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

List:       koffice-devel
Subject:    Re: Question about RTF import filter
From:       Nicolas Goutte <nicolasg () snafu ! de>
Date:       2003-08-29 12:27:42
[Download RAW message or body]

On Friday 29 August 2003 13:25, Ewald Snel wrote:
> Hi Nicolas,
>
> > Wait! You are not telling me that MS has changed the specification after
> > RTF 1.5 on that point. :-(
>
> I have used version 1.6 (1999) to develop the import filter.
>
> > Good, I leave it as it, even if it is uncompatible with older RTF
> > versions. (I will just add a comment so that another developer does not
> > fall into the same trap.)
>
> It should be compatible according to the specification. The writer should
> probably insert some extra keywords for compatibility with older readers
> (\ul to turn on any underline for example, followed by the underline
> style).

The compatibility is probably hold because nobody has used something like 
\ulw0 . But otherwise it is a break, at least in documentation.

As for adding an extra \ul, I do not think that it is a good idea. Most \ul 
variants are known since RTF 1.2, except the waves and dashes (not even in 
RTF 1.5). However adding \ul is a risk, as surely some buggy readers will 
probably not like contradicting underlines one after another (without text 
between.)

>
> > Before I make another mistake, do \ulnone and \ul0 still switch off *all*
> > underlines or has this be changed too?
>
> Yes, from the specification:
>
> "\ul		Continuous underline. \ul0 turns off all underlining."
>
> The code is correct, the "\ul" keyword is a toggle property and the other
> underline keywords are flag properties.

But \ul0 stops *all* form of underline, as does \ulnone.

So \ul and \ulnone need special treatments, which is not currently done in the 
import filter.

>
> Perhaps it would be better to use an enumeration for the underline styles?
> The parsing of underline styles of KOffice is now incorrect: these keywords
> are not booleans, but should select an underline style (flag).

Yes, an enumeration would be better.

I am going to see if I can do it before KOffice 1.3 RC 1, otherwise it will 
probably be for KOffice 1.4. (I would prefer if it could be tested by users.)

>
> > Have a nice day!
>
> bye,
>
> ewald
Have a nice day!
>
> _______________________________________________
> koffice-devel mailing list
> koffice-devel@mail.kde.org
> http://mail.kde.org/mailman/listinfo/koffice-devel

_______________________________________________
koffice-devel mailing list
koffice-devel@mail.kde.org
http://mail.kde.org/mailman/listinfo/koffice-devel

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

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