Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Hand Coded GUI Versus Qt Designer GUI [closed]

People also ask

What is difference between Qt Designer and Qt Creator?

Qt Creator is Qt's IDE. You don't have to use it, but it greatly simplifies Qt development. Qt Designer is a graphical tool that lets you build QWidget GUIs. Qt Quick Designer is similar, but for building QML GUIs.

Can you use Qt Designer with Pyside?

Qt is a cross-platform GUI toolkit that scales from mobile interfaces to full blown desktop applications. You can access them using a variety of different programming languages ranging from compiled applications like C++ to scripted languages like Python.

What is Qt GUI programming?

Qt is a cross-platform application and graphical user interface (GUI) framework, a toolkit, that is used for developing software that can be run on different hardware platforms and operating systems.

Is Qt Designer part of pyqt5?

The PyQt installer comes with a GUI builder tool called Qt Designer. Using its simple drag and drop interface, a GUI interface can be quickly built without having to write the code. It is however, not an IDE such as Visual Studio.


Our experience with Designer started in Qt3.

Qt3

At that point, Designer was useful mainly to generate code that you would then compile into your application. We started using for that purpose but with all generated code, once you edit it, you can no longer go back and regenerate it without losing your edits. We ended up just taking the generated code and doing everything by hand henceforth.

Qt4

Qt4 has improved on Designer significantly. No longer does it only generate code, but you can dynamically load in your Designer files (in xml) and dynamically connect them to the running objects in your program -- no generated code however, you do have to name the items in Designer and stick with the names to not break your code.

My assessment is that it's nowhere near as useful as Interface Builder on Mac OS X, but at this point, I could see using the Designer files directly in a program.

We haven't moved back to Designer since Qt3, but still use it to prototype, and debug layouts.

For your problems:

  1. You could probably get away with using the standard dialogs that Qt offers. QInputDialog or if you subclass QDialog, make sure to use QButtonDialogBox to make sure your buttons have the proper platform-layout.

  2. You could probably do something more limited like xPad with limited Designer functionality.

  3. I wouldn't think you could write something like OpenOffice solely with Designer but maybe that's not the point.

I'd use Designer as another tool, just like your text editor. Once you find the limitations, try a different tool for that new problem. I totally agree with Steve S that one advantage of Designer is that someone else who's not a programmer can do the layout.


In my experience with Qt Designer and other toolkits/UI-tools:

  • UI tools speed up the work.
  • UI tools make it easier to tweak the layout later.
  • UI tools make it easier/possible for non-programmers to work on the UI design.

Complexity can often be dealt with in a UI tool by breaking the design into multiple UI files. Include small logical groups of components in each file and treat each group as a single widget that is used to build the complete UI. Qt Designer's concept of promoted widgets can help with this.

I haven't found that the scale of the project makes any difference. Your experience may vary.

The files created with UI tools (I guess you could write them by hand if you really wanted to) can often be dynamically loaded at run-time (Qt and GTK+ both provide this feature). This means that you can make layout changes and test them without recompiling.

Ultimately, I think both raw code and UI tools can be effective. It probably depends a lot on the environment, the toolkit/UI-tool, and of course personal preference. I like UI tools because they get me up and running fast and allow easy changes later.


The organisation I work for has ported its GUI application to Qt several years ago. I think there are several aspects that are worth mentioning:

  • Working with Qt Designer, at least at that point, was not a realistic option: there were too many features that couldn't be done with Qt Designer;
  • Conventions and structure that had to be preserved prevented the use of Qt Designer;
  • Once you've started without Designer, it is probably difficult to return to it;
  • the most important aspect, though, was that the programmers were very much used to programming using vi or emacs, rather than using a GUI IDE.

My own experience, which goes back approx. 4 years, using Qt3.3, is that dynamic behavior in dialogs was not possible to realise in Designer.


Just to say I've written and maintained complex GUIs in Qt without using Qt Designer -- not because I don't like Qt Designer, but because I never got around to working that way.

It's partly a matter of style and where you're coming from: when I started on Qt, I'd had horrible experiences of Dreamweaver and Frontpage and other visual HTML tools,and far preferred writing code with HomeSite and resorting to Photoshop for tricky layout problems.

There's a danger with visual code IDEs that you try to keep within the visual tools, but end up having to tweak code as well -- in ways that aren't well understood.

Learning iPhone development, for example, I've found it frustrating to hit 'magic' visual stuff ('drag from the empty circle in the Connections inspector to the object in the Interface Builder window...') that would be simpler (for me) to understand in plain old code.

Good luck with Qt -- it's a great toolkit, however you use it, and Qt Creator looks like being a great IDE.