Results 1 to 10 of 10

Thread: QDial in Qt4.6 is without needle?

  1. #1
    Join Date
    Apr 2010
    Posts
    23
    Thanks
    1
    Qt products
    Qt4 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Default QDial in Qt4.6 is without needle?

    Hello,,
    how can i get Qdial widget with the needle instead of a notch as in http://doc.trolltech.com/4.3/widgets-sliders.html ?

    Thanks

  2. #2
    Join Date
    Jan 2006
    Location
    Belgium
    Posts
    1,938
    Thanked 268 Times in 268 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows
    Wiki edits
    20

    Default Re: QDial in Qt4.6 is without needle?

    Not sure what you mean, but maybe this?
    http://doc.qt.nokia.com/4.6/qdial.ht...esVisible-prop

  3. #3
    Join Date
    Apr 2010
    Posts
    23
    Thanks
    1
    Qt products
    Qt4 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Default Re: QDial in Qt4.6 is without needle?

    Quote Originally Posted by tbscope View Post
    Not sure what you mean, but maybe this?
    http://doc.qt.nokia.com/4.6/qdial.ht...esVisible-prop
    hello,

    the link u sent me displays the Qdial with a needle as a pointer.
    but uf u try to use QDial you will get

    Uploaded with ImageShack.us

  4. #4
    Join Date
    Jan 2006
    Location
    Belgium
    Posts
    1,938
    Thanked 268 Times in 268 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows
    Wiki edits
    20

    Default Re: QDial in Qt4.6 is without needle?

    That's controlled by the style.

  5. #5
    Join Date
    Apr 2010
    Posts
    23
    Thanks
    1
    Qt products
    Qt4 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Default Re: QDial in Qt4.6 is without needle?

    Ok,,,is there a way to change it to needle style??
    i am after something like speedometer, any ideas where/how to get/do it??

    Thnaks

  6. #6
    Join Date
    Apr 2010
    Posts
    23
    Thanks
    1
    Qt products
    Qt4 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Default Re: QDial in Qt4.6 is without needle?

    any hints for speedometer style widget???
    thanks

  7. #7
    Join Date
    Jan 2008
    Posts
    5
    Thanks
    1
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Unhappy Re: QDial in Qt4.6 is without needle?

    Hi
    I have been looking to change the QDial as well. But according to this post about the appearance change, it can not be done (at the moment)
    http://labs.trolltech.com/blogs/2009...ace-for-qdial/

    Cheers

  8. #8
    Join Date
    Oct 2006
    Location
    New Delhi, India
    Posts
    2,467
    Thanks
    8
    Thanked 334 Times in 317 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: QDial in Qt4.6 is without needle?

    You can look into previous code of Qt and copy the code.
    You will need to override the paintEvent.

  9. #9
    Join Date
    Feb 2008
    Posts
    491
    Thanks
    12
    Thanked 142 Times in 135 Posts
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11

    Default Re: QDial in Qt4.6 is without needle?

    From the linked blog:
    Old styles like motif and windows classic will still get the old looks because that’s what they are… old
    On Linux, use:
    Qt Code:
    1. QDial::setStyle(new QMotifStyle)
    To copy to clipboard, switch view to plain text mode 

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

    Default Re: QDial in Qt4.6 is without needle?

    QDial is more of an input widget rather than a display widget.
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


Similar Threads

  1. needle diagram
    By darksaga in forum Qt Programming
    Replies: 4
    Last Post: 31st March 2008, 11:01
  2. Can I Add two needle for QwtDial
    By validator in forum Qwt
    Replies: 4
    Last Post: 14th February 2008, 08:57
  3. How can I draw needle for dial in Qwt
    By validator in forum Qwt
    Replies: 6
    Last Post: 3rd February 2008, 20:27
  4. How can I resize needle of QDial
    By validator in forum Qt Tools
    Replies: 1
    Last Post: 1st February 2008, 10:10
  5. setting needle size in qwtCompass
    By user in forum Qwt
    Replies: 4
    Last Post: 22nd July 2007, 23:40

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.