UBports Robot Logo UBports Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Register
    • Login

    QML Templates and Tools

    Scheduled Pinned Locked Moved App Development
    12 Posts 6 Posters 1.7k Views 2 Watching
    Loading More Posts
    • 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.
      • CiberSheepC Offline
        CiberSheep
        last edited by CiberSheep

        List of Useful Code

        I thought it would be useful to do a list of little templates, tools and maybe tricks to common problems we face when developing.

        Templates

        • About QML Template
        • Button to Hide/Show Header
        • Download Dialogue with Progress Bar
        • Import Hub example. Click on the button to import a file and see in the logs the mimeType, url, etc

        Tools

        • Download Interceptor (download files that cannot be handled by the download manager
        • Blob Saver (be able to download blob url)

        Thanks @bhdouglass
        Do you want to share yours?

        Another planet, another time, another universe!

        CiberSheepC 1 Reply Last reply Reply Quote 9
        • CiberSheepC Offline
          CiberSheep @CiberSheep
          last edited by

          Updated the repo with an example for importing a file from the Content Hub (see the logs when you do)

          Another planet, another time, another universe!

          1 Reply Last reply Reply Quote 0
          • KrilleK Offline
            Krille
            last edited by

            Great. I was thinking about this too. What about creating Qml Plugins out of these so we can use git submodules to get updates from upstream and we dont need to copy them 1000x times. Or we create Debian packages and add them to the system image?

            CiberSheepC 1 Reply Last reply Reply Quote 1
            • K Offline
              kugiigi
              last edited by

              We had a similar thing before right? Something like the component store.

              CiberSheepC 1 Reply Last reply Reply Quote 1
              • CiberSheepC Offline
                CiberSheep @Krille
                last edited by

                @Krille That is a great idea. @bhdouglass you and me got into the same path.

                The idea (I think common) is to have those as templates one can use. I actually use the about in the repo quite often πŸ™‚

                So, what I need to change or do to have those prepared for them to be used?

                Another planet, another time, another universe!

                1 Reply Last reply Reply Quote 0
                • CiberSheepC Offline
                  CiberSheep @kugiigi
                  last edited by

                  @kugiigi Yep. Canonical had a store you could get BottomEdge previous to the BottomEdge, the Ogra radial bottom menu, and other part (some we are still use).

                  They are obsolete now but...

                  Another planet, another time, another universe!

                  1 Reply Last reply Reply Quote 0
                  • poVoqP Offline
                    poVoq
                    last edited by

                    App templates like this:
                    https://gitlab.com/ubports/apps/qt-webengine-demo/

                    Would probably also be cool to keep updated.

                    In general probably also a good place to start with the transition to qt quick controls 2.

                    Fairphone 5 (waiting for port)

                    1 Reply Last reply Reply Quote 0
                    • F Offline
                      fulvio
                      last edited by

                      if can be useful: https://github.com/fulvio999/ubports_app_templates

                      CiberSheepC 1 Reply Last reply Reply Quote 1
                      • CiberSheepC Offline
                        CiberSheep @fulvio
                        last edited by

                        @fulvio excellent!

                        Another planet, another time, another universe!

                        1 Reply Last reply Reply Quote 0
                        • CiberSheepC Offline
                          CiberSheep
                          last edited by

                          https://gitlab.com/cibersheep/qml-templates-for-ubuntutouch/

                          Update

                          • Added a new template: Rotate element. You can rotate an image or item and set some degrees to snap.
                            Maybe a Readme would be useful but the comments in the code should be enough.
                            Example of use:
                            • https://open-store.io/manage/turnstile.cibersheep
                            • https://open-store.io/app/circlepuzzle.cibersheep
                          • Updated About template with a better code. MR are welcome as it might be well improved.

                          Another planet, another time, another universe!

                          1 Reply Last reply Reply Quote 1
                          • arubislanderA Offline
                            arubislander
                            last edited by arubislander

                            This is a great idea for a community resource! Now how do I go about bookmarking this whole conversation thread?

                            EDIT: Now I see it is an old thread and I had already upvoted and bookmarked the first post way back then... :grinning_face_with_sweat:

                            πŸ‡¦πŸ‡Ό πŸ‡³πŸ‡± πŸ‡ΊπŸ‡Έ πŸ‡ͺπŸ‡Έ
                            Happily running Ubuntu Touch
                            Google Pixel 3a (20.04 DEV)
                            JingPad (24.04 preview)
                            Meizu Pro 5 (16.04 DEV)

                            CiberSheepC 1 Reply Last reply Reply Quote 0
                            • CiberSheepC Offline
                              CiberSheep @arubislander
                              last edited by

                              @arubislander said in QML Templates and Tools:

                              Now how do I go about bookmarking this whole conversation thread?

                              You can star projects in Git*b to receive updates πŸ™‚

                              Another planet, another time, another universe!

                              1 Reply Last reply Reply Quote 1
                              • First post
                                Last post