您当前的位置: 首页 > 

插件开发

暂无认证

  • 1浏览

    0关注

    492博文

    0收益

  • 0浏览

    0点赞

    0打赏

    0留言

私信
关注
热门博文

InDesign插件-常规功能开发-JS调试器打开和关闭-js脚本开发-ID插件

插件开发 发布时间:2022-06-29 09:39:57 ,浏览量:1

文章目录
    • 1.算法原理
    • 2.作者答疑

1.算法原理

  Adobe InDesign是Adobe公司的一个桌面出版 (DTP) 的应用程序,主要用于各种印刷品的排版编辑。InDesign可以将文档直接导出为Adobe的PDF格式,而且有多语言支持。它也是第一个支持Unicode文本处理的主流DTP应用程序,率先使用新型OpenType字体,高级透明性能,图层样式,自定义裁切等功能。它基于JavaScript特性,和与兄弟软件Illustrator、Photoshop等的完美结合,界面的一致性等特点都受到了用户的青睐。采用脚本语言自动化编码,在学习中的一个重要功能是开启调试环境和关闭调试环境功能,源代码如下所示:

//DebugOn.js
//An InDesign CS JavaScript

//Starts the debugger at the beginning of every script.

//For more on InDesign scripting, go to http://www.adobe.com/products/indesign/scripting.html
//or visit the InDesign Scripting User to User forum at http://www.adobeforums.com
alert("JavaScript调试器现在打开,并且将会保持到你关闭InDesign或运行“JS调试器关闭”脚本")
//$.level = 0 to disable debugging
//$.level = 1 to break on runtime errors
//$.level = 2 to break at the beginning of every script.
$.level = 2

//DebugOff.js
//An InDesign CS JavaScript

//Turns the JavaScript debugger off.

//For more on InDesign scripting, go to http://www.adobe.com/products/indesign/scripting.html
//or visit the InDesign Scripting User to User forum at http://www.adobeforums.com
alert("JavaScript调试器关闭。要重新启动JavaScript调试器,运行“JS调试器打开”脚本或按下Shift键同时运行一个脚本。")
//$.level = 0 to disable debugging
//$.level = 1 to break on runtime errors
//$.level = 2 to break at the beginning of every script.
$.level = 0

  合理的脚本代码可以有效的提高工作效率,减少重复劳动。

2.作者答疑

  如有疑问,敬请留言。

关注
打赏
1665481431
查看更多评论
立即登录/注册

微信扫码登录

0.0402s