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

List:       kde-core-devel
Subject:    Re: Looking for (KDE) lib/class to perform calculations
From:       Rik Hemsley <rik () kde ! org>
Date:       2002-03-25 9:01:36
[Download RAW message or body]

#if Rob Kaper
> Is there a class/method/lib in KDE/Qt to perform calculations?
>
> Something like KCalculator::calculate(const QString expression) or
> something that let's me do int result = calculate( "(3*%1)+40" ).(30) which
> will return 130..

Have a look at 'spirit'. It allows you to write a parser in (very
few lines of) pure C++.

The examples include a calculator which seems to be almost exactly
what you're looking for.

Rik

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

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