
上QQ阅读APP看本书,新人免费读10天
设备和账号都新为新人
2.2 自定义功能区
NX9.0之前版本的功能区一直使用经典工具条,之后的版本官方建议使用Ribbon工具条。开发者可以在目录“%UGII_BASE_DIR%\UGII\menus\profiles”的子目录中找到不同应用模块中Ribbon工具条的样例。
2.2.1 Ribbon工具条接口文件
对于Ribbon工具条,用户可以创建或者修改不同的文件来定制Ribbon样式,其样式与接口文件扩展名对应关系如表2-2所示。NX二次开发时常用“.grb”“.gly”“.rtb”三种扩展名对应的样式定制Ribbon工具条。
表2-2 Ribbon工具条样式与接口文件扩展名对应关系

2.2.2 Ribbon工具条接口关键字
在制作Ribbon工具条时,脚本文件中也包含很多关键字,开发者可以在帮助文档“Customizing ribbon bar”中找到相关介绍,Ribbon工具条接口关键字及描述如表2-3所示。
表2-3 Ribbon工具条接口关键字及描述

续表
