Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

Custom widget [SOLVED]



  • Hi guys,
    I'd like to ask you what is the easiest way, or what ways exist, how to use custom widget in designer in Qt Creator. By custom widget I mean subclassed QWidget (for example form with several buttons). I am able to use it in code, but I don't know how to use it via designer. Thanks for advice in advance.



  • There is two way for this:

    1. Promote your widget in qtdesigner. put a simple widget in form and right click on it and select promote
    2. Write a plugin for that (there is a example in qt for that)


  • The "promote" option Mostafa mentioned is very easy to use.



  • Thanks a lot guys, ithis is what I looked for. This thread could be marked as SOLVED.


Log in to reply