The community will undergo maintenance on October 16th at 10:00 PM PDT and will be unavailable for up to one hour.
Hi all,
I need to double check how this usetext is being used:
<usetext source="space.fill,bullet.txt,@2.2mm,1.3mm" placemnt="before">
I know the @2.2mm is kern to , but what is the 1.3mm used for?
The problem that I have run into was in another part of the FOSI where the kern to wasn't working with another usetext before it. I changed that to use an algroup, but that has now thrown off the list item indent. So I am wondering if I need to use another algroup for the list items.
Thanks for any suggestions,
Ellen
Thanks Suzanne,
I will get reading 🙂
Ellen
I must not be understanding something.....and I have no more hair left to pull
Here is a snipit of the code I am working with.
<e-i-c gi="para" context="listitem" *=" unorderedlist"=" occur="first">
<charlist inherit="1" charsubsetref="endline" postspace_high_2"=">
<indent inherit="1" leftind="@3.5mm" firstln="*"/">
</charlist>
<att>
<specval attname="mark" attloc="unorderedlist" attval="none"/">
<charsubset>
<savetext textid="bullet.txt" conrule="!!"/">
</charsubset>
</att>
.......
<att>
<charsubset>
<usetext source="bullet.txt" placemnt="before">
<subchars charsubsetref="inline">
<indent inherit="1" leftind="@" rightind="*+2.2mm" firstln="*"/">
<quadding quad="right"/">
<algroup refpoint="first"/">
</subchars>
</usetext>
</charsubset>
</att>
</e-i-c>
At one point I had the bullet in the correct place, but on a line by itself...
I can get the algroup to work if it is starting from the left margin with 0, but as you know lists can be nested. Can the algroup be nested?
Normally I would approach this differently, but the constraint I am working with is that the paragraph can also have another usetext placed before the bullet and paragraph triggered by an attribute on the paragraph.
Thanks,
Ellen
Slight change to the code:
<e-i-c gi="unorderedlist" occur="all">
<charlist inherit="1" charsubsetref="block">
<indent inherit="1" leftind="@3.5mm" firstln="*-3.5mm"/">
</charlist>
</e-i-c>
<e-i-c gi="para" context="listitem" *=" unorderedlist"=" occur="first">
<charlist inherit="1" charsubsetref="endline" postspace_high_2"=">
</charlist>
<att>
<charsubset>
<usetext source="bullet.txt" placemnt="before">
<subchars charsubsetref="inline">
<indent inherit="1" <strong=">leftind="^" rightind="*+2.2mm" firstln="*"/>
<quadding quad="right"/">
<algroup refpoint="first"/">
</subchars>
</usetext>
</charsubset>
</att>
Still the bullet is on a line by itself.
I hope just like you would have thought 🙂
<charsubset charsubsetid="inline">
<textbrk startln="0" endln="0"/">
</charsubset>
<charsubset charsubsetid="block">
<textbrk startln="1" endln="1"/">
</charsubset>
I am going to try to make a very small test case that will hopefully leave no questions, but maybe an answer!
Thanks,
Ellen
I have made a very simple testcase, using the asdocbook.dtd. I will include a zip file so that no everyone needs to see it in the forum. The output should look like a "normal" list. I need to use the algroup because of another limitation of the kern to function not working when there are more than one usetext on an element.
Thank you everybody that has taken time to look at this!
Ellen
Suzanne,
The algroup is needed so that the nested and the sdyf on the second line line up at the 3.5mm indent.
*nested list 3 extra long line lkjsdf lkjhweiou dnv ht djfho;I wer ldskfh;oe r sheroi ksdf
sdyf sdjhfoi er skdhioue rkshdf seuyr kbjsdfkjhsioerus dfhsekr sdkfjhsdfyuoweyr
The code I am trying to replace is:
source="space.fill,bullet.txt,@2.2mm,1.3mm"
Where it has the space fillaround the bullet. This space around the bullet is significant.
Going back to square one to try to explain what I am doing..... I ran into a problem where I had text not lining up. When I researched it I found something (which I can't find now!) that said when you have more than one usetext the kern-to parameters doesn't always work. I was able to use an algroup to get the first problem on a heading to line up correctly. After making this correction it caused the lists to not line up correctly. The next step as I saw it was to make the lists also use the algroup.
So what the structure can look like is:
list
list item
para with attribute that causes test before conditionally, but also has to put out the bullet
So what it needs to format like is:
**** Conditional text<<< so this a usetext on the para and the bullet is a usetext that has space around it.
* here is the start if the para 3.5mm indented
if the line wraps the first and second line are both at the 3.5mm indent
I hope this spacing lines up in your emails, so that you can get a better idea of my problem.
Thanks for your patience,
In Reply to Suzanne Napoleon:
Ellen,
I don't think algroup is needed. I think the code below does what you want, including handling nested lists. Be sure all charlists and all inheriting categories are coded with inherit="1" (especially indent in this case), and set defaults in the docdesc. Then you can take advantage of inheritance and defaulting, and just code exception cases. Also, keep in mind that some categories, such as leading, first line indent, and presp are ignored unless the charlit contains textbrk startln=1 (block or startline charsubset). Similarly, some categories, such as postsp, require textbrk endln=1.
Good luck!
Suzanne
www.FOSIexpert.com
"WYSIWYG is last-century technology!"
<docdesc>
<charlist>
...
<indent leftind="0pt" rightind="0pt" firstln="*"/">
...
</charlist>
</docdesc>
<e-i-c gi="itemizedlist">
<charlist inherit="1" charsubsetref="block">
<indent inherit="1" leftind="@3.5mm" firstln="*"/">
</charlist>
<att>
<charsubset>
<savetext textid="bullet.txt" conrule="\=\"/">
</charsubset>
</att>
</e-i-c>
<e-i-c gi="listitem" context="*" itemizedlist"=">
<charlist inherit="1"charsubsetref="block">
<indent inherit="1" leftind="@3.5mm" firstln="*-3.5mm"/">
</charlist>
</e-i-c>
<e-i-c gi="para" context="listitem" *=" itemizedlist"=" occur="first">
<charlist inherit="1" charsubsetref="endline" postspace_high_2"=">
</charlist>
</e-i-c>
<e-i-c gi="para" context="listitem" *=" itemizedlist"=" occur="notfirst">
<charlist inherit="1" charsubsetref="block" postspace_high_2"=">
<indent inherit="1" firstln="*"/">
</charlist>
</e-i-c>