Copy link to clipboard
Copied
I'm quite suprised that powerful Illustrator does not have any easy solution for creating custom angled triangles. Is there anybody help me to create a custom angle triangle script ?
Thank you,
Best Regards.
2 Correct answers
Triangle Maker (Side, Angle, Angle)
...// Triangle Maker (Side, Angle, Angle)
// Carlos Canto - 11/21/13;
// http://forums.adobe.com/thread/1339420?tstart=0
var idoc = app.activeDocument;
var s_ssa = Window.prompt ('Enter 1 Side in points, 2 Angles in degrees, (Side, Angle1, Angle2)', '120, 30, 57', 'Triangle Maker');
var a_ssa = s_ssa.split(','); // turn into an array
var side = parseFloat (a_ssa[0]);
var angle1 = parseFloat (a_ssa[1]);
var angle2 = parseFloat (a_ssa[2]);
if (angle1+angle2<180) {
var pat
Inspired by Carlos' ideas, I combined the two scripts into one — TriangleMaker. It now has a triangle settings dialog and previews.
Explore related tutorials & articles
Copy link to clipboard
Copied
Like I mentioned, it is easy to do, but I wonder how you would create a triangle with the script that cannot be converted to a Live Shape.
Copy link to clipboard
Copied
Going to give this a try - thanks!


-
- 1
- 2