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

List:       kde-i18n-doc
Subject:    Bug in the calculator of Kalzium. May I introduce a new string?
From:       Carsten Niehaus <cniehaus () gmx ! de>
Date:       2005-12-29 12:37:34
Message-ID: 200512291337.40208.cniehaus () gmx ! de
[Download RAW message or body]


Hi

In Kalzium you can calculate the molecular weight of a molecule. 

Calculate "CO2Of". Of course there is no element "f". The result is (on the 
shell)

kalzium: Found element C
kalzium: Found element O
kalzium: Weight of term = 12.0107
kalzium: [Element* MoleculeParser::lookupElement(const QString&)] no such 
element: Of
kalzium: Weight of term = 31.9988
kalzium: Mass of CO2Of = 44.0095

The GUI presents 44.0095 as the result to the user. No errormessage. This is 
wrong for two reasons: 
1 - As the input was invalid there should be no result
2 - *If* we show a result it be neglect the "f" and display "60.0089" as a 
result because the would be correct for "CO2O".


Now calculate "CO2O":

kalzium: Found element C
kalzium: Found element O
kalzium: Weight of term = 12.0107
kalzium: Found element O
kalzium: Weight of term = 31.9988
kalzium: Weight of term = 15.9994
kalzium: Mass of CO2O = 60.0089

The result is correct and presented as 60.0089. 

Solution: Display a "Invalid input"-error.

Question 1: Is this the same as BUG 117774?
Question 2 (for the kde-i18n-folks): Would it be ok to display the new 
errormessage? I would introduce the new string today. I am not sure if this 
bugfix+new message would be covered by the current message-policy...

Carsten

[Attachment #3 (application/pgp-signature)]

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

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