Results 1 to 4 of 4

Thread: Editable QLCDNumber

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Jun 2013
    Posts
    3
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Question Editable QLCDNumber

    Hi guys

    I'd like to hear you suggestions to the following problem.

    I need an editable lcd editor in my GUI. I mean that I display some value in it and allow a user to edit it in a clickable way. For example, the current value is 123. A user clicks to the area of digit 2 and press some digit key on his keyboard to modify this digit.

    The quick solution spinning in my mind is to implement a QButton over the QLCDNumber widget but it seems to be a dirty hack.

    Are there any tested solutions for this case? If anyone could share an example I'd be highly appreciated. But anyhow I need a concept to start.

    My environment : Qt4.7, no QML.

    BR,
    Dmitry

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

    Default Re: Editable QLCDNumber

    Subclass QLCDNumber, activate focus and reimplement key events.
    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. Modelling a QLCDNumber in QML
    By lixo1 in forum Qt Quick
    Replies: 1
    Last Post: 24th August 2011, 14:19
  2. QLCDNumber problem
    By ale301168 in forum Newbie
    Replies: 1
    Last Post: 11th November 2009, 21:16
  3. QLCDNumber display
    By jhearon in forum Qt Programming
    Replies: 0
    Last Post: 26th October 2008, 23:53
  4. QLCDNumber justify
    By davisjamesf in forum Qt Programming
    Replies: 1
    Last Post: 5th July 2007, 10:02
  5. QLabel and QLCDNumber
    By mickey in forum Newbie
    Replies: 5
    Last Post: 17th 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
  •  
Qt is a trademark of The Qt Company.