HISE Logo Forum
    • Categories
    • Register
    • Login

    Can a label be clickable?

    Scheduled Pinned Locked Moved Scripting
    34 Posts 6 Posters 701 Views
    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.
    • MorphoiceM
      Morphoice @d.healey
      last edited by Morphoice

      @d-healey

      I suppose it's

      const var panel = Content.addPanel("Panel", 0, 0);
      

      but getting the coordinates right will probably be a pain

      https://instagram.com/morphoice - 80s inspired Synthwave Music, Arcade & Gameboy homebrew!

      1 Reply Last reply Reply Quote 0
      • MorphoiceM
        Morphoice @Christoph Hart
        last edited by Morphoice

        @Christoph-Hart coming across this iconic example I wonder if we ever figured out whether Oxygen is compiled into the plugins by default or has to be added to the image directory in order for all distributions to show the correct font. and if not, what does it default to? please don't say Comic Sans

        Screenshot 2024-12-05 at 13.41.09.png

        https://instagram.com/morphoice - 80s inspired Synthwave Music, Arcade & Gameboy homebrew!

        d.healeyD 1 Reply Last reply Reply Quote 0
        • d.healeyD
          d.healey @Morphoice
          last edited by

          @Morphoice said in Can a label be clickable?:

          I was just wondering if it is possible to create an entire panel from script and not in the UI editor

          You can create an entire UI via scripting.

          There's a whole documentation section about this: https://docs.hise.dev/scripting/scripting-in-hise/scriptpanel.html#use-the-"create-ui-factory-method"-tool

          For positioning you can use maths. For example if you want a panel in the centre of the UI you could use

          panel.set("x" UiWidth / 2 - panel.getWidth() / 2);
          panel.set("y" UiHeight / 2 - panel.getHeight() / 2);
          

          For your main interface you probably will want to stick to using the interface designer for most things, but for secondary scripts you should use scripting to create their UIs.

          Libre Wave - Freedom respecting instruments and effects
          My Patreon - HISE tutorials
          YouTube Channel - Public HISE tutorials

          1 Reply Last reply Reply Quote 1
          • d.healeyD
            d.healey @Morphoice
            last edited by

            @Morphoice said in Can a label be clickable?:

            what does it default to?

            Probably whatever the OS decides. You should always include the fonts you want to use, just to be sure. Also be aware that if you're using fonts in paint routines they might look different on different operating systems, so you'll need to test and account for that.

            Libre Wave - Freedom respecting instruments and effects
            My Patreon - HISE tutorials
            YouTube Channel - Public HISE tutorials

            MorphoiceM 1 Reply Last reply Reply Quote 1
            • MorphoiceM
              Morphoice @d.healey
              last edited by

              @d-healey

              so by default an

              Engine.loadFont("{PROJECT_FOLDER}Fonts/Oxygen.ttf"); 
              

              is generally a good idea at the start of the plugin, just to be safe?

              https://instagram.com/morphoice - 80s inspired Synthwave Music, Arcade & Gameboy homebrew!

              d.healeyD 1 Reply Last reply Reply Quote 0
              • d.healeyD
                d.healey @Morphoice
                last edited by d.healey

                @Morphoice said in Can a label be clickable?:

                is generally a good idea at the start of the plugin, just to be safe?

                Yes but no, loadFont is deprecated, you should use loadFontAs() instead. Only use Oxygen if that's the font you want to use.

                Libre Wave - Freedom respecting instruments and effects
                My Patreon - HISE tutorials
                YouTube Channel - Public HISE tutorials

                MorphoiceM 1 Reply Last reply Reply Quote 0
                • MorphoiceM
                  Morphoice @d.healey
                  last edited by

                  @d-healey said in Can a label be clickable?:

                  loadFontAs

                  I see. So the bold version I load as "Oxygen Bold" etc.

                  https://instagram.com/morphoice - 80s inspired Synthwave Music, Arcade & Gameboy homebrew!

                  d.healeyD 1 Reply Last reply Reply Quote 0
                  • d.healeyD
                    d.healey @Morphoice
                    last edited by

                    @Morphoice Yes, but you can use whatever name you like, here's an example - https://codeberg.org/LibreWave/RhapsodyBoilerplate/src/branch/main/includes/LookAndFeel.js#L22

                    Libre Wave - Freedom respecting instruments and effects
                    My Patreon - HISE tutorials
                    YouTube Channel - Public HISE tutorials

                    1 Reply Last reply Reply Quote 1
                    • ustkU
                      ustk @Christoph Hart
                      last edited by ustk

                      @Christoph-Hart said in Can a label be clickable?:

                      it‘s a separate HISE instance.

                      Not really sure of that one... https://forum.hise.audio/topic/10665/warning-snippet-browser-overwriting-the-current-project/7

                      @d-healey said in Can a label be clickable?:

                      Inferior operating system :p

                      Phewww.... We had a close shave! 😰 😁
                      https://www.totalphase.com/support/articles/200349376-multiple-application-instances-on-mac-os-x/?srsltid=AfmBOoqArvsq9Evjguf3dQ4sTrVAUeIOfEVHNXRSzDGsKDhfIKEX3GHp

                      Can't help pressing F5 in the forum...

                      MorphoiceM LindonL 2 Replies Last reply Reply Quote 2
                      • MorphoiceM
                        Morphoice @ustk
                        last edited by

                        @ustk said in Can a label be clickable?:

                        Phewww.... We had a close shave!
                        https://www.totalphase.com/support/articles/200349376-multiple-application-instances-on-mac-os-x/?srsltid=AfmBOoqArvsq9Evjguf3dQ4sTrVAUeIOfEVHNXRSzDGsKDhfIKEX3GHp

                        I knew there was an option somewhere :) Superior OS :-p

                        https://instagram.com/morphoice - 80s inspired Synthwave Music, Arcade & Gameboy homebrew!

                        d.healeyD VirtualVirginV 2 Replies Last reply Reply Quote 0
                        • d.healeyD
                          d.healey @Morphoice
                          last edited by

                          @Morphoice said in Can a label be clickable?:

                          Superior OS

                          This will only lead us to dark places, let's get out while we can.

                          Libre Wave - Freedom respecting instruments and effects
                          My Patreon - HISE tutorials
                          YouTube Channel - Public HISE tutorials

                          1 Reply Last reply Reply Quote 0
                          • LindonL
                            Lindon @ustk
                            last edited by

                            @ustk said in Can a label be clickable?:

                            @Christoph-Hart said in Can a label be clickable?:

                            it‘s a separate HISE instance.

                            Not really sure of that one... https://forum.hise.audio/topic/10665/warning-snippet-browser-overwriting-the-current-project/7

                            @d-healey said in Can a label be clickable?:

                            Inferior operating system :p

                            Phewww.... We had a close shave! 😰 😁
                            https://www.totalphase.com/support/articles/200349376-multiple-application-instances-on-mac-os-x/?srsltid=AfmBOoqArvsq9Evjguf3dQ4sTrVAUeIOfEVHNXRSzDGsKDhfIKEX3GHp

                            LOL thats so funny - MacOS users having to revert to the command line.....

                            HISE Development for hire.
                            www.channelrobot.com

                            MorphoiceM ustkU 2 Replies Last reply Reply Quote 2
                            • MorphoiceM
                              Morphoice @Lindon
                              last edited by Morphoice

                              @Lindon said in Can a label be clickable?:

                              LOL thats so funny - MacOS users having to revert to the command line.....

                              well it's a unix based OS, using the terminal is normal to us ;)
                              In fact it felt way more weird when I had to do it on windows to concat some eprom bin files a few days ago

                              https://instagram.com/morphoice - 80s inspired Synthwave Music, Arcade & Gameboy homebrew!

                              1 Reply Last reply Reply Quote 0
                              • ustkU
                                ustk @Lindon
                                last edited by

                                @Lindon said in Can a label be clickable?:

                                LOL thats so funny - MacOS users having to revert to the command line.....

                                sponge-bob-square-pants-sad.gif

                                Can't help pressing F5 in the forum...

                                1 Reply Last reply Reply Quote 1
                                • VirtualVirginV
                                  VirtualVirgin @Morphoice
                                  last edited by

                                  @Morphoice said in Can a label be clickable?:

                                  @ustk said in Can a label be clickable?:

                                  Phewww.... We had a close shave!
                                  https://www.totalphase.com/support/articles/200349376-multiple-application-instances-on-mac-os-x/?srsltid=AfmBOoqArvsq9Evjguf3dQ4sTrVAUeIOfEVHNXRSzDGsKDhfIKEX3GHp

                                  I knew there was an option somewhere :) Superior OS :-p

                                  There is an easier method of running multiple instances of an application in macOS:

                                  Make a copy of your application in the app folder, then open it.

                                  I keep shortcuts for the two HISE apps on my desktop:

                                  Screenshot 2024-12-06 at 1.15.16 AM.png

                                  You can listen to orchestral my orchestral mockups here:
                                  https://www.virtualvirgin.net/

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

                                  33

                                  Online

                                  1.7k

                                  Users

                                  11.8k

                                  Topics

                                  102.8k

                                  Posts