Thank you very much for your help.
 
Miroslav

________________________________

From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] 
Sent: Friday, March 16, 2007 1:54 PM
To: fop-users@xmlgraphics.apache.org
Subject: RE: Multi-line in a cell



Move the block outside of your loop.  The 'instream-foreign-object' is a
flow object so it will stay on the same line in the cell.  If you need a
new line, put the data in separate blocks. 

I did not check your code, but it looks OK. 

-Lou 

"Gregan, Miroslav" <[EMAIL PROTECTED]> wrote on 03/16/2007
08:35:22 AM:

> ok, I'm sorry I should have made a small expected result, here a 
> picture of it. 
> so this feature would be used only for the table-header. For some 
> cells I need to write vertically and for other horizontally. 
> As I wrote I do not know how many lines I will have write, so it can
> be between 1 and N. 
>   
> so the solution I should use would be something like? 
>   
>   
> <fo:table-cell border-width="0.37px" language="en" border-
> style="solid" padding-left="3px" padding-before="2.5px"
padding-after="0.5px"> 
>  <xsl:for-each select="@values">
>   <fo:block> 
>    <fo:instream-foreign-object> 
>     <svg width="10" height="100" xmlns="http://www.w3.org/2000/svg";> 
>      <g transform="translate(7,98)"> 
>      <g transform="rotate(-90)" font-family="SansSerif"> 
>       <text x="0" y="0"><xsl:value-of select="@value"/></text> 
>      </g> 
>      </g> 
>     </svg> 
>    </fo:instream-foreign-object> 
>   </fo:block>  
>  </xsl:for-each> 
> </fo:table-cell> 
> If this code should work, I have an other question, how are the 
> block inserted in a cell, is it predictable? 
> Because I though that the block would be put under the precedent 
> one, not on the precedents right. 
>   
> Could someone confirm that the code up will put as many vertical 
> lines in a cell as I want to. (After It's my problem to define the 
> cell size of course) 
>   
> and that the following will put as many horizontal lines in a cell 
> as I want to. 
>   
> > <xsl:template match="header/column"> 
> >   <fo:table-cell border-width="0.37px" language="en" border-
> style="solid" padding-left="3px" padding-before="2.5px" padding-
> after="0.5px"> 
> >     <fo:block hyphenate="true" font-size="10pt" font-weight="bold"> 
> >       <xsl:for-each select="@values"> 
> >         <fo:block> 
> >           <xsl:value-of select="@value"/> 
> >         </fo:block> 
> >       </xsl:for-each> 
> >     </fo:block> 
> >   </fo:table-cell> 
> > </xsl:template> 
>   
>   
> Thank you for your help 
>   
> Miroslav 
> 
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] 
> Sent: Friday, March 16, 2007 12:56 PM
> To: fop-users@xmlgraphics.apache.org
> Subject: Re: Multi-line in a cell

> 
> Miroslav: 
> 
> Not exactly sure of the layout you want, but did you try: 
> 
> <fo:table-cell border-width="0.37px" language="en" border-
> style="solid" padding-left="3px" padding-before="2.5px"
padding-after="0.5px">
>     <fo:block> 
>     <fo:instream-foreign-object> 
>   <svg width="10" height="100" xmlns="http://www.w3.org/2000/svg";> 
> <g transform="translate(7,98)"> 
> <g transform="rotate(-90)" font-family="SansSerif"> 
> <text x="0" y="0"><xsl:value-of select="@value"/></text> 
> </g> 
> </g> 
> </svg> 
> </fo:instream-foreign-object> 
> <fo:instream-foreign-object> <!--SECOND LINE HERE--> 
> <svg width="10" height="100" xmlns="http://www.w3.org/2000/svg";> 
> <g transform="translate(7,98)"> 
> <g transform="rotate(-90)" font-family="SansSerif"> 
> <text x="0" y="0"><xsl:value-of select="@value"/></text> 
> </g> 
> </g> 
> </svg> 
> </fo:instream-foreign-object> 
> </fo:block> 
> </fo:table-cell> 
> 
> This will produce multiple vertical lines, running bottom to top, 
> left to right.  Example: 
> 
> 3 6 
> 2 5 
> 1 4 
> 
> 
> -Lou 
> 
> 
> "Gregan, Miroslav" <[EMAIL PROTECTED]> wrote on 03/15/2007
> 11:51:51 AM:
> 
> > Hello all, 
> >   
> > I need a little help from you. 
> > I have to put manual line breaks in fo:table-cells. 
> > So as I understood I need to insert each line in a separate block in
> > the cell like in this XSL code, is it correct? 
> >   
> > <xsl:template match="header/column"> 
> >   <fo:table-cell border-width="0.37px" language="en"
border-style="solid"
> > padding-left="3px" padding-before="2.5px" padding-after="0.5px"> 
> >     <fo:block hyphenate="true" font-size="10pt" font-weight="bold"> 
> >       <xsl:for-each select="@values"> 
> >         <fo:block> 
> >           <xsl:value-of select="@value"/> 
> >         </fo:block> 
> >       </xsl:for-each> 
> >     </fo:block> 
> >   </fo:table-cell> 
> > </xsl:template> 
> >   
> > But I need to implement this feature also for text written 
> > vertically, so using SVG, 
> > knowing that I use the same structure "values" containing 1 to N 
> > "value" to stores the datas, how should I modify this? 
> >   
> > <xsl:template match="header/column"> 
> >   <fo:table-cell border-width="0.37px" language="en"
border-style="solid"
> > padding-left="3px" padding-before="2.5px" padding-after="0.5px"> 
> >     <fo:block> 
> >       <fo:instream-foreign-object> 
> >         <svg width="10" height="100"
xmlns="http://www.w3.org/2000/svg";> 
> >           <g transform="translate(7,98)"> 
> >           <g transform="rotate(-90)" font-family="SansSerif"> 
> >             <text x="0" y="0"><xsl:value-of select="@value"/></text>

> >           </g> 
> >           </g> 
> >         </svg> 
> >       </fo:instream-foreign-object> 
> >     </fo:block> 
> >   </fo:table-cell> 
> > </xsl:template> 
> >   
> > Thank you for your help. 
> >   
> > Kind regards, 
> >   
> > Miroslav Gregan 
> >   
> > Siemens PSE-SK KB SK2 
> > Dubravska cesta 4 
> > 84104 Bratislava 
> > Slovakia 
> >  [attachment "example.JPG" deleted by Louis.Masters/LOG-NET] 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to