Results 1 to 10 of 10

Thread: QVariant types support for custom properties

  1. #1
    Join Date
    Jan 2006
    Posts
    32
    Thanks
    1
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11

    Default QVariant types support for custom properties

    Hi there,

    I'm writing a custom plugin for the designer and I need QList properties, but at the moment not all the QVariant type are handled in QAbstractFormBuilder::createProperty (tools/designer/src/lib/uilib/abstractformbuilder.cpp:1247): when can we expect a full implementation of QVariant types? maybe in Qt 4.1.1?

  2. #2
    Join Date
    Jan 2006
    Location
    Frankfurt
    Posts
    500
    Thanks
    1
    Thanked 52 Times in 52 Posts
    Platforms
    MacOS X Unix/X11

    Default Re: QVariant types support for custom properties

    What exactly do you want to do? Can you give us an example of one of the properties you plan?
    It's nice to be important but it's more important to be nice.

  3. #3
    Join Date
    Jan 2006
    Posts
    32
    Thanks
    1
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11

    Default Re: QVariant types support for custom properties

    Quote Originally Posted by axeljaeger
    What exactly do you want to do? Can you give us an example of one of the properties you plan?
    I have to store a variable number of QColor and QString values, so I defined the properties as QVariant, and internally represent them as QList<QVariant>, but when the designer is going to save them it says that writing properties of type QVariant::List is not implemented yet (from within the method I mentioned in the first post)

  4. #4
    Join Date
    Jan 2006
    Location
    Frankfurt
    Posts
    500
    Thanks
    1
    Thanked 52 Times in 52 Posts
    Platforms
    MacOS X Unix/X11

    Default Re: QVariant types support for custom properties

    I think this is not (yet) possible with Designer.
    It's nice to be important but it's more important to be nice.

  5. #5
    Join Date
    Jan 2006
    Posts
    32
    Thanks
    1
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11

    Default Re: QVariant types support for custom properties

    Quote Originally Posted by axeljaeger
    I think this is not (yet) possible with Designer.
    I know that it's not possible, I was wondering when it will be. I wrote my own configuration window for my widget and I would like to save QList properties in the ui file, but Designer says that QList are not implemented yet.

  6. #6
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,364
    Thanks
    3
    Thanked 5,013 Times in 4,791 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: QVariant types support for custom properties

    Do you have to implement that through properties?

  7. #7
    Join Date
    Jan 2006
    Posts
    32
    Thanks
    1
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11

    Default Re: QVariant types support for custom properties

    Quote Originally Posted by wysota
    Do you have to implement that through properties?
    Yes, because I want to store them in the ui

  8. #8
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,364
    Thanks
    3
    Thanked 5,013 Times in 4,791 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: QVariant types support for custom properties

    I'm not familiar with Designer 4 mechanisms regarding setting custom ways of defining properties, but with Designer 3 one could for example edit QListView columns using a built-in editor and this information was saved in the ui too. Can't you do it this way? Or does it involve using these listed properties too?

  9. #9
    Join Date
    Jan 2006
    Posts
    32
    Thanks
    1
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11

    Default Re: QVariant types support for custom properties

    Quote Originally Posted by wysota
    I'm not familiar with Designer 4 mechanisms regarding setting custom ways of defining properties, but with Designer 3 one could for example edit QListView columns using a built-in editor and this information was saved in the ui too. Can't you do it this way? Or does it involve using these listed properties too?
    I don't know how the designer saves the data in this case, if I had some time I'd take a look at the code (since the documentation isn't helping me)

  10. #10
    Join Date
    Jan 2006
    Posts
    32
    Thanks
    1
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11

    Default Re: QVariant types support for custom properties

    for the moment I solved the problem joining data in a QString, but I think this feature should definitely be implemented.

Similar Threads

  1. Qt 4.4.3 commercial on Kubuntu 8.10
    By Micawber in forum Installation and Deployment
    Replies: 5
    Last Post: 17th February 2010, 02:02
  2. Qt-4.4.0 installation error in linux
    By babu198649 in forum Installation and Deployment
    Replies: 4
    Last Post: 27th May 2008, 15:35

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.