private void updateOptions() {
		String charsetName = charsetComboBox.getSelectedItem().toString();
		if (!charsetExists(charsetName)) {
			charsetName = CharsetInfo.USASCII;
		}

		boolean scriptOptions = showScriptOptionsButton.isSelected();
		boolean excludeStringsWithErrors = excludeStringsWithCodecErrorCB.isSelected();
		boolean excludeStringsWithNonStdCtrlChars =
			excludeStringsWithNonStdCtrlCharsCB.isSelected();
		boolean alignStartofString = alignStartOfStringCB.isSelected();

		// override the strminlen if the address range selection would be too small
		int minStrLen = !isSingleStringMode()
				? (int) Math.min(minStringLengthSpinner.getTextField().getIntValue(),
					selectedAddresses.getNumAddresses())
				: -1; // single string mode - no min len

		AbstractStringDataType stringDT = CHARSET_TO_DT_MAP.get(charsetName);
		Settings settings = SettingsImpl.NO_SETTINGS;
		if (stringDT == null) {
			stringDT = StringDataType.dataType;
			settings = new SettingsImpl();
			CharsetSettingsDefinition.CHARSET.setCharset(settings, charsetName);
		}
		int charSize = CharsetInfo.getInstance().getCharsetCharSize(charsetName);

		updateTrigramStringValidator(stringModelFilenameComboBox.getText());
		boolean requireValidStrings = requireValidStringCB.isSelected();
		boolean breakOnRef = breakOnRefCB.isSelected();

		currentOptions = new EncodedStringsOptions(stringDT, settings, charsetName,
			scriptOptions ? getRequiredScripts() : null, scriptOptions ? getAllowedScripts() : null,
			excludeStringsWithErrors, excludeStringsWithNonStdCtrlChars, alignStartofString,
			charSize, minStrLen, breakOnRef, stringValidator, requireValidStrings);
	}
For test/screen shot use

@return button
Ghidra/Features/Base/src/main/java/ghidra/app/plugin/core/strings/EncodedStringsDialog.java