Results 1 to 3 of 3

Thread: uppercase letters in a QTextEdit

  1. #1
    Join Date
    Jul 2013
    Posts
    2
    Qt products
    Qt4
    Platforms
    Windows

    Default uppercase letters in a QTextEdit

    I am designing a notepad application and I want to change the case of the text in QTextEdit to uppercase.
    I tried
    Qt Code:
    1. if (name == "Uppercase") {
    2. textEdit->setFont(Qt::Alluppercase);
    3. }
    To copy to clipboard, switch view to plain text mode 

    but it doesn't work. Which property can I use?

  2. #2
    Join Date
    Feb 2013
    Location
    India
    Posts
    153
    Thanks
    27
    Thanked 18 Times in 18 Posts
    Qt products
    Qt4 Qt5 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows Symbian S60 Maemo/MeeGo

    Default Re: uppercase letters in a QTextEdit

    You can use "setInputMethod" method of QTextEdit and assign it "Qt::ImhPreferUppercase"

    AND IT IS SOLVED.

    CHEERS

  3. #3
    Join Date
    Jul 2013
    Posts
    2
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: uppercase letters in a QTextEdit

    setInputMethod does not exist. I tried setInputMethodHints but no result
    Last edited by annitaz; 6th July 2013 at 10:02.

Similar Threads

  1. QregExp: matching accented letters
    By bred in forum Qt Programming
    Replies: 0
    Last Post: 4th January 2011, 11:48
  2. A collection of letters and numbers
    By NewLegend in forum Qt Programming
    Replies: 8
    Last Post: 8th September 2010, 20:44
  3. Replies: 10
    Last Post: 12th February 2009, 08:23
  4. QTextEdit UpperCase
    By ederbs in forum Qt Programming
    Replies: 2
    Last Post: 18th November 2006, 15:41
  5. Reading umlaut letters from sqlite database
    By Djony in forum Qt Programming
    Replies: 11
    Last Post: 17th November 2006, 11:30

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.