Skip to content
  • 0 Votes
    2 Posts
    111 Views
    Pl45m4P

    @Joe-von-Habsburg said in Add ready widget into widget:

    I am leaving an example

    QtCreator Preferences is your example?!
    So you want something similar?!

    You could dig into QtCreator source code and check out how it's done.
    For this I would use QToolButton to populate the "menu bar" on the left and a QStackedWidget to display the content pages on the right. Actually the QStackedWidget is more like centered, as the whole window you see is divided into two sections (~15% / ~85%) for the menu and the "rest" (the QStackedWidget for the content).

    Is it Qt designer form class (.cpp && .h && .ui)?

    The "right side" is the content widget... In case of QtCreator a custom QWidget containing a QTabWidget for the Text Editor settings among many other things.
    The parent of all this is probably a QStackedWidget as I presumed above.

    What approach (with or without Designer Form) you pick to implement this has nothing to do with how it works.
    Both ways are possible.

  • 0 Votes
    3 Posts
    178 Views
    Pl45m4P

    @silvio

    Show the code please.

    Any chance that the ui file is not used at all or the project overwrites the ui file layout by setting a new one using the widget's code?!

  • 0 Votes
    5 Posts
    2k Views
    D

    dc4d228b-0604-4860-ba95-ae4541f57518-image.png

    am having the same issue .
    if I create a new project then select the Qt version 6 and then run the default code it produces no output .Ho do i fix fix this ?
    On the other hand if i start a new project and select the target Qt as Qt5 , it runs and produces an output..
    so what could be the issue
    da7bf813-5f34-42ca-abfb-40fd17527ea9-image.png