不一样地设计
发表于 2015-5-5 23:31:39
不错的 菜单,还可以定制,解决了我的问题!感谢!
wyl605
发表于 2015-5-7 12:10:35
谁发一个做好了工具箱试试看
sdbaijiao
发表于 2015-5-16 11:20:22
谢谢楼主的分享,好像很强。下来试试
csu911
发表于 2015-5-17 07:20:35
确实强大,收藏了。
yaokui25
发表于 2015-5-18 12:00:23
楼主您好。
从最新上传文件内容来看,时间都是·2015年2月份的?您所说的:
2015-5-5号,修复07以上修复提示错误、图标不能正确显示错误
从时间上看不对啊.
旺远镜里画世界
发表于 2015-5-19 17:15:10
只是个UI,实用功能没有加上
elitefish
发表于 2015-5-20 18:46:03
楼主的菜单做的不错,借楼主的插件做了个[信·CAD]工具箱的适配,可以自动生成工具箱的相应菜单
附上适配源码(defun mMenu:subMenu (subList mMenu bSpace
/
subMenu
)
(setq subList (cdr (assoc "SUBLIST" subList)))
(while subList
(setq subMenu (car subList)
subList (cdr subList)
)
(cond
;菜单
((= (cdr (assoc "TYPE" subMenu)) "MENU")
(progn
(if (not bSpace) (progn (write-line "\t[--]" mMenu) (setq bSpace T)))
(mMenu:subMenu subMenu mMenu bSpace)
)
)
;命令
((= (cdr (assoc "TYPE" subMenu)) "COMMAND")
(progn
(write-line (strcat "\t[" (cdr (assoc "NAME" subMenu)) "]"
"^C^C"
(apply '7Xin:CMDKernelName (cdr (assoc "COMMAND" subMenu)))
)
mMenu)
(setq bSpace nil)
)
)
((= (cdr (assoc "TYPE" subMenu)) "SPACER")
(if (not bSpace) (progn (write-line "\t[--]" mMenu) (setq bSpace T)))
)
)
)
)
(defun mMenu:MainMenu ( /
mMenu
lstMenu
subMenu
cmd
)
(if (setq mMenu (findfile "mMenu.Mnu"))
(progn
(setq mMenu (open mMenu "w"))
(write-line "***menugroup=信·CAD" mMenu)
(setq lstMenu (cdr (assoc "SUBLIST" 7Xin::MenuList)))
(while lstMenu
(setq subMenu (car lstMenu)
lstMenu (cdr lstMenu)
)
(cond
;子菜单
((= (cdr (assoc "TYPE" subMenu)) "MENU")
(progn
(write-line "***POP1" mMenu)
(write-line (strcat "[" (cdr (assoc "NAME" subMenu)) "]") mMenu)
(mMenu:subMenu subMenu mMenu nil)
(write-line "" mMenu)
)
)
;根菜单命令
((= (cdr (assoc "TYPE" subMenu)) "COMMAND")
(progn
(write-line "***POP1" mMenu)
;(write-line (strcat "[" (cdr (assoc "NAME" subMenu)) "]") mMenu)
(write-line (strcat "[" (cdr (assoc "NAME" subMenu)) "]"
"^C^C"
(apply '7Xin:CMDKernelName (cdr (assoc "COMMAND" subMenu)))
)
mMenu)
)
(write-line "" mMenu)
)
((= (cdr (assoc "TYPE" subMenu)) "SPACER")
)
)
)
(write-line "***POP1" mMenu)
(write-line "[更新CAD菜单]^C^CEF_MAKECADMENU" mMenu)
(write-line "***POP500" mMenu)
(close mMenu)
)
)
)
;生成CAD菜单
(defun C:EF_MakeCADMenu ()
(mMenu:MainMenu);生成菜单
;尝试卸载插件
(vl-catch-all-apply 'arxunload (list "MMenu.arx"))
(vl-catch-all-apply 'arxunload (list "MMenu_x64.arx"))
(setq 7Xin::Loaded (vl-remove "CAD菜单" 7Xin::Loaded))
(7Xin:LoadPlugin "CAD菜单")
)
mochaolong
发表于 2015-5-20 19:10:15
elitefish 发表于 2015-5-20 18:46 static/image/common/back.gif
楼主的菜单做的不错,借楼主的插件做了个[信·CAD]工具箱的适配,可以自动生成工具箱的相应菜单
附上适配 ...
倒三角不应该有灰色底,可能是你菜单文件编辑的原因,把菜单文件上传或是发给我,我给你看看。
阡陌客
发表于 2015-5-20 19:38:32
这么好的工具,必须给赞!谢谢楼主!
elitefish
发表于 2015-5-21 08:41:35
mochaolong 发表于 2015-5-20 19:10 static/image/common/back.gif
倒三角不应该有灰色底,可能是你菜单文件编辑的原因,把菜单文件上传或是发给我,我给你看看。
这个你看一下