View Full Version : Canvas in QT
chandan
11th March 2010, 16:15
Hi Everyone,
I am new in QT so can you please tell me how can I add two Canvas in my QFrame?
Thanks.
Lykurg
11th March 2010, 16:19
what exactly you mean by Canvas? You can draw on every QWidget. To position two widget in a frame use layouts.
chandan
11th March 2010, 16:21
I want to add two canvas where I can draw depending on the event I will receive from the user.
Lykurg
11th March 2010, 16:25
I want to add two canvas where I can draw depending on the event I will receive from the user.
Ok, then you have two main options: Subclass a QWidget and paint in its paint event to draw via QPainter. Or use a (more complex and powerfull) QGraphicsView framework.
For arranging them in a frame use as told QLayout/QHBoxLayout...
chandan
11th March 2010, 16:27
Thanks a lot.
mag
11th April 2011, 04:46
I want to add two canvas where I can draw depending on the event I will receive from the user.
have you done this already?
Powered by vBulletin® Version 4.2.5 Copyright © 2024 vBulletin Solutions Inc. All rights reserved.