AutoHotkey Community

It is currently May 25th, 2012, 8:27 am

All times are UTC [ DST ]




Post new topic Reply to topic  [ 264 posts ]  Go to page Previous  1, 2, 3, 4, 5 ... 18  Next

What should happen to this project?
Let's work on it, I'll help
Keep it alive
Let it go
I don't care
You may select 1 option

View results
Author Message
 Post subject:
PostPosted: June 14th, 2007, 8:11 pm 
Offline

Joined: June 13th, 2007, 5:32 pm
Posts: 5
and I must say I find this much easier to make stuff thand with the GUI Creator or what ever it's name is.


((BTW Reinstalling worked :D))


Report this post
Top
 Profile  
Reply with quote  
 Post subject: Congratulations !
PostPosted: June 14th, 2007, 8:42 pm 
I'd like to congratulate you all for this state-of-art ahk software ! This is a realy amazing tool =) I don't know why didn't anyone make this before.

Congratulations guys !

Kind Regards !
Johann


Report this post
Top
  
Reply with quote  
 Post subject: Saving?
PostPosted: June 14th, 2007, 8:59 pm 
Offline

Joined: June 13th, 2007, 5:32 pm
Posts: 5
How do you save your Gui?



and also I want to do soemthing im not sure how to do


I got it set up and everything but....I need to generate a character description but I don't know hwo to make it do that?


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: June 14th, 2007, 10:51 pm 
Offline

Joined: January 31st, 2005, 9:50 am
Posts: 3910
Location: Bremen, Germany
New version 0.6.4 is out
Quote:
Rev 45
- added control prop "Disabled"
- added handling for "Disabled" for context menu, export&import and final script
Rev 46
- fixed control creation bug, which was introduced with Rev 45
- fixed bug in change content for CheckboxesR,Radio,DateTime
- added control prop "Checked" for Checkbox and Radio
- added handling for "Checked" for context menu, export&import and final script
Rev 47
- changed SaveLoad_FinalScript() to SaveLoad_CreateFinalScript() to prepare a full output of the script
- changed LB_functions to prepare a full output of the script
- changed default for final GUI to not resize
- added menu item for "Allow Resize" for gui context menu
- added inc\ExportGui.ahk as a copy from guis\
Rev 48
- included inc\ExportGui.ahk into LilBuilder and got it working
- added gui prop "AlwaysOnTop" and "Hidden"
- added control prop "Hidden"
- added handling for "AlwaysOnTop" and "Hidden" for context menu, export&import and final script


!!! Finally: LilBuilder uses its own format.
The Export Gui is created with LilBuilder itself and can still be maintained with it. :)

@Alena: To export a gui, use context menu of toolbox.

_________________
Ciao
toralf
Image


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: June 14th, 2007, 11:11 pm 
Offline

