Speeech! [UPDATE]
July 27, 2015 | Snippets | en | fr
Speeech for InDesign CS4, CS5, CS6, and CC is a very basic script inspired by a recent forum topic: “Drawing a triangle shape thru a script…”. The user was “looking for a way to automate some of the work [he does] for a manga magazine...” Given a dialog in an oval shape already formatted, he wanted to specify the place where the oval should point and have the speech balloon automatically created.
Update 27-July-2015. — Slight bug fix, thanks to Bruno Herfst.
Speeech provides two alternative ways to easily achieve this task:
1) Click the Reference Point—in the Control panel—which corresponds to the direction of the pointer relative to the target object, then select the object and run the script.
2) Use the Line tool to draw a direction line, then select both the line and the target object and run the script.
Technical notes
— Speeech can be applied to any polygonal shape (Oval
, Rectangle
, etc.), including customized paths. It also supports text frames.
— If needed, the script automatically computes the intersection point between the direction line and the target frame, so you don't have to position the exact junction point.
— Speeech supports rotated, scaled, and/or skewed shapes. It always considers the inner coordinate space of the target object.
— Advanced users can customize the Speeech effect by playing with the following parameters (see the source file):
// Distance between the 'attach' point // and each 'twin' point (in pt) ATTACH_WIDTH = 6 // Depth of the attach point within // the frame (in pt) DEPTH = 8 // Magnitude of the direction vectors // given as a barycentric factor ]0,1] DIR_WEIGHT = 0.5 // Curve factor (>=0) CURVE = 2
In particular, resetting the CURVE
parameter to 0 (zero) lets you get straight pointers, while increasing that value produce more pronounced curves:
Comments
Comme tu le dis, Trop fort !
Héhé marrant ce truc. Tu es toujours là où on t'attend pas :D
Loic
Ce script est peut-être "rudimentaire", mais il va m'être bien utile.
Parfois je dois "interpeller" le lecteur au moyen d'un phylactère. Ma plus grande difficulté était de dessiner le pointeur. Ceux que je produisais ne me convenaient jamais... et y passait trop de temps pour y parvenir.
En plus, je trouve très astucieux le placement de cette pointe. :)
Hello again - I am the user who proposed the idea... I used to make this manually, by creating one text frame (ussually oval) and the duplicating a piece of triangle drawn just the way I liked it: a bit curved and rotating and scalling until I got the result I wanted. After that I would join the two paths. Your solution is outstanding, thank you again... I owe you big...
Excellent Marc !
La simplicité n'est ici que le symptôme visible de la maîtrise :)
C'est Magnifique!
how do you actually run this on a mac? I tried to download it but it just opened to another browser page with the script, and copying and pasting in applescript editor window didnt work.
this is the first time i am using a script! please help.
Hi ANIA,
> this is the first time i am using a script! please help.
Let me direct you to this excellent resource for beginners (designed by Dan Rodney): “How to install InDesign/InCopy Scripts”
See also this useful page at InDesign Secrets: “How to Install a Script in InDesign That You Found in a Forum or Blog Post”
@+
Marc
@Anina: hold down the alt key before clicking the link. This will then download the file into your downloads folder.
Nice script - thanks!
Bon, c'est pas le tout de jouer Marc, on attend des scripts sérieux…!! J'déconne, excellente idée et pas si farfelue…!!!
NB : tu devrais prendre plus souvent des vacances, ça te réussit ;^)
Ha c'est génial... Marc a encore frappé... Bravo et merci...!
C'est assez génial, mais... On me demande des phylactères en forme de nuages (songe, rêve...). Existe-t-il autre chose ? Je cherche encore. La difficulté réside surtout dans le fait que la flèche est composée de bulles de plus en plus petites.
@ M Raj
Merci pour l'idée. Ce serait une évolution intéressante du script de départ. Je vais y réfléchir.
@+
Marc
Merci pour ce script, une révolution!
Que ce soit le texte explicatif, la petite vidéo explicative, les liens dans les commentaires; tout est fait pour trouver son chemin, même pour l'amateur que je suis! Où en est le script avec les petites bulles mode rêve/pensée? Encore merci, très beau travail!
Hello, Mr. Autret. I'm having troubles getting this to work. I made a circle using the circle tool, set the reference point, selected the circle shape, and run the script. It says, "Unable to attach the objects." So I tried with a line. I made a diagonal line, selected it and the circle, and run the script (via the script panel) and I get the same response. Can you help me (please)?
@AliM
> […] Où en est le script avec les petites
> bulles mode rêve/pensée ?
C'est sur mes tablettes.
(Ce printemps glacial ralentit la course de mes phalanges ;-)
@+
Marc
@BGM
> I'm having troubles getting this to work. I made a circle using the circle
> tool, set the reference point, selected the circle shape, and run the
> script. It says, "Unable to attach the objects."
Hmmm... What InDesign version are you using?
Bonjour, j'ai le même problème que BGM. Ce script fonctionne avec InDesign CS5, mais avec InDesign CS6 il fonctionne aléatoirement. Quand il ne fonctionne pas, le message “Unable to attach the objects” s'affiche.
Bonjour, ce script à l'air très intéressant, mais le fichier script n'est plus disponible lorsqu'on clique sur télécharger. Est-ce normal?
Bonsoir Michel,
Le script est bien disponible. Faites un CLIC DROIT sur le lien pour enregistrer le fichier (Speeech.js) sur votre disque.
Concernant l'installation du script dans InDesign, je vous renvoie à ce lien plus détaillé : http://www.indiscripts.com/pages/he...
Cordialement,
Marc
En effet, c'est erreur est dû à mon navigateur.
Merci beaucoup !