TA的每日心情![](source/plugin/dsu_paulsign/img/emot/kx.gif) | 开心 2024-8-31 15:58 |
---|
签到天数: 89 天 [LV.6]常住居民II
管理员
- 积分
- 3366
|
radio.lsp:
[code]
;功能:演示 1、 radio按钮
;所需文件包括: radio.lsp radio.dcl
;
;加载步骤:
;1、加载lsp
;2、命令行输入 test
(defun c:test( / continue curBtn dlgId )
(setq dlgId (load_dialog "radio.dcl"))
(if (not (new_dialog "a" dlgId))
(exit)
)
(start_dialog)
(cond ((= curBtn "btn1") (f1))
((= curBtn "cancel") (setq continue nil))
)
(unload_dialog dlgId)
)
[/code]
radio.dcl:
[code]a:dialog{
label="radio";
:boxed_column {
label = "Type" ;
: radio_button {
key = "rb1" ;
label = "单选按钮1" ;
value = "1" ; //表示被选中
}
: radio_button {
key = "rb2" ;
label = "单选按钮1" ;
}
: radio_button {
key = "rb3" ;
label = "单选按钮1" ;
}
}
:boxed_radio_column {
label = "Type" ;
: radio_button {
key = "rb4" ;
label = "单选按钮1&a" ; //可以用ctrl+a 选中
value = "0" ;
}
: radio_button {
key = "rb5" ;
label = "单选按钮1" ;
}
: radio_button {
key = "rb6" ;
label = "单选按钮1" ;
value=1;
}
}
:row{
:button{
key="okBtn";
label="确定";
}
:cancel_button{
label="关闭";
}
}
}
[/code] |
|