3

How to advise code that pops up menus (like the ones you get by left-clicking a major-mode indicator in the modeline) to stay within the current Emacs frame?

Background:
Probably this is a bug within my window manager. I have a multi-monitor setup with one screen above the other. With Emacs's frame at the bottom of the upper screen its popup menus look like this:
enter image description here

But it should look like this:
enter image description here

I would not mind if this popup menu popped up far away from my mouse, as long as I was able to use the menu.

Note: with x-popup-menu placing of own popup menus is possible, so it should somehow be possible with those major-mode popup menus from modeline.

  • I suggest that you file an enhancement request for Emacs, using M-x report-emacs-bug (that's also for enhancement requests). Presumably the request is for a Boolean user option to control whether a mode-line popup menu should be contained within the frame borders (or something similar). – Drew Apr 10 '19 at 15:14
  • The multi-monitor setup is a very good observation. At my place the monitors stand side-by-side. On the first monitor the pop-up menus are off the screen on the second one they are not (for the same frame and the same pop-up menu). It happens with emacs -Q and Emacs version GNU Emacs 26.1 (build 2, x86_64-pc-linux-gnu, GTK+ Version 3.22.30) of 2018-05-29. – Tobias Apr 10 '19 at 16:04
  • Do the displays differ in size? If so which one is larger? – Tobias Apr 10 '19 at 16:35
  • After changing the resolution of my larger screen such that it is equal to the resolution of the smaller one Emacs avoids cutting off the menu on both screens. So the effect is related to different screen sizes (in pixels). – Tobias Apr 10 '19 at 17:27
  • @Tobias both screens have the same resolution (FullHD). The problem is that one screen is above the other and then either X11 or my window manager has a bug. – jue Apr 10 '19 at 19:33

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.