#9 Main window always starts on the "primary" monitor


I am running Ubuntu Oneiric with a nonstandard display configuration. The main display of the notebook has a resolution of 1440x900, the external monitor is 1200x1920 (vertical). Now diffuse seems to start always on the external monitor, which is rather inconvenient. How is the display to show the main window determined?


  • Derrick Moser

    Derrick Moser - 2011-12-06

    Diffuse will record its last position in ~/.local/share/diffuse/state before quitting. The next time Diffuse is run, it will move the window to the position recorded in that file. You should be able to just move the window to the desired location and it will be remembered.

    Is ~/.local/share/diffuse/state being created? If you move the window to a new position and quit, does the file get updated? Does Diffuse correctly move the window to the old position when run again?

  • Kirill Müller

    Kirill Müller - 2011-12-06
    • summary: Main window always starts on the vertical monitor --> Main window always starts on the "primary" monitor
  • Kirill Müller

    Kirill Müller - 2011-12-06

    The position is recorded, the file is written and read correctly. The only thing that is missing in the file is the display on which to open the window.

    I have tried several arrangements of the logical displays. It turns out that GNOME (or whoever) assumes that the monitor that is on the bottom right is the primary monitor -- for whatever reason. That is, if I close diffuse while it's non-maximized on the secondary monitor, it will be restored at exactly the same coordinates, but on the primary monitor. Now, my vertical monitor is located right of the laptop, and hence is treated as "primary" monitor.

    I'm not sure if this can be handled on the client side after all. Eclipse has exactly the same problems. But if the problem can be solved at the client side, this will be a valuable hint for fixing Eclipse, too.

  • Kirill Müller

    Kirill Müller - 2011-12-06

    No, I was wrong. The display information is implicit. If the window is closed on the vertical monitor (right of the laptop), the x coordinate becomes "large".

    I think it's some "clever" window placement algorithm that prevents the positioning. The GTK documentation reads that window managers are free to ignore move operations before a window is shown. Didn't know that.

    SOLUTION: Copying a call of diff.loadState(...) just after diff.show() solves the problem for me, there is even no flickering (Unity 2D).

  • Kirill Müller

    Kirill Müller - 2015-01-10

    This is not an issue in my Ubuntu Gnome anymore.


Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

No, thanks