Results 1 to 3 of 3

Thread: Highlight open & close brackets in QTextEdit

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Jun 2015
    Thanked 14 Times in 14 Posts
    Qt products
    Qt4 Qt5
    Unix/X11 Windows

    Default Highlight open & close brackets in QTextEdit


    I want to highlight open and close braces in QTextEdit exactly how Qt creator does when we code.
    when I move my cursor to open brace "(" the respective close brace ")" should be highlight and opposite also should work.

    I am interested to know is there a way available in Qt already for this behavior or do we need to implement our own algorithm.

    Thanks in advance :-)
    Last edited by prasad_N; 31st July 2015 at 20:14.
    Thanks :-)

Similar Threads

  1. Forcing a QTextEdit to highlight
    By high_flyer in forum Qt Programming
    Replies: 2
    Last Post: 25th November 2012, 23:45
  2. Open or close?
    By isaias1984 in forum Newbie
    Replies: 3
    Last Post: 12th July 2011, 12:31
  3. QTextEdit contents changed highlight the color
    By sujan.dasmahapatra in forum Qt Programming
    Replies: 3
    Last Post: 8th June 2011, 17:31
  4. highlight in QTextEdit
    By ubuntudevelop78 in forum Qt Programming
    Replies: 1
    Last Post: 27th November 2009, 00:22
  5. How to Open & Close a Widget ?!!
    By Fatla in forum Qt Programming
    Replies: 6
    Last Post: 13th June 2008, 20:39

Tags for this Thread


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.