Is it possible to find the text thickness used in Indesign document? So far am using Pitstop for detecting those errors in PDF and it is also require some visual inspection.
I just want to know if it possible or not? I am thinking if i do outline all texts and check the thickness. But not sure i can achieve this,
did you check Acrobat Pro's own Preflight capabilities?
There are some single preflight tests that are looking promising:
"Text uses artifical outline style"
"Text with stroked outlines"
From my Acrobat Pro DC on Mac OSX
( latest CC subscription version )
I am not looking for outlines text but i am looking for checking all text thickness if anything below 0.0047 inches.
So i thought if i do outline the texts in Indesign then i can able to check.. but not sure.
Not sure it's achievable inside InDesign. Would keep on checking it with Prepress tools.
You may as well consider Enfocus Connect You which allows generating a PDF file on the fly while doing some PitStop Preflight.
So you could check for such issues in InDesign.
Thank you for your suggestions. I thought it would be better if i get solution in Indesign itself.
I am going to look as Uwe and you suggested.
To correct myself I can't see any pitstop preflight that would check for text thickness, only text size. So it's a dead end.
Thanks, you saved my time. Now i have only option is using PDF preflight, isn't it?
no. I don't think you have a chance to get the values you want from Acrobat Preflight.
You can look for text size and used fonts. That's it. And for strokes on text.
Maybe you can do a blacklist out of these parameters and check with InDesign's preflight?
But one thing if you are trying to do that:
You cannot catch the "effictive" "thickness" of a glyph if it has e.g. a white stroke on white background…
Even if the design of a glyph would be in a way that all graphic lines are in parallel.
And it is not as you can see with your screenshot from your first post:
Different "thickness" values on the same glyph.
To analyze "thickness" would require something like a raster bitmap where you can count pixels in one way or another.
Thank you again for your response. I hope you may get little more information with the screen shots below from my client. They mentioned about point size is not important in 18.104.22.168 point
if you outlined the text,
offset the path by -0.002",
then check to see how many paths you have.
if Not 1, then text is too fine.
I can see some issues when it deals with letters such as "i" as it generally is a compound path I think.
breaking all compound paths may fix an "i" but will then break an "e".
not tested, off the top of my head.
can't see it being very fast.
some help in that direction can be found here:
this thread is for illy, but most should apply.
unfortunately there is no area property on paths with InDesign.
IF I remember well my high school mathematics, one possible algoritm would be to create outlines and then split the shape into a myriad of extra thin slices, as small as one can consider it's a rectangle. Then you could compute height of this shape to ensure about thickness. But I guess that in best cases, even a document made of one character would take ages to compute in ExtendScript.
There is some stuff in the Plugin SDK about ink bounds, maybe that is what you are looking for. If you download the SDK search for IWaxRunShape.
I dont think the slice would work in all casses.
but i like the idea.
as for the time in to compute, if you did go down a path like this, you could just run the test on the font.
just 1 instance of each letter for each point size.
you could do this as a pre-design test so you know how small a point size you can safely include in your design.
It's even way easier than that. Open the font in a font designer and measure the interesting distances in there, in design units. After all, all of those measurements will scale along with the rest of the font at any size.
You are so right but what about those who don't own a font editor and what about the users interested in a generic check
Loic, shame on you for not thinking inside the box You don't actually need a font editor (I could have mentioned that, but hey, what's a help forum without the occasional spoon feeding?).
Type the character of interest at 1000 pts. Measure the distance of interest. Divide by 1000. Now you have your multiplication factor, for that position, for any font size.
(You don't even literally have to use 1,000 pts exactly, as this will work for every possible size, which was my main point. But a lot of fonts have a one thousand units design size, and with good grid settings you will see the path points snap to 'logical' places inside the character.)
the question is, if the task of meassuring can be automated somehow.
I see no way.* At least no fast and reliable way…
Wrapped my head around this problem. Took it as an intellectual challenge.
Also developed a hopefully sufficient substitute for path.shape (Adobe Illustrator) for InDesign that would require a lot of processing time and is far from perfect. And finally found an algorithm to get the center of an arbitary shape with InDesign scripting only. It is based on the solution Quertifly is pointing at with changing the stroke weight of a shape in Illustrator. But would that help?
* Maybe I see a way now while typing this:
It would require to do sections of the path and subpaths of a glyph to break down the problem to smaller pieces.
And inspect the smaller pieces one by one.
But here comes the next obstacle:
How can we break a shape like the "e" to substantial and handy parts?
Seems the whole operation would require a lot of processing time if that is possible at all.
Meassuring by "mouse" would be faster and more precise 😉
Uwe, that can be done with converting the character to an outline and then subdividing the outline into a Delaunay triangulation - Wikipedia. That will give you the center lines.
The math is way beyond me, and it'd be such an amount of work that I'm not going to do so for free just because someone asked.
Adding to that, I still have no idea what the purpose is of this exercise. If all the OP wants to do is find out the thickness of the middle line of a Myriad Pro 'e', at any size, then measure once, and multiply this measurement by the actual font size. If the purpose is to have a tool that reports live, while moving the mouse around, what the 'thickness' is of the sub-element where the mouse is pointing to, then I'd ask "in what direction? what about fonts such as Optima? what about serif fonts? why do you (think you) need to know this?" etc.
Thanks a lot, Jongware!
All valid points.
I also ask myself all the time how "sane" this task really is…
Hm. About the Delaunay triangulation:
Would that really help for subdividing? For finding the center lines yes, but for subdividing?
This is much above my head…
OMG.. AWESOME.. Eagerly waiting to check the script with my document..
Thanks you so much
would Trevor's script be helpful to you?
I mean, I still don't understand fully what is required by your customer.
Should a single dot be measured? The smallest edge of a serif in a glyph?
I think, that would be really insane.
Trevor's script is looking great. And it is blazingly fast.
Well done, Trevor! I'm "enthusiasmerized" 🙂
As I understand your algorithm you are testing on a capital "T" only with your first version.
Maybe that could be expanded to other glyphs like "l"s or "i"s. Or dashes…
Thanks a lot!
The screenshot what i put in thread 8 is the requirement, that is what I got from my customer. Yesterday I thought I don't get any solution, so can windup. But luckily Trevor post with his video.
But not sure it will be give best output what my customer required. But I can say this after Trevor post the code.
Thanks for all the complements, I've been out the whole day and going out for another few hours.
I'll try get to the computer when I get back (quite late) and if not then I'll get it done tomorrow.