Stalker0 Posted October 10, 2007 Posted October 10, 2007 (edited) I'm creating a GUI window that I want to appear in the bottom right corner of the screen. Thing is, the window will appear on multiple computers, each with a different sized screen. Is there are way to softcode the window to always appear in the bottom right corner relative to the size of the window? Edited October 10, 2007 by Stalker0
Paulie Posted October 10, 2007 Posted October 10, 2007 @DesktopWidth @DesktopHeight Give you resolution.
Stalker0 Posted October 10, 2007 Author Posted October 10, 2007 @DesktopWidth@DesktopHeightGive you resolution.Thank you for the quick response. What do you mean by "give you resolution". Does the resolution matter if I use those macros?
Moderators SmOke_N Posted October 10, 2007 Moderators Posted October 10, 2007 Thank you for the quick response. What do you mean by "give you resolution". Does the resolution matter if I use those macros?He's talking about your screen/monitor Width and Height, not your color quality. Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.
cppman Posted October 10, 2007 Posted October 10, 2007 Global Const $TOPLEFT = 0 Global Const $TOPRIGHT = 1 Global Const $BOTTOMLEFT = 2 Global Const $BOTTOMRIGHT = 3 Func _CornerWindow($hWnd, $Corner) Local $WindowInfo Local $x, $y Local $tx = @DesktopWidth Local $ty = @DesktopHeight $WindowInfo = WinGetPos($hWnd) if ($Corner == 0) Then $x = 0 $y = 0 Elseif ($Corner == 1) Then $x = $tx - $WindowInfo[2] $y = 0 Elseif ($Corner == 2) Then $x = 0 $y = $ty - $WindowInfo[3] Elseif ($Corner == 3) Then $x = $tx - $WindowInfo[2] $y = $ty - $WindowInfo[3] Else return 0 EndIf WinMove($hWnd, "", $x, $y) EndFuncoÝ÷ Ù©Ýjw±jjez;¬µª®É(æ®¶sbb33c·FW7BÒuT7&VFRgV÷CµFW7BgV÷C²¤uT6WE7FFR¤÷D¶W6WBgV÷C·´c'ÒgV÷C²ÂgV÷CµõF÷ÆVgBgV÷C²¤÷D¶W6WBgV÷C·´c7ÒgV÷C²ÂgV÷CµõF÷&vBgV÷C²¤÷D¶W6WBgV÷C·´cGÒgV÷C²ÂgV÷Cµô&÷GFöÔÆVgBgV÷C²¤÷D¶W6WBgV÷C·´cWÒgV÷C²ÂgV÷Cµô&÷GFöÕ&vBgV÷C² §vÆR¥tVæ@ ¤gVæ2õF÷ÆVgB¢ô6÷&æW%væF÷rb33c·FW7BÂb33cµDõÄTeB¤VæDgVæ0 ¤gVæ2õF÷&vB¢ô6÷&æW%væF÷rb33c·FW7BÂb33cµDõ$tB¤VæDgVæ0 ¤gVæ2ô&÷GFöÔÆVgB¢ô6÷&æW%væF÷rb33c·FW7BÂb33c´$õEDôÔÄTeB¤VæDgVæ0 ¤gVæ2ô&÷GFöÕ&vB¢ô6÷&æW%væF÷rb33c·FW7BÂb33c´$õEDôÕ$tB¤VæDgVæ This what you are trying to do? Miva OS Project
Stalker0 Posted October 12, 2007 Author Posted October 12, 2007 Thank you all for the help, I've got it working now!
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now