Skip to main content
Participant
January 31, 2025
Answered

Blinking Cursor Custom character

  • January 31, 2025
  • 1 reply
  • 165 views

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!!

 

 

 

 

 




Correct answer ShiveringCactus

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
January 31, 2025

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];