[SOLVED] application minimizes
Moderator: ickputzdirwech
[SOLVED] application minimizes
When I switch to the desktop using the Windows key because I just want to do something different for a short time, the Factorio application minimizes itself. If I now open another application, the Factorio application forces itself directly into the background.
Last edited by XaLpHa89 on Wed Jan 16, 2019 12:11 am, edited 1 time in total.
- bobingabout
- Smart Inserter
- Posts: 7352
- Joined: Fri May 09, 2014 1:01 pm
- Contact:
Re: application minimizes
I believe that's only an issue when you use fullscreen mode, as it is effectively borderless full screen window, and you the same thing happens with other borderless full screen programs.
if you press the minimise button in window mode, it doesn't happen.
Instead of pressing the windows key, try pressing alt + Tab instead, I'm fairly sure this actually minimises the game rather than just showing the desktop for a moment, and you have less problems with it.
Though on a semi-related note, I also hope that the devs are working on it so the graphics actually stop being drawn when the game is minimised as a lot of games do. it's fairly annoying to not get your graphics power back for whatever you do want to look at just because Factorio is running minimised. It's not like the game even needs the graphics to continue the simulation, Factorio is one of those ideal games where graphics can just be turned off and it runs fine, so it shouldn't be wasting graphics power when minimised.
if you press the minimise button in window mode, it doesn't happen.
Instead of pressing the windows key, try pressing alt + Tab instead, I'm fairly sure this actually minimises the game rather than just showing the desktop for a moment, and you have less problems with it.
Though on a semi-related note, I also hope that the devs are working on it so the graphics actually stop being drawn when the game is minimised as a lot of games do. it's fairly annoying to not get your graphics power back for whatever you do want to look at just because Factorio is running minimised. It's not like the game even needs the graphics to continue the simulation, Factorio is one of those ideal games where graphics can just be turned off and it runs fine, so it shouldn't be wasting graphics power when minimised.
Re: application minimizes
In 0.17 fullscreen game will minize if you alt+tab out of it, as it is default behavior in SDL. We might add option to disable this behavior, but when I tested it, it seemed SDL is much more stubborn about keeping its borderless fullscreen window on top than Allegro was.XaLpHa89 wrote: Fri Oct 05, 2018 7:37 am When I switch to the desktop using the Windows key because I just want to do something different for a short time, the Factorio application minimizes itself. If I now open another application, the Factorio application forces itself directly into the background.
Rseding implemented it in 0.16.0 for Windows version. In 0.17 it should work on all OSes. There is an config.ini option to disable this behavior "halting-rending-when-minimized", but it is enabled by default ... other than that nobody works on this any further. (Note: the game needs to be minimized, being under some other window is not enough)bobingabout wrote: Fri Oct 05, 2018 8:22 amThough on a semi-related note, I also hope that the devs are working on it so the graphics actually stop being drawn when the game is minimised as a lot of games do. it's fairly annoying to not get your graphics power back for whatever you do want to look at just because Factorio is running minimised. It's not like the game even needs the graphics to continue the simulation, Factorio is one of those ideal games where graphics can just be turned off and it runs fine, so it shouldn't be wasting graphics power when minimised.
- eradicator
- Smart Inserter
- Posts: 5211
- Joined: Tue Jul 12, 2016 9:03 am
- Contact:
Re: application minimizes
Maybe i'm misunderstanding what you mean by "on top" here... but for me the main point of "borderless fullscreen" is that it behaves mostly like a window. I.e. that i can "stack" it with other windows and push other windows in front of it as i see fit? I.e. the only differences i expect there to be when something calls itself "borderless fullscreen" is that it a) doesn't have a window border and b) that it doesn't cover the task bar when it's not the active window.posila wrote: Fri Oct 05, 2018 9:18 am it seemed SDL is much more stubborn about keeping its borderless fullscreen window on top than Allegro was.
Regrettably factorio currently can't do that so i'm stuck with a normal window (i guess i could hack an autohotkey script to force that behavior since factorio behaves quite nicely when resizing the window).
Author of: Belt Planner, Hand Crank Generator, Screenshot Maker, /sudo and more.
Mod support languages: 日本語, Deutsch, English
My code in the post above is dedicated to the public domain under CC0.
Mod support languages: 日本語, Deutsch, English
My code in the post above is dedicated to the public domain under CC0.
- eradicator
- Smart Inserter
- Posts: 5211
- Joined: Tue Jul 12, 2016 9:03 am
- Contact:
Re: application minimizes
While testing that option (though not affected by the option) i just noticed that i get huge CPU usage increases when i minimize factorio. On a fresh map i get 8% utilization when the window is active, and 20% when i minimize the game. Similarly on a large factory it goes from 19% to 24% utilization.posila wrote: Fri Oct 05, 2018 9:18 amRseding implemented it in 0.16.0 for Windows version. In 0.17 it should work on all OSes. There is an config.ini option to disable this behavior "halting-rending-when-minimized", but it is enabled by default ... other than that nobody works on this any further. (Note: the game needs to be minimized, being under some other window is not enough)bobingabout wrote: Fri Oct 05, 2018 8:22 amThough on a semi-related note, I also hope that the devs are working on it so the graphics actually stop being drawn when the game is minimised as a lot of games do. it's fairly annoying to not get your graphics power back for whatever you do want to look at just because Factorio is running minimised. It's not like the game even needs the graphics to continue the simulation, Factorio is one of those ideal games where graphics can just be turned off and it runs fine, so it shouldn't be wasting graphics power when minimised.
Author of: Belt Planner, Hand Crank Generator, Screenshot Maker, /sudo and more.
Mod support languages: 日本語, Deutsch, English
My code in the post above is dedicated to the public domain under CC0.
Mod support languages: 日本語, Deutsch, English
My code in the post above is dedicated to the public domain under CC0.
Re: application minimizes
So, DirectX has concept of exclusive fullscreen - the application takes exclusive ownership of the picture on screen, possibly even changes display mode (resolution, refresh rate, color depth) and rendered image goes directly to the screen. If you alt+tab from such application, your screen(s) might blink as they change mode back to desktop and it usually takes a second to swich into or out of the application. From the programming stand point - the application has window, but its size is completely irrelevant, as backbuffer can have any arbitrary size and since we don't render to the window.eradicator wrote: Fri Oct 05, 2018 10:28 amMaybe i'm misunderstanding what you mean by "on top" here... but for me the main point of "borderless fullscreen" is that it behaves mostly like a window. I.e. that i can "stack" it with other windows and push other windows in front of it as i see fit? I.e. the only differences i expect there to be when something calls itself "borderless fullscreen" is that it a) doesn't have a window border and b) that it doesn't cover the task bar when it's not the active window.
Regrettably factorio currently can't do that so i'm stuck with a normal window (i guess i could hack an autohotkey script to force that behavior since factorio behaves quite nicely when resizing the window).
Borderless fullscreen, to me, is when application renders to its window (so rendered image doesn't go to screen directly, but to compositing window manager in OS), but dimensions and properties of the window are such that it covers entire screen (including task bar). Advantage is that switching to different window works like in any other application - so it is instant. Disadvantage is that the window needs to force itself on top of things that don't want to be covered by windows normally (like task bar) - or somehow hide those things. It seems there is no standard way how to do it right. For me, 0.16 works perfectly fine on all my computers - if I alt+tab out of fullscreen, I can interact with desktop, other applications and task bar, but I know Twinsen was able to reproduce some weird behavior under some circumstances. SDL seems to be more aggresive in keeping its window top-most, so that's probably why by default it minimizes when alt+tabbing out of it. (EDIT: it might not be more aggressive, it might be just different from Allegro, and while Allegro behaved nicely for me, SDL doesn't)
In my opinion, borderless fullscreen gives superiour user experience on multimonitor setups (I can interact with different application on other screen without weird transitions between exclusive fullscreen and desktop); exclusive fullscreen is probably better for laptops, as is doesn't have to deal with rest of the desktop when rendering, or offers option to lower resolution.
In OpenGL, there is no concept of exclusive fullscreen, but it seems to me, the drivers trigger it automatically when OpenGL context renders to a window surface that covers entire screen.
EDIT2: Tested it again on my work computer (previously I was testing it on my home computer) and SDL behaved same as Allegro (when auto-minimize was disabled). That is - when working with application on other screen, Factorio still covered task bar, but once I alt+tabbed to different application on the same screen as Factorio, task bar showed up.
- eradicator
- Smart Inserter
- Posts: 5211
- Joined: Tue Jul 12, 2016 9:03 am
- Contact:
Re: application minimizes
Sounds promising. I use a laptop with an attached screen when one is available / when i'm in the mood. So i don't have a stable monitor count, but i also don't want to constantly switch window modes (and i do prefer borderless even for single monitor so i can peak at the game through the window seams). Also thanks for the detailed explanation :).posila wrote: Fri Oct 05, 2018 12:15 pm EDIT2: Tested it again on my work computer (previously I was testing it on my home computer) and SDL behaved same as Allegro (when auto-minimize was disabled). That is - when working with application on other screen, Factorio still covered task bar, but once I alt+tabbed to different application on the same screen as Factorio, task bar showed up.
Author of: Belt Planner, Hand Crank Generator, Screenshot Maker, /sudo and more.
Mod support languages: 日本語, Deutsch, English
My code in the post above is dedicated to the public domain under CC0.
Mod support languages: 日本語, Deutsch, English
My code in the post above is dedicated to the public domain under CC0.
Re: application minimizes
I am pleased that this topic has caused some discussion. I am on a Windows 10 system. I'm not sure if I understood everything. With ALT + TAB I can jump between applications. My approach is, I press CMD + D and want to work on the desktop without any application sliding back into the foreground.


Re: [SOLVED] application minimizes
The solution is the use of: [ALT]+[ENTER]
So jumping between full screen and window screen.
So jumping between full screen and window screen.
Re: [SOLVED] application minimizes
Current builds have the habit of sometimes refusing to go to the background when alt-tabbing out of factorio during launch on Win10 64bit.
I sometimes have to click into factorio then tab out again to see my other windows. May or may not have something to do with me launching factorio from batch script.
I sometimes have to click into factorio then tab out again to see my other windows. May or may not have something to do with me launching factorio from batch script.
My Mods: mods.factorio.com