[prev in list] [next in list] [prev in thread] [next in thread]
List: koffice-devel
Subject: Re: KOScript & KSpread
From: <weis () stud ! uni-frankfurt ! de>
Date: 2001-08-31 16:40:55
[Download RAW message or body]
Hi,
On Thu, 23 Aug 2001, Werner Trobin wrote:
> Hi!
>
> I thought I'll have some fun in the holidays and try to make
> KOScript work with Unicode input and stuff like that. I started
> to check the sources and now I have some questions:
>
> 1) What happens when someone transfers his KSpread files to a
> different country? Should we try to convert the time/money
> formats? (e.g. change "1.200,34" to "1 200.34" or so depending
> on the settings in KLocale or leave them as they are?
> Related to that is the question of scanning these literals, but
> that's "only" an implementation issue... I guess I can make that
> work with some more C code within the scanner.
The way I used to think about it is the following:
A file saved in germany and opened in america should put the american
kspread into german mode. So instead of converting the document the
application should adapt itself. However, I think that did never
work during the time I have been hacking on the stuff.
> 2) Should it be possible to process Unicode strings? That means not
Would be nice.
> only "=A1+A2" should work if these fields contain non-latin1 text,
> but also e.g '="Hallo"+A2' where "Hallo" is some unicode text.
> How to pass these strings around? UTF-8?
> flex isn't able to process Unicode (UCS-2) strings, but it should
> be possible to hack around that by passing UTF-8 and allow "real"
> UTF-8 only for string literals. Plain Expressions like =A1+A2 don't
> contain anything but ASCII so that should work, no?
Looks like a solution to work around the lex limitations.
Trolltech should develop a unicode lexer :-)
(not speaking as a TT person)
> 3) (Mainly directed at Torben) Do we really want to do that?
>
> -[\n] idl_line_no++;
> +[\n] { idl_line_no++; return T_SEMICOLON; }
>
> -"," return T_COMMA;
> -";" return T_SEMICOLON;
> +";" return T_COMMA;
>
> (A part of the diff between the KScript and the KOScript scanner)
> This really results in ugly syntax and incomprehensible limitations
> in the coding style (layout wise) :}
Hmmmm, there was once a reason for removing this semicolon.
Ah, correct, because ; is used instead of , in some locales. That
is needed if numbers are formatted like 1,234.
-> ; could not be used as a delimiter any more.
> 4) KSpread flickers a lot and it seems to do lots of useless updates.
> I didn't look into that yet, and I can't guarantee that I'll have
> time to do so. Comments?
Maybe. This code has often been subject to problems, and I am out
of coding for too long to have any concrete ideas here.
> 5) KSpread shouldn't draw a cursor in a not active view. On deactivation
> it should just store the current position and restore it on activation
> again.
Yep.
> So before I start tearing KSpread apart I'd like to hear your comments
> and suggestions ;)
Koffice hacking seems to me to be 100 years ago ... a strange feeling ...
Torben
> Ciao,
> Werner
>
_______________________________________________
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