Skip to main content

Text Exploder KBar API

TextExploder V3 comes with build-in KBar support, which means that you can execute any TextExploder function using custom toolbar buttons of KBar (or let any other scripts remote execute KBar functions).


To create a custom KBar button, go to the KBar Settings, click on "Add Button" and choose as button type "Run JSX/JSXBIN File".

In the dialog that opens, choose the TextExploder script (TextExploder.jsxbin) as file to execute and enter at Script function or argument one of the following:

  • explode({split:"characters"}) to split into characters
  • explode({split:"words"}) to split into words
  • explode({split:"lines"}) to split into lines
  • explode({split:"custom word", splitWord:"MYWORD"}) to split at a custom word MYWORD
  • explode({split:"custom regular expression", splitWord:"REGEX"}) to split at a custom regular expression REGEX

Available Options

The explode function accepts the following additional arguments. If not provided, it uses the options you used the last time you used TextExploder with its normal user interface.

  • split (string) must be one of "characters", "words", "lines", "custom word", "custom regular expression"
  • splitWord (string) the custom word or custom regular expression
  • rtlText (bool) set to true for "right to left" text
  • deleteOriginal (bool) set to true to delete the original layer
  • layerOrder (string) must be one of \"bottomToTop\"|\"topToBottom\"
  • layerArray (array or layer objects to which TextExploder should be applied; default is the selected layers of the active comp)
  • silent (bool) set to true to suppress any messages


You can use the following icons for your KBar buttons.

You created your own icons and want to share them here? Please let us know!


  • explode({}) executes TextExploder exactly with the same options as it has been executed the last time with the TextExploder UI.
  • explode({split:"words", deleteOriginal:true, layerOrder:"topToBottom"}) splits the selected layer(s) into words, deletes the original layer(s) and sorts the layers of the words in reading order from top to bottom.
  • explode({split:"characters", layerArray:[app.project.activeItem.layers(1),app.project.activeItem.layers(3)]})
    splits the first and third layer of the comp into characters.