Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Mobile and Embedded
  4. [SOLVED] QtSvg on iOS
Forum Updated to NodeBB v4.3 + New Features

[SOLVED] QtSvg on iOS

Scheduled Pinned Locked Moved Mobile and Embedded
8 Posts 2 Posters 2.7k 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.
  • K Offline
    K Offline
    kostyamaslyuk
    wrote on last edited by
    #1

    Just can't get how to enable svg support for iPhone on Mac. I have compiled qt5 from git, make qtbase, make qtsvg. Adding libQt5Svg.a, libQt5Xml.a libraries manually seem does not affect anything.

    QImageReader::supportedImageFormsts() does not contain "svg"

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

      Hi and welcome to devnet,

      Did you add

      @QT += svg@

      To your pro file ?

      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
      • K Offline
        K Offline
        kostyamaslyuk
        wrote on last edited by
        #3

        Hi, and thanks. I have

        @CONFIG += svg xml@

        i should try to add your line, because behavior would be different

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

          Yes it would, QT += is the line used to tell which module from Qt you want to use. On the other hand CONFIG is for compilation related stuff.

          You can find more information in qmake's Variable Reference documentation

          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
          • K Offline
            K Offline
            kostyamaslyuk
            wrote on last edited by
            #5

            Thanks, now libQt5Svg is added automatically after qmake. Android required only CONFIG option.

            Svg still unavailable on device (iOS simulator). I can read in documentation that on Mac qsvg icon plugin is deployed automatically if QtSvg Module is selected. But i haven't shared library for qsvg plugin that would be deployed (only static lib is built by default - libqsvg.a).

            So i whether should try to build Qt as shared library or post something on bugtracker.

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

              Then you'll have to follow the static plugin documentation

              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
              • K Offline
                K Offline
                kostyamaslyuk
                wrote on last edited by
                #7

                I need to explicitly import plugin with
                @Q_IMPORT_PLUGIN(QSvgPlugin);@

                Because Qt is built staticaly...

                Thank you for helping to investigate this!

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

                  You're welcome !

                  Don't forget to update your thread's title to solved so other forum users may know that a solution to the problem has been found :)

                  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

                  • Login

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