Results 1 to 6 of 6

Thread: Embed Qt Designer

  1. #1

    Question Embed Qt Designer

    How can I embed Qt Designer in my application?
    Somebody have some examples?
    There are license problems?
    tnks

  2. #2
    Join Date
    Jan 2006
    Location
    Munich, Germany
    Posts
    4,714
    Thanks
    21
    Thanked 418 Times in 411 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Default Re: Embed Qt Designer

    Which functionality from designer do you need?
    embedding the whole designer in another application makes little sense - just start it with QProcess.
    But you can use various functionalities in your own application.
    Explain more what you are after.
    ==========================signature=============== ==================
    S.O.L.I.D principles (use them!):
    https://en.wikipedia.org/wiki/SOLID_...iented_design)

    Do you write clean code? - if you are TDD'ing then maybe, if not, your not writing clean code.

  3. #3

    Default Re: Embed Qt Designer

    I think I follow your solution, but ....
    i needed to customizing QtDesigner inhibiting widget from the list "widget box" type:
    -View-Item (model-based)
    -Widget-item

    any ideas?

  4. #4
    Join Date
    Jan 2006
    Location
    Munich, Germany
    Posts
    4,714
    Thanks
    21
    Thanked 418 Times in 411 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Default Re: Embed Qt Designer

    Well, if you want designer as designer, but modified, then you have to modify designer.
    You can the code - so you will have to dive in and change what you need in the designer code it self.
    ==========================signature=============== ==================
    S.O.L.I.D principles (use them!):
    https://en.wikipedia.org/wiki/SOLID_...iented_design)

    Do you write clean code? - if you are TDD'ing then maybe, if not, your not writing clean code.

  5. #5
    Join Date
    Sep 2009
    Location
    UK
    Posts
    2,447
    Thanks
    6
    Thanked 348 Times in 333 Posts
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: Embed Qt Designer

    Qt Designer is open source so you can embed as much or as little as you want in your own code, just ensure you abide by the license and publish your modified source code some where.

  6. #6

    Default Re: Embed Qt Designer

    I'm trying to create a fake customplugin to access QtDesigner istance.
    I'm editing "taskmenuextension" project to redefine:
    Qt Code:
    1. void TicTacToePlugin::initialize(QDesignerFormEditorInterface *formEditor)
    To copy to clipboard, switch view to plain text mode 

    QDesignerFormEditorInterface is a interface to access at WidgetBox(QDesignerWidgetBoxInterface)

    Qt Code:
    1. void TicTacToePlugin::initialize(QDesignerFormEditorInterface *formEditor)
    2. {
    3. widgetBox = formEditor->widgetBox();
    4. if (widgetBox) {
    5. qDebug()<<"Ok widgetBox";
    6. } else {
    7. qDebug()<<"NO widgetBox";
    8. }
    9. }
    To copy to clipboard, switch view to plain text mode 
    I followed these steps:
    - i have compiled "taskmenuextension" project (generating libtaskmenuextension.so)
    - copy libtaskmenuextension.so in QtDesigner pluginDir
    - in command line type
    emmanuelgranatello@isi-82:~$ designer
    NO widgetBox

    The widgetBox is equal to NULL because the main window (and consequently the WidgetBox) is instantiated after loading the plugin

    Anyone knows how to use QDesignerWidgetBoxInterface?


    Added after 52 minutes:


    I found (in sourcecode) the xml file that populates the Widgetbox's qtdesignr.

    the folder is:
    Qt_sourcecode_4.7.1/tools/designer/src/components/widgetbox
    xml file:
    widgetbox.xml

    This file is included as a resource(.qrc) in the project.
    Last edited by emmynet; 21st April 2011 at 14:52.

Similar Threads

  1. Embed VNC Viewer
    By NoRulez in forum Qt Programming
    Replies: 4
    Last Post: 15th March 2021, 16:03
  2. Is it possible to embed html with js into QwebKit
    By umen in forum Qt Programming
    Replies: 0
    Last Post: 24th October 2010, 06:56
  3. Embed QColorDialog as a widget
    By totem in forum Qt Programming
    Replies: 2
    Last Post: 23rd January 2010, 00:40
  4. Embed SQLite driver
    By NoRulez in forum Qt Programming
    Replies: 2
    Last Post: 7th October 2009, 09:41
  5. Embed external application
    By zeldaknight in forum Qt Programming
    Replies: 0
    Last Post: 21st August 2009, 00:34

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.