Jump to content

Autoit3-gui 102.17 Available


jpm
 Share

Recommended Posts

14st April, 2004 - v3.0.102.17 (unstable)

  • Added : GuiSetControl("ico",... can reference .dll,.icl (from Holger)
  • Fixed : Illegal controlref return 0 and set @error to 1..
  • Fixed : GuiRead() after close notification for "input" control return the right controlref.
  • Fixed : Font change without asking for it. Thanks Steve8tch.
  • Added : GuiSetControl("tab",...
  • Added : GuiSendMsg, GuiRecvMsg for super advanced user.
download from http://www.hiddensoft.com/fileman/users/jpm/AutoIt3-gui/

Happy beta testing :D

Link to comment
Share on other sites

Forgot to mention this earlier:

If a GUI is resizable and contains combo boxes, then the combo box text is selected when you resize the window. Focus does not change--so the highlighting is only a slight annoyance.

; Resizable window style borrowed from Windows Notepad
GUICreate("title", 400, 400, 10, 10, 0x04CF0000)

$combo = GUISetControl ( "combo", "", 0, 0)
GUISetControlData( $combo, "one|two|three", "one")

$edit = GUISetControl ( "edit", "Resize the Window", 30, 30)
GUISetControlEx ($edit, 256);control has focus

GUIWaitClose()
Edited by CyberSlug
Use Mozilla | Take a look at My Disorganized AutoIt stuff | Very very old: AutoBuilder 11 Jan 2005 prototype I need to update my sig!
Link to comment
Share on other sites

not so important like the gdi-resource-problem, only a documentation bug that I saw:

Under "Gui Control Styles" and "Avi Clip styles" the style "ACS_TRANSPARENT" is false!

Right is: ACS_TIMER, 0x08, "By default, the control creates a thread to play the AVI clip. If you set this flag, the control plays the clip without creating a thread; internally the control uses a Win32 timer to synchronize playback."

The style "ACS_TRANSPARENT" is set by default and can be overwritten with "ACS_NONTRANSPARENT" (0x10).

Regards Holger

Link to comment
Share on other sites

not so important like the gdi-resource-problem, only a documentation bug that I saw:

Under "Gui Control Styles" and "Avi Clip styles" the style "ACS_TRANSPARENT" is false!

Right is: ACS_TIMER, 0x08, "By default, the control creates a thread to play the AVI clip. If you set this flag, the control plays the clip without creating a thread; internally the control uses a Win32 timer to synchronize playback."

The style "ACS_TRANSPARENT" is set by default and can be overwritten with "ACS_NONTRANSPARENT" (0x10).

Regards Holger

Thanks I did the correction. but It look to me that the ACS_TIMER option was "too hazardeous" that the reason I omit it.

Do you think situation where it will be needed?

Link to comment
Share on other sites

@jpm: with this ACS_TIMER-style I don't know.

I found nowhere a reason what is the advantage of it...

Maybe you let this style complete out of the documentation and add something like the ACS_TRANSPARENT is set be default.

Regards Holger

Link to comment
Share on other sites

Is there a limit on the length of text in a list box.

If I put more than 256 chractors in a list box - the box displays them OK - but the script crashes if I try and use the data.

I have included a small script here to highlight the problem - hopefully it will be a simple fix!!

Global $message1 = "012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345

6789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345

6789012345678901234567890123456789012345678901234567890123456"
Global $message2 = "012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345

6789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345

67890123456789012345678901234567890123456789012345678901234567"
Global $WS_HSCROLL = 1048576
Global $WS_VSCROLL = 2097152
GUICreate("My GUI")

$button1=GUISetControl("button", "Button1", 64,32,75,25)
GUISetControlNotify()
$button2=GUISetControl("button", "Button2", 64,72,75,25)
GUISetControlNotify()
$mylist=GUISetControl("list", "1 less charactor", 176,32,121,97)
GUISetControlEx(-1,-1,-1,"First line in list box has 256 charactors",50)
GUISetControlData(-1,$message1)
GUISetControlNotify()
$mylist2=GUISetControl("list", "text style one", 176,160,121,140,$WS_HSCROLL + $WS_VSCROLL)
GUISetControlEx(-1,-1,-1,"First line in list box has 257 charactors - press button 2 - see what happens",2000)
GUISetControlData(-1,$message2)
GUISetControlNotify()
$close=GUISetControl("button", "Close", 64,160,75,50)
GUISetControlNotify()

While GUIMsg() > 0 
   If GUIRead() = $button1 Then
      $message1 = $message1 & "|" & "1 less charactor"
      GuiSetControlData($mylist,"")
      GuiSetControlData($mylist,$message1)
   EndIf
   If GUIRead() = $button2 Then 
      $message2 = $message2 & "|" & "1 more charactor"
      GuiSetControlData($mylist2,"")
      GuiSetControlData($mylist2,$message2)
   EndIf
   If GUIRead() = $close Then
      MsgBox(0,"data", "You must have clicked on button one first" & @CRLF & "Button 2 would have crashed the script")
      Exit
   EndIf
Wend

;==>extract_data_from_GUIRead

Thanks.

This doesn't just happen in autoit-gui.102.17. - it also occurred in ..16

Link to comment
Share on other sites

So much elements to test in Auto3-gui version... :huh2:

I' don't understand all the options...I am just take a look at basic functions for the moment waiting more examples, GUI will be a good thing for autoit3 :D

It could be very usefull in a GUI context to permit:

- Support of transparency in GIF , and aniGIF (more used that .ani and .avi)

- Very basic graphic function: line, circle, square, fill

- The type "menu"

- The type "toolbar"

Thanks

Wolf

Link to comment
Share on other sites

Is there a limit on the length of text in a list box.

If I put more than 256 chractors in a list box - the box displays them OK - but the script crashes if I try and use the data.

I have included a small script here to highlight the problem - hopefully it will be a simple fix!!

Global $message1 = "012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345

6789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345

6789012345678901234567890123456789012345678901234567890123456"
Global $message2 = "012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345

6789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345

67890123456789012345678901234567890123456789012345678901234567"
Global $WS_HSCROLL = 1048576
Global $WS_VSCROLL = 2097152
GUICreate("My GUI")

$button1=GUISetControl("button", "Button1", 64,32,75,25)
GUISetControlNotify()
$button2=GUISetControl("button", "Button2", 64,72,75,25)
GUISetControlNotify()
$mylist=GUISetControl("list", "1 less charactor", 176,32,121,97)
GUISetControlEx(-1,-1,-1,"First line in list box has 256 charactors",50)
GUISetControlData(-1,$message1)
GUISetControlNotify()
$mylist2=GUISetControl("list", "text style one", 176,160,121,140,$WS_HSCROLL + $WS_VSCROLL)
GUISetControlEx(-1,-1,-1,"First line in list box has 257 charactors - press button 2 - see what happens",2000)
GUISetControlData(-1,$message2)
GUISetControlNotify()
$close=GUISetControl("button", "Close", 64,160,75,50)
GUISetControlNotify()

While GUIMsg() > 0 
   If GUIRead() = $button1 Then
      $message1 = $message1 & "|" & "1 less charactor"
      GuiSetControlData($mylist,"")
      GuiSetControlData($mylist,$message1)
   EndIf
   If GUIRead() = $button2 Then 
      $message2 = $message2 & "|" & "1 more charactor"
      GuiSetControlData($mylist2,"")
      GuiSetControlData($mylist2,$message2)
   EndIf
   If GUIRead() = $close Then
      MsgBox(0,"data", "You must have clicked on button one first" & @CRLF & "Button 2 would have crashed the script")
      Exit
   EndIf
Wend

;==>extract_data_from_GUIRead

Thanks.

This doesn't just happen in autoit-gui.102.17. - it also occurred in ..16

Thanks for finding the bug. :D

I never figure out that an item can be more than 255 characters.

I forget to check the size. It will return 0 if it failed.

Is the size acceptable?

Link to comment
Share on other sites

Final beta ???

Heh, you right, maybe it's really time to start squishing remain bugs :D

Today I found two issues (bugs?):

1. Why controls (labels, checkboxes, radios), placed onto tab page have white background by default?

2. I have a problem with WS_EX_ACCEPTFILES. In example shown below, when I drag file onto control, I see that cursor changed to arrow with "+" - that's ok. But after I've drop file - nothing appear.

Filename not show in the control, and GUIRead give me emptyness.

How I can get filename from control? Or maybe this bug?

Don't have 101.8 version, where this feature first appear, but it won't work in any other releases.

Opt("GUINotifyMode", 1)

GUICreate("GUI", 320,120, @DesktopWidth/2-160, @DesktopHeight/2-45, -1, 0x00000008)
$file = GUISetControl ("input",  "", 10,  5, 300, 20, -1, 0x00000010); WS_EX_ACCEPTFILES
$btn = GUISetControl ("button",  "Button", 40,  55, 60, 20)
GUISetControl ("input",  "", 10,  35, 300, 20); WS_EX_ACCEPTFILES
GUISetControl ("input",  "", 10,  55, 300, 20); WS_EX_ACCEPTFILES
   
While GUIMsg() > 0
        $res = GUIRead()
         Select
            Case $res = $btn
                MsgBox (4096, "title", GUIRead($file), 2)
        EndSelect
Wend
Link to comment
Share on other sites

Thanks for finding the bug.  
I never figure out that an item can be more than 255 characters.
I forget to check the size. It will return 0 if it failed.
Is the size acceptable?

As large as poss !!

One of the uses I would like to put this GUI to is helping our team reliably construct command line copy statements - using robocopy or xxcopy. By the time you have added a "from" and a "to" and a few excluded directories - I will have used up the 255 charactors.

The odd thing is - the list box displays more than 255 charactors in a line OK - its just - I can't use the data.

How about 1024 or 2048

If it can't be done - I will find a work around using variables - but if it can be done - even better!!

Thanks again for your support

Link to comment
Share on other sites

About GUI v102.17

I'm happy with the new improvements (principally the TAB). :)

Only, I want know,

I not sure, if they're are a bugs or limitations:

- The checkboxs display a white background, if exist a TAB in the window.(in this case the window have a background color) ¿:D?

- I could in v102.13 refresh a color LABEL,

e.g.:

If $_btnColor = GUIRead() then GUISetControlEx ( $myLabel, -1, "", "", 0xffFFff, 0x552211)

But, I can't do it in v102.17. :huh2:

thxs :lol:

Edited by josbe
Link to comment
Share on other sites

Thanks for finding the bug.  
I never figure out that an item can be more than 255 characters.
I forget to check the size. It will return 0 if it failed.
Is the size acceptable?

As large as poss !!

One of the uses I would like to put this GUI to is helping our team reliably construct command line copy statements - using robocopy or xxcopy. By the time you have added a "from" and a "to" and a few excluded directories - I will have used up the 255 charactors.

The odd thing is - the list box displays more than 255 charactors in a line OK - its just - I  can't use the data.

How about 1024 or 2048

If it can't be done - I will find a work around using variables - but if it can be done - even better!!

Thanks again for your support

I am not sure why you use combo/listbox for this purpose but it is not a big deal to put the AUT_MAX_LINESIZE which is 4096
Link to comment
Share on other sites

About GUI v102.17

I'm happy with the new improvements (principally the TAB). :)

Only, I want know,

I not sure, if they're are a bugs or limitations:

- The checkboxs display a white background, if exist a TAB in the window.(in this case the window have a background color) ¿:D?

- I could in v102.13 refresh a color LABEL,

e.g.: 

If $_btnColor = GUIRead() then GUISetControlEx ( $myLabel, -1, "", "", 0xffFFff, 0x552211)

But, I can't do it in v102.17. :huh2:

thxs :lol:

The white background come from a problem I cannot solve for the time being of the default color of a tab . Almost white in XP but gray under Win9x perhaps Win2K.

For the refresh color of a label I need to have a look to what happen.

Stay tune

Link to comment
Share on other sites

I am not sure why you use combo/listbox for this purpose but it is not a big deal to put the AUT_MAX_LINESIZE which is 4096

Is this something we/I can do - or is this something that you have to do ?

- I was trying to be clever and display the code that the users were going to use in a list box with horizontal scroll (just in case the code was long!!)

btw - even my boss is getting quite interested in au3-gui - we are finding more and more uses for it. Thanks for all your efforts. :D

Link to comment
Share on other sites

I am not sure why you use combo/listbox for this purpose but it is not a big deal to put the AUT_MAX_LINESIZE which is 4096

Is this something we/I can do - or is this something that you have to do ?

- I was trying to be clever and display the code that the users were going to use in a list box with horizontal scroll (just in case the code was long!!)

btw - even my boss is getting quite interested in au3-gui - we are finding more and more uses for it. Thanks for all your efforts. :huh2:

I set as I say the max size big for next delivery.

But I cannot understand why you use a combo/listbox.

I think an edit control will be more appropriate to show the code.

You can manage to add lines very easily. What you cannot do easily is delete a line. You can have a look at GuiSendMsg or GuiRecvMsg if you can access at Window edit control message definition. I am sure you can manage deletion.

I hope your boss will improve your salary :D

Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...