private void createDataType(ListingActionContext context) {
		int maxSize = getSelectedVariableStorageSize(context);

		DataType dataType = getUserSelectedDataType(context, maxSize);
		if (dataType != null) {
			plugin.createData(dataType, context, false, true);
		}
	}
An action that allows the user to change or select a data type.
Ghidra/Features/Base/src/main/java/ghidra/app/plugin/core/function/ChooseDataTypeAction.java