Indiscripts

Tag : JavaScripting

InDiScripts Top 80 Autumn Links

Top 80 LinksAs a present for Christmas, here is a compilation of the greatest links we've tweeted during those last 3 months. An overwhelming majority regards InDesign scripting, plug-ins, GREP and/or JavaScript resources for ‘InDevelopers’.

Continue reading...

Can InDesign Script Rewrite Itself?

As illustrated by the YALT technique, it's easy —and powerful!— to let a script read its own bytes while it is running. We could even go further and get a script to update itself to achieve some advanced functionalities.

Continue reading...

Yet Another Localization Technique (YALT) – Part 2/2

In the previous episode, we designed a light-weighted markup syntax for localized strings of any JavaScript based projects. Now let's see how to get a generic and simple access to those L10N data.

Continue reading...

Yet Another Localization Technique (YALT) – Part 1/2

When you need your script's user interface to be translated according to the InDesign application locale, the common approch is to invoke the localization ExtendScript feature. The process is pretty straightforward, except that —in a verbose UI— you will have to create and manage many “localization objects”.

Continue reading...

Web Color Picker

InDesign is definitely not a solution for web designers. For example, look at the Swatches panel, isn't it the worst tool to select or create “web colors” in the #rrggbb hexadecimal format? Fortunately, the ScriptUI elements bring a way to build our own “Web Color Picker”, interacting with the swatches.

Continue reading...

How to Quickly Test a Sample Code

Sometimes you just need to test a short snippet without having to create and install a complete script. Suppose you want to check some object properties, or to evaluate a simple JavaScript expression. It is easy to write and interprete your instructions from the ExtendScript Toolkit, but it would be even faster to do the whole job from the InDesign user interface.

Continue reading...

Type your Code

JavaScript is often considered as a weakly typed language. It means —among other things— that we don't need to tell explicitly what kind of variables we handle, or what kind of arguments we provide to a given function. String? Integer? Boolean? In most cases, everything will work without ever declaring the type.

Continue reading...