Jump to content
Sign in to follow this  
mdexter

Script running fullscreen windowed - Help!

Recommended Posts

Hi all,I am using Autoit v3 running a script to load fsx in windowed mode but fullscreen, although its great its runs at the desktop resolution leaving like a 2px white border, and I am wanting the window to bleed over the desktop resolution to hide the white borders. Ok here is the script I am using in Autoit, can anyone help me with the changes I will need to add so I can get rid of the white borders??Many thanks in advanceCURRENT SCRIPT FOR FULLSCREEN FSX WINDOWED MODE AT 1920 x 1200 but has a white border, need to add a couple more px to eaacvh edge!!__________________________________________________________________________________________________________#include <WindowsConstants.au3> Dim $fsxWindowName = "Microsoft Flight Simulator X" WinWait($fsxWindowName) macro_fullscreen() Func macro_fullscreen() ; Make the active window fullscreen. Const $GWL_STYLE = -16 Const $GWL_EXSTYLE = -20 Const $SWP_NOMOVE = 0x0002 Const $SWP_NOSIZE = 0x0001 Const $SWP_NOZORDER = 0x0004 Const $SWP_FRAMECHANGED = 0x0020 $hwnd = WinGetHandle($fsxWindowName, "") if ($hwnd<>0) Then ; Toggle windows styles Local $winlong = DllCall("user32.dll","long","GetWindowLong","hwnd",$hwnd,"int",$GWL_STYLE) $result = DllCall("user32.dll","long","SetWindowLong","hwnd",$hwnd,"int",$GWL_STYLE,"long",BitXOR($winlong[0],$WS_CAPTION, $WS_BORDER,$WS_THICKFRAME)) ; Toggle extended styles $winlong = DllCall("user32.dll","long","GetWindowLong","hwnd",$hwnd,"int",$GWL_EXSTYLE) $result = DllCall("user32.dll","long","SetWindowLong","hwnd",$hwnd,"int",$GWL_EXSTYLE,"long",BitXOR($winlong[0],0)) ; Maximize and refresh display DllCall("user32.dll", "long", "SetWindowPos", "hwnd", $hwnd, "hwnd", $hwnd, "int", 0, "int", 0, "int", @DesktopWidth, "int", @DesktopHeight, "long", BitOR($SWP_NOZORDER, $SWP_FRAMECHANGED)) else msgbox(0,"Error","Failed to get active window handle") endif EndFunc ________________________________________________________________________________Many thanks in advance

Share this post


Link to post
Share on other sites
Thanks for the heads up it works wonderfully, cant believe I never heard of this before, brilliant.
Finally instant alt-tab too ;)

Share this post


Link to post
Share on other sites

Hi Squishy, I usecd autohotkey and it doesnt load fullscreen.I am wanting a script that will load the window full screen with no borders, does anyone have this for FSX, where there is no white border part. I run 1920 x 1200 and tried several ways but I assume it would be -2 px or something lihe that, does anyone have a script like that for Autoit or Autohotkey, the one from avsim does not go true fullscreen, many thanks anyone.....

Share this post


Link to post
Share on other sites
Hi Squishy, I usecd autohotkey and it doesnt load fullscreen.I am wanting a script that will load the window full screen with no borders, does anyone have this for FSX, where there is no white border part. I run 1920 x 1200 and tried several ways but I assume it would be -2 px or something lihe that, does anyone have a script like that for Autoit or Autohotkey, the one from avsim does not go true fullscreen, many thanks anyone.....
Hi,I am the author of the authotkey script mentioned above, and I can assure you that the FSX window (or any window for that matter) will go to full screen without any borders whatsoever by pressing win+F11. You have to make sure however that you have your taskbar set to auto-hide. I am using 1920 x 1200 myself as well, but the script is resolution independent.Maarten

Maarten Boelens ([m][a:][R][t][ʏ][n])
Developer of SimLauncherX

ftx_supporter_avsim.gifC172Siggy1_zps11944daf.jpg

Share this post


Link to post
Share on other sites
Hi Squishy, I usecd autohotkey and it doesnt load fullscreen.I am wanting a script that will load the window full screen with no borders, does anyone have this for FSX, where there is no white border part. I run 1920 x 1200 and tried several ways but I assume it would be -2 px or something lihe that, does anyone have a script like that for Autoit or Autohotkey, the one from avsim does not go true fullscreen, many thanks anyone.....
I run at 1920x1200 and use Maarten's script with Autohotkey and I go full screen with no border. Works like a charm.

Share this post


Link to post
Share on other sites
I run at 1920x1200 and use Maarten's script with Autohotkey and I go full screen with no border. Works like a charm.
Hmm I can see like 1px of the baclground wallpaper showing, I will post a screeny of what happens if anyone has the script to post the code here I will copy it directly from here and create the .exe, could someone post the script code here for Autohotkey please??Many thanks, P.S. Many thanks Maarten for your script BTW

