Jump to content

best strategy for window child control layout


ershiba
 Share

Recommended Posts

hi autoit members,

just joined today and start having question, :sweating:

i want to pack child controls into one group so that i could perform necessary resize when WM_SIZE coming,

i google this board and found the method to do so is using _WinAPI_SetParent

conversion from control id to handle is a little bit uneasy, i dont understand why we need to provide more information if let say we already got control id during control creation?

eg.

ControlGetHandle("Hello World","","[CLASS:Static; INSTANCE:1]")

i suggest

$groupid = GUICtrlCreateGroup("", 0,0,100,100)

$grouph = ControlIdGetHandle($groupid) ; get control handle

and is there anything like table layout? or panel layout,

thank you.

Link to comment
Share on other sites

  • Moderators

ershiba,

Welcome to the AutoIt forum. :)

Take a look at GUICtrlSetResizing in the Help file - it allows you to set how the controls will resize inside the GUI as it is resized. It may well be what you are looking for without having to get into API child/parent relationships. ;)

It might also help if you post the code you have so far - put [autoit] before and [/autoit] after it so you get a scrolling box and syntax colouring. ;)

M23

Public_Domain.png.2d871819fcb9957cf44f4514551a2935.png Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind

Open spoiler to see my UDFs:

Spoiler

ArrayMultiColSort ---- Sort arrays on multiple columns
ChooseFileFolder ---- Single and multiple selections from specified path treeview listing
Date_Time_Convert -- Easily convert date/time formats, including the language used
ExtMsgBox --------- A highly customisable replacement for MsgBox
GUIExtender -------- Extend and retract multiple sections within a GUI
GUIFrame ---------- Subdivide GUIs into many adjustable frames
GUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView items
GUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeView
Marquee ----------- Scrolling tickertape GUIs
NoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxes
Notify ------------- Small notifications on the edge of the display
Scrollbars ----------Automatically sized scrollbars with a single command
StringSize ---------- Automatically size controls to fit text
Toast -------------- Small GUIs which pop out of the notification area

 

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...