Questions about QT Designer

Werner Modenbach modenbach at alc.de
Thu Jan 24 08:42:48 GMT 2002


On Mittwoch, 23. Januar 2002 21:07 Sean Murphy wrote / Am Mittwoch, 23. 
Januar 2002 21:07 schrieb Sean Murphy:
> This is really a QT Designer question, but I can't find a QT Designer
> mail list.  If there is one, I apologize for asking this here, and if
> someone could point me to the QT Designer mail list, I'd appreciate it.
>
> I'm trying to create some moving map software that interfaces to a GPS
> unit.  The GUI that I am creating will have the moving map area, and
> some other widgets to display other information.  I've laid out what I
> want the GUI to look like in QT Designer, except for the moving map
> area.
>
> The moving map area needs to have a background pixmap, then some sprites
> over the top of it that show where we are currently at, and where we
> have been.  From reading some of the QT docs, it looks like I want to
> use a QCanvas object to do this.  The problem is, what do I do in QT
> Designer to layout the QCanvas object?  There is no button (like there
> is for a QLabel, QHBox, etc.) to create a QCanvas widget.  I saw under
> Tools->Custom there is an "Edit Custom Widgets..." selection, but when I
> selected that I wasn't sure what I should put in the resulting dialog
> box.
>
> Anyone have any hints?  If I need to add a custom widget, what stuff do
> I need to put where to make it work?  Has anyone created other custom
> widgets?
>

Hi Sean,

The way I would handle this is to use a QFrame for the graphic area inside QT 
Designer.
Next you have to create your graphic class derived from QCanvas widget.
Use the event routines/slots to do apropriate actions (creating and moving 
the objects etc.). 
Use the QFrame widget as parent of your new class , thats it. 
To get automatic layout functionality you can use layoutclasses together with.

- Werner -

-- 
--------------------------------------------------------------
                    ALC Computertechnik GmbH

        \_       \_          \_\_\_     Kaiserstr. 100
       \_\_      \_        \_           D-52134 Herzogenrath
      \_  \_     \_        \_           Germany
     \_\_\_\_    \_        \_           Fon +49 2407 95810
    \_      \_   \_        \_           Fax +49 2407 958139
   \_        \_  \_\_\_\_    \_\_\_     http://www.alc.de
   ===========================================================
   Werner Modenbach                     modenbach at alc.de
--------------------------------------------------------------

-
to unsubscribe from this list send an email to kdevelop-request at kdevelop.org with the following body:
unsubscribe »your-email-address«



More information about the KDevelop mailing list