Solved

Justify align codes for RTF (XSL)

Posted on 2007-11-28
3
5,258 Views
Last Modified: 2013-11-18
I'm writing an html to RTF transformer. Typically the align attribute appears in a <p> i.e:

<p align="justify">

Here is the xsl code i have (XSL knowledge isn't strictly necessary to answer this so read on regardless):

<xsl:template name="attribute_align">
  <xsl:choose>
    <xsl:when test="@align = 'center'">\qc </xsl:when>
    <xsl:when test="@align = 'left'">\ql </xsl:when>
    <xsl:when test="@align = 'right'">\qr </xsl:when>
    <xsl:otherwise>\ql </xsl:otherwise>
  </xsl:choose>
</xsl:template>

.. however, my code does not support "justify" align as shown in the above example. So if:

center align RTF= \qc
left align RTF = \ql
right align RTF = \qr
justify align RTF = ???

.. then what is the code for justify align? Or how would i accomplish this?
0
Comment
Question by:paddycobbett
  • 2
3 Comments
 
LVL 60

Accepted Solution

by:
Geert Bormans earned 500 total points
ID: 20368970
\qj
0
 
LVL 1

Author Comment

by:paddycobbett
ID: 20369438
Not quite sure why i couldn't find that! thanks once again :)
0
 
LVL 60

Expert Comment

by:Geert Bormans
ID: 20369576
welcome
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Stupid git question 2 63
Cordova Camera plugin fails 2 98
Where do I learn ES6? 3 51
Deleting Unselectable Lines in Word 2013 2 35
A few years ago I was very much a beginner at VBA, and that very much remains the case today.  I'll do my best to explain things as I go in the hope that other beginners can follow.  If you just want to check out a tool that creates a Select Case fu…
Have you tried to learn about Unicode, UTF-8, and multibyte text encoding and all the articles are just too "academic" or too technical? This article aims to make the whole topic easy for just about anyone to understand.
The viewer will learn how to look for a specific file type in a local or remote server directory using PHP.
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.

867 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now