From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Lars Ingebrigtsen Newsgroups: gmane.emacs.bugs Subject: bug#27357: 26.0.50; Emacs starts fullscreen in Ubuntu 17.04 Date: Sun, 16 Jul 2017 15:29:13 +0200 Message-ID: <87bmokqzme.fsf@mouse> References: <594143AB.7040500@gmx.at> <59423E58.8030606@gmx.at> <59425D45.1010006@gmx.at> <87a84ik6w6.fsf@mouse> <871spuk5im.fsf@mouse> <595DD90E.2040503@gmx.at> <87lgnor1v3.fsf@mouse> <596B613C.4080203@gmx.at> <87h8ycr0qu.fsf@mouse> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1500211813 5987 195.159.176.226 (16 Jul 2017 13:30:13 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sun, 16 Jul 2017 13:30:13 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.0.50 (gnu/linux) Cc: 27357@debbugs.gnu.org To: martin rudalics Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Jul 16 15:30:08 2017 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dWjce-0001Gj-JN for geb-bug-gnu-emacs@m.gmane.org; Sun, 16 Jul 2017 15:30:08 +0200 Original-Received: from localhost ([::1]:45295 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dWjcj-0007Hr-LH for geb-bug-gnu-emacs@m.gmane.org; Sun, 16 Jul 2017 09:30:13 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:59791) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dWjcc-0007GN-1v for bug-gnu-emacs@gnu.org; Sun, 16 Jul 2017 09:30:07 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dWjcY-0001G0-Ru for bug-gnu-emacs@gnu.org; Sun, 16 Jul 2017 09:30:05 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:38462) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1dWjcY-0001Fs-PG for bug-gnu-emacs@gnu.org; Sun, 16 Jul 2017 09:30:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1dWjcY-0003Kg-BM for bug-gnu-emacs@gnu.org; Sun, 16 Jul 2017 09:30:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Lars Ingebrigtsen Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 16 Jul 2017 13:30:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 27357 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 27357-submit@debbugs.gnu.org id=B27357.150021175812731 (code B ref 27357); Sun, 16 Jul 2017 13:30:02 +0000 Original-Received: (at 27357) by debbugs.gnu.org; 16 Jul 2017 13:29:18 +0000 Original-Received: from localhost ([127.0.0.1]:41139 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dWjbq-0003JH-6e for submit@debbugs.gnu.org; Sun, 16 Jul 2017 09:29:18 -0400 Original-Received: from hermes.netfonds.no ([80.91.224.195]:59609) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dWjbo-0003J9-ML for 27357@debbugs.gnu.org; Sun, 16 Jul 2017 09:29:17 -0400 Original-Received: from cm-84.209.243.26.getinternet.no ([84.209.243.26] helo=mouse) by hermes.netfonds.no with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1dWjbl-0005gD-IK; Sun, 16 Jul 2017 15:29:15 +0200 In-Reply-To: <87h8ycr0qu.fsf@mouse> (Lars Ingebrigtsen's message of "Sun, 16 Jul 2017 15:04:57 +0200") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:134617 Archived-At: I found the place where the tooltips are positions, and that seemed like an easy place to experiment, so I did. If I divide root_x and root_y by 2, the positioning is exactly as it's supposed to be. So the wrong calculations here seem to be completely internal to gtk. To verify, I did the following: diff --git a/src/gtkutil.c b/src/gtkutil.c index 2d4abefa96..050433d5c3 100644 --- a/src/gtkutil.c +++ b/src/gtkutil.c @@ -724,7 +724,10 @@ xg_show_tooltip (struct frame *f, int root_x, int root_y) if (x->ttip_window) { block_input (); - gtk_window_move (x->ttip_window, root_x, root_y); + printf("Input x %d, y %d\n", root_x, root_y); + gtk_window_move (x->ttip_window, root_x/2, root_y/2); + gtk_window_get_position (x->ttip_window, &root_x, &root_y); + printf("Output x %d, y %d\n", root_x, root_y); gtk_widget_show_all (GTK_WIDGET (x->ttip_window)); unblock_input (); } The output is: Input x 725, y 464 Output x 362, y 232 So gtk seems to think that we're living in a world where the pixels passed in are supposed to be doubled from what Emacs is passing it: That is, that if you send in (2, 2), the physical pixel being addressed is (4, 4). Perhaps there's a way to tell gtk to stop doing that? -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no