Forum
    • Categories
    • Register
    • Login

    Multiple Styles for Controls?

    Scheduled Pinned Locked Moved Scripting
    4 Posts 2 Posters 12 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.
    • B
      bwoogie
      last edited by

      Is it possible to create multiple styles for the same control? Like, if I wanted to have a couple different looking buttons or knobs for instance.

      The only way I currently see is check the id of the control in my Look and Feel and draw based on that. But that's an awful way because it makes my code not reusable between plugins.

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

        @bwoogie You could create an array of selected components and just apply its own laf functions to them. You could make how ever many different lafs you want. Make sure you're using LocalLookAndFeel as opposed to GlobalLookAndFeel. Does that answer your question? I think im understanding what you're asking.

        B 1 Reply Last reply Reply Quote 0
        • B
          bwoogie @Chazrox
          last edited by

          @Chazrox Yes, that makes sense. That may be the way I'll do it, if a better way doesn't show up. I'd prefer to be able to just change a style setting in the gui editor - like how you'd choose a knob or a slider. But at least I'll have a method.

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

            @bwoogie The only way I think you can change the actual style of the knob/button like that (and we're not just talking about colour and dimensions right?), you can use filmstrip images and just load different ones through the property editor. Then you can change the images individually.

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

            18

            Online

            2.1k

            Users

            13.0k

            Topics

            112.5k

            Posts