Results 1 to 4 of 4

Thread: line edit mask problem

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #3
    Join Date
    Oct 2009
    Posts
    105
    Thanked 4 Times in 2 Posts
    Qt products
    Qt/Embedded
    Platforms
    Unix/X11

    Default Re: line edit mask problem

    Quote Originally Posted by moosa View Post
    You used QTextEdit where you should use QLineEdit. QLineEdit is better for this kind of input.
    The code you need is:
    Qt Code:
    1. ui->lineEdit->setInputMask("000.000.000.000;_");
    To copy to clipboard, switch view to plain text mode 
    All of this is documented in QT. Read about it in the documentation of QLineEdit.
    Oh I'm sorry actually i've used a line edit in my project. but while disaplyaing that line edit i need to display the "." at equal distance. Herewith i've attached the sample code again Please check this. and tell me what should i changed. And also i dont want to show "_" in inputmask. I need empty space.



    Thank you .
    Attached Files Attached Files
    Last edited by sudhansu; 31st March 2010 at 07:13.

Similar Threads

  1. QTableView line edit clears the text on edit
    By PlasticJesus in forum Qt Programming
    Replies: 5
    Last Post: 14th March 2015, 19:06
  2. Assert problem in line edit
    By grsandeep85 in forum Qt Programming
    Replies: 19
    Last Post: 28th July 2009, 05:30
  3. Problem updating Line edit from a thread
    By raghvendramisra in forum Qt Programming
    Replies: 5
    Last Post: 3rd December 2007, 05:05
  4. Line Edit Controll problem
    By mansoorulhaq in forum Qt Programming
    Replies: 5
    Last Post: 31st October 2007, 08:33
  5. mask line edit
    By steg90 in forum Qt Programming
    Replies: 4
    Last Post: 3rd July 2007, 10:27

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.