private void zEventTextFieldChanged() {
        if (settings == null) {
            return;
        }
        // Skip this function if it should not be run.
        if (skipTextFieldChangedFunctionWhileTrue) {
            return;
        }
        // Gather some variables that we will need.
        String dateText = dateTextField.getText();
        boolean textIsEmpty = dateText.trim().isEmpty();
        DateVetoPolicy vetoPolicy = settings.getVetoPolicy();
        boolean nullIsAllowed = settings.getAllowEmptyDates();
        // If the text is not empty, then try to parse the date.
        LocalDate parsedDate = null;
        if (!textIsEmpty) {
            parsedDate = InternalUtilities.getParsedDateOrNull(dateText,
                    settings.getFormatForDatesCommonEra(),
                    settings.getFormatForDatesBeforeCommonEra(),
                    settings.getFormatsForParsing(), settings.getLocale());
        }
        // If the date was parsed successfully, then check it against the veto policy.
        boolean dateIsVetoed = false;
        if (parsedDate != null) {
            dateIsVetoed = InternalUtilities.isDateVetoed(vetoPolicy, parsedDate);
        }
        // If the date is a valid empty date, then set the last valid date to null.
        if (textIsEmpty && nullIsAllowed) {
            zInternalSetLastValidDateAndNotifyListeners(null);
        }
        // If the date is a valid parsed date, then store the last valid date.
        if ((!textIsEmpty) && (parsedDate != null) && (dateIsVetoed == false)) {
            zInternalSetLastValidDateAndNotifyListeners(parsedDate);
        }
        // Draw the date status indications for the user.
        zDrawTextFieldIndicators();
        // Fire a change event for beans binding.
        firePropertyChange("text", null, dateTextField.getText());
    }
private void zEventTextFieldChanged ( ) { if ( settings == null ) { return ; } if ( skipTextFieldChangedFunctionWhileTrue ) { return ; } String dateText = dateTextField . getText ( ) ; boolean textIsEmpty = dateText . trim ( ) . isEmpty ( ) ; DateVetoPolicy vetoPolicy = settings . getVetoPolicy ( ) ; boolean nullIsAllowed = settings . getAllowEmptyDates ( ) ; LocalDate parsedDate = null ; if ( ! textIsEmpty ) { parsedDate = InternalUtilities . getParsedDateOrNull ( dateText , settings . getFormatForDatesCommonEra ( ) , settings . getFormatForDatesBeforeCommonEra ( ) , settings . getFormatsForParsing ( ) , settings . getLocale ( ) ) ; } boolean dateIsVetoed = false ; if ( parsedDate != null ) { dateIsVetoed = InternalUtilities . isDateVetoed ( vetoPolicy , parsedDate ) ; } if ( textIsEmpty && nullIsAllowed ) { zInternalSetLastValidDateAndNotifyListeners ( null ) ; } if ( ( ! textIsEmpty ) && ( parsedDate != null ) && ( dateIsVetoed == false ) ) { zInternalSetLastValidDateAndNotifyListeners ( parsedDate ) ; } zDrawTextFieldIndicators ( ) ; firePropertyChange ( "text" , null , dateTextField . getText ( ) ) ; }
zEventTextFieldChanged, This is called whenever the text in the date picker text field has
changed, whether programmatically or by the user.

If the current text contains a valid date, it will be stored in the variable lastValidDate.
Otherwise, the lastValidDate will not be changed.

This will also call the function to indicate to the user if the currently text is a valid
date, invalid text, or a vetoed date. These indications are created by using font, color, and
background changes of the text field.