Revision: 5196
          http://sourceforge.net/p/jump-pilot/code/5196
Author:   ma15569
Date:     2016-11-19 10:44:08 +0000 (Sat, 19 Nov 2016)
Log Message:
-----------
Added Sextante GUI source

Added Paths:
-----------
    plug-ins/SextantePlugIn/sextante-lib-source/sextante/
    plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/
    plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/
    plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/
    plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/additionalResults/
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/additionalResults/AdditionalResults.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/additionalResults/AdditionalResultsDialog.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/additionalResults/AdditionalResultsTreeCellRenderer.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/additionalResults/TableTools.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/AlgorithmDialog.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/AnalysisExtentPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/CheckBoxList.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/DatabaseOutputChannelSelectionPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/DefaultParametersPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/ExtentFromSavedPointsDialog.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/FileOutputChannelSelectionPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/FileSelectionComboPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/FileSelectionPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/FixedTableDialog.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/FixedTablePanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/GeneralOptionsChannelSelectionPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/GenericFileFilter.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/GeoAlgorithmParametersPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/MultipleInputSelectionDialog.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/OutputChannelSelectionDialog.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/OutputChannelSelectionPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/OutputParameterContainer.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/ParameterContainer.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/PointSelectionPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/TridimensionalAnalysisExtentPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/iterative/
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/iterative/IterativeAlgorithmMonitorableTask.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/iterative/IterativeAlgorithmSingleUnit.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/iterative/SingleFeatureIterator.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/iterative/SingleFeatureVectorLayer.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/batch/
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/batch/AnalysisExtentPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/batch/AutoCompletePanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/batch/BatchProcessDialog.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/batch/BatchProcessMonitorableTask.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/batch/BatchProcessSingleUnit.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/batch/MultipleBandSelectionDialog.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/batch/MultipleBandsSelectionTableModel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/batch/ParameterCellPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/batch/ParameterCellPanelEditor.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/batch/ParameterCellPanelRenderer.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/batch/ParametersPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/batch/ParametersTableModel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/batch/PointSelectionDialog.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/batch/PointSelectionPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/batch/RasterBandPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/batch/RasterBandPanelEditor.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/batch/RasterFilePanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/batch/RasterFilePanelEditor.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/batch/TextFieldAndButton.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/batch/TridimensionalAnalysisExtentPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/batch/nonFileBased/
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/batch/nonFileBased/AutoCompletePanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/batch/nonFileBased/BatchProcessDialog.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/batch/nonFileBased/BatchProcessMonitorableTask.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/batch/nonFileBased/BatchProcessSingleUnit.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/batch/nonFileBased/ParameterCellPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/batch/nonFileBased/ParameterCellPanelEditor.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/batch/nonFileBased/ParameterCellPanelRenderer.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/batch/nonFileBased/ParametersPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/batch/nonFileBased/ParametersTableModel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/batch/nonFileBased/PointSelectionDialog.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/batch/nonFileBased/PointSelectionPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/cmd/
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/cmd/BSHDialog.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/cmd/CommandLineData.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/cmd/CreateScriptToolboxAction.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/cmd/EditScriptAction.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/cmd/OpenCommandLineInterfaceAction.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/cmd/Parser.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/cmd/ScriptAlgorithm.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/cmd/ScriptAlgorithmProvider.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/cmd/ScriptEditingPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/cmd/ScriptsIO.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/cmd/bshcommands/
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/cmd/bshcommands/algs.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/cmd/bshcommands/autoextent.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/cmd/bshcommands/close.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/cmd/bshcommands/data.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/cmd/bshcommands/describe.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/cmd/bshcommands/describealg.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/cmd/bshcommands/extent.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/cmd/bshcommands/getrasterlayers.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/cmd/bshcommands/gettables.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/cmd/bshcommands/getvectorlayers.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/cmd/bshcommands/open.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/cmd/bshcommands/options.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/cmd/bshcommands/rename.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/cmd/bshcommands/runalg.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/cmd/bshcommands/setnodata.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/core/
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/core/DefaultDataRenderer.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/core/DefaultGUIFactory.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/core/DefaultTaskMonitor.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/core/GUIResources.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/core/GenericDialog.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/core/GenericInfoDialog.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/core/GeoAlgorithmExecutors.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/core/IAlgorithmProvider.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/core/IDataRenderer.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/core/IGUIFactory.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/core/IPostProcessTaskFactory.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/core/IToolboxRightButtonAction.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/core/NameAndIcon.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/core/NamedPoint.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/core/ProgressMonitor.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/core/RenderingData.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/core/SextanteGUI.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/core/TextFieldServices.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/core/ToolboxAction.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/dataExplorer/
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/dataExplorer/Action.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/dataExplorer/BandTreeNode.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/dataExplorer/DataExplorerDialog.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/dataExplorer/DataExplorerPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/dataExplorer/DataExplorerTreeCellRenderer.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/dataExplorer/Modify.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/dataExplorer/ModifyNoDataValue.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/dataExplorer/ShowTable.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/dataExplorer/TableDialog.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/exceptions/
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/exceptions/AlgorithmNotFoundException.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/exceptions/CommandLineException.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/exceptions/LayerCannotBeOverwrittenException.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/exceptions/ModelIOException.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/exceptions/ModelNotFoundException.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/exceptions/OutputExtentNotSetException.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/exceptions/OverwrittingNotAllowedException.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/exceptions/TooLargeGridExtentException.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/exceptions/WPSProcessNotFoundException.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/exceptions/WrongGrassFolderException.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/exceptions/WrongGrassMapsetFolderException.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/exceptions/WrongGrassWinShellException.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/exceptions/WrongNumberOfParametersException.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/exceptions/WrongScriptException.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/exceptions/WrongSettingValuesException.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/exceptions/WrongViewNameException.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/grass/
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/grass/GrassAlgorithm.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/grass/GrassAlgorithmProvider.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/grass/GrassBlackList.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/grass/GrassExecutionException.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/grass/GrassModelerBlackList.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/grass/GrassModelerParametersPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/grass/GrassParametersPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/grass/GrassUtils.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/grass/GrassVInfoUtils.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/grass/UnwrappableGrassProcessException.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/help/
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/help/AlgorithmTreeCellRenderer.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/help/ElementEditionPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/help/FileUtilities.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/help/HelpEditionDialog.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/help/HelpElement.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/help/HelpIO.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/help/ImageAndDescription.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/help/ImageSelectionDialog.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/help/ImageSelectionPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/help/SextanteHelpWindow.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/history/
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/history/DateAndCommand.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/history/History.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/history/HistoryDialog.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/history/HistoryPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/history/NonWordWrapPane.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/AlgorithmCellRenderer.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/AlgorithmDialog.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/AlgorithmsPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/ColorComboBox.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/CreateModelToolboxAction.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/CustomCellRenderer.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/DefaultModelerParametersPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/DeleteModelAction.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/EditModelAction.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/FixedTableSelectionPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/GeoAlgorithmModelerParametersPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/InputsPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/ModelAlgorithm.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/ModelAlgorithmIO.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/ModelCodeCreator.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/ModelFileFilter.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/ModelGraphPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/ModelerAlgorithmProvider.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/ModelerDialog.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/ModelerPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/MultipleInputSelectionDialog.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/OutputLayerSettings.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/OutputLayerSettingsPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/OutputParameterContainer.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/SelectionAndChoices.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/parameters/
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/parameters/BooleanPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/parameters/FilepathPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/parameters/FixedTablePanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/parameters/ImageLayerPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/parameters/MultipleInputPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/parameters/NumericalValuePanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/parameters/ParameterPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/parameters/ParameterPanelFactory.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/parameters/PointPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/parameters/Raster3DLayerPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/parameters/RasterBandPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/parameters/RasterLayerPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/parameters/SelectionPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/parameters/SelectionTreePanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/parameters/StringPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/parameters/TableFieldPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/parameters/TablePanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/modeler/parameters/VectorLayerPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/r/
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/r/EditRScriptAction.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/r/RAlgorithm.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/r/RAlgorithmProvider.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/r/RConsoleToolboxAction.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/r/RExecutionException.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/r/RScriptEditingPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/r/RScriptsIO.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/r/RUtils.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/saga/
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/saga/SagaAlgorithm.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/saga/SagaAlgorithmProvider.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/saga/SagaBlackList.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/saga/SagaExecutionException.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/saga/SagaLibraryNames.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/saga/SagaUtils.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/saga/UnwrappableSagaAlgorithmException.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/settings/
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/settings/AlgorithmGroupsConfigurationDialog.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/settings/AlgorithmGroupsConfigurationTableModel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/settings/Setting.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/settings/SettingPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/settings/SextanteConfigurationDialog.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/settings/SextanteGeneralSettings.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/settings/SextanteGeneralSettingsPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/settings/SextanteGrassSettings.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/settings/SextanteGrassSettingsPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/settings/SextanteModelerSettings.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/settings/SextanteModelerSettingsPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/settings/SextanteRSettings.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/settings/SextanteRSettingsPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/settings/SextanteSagaSettings.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/settings/SextanteSagaSettingsPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/settings/SextanteScriptsSettings.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/settings/SextanteScriptsSettingsPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/toolbox/
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/toolbox/AlgorithmGroupConfiguration.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/toolbox/AlgorithmGroupsOrganizer.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/toolbox/AlgorithmTreeCellRenderer.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/toolbox/AlgorithmsPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/toolbox/IToolboxDialog.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/toolbox/OutputRenderingSettingsDialog.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/toolbox/TextSearchPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/toolbox/ToolboxDialog.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/toolbox/ToolboxPanel.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/toolbox/TransparentScrollPane.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/win32/
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/win32/Kernel32.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/win32/W32API.java
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/win32/W32Errors.java
    plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/i18n/
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/i18n/SextanteGui_fr.properties
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/i18n/sextanteGui.properties
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/i18n/sextanteGui_es.properties
    plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/
    plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/README
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/Rlogo.gif
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/application-terminal.png
    plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/book.png
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/bullseye.gif
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/chart.gif
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/chart_organisation.png
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/config.png
    plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/copy.png
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/documenter.png
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/font_larger.gif
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/font_smaller.gif
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/grass.png
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/grass.smlogo.gif
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/history.gif
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/image_layer.gif
    plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/info.gif
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/layers.gif
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/list-add.png
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/logo_saga.png
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/model.png
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/module2.png
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/module_wrong.png
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/paste.png
    plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/r.png
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/raster_layer.gif
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/report-image.png
    plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/saga.png
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/sextante.gif
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/sextante_toolbox.gif
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/sextante_toolbox2.gif
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/table_icon.png
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/target.png
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/terminal.png
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/vector_layer.gif
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/images/wrench-screwdriver.png
    plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/jsh/
    plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/jsh/shell/
    
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/jsh/shell/Utils.java

Removed Paths:
-------------
    plug-ins/SextantePlugIn/sextante-lib-source/Sextante/

Added: 
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/additionalResults/AdditionalResults.java
===================================================================
--- 
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/additionalResults/AdditionalResults.java
                          (rev 0)
+++ 
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/additionalResults/AdditionalResults.java
  2016-11-19 10:44:08 UTC (rev 5196)
@@ -0,0 +1,73 @@
+package es.unex.sextante.gui.additionalResults;
+
+import java.util.ArrayList;
+
+import es.unex.sextante.core.ObjectAndDescription;
+import es.unex.sextante.gui.core.SextanteGUI;
+
+/**
+ * This class stores results generated by SEXTANTE geoalgorithms that are
+ * neither layers nor tables (i.e text results and charts). They are all stored
+ * as java Component objects, so they can be shown in a dialogs. Charts do not
+ * have to be modified, since they already extend the Component class. Text
+ * strings should be put into some kind of panel or TextArea. This is not done
+ * by this class, but should be done by the corresponding post-process task 
(see
+ * {IPostProcessFactory})
+ *
+ * @author volaya
+ *
+ */
+public class AdditionalResults {
+
+    private static ArrayList<ObjectAndDescription> m_Components = new 
ArrayList<ObjectAndDescription>();
+
+    /**
+     * Shows a panel with results, only if there is at least one of them,
+     */
+    public static void showPanel() {
+
+        if (m_Components == null || m_Components.size() == 0) {
+            return;
+        }
+
+        SextanteGUI.getGUIFactory().showAdditionalResultsDialog(m_Components);
+
+    }
+
+    /**
+     * Returns the list of results as a list of components
+     *
+     * @return the list of results
+     */
+    public static ArrayList<ObjectAndDescription> getComponents() {
+
+        return m_Components;
+
+    }
+
+    /**
+     * Adds a new result
+     *
+     * @param oad
+     *            a result and its description, to be shown in the 
corresponding
+     *            panel
+     */
+    public static void addComponent(final ObjectAndDescription oad) {
+
+        m_Components.add(oad);
+
+    }
+
+    /**
+     * Removes a result
+     *
+     * @param oad
+     *            The result to remove
+     */
+    public static void removeComponent(final ObjectAndDescription oad) {
+
+        m_Components.remove(oad);
+
+    }
+
+}


Property changes on: 
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/additionalResults/AdditionalResults.java
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+text/plain
\ No newline at end of property
Added: 
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/additionalResults/AdditionalResultsDialog.java
===================================================================
--- 
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/additionalResults/AdditionalResultsDialog.java
                            (rev 0)
+++ 
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/additionalResults/AdditionalResultsDialog.java
    2016-11-19 10:44:08 UTC (rev 5196)
