Discussion:
fop doesn't style list-item-label for RTF
Deryl Seale
2007-06-18 15:42:50 UTC
Permalink
I am trying to render a numbered (well, lettered really) list in RTF
format, but FOP doesn't apply the styles I specify. I have tried the
following:

<fo:list-item-label end-indent="label-end()" font-weight="bold">
<fo:block><xsl:number count="qti:simpleChoice"
format="A"/></fo:block>
</fo:list-item-label>

<fo:list-item-label end-indent="label-end()">
<fo:block font-weight="bold"><xsl:number
count="qti:simpleChoice" format="A"/></fo:block>
</fo:list-item-label>

Both of these correctly make the label for the list item bold, but in
RTF, the label is just plain text. Any idea if this is a known bug,
and if so, where I might poke around to fix it?

thanks.
--
Deryl Seale -- Director of Engineering
c: 734.883.9636
***@intel-assess.com
www.intel-assess.com
Deryl Seale
2007-06-18 15:52:24 UTC
Permalink
Post by Deryl Seale
Both of these correctly make the label for the list item bold, but
in RTF, the label is just plain text.
Sorry, I meant to say that these declarations make the label bold for
PDF output, but not in RTF for some reason.

-d.
Adrian Cumiskey
2007-06-18 16:17:56 UTC
Permalink
Hi Deryl,

Which version of FOP are you using? It would be really helpful if you
include the FO file in full.

Cheers,

Adrian.
Post by Deryl Seale
I am trying to render a numbered (well, lettered really) list in RTF
format, but FOP doesn't apply the styles I specify. I have tried the
<fo:list-item-label end-indent="label-end()" font-weight="bold">
<fo:block><xsl:number count="qti:simpleChoice"
format="A"/></fo:block>
</fo:list-item-label>
<fo:list-item-label end-indent="label-end()">
<fo:block font-weight="bold"><xsl:number
count="qti:simpleChoice" format="A"/></fo:block>
</fo:list-item-label>
Both of these correctly make the label for the list item bold, but in
RTF, the label is just plain text. Any idea if this is a known bug, and
if so, where I might poke around to fix it?
thanks.
--
Deryl Seale -- Director of Engineering
c: 734.883.9636
www.intel-assess.com
Deryl Seale
2007-06-18 22:07:59 UTC
Permalink
Sorry, I am using FOP 0.93, and a sample of the FO file is below --
note that it renders the list-item-label text in bold when outputting
in PDF form, but only renders them in plain text when outputting to RTF.

thanks.
-d.

-=-=-=-=-=- SAMPLE -=-=-=-=-=-

<fo:root xmlns:fo='http://www.w3.org/1999/XSL/Format' xmlns:m='http://
www.w3.org/1998/Math/MathML' font-family='Helvetica'>
<fo:layout-master-set>
<fo:simple-page-master margin-left='0.75in' master-name='normal-
page' page-width='8.5in' page-height='11in' margin-bottom='.5in'
margin-top='.5in' margin-right='0.75in'>
<fo:region-body region-name='body' margin-bottom='0.7in'
margin-top='1in' />
</fo:simple-page-master>
</fo:layout-master-set>
<fo:page-sequence master-reference='normal-page'>
<fo:flow flow-name='body' font-size='11pt'>

<fo:block>
<fo:table table-layout='fixed'>
<fo:table-body border='1px solid white'>
<fo:table-row>

<fo:table-cell border='1px solid white' width='0.5in'>
<fo:block font-weight='bold'>1</fo:block>
</fo:table-cell>
<fo:table-cell border='1px solid white' width='3.5in'>
<fo:block space-after='5pt' font-weight='bold'>Which
of the following resources would be most valuable for a student doing
research about the life cycle of a frog?</fo:block>
<fo:block space-before='10pt'>
<fo:list-block provisional-distance-between-
starts='6.5mm'>
<fo:list-item>

<fo:list-item-label font-weight='bold' end-
indent='label-end()'>
<fo:block>A</fo:block>
</fo:list-item-label>
<fo:list-item-body start-indent='body-start()'>
<fo:block space-after='2pt' space-before='2pt'>
<fo:block>Science book about frogs</fo:block>
</fo:block>
</fo:list-item-body>

</fo:list-item>
<fo:list-item>
<fo:list-item-label font-weight='bold' end-
indent='label-end()'>
<fo:block>B</fo:block>
</fo:list-item-label>
<fo:list-item-body start-indent='body-start()'>
<fo:block space-after='2pt' space-before='2pt'>
<fo:block>A short story entitled "Jumping
Frogs"</fo:block>

</fo:block>
</fo:list-item-body>
</fo:list-item>
<fo:list-item>
<fo:list-item-label font-weight='bold' end-
indent='label-end()'>
<fo:block>C</fo:block>
</fo:list-item-label>
<fo:list-item-body start-indent='body-start()'>

<fo:block space-after='2pt' space-before='2pt'>
<fo:block>Map of frog habitats</fo:block>
</fo:block>
</fo:list-item-body>
</fo:list-item>
<fo:list-item>
<fo:list-item-label font-weight='bold' end-
indent='label-end()'>
<fo:block>D</fo:block>

</fo:list-item-label>
<fo:list-item-body start-indent='body-start()'>
<fo:block space-after='2pt' space-before='2pt'>
<fo:block>Dictionary entry for "Frogs"</
fo:block>
</fo:block>
</fo:list-item-body>
</fo:list-item>
</fo:list-block>

</fo:block>
</fo:table-cell>
</fo:table-row>
</fo:table-body>
</fo:table>
</fo:block>
</fo:flow>
</fo:page-sequence>
</fo:root>
Post by Adrian Cumiskey
Hi Deryl,
Which version of FOP are you using? It would be really helpful if
you include the FO file in full.
Cheers,
Adrian.
Post by Deryl Seale
I am trying to render a numbered (well, lettered really) list in
RTF format, but FOP doesn't apply the styles I specify. I have
<fo:list-item-label end-indent="label-end()" font-weight="bold">
<fo:block><xsl:number count="qti:simpleChoice"
format="A"/></fo:block>
</fo:list-item-label>
<fo:list-item-label end-indent="label-end()">
<fo:block font-weight="bold"><xsl:number
count="qti:simpleChoice" format="A"/></fo:block>
</fo:list-item-label>
Both of these correctly make the label for the list item bold, but
in RTF, the label is just plain text. Any idea if this is a known
bug, and if so, where I might poke around to fix it?
thanks.
--
Deryl Seale -- Director of Engineering
c: 734.883.9636
www.intel-assess.com
---------------------------------------------------------------------
--
Deryl Seale -- Director of Engineering
c: 734.883.9636
***@intel-assess.com
www.intel-assess.com
Loading...