Results 1 to 4 of 4

Thread: Showing the output from cmake on my widget

  1. #1
    Join Date
    Mar 2006
    Location
    Moldova
    Posts
    12
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Question Showing the output from cmake on my widget

    Hi, i have a QListWidget that prints the output from a cmake process. But cmake prints its output on a terminal with colors .. How can i get those colors ?? Is there a way to do that ?? Thanks ...
    All Rights Reserved ...

  2. #2
    Join Date
    Feb 2006
    Location
    Romania
    Posts
    2,744
    Thanks
    8
    Thanked 541 Times in 521 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Showing the output from cmake on my widget


    Tough question.
    Better I tell you how I would do it.
    - I'd examine very carefully which color represents what in the output ( or better yet look at the cmake sources and analyze the output section - more likely to understand everything )
    - Get the output
    - Parse it and organize it in color categories ( I assume cmake has a well behaved output structure )
    - The use style sheets or whatever to draw the highlighted text in your widget ( or use a QTextEdit and format the text appropriately ).

    Not easy, but could work.

  3. #3
    Join Date
    Mar 2006
    Location
    Moldova
    Posts
    12
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Showing the output from cmake on my widget

    This way i know but, anyway, thanks for reply ...

    P.S. Doar konsole (sau orice terminal) arata cumva culorile .. mi'i lene sa citesc sursele ...
    All Rights Reserved ...

  4. #4
    Join Date
    Feb 2006
    Location
    Romania
    Posts
    2,744
    Thanks
    8
    Thanked 541 Times in 521 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Showing the output from cmake on my widget


    I doubt there is any other way.
    After all, the cmake output is just text. It is your responsibility to reformat it, etc.

    Regards

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.