carp wrote:In Qt Designer, you do not need to know beforehand, how your widgets should be arranged. You simply place all the widgets on the canvas, without specifying any layout manager.
carp wrote:I think this approach is easier than being forced into the behavior of the layout managers from the beginning on (especially for prototyping, where you don't know exactly how the result should look like).
carp wrote:So much for the layouting philosophy, the only real problem I have is that the "snapshotting" of the widgets is rather slow and not always successful on X11/KDE. It usually takes a few seconds before the view shows the updated widgets -- and sometimes it only shows garbage.
Multiple layout managers exist because there is no such thing as a perfect layout manager that will satisfy every user or use case. The goal of Designer is to support all of the Swing and SWT layout managers and make using them as easy as possible. We specifically don't pass judgement on which layout manager is the "best" one to use.
I think your familiarity with this particular tool is coloring your perceptions a bit.
I reviewed the material at the links you provided, and I disagree with your implied assertion that you don't need to understand the layout manager that is used. Qt Designer seems to be using a layout manager that is very similar to the Swing BoxLayout manager. That's a fine layout manager, but you still need to understand how it works to get decent results out of it (e.g., how and when to group widgets, where to use spacers, etc). It is not a magic black box.
It sounds like you want to use more of a free form approach and then apply constraints when you have everything positioned the way you want. The best layout manager for that is the SWT FormLayout manager. You can lay widgets out anywhere you want in an X-Y grid. Once you are done, you can apply various constraints to control the widget's resizing behavior (e.g., lock the OK and Cancel buttons to the lower-right corner, have a list box grow to fill any extra space, etc.).
In that case, you should probably turn on Draft Mode (on the Designer > General preference page).
afalck wrote:It turns out that Designer had added calls to setBounds when I was placing the components BEFORE setting the layout manager... when I added the layout, it should have removed the setBounds.
Users browsing this forum: No registered users and 1 guest