Share this post


Link to post
Share on other sites
Hi,I am the author of the authotkey script mentioned above, and I can assure you that the FSX window (or any window for that matter) will go to full screen without any borders whatsoever by pressing win+F11. You have to make sure however that you have your taskbar set to auto-hide. I am using 1920 x 1200 myself as well, but the script is resolution independent.Maarten
Hello. I just wanted to mention that I can run fullscreen just fine without auto-hiding the taskbar.9/10 it works fine instantly, the 1/10 time I have to refocus FSX after windows+D to desktop, and it works great :( Thanks btw

Share this post


Link to post
Share on other sites
Hello. I just wanted to mention that I can run fullscreen just fine without auto-hiding the taskbar.9/10 it works fine instantly, the 1/10 time I have to refocus FSX after windows+D to desktop, and it works great Big Grin.gif Thanks btw
So when you say refocus, is that by ALT+TAB back into the FSX screen or clicking the screen, I use an autohide taskbar proggy aswell, it shows like 1px of the wallpaper in the background around the edges.....hmm, again is there a way to make the script -1 px on each edge.Is the script from Autoit, do I simply make that same script an Autohotkey script??Can someone post the script for autohotkey??Many thanks

Share this post


Link to post
Share on other sites
So when you say refocus, is that by ALT+TAB back into the FSX screen or clicking the screen, I use an autohide taskbar proggy aswell, it shows like 1px of the wallpaper in the background around the edges.....hmm, again is there a way to make the script -1 px on each edge.Is the script from Autoit, do I simply make that same script an Autohotkey script??Can someone post the script for autohotkey??Many thanks
Hi Mat, (from Vince) No not really, this only removes the windows decoration. It does not oversize the window. Have you tries the equivalent script mentioned in the thread stored in the library? If, that does work, could could try my first script. That one oversize the window, you could then increase the size. Note That I don't have the problem you talk about in the thread. My windowed window is fullscreen. Hi Vince, do you have the original script or could you point me to where I can download the original script and what settings I would need to oversize the window slightly, can anyone help with this script so I can oversize it by a couple of PX each edge.I run 1920 x 1200

Share this post


Link to post
Share on other sites

Hi,I was jumping on my chair when i have discovered this topic: finally a solution for what I was looking for since years!!!!! :( but... when I tried to execute the script I got the crash like the one I always have when I try to swap from windowed mode to full screen mode or viceversa (clicking TAB+ENTER).:( :( Can someone give me some direction hot to solve this damend issue allowing me to use this great script?Thanks a lot in advance for your supportBy the way I use FSX SP2 - I7/2600K - Nvidia 470 last driver - Win 7/64 PROChhers and have good flightsJoe

Share this post


Link to post
Share on other sites
Hi,I am the author of the authotkey script mentioned above, and I can assure you that the FSX window (or any window for that matter) will go to full screen without any borders whatsoever by pressing win+F11. You have to make sure however that you have your taskbar set to auto-hide. I am using 1920 x 1200 myself as well, but the script is resolution independent.Maarten
Mawibu, I downloaded the full-screen script, but where do I put this file (what do I do with it?)

Share this post


Link to post
Share on other sites
Mawibu, I downloaded the full-screen script, but where do I put this file (what do I do with it?)
Hi Hirgab and others do the following for FSX fullscreen windowed modeCopy the script above and place it into Autoit V3, its a freeware program you can download, then compile the script (right click context menu the file once saved) Then you can also Download taskbar eliminator.This means you have three programs to start:fsx.exetaskbar eliminator.exethe fullscreen script.exeGet a batch file to start all programs at once, this will be the only file you will need to click to make it all happen, fsx will start, taskbar eliminator will hide the taskbar (ALT+T brings it back) and the fullscreen.exeFSX will load the main program, hit fly and FSX will be fullscreen windowed.I wanted this originally to fix the miuse loosing focus in 2D panel when I switched to externals views then came back, the fullscreen windowed mode keeps the sim in focus always.Cheers

Share this post


Link to post
Share on other sites

Thanks for the response. I figured out how to use Autohotkey. The reason why I am using Window mode is to avoid blackscreens that I get when alt-tabbing or changing weather/time on the menus. However, I find that when I press the window key + F11 to get full-screen, the window refresh that occurs can cause a black screen. Is there any other way where I can maximize my screen space from the beginning without having to refresh my page in any way?

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Tom Allensworth,
    Founder of AVSIM Online


  • Flight Simulation's Premier Resource!

    AVSIM is a free service to the flight simulation community. AVSIM is staffed completely by volunteers and all funds donated to AVSIM go directly back to supporting the community. Your donation here helps to pay our bandwidth costs, emergency funding, and other general costs that crop up from time to time. Thank you for your support!

    Click here for more information and to see all donations year to date.
×
×
  • Create New...