setCaretColor usage?

It should be as simple as

from java.awt import Color
event.source.setCaretColor(Color.GREEN)

if you put that on the text field’s focus gained or something, it will set the caret color to green.