RepCad Posted April 22, 2021 Posted April 22, 2021 (edited) Hi all, I've made a DCL for my Autolisp progoram, it works well but alignment of tiles is not set : Can someone modify or rewrite DCL codes to format window( or a better format that you think is better)? Thanks in advance. dclnam : dialog { key = "Title"; label = " AutoParcel "; initial_focus = "save"; spacer; width = 35; : column { : boxed_row { label = " Fixed values "; : edit_box { label = " Text Size "; key = "txtsize"; alignment = left; } : edit_box { label = " Decimal "; key = "txtdec"; alignment = left; }} : boxed_column { label = " Other options "; alignment = left; : row { alignment = left; children_fixed_width=true; : text { label = ""; key = "tx1"; } : text { label = "Prefix"; key = "tx2"; } : text { label = "Suffix"; key = "tx3"; }} : row { alignment = left; children_fixed_width=true; : toggle { label = "Area"; key = "togarea"; } : edit_box { label = ""; key = "areaprefix"; fixed_width=true; } : popup_list { key = "areasuffix"; } } : row { alignment = left; children_fixed_width=true; : toggle { label = "Perimeter "; key = "togpri"; } : edit_box { label = ""; key = "priprefix"; fixed_width=true; } : popup_list { key = "prisuffix"; } }} } spacer; : row { fixed_width = true; alignment = centered; : button { key = "save"; alignment = centered; label = " Save "; is_default = false; is_cancel = false; } : cancel_button { label = " EXIT "; width = 11; } } } Edited April 22, 2021 by amir0914 Quote
rlx Posted April 22, 2021 Posted April 22, 2021 dclnam :dialog {label=" AutoParcel ";initial_focus="utmsave"; spacer; :boxed_row {label=" Fixed values "; :edit_box {label=" Text Size "; key="txtsize"; alignment=left;} :edit_box {label=" Decimal "; key="txtdec"; alignment=left;}} :boxed_row {label=" Other options "; :column {:text_part {key="tp_1";}:toggle {label="Area"; key="togarea";}:toggle {label="Perimeter"; key="togpri";}} :column {:text {label="Prefix";} :edit_box {key="areaprefix";} :edit_box {key="priprefix";}} :column {:text {label="Suffix";} :popup_list {key="areasuffix";} :popup_list {key="prisuffix";}}} spacer; :row {fixed_width=true;alignment=centered; :button {key="utmsave"; alignment=centered;label=" Save ";}:cancel_button { label=" EXIT "; width=11;}} } you don't need to assign a key to the main dialog (key = "Title") and I think you don't need initial_focus if you set is_default = true for your "utmsave" button 1 Quote
RepCad Posted April 23, 2021 Author Posted April 23, 2021 (edited) Thanks for your replying, Is it possible to align center labels or edit boxes? for example I changed to below code but it didn't work : {:text {label="Prefix";alignment=centered;} Or Edited April 23, 2021 by amir0914 Quote
rlx Posted April 23, 2021 Posted April 23, 2021 dclnam :dialog {label="AutoParcel"; spacer; :boxed_row {label="Fixed values";:edit_box {label="Text Size";key="txtsize";}:edit_box {label="Decimal";key="txtdec";}} :boxed_row {label="Other options"; :column {children_alignment=centered;:text_part {key="tp_1";} :toggle {label="Area";key="togarea";}:toggle {label="Perimeter";key="togpri";}} :column {children_alignment=centered;:text {label="Prefix"; } :edit_box {key="areaprefix";} :edit_box {key="priprefix";}} :column {children_alignment=centered;:text {label="Suffix"; } :popup_list {key="areasuffix";} :popup_list {key="prisuffix";}}} spacer; :row {fixed_width=true;alignment=centered;:button {key="utmsave";is_default=true;label="Save";}:cancel_button {label="EXIT";}} } 1 Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.