Caps Lock Input for Text Draw actor
-
Hello Isadoramongers, quick test of a feature request: Caps Lock input for the Text Draw actor. (I never needed it before, but now there's the Speech to Text actor to play around with, it would be lovely to be able to dynamically control whether the text generated is in lower case or capitals)
-
This post is deleted! -
@dbini said:
dynamically control whether the text generated is in lower case or capitals
This can easily be done via Javascript.
// iz_input 1 "text input"
// iz_input 2 "format mode"
// iz_output 1 "text output" /*
INPUT ORDER
arguments[0] = incoming text
arguments[1] = format mode (Integer) FORMAT MODES
1 = unchanged
2 = UPPERCASE
3 = lowercase OUTPUT ORDER
The single returned value is sent to output 1.
*/ function main()
{
var textInput = String(arguments[0]);
var formatMode = Math.round(arguments[1]); var outputText = textInput; if (formatMode === 2)
{
outputText = textInput.toUpperCase();
}
else if (formatMode === 3)
{
outputText = textInput.toLowerCase();
} // View these messages using Windows > Show Monitor.
print("Input: " + textInput + "\n");
print("Mode: " + formatMode + "\n");
print("Output: " + outputText + "\n"); return [outputText];
} -
Thanks Ryan, I suspected there would be a codey way to format the text. Still, I think it would be a nice addition to the Text Draw.
-
- although, after experimenting, the system works in a slightly different way, in that now the text builds up over time. if you go directly from Audio to Text into Text Draw, it resets at the end of each sentence. Im sure there's a way to add a reset trigger to the Javascript.
-
@dbini said:
the text builds up over time. if you go directly from Audio to Text into Text Draw, it resets at the end of each sentence.
Not sure if this helps at all

Also just gunna throw these in here for good measure. Maybe I made something before that you might find useful: js-text-user-actors.zip
-
a workaround is to use a font with a capital version like Bodoni 72 and Bodoni 72 small caps and to switch between both.
Best regardsJean-François