Skip to main content
Participant
Jan 31, 2025 11:00 AM UTC
Answered

Blinking Cursor Custom character

Hi all,

 

I want to do a blinking typewriter effect with the preset:
Blinking Cursor Typewriting Console

I want to have a dot as the blinking cursor, but it is not available as an option.
I can however edit the list via the Edit button on the top right.

But everything I enter, will lead to the cursor spelling "undefined"

 

Does anyone have an idea where I can define these custom characters?

Thank you!!

 

 

 

 

 




ShiveringCactus
ShiveringCactusCorrect answer
Community Expert
Jan 31, 2025 11:47 AM UTC

If you expand the text layer so that you can see the sourceText property and then view the expression on it, you'll see this code:

var t = text.sourceText;
var l = t.length;
var a = effect("Animation")(1);
var c = ["|","_","—","<",">","«","»","^"];
var d = effect("Cursor Shape")(1).value;
var reveal = t.slice(0, l*linear(a,0,100,0,1));
reveal + c[d-1];

The variable c in the code is an array of different characters that the Cursor shape is pointing to.   So the simplest option is to replace one of the characters with a dot.  I got this one: ● from https://copychar.cc/

 

var t = text.sourceText;
var l = t.length;
var a = effect("Animation")(1);
var c = ["●","_","—","<",">","«","»","^"];
var d = effect("Cursor Shape")(1).value;
var reveal = t.slice(0, l*linear(a,0,100,0,1));
reveal + c[d-1];

 

 

1 reply

ShiveringCactus
Community Expert
ShiveringCactusCommunity ExpertCorrect answer
Community Expert
Jan 31, 2025 11:47 AM UTC

If you expand the text layer so that you can see the sourceText property and then view the expression on it, you'll see this code:

var t = text.sourceText;
var l = t.length;
var a = effect("Animation")(1);
var c = ["|","_","—","<",">","«","»","^"];
var d = effect("Cursor Shape")(1).value;
var reveal = t.slice(0, l*linear(a,0,100,0,1));
reveal + c[d-1];

The variable c in the code is an array of different characters that the Cursor shape is pointing to.   So the simplest option is to replace one of the characters with a dot.  I got this one: ● from https://copychar.cc/

 

var t = text.sourceText;
var l = t.length;
var a = effect("Animation")(1);
var c = ["●","_","—","<",">","«","»","^"];
var d = effect("Cursor Shape")(1).value;
var reveal = t.slice(0, l*linear(a,0,100,0,1));
reveal + c[d-1];

 

 

Translate