-
-
Notifications
You must be signed in to change notification settings - Fork 236
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature: Remember Windows Position #1158
Comments
Whoa 5 monitors? Yikes. Well, MM does this for my setup with 2 monitors. I open MM on a secondary monitor shut down and it comes back up on the secondary monitor. I suspect there's an edge case here with 5 monitors where the virtual space is too far out where the monitor gets moved. The default is 10,000 pixels so I suspect it lies outside of it. How are your monitors laid out and how big are they? Can you try using a monitor that is most 'adjacent' to your main monitor - and thus more likely to be within a more limited pixel range - and see if that works? MM basically uses a virtualized desktop space - all monitors are mapped into that pixel space and the shutdown location is remembered. If the location is outside of dimensions when MM starts back up it will pull the monitor back onto the main screen Another related issue is if the Window is maximized on another screen - it looks like there's a bug that when that's the case the position is not correctly remembered as it restores maximized onto the main screen. I'll take a look and review the algo for this - I bet there's some outer limit that is triggering the move back to the main desktop. |
I've added a fix for the Maximized window positioning. Maximized windows should now remember their position and come back on the monitor they were last run on (assuming the screen layouts stay the same). v3.5.6.2 |
Incidentally this patch also fixes a related issue where the window in some cases double positions and appears to bounce around - specifically in Maximized modes but also when relocating to other screens. This update should snap windows into the right place exactly once (as it should be) in all situations. |
Seems related to presentation mode. See #1155 |
Sorry, was busy. Downloaded latest version 3.5.6.2. Good news. The copy error is gone. Fixed. The bad news. The windows/monitor position is now worse than before. Before: After: The way I open it: I just open a markdown file, I set .md files to use Markdown Monster as default. In the settings I have the checkbox option enabled 'Open in Presentation Mode' because I mostly want to open files to read them first, as documentation by default. I decided to test this with the setting off. And then it seems to work. It seems to remember the monitor, and it opens the applications correctly. I then check the setting again, and it goes off-screen once more, between 2 monitors (none of which are the one I actually set before). It seems to be isolated to when Presentation Mode is turned on. The JSON after closing the app (with Presentation Mode checked) "WindowPosition": {
"Top": 1080,
"Left": 516,
"Width": 1050,
"Height": 690,
"InternalPreviewWidth": 883, I think you just need to look into Presentation Mode, I will turn it off for now, not a big deal, but at least we know where the bug is 😊 |
Confirmed. I see different behavior than you, but it's definitely not right. On my machine with Open in Presentation Mode checked, if I close the monitor on my second monitor, it'll reopen in what seems like a random position on my main monitor which is very odd. I'll have to take a look and see. Presentation mode on startup is tricky due to timing of the document loading and I think the hacks around waiting for the document to be available are causing this weird behavior. Taking a look... |
Give 3.6.7.2+ a try - it should have the presentation mode issue fixed. As suspected this was a timing issue with the notification bit getting fired before the window had properly positioned itself and then wrote out the wrong values to the configuration, which threw off the resizing. The solution is to do the presentation mode activation after the window has completed loading. This will make the startup a little janky as the window adjusts after it becomes visible, but it ensures that mode behaves correct and it only occurs on startup when presentation mode is explicitly requested on startup. |
I have 5 displays, with a DisplayLink Dock.
When I open the MarkdownMonster, it always opens it by default on the monitor that is set as the main (default) one on Windows 11.
It would be nice if it would remember the windows position and monitor like other applications. For example, if I moved it to monitor 3 and close it, it should then always open on monitor 3.
The same should be true for the window used by the external preview option.
Most Windows applications do this by default for years. They remember where it was last opened, that means monitor, and even position, if in case it was resized.
The text was updated successfully, but these errors were encountered: