1291500406
发表于 2019-4-24 14:00:14
664571221 发表于 2018-8-3 15:07
能否然按空格继续执行命令,而不是跳回面板
不要用c:命令 用sendkey的方法
664571221
发表于 2019-4-24 14:06:17
1291500406 发表于 2019-4-24 14:00
不要用c:命令 用sendkey的方法
能不能搞一个
1291500406
发表于 2019-4-24 14:08:50
本帖最后由 1291500406 于 2019-4-24 19:15 编辑
664571221 发表于 2019-4-24 14:06
能不能搞一个
[*](cond
[*]http://bbs.mjtd.com/source/plugin/imc_colorcode/images/jssc_none.gif ((= 0 dd) (setq Loop nil))
[*]http://bbs.mjtd.com/source/plugin/imc_colorcode/images/jssc_none.gif ((= 2 dd) (setq Loop nil) (bb_key"drawline "))
[*] ((= 3dd)(setq Loop nil) (bb_key"plot "))
[*] )
(vl-load-com)
(defun bb_key(key)(vla-sendcommand (vlax-get-property (vlax-get-acad-object) 'ActiveDocument) key)(princ))
一页一百,28页
2800按键管理界面
file:///C:/Users/必强电脑/AppData/Roaming/Tencent/Users/1291500406/TIM/WinTemp/RichOle/C%7DMBXX75D86%7D~N%25%021]G$1.png
yaokui25
发表于 2019-4-24 19:41:06
AAAAAAAAA
cowboy110
发表于 2019-5-9 17:03:05
谢谢分享!!!
qyming
发表于 2019-6-20 20:09:40
(setq lst '(("钢筋书写"
("钢筋结钩" "xyp-gjg")
("另类镜像" "lljx")
("板筋处理" "bjcl ")
("动态板筋" "dtbj")
)
("注筋标注"
("注筋排版" "zjpb")
("注筋左置 " "zjzz")
("注筋移位 " "zjyw")
("改图层名 " "gtcm")
)
("桩基网架"
("桩基承台 " "zjct")
("桩基统计 " "zjtj")
("平板网架 " "pbwj")
("曲线桁架 " "qxhj")
)
("编辑处理"
("改粱编号" "glbh")
("梁宽校对" "lkjd")
("梁柱修剪" "lzxj")
("井字梁 " "xyp-jzl")
)
)
)
;;(dcl-load lst)
(defun dcl-load (lst / make-dcl do_buttion
dclid dd i loop lst1 lst2
m n2 tt
)
(defun do_buttion (tt)
(if (= (eval (read (strcat "(type c:" tt ")"))) 'subr)
(eval (read (strcat "(c:" tt ")")))
(vl-cmdf tt)
)
)
(setq lst1 (mapcar 'car lst))
(defun make-dcl (lst / dcla dclb dclc dcld i lst2 m)
(setq dcla
(list "my_dialog:dialog{label = \"防迷你菜单\";")
)
(setq i 0)
(setq dclb (list ":row{:boxed_column{label = \"【菜单分组】\";"))
(foreach n lst1
(setq dclb
(append
dclb
(list
(strcat
":button{label=\""
n
"\";key = \"butt"
(itoa i)
"\";vertical_margin=none;vertical_margin=none;}"
)
)
)
)
(setq i (1+ i))
)
(setq lst2 (cdr (assoc (nth 0 lst1) lst)))
(setq dclc (list "}:boxed_column{"))
(setq m 0)
(foreach n1 lst2
(setq dclc
(append
dclc
(list
(strcat
":button{label=\""
(car n1)
"\";key = \"but"
(itoa m)
"\";vertical_margin=none;vertical_margin=none;}"
)
)
)
)
(setq m (1+ m))
)
(setq dcld
(list
"}}:button{label=\"关闭\";key=\"cancel\";is_cancel=true;width=10;fixed_width=true;alignment=centered;}}"
)
)
(append dcla dclb dclc dcld)
)
(new_dialog
"my_dialog"
(setq dclid (dcl-write (make-dcl lst)))
)
(setq loop t)
(while loop
;|
(setq i 0)
(repeat (length lst1)
(action_tile
(strcat "butt" (itoa i))
(progn (setq lst2 (cdr (assoc (nth i lst1) lst))
m 0
)
(foreach n2 lst2
(set_tile (strcat "but" (itoa m)) (car n2))
(action_tile
(strcat "but" (itoa m))
(progn
(setq tt (cadr (nth m lst2)))
(do_buttion tt)
)
)
(setq m (1+ m))
)
)
)
(setq i (1+ i))
)|;
(setq dd (start_dialog))
(cond
((= 0 dd) (setq Loop nil))
)
)
(unload_dialog dclid)
)
(defun dcl-write (lst / dcl_file file str dcl_id dcl-name)
(setq dcl_file (vl-filename-mktemp nil nil ".dcl"))
(setq file (open dcl_file "w"))
(foreach str lst (write-line str file))
(close file)
(setq dcl_id (load_dialog dcl_file))
(vl-file-delete dcl_file)
dcl_id
)
没法完成了,看下
paulpipi
发表于 2019-7-17 22:19:50
学习一下,谢谢
nochao
发表于 2020-2-17 02:09:47
1291500406 发表于 2019-4-24 14:08
[*](cond
[*] ((= 0 dd) (setq Loop nil))
[*] ((= 2 dd) (setq Loop nil) (bb_key
请教一下顶部的时间和底部的名言是怎么做的?方便发个源码学习一下吗
生活丨好无奈
发表于 2020-7-1 10:01:28
支持,很给力
zj20190405
发表于 2020-8-24 13:08:09
1291500406 发表于 2019-4-23 18:10
把一个数字改掉151改成1~255之间的数
大佬,这个面板源码能奉献下不