[Interest] Adding layouts to designer?

Scott Aron Bloom Scott.Bloom at onshorecs.com
Thu Dec 1 03:09:43 CET 2011


Have you looked at the code for the existing layouts and how they
integrate...

 

IIRC (and its been 4+ years since I did this exact thing for a
customer), I had to crfeate a widget to render some things for the
layout we added..

 

I essentially started with the code for the Grid Layout, and extended it
from there

 

Scott

 

From: interest-bounces+scott.bloom=onshorecs.com at qt-project.org
[mailto:interest-bounces+scott.bloom=onshorecs.com at qt-project.org] On
Behalf Of Jason H
Sent: Wednesday, November 30, 2011 2:44 PM
To: Andreas Pakulat; interest at qt-project.org
Subject: Re: [Interest] Adding layouts to designer?

 

Thanks Andreas, but what if I wanted to reject reality and substitute my
own? What would my options be? For a hypothetical example, say I wanted
to add a"FlowLayout"?

 

I'm thinking an inelegant but possibly functional solution would to be
to create a FlowWidget which has the FlowLayout set by default. Would
that work or not? 

 

 

 

 

________________________________

From: Andreas Pakulat <apaku at gmx.de>
To: interest at qt-project.org 
Sent: Wednesday, November 30, 2011 5:36 PM
Subject: Re: [Interest] Adding layouts to designer?

On 30.11.11 13:44:07, Jason H wrote:
> I want to add some additional layouts to Designer (yes, that dinosaur)
I have a widget library I am working on, and I have a special layout
that I need to add. Now the plugin only works for those things which can
return a QWidget*, but QLayouts are not based on QWidget. So how do I
add my special layout to Designer?
> 
> I'm stumped here.

Thats because you can't. Designer is not universally extendable as you'd
like it to be. It does not even support all kinds of qwidgets since it
has quite some special code for handling some of the standard Qt widgets
(QMainWindow, Q(Table|Tree|List)Widget, but others too IIRC).

Andreas

_______________________________________________
Interest mailing list
Interest at qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest



-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20111130/56bff33c/attachment.html>


More information about the Interest mailing list