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. QGrahphicsScene/View Image Error.

QGrahphicsScene/View Image Error.

Scheduled Pinned Locked Moved Unsolved General and Desktop
8 Posts 2 Posters 1.0k 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.
  • P Offline
    P Offline
    Pada_
    wrote on last edited by
    #1

    On the Internet, right-click to copy an image, and then paste it in the GraphicsView.

    Can I get the URL of the homepage where the image was saved from the image stored in the clipboard when I confirmed that the image is in the clipboard? Can I get it and create an image with it?

    jsulmJ 1 Reply Last reply
    0
    • P Pada_

      On the Internet, right-click to copy an image, and then paste it in the GraphicsView.

      Can I get the URL of the homepage where the image was saved from the image stored in the clipboard when I confirmed that the image is in the clipboard? Can I get it and create an image with it?

      jsulmJ Offline
      jsulmJ Offline
      jsulm
      Lifetime Qt Champion
      wrote on last edited by
      #2

      @Pada_ Don't know about original URL, but you can get the image from clipboard using https://doc.qt.io/qt-5/qclipboard.html

      https://forum.qt.io/topic/113070/qt-code-of-conduct

      P 1 Reply Last reply
      0
      • jsulmJ jsulm

        @Pada_ Don't know about original URL, but you can get the image from clipboard using https://doc.qt.io/qt-5/qclipboard.html

        P Offline
        P Offline
        Pada_
        wrote on last edited by
        #3

        @jsulm

        Thank you for answer. First, it works fine until you get the image from the local to the clipboard and use it.

        When I press the Copy image from Chrome button, it works fine.

        https://www.google.com/images/branding/googlelogo/2x/googlelogo_color_272x92dp.png

        I am looking for a way to put images using the URLs in these links.

        jsulmJ 1 Reply Last reply
        0
        • P Pada_

          @jsulm

          Thank you for answer. First, it works fine until you get the image from the local to the clipboard and use it.

          When I press the Copy image from Chrome button, it works fine.

          https://www.google.com/images/branding/googlelogo/2x/googlelogo_color_272x92dp.png

          I am looking for a way to put images using the URLs in these links.

          jsulmJ Offline
          jsulmJ Offline
          jsulm
          Lifetime Qt Champion
          wrote on last edited by
          #4

          @Pada_ said in QGrahphicsScene/View Image Error.:

          I am looking for a way to put images using the URLs in these links.

          Sorry, I don't understand. To put to where? Can you please explain better what exactly you want to do?
          Do you want to download the picture from that URL?

          https://forum.qt.io/topic/113070/qt-code-of-conduct

          P 1 Reply Last reply
          0
          • jsulmJ jsulm

            @Pada_ said in QGrahphicsScene/View Image Error.:

            I am looking for a way to put images using the URLs in these links.

            Sorry, I don't understand. To put to where? Can you please explain better what exactly you want to do?
            Do you want to download the picture from that URL?

            P Offline
            P Offline
            Pada_
            wrote on last edited by
            #5

            @jsulm

            Of course, QGraphicsPixmap exists as an item in QGraphicsView / Scene, but what we want is that when the user presses the right button of the mouse on the Internet to copy the image,

            I want to get the URL with that image,

            You want to show it in the scene with that URL.

            The URL you posted earlier is the URL for the GOOGLE logo on the GOOGLE homepage.

            I want to add a lot of comments quickly, but I can only write once every 10 minutes because I'm a beginner.

            jsulmJ 1 Reply Last reply
            0
            • P Pada_

              @jsulm

              Of course, QGraphicsPixmap exists as an item in QGraphicsView / Scene, but what we want is that when the user presses the right button of the mouse on the Internet to copy the image,

              I want to get the URL with that image,

              You want to show it in the scene with that URL.

              The URL you posted earlier is the URL for the GOOGLE logo on the GOOGLE homepage.

              I want to add a lot of comments quickly, but I can only write once every 10 minutes because I'm a beginner.

              jsulmJ Offline
              jsulmJ Offline
              jsulm
              Lifetime Qt Champion
              wrote on last edited by jsulm
              #6

              @Pada_ You should check what https://doc.qt.io/qt-5/qclipboard.html#mimeData returns after you click Copy in the browser. I'm not sure the browser will put the URL as mime data into clipboard. If it does not then you can't do it like this.

              https://forum.qt.io/topic/113070/qt-code-of-conduct

              P 1 Reply Last reply
              0
              • jsulmJ jsulm

                @Pada_ You should check what https://doc.qt.io/qt-5/qclipboard.html#mimeData returns after you click Copy in the browser. I'm not sure the browser will put the URL as mime data into clipboard. If it does not then you can't do it like this.

                P Offline
                P Offline
                Pada_
                wrote on last edited by
                #7

                @jsulm

                If you click Copy image on the image, the contents of the clipboard will be stored in the Image, and the link (URL) with that image will not be saved. It is very difficult to create an image with that link.

                jsulmJ 1 Reply Last reply
                0
                • P Pada_

                  @jsulm

                  If you click Copy image on the image, the contents of the clipboard will be stored in the Image, and the link (URL) with that image will not be saved. It is very difficult to create an image with that link.

                  jsulmJ Offline
                  jsulmJ Offline
                  jsulm
                  Lifetime Qt Champion
                  wrote on last edited by
                  #8

                  @Pada_ Well, if the link is not copied together with the image into clipboard then you can't do it this way. You only get the image then...

                  https://forum.qt.io/topic/113070/qt-code-of-conduct

                  1 Reply Last reply
                  0

                  • Login

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