Forum
    • Categories
    • Register
    • Login

    Added ShowFolderRows option to Preset Browser

    Scheduled Pinned Locked Moved General Questions
    3 Posts 2 Posters 17 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.
    • dannytaurusD
      dannytaurus
      last edited by dannytaurus

      I'm using a single-column preset browser in my plugin, but wanted a way to show folder breaks in the list. The interim was to write tiny folder name text at the top of the preset row that changes folder, but it's a hack and looks terrible anyway.

      So I had Claude add a ShowFolderRows JSON param to the native preset browser:

      # How to use it
      
      const var data = {
          "Type": "PresetBrowser",
          "NumColumns": 1,
          "ShowFolderRows": true,
          ...
      };
      
      # And optionally in your LAF script:
      
      laf.registerFunction("drawPresetBrowserFolderRow", function(g, obj)
        {
            g.setColour(Colours.withAlpha(obj.textColour, 0.5));
            g.setFont(obj.font, obj.fontSize - 2);
            g.drawAlignedText(obj.text, obj.area, "left");
        });
      

      So now I have nice folder breaks in my single column preset list:

      CleanShot 2026-07-28 at 14.14.46@2x.png

      I know the general consensus is "if you don't like the native preset browser, build your own". But I didn't want to script my own preset browser just for this one extra feature, because the native preset browser is battle-tested and has really nice mechanics for free.

      I also know this is highly unlikely to get accepted upstream but I made a PR that might help someone else who is looking for the same feature in the future:

      https://github.com/christophhart/HISE/pull/1009

      Meat Beats: https://meatbeats.com
      Klippr Video: https://klippr.video

      David HealeyD 1 Reply Last reply Reply Quote 1
      • David HealeyD
        David Healey @dannytaurus
        last edited by

        @dannytaurus said in Added ShowFolderRows option to Preset Browser:

        I also know this is highly unlikely to get accepted upstream

        I've made a lot of PRs related to the preset browser over the years, most of which (possibly all) have been merged. This seems like a good candidate.

        Free HISE Bootcamp Full Course for beginners.
        YouTube Channel - HISE tutorials
        My Patreon - More HISE tutorials

        dannytaurusD 1 Reply Last reply Reply Quote 2
        • dannytaurusD
          dannytaurus @David Healey
          last edited by

          @David-Healey Yours always seems to be more generally useful than mine though 😂

          This one is pretty niche but I'll likely be using single column preset browsers in most of my plugins, so it's really useful for me.

          Meat Beats: https://meatbeats.com
          Klippr Video: https://klippr.video

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

          19

          Online

          2.4k

          Users

          13.9k

          Topics

          120.8k

          Posts