HISE Logo Forum
    • Categories
    • Register
    • Login

    Preset Browser Laf || Multi-line?

    Scheduled Pinned Locked Moved Solved Scripting
    16 Posts 3 Posters 1.0k 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.
    • ChazroxC
      Chazrox @rglides
      last edited by

      @rglides bruh thats the one...lol. Thanks! 🤜 🤛

      Gottem:
      Screenshot 2025-05-26 at 8.48.05 PM.png

      rglidesR 1 Reply Last reply Reply Quote 2
      • rglidesR
        rglides @Chazrox
        last edited by

        @Chazrox Niiice!

        1 Reply Last reply Reply Quote 1
        • ChazroxC Chazrox marked this topic as a question on
        • ChazroxC Chazrox has marked this topic as solved on
        • ChazroxC
          Chazrox @rglides
          last edited by

          @rglides I need to learn how to read the api's before I come here. 😆

          rglidesR 1 Reply Last reply Reply Quote 1
          • rglidesR
            rglides @Chazrox
            last edited by

            @Chazrox 😁

            1 Reply Last reply Reply Quote 0
            • T
              treynterrio @Chazrox
              last edited by

              @Chazrox how did you do that? I'm trying to change Add a Preset, Add a Category but I can't manage how I could do that

              ChazroxC 1 Reply Last reply Reply Quote 0
              • ChazroxC
                Chazrox @treynterrio
                last edited by Chazrox

                @treynterrio

                in your "drawPresetBrowserColumnBackground" LAF function, add this and adjust to your liking.

                   		if (obj.text == "Select a Column")
                   			{
                   				obj.text = "";		
                   				g.setFont("Proggy", 14);
                   				g.setColour(Colours.withAlpha(obj.textColour, 0.5));
                   				g.drawMultiLineText("SELECT A CATEGORY\r\n\TO THE LEFT", [75,86], 100, "centred", 2.0);
                   			}
                   		if (obj.text == "Add a Category")
                   			{
                   						obj.text = "";				
                   				g.setFont("Proggy", 10);
                   				g.setColour(Colours.withAlpha(obj.textColour, 0.5));
                   				g.drawMultiLineText("SELECT A BANK\r\n\TO THE LEFT\r\n\OR CREATE A NEW\r\n\ CATEGORY BELOW\r\n\(CLICK '+' SIGN)", [a[2]/2 - 40,a[3] / 2 - 30], 80, "centred", 2.0);
                   			}
                   		if (obj.text == "Add a Preset")	
                   			{
                   				obj.text = "";		
                   				g.setFont("Proggy", 10);
                   				g.setColour(Colours.withAlpha(obj.textColour, 0.5));
                   				g.drawMultiLineText("SELECT A CATEGORY\r\n\TO THE LEFT\r\n\OR CREATE A PRESET BELOW (USE '+' SIGN)", [a[2]/2 - 40,a[3] / 2 - 30], 80, "centred", 2.0);
                   			} 	
                
                
                T 2 Replies Last reply Reply Quote 1
                • T
                  treynterrio @Chazrox
                  last edited by

                  @Chazrox thank you!!!!

                  ChazroxC 1 Reply Last reply Reply Quote 1
                  • ChazroxC
                    Chazrox @treynterrio
                    last edited by

                    @treynterrio You're welcome!

                    1 Reply Last reply Reply Quote 0
                    • T
                      treynterrio @Chazrox
                      last edited by

                      @Chazrox ok, that messed up my preset browser a bit. Do you know how I can get the column lines back? I tried using the draw function, but the lines aren't aligned properly.

                      ChazroxC 1 Reply Last reply Reply Quote 0
                      • ChazroxC
                        Chazrox @treynterrio
                        last edited by

                        @treynterrio Did you already have a LAF going for column background? If you didnt, you will have to draw it again yourself because now you're taking over the look and feel of that section.

                        start with :

                        g.drawRect(obj.area); 
                        
                        // or
                        g.drawRoundedRectangle( obj.area, 6, 1.0);
                        
                        //etc. 
                        
                        
                        1 Reply Last reply Reply Quote 0
                        • First post
                          Last post

                        14

                        Online

                        2.0k

                        Users

                        12.7k

                        Topics

                        110.5k

                        Posts