06-19-2013, 08:14 AM
Macro Macro2105
However then cannot edit in dialog editor.
Better use regular expression.
Function Dialog127
Or in dialog procedure (smart dialog) resize under case WM_INITDIALOG.
In dialog definition are used dialog units - depends on font size. In dialog procedure would need to use pixels.
int w=309
int h=250
str dd=
F
;BEGIN DIALOG
;0 "" 0x10C80A44 0x100 0 0 400 300 "Data"
;3 QM_Grid 0x54030000 0x0 0 0 {w} {h} ""
;...
if(!ShowDialog(dd 0 &controls 0 2)) retBetter use regular expression.
Function Dialog127
\Dialog_Editor
int w=309
int h=250
str dd=
;BEGIN DIALOG
;0 "" 0x90C80AC8 0x0 0 0 223 135 "Dialog"
;3 QM_Grid 0x56031041 0x200 8 8 96 48 "0x0,0,0,0,0x0[]A,,,[]B,,,"
;1 Button 0x54030001 0x4 120 116 48 14 "OK"
;2 Button 0x54030000 0x4 170 116 48 14 "Cancel"
;END DIALOG
;DIALOG EDITOR: "" 0x2030507 "*" "" "" ""
if(dd.replacerx("^(3 \w+ \w+ \w+ \w+ \w+) \d+ \d+" F"$1 {w} {h}" 4|8)<=0) end "rx failed"
str controls = "3"
str qmg3x
if(!ShowDialog(dd 0 &controls)) retOr in dialog procedure (smart dialog) resize under case WM_INITDIALOG.
In dialog definition are used dialog units - depends on font size. In dialog procedure would need to use pixels.
