@Override
	public void moveDot( int dot ) {
		super.moveDot( dot );

		// mark as focused if invoked from JTextComponent.moveCaretPosition()
		// to disable SELECT_ALL_ON_FOCUS_POLICY_ONCE if application explicitly changes selection
		if( !wasFocused &&
			getSelectAllOnFocusPolicy() == ONCE &&
			StackUtils.wasInvokedFrom( JTextComponent.class.getName(), "moveCaretPosition", 6 ) )
		  wasFocused = true;
	}
Caret that can select all text on focus gained.
Also fixes Swing's double-click-and-drag behavior so that dragging after
a double-click extends selection by whole words.

@author Karl Tauber
flatlaf-core/src/main/java/com/formdev/flatlaf/ui/FlatCaret.java