Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. TextBox in Output pane of Qt creator
Forum Update on Monday, May 27th 2025

TextBox in Output pane of Qt creator

Scheduled Pinned Locked Moved Unsolved General and Desktop
12 Posts 4 Posters 2.3k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • V Offline
    V Offline
    Veepee
    wrote on 18 Jan 2018, 06:29 last edited by
    #1

    I have a plugin which prints the output data read from a perl script in the General messages output pane. I want to make each statement from the output data clickable to parse the clicked output and open the file if valid.

    To achieve this, I am trying to redirect each line to a textview/QLabel in Qt , to handle click events of it. Is it possible to create a label in output pane to display the texts in it from the plugin ?

    J 1 Reply Last reply 18 Jan 2018, 09:01
    0
    • V Veepee
      18 Jan 2018, 06:29

      I have a plugin which prints the output data read from a perl script in the General messages output pane. I want to make each statement from the output data clickable to parse the clicked output and open the file if valid.

      To achieve this, I am trying to redirect each line to a textview/QLabel in Qt , to handle click events of it. Is it possible to create a label in output pane to display the texts in it from the plugin ?

      J Offline
      J Offline
      JonB
      wrote on 18 Jan 2018, 09:01 last edited by
      #2

      @Veepee
      I am a not a Qt expert. I don't know whether it's possible to do this in Qt Creator's Output window. But what sort of order of number of lines are you expecting? Because 1,000 lines => 1,000 separate QLabel widgets sounds non-scalable to me...

      V 1 Reply Last reply 18 Jan 2018, 11:52
      0
      • J JonB
        18 Jan 2018, 09:01

        @Veepee
        I am a not a Qt expert. I don't know whether it's possible to do this in Qt Creator's Output window. But what sort of order of number of lines are you expecting? Because 1,000 lines => 1,000 separate QLabel widgets sounds non-scalable to me...

        V Offline
        V Offline
        Veepee
        wrote on 18 Jan 2018, 11:52 last edited by
        #3

        @JonB Yes, true. Definitely this doesnt look to be a good option to me either :| , but couldn't identify any other feasible solution yet.

        1 Reply Last reply
        0
        • M Offline
          M Offline
          mrjj
          Lifetime Qt Champion
          wrote on 18 Jan 2018, 12:07 last edited by
          #4

          Hi
          You mean something like what Todo plugin does ?
          http://katecpp.github.io/qtcreator-todo/

          V 1 Reply Last reply 19 Jan 2018, 07:21
          1
          • M mrjj
            18 Jan 2018, 12:07

            Hi
            You mean something like what Todo plugin does ?
            http://katecpp.github.io/qtcreator-todo/

            V Offline
            V Offline
            Veepee
            wrote on 19 Jan 2018, 07:21 last edited by
            #5

            @mrjj Exactly. Thanks a lot for this.
            But this looks to identify the comments section from current document. The difference is I want to filter the warning/error output from General messages pane .

            M 1 Reply Last reply 19 Jan 2018, 07:26
            0
            • V Veepee
              19 Jan 2018, 07:21

              @mrjj Exactly. Thanks a lot for this.
              But this looks to identify the comments section from current document. The difference is I want to filter the warning/error output from General messages pane .

              M Offline
              M Offline
              mrjj
              Lifetime Qt Champion
              wrote on 19 Jan 2018, 07:26 last edited by
              #6

              @Veepee

              well i was thinking you altered the the todo sample and simple output
              to that pane instead (from perl plugin) ?

              V 1 Reply Last reply 19 Jan 2018, 09:14
              0
              • A Offline
                A Offline
                aha_1980
                Lifetime Qt Champion
                wrote on 19 Jan 2018, 09:06 last edited by
                #7

                @Veepee

                What happened to your other thread? https://forum.qt.io/topic/86282/get-click-events-from-output-pane-of-qt-creator/5

                As said there, the General Messages pane is currently missing that function, but it is there in Compile output e.g.

                Qt has to stay free or it will die.

                1 Reply Last reply
                0
                • V Offline
                  V Offline
                  Veepee
                  wrote on 19 Jan 2018, 09:11 last edited by
                  #8

                  @aha_1980 I am open to redirect my output to Compile output window as well if this supports the link functionality.. But I see Core::MessageManager::write only redirects to General messages output pane. Do we have any similar interface to write to Compile output window ?

                  1 Reply Last reply
                  0
                  • M mrjj
                    19 Jan 2018, 07:26

                    @Veepee

                    well i was thinking you altered the the todo sample and simple output
                    to that pane instead (from perl plugin) ?

                    V Offline
                    V Offline
                    Veepee
                    wrote on 19 Jan 2018, 09:14 last edited by
                    #9

                    @mrjj No, I have not altered any. Its a plugin that reads the data from perl and dumps to output pane using MessageManager::write

                    M 1 Reply Last reply 19 Jan 2018, 09:23
                    0
                    • V Veepee
                      19 Jan 2018, 09:14

                      @mrjj No, I have not altered any. Its a plugin that reads the data from perl and dumps to output pane using MessageManager::write

                      M Offline
                      M Offline
                      mrjj
                      Lifetime Qt Champion
                      wrote on 19 Jan 2018, 09:23 last edited by
                      #10

                      @Veepee

                      ok. but if you already have a Creator plugin why not make your own pane ( like todo)
                      and just output there ?

                      V 1 Reply Last reply 19 Jan 2018, 09:26
                      0
                      • M mrjj
                        19 Jan 2018, 09:23

                        @Veepee

                        ok. but if you already have a Creator plugin why not make your own pane ( like todo)
                        and just output there ?

                        V Offline
                        V Offline
                        Veepee
                        wrote on 19 Jan 2018, 09:26 last edited by
                        #11

                        @mrjj That would be great. But is it that simple ? Do we have any direct interfaces available for this ? Currently am referring ToDo plugin to understand how this is done.

                        M 1 Reply Last reply 19 Jan 2018, 09:28
                        0
                        • V Veepee
                          19 Jan 2018, 09:26

                          @mrjj That would be great. But is it that simple ? Do we have any direct interfaces available for this ? Currently am referring ToDo plugin to understand how this is done.

                          M Offline
                          M Offline
                          mrjj
                          Lifetime Qt Champion
                          wrote on 19 Jan 2018, 09:28 last edited by
                          #12

                          @Veepee

                          Hi, to be frank, i would just reuse the toDo pane as
                          its all the same and only difference is what widgets are used.
                          As i remember it, it was not terrible complex when you had sample to reuse. :)

                          1 Reply Last reply
                          1

                          8/12

                          19 Jan 2018, 09:11

                          • Login

                          • Login or register to search.
                          8 out of 12
                          • First post
                            8/12
                            Last post
                          0
                          • Categories
                          • Recent
                          • Tags
                          • Popular
                          • Users
                          • Groups
                          • Search
                          • Get Qt Extensions
                          • Unsolved