Class Preferences


  • public class Preferences
    extends java.lang.Object
    This class reads the MIPAV preference file. The preference file stores a number of user specific parameters of the application. It is stored in the /mipav directory so that it can be read and written to by the user. It is a text file and can be manually edited - not recommended.
    • Constructor Summary

      Constructors 
      Constructor Description
      Preferences()  
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      static boolean addShortcut​(java.lang.String command)
      Adds a new shortcut to the hashtable. if there is already a command predefined for the keystroke set from setShortcut(), it will be removed then replaced with the new command.
      static boolean addShortcut​(java.lang.String command, javax.swing.KeyStroke shortcut)
      Adds a new shortcut to the hashtable with a given keystroke. if there is already a command predefined for the keystroke set from setShortcut(), it will be removed then replaced with the new command.
      private static java.util.Hashtable<java.lang.String,​javax.swing.KeyStroke> buildDefaultShortcuts()
      Builds the default shortcut hashtable (not user modifiable).
      static void buildShortcutTable()
      Builds a hashtable of actioncommands (keys) with associated keystrokes from the Preferences file.
      static void data​(java.lang.String string)
      Prints to data tab
      static void debug​(java.lang.String string)
      If at least one debug level is turned on, output the string.
      static void debug​(java.lang.String string1, boolean string2, java.lang.String string3, int category)
      If the debug is turned on for the given level, output to the messageFrame.
      static void debug​(java.lang.String string1, boolean string2, java.lang.String string3, int category, Preferences.LogLevel level)
      If the debug is turned on for the given level, output to the messageFrame.
      static void debug​(java.lang.String string1, char string2, java.lang.String string3, int category)
      If the debug is turned on for the given level, output to the messageFrame.
      static void debug​(java.lang.String string1, char string2, java.lang.String string3, int category, Preferences.LogLevel level)
      If the debug is turned on for the given level, output to the messageFrame.
      static void debug​(java.lang.String string1, double string2, java.lang.String string3, int category)
      If the debug is turned on for the given level, output to the messageFrame.
      static void debug​(java.lang.String string1, double string2, java.lang.String string3, int category, Preferences.LogLevel level)
      If the debug is turned on for the given level, output to the messageFrame.
      static void debug​(java.lang.String string, int category)
      If the debug is turned on for the given level, output to the messageFrame.
      static void debug​(java.lang.String string, int category, Preferences.LogLevel level)
      If the debug is turned on for the given level, output to the messageFrame.
      static void debug​(java.lang.String string1, java.lang.Object string2, java.lang.String string3, int category)
      If the debug is turned on for the given level, output to the messageFrame.
      static void debug​(java.lang.String string1, java.lang.Object string2, java.lang.String string3, int category, Preferences.LogLevel level)
      If the debug is turned on for the given level, output to the messageFrame.
      static void debug​(java.lang.String string1, java.lang.String string2)
      If at least one debug level is turned on, output the string.
      static void debug​(java.lang.String string1, java.lang.String string2, int category)
      If the debug is turned on for the given level, output to the messageFrame.
      static void debug​(java.lang.String string1, java.lang.String string2, int category, Preferences.LogLevel level)
      If the debug is turned on for the given level, output to the messageFrame.
      static void debug​(java.lang.String string1, java.lang.String string2, java.lang.String string3)
      If at least one debug level is turned on, output the string.
      static void debug​(java.lang.String string1, java.lang.String string2, java.lang.String string3, int category)
      If the debug is turned on for the given level, output to the messageFrame.
      static void debug​(java.lang.String string1, java.lang.String string2, java.lang.String string3, int category, Preferences.LogLevel level)
      If the debug is turned on for the given level, output to the messageFrame.
      static void debug​(java.lang.String string1, java.lang.String string2, java.lang.String string3, java.lang.String string4)
      If at least one debug level is turned on, output the string.
      static void debug​(java.lang.String string1, java.lang.String string2, java.lang.String string3, java.lang.String string4, int category)
      If the debug is turned on for the given level, output to the messageFrame.
      static void debug​(java.lang.String string1, java.lang.String string2, java.lang.String string3, java.lang.String string4, int category, Preferences.LogLevel level)
      If the debug is turned on for the given level, output to the messageFrame.
      static void debug​(java.lang.String string1, java.lang.String string2, java.lang.String string3, java.lang.String string4, java.lang.String string5)
      If at least one debug level is turned on, output the string.
      static void debug​(java.lang.String string1, java.lang.String string2, java.lang.String string3, java.lang.String string4, java.lang.String string5, int category)
      If the debug is turned on for the given level, output to the messageFrame.
      static void debug​(java.lang.String string1, java.lang.String string2, java.lang.String string3, java.lang.String string4, java.lang.String string5, int category, Preferences.LogLevel level)
      If the debug is turned on for the given level, output to the messageFrame.
      static boolean debugLevel​(int category)
      Indicates whether debug is turned on for the given level.
      static void debugMessageFrameAppend​(java.lang.String string)
      Appends the specified message to the message frame.
      static Preferences.ComplexDisplay getComplexDisplay()
      Returns how pixel values are displayed on the MIPAV toolbar for complex images.
      static java.lang.String getData()
      Gets all the text printed to the data panel.
      static java.lang.String getDebug()
      Gets all the text printed to the debug panel.
      static Preferences.LogConfig getDebugPreferences()
      Gets the LogConfiguration for logging categories (minor, algorithm, fileIO, comms, scripting).
      static Preferences.DefaultDisplay getDefaultDisplay()
      Returns how pixel values of images are displayed in terms or brightness values and possible colors.
      static float getDefaultFrameRate()
      Gets the default frame rate used in saving AVI movies.
      static java.lang.String getDefaultHostKey()
      Accessor to get the default chat/file server host key.
      static java.lang.String getDefaultServerKey()
      Accessor to get default DICOM image server key.
      static java.util.Hashtable<java.lang.String,​javax.swing.KeyStroke> getDefaultShortcutTable()
      Gets the Default Hashtable used to store the shortcut keystrokes and commands.
      static java.lang.String getDefaultStorageKey()
      Accessor to get default DICOM image storage location.
      static java.util.Vector<java.lang.String> getDICOMBrowserTableConfiguration()
      Gets the user-configured columns that indicate the DICOM tags that are displayed in the DICOM browser table.
      static java.lang.String getDICOMSaveDictionary()
      Accessor to get the default DICOM Save Dictionary (which tags to save into XML header.
      static int getFileFilter()
      Returns the index of the latest used file filter.
      static java.lang.String getFileTempDir()
      Returns the temporary directory which is used to store files to be deleted.
      static java.lang.String getHostIP​(java.lang.String AETitle)
      Accessor to get host (chat/file) server Internet Protocol for selected Name.
      static java.lang.String getIconName()
      Returns the name of the application icon.
      static java.lang.String getImageDirectory()
      Returns the image directory used last time.
      static Preferences.InterpolateDisplay getInterpolateDisplay()
      Returns how pixel values are interpolated for displayed slices.
      static java.lang.String getIP​(java.lang.String AETitle)
      Accessor to get DICOM image server Internet Protocol for selected AETitle.
      static java.lang.String getLastImageAt​(int index)
      Returns the image name of "last X images" at the given index.
      static java.lang.String getLastOpenSequenceChannels()
      Used by ViewOpenImageSequence to get the saved number of channels used when opening an image sequence.
      static java.lang.String getLastOpenSequenceOrdering()
      Used by ViewOpenImageSequence to get the Z-C-T ordering of data used when opening an image sequence.
      static java.lang.String getLastOpenSequencePath()
      Used by ViewOpenImageSequence to get the last path used when opening an image sequence.
      static java.lang.String getLastOpenSequenceSlices()
      Used by ViewOpenImageSequence to get the saved number of slices used when opening an image sequence.
      static java.lang.String getLastOpenSequenceTimePoints()
      Used by ViewOpenImageSequence to get the saved number of time points used when opening an image sequence.
      static java.lang.String[] getLastXImages()
      Gets the names of the last X number of images that were loaded from the Preferences file.
      static int getMaxDebugLines()  
      static java.util.Properties getMipavProps()  
      static java.lang.String getNextHostKey()
      Returns the next host key.
      static java.lang.String getNextServerKey()
      Returns the next server key.
      static java.lang.String getNextStorageKey()
      Returns the next storage key.
      static int getNumberOfThreads()
      The number of threads available for MIPAV for processing.
      static java.lang.String[] getOverlayNames​(boolean isDicom)
      Retrieves the list of overlay names (user can type whatever).
      static java.lang.String[] getOverlays​(boolean isDicom)
      Gets the image overlay codes (they identify what to display in the corners of the image), from the preference file.
      static java.lang.String getPluginInstallDirectory()
      Returns the directory last used for installing plugins.
      static java.lang.String getPluginUserDir()
      Returns String indicating the directory where plugin class files are stored.
      static int getPort​(java.lang.String AETitle)
      Accessor to get DICOM image server's port for selected AETitle.
      static java.lang.String getPreferencesDir()
      Return the directory where mipav-generated, user-specific files should be placed.
      static java.lang.String getProperty​(java.lang.String key)
      Accessor to return a specfic properties given a key.
      static java.lang.String getScriptFile()
      DOCUMENT ME!
      static java.lang.String getScriptsDirectory()
      Returns the default script directory. if null, returns the user's current working directory + "scripts"
      static javax.swing.KeyStroke getShortcut​(java.lang.String command)
      Returns a keystroke shortcut for the given command.
      static java.lang.String getShortcutCommand​(javax.swing.KeyStroke ks)
      Gets the command associated with the shortcut (if there is one).
      static java.awt.Dimension getSubsampleDimensions()
      Used by ViewOpenImageSequence to get the subsample dimensions that were saved in the preferences file.
      static boolean getTrimAdjacient()
      Accessor to get the trim parameter (trimming contour of adjacent points).
      static float getTrimMask()
      Accessor to get the TRIM parameter (trimming VOIcontour of points).
      static float getTrimVoi()
      Accessor to get the TRIM parameter (trimming VOIcontour of points).
      static java.util.Hashtable<java.lang.String,​javax.swing.KeyStroke> getUserShortcutTable()
      Gets the User defined Hashtable used to store the shortcut keystrokes and commands.
      static int getVOIColorIncrement()
      Gets the VOI color increment value.
      static java.awt.Color getVOIDrawColor()
      Gets the VOI draw color.
      static int getVOIThickness()
      DOCUMENT ME!
      static void initDebugPreferences()
      this method must be invoked very early on in the startup sequence (typically in the startup main method or ViewUserInterface.
      static boolean is​(java.lang.String propertyName)
      Gets the boolean state of the property, where in the preferences file the "yes", "on", "true" all return true, but anything else (or non-existent property) returns false.
      static boolean isDebug()
      Returns flag indicating if the debug flag is true or false.
      static boolean isDefaultCommand​(java.lang.String command)
      DOCUMENT ME!
      static boolean isDefaultKeyStroke​(javax.swing.KeyStroke ks)
      DOCUMENT ME!
      static boolean isGpuCompEnabled()
      Indicates whether GPU-computing should be enabled.
      static boolean isHistogramDisplay()
      Indicates whether the image display should be updated in real-time as histogram LUTs are changed
      static boolean isInterpolateDisplay()
      Maintained for backwards compatibility.
      static boolean isLogAlgorithmEnabled()  
      boolean isLogCommsEnabled()  
      static boolean isLogFileIOEnabled()  
      static boolean isLogMinorEnabled()  
      boolean isLogScriptingEnabled()  
      static boolean isMultiThreadingEnabled()
      Indicates whether multi-threading should be enabled for algorithms.
      static boolean isPreference​(java.lang.String propertyName)
      Gets the boolean state of the property, where in the preferences file the "yes", "on", "true" all return true, but anything else (or non-existent property) returns false.
      static boolean isPreferenceSet​(java.lang.String propertyName)
      Returns whether the user has a preference indicated for a particular property.
      static void print()
      Prints mipav.preferences to System.out.
      static boolean read()
      Reads the "mipav.preferences" file from the user's 'home' directory.
      static void removeProperty​(java.lang.String key)
      Removes the property key from the MIPAV property list.
      static void removeShortcut​(java.lang.String commandToRemove)
      Removes a shortcut from the table.
      static void resetToDefaults()
      Resets the current MIPAV properties to the defaults and saves the preferences file.
      static boolean save()
      Saves preference file to the user's 'home' directory.
      static void saveShortcuts()
      Sets the property for shortcuts by building string from ViewUserInterface's Shortcut Hashtable.
      static void saveSubsampleDimensions​(java.awt.Dimension subsampleDimension)
      Used by ViewOpenImageSequence to save its subsample dimensions for the next time it is opened.
      static void setAlwaysSaveImgAsAnalyze​(boolean doSaveAnalyze)
      Sets whether all imgs should be saved in analyze format (i.e., don't ask about whether to save as analyze/interfile/nifti).
      static void setAlwaysSaveImgAsInterfile​(boolean doSaveInterfile)
      Sets whether all imgs should be saved in interfile format (i.e., don't ask about whether to save as analyze/interfile/nifti).
      static void setAlwaysSaveImgAsNifti​(boolean doSaveNifti)
      Sets whether all imgs should be saved in nifti format (i.e., don't ask about whether to save as analyze/interfile/nifti).
      static void setAlwaysSaveMncAsMinc1​(boolean doSaveMinc1)
      Sets whether all mncs should be saved in minc1 cdf format (i.e., don't ask about whether to save as minc1/minc2).
      static void setAlwaysSaveMncAsMinc2​(boolean doSaveMinc2)
      Sets whether all mncs should be saved in minc2 hdf5 format (i.e., don't ask about whether to save as minc1/minc2).
      static void setCurrentShortcut​(javax.swing.KeyStroke ks)
      Sets the current keystroke shortcut for assignment once a command has been passed in.
      static void setDebugLevels​(java.util.Map<java.lang.Integer,​java.lang.String> debugLevels)
      Sets the debug levels
      static void setDefaultDisplay​(Preferences.DefaultDisplay display)
      Sets the default display mode for 2D/3D image display.
      static boolean setDICOMBrowserTableConfiguration​(java.util.Vector<java.lang.String> newConfiguration)
      Sets the user-configured columns that indicate the DICOM tags that are displayed in the DICOM browser table.
      static void setFileFilter​(int fileFilterIndex)
      Sets the current used file filter as the latest used file filter.
      static void setFileTempDir​(java.lang.String tempDir)
      Sets the temporary directory which is used for files which will be deleted.
      static void setImageDirectory​(java.io.File imageDirectory)
      Sets the image directory as the latest used image directory.
      static void setInterpolationMode​(Preferences.InterpolateDisplay interp)
      Sets the display interpolation mode for 2D image display.
      static void setLastImage​(java.lang.String name, boolean multiFile, int numDims)
      Sets the last image loaded in the Preferences file.
      static void setLastOpenSequenceParams​(java.lang.String slices, java.lang.String channels, java.lang.String timePoints, java.lang.String ordering)
      Used by ViewOpenImageSequence to save the user's most recent slices, channels, time points, and ordering that were specified in the component.
      static void setLastOpenSequencePath​(java.lang.String path)
      Used by ViewOpenImageSequence to save the path used when opening an image sequence.
      void setLogLevelAlgorithm​(Preferences.LogLevel level)  
      void setLogLevelComms​(Preferences.LogLevel level)  
      void setLogLevelFileIO​(Preferences.LogLevel level)  
      void setLogLevelMinor​(Preferences.LogLevel level)  
      void setLogLevelScripting​(Preferences.LogLevel level)  
      static void setMaxDebugLines​(int lines)
      Sets the maximum number of debug lines that are output
      static void setMessageFrame​(ViewJFrameMessage mFrame)
      Sets the message frame.
      static void setOverlayNames​(boolean isDicom, java.lang.String[] overlays)
      Sets the labels for each overlay position.
      static void setOverlays​(boolean isDicom, java.lang.String[] overlays)
      Sets the overlay tag identifiers in the preference file.
      static void setPluginInstallDirectory​(java.io.File pluginInstallDirectory)
      Sets the plugin install directory.
      static void setPreferencesFileDirectory​(java.lang.String fileDir)
      Change the file directory of the preferences file.
      static void setPreferencesFileName​(java.lang.String fileName)
      Change the file name of the preferences file we should use (without any path).
      static boolean setProperty​(java.lang.String key, java.lang.Object value)
      Sets the property key in the MIPAV property list and saves it to a file.
      static void setScriptFile​(java.lang.String scriptFile)
      DOCUMENT ME!
      static void setScriptsDirectory​(java.lang.String scriptsDirectory)
      Sets the scripts directory to the new scripts directory.
      static void setShowDICOMOverlays​(boolean doShow)
      Sets whether to show the DICOM overlays.
      static void setShowImageOverlays​(boolean doShow)
      Sets whether to show the Image overlays.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • PREF_SAVE_ALL_ON_SAVE

        public static final java.lang.String PREF_SAVE_ALL_ON_SAVE
        Constant that indicates use of saving images, vois, and transfer functions.
        See Also:
        Constant Field Values
      • PREF_SAVE_XML_THUMBNAIL

        public static final java.lang.String PREF_SAVE_XML_THUMBNAIL
        Constant that indicates the saving of the xml thumbnail during a save.
        See Also:
        Constant Field Values
      • PREF_FLIP_NIFTI_READ

        public static final java.lang.String PREF_FLIP_NIFTI_READ
        See Also:
        Constant Field Values
      • PREF_FILE_TEMP_DIR

        public static final java.lang.String PREF_FILE_TEMP_DIR
        Constant that indicates the file temp directory.
        See Also:
        Constant Field Values
      • PREF_LAX_CHECK

        public static final java.lang.String PREF_LAX_CHECK
        Constant that indicates if lax file should be checked on mipav start.
        See Also:
        Constant Field Values
      • PREF_CLOSE_FRAME_CHECK

        public static final java.lang.String PREF_CLOSE_FRAME_CHECK
        Constant that indicates if user should be prompted on closing a frame.
        See Also:
        Constant Field Values
      • PREF_OVERWRITE_VOI_STATS

        public static final java.lang.String PREF_OVERWRITE_VOI_STATS
        Constant indicating if VOI statistics file should be overwritten.
        See Also:
        Constant Field Values
      • PREF_DATA_PROVENANCE

        public static final java.lang.String PREF_DATA_PROVENANCE
        Constant that indicates if data provenance is turned on.
        See Also:
        Constant Field Values
      • PREF_IMAGE_LEVEL_DATA_PROVENANCE

        public static final java.lang.String PREF_IMAGE_LEVEL_DATA_PROVENANCE
        Constant that indicates if data provenance is turned on for individual images (and saved on image-save).
        See Also:
        Constant Field Values
      • PREF_DATA_PROVENANCE_FILENAME

        public static final java.lang.String PREF_DATA_PROVENANCE_FILENAME
        Constant that indicates the path where the system data provenance should be stored
        See Also:
        Constant Field Values
      • PREF_DEBUG

        public static final java.lang.String PREF_DEBUG
        Constant for debug string.
        See Also:
        Constant Field Values
      • PREF_LOGGING_ENABLED

        public static final java.lang.String PREF_LOGGING_ENABLED
        Constant for whether logging is enabled
        See Also:
        Constant Field Values
      • PREF_QUICK_MASK_NEW

        public static final java.lang.String PREF_QUICK_MASK_NEW
        Constant that indicates if the Quick Mask operation should output to a new image
        See Also:
        Constant Field Values
      • PREF_PAINT_TO_MASK_NEW

        public static final java.lang.String PREF_PAINT_TO_MASK_NEW
        Constant that indicates if the Paint-to-Mask operation should output to a new image
        See Also:
        Constant Field Values
      • PREF_ZOOM_LINEAR

        public static final java.lang.String PREF_ZOOM_LINEAR
        Constant that indicates if the zoom should be linear (otherwise geometric)
        See Also:
        Constant Field Values
      • PREF_INTENSITY_LABEL_COLOR

        public static final java.lang.String PREF_INTENSITY_LABEL_COLOR
        Constant that indicates the intensity label color.
        See Also:
        Constant Field Values
      • PREF_INTENSITY_LABEL_BACKGROUND_COLOR

        public static final java.lang.String PREF_INTENSITY_LABEL_BACKGROUND_COLOR
        Constant that indicates the intensity label background color.
        See Also:
        Constant Field Values
      • PREF_DEFAULT_FRAME_RATE

        public static final java.lang.String PREF_DEFAULT_FRAME_RATE
        Constant that indicates the default frame rate
        See Also:
        Constant Field Values
      • PREF_SAVE_DEFAULTS

        public static final java.lang.String PREF_SAVE_DEFAULTS
        Constant that indicates if the last used parameters for algorithm dialogs should be used when they are opened.
        See Also:
        Constant Field Values
      • PREF_SAVE_PROMPT_OVERWRITE

        public static final java.lang.String PREF_SAVE_PROMPT_OVERWRITE
        Constant that indicates if a prompt should be shown before an image file is overwritten.
        See Also:
        Constant Field Values
      • PREF_SHOW_DICOM_OVERLAYS

        public static final java.lang.String PREF_SHOW_DICOM_OVERLAYS
        Constant that indicates if the DICOM overlay should be shown.
        See Also:
        Constant Field Values
      • PREF_SHOW_IMAGE_OVERLAYS

        public static final java.lang.String PREF_SHOW_IMAGE_OVERLAYS
        Constant that indicates if the image overlay should be shown.
        See Also:
        Constant Field Values
      • PREF_SHOW_PAINT_BORDER

        public static final java.lang.String PREF_SHOW_PAINT_BORDER
        Constant that indicates if the paint border shown.
        See Also:
        Constant Field Values
      • PREF_SHOW_PRIVATE_TAGS

        public static final java.lang.String PREF_SHOW_PRIVATE_TAGS
        Constant that indicates if the private DICOM tags are to be shown
        See Also:
        Constant Field Values
      • PREF_SHOW_SPLASH

        public static final java.lang.String PREF_SHOW_SPLASH
        Constant that indicates if the splash graphic should be shown when mipav starts.
        See Also:
        Constant Field Values
      • PREF_SHOW_UI_LF

        public static final java.lang.String PREF_SHOW_UI_LF
        Class name for selected look and feel type, can also be "None" (default selection)
        See Also:
        Constant Field Values
      • PREF_LOG_FILENAME

        public static final java.lang.String PREF_LOG_FILENAME
        Constant that indicates the pathname of the log file.
        See Also:
        Constant Field Values
      • PREF_IMAGE_TOOLBAR_ON

        public static final java.lang.String PREF_IMAGE_TOOLBAR_ON
        Constant identifying if the miscellaneous toolbar is on by default.
        See Also:
        Constant Field Values
      • PREF_PAINT_TOOLBAR_ON

        public static final java.lang.String PREF_PAINT_TOOLBAR_ON
        Constant indicating if the Paint Toolbar is on by default.
        See Also:
        Constant Field Values
      • PREF_SCRIPTING_TOOLBAR_ON

        public static final java.lang.String PREF_SCRIPTING_TOOLBAR_ON
        Constant that indicates if the Scripting toolbar should be shown by default.
        See Also:
        Constant Field Values
      • PREF_VOI_TOOLBAR_ON

        public static final java.lang.String PREF_VOI_TOOLBAR_ON
        Constant indicating if the VOI Toolbar is on by default.
        See Also:
        Constant Field Values
      • PREF_SHORTCUTS

        public static final java.lang.String PREF_SHORTCUTS
        Constant indicating the application shortcuts (user defined).
        See Also:
        Constant Field Values
      • PREF_DICOM_BROWSER_CONFIG

        public static final java.lang.String PREF_DICOM_BROWSER_CONFIG
        Constant indicating the DICOM browser configuration.
        See Also:
        Constant Field Values
      • PREF_FAST_TRIPLANAR_REPAINT

        public static final java.lang.String PREF_FAST_TRIPLANAR_REPAINT
        Constant that indicates whether the triplanar frame should wait for a mouse released event before repainting all 9 tri-planar images. Inserted here because repainting 9 images in real time gets to be tedious.
        See Also:
        Constant Field Values
      • PREF_TRIPLANAR_SNAP90

        public static final java.lang.String PREF_TRIPLANAR_SNAP90
        Constant that indicates if triplanar protractor should snap to nearest multiple of 90 degrees.
        See Also:
        Constant Field Values
      • PREF_TRIPLANAR_SCROLL_ORIGINAL

        public static final java.lang.String PREF_TRIPLANAR_SCROLL_ORIGINAL
        Constant that indicates if the triplanar should scroll the original image
        See Also:
        Constant Field Values
      • PREF_SHOW_LINE_ANGLE

        public static final java.lang.String PREF_SHOW_LINE_ANGLE
        Constant that indicates whether the angle of line VOIs should be shown on screen.
        See Also:
        Constant Field Values
      • PREF_CONTINUOUS_VOI_CONTOUR

        public static final java.lang.String PREF_CONTINUOUS_VOI_CONTOUR
        Constant that indicates whether [SHIFT] must be held down to draw continuous contours (false = hold-shift).
        See Also:
        Constant Field Values
      • PREF_VOI_POINT_DRAW_TYPE

        public static final java.lang.String PREF_VOI_POINT_DRAW_TYPE
        Constant indicating the look of VOI Points drawn on an image.
        See Also:
        Constant Field Values
      • PREF_VOI_LPS_SAVE

        public static final java.lang.String PREF_VOI_LPS_SAVE
        Constant indicating if VOIs should be saved as LPS or file coordinates
        See Also:
        Constant Field Values
      • PREF_TRIPLANAR_2X2_LAYOUT

        public static final java.lang.String PREF_TRIPLANAR_2X2_LAYOUT
        Constant that indicates whether the triplanar frame should use the old 2x2 layout or the newer 3x1 layout.
        See Also:
        Constant Field Values
      • PREF_CROSSHAIR_PIXEL_GAP

        public static final java.lang.String PREF_CROSSHAIR_PIXEL_GAP
        Constant that indicates the pixel gap away from the center of the crosshair (in one direction) actual gap is 2x.
        See Also:
        Constant Field Values
      • PREF_MENU_FONT

        public static final java.lang.String PREF_MENU_FONT
        Constant that indicates the menu font.
        See Also:
        Constant Field Values
      • PREF_MENU_FONT_SIZE

        public static final java.lang.String PREF_MENU_FONT_SIZE
        Constant that indicates the menu font size.
        See Also:
        Constant Field Values
      • PREF_MENU_FONT_COLOR

        public static final java.lang.String PREF_MENU_FONT_COLOR
        Constant that indicates the menu font color.
        See Also:
        Constant Field Values
      • PREF_SHOW_VOI_NAME

        public static final java.lang.String PREF_SHOW_VOI_NAME
        Constant that indicates whether to show the VOI name.
        See Also:
        Constant Field Values
      • PREF_SHOW_OUTPUT

        public static final java.lang.String PREF_SHOW_OUTPUT
        Constant that indicates whether to show output.
        See Also:
        Constant Field Values
      • PREF_LAST_STACK_FLAG

        public static final java.lang.String PREF_LAST_STACK_FLAG
        Constant that indicates the last stack flag.
        See Also:
        Constant Field Values
      • PREF_DEFAULT_IMAGE_BROWSER_DIR

        public static final java.lang.String PREF_DEFAULT_IMAGE_BROWSER_DIR
        Constant that indicates the initial directory in which to open the file chooser of the image browser.
        See Also:
        Constant Field Values
      • PREF_MULTI_THREADING_ENABLED

        public static final java.lang.String PREF_MULTI_THREADING_ENABLED
        Constant that indicated if the multi-theading is enabled
        See Also:
        Constant Field Values
      • PREF_GPU_COMP_ENABLED

        public static final java.lang.String PREF_GPU_COMP_ENABLED
        Constant that indicates if computing on the GPU is enabled
        See Also:
        Constant Field Values
      • PREF_NUMBER_OF_THREADS

        public static final java.lang.String PREF_NUMBER_OF_THREADS
        Constant that specifies how many system threads user would like MIPAV to use
        See Also:
        Constant Field Values
      • PREF_SHOW_INTENSITY_ON_LEFT_CLICK

        public static final java.lang.String PREF_SHOW_INTENSITY_ON_LEFT_CLICK
        Constant that indicates if left mouse click inside image should cause intensity value to display
        See Also:
        Constant Field Values
      • PREF_SHOW_WINLEV_ON_RIGHT_CLICK

        public static final java.lang.String PREF_SHOW_WINLEV_ON_RIGHT_CLICK
        Constant that indicates if right mouse click inside image should cause window/level changes
        See Also:
        Constant Field Values
      • PREF_RELATIVE_WINDOW_LEVEL

        public static final java.lang.String PREF_RELATIVE_WINDOW_LEVEL
        Constant that indicates if window/level changes should be relative to the current transfer function values
        See Also:
        Constant Field Values
      • PREF_OPEN_IMAGES_IN_TILED_FORMAT

        public static final java.lang.String PREF_OPEN_IMAGES_IN_TILED_FORMAT
        Constant that indicates if images are to be open im tiled format
        See Also:
        Constant Field Values
      • PREF_LAST_PAINT_BRUSH

        public static final java.lang.String PREF_LAST_PAINT_BRUSH
        Constant that indicates the last used paint brush so that it will be set as the default when new images are opened or mipav is restarted.
        See Also:
        Constant Field Values
      • PREF_USER_FILETYPE_ASSOC

        public static final java.lang.String PREF_USER_FILETYPE_ASSOC
        Constant that indicates the user defined file type associations.
        See Also:
        Constant Field Values
      • PREF_USER_FILETYPES

        public static final java.lang.String PREF_USER_FILETYPES
        Constant that indicates the user defined file types.
        See Also:
        Constant Field Values
      • PREF_USER_FILETYPES_TEXTFIELDS

        public static final java.lang.String PREF_USER_FILETYPES_TEXTFIELDS
        ?
        See Also:
        Constant Field Values
      • PREF_FILENAME_FILTER

        public static final java.lang.String PREF_FILENAME_FILTER
        Constant that indicates the filename filter.
        See Also:
        Constant Field Values
      • PREF_IMAGE_DIR

        public static final java.lang.String PREF_IMAGE_DIR
        Constant that indicates the current image directory.
        See Also:
        Constant Field Values
      • PREF_PLUGIN_INSTALL_DIR

        public static final java.lang.String PREF_PLUGIN_INSTALL_DIR
        Constant that indicates the current directory where plugins can be installed from.
        See Also:
        Constant Field Values
      • PREF_VOI_TEXT_COLOR

        public static final java.lang.String PREF_VOI_TEXT_COLOR
        Constant that indicates the last used VOI text color.
        See Also:
        Constant Field Values
      • PREF_VOI_TEXT_BACKGROUND_COLOR

        public static final java.lang.String PREF_VOI_TEXT_BACKGROUND_COLOR
        Constant that indicates the last used VOI text background color.
        See Also:
        Constant Field Values
      • PREF_DICOM_STORAGE_DIR

        public static final java.lang.String PREF_DICOM_STORAGE_DIR
        Constant that indicates the default dicom storage directory.
        See Also:
        Constant Field Values
      • PREF_AUTOSTART_DICOM_RECEIVER

        public static final java.lang.String PREF_AUTOSTART_DICOM_RECEIVER
        Constant that indicates whether to enable the dicom receiver on startup.
        See Also:
        Constant Field Values
      • PREF_ASK_DICOM_RECEIVER

        public static final java.lang.String PREF_ASK_DICOM_RECEIVER
        Constant that indicates whether to ask about starting dicom receiver on startup.
        See Also:
        Constant Field Values
      • PREF_ACTIVE_IMAGE_COLOR

        public static final java.lang.String PREF_ACTIVE_IMAGE_COLOR
        Constant that indicates the active image color.
        See Also:
        Constant Field Values
      • PREF_ACTIVE_IMAGE_COLOR_BORDERSIZE

        public static final java.lang.String PREF_ACTIVE_IMAGE_COLOR_BORDERSIZE
        Constant that indicates the active image color border size
        See Also:
        Constant Field Values
      • PREF_QUICKLIST_NUMBER

        public static final java.lang.String PREF_QUICKLIST_NUMBER
        number of recently used images to store in quicklist.
        See Also:
        Constant Field Values
      • PREF_LAST_X_IMAGES

        public static final java.lang.String PREF_LAST_X_IMAGES
        constant for the names of the last X number of images used to be shown in quicklist.
        See Also:
        Constant Field Values
      • PREF_WARN_AUDIO_AVI

        public static final java.lang.String PREF_WARN_AUDIO_AVI
        constant for warning the user when audio will be discarded from opened AVIs.
        See Also:
        Constant Field Values
      • PREF_OVERWRITE_STATISTICS

        public static final java.lang.String PREF_OVERWRITE_STATISTICS
        constant on whether to overwrite the voi statistics file automatically
        See Also:
        Constant Field Values
      • PREF_CROSSHAIR_CURSOR

        public static final java.lang.String PREF_CROSSHAIR_CURSOR
        Constant that indicates the crosshair cursor to be used.
        See Also:
        Constant Field Values
      • PREF_DEFAULT_DISPLAY

        public static final java.lang.String PREF_DEFAULT_DISPLAY
        Constant to indicate default brightness and color display to screen
        See Also:
        Constant Field Values
      • PREF_COMPLEX_DISPLAY

        public static final java.lang.String PREF_COMPLEX_DISPLAY
        Constant that indicates method used to display complex data values on MIPAV toolbar (MIPAV visually always shows magnitude or log magnitude).
        See Also:
        Constant Field Values
      • PREF_LOGMAG_DISPLAY

        public static final java.lang.String PREF_LOGMAG_DISPLAY
        Constant that indicates whether the log of the magnitude of an image is used for image display
        See Also:
        Constant Field Values
      • PREF_AFNI_ORDER_LOAD

        public static final java.lang.String PREF_AFNI_ORDER_LOAD
        Constant that indicates whether DICOM ordering should be used by default for loading AFNI images
        See Also:
        Constant Field Values
      • PREF_FILE_LUT_DISPLAY

        public static final java.lang.String PREF_FILE_LUT_DISPLAY
        Constant that indicates whether image will display using a stored LUT (from image file or generic to image type)
        See Also:
        Constant Field Values
      • PREF_INTERPOLATE_MODE

        public static final java.lang.String PREF_INTERPOLATE_MODE
        Constant that indicates the mode of image interpolation used for display
        See Also:
        Constant Field Values
      • PREF_HISTOGRAM_DISPLAY

        public static final java.lang.String PREF_HISTOGRAM_DISPLAY
        Constant that indicates whether image is updated in real-time on histogram changes
        See Also:
        Constant Field Values
      • PREF_TRIM_VOI

        public static final java.lang.String PREF_TRIM_VOI
        Constant that indicates the VOI Trim level variable.
        See Also:
        Constant Field Values
      • PREF_TRIM_MASK

        public static final java.lang.String PREF_TRIM_MASK
        Constant that indicates the mask trim level variable.
        See Also:
        Constant Field Values
      • PREF_TRIM_FLAG

        public static final java.lang.String PREF_TRIM_FLAG
        Constant that indicates the VOI Trim flag for trimming adjacent points.
        See Also:
        Constant Field Values
      • PREF_VOI_THICKNESS

        public static final java.lang.String PREF_VOI_THICKNESS
        Constant indicating the VOI Thickness.
        See Also:
        Constant Field Values
      • PREF_VOI_DRAW_COLOR

        public static final java.lang.String PREF_VOI_DRAW_COLOR
        the voi draw color constant.
        See Also:
        Constant Field Values
      • PREF_VOI_START_COLOR

        public static final java.lang.String PREF_VOI_START_COLOR
        the starting color for VOIs (first drawn).
        See Also:
        Constant Field Values
      • PREF_DATA_PROVENANCE_MODE

        public static final java.lang.String PREF_DATA_PROVENANCE_MODE
        constant for logging.
        See Also:
        Constant Field Values
      • PREF_RGB_PAINT_COMPONENTS

        public static final java.lang.String PREF_RGB_PAINT_COMPONENTS
        Constant indicating which channels should be used for applying paint to a RGB image
        See Also:
        Constant Field Values
      • PREF_ALWAYS_SAVE_IMG_AS_ANALYZE

        public static final java.lang.String PREF_ALWAYS_SAVE_IMG_AS_ANALYZE
        Constant that indicates whether .hdr/.img files should always be written in analyze format (as opposed to asking whether to save as interfile or nifti).
        See Also:
        Constant Field Values
      • PREF_ALWAYS_SAVE_IMG_AS_INTERFILE

        public static final java.lang.String PREF_ALWAYS_SAVE_IMG_AS_INTERFILE
        Constant that indicates whether .hdr/.img files should always be written in interfile format (as opposed to asking whether to save as analyze or nifti).
        See Also:
        Constant Field Values
      • PREF_ALWAYS_SAVE_IMG_AS_NIFTI

        public static final java.lang.String PREF_ALWAYS_SAVE_IMG_AS_NIFTI
        Constant that indicates whether .hdr/.img files should always be written in nifti format (as opposed to asking whether to save as analyze or interfile).
        See Also:
        Constant Field Values
      • PREF_ALWAYS_SAVE_MNC_AS_MINC1

        public static final java.lang.String PREF_ALWAYS_SAVE_MNC_AS_MINC1
        Constant that indicates whether .mnc files should always be written in minc1 CDF format (as opposed to asking whether to save as minc1 or minc2).
        See Also:
        Constant Field Values
      • PREF_ALWAYS_SAVE_MNC_AS_MINC2

        public static final java.lang.String PREF_ALWAYS_SAVE_MNC_AS_MINC2
        Constant that indicates whether .mnc files should always be written in minc2 HDF5 format (as opposed to asking whether to save as minc1 or minc2).
        See Also:
        Constant Field Values
      • PREF_SCRIPT_DIR

        public static final java.lang.String PREF_SCRIPT_DIR
        Constant that indicates the script directory.
        See Also:
        Constant Field Values
      • PREF_LAST_SCRIPT

        public static final java.lang.String PREF_LAST_SCRIPT
        Constant that indicates the last script that was run.
        See Also:
        Constant Field Values
      • PREF_DICOM_SAVE_DICTIONARY

        public static final java.lang.String PREF_DICOM_SAVE_DICTIONARY
        constant that indicates the dicom save dictionary.
        See Also:
        Constant Field Values
      • PREF_STARTING_HEAP_SIZE

        public static final java.lang.String PREF_STARTING_HEAP_SIZE
        The starting heap size.
        See Also:
        Constant Field Values
      • PREF_MAX_HEAP_SIZE

        public static final java.lang.String PREF_MAX_HEAP_SIZE
        The maximum heap size.
        See Also:
        Constant Field Values
      • PREF_RAW_EXTENTS

        public static final java.lang.String PREF_RAW_EXTENTS
        Constant that indicates the default raw image extents.
        See Also:
        Constant Field Values
      • PREF_RAW_BIG_ENDIAN

        public static final java.lang.String PREF_RAW_BIG_ENDIAN
        Constant that indicates the default raw image big endian.
        See Also:
        Constant Field Values
      • PREF_RAW_RESOLUTIONS

        public static final java.lang.String PREF_RAW_RESOLUTIONS
        Constant that indicates the default raw image resolutions.
        See Also:
        Constant Field Values
      • PREF_RAW_UNITS

        public static final java.lang.String PREF_RAW_UNITS
        Constant that indicates the default raw image units.
        See Also:
        Constant Field Values
      • PREF_RAW_TYPE

        public static final java.lang.String PREF_RAW_TYPE
        Constant that indicates the default raw image type.
        See Also:
        Constant Field Values
      • PREF_RAW_DATA_OFFSET

        public static final java.lang.String PREF_RAW_DATA_OFFSET
        Constant that indicates the default raw image data offset.
        See Also:
        Constant Field Values
      • PREF_LB_ROW_DEPENDENT

        public static final java.lang.String PREF_LB_ROW_DEPENDENT
        Constant that indicates the LightBox row dependant variable.
        See Also:
        Constant Field Values
      • PREF_LB_GRID_ROW

        public static final java.lang.String PREF_LB_GRID_ROW
        Constant that indicates the LightBox grid row variable.
        See Also:
        Constant Field Values
      • PREF_LB_GRID_COL

        public static final java.lang.String PREF_LB_GRID_COL
        Constant that indicates the LightBox grid column variable.
        See Also:
        Constant Field Values
      • PREF_LB_GRID_SIZE

        public static final java.lang.String PREF_LB_GRID_SIZE
        Constant that indicates the LightBox grid size variable.
        See Also:
        Constant Field Values
      • PREF_LB_INCREMENT

        public static final java.lang.String PREF_LB_INCREMENT
        Constant that indicates the increment between displayed lightbox slices
        See Also:
        Constant Field Values
      • PREF_LB_GRID_COLOR

        public static final java.lang.String PREF_LB_GRID_COLOR
        Constant that indicates the LightBox grid color variable.
        See Also:
        Constant Field Values
      • PREF_LB_BORDER_SIZE

        public static final java.lang.String PREF_LB_BORDER_SIZE
        Constant that indicates the LightBox border size variable.
        See Also:
        Constant Field Values
      • PREF_LB_BORDER_COLOR

        public static final java.lang.String PREF_LB_BORDER_COLOR
        Constant that indicates the LightBox border color variable.
        See Also:
        Constant Field Values
      • PREF_LB_SELECTED_BORDER_SIZE

        public static final java.lang.String PREF_LB_SELECTED_BORDER_SIZE
        Constant that indicates the LightBox selected border size variable.
        See Also:
        Constant Field Values
      • PREF_LB_SELECTED_BORDER_COLOR

        public static final java.lang.String PREF_LB_SELECTED_BORDER_COLOR
        Constant that indicates the LightBox selected border color variable.
        See Also:
        Constant Field Values
      • PREF_LB_MAG

        public static final java.lang.String PREF_LB_MAG
        Constant that indicates the LightBox magnification variable.
        See Also:
        Constant Field Values
      • PREF_LB_LOCATION

        public static final java.lang.String PREF_LB_LOCATION
        Constant that indicates the LightBox location variable.
        See Also:
        Constant Field Values
      • PREF_LB_TSLICE

        public static final java.lang.String PREF_LB_TSLICE
        Constant that indicates the LightBox individual t-slice variable.
        See Also:
        Constant Field Values
      • PREF_LB_CUPDATE

        public static final java.lang.String PREF_LB_CUPDATE
        Constant that indicates continuous update of LightBox
        See Also:
        Constant Field Values
      • PREF_APP_TITLE

        public static final java.lang.String PREF_APP_TITLE
        Constant that indicates the application title.
        See Also:
        Constant Field Values
      • PREF_APP_ICON

        public static final java.lang.String PREF_APP_ICON
        Constant that indicates the application icon.
        See Also:
        Constant Field Values
      • PREF_SHOW_OVERLAYS

        public static final java.lang.String PREF_SHOW_OVERLAYS
        Constant that indicates whether to show image overlays.
        See Also:
        Constant Field Values
      • PREF_PLUGIN_ALGORITHM

        public static final java.lang.String PREF_PLUGIN_ALGORITHM
        plugin of algorithm type.
        See Also:
        Constant Field Values
      • PREF_PLUGIN_FILE

        public static final java.lang.String PREF_PLUGIN_FILE
        plugin of file type.
        See Also:
        Constant Field Values
      • PREF_PLUGIN_VIEW

        public static final java.lang.String PREF_PLUGIN_VIEW
        plugin of view type.
        See Also:
        Constant Field Values
      • PREF_NINDS_ANON_PLUGIN_INPUTDIR

        public static final java.lang.String PREF_NINDS_ANON_PLUGIN_INPUTDIR
        ?
        See Also:
        Constant Field Values
      • PREF_NINDS_ANON_PLUGIN_OUTPUTDIR

        public static final java.lang.String PREF_NINDS_ANON_PLUGIN_OUTPUTDIR
        ?
        See Also:
        Constant Field Values
      • PREF_NINDS_ANON_PLUGIN_CSVDIR

        public static final java.lang.String PREF_NINDS_ANON_PLUGIN_CSVDIR
        ?
        See Also:
        Constant Field Values
      • ITEM_SEPARATOR

        public static final java.lang.String ITEM_SEPARATOR
        The character that separates items (such as in the user file type definitions).
        See Also:
        Constant Field Values
      • PREF_NDAR_PLUGIN_SERVER

        public static final java.lang.String PREF_NDAR_PLUGIN_SERVER
        See Also:
        Constant Field Values
      • PREF_NDAR_PLUGIN_DATASTRUCT_NAME

        public static final java.lang.String PREF_NDAR_PLUGIN_DATASTRUCT_NAME
        See Also:
        Constant Field Values
      • PREF_NDAR_PLUGIN_OUTPUT_DIR

        public static final java.lang.String PREF_NDAR_PLUGIN_OUTPUT_DIR
        See Also:
        Constant Field Values
      • PREF_NDAR_PLUGIN_CSV_DIR

        public static final java.lang.String PREF_NDAR_PLUGIN_CSV_DIR
        See Also:
        Constant Field Values
      • PREF_BRICS_PLUGIN_OUTPUT_DIR

        public static final java.lang.String PREF_BRICS_PLUGIN_OUTPUT_DIR
        See Also:
        Constant Field Values
      • PREF_BRICS_PLUGIN_CSV_DIR

        public static final java.lang.String PREF_BRICS_PLUGIN_CSV_DIR
        See Also:
        Constant Field Values
      • PREF_BRICS_PLUGIN_BIDS_DIR

        public static final java.lang.String PREF_BRICS_PLUGIN_BIDS_DIR
        See Also:
        Constant Field Values
      • PREF_BRICS_CONFLICT_RESOLUTION

        public static final java.lang.String PREF_BRICS_CONFLICT_RESOLUTION
        See Also:
        Constant Field Values
      • PREF_PAINT_OPACITY

        public static final java.lang.String PREF_PAINT_OPACITY
        See Also:
        Constant Field Values
      • PREF_BUG_REPORT_NAME

        public static final java.lang.String PREF_BUG_REPORT_NAME
        See Also:
        Constant Field Values
      • PREF_BUG_REPORT_EMAIL

        public static final java.lang.String PREF_BUG_REPORT_EMAIL
        See Also:
        Constant Field Values
      • PREF_BUG_REPORT_URGENCY

        public static final java.lang.String PREF_BUG_REPORT_URGENCY
        See Also:
        Constant Field Values
      • PREF_USE_INCORRECT_ACPC_XDIM

        public static final java.lang.String PREF_USE_INCORRECT_ACPC_XDIM
        See Also:
        Constant Field Values
      • PREF_FORCE_HISTO_UBYTE

        public static final java.lang.String PREF_FORCE_HISTO_UBYTE
        See Also:
        Constant Field Values
      • PREF_MAX_DEBUG_LINES

        public static final java.lang.String PREF_MAX_DEBUG_LINES
        See Also:
        Constant Field Values
      • PREF_DEBUG_MINOR

        public static final java.lang.String PREF_DEBUG_MINOR
        See Also:
        Constant Field Values
      • PREF_DEBUG_ALGORITHM

        public static final java.lang.String PREF_DEBUG_ALGORITHM
        See Also:
        Constant Field Values
      • PREF_DEBUG_FILEIO

        public static final java.lang.String PREF_DEBUG_FILEIO
        See Also:
        Constant Field Values
      • PREF_DEBUG_COMMS

        public static final java.lang.String PREF_DEBUG_COMMS
        See Also:
        Constant Field Values
      • PREF_DEBUG_SCRIPTING

        public static final java.lang.String PREF_DEBUG_SCRIPTING
        See Also:
        Constant Field Values
      • DEFINITION_SEPARATOR

        public static final java.lang.String DEFINITION_SEPARATOR
        The character that separates an item from its value in a definition or mapping (such as in the user file type definitions).
        See Also:
        Constant Field Values
      • DEBUG_MINOR

        public static final int DEBUG_MINOR
        Constant used to identify debugging category for general output.
        See Also:
        Constant Field Values
      • DEBUG_ALGORITHM

        public static final int DEBUG_ALGORITHM
        Constant used to identify debugging category for general output by algorithms.
        See Also:
        Constant Field Values
      • DEBUG_FILEIO

        public static final int DEBUG_FILEIO
        Constant used to identify debugging category for general output by FileIO.
        See Also:
        Constant Field Values
      • DEBUG_COMMS

        public static final int DEBUG_COMMS
        Constant used to identify debugging category for general output by communications.
        See Also:
        Constant Field Values
      • DEBUG_SCRIPTING

        public static final int DEBUG_SCRIPTING
        Constant used to identify debugging category for output of scripting system messages.
        See Also:
        Constant Field Values
      • CACHED_MAX_DEBUG_LINES

        public static int CACHED_MAX_DEBUG_LINES
        Constant used to identify the maximum number of lines in the debugging panel. This is initialized from the properties file and updated whenever changed via the options panel (this value is used every time a debug line is output so access to this value needs to be as fast as possible)
      • DATA_PROVENANCE_SCHEMA

        public static final java.lang.String DATA_PROVENANCE_SCHEMA
        The schema for the data provenance xml files
        See Also:
        Constant Field Values
      • SAVE_DICOM_TAGS

        public static final java.lang.String SAVE_DICOM_TAGS
        Dicom tags to be saved
        See Also:
        Constant Field Values
      • mipavProps

        private static java.util.Properties mipavProps
        A list of MIPAV properties.
      • defaultProps

        private static java.util.Properties defaultProps
        A default list of properties used if the mipav.preferences file cannot be found.
      • messageFrame

        private static ViewJFrameMessage messageFrame
        Reference to the message frame where debug information can be displayed.
      • preferencesFileName

        private static java.lang.String preferencesFileName
        The MIPAV preferences file name (without path).
      • preferencesDir

        private static java.lang.String preferencesDir
        The place where user-individual mipav files should be put.
      • preferencesFile

        private static java.lang.String preferencesFile
        The MIPAV preferences file path and name.
      • userShortcutTable

        private static java.util.Hashtable<java.lang.String,​javax.swing.KeyStroke> userShortcutTable
        Hashtable that holds all user-defined shortcuts
      • defaultShortcutTable

        private static java.util.Hashtable<java.lang.String,​javax.swing.KeyStroke> defaultShortcutTable
        Hashtable that holds the default shortcuts
      • currentShortcut

        private static javax.swing.KeyStroke currentShortcut
        The current shortcut
    • Constructor Detail

      • Preferences

        public Preferences()
    • Method Detail

      • addShortcut

        public static boolean addShortcut​(java.lang.String command)
        Adds a new shortcut to the hashtable. if there is already a command predefined for the keystroke set from setShortcut(), it will be removed then replaced with the new command.
        Parameters:
        command - the command to map
        Returns:
        DOCUMENT ME!
      • addShortcut

        public static boolean addShortcut​(java.lang.String command,
                                          javax.swing.KeyStroke shortcut)
        Adds a new shortcut to the hashtable with a given keystroke. if there is already a command predefined for the keystroke set from setShortcut(), it will be removed then replaced with the new command.
        Parameters:
        command - the command to map
        Returns:
        DOCUMENT ME!
      • buildShortcutTable

        public static final void buildShortcutTable()
        Builds a hashtable of actioncommands (keys) with associated keystrokes from the Preferences file.
      • getDebug

        public static final java.lang.String getDebug()
        Gets all the text printed to the debug panel.
        Returns:
        String representation of debug panel (new lines are removed)
      • data

        public static final void data​(java.lang.String string)
        Prints to data tab
        Parameters:
        string - String string to be output
      • getData

        public static final java.lang.String getData()
        Gets all the text printed to the data panel.
        Returns:
        String representation of data panel (new lines are removed)
      • debug

        public static final void debug​(java.lang.String string)
        If at least one debug level is turned on, output the string.
        Parameters:
        string - String string to be output
      • debug

        public static final void debug​(java.lang.String string1,
                                       java.lang.String string2)
        If at least one debug level is turned on, output the string. This is a overriden method variant that takes multiple string parameters.
        Parameters:
        string1 - String string to be output
        string2 - String string to be output
      • debug

        public static final void debug​(java.lang.String string1,
                                       java.lang.String string2,
                                       java.lang.String string3)
        If at least one debug level is turned on, output the string. This is a overriden method variant that takes multiple string parameters.
        Parameters:
        string1 - String string to be output
        string2 - String string to be output
        string3 - String string to be output
      • debug

        public static final void debug​(java.lang.String string1,
                                       java.lang.String string2,
                                       java.lang.String string3,
                                       java.lang.String string4)
        If at least one debug level is turned on, output the string. This is a overriden method variant that takes multiple string parameters.
        Parameters:
        string1 - String string to be output
        string2 - String string to be output
        string3 - String string to be output
        string4 - String string to be output
      • debug

        public static final void debug​(java.lang.String string1,
                                       java.lang.String string2,
                                       java.lang.String string3,
                                       java.lang.String string4,
                                       java.lang.String string5)
        If at least one debug level is turned on, output the string. This is a overriden method variant that takes multiple string parameters.
        Parameters:
        string1 - String string to be output
        string2 - String string to be output
        string3 - String string to be output
        string4 - String string to be output
        string5 - String string to be output
      • debug

        public static final void debug​(java.lang.String string,
                                       int category)
        If the debug is turned on for the given level, output to the messageFrame.
        Parameters:
        string - String to be output
        level - int level of debug to check
      • debug

        public static final void debug​(java.lang.String string1,
                                       java.lang.String string2,
                                       int category)
        If the debug is turned on for the given level, output to the messageFrame. This is a overriden method variant that takes multiple string parameters.
        Parameters:
        string1 - String to be output
        string2 - String to be output
        level - int level of debug to check
      • debug

        public static final void debug​(java.lang.String string1,
                                       java.lang.String string2,
                                       java.lang.String string3,
                                       int category)
        If the debug is turned on for the given level, output to the messageFrame. This is a overriden method variant that takes multiple string parameters.
        Parameters:
        string1 - String to be output
        string2 - String to be output
        string3 - String to be output
        level - int level of debug to check
      • debug

        public static final void debug​(java.lang.String string1,
                                       char string2,
                                       java.lang.String string3,
                                       int category)
        If the debug is turned on for the given level, output to the messageFrame. This is a overriden method variant that takes multiple string parameters.
        Parameters:
        string1 - String to be output
        string2 - String to be output
        string3 - String to be output
        level - int level of debug to check
      • debug

        public static final void debug​(java.lang.String string1,
                                       boolean string2,
                                       java.lang.String string3,
                                       int category)
        If the debug is turned on for the given level, output to the messageFrame. This is a overriden method variant that takes multiple string parameters.
        Parameters:
        string1 - String to be output
        string2 - String to be output
        string3 - String to be output
        level - int level of debug to check
      • debug

        public static final void debug​(java.lang.String string1,
                                       double string2,
                                       java.lang.String string3,
                                       int category)
        If the debug is turned on for the given level, output to the messageFrame. This is a overriden method variant that takes multiple string parameters.
        Parameters:
        string1 - String to be output
        string2 - String to be output
        string3 - String to be output
        level - int level of debug to check
      • debug

        public static final void debug​(java.lang.String string1,
                                       java.lang.Object string2,
                                       java.lang.String string3,
                                       int category)
        If the debug is turned on for the given level, output to the messageFrame. This is a overriden method variant that takes multiple string parameters.
        Parameters:
        string1 - String to be output
        string2 - String to be output
        string3 - String to be output
        level - int level of debug to check
      • debug

        public static final void debug​(java.lang.String string1,
                                       java.lang.String string2,
                                       java.lang.String string3,
                                       java.lang.String string4,
                                       int category)
        If the debug is turned on for the given level, output to the messageFrame. This is a overriden method variant that takes multiple string parameters.
        Parameters:
        string1 - String to be output
        string2 - String to be output
        string3 - String to be output
        string4 - String to be output
        level - int level of debug to check
      • debug

        public static final void debug​(java.lang.String string1,
                                       java.lang.String string2,
                                       java.lang.String string3,
                                       java.lang.String string4,
                                       java.lang.String string5,
                                       int category)
        If the debug is turned on for the given level, output to the messageFrame. This is a overriden method variant that takes multiple string parameters.
        Parameters:
        string1 - String to be output
        string2 - String to be output
        string3 - String to be output
        string4 - String to be output
        string5 - String to be output
        level - int level of debug to check
      • debug

        public static final void debug​(java.lang.String string,
                                       int category,
                                       Preferences.LogLevel level)
        If the debug is turned on for the given level, output to the messageFrame.
        Parameters:
        string - String to be output
        level - int level of debug to check
      • debug

        public static final void debug​(java.lang.String string1,
                                       java.lang.String string2,
                                       int category,
                                       Preferences.LogLevel level)
        If the debug is turned on for the given level, output to the messageFrame. This is a overriden method variant that takes multiple string parameters.
        Parameters:
        string1 - String to be output
        string2 - String to be output
        level - int level of debug to check
      • debug

        public static final void debug​(java.lang.String string1,
                                       java.lang.String string2,
                                       java.lang.String string3,
                                       int category,
                                       Preferences.LogLevel level)
        If the debug is turned on for the given level, output to the messageFrame. This is a overriden method variant that takes multiple string parameters.
        Parameters:
        string1 - String to be output
        string2 - String to be output
        string3 - String to be output
        level - int level of debug to check
      • debug

        public static final void debug​(java.lang.String string1,
                                       char string2,
                                       java.lang.String string3,
                                       int category,
                                       Preferences.LogLevel level)
        If the debug is turned on for the given level, output to the messageFrame. This is a overriden method variant that takes multiple string parameters.
        Parameters:
        string1 - String to be output
        string2 - String to be output
        string3 - String to be output
        level - int level of debug to check
      • debug

        public static final void debug​(java.lang.String string1,
                                       boolean string2,
                                       java.lang.String string3,
                                       int category,
                                       Preferences.LogLevel level)
        If the debug is turned on for the given level, output to the messageFrame. This is a overriden method variant that takes multiple string parameters.
        Parameters:
        string1 - String to be output
        string2 - String to be output
        string3 - String to be output
        level - int level of debug to check
      • debug

        public static final void debug​(java.lang.String string1,
                                       double string2,
                                       java.lang.String string3,
                                       int category,
                                       Preferences.LogLevel level)
        If the debug is turned on for the given level, output to the messageFrame. This is a overriden method variant that takes multiple string parameters.
        Parameters:
        string1 - String to be output
        string2 - String to be output
        string3 - String to be output
        level - int level of debug to check
      • debug

        public static final void debug​(java.lang.String string1,
                                       java.lang.Object string2,
                                       java.lang.String string3,
                                       int category,
                                       Preferences.LogLevel level)
        If the debug is turned on for the given level, output to the messageFrame. This is a overriden method variant that takes multiple string parameters.
        Parameters:
        string1 - String to be output
        string2 - String to be output
        string3 - String to be output
        level - int level of debug to check
      • debug

        public static final void debug​(java.lang.String string1,
                                       java.lang.String string2,
                                       java.lang.String string3,
                                       java.lang.String string4,
                                       int category,
                                       Preferences.LogLevel level)
        If the debug is turned on for the given level, output to the messageFrame. This is a overriden method variant that takes multiple string parameters.
        Parameters:
        string1 - String to be output
        string2 - String to be output
        string3 - String to be output
        string4 - String to be output
        level - int level of debug to check
      • debug

        public static final void debug​(java.lang.String string1,
                                       java.lang.String string2,
                                       java.lang.String string3,
                                       java.lang.String string4,
                                       java.lang.String string5,
                                       int category,
                                       Preferences.LogLevel level)
        If the debug is turned on for the given level, output to the messageFrame. This is a overriden method variant that takes multiple string parameters.
        Parameters:
        string1 - String to be output
        string2 - String to be output
        string3 - String to be output
        string4 - String to be output
        string5 - String to be output
        level - int level of debug to check
      • debugLevel

        public static final boolean debugLevel​(int category)
        Indicates whether debug is turned on for the given level.
        Parameters:
        level - debugging level to check for
        Returns:
        true if the given debugging level is activated
      • getDefaultDisplay

        public static Preferences.DefaultDisplay getDefaultDisplay()
        Returns how pixel values of images are displayed in terms or brightness values and possible colors.
        Returns:
        The default display enumeration.
      • getComplexDisplay

        public static Preferences.ComplexDisplay getComplexDisplay()
        Returns how pixel values are displayed on the MIPAV toolbar for complex images. Although MIPAV always displays the magnitude or log magnitude when viewing an image, the toolbar can display both real and complex components.
        Returns:
        The complex display enumeration, includes number of parts that the complex display requires
      • getInterpolateDisplay

        public static Preferences.InterpolateDisplay getInterpolateDisplay()
        Returns how pixel values are interpolated for displayed slices. Default is nearest neighbor.
      • initDebugPreferences

        public static final void initDebugPreferences()
        this method must be invoked very early on in the startup sequence (typically in the startup main method or ViewUserInterface. This sets up the logging which other initialization code relies on - for example, if there is another error later in the initialization process, that error might call a debug method which means the debug variables must already have been initialized.
      • getDebugPreferences

        public static final Preferences.LogConfig getDebugPreferences()
        Gets the LogConfiguration for logging categories (minor, algorithm, fileIO, comms, scripting).
        Returns:
        LogConfig the logging configuration
      • getDefaultFrameRate

        public static float getDefaultFrameRate()
        Gets the default frame rate used in saving AVI movies. Default value is 10.0.
        Returns:
        the default frame rate as a floating point number.
      • getDefaultHostKey

        public static java.lang.String getDefaultHostKey()
        Accessor to get the default chat/file server host key.
        Returns:
        default host key
      • getDefaultServerKey

        public static java.lang.String getDefaultServerKey()
        Accessor to get default DICOM image server key.
        Returns:
        default server key
      • getDefaultShortcutTable

        public static java.util.Hashtable<java.lang.String,​javax.swing.KeyStroke> getDefaultShortcutTable()
        Gets the Default Hashtable used to store the shortcut keystrokes and commands.
        Returns:
        Hashtable the shortcut hashtable
      • getDefaultStorageKey

        public static java.lang.String getDefaultStorageKey()
        Accessor to get default DICOM image storage location.
        Returns:
        default storage information
      • getDICOMBrowserTableConfiguration

        public static java.util.Vector<java.lang.String> getDICOMBrowserTableConfiguration()
        Gets the user-configured columns that indicate the DICOM tags that are displayed in the DICOM browser table.
        Returns:
        Vector List of strings that identify the columns.
      • getDICOMSaveDictionary

        public static final java.lang.String getDICOMSaveDictionary()
        Accessor to get the default DICOM Save Dictionary (which tags to save into XML header.
        Returns:
        String The full path of the dictionary in which a subset of the DICOM tags are stored.
      • getFileFilter

        public static int getFileFilter()
        Returns the index of the latest used file filter.
        Returns:
        the index of the latest used file filter.
      • getFileTempDir

        public static java.lang.String getFileTempDir()
        Returns the temporary directory which is used to store files to be deleted.
        Returns:
        the temporary directory which is used to store files to be deleted.
      • getHostIP

        public static java.lang.String getHostIP​(java.lang.String AETitle)
        Accessor to get host (chat/file) server Internet Protocol for selected Name.
        Parameters:
        AETitle - application entity title
        Returns:
        IP address of asssociated Name
      • getIconName

        public static final java.lang.String getIconName()
        Returns the name of the application icon.
        Returns:
        string containing the name of the system icon
      • getImageDirectory

        public static java.lang.String getImageDirectory()
        Returns the image directory used last time.
        Returns:
        the image directory used last time.
      • getIP

        public static java.lang.String getIP​(java.lang.String AETitle)
        Accessor to get DICOM image server Internet Protocol for selected AETitle.
        Parameters:
        AETitle - application entity title
        Returns:
        IP address of asssociated AETitle
      • getLastImageAt

        public static final java.lang.String getLastImageAt​(int index)
        Returns the image name of "last X images" at the given index. Index should be between 0 and 3.
        Parameters:
        index - Index of image.
        Returns:
        Name of image at index.
      • getLastOpenSequenceChannels

        public static final java.lang.String getLastOpenSequenceChannels()
        Used by ViewOpenImageSequence to get the saved number of channels used when opening an image sequence.
        Returns:
        String - the value that was saved to the preferences file, represented by a String, of the number of channels that were used in the corresponding text box of this frame the last time the value was saved
      • getLastOpenSequenceOrdering

        public static final java.lang.String getLastOpenSequenceOrdering()
        Used by ViewOpenImageSequence to get the Z-C-T ordering of data used when opening an image sequence.
        Returns:
        String - the value that was saved to the preferences file, represented by a String, of the Z-C-T ordering of data that was used in the corresponding text box of this frame the last time the value was saved
      • getLastOpenSequencePath

        public static final java.lang.String getLastOpenSequencePath()
        Used by ViewOpenImageSequence to get the last path used when opening an image sequence.
        Returns:
        String
      • getLastOpenSequenceSlices

        public static final java.lang.String getLastOpenSequenceSlices()
        Used by ViewOpenImageSequence to get the saved number of slices used when opening an image sequence.
        Returns:
        String - the value that was saved to the preferences file, represented by a String, of the number of slices that were used in the corresponding text box of this frame the last time the value was saved
      • getLastOpenSequenceTimePoints

        public static final java.lang.String getLastOpenSequenceTimePoints()
        Used by ViewOpenImageSequence to get the saved number of time points used when opening an image sequence.
        Returns:
        String - the value that was saved to the preferences file, represented by a String, of the number of time points that were used in the corresponding text box of this frame the last time the value was saved
      • getLastXImages

        public static final java.lang.String[] getLastXImages()
        Gets the names of the last X number of images that were loaded from the Preferences file. Shortens the names so the menu isn't too wide.
        Returns:
        Array of strings representing the last images that were loaded
      • getMaxDebugLines

        public static int getMaxDebugLines()
        Returns:
        the max number of debug lines that are output
      • getMipavProps

        public static java.util.Properties getMipavProps()
        Returns:
        the mipavProps
      • getNextHostKey

        public static java.lang.String getNextHostKey()
        Returns the next host key.
        Returns:
        The next host key.
      • getNextServerKey

        public static java.lang.String getNextServerKey()
        Returns the next server key.
        Returns:
        The next server key.
      • getNextStorageKey

        public static java.lang.String getNextStorageKey()
        Returns the next storage key.
        Returns:
        The next storage key.
      • getNumberOfThreads

        public static int getNumberOfThreads()
        The number of threads available for MIPAV for processing. MIPAV typically uses this number for highly-parallel algorithm computations.
        Returns:
        the number of threads available for mipav
      • getOverlayNames

        public static final java.lang.String[] getOverlayNames​(boolean isDicom)
        Retrieves the list of overlay names (user can type whatever).
        Parameters:
        isDicom - boolean is this a dicom image
        Returns:
        String[] array of strings for overlay labeling
      • getOverlays

        public static final java.lang.String[] getOverlays​(boolean isDicom)
        Gets the image overlay codes (they identify what to display in the corners of the image), from the preference file.
        Parameters:
        isDicom - if true loads the overlay IDs for a DICOM image
        Returns:
        the overlay codes that identifies what should be displayed.
      • getPluginUserDir

        public static final java.lang.String getPluginUserDir()
        Returns String indicating the directory where plugin class files are stored. If this property has not been set, then the image Directory is returned.
        Returns:
        directory name for the property PluginUserDir or the directory name for the property ImageDirectory if PluginUserDir is not set.
      • getPluginInstallDirectory

        public static java.lang.String getPluginInstallDirectory()
        Returns the directory last used for installing plugins.
        Returns:
        the directory last used for installing plugins.
      • getPort

        public static int getPort​(java.lang.String AETitle)
        Accessor to get DICOM image server's port for selected AETitle.
        Parameters:
        AETitle - application entity title
        Returns:
        port address of asssociated AETitle
      • getPreferencesDir

        public static final java.lang.String getPreferencesDir()
        Return the directory where mipav-generated, user-specific files should be placed.
        Returns:
        the place to put user-specific files
      • getProperty

        public static final java.lang.String getProperty​(java.lang.String key)
        Accessor to return a specfic properties given a key.
        Parameters:
        key - the property key.
        Returns:
        the mipav property. The method returns null if the property is not found.
      • getScriptFile

        public static final java.lang.String getScriptFile()
        DOCUMENT ME!
        Returns:
        DOCUMENT ME!
      • getScriptsDirectory

        public static final java.lang.String getScriptsDirectory()
        Returns the default script directory. if null, returns the user's current working directory + "scripts"
        Returns:
        script dir
      • getShortcut

        public static javax.swing.KeyStroke getShortcut​(java.lang.String command)
        Returns a keystroke shortcut for the given command.
        Parameters:
        command - String the command to check
        Returns:
        KeyStroke the shortcut's keystroke
      • getShortcutCommand

        public static java.lang.String getShortcutCommand​(javax.swing.KeyStroke ks)
        Gets the command associated with the shortcut (if there is one).
        Parameters:
        ks - KeyStroke the keystroke to check
        Returns:
        String the command associated (or null if none)
      • getSubsampleDimensions

        public static final java.awt.Dimension getSubsampleDimensions()
        Used by ViewOpenImageSequence to get the subsample dimensions that were saved in the preferences file.
        Returns:
        Dimension - the dimension that was last used to subsample an image while using the ViewOpenImageSequence tool, null if dimension is invalid in the preferences file
      • getTrimVoi

        public static final float getTrimVoi()
        Accessor to get the TRIM parameter (trimming VOIcontour of points). Default value is 0.3 which trims some of the points of the contours.
        Returns:
        the trim value.
      • getTrimMask

        public static final float getTrimMask()
        Accessor to get the TRIM parameter (trimming VOIcontour of points). Default value is 0.3 which trims no points in the contours.
        Returns:
        the trim value.
      • getTrimAdjacient

        public static boolean getTrimAdjacient()
        Accessor to get the trim parameter (trimming contour of adjacent points).
        Returns:
        the trim boolean to indicate if the directly adjacent points should be trimmed.
      • getUserShortcutTable

        public static java.util.Hashtable<java.lang.String,​javax.swing.KeyStroke> getUserShortcutTable()
        Gets the User defined Hashtable used to store the shortcut keystrokes and commands.
        Returns:
        Hashtable the shortcut hashtable
      • getVOIColorIncrement

        public static int getVOIColorIncrement()
        Gets the VOI color increment value. Ben add here.
        Returns:
        int
      • getVOIDrawColor

        public static java.awt.Color getVOIDrawColor()
        Gets the VOI draw color.
        Returns:
        Color color to draw with
      • getVOIThickness

        public static int getVOIThickness()
        DOCUMENT ME!
        Returns:
        DOCUMENT ME!
      • is

        public static final boolean is​(java.lang.String propertyName)
        Gets the boolean state of the property, where in the preferences file the "yes", "on", "true" all return true, but anything else (or non-existent property) returns false. This method is provided for semantic preference, but is exactly the same as (in fact, calls) isPreference.
        Parameters:
        propertyName - Name of a property in preferences to check.
        Returns:
        boolean true when the named property has the String the "yes", "on", "true". false for any other string, or if the property does not exist.
        See Also:
        isPreference(String)
      • isDebug

        public static final boolean isDebug()
        Returns flag indicating if the debug flag is true or false. (and in preferences v2, if debug level is zero, returns false. Returns true if debug level is greater than 0.)

        debug level is the amount of output given for debugging mipav.

        Returns:
        returns true if either debug flag is true or level is greater than zero and false if either debug flag is false or level is zero.
      • isDefaultCommand

        public static boolean isDefaultCommand​(java.lang.String command)
        DOCUMENT ME!
        Parameters:
        command - DOCUMENT ME!
        Returns:
        DOCUMENT ME!
      • isDefaultKeyStroke

        public static boolean isDefaultKeyStroke​(javax.swing.KeyStroke ks)
        DOCUMENT ME!
        Parameters:
        ks - DOCUMENT ME!
        Returns:
        DOCUMENT ME!
      • isGpuCompEnabled

        public static boolean isGpuCompEnabled()
        Indicates whether GPU-computing should be enabled. The renderer and algorithms use this information for processing
        Returns:
        true if gpu compinting is enabled
      • isInterpolateDisplay

        public static boolean isInterpolateDisplay()
        Maintained for backwards compatibility. If interpolation mode is equal to nearest neighbor, then returns false, otherwise returns true.
        Returns:
      • isMultiThreadingEnabled

        public static boolean isMultiThreadingEnabled()
        Indicates whether multi-threading should be enabled for algorithms. Most algorithms check this before launching highly-parallel processes (such as FFT).
        Returns:
        true if multi-threading is enabled
      • isHistogramDisplay

        public static boolean isHistogramDisplay()
        Indicates whether the image display should be updated in real-time as histogram LUTs are changed
        Returns:
        true if real-time operation should occur
      • isPreference

        public static final boolean isPreference​(java.lang.String propertyName)
        Gets the boolean state of the property, where in the preferences file the "yes", "on", "true" all return true, but anything else (or non-existent property) returns false. While not as intuitive, perhaps, as some of the specially named property-retrieval methods (eg., isSplashScreen), this method can be used to replace all of those methods when the preferences property is known. It can also be convenient for limited-use properties used in debugging.
        Parameters:
        propertyName - Name of a property in preferences to check.
        Returns:
        boolean true when the named property has the String the "yes", "on", "true". false for any other string, or if the property does not exist.
      • isPreferenceSet

        public static final boolean isPreferenceSet​(java.lang.String propertyName)
        Returns whether the user has a preference indicated for a particular property. Note that this just checks for some value, not necessarily a "true" value.
        Parameters:
        propertyName - the name of the property to check for
        Returns:
        true if there is some preference set for the given property name
      • print

        public static void print()
        Prints mipav.preferences to System.out.
      • read

        public static boolean read()
        Reads the "mipav.preferences" file from the user's 'home' directory.
        Returns:
        true if found else false
      • removeProperty

        public static final void removeProperty​(java.lang.String key)
        Removes the property key from the MIPAV property list.
        Parameters:
        key - the property key.
      • removeShortcut

        public static void removeShortcut​(java.lang.String commandToRemove)
        Removes a shortcut from the table.
        Parameters:
        commandToRemove - String
      • save

        public static boolean save()
        Saves preference file to the user's 'home' directory.
        Returns:
        boolean true if successful, false otherwise
      • saveShortcuts

        public static final void saveShortcuts()
        Sets the property for shortcuts by building string from ViewUserInterface's Shortcut Hashtable.
      • saveSubsampleDimensions

        public static final void saveSubsampleDimensions​(java.awt.Dimension subsampleDimension)
        Used by ViewOpenImageSequence to save its subsample dimensions for the next time it is opened. The dimension is actually saved as its two parts, width and height
        Parameters:
        subsampleDimension - Dimension - the subsample dimension to save
      • setAlwaysSaveImgAsAnalyze

        public static final void setAlwaysSaveImgAsAnalyze​(boolean doSaveAnalyze)
        Sets whether all imgs should be saved in analyze format (i.e., don't ask about whether to save as analyze/interfile/nifti).
        Parameters:
        doSaveAnalyze - whether to always save .hdr/.img files as analyze format files
      • setAlwaysSaveImgAsInterfile

        public static final void setAlwaysSaveImgAsInterfile​(boolean doSaveInterfile)
        Sets whether all imgs should be saved in interfile format (i.e., don't ask about whether to save as analyze/interfile/nifti).
        Parameters:
        doSaveInterfile - whether to always save .hdr/.img files as interfile format files
      • setAlwaysSaveImgAsNifti

        public static final void setAlwaysSaveImgAsNifti​(boolean doSaveNifti)
        Sets whether all imgs should be saved in nifti format (i.e., don't ask about whether to save as analyze/interfile/nifti).
        Parameters:
        doSaveNifti - whether to always save .hdr/.img files as nifti format files
      • setAlwaysSaveMncAsMinc1

        public static final void setAlwaysSaveMncAsMinc1​(boolean doSaveMinc1)
        Sets whether all mncs should be saved in minc1 cdf format (i.e., don't ask about whether to save as minc1/minc2).
        Parameters:
        doSaveMinc1 - whether to always save .mnc files as minc1 cdf format files
      • setAlwaysSaveMncAsMinc2

        public static final void setAlwaysSaveMncAsMinc2​(boolean doSaveMinc2)
        Sets whether all mncs should be saved in minc2 hdf5 format (i.e., don't ask about whether to save as minc1/minc2).
        Parameters:
        doSaveMinc2 - whether to always save .mnc files as minc2 hdf5 format files
      • setCurrentShortcut

        public static void setCurrentShortcut​(javax.swing.KeyStroke ks)
        Sets the current keystroke shortcut for assignment once a command has been passed in.
        Parameters:
        ks - KeyStroke the shortcut keystroke
      • setDebugLevels

        public static final void setDebugLevels​(java.util.Map<java.lang.Integer,​java.lang.String> debugLevels)
        Sets the debug levels
        Parameters:
        levels - a Map of Category (int) -> LogLevel.
      • setDefaultDisplay

        public static void setDefaultDisplay​(Preferences.DefaultDisplay display)
        Sets the default display mode for 2D/3D image display.
        Parameters:
        display - the DefaultDisplay type
      • setDICOMBrowserTableConfiguration

        public static boolean setDICOMBrowserTableConfiguration​(java.util.Vector<java.lang.String> newConfiguration)
        Sets the user-configured columns that indicate the DICOM tags that are displayed in the DICOM browser table.
        Parameters:
        newConfiguration - Vector List of strings that identify the columns.
        Returns:
        boolean Success or failure of the setting the columns.
      • setFileFilter

        public static void setFileFilter​(int fileFilterIndex)
        Sets the current used file filter as the latest used file filter.
        Parameters:
        fileFilterIndex - the index of the current used file filter.
      • setFileTempDir

        public static void setFileTempDir​(java.lang.String tempDir)
        Sets the temporary directory which is used for files which will be deleted.
        Parameters:
        tempDir - the temporary directory.
      • setImageDirectory

        public static void setImageDirectory​(java.io.File imageDirectory)
        Sets the image directory as the latest used image directory.
        Parameters:
        imageDirectory - the current used image directory.
      • setInterpolationMode

        public static void setInterpolationMode​(Preferences.InterpolateDisplay interp)
        Sets the display interpolation mode for 2D image display.
        Parameters:
        interp - the InterpolateDisplay type
      • setLastImage

        public static final void setLastImage​(java.lang.String name,
                                              boolean multiFile,
                                              int numDims)
        Sets the last image loaded in the Preferences file. If it is a duplicate, moves it up on the list.
        Parameters:
        name - Full pathname of last image loaded.
        multiFile - true if the last image was a multi-file image, false otherwise
        numDims - DOCUMENT ME!
      • setLastOpenSequenceParams

        public static final void setLastOpenSequenceParams​(java.lang.String slices,
                                                           java.lang.String channels,
                                                           java.lang.String timePoints,
                                                           java.lang.String ordering)
        Used by ViewOpenImageSequence to save the user's most recent slices, channels, time points, and ordering that were specified in the component.
        Parameters:
        slices - String - number of slices in the slices text box of the ViewOpenImageSequence frame
        channels - String - number of channels in the channels text box of the ViewOpenImageSequence frame
        timePoints - String - number of time points in the time points text box of the ViewOpenImageSequence frame
        ordering - String - ordering sequence used in the radio button panel of the ViewOpenImageSequence frame
      • setLastOpenSequencePath

        public static final void setLastOpenSequencePath​(java.lang.String path)
        Used by ViewOpenImageSequence to save the path used when opening an image sequence.
        Parameters:
        path - DOCUMENT ME!
      • setMessageFrame

        public static final void setMessageFrame​(ViewJFrameMessage mFrame)
        Sets the message frame.
        Parameters:
        mFrame - Message frame to set.
      • setMaxDebugLines

        public static void setMaxDebugLines​(int lines)
        Sets the maximum number of debug lines that are output
        Parameters:
        int - max number of debug lines
      • setOverlayNames

        public static final void setOverlayNames​(boolean isDicom,
                                                 java.lang.String[] overlays)
        Sets the labels for each overlay position. The labels can be user input with any text and will be displayed before the overlay values
        Parameters:
        isDicom - boolean is the image DICOM
        overlays - String[] array of strings (16) for each of the overlay positions
      • setOverlays

        public static final void setOverlays​(boolean isDicom,
                                             java.lang.String[] overlays)
        Sets the overlay tag identifiers in the preference file.
        Parameters:
        isDicom - if true identifies the tags as a list of DICOMOverlays else identifies the tags as ImageOverlays (i.e., it is not a DICOM image)
        overlays - an array of 16 strings (4 for each corner) that identifies what is to be displayed in the image.
      • setPluginInstallDirectory

        public static void setPluginInstallDirectory​(java.io.File pluginInstallDirectory)
        Sets the plugin install directory.
      • setPreferencesFileName

        public static final void setPreferencesFileName​(java.lang.String fileName)
        Change the file name of the preferences file we should use (without any path).
        Parameters:
        fileName - the file name (eg mipav.preferences), which should be in $HOME/mipav/
      • setPreferencesFileDirectory

        public static final void setPreferencesFileDirectory​(java.lang.String fileDir)
        Change the file directory of the preferences file.
        Parameters:
        fileDir - the file directory, defaults to $HOME/mipav/
      • setProperty

        public static final boolean setProperty​(java.lang.String key,
                                                java.lang.Object value)
        Sets the property key in the MIPAV property list and saves it to a file.
        Parameters:
        key - the property key.
        value - the value of the property key.
        Returns:
        true if the property was set and saved successfully, false otherwise
      • setScriptFile

        public static final void setScriptFile​(java.lang.String scriptFile)
        DOCUMENT ME!
        Parameters:
        scriptFile - DOCUMENT ME!
      • setScriptsDirectory

        public static final void setScriptsDirectory​(java.lang.String scriptsDirectory)
        Sets the scripts directory to the new scripts directory.
        Parameters:
        scriptsDirectory - the new scripts directory
      • setShowDICOMOverlays

        public static final void setShowDICOMOverlays​(boolean doShow)
        Sets whether to show the DICOM overlays.
        Parameters:
        doShow - boolean true means show DICOM overlays
      • setShowImageOverlays

        public static final void setShowImageOverlays​(boolean doShow)
        Sets whether to show the Image overlays.
        Parameters:
        doShow - boolean true means show image overlays
      • buildDefaultShortcuts

        private static java.util.Hashtable<java.lang.String,​javax.swing.KeyStroke> buildDefaultShortcuts()
        Builds the default shortcut hashtable (not user modifiable).
        Returns:
        default shortcut hashtable
      • resetToDefaults

        public static void resetToDefaults()
        Resets the current MIPAV properties to the defaults and saves the preferences file. Cannot be undone.
      • debugMessageFrameAppend

        public static void debugMessageFrameAppend​(java.lang.String string)
        Appends the specified message to the message frame. Clears the message frame first if the number of lines exceeds the maximum number of lines allowed in the frame.
      • isLogMinorEnabled

        public static boolean isLogMinorEnabled()
      • isLogAlgorithmEnabled

        public static boolean isLogAlgorithmEnabled()
      • isLogFileIOEnabled

        public static boolean isLogFileIOEnabled()
      • isLogCommsEnabled

        public boolean isLogCommsEnabled()
      • isLogScriptingEnabled

        public boolean isLogScriptingEnabled()