PDA

View Full Version : Qwt examples


nitriles
1st October 2007, 14:51
Hey, ive recently got Qwt to work inside of Qt. Now i want to study the examples that are given with Qwt so that i can make my own 2D graph.
In:
/home/benutzer/Documents/qwt-5.0.2/examples/simple_plot
i have two files:
- simple.cpp
- simple_plot.pro

I want to run these programs so that i can see what they look like. Do i need to convert them to a python file first? How do i do that, which command do i use?
thanks a lot.

Uwe
1st October 2007, 21:54
Qwt is a C++ library, the examples are C++ code. You need to install a C++ development environment and have to compile and link the Qwt examples before you can execute them.

But maybe you are looking for PyQwt (http://pyqwt.sourceforge.net). It offers Python Bindings for the Qwt library.

HTH,
Uwe

nitriles
2nd October 2007, 08:47
I am indeed looking for PyQwt, which should be installed already.
So how should I go about installing/opening these examples?
Is it something similar to converting .ui Qt files into .py codes:
pyuic form.ui > form.py
Thanks!

nitriles
2nd October 2007, 10:26
Ok so i managed opening them!
But now they are in C++ code, how can i get it to python code, ive never had c++ and it is different!

Uwe
2nd October 2007, 16:46
AFAIK PyQwt comes with it's own examples, that are written in Python. This is what you are looking for.

I'm don't know if these examples are included in the PyQwt package you have installed. If you don't find them look at the PyQwt project page.

I'm the author of Qwt, but I never used the Python bindings myself. So for further question better ask Gerard ( the author of the bindings ) on the PyQwt mailing list.

Uwe

nitriles
4th October 2007, 13:48
Ok thanks a lot!
I found the examples and they are a great help!
thanks again.