Sign in to follow this  
Followers 0
sshrum

Window exploding!

8 posts in this topic

#1 ·  Posted (edited)

Using the current beta, although i've seen it before a few times, when I go to move or restore a GUI window, the size of the window explodes. I have no idea how big as it seems to go on and on and on as I move it.

I'm fairly new to the GUI part of AutoIT so I may have envoked the wrong arguments or something.

Bear in mind that this happens every now and then...most of the time it is well behaved.

Here's my current code:

If $iProgress = "1" Then
        $hDialog = GUICreate($sAppTitle, 440, 95, (@DesktopWidth - 421) / 2, (@DesktopHeight - 106) / 2, $WS_MINIMIZEBOX + $WS_VISIBLE + $WS_OVERLAPPED + $WS_SYSMENU + $WS_CAPTION); + $WS_CLIPSIBLINGS)
        $cTopLabel = GUICtrlCreateLabel("Top", 10, 9, 420, 20, $SS_CENTER)
        $cProgress = GUICtrlCreateProgress(10, 30, 420, 30, $PBS_SMOOTH)
        $cMiddleLabel = GUICtrlCreateLabel("Middle", 10, 38, 420, 20, $SS_CENTER)
        GUICtrlSetFont(-1, 9, 800)
        $cBottomLabel = GUICtrlCreateLabel("Bottom", 10, 69, 420, 20, $SS_CENTER)
    EndIf

TIA

Edited by sshrum

Sean Shrum :: http://www.shrum.net

All my published AU3-based apps and utilities

'Make it idiot-proof, and someone will make a better idiot'

 

Share this post


Link to post
Share on other sites



Attached are the before and after (sorta) shots of the dialog that I am seeing.

Note that once the explosion happens, the text controls don't clear when the text is changed.


Sean Shrum :: http://www.shrum.net

All my published AU3-based apps and utilities

'Make it idiot-proof, and someone will make a better idiot'

 

Share this post


Link to post
Share on other sites

Like I said with the part of the script you supplied, I didn't have a problem

Would be good Idea to supply the entire script to find the problem.

Gary


SciTE for AutoItDirections for Submitting Standard UDFs

 

Don't argue with an idiot; people watching may not be able to tell the difference.

 

Share this post


Link to post
Share on other sites

I can see one potential problem. You added your styles together. They should be BitOr'd together.

Change this line:

$hDialog = GUICreate($sAppTitle, 440, 95, (@DesktopWidth - 421) / 2, (@DesktopHeight - 106) / 2, $WS_MINIMIZEBOX + $WS_VISIBLE + $WS_OVERLAPPED + $WS_SYSMENU + $WS_CAPTION); + $WS_CLIPSIBLINGS)

To this:

$hDialog = GUICreate($sAppTitle, 440, 95, (@DesktopWidth - 421) / 2, (@DesktopHeight - 106) / 2, BitOr($WS_MINIMIZEBOX, $WS_VISIBLE, $WS_OVERLAPPED, $WS_SYSMENU, $WS_CAPTION))

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  
Followers 0