artofillusion
Class ArtOfIllusion

java.lang.Object
  extended by artofillusion.ArtOfIllusion

public class ArtOfIllusion
extends java.lang.Object

This is the main class for Art of Illusion. All of its methods and variables are static, so no instance of this class ever gets created. It starts up the application, and maintains global variables.


Field Summary
static java.lang.String APP_DIRECTORY
           
static javax.swing.ImageIcon APP_ICON
           
static java.awt.Font defaultFont
           
static java.lang.String OBJECT_SCRIPT_DIRECTORY
           
static java.lang.String PLUGIN_DIRECTORY
           
static int standardDialogInsets
           
static java.lang.String STARTUP_SCRIPT_DIRECTORY
           
static java.lang.String TOOL_SCRIPT_DIRECTORY
           
 
Constructor Summary
ArtOfIllusion()
           
 
Method Summary
static void addWindow(EditingWindow win)
          Add a window to the list of open windows.
static void closeWindow(EditingWindow win)
          Close a window.
static void copyToClipboard(ObjectInfo[] obj, Scene scene)
          Copy a list of objects to the clipboard, so they can be pasted into either the same scene or a different one.
static java.lang.Class getClass(java.lang.String name)
          Get a class specified by name.
static int getClipboardSize()
          Get the number of objects on the clipboard.
static java.lang.String getCurrentDirectory()
          Get the directory in which the user most recently accessed a file.
static java.lang.String getMajorVersion()
          Get the major part of the version number of Art of Illusion.
static ApplicationPreferences getPreferences()
          Get the application preferences object.
static java.lang.String getVersion()
          Get the complete version number of Art of Illusion.
static EditingWindow[] getWindows()
          Get a list of all open windows.
static java.lang.String loadFile(java.io.File f)
          This is a utility routine which loads a file from disk.
static void main(java.lang.String[] args)
           
static void newWindow()
          Create a new Scene, and display it in a window.
static void newWindow(Scene theScene)
          Create a new window for editing the specified scene.
static void openScene(BFrame fr)
          Prompt the user to select a scene file, then open a new window containing it.
static void openScene(java.io.File f, BFrame fr)
          Load a scene from a file, and open a new window containing it.
static void pasteClipboard(LayoutWindow win)
          Paste the contents of the clipboard into a window.
static void quit()
          Quit Art of Illusion.
static boolean saveScene(Scene sc, LayoutWindow fr)
          Save a scene to a file.
static void setCurrentDirectory(java.lang.String currentDirectory)
          Set the directory in which the user most recently accessed a file.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

APP_DIRECTORY

public static final java.lang.String APP_DIRECTORY

PLUGIN_DIRECTORY

public static final java.lang.String PLUGIN_DIRECTORY

TOOL_SCRIPT_DIRECTORY

public static final java.lang.String TOOL_SCRIPT_DIRECTORY

OBJECT_SCRIPT_DIRECTORY

public static final java.lang.String OBJECT_SCRIPT_DIRECTORY

STARTUP_SCRIPT_DIRECTORY

public static final java.lang.String STARTUP_SCRIPT_DIRECTORY

APP_ICON

public static final javax.swing.ImageIcon APP_ICON

defaultFont

public static java.awt.Font defaultFont

standardDialogInsets

public static int standardDialogInsets
Constructor Detail

ArtOfIllusion

public ArtOfIllusion()
Method Detail

main

public static void main(java.lang.String[] args)

getVersion

public static java.lang.String getVersion()
Get the complete version number of Art of Illusion.


getMajorVersion

public static java.lang.String getMajorVersion()
Get the major part of the version number of Art of Illusion.


getPreferences

public static ApplicationPreferences getPreferences()
Get the application preferences object.


newWindow

public static void newWindow()
Create a new Scene, and display it in a window.


newWindow

public static void newWindow(Scene theScene)
Create a new window for editing the specified scene.


addWindow

public static void addWindow(EditingWindow win)
Add a window to the list of open windows.


closeWindow

public static void closeWindow(EditingWindow win)
Close a window.


getWindows

public static EditingWindow[] getWindows()
Get a list of all open windows.


quit

public static void quit()
Quit Art of Illusion.


getClass

public static java.lang.Class getClass(java.lang.String name)
                                throws java.lang.ClassNotFoundException
Get a class specified by name. This checks both the system classes, and all plugins. It also accounts for classes which changed packages in version 1.3.

Throws:
java.lang.ClassNotFoundException

loadFile

public static java.lang.String loadFile(java.io.File f)
                                 throws java.io.IOException
This is a utility routine which loads a file from disk.

Throws:
java.io.IOException

saveScene

public static boolean saveScene(Scene sc,
                                LayoutWindow fr)
Save a scene to a file. This method returns true if the scene is successfully saved, false if an error occurs.


openScene

public static void openScene(BFrame fr)
Prompt the user to select a scene file, then open a new window containing it. The BFrame is used for displaying dialogs.


openScene

public static void openScene(java.io.File f,
                             BFrame fr)
Load a scene from a file, and open a new window containing it. The BFrame is used for displaying dialogs.


copyToClipboard

public static void copyToClipboard(ObjectInfo[] obj,
                                   Scene scene)
Copy a list of objects to the clipboard, so they can be pasted into either the same scene or a different one.


pasteClipboard

public static void pasteClipboard(LayoutWindow win)
Paste the contents of the clipboard into a window.


getClipboardSize

public static int getClipboardSize()
Get the number of objects on the clipboard.


getCurrentDirectory

public static java.lang.String getCurrentDirectory()
Get the directory in which the user most recently accessed a file.


setCurrentDirectory

public static void setCurrentDirectory(java.lang.String currentDirectory)
Set the directory in which the user most recently accessed a file.



Copyright © 1999-2011 by Peter Eastman.