Sweet Home 3D 3.4

com.eteks.sweethome3d.viewcontroller
Interface HomeView

All Superinterfaces:
View
All Known Implementing Classes:
HomePane

public interface HomeView
extends View

The main view that displays a home.

Author:
Emmanuel Puybaret

Nested Class Summary
static class HomeView.ActionType
          The actions proposed by the view to user.
static class HomeView.SaveAnswer
           
 
Method Summary
 void attachView(View view)
          Attaches the given view to home view.
 boolean confirmDeleteCatalogSelection()
          Displays a dialog that let user choose whether he wants to delete the selected furniture from catalog or not.
 boolean confirmExit()
          Displays a dialog that let user choose whether he wants to exit application or not.
 boolean confirmReplaceFurnitureLibrary(java.lang.String furnitureLibraryName)
          Displays a dialog that lets user choose whether he wants to overwrite an existing furniture library or not.
 boolean confirmReplaceLanguageLibrary(java.lang.String languageLibraryName)
          Displays a dialog that lets user choose whether he wants to overwrite an existing language library or not.
 boolean confirmReplacePlugin(java.lang.String pluginName)
          Displays a dialog that lets user choose whether he wants to overwrite an existing plug-in or not.
 boolean confirmReplaceTexturesLibrary(java.lang.String texturesLibraryName)
          Displays a dialog that lets user choose whether he wants to overwrite an existing textures library or not.
 HomeView.SaveAnswer confirmSave(java.lang.String homeName)
          Displays a dialog that lets user choose whether he wants to save the current home or not.
 boolean confirmSaveNewerHome(java.lang.String homeName)
          Displays a dialog that let user choose whether he wants to save a home that was created with a newer version of Sweet Home 3D.
 void detachView(View view)
          Detaches the given view from home view.
 void exportToOBJ(java.lang.String objFile)
          Exports the 3D home objects to a given OBJ file.
 void exportToSVG(java.lang.String svgName)
          Exports the plan objects to a given SVG file.
 void invokeLater(java.lang.Runnable runnable)
          Execute runnable asynchronously in the thread that manages toolkit events.
 boolean isClipboardEmpty()
          Returns true if clipboard contains data that components are able to handle.
 void printToPDF(java.lang.String pdfFile)
          Prints a home to a given PDF file.
 void setEnabled(HomeView.ActionType actionType, boolean enabled)
          Enables or disables the action matching actionType.
 void setTransferEnabled(boolean enabled)
          Enables or disables transfer between components.
 void setUndoRedoName(java.lang.String undoText, java.lang.String redoText)
          Sets the name and tool tip of undo and redo actions.
 void showAboutDialog()
          Displays an about dialog.
 boolean showActionTipMessage(java.lang.String actionTipKey)
          Displays the tip matching actionTipKey and returns true if the user chose not to display again the tip.
 void showError(java.lang.String message)
          Displays message in an error message box.
 java.lang.String showExportToOBJDialog(java.lang.String homeName)
          Shows a content chooser save dialog to export a 3D home in a OBJ file.
 java.lang.String showExportToSVGDialog(java.lang.String name)
          Shows a content chooser save dialog to export a home plan in a SVG file.
 java.lang.String showImportFurnitureLibraryDialog()
          Displays a content chooser open dialog to choose a furniture library.
 java.lang.String showImportLanguageLibraryDialog()
          Displays a content chooser open dialog to choose a language library.
 java.lang.String showImportTexturesLibraryDialog()
          Displays a content chooser open dialog to choose a textures library.
 void showMessage(java.lang.String message)
          Displays message in a message box.
 java.lang.String showOpenDialog()
          Displays a content chooser open dialog to choose the name of a home.
 java.util.concurrent.Callable<java.lang.Void> showPrintDialog()
          Shows a print dialog to print the home displayed by this pane.
 java.lang.String showPrintToPDFDialog(java.lang.String homeName)
          Shows a content chooser save dialog to print a home in a PDF file.
 java.lang.String showSaveDialog(java.lang.String homeName)
          Displays a content chooser save dialog to choose the name of a home.
 java.lang.String showStoreCameraDialog(java.lang.String cameraName)
          Displays a dialog that lets the user choose a name for the current camera.
 

Method Detail

setEnabled

void setEnabled(HomeView.ActionType actionType,
                boolean enabled)
Enables or disables the action matching actionType.


setUndoRedoName

void setUndoRedoName(java.lang.String undoText,
                     java.lang.String redoText)
Sets the name and tool tip of undo and redo actions. If a parameter is null, the properties will be reset to their initial values.


setTransferEnabled

void setTransferEnabled(boolean enabled)
Enables or disables transfer between components.


detachView

void detachView(View view)
Detaches the given view from home view.


attachView

void attachView(View view)
Attaches the given view to home view.


showOpenDialog

java.lang.String showOpenDialog()
Displays a content chooser open dialog to choose the name of a home.


showImportLanguageLibraryDialog

java.lang.String showImportLanguageLibraryDialog()
Displays a content chooser open dialog to choose a language library.


confirmReplaceLanguageLibrary

boolean confirmReplaceLanguageLibrary(java.lang.String languageLibraryName)
Displays a dialog that lets user choose whether he wants to overwrite an existing language library or not.


showImportFurnitureLibraryDialog

java.lang.String showImportFurnitureLibraryDialog()
Displays a content chooser open dialog to choose a furniture library.


confirmReplaceFurnitureLibrary

boolean confirmReplaceFurnitureLibrary(java.lang.String furnitureLibraryName)
Displays a dialog that lets user choose whether he wants to overwrite an existing furniture library or not.


showImportTexturesLibraryDialog

java.lang.String showImportTexturesLibraryDialog()
Displays a content chooser open dialog to choose a textures library.


confirmReplaceTexturesLibrary

boolean confirmReplaceTexturesLibrary(java.lang.String texturesLibraryName)
Displays a dialog that lets user choose whether he wants to overwrite an existing textures library or not.


confirmReplacePlugin

boolean confirmReplacePlugin(java.lang.String pluginName)
Displays a dialog that lets user choose whether he wants to overwrite an existing plug-in or not.


showSaveDialog

java.lang.String showSaveDialog(java.lang.String homeName)
Displays a content chooser save dialog to choose the name of a home.


confirmSave

HomeView.SaveAnswer confirmSave(java.lang.String homeName)
Displays a dialog that lets user choose whether he wants to save the current home or not.

Returns:
HomeView.SaveAnswer.SAVE if user chose to save home, HomeView.SaveAnswer.DO_NOT_SAVE if user don't want to save home, or HomeView.SaveAnswer.CANCEL if doesn't want to continue current operation.

confirmSaveNewerHome

boolean confirmSaveNewerHome(java.lang.String homeName)
Displays a dialog that let user choose whether he wants to save a home that was created with a newer version of Sweet Home 3D.

Returns:
true if user confirmed to save.

confirmDeleteCatalogSelection

boolean confirmDeleteCatalogSelection()
Displays a dialog that let user choose whether he wants to delete the selected furniture from catalog or not.

Returns:
true if user confirmed to delete.

confirmExit

boolean confirmExit()
Displays a dialog that let user choose whether he wants to exit application or not.

Returns:
true if user confirmed to exit.

showError

void showError(java.lang.String message)
Displays message in an error message box.


showMessage

void showMessage(java.lang.String message)
Displays message in a message box.


showActionTipMessage

boolean showActionTipMessage(java.lang.String actionTipKey)
Displays the tip matching actionTipKey and returns true if the user chose not to display again the tip.


showAboutDialog

void showAboutDialog()
Displays an about dialog.


showPrintDialog

java.util.concurrent.Callable<java.lang.Void> showPrintDialog()
Shows a print dialog to print the home displayed by this pane.

Returns:
a print task to execute or null if the user canceled print. The call method of the returned task may throw a RecorderException exception if print failed or an InterruptedRecorderException exception if it was interrupted.

showPrintToPDFDialog

java.lang.String showPrintToPDFDialog(java.lang.String homeName)
Shows a content chooser save dialog to print a home in a PDF file.


printToPDF

void printToPDF(java.lang.String pdfFile)
                throws RecorderException
Prints a home to a given PDF file. This method may be overridden to write to another kind of output stream.

Throws:
RecorderException

showExportToSVGDialog

java.lang.String showExportToSVGDialog(java.lang.String name)
Shows a content chooser save dialog to export a home plan in a SVG file.


exportToSVG

void exportToSVG(java.lang.String svgName)
                 throws RecorderException
Exports the plan objects to a given SVG file.

Throws:
RecorderException

showExportToOBJDialog

java.lang.String showExportToOBJDialog(java.lang.String homeName)
Shows a content chooser save dialog to export a 3D home in a OBJ file.


exportToOBJ

void exportToOBJ(java.lang.String objFile)
                 throws RecorderException
Exports the 3D home objects to a given OBJ file.

Throws:
RecorderException

showStoreCameraDialog

java.lang.String showStoreCameraDialog(java.lang.String cameraName)
Displays a dialog that lets the user choose a name for the current camera.


isClipboardEmpty

boolean isClipboardEmpty()
Returns true if clipboard contains data that components are able to handle.


invokeLater

void invokeLater(java.lang.Runnable runnable)
Execute runnable asynchronously in the thread that manages toolkit events.


Sweet Home 3D 3.4

? Copyrights 2006-2011 eTeks - All rights reserved
Distributed under GNU General Public License