artofillusion
Class ApplicationPreferences

java.lang.Object
  extended by artofillusion.ApplicationPreferences

public class ApplicationPreferences
extends java.lang.Object

This class keeps track of program-wide user preferences.


Constructor Summary
ApplicationPreferences()
          Create a new ApplicationPreferences object, loading the preferences from a file in the default location.
ApplicationPreferences(java.io.InputStream in)
          Create a new ApplicationPreferences object, loading the preferences from an InputStream.
 
Method Summary
 int getDefaultDisplayMode()
          Get the default display mode.
 Renderer getDefaultRenderer()
          Get the default renderer.
 double getInteractiveSurfaceError()
          Get the interactive surface error.
 boolean getKeepBackupFiles()
          Get whether to keep backup files.
 java.util.Locale getLocale()
          Get the locale for displaying text.
 Renderer getObjectPreviewRenderer()
          Get the object preview renderer.
static java.io.File getPreferencesDirectory()
          Get the directory in which preferences files are saved.
 boolean getReverseZooming()
          Get whether to reverse the direction of scroll wheel zooming.
 Renderer getTexturePreviewRenderer()
          Get the texture preview renderer.
 int getUndoLevels()
          Get the number of levels of Undo to support.
 boolean getUseCompoundMeshTool()
          Get whether to use the compound move/scale/rotate tool as the default for mesh editing.
 boolean getUseOpenGL()
          Get whether to use OpenGL for interactive rendering.
 void savePreferences()
          Save any changed preferences to disk.
 void setDefaultDisplayMode(int mode)
          Set the default display mode.
 void setDefaultRenderer(Renderer rend)
          Set the default renderer.
 void setInteractiveSurfaceError(double tol)
          Set the interactive surface error.
 void setKeepBackupFiles(boolean keep)
          Set whether to keep backup files.
 void setLocale(java.util.Locale locale)
          Set the locale for displaying text.
 void setObjectPreviewRenderer(Renderer rend)
          Set the object preview renderer.
 void setReverseZooming(boolean reverse)
          Set whether to reverse the direction of scroll wheel zooming.
 void setTexturePreviewRenderer(Renderer rend)
          Set the texture preview renderer.
 void setUndoLevels(int levels)
          Set the number of levels of Undo to support.
 void setUseCompoundMeshTool(boolean use)
          Set whether to use the compound move/scale/rotate tool as the default for mesh editing.
 void setUseOpenGL(boolean use)
          Set whether to use OpenGL for interactive rendering.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ApplicationPreferences

public ApplicationPreferences()
Create a new ApplicationPreferences object, loading the preferences from a file in the default location.


ApplicationPreferences

public ApplicationPreferences(java.io.InputStream in)
Create a new ApplicationPreferences object, loading the preferences from an InputStream.

Method Detail

savePreferences

public void savePreferences()
Save any changed preferences to disk.


getPreferencesDirectory

public static java.io.File getPreferencesDirectory()
Get the directory in which preferences files are saved.


getDefaultRenderer

public final Renderer getDefaultRenderer()
Get the default renderer.


setDefaultRenderer

public final void setDefaultRenderer(Renderer rend)
Set the default renderer.


getObjectPreviewRenderer

public final Renderer getObjectPreviewRenderer()
Get the object preview renderer.


setObjectPreviewRenderer

public final void setObjectPreviewRenderer(Renderer rend)
Set the object preview renderer.


getTexturePreviewRenderer

public final Renderer getTexturePreviewRenderer()
Get the texture preview renderer.


setTexturePreviewRenderer

public final void setTexturePreviewRenderer(Renderer rend)
Set the texture preview renderer.


getDefaultDisplayMode

public final int getDefaultDisplayMode()
Get the default display mode.


setDefaultDisplayMode

public final void setDefaultDisplayMode(int mode)
Set the default display mode.


getInteractiveSurfaceError

public final double getInteractiveSurfaceError()
Get the interactive surface error.


setInteractiveSurfaceError

public final void setInteractiveSurfaceError(double tol)
Set the interactive surface error.


getLocale

public final java.util.Locale getLocale()
Get the locale for displaying text.


setLocale

public final void setLocale(java.util.Locale locale)
Set the locale for displaying text.


getUndoLevels

public final int getUndoLevels()
Get the number of levels of Undo to support.


setUndoLevels

public final void setUndoLevels(int levels)
Set the number of levels of Undo to support.


getUseOpenGL

public final boolean getUseOpenGL()
Get whether to use OpenGL for interactive rendering.


setUseOpenGL

public final void setUseOpenGL(boolean use)
Set whether to use OpenGL for interactive rendering.


getKeepBackupFiles

public final boolean getKeepBackupFiles()
Get whether to keep backup files.


setKeepBackupFiles

public final void setKeepBackupFiles(boolean keep)
Set whether to keep backup files.


getUseCompoundMeshTool

public final boolean getUseCompoundMeshTool()
Get whether to use the compound move/scale/rotate tool as the default for mesh editing.


setUseCompoundMeshTool

public final void setUseCompoundMeshTool(boolean use)
Set whether to use the compound move/scale/rotate tool as the default for mesh editing.


getReverseZooming

public final boolean getReverseZooming()
Get whether to reverse the direction of scroll wheel zooming.


setReverseZooming

public final void setReverseZooming(boolean reverse)
Set whether to reverse the direction of scroll wheel zooming.



Copyright © 1999-2011 by Peter Eastman.