[prev in list] [next in list] [prev in thread] [next in thread]
List: koffice
Subject: RE: Problem with KSpread from KDE 2.0 branch
From: Tinkl_Lukáš <Lukas.Tinkl () merlin ! cz>
Date: 2000-11-22 13:18:27
[Download RAW message or body]
> http://hasso.estpak.ee/kspread-problem.png
>
> Enetered formula to cell A1. Pressed ctrl+C and pasted it to
> cell A2 and A3.
> Once again ctrl+C in A1 and pasted result to the A4 and A5 etc.
>
> As I said I'm not sure, maybe there is a problem with debian packages.
>
> And ... maybe there is a problem with qt? Current Debian packages are
> compiled with qt-2.2.2.
>
Hi Hasso,
I'm not sure if it's related, but chances are it was me who broke it :-((
Try to revert the attached diff and tell me if it works
Thanks,
Lukas
["kformulaedit.cc.diff" (application/octet-stream)]
--- kformulaedit.cc.orig Sun Nov 5 17:57:34 2000
+++ kformulaedit.cc Sun Nov 5 18:59:58 2000
@@ -1182,20 +1182,21 @@
//NORMAL KEY:
//remove the selection and insert what the user types and
//perhaps some curly braces
- if(!(e->state() & (ControlButton | AltButton)) && e->ascii() >= 32 &&
- !strchr("{})]#", e->ascii())) {
// the {}])# are chars that can't be typed
- if(QChar(e->ascii()).isLetter() && nextGreek)
- insertChar(QChar(e->ascii() + SYMBOL_ABOVE));
+ if(!(e->state() & (ControlButton | AltButton)) && !(e->text().isEmpty()) &&
+ !(e->text().contains("{})]#")) ) {
+
+ if(e->text().unicode()[0].isLetter() && nextGreek)
+ insertChar(e->text()[0].unicode() + SYMBOL_ABOVE); //lukas: ugly, but works fine for non-ascii :-)
else
- insertChar(QChar(e->ascii()));
+ insertChar(e->text()[0].unicode()); //lukas: here too...
MODIFIED
redraw();
UPDATE_SIZE
return;
}
- else if(strchr("{})]#", e->ascii()))
+ else if(e->text().contains("{})]#"))
{
return;
}
@@ -1384,7 +1385,7 @@
if(restricted) { // we need to limit to only those things
// which can be evaluated.
- if(!isalnum((char)c) && !isspace((char)c) && (char)c != '.' && !IS_REFERENCE(c.unicode()) &&
+ if(!c.isLetterOrNumber() && !c.isSpace() && !c.isPunct() && !IS_REFERENCE(c.unicode()) &&
!(KFormula::eval()).contains(c) && (extraChars.isNull() || !extraChars.contains(c))) return;
}
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic