GNU bug report logs -
#27357
26.0.50; Emacs starts fullscreen in Ubuntu 17.04
Previous Next
Reported by: Lars Ingebrigtsen <larsi <at> gnus.org>
Date: Wed, 14 Jun 2017 12:34:02 UTC
Severity: normal
Tags: fixed
Merged with 20619,
21348,
22204,
23231
Found in versions 24.5, 25.0.50, 25.1.50, 26.0.50
Done: Lars Ingebrigtsen <larsi <at> gnus.org>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
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
This bug report was last modified 7 years and 312 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.