Quantcast
Channel: Adobe Community : Popular Discussions - Illustrator Scripting
Viewing all articles
Browse latest Browse all 12845

Help determining stroke width of a font...

$
0
0

   Hi all, looking for some creative solutions here.  I need to determine the stroke thickness of a font via script and only via AI.  My idea is to always test the vertical center of an upper case "i" to get the width of the stroke.  I thought I would be able to just intersect the center of the glyph with a small rectangle, and take the width of that; however, I can not make calls to pathfinder from ExtendScript in AI.  I found out that InDesign can use the pathfinder via script, but that will not work in this situation.  Everything must be done via script and within AI.  My next idea would be to loop through the horizontal positions of anchor points in the letter and try to figure out which ones are positioned on the stroke.  I think I can work something out there, but I need a way to add in anchor points evenly along the curve and I don't see a way to do that.  Does anyone know if there is a way to add a point much like the Object>Path>Add Anchor Points - or if anyone has a better idea how to acomplish this task, please let me know.  Thanks!


Viewing all articles
Browse latest Browse all 12845

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>