drracket icon indicating copy to clipboard operation
drracket copied to clipboard

Tooltips displayed on wrong monitor

Open lwhjp opened this issue 5 years ago • 7 comments

I'm using X11 (Debian buster) with three monitors.

When I mouse-over something in DrRacket, I get a tooltip (usually a type signature or "imported from" message), but it is displayed on the monitor to the right of the monitor on which DrRacket is running -- this is presumably not what is intended.

lwhjp avatar Nov 16 '19 13:11 lwhjp

I also use X11 with 3 monitors and the tooltips appear in the right place. Can you say more about your setup (for example, WM)?

samth avatar Nov 18 '19 15:11 samth

I'm using the stock X.Org from Debian (package version 1:7.7+19, server reports "X.Org X Server 1.20.4") with xfce4. No custom configuration - xorg is autodetecting everything.

The monitors are all plugged into one AMD Radeon RX 570 card, two with DisplayPort and one DVI, running at 2560x1440@60Hz/24-bit, arranged horizontally into one very wide desktop. The order from left to right is 2, 3, 1 - if DrRacket is on monitor 2 or 3, I see tooltips on 3 or 1 respectively (I get no tooltips when DrRacket is on the rightmost monitor 1). However, if I reorder the monitors to 1, 2, 3, then running DrRacket on monitor 1 gives me tooltips on monitor 2, but running on monitors 2 or 3 shows no tooltips. Monitor 3 is the one with the DVI connection.

Interestingly, I just tried changing both the Xfce (GTK?) theme and DrRacket theme, but the tooltips still show up as pale yellow (on the wrong monitor), whereas all the other apps I tried use the theme color (on the correct monitor).

lwhjp avatar Nov 18 '19 23:11 lwhjp

Oh, and this happens both with Racket 7.2 included with Debian, and a recent build of 7.5.0.6 from master. I don't recall any version which worked on this machine, so I don't think this is a recent regression.

lwhjp avatar Nov 19 '19 00:11 lwhjp

Just chime in: I have the same problem running drracket on wayland

Screenshot from 2022-06-14 15-44-10

Screenshot from 2022-06-14 15-45-15

capfredf avatar Jun 14 '22 19:06 capfredf

I also have this problem using XFCE4 with two monitors.

samdphillips avatar Jun 14 '22 21:06 samdphillips

I had some time and did some digging.

It seems this issue has something to do with "the default monitor". On my machine, (get-display-left-top-inset #f #:monitor 0) returns -1920 and 0, which does not follow the documentation for this function:

For monitor 0, on Unix and Windows, the result is always 0 and 0; 

In addition, I changed the implementation of get-display-left-top-inset so that it always used 1 for monitor. Then, the tooltip showed up where the drracket main window was.

capfredf avatar Dec 25 '22 20:12 capfredf

Relevant: racket/gui#223 Not sure if related: racket/racket#3462

shhyou avatar Feb 05 '23 04:02 shhyou