Joined: March 28th, 2004, 3:53 pm
Posts: 1865
toralf,
i just saw the newest changes... well great to see the stealer already fixed (it was broken only for controls with no labels or 0 label...or that's all i noticed).

but i'm not really happy with some changes:

- separate file extensions of builder
the universal ones have some benefits like they don't need new file associations created, and don't need separate syntax highlightings added to editors. yes we dn't want newcomers to mess with them, but i'd also want myself and others to be able to, if they know what they're doing.

- the generated script's functions in a separate file
i've never been a fan of fileIncludes, but its needed after functions got added. but i'd still hate to see a simple new gui script to consist of 3 separate files. can we not keep the generated script to 2 files (script and project) and any extra if custom controls are added. custom controls will be includes.

_________________
Image


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: June 15th, 2007, 4:34 am 
Offline

Joined: July 29th, 2005, 5:32 pm
Posts: 179
It keeps looking better and better :)
Quote:
the generated script's functions in a separate file
I was a little confused by this myself. I believe that the project files are to be strictly used by Lil Builder- & most likely a 'Save As AHK' option will be added to export all gui building & subs from combined project files (I can't see Fileinstall, MyGui.lbp.. creeping up into any compiled script projects..)

I always imagined an AHK gui project file (if there would ever be such a thing..) as a combination AHK/ini.. & if not formatted correctly.. just would give a warning from IDE. Much much easier said than done though..
Code:
;/*  <--------- ..for stand alone testing purposes..
ResourcesPath = ..\RESOURCES 
GuiName(ResourcesPath)
Return

#Include %A_ScriptDir%\INCLUDES   ;-copied to local project path on export
#Include REQUIRED FUNCS.....
*/


;#### DO NOT MANUALLY EDIT FROM THIS LINE DOWN ####

;  (¯·._ (¯·._ Function: GuiName _.·´¯) _.·´¯)
GuiName(ResourcesPath)
/*
[Project]
RequiredAhkVer=1.0.46.17
RequiredLilBuilderVer=0.6.4
ListOfGuiID=1
[Gui 1]
PosSize=x208 y146 w168 h170
AlwaysOnTop=0
Content=Gui 1
Hidden=0
Resize=0
Toolwindow=0
OrderOfControls=1|2
[Control 1]
Content=Button1
ToolTip=Gui1BtnOneVar (Button1) hover tip..
Disabled=0
Hidden=0
Label=BtnOneSub
Type=Button
VarName=BtnOneVar
PosSize=x14 y12 w88 h23
[Control 2]
Content=Button2
ToolTip=Gui1BtnTwoVar (Button2) hover tip..
Disabled=0
Hidden=0
Label=BtnTwoSub
Type=Button
VarName=BtnTwoVar
PosSize=x14 y36 w88 h23
*/
{
  Gui 1:+LastFoundExist
  IfWinExist
    return  ;..gui1 already exists..

  ;assume local..
  Static Gui1BtnOneVar, Gui1BtnTwoVar
 
  Gui, 1:Default
  Gui, 1:+LabelGui1
  Gui, 1:+LastFound
  Gui1HWND := WinExist() ; Handle
  GuiName = Gui1

  Gui, Add, Button, x16 y17 w70 h30 vGui1BtnOneVar gGui1BtnOneSub, Button1
  Gui1BtnOneVar_Tooltip = Gui1BtnOneVar (Button1) hover tip..

  Gui, Add, Button, x16 y47 w70 h30 vGui1BtnTwoVar gGui1BtnTwoSub, Button2
  Gui1BtnTwoVar_Tooltip = Gui1BtnTwoVar (Button2) hover tip..

  Gui, Show, x131 y120 w119 h153, %GuiName%

  OnMessage(0x200, "GuiHoverControl") ; Start tooltip routine..

  Hotkey, IfWinActive, ahk_id %Gui1HWND% ; Define hotkeys for this window...
  ; Hotkey, ^!c, Gui1Hotkeys  ;<--hotkeys go here..
  Hotkey, IfWinActive
Return
;-----------------
Gui1Size:
  GuiAnchor("Gui1BtnOneVar", "xy", "draw")
  GuiAnchor("Gui1BtnTwoVar", "xy", "draw")
return
;-----------------
Gui1Escape:
Gui1Close:
  Gui, 1:Destroy
  OnMessage(0x200, "")  ; Stop tooltip routine..
return
;-----------------
Gui1ContextMenu:
MsgBox,, Context Menu Routine,
( Ltrim
  A_GuiControl = %A_GuiControl%
  A_EventInfo = %A_EventInfo%
  A_GuiX = %A_GuiX% and A_GuiY = %A_GuiY%
  A_GuiControlEvent = %A_GuiControlEvent%
)
return
;-----------------
Gui1DropFiles:
MsgBox,, Drop Files Routine,
( Ltrim
  A_GuiControl = %A_GuiControl%
  A_EventInfo = %A_EventInfo% (# of files dropped..)
  A_GuiX = %A_GuiX% and A_GuiY = %A_GuiY%

  --FILES DROPPED ON CONTROL--
  %A_GuiControlEvent%
)
return
;------
Gui1BtnOneSub:
  MsgBox, A_Gui = %A_Gui% `nA_GuiControl = %A_GuiControl%
return
;------
Gui1BtnTwoSub:
  MsgBox, A_Gui = %A_Gui% `nA_GuiControl = %A_GuiControl%
return
;------
Gui1Hotkeys:
  MsgBox, , Gui1HWND Hotkeys.., A_ThisHotkey = %A_ThisHotkey%
return
}   ;--------- End of Function: GUI1 ------------


majkinetor--- The properties window is absolutely stunning! I think that once pic's are fully implemented-- it (SS control..) should be used for toolbox window too... but thats low low end of the project type priority.
Do you plan to modify existing Control function so it will update property window as things get modified in Dic.. or is that what Control_Property_Editor() you mentioned is for? I only ask since I am interested in enhancing some of the context menus for controls-- I hate to have go back & add 'update property window' section for each menu item.

_________________
.o0[ corey ]0o.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: June 15th, 2007, 8:05 am 
Offline

Joined: January 31st, 2005, 9:50 am
Posts: 3910
Location: Bremen, Germany
Rajat wrote:
- separate file extensions of builder
I see you point. At the end we could specify them in the INI file for LilBuilder. We just have to decide on the default once, then everyone can choose his preferences.

Rajat wrote:
- the generated script's functions in a separate file
Another option in the export gui to create only 2 files would make use both happy, wouldn't it?

_________________
Ciao
toralf
Image


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: June 15th, 2007, 8:05 am 
Offline

Joined: May 24th, 2006, 2:49 pm
Posts: 4511
Location: Belgrade
Quote:
Do you plan to modify existing Control function so it will update property window as things get modified in Dic.

Thats how it works now. As soon as you select something all properties are grabed from the dict and shown.

_________________
Image


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: June 15th, 2007, 8:14 am 
Offline

Joined: January 31st, 2005, 9:50 am
Posts: 3910
Location: Bremen, Germany
freakkk wrote:
I hate to have go back & add 'update property window' section for each menu item.
This could be added to the end of the <Control>_ShowMenu: in each menu file. Which isn't much to do. I also think that the
Code:
  Else If IsLabel(MMenu_ID)
    GoSub, %MMenu_ID%
could be replaced with a function that calls common functions. E.g.
Code:
  Else
    CommonMenu_OnSelection(MMenu_Title, MMenu_ID, Menu_vGuiHWND(), Menu_vCtrlHWND())
This would remove the subroutines.

_________________
Ciao
toralf
Image


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: June 15th, 2007, 8:21 am 
Offline

Joined: January 31st, 2005, 9:50 am
Posts: 3910
Location: Bremen, Germany
freakkk wrote:
a 'Save As AHK' option will be added to export all gui building & subs from combined project files (I can't see Fileinstall, MyGui.lbp.. creeping up into any compiled script projects..)
If you want to create a single file, you'll can't use INI for storage, since it will not work when compiled. We then have to think of a different approach. I'm open. The current way, is just a way that works, and maybe not the optimum.

Instead of a INI or XML file, e.g. LilBuilder could store the data in a single var that gets parsed at runtime.
Code:
LB_GuiData_1 =
(
[...]
)
Or maybe some other fancy storage, that is easy to parse, create and edited.

_________________
Ciao
toralf
Image


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: June 15th, 2007, 8:46 am 
Offline

Joined: May 24th, 2006, 2:49 pm
Posts: 4511
Location: Belgrade
Quote:
Instead of a INI or XML file, e.g. LilBuilder could store the data in a single var that gets parsed at runtime.

Sounds resoanable. Content of the file is read into the buffer anyway.

_________________
Image


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: June 15th, 2007, 12:17 pm 
Offline

Joined: May 24th, 2006, 2:49 pm
Posts: 4511
Location: Belgrade
This is needed for GRID not to draw over controls. It will also work for Tabs, but can be easily skiped if hwnd is determined to represent Tab control.

Code:
Grid_Draw() {

....

  ;remove grid over controls
  controls := Gui( GuiHWND, "OrderOfControls" )
  loop, parse, controls, |
   DllCall("InvalidateRect", "uint", A_LoopField, "uint", 0, "uint", 0)
}


BTW, I am working on other GRID updates, lets hope it will be productive. The problem in current one is that it always updates entire windows, no matter if only small rect should be updated.

I am also trying to make Properties not be activated when it is shown, just when explicitely activated (I don't want it to steal focus from User gui)

_________________
Image


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: June 15th, 2007, 12:44 pm 
Offline

Joined: May 24th, 2006, 2:49 pm
Posts: 4511
Location: Belgrade
2 ahkuser
We must start to organise object properties. Public properties.

The list would be good for start. We can have common properties (like x, y, w, h) and object private properties.

Common properties:
Code:
X : Integer
Y : Integer
W : Integer
H  : Integer
Style : Button 
Color:  TColors (global Properties type, ComboBox)
Visible: TBool (true/false ComboBox)
Font   : Button

Lets try first with Text:
Code:
[Text]
Common

Label : Edit
Multiline :TBool
Aligment : TAligment
Anchor   : Button
Border : TBool


Lets check out GUI. It will be something like
Code:
[Gui]
Common

Style : TGuiStyle (Combo : ToolWindow, NoCaption... )
Transparent: Integer
TransColor: TColors
Position: TGuiPosition (Combo: Design, Center... )
State: TGuiState (minimised, maximized, hidden)
Title: Edit
Controls: Button (TVX Editor to rearange controls )


Then we can update the code to reflect changes: moving control should change its position and size properties, Menus should be redirected to propertie setters, etc..

Notes:
- Private properties should be marked somehow, for instance _ in front of name. We use this for oposite role now. We can have some debug flag. When its on, we can display private properties in PGUI. Otherwise, we display just public properties. I realised that PGui is good for debuging too as we currently have no mean to see what is going on with global variables as they are in dicts. PGUI provides simple and effective way to analyse all that.

- Some properties can be specified on creation (Gui, Add) while some can't (Font for instance, Anchor..). My idea is to have aditional function automaticaly generated , lets say, InitGui(). This function should set all properties that are not set on creation (in advance, native and nonnative properties). This should generaly work with the same property setters as in design mode. So, if I set in design mode Style to some value, it will reflect imediately in the GUI as appropriate function will be called: xxx_Style(ctrlID, value). This function can be used in runtime mode in InitGui() function. Note must be taken care that some properties we don't want to present in design mode (for instance Visibile). So property will need to have another attribute (InDesign= true/false)

- Suggestions and different approaches are appricated ofc.

_________________
Image


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: June 15th, 2007, 1:25 pm 
Offline

Joined: June 26th, 2006, 6:14 pm
Posts: 1379
Location: USA
majkinetor wrote:
bug with GRID
Please elaborate.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: June 15th, 2007, 1:51 pm 
Offline

Joined: May 24th, 2006, 2:49 pm
Posts: 4511
Location: Belgrade
It draws over controls, so controls become garbadged soon.

_________________
Image


Report this post
Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 264 posts ]  Go to page Previous  1, 2, 3, 4, 5 ... 18  Next

All times are UTC [ DST ]


Who is online

Users browsing this forum: No registered users and 24 guests


You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Powered by phpBB® Forum Software © phpBB Group