elementary / applications-menu

Applications Menu for elementary OS and the Pantheon desktop environment
https://elementary.io
GNU General Public License v3.0
104 stars 35 forks source link

Applications menu is too narrow #567

Open itoshkov opened 1 year ago

itoshkov commented 1 year ago

What Happened?

Sometimes the applications menu is too narrow (I guess about half its normal width). Killing and restarting wingpanel sometimes helps, but not always. Logging out and back again helps, but again, not always.

(I have a screenshot, but I'm not sure how to attach it.)

Steps to Reproduce

  1. Login.
  2. Click on the "Applications" menu.
  3. The menu shows up, but sometimes it's narrower than normal.

Expected Behavior

The menu size should be consistent.

OS Version

7.x (Horus)

Software Version

Latest release (I have run all updates)

Log Output

No response

Hardware Info

I have an ATI/NVIDIA laptop and I'm running the nvidia proprietary driver in on-demand mode. The relevant lspci output:

01:00.0 VGA compatible controller: NVIDIA Corporation GA107M [GeForce RTX 3050 Mobile] (rev a1)
05:00.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] Renoir (rev c6)
itoshkov commented 1 year ago

I ran io.elementary.wingpanel from the command line and I saw the following line in the log when I first open the menu and it shows up narrow:

(switchboard-plugin:5376): Gtk-CRITICAL **: 13:40:04.464: gtk_style_context_add_provider_for_screen: assertion 'GDK_IS_SCREEN (screen)' failed

I haven't been able to run it with normal width to see if the same message appears in that case.

itoshkov commented 1 year ago

I haven't been able to run it with normal width to see if the same message appears in that case.

I finally managed to run it with a proper sized Applications menu and it still shows this error message.

itoshkov commented 1 year ago

Any help with this?

lenemter commented 1 year ago

@itoshkov Can you send a screenshot please?

itoshkov commented 1 year ago

The narrow menu

The normal menu

itoshkov commented 1 year ago

I found a workaround for the issue. It's not pretty but it has worked consistently for me so far. Here are the steps:

  1. Kill wingpanel: pkill io.elementary.w [^1]
  2. Press the key combination to show the application menu ( Space by default).
  3. If the menu is still narrow kill the wingpanel process again. This time the whole wingpanel will disappear. Here I used to run wingpanel manually, but it was behaving unpredictably again. Instead, if you press the application menu key combination the winpanel will be restarted by the system. Press the key combination a couple more times (without killing the process) and the menu will appear with proper size.

[^1]: The actual process name is io.elementary.wingpanel, but pkill and pgrep seem to have a limit on the number of characters they recognize. To make sure that it will only kill the wingpanel you can first do pgrep -a io.elementary.w. If the result contains more processes, you'll at least have the actual PID of the wingpanel and can use kill $PID instead. Note that the PID would change after restart of the process, which I think happens after the second TERM signal is sent.

itoshkov commented 11 months ago

It looks like this might be timing dependent. It seems to manifest itself if I try to open the Applications menu too quickly after I log in. On the other hand, if I wait for 5-10 seconds (or maybe less) before doing anything, things seem to work fine.

I'm not sure if other actions would affect this, like using the dock or opening a terminal with T.

sauntor commented 11 months ago

I got this problem too, it may be caused by HiDPI scaling.

itoshkov commented 11 months ago

I got this problem too, it may be caused by HiDPI scaling.

I am running on 1080 without HiDPI scaling.