velocity-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Geir Magnusson Jr." <ge...@optonline.net>
Subject Re: Quick Question.
Date Tue, 10 Sep 2002 12:27:48 GMT
On 9/10/02 8:11 AM, "Anakreon Mejdi" <amejdi@ertonline.gr> wrote:

> It would do the job.
> But the best solution would be not to need anything else to produce
> the correct output.

I think the point of difference is the definition of 'correct output'

:)

> 
> Charles Anthony wrote:
> 
>> Why not use a code-tidier to do exactly the same thing to generated code ?
>> e.g.
>> use Jalopy where you suggest to use JTidy...
>> 
>> Cheers,
>> 
>> Charles.
>> 
>> 
>>> -----Original Message-----
>>> From: Anakreon Mejdi [mailto:amejdi@ertonline.gr]
>>> Sent: 10 September 2002 12:52
>>> To: Velocity Users List
>>> Subject: Re: Quick Question.
>>> 
>>> 
>>> I had a problem with ideating when I wrote a template to produce java
>>> source code.
>>> I didn't make any questions in the list because now I am writing an
>>> other program and decided to fix the problem later.
>>> 
>>> To format HTML I would use JTidy or event better the combination of
>>> JTidy and org.dom4j.io.DOMReader + org.dom4j.io.HTMLWriter for grater
>>> control on the indentation of html.
>>> 
>>> I believe that the indentation should be fixed for cases like source
>>> code production when idendation does matter.
>>> 
>>> Geir Magnusson Jr. wrote:
>>> 
>>> 
>>>> On 9/6/02 12:39 PM, "Carsten Burstedde" <c@burstedde.de> wrote:
>>>> 
>>>> 
>>>> 
>>>>>> Velocity has some quirks with whitespaces. Currently nicely
>>>>>> 
>>> structured
>>> 
>>>>>> templates produce ugly HTML souce, since whitespaces of indented
>>>>>> directives are emitted to the output (except around
>>>>>> 
>>> #set(...) and #end
>>> 
>>>>>> statements).
>>>>>> 
>>>>>> 
>>>>> That's true - my processed HTML pages have dozens of empty lines in
>>>>> front of the beginning <html>. Why not omit all whitespace
>>>>> 
>>> output on a
>>> 
>>>>> line and the newline if it contains only a directive and no html?
>>>>> 
>>>>> 
>>>> What if you want whitespace?
>>>> 
>>>> 
>>>> 
>>> 
>>> 
>>> --
>>> To unsubscribe, e-mail:
>>> <mailto:velocity-user->unsubscribe@jakarta.apache.org>
>>> For 
>>> additional commands,
>>> e-mail: <mailto:velocity-user-help@jakarta.apache.org>
>>> 
>> 
>> 
>> This email and any attachments are strictly confidential and are intended
>> solely for the addressee. If you are not the intended recipient you must
>> not disclose, forward, copy or take any action in reliance on this message
>> or its attachments. If you have received this email in error please notify
>> the sender as soon as possible and delete it from your computer systems.
>> Any views or opinions presented are solely those of the author and do not
>> necessarily reflect those of HPD Software Limited or its affiliates.
>> 
>>  At present the integrity of email across the internet cannot be guaranteed
>> and messages sent via this medium are potentially at risk.  All liability
>> is excluded to the extent permitted by law for any claims arising as a re-
>> sult of the use of this medium to transmit information by or to
>> HPD Software Limited or its affiliates.
>> 
>> 
>> 
>> --
>> To unsubscribe, e-mail:
>> <mailto:velocity-user-unsubscribe@jakarta.apache.org>
>> For additional commands, e-mail:
>> <mailto:velocity-user-help@jakarta.apache.org>
>> 
> 
> 
> 
> --
> To unsubscribe, e-mail:
> <mailto:velocity-user-unsubscribe@jakarta.apache.org>
> For additional commands, e-mail:
> <mailto:velocity-user-help@jakarta.apache.org>
> 

-- 
Geir Magnusson Jr. 
Research & Development, Adeptra Inc.
geirm@adeptra.com
+1-203-247-1713



--
To unsubscribe, e-mail:   <mailto:velocity-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:velocity-user-help@jakarta.apache.org>


Mime
View raw message