We had a quick question on how to wrap buttons in Spotfire. Usually buttons come out like this when you don’t specify the length of the button.
But! If you specify specific dimensions, you’ll find that your button label will trail off into the distance like the button below.
We can employ some simple tricks in Spotfire to get this label to wrap. You’ll need to have the ability to write CSS scripts using the <style> tag. Your Spotfire administrator can turn this on for you. To begin, you’ll need to do the following:
- Create a text area.
- Create your button with the size you want.
- Open the text area into the HTML editor by right-clicking and selecting Edit HTML…
In the script below, you’ll want to add the <style> tag that I have listed below
The white-space property controls how text wraps inside the button. You’ll override this property to the “normal” way it works. The “!important” attribute overrides how Spotfire does this.
Presto! You’re all set.
Technical Director at Ruths.ai