GNOME Bugzilla – Bug 314235
Switching resolution can cause all applets to become right stuck
Last modified: 2009-09-10 15:10:01 UTC
From fedora: https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=165748 the order of the objects on the Gnome panel gets mixed up after switching from resolution 1600x1200 to resolution 1024x768 and to 1600x1200. Screenshot before: https://bugzilla.redhat.com/bugzilla/attachment.cgi?id=117887 Screenshot after: https://bugzilla.redhat.com/bugzilla/attachment.cgi?id=117888 I should probably mention that in the sequence documented above, I did absolutely nothing, except switching resolution and do what you asked me to. Nothing was done to the panel while in 1024x768. From looking at the configuration dumps attached to the bug you can see that the config changed along the lines of: @@ -16,11 +16,11 @@ launcher_location = gegl-00b540bf94.desktop tooltip = use_menu_path = false - panel_right_stick = false + panel_right_stick = true locked = false menu_path = applications:/ object_type = launcher-object - position = 380 + position = 6 /tmp/t2/objects/object_0: toplevel_id = panel_0 action_type = force-quit @@ -31,11 +31,11 @@ launcher_location = tooltip = use_menu_path = false - panel_right_stick = false + panel_right_stick = true locked = false menu_path = applications:/ object_type = action-applet - position = 538 + position = 4 /tmp/t2/objects/menu_bar: toplevel_id = top_panel action_type = lock i.e. all the applets became right stuck. Basically, what we need to ensure is that we never change an applets GConf config unless the user explicitly moves it. In panel-widget.c we try to do this by storing the configured position in AppletData::pos and the actual position in AppletData::constrained_pos - so if the resolution changes, I'd expect to see all applet's AppletData::pos remain the same, but the AppletData::constrained_pos would reflect the actual position on the panel. It looks like the problem might be in panel_widget_right_stick() - when the panel width (for horizontal panels) changes, we call this function and it changes AppletData::constrained_pos, which will later get saved to GConf. There shouldn't be any need for this - panel_widget_right_stick() should only change AppletData::pos, I reckon
Created attachment 51170 [details] [review] dont-screw-up-the-panel-on-resize.patch Okay, here's a patch which looks reasonable to me I'm failing to reproduce the issue, though
http://bugs.winehq.org/show_bug.cgi?id=6069 rasz@rasz-desktop:~$ xrandr -d :0 -q SZ: Pixels Physical Refresh *0 1024 x 768 ( 271mm x 203mm ) *85 1 800 x 600 ( 271mm x 203mm ) 85 2 640 x 480 ( 271mm x 203mm ) 85 Current rotation - normal Current reflection - none Rotations possible - normal Reflections possible - none rasz@rasz-desktop:~$ xrandr -d :0 -s 2 rasz@rasz-desktop:~$ xrandr -d :0 -s 0 the result is cropped wine window and messed up panel. btw same bug http://bugzilla.gnome.org/show_bug.cgi?id=343506
I have seen this quite often too, and there are several debian bugs open about this issue. See for example http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=373795
Hi, I have the exact same problem on my laptop. I must use a lower resolution to use an external display and when I switch back to my previous resolution, all applets have been moved around in the panel. This is so irritating that I created a second account that I use only with an external display just to avoid this... I don't know exactly how this is currently managed, but one solution may be to store the positions of applets in separated configurations, one for each used resolution. This way, I could organize my panel to fit the lower resolution, and then the previous configuration will used when switching back to the standard resolution.
two years and still Status: UNCONFIRMED nice ...
(In reply to comment #5) > two years and still Status: UNCONFIRMED > nice ... There's really not a big difference between UNCONFIRMED and NEW in this bugzilla (at least, for most people). We know this is a bug. Someone just needs to sit down and fix it. It's not an easy one, though.
I am confirming this bug on GNOME 2.20.1 Ubuntu 7.10 Gutsy Gibon i386
I can also confirm it with Ubuntu 7.10 with latest patches. It's running Gnome 2.20.1 and applets keep moving around when I switch to an external monitor. Also, I think http://bugzilla.gnome.org/show_bug.cgi?id=492315 is the same.
I can also confirm this with Ubuntu 8.04.
Same issue with openSUSE 11.0 (Gnome 2.22.1). How to reproduce problem: 0/ Add applets to panel 1/ Run any Wine application in fullscreen mode when its resolution differs from desktop resolution 2/ Applets (all but the leftmost one) are randomly distributed on panel, leftmost one stays in right position
*** Bug 563646 has been marked as a duplicate of this bug. ***
*** This bug has been marked as a duplicate of 341441 ***
I have just confirmed that the attached patch does fix the problem. I had to use 'gconf-editor' to set the positions of the right-stuck applets. For each of them, I set their relative position from the right end of the panel. Now they are staying where they belong when I switch from laptop to tablet mode, and also after log-out and log-in.
Please apply that patch, it's two lines. Is the right-stick property automatically set or should it be necessarily changed by hand? It can be set with a guess: if the applet touches one of the screen edges, then it sticks on that side. If an applet touches only applets with the left (resp. right) stick property or without that property set at all, then it sticks on the same side. If it touches both or nothing, then don't set the property or default to left?