Giter VIP home page Giter VIP logo

Comments (4)

GeekyEggo avatar GeekyEggo commented on June 11, 2024 1

Would there be a possibility for a work-around where there's basically a "title" field but provided by the plugin?

Yes, and no.

Background

In the form of buttons, the SDK allows plug-ins to control two graphical things;

  • setImage - Sets the icon of the action; this call is ignored if the user has specified an image in the Stream Deck application.
  • setTitle - Sets the title of the action; this call is ignored if the user has specified a title in the Stream Deck application.

Question at hand

With this knowledge, going back to your question: the plug-in could...

  1. Offer a text input that prompted the user for a "custom" title.
  2. Generate a new icon using the action's default icon, and the "custom" title.
  3. Call setImage with this generated icon that includes the "custom" title stamped into it.

This sadly means that users wouldn't be able to assign custom icons themselves, and we enter a similar problem that we did with setTitle.

Future

Excitingly, with the release of the Stream Deck+, the SDK introduces the concept of "layouts", where plug-ins have much greater flexibility with how an action can be graphically represented by the plug-in. At this time, layouts are only available as part of the SD+'s touch screen. Moving forwards, I'm hopeful that they layouts will be available for standard "button" actions; should that happen, I'll look into this further! 🤞

from sounddeck.

GeekyEggo avatar GeekyEggo commented on June 11, 2024

Hey @SmartASCII, good news, this is currently available! There's a small caveat though, it does require the title field to be empty. Sadly this is a design feature that's enforced by the Stream Deck SDK, whereby the user-specified title takes precedent over the plug-ins preferred title.

If you set the title of the action to be empty, it should display the remaining time for the current audio file being played, like so:

image

from sounddeck.

SmartASCII avatar SmartASCII commented on June 11, 2024

Yuck, that's quite a restrictive caveat! I wish they'd allow it to function like their built-in sound board action.

Would there be a possibility for a work-around where there's basically a "title" field but provided by the plugin? That way you're not overriding the system-defined "user title", but just another field given by the plugin itself?

It's not a perfect solution, but it's not as messy as making me create 100+ icons with sound names on them 😁

from sounddeck.

SmartASCII avatar SmartASCII commented on June 11, 2024

Thanks for the detailed explanation!

from sounddeck.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.