@@ -0,0 +1,484 @@
+package es.unex.sextante.gui.additionalResults;
+
+import java.awt.BorderLayout;
+import java.awt.Component;
+import java.awt.Dimension;
+import java.awt.Frame;
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+import java.awt.event.MouseAdapter;
+import java.awt.event.MouseEvent;
+import java.awt.event.MouseListener;
+import java.io.BufferedWriter;
+import java.io.File;
+import java.io.FileWriter;
+import java.util.ArrayList;
+import java.util.Enumeration;
+
+import javax.swing.JDialog;
+import javax.swing.JFileChooser;
+import javax.swing.JMenuItem;
+import javax.swing.JOptionPane;
+import javax.swing.JPanel;
+import javax.swing.JPopupMenu;
+import javax.swing.JScrollPane;
+import javax.swing.JSplitPane;
+import javax.swing.JTable;
+import javax.swing.JTextPane;
+import javax.swing.JTree;
+import javax.swing.ScrollPaneConstants;
+import javax.swing.table.TableModel;
+import javax.swing.tree.DefaultMutableTreeNode;
+import javax.swing.tree.DefaultTreeModel;
+import javax.swing.tree.TreePath;
+
+import org.jfree.chart.ChartPanel;
+import org.jfree.chart.ChartUtilities;
+
+import es.unex.sextante.core.ObjectAndDescription;
+import es.unex.sextante.core.Sextante;
+import es.unex.sextante.gui.algorithm.GenericFileFilter;
+import es.unex.sextante.gui.core.SextanteGUI;
+
+public class AdditionalResultsDialog extends JDialog {
+
+    /**
+     * 
+     */
+    private static final long serialVersionUID = 1L;
+    private JSplitPane jSplitPane;
+    private JTree jTree;
+    private TreePath m_Path;
+    private JScrollPane jScrollPane;
+    private JMenuItem menuItemSave;
+    private JPopupMenu popupMenu;
+    private JMenuItem menuItemRemove;
+    private JMenuItem menuItemRename;
+
+    private static int FILE_BROWSER_WIDTH = 800;
+    private static int FILE_BROWSER_HEIGHT = 600;
+    private static String LAST_DIR = null;
+
+    public AdditionalResultsDialog(final ArrayList<?> components,
+            final Frame mainFrame) {
+
+        super(mainFrame, Sextante.getText("Result"), true);
+
+        initGUI(components);
+        setLocationRelativeTo(null);
+
+    }
+
+    private boolean initGUI(final ArrayList<?> components) {
+
+        final JPanel panel = new JPanel();
+        final BorderLayout thisLayout = new BorderLayout();
+        panel.setLayout(thisLayout);
+        this.setContentPane(panel);
+
+        if (components.size() == 0) {
+            return false;
+        }
+        try {
+            {
+                this.setPreferredSize(new java.awt.Dimension(700, 350));
+                this.setSize(new java.awt.Dimension(700, 350));
+                {
+                    jSplitPane = new JSplitPane();
+                    panel.add(jSplitPane, BorderLayout.CENTER);
+                    {
+                        jTree = new JTree();
+                        jTree.setCellRenderer(new 
AdditionalResultsTreeCellRenderer());
+                        final MouseListener ml = new MouseAdapter() {
+                            @Override
+                            public void mousePressed(MouseEvent e) {
+                                m_Path = jTree.getPathForLocation(e.getX(),
+                                        e.getY());
+                                showComponent();
+                                if ((e.getButton() == MouseEvent.BUTTON3)
+                                        && (m_Path != null)) {
+                                    DefaultMutableTreeNode node = 
(DefaultMutableTreeNode) m_Path
+                                            .getLastPathComponent();
+                                    if (node.getUserObject() instanceof 
ObjectAndDescription) {
+                                        showPopupMenu(e);
+                                    }
+                                }
+                            }
+                        };
+                        jTree.addMouseListener(ml);
+
+                        fillTree(components);
+
+                        if (components.size() > 0) {
+                            final DefaultMutableTreeNode node = 
findNode((ObjectAndDescription) components
+                                    .get(components.size() - 1));
+                            final DefaultTreeModel model = (DefaultTreeModel) 
jTree
+                                    .getModel();
+                            final TreePath path = new TreePath(
+                                    model.getPathToRoot(node));
+                            jTree.setSelectionPath(path);
+                            jTree.scrollPathToVisible(path);
+                            m_Path = path;
+                            showComponent();
+                        }
+
+                        jScrollPane = new JScrollPane(
+                                jTree,
+                                ScrollPaneConstants.VERTICAL_SCROLLBAR_ALWAYS,
+                                
ScrollPaneConstants.HORIZONTAL_SCROLLBAR_AS_NEEDED);
+
+                        jScrollPane.setPreferredSize(new Dimension(200, 450));
+                        jScrollPane.setMinimumSize(new Dimension(200, 450));
+                        jScrollPane.setMaximumSize(new Dimension(200, 450));
+                    }
+                    {
+                        jSplitPane.add(jScrollPane, JSplitPane.LEFT);
+                    }
+                }
+            }
+
+            popupMenu = new JPopupMenu("Menu");
+
+            menuItemSave = new JMenuItem(Sextante.getText("Save"));
+            menuItemSave.addActionListener(new ActionListener() {
+                public void actionPerformed(final ActionEvent evt) {
+                    if (m_Path != null) {
+                        try {
+                            final DefaultMutableTreeNode node = 
(DefaultMutableTreeNode) m_Path
+                                    .getLastPathComponent();
+                            if (node.getUserObject() instanceof 
ObjectAndDescription) {
+                                save();
+                            }
+                        } catch (final Exception e) {
+                        }
+                    }
+                }
+            });
+            popupMenu.add(menuItemSave);
+
+            menuItemRemove = new JMenuItem(Sextante.getText("Remove"));
+            menuItemRemove.addActionListener(new ActionListener() {
+                public void actionPerformed(final ActionEvent evt) {
+                    if (m_Path != null) {
+                        try {
+                            final DefaultMutableTreeNode node = 
(DefaultMutableTreeNode) m_Path
+                                    .getLastPathComponent();
+                            if (node.getUserObject() instanceof 
ObjectAndDescription) {
+                                remove();
+                            }
+                        } catch (final Exception e) {
+                        }
+                    }
+                    ;
+                }
+            });
+            popupMenu.add(menuItemRemove);
+
+            menuItemRename = new JMenuItem(Sextante.getText("Rename"));
+            menuItemRename.addActionListener(new ActionListener() {
+                public void actionPerformed(final ActionEvent evt) {
+                    if (m_Path != null) {
+                        try {
+                            final DefaultMutableTreeNode node = 
(DefaultMutableTreeNode) m_Path
+                                    .getLastPathComponent();
+                            if (node.getUserObject() instanceof 
ObjectAndDescription) {
+                                rename();
+                            }
+                        } catch (final Exception e) {
+                        }
+                    }
+                    ;
+                }
+
+            });
+            popupMenu.add(menuItemRename);
+
+            panel.updateUI();
+            return true;
+        } catch (final Exception e) {
+            Sextante.addErrorToLog(e);
+            return false;
+        }
+
+    }
+
+    protected void showPopupMenu(final MouseEvent e) {
+
+        jTree.setSelectionPath(m_Path);
+
+        menuItemSave.setEnabled(true);
+        popupMenu.show(e.getComponent(), e.getX(), e.getY());
+
+    }
+
+    private void rename() {
+
+        if (m_Path != null) {
+            try {
+                final DefaultMutableTreeNode node = (DefaultMutableTreeNode) 
m_Path
+                        .getLastPathComponent();
+                final ObjectAndDescription oad = (ObjectAndDescription) node
+                        .getUserObject();
+                final String sName = oad.getDescription();
+
+                final JOptionPane pane = new JOptionPane();
+                pane.setMessage(Sextante.getText("introduce_nombre"));
+                pane.setMessageType(JOptionPane.QUESTION_MESSAGE);
+                pane.setWantsInput(true);
+                pane.setInitialSelectionValue(sName);
+                pane.setInputValue(sName);
+                final JDialog dlg = pane.createDialog(null,
+                        Sextante.getText("renombrar"));
+                dlg.setModal(true);
+                dlg.setVisible(true);
+
+                final String sNewName = pane.getInputValue().toString().trim();
+
+                if ((sNewName != null) && (sNewName.length() != 0)) {
+                    oad.setDescription(sNewName);
+                }
+
+                update();
+            } catch (final Exception e) {
+            }
+        }
+
+    }
+
+    protected void remove() {
+
+        if (m_Path != null) {
+            try {
+                final DefaultMutableTreeNode node = (DefaultMutableTreeNode) 
m_Path
+                        .getLastPathComponent();
+                final ObjectAndDescription oad = (ObjectAndDescription) node
+                        .getUserObject();
+                AdditionalResults.removeComponent(oad);
+                update();
+            } catch (final Exception e) {
+            }
+        }
+
+    }
+
+    /*
+     * [Giuseppe Aruta 12/11/2016] Add automatic extension to saved files 
(html,
+     * csv and png). Increased of 1/2 dimension of output png file
+     */
+    protected void save() {
+
+        if (m_Path != null) {
+            try {
+                final DefaultMutableTreeNode node = (DefaultMutableTreeNode) 
m_Path
+                        .getLastPathComponent();
+                final ObjectAndDescription oad = (ObjectAndDescription) node
+                        .getUserObject();
+                final Component c = (Component) oad.getObject();
+                if (c instanceof JScrollPane) {
+                    final JScrollPane pane = (JScrollPane) c;
+                    final Component view = pane.getViewport().getView();
+                    if (view instanceof JTextPane) {
+                        final JTextPane text = (JTextPane) pane.getViewport()
+                                .getView();
+                        final JFileChooser fc = new JFileChooser();
+                        fc.setPreferredSize(new Dimension(FILE_BROWSER_WIDTH,
+                                FILE_BROWSER_HEIGHT));
+                        if (LAST_DIR != null) {
+                            fc.setCurrentDirectory(new File(LAST_DIR));
+                        } else {
+                            fc.setCurrentDirectory(new File(SextanteGUI
+                                    .getOutputFolder()));
+                        }
+                        fc.setFileFilter(new GenericFileFilter(
+                                new String[] { "htm" }, "HTML"));
+                        final int returnVal = fc.showSaveDialog(this);
+                        FILE_BROWSER_WIDTH = fc.getWidth();
+                        FILE_BROWSER_HEIGHT = fc.getHeight();
+                        if (returnVal == JFileChooser.APPROVE_OPTION) {
+                            try {
+                                // final File file = fc.getSelectedFile();
+                                final File file = new File(fc.getSelectedFile()
+                                        + ".htm");
+                                LAST_DIR = file.getParent();
+                                final FileWriter fileWriter = new FileWriter(
+                                        file);
+                                final BufferedWriter bufferedWriter = new 
BufferedWriter(
+                                        fileWriter);
+                                bufferedWriter.write(text.getText());
+                                bufferedWriter.close();
+                            } catch (final Exception e) {
+                                JOptionPane.showMessageDialog(null,
+                                        "Could not save selected result",
+                                        Sextante.getText("Warning"),
+                                        JOptionPane.WARNING_MESSAGE);
+                            }
+                        }
+                    } else if (view instanceof JTable) {
+                        final JTable table = (JTable) pane.getViewport()
+                                .getView();
+                        final TableModel model = table.getModel();
+                        final JFileChooser fc = new JFileChooser();
+                        fc.setPreferredSize(new Dimension(FILE_BROWSER_WIDTH,
+                                FILE_BROWSER_HEIGHT));
+                        if (LAST_DIR != null) {
+                            fc.setCurrentDirectory(new File(LAST_DIR));
+                        } else {
+                            fc.setCurrentDirectory(new File(SextanteGUI
+                                    .getOutputFolder()));
+                        }
+                        fc.setFileFilter(new GenericFileFilter(
+                                new String[] { "csv" },
+                                "Comma-Separated Values (csv)"));
+                        final int returnVal = fc.showSaveDialog(this);
+                        FILE_BROWSER_WIDTH = fc.getWidth();
+                        FILE_BROWSER_HEIGHT = fc.getHeight();
+                        if (returnVal == JFileChooser.APPROVE_OPTION) {
+                            try {
+                                // final File file = fc.getSelectedFile();
+                                final File file = new File(fc.getSelectedFile()
+                                        + ".csv");
+                                LAST_DIR = file.getParent();
+                                final FileWriter fileWriter = new FileWriter(
+                                        file);
+                                final BufferedWriter bufferedWriter = new 
BufferedWriter(
+                                        fileWriter);
+                                for (int j = 0; j < model.getColumnCount(); 
j++) {
+                                    bufferedWriter
+                                            .write(model.getColumnName(j));
+                                    if (j == model.getColumnCount() - 1) {
+                                        bufferedWriter.write("\n");
+                                    } else {
+                                        bufferedWriter.write(",");
+                                    }
+                                }
+                                for (int i = 0; i < model.getRowCount(); i++) {
+                                    for (int j = 0; j < 
model.getColumnCount(); j++) {
+                                        bufferedWriter.write(model.getValueAt(
+                                                i, j).toString());
+                                        if (j == model.getColumnCount() - 1) {
+                                            bufferedWriter.write("\n");
+                                        } else {
+                                            bufferedWriter.write(",");
+                                        }
+                                    }
+                                }
+                                bufferedWriter.close();
+                            } catch (final Exception e) {
+                                JOptionPane.showMessageDialog(null,
+                                        "Could not save selected result",
+                                        Sextante.getText("Warning"),
+                                        JOptionPane.WARNING_MESSAGE);
+                            }
+                        }
+                    }
+                } else if (c instanceof ChartPanel) {
+                    final ChartPanel panel = (ChartPanel) c;
+                    final JFileChooser fc = new JFileChooser();
+                    fc.setPreferredSize(new Dimension(FILE_BROWSER_WIDTH,
+                            FILE_BROWSER_HEIGHT));
+                    if (LAST_DIR != null) {
+                        fc.setCurrentDirectory(new File(LAST_DIR));
+                    } else {
+                        fc.setCurrentDirectory(new File(SextanteGUI
+                                .getOutputFolder()));
+                    }
+                    fc.setFileFilter(new GenericFileFilter(
+                            new String[] { "png" }, "png"));
+                    final int returnVal = fc.showSaveDialog(this);
+                    FILE_BROWSER_WIDTH = fc.getWidth();
+                    FILE_BROWSER_HEIGHT = fc.getHeight();
+                    if (returnVal == JFileChooser.APPROVE_OPTION) {
+                        // final File file = fc.getSelectedFile();
+                        final File file = new File(fc.getSelectedFile()
+                                + ".png");
+                        LAST_DIR = file.getParent();
+                        ChartUtilities.saveChartAsPNG(file, panel.getChart(),
+                                900, 525);
+                        // ChartUtilities.saveChartAsPNG(fc.getSelectedFile(),
+                        // panel.getChart(), 600, 350);
+                    }
+                }
+
+            } catch (final Exception e) {
+                Sextante.addErrorToLog(e);
+            }
+        }
+
+    }
+
+    protected void showComponent() {
+
+        if (m_Path != null) {
+            try {
+                final DefaultMutableTreeNode node = (DefaultMutableTreeNode) 
m_Path
+                        .getLastPathComponent();
+                final ObjectAndDescription oad = (ObjectAndDescription) node
+                        .getUserObject();
+                final Component c = (Component) oad.getObject();
+                c.setMinimumSize(new Dimension(300, 200));
+                jSplitPane.setRightComponent(c);
+            } catch (final Exception e) {
+                Sextante.addErrorToLog(e);
+            }
+
+        }
+
+    }
+
+    public void fillTree(final ArrayList<?> components) {
+
+        DefaultMutableTreeNode node;
+        final DefaultMutableTreeNode mainNode = new DefaultMutableTreeNode(
+                Sextante.getText("Processing"));
+        ;
+        final DefaultMutableTreeNode componentsNode = new 
DefaultMutableTreeNode(
+                Sextante.getText("Result"));
+
+        for (int i = 0; i < components.size(); i++) {
+            node = new DefaultMutableTreeNode(components.get(i));
+            componentsNode.add(node);
+        }
+
+        mainNode.add(componentsNode);
+
+        jTree.setModel(new DefaultTreeModel(mainNode));
+
+    }
+
+    public void update() {
+
+        if (!initGUI(AdditionalResults.getComponents())) {
+            dispose();
+            setVisible(false);
+        }
+
+    }
+
+    private DefaultMutableTreeNode findNode(final ObjectAndDescription oad) {
+
+        Object ob;
+        final DefaultTreeModel data = (DefaultTreeModel) jTree.getModel();
+        final DefaultMutableTreeNode root = (DefaultMutableTreeNode) data
+                .getRoot();
+        DefaultMutableTreeNode node = null;
+
+        if (root != null) {
+            for (final Enumeration<?> e = root.breadthFirstEnumeration(); e
+                    .hasMoreElements();) {
+                final DefaultMutableTreeNode current = 
(DefaultMutableTreeNode) e
+                        .nextElement();
+                ob = current.getUserObject();
+                if (ob instanceof ObjectAndDescription) {
+                    if (ob == oad) {
+                        node = current;
+                        break;
+                    }
+                }
+            }
+        }
+
+        return node;
+
+    }
+
+}


Property changes on: 
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/additionalResults/AdditionalResultsDialog.java
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+text/plain
\ No newline at end of property
Added: 
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/additionalResults/AdditionalResultsTreeCellRenderer.java
===================================================================
--- 
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/additionalResults/AdditionalResultsTreeCellRenderer.java
                          (rev 0)
+++ 
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/additionalResults/AdditionalResultsTreeCellRenderer.java
  2016-11-19 10:44:08 UTC (rev 5196)
@@ -0,0 +1,43 @@
+package es.unex.sextante.gui.additionalResults;
+
+import java.awt.Color;
+import java.awt.Component;
+
+import javax.swing.JLabel;
+import javax.swing.JTree;
+import javax.swing.tree.TreeCellRenderer;
+
+public class AdditionalResultsTreeCellRenderer extends JLabel implements
+        TreeCellRenderer {
+
+    /**
+     * 
+     */
+    private static final long serialVersionUID = 1L;
+
+    public Component getTreeCellRendererComponent(final JTree tree,
+            final Object value, final boolean sel, final boolean expanded,
+            boolean leaf, final int row, final boolean hasFocus) {
+
+        final String sName = tree.convertValueToText(value, sel, expanded,
+                leaf, row, hasFocus);
+
+        // setFont(tree.getFont());
+        setEnabled(tree.isEnabled());
+        setText(sName);
+
+        if (!leaf) {
+            // setFont(new java.awt.Font("Tahoma", 1, 11));
+            setForeground(Color.black);
+        } else {
+            if (sel) {
+                setForeground(Color.blue);
+            } else {
+                setForeground(Color.black);
+            }
+        }
+        return this;
+
+    }
+
+}


Property changes on: 
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/additionalResults/AdditionalResultsTreeCellRenderer.java
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+text/plain
\ No newline at end of property
Added: 
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/additionalResults/TableTools.java
===================================================================
--- 
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/additionalResults/TableTools.java
                         (rev 0)
+++ 
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/additionalResults/TableTools.java
 2016-11-19 10:44:08 UTC (rev 5196)
@@ -0,0 +1,102 @@
+package es.unex.sextante.gui.additionalResults;
+
+import javax.swing.JScrollPane;
+import javax.swing.JTable;
+import javax.swing.table.DefaultTableModel;
+import javax.swing.table.TableModel;
+
+import es.unex.sextante.dataObjects.IDataObject;
+import es.unex.sextante.dataObjects.IFeature;
+import es.unex.sextante.dataObjects.IFeatureIterator;
+import es.unex.sextante.dataObjects.IRecord;
+import es.unex.sextante.dataObjects.IRecordsetIterator;
+import es.unex.sextante.dataObjects.ITable;
+import es.unex.sextante.dataObjects.IVectorLayer;
+import es.unex.sextante.exceptions.IteratorException;
+
+public class TableTools {
+
+   public static JScrollPane getScrollableTablePanelFromITable(final 
IDataObject obj) {
+
+      final JScrollPane jScrollPane = new JScrollPane();
+
+      final JTable jTable = new JTable();
+      jScrollPane.setViewportView(jTable);
+      final TableModel model = getTableModel(obj);
+      if (model != null) {
+         jTable.setModel(model);
+      }
+      jTable.setEnabled(false);
+
+      return jScrollPane;
+
+
+   }
+
+
+   private static TableModel getTableModel(final IDataObject obj) {
+
+      final DefaultTableModel model = new DefaultTableModel();
+
+      String[] fields;
+      int iCount;
+
+
+      if (obj instanceof ITable) {
+         iCount = (int) ((ITable) obj).getRecordCount();
+         fields = ((ITable) obj).getFieldNames();
+
+      }
+      else if (obj instanceof IVectorLayer) {
+         iCount = ((IVectorLayer) obj).getShapesCount();
+         fields = ((IVectorLayer) obj).getFieldNames();
+      }
+      else {
+         return null;
+      }
+
+      final String[][] data = new String[iCount][fields.length];
+
+      if (obj instanceof ITable) {
+         final IRecordsetIterator iter = ((ITable) obj).iterator();
+         int i = 0;
+         while (iter.hasNext()) {
+            IRecord record;
+            try {
+               record = iter.next();
+               for (int j = 0; j < fields.length; j++) {
+                  data[i][j] = record.getValue(j).toString();
+               }
+               i++;
+            }
+            catch (final IteratorException e) {
+               e.printStackTrace();
+            }
+         }
+      }
+      else {
+         final IFeatureIterator iter = ((IVectorLayer) obj).iterator();
+         int i = 0;
+         while (iter.hasNext()) {
+            IFeature feature;
+            try {
+               feature = iter.next();
+               for (int j = 0; j < fields.length; j++) {
+                  data[i][j] = feature.getRecord().getValue(j).toString();
+               }
+               i++;
+            }
+            catch (final IteratorException e) {
+               e.printStackTrace();
+            }
+         }
+      }
+
+      model.setDataVector(data, fields);
+
+      return model;
+
+   }
+
+
+}


Property changes on: 
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/additionalResults/TableTools.java
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+text/plain
\ No newline at end of property
Added: 
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/AlgorithmDialog.java
===================================================================
--- 
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/AlgorithmDialog.java
                            (rev 0)
+++ 
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/AlgorithmDialog.java
    2016-11-19 10:44:08 UTC (rev 5196)
@@ -0,0 +1,683 @@
+package es.unex.sextante.gui.algorithm;
+
+import info.clearthought.layout.TableLayout;
+import info.clearthought.layout.TableLayoutConstants;
+
+import java.awt.Font;
+import java.awt.Toolkit;
+import java.awt.datatransfer.Clipboard;
+import java.awt.datatransfer.DataFlavor;
+import java.awt.datatransfer.StringSelection;
+import java.awt.datatransfer.Transferable;
+import java.awt.datatransfer.UnsupportedFlavorException;
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+import java.io.IOException;
+import java.util.ArrayList;
+
+import javax.swing.ImageIcon;
+import javax.swing.JButton;
+import javax.swing.JDialog;
+import javax.swing.JOptionPane;
+import javax.swing.JPanel;
+import javax.swing.JTabbedPane;
+import javax.swing.JTextField;
+
+import es.unex.sextante.core.AnalysisExtent;
+import es.unex.sextante.core.GeoAlgorithm;
+import es.unex.sextante.core.OutputObjectsSet;
+import es.unex.sextante.core.ParametersSet;
+import es.unex.sextante.core.Sextante;
+import es.unex.sextante.exceptions.WrongAnalysisExtentException;
+import es.unex.sextante.exceptions.WrongInputException;
+import es.unex.sextante.gui.core.IGUIFactory;
+import es.unex.sextante.gui.core.SextanteGUI;
+import es.unex.sextante.gui.exceptions.LayerCannotBeOverwrittenException;
+import es.unex.sextante.gui.exceptions.OverwrittingNotAllowedException;
+import es.unex.sextante.gui.exceptions.TooLargeGridExtentException;
+import es.unex.sextante.gui.history.DateAndCommand;
+import es.unex.sextante.gui.history.History;
+import es.unex.sextante.outputs.Output;
+import es.unex.sextante.outputs.Output3DRasterLayer;
+import es.unex.sextante.outputs.OutputRasterLayer;
+import es.unex.sextante.outputs.OutputTable;
+import es.unex.sextante.outputs.OutputVectorLayer;
+import es.unex.sextante.parameters.Parameter;
+
+/**
+ * A dialog used to introduce all the necessary input for a geoalgorithm (input
+ * parameters and raster extent if needed. see
+ * {@link es.unex.sextante.core.GeoAlgorithm#getUserCanDefineAnalysisExtent()})
+ * for a given algorithm
+ * 
+ * @author volaya
+ * 
+ */
+public class AlgorithmDialog extends JDialog {
+
+    private static final long serialVersionUID = 1L;
+
+    protected GeoAlgorithm m_Algorithm;
+    protected JTabbedPane jTabbedPane1;
+    private JPanel jPanelButtons;
+    private JPanel jMainPanel;
+    protected JButton jButtonCancel;
+    protected JButton jButtonOK;
+
+    private int m_iDialogReturn;
+
+    protected GeoAlgorithmParametersPanel jPanelParametersMain = null;
+    private AnalysisExtentPanel jAnalysisExtentPanel;
+    private JButton jButtonHelp;
+    private JButton jButtonCopy;
+    private JButton jButtonPaste;
+    private String[] m_PreviousParameters;
+    private String[] m_Extents;
+    private JTextField jLabelCommand;
+    private JButton jButtonPrevious;
+    private JButton jButtonNext;
+    private int m_iPreviousCommandIndex;
+    private final ArrayList<DateAndCommand> m_sCommand;
+
+    /**
+     * Creates a new dialog for a given algorithm.
+     * 
+     * @param algorithm
+     *            the algorithm
+     * @param parent
+     *            the parent dialog
+     * @param panel
+     *            the parameters panel to use. Doesn't have to be initialized
+     *            using its init(Geoalgorithm) method. This constructor will
+     *            initialize it
+     * @param commands
+     *            a list of DateAndCommand objects to use as previous 
parameters
+     *            set. Must include both the "runalg" commands and the "extent"
+     *            ones, in case you want them to be used for algorithms
+     *            generating new raster layers. If null, all suitable commands
+     *            from history are used
+     */
+    public AlgorithmDialog(final GeoAlgorithm algorithm, final JDialog parent,
+            final GeoAlgorithmParametersPanel panel,
+            final ArrayList<DateAndCommand> commands) {
+
+        super(parent, algorithm.getName(), true);
+
+        m_Algorithm = algorithm;
+        m_sCommand = commands;
+
+        jPanelParametersMain = panel;
+        jPanelParametersMain.init(m_Algorithm);
+
+        initGUI();
+        this.setLocationRelativeTo(null);
+
+    }
+
+    /**
+     * Creates a new dialog for a given algorithm. The main frame of the UI is
+     * used as the parent component
+     * 
+     * @param algorithm
+     *            the algorithm
+     * @param panel
+     *            the parameters panel to use. Doesn't have to be initialized
+     *            using its init(Geoalgorithm) method. This constructor will
+     *            initialize it
+     * @param comands
+     *            a list of DateAndCommand objects to use as previous 
parameters
+     *            set. Must include both the "runalg" commands and the "extent"
+     *            ones, in case you want them to be used for algorithms
+     *            generating new raster layers. If null, all suitable commands
+     *            from history are used
+     */
+    public AlgorithmDialog(final GeoAlgorithm algorithm,
+            final GeoAlgorithmParametersPanel panel,
+            final ArrayList<DateAndCommand> commands) {
+
+        super(SextanteGUI.getMainFrame(), algorithm.getName(), true);
+
+        m_sCommand = commands;
+        m_Algorithm = algorithm;
+
+        jPanelParametersMain = panel;
+        jPanelParametersMain.init(m_Algorithm);
+
+        initGUI();
+        this.setLocationRelativeTo(null);
+
+    }
+
+    private void initGUI() {
+
+        this.setResizable(false);
+
+        jMainPanel = new JPanel();
+
+        this.add(jMainPanel);
+
+        final TableLayout thisLayout = new TableLayout(
+                new double[][] { { 10.0, TableLayoutConstants.FILL, 10. },
+                        { 1.0, 338.0, 37.0 } });
+        jMainPanel.setLayout(thisLayout);
+        this.setSize(696, 446);
+        {
+            jTabbedPane1 = new JTabbedPane();
+            jMainPanel.add(jTabbedPane1, "1, 1");
+            {
+                jTabbedPane1.addTab(Sextante.getText("Parameters"), null,
+                        jPanelParametersMain, null);
+            }
+            {
+                if (m_Algorithm.getUserCanDefineAnalysisExtent()) {
+                    jTabbedPane1.addTab(Sextante.getText("Raster_output"),
+                            null, getAnalysisExtentPanel(), null);
+                }
+            }
+        }
+        {
+            jPanelButtons = new JPanel();
+            final TableLayout jPanelButtonsLayout = new TableLayout(
+                    new double[][] {
+                            { 0.0, 45.0, 120.0, 120.0, 45.0, 25.0, 25.0,
+                                    TableLayoutConstants.FILL, 90.0, 90.0, 
25.0 },
+                            { TableLayoutConstants.FILL, 25.0,
+                                    TableLayoutConstants.FILL } });
+            jPanelButtonsLayout.setHGap(5);
+            jPanelButtonsLayout.setVGap(5);
+            jPanelButtons.setLayout(jPanelButtonsLayout);
+            jMainPanel.add(jPanelButtons, "1, 2");
+            jPanelButtons.setFocusable(false);
+            {
+                jButtonOK = new JButton();
+                jPanelButtons.add(jButtonOK, "8, 1");
+                jButtonOK.setText(Sextante.getText("OK"));
+                jButtonOK
+                        .addActionListener(new java.awt.event.ActionListener() 
{
+                            public void actionPerformed(
+                                    final java.awt.event.ActionEvent e) {
+                                executeAlgorithm();
+                            }
+                        });
+            }
+            {
+                jButtonCancel = new JButton();
+                jPanelButtons.add(jButtonCancel, "9, 1");
+                jButtonCancel.setText(Sextante.getText("Cancel"));
+                jButtonCancel
+                        .addActionListener(new java.awt.event.ActionListener() 
{
+                            public void actionPerformed(
+                                    final java.awt.event.ActionEvent e) {
+                                m_iDialogReturn = IGUIFactory.CANCEL;
+                                dispose();
+                                setVisible(false);
+                            }
+                        });
+            }
+            {
+                jButtonHelp = new JButton();
+                jPanelButtons.add(jButtonHelp, "10, 1");
+                jButtonHelp.setIcon(new ImageIcon(getClass().getClassLoader()
+                        .getResource("images/info.gif")));
+                jButtonHelp.setToolTipText(Sextante
+                        .getText("sextante_gui_algorithm_tooltip_help"));
+                jButtonHelp.setPreferredSize(new java.awt.Dimension(33, 0));
+                jButtonHelp.addActionListener(new ActionListener() {
+                    public void actionPerformed(final ActionEvent evt) {
+                        showHelp();
+                    }
+                });
+            }
+        }
+
+        retrievePreviouslyUsedParametersFromHistory();
+        if (m_PreviousParameters != null) {
+            try {
+                {
+                    jButtonPrevious = new JButton();
+                    jPanelButtons.add(jButtonPrevious, "1, 1");
+                    jButtonPrevious.setText("<");
+                    jButtonPrevious
+                            .setToolTipText(Sextante
+                                    
.getText("sextante_gui_algorithm_tooltip_previous"));
+                    jButtonPrevious.addActionListener(new ActionListener() {
+                        public void actionPerformed(final ActionEvent evt) {
+                            setPreviousSetOfPreviouslyUsedCommand();
+                        }
+                    });
+                }
+                {
+                    jButtonNext = new JButton();
+                    jPanelButtons.add(jButtonNext, "4, 1");
+                    jButtonNext.setText(">");
+                    jButtonNext.setToolTipText(Sextante
+                            .getText("sextante_gui_algorithm_tooltip_next"));
+                    jButtonNext.addActionListener(new ActionListener() {
+                        public void actionPerformed(final ActionEvent evt) {
+                            setNextSetOfPreviouslyUsedCommand();
+                        }
+                    });
+                }
+                {
+                    jLabelCommand = new JTextField();
+                    jLabelCommand
+                            .setFont(new Font("Monospaced", Font.PLAIN, 10));
+                    jLabelCommand.setEditable(false);
+                    jPanelButtons.add(jLabelCommand, "2, 1, 3, 1");
+                }
+                {
+                    jButtonCopy = new JButton();
+                    jPanelButtons.add(jButtonCopy, "5, 1");
+                    jButtonCopy.setIcon(new ImageIcon(getClass()
+                            .getClassLoader().getResource("images/copy.png")));
+                    jButtonCopy.setToolTipText(Sextante
+                            .getText("sextante_gui_algorithm_tooltip_copy"));
+                    jButtonCopy.setPreferredSize(new java.awt.Dimension(33, 
0));
+                    jButtonCopy.addActionListener(new ActionListener() {
+                        public void actionPerformed(final ActionEvent evt) {
+                            try {
+                                assignParameters();
+                            } catch (WrongAnalysisExtentException
+                                    | WrongInputException
+                                    | OverwrittingNotAllowedException
+                                    | LayerCannotBeOverwrittenException
+                                    | TooLargeGridExtentException e) {
+                                // Do nothing
+                            }
+                            final String[] cmd = m_Algorithm
+                                    .getAlgorithmAsCommandLineSentences();
+                            String content = new String("");
+                            for (int i = 0; i < cmd.length; i++) {
+                                content += cmd[i];
+                                if (i < cmd.length - 1) {
+                                    content += "\n";
+                                }
+                            }
+                            StringSelection selection = new StringSelection(
+                                    content);
+                            Clipboard clipboard = Toolkit.getDefaultToolkit()
+                                    .getSystemClipboard();
+                            clipboard.setContents(selection, selection);
+                        }
+                    });
+                }
+                {
+                    jButtonPaste = new JButton();
+                    jPanelButtons.add(jButtonPaste, "6, 1");
+                    jButtonPaste.setIcon(new ImageIcon(getClass()
+                            
.getClassLoader().getResource("images/paste.png")));
+                    jButtonPaste.setToolTipText(Sextante
+                            .getText("sextante_gui_algorithm_tooltip_paste"));
+                    jButtonPaste
+                            .setPreferredSize(new java.awt.Dimension(33, 0));
+                    jButtonPaste.addActionListener(new ActionListener() {
+                        public void actionPerformed(final ActionEvent evt) {
+                            Clipboard clipboard = Toolkit.getDefaultToolkit()
+                                    .getSystemClipboard();
+                            Transferable t = clipboard.getContents(null);
+                            if 
(t.isDataFlavorSupported(DataFlavor.stringFlavor)) {
+                                try {
+                                    String data = (String) t
+                                            
.getTransferData(DataFlavor.stringFlavor);
+                                    String[] lines = data.split("\n");
+                                    for (int i = 0; i < lines.length; i++) {
+                                        String current = lines[i].trim();
+                                        if (current.startsWith("runalg(\""
+                                                + m_Algorithm
+                                                        .getCommandLineName()
+                                                + "\"")) {
+                                            // Apply parameters
+                                            int j;
+                                            Parameter param;
+                                            String[] args;
+                                            String sArg;
+                                            args = current.split("\"");
+                                            for (int k = 0; k < 2; k++) { // 
twice
+                                                                          // to
+                                                                          // 
handle
+                                                                          // 
dependencies
+                                                final ParametersSet ps = 
m_Algorithm
+                                                        .getParameters();
+                                                for (j = 0; j < m_Algorithm
+                                                        
.getNumberOfParameters(); j++) {
+                                                    param = ps.getParameter(j);
+                                                    sArg = args[j * 2 + 3];
+                                                    
jPanelParametersMain.setParameterValue(
+                                                            
param.getParameterName(),
+                                                            sArg.trim());
+                                                }
+                                                int iOutputIndex = j * 2 + 3;
+                                                final OutputObjectsSet ooSet = 
m_Algorithm
+                                                        .getOutputObjects();
+                                                for (j = 0; j < ooSet
+                                                        
.getOutputObjectsCount(); j++) {
+                                                    final Output out = ooSet
+                                                            .getOutput(j);
+                                                    if ((out instanceof 
OutputRasterLayer)
+                                                            || (out instanceof 
Output3DRasterLayer)
+                                                            || (out instanceof 
OutputVectorLayer)
+                                                            || (out instanceof 
OutputTable)) {
+                                                        final String sValue = 
args[iOutputIndex]
+                                                                .trim();
+                                                        jPanelParametersMain
+                                                                
.setOutputValue(
+                                                                        
out.getName(),
+                                                                        
sValue);
+                                                        iOutputIndex += 2;
+                                                    }
+                                                }
+                                            }
+
+                                        }
+                                        if (current.startsWith("extent(")) {
+                                            // Apply Extent
+                                            String sExtent = current;
+                                            if (sExtent != null) {
+                                                sExtent = sExtent.substring(
+                                                        sExtent.indexOf("(") + 
1,
+                                                        sExtent.indexOf(")"));
+                                                final AnalysisExtent ae = new 
AnalysisExtent();
+                                                final String[] sCoords = 
sExtent
+                                                        .split(",");
+                                                double dCellSizeX = 1;
+                                                double dCellSizeY = 1;
+                                                double dCellSizeZ = 1;
+                                                if (sCoords.length == 8) {
+                                                    // Backward compatibility
+                                                    dCellSizeX = Double
+                                                            
.parseDouble(sCoords[6]);
+                                                    dCellSizeY = dCellSizeX;
+                                                    dCellSizeZ = Double
+                                                            
.parseDouble(sCoords[7]);
+                                                } else if (sCoords.length == 
9) {
+                                                    dCellSizeX = Double
+                                                            
.parseDouble(sCoords[6]);
+                                                    dCellSizeY = Double
+                                                            
.parseDouble(sCoords[7]);
+                                                    dCellSizeZ = Double
+                                                            
.parseDouble(sCoords[8]);
+                                                } else {
+                                                    // Wrong number of
+                                                    // parameters
+                                                    throw new IOException();
+                                                }
+                                                ae.setCellSizeX(dCellSizeX);
+                                                ae.setCellSizeY(dCellSizeY);
+                                                ae.setCellSizeZ(dCellSizeZ);
+                                                final double xMin = Double
+                                                        
.parseDouble(sCoords[0]);
+                                                final double xMax = Double
+                                                        
.parseDouble(sCoords[3]);
+                                                ae.setXRange(xMin, xMax, true);
+                                                final double yMin = Double
+                                                        
.parseDouble(sCoords[1]);
+                                                final double yMax = Double
+                                                        
.parseDouble(sCoords[4]);
+                                                ae.setYRange(yMin, yMax, true);
+                                                final double zMin = Double
+                                                        
.parseDouble(sCoords[2]);
+                                                final double zMax = Double
+                                                        
.parseDouble(sCoords[5]);
+                                                ae.setZRange(zMin, zMax, true);
+                                                getAnalysisExtentPanel()
+                                                        .setExtent(ae);
+                                            }
+                                        }
+                                    }
+                                } catch (UnsupportedFlavorException
+                                        | IOException e) {
+                                    Sextante.getLogger()
+                                            .addError(
+                                                    "Failed to apply region 
extent and resolution from system clipboard.");
+                                    e.printStackTrace();
+                                }
+                            }
+                        }
+                    });
+                }
+
+                m_iPreviousCommandIndex = m_PreviousParameters.length - 1;
+                setPreviouslyUsedParameters(m_iPreviousCommandIndex);
+            } catch (final Exception e) {
+                Sextante.getLogger().addError(
+                        "Failed to retrieve parameters from commmand 
history.");
+                e.printStackTrace();
+            }
+        }
+
+    }
+
+    private void setPreviouslyUsedParameters(final int iIndex) {
+
+        int i;
+        Parameter param;
+        String[] args;
+        String sArg;
+
+        jLabelCommand.setText("[" + Integer.toString(iIndex + 1) + "] "
+                + m_PreviousParameters[iIndex]);
+        args = m_PreviousParameters[iIndex].split("\"");
+
+        for (int j = 0; j < 2; j++) { // twice to handle dependencies
+            final ParametersSet ps = m_Algorithm.getParameters();
+            for (i = 0; i < m_Algorithm.getNumberOfParameters(); i++) {
+                param = ps.getParameter(i);
+                sArg = args[i * 2 + 3];
+                jPanelParametersMain.setParameterValue(
+                        param.getParameterName(), sArg.trim());
+            }
+            int iOutputIndex = i * 2 + 3;
+            final OutputObjectsSet ooSet = m_Algorithm.getOutputObjects();
+            for (i = 0; i < ooSet.getOutputObjectsCount(); i++) {
+                final Output out = ooSet.getOutput(i);
+                if ((out instanceof OutputRasterLayer)
+                        || (out instanceof Output3DRasterLayer)
+                        || (out instanceof OutputVectorLayer)
+                        || (out instanceof OutputTable)) {
+                    try {
+                        final String sValue = args[iOutputIndex].trim();
+                        jPanelParametersMain.setOutputValue(out.getName(),
+                                sValue);
+                        iOutputIndex += 2;
+                    } catch (java.lang.ArrayIndexOutOfBoundsException
+                            | java.lang.NullPointerException e) {
+                        Sextante.addErrorToLog("Failed to set previous 
parameters for '"
+                                + m_Algorithm.getName() + '.');
+                    }
+                }
+            }
+        }
+
+        if (m_Algorithm.getUserCanDefineAnalysisExtent()) {
+            String sExtent = m_Extents[iIndex];
+            if (sExtent != null) {
+                try {
+                    sExtent = sExtent.substring(sExtent.indexOf("(") + 1,
+                            sExtent.indexOf(")"));
+                    final AnalysisExtent ae = new AnalysisExtent();
+                    final String[] sCoords = sExtent.split(",");
+                    double dCellSizeX = 1;
+                    double dCellSizeY = 1;
+                    double dCellSizeZ = 1;
+                    if (sCoords.length == 8) {
+                        // Backward compatibility
+                        dCellSizeX = Double.parseDouble(sCoords[6]);
+                        dCellSizeY = dCellSizeX;
+                        dCellSizeZ = Double.parseDouble(sCoords[7]);
+                    } else if (sCoords.length == 9) {
+                        dCellSizeX = Double.parseDouble(sCoords[6]);
+                        dCellSizeY = Double.parseDouble(sCoords[7]);
+                        dCellSizeZ = Double.parseDouble(sCoords[8]);
+                    } else {
+                        // Wrong number of parameters
+                        throw new IOException();
+                    }
+                    ae.setCellSizeX(dCellSizeX);
+                    ae.setCellSizeY(dCellSizeY);
+                    ae.setCellSizeZ(dCellSizeZ);
+                    final double xMin = Double.parseDouble(sCoords[0]);
+                    final double xMax = Double.parseDouble(sCoords[3]);
+                    ae.setXRange(xMin, xMax, true);
+                    final double yMin = Double.parseDouble(sCoords[1]);
+                    final double yMax = Double.parseDouble(sCoords[4]);
+                    ae.setYRange(yMin, yMax, true);
+                    final double zMin = Double.parseDouble(sCoords[2]);
+                    final double zMax = Double.parseDouble(sCoords[5]);
+                    ae.setZRange(zMin, zMax, true);
+                    getAnalysisExtentPanel().setExtent(ae);
+                } catch (IOException e) {
+                    Sextante.getLogger().addError(
+                            "Failed to restore region extent and resolution.");
+                    e.printStackTrace();
+                }
+            } else {
+                getAnalysisExtentPanel().setAutoExtent();
+            }
+        }
+
+    }
+
+    private void retrievePreviouslyUsedParametersFromHistory() {
+
+        ArrayList<DateAndCommand> dac;
+        if (m_sCommand != null) {
+            dac = m_sCommand;
+        } else {
+            dac = History.getHistory();
+        }
+        final ArrayList<String> previousParameters = new ArrayList<String>();
+        final ArrayList<String> extents = new ArrayList<String>();
+        for (int i = 0; i < dac.size(); i++) {
+            String command = dac.get(i).getCommand();
+            if (command.startsWith("runalg(\""
+                    + m_Algorithm.getCommandLineName() + "\"")) {
+                previousParameters.add(command);
+                if (m_Algorithm.getUserCanDefineAnalysisExtent() && (i != 0)) {
+                    command = dac.get(i - 1).getCommand();
+                    if (command.startsWith("extent")) {
+                        extents.add(command);
+                    } else {
+                        extents.add(null);
+                    }
+                }
+            }
+        }
+
+        if (previousParameters.size() == 0) {
+            m_PreviousParameters = null;
+            m_Extents = null;
+        } else {
+            m_PreviousParameters = previousParameters.toArray(new String[0]);
+            m_Extents = extents.toArray(new String[0]);
+
+        }
+
+    }
+
+    public void setPreviousSetOfPreviouslyUsedCommand() {
+
+        if (m_iPreviousCommandIndex <= 0) {
+            // m_iPreviousCommandIndex = m_PreviousParameters.length - 1;
+        } else {
+            m_iPreviousCommandIndex--;
+            setPreviouslyUsedParameters(m_iPreviousCommandIndex);
+        }
+
+    }
+
+    public void setNextSetOfPreviouslyUsedCommand() {
+
+        if (m_iPreviousCommandIndex >= m_PreviousParameters.length - 1) {
+            // m_iPreviousCommandIndex = 0;
+        } else {
+            m_iPreviousCommandIndex++;
+            setPreviouslyUsedParameters(m_iPreviousCommandIndex);
+        }
+
+    }
+
+    protected void showHelp() {
+
+        SextanteGUI.getGUIFactory().showHelpDialog(m_Algorithm);
+
+    }
+
+    protected void executeAlgorithm() {
+
+        try {
+            try {
+                assignParameters();
+            } catch (final TooLargeGridExtentException e) {
+                final int iRet = JOptionPane.showConfirmDialog(null,
+                        e.getMessage(), Sextante.getText("Warning"),
+                        JOptionPane.YES_NO_OPTION);
+                if (iRet != JOptionPane.YES_OPTION) {
+                    this.jTabbedPane1.setSelectedIndex(1);
+                    return;
+                }
+            }
+
+            m_iDialogReturn = IGUIFactory.OK;
+
+            dispose();
+            setVisible(false);
+
+        } catch (final WrongInputException e) {
+            JOptionPane.showMessageDialog(null, e.getMessage(),
+                    Sextante.getText("Warning"), JOptionPane.WARNING_MESSAGE);
+            this.jTabbedPane1.setSelectedIndex(0);
+        } catch (final WrongAnalysisExtentException e) {
+            JOptionPane.showMessageDialog(null, e.getMessage(),
+                    Sextante.getText("Warning"), JOptionPane.WARNING_MESSAGE);
+            this.jTabbedPane1.setSelectedIndex(1);
+        } catch (final OverwrittingNotAllowedException e) {
+            JOptionPane.showMessageDialog(null, e.getMessage(),
+                    Sextante.getText("Warning"), JOptionPane.WARNING_MESSAGE);
+            this.jTabbedPane1.setSelectedIndex(0);
+        } catch (final LayerCannotBeOverwrittenException e) {
+            JOptionPane.showMessageDialog(null, e.getMessage(),
+                    Sextante.getText("Warning"), JOptionPane.WARNING_MESSAGE);
+            this.jTabbedPane1.setSelectedIndex(0);
+        }
+
+    }
+
+    protected void assignParameters() throws WrongInputException,
+            OverwrittingNotAllowedException, LayerCannotBeOverwrittenException,
+            WrongAnalysisExtentException, TooLargeGridExtentException {
+
+        jPanelParametersMain.assignParameters();
+        if (m_Algorithm.getUserCanDefineAnalysisExtent()) {
+            getAnalysisExtentPanel().assignExtent();
+        }
+
+    }
+
+    private AnalysisExtentPanel getAnalysisExtentPanel() {
+
+        if (jAnalysisExtentPanel == null) {
+            if (m_Algorithm.is3D()) {
+                jAnalysisExtentPanel = new TridimensionalAnalysisExtentPanel(
+                        m_Algorithm);
+            } else {
+                jAnalysisExtentPanel = new AnalysisExtentPanel(m_Algorithm);
+            }
+        }
+        return jAnalysisExtentPanel;
+
+    }
+
+    /**
+     * Returns {@link es.unex.sextante.gui.core.IGUIFactory#OK} if the user
+     * selected "OK" and the algorithm should be executed
+     * 
+     * @return IGUIFactory.OK if the user selected "OK" and the algorithm 
should
+     *         be executed
+     */
+    public int getDialogReturn() {
+
+        return m_iDialogReturn;
+
+    }
+
+}


Property changes on: 
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/AlgorithmDialog.java
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+text/plain
\ No newline at end of property
Added: 
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/AnalysisExtentPanel.java
===================================================================
--- 
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/AnalysisExtentPanel.java
                                (rev 0)
+++ 
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/AnalysisExtentPanel.java
        2016-11-19 10:44:08 UTC (rev 5196)
@@ -0,0 +1,811 @@
+
+
+package es.unex.sextante.gui.algorithm;
+
+import info.clearthought.layout.TableLayout;
+import info.clearthought.layout.TableLayoutConstants;
+
+import java.awt.Dimension;
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+import java.awt.event.FocusAdapter;
+import java.awt.event.FocusEvent;
+import java.awt.event.KeyAdapter;
+import java.awt.event.KeyEvent;
+import java.awt.geom.Rectangle2D;
+import java.text.DecimalFormat;
+
+import javax.swing.BorderFactory;
+import javax.swing.ButtonGroup;
+import javax.swing.ComboBoxModel;
+import javax.swing.DefaultComboBoxModel;
+import javax.swing.JButton;
+import javax.swing.JComboBox;
+import javax.swing.JLabel;
+import javax.swing.JPanel;
+import javax.swing.JRadioButton;
+import javax.swing.JTextField;
+
+import es.unex.sextante.core.AnalysisExtent;
+import es.unex.sextante.core.GeoAlgorithm;
+import es.unex.sextante.core.NamedExtent;
+import es.unex.sextante.core.Sextante;
+import es.unex.sextante.dataObjects.ILayer;
+import es.unex.sextante.dataObjects.IRasterLayer;
+import es.unex.sextante.exceptions.WrongAnalysisExtentException;
+import es.unex.sextante.gui.core.SextanteGUI;
+import es.unex.sextante.gui.core.TextFieldServices;
+import es.unex.sextante.gui.exceptions.TooLargeGridExtentException;
+import es.unex.sextante.gui.grass.GrassAlgorithm;
+import es.unex.sextante.outputs.Output;
+import es.unex.sextante.outputs.OutputRasterLayer;
+
+
+/**
+ * A panel to select a extent to be used for generating output layers from a 
given algorithm
+ * 
+ * @author volaya
+ * 
+ */
+public class AnalysisExtentPanel extends javax.swing.JPanel {
+
+       /**
+        * 
+        */
+       private static final long serialVersionUID = 1L;
+
+       protected static final int   BIG_SIZE = 10000000;
+
+       private final static String COORD_FORMAT = "#.############";
+
+       private JTextField           jTextFieldCols;
+       private JTextField           jTextFieldRows;
+       protected JTextField         jTextFieldCellSizeX;
+       protected JTextField         jTextFieldCellSizeY;
+       protected JTextField         jTextFieldXMin;
+       protected JTextField         jTextFieldXMax;
+       protected JTextField         jTextFieldYMin;
+       protected JTextField         jTextFieldYMax;    
+       private JLabel               jLabelExtentFromPoints;
+       private JLabel               jLabelRowsCols;
+       private JLabel               jLabelCellSizeXY;
+       private JLabel               jLabelRangeY;
+       private JLabel               jLabelRangeX;
+       protected JComboBox          jComboBoxLayers;
+       private JComboBox            jComboBoxViews;
+       protected JPanel             jPanelAnalysisExtentValues;
+       private JPanel               jPanelAnalysisExtentOptions;
+       private JRadioButton         jRadioButtonAdjustToInputDataExtent;
+       private JRadioButton         jRadioButtonViewExtent;
+       private JRadioButton         jRadioButtonUserDefinedExtent;
+       private JRadioButton         jRadioButtonExtentFromLayer;
+       private ButtonGroup          jButtonGroup;
+       private JButton                  jButtonExtentFromPoints;
+
+       protected final GeoAlgorithm m_Algorithm;
+       protected final ILayer[]     m_Layers;
+
+
+       /**
+        * Creates a new panel
+        * 
+        * @param algorithm
+        *                the algorithm
+        */
+       public AnalysisExtentPanel(final GeoAlgorithm algorithm) {
+
+               super();
+
+               m_Layers = SextanteGUI.getInputFactory().getLayers();
+               m_Algorithm = algorithm;
+
+               initGUI();
+
+       }
+
+
+       private void initGUI() {
+
+               final TableLayout jPanelParametersRasterLayout = new 
TableLayout(new double[][] 
+                               { { 1.0, TableLayoutConstants.FILL, 1.0 }, 
//Cols
+                       { 1.0, TableLayoutConstants.MINIMUM, 
TableLayoutConstants.FILL, 1.0 } }); //Rows
+               jPanelParametersRasterLayout.setHGap(5);
+               jPanelParametersRasterLayout.setVGap(5);
+               this.setLayout(jPanelParametersRasterLayout);
+
+               this.add(getJPanelAnalysisExtentOptions(), "1, 1");
+               this.add(getJPanelAnalysisExtentValues(), "1, 2");
+               if (m_Algorithm.canDefineOutputExtentFromInput()) {
+                       getJPanelAnalysisExtentValues().setVisible(false);
+               }
+               else {
+                       getJPanelAnalysisExtentValues().setVisible(true);
+               }
+
+       }
+
+
+       /**
+        * Assigns the selected extent to the algorithm
+        * 
+        * @throws TooLargeGridExtentException
+        *                 if the dimensions of the extent are too large (too 
many cells) and the user should be queried to make sure
+        *                 that the input values are correct
+        * @throws WrongAnalysisExtentException
+        *                 if the input values are not correct
+        */
+       public void assignExtent() throws TooLargeGridExtentException, 
WrongAnalysisExtentException {
+
+               m_Algorithm.setAnalysisExtent((AnalysisExtent) null);
+
+               if (getJRadioButtonAdjustToInputDataExtent().isSelected()) {
+                       if (!m_Algorithm.adjustOutputExtent()) {
+                               throw new 
WrongAnalysisExtentException(Sextante.getText("Wrong_or_missing_region"));
+                       }
+                       else {
+                               return;
+                       }
+
+               }
+
+               final AnalysisExtent outputExtent = new AnalysisExtent();
+               try {
+                       
outputExtent.setCellSizeX(Double.parseDouble(jTextFieldCellSizeX.getText()));
+                       
outputExtent.setCellSizeY(Double.parseDouble(jTextFieldCellSizeY.getText()));
+                       
outputExtent.setXRange(Double.parseDouble(jTextFieldXMin.getText()), 
+                                       
Double.parseDouble(jTextFieldXMax.getText()), true);
+                       
outputExtent.setYRange(Double.parseDouble(jTextFieldYMin.getText()), 
+                                       
Double.parseDouble(jTextFieldYMax.getText()), true);
+                       m_Algorithm.setAnalysisExtent(outputExtent);
+               }
+               catch (final NumberFormatException e) {
+                       //Sextante.addErrorToLog(e);
+                       if (m_Algorithm instanceof GrassAlgorithm) {
+                               //GRASS vector output modules can always fall 
back to a default extent
+                               outputExtent.setXRange(0.0, 1.0, true);
+                               outputExtent.setYRange(0.0, 1.0, true);
+                               m_Algorithm.setAnalysisExtent(outputExtent);
+                               if 
(m_Algorithm.getName().contains("v.in.region")) {
+                                       //we absolutely need a region for these 
commands!
+                                       throw new 
WrongAnalysisExtentException(Sextante.getText("Wrong_or_missing_region"));
+                               }
+                               for (int i = 0; i < 
m_Algorithm.getNumberOfOutputObjects(); i++) {
+                                       final Output out = 
m_Algorithm.getOutputObjects().getOutput(i);
+                                       //Raster import modules also do not 
need an extent setting
+                                       if ((out instanceof OutputRasterLayer) 
&& !m_Algorithm.getName().contains("r.in.")) {
+                                               //But if we have another raster 
output, then we need an extent!
+                                               throw new 
WrongAnalysisExtentException(Sextante.getText("Wrong_or_missing_region"));
+                                       }
+                               }
+                       }
+                       else {
+                               throw new 
WrongAnalysisExtentException(Sextante.getText("Wrong_or_missing_raster_extent_definition"));
+                       }
+               }
+
+               /* benducke: let's just assume the user knows what (s)he is 
doing...
+               final int numCells = outputExtent.getNX() * 
outputExtent.getNY();               
+       if ((numCells > BIG_SIZE) || (Integer.MAX_VALUE / outputExtent.getNY() 
< outputExtent.getNX())) {
+               throw new 
TooLargeGridExtentException(Sextante.getText("The_selected_grid_extent_seems_too_large")
 + "("
+                                               + 
Integer.toString(outputExtent.getNX()) + " X "
+                                               + 
Integer.toString(outputExtent.getNY()) + ")\n"
+                                               + 
Sextante.getText("Are_you_sure_you_want_to_use_it?"));
+       }
+                */
+       }
+
+
+       private ButtonGroup getJButtonGroup() {
+
+               if (jButtonGroup == null) {
+                       jButtonGroup = new ButtonGroup();
+               }
+               return jButtonGroup;
+
+       }
+
+
+       protected JRadioButton getJRadioButtonUserDefinedExtent() {
+
+               if (jRadioButtonUserDefinedExtent == null) {
+                       jRadioButtonUserDefinedExtent = new JRadioButton();
+                       
jRadioButtonUserDefinedExtent.setText(Sextante.getText("User_defined"));
+                       jRadioButtonUserDefinedExtent.addActionListener(new 
java.awt.event.ActionListener() {
+                               public void actionPerformed(final 
java.awt.event.ActionEvent e) {
+                                       setTextFieldsEnabled(true);
+                                       extentHasChanged();
+                               }
+                       });
+               }
+
+
+               return jRadioButtonUserDefinedExtent;
+       }
+
+
+       protected JRadioButton getJRadioButtonAdjustToInputDataExtent() {
+
+               if (jRadioButtonAdjustToInputDataExtent == null) {
+                       jRadioButtonAdjustToInputDataExtent = new 
JRadioButton();
+                       
jRadioButtonAdjustToInputDataExtent.setText(Sextante.getText("Fit_to_input_layers"));
+                       
jRadioButtonAdjustToInputDataExtent.addActionListener(new 
java.awt.event.ActionListener() {
+                               public void actionPerformed(final 
java.awt.event.ActionEvent e) {
+                                       
getJPanelAnalysisExtentValues().setVisible(false);
+                               }
+                       });
+               }
+
+
+               return jRadioButtonAdjustToInputDataExtent;
+       }
+
+
+       private JRadioButton getJRadioButtonViewExtent() {
+               if (jRadioButtonViewExtent == null) {
+                       jRadioButtonViewExtent = new JRadioButton();
+                       
jRadioButtonViewExtent.setText(Sextante.getText("Use_extent_from_view"));
+                       jRadioButtonViewExtent.addActionListener(new 
java.awt.event.ActionListener() {
+                               public void actionPerformed(final 
java.awt.event.ActionEvent evt) {
+                                       try {
+                                               
getJComboBoxViews().setSelectedIndex(getJComboBoxViews().getSelectedIndex());
+                                               setTextFieldsEnabled(false);
+                                       }
+                                       catch (final Exception e) {
+                                       }
+                               }
+                       });
+               }
+               return jRadioButtonViewExtent;
+       }
+
+
+       JRadioButton getJRadioButtonExtentFromLayer() {
+               if (jRadioButtonExtentFromLayer == null) {
+                       jRadioButtonExtentFromLayer = new JRadioButton();
+                       
jRadioButtonExtentFromLayer.setText(Sextante.getText("Use_extent_from_layer"));
+                       jRadioButtonExtentFromLayer.addActionListener(new 
java.awt.event.ActionListener() {
+                               public void actionPerformed(final 
java.awt.event.ActionEvent e) {
+                                       
getJComboBoxLayers().setSelectedIndex(getJComboBoxLayers().getSelectedIndex());
+                                       setTextFieldsEnabled(false);
+                               }
+                       });
+               }
+               return jRadioButtonExtentFromLayer;
+       }
+
+
+       protected JPanel getJPanelAnalysisExtentOptions() {
+               if (jPanelAnalysisExtentOptions == null) {
+                       jPanelAnalysisExtentOptions = new JPanel();
+                       final TableLayout jPanelRasterExtentOptionsLayout = new 
TableLayout(new double[][] {
+                               { 253.0, TableLayoutConstants.FILL },
+                               { TableLayoutConstants.MINIMUM, 
TableLayoutConstants.MINIMUM, TableLayoutConstants.MINIMUM,
+                                       TableLayoutConstants.MINIMUM } });
+                       jPanelRasterExtentOptionsLayout.setHGap(5);
+                       jPanelRasterExtentOptionsLayout.setVGap(5);
+                       
jPanelAnalysisExtentOptions.setLayout(jPanelRasterExtentOptionsLayout);
+                       jPanelAnalysisExtentOptions.setPreferredSize(new 
java.awt.Dimension(660, 200));
+                       
jPanelAnalysisExtentOptions.setBorder(BorderFactory.createTitledBorder(Sextante.getText("Extent_from")));
+                       
jPanelAnalysisExtentOptions.add(getJRadioButtonUserDefinedExtent(), "0, 1");
+                       
jPanelAnalysisExtentOptions.add(getJRadioButtonViewExtent(), "0, 2");
+                       
jPanelAnalysisExtentOptions.add(getJRadioButtonExtentFromLayer(), "0, 3");
+                       
getJButtonGroup().add(getJRadioButtonUserDefinedExtent());
+                       getJButtonGroup().add(getJRadioButtonViewExtent());
+                       getJButtonGroup().add(getJRadioButtonExtentFromLayer());
+                       if (m_Algorithm.canDefineOutputExtentFromInput()) {
+                               
jPanelAnalysisExtentOptions.add(getJRadioButtonAdjustToInputDataExtent(), "0, 
0");
+                               
getJButtonGroup().add(getJRadioButtonAdjustToInputDataExtent());
+                               
getJRadioButtonAdjustToInputDataExtent().setSelected(true);
+                       }
+                       else {
+                               
getJRadioButtonUserDefinedExtent().setSelected(true);
+                       }
+                       jPanelAnalysisExtentOptions.add(getJComboBoxViews(), 
"1, 2");
+                       jPanelAnalysisExtentOptions.add(getJComboBoxLayers(), 
"1, 3");
+
+               }
+               return jPanelAnalysisExtentOptions;
+       }
+
+
+       protected JPanel getJPanelAnalysisExtentValues() {
+
+               if (jPanelAnalysisExtentValues == null) {
+                       jPanelAnalysisExtentValues = new JPanel();
+                       final TableLayout jPanelRasterExtentValuesLayout = new 
TableLayout(new double[][] {
+                               { 255.0, TableLayoutConstants.FILL, 
TableLayoutConstants.FILL }, //Cols
+                               {       //Rows
+                                       TableLayoutConstants.MINIMUM, //0: X 
range 
+                                       TableLayoutConstants.MINIMUM, //1: Y 
range
+                                       TableLayoutConstants.MINIMUM, //2: Cell 
size
+                                       TableLayoutConstants.MINIMUM, //3: Cell 
size picker
+                                       TableLayoutConstants.MINIMUM, //4: 
Cols/rows count
+                                       TableLayoutConstants.FILL } });
+                       jPanelRasterExtentValuesLayout.setHGap(5);
+                       jPanelRasterExtentValuesLayout.setVGap(5);
+                       
jPanelAnalysisExtentValues.setLayout(jPanelRasterExtentValuesLayout);
+                       
jPanelAnalysisExtentValues.setBorder(BorderFactory.createTitledBorder(Sextante.getText("Extent__values")));
+                       jPanelAnalysisExtentValues.setPreferredSize(new 
java.awt.Dimension(660, 145));
+                       jPanelAnalysisExtentValues.add(getJLabelRangeX(),       
        "0, 0");
+                       jPanelAnalysisExtentValues.add(getJTextFieldXMin(),     
"1, 0");
+                       jPanelAnalysisExtentValues.add(getJTextFieldXMax(),     
"2, 0");
+                       jPanelAnalysisExtentValues.add(getJLabelRangeY(),       
        "0, 1");
+                       jPanelAnalysisExtentValues.add(getJTextFieldYMin(),     
"1, 1");
+                       jPanelAnalysisExtentValues.add(getJTextFieldYMax(),     
"2, 1");
+                       
jPanelAnalysisExtentValues.add(getJLabelExtentFromPoints(), "0, 2");
+                       
jPanelAnalysisExtentValues.add(getJButtonExtentFromPoints(), "1, 2");
+                       jPanelAnalysisExtentValues.add(getJLabelCellSizeXY(),   
"0, 3");
+                       
jPanelAnalysisExtentValues.add(getJTextFieldCellSizeX(),"1, 3");                
                                                        
+                       
jPanelAnalysisExtentValues.add(getJTextFieldCellSizeY(),"2, 3");                
        
+                       jPanelAnalysisExtentValues.add(getJLabelRowsCols(),     
"0, 4");
+                       jPanelAnalysisExtentValues.add(getJTextFieldCols(),     
"1, 4");
+                       jPanelAnalysisExtentValues.add(getJTextFieldRows(),     
"2, 4");
+               }
+               return jPanelAnalysisExtentValues;
+       }
+
+
+       protected JButton getJButtonExtentFromPoints() {
+               if ( jButtonExtentFromPoints == null ) {
+                       jButtonExtentFromPoints = new JButton("...");
+                       jButtonExtentFromPoints.setSize(new Dimension(30, 30));
+                       jButtonExtentFromPoints.addActionListener(new 
ActionListener() {
+                               public void actionPerformed(final ActionEvent 
arg0) {
+                                       final ExtentFromSavedPointsDialog 
dialog = new ExtentFromSavedPointsDialog();
+                                       dialog.pack();
+                                       dialog.setVisible(true);
+                                       final double[] ret = dialog.getPoints();
+                                       if (ret != null) {      
+                                               getJTextFieldXMin().setText(new 
DecimalFormat(COORD_FORMAT).format(ret[0]));                    
+                                               getJTextFieldYMin().setText(new 
DecimalFormat(COORD_FORMAT).format(ret[1]));
+                                               getJTextFieldXMax().setText(new 
DecimalFormat(COORD_FORMAT).format(ret[2]));
+                                               getJTextFieldYMax().setText(new 
DecimalFormat(COORD_FORMAT).format(ret[3]));
+                                               extentHasChanged();
+                                       }
+                               }
+                       });
+               }
+               return jButtonExtentFromPoints;
+       }
+
+
+       protected JComboBox getJComboBoxLayers() {
+               if (jComboBoxLayers == null) {
+                       final ComboBoxModel jComboBoxLayersModel = new 
DefaultComboBoxModel(m_Layers);
+                       jComboBoxLayers = new JComboBox();
+                       jComboBoxLayers.setModel(jComboBoxLayersModel);
+                       jComboBoxLayers.addActionListener(new 
java.awt.event.ActionListener() {
+                               public void actionPerformed(final 
java.awt.event.ActionEvent evt) {
+                                       double dCoord;
+                                       
getJRadioButtonAdjustToInputDataExtent().setSelected(false);
+                                       
getJRadioButtonUserDefinedExtent().setSelected(false);
+                                       
getJRadioButtonViewExtent().setSelected(false);
+                                       
getJRadioButtonExtentFromLayer().setSelected(true);
+                                       try {
+                                               final ILayer layer = (ILayer) 
jComboBoxLayers.getSelectedItem();
+                                               dCoord = 
layer.getFullExtent().getMinX();                     
+                                               getJTextFieldXMin().setText(new 
DecimalFormat(COORD_FORMAT).format(dCoord));
+                                               dCoord = 
layer.getFullExtent().getMaxX();
+                                               getJTextFieldXMax().setText(new 
DecimalFormat(COORD_FORMAT).format(dCoord));
+                                               dCoord = 
layer.getFullExtent().getMinY();
+                                               getJTextFieldYMin().setText(new 
DecimalFormat(COORD_FORMAT).format(dCoord));
+                                               dCoord = 
layer.getFullExtent().getMaxY();
+                                               getJTextFieldYMax().setText(new 
DecimalFormat(COORD_FORMAT).format(dCoord));
+                                               if (layer instanceof 
IRasterLayer) {
+                                                       
getJTextFieldCellSizeX().setText(new Double(((IRasterLayer) layer).
+                                                                       
getLayerCellSizeX()).toString());
+                                                       
getJTextFieldCellSizeY().setText(new Double(((IRasterLayer) layer).
+                                                                       
getLayerCellSizeY()).toString());
+                                               }
+                                               extentHasChanged();
+                                       }
+                                       catch (final Exception e) {
+                                       }
+
+                               }
+                       });
+               }
+               return jComboBoxLayers;
+       }
+
+
+       private JComboBox getJComboBoxViews() {
+               if (jComboBoxViews == null) {
+                       final ComboBoxModel jComboBoxViewsModel = new 
DefaultComboBoxModel(SextanteGUI.getInputFactory().
+                                       getPredefinedExtents());
+                       jComboBoxViews = new JComboBox();
+                       jComboBoxViews.setModel(jComboBoxViewsModel);
+                       jComboBoxViews.addActionListener(new 
java.awt.event.ActionListener() {
+                               public void actionPerformed(final 
java.awt.event.ActionEvent evt) {
+                                       
getJRadioButtonAdjustToInputDataExtent().setSelected(false);
+                                       
getJRadioButtonUserDefinedExtent().setSelected(false);
+                                       
getJRadioButtonViewExtent().setSelected(true);
+                                       
getJRadioButtonExtentFromLayer().setSelected(false);                            
                                                
+                                       try {
+                                               final NamedExtent ne = 
(NamedExtent) jComboBoxViews.getSelectedItem();
+                                               if (ne != null) {
+                                                       Rectangle2D.Double 
extent = ne.getExtent();
+                                                       if ( extent == null ) {
+                                                               extent = new 
Rectangle2D.Double(0,0,1,1);
+                                                       }
+                                                       
getJTextFieldXMin().setText(new DecimalFormat(COORD_FORMAT).
+                                                                       
format(extent.getMinX()));
+                                                       
getJTextFieldXMax().setText(new DecimalFormat(COORD_FORMAT).
+                                                                       
format(extent.getMaxX()));
+                                                       
getJTextFieldYMin().setText(new DecimalFormat(COORD_FORMAT).
+                                                                       
format(extent.getMinY()));
+                                                       
getJTextFieldYMax().setText(new DecimalFormat(COORD_FORMAT).
+                                                                       
format(extent.getMaxY()));
+                                                       
setTextFieldsEnabled(false);
+                                                       extentHasChanged();
+                                               }
+                                       }
+                                       catch (final Exception e) {
+                                               Sextante.addErrorToLog(e);
+                                       }                                       
+                               }
+                       });
+               }
+               return jComboBoxViews;
+       }
+
+
+       protected JLabel getJLabelRangeX() {
+               if (jLabelRangeX == null) {
+                       jLabelRangeX = new JLabel();
+                       jLabelRangeX.setText(Sextante.getText("Range_X"));
+               }
+               return jLabelRangeX;
+       }
+
+
+       protected JTextField getNewJTextField() {
+
+               final JTextField jTextField = new JTextField();
+               jTextField.addFocusListener(new FocusAdapter() {
+                       @Override
+                       public void focusLost(final FocusEvent e) {
+                               final JTextField textField = (JTextField) 
e.getSource();
+                               final String content = textField.getText();
+                               if (content.length() != 0) {
+                                       try {
+                                               final double d = 
Double.parseDouble(content);
+                                               extentHasChanged();
+                                       }
+                                       catch (final NumberFormatException nfe) 
{
+                                               getToolkit().beep();
+                                               textField.requestFocus();
+                                       }
+                               }
+                       }
+               });
+               jTextField.addKeyListener(new KeyAdapter() {
+                       @Override
+                       public void keyTyped(final KeyEvent event) {
+                               validateKeyTyping(event);
+                       }
+               });
+
+               return jTextField;
+       }
+
+
+       protected JTextField getJTextFieldXMin() {
+               if (jTextFieldXMin == null) {
+                       jTextFieldXMin = getNewJTextField();
+                       jTextFieldXMin.addMouseListener(new 
TextFieldServices(jTextFieldXMin) {});
+               }
+               return jTextFieldXMin;
+       }
+
+
+       protected JTextField getJTextFieldXMax() {
+               if (jTextFieldXMax == null) {
+                       jTextFieldXMax = getNewJTextField();
+                       jTextFieldXMax.addMouseListener(new 
TextFieldServices(jTextFieldXMax) {});
+               }
+               return jTextFieldXMax;
+       }
+
+
+       protected JTextField getJTextFieldYMin() {
+               if (jTextFieldYMin == null) {
+                       jTextFieldYMin = getNewJTextField();
+                       jTextFieldYMin.addMouseListener(new 
TextFieldServices(jTextFieldYMin) {});
+               }
+               return jTextFieldYMin;
+       }
+
+
+       protected JTextField getJTextFieldYMax() {
+               if (jTextFieldYMax == null) {
+                       jTextFieldYMax = getNewJTextField();
+                       jTextFieldYMax.addMouseListener(new 
TextFieldServices(jTextFieldYMax) {});
+               }
+               return jTextFieldYMax;
+       }
+
+
+       protected JLabel getJLabelRangeY() {
+               if (jLabelRangeY == null) {
+                       jLabelRangeY = new JLabel();
+                       jLabelRangeY.setText(Sextante.getText("Range_Y"));
+               }
+               return jLabelRangeY;
+       }
+
+
+       public double getXMin() {
+               double result = 0;
+               if (this.getJTextFieldXMin().getText() == null ) {
+                       return (0.0);
+               }
+               if (this.getJTextFieldXMin().getText().length() < 1 ) {
+                       return (0.0);
+               }
+               try {
+                       if ( Double.valueOf(this.getJTextFieldXMin().getText()) 
!= null ) {
+                               return 
(Double.parseDouble(this.getJTextFieldXMin().getText()));
+                       }
+               } catch ( NumberFormatException nfe ) {
+                       return (0.0);
+               }
+               return (result);
+       }
+
+
+       public double getXMax() {
+               double result = 0;
+               if (this.getJTextFieldXMax().getText() == null ) {
+                       return (0.0);
+               }
+               if (this.getJTextFieldXMax().getText().length() < 1 ) {
+                       return (0.0);
+               }
+               try {
+                       if ( Double.valueOf(this.getJTextFieldXMax().getText()) 
!= null ) {
+                               return 
(Double.parseDouble(this.getJTextFieldXMax().getText()));
+                       }
+               } catch ( NumberFormatException nfe ) {
+                       return (0.0);
+               }
+               return (result);
+       }
+
+
+       public double getYMin() {
+               double result = 0;
+               if (this.getJTextFieldYMin().getText() == null ) {
+                       return (0.0);
+               }
+               if (this.getJTextFieldYMin().getText().length() < 1 ) {
+                       return (0.0);
+               }
+               try {
+                       if ( Double.valueOf(this.getJTextFieldYMin().getText()) 
!= null ) {
+                               return 
(Double.parseDouble(this.getJTextFieldYMin().getText()));
+                       }
+               } catch ( NumberFormatException nfe ) {
+                       return (0.0);
+               }
+               return (result);
+       }
+
+
+       public double getYMax() {
+               double result = 0;
+               if (this.getJTextFieldYMax().getText() == null ) {
+                       return (0.0);
+               }
+               if (this.getJTextFieldYMax().getText().length() < 1 ) {
+                       return (0.0);
+               }
+               try {
+                       if ( Double.valueOf(this.getJTextFieldYMax().getText()) 
!= null ) {
+                               return 
(Double.parseDouble(this.getJTextFieldYMax().getText()));
+                       }
+               } catch ( NumberFormatException nfe ) {
+                       return (0.0);
+               }
+               return (result);
+       }
+
+       protected JLabel getJLabelExtentFromPoints() {
+               if (jLabelExtentFromPoints == null) {
+                       jLabelExtentFromPoints = new JLabel();
+                       
jLabelExtentFromPoints.setText(Sextante.getText("Extent_from_points"));
+               }
+               return jLabelExtentFromPoints;
+       }
+       
+       
+       protected JLabel getJLabelCellSizeXY() {
+               if (jLabelCellSizeXY == null) {
+                       jLabelCellSizeXY = new JLabel();
+                       
jLabelCellSizeXY.setText(Sextante.getText("Cell_sizeXY"));
+               }
+               return jLabelCellSizeXY;
+       }
+
+
+       protected JTextField getJTextFieldCellSizeX() {
+               if (jTextFieldCellSizeX == null) {
+                       jTextFieldCellSizeX = new JTextField();
+                       jTextFieldCellSizeX.setText("1");
+                       jTextFieldCellSizeX.addFocusListener(new FocusAdapter() 
{
+                               @Override
+                               public void focusLost(final FocusEvent e) {
+                                       final JTextField textField = 
(JTextField) e.getSource();
+                                       final String content = 
textField.getText();
+                                       if (content.length() != 0) {
+                                               try {
+                                                       final double d = 
Double.parseDouble(content);
+                                                       if (d <= 0) {
+                                                               throw new 
NumberFormatException();
+                                                       }
+                                                       else {
+                                                               
extentHasChanged();
+                                                       }
+                                               }
+                                               catch (final 
NumberFormatException nfe) {
+                                                       getToolkit().beep();
+                                                       
textField.requestFocus();
+                                               }
+                                       }
+
+                               }
+                       });
+                       jTextFieldCellSizeX.addMouseListener(new 
TextFieldServices(jTextFieldCellSizeX, this) {});
+                       jTextFieldCellSizeX.addKeyListener(new KeyAdapter() {
+                               @Override
+                               public void keyTyped(final KeyEvent event) {
+                                       validateKeyTyping(event);
+                               }
+                       });
+               }
+               return jTextFieldCellSizeX;
+       }
+
+
+       protected JTextField getJTextFieldCellSizeY() {
+               if (jTextFieldCellSizeY == null) {
+                       jTextFieldCellSizeY = new JTextField();
+                       jTextFieldCellSizeY.setText("1");
+                       jTextFieldCellSizeY.addFocusListener(new FocusAdapter() 
{
+                               @Override
+                               public void focusLost(final FocusEvent e) {
+                                       final JTextField textField = 
(JTextField) e.getSource();
+                                       final String content = 
textField.getText();
+                                       if (content.length() != 0) {
+                                               try {
+                                                       final double d = 
Double.parseDouble(content);
+                                                       if (d <= 0) {
+                                                               throw new 
NumberFormatException();
+                                                       }
+                                                       else {
+                                                               
extentHasChanged();
+                                                       }
+                                               }
+                                               catch (final 
NumberFormatException nfe) {
+                                                       getToolkit().beep();
+                                                       
textField.requestFocus();
+                                               }
+                                       }
+
+                               }
+                       });
+                       jTextFieldCellSizeY.addMouseListener(new 
TextFieldServices(jTextFieldCellSizeY, this) {});
+                       jTextFieldCellSizeY.addKeyListener(new KeyAdapter() {
+                               @Override
+                               public void keyTyped(final KeyEvent event) {
+                                       validateKeyTyping(event);
+                               }
+                       });
+               }
+               return jTextFieldCellSizeY;
+       }
+
+
+       protected JLabel getJLabelRowsCols() {
+               if (jLabelRowsCols == null) {
+                       jLabelRowsCols = new JLabel();
+                       
jLabelRowsCols.setText(Sextante.getText("Number_of_rows-cols"));
+               }
+               return jLabelRowsCols;
+       }
+
+
+       protected JTextField getJTextFieldRows() {
+               if (jTextFieldRows == null) {
+                       jTextFieldRows = new JTextField();
+                       jTextFieldRows.setEnabled(false);
+               }
+               return jTextFieldRows;
+       }
+
+
+       protected JTextField getJTextFieldCols() {
+               if (jTextFieldCols == null) {
+                       jTextFieldCols = new JTextField();
+                       jTextFieldCols.setEnabled(false);
+               }
+               return jTextFieldCols;
+       }
+
+
+       private void validateKeyTyping(final KeyEvent event) {
+               String text = ((JTextField) event.getSource()).getText();
+               switch (event.getKeyChar()) {
+               case KeyEvent.VK_ENTER:
+                       extentHasChanged();
+                       break;
+               default:
+                       text += event.getKeyChar();
+                       break;
+               }
+       }
+
+
+       protected void setTextFieldsEnabled(final boolean bEnabled) {
+               getJPanelAnalysisExtentValues().setVisible(true);
+               getJTextFieldXMin().setEnabled(bEnabled);
+               getJTextFieldXMax().setEnabled(bEnabled);
+               getJTextFieldYMin().setEnabled(bEnabled);
+               getJTextFieldYMax().setEnabled(bEnabled);
+               getJButtonExtentFromPoints().setEnabled(bEnabled);
+       }
+
+
+       protected void extentHasChanged() {
+               double dRangeX;
+               double dRangeY;
+               double dCellSizeX;
+               double dCellSizeY;
+               int iRows;
+               int iCols;
+
+               try {
+                       dRangeX = 
Math.abs(Double.parseDouble(getJTextFieldXMax().getText()) 
+                                       - 
Double.parseDouble(getJTextFieldXMin().getText()));
+                       //=408
+                       dRangeY = 
Math.abs(Double.parseDouble(getJTextFieldYMax().getText()) 
+                                       - 
Double.parseDouble(getJTextFieldYMin().getText()));
+                       //=599.72932330827
+                       dCellSizeX = 
Double.parseDouble(getJTextFieldCellSizeX().getText());
+                       //=1.5338345864661653
+                       dCellSizeY = 
Double.parseDouble(getJTextFieldCellSizeY().getText());
+                       //=1.5338345864661653
+                       iCols = (int) Math.round(dRangeX / dCellSizeX);
+                       //=408/1.5338345864661653
+                       iRows = (int) Math.round(dRangeY / dCellSizeY);
+                       //=599.72932330827/1.5338345864661653
+                       getJTextFieldCols().setText(Integer.toString(iCols));
+                       getJTextFieldRows().setText(Integer.toString(iRows));   
                
+               }
+               catch (final NumberFormatException e) {
+                       return;
+               }
+       }
+
+
+       public void setExtent(final AnalysisExtent ge) {
+               getJRadioButtonUserDefinedExtent().setSelected(true);
+               setTextFieldsEnabled(true);
+               
getJTextFieldCellSizeX().setText(Double.toString(ge.getCellSizeX()));
+               
getJTextFieldCellSizeY().setText(Double.toString(ge.getCellSizeY()));
+               getJTextFieldXMin().setText(new 
DecimalFormat(COORD_FORMAT).format(ge.getXMin()));
+               getJTextFieldXMax().setText(new 
DecimalFormat(COORD_FORMAT).format(ge.getXMax()));
+               getJTextFieldYMin().setText(new 
DecimalFormat(COORD_FORMAT).format(ge.getYMin()));
+               getJTextFieldYMax().setText(new 
DecimalFormat(COORD_FORMAT).format(ge.getYMax()));
+               extentHasChanged();
+       }
+
+
+       public void setAutoExtent() {
+               getJRadioButtonAdjustToInputDataExtent().setSelected(true);
+               setTextFieldsEnabled(false);
+               getJPanelAnalysisExtentValues().setVisible(false);
+       }
+
+
+}


Property changes on: 
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/AnalysisExtentPanel.java
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+text/plain
\ No newline at end of property
Added: 
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/CheckBoxList.java
===================================================================
--- 
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/CheckBoxList.java
                               (rev 0)
+++ 
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/CheckBoxList.java
       2016-11-19 10:44:08 UTC (rev 5196)
@@ -0,0 +1,64 @@
+package es.unex.sextante.gui.algorithm;
+
+import java.awt.Component;
+import java.awt.event.MouseAdapter;
+import java.awt.event.MouseEvent;
+
+import javax.swing.JCheckBox;
+import javax.swing.JList;
+import javax.swing.ListCellRenderer;
+import javax.swing.ListSelectionModel;
+import javax.swing.border.Border;
+import javax.swing.border.EmptyBorder;
+
+/**
+ * A list with checkboxes
+ * 
+ * @author volaya
+ * 
+ */
+@SuppressWarnings({ "serial", "rawtypes" })
+public class CheckBoxList extends JList {
+    protected static final Border noFocusBorder = new EmptyBorder(1, 1, 1, 1);
+
+    /**
+     * Creates a new checkbox list
+     */
+    @SuppressWarnings("unchecked")
+    public CheckBoxList() {
+        setCellRenderer(new CellRenderer());
+
+        addMouseListener(new MouseAdapter() {
+            @Override
+            public void mousePressed(final MouseEvent e) {
+                final int index = locationToIndex(e.getPoint());
+
+                if (index != -1) {
+                    final JCheckBox checkbox = (JCheckBox) getModel()
+                            .getElementAt(index);
+                    checkbox.setSelected(!checkbox.isSelected());
+                    repaint();
+                }
+            }
+        });
+
+        setSelectionMode(ListSelectionModel.SINGLE_SELECTION);
+
+    }
+
+    protected class CellRenderer implements ListCellRenderer {
+        public Component getListCellRendererComponent(final JList list,
+                final Object value, final int index, final boolean isSelected,
+                final boolean cellHasFocus) {
+            final JCheckBox checkbox = (JCheckBox) value;
+            checkbox.setBackground(getBackground());
+            checkbox.setForeground(getForeground());
+            checkbox.setEnabled(isEnabled());
+            // checkbox.setFont(getFont());
+            checkbox.setFocusPainted(false);
+            checkbox.setBorderPainted(true);
+            checkbox.setBorder(noFocusBorder);
+            return checkbox;
+        }
+    }
+}


Property changes on: 
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/CheckBoxList.java
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+text/plain
\ No newline at end of property
Added: 
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/DatabaseOutputChannelSelectionPanel.java
===================================================================
--- 
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/DatabaseOutputChannelSelectionPanel.java
                                (rev 0)
+++ 
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/DatabaseOutputChannelSelectionPanel.java
        2016-11-19 10:44:08 UTC (rev 5196)
@@ -0,0 +1,15 @@
+package es.unex.sextante.gui.algorithm;
+
+import java.awt.event.ActionListener;
+
+import javax.swing.JPanel;
+
+@SuppressWarnings("serial")
+public class DatabaseOutputChannelSelectionPanel extends JPanel {
+
+    public DatabaseOutputChannelSelectionPanel(final String sDescription,
+            final ActionListener listener) {
+        // TODO Auto-generated constructor stub
+    }
+
+}


Property changes on: 
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/DatabaseOutputChannelSelectionPanel.java
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+text/plain
\ No newline at end of property
Added: 
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/DefaultParametersPanel.java
===================================================================
--- 
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/DefaultParametersPanel.java
                             (rev 0)
+++ 
plug-ins/SextantePlugIn/sextante-lib-source/sextante_gui/src/es/unex/sextante/gui/algorithm/DefaultParametersPanel.java
     2016-11-19 10:44:08 UTC (rev 5196)
@@ -0,0 +1,1993 @@
+package es.unex.sextante.gui.algorithm;
+
+import info.clearthought.layout.TableLayout;
+import info.clearthought.layout.TableLayoutConstants;
+
+import java.awt.BorderLayout;
+import java.awt.Dimension;
+import java.awt.Font;
+import java.awt.event.FocusAdapter;
+import java.awt.event.FocusEvent;
+import java.awt.geom.Point2D;
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.StringTokenizer;
+
+import javax.swing.BorderFactory;
+import javax.swing.ComboBoxModel;
+import javax.swing.DefaultComboBoxModel;
+import javax.swing.JCheckBox;
+import javax.swing.JComboBox;
+import javax.swing.JLabel;
+import javax.swing.JPanel;
+import javax.swing.JScrollPane;
+import javax.swing.JTextField;
+import javax.swing.ScrollPaneConstants;
+
+import org.japura.gui.Anchor;
+import org.japura.gui.BatchSelection;
+import org.japura.gui.CheckComboBox;
+import org.japura.gui.EmbeddedComponent;
+import org.japura.gui.model.ListCheckModel;
+
+import es.unex.sextante.additionalInfo.AdditionalInfo3DRasterLayer;
+import es.unex.sextante.additionalInfo.AdditionalInfoBand;
+import es.unex.sextante.additionalInfo.AdditionalInfoBoolean;
+import es.unex.sextante.additionalInfo.AdditionalInfoFilepath;
+import es.unex.sextante.additionalInfo.AdditionalInfoFixedTable;
+import es.unex.sextante.additionalInfo.AdditionalInfoImageLayer;
+import es.unex.sextante.additionalInfo.AdditionalInfoMultipleInput;
+import es.unex.sextante.additionalInfo.AdditionalInfoNumericalValue;
+import es.unex.sextante.additionalInfo.AdditionalInfoRasterLayer;
+import es.unex.sextante.additionalInfo.AdditionalInfoSelection;
+import es.unex.sextante.additionalInfo.AdditionalInfoString;
+import es.unex.sextante.additionalInfo.AdditionalInfoTable;
+import es.unex.sextante.additionalInfo.AdditionalInfoTableField;
+import es.unex.sextante.additionalInfo.AdditionalInfoVectorLayer;
+import es.unex.sextante.core.GeoAlgorithm;
+import es.unex.sextante.core.ObjectAndDescription;
+import es.unex.sextante.core.OutputObjectsSet;
+import es.unex.sextante.core.ParametersSet;
+import es.unex.sextante.core.Sextante;
+import es.unex.sextante.dataObjects.I3DRasterLayer;
+import es.unex.sextante.dataObjects.IDataObject;
+import es.unex.sextante.dataObjects.IRasterLayer;
+import es.unex.sextante.dataObjects.ITable;
+import es.unex.sextante.dataObjects.IVectorLayer;
+import es.unex.sextante.exceptions.NullParameterAdditionalInfoException;
+import es.unex.sextante.exceptions.WrongInputException;
+import es.unex.sextante.exceptions.WrongOutputChannelDataException;
+import es.unex.sextante.exceptions.WrongOutputIDException;
+import es.unex.sextante.exceptions.WrongParameterIDException;
+import es.unex.sextante.gui.core.SextanteGUI;
+import es.unex.sextante.gui.core.TextFieldServices;
+import es.unex.sextante.gui.exceptions.LayerCannotBeOverwrittenException;
+import es.unex.sextante.gui.grass.GrassAlgorithm;
+import es.unex.sextante.gui.help.HelpElement;
+import es.unex.sextante.gui.help.HelpIO;
+import es.unex.sextante.outputs.IOutputChannel;
+import es.unex.sextante.outputs.Output;
+import es.unex.sextante.outputs.Output3DRasterLayer;
+import es.unex.sextante.outputs.OutputRasterLayer;
+import es.unex.sextante.outputs.OutputTable;
+import es.unex.sextante.outputs.OutputVectorLayer;
+import es.unex.sextante.outputs.OverwriteOutputChannel;
+import es.unex.sextante.parameters.FixedTableModel;
+import es.unex.sextante.parameters.Parameter;
+import es.unex.sextante.parameters.Parameter3DRasterLayer;
+import es.unex.sextante.parameters.ParameterBand;
+import es.unex.sextante.parameters.ParameterBoolean;
+import es.unex.sextante.parameters.ParameterDataObject;
+import es.unex.sextante.parameters.ParameterFilepath;
+import es.unex.sextante.parameters.ParameterFixedTable;
+import es.unex.sextante.parameters.ParameterImageLayer;
+import es.unex.sextante.parameters.ParameterMultipleInput;
+import es.unex.sextante.parameters.ParameterNumericalValue;
+import es.unex.sextante.parameters.ParameterPoint;
+import es.unex.sextante.parameters.ParameterRasterLayer;
+import es.unex.sextante.parameters.ParameterSelection;
+import es.unex.sextante.parameters.ParameterString;
+import es.unex.sextante.parameters.ParameterTable;
+import es.unex.sextante.parameters.ParameterTableField;
+import es.unex.sextante.parameters.ParameterVectorLayer;
+import es.unex.sextante.parameters.RasterLayerAndBand;
+
+/**
+ * A panel to introduce parameters for a geoalgorithm, created automatically
+ * based on the parameters needed by that geoalgorithm If no additional panel 
is
+ * provided for an algorithm, SEXTANTE will use this panel as the default one.
+ * 
+ * @author volaya
+ * 
+ */
+public class DefaultParametersPanel extends GeoAlgorithmParametersPanel {
+
+    /**
+     * 
+     */
+    private static final long serialVersionUID = 1L;
+    protected static int CELL_HEIGHT = 18;
+    protected static int COLUMN_WIDTH = 250;
+
+    protected int m_iCurrentRow = 0;
+    protected JScrollPane jScrollPanelParameters;
+    protected JPanel jPanelParameters;
+    protected ArrayList m_ParameterContainer = new ArrayList();
+    protected ArrayList m_ComboBox = new ArrayList();
+    protected GeoAlgorithm m_Algorithm;
+    protected ArrayList m_OutputParameterContainer = new ArrayList();
+    protected HashMap m_HelpElements;
+
+    /**
+     * Constructor.
+     */
+    public DefaultParametersPanel() {
+
+        super();
+
+    }
+
+    @Override
+    public void init(final GeoAlgorithm alg) {
+
+        m_Algorithm = alg;
+
+        try {
+            final ArrayList list = HelpIO.open(SextanteGUI
+                    .getAlgorithmHelpFilename(alg, false));
+
+            if (list != null) {
+                m_HelpElements = HelpIO.createMap(list);
+            } else {
+                m_HelpElements = new HashMap();
+            }
+        } catch (final Exception e) {
+            m_HelpElements = new HashMap();
+        }
+
+        initGUI();
+
+    }
+
+    protected void initGUI() {
+
+        m_ComboBox = new ArrayList();
+
+        {
+            jScrollPanelParameters = new JScrollPane();
+            jPanelParameters = new JPanel();
+
+            int guiRows = 0;
+
+            final JPanel jInputs = new JPanel();
+            final JPanel jOptions = new JPanel();
+            final JPanel jOutputs = new JPanel();
+
+            final double[][] inputs_matrix = getInputsTableLayoutMatrix();
+            if (inputs_matrix[1].length > 1) {
+                final TableLayout jInputsLayout = new 
TableLayout(inputs_matrix);

@@ Diff output truncated at 100000 characters. @@

------------------------------------------------------------------------------
_______________________________________________
Jump-pilot-devel mailing list
Jump-pilot-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel

Reply via email to