How to add things to displayed value?

Home Forums General Programming How to add things to displayed value?

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #85224
    coupe70
    Participant
      • Topics: 3
      • Replies: 2
      • Total: 5

      Hello!
      I managed to change the MIDI range (0-127) of a fader to a displayed value of 0-100.
      But I can’t find out how to add a “%” to the displayed value.
      I’ve seen that in a panel, but it is locked, so I couldn’t look inside.
      Any advise?

      #85227
      Puppeteer
      Participant
        • Topics: 16
        • Replies: 185
        • Total: 201
        • ★★

        Use the fixed UI element and then type the list of values you want displayed in the values box. Each line will be indexed, but you can even override the index by listing the index value and the display value.

        I can’t remember the exact syntax and order, but it’s around these forums somewhere.

        The Puppeteer
        http://godlike.com.au

        #85901
        goodweather
        Participant
          • Topics: 45
          • Replies: 550
          • Total: 595
          • ★★★

          This is one way of doing but it requires the input of all possible values.

          What I’m usually doing is to not show the value of the uiSlider modulator directly.
          Instead, I create another static uiLabel modulator that you change the content dynamically using a Lua script.
          Then you can write anything you want based on the value (typically, adding a % or a +- sign or even perform some calculation).
          You call the script from your uiSlider “Called when the modulator value change” property.

        Viewing 3 posts - 1 through 3 (of 3 total)
        • The forum ‘Programming’ is closed to new topics and replies.
        There is currently 0 users and 68 guests online
        No users are currently active
        Forum Statistics
        Threads: 2,495, Posts: 17,374, Members: 77,605
        Most users ever online was 12 on January 22, 2019 3:47 pm
        Ctrlr