08-09-2008, 03:05 AM
A quick example to show how the new lines are about 2/3 the size as the Dialog Editor's controls, even though they are using the same x y cx cy values.
Function CC_Dialog
Function CC_Add
Function CC_Dialog
\Dialog_Editor
function# hDlg message wParam lParam
if(hDlg) goto messages
;BEGIN DIALOG
;0 "" 0x90C80A44 0x100 0 0 439 135 "Dialog"
;1 Button 0x54030001 0x4 374 0 48 14 "OK"
;2 Button 0x54030000 0x4 374 16 48 14 "Cancel"
;3 ComboBox 0x54230243 0x0 2 2 96 213 ""
;4 ComboBox 0x54230243 0x0 100 2 96 213 ""
;5 Edit 0x54030080 0x200 198 2 20 12 ""
;6 Edit 0x54030080 0x200 220 2 46 12 ""
;7 Edit 0x54030080 0x200 268 2 48 12 ""
;8 Button 0x54032000 0x0 320 2 46 12 "Add"
;END DIALOG
;DIALOG EDITOR: "" 0x2030001 "" "" ""
str controls = "3 4 5 6 7"
str cb3 cb4 e5 e6 e7
e5=1
if(!ShowDialog("CC_Dialog" &CC_Dialog &controls)) ret
ret
;messages
sel message
,case WM_INITDIALOG
,case WM_DESTROY
,case WM_COMMAND goto messages2
ret
;messages2
sel wParam
,case 8
,CC_Add hDlg
,
,case IDOK
,case IDCANCEL
ret 1Function CC_Add
;/CC_Dialog
function hwnd
int index=id(5 win("Dialog" "#32770"))
str sIndex.getwintext(index)
int i=val(sIndex)
int i2=val(sIndex)
i2*25
i*100
int idctrl
int hctrl
;CreateControl([Exstyle][Class][Text][Style][x][y][cx][cy][Hwnd][Id])
for(idctrl i 1000000) if(!id(idctrl hwnd)) break
hctrl=CreateControl(WS_EX_CLIENTEDGE "ComboBox" 0 0x54230243 2 i2 96 213 hwnd idctrl)
for(idctrl i 1000000) if(!id(idctrl hwnd)) break
hctrl=CreateControl(WS_EX_CLIENTEDGE "ComboBox" 0 0x54230243 100 i2 96 213 hwnd idctrl)
for(idctrl i 1000000) if(!id(idctrl hwnd)) break
hctrl=CreateControl(WS_EX_CLIENTEDGE "Edit" 0 0x54030080 198 i2 20 12 hwnd idctrl)
for(idctrl i 1000000) if(!id(idctrl hwnd)) break
hctrl=CreateControl(WS_EX_CLIENTEDGE "Edit" 0 0x54030080 220 i2 46 12 hwnd idctrl)
for(idctrl i 1000000) if(!id(idctrl hwnd)) break
hctrl=CreateControl(WS_EX_CLIENTEDGE "Edit" 0 0x54030080 268 i2 48 12 hwnd idctrl)
;
i/100
i+1
sIndex=i
sIndex.setwintext(index)