Community Tip - Stay updated on what is happening on the PTC Community by subscribing to PTC Community Announcements. X
How do I create dotfill and space fill with Styler for APP via javascript?
Solved! Go to Solution.
By "dotfill" and "space fill", I assume you are talking about the "leaders" feature. Leaders is a typesetting term for spacing or dots that push content apart (such as you might see in Tables of Contents with text on the left, a row of dots, and numbers on the right).
I'm not sure if Styler has this feature in the dialog box, but APP can certainly achieve this. If you open the FOM documentation or APP Help Center then you can search for the "fLeader" formatting object. This is intended to work with the formatting.insertLeader() formatting method. Obviously you will need to use an APP source edit to add the necessary code.
By "dotfill" and "space fill", I assume you are talking about the "leaders" feature. Leaders is a typesetting term for spacing or dots that push content apart (such as you might see in Tables of Contents with text on the left, a row of dots, and numbers on the right).
I'm not sure if Styler has this feature in the dialog box, but APP can certainly achieve this. If you open the FOM documentation or APP Help Center then you can search for the "fLeader" formatting object. This is intended to work with the formatting.insertLeader() formatting method. Obviously you will need to use an APP source edit to add the necessary code.
Hi Gareth,
Thank you for replay.
This would be the solution.
Can you give me please a hint in how to control the gap between each leader, in my case dots.
I have read the help and used
fLeader([text[, align[, gap[, gapLeft[, gapRight]]]]])
syntax as
var dotfill = new fLeader(".",0,1, 0, 0);
but it seems to keep the same gap no mather what fLength I assign for the "gap" attribute.
Thank you for help in advance.
Florin
formatting.insertLeader(
new fLeader(".", 0, new fLength("2mm"))
);
It is trying to convert the gap parameter to an fLength(). The base unit for fLength is decimicron (dm) where 10000dm = 1mm. You could replace new fLength("2mm") above with 20000 and get the same result.