Important: Please read the Qt Code of Conduct -

Custom Widget in Qt Embedded can't compile correctly

  • I made a widget in Linux and it works fine in it.

    but when i try to use it in my ARM board

    compile error says it can't find QtDesigner/QDesignerExportWidget

    do i have to add some configure option to use Custom Widget in Embedded condition?

  • The class you are looking for is in the QtDesigner library which is not built by default if you are cross compiling. So you probably need to manually compile that module if that is what you really want.

    In the meantime though, why are you using that module on the device? As far as I know, this module is only used when you want your widget to be loaded into Qt Designer (the app). Have you cross-compiled Qt Designer for the ARM board? If not, then it is probably just your widget's .h and .cpp that you want to compile here and not the whole designer plugin.

  • Thank you for your reply
    I was doing below to make my "Custom Widget"

    to make a Custom Widget's for QtDesigner
    I used below in my CustomWidget's XXX.h
    #include (QtDesigner/QDesignerExportWidget)
    class QDESIGNER_WIDGET_EXPORT WidgetName : public QWidget

    the QtDesigner/QDesignerExportWidget include & QDESIGNER_WIDGET_EXPORT caused the error when I try to use XXX.h & XXX.cpp in my ARM board's build

    anyway I made normal build with my Linux pc for Qt Creator's Design work and after that
    I just removed those two stuff from my .h file

    after that "there is NO BUILD ERROR" but can't understand why they made it this way to create Custom Widget & Need of Customizing it for Embedded Build

    Can Qt Make "Custom Widget Guide" in Qt Homepage

    1. more Easy To Understand (there is no guide about "how to make Custom Widget Project with Qt Creator and how to use it in a Right way) to make .So and other Stuff to Make Custom Widgets
    2. and include how to use .ui in Custom Widget? (not just .h & .c. I wan't to use .ui to create my Custom Widget more easy)
    3. Make some Note in "Custom Widget Guide in Qt Homepage" about Difference between Normal Qt Creator's Build & Qt Embedded's Build about QtDesigner/QDesignerExportWidget for future Qt Programmers who might do the same mistake like me

  • I also meet the same problem, the reason is Qt for iOS does not include QtDesigner module, and it cannot find the header files. Cannot make it work until now, maybe we can create a individual project for iOS (which does not include plugin things), does anyone have a better solution?

Log in to reply