;;;CAD2004以上版本一键恢复【AutoCAD 经典】工作空间,命令jdkj
(defun c:jdkj ()
(command "TOOLBAR" "ALL" "H")
; 隐藏全部工具栏,目的是关闭天正软件等插件的工具栏
(cond (
(< (atoi (substr (ver) 13)) 2009 );;判断CAD版本是否小于 2009
(command "TOOLBAR" "工作空间" "H")
(command "TOOLBAR" "标准注释" "H")
(command "TOOLBAR" "标准" "S")
)) ;;cond
(command "TOOLBAR" "图层" "S")
(command "TOOLBAR" "特性" "S")
(command "TOOLBAR" "样式" "S")
(command "TOOLBAR" "绘图" "S")
(command "TOOLBAR" "修改" "S")
;(command "TOOLBAR" "查询" "S")
(command "TOOLBAR" "绘图次序" "S")
;(command "TOOLBAR" "图层 II" "S")
; 显示工具栏
(cond (
(> (atoi (substr (ver) 13)) 2008 );;判断CAD版本是否大于 2008
(setvar "MENUBAR" 1)
;显示菜单栏(2009及以上版本)
(command "RIBBONCLOSE")
;隐藏RIBBON功能区(2009及以上版本)
));;cond
(command "-wssave" "AutoCAD 经典" "y")
;将工作空间另存为"AutoCAD 经典"
;(command "workspace" "C" "AutoCAD 经典")
;当前工作空间"AutoCAD 经典"
(princ)
)
|