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. PhonOn displays at the only one monitor in a dual monitor system.
Qt 6.11 is out! See what's new in the release blog

PhonOn displays at the only one monitor in a dual monitor system.

Scheduled Pinned Locked Moved Unsolved General and Desktop
20 Posts 3 Posters 4.2k Views 1 Watching
  • 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.
  • T Offline
    T Offline
    twoplus
    wrote on last edited by
    #3
    This post is deleted!
    1 Reply Last reply
    0
    • SGaistS SGaist

      Hi and welcome to devnet,

      From your code, you're not telling your VideoWidgets to go on the secondary monitor, so they should stay on the default monitor.

      T Offline
      T Offline
      twoplus
      wrote on last edited by
      #4

      @SGaist
      I want to display from monitor1 to monitor2. Video is displayed in the monitor1 but black is displayed in the monitor2.

      1 Reply Last reply
      0
      • SGaistS SGaist

        Hi and welcome to devnet,

        From your code, you're not telling your VideoWidgets to go on the secondary monitor, so they should stay on the default monitor.

        T Offline
        T Offline
        twoplus
        wrote on last edited by
        #5

        @SGaist I want to display monitor1 and monitor2 at the same time because displayed video resolution is larger than the resolution of the monitor1.

        1 Reply Last reply
        0
        • SGaistS Offline
          SGaistS Offline
          SGaist
          Lifetime Qt Champion
          wrote on last edited by
          #6

          What you are doing is just setting your desktopWidget as parent of videoWidget. You're not moving it to your secondary screen. Also note that the correct way to have a QDesktopWidget instance is to get it from QApplication.

          Interested in AI ? www.idiap.ch
          Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

          T 1 Reply Last reply
          0
          • SGaistS SGaist

            What you are doing is just setting your desktopWidget as parent of videoWidget. You're not moving it to your secondary screen. Also note that the correct way to have a QDesktopWidget instance is to get it from QApplication.

            T Offline
            T Offline
            twoplus
            wrote on last edited by
            #7

            @SGaist Thank you for your answer, but I can't understand "moving it to your secondary screen".
            If you don't mind, can you give me a sample code?

            1 Reply Last reply
            0
            • SGaistS Offline
              SGaistS Offline
              SGaist
              Lifetime Qt Champion
              wrote on last edited by
              #8

              You have two monitors, so if you want your widget to appear on your second monitor, you have to move it there. i.e. set its position to be in your secondary screen QDesktopWidget. You can get that using QDesktopWidget::screenGeometry

              QDesktopWidget *desktopWidget = qApp->desktop();
              QRect secondScreenGeometry = desktopWidget->screenGeometry(1);
              myWidget->move(secondScreenGeometry.center());
              

              Interested in AI ? www.idiap.ch
              Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

              T SprezzaturaS 2 Replies Last reply
              0
              • SGaistS SGaist

                You have two monitors, so if you want your widget to appear on your second monitor, you have to move it there. i.e. set its position to be in your secondary screen QDesktopWidget. You can get that using QDesktopWidget::screenGeometry

                QDesktopWidget *desktopWidget = qApp->desktop();
                QRect secondScreenGeometry = desktopWidget->screenGeometry(1);
                myWidget->move(secondScreenGeometry.center());
                
                T Offline
                T Offline
                twoplus
                wrote on last edited by
                #9

                @SGaist I think there is misunderstanding. I want to display video that displaying area is 2000x700. So the video is displayed in the monitor1(1600x900) and monitor2(1920x1080), not monitor1 or monitor2. My problem is the area of monitor1 displays video well but the area of monitor2 only display black screen.

                1 Reply Last reply
                0
                • SGaistS Offline
                  SGaistS Offline
                  SGaist
                  Lifetime Qt Champion
                  wrote on last edited by
                  #10

                  Ok, indeed, there was a misunderstanding. So if you move your widget to your second monitor, it gets black or just the part when the widget is first shown ?

                  Interested in AI ? www.idiap.ch
                  Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                  T 1 Reply Last reply
                  0
                  • SGaistS SGaist

                    Ok, indeed, there was a misunderstanding. So if you move your widget to your second monitor, it gets black or just the part when the widget is first shown ?

                    T Offline
                    T Offline
                    twoplus
                    wrote on last edited by
                    #11

                    @SGaist Displayed video size(area) is 2000x700. So I should use from (100,100) of monitor1 to (500,800) of monitor2. In other words monitor1 display 1500x700 of video and monitor2 display 500x700 of video at the same time. But monitor1 displays well but monitor2 displays black. So some area(monitor2) of video is shown black.

                    1 Reply Last reply
                    0
                    • SGaistS Offline
                      SGaistS Offline
                      SGaist
                      Lifetime Qt Champion
                      wrote on last edited by
                      #12

                      What happens if you have the complete video widget on the secondary screen ?

                      Interested in AI ? www.idiap.ch
                      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                      T 1 Reply Last reply
                      0
                      • SGaistS SGaist

                        What happens if you have the complete video widget on the secondary screen ?

                        T Offline
                        T Offline
                        twoplus
                        wrote on last edited by
                        #13

                        @SGaist Then PhonOn displays the vidoe well.

                        1 Reply Last reply
                        0
                        • SGaistS Offline
                          SGaistS Offline
                          SGaist
                          Lifetime Qt Champion
                          wrote on last edited by
                          #14

                          Are both your screen "standard" ? Meaning not one being retina

                          Interested in AI ? www.idiap.ch
                          Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                          T 1 Reply Last reply
                          0
                          • SGaistS SGaist

                            Are both your screen "standard" ? Meaning not one being retina

                            T Offline
                            T Offline
                            twoplus
                            wrote on last edited by
                            #15

                            @SGaist Yes, my screens are standard.

                            1 Reply Last reply
                            0
                            • SGaistS Offline
                              SGaistS Offline
                              SGaist
                              Lifetime Qt Champion
                              wrote on last edited by
                              #16

                              I just realized, Qt 4.6.2 ? You should at least go to 4.8.7

                              Interested in AI ? www.idiap.ch
                              Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                              T 1 Reply Last reply
                              0
                              • SGaistS SGaist

                                I just realized, Qt 4.6.2 ? You should at least go to 4.8.7

                                T Offline
                                T Offline
                                twoplus
                                wrote on last edited by
                                #17

                                @SGaist Thank you for your help. Do you mean the PhonOn of 4.6.2 doesn't work but 4.8.7 works well in this case?

                                1 Reply Last reply
                                0
                                • SGaistS Offline
                                  SGaistS Offline
                                  SGaist
                                  Lifetime Qt Champion
                                  wrote on last edited by
                                  #18

                                  No, I mean that Qt 4.6.2 is pretty outdated so you should at least use the latest version available of the Qt 4 series (note that 4.8.7 is the last version of the Qt 4 series).

                                  Interested in AI ? www.idiap.ch
                                  Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                                  1 Reply Last reply
                                  0
                                  • SGaistS SGaist

                                    You have two monitors, so if you want your widget to appear on your second monitor, you have to move it there. i.e. set its position to be in your secondary screen QDesktopWidget. You can get that using QDesktopWidget::screenGeometry

                                    QDesktopWidget *desktopWidget = qApp->desktop();
                                    QRect secondScreenGeometry = desktopWidget->screenGeometry(1);
                                    myWidget->move(secondScreenGeometry.center());
                                    
                                    SprezzaturaS Offline
                                    SprezzaturaS Offline
                                    Sprezzatura
                                    wrote on last edited by
                                    #19

                                    @SGaist Not working for me (Qt 5.13).

                                    SGaistS 1 Reply Last reply
                                    0
                                    • SprezzaturaS Sprezzatura

                                      @SGaist Not working for me (Qt 5.13).

                                      SGaistS Offline
                                      SGaistS Offline
                                      SGaist
                                      Lifetime Qt Champion
                                      wrote on last edited by
                                      #20

                                      @Sprezzatura said in PhonOn displays at the only one monitor in a dual monitor system.:

                                      @SGaist Not working for me (Qt 5.13).

                                      Well, with that much details, it's going to be a bit hard to help.

                                      Interested in AI ? www.idiap.ch
                                      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                                      1 Reply Last reply
                                      1

                                      • Login

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