Hi,

If your 'XXXX' data don't contain any spaces, you can imagine a XSLT
that replace your string with a fo:table, since you have both line
separator(
) and cell separator (last space before 'XXXX'). XSLT
gurus will help you for that.

If not, uou have to ensure that the used font is a monospace one, so
there will be no offset from one line to one other.

Le 11/05/2011 16:26, Michael Seeberger a écrit :
> Hi Georg,
> 
> you're right .. in this case the user is responsible for correctly
> inserting the text.
> So there is no way to get this done with setting the attributes correctly?
> 
> Michael
> 
> Am 11.05.2011 16:18, schrieb Georg Datterl:
>>
>> Hi Michael,
>>
>>  
>>
>> So if the user misses a blank, the alignment goes to hell? If yes, try
>> to replace all blanks with   (or all double blanks with two nbsp,
>> if you still want a break in the text). Ugly, but could work.
>>
>>  
>>
>> Regards,
>>
>>  
>>
>> Georg Datterl
>>
>> *Von:*Michael Seeberger [mailto:michael.seeber...@isys-software.de]
>> *Gesendet:* Mittwoch, 11. Mai 2011 16:13
>> *An:* fop-users@xmlgraphics.apache.org
>> *Betreff:* Re: Problem with whitespace-treatment
>>
>>  
>>
>> Hi George,
>>
>> the reason is, that the text comes form an textarea,
>> in which a customer can insert any text he or she wants to.
>>
>> regards,
>> Michael
>>
>> Am 11.05.2011 16:03, schrieb Georg Datterl:
>>
>> Hallo Michael,
>>
>>  
>>
>> Is there a reason why you don’t split the text into 9 parts and use a
>> table?
>>
>>  
>>
>> Regards,
>>
>>  
>>
>> Georg Datterl
>>
>> *Von:*Michael Seeberger [mailto:michael.seeber...@isys-software.de]
>> *Gesendet:* Mittwoch, 11. Mai 2011 15:37
>> *An:* fop-users@xmlgraphics.apache.org
>> <mailto:fop-users@xmlgraphics.apache.org>
>> *Betreff:* Problem with whitespace-treatment
>>
>>  
>>
>> Hello,
>>
>> i have a problem with whitespace-treatment in FOP. I'm using FOP 1.0
>> and can't get my text formatted the way i want to:
>>
>> my formatted text is (leading whitespaces before Bank, BLZ, Konto and
>> Empfänger)
>>
>>     Bank:                                      XXXXX
>>     BLZ:                                        XXXXX
>>     Konto:                                     XXXXX
>>     Empfänger:                            XXXXX
>>
>> Gutschriften überweisen wir auf die uns seinerzeit mitgeteilte
>> Bankverbindung. Sofern sich diese
>> geändert haben sollte, bitten wir zur Vermeidung von Fehlbuchungen um
>> Bekanntgabe.
>>
>> the value in my xml-tag is:
>>
>> <abrechnungsfreitext isMonospace="false" text="   
>> Bank:                   XXXXX&#xA;    BLZ:                   
>> XXXXX&#xA;    Konto:                  XXXXX&#xA;   
>> Empfänger:              XXXXX&#xA;&#xA;Gutschriften überweisen wir auf
>> die uns seinerzeit mitgeteilte Bankverbindung. Sofern sich diese
>> geändert haben sollte, bitten wir zur Vermeidung von Fehlbuchungen um
>> Bekanntgabe." />
>>
>> i tried several combinations of white-space-collapse,
>> white-space-treatment and linefeed-treatment. For example when using
>>
>> 1. white-space-collapse=false, linefeed-treatment=preserve,
>> white-space-treatment=*preserve *or *ignore-if-before-linefeed*
>>     => The text "Gutschriften überweisen ...." gets wrapped at "diese"
>> and a leading whitespace is added to the following line so it looks
>> like this:
>>    
>>     Gutschriften überweisen wir auf die uns seinerzeit mitgeteilte
>> Bankverbindung. Sofern sich diese
>>      geändert haben sollte, bitten wir zur Vermeidung von
>> Fehlbuchungen um Bekanntgabe.
>>
>> 2. white-space-collapse=false, linefeed-treatment=preserve,
>> white-space-treatment=*ignore-if-after-linefeed* or
>> *ignore-if-surrounding-linefeed*
>>     => The leading whitespaces before "Bank", "BLZ" etc. are beeing
>> ignored so the text is printed this way;
>>
>>    
>>     Bank:                                      XXXXX
>>     BLZ:                                        XXXXX
>>     Konto:                                     XXXXX
>>     Empfänger:                            XXXXX
>>
>>     Gutschriften überweisen wir auf die uns seinerzeit mitgeteilte
>> Bankverbindung. Sofern sich diese
>>     geändert haben sollte, bitten wir zur Vermeidung von Fehlbuchungen
>> um Bekanntgabe.
>>
>> Is there a way to prevent FOP from deleting the inserted whitespaces
>> before "Bank", and inserting a whitespace when performing an automatic
>> linebreak??
>>
>> I hope you get my point and can help me.
>>
>> Thx
>> Michael Seeberger
>>
>>
>>
>> -- 
>> iSYS Software GmbH
>>  
>> Michael Seeberger | Softwareentwickler
> 
> -- 
> iSYS Software GmbH
> 
> Michael Seeberger | Softwareentwickler

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org

Reply via email to