Results 1 to 3 of 3

Thread: QSpinBox question...

  1. #1
    Join Date
    Aug 2006
    Location
    troy, new york
    Posts
    24
    Thanks
    4
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11

    Default QSpinBox question...

    can this be subclassed to display text (ie QStringList)? the reason i ask is that it i would rather use this for an app than something like QComboBox or QInputDialog for special reasons. thanx.

  2. #2
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    5,372
    Thanks
    28
    Thanked 976 Times in 912 Posts
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Default Re: QSpinBox question...

    All you have to do is to reimplement QSpinBox::valueFromText() and QSpinBox::textFromValue().

  3. #3
    Join Date
    Aug 2006
    Location
    troy, new york
    Posts
    24
    Thanks
    4
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11

    Default Re: QSpinBox question...

    thanx, that will save some time... i'm trying to finish a painting so i can't play around today.

Similar Threads

  1. QTextEdit simple question
    By Marcopolo in forum Qt Tools
    Replies: 4
    Last Post: 11th October 2007, 00:01
  2. float value to Qspinbox
    By nErnie in forum Qt Programming
    Replies: 6
    Last Post: 17th October 2006, 08:16
  3. QThread exit()/quit() question
    By TheKedge in forum Qt Programming
    Replies: 1
    Last Post: 28th August 2006, 14:38
  4. simple thread layout question
    By mhoover in forum Qt Programming
    Replies: 1
    Last Post: 12th August 2006, 11:02
  5. Problem reimplementing QSpinBox in a custom widget
    By hvengel in forum Qt Programming
    Replies: 1
    Last Post: 30th March 2006, 08:12

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.