[prev in list] [next in list] [prev in thread] [next in thread] 

List:       velocity-user
Subject:    Re: Whitespaces in rtf file
From:       "Angelo zerr" <angelo.zerr () gmail ! com>
Date:       2006-09-07 12:28:14
Message-ID: c77e343c0609070528s2c33391fr6ed27f70fa1cada () mail ! gmail ! com
[Download RAW message or body]


Hello Marcos,
With RTFTemplate you can design your model with word without editing (with
notepad) your RTF model.
RTFTemplate manage simple field and list of field. RTFTemplate is based on
Velocity.

 Process of RTFTemplate is :
1. read RTF file and trasform it to RTFDocument to detect mergefield ans
bookmark.
2. replace mergefield RTF code to remove the "" character and generate
#foreach when object context found is the list (see documentation) => in
this step you have velocity RTF file.
3. Merge JAVA context with the RTF velocity

I hope RTFTemplate will please you.

Regards Angelo

2006/9/7, Matthias Hendler <matthias.hendler@siv.de>:
>
> Hello Marcos,
>
> well, I use Velocity for processing plsql source code. I don't have
> experienced any problems with missing spaces and so while velocity
> inserts values.
> Only the #if ... #end and so on statements eat up whitespaces.
>
> As I don't know much about rtf (but willing to learn) it would really
> help us, if you can send us a short template where the problem occurs.
>
> Just some ideas, which you can verify.
> 1. Which velocity version you use?
> 2. Perhaps its a problem with the file loader? Or in general the way the
> rtf is loaded into memory?
> 3. Perhaps its a problem how the template is written to disk?
>
> Ciao Matthias
>
>
> Marcos Pazo schrieb:
>
> > We have already proven all ways, tabs, spaces..
> > the only form is to write the words without format but that is not
> > what we
> > want
> >
> > I will try RTFTemplate project although we would like to do it with
> > Velocity.
> >
> > Thank you
> >
> > 2006/9/7, Paul Loy <paul.loy@peoplesarchive.com>:
> >
> >>
> >> Are you sure that the spaces in the document are actually spaces and
> not
> >> tab characters?
> >>
> >> try explicitly changing them into spaces.
> >>
> >> Marcos Pazo wrote:
> >> > Template is:
> >> >
> >> > La empresa $expediente.razonSocial (CIF: $expediente.cif) situada en
> >> > $expediente.ciudad   - provincia de $expediente.provincia
> >> >
> >> > and the result is:
> >> > La empresa UNA EMPRESA S.L.(CIF: 99999999X) situada en Madrid-
> >> > provincia de
> >> > Madrid.
> >> >
> >> > |                                                       |
> >> >
> >> > Too, it occurs with word which are not tags...
> >> >
> >> > Example:
> >> > (rtf template)
> >> > it's a template
> >> > (result)
> >> > it's atemplate
> >> >
> >> >
> >> >
> >> > 2006/9/7, Paul Loy <paul.loy@peoplesarchive.com>:
> >> >>
> >> >> Sorry, totally thought that was an internal email!
> >> >>
> >> >> Send us the template and we'll be able to help more.
> >> >>
> >> >> Paul
> >> >>
> >> >> Marcos Pazo wrote:
> >> >> > Hi,
> >> >> >
> >> >> > I'm a novice user of Velocity.
> >> >> > I'm using it for change some rtf templates but I have a problem;
> >> when
> >> >> > I have
> >> >> > a tag ($date, i.e) in the middle of a paragraph,the following word
> >> >> always
> >> >> > appears beaten to tag without spaces, if the tag have a different
> >> >> format,
> >> >> > color, font, capital letters etc..
> >> >> >
> >> >> > Sorry for my bad English.
> >> >> > I hope you can help me.
> >> >> >
> >> >>
> >> >> This email has been scanned by Postini.
> >> >> For more information please visit http://www.postini.com
> >> >>
> >> >>
> >> >>
> ---------------------------------------------------------------------
> >> >> To unsubscribe, e-mail: velocity-user-unsubscribe@jakarta.apache.org
> >> >> For additional commands, e-mail:
> >> velocity-user-help@jakarta.apache.org
> >> >>
> >> >>
> >> >
> >>
> >>
> >> ---------------------------------------------------------------------
> >> To unsubscribe, e-mail: velocity-user-unsubscribe@jakarta.apache.org
> >> For additional commands, e-mail: velocity-user-help@jakarta.apache.org
> >>
> >>
> >
>
>
> --
> Mit freundlichen Grüßen
>
> Matthias Hendler
>
> Technologie
>
> SIV.AG
> Konrad-Zuse-Str. 1
> 18184 Roggentin
>
> Telefon: +49 (0)3 81 / 25 24 - 0
> Telefax: +49 (0)3 81 / 25 24 - 4 99
>
>
>
>
> mailto:matthias.hendler@siv.de
> http://www.siv.de
>
>
>
> **********************************************************************
> This email and any files transmitted with it are confidential
> and intended solely for the use of the individual or entity
> to whom they are addressed. The views expressed in this
> e-mail are those of the individual author and not necessarily
> those of SIV.AG.
>
> This footnote also confirms that this email message has
> been swept by serval anti-virus tools for the presence
> of computer viruses.
> *********************************************************************
>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: velocity-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: velocity-user-help@jakarta.apache.org
>
>


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic