question: protected void paintComponent ( Graphics g ) { super . paintComponent ( g ) ; if ( caretLineY > - 1 ) { g . setColor ( getCaretMarkerColor ( ) ) ; g . fillRect ( 0 , caretLineY , getWidth ( ) , 2 ) ; } }
target:  Overridden to (possibly) draw the caret's position.