[Repository Listing] / [Slicer4] / trunk / Base
 

Log of /trunk/Base

Parent Directory Parent Directory View Directory Listing Directory Listing


Sticky Revision:

Revision 26392  Directory Listing
Modified Fri Sep 22 03:59:45 2017 UTC (3 days, 11 hours ago) by jcfr
BUG: Fix test_slicer_environment on windows

Revision 26380  Directory Listing
Modified Wed Sep 20 17:13:25 2017 UTC (4 days, 21 hours ago) by jcfr
ENH: Integrate VTK plotting to support Interactive manipulation

This commit provides Plotting facilities that include a Plot View
that can be packed in the layout, similar to the Slice Views and 3D Views.

The architecture also includes nodes that represent the data to be displayed
in the plot as well as nodes to represent the display properties of the data
and the plot itself.

In Addition, the PlotView is connected with the Table Module and Views allowing
the plotting of arrays with a simple click.

References:
https://www.slicer.org/wiki/Documentation/Nightly/Developers/Plots
https://www.na-mic.org/wiki/Project_Week_25/Interactive_Manipulation_of_Plots_and_Graphs
https://www.slicer.org/wiki/Developer_Meetings/20170425

Reviewed-by: Andras Lasso <lasso@queensu.ca>
Reviewed-by: Andriy Fedorov <fedorov@bwh.harvard.edu>
Reviewed-by: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>
Reviewed-by: Steve Pieper <pieper@bwh.harvard.edu>

From: Davide Punzo <punzodavide@hotmail.it>

Revision 26369  Directory Listing
Modified Tue Sep 12 17:33:18 2017 UTC (12 days, 21 hours ago) by lassoan
BUG: Fixed incorrect value ending up in composite view's volume node IDs

By not checking the compared object by contained values, the string 'keep-current' could end up in the volume node IDs (background, foreground, label) stored in vtkMRMLSliceCompositeNode, making it hard to check if a valid volume node in shown in a slice view.

For some reason the string 'NULL' can also end up in these char* members that should only contain valid node ID strings or null pointer, hence the fix in qSlicerSubjectHierarchyVolumesPlugin. The source of the string 'NULL' is still unknown.

Revision 26365  Directory Listing
Modified Fri Sep 8 20:48:19 2017 UTC (2 weeks, 2 days ago) by jcfr
COMP: MRML: Fix "inconsistent-missing-override" C++11 warnings

Ensure that overridden functions are explicitly validated
when compiling with C++11

This patch suppresses 100's of warnings:
warning: 'SomeMemberFunctionOfDerivedClass' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]

From: Hans Johnson <hans-johnson@uiowa.edu>

Revision 26351  Directory Listing
Modified Wed Sep 6 02:54:53 2017 UTC (2 weeks, 5 days ago) by jcfr
ENH: Extend application API adding environment()/startupEnvironment()

Thanks: Andras Lasso <lasso@queensu.ca>

Revision 26344  Directory Listing
Modified Tue Sep 5 14:29:50 2017 UTC (2 weeks, 6 days ago) by jcfr
COMP: Fix unused variable warnings

Revision 26328  Directory Listing
Modified Thu Aug 31 23:47:57 2017 UTC (3 weeks, 3 days ago) by jcfr
ENH: Extend scripted module API adding support for cleanup() method

This allows to do some cleanup before a scripted module is effectively
unloaded. It is particularly useful to update objects or widgets and avoid
memory leaks due to complex interdependencies between C++ application and
python layer.

Reviewed-by: Steve Pieper <pieper@bwh.harvard.edu>

Revision 26315  Directory Listing
Modified Tue Aug 29 07:39:44 2017 UTC (3 weeks, 6 days ago) by jcfr
ENH: Support scripted module associated only with loadable logics

This commit adds support for creating extension (e.g CarreraSlice) that
bundles only a scripted loadable module and loadable module logics like
MRML, MRMLDM, Logic or PythonQt.

Benchmark using

  python /path/to/Slicer/Applications/SlicerApp/Testing/Python/MeasureStartupTimes.py --normal  ./Slicer

didn't show any impact on startup time. Around 3.05s with or without this
change.

Revision 26284  Directory Listing
Modified Wed Aug 16 18:06:38 2017 UTC (5 weeks, 4 days ago) by jcfr
ENH: SlicerWebWidget: Add support for reporting SSL errors with Qt5/WebEngine

Revision 26283  Directory Listing
Modified Wed Aug 16 18:06:37 2017 UTC (5 weeks, 4 days ago) by jcfr
STYLE: SlicerWebWidget: Remove debug statement, use qWarnings

This commit also simplifies the conditional inclusion of code based
on the version of Qt by grouping statement together.

Revision 26280  Directory Listing
Modified Wed Aug 16 14:15:49 2017 UTC (5 weeks, 5 days ago) by jcfr
ENH: SlicerApplication: Introduce "startupCompleted()" signal

This signal is emitted when the startup phase has been completed.

Startup is complete when all the modules have been
initialized and the main window is shown to the user.

Note: If the application is started without the mainwindow,
the signal is emitted after the modules are initialized.

Test checking that both cases work as expected is also added.

Suggested-by: Andras Lasso <lasso@queensu.ca>

Revision 26279  Directory Listing
Modified Wed Aug 16 14:15:45 2017 UTC (5 weeks, 5 days ago) by jcfr
BUG: Fix module updating mainwindow at load time when using Qt5

With Qt5, relying on "Qtimer::singleShow" with a time of 0ms is not
sufficient anymore to ensure the associated slot is called after the
main window is shown.

The following errors were reported at startup time:

```
Failed to obtain reference to 'FileMenu'
Failed to obtain reference to 'qSlicerAppMainWindow'
No Data Probe frame - cannot create DataProbe
Failed to obtain reference to 'qSlicerAppMainWindow'
Failed to obtain reference to 'FileMenu'
```

To ensure module can update the main window once it is shown, this
commit introduces the signal "qSlicerApplication::mainWindowShown()" that
can be connected when a scripted or loadable module is initialized.

Once the main window is shown, the signal "mainWindowShown()" ends up being
triggered.

Revision 26278  Directory Listing
Modified Wed Aug 16 11:11:54 2017 UTC (5 weeks, 5 days ago) by jcfr
BUG: slicer.util: Add missing import to pythonShell function

This commit fixes the following error:

```
>>> slicer.util.pythonShell()
Traceback (most recent call last):
  File "<console>", line 1, in <module>
  File "/path/to/Slicer-build/Slicer-build/bin/Python/slicer/util.py", line 147, in pythonShell
    console = slicer.app.pythonConsole()
NameError: global name 'slicer' is not defined
```

Revision 26265  Directory Listing
Modified Mon Aug 14 02:16:23 2017 UTC (6 weeks ago) by jcfr
COMP: Fix QStyleOptionFrameV[2-4] deprecation warnings with Qt5

Fix warnings similar to the following when building with Qt5:

    Base/QTGUI/qSlicerStyle.cxx:149:61: warning: 'QStyleOptionFrameV2' is deprecated [-Wdeprecated-declarations]

From: Max Smolens <max.smolens@kitware.com>

Revision 26260  Directory Listing
Modified Mon Aug 14 02:16:07 2017 UTC (6 weeks ago) by jcfr
ENH: Set default QSurfaceFormat for QVTKOpenGLWidget

Set default QSurfaceFormat for QVTKOpenGLWidget so that QVTKOpenGLWidget
receives the proper OpenGL core profile context.

From QOpenGLWidget documentation (http://doc.qt.io/qt-5/qopenglwidget.html):

    Note: Calling QSurfaceFormat::setDefaultFormat() before constructing
    the QApplication instance is mandatory on some platforms (for
    example, macOS) when an OpenGL core profile context is requested.
    This is to ensure that resource sharing between contexts stays
    functional as all internal contexts are created using the correct
    version and profile.

Client code uses QVTKOpenGLWidget when SlICer_VTK_USE_QVTKOPENGLWIDGET
is defined in vtkSlicerConfigure.h.

Multisampling is disabled to support volume rendering and other VTK
functionality that reads from the framebuffer. See
https://gitlab.kitware.com/vtk/vtk/issues/1709.

From: Max Smolens <max.smolens@kitware.com>

Revision 26259  Directory Listing
Modified Mon Aug 14 02:15:39 2017 UTC (6 weeks ago) by jcfr
COMP: Recognize QT_NO_SSL feature macro

Fix the following build error when using Qt5 without SSL support:

    In file included from /path/to/Slicer/Base/QTGUI/qSlicerWebWidget.cxx:45:
    /path/to/Slicer/Base/QTGUI/qSlicerWebWidget.h:43:8: error: redefinition of 'QSslError'
    struct QSslError{};
           ^
    /path/to/Qt5.7.1/5.7/clang_64/lib/QtNetwork.framework/Headers/qsslerror.h:53:24: note: previous definition is here
    class Q_NETWORK_EXPORT QSslError

From: Max Smolens <max.smolens@kitware.com>

Revision 26258  Directory Listing
Modified Mon Aug 14 02:15:37 2017 UTC (6 weeks ago) by jcfr
COMP: Link qSlicerBaseQTCore to Qt libraries

Link qSlicerBaseQTCore to Qt libraries. Qt4's QtCore module previously
contained networking classes, but Qt5 moves classes like
QNetworkProxyFactory to Qt5::Network.

From: Max Smolens <max.smolens@kitware.com>

Revision 26254  Directory Listing
Modified Mon Aug 14 02:15:25 2017 UTC (6 weeks ago) by jcfr
ENH: WIP - WebEngine support for extension manager

From: Hina Shah <hina.shah@kitware.com>

Revision 26252  Directory Listing
Modified Mon Aug 14 02:15:15 2017 UTC (6 weeks ago) by jcfr
ENH: Suport Qt5 integrating QCleanLooksStyle from qtstyleplugins

This commit integrates qtstyleplugins files based of commit 600c296
from git://code.qt.io/qt/qtstyleplugins.git

BUG: bug fixes for some compilation errors on Windows

Co-authored-by: Hina Shah <hina.shah@kitware.com>

From: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

Revision 26251  Directory Listing
Modified Mon Aug 14 02:07:21 2017 UTC (6 weeks ago) by jcfr
ENH: Add preliminary support for Qt5

Support configuration using either Qt4 or Qt5

Based on preliminary work from Steve Pieper <pieper@bwh.harvard.edu>

* vtkSlicerConfigure: Introduced Slicer_HAVE_QT5 and Slicer_HAVE_WEBKIT_SUPPORT.
  This was needed to workaround limitation of "moc" compiler preventing it
  from expanding macro like "QT_VERSION_CHECK.

* Explicitly set QT_PLUGINS_DIR and QT_BINARY_DIR variables when using Qt5

* Update extension build system to propagate Qt version

Tested with Qt 5.7 and Qt 5.9 on Ubuntu

Remaining tasks:
* Port extension manager
* Update install/packaging rules to support Qt5
* SlicerStyle (based on CommonStyle) is disabled (see Main.cxx). Application crashes on Linux.
* Fix runtime errors:
 * libpng warning: iCCP: known incorrect sRGB profile
 * QPixmap::grabWidget is deprecated, use QWidget::grab() instead

Co-authored-by: Hina Shah <hina.shah@kitware.com>
Co-authored-by: Max Smolens <max.smolens@kitware.com>

COMP adding qt5 variables for extension testing

COMP Adding Qt5 build and plugin cmake variables

From: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

Revision 26248  Directory Listing
Modified Mon Aug 14 02:06:21 2017 UTC (6 weeks ago) by jcfr
COMP: Fix inconsistent-missing-override warnings

This commit adds the VTK_OVERRIDE macros to fix the warnings.

From: Hina Shah <hina.shah@kitware.com>

Revision 26242  Directory Listing
Modified Sat Aug 12 12:04:40 2017 UTC (6 weeks, 2 days ago) by lassoan
BUG: Fixed regression in sitkUtils

Regression introduced in the last commit (not latest version of the file was committed).

Revision 26241  Directory Listing
Modified Fri Aug 11 18:27:18 2017 UTC (6 weeks, 2 days ago) by lassoan
STYLE: Fixed mistake in sitkUtils documentation

Based on Jc's code review.

Revision 26239  Directory Listing
Modified Fri Aug 11 16:54:46 2017 UTC (6 weeks, 2 days ago) by jcfr
BUG: Fix reading DeveloperMode setting

Similar to the approach in Slicer/Slicer@fba6424, make reading the DeveloperMode
setting more robust. The setting lookup now handles when the setting doesn't
exist and when it returns a bool, as in Qt5. This fixes the following error:

    AttributeError: 'bool' object has no attribute 'lower'

Co-authored-by: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

From: Max Smolens <max.smolens@kitware.com>

Revision 26230  Directory Listing
Modified Fri Aug 11 03:50:39 2017 UTC (6 weeks, 3 days ago) by lassoan
ENH: Made sitkUtils API more robust

Methods in sitkUtils were simple and usable for simple testing, but were not robust enough
for general use:
- Referring to nodes by ID is unreliable: several nodes may have the same node name;
  users may change node name at any time; node names may be changed when added to the scene
  if a node name is already used, etc.
- Old APIs are used. For example, adding of display nodes, showing volumes in certain views, adding nodes
  to the scene have simpler, more effective methods.
- Display options were mixed with data management (data pushed into Slicer was forced to be displayed)

Solution:

Existing methods were kept for backward compatibility but a warning is logged to inform the user that the methods
are deprecated and will be removed in the future.

Added new methods that are more robust, refer to nodes by node object, and use new APIs.
Method names are more specific (indicate that volume nodes are pushed/pulled, not transforms, etc).
Slice display management is removed from push/pull volume.

Updated tests. Tests cover both current and deprecated methods.

Revision 26221  Directory Listing
Modified Wed Aug 9 18:46:24 2017 UTC (6 weeks, 4 days ago) by pieper
ENH: expose grid transform vector field as numpy array

From: Steve Pieper <pieper@isomics.com>

Revision 26196  Directory Listing
Modified Thu Aug 3 18:35:52 2017 UTC (7 weeks, 3 days ago) by jcfr
COMP: vtkSlicerApplicationLogicRequest: Fix unused parameter warnings

From: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

Revision 26182  Directory Listing
Modified Fri Jul 28 21:48:36 2017 UTC (8 weeks, 2 days ago) by lassoan
ENH: Print separator in Python console when a module is reloaded

This helps in distinguishing between errors occurred before/after reload.

Contributed by: Mohamed Moselhy (https://github.com/moselhy)
https://github.com/Slicer/Slicer/pull/757

Revision 26161  Directory Listing
Modified Fri Jul 21 16:41:04 2017 UTC (2 months ago) by jcfr
BUG: QTCLI: Fix crash during UI buildup if ButtonGroup has no checked button

From: Michael Schwier <mschwier@bwh.harvard.edu>

Revision 26160  Directory Listing
Modified Fri Jul 21 16:41:02 2017 UTC (2 months ago) by jcfr
COMP: vtkSlicerApplicationLogicRequest: Fix -Wdelete-non-virtual-dtor warning

From: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

Revision 26157  Directory Listing
Modified Wed Jul 19 22:51:28 2017 UTC (2 months ago) by jcfr
ENH: AbstractModuleWidget: Expose enter()/exit() to python scripting

Revision 26156  Directory Listing
Modified Tue Jul 18 17:32:16 2017 UTC (2 months, 1 week ago) by jcfr
BUG: Ensure function defined in .slicerrc.py are available in console

Reported-by: Mohamed Moselhy <mmoslehy@uwo.ca>
Tested-by: Mohamed Moselhy <mmoslehy@uwo.ca>

Revision 26149  Directory Listing
Modified Mon Jul 10 14:38:16 2017 UTC (2 months, 2 weeks ago) by lassoan
ENH: Made updateVolumeFromArray work for new volume nodes

Revision 26147  Directory Listing
Modified Mon Jul 10 13:59:40 2017 UTC (2 months, 2 weeks ago) by lassoan
ENH: Added more numpy array conversions to slicer.util

Added arrayFromVolume() and arrayFromModelPoints(). These are more explicit MRML node -> numpy array
conversion functions than array(): they use a MRML node object as input and it is more clear
what part of the MRML node is retrieved as numpy array.

Added updateVolumeFromArray. It copies content of an existing numpy array into image data of a volume node.

Also added automatic tests to UtilTest.py.

Revision 26145  Directory Listing
Modified Thu Jul 6 15:50:03 2017 UTC (2 months, 2 weeks ago) by lassoan
ENH: Make CLI output update more robust

After a CLI module is executed, nodes that have references to other nodes are updated:
their parent transform are set to the referenced transform node; and/or their subject hierarchy
parent item is set to be the same as the parent of the referenced node.

This scene updated relied on a Qt timer that performed the updates "right after" CLI execution
was completed. This mechanism was not reliable because the timer required the user to
force background event processing for a while after the CLI execution was reported to be completed,
but this workaround was not reliable (see for example this report:
https://discourse.slicer.org/t/issues-modifying-the-transform-tree/569/13).

Changed the mechanism to use the same event queue that is used for processing reading of results
back into the scene. This way it can be assured that by the time the CLI execution is reported
to be complete, all the scene updates are completed as well.

Revision 26140  Directory Listing
Modified Fri Jun 30 13:50:05 2017 UTC (2 months, 3 weeks ago) by jcfr
COMP: qSlicerSlicer2SceneReader: Remove deprecated data types

VTK___INT64 and VTK_UNSIGNED___INT64 have been deprecated
on 2015-12-08 (kitware/VTK@36bb09a) and are compiled away
since 2017-04-13 (kitware/VTK@bc2e2c5) when VTK_LEGACY_REMOVE
is ON.

Revision 26139  Directory Listing
Modified Fri Jun 30 12:20:33 2017 UTC (2 months, 3 weeks ago) by jcfr
ENH: ColorFiles: Add diverging colormap

Slicer lacked a perceptually uniform diverging colormap.

These are useful when the information being plotted has
a critical middle value, or when the data deviates around zero.

According to matplotlib:
> Diverging: change in lightness and possibly saturation of two different
> colors that meet in the middle at an unsaturated color; should be used
> when the information being plotted has a critical middle value, such as
> topography or when the data deviates around zero.

More info about why perceptually uniform colormaps should be used over
older colormaps like Rainbow or Jet:

- matplotlib colormaps [2]
- Diverging colormaps [3]
- MATLAB's posts about new perceptually uniform colormaps [4]

[1] https://matplotlib.org/
[2] https://matplotlib.org/users/colormaps.html
[3] http://www.kennethmoreland.com/color-maps/
[4] http://blogs.mathworks.com/steve/2014/10/13/a-new-colormap-for-matlab-part-1-introduction/

From: Fernando <fepegar@gmail.com>

Revision 26137  Directory Listing
Modified Mon Jun 26 15:29:23 2017 UTC (2 months, 4 weeks ago) by jcfr
ENH: Updating SEM to integrate more explicitly named functions

- New Slicer Execution model version in Slicer (see Slicer/SlicerExecutionModel#91):

  $ git shortlog Slicer/SlicerExecutionModel@61bb14d..Slicer/SlicerExecutionModel@1d3e9a2 --no-merges
  Jean-Baptiste Vimort (2):
      STYLE: Renaming of the 'defaultValue' parameter's attribute to 'Value'
      ENH: Depreciation of the old functions

- Replace the use of deprecated functions with the new ones

- Deprecate the GetParameterDefault method: the GetParameterValue method
  should be used instead

Co-authored-by: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

Reviewed-by: Johan Andruejol <johan.andruejol@kitware.com>
Reviewed-by: Steve Pieper <pieper@bwh.harvard.edu>

From: Jean-Baptiste VIMORT <jb.vimort@kitware.com>

Revision 26105  Directory Listing
Modified Tue Jun 20 17:16:54 2017 UTC (3 months ago) by lassoan
ENH: Removed terminology support from Colors module

Terminologies are now managed by a dedicated module (Terminologies) and used in segmentations modules.

Fixes #4320 (https://issues.slicer.org/view.php?id=4320)

Revision 26097  Directory Listing
Modified Thu Jun 15 23:27:36 2017 UTC (3 months, 1 week ago) by lassoan
BUG: Fixed qSlicerWidgetTest2

ITK IO classes had to be registered to be able to read input images.
Added error/warning check in output of all Qt GUI cxx tests.

Fixes #4272 (https://issues.slicer.org/view.php?id=4272)

Revision 26084  Directory Listing
Modified Tue Jun 13 14:07:09 2017 UTC (3 months, 1 week ago) by lassoan
BUG: Fixed extension manager crash with dark theme

Cleanlooks style requires a window gradient if a button gradient is used but the gradient was only defined for default group,
not for disabled group.

Fixes #3732 (https://issues.slicer.org/view.php?id=3732)

Revision 26078  Directory Listing
Modified Sat Jun 10 02:44:13 2017 UTC (3 months, 2 weeks ago) by ihnorton
ENH: set CLI widget objectName based on parameter name

Revision 26076  Directory Listing
Modified Sat Jun 10 02:42:03 2017 UTC (3 months, 2 weeks ago) by ihnorton
ENH: add 'AllowInMemoryTransfer' CLI setting

This allows a CLI to control whether in-memory (MRMLID) transfer is attempted.
Implemented as a parameter for simplicity. Could be implemented in SEM, but
not sure it's worth the churn that would cause.

Revision 26074  Directory Listing
Modified Fri Jun 9 20:52:41 2017 UTC (3 months, 2 weeks ago) by lassoan
BUG: Fixed scene save with images loaded from command-line

fixes #3630 (https://issues.slicer.org/view.php?id=3630)

The problem was that file names passed to Slicer through command-line arguments are interpreted as relative to the current working directory, which is different from how relative paths are interpreted in a scene (relative to .mrb scene file location).

Fixed it by converting relative path to absolute path when interpreting command-line arguments.

Revision 26072  Directory Listing
Modified Sun Jun 4 01:21:21 2017 UTC (3 months, 3 weeks ago) by lassoan
ENH: SampleData module loads all data sets from Midas

Also added showing of loading status on the status bar, as the log window is not always visible in lower resolution screens.

Revision 26062  Directory Listing
Modified Wed May 31 15:58:46 2017 UTC (3 months, 3 weeks ago) by lassoan
BUG: Removed memory leaks using GetNodesByClass from Python

GetNodesByClass creates a new collection that the caller has to take ownership of (the caller will have to delete).
Python automatically adds a reference, so we have to call UnRegister to remove the extra reference.

Revision 26059  Directory Listing
Modified Tue May 30 18:39:17 2017 UTC (3 months, 3 weeks ago) by lassoan
BUG: Removed all iteratorless traverse of shared collections

Collections have convenience functions for traversing it without the need for creating an iterator,
using InitTraversal() and GetNextItemAsObject(). These functions use an internal iterator stored in the collection.

Problem:

When a collection is traversed using the internal iterator by multiple functions at the same time, the behavior will be incorrect.

For collections that can be accessed by multiple objects, it is almost impossible to make sure that only one function will use
the internal iterator at a time. Therefore, shared collections must be traversed using external iterators.

For example, this error caused a bug in View Controllers module: it only showed the first slice view controller (while there were three). The problem was that View Controllers module iterated through the nodes using the internal iterator and internally a method was called that asked for a list of nodes by classname, which used the same internal iterator.

Solution:

- Replaced all instances of shared collection traversal with internal iterator.
- Made vtkMRMLScene's InitTraversal, GetNextNode, and GetNextNodeByClass methods deprecated (they are still functional,
  but log a warning when they are called).
- Added vtkMRMLScene::GetFirstNodeByClass convenience function and modified functions that used InitTraversal/GetNextNodeByClass
  or GetNthNodeByClass(0, ...) to use this function.

Revision 26042  Directory Listing
Modified Thu May 25 05:06:47 2017 UTC (4 months ago) by jcfr
ENH: Add support for reading launcher setting using CTKAppLauncherLib

This commit introduces a dependency to the statically linked
library CTKAppLauncherLib

This library also used internally by the regular Slicer launcher allows
to read the launcher main settings and its associated revision specific
settings listing extensions paths.

Since on all platforms, environment variables are now consistently read
from settings files, this commit removes:

(1) the duplicated code path settings variables from the application
using methods like:
* qSlicerCoreApplicationPrivate::setPythonEnvironmentVariables()
* qSlicerCoreApplicationPrivate::setTclEnvironmentVariables()
* qSlicerCoreApplicationPrivate::discoverITKFactoriesDirectory()
* qSlicerCorePythonManager::pythonPaths()

(2) the application settings "Python/AdditionalPythonPaths" originally
introduced in r20852 (BUG: Ensure extension python paths are set on MacOSX)
to workaround the fact launcher settings were not used on MacOSX.

Finally, this commit also ensures that PYTHONPATH associated with thirdparty
libraries bundled in extension are considered on MacOSX. See Radiomics/SlicerRadiomics#18

[ci skip]

Revision 26041  Directory Listing
Modified Thu May 25 05:06:43 2017 UTC (4 months ago) by jcfr
ENH: SlicerCoreApplication: Introduces "isUsingLauncher()" function

Revision 26040  Directory Listing
Modified Thu May 25 05:06:41 2017 UTC (4 months ago) by jcfr
STYLE: SlicerCoreApplication: Simplify code removing updatePythonOsEnviron()

This commit simplifies the code removing optimization (use of "updatePythonOsEnviron()"
function and associated cache variable "EnvironmentVariablesCache") initially introduced
in commits:

* r16909 (BUG: Call updatePythonOsEnviron() after python is initialized.)
* r18762 (ENH: Initialization of python context done within qSlicerCoreApplication)
* r17611 (ENH: qSlicerCoreApplication - Add convenient function allowing to update environment).

Revision 26035  Directory Listing
Modified Wed May 24 19:09:23 2017 UTC (4 months ago) by lassoan
ENH: Added centered slice jump crosshair behavior

In Crosshair menu the user can now choose between slice jump with offset or centered (or jump slice disabled).

Revision 26030  Directory Listing
Modified Tue May 23 05:24:59 2017 UTC (4 months ago) by jcfr
STYLE: qSlicerPythonManager: Remove unneeded "pythonPaths()" function

Revision 26011  Directory Listing
Modified Mon May 15 15:46:24 2017 UTC (4 months, 1 week ago) by jcfr
ENH: Add support for MINC image IO

Issue #4085

This enables MINC Image IO via ITK. This currently supports MINC version 2
(HDF5-based).

Reviewed-by: Andriy Fedorov <fedorov@bwh.harvard.edu>
Reviewed-by: Andras Lasso <lasso@queensu.ca>
Reviewed-by: Johan Andruejol <johan.andruejol@kitware.com>
Reviewed-by: Gabriel A. Devenyi <gdevenyi@gmail.com>
Reviewed-by: Vladimir S. FONOV <vladimir.fonov@gmail.com>

Tested-by: Andras Lasso <lasso@queensu.ca>
Tested-by: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

From: Matt McCormick <matt.mccormick@kitware.com>

Revision 26007  Directory Listing
Modified Sat May 6 19:01:05 2017 UTC (4 months, 2 weeks ago) by jcfr
COMP: Update CTK and fix warnings

$ git shortlog a63253f..7129bb0 --no-merges
Jean-Christophe Fillion-Robin (2):
      Update QtTesting to fix overload warnings
      COMP: ctkErrorLogFDMessageHandler: Fix "unused-result" warning

Revision 25995  Directory Listing
Modified Mon May 1 22:42:35 2017 UTC (4 months, 3 weeks ago) by lassoan
ENH: Made reading of DeveloperMode settings more robust

DeveloperMode setting may be missing (if Slicer is not executed before).
If this setting is missing then it is now assumed to be false
(instead of failing with an error).

Revision 25983  Directory Listing
Modified Thu Apr 27 23:15:57 2017 UTC (4 months, 4 weeks ago) by pieper
BUG: fix missing backslash to escape quote in URL

From: Steve Pieper <pieper@isomics.com>

Revision 25982  Directory Listing
Modified Thu Apr 27 20:58:35 2017 UTC (4 months, 4 weeks ago) by johan.andruejol
STYLE: Fixed dead link in about box

Changed linnk from http://nihroadmap.nih.gov/bioinformatics to https://commonfund.nih.gov/bioinformatics

From: Samuel Gerber <sgerber@uoregon.edu>

Revision 25980  Directory Listing
Modified Thu Apr 27 16:53:47 2017 UTC (4 months, 4 weeks ago) by lassoan
ENH: Reduced false alarms in UtilTest

Reduced false alarms in UtilTest to make it easier to detect real errors on the dashboard.

Revision 25967  Directory Listing
Modified Wed Apr 26 01:30:29 2017 UTC (5 months ago) by lassoan
BUG: Fixed miniscene import

Fixed premature node reference resolution during miniscene import.

Revision 25959  Directory Listing
Modified Tue Apr 25 03:58:22 2017 UTC (5 months ago) by jcfr
STYLE: ExtensionManager: Add PYTHON_SITE_PACKAGES_SUBDIR to launcher settings

This commit ensures that python path is updated after installing extension
bundling python packages.

Revision 25958  Directory Listing
Modified Tue Apr 25 03:58:20 2017 UTC (5 months ago) by jcfr
STYLE: ExtensionManager: Add Slicer_THIRDPARTY_ vars to launcher settings

For sake of consistency, this commit explicitly add directory associated
with third-party libraries packages to the launcher settings.

Related commits:

* r25288 (BUG: Add the extension third party directories to
  additional launcher settings)

* r25182 (BUG: Extension packaging: Support fixup of 3rd-party (external
  proj) libs)

Revision 25941  Directory Listing
Modified Fri Apr 21 21:57:43 2017 UTC (5 months ago) by ihnorton
ENH: add module to PYTHONPATH during instantiation

Allows python modules to depend on resources provided by other modules.

ref: https://github.com/Slicer/Slicer/pull/705
ref: https://discourse.slicer.org/t/scripted-module-dependency-loaded-too-late-for-one-module-but-for-another-one-not/142

from jcfr:

Instantiation is done in arbitrary order but the "loading" of each module is done based on the dependency graph captured by the dependencies property:

instantiateModules loops over the keys alphabetically,
Each module is instantiated in the order of the key,

```
foreach (const QString& moduleName, d->RegisteredModules.keys())
{
```

then instantiateModule for each module will collect the dependent modules

See https://github.com/Slicer/Slicer/blob/eefeac9286f48552e8418a11f412b2823a09b407/Base/QTCore/qSlicerAbstractModuleFactoryManager.cxx#L394-L424

which are later loaded in the right order:

```
  // Load the modules the module depends on.
  // There is no cycle check, so be careful
  foreach(const QString& dependency, instance->dependencies())
    {
    // no-op if the module is already loaded
    bool dependencyLoaded = this->loadModule(dependency, name);
    if (!dependencyLoaded)
      {
      qWarning() << "When loading module " << name << ", the dependency"
                 << dependency << "failed to be loaded.";
      return false;
      }
}
```

Revision 25894  Directory Listing
Modified Fri Mar 31 13:07:11 2017 UTC (5 months, 3 weeks ago) by pinter
BUG: Fixed CLI subject hierarchy crash with no reference node

Revision 25885  Directory Listing
Modified Tue Mar 28 18:37:17 2017 UTC (5 months, 4 weeks ago) by pieper
COMP: avoid undefined symbol in Qt5 with Q_ASSERT

Apparently in Qt4 built in release mode Q_ASSERT is a noop in
release mode so the compiler never sees the variable.
But Qt5 there is a compile error about missing variable 'd'.

From: Steve Pieper <pieper@isomics.com>

Revision 25829  Directory Listing
Modified Mon Mar 13 13:00:11 2017 UTC (6 months, 1 week ago) by jcfr
STYLE: Fix style of ITK classes using KWStyle

This commit introduced the style Utilities/KWStyle/ITK.kws.xml based of
the official ITK Style.

Style was checked using the following command:

  for file in $(find . | ack-grep "\/itk.+(h|cpp|txx|cxx)$"); do
    KWStyle -gcc -xml ./Utilities/KWStyle/ITK.kws.xml $file;
  done

KWStyle was built from source: https://github.com/Kitware/KWStyle

The following errors remain:

  ./Modules/CLI/ExpertAutomatedRegistration/ITKRegistrationHelper/itkAnisotropicSimilarity3DTransform.h:109: error: Internal variable (itk::Rigid3DTransform<TScalarType>::SetMatrix) doesn't match regular expression (m_[A-Z])
  ./Modules/CLI/ResampleDTIVolume/Testing/itkTestMainExtended.h:17: error: namespace not defined

Revision 25826  Directory Listing
Modified Mon Mar 13 12:59:55 2017 UTC (6 months, 1 week ago) by jcfr
STYLE: Remove double underscore in header guards (.h & __itk*_h form)

Used the following command:

find . \( -iname *.h -and -type f \) -exec perl -pi -w -e 's/__itk(.*)_h/itk$1_h/g;' {} \;

Fixes many, but not all, clang -Wreserved-id-macro warnings.

Adapted from scripts created by Sean McBride <sean@rogue-research.com> to
update ITK and VTK code base.

Revision 25823  Directory Listing
Modified Mon Mar 13 04:05:02 2017 UTC (6 months, 1 week ago) by jcfr
STYLE: qSlicerExtensionsManagerModel: Remove unused function appendToPathList

Revision 25809  Directory Listing
Modified Sun Mar 12 19:44:04 2017 UTC (6 months, 2 weeks ago) by jcfr
COMP: vtkTransformVisualizerGlyph3D: Fix -Wunused-const-variable warning

Revision 25808  Directory Listing
Modified Sun Mar 12 19:44:03 2017 UTC (6 months, 2 weeks ago) by jcfr
COMP: vtkSlicerApplicationLogic: Fix -Wself-assign warning

Revision 25799  Directory Listing
Modified Sun Mar 12 19:43:43 2017 UTC (6 months, 2 weeks ago) by jcfr
COMP: Fix unused variable warnings

Revision 25777  Directory Listing
Modified Fri Mar 10 16:46:19 2017 UTC (6 months, 2 weeks ago) by pinter
ENH: Changed invalid subject hierarchy item ID to 0 for easier checking

Revision 25751  Directory Listing
Modified Tue Mar 7 20:44:02 2017 UTC (6 months, 2 weeks ago) by pinter
ENH: Added long needed basic features made possible by new subject hierarchy design

- Re-ordering and expanded state are saved in the items, and restored on update
- Root item handling
- Subject hierarchy python scripted plugins
- Various bugfixes related to the above features and subject hierarchy core

-----------------------------------------------
Details:

BUG: Fixed subject hierarchy tree root item handling

ENH: Re-select items after drag&drop in subject hierarchy

BUG: Fixed subject hierarchy Register plugin

BUG: Fixed subject hierarchy reordering

It failed when an item was moved up not down

BUG: Fixed issues related to deleting subject hierarchy items

Also fixed the feature in DICOM plugin for converting folders into patients and studies

BUG: Fixed segmentation reparenting and visibility icon updates in SH

BUG: Fixed show/hide in subject hierarchy

ENH: Simplified creating subject hierarchy items

Instead of the Swiss army knife function that could be used to create subject hierarchy items for both data nodes and hierarchies (folder, study, etc.) there are two separate methods for CreateItem. One for creating the pure hierarchy items (folder etc.) and the other for the ones corresponding to data nodes. The latter is for internal use and should not be called.

Also fixed basic DICOM loading

ENH: Deploy scripted plugin in SubjectHierarchyPlugins folder

Previous commit deployed them in individual folders, but for consistency and simplicity, a common folder is better. It is achieved by having the __init__ script import all plugin python files dynamically

ENH: Added python scripted subject hierarchy plugins

For SegmentEditor (that replaces the core SegmentPlugin) and SegmentStatistics. Both are mostly sample plugins, to demonstrate how to write scripted plugins, and as a proof of concept for multiple scripted plugins built.
The reason why SegmentEditorSubjectHierarchyPlugins subfolder was chosen for source and install path: 1. If the plugin is added with the module file, it is attempted to be recognized as a module and will throw error 2. If a common SubjectHierarchyPlugins folder is created in each module having a scripted plugin, the __init__ files are not merged, but the last one overwrites the previous ones, and only one plugin is exposed.

ENH: Added subject hierarchy item info in SH module widget

It contains a label that displays the item's self print string.
Level and owner plugin info was removed from the tooltip, as the info box shows that, and it's not needed for normal usage (mostly for debugging)

BUG: Root item restored after complete subject hierarchy update

ENH: Subject hierarchy item expanded state handling added

BUG: Prevent crash when closing Slicer

BUG: Allow dropping subject hierarchy items on empty area

In which case it is reparented under the scene

ENH: Added item reordering support

Also fixed model update when item is reparented programmatically

Revision 25750  Directory Listing
Modified Tue Mar 7 20:37:27 2017 UTC (6 months, 2 weeks ago) by pinter
BUG: Initial bugfixes in subject hierarchy 2.0

-----------------------------------------------
Details:

BUG: Fixed item drag&drop in subject hierarchy tree

Implemented PrintSelf for subject hierarchy node

BUG: Enable python wrapping of SH functions by changing the ID type

The typedef that mapped vtkIdType to SubjectHierarchyItemID was not propagated to python, so the functions that had such an argument were not wrapped. Now vtkIdType is used directly instead.

Qt functions having vtkIdType arguments still cannot be called from python. Error similar to the one below occurs:
"ValueError: Called setRootItem(vtkIdType itemID) with wrong arguments: (0,)"

BUG: Plugin ownership, selection, context menu, and reparenting related fixes

BUG: Scene closing related fix and other small fixes

BUG: Basic fixes in refactored subject hierarchy

Revision 25749  Directory Listing
Modified Tue Mar 7 20:32:06 2017 UTC (6 months, 2 weeks ago) by pinter
ENH: Created single-node subject hierarchy mechanism, updated modules to build using it

-----------------------------------------------
Details:

ENH: Updated remaining classes. Build succeeds

ENH: Update subject hierarchy plugins and fix build errors

ENH: Subject hierarchy core builds alright

ENH: Updated SH tree view

Also moved model classes back to the module because they use SH specific functions (logic, etc.)

ENH: Updated SH proxy model and progress with new tree view

ENH: Automatic subject hierarchy creation and event processing

ENH: Subject hierarchy logic and plugin handler updated

to use new node and items

ENH: Added new subject hierarchy model WIP

New qMRMLSubjectHierarchyModel class added that will use the new subject hierarchy node for the data model. Removed AutoCreateSubjectHierarchy option from application settings, as it won't be needed with the new model in place. Subject hierarchy abstract plugin updated for new subject hierarchy node and items.

Remaining tasks: Subject hierarchy logic, all plugin classes, tree view, CLI support, extensions using SH, new SH features (model hierarchy support, reordering, expand state preservation, filtering in tree view by name)

ENH: Re-wrote vtkMRMLSubjectHierarchyNode to contain the whole tree WIP

The new subject hierarchy node contains the whole tree instead of representing an item in the tree. The advantages:
- No node duplication for the data nodes, only one extra node is in the scene. This means that SH can be turned on by default, so the extra step of enabling it will not be necessary
- No nested associations to support multiple types of hierarchies (mainly model hierarchy). Subject hierarchy will be able to co-exist with other hierarchies more easily, and those hierarchies can be imported into SH, so for example atlases can be used from SH
- Option to re-order nodes in the tree
- No subject hierarchy postfix in node names, thus decreased complexity and chance for error

Revision 25674  Directory Listing
Modified Fri Jan 27 15:45:04 2017 UTC (7 months, 4 weeks ago) by lassoan
ENH: Made Add data dialog more keyboard-friendly

It was very inconvenient that after drag-and-dropping or selecting data for loading in "Add data" dialog, user had to click on OK button.
Hitting Enter key opened the "Add directory" window instead of loading the data.

Changed behavior so that Enter always loads the listed data sets.

Hitting space bar clicks the button that has the focus. If somebody wants to load multiple files, then after a file is selected for loading
the user has to hit space bar to add more files. Once all the files are selected the user hits Enter key.

Revision 25655  Directory Listing
Modified Tue Jan 24 02:57:22 2017 UTC (8 months ago) by jcfr
BUG: qSlicerSettingsModulesPanel: Nicely expand vertically. Fixes #4324

Modules panel in settings dialog now expands nicely in the vertical direction
when the settings dialog is expanded

From: Adam Rankin <arankin@robarts.ca>

Revision 25646  Directory Listing
Modified Sat Jan 21 23:04:24 2017 UTC (8 months ago) by lassoan
ENH: Added CLI output display to module widget

Problem:
It is often difficult to find out why a CLI failed or get detailed output.
(user would need to open the log window and find the messages in the log,
but most users don't even know that there is a log window).

Solution:

Expand button is added next to the status message.
User can click there to show/hide all details.
Error output is displayed in red, at the top. Standard output is displayed black.
Window is automatically sized to show all content with minimal need for scrolling.

If CLI completes with errors, error output is displayed regardless of show/hide details choice.

Revision 25622  Directory Listing
Modified Fri Dec 23 15:40:15 2016 UTC (9 months ago) by lassoan
BUG: Fixed crash in scene view node saving

Revision 25614  Directory Listing
Modified Tue Dec 20 20:17:43 2016 UTC (9 months ago) by naucoin
ENH: Add missing python load utility methods

The python utility file was missing methods to load Annotation
rulers and ROIs, this change adds:
loadAnnotationRuler('ruler.acsv')
loadAnnotationROI('box.acsv')

Issue #4319

Revision 25613  Directory Listing
Modified Tue Dec 20 02:27:07 2016 UTC (9 months ago) by lassoan
BUG: Fixed file extension extraction logic

For transform file sometransform_version2.0_some.h5 it returned .0_some.h5 as extension (instead of the correct .h5).

Solution: wildcard matching is only used if no specific extension is matched.

Revision 25596  Directory Listing
Modified Thu Dec 8 21:10:42 2016 UTC (9 months, 2 weeks ago) by johan.andruejol
ENH: Add util methods for easier programming of python widgets

LoadUI() allows to create a widget from a .ui file and findChild() allows
quick access to a particular widget by name.

Revision 25595  Directory Listing
Modified Thu Dec 8 21:09:27 2016 UTC (9 months, 2 weeks ago) by johan.andruejol
ENH: Add util method to set and fit slice views in python

Also add testing for those methods.

Revision 25593  Directory Listing
Modified Thu Dec 8 20:31:46 2016 UTC (9 months, 2 weeks ago) by jcfr
STYLE: ExtensionsManagerModel: Refactor to ease reuse of isExtensionCompatible

Revision 25592  Directory Listing
Modified Thu Dec 8 20:31:45 2016 UTC (9 months, 2 weeks ago) by jcfr
STYLE: ExtensionsManagerModel: Fix typo in doxygen comments

Revision 25590  Directory Listing
Modified Wed Dec 7 19:45:00 2016 UTC (9 months, 2 weeks ago) by lassoan
ENH: Moved clickAndDrag to slicer.util

It is more accessible there.
Removed duplicates of clickAndDrag in other modules, now all of them use the one in slicer.util.

Revision 25571  Directory Listing
Modified Tue Nov 22 22:51:33 2016 UTC (10 months ago) by jcfr
ENH: Add python cli automating versioning of Slicer wiki documentation

See https://www.slicer.org/wiki/Documentation/Nightly/Developers/ReleaseProcess#Update_Slicer_wiki

```
$ python wiki.py --help
usage: wiki.py [-h] [--log-level LOG_LEVEL] [--password PASSWORD]
               {query,copy,update} ...

This command-line tool allows to `version` Slicer mediawiki documentation. It
has three main modes of operation: ``query``, `copy` and ``update``.

positional arguments:
  {query,copy,update}   available sub-commands
    query               obtain version information
    copy                copy Nightly pages into RELEASE_VERSION namespace
    update              create and/or update wiki pages with RELEASE_VERSION

optional arguments:
  -h, --help            show this help message and exit
  --log-level LOG_LEVEL
                        Level of debug verbosity. DEBUG, INFO, WARNING, ERROR,
                        CRITICAL.
  --password PASSWORD   password for 'UpdateBot' user. By default, try to get
                        password from 'SLICER_WIKI_UPDATEBOT_PWD' environment
                        variable.
```

Revision 25551  Directory Listing
Modified Fri Nov 18 18:44:48 2016 UTC (10 months ago) by lassoan
ENH: Allow display transform glyphs at markup positions

It is now possible to show where a markup point is transformed to using transform visualization.
Select "Glyph" visualization mode, open "Advanced" section and set "Source points".
Glyphs are updated in real-time as markups are moved, so this can be also used for probing the transformation
by drag-and-dropping markups in 2D and 3D views.

Transform logic needed access to Markups node, therefore module logic was moved to Modules/Loadable/Transforms/Logic.

Revision 25550  Directory Listing
Modified Fri Nov 18 07:56:26 2016 UTC (10 months, 1 week ago) by jcfr
STYLE: Fix spelling 'additonal' -> 'additional'

From: Isaiah Norton <inorton@bwh.harvard.edu>

Revision 25529  Directory Listing
Modified Sat Nov 12 08:29:06 2016 UTC (10 months, 1 week ago) by jcfr
BUG: Fix qSlicerSslTest accounting for updated redirect to https://slicer.org

(1) The HTTP code has been changed from "302 Found" to "301 Moved Permanently"

    See https://en.wikipedia.org/wiki/HTTP_302 and https://en.wikipedia.org/wiki/HTTP_301

(2) Accessing https://slicer.org does not return SSL error anymore.
    Thanks to "eQuality Technology <info@equality-tech.com>", the SSL
    certificates are kept up-to-date with "certbot-auto" and the grade
    returned by SSL Labs is A (for the sites:
     https://www.ssllabs.com/ssltest/analyze.html?d=slicer.org
     https://www.ssllabs.com/ssltest/analyze.html?d=www.slicer.org
     https://www.ssllabs.com/ssltest/analyze.html?d=wiki.slicer.org

Thanks: eQuality Technology <info@equality-tech.com>

Revision 25521  Directory Listing
Modified Fri Nov 11 14:58:23 2016 UTC (10 months, 1 week ago) by lassoan
ENH: Improved crosshair usability, added display in 3D view

Crosshair had several problems/limitations:
1. Crosshair position was often inconsistent in different slice views (for example: when in navigation view, crosshair was always displayed in all slice views because otherwise the user could not drag the crosshair to a new position; but this way when the user changed slices then the crosshair showed different RAS positions in each slice view)
2. Navigation mode was very inconvenient: to jump all slices to a specific RAS position the user had to position the mouse to the previous crosshair and drag it to the new position (it was too easy to miss the small navigation area in the middle and when it was missed, brightness/contrast of the image was accidentally modified)
3. By default (if the user just toggled the crosshair button on the toolbar), crosshair was only visible in the current slice view, which was useless (the crosshair just followed the mouse in the current view)
4. Crosshair position was not visible in 3D view

Solution implemented:
1. Only show crosshair in the correct position in all views. If crosshair position is not in the current slice then hide the crosshair from current slice.
2. Crosshair is now moved by holding down shift + moving mouse. No need to grab the previous crosshair position. Navigation mode is replaced by "jump slices" option (enabled by default), which controls if slice views should jump to current crosshair position. If disabled then shift + moving mouse only moves the crosshair.
3. By default slices jump to current crosshair position, so crosshair is visible in all views. User just has to keep Shift key depressed (added hint to tooltip)
4. Implemented display of crosshair in 3D view.

Revision 25504  Directory Listing
Modified Mon Nov 7 18:52:12 2016 UTC (10 months, 2 weeks ago) by jcfr
ENH: release/midasdata: Re-use destination folder if it already exists

Revision 25498  Directory Listing
Modified Wed Nov 2 19:06:35 2016 UTC (10 months, 3 weeks ago) by lassoan
BUG: Fixed DataProbe when slicer starts up with a chart in the layout

Problem: If Slicer starts up with a quantitative layout (that contains a chart view)
then DataProbe widget does not work.

Root cause: Chart view has a QUndoStack object that breaks slicer.util.findChildren.

Fix: Made slicer.util.findChildren more robust to presence of non-string attributes.

Revision 25486  Directory Listing
Modified Fri Oct 28 23:03:02 2016 UTC (10 months, 3 weeks ago) by lassoan
BUG: Fixed regression in slicerrc file loading

There was a missing import.

Revision 25479  Directory Listing
Modified Wed Oct 26 16:20:55 2016 UTC (10 months, 4 weeks ago) by lassoan
ENH: Made slicer startip script more discoverable

Show slicerrc file location in application settings and add a button to open it.
If the file does not exist then a default file is created.

Revision 25464  Directory Listing
Modified Thu Oct 20 13:10:27 2016 UTC (11 months ago) by lassoan
ENH: Added Edit button to Reload&test area

It is now simpler to open a scripted module's source code in an editor.

Revision 25426  Directory Listing
Modified Wed Oct 12 04:57:56 2016 UTC (11 months, 1 week ago) by jcfr
STYLE: Remove commented code from qSlicerModulePanel

From: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

Revision 25423  Directory Listing
Modified Tue Oct 11 18:30:46 2016 UTC (11 months, 2 weeks ago) by msmolens
ENH: Update Qt link in about box

Revision 25416  Directory Listing
Modified Wed Oct 5 23:41:07 2016 UTC (11 months, 2 weeks ago) by jcfr
BUG: Introduce macro to set "Prefer CLI executable" settings default value

This commit fixes a regression introduced in r25404 (ENH: prefer executable
CLIs by default) and ensures the settings default value is consistently set.

Revision 25404  Directory Listing
Modified Mon Oct 3 20:01:44 2016 UTC (11 months, 3 weeks ago) by fedorov
ENH: prefer executable CLIs by default

This resolves a known issue with the application crashing while using modules
as shared libraries under certain circumstances.

Motivated by this thread:

http://slicer-devel.65872.n3.nabble.com/Slicer-crashes-when-running-registration-without-having-settings-set-to-quot-Prefer-Executable-CLIs--td4037245.html

Revision 25389  Directory Listing
Modified Thu Sep 22 21:15:02 2016 UTC (12 months ago) by lassoan
ENH: Made vtkMRMLStorageNode::GetFileNameWithoutExtension more convenient

It strips known file extensions, which simplifies its usage (no need for three separate steps of
getting the filename, getting known extension, and then removing the known extension).

Also cleaned up a workaround that was introduced to quickly fix this issue:
http://www.na-mic.org/Bug/view.php?id=3991

Revision 25382  Directory Listing
Modified Tue Sep 20 22:10:24 2016 UTC (12 months ago) by lassoan
BUG: Fixed Segment editor to not create unintended segmentation nodes

fixes http://na-mic.org/Mantis/view.php?id=4259

Revision 25372  Directory Listing
Modified Tue Sep 20 17:08:16 2016 UTC (12 months ago) by jcfr
ENH: Reorganized developer section buttons horizontally for saving space

From: Christian Herz <christianherz1985@gmail.com>

Revision 25371  Directory Listing
Modified Tue Sep 20 17:08:15 2016 UTC (12 months ago) by jcfr
ENH: Added "Restart Slicer" button into developer section

From: Christian Herz <christianherz1985@gmail.com>

Revision 25368  Directory Listing
Modified Sat Sep 17 18:36:39 2016 UTC (12 months, 1 week ago) by pieper
ENH: Add perceptually uniform color lookup tables

Add matplotlib's new perceptually uniform colormaps to Slicer default color lookup tables. Issue 4255

From: Fernando Perez-Garcia <fepegar@gmail.com>

Revision 25357  Directory Listing
Modified Wed Sep 14 01:09:50 2016 UTC (12 months, 1 week ago) by lassoan
ENH: Make it simpler to add doc link to Python scripted modules

Link to module documentation can be added to the help text by a single line of code:
self.parent.helpText += self.getDefaultModuleDocumentationLink()

Updated existing modules to take advantage of this new method.
Also updated a few additional modules to use the common scripted module template
to get access to this new getDefaultModuleDocumentationLink method.

Revision 25333  Directory Listing
Modified Thu Sep 8 16:23:02 2016 UTC (12 months, 2 weeks ago) by msmolens
COMP: Convert to vtkMTimeType for modified times to fix compile errors

https://gitlab.kitware.com/vtk/vtk/merge_requests/1790 ("ENH: Introduce
vtkMTimeType") adds vtkMTimeType as a typedef for vtkObject modified times,
replacing unsigned long. This commit updates Slicer to use the new type. This
fixes compile errors like:

    c:\path\to\slicer\libs\vtkteem\vtkDiffusionTensorGlyph.h(192): error C2555: 'vtkDiffusionTensorGlyph::GetMTime': overriding virtual function return type differs and is not covariant from 'vtkObject::GetMTime'

Revision 25331  Directory Listing
Modified Sat Sep 3 02:25:13 2016 UTC (12 months, 3 weeks ago) by lassoan
BUG: Fixed module factoryManager loadModules

When trying to load an unregistered module, caused Slicer to crash
slicer.app.moduleManager().factoryManager().loadModules(['nonexisting'])

Replaced assert by pointer check and added some more checks.

Revision 25330  Directory Listing
Modified Thu Sep 1 20:51:23 2016 UTC (12 months, 3 weeks ago) by lassoan
ENH: Implemented missing AddEnabled, NoneEnabled logic for CLI GUI

Revision 25329  Directory Listing
Modified Thu Sep 1 20:51:20 2016 UTC (12 months, 3 weeks ago) by lassoan
ENH: Added option of specifying general transform as CLI output

Earlier transform node was an abstract class, so it was not possible to create one as an output node.

Revision 25325  Directory Listing
Modified Wed Aug 31 15:29:59 2016 UTC (12 months, 3 weeks ago) by lassoan
BUG: Fixed non-saved node handling in scene save dialog

Storage nodes are not created anymore for nodes that will not be saved with the scene.
This avoids creation of unused storage nodes (and warnings during scene load).

Revision 25323  Directory Listing
Modified Wed Aug 31 15:29:51 2016 UTC (12 months, 3 weeks ago) by lassoan
ENH: Improved node saving and loading

This commit contains two changes, which might have been delivered as two separate commits, but they have been implemented at the same time
and modify the same files, therefore splitting them would be not easy.

1. Storable node can decide what is the most appropriate storage node, based on the requested file name and storable node content.

Implemented by adding vtkMRMLStorableNode::AddDefaultStorageNode, which creates most appropriate storage node class and adds it to the scene
(similarly to vtkMRMLDisplayableNode::CreateDisplayNodes()). Also added vtkMRMLStorableNode::GetDefaultStorageNodeClassName(), which allows
creating the right type of storage node depending on target filename and storable node content.

Now there is no more need for the model storage node "special case" in vtkSlicerApplicationLogic::ProcessReadNodeData.

Now current scene's CreateNodeInstance method can be used for storage node creation. The scene may contain customized default storage nodes
(e.g., storage node that uses a customized file extension or compression option), which are now taken into account.
For example, changing default model node saving extension can be achieved by this:

msn=slicer.vtkMRMLModelStorageNode()
msn.SetDefaultWriteFileExtension('stl')
slicer.mrmlScene.AddDefaultNode(msn)

Default nodes can be created from information stored in the application settings, so this allows
specifying default file saving format in the application settings (this is how default view options are configured already).

Having a method for creating and adding storage node as needed also simplifies vtkSlicerFiducialsLogic::AddFiducialList,
vtkMRMLColorNode::ReadXMLAttributes, vtkMRMLSceneViewNode::ReadXMLAttributes, vtkMRMLApplicationLogic::SaveSceneToSlicerDataBundleDirectory, etc.

2. Improved composite file extension support (.nii.gz, .seg.nrrd, ...)

Suitable file reader list in "Add data dialog" is populated using the most specific matched extension's reader.
For example, .nrrd is more specific than .*; .seg.nrrd is more specific than .nrrd. This allows correct deafult
selection. This allowed removing workarounds and special cases added for composite image file extensions (such as .nii.gz)
and .* wildcard. It also allows proper default selection for segmentation nodes (.seg.nrrd).
In the future, it could be used for removing workarounds added for guessing labelmaps, annotation ROI nodes, etc
(labelmap volumes could use .label.nrrd, annotation nodes could use something.roi.csv something.fid.csv, ... instead of
using ambiguous and/or non-standard file extensions such as .acsv or .fcsv).

Made file extension matching more robust: instead of using heuristics, such as assuming .gz means a composite file extension
and collecting all possible extension from all storage nodes; now extensions are verified/matched/removed by the specific
storage node that is responsible for reading/writing the node.

Revision 25317  Directory Listing
Modified Mon Aug 29 18:29:01 2016 UTC (12 months, 3 weeks ago) by lassoan
BUG: Fixed selection of output files in CLI module GUI

It was only possible to select an existing file as output file.
Also, supported file extensions were ignored.

Revision 25308  Directory Listing
Modified Wed Aug 24 14:46:27 2016 UTC (13 months ago) by lassoan
ENH: Added segmentation support to slicer.util.py

Added loadSegmentation() and openAddSegmentationDialog() utility scripts.

Revision 25287  Directory Listing
Modified Mon Aug 15 18:03:33 2016 UTC (13 months, 1 week ago) by jcfr
BUG: Fixed max allowed module widget size for HiDPI screens

The fixed 500px maximum width for widget minimum size hint is not applicable for HiDPI screens, where 500px corresponds to about 15% or less of the screen width.
Allow widget size to be max(500px, 30% of screen width).

From: Andras Lasso <lasso@queensu.ca>

Revision 25258  Directory Listing
Modified Tue Aug 2 20:37:14 2016 UTC (13 months, 3 weeks ago) by lassoan
BUG: Fixed crash when saving a scene after deleting storable nodes

How to reproduce: create a storable node (without storage node), create a scene view, delete the storable node, save the scene -> Slicer crashes.
The root cause of the problem was that missing storage node for was was added to the main scene instead of the scene view.

Storage node is now added to the correct scene and also replaced a few asserts by error handling to reduce chances of crashing during scene save.

Revision 25255  Directory Listing
Modified Fri Jul 29 20:07:02 2016 UTC (13 months, 3 weeks ago) by lassoan
ENH: Made Python interactor dockable window optional

In application settings Python section the user can now choose betwen dockable/standalone window.
Also made the Python Interactor toolbar button and menu item checkable.

Revision 25249  Directory Listing
Modified Thu Jul 28 13:55:36 2016 UTC (13 months, 4 weeks ago) by lassoan
ENH: Added getNodesByClass Python utility method

It returns all nodes of a certain class in a python list.

Revision 25248  Directory Listing
Modified Wed Jul 27 21:29:57 2016 UTC (13 months, 4 weeks ago) by lassoan
ENH: Made Python interactor a docking widget

Problem:
 It was always necessary to rearrange windows after showing the Python interactor so that both the console and Slicer screen.
 This has to be repeated every time Slicer is started, since the Python interactor window's position was not saved.

Implemented solution:

1.Made Python interactor a docking widget (if Slicer starts with main window visible).
 For single-screen configuration this allows sharing of the screen between the Python interactor and other Slicer windows.
 On multi-screen configurations the interactor can be dragged to the second screen.

2.The position (which screen, where), size, and state (docked/undocked, shown/hidden) of the Python interactor window is now also saved,
 so there is no need for any repositioning of the windows between sessions.

3.Ctrl-3 shows/hides the interactor (not just shows as before) and when the interactor is shown it gets keyboard focus.
 It allows easy opening of the interactor, typing some text, and closing it, without the need of taking the mouse to reposition
 any windows.

Also cleaned up deletion of ctkPythonConsole. As the ctkPythonConsole widget can be owned by a widget (docking window), it is not
 possible to create it on the stack anymore. Instead, qSlicerApplication creates the ctkPythonConsole (similarly to qSlicerPythonManager)
 and destroys it if it is not owned by a widget.

Revision 25236  Directory Listing
Modified Thu Jul 14 05:26:16 2016 UTC (14 months, 1 week ago) by jcfr
ENH: Update Slicer.crt

This commit implements the following changes:

* updates make-ca.sh and make-cert.pl script considering latest
  version provided by BLFS:
  http://www.linuxfromscratch.org/blfs/view/svn/postlfs/cacerts.html

* updates the scripts to work with version of certdata.txt not having CVS_ID

* improves make-ca.sh to that it can be called from any dictory

* updates README file

* re-generate Slicer.crt

Revision 25235  Directory Listing
Modified Tue Jul 12 15:13:38 2016 UTC (14 months, 2 weeks ago) by jcfr
ENH: qSlicerCLILoadableModuleFactory: Print CTK QLibrary load error messages

From: Isaiah Norton <inorton@bwh.harvard.edu>

Revision 25226  Directory Listing
Modified Fri Jul 8 17:53:40 2016 UTC (14 months, 2 weeks ago) by msmolens
BUG: Update vtkObject Tcl variable name generation for VTK 7

This commit ensures that Tcl variable names generated for vtkObjects are valid
with VTK 7.

In VTK 7, the repr() of vtkObjects now includes the module name in addition to
the class name and memory address. By replacing the period separating the module
name and class name and removing the parentheses, we ensure that the returned
name is valid for a Tcl variable.

This fixes the following tests:

    EMSegCL_IntermediateResults
    EMSegCL_RunDefaultNodes
    EMSegCL_RunSetEverything
    EMSegCL_Task_BRAINS_MRIHumanBrain_scalartype_float_very_small
    EMSegCL_Task_BRAINS_MRIHumanBrain_scalartype_uint_very_small
    EMSegCL_Task_HumanEye_BRAINS_small
    EMSegCL_Task_MRIHumanBrainExp_BRAINS_small
    EMSegCL_Task_MRIHumanBrainFullParcellation_BRAINS_small
    EMSegCL_Task_MRIHumanBrainParcellation_BRAINS_small
    EMSegCL_Task_MRIHumanBrain_2CH
    EMSegCL_Task_MRIHumanBrain_BRAINS_small
    EMSegCL_Task_NonHumanPrimate_BRAINS_small

Revision 25225  Directory Listing
Modified Fri Jul 8 17:53:39 2016 UTC (14 months, 2 weeks ago) by msmolens
COMP: Update importing of wrapped VTK classes for VTK 7

Python wrapped objects in VTK 7 are now new-style Python classes. Subsequently,
the type of a wrapped class is now the built-in 'type', whereas in VTK 6 it was
'vtkclass'. Compare the following output for VTK 6 and VTK 7:

    >>> vtk.VTK_MAJOR_VERSION, type(vtk.vtkObjectBase)
    (6, <type 'vtkclass'>)

    >>> vtk.VTK_MAJOR_VERSION, type(vtk.vtkObjectBase)
    (7, <type 'type'>)

This commit updates the importing of wrapped VTK classes to account for the new
behavior. Instead of checking for the type name to equal 'vtkclass', importing
now checks whether the type is a subclass of vtkObjectBase.

Revision 25205  Directory Listing
Modified Mon Jul 4 21:53:51 2016 UTC (14 months, 3 weeks ago) by jcfr
STYLE: Facilitate re-use of vtkImageFillROI relocating to Base/Logic

Anticipating the re-use of the class by other C++ module, this commit
moves the class to Base/Logic.

From: Csaba Pinter <csaba.pinter@queensu.ca>

Revision 25204  Directory Listing
Modified Mon Jul 4 21:53:48 2016 UTC (14 months, 3 weeks ago) by jcfr
STYLE: qSlicerDirectoryListView: Fix unused variable warning

From: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

Revision 25192  Directory Listing
Modified Tue Jun 14 00:12:06 2016 UTC (15 months, 1 week ago) by jcfr
STYLE: Add vtkSlicerVersionConfigureTest1

Revision 25176  Directory Listing
Modified Thu Jun 9 02:53:09 2016 UTC (15 months, 2 weeks ago) by jcfr
STYLE: slicer.util.getFirstNodeByName: Extend test case.

From: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

Revision 25175  Directory Listing
Modified Thu Jun 9 02:53:07 2016 UTC (15 months, 2 weeks ago) by jcfr
BUG: slicer.util.getFirstNodeByName: Should not return only visible nodes

This commits updates "getFirstNodeByName()" to leverage changes
integrated in r25160 (ENH: Update VTK to handle default values
for array parameters in python)

Now wrapping of methods with pointer parameter having a NULL default value
are supported, there is no need to hardcode the value of "byHideFromEditors"
to either [0] or [1].

From: Francois Budin <francois.budin@gmail.com>

Revision 25174  Directory Listing
Modified Thu Jun 9 02:53:06 2016 UTC (15 months, 2 weeks ago) by jcfr
BUG: Fix test_getNodesMultipleNodesSharingName. See #4186

This commit fixes a regression introduced in r25155 (BUG: slicer.util.GetNodes:
Support multiple node with same name. Fix #4186) by properly adding the
nodes sharing the same name.

From: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

Revision 25169  Directory Listing
Modified Wed Jun 8 15:53:06 2016 UTC (15 months, 2 weeks ago) by alexy
BUG: 4204. Fixed output CLI parameters <file> and <directory> so that users are able to enter file/directory names.

Revision 25158  Directory Listing
Modified Fri Jun 3 20:38:17 2016 UTC (15 months, 3 weeks ago) by jcfr
STYLE: vtkMRMLSliceNode: Keep reference to matrix using smart pointers

Co-authored-by: Davide Punzo <punzodavide@hotmail.it>
Suggested-by: Andras Lasso <lasso@queensu.ca>

Revision 25156  Directory Listing
Modified Fri Jun 3 05:16:13 2016 UTC (15 months, 3 weeks ago) by jcfr
STYLE: slicer.util.getFirstNodeByName: Refactor code to use C++ implementation

From: Francois Budin <francois.budin@gmail.com>

Revision 25155  Directory Listing
Modified Fri Jun 3 05:16:11 2016 UTC (15 months, 3 weeks ago) by jcfr
BUG: slicer.util.GetNodes: Support multiple node with same name. Fix #4186

If multiple nodes share the same name, only the last node with that name
will be returned. A new parameter has been added to return a dictionary
containing, for each node name, a list of nodes, to avoid returning only
the last node with a specific name.

From: Francois Budin <francois.budin@gmail.com>

Revision 25154  Directory Listing
Modified Fri Jun 3 05:16:09 2016 UTC (15 months, 3 weeks ago) by jcfr
STYLE: getNodes test: Improve error reporting using specific assert

From: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

Revision 25153  Directory Listing
Modified Fri Jun 3 05:16:07 2016 UTC (15 months, 3 weeks ago) by jcfr
BUG: slicer.util.getNodes/getNode: Keep dict entry ordered. See #4201

Since method "getNode()" allows to specify an index parameter
corresponding to the index in the scene,  it is importent to keep
the dictionary entries ordered.

co-authored-by: Francois Budin <francois.budin@gmail.com>

From: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

Revision 25150  Directory Listing
Modified Fri Jun 3 03:40:03 2016 UTC (15 months, 3 weeks ago) by jcfr
BUG: Fix LandmarkRegistration test updating slicer.util.getNode. See #4201

This commit fixes a regression introduced in r25140 (BUG: slicer.util.getNodes:
Return MRML nodes by default. Fixes #4201)

The method "getNode()" should *NOT* return a node if an empty pattern
is provided.

Revision 25149  Directory Listing
Modified Thu Jun 2 06:49:25 2016 UTC (15 months, 3 weeks ago) by jcfr
ENH: Add option "--application-information"

By default, do not print application information to standard output, only
log it to file.

If the application is started with `--application-information`, information
will also be displayed in the terminal.

To remain consistent with existing option displaying information in
the terminal (e.g --home, --settings-path, ...), the option has been
named "--application-information".

Revision 25148  Directory Listing
Modified Thu Jun 2 06:49:22 2016 UTC (15 months, 3 weeks ago) by jcfr
STYLE: Fix typo in displayApplicationInformation function name.

"In native-speaker norms, information is a non-count noun, so the
convention is that information is both singular and plural."
Source: http://english.stackexchange.com/questions/117552/why-does-information-not-have-a-plural-form

Revision 25146  Directory Listing
Modified Thu Jun 2 03:24:43 2016 UTC (15 months, 3 weeks ago) by jcfr
BUG: Remove duplicate file browse button for CLI UIs. Fixes #2763

The regression was originally introduced in commontk/CTK@0de5ad0
where ctkPathLineEdit was enhanced with a browse button visible
by default.

From: Tim Thirion <tim.thirion@kitware.com>

Revision 25142  Directory Listing
Modified Wed Jun 1 19:24:56 2016 UTC (15 months, 3 weeks ago) by jcfr
BUG: Fix display of CPU properties in application info. Fixes #4176

Instead of explicitly computing the frequency and displaying the number
of cores, this commit updates the function "qSlicerApplication::displayApplicationInformations"
to:

 * display the model name: The model name provides CPU vendor specific model and clock
   frequency in GHz.

 * the number of logical processors.

Since the processor has a variable frequency (e.g. from 2.90GHz to 3.8 GHz
for the Intel E3-1535M), calling "GetProcessorClockFrequency()"
was returning a different result for each call.

Before:
CPU ......................: GenuineIntel 3.579 MHz, 1 cores

After:
CPU ......................: GenuineIntel Intel(R) Xeon(R) CPU E3-1535M v5 @ 2.90GHz, 1 cores, 8 logical processors

Co-authored-by: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

From: Sankhesh Jhaveri <sankhesh.jhaveri@kitware.com>

Revision 25141  Directory Listing
Modified Wed Jun 1 19:24:55 2016 UTC (15 months, 3 weeks ago) by jcfr
ENH: vtkSystemInformation: Add API to retrieve processor model name

vtkSystemInformation can now be queried for CPU model name along
with vendor. This reports the actual model type along with the
clock frequency on most systems.

See #4176

From: Sankhesh Jhaveri <sankhesh.jhaveri@kitware.com>

Revision 25140  Directory Listing
Modified Wed Jun 1 16:28:14 2016 UTC (15 months, 3 weeks ago) by jcfr
BUG: slicer.util.getNodes: Return MRML nodes by default. Fixes #4201

From: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

Revision 25137  Directory Listing
Modified Tue May 31 21:21:10 2016 UTC (15 months, 3 weeks ago) by jcfr
BUG: Ensure extension python wrapped modules can be loaded

This commit fixes a regression introduced in r25128 (STYLE: Simplify
import of Logic/MRML/DisplayableManager python modules)

Reported-by: Andras Lasso <lasso@queensu.ca>

Revision 25136  Directory Listing
Modified Tue May 31 17:39:39 2016 UTC (15 months, 3 weeks ago) by lassoan
BUG: Fixed missing slicer namespace in SlicerApplicationLogHandler

Revision 25128  Directory Listing
Modified Tue May 31 06:11:35 2016 UTC (15 months, 3 weeks ago) by jcfr
STYLE: Simplify import of Logic/MRML/DisplayableManager python modules

Instead of creating intermediate python scripts, this commit updates
loadable modules wrapping and import mechanism to directly use the
shared library.

The management of PythonQt and VTK*Python module is now identical.

Revision 25127  Directory Listing
Modified Tue May 31 06:11:33 2016 UTC (15 months, 3 weeks ago) by jcfr
STYLE: Do not explicitly import "freesurfer" into "slicer" module

FreeSurfer classes are expected to be used by explicitly importing the
module.

The classes are not used in either Slicer core or any of the extensions
available in the extensions index.

Slicer core:

$ for class in $(ls -1 ./Libs/FreeSurfer/vtk*.h | cut -d"/" -f4 | cut -d"." -f1); do echo "Looking for $class [$(pwd)]"; ack --py $class; done
Looking for vtkFreeSurferWin32Header [/home/jcfr/Projects/Slicer]
Looking for vtkFSIO [/home/jcfr/Projects/Slicer]
Looking for vtkFSLookupTable [/home/jcfr/Projects/Slicer]
Looking for vtkFSSurfaceAnnotationReader [/home/jcfr/Projects/Slicer]
Looking for vtkFSSurfaceHelper [/home/jcfr/Projects/Slicer]
Looking for vtkFSSurfaceLabelReader [/home/jcfr/Projects/Slicer]
Looking for vtkFSSurfaceReader [/home/jcfr/Projects/Slicer]
Looking for vtkFSSurfaceScalarReader [/home/jcfr/Projects/Slicer]
Looking for vtkFSSurfaceWFileReader [/home/jcfr/Projects/Slicer]


Extensions:

$ for class in $(cd /home/kitware/Dashboards/Nightly/Slicer-0; ls -1 ./Libs/FreeSurfer/vtk*.h | cut -d"/" -f4 | cut -d"." -f1); do echo "Looking for $class [$(pwd)]"; ack-grep --py $class; done
Looking for vtkFreeSurferWin32Header [/home/kitware/Dashboards/Nightly/S-0-E-b]
Looking for vtkFSIO [/home/kitware/Dashboards/Nightly/S-0-E-b]
Looking for vtkFSLookupTable [/home/kitware/Dashboards/Nightly/S-0-E-b]
Looking for vtkFSSurfaceAnnotationReader [/home/kitware/Dashboards/Nightly/S-0-E-b]
Looking for vtkFSSurfaceHelper [/home/kitware/Dashboards/Nightly/S-0-E-b]
Looking for vtkFSSurfaceLabelReader [/home/kitware/Dashboards/Nightly/S-0-E-b]
Looking for vtkFSSurfaceReader [/home/kitware/Dashboards/Nightly/S-0-E-b]
Looking for vtkFSSurfaceScalarReader [/home/kitware/Dashboards/Nightly/S-0-E-b]
Looking for vtkFSSurfaceWFileReader [/home/kitware/Dashboards/Nightly/S-0-E-b]

Revision 25125  Directory Listing
Modified Tue May 31 06:11:29 2016 UTC (15 months, 3 weeks ago) by jcfr
STYLE: slicer/__init__: Improve comments

Revision 25124  Directory Listing
Modified Tue May 31 06:11:26 2016 UTC (15 months, 3 weeks ago) by jcfr
STYLE: Relocate logging initialization from slicer/__init__ to slicerqt.py

Relocate configuration of the application loggers into the application
initialization script. This is done anticipating the possible introduction
of lazy loading of slicer module attributes.

Revision 25122  Directory Listing
Modified Thu May 26 23:29:34 2016 UTC (15 months, 4 weeks ago) by jcfr
BUG: Fix loading of PythonQt module from visual studio build tree

This commit fixes a regression introduced in r25115 (STYLE: Simplify
loading of loadable module python modules)

Module like "qSlicer*PythonQt.*" are built in the intermediate directory.

Thanks: Andras Lasso <lasso@queensu.ca>
Thanks: Csaba Pinter <csaba.pinter@queensu.ca>

Revision 25121  Directory Listing
Modified Thu May 26 22:34:47 2016 UTC (16 months ago) by jcfr
STYLE: slicerqt-with-tcl: Remove redundant 'mrmlLogic' package

mrmlLogic is already included in mrml.py

Revision 25120  Directory Listing
Modified Thu May 26 22:28:50 2016 UTC (16 months ago) by jcfr
STYLE: Remove redundant modules 'mrmlLogic' and 'mrmlcli'

These modules are already imported in mrml.py

Revision 25119  Directory Listing
Modified Wed May 25 19:46:00 2016 UTC (16 months ago) by jcfr
BUG: Fixes widget and logic python module loading regression

This commit fixes regressions introduced in r25115 and r25116.

* Ensure vtkSlicerCLIModuleLogic (in Base/QTCLI/) python wrapping is loaded.

* Update EMSegment to a version referencing python widget and logic
from the "slicer" namespace.

Reported-by: Andras Lasso <lasso@queensu.ca>

Revision 25117  Directory Listing
Modified Mon May 23 06:14:08 2016 UTC (16 months ago) by jcfr
PERF: Improve slicer.util.importModuleObjects to avoid repeat same file glob

To justify the added complexity, startup times has been measured
for the last 5 commits and, given the experimental setup, it confirms
that this commit slight reduce the startup time.

Results have been gathered on Ubuntu 15.10 on a workstation with the
following specs: 64GB / M.2 PCIe NVMe SSD / Quad Core 3.80GHz

For each commit, the performance have been measured by averaging
the startup time over 15 runs where disk has been flushed before each
run using:

  sudo sysctl vm.drop_caches=1

Results are the following:


* Baseline: ENH: MeasureStartupTimes: Add option to benchmark only regular startup
  5.19s

* Improvement 1: PERF: slicer.util.importClassesFromDirectory: Compile regex outside for loop
  5.18s

* Improvement 2: STYLE: slicer.util.importModuleObjects: Simplify code
  5.16s

* Improvement 3: STYLE: Simplify loading of loadable module python modules
  5.18s

* Improvement 4: PERF: Import loadable module python extension only into 'slicer' module
  5.19s

* Improvement 5: [THIS COMMIT]
  5.07s


Automatic collection of stats have been done using shell script
including code like this one:

8<--8<--8<--8<--8<--8<--8<--8<--8<--8<--8<--8<--8<--8<--8<--
what=improvement-5 &&
commit=1234567 &&
desc="PERF: Improve slicer.util.importModuleObjects to avoid repeat same file glob" &&

echo "" &&
echo "$what: $desc" &&
(cd ~/Projects/Slicer && git reset --hard $commit) &&
cmake . &&
make qSlicerBaseQTCore/fast  &&
make qSlicerBaseQTGUI/fast &&
make CopySlicerPythonScriptFiles/fast -B &&
make CompileSlicerPythonFiles/fast -B &&
(~/Projects/Slicer/Applications/SlicerApp/Testing/Python/MeasureStartupTimes.py --normal --drop-cache --repeat 15 ./Slicer) &&
cp ./StartupTimesNormal.json ./StartupTimesNormal-$what.json
8<--8<--8<--8<--8<--8<--8<--8<--8<--8<--8<--8<--8<--8<--8<--

Revision 25116  Directory Listing
Modified Mon May 23 06:14:06 2016 UTC (16 months ago) by jcfr
PERF: Import loadable module python extension only into 'slicer' module

Since the modules "slicer.moduledm", "slicer.modulelogic",  "slicer.modulemrml"
and "slicer.modulewidget" were not used, this commit removes them and avoid
the overhead of updating their respective dictionaries.

It is a follow up of r19775 (STYLE: Prevent future issue related to
refactoring by referencing all MRML node from 'slicer' module.).

Revision 25115  Directory Listing
Modified Mon May 23 06:14:03 2016 UTC (16 months ago) by jcfr
STYLE: Simplify loading of loadable module python modules

This commit removes the special case and ensures all loadable module
python dependencies (Logic, MRML, MRMLDisplayableManager and Widget) are
loaded using the method "qSlicerLoadableModule::importModulePythonExtensions".

Since prior to this change, moduledm, modulelogic, modulemrml and modulewidget
where imported into slicer from within slicer/__init__.py, this commit
updates "slicer.util.importModuleObjects" to explicitly add the classes
to the slicer module.

Revision 25114  Directory Listing
Modified Mon May 23 06:14:00 2016 UTC (16 months ago) by jcfr
STYLE: slicer.util.importModuleObjects: Simplify code

Revision 25113  Directory Listing
Modified Mon May 23 06:13:58 2016 UTC (16 months ago) by jcfr
PERF: slicer.util.importClassesFromDirectory: Compile regex outside for loop

While no significant improvements could be measured, compiling the regex
only once is a sensible choice.

Revision 25100  Directory Listing
Modified Sat May 21 05:44:14 2016 UTC (16 months ago) by jcfr
BUG: Fix regression: python code "exit(status)" will now exit with "status"

This commit fixes py_nomainwindow_SlicerPythonCodeTest2 fixing a regression
introduced in r25083 (STYLE: Automatically enable "ignore-slicerrc" if
"testing" option is given).

Associating the test with "--testing" option was causing the application
to always exit with EXIT_SUCCESS when "exit(EXIT_FAILURE)" was called.

This commit ensures the all to slicer.app.exit() in "slicer.util.exit()"
is considered.

Revision 25088  Directory Listing
Modified Thu May 19 08:10:45 2016 UTC (16 months, 1 week ago) by jcfr
BUG: Update qSlicerSslTest. See #4194

Now that "http://slicer.org" redirects to "https://slicer.org", this commit
update the test by:

* checking query on http://slicer.org gives the status code 302 corresponding
to URL redirection.

* adding a test checking that query to https://slicer.org works as expected.
It turns out that the SSL certificate associated with slicer.org has some
issue. The test currently list the HostNameMismatch error as expected.
See #4194.

Revision 25087  Directory Listing
Modified Thu May 19 07:10:54 2016 UTC (16 months, 1 week ago) by jcfr
BUG: Ensure modules set with --modules-to-ignore are not saved in settings

This commit updates the modules panel adding "modulesToAlwaysIgnoreChanged"
signal emitted only with a list of modules excluding the one passed
as argument to "--modules-to-ignore" command line arguments.

Also adds "SlicerOptionModulesToIgnoreTest" and teaches "SlicerAppTesting.run()"
to understand the "shell" parameter

Revision 25086  Directory Listing
Modified Thu May 19 07:10:52 2016 UTC (16 months, 1 week ago) by jcfr
STYLE: AbstractModuleFactoryManager: Improve doxygen

Revision 25085  Directory Listing
Modified Thu May 19 07:10:51 2016 UTC (16 months, 1 week ago) by jcfr
ENH: Add command line option "--modules-to-ignore"

Revision 25084  Directory Listing
Modified Thu May 19 07:10:49 2016 UTC (16 months, 1 week ago) by jcfr
STYLE: Use imperative tense in command line option descriptions

Options are now all using the same tense.

Revision 25083  Directory Listing
Modified Thu May 19 07:10:48 2016 UTC (16 months, 1 week ago) by jcfr
STYLE: Automatically enable "ignore-slicerrc" if "testing" option is given

This simplifies writing of tests.

Revision 25082  Directory Listing
Modified Thu May 19 07:10:46 2016 UTC (16 months, 1 week ago) by jcfr
ENH: Add "--keep-temporary-settings" option

When specified with "disable-settings", it prevents the temporary settings
from being cleared. This is useful when writing test checking effect
of settings values.

Revision 25081  Directory Listing
Modified Thu May 19 07:10:44 2016 UTC (16 months, 1 week ago) by jcfr
STYLE: qSlicerCoreCommandOptions: Simplify disabling of settings

Also improve and fix doxygen documentation.

Revision 25079  Directory Listing
Modified Wed May 18 23:36:00 2016 UTC (16 months, 1 week ago) by jcfr
PERF: Improve startup time delaying execution of shared and executable CLIs

This commit reduces startup time by ~50% (8.6s -> 5.5s). Detailed startup
time stats reported below.

[ci skip]

More specifically, it updates the loadable and executable CLI factories
so that (1) the XML file is directly loaded from disk if it exists along
side the executable or library and (2) the execution of the executable or
"entry point" for shared library is delayed until needed.

For CLI executable, change consists simply in reading the XML file if it
exists and postpone the execution until it is needed.

For CLI shared library, the ModuleDescription object API has been updated.
It now allows the association of a callback in charge of loading the
library and resolving symbols. The callback is automatically called
when "GetTarget()" method is called and no target has already been set.

Note that the XML file is now copied (and installed if it applies) along
side the CLI executable. There are currently no option to avoid the new
behavior, if it reveals problematic, we could revisit and introduce
an option for "SEMMacroBuildCLI" macro.

Detailed startup time stats without this change are reported in
precedent commit (ENH: Add convenience script to measure the application
startup time).

Detailed startup time stats after this change:

 - Obtained on Ubuntu 15.10, 64GB/M.2 PCIe NVMe SSD/Quad Core 3.80GHz.
 - For a release build

Slicer --no-splash --exit-after-startup
5.537 seconds

Slicer --no-splash --exit-after-startup --disable-builtin-cli-modules
5.438 seconds

Slicer --no-splash --exit-after-startup --disable-builtin-loadable-modules
2.863 seconds

Slicer --no-splash --exit-after-startup --disable-builtin-scripted-loadable-modules
3.925 seconds

Slicer --no-splash --exit-after-startup --disable-builtin-cli-modules --disable-builtin-scripted-loadable-modules
3.973 seconds

Slicer --no-splash --exit-after-startup --disable-modules
1.761 seconds

Slicer --no-splash --exit-after-startup --disable-python
3.094 seconds

Slicer --no-splash --exit-after-startup --disable-python --disable-builtin-cli-modules
3.054 seconds

Slicer --no-splash --exit-after-startup --disable-python --disable-builtin-loadable-modules
0.972 seconds

Slicer --no-splash --exit-after-startup --disable-python --disable-builtin-scripted-loadable-modules
3.135 seconds

Slicer --no-splash --exit-after-startup --disable-python --disable-builtin-cli-modules --disable-builtin-scripted-loadable-modules
3.085 seconds

Slicer --no-splash --exit-after-startup --disable-python --disable-modules
0.924 seconds

SlicerExecutionModel changes:

$ git shortlog b2c78c7..1b2a454 --no-merges
Jean-Christophe Fillion-Robin (9):
      STYLE: ModuleDescription: Move definition to cxx file
      STYLE: Remove obsolete ModuleFactory class
      STYLE: ModuleDescription: Remove unused Alternative Type/Target/Location
      STYLE: Remove obsolete BinaryFileDescriptor support
      STYLE: ModuleDescriptionParser: Add separator comment, small tweaks
      STYLE: Add ModuleDescriptionTesting Macros and Utilities files
      STYLE: ModuleDescription: Add TestDefaults
      ENH: ModuleDescription: Add support for lazily setting the target
      ENH: Update SEMMacroBuildCLI to copy (and optionally install) the XML file

Revision 25078  Directory Listing
Modified Wed May 18 23:35:58 2016 UTC (16 months, 1 week ago) by jcfr
BUG: Ensure "--disable-settings" clear all temporary settings

Revision 25075  Directory Listing
Modified Wed May 18 23:35:53 2016 UTC (16 months, 1 week ago) by jcfr
STYLE: Refactor CLI Executable and Loadable module factories

Anticipating coming changes, this commit re-organize code without
changing the functionality.

Revision 25074  Directory Listing
Modified Wed May 18 23:35:52 2016 UTC (16 months, 1 week ago) by jcfr
STYLE: qSlicerCLIModule: Add "moduleDescription()" method

Revision 25073  Directory Listing
Modified Wed May 18 23:35:50 2016 UTC (16 months, 1 week ago) by jcfr
STYLE: qSlicerCLIModule: Simplify core removing unneeded ivars.

Refactor the code to directly use the ModuleDescription to store
module property.

Revision 25072  Directory Listing
Modified Wed May 18 23:35:49 2016 UTC (16 months, 1 week ago) by jcfr
STYLE: qSlicerCLIModule: Remove unused "ProcessInformation" ivar

Revision 25071  Directory Listing
Modified Wed May 18 23:35:48 2016 UTC (16 months, 1 week ago) by jcfr
BUG: Ensure "exit-after-startup" exits with failure if python error occurred

This commit improves the command line argument originally added in
r25059 (ENH: Add "exit-after-startup" command line option.)

Revision 25059  Directory Listing
Modified Sun May 8 05:45:43 2016 UTC (16 months, 2 weeks ago) by jcfr
ENH: Add "exit-after-startup" command line option.

This is useful to "measure" startup time.

Note that part of the implementation of this feature was accidentally
integrated in the previous commit.

Revision 25058  Directory Listing
Modified Sun May 8 05:37:04 2016 UTC (16 months, 2 weeks ago) by jcfr
STYLE: Fix unused-parameter and unused-variable warnings

Revision 25056  Directory Listing
Modified Sun May 8 05:00:56 2016 UTC (16 months, 2 weeks ago) by jcfr
PERF: Improve selection node lookup

Similarly to r25054, this commit updates the code to retrieve the node
using its singleton node id.

Suggested-by: Andras Lasso <lasso@queensu.ca>
Suggested-by: Isaiah Norton <inorton@bwh.harvard.edu>

Revision 25052  Directory Listing
Modified Sat May 7 19:11:04 2016 UTC (16 months, 2 weeks ago) by lassoan
BUG: Removed memory leaks in Python method calls

Py_DECREF(arguments) is called after each Python method calls from C++, but it was missing at a few places, so input arguments to Python method calls were leaked.

Revision 25047  Directory Listing
Modified Fri May 6 09:03:27 2016 UTC (16 months, 2 weeks ago) by jcfr
ENH: qSlicerCoreIOManager: Display time used to load a file.

From: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

Revision 25012  Directory Listing
Modified Mon Apr 18 02:21:38 2016 UTC (17 months, 1 week ago) by lassoan
ENH: Improved API for getting editable VTK transform from node

It is now simpler to ask for a transform that can be modified (it can be indicated with an extra optional flag).

Revision 25005  Directory Listing
Modified Tue Apr 12 06:27:26 2016 UTC (17 months, 2 weeks ago) by jcfr
COMP: Fix "-Wunused-parameter" and "-Wparentheses" warnings

Revision 25003  Directory Listing
Modified Mon Apr 11 04:57:13 2016 UTC (17 months, 2 weeks ago) by lassoan
BUG: Fixed edit properties option in node selectors

Fixes http://www.na-mic.org/Bug/view.php?id=2109

Now any module can associate a MRML node type with a module (instead of having a hardcoded list of modules
in qSlicerApplication) and when switching to a module, the chosen node is selected as active node.
Associations can be added by calling qSlicerApplication::registerNodeModule().
Multiple modules can be associated with the same MRML node type.

The best module for a specific node instance is determined run-time, by calling
qSlicerAbstractModuleWidget::nodeEditable() for each candidate and choosing
the one that has the highest confidence in handling the node.
This mechanism is used for selecting the CLI module that corresponds to a specific CLI module parameter node.
This mechanism is also used for switching to volume rendering module if a volume rendering clipping ROI node
is selected for editing (instead of switching to the Annotations module).
The most suitable module's qSlicerAbstractModuleWidget::setEditedNode() method is called to select the currently edited node.
qSlicerAbstractModuleWidget::nodeEditable() and qSlicerAbstractModuleWidget::setEditedNode() methods can be overridden
in scripted loadable modules as well.

As edited node selection is now possible using a clean, unified method call, it is no longer necessary
to access GUI widgets directly. Therefore, almost all editProperties() method calls in subject hierarchy plugins were
removed (replaced by a common implementation in the base class). This new, simplified method fixes robustness issues
of using node name filters for selecting a node in model hierarchy, inability to choose annotation hierarchy nodes, etc.

qSlicerAbstractModuleWidget::setEditedNode(vtkMRMLNode* node, QString role, QString context) has two extra (optional)
arguments. Role can be used to specify additional nodes for a module (e.g., if there are multiple inputs for a module
then role argument can select between them). Context can be used for specifying a sub-selection within a node (for
example, Segment Editor module can be activated for a selected segment - specified by 'context' - of a specific
segmentation node - specified by 'node').

Fixed code review errors (typos and API simplification).

Revision 25000  Directory Listing
Modified Mon Apr 4 21:41:11 2016 UTC (17 months, 3 weeks ago) by lassoan
COMP: Fixed merge error

Revision 24998  Directory Listing
Modified Mon Apr 4 20:40:02 2016 UTC (17 months, 3 weeks ago) by lassoan
ENH: Added convert section to transforms module

Conversion of transform to displacement field was often requested. Added a new "Convert" section at the bottom of Transforms module that allows converting a transform to a grid transform or to a displacement volume.

Revision 24965  Directory Listing
Modified Thu Mar 10 19:24:07 2016 UTC (18 months, 2 weeks ago) by pinter
BUG: Fixed class name criteria mode for findChildren

See http://slicer-devel.65872.n3.nabble.com/Changing-the-behavior-of-slicer-util-findChildren-td4036266.html

From: Jorge Onieva

Revision 24957  Directory Listing
Modified Thu Mar 3 17:48:36 2016 UTC (18 months, 3 weeks ago) by jcfr
ENH: slicer.util.findChildren: Change behavior to an "and" filter

As discussed in [1], this commit changes the behavior so that *ALL*
parameters (name, text, title and className) are considered when checking
a descendant widget. Prior to this change, the widget was considered
"matched" as soon as the *FIRST* non-False parameter was matching.

[1] http://slicer-devel.65872.n3.nabble.com/Changing-the-behavior-of-slicer-util-findChildren-td4036266.html

Co-authored-by: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

From: jonieva <jorgeonieva@gmail.com>

Revision 24955  Directory Listing
Modified Thu Mar 3 06:16:24 2016 UTC (18 months, 3 weeks ago) by jcfr
ENH: Improve --additional-module-paths to support extension build directory

This commit teaches Slicer to check if any given "additional-module-path"
is the build or install directory of an extension.

Revision 24948  Directory Listing
Modified Thu Feb 25 16:23:28 2016 UTC (19 months ago) by lassoan
STYLE: Deleted empty directories

Most of them were probably leftovers from git-svn commits.

Revision 24938  Directory Listing
Modified Mon Feb 22 01:28:47 2016 UTC (19 months ago) by jcfr
BUG: Handle exception if string encoding fails

Sometimes there are tricky characters in the strings that need to be encoded (in my case 0xe9), throwing a UnicodeDecodeError exception, which, if not handled properly, results in a long list of SliceViewAnnotations error messages, furthermore stoppage of the running script

From: Csaba Pinter <csaba.pinter@queensu.ca>

Revision 24934  Directory Listing
Modified Thu Feb 18 04:31:03 2016 UTC (19 months, 1 week ago) by lassoan
BUG: Fixed inconsistent mouse mode toolbar state

Fixes this faulty behavior:
* Start Slicer
* Switch mouse mode to place ruler => mouse cursor becomes a ruler
* Switch mouse mode to place ROI => ERROR: mouse mode stays a ruler (it should have switched to ROI)

Revision 24930  Directory Listing
Modified Tue Feb 16 20:29:13 2016 UTC (19 months, 1 week ago) by lassoan
BUG: Fix crash in CLI module widget

Use weak pointer to make sure we don't try to access a node that was already deleted.

Probably fixes http://na-mic.org/Mantis/view.php?id=4141

Revision 24929  Directory Listing
Modified Fri Feb 12 01:46:38 2016 UTC (19 months, 1 week ago) by lassoan
ENH: Enable full logging of python error and warning messages

Currently, if a non-debug message is logged from Python (using logging.info, logging.warning, logging.error) then the following appears in the log:
[CRITICAL][Stream] 11.02.2016 14:28:29 [] (unknown:0) - this is a warning message

If we enable full logging of non-debug messages then we get file name and line number as well:
[WARNING][Python] 11.02.2016 14:28:29 [Python] (MyLoggingTest.py:123) - this is a warning message
[CRITICAL][Stream] 11.02.2016 14:28:29 [] (unknown:0) - this is a warning message

The change in this commit enables full logging of non-debug messages, which has the slight disadvantage of having two entries for each error (one corresponding to the message appearing on the Python console and the other is the actual error log) but it provides the filename and line number, which is very useful for debugging.

Revision 24925  Directory Listing
Modified Wed Feb 10 06:02:44 2016 UTC (19 months, 2 weeks ago) by lassoan
BUG: Fixed crosshair node setting from MRML

Fixes the error reported below.

-----Original Message-----
From: slicer-devel-bounces@bwh.harvard.edu [mailto:slicer-devel-bounces@bwh.harvard.edu] On Behalf Of criskross
Sent: February 8, 2016 3:27 PM
To: SPL Slicer Devel <slicer-devel@bwh.harvard.edu>
Subject: [slicer-devel] CrosshairNode control from module UI

Hi Developers,

I got the following problem: I added a checkable button, that activates/deactivates the crosshair with a specific mode. My code:

crosshairNode = slicer.mrmlScene.GetNthNodeByClass(0,
'vtkMRMLCrosshairNode')
crosshairNode.SetCrosshairMode(slicer.vtkMRMLCrosshairNode.ShowSmallBasic)

However the crosshair is shown, but in its basic appearance (not small).

It works, when I execute the following code:

crosshairNode = slicer.mrmlScene.GetNthNodeByClass(0,
'vtkMRMLCrosshairNode')
crosshairNode.SetCrosshairMode(slicer.vtkMRMLCrosshairNode.ShowSmallBasic)
crosshairNode.SetCrosshairMode(slicer.vtkMRMLCrosshairNode.ShowSmallBasic)

To make sure, that this doesn't happen only with my nightly build 01/28/2016, I installed the current nightly build. Same issue.


Btw., what is the difference between crosshair display and behavior? For me it seems to be pretty much the same.
http://slicer.org/doc/html/classvtkMRMLCrosshairNode.html#ac0d010fdec7d7f49bb6ec7fe67e61af7
does not tell anything about that difference. Only the following:

<http://slicer-devel.65872.n3.nabble.com/file/n4036198/Screen_Shot_2016-02-08_at_3.png> 

Thanks
Christian

Revision 24916  Directory Listing
Modified Wed Feb 3 04:58:06 2016 UTC (19 months, 3 weeks ago) by jcfr
COMP: Fix compilation adding missing qSlicerDirectoryListViewPlugin sources.

This commit fixes a regression introduced in r24914 (ENH: Allow adding
module directories by drag-and-drop).

Revision 24915  Directory Listing
Modified Tue Feb 2 20:20:58 2016 UTC (19 months, 3 weeks ago) by lassoan
ENH: Added maximize button to Settings dialog

Some settings panels are quite large, show maximize button to allow making it larger with a single click (instead of dragging the window to the top left and then drag the top-right corner of the window).

Revision 24914  Directory Listing
Modified Tue Feb 2 20:14:08 2016 UTC (19 months, 3 weeks ago) by lassoan
ENH: Allow adding module directories by drag-and-drop

In Settings dialog / Modules panel, it is now possible to drag a directory to the directory list to add the directory (no need to click 'Add', select the directory, and click OK).

Implemented by adding this feature to qSlicerDirectoryListView widget. Also added a designer plugin for this widget to make it show up in Qt Designer.

Revision 24908  Directory Listing
Modified Fri Jan 29 18:29:10 2016 UTC (19 months, 3 weeks ago) by jcfr
ENH: Refactored view ruler and orientation marker

Ruler and orientation marker:
-----------------------------

- available in both 2D and 3D viewers

- easier to discover (available in viewer controller widgets and
  application settings)

- more customizable (size, visibility, custom ruler scales, orientation
  marker models)

- implemented with cleaner design (using displayable managers for
  rendering and regular node attributes for data storage).

New features:
-------------

- Ruler and orientation marker is configurable per viewer in the slice/3D
  view controller widgets (same way as all view options)

- Ruler and orientation marker can be shown in 3D view

- Default ruler orientation marker settings (and additional 3D view settings,
  such as orthographic projection, show 3D cube, axis labels, depth peeling)
  can be configured in the application settings (saved in .ini file)

- Allow using any model in the scene as orientation marker (for example, set a
  custom orientation marker in the 3D viewer:

    getNode('View1').SetOrientationMarkerHumanModelNodeID(getNode('ToriaClipped03').GetID() )

- All ruler and orientation marker settings (including custom orientation marker)
  are saved in the scene

- Added "thick" ruler mode: there is an option now to show the ruler with a
  thicker line and larger font so that it can be seen from a larger distance
  (e.g., interventional use)

Fixes bugs in the old implementation:
-------------------------------------

- ruler showed incorrect value when zoomed in or zoomed out very much (instead
  of hiding the ruler, it was kept displayed at an incorrect scale)

- Ruler was unusable in lightboxview: ruler line was clipped in half, label was
  not visible

- Some observers were not removed

Design changes compared to the old implementation:
--------------------------------------------------

- Ruler and orientation marker are rendered by displayable managers: This allows
  much simpler and more robust resource management and rendering update (there was
  previously an infinite loop in the orientation marker update causing Slicer crash
  by stack overflow).

- Orientation marker is loaded from a single file, color is stored in scalars:
  This makes the implementation simpler and displaying of multi-color custom
  models feasible.

Slicer core changes:
--------------------

- Removed roll/pitch/yaw buttons from 3D view: to reduce the additional
  complexity caused by adding 2 new buttons (for show/hide ruler and
  orientation marker)

Remarks and next steps:
----------------------

- Slice view corner annotations and scalar bar were left unchanged in the DataProbe
  module, as they were not obvious how to clean up and generalize. Slice corner
  annotations have to be made more generic, allowing displaying of custom text provided
  by various modules (see for example CornerAnnotations module).

- Scalar bar will need to be harmonized with the Color module's scalar bar display
  (that is currently only available in the 3D view).

From: Andras Lasso <lasso@queensu.ca>

Revision 24905  Directory Listing
Modified Fri Jan 29 18:27:12 2016 UTC (19 months, 3 weeks ago) by jcfr
ENH: Add infrastructure to support default MRML nodes

Allow modifying default node content: Scene can store "default" nodes. If
a default node is specified for a class then the content of that node will
be used to initialize new nodes and reset nodes.

Currently used only for 3D views but can be used for other purposes, too
(e.g., disable interpolation by default for volume nodes).

This is a backward incompatible change. Signature of

  vtkMRMLNode::Reset()

has been changed into

  vtkMRMLNode::Reset(vtkMRMLNode* defaultNode)

Co-authored-by: Csaba Pinter <csaba.pinter@queensu.ca>

From: Andras Lasso <lasso@queensu.ca>

Revision 24901  Directory Listing
Modified Tue Jan 26 05:30:39 2016 UTC (20 months ago) by jcfr
STYLE: Replace occurrences of QProgressDialog by slicer.util method calls

From: Christian Herz <christian.herz@mevis.fraunhofer.de>

Revision 24899  Directory Listing
Modified Tue Jan 26 05:30:31 2016 UTC (20 months ago) by jcfr
ENH: Add slicer.util.createProgressDialog method

From: Christian Herz <christian.herz@mevis.fraunhofer.de>

Revision 24898  Directory Listing
Modified Tue Jan 26 05:30:29 2016 UTC (20 months ago) by jcfr
ENH: Add slicer.util display methods

In addition to the introducion of "messageBox()" method used to
refactore the existing "errorDisplay()" and "warningDisplay()"
methods, this commit also adds the following methods:
* confirmationDisplay
* confirmYesNoDisplay
* confirmRetryCloseDisplay
* infoDisplay

From: Christian Herz <christian.herz@mevis.fraunhofer.de>

Revision 24897  Directory Listing
Modified Tue Jan 26 05:30:27 2016 UTC (20 months ago) by jcfr
STYLE: Remove unused parameter from slicer.util display methods

From: Christian Herz <christian.herz@mevis.fraunhofer.de>

Revision 24896  Directory Listing
Modified Tue Jan 26 05:12:45 2016 UTC (20 months ago) by jcfr
COMP: qSlicerApplication: Fix unused variable warning in release build

This commit fixes the following warning:

/path/to/Slicer/Base/QTGUI/qSlicerApplication.cxx: In member function ‘virtual void qSlicerApplication::handlePreApplicationCommandLineArguments()’:
/path/to/Slicer/Base/QTGUI/qSlicerApplication.cxx:451:30: warning: unused variable ‘options’ [-Wunused-variable]
   qSlicerCoreCommandOptions* options = this->coreCommandOptions();
                              ^

From: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

Revision 24891  Directory Listing
Modified Tue Jan 26 04:59:20 2016 UTC (20 months ago) by jcfr
ENH: Moved up vtkMRMLStorableNode in the MRML node hierarchy.

vtkMRMLStorableNode is not a children of vtkMRMLTransformable node anymore,
but directly a children of vtkMRMLNode.

This allows making a node storable without requiring it to be also
transformable. It is important for several node types (color maps, tables,
etc), which require separate storage node but are not transformable.

From: Andras Lasso <lasso@queensu.ca>

Revision 24857  Directory Listing
Modified Fri Jan 8 19:15:25 2016 UTC (20 months, 2 weeks ago) by johan.andruejol
STYLE: CLIEvent testing

This is a test that shows how Slicer handles CLI events.
Note that this only reflects how the application works now.

Revision 24834  Directory Listing
Modified Wed Jan 6 22:29:27 2016 UTC (20 months, 2 weeks ago) by jcfr
BUG: Fix CLI running issues and add tests to prevent future regression.

Before, the CLI module logic would add the observer before running the CLI
and remove it once the CLI is modified. This proved to be error prone, for
example if two CLIs are ran at the same time. One CLI would finish and
remove the observation, preventing the other one from ever finishing.
Instead, we propose to always listen to the event. This make the code
simpler and more robust.

Thanks to Alexis and Dzenan for their help creating a simple test case.

Reported-by: Dzenan Zukic <dzenan.zukic@kitware.com>
Co-authored-by: Alexis Girault <alexis.girault@kitware.com>
Co-authored-by: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

From: Johan Andruejol <johan.andruejol@kitware.com>

Revision 24833  Directory Listing
Modified Wed Jan 6 18:10:17 2016 UTC (20 months, 2 weeks ago) by jcfr
BUG: Fixed crash when calling widgetRepresentation().self()

How to reproduce:

1. Go to endoscopy module (just an example, the behavior is the same for every scripted modules)

2. Copy-paste this into the Python console:

import sys
for i in range(30):
  w = slicer.modules.endoscopy.widgetRepresentation().self()
  print("Reference count of widget object: "+str(sys.getrefcount(w)))

=> memory is corrupted now and Slicer will crash very soon (e.g., if the above code copy-pasted again or any other operation is performed)

Problem:
Each time pythonSelf() is used to return an reference to Python, the reference count is decreased by one (when the temporary Python object is deleted).

Solution:
When returning a reference to Python, the reference count has to be increased by one.
(for example, the same is done in CTK-build\PythonQt\tests\PythonQtTests.h)

This might (hopefully) also solve the frequent crash of Slicer on application exit due to double-delete of PythonQt widgets.

Reviewed-by: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>
Reviewed-by: Max Smolens <max.smolens@kitware.com>

From: Andras Lasso <lasso@queensu.ca>

Revision 24826  Directory Listing
Modified Wed Dec 23 21:26:28 2015 UTC (21 months ago) by lassoan
ENH: Improved MRML tests

* Added output check to MRML core cxx methods (if any MRML node logs an unexpected error or warning during a test then it makes the test return with failure).
* Changed very long test macros to regular methods. It allows step-by-step debugging, getting exact error location (not just where the macro was called), simpler editing of the code (no need to put backslashes at the end of every line).
* Created a test macro for exercising all applicable MRML methods (ExerciseAllBasicMRMLMethods), which determines which methods should be tested by dynamic casting. Changed all MRML tests to use this single macro. It is still a macro to be able to run the function and log the line number in a single line using a simple syntax.
* Separated test macros (vtkMRMLCoreTestingMacros) and functions (vtkMRMLCoreTestingUtilities.h/txx/cxx) for clarity.
* Replaced several-line checks by CHECK_... macros for shorter code and simpler syntax. The check macros just gather the line number, call a check method, and return in case of an error: problems can still be analyzed using step-by-step debugging.
* Replaced bool return values by int (EXIT_FAILURE/EXIT_SUCCESS) at many places. It allows propagating the same error code from any level back to the main() function, using the same CHECK_... macros at every level.
* Re-enabled and fixed old tests that did not work in the core MRML library because they depended on classes that are not in MRML core. Moved tests to the module where the corresponding MRML node was defined. Updated obsolete scene files.
* Added thorough testing of node references between singleton and non-singleton nodes.

Revision 24819  Directory Listing
Modified Mon Dec 21 21:35:55 2015 UTC (21 months ago) by pinter
BUG: Fixed crash when saving scene with no main window

A scenario common with slicelets

Revision 24816  Directory Listing
Modified Mon Dec 14 20:54:25 2015 UTC (21 months, 1 week ago) by lassoan
COMP: Fixed build warning

Revision 24811  Directory Listing
Modified Wed Dec 9 22:54:37 2015 UTC (21 months, 2 weeks ago) by lassoan
BUG: CLI several module GUI bugs

Fix for need to re-select node after changing some parameters (http://www.na-mic.org/Bug/view.php?id=4090):
- Create a CLI node when switching to CLI if a compatible node is not available already (to not require users create a CLI node before starting interacting with the module). (http://www.na-mic.org/Bug/view.php?id=4090)
- Disable CLI module parameter editing widgets if no CLI node is selected (e.g., after scene close).
- Prevent crash in qSlicerCLIModuleUIHelper::setCommandLineModuleParameter when the method is called before a scene is set.

Fix for editable output values (http://www.na-mic.org/Bug/view.php?id=2402 and http://www.na-mic.org/Bug/view.php?id=2842):
- Prevent editing of CLI output values.
- Print current parameter values in vtkMRMLCommandLineModuleNode::PrintSelf instead of the module description, which is long and in general not informative.
- Added a method for printing module description (vtkMRMLCommandLineModuleNode::GetModuleDescriptionAsString).

Fix for editing vector fields:
- Prevent moving the cursor to the end of the line when editing a vector field (e.g., try to edit the first value in Float Vector Parameter in Execution Model Tour)

Revision 24801  Directory Listing
Modified Tue Dec 1 20:06:37 2015 UTC (21 months, 3 weeks ago) by jcfr
STYLE: Remove VTKv5 support

As discussed during the developer hangout of 2015-03-31, this commit
removes support for VTKv5.

Most of the h/cxx files have been updated automatically using the
script "slicer_remove_vtk5_support.py" [1]. See below.

The remaining of h/cxx, python and CMake files have been updated
manually.


slicer_remove_vtk5_support.py:
cd ~/Project/Slicer
~/Download/slicer_remove_vtk5_support.py $(ack -l VTK_MAJOR_VERSION)

[1] https://gist.github.com/jcfr/91d2f5d07c2a36320e48

Revision 24798  Directory Listing
Modified Tue Dec 1 18:51:08 2015 UTC (21 months, 3 weeks ago) by pinter
ENH: Added CLI support for Subject hierarchy #1

1. Moved vtkMRMLSubjectHierarchyNode and constants to MRML core. Moved transform related functions to SH logic from the node
2. Added reference argument support for Volume (image) and Model (geometry) nodes when outputs of a CLI module

Revision 24783  Directory Listing
Modified Mon Nov 30 19:46:18 2015 UTC (21 months, 3 weeks ago) by lassoan
ENH: Added support for Tables

* New module added: Tables. Create create/view/edit/delete tables, freeze column/row header, lock to read-only (vtkMRMLTableNode).
* Tables can be shown in the view layout (new layout added: Four-up table, more can be added as needed)
* Load/save csv, tsv, txt files as table nodes
* Copy-paste to/from Excel
* SubjectHierarchy plugin (show/hide, edit, clone tables)
* Use tables as input/output for CLI modules (PET Standard Uptake Value Computation module is updated to use tables; there was no need to change the Slicer Execution Model, the Table data type was already usable)
* Reusable widget added for viewing/editing tables in C++ and Python modules

Revision 24780  Directory Listing
Modified Mon Nov 30 19:13:46 2015 UTC (21 months, 3 weeks ago) by lassoan
ENH: Simplified vtkSlicerApplicationLogic

Problem:
vtkSlicerApplicationLogic had node-specific logic for creating storage and display nodes.
This made it necessary to modify vtkSlicerApplicationLogic whenever a new node type is added.
CreateDefaultStorageNode and CreateDefaultDisplayNodes methods are introduced some time ago
to encapsulate all node-specific storage and display node creation. These methods were partly
used by vtkSlicerApplicationLogic, but not for all cases; also, CreateDefaultStorageNode and
CreateDefaultDisplayNodes methods were not implemented for all nodes.

Solution:
Moved node-specific storage and display node creation code to CreateDefaultStorageNode and
CreateDefaultDisplayNodes methods of the corresponding nodes.
Replaced node-specific logic from vtkSlicerApplicationLogic by CreateDefaultStorageNode and
CreateDefaultDisplayNodes method calls.

Revision 24771  Directory Listing
Modified Wed Nov 25 04:01:26 2015 UTC (22 months ago) by jcfr
ENH: Fix scene save with default parameters

Novice Slicer users often complain that scene saving fails. The problem
is that Slicer offers scene saving in a read-only directory by default
(into the current working directory, which is the read-only program
binary directory by default).

Fixes applied:

1. Changed the default scene root directory to be the user's documents
   folder (determined the same way as the default DICOM database directory).

2. Made default scene directory configurable in the application settings
   GUI (selection is stored in application settings under "DefaultScenePath" key).

From: Andras Lasso <lasso@queensu.ca>

Revision 24759  Directory Listing
Modified Fri Nov 20 03:56:01 2015 UTC (22 months ago) by jcfr
STYLE: Update python tests to use more specific asserts.

Using the more specific assert functions usually gives more useful
error messages.

Suggested-by: Csaba Pinter <csaba.pinter@queensu.ca>
Suggested-by: Max Smolens <max.smolens@kitware.com>

Revision 24758  Directory Listing
Modified Fri Nov 20 03:55:52 2015 UTC (22 months ago) by jcfr
STYLE: Update python scripts to use "is None" instead of "== None"

Rational copied from https://www.python.org/dev/peps/pep-0290/#testing-for-none

// -----------------
 Since there is only one None object, equality can be tested with identity. Identity tests are slightly faster than equality tests. Also, some object types may overload comparison, so equality testing may be much slower.

Pattern:

if v == None  -->  if v is None:
if v != None  -->  if v is not None:
// -----------------

Reviewed-by: Csaba Pinter <csaba.pinter@queensu.ca>
Reviewed-by: Max Smolens <max.smolens@kitware.com>

Revision 24743  Directory Listing
Modified Mon Nov 16 23:24:44 2015 UTC (22 months, 1 week ago) by naucoin
BUG: Fix error in terminology install command

Remove the extra ColorFiles directory in the install path.

Issue #4047

Revision 24742  Directory Listing
Modified Mon Nov 16 22:46:35 2015 UTC (22 months, 1 week ago) by naucoin
ENH: Add terminology information to color picker in Editor

Added terminology files, read them on start up, associate
with the generic anatomy colors node.
Add accessors to the color logic as well as basic methods to
allow creating new terminologies (used by the Reporting extension).
Created Python callable utility methods to allow scripted access[1].
Add read only widgets to the Editor, shown if the selected
color node has terminology associated with it (using
node attributes).
Added testing for the terminology functionality to vtkSlicerColorLogicTest (rather than
in vtkMRMLColorLogicTest1 since the Colors module logic adds the terminology files).
Pass the color logic to the color model so that it can look up
terminology information to set the tool tips on the color table
entries.
Minor changes to respond to feedback on the pull request (CMake,
references, default terminology).
[1] Utility accessor functions:
- GetTerminologyFromLabel takes in the strings defining the color label
categorization and the standard term elements and returns the specific term.
- Get the colon concatenated full standard term values via
GetSegmentedPropertyCategory, GetSegmentedPropertyType, GetSegmentedPropertyTypeModifier,
GetAnatomicRegion, GetAnatomicRegionModifier

Issue #4047

Revision 24741  Directory Listing
Modified Mon Nov 16 22:23:29 2015 UTC (22 months, 1 week ago) by lassoan
ENH: Added update_display parameter to cli

It allows running a CLI without resetting the slice viewers.

Revision 24722  Directory Listing
Modified Wed Nov 11 16:15:34 2015 UTC (22 months, 2 weeks ago) by naucoin
BUG: Fix crash on saving node named with a single number

A previous fix[1] to avoid crashes on windows when saving
volumes named "1:xxxx" leads to a crash when a node name
is just a single number (the first part of the check passes, but
crashes when trying to get the second character in the name string).
This fix adds a string length check so that valid node names like
"1" or "2" will not cause a crash on save.

[1] http://viewvc.slicer.org/viewvc.cgi/Slicer4?view=revision&revision=24294

Issue #3991

Revision 24694  Directory Listing
Modified Fri Nov 6 15:26:51 2015 UTC (22 months, 2 weeks ago) by lassoan
BUG: Fixed extension install failure

Extension installation silently failed after a previous extension installation was partially completed due to running out of disk space.

1. No errors were displayed => Added error display for all failure branches in qSlicerExtensionsManagerModel::extractExtensionArchive

2. SlicerIGT-XXXXXX intermediate directory was left in the extension directory, that prevented all further attempts to move the extracted archive content to the correct location (directory copy fails if the target directory is not empty) => Added deletion of the intermediate directory before copying.

Revision 24689  Directory Listing
Modified Tue Nov 3 17:47:12 2015 UTC (22 months, 3 weeks ago) by jcfr
BUG: Fix ScriptedLoadableModuleLogic.clickAndDrag() to work with editor

Since the EffectTool observes the interactor events with a priority
of 1.0, this commit updates the code in clickAndDrag() to use interactor
functions instead of interactor style ones. This will ensure the interactor
events are invoked.

Revision 24666  Directory Listing
Modified Wed Oct 28 01:59:56 2015 UTC (22 months, 4 weeks ago) by jcfr
BUG: Handle download/install error for extension dependencies.

The function downloadAndInstallExtension() did not handled the case of
downloadExtension() returning 0. This commit implements the same approach
as in scheduleExtensionForUpdate() to handle that case correctly in
downloadAndInstallExtension().

To avoid overwhelming the user with a lot of different messages when
some of all dependent extensions failed to download, error messages are
accumulated in a list and shown only outside the loop if it applies.

Reviewed-by: Andras Lasso <lasso@queensu.ca>
Reviewed-by: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

From: Francois Budin <fbudin@unc.edu>

Revision 24662  Directory Listing
Modified Mon Oct 26 01:52:20 2015 UTC (23 months ago) by jcfr
BUG: Fix CERTIFICATE_VERIFY_FAILED error using "urllib2.urlopen()" on MacOSX

See http://www.na-mic.org/Bug/view.php?id=4067

This commit ensures the "Slicer.crt" certificate is found when using
function like "urlib2.urlopen()" in the python interactor from an install
tree on MacOSX.

This is needed because on MacOSX the launcher is not used when the
application is installed.

Reported-by: Andriy Fedorov <fedorov@bwh.harvard.edu>

Revision 24661  Directory Listing
Modified Sat Oct 24 06:13:23 2015 UTC (23 months ago) by jcfr
ENH: Add python method cli.runSync(). See #3600

See http://www.na-mic.org/Bug/view.php?id=3600

Suggested-by: Michael Halle <mhalle@bwh.harvard.edu>

Revision 24659  Directory Listing
Modified Fri Oct 23 19:53:45 2015 UTC (23 months ago) by pieper
BUG: #4060 make package button perform a toggle (save dialog)

See:
http://www.na-mic.org/Bug/view.php?id=4060

From: Steve Pieper <pieper@bwh.harvard.edu>

Revision 24658  Directory Listing
Modified Fri Oct 23 19:38:06 2015 UTC (23 months ago) by jcfr
BUG: Fix installation of Slicer.crt on MacOSX. Fixes #4067

Revision 24651  Directory Listing
Modified Wed Oct 21 02:02:25 2015 UTC (23 months ago) by jcfr
ENH: Configure and install Slicer.crt as files to facilitates its reuse.

This change is done anticipating the Slicer certificates will be reused
from python by setting env variable like SSL_CERT_FILE.

Revision 24650  Directory Listing
Modified Wed Oct 21 02:02:22 2015 UTC (23 months ago) by jcfr
STYLE: Update SlicerCoreApplication::loadCaCertificates documentation

This commit updates the documentation to describe changes implemented
in r23555 (ENH: For sake of consistency, systematically load Slicer SSL
certificates)

Revision 24622  Directory Listing
Modified Thu Oct 8 17:15:57 2015 UTC (23 months, 2 weeks ago) by jcfr
STYLE: Update python scripts to not import from __main__

This commit simplifies the scripts removing extra `from __main__`
statements and improve the integration with Python IDE ensuring python
package like "slicer" can simply be imported.

The `from __main__` statement most likely became obsolete since
r24155 (ENH: Fixes #3549. Import scripted module as python module).

Remarks:

A global replace of "from __main__ import" into "import" as been done
except in:
 * EditOptions: "from __main__ getNodes" changed into "from slicer.util import getNodes"
 * slicer/module[dm|logic|mrml|widget]/__init__.py where it makes sense to keep it.

Revision 24621  Directory Listing
Modified Thu Oct 8 05:41:19 2015 UTC (23 months, 2 weeks ago) by jcfr
BUG: Fix incorrect truncation to integer in vtkSlicerTransformLogic

The rotation was incorrectly truncated to integer.

This commit fixes the following clang warnings:

Slicer/Base/Logic/vtkSlicerTransformLogic.cxx:718:59: warning: using integer absolute value function 'abs' when argument is of
      floating point type [-Wabsolute-value]
    rotateArrow->RotateX(vtkMath::DegreesFromRadians(acos(abs(sliceNormal_RAS[2])))); // TODO: check this, it might not be correct for an arbi...
                                                          ^

From: Hans Johnson <hans-johnson@uiowa.edu>

Revision 24615  Directory Listing
Modified Thu Oct 8 04:34:12 2015 UTC (23 months, 2 weeks ago) by lassoan
ENH: Make vtkAddon classes available in Python as vtkITK

Similarly to vtkITK make vtkAddon classes (vtkOrientedGridTransform, vtkOrientedBSplineTransform) easily accessible in Python.
One can now write: import vtkAddon (instead of import vtkAddonPython) to make classes available.

Revision 24611  Directory Listing
Modified Wed Oct 7 23:50:24 2015 UTC (23 months, 2 weeks ago) by jcfr
STYLE: Consistently use triple double-quoted string in python docstrings

From: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

Revision 24606  Directory Listing
Modified Tue Oct 6 17:20:06 2015 UTC (23 months, 2 weeks ago) by jcfr
COMP: KWSYS code for pre-C++98 STL is removed

Various work arounds for pre C++98 STL compilers
have been removed from KWSYS (and by extension, ITK).

For any C++98 or greater compliant compiler, these
constructs were simply aliases to the stl objects.

This is related to the changes made to
KWSYS(5f3fd465ecc0c2d78f7af2495dfe2604be90d4bd) by
Brad King in August 2015.

These changes will be needed when upgrading to ITK v4.9 or greater.

From: Hans Johnson <hans-johnson@uiowa.edu>

Revision 24599  Directory Listing
Modified Tue Oct 6 01:22:34 2015 UTC (23 months, 2 weeks ago) by jcfr
COMP: Fix build error in app logic when extension support is disabled.

In `vtkSlicerApplicationLogic::IsPluginBuiltIn` the variable
`Slicer_EXTENSIONS_DIRBASENAME` is not defined if the
`Slicer_BUILD_EXTENSIONMANAGER_SUPPORT` is false.

Also fix a warning due to unused variable `slicerRevision`
in `vtkSlicerApplicationLogic::IsEmbeddedModule` in the case
where the Extension Manager was not build.

Co-authored-by: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

From: Alexis Girault <alexis.girault@kitware.com>

Revision 24595  Directory Listing
Modified Mon Oct 5 03:06:56 2015 UTC (23 months, 3 weeks ago) by jcfr
BUG: Fix failing qSlicerUtilsTest1 on MacOSX

Since on mac the canonical path associated with a tmp folder
resolved to "/Private/tmp/...", this commit fixes the test by ensuring
both paths are in the same form.

Revision 24594  Directory Listing
Modified Fri Oct 2 23:44:49 2015 UTC (23 months, 3 weeks ago) by jcfr
ENH: Built-in module categories are listed separately in modules list

Modules that are loaded from the Slicer build/install tree are marked
as built-in, modules from different folders are not built-in. If a
non-built-in module adds a category, then it is shown above the built-in
categories, divided by a separator.

Fixes #3844

Co-authored-by: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

Reviewed-by: Andras Lasso <lasso@queensu.ca>
Reviewed-by: Andriy Fedorov <fedorov@bwh.harvard.edu>
Reviewed-by: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>
Reviewed-by: Sharp, Gregory C. <GCSHARP@mgh.harvard.edu>
Reviewed-by: Nicole Aucoin <nicole@bwh.harvard.edu>
Reviewed-by: Steve Pieper <pieper@isomics.com>

From: Csaba Pinter <csaba.pinter@queensu.ca>

Revision 24589  Directory Listing
Modified Fri Oct 2 21:48:34 2015 UTC (23 months, 3 weeks ago) by pieper
ENH: always be case sensitive when matching node names with fnmatch

when using fnmatch.fnmatch the case sensitivity depends on the
filesystem [1].  For matching used when finding slicer nodes and
qt widgets this variability does not make sense and may introduce
cross-platform bugs.  So we use fnmatch.fnmatchcase to ensure
the same behavior across platfroms.

https://docs.python.org/2/library/fnmatch.html

http://slicer-users.65878.n3.nabble.com/Capturing-mouse-events-tt4029365.html#none

From: Steve Pieper <pieper@bwh.harvard.edu>

Revision 24588  Directory Listing
Modified Thu Oct 1 22:07:12 2015 UTC (23 months, 3 weeks ago) by jcfr
COMP: Update Slicer and CTK to fix DCMTK windows build error.

This commit fixes windows build error and redefined warnings introduced
by the commit r24586 (ENH: Update DMCTK to use version DCMTK-3.6.1_20150924)

Related commits:
 * r24136 (STYLE: Update CTK to fix warning related to wrapping of CTKDICOM module)
 * r23955 (COMP: Workaround to fix HAVE_STAT redefined warning in SlicerDICOMExportDialog)
 * r23952 (COMP: Workaround to fix HAVE_STAT redefined warning in qSlicerCoreApplication)

CTK updates:

$ git shortlog 7199173..6453c27 --no-merges
Jean-Christophe Fillion-Robin (2):
      Workaround refined macro warning when building CTKDICOMWidgetsPythonQt
      Fix CTKDICOMWidgetsPythonQt windows build error undefining HAVE_INT64_T

Reported-by: Andriy Fedorov <fedorov@bwh.harvard.edu>
Thanks: Andras Lasso <lasso@queensu.ca>
Thanks: Jörg Riesmeier
Thanks: Michael Onken

Revision 24586  Directory Listing
Modified Wed Sep 30 14:21:47 2015 UTC (23 months, 3 weeks ago) by fedorov
ENH: Update DMCTK to use version DCMTK-3.6.1_20150924

The important improvements provided by the new version of DCMTK
is the support for new API that in particular greatly simplify creation of and
interaction with DICOM Segmentation image objects.

More specifically, it introduces the dcmiod, dcmfg and dcmseg classes
helpful in creating multiframe DICOM objects, such as segmentation and
parametric map objects.

Considering that standard and private dictionaries can now be  embedded
in DCMTK library, this commit partially reverts r24473 (ENH: Add support
for DCMTK private dictionary). The test DCMTKPrivateDictTest.py was updated to
not expect DCMDICTPATH environment variable that is no longer needed and is not
initialized.

List of DCMTK changes:

$ git shortlog 3366181..DCMTK-3.6.1_20150924 --no-merges

Andreas Thiel (1):
      Updated man pages for new development snapshot.

Jan Schlamelcher (86):
      Some workarounds for VC6 compiler peculiarity.
      Introduced OFunique_ptr as a fallback if std::unique_ptr is not available.
      Make use of  unique pointer (free memory if C-MOVE/C-FIND is canceled).
      Fixed dll build on windows.
      Correction of inconsistent previous commit.
      Fixed DcmSCPPool test case failing on older systems.
      Enabled shutdown functionality of DcmSCPPool.
      Fixed building with mingw-w64.
      Fixed most of the warnings in dcmjpeg.
      Fixed potential bug in dcmjpeg 12 and 16 bit variants.
      Marked SCPPool-Test (dcmnet_scp_pool) as exhaustive.
      Fixed most of the warnings in dcmdata.
      Fixed a mistake in CHANGES.361.
      Minor fixes in dcmdata.
      Added support for some C++11 types, literals and traits.
      Added documentation for the new macro "DOXYGEN".
      Fixed most of the warnings in ofstd and oflog.
      Added support for some additional C++11 traits.
      Introduced the new explicit boolean type OFExplicitBool.
      Fixed possibly wrong overload resolution in DSRCodedEntryValue.
      Minor fixes (whitespace and line ending errors).
      Modified DcmQuantColorHashTable to perform lazy initialization.
      Introduced OFoptional, implementing optional types.
      Renamed DoxygenLayout.xml to comply with filename conventions.
      Minor fixes and workarounds for Microsoft's compilers.
      Fixed ofstd_tatof error on older MSVC versions.
      Fixed DCMTK-Exports for custom module setups.
      Fixed and suppressed some warnings.
      Added 'DCMTK_USE_CXX11_STL' and 'DCMTK_CXX11_FLAGS'.
      Updated manpages.
      Updated DCMTK_ABI_VERSION for new development snapshot.
      Clarified an ambiguous configure message.
      Removed misleading comment in dcmjpeg.
      Fixed a wrong type-alias for OFintegral_constant.
      Introduced C++11-like alignment support.
      Fixed an alignment problem in OFoptional.
      Fixed building 32 bit targets with mingw-w64.
      Refined definition of numeric types and traits.
      Fixed a problem with Microsoft Safe CRT in oflog.
      Fixed a bug in dcmdata.
      Introduced DcmOutputBufferStream::filled() method.
      Fixed a problem in storescp.
      Modified some of OFoptional's comparison operators.
      Introduced OFtuple implementing generic tuples.
      Introduced move emulation for pre C++11 compilers.
      Small fixes for a previous commit about OFtuple.
      Several fixes and additions for yesterday's commits.
      Reintroduced bugfix-comment in dcmjpeg.
      Fixed autoconf install regarding ofstd variadic.
      Introduced OFnumeric_limits.
      Several fixes regarding OFnumeric_limits.
      Fixed possible arith.h generation problem on MinGW.
      Introduced basic support for assisted cross compiling.
      Fixed some problems regarding DCMTK's C++11 support.
      Added support for trusted client certificates.
      Adjusted DCMNET's default socket buffer length.
      Introduced cross compiling support for Android.
      Fixed a const correctness problem within DCMTLS.
      Introduced check-exhaustive targets to Autoconf.
      Corrections regarding recent commits.
      Modified CMake minimum version as required.
      Revised cleanup of temporary unit test files.
      Updated Autoconf dependencies.
      Updated man pages for new development snapshot.
      Updated DCMTK_ABI_VERSION for new development snapshot.
      Fixed a CMake problem with paths containing spaces.
      Moved some utility functions inside OFStandard.
      Modified fallback implementation of OFtuple.
      Added additional configuration methods for DCMTLS.
      Updated Makefile dependencies.
      Updated DCMTK_ABI_VERSION for new development snapshot.
      Moved CHANGES.361 to /docs.
      Updated Doxygen configuration files.
      Updated man pages.
      Updated default compiler flags.
      Refactored handling of some <cmath> functions.
      Fixed problems with previous commit.
      Fixed cross compiling via MinGW and Wine.
      Fixed building on FreeBSD.
      Fixed building on FreeBSD with C++11 enabled.
      Fixed inconsistent defines in CMake's osconfig.h.
      Fixed a problem in DcmAttributeFilter's unit test.
      Fixed building via GCC 4.2 on OpenBSD.
      Updated man pages for new development snapshot.
      Updated DCMTK_ABI_VERSION for new development snapshot.
      Updated CHANGES.361 for new development snapshot.

Joerg Riesmeier (511):
      Added support for CP-1236 to data dictionary.
      Added support for CP-1236 to checkAndUpdateVR() method.
      Added support for Supplement 154 to the data dictionary.
      Added support for new SOP Class UIDs from Supplement 154.
      Added support for directory record type "SURFACE SCAN".
      Added new SOP Class UID from Supplement 162.
      Added missing assignment of member variable.
      Added full support for the new Comprehensive 3D SR IOD.
      Fixed various issues in syntax usage output.
      Minor fixes in comments, e.g. typos.
      Minor fixes in comments. Also made some input parameters "const".
      Use non-throwing new and delete operator.
      Fixed two possible memory leaks.
      Added comment to variable that is currently unused.
      Fixed issue with odd-length pixel data.
      Added missing sub-directory to "make install" target.
      Added some debug output to lookForXfer() method.
      Added some debug output to read() method.
      Added new print options for SOP class output.
      Added new command line options for print output.
      Fixed bug in checkSOPClassUID() method.
      Added note on support for shared libraries.
      Added support for CP-1246 and CP-1249 to data dictionary.
      Fixed some tag key constants of recently retired attributes.
      Fixed issue with unnecessary call to clearNodeCursorStack().
      Added missing support for the new print options.
      Enhanced output to trace logger.
      Fixed inconsistencies introduced with last commit.
      Various fixes to comments. Removed trailing spaces.
      Added support for recently approved Correction Items.
      Enhanced documentation of complete flag methods.
      Added support for Supplement 157 to data dictionary.
      Added SOP Class UIDs from Supplement 157.
      Minor fixes to comments on VOI-related methods.
      Fixed bug in getTimeZoneFromString() method.
      Fixed issue with misplaced log output.
      Replaced "OFString::length() == 0" by "OFString::empty()".
      Replaced "OFString::length() != 0" by "!OFString::empty()".
      Replaced "OFString::length() > 0" by "!OFString::empty()".
      Added support for new VR "Other Double String" (OD)
      Added private tags for AGFA IMPACS 6.5.x Solution.
      Fixed wrong VR for private AGFA IMPAX tag.
      Updated version number of snapshot compilers.
      Added comment on inappropriate use of EC_IllegalCall.
      Fixed various oddities and inconsistencies:
      Replaced tabulator by space characters.
      Fixed various oddities and inconsistencies.
      Really call shouldStopAfterCurrentSOPInstance():
      Fixed further documentation issues.
      Removed trailing space characters.
      Fixed various typos.
      Added releaseAssociation() and abortAssociation()
      Fixed various typos and other Doxygen issues.
      Enable WITH_THREADS for thread-related classes.
      Added new condition constants.
      Fixed various typos.
      Use optional fields in sendSTOREResponse().
      Reimplemented sendSTOREResponse() method.
      Modified log output in loadAssociationCfgFile().
      Fixed issues with optional message fields.
      Removed unused fields from sendACTIONResponse().
      Added file missing for last commit :(
      Added progress notification to DcmSCP.
      Removed trailing spaces.
      Added global helper function createDirectory().
      Fixed some minor Doxygen issues.
      Added new class DcmStorageSCP.
      Added new command line tool "dcmrecv".
      Added comments to unused exit codes.
      Rebuilt Makefile dependencies.
      Updated man pages.
      Function createDirectory() also works on Windows:
      Updated CMake version.
      Fixed various typos.
      Deprecated closeAssociation() method.
      Added support for Supplement 163 to data dictionary.
      Added meta header to stored DICOM files.
      Fixed various typos in comments.
      Pass existing dataset to handleSTORERequest().
      Fixed various inconsistencies in comments.
      Do not copy received dataset in memory.
      Removed class name from derived method calls.
      Removed "&" from constant integer parameters.
      Fixed wrong log message in handleMOVERequest().
      Fixed various typos in comments.
      Restructured implementation of handleSTORERequest().
      Introduced dataset storage mode.
      Fixed various typos in comments.
      Receive C-STORE request dataset directly to file.
      Added new dataset storage mode.
      dded new storage mode options.
      Updated copyright dates (where appropriate).
      Added support for generating a Doxygen tag file.
      Fixed wrong Doxygen reference to a method.
      Minor fixes, e.g. added Doxygen markup.
      Fixed issue with CP-246 files and private tags.
      Slightly changed output of print() method.
      Added new print flag for showing invalid codes.
      Added new option for printing invalid codes.
      Added missing references to closed DCMTK features.
      Fixed typos.
      Added support for <InlineBinary> XML element.
      Clarified use of writeXML() flags.
      Fixed typo copied from Supplement 163.
      Output a warning message if the VR is unknown.
      Output currently processed line of input file.
      Removed superfluous footnote symbol "(*)".
      Fixed various coding style issues.
      Added trace log message on VR replacement.
      Added two new global flags for VR generation.
      Made use of new global flags for VR generation:
      Updated our email address for bug reports.
      Updated to autoconf 2.69.
      Added definition of DCMTK_PACKAGE_URL.
      Added Doxygen tag file to .gitignore.
      Added *.patch files to .gitignore.
      Also updated autoconf support files.
      Updated automake script to version 1.14.
      Fixed typos.
      Fixed various typos.
      Fixed various typos in comments.
      Added method to determine SpecificCharacterSet.
      Added 'charset' parameter to checkStringValue().
      Added new variant of checkElementValue().
      Avoid unnecessary copies of sequence elements.
      Enhanced implementation of checkCode() method.
      Report warning on unsupported character set.
      Use helper function findAndGetSequence().
      Updated comment on current character set issue.
      Fixed memory leak in log4cplus code.
      Minor fixes in comments.
      Minor changes to comments.
      Updated Doxygen configuration files.
      Removed outdated custom CSS file.
      Updated URL of DCMTK's home page.
      Fixed timeout issue in handleAssociation().
      Fixed source code formatting and various comments.
      Fixed wrong content type of XML element in DTD.
      Do not output group length in Native DICOM Model.
      Fixed outdated comment on 1st PN component group.
      Removed redundant API comment.
      Added support for CP-1268 to data dictionary.
      Added support for Supplement 168 to data dictionary.
      Added support for new UID from Supplement 168.
      Never output NULL bytes to markup string/stream.
      Adapted test cases for markup conversion.
      Iterate more efficiently over sequence items.
      Use helper method for deleting data elements.
      Added comments on missing features.
      Fixed small typos in comments.
      Added support for Real World Value Mapping objects.
      Added comment on getFrameList() method.
      Moved checkCurrentValue() to "protected" section.
      Slightly enhanced comments.
      Check return value of write() methods.
      Added support for Referenced Segment Number.
      Updated CMake version.
      Fixed small issue reported by CMake 2.8.12.
      Added Corneal Topography Map Storage SOP Class.
      Fixed bug that could cause a crash.
      Fixed doubled output of XML start tag for VR=OD.
      Added comment on wrong color model for icon images.
      Fixed issue with color icon images.
      Removed trailing white spaces from man pages files.
      Fixed build issue with shared libraries (Win32).
      Avoid CMake warning on non-installable files.
      Added missing break statements to switch cases.
      Removed redundant and outdated Word document.
      Added global flag for disabling the VR checker.
      Added new option for disabling the VR checker.
      Fixed minor Doxygen-related issue in documentation.
      Fixed name of PN component in Native DICOM Model.
      Fixed minor Doxygen-related issue in documentation.
      Fixed issue with test "ofstd_markup_6" (Win32).
      Fixed various typos in man pages.
      Fixed output of AT values in Native DICOM Model.
      Do not check valueLoaded() for Native DICOM Model.
      Completed support for <InlineBinary> XML element.
      Second try to fix the issue with "ofstd_markup_6".
      Fixed typos, comments and coding style.
      Replaced deprecated DcmSCU::closeAssociation().
      Removed check on number of command line arguments.
      Cleaned up source code in various aspects.
      Again, fixed comments to be consistent with code.
      Fixed comments and documented default values.
      Added support for recently approved CPs.
      Added support for Supplement 165 to data dictionary.
      Added support for new UIDs from Supplement 165.
      Fixed wrong/missing comment on method parameter.
      Fixed various minor documentation issues.
      Added missing module dcmrt to include directories.
      Removed comment on UID_HangingProtocolStorage.
      Added support for approved but still missing CPs.
      Added comments on some ACR/NEMA attributes.
      Fixed timeout issue in DIMSE_moveUser().
      Fixed typos in comments.
      Moved ACR/NEMA data dictionary to a separate file.
      Fixed issue with wrong check on stream compression.
      Fixed wrong VR for some retired command fields.
      Consistently use upper case letters for DICOM tags.
      Added new test cases for testing helper functions.
      Fixed typo and added comment.
      Added OFFilename versions to some helper functions.
      Added new helper function for renaming files.
      Added function for appending filename extension.
      Added wide character support to this tool.
      Added new helper function for copying files.
      Changed file mode bits back from "0755" to "0644".
      Fixed typo in comment.
      Added new command line option --create-backup.
      Avoid passing invalid values to rename().
      Avoid passing NULL to OFString, which is deprecated.
      Added support for wide chars to DICOMDIR code.
      Fixed issue when compiled with wide char support.
      Added new condition constant and fixed typo.
      Fixed issue with missing terminating NULL byte.
      Always use OFFilename() instead of "" as a default.
      Use printError() instead of OFLOG_FATAL().
      Fixed further issues with wide char support.
      Allow empty file-set ID in DICOMDIR (type 2).
      Fixed some comments.
      Fixed wrong tag in CodingSchemeIdentificationSequence.
      Made installation of tag file optional.
      Added another addContentItem() method.
      Replaced tabs by spaces and fixed indention.
      Fixed various issues in Doxygen comments.
      Fixed various minor issues in new helper class.
      Rebuilt Makefile dependencies.
      Added missing data elements to BD profiles.
      Added check for Shared Functional Groups Sequence.
      DIMSE_createFilestream() now uses an OFFilename.
      Fixed various typo.
      Pass OFString to DIMSE_createFilestream().
      Added support for CP-1090 to the data dictionary.
      Fixed issue with automatically generated classes.
      Removed superfluous quotations marks.
      Fixed small typos in comments.
      Added readPatientData() and readStudyData().
      Updated outdated comments on "log stream".
      Made sure that header file is parsed by Doxygen.
      Made sure that "Files" section is available.
      Added further header files to Doxygen documentation.
      Added support for recently approved CPs.
      Fixed some issues with wide character support.
      Added test for OFStandard::appendFilenameExtension().
      Fixed issue with untyped NULL reported by MSVC++.
      Fixed various typos in comments.
      Enhanced removeRootDirFromPathname() function.
      Enhanced createDirectory() function.
      Use non-throwing new and delete operator.
      Fixed typo in comment.
      Output to debug logger if memory allocation fails.
      Simplified creation of temporary DICOMDIR file.
      Optionally disable isFilenameValid() check.
      Added support for new UIDs from Supplement 124.
      Added support for Supplement 124 to data dictionary.
      Removed superfluous member initialization.
      Fixed typo in comments.
      Added support for determining the FrameTime.
      Access the (total) number of frames in an image.
      Fixed inconsistent parameter type.
      Added explicit type casts to avoid warnings.
      Fixed inconsistent parameter type.
      Updated data dictionary for DICOM 2013 edition.
      Fixed typos in comments.
      Added further error handling options.
      Fixed typos in comments.
      Fixed typos, added missing documentation, etc.
      Various minor fixes for development version.
      Fixed typos in comments.
      Made sure that the move originator is cleared.
      Fixed issue with text alignment in PatternLayout.
      Fixed some Doxygen related issues (and a typo).
      Consistently use "presInfo" for variables/parameters.
      Added support for Supplement 159 to data dictionary.
      Added support for new UID from Supplement 159.
      Added support for new SR IOD from Supplement 159.
      Added DcmSCP::abortAssociation() method.
      Fixed typo and updated copyright date.
      Removed meaningless layout file setting.
      Renamed Doxygen's layout file again.
      Made sure that header file is parsed by Doxygen.
      Group condition constants in Doxygen output.
      Avoid full directory path in Doxygen footer.
      Replaced CMake variable in Doxygen config file.
      Removed outdated comment on DICOM 2008 standard.
      Added missing empty line.
      Fixed typos and other minor issues.
      Updated reference to DICOM standard edition.
      Updated DCMTK's copyright date.
      Added support for CP-1125 to SR implementation.
      Fixed incomplete #include comment.
      Added support for recently approved CPs.
      Updated comment based on CP-1335.
      Added support for new Colon CAD SR constraints.
      Fixed various typos and minor Doxygen issues.
      Updated data dictionary for DICOM 2014a edition.
      Removed year component from version field.
      Minor fixes to file's comment header.
      Updated copyright date and other minor changes.
      Implemented copy constructors and added clone().
      Added explaining comment on new copy constructor.
      Removed outdated CMake exclude pattern.
      Excluded "*.md5" files from installation.
      Made sure that all top-level nodes are deleted.
      Added method counting the number of nodes.
      Added two new convenience functions.
      Fixed issue with tests run in different order.
      Fixed various Doxygen-related issues.
      Introduced new class DSRDocumentSubTree.
      Implemented copy constructors for tree classes.
      Added getPreviousNode() and getChildNode().
      Added further checking methods to cursor class.
      Added gotoFirst() and gotoLast() methods.
      Minor fixes on "const" declaration of pointers.
      Added cloneSubTree() method to tree classes.
      Changed return type of addContentItem(node*).
      Reimplemented various getXXX() methods.
      Cleaned up handling of "unknown" relationships.
      Restructured classes for nodes and trees.
      Fixed a bug in convertNewlineCharacters().
      Added insertSubTree() method to subtree class.
      Added checking of IOD-specific constraints.
      Fixed two memory leaks in recently added code.
      Clarified use of template identification.
      Removed DLL specifier from template classes.
      Slightly enhanced layout of Doxygen documentation.
      Added public method to change SR document type.
      Fixed wrong term in Doxygen documentation.
      Added removeSubTree() method to subtree class.
      Added extractSubTree() method to tree classes.
      Enhanced support for by-reference relationships.
      Further enhanced by-reference relationships.
      Insert a subtree into an empty document tree.
      Added dcmIsImageStorageSOPClassUID() function.
      Added check on valid "IMAGE" SOP Classes.
      Added support for optional JPEG fill byte.
      Removed misleading comment from checkStringValue().
      Fixed typos in comments and other minor issues.
      Added support for new value representation "UR".
      Updated data dictionary for DICOM 2014b edition.
      Added functions to enable/disable post-1993 VRs.
      Enhanced rewriting rules in DcmVR::getValidEVR().
      Use new VR "UR" for Pixel Data Provider URL.
      Fixed typo in method name.
      RLE images should not use multiple fragments.
      Added missing documentation for --propose-deflated.
      Attribute (0040,4005) has not been retired.
      Fixed wrong term "Device Driving Level".
      Updated "dcmrt" classes based on DICOM 2014b.
      Added "data correction" options to findscu.
      Fixed issue when scaling certain images.
      Removed unneeded header include.
      Fixed typo in comment.
      Fixed wrong validation of PN, LO and SH values.
      Added check for requirements clarified by CP-1401.
      Updated data dictionary for DICOM 2014c edition.
      Added support for new UIDs from DICOM 2014c.
      Fixed typo in comment.
      Added new temporarily generates files.
      Use "try and catch" block around new[].
      Fixed error handling in detachValueField().
      Fixed error handling in changeValue().
      Added new test case for VR=FD.
      Changed attribute used for the "FD" test.
      Added support for new value representation "UC".
      Added support for recently approved CPs.
      Added Mapping Resource UID from CP-1417.
      Removed outdated name suffix from EXS_xxx constant.
      Added missing standard include for assert().
      Fixed another CMake 3.1.x quotation issue.
      Updated latest tested CMake version.
      Fixed documentation of default TCP buffer length.
      Updated data dictionary for DICOM 2015a edition.
      Fixed typos in comments and other minor issues.
      Updated Makefile dependencies again.
      Updated outdated API documentation.
      Output message to logger on wrong pixel data class.
      Enhanced use of DSRCodingSchemeIdentificationList.
      Added support for recently approved CPs.
      Added support for Supplement 173 to dictionary.
      Added support for new UIDs from Supplement 173.
      Added support for recently approved CP-1425.
      Fixed test after after implementing CP-1425.
      Added further test cases for VR checker.
      Added read flag to all readXXX() methods.
      Optionally accept invalid content item values.
      Distinguish b/w invalid content items and values.
      Enhanced output to debug logger.
      Fixed wrong position counter in tree node.
      Added regression test for DSRTree::getPosition().
      Added method for counting number of child nodes.
      Fixed issue with VR checker for PN values.
      Fixed warning C4800 reported by Visual Studio.
      Updated data dictionary for DICOM 2015b edition.
      Ignore empty value for XML element 'charset'.
      Added support for optional Mapping Resource UID.
      Pass OFList parameter by-reference not by-value.
      Fixed issue with interpolation algorithm.
      Added hasTemplateIdentification() method.
      Replace the document tree of an SR document.
      Added initial support for SR templates.
      Added helpers for setting a value from dataset.
      Set observation date/time from dataset.
      Moved various methods to protected section.
      Added helpers for setting a value from element.
      Set observation date/time from element.
      Avoid using "check" parameter of SR code class.
      Introduced new error code "Unknow VR".
      Fixed source code and/or comment formatting.
      Do not check invalid UID values for IMAGE node.
      Added support for long code values (CP-1031).
      New class for "Basic Coded Entry Attributes".
      Fixed bug in time normalization code.
      Added missing empty() method to OFMap.
      Added new option for print() method.
      Added new comparison method to DSRCodedEntryValue.
      Made getAndRemoveRootNode() public.
      Fixed issue with addNode() in basic tree class.
      Added new and enhanced existing swap() function.
      Check whether a template is extensible.
      Added initial support for Supplement 186.
      Added initial support for Supplement 180.
      Made constructor and destructor "protected".
      Removed explicit name of base class from call.
      Added mechanism for remembering node positions.
      Added base class for context groups.
      Added initial version of DCM code definitions.
      Added first specific Templates and Context Groups.
      Updated "DCM" codes for DICOM 2015c edition.
      Updated data dictionary for DICOM 2015c edition.
      Fixed issue with wrong quotation marks.
      Added static initialization function (MT-safe).
      Fixed issue in OFStandard::combineDirAndFilename().
      Enhanced check on empty dataset.
      Improved documentation of disableXXXCheck().
      Consistently use "file-set" and "file format".
      Allow for disabling check on "DICOM file format".
      Renamed ANNOUNCE file (removed version suffix).
      Enhanced documentation of createNewSOPInstance().
      Added conversion operator to context group class.
      Added support for CID 42 (Numeric Value Qualifier).
      Added function that initializes all context groups.
      Updated copyright date.
      Fixed wrong documentation of return value.
      Removed superfluous OFStringStream_ends statement.
      Fixed wrong exit code on invalid input file.
      Added support for further Context Groups.
      Fixed various typos in comments.
      Enhanced handling of empty Measured Value Sequence.
      Added check for CID 42 to NUM values.
      Added support for Context Group CID 29.
      Added general information on coding scheme "DCM".
      Added easier method to set a composite reference.
      Fixed issue reported by Clang 3.5 on OpenBSD.
      Introduced condition constant EC_NotYetImplemented.
      Do not set empty concept name codes.
      Added missing DCMTK_DCMDATA_EXPORT macro.
      Added new helper method gotoEntryFromNodeList().
      Added method to look up a context group entry
      Added new mode for adding nodes to the tree.
      Fixed typos in comment.
      Added comment on reserved error codes (for "cmr").
      Fixed wrong comment.
      Introduced new flag to customize the print output.
      Added new command line options to dsrdump.
      Added specific logger for submodule "dcmsr/cmr".
      Added parameter "pos" to getStringValueFromDataset.
      Added static method setEnhancedEncodingMode().
      Clarified use of invalid coded entries.
      Added support for Context Group CID 244.
      Made sure that IOD constraint checker is used.
      Added "Extensible SR" to known document types.
      Added enhanced versions of CID 29, 244 and 4031.
      Added cleanup() function to context group classes.
      Fixed typo and other minor issues in comments.
      Added name prefix to class ContentMappingResource.
      Fixed copyright header in module "dcmsr".
      Added new optional parameter "vm" to readSequence.
      Added methods to read/write to/from sequence items.
      Fixed inconsistencies regarding the use of OFMap.
      Updated Makefile dependencies.
      Added enhanced versions of CID 10013 and 10033.
      Added initial version of SRT and UCUM codes.
      Introduced type for list of CID 7445 values.
      Updated Makefile dependencies.
      Added initial version of TID 1600 (Image Library).
      Slightly changed conversion operator.
      Extracted general information from template.
      Avoid seperator if time component is empty.
      Added support for annotating content items.
      Added support for Context Group CID 100 and 7021.
      Added support for clearing tree node annotations.
      Made sure that tree node annotations are copied.
      Made sure that "dicom.dic" is loaded for tests.
      Fixed various issues in test case.
      Fixed "cardinality" for SQ elements in comments.
      Added comment that "Big Endian" is retired.
      Removed version suffix "3" from dictionary entries.
      Check logger for debug output of template tree.
      Introduced global definitions for certain tags.
      Added CREDITS file.
      Added "YXLON" to the new CREDITS file.
      Added support for recently approved CPs.
      Added support for Supplement 156 to dictionary.
      Added support for new UIDs from Supplement 156.
      Check for recently approved multi-frame images.
      Updated currently supported compiler versions.
      Fixed various minor issues in module descriptions.
      Fixed order of modules in main HTML file.
      Added three new DCMTK modules to README.

Marco Eichelberg (5):
      Introduced OFStandard::dropPrivileges().
      Tools now use OFStandard::dropPrivileges().
      Fixed minor bug in DICOM upper layer FSM.
      Always use current dicom.dic for dcmdata unit tests.
      Removed unsupported wwwapps and perl scripts from module dcmwlm.

Michael Onken (84):
      Added (optional) originating C-MOVE AE title and message ID to C-STORE message.
      Make DcmStorageSCU make use of new MoveOriginator feature.
      Added optional status detail when sending C-MOVE response.
      Make sure memcpy does not copy to NULL destination. Thanks to Francesco Gigante     for the report.
      Added option to discard illegal characters when converting between     DICOM character sets.
      Add "Discard illegal character" support to dcmconv and classes like DcmItem.
      Make sure SCU and SCP request/response data structures are initially zeroed.
      Fixed typo (coersion -> coercion) in DIMSE status constant.
      Added missing kudos.
      Fixed too small buffer for UID in Q/R server.
      Fixed issues where JPEG marker map was not cleared if more than one JPEG     was converted using the same plugin instance.
      Fixed possible doubled destruction of association.
      Make sure oflog also compiles if threads are disabled.
      Always write meta header when receiving files. Removed Winsock comment.
      Added missing CHANGES entry.
      Warning to re-create index.dat after 20130705:
      Create DcmFileFormat from DcmDataset w/o copying.
      Do not copy DcmDataset during C-GET receive.
      Worklist SCP support for Responsible Person/Role.
      Replaced tabs with spaces.
      Support explicit item length denoting too many bytes.
      Corrected misleading transfer syntax error message.
      Fixed Comments.
      Described movescu storage SCP timeout problem.
      Make sure CMAKE_BUILD_TYPE has a default value.
      Fixed doubled tag output in XML output of VR OF.
      Avoid second OpenSSL initialization in constructor.
      Documentation for CMAKE_BUILD_TYPE default value.
      Fixed typo.
      Fixed CHANGES entries.
      Fixed some inconsistencies in documentation.
      Make sure to handle setuid() return code properly.
      Add libjpeg dependency for libtiff and minor changes.
      Fixed shared library build under Unix (configure).
      Enhanced DCMTK CMake exports for external projects.
      Capitalized all CMake key words for consistency.
      Ensure CMake v2.6 still writes DCMTKConfig.cmake.
      DCMTK.cmake and DCMTKTargets.cmake documentation.
      Added helpers to copy common modules between items.
      Fixed Makefile.dep for new files from last comit.
      Switched windows line endings to unix line endings.
      Added further module helpers and fixed small issues.
      Fixed comments and error message.
      Updated module helpers to latest DICOM 2013 draft.
      Fixed wrong ifdef syntax.
      Add connection timeout setting to SCU class.
      Fixed possible memory leak.
      Specific error if no presentation context proposed.
      Reverted false retirement status of some SOP Classes.
      Fix last commit by including implementation file.
      New compare() function for dcmdata object values.
      Make sure dcmdata tests compile with autoconf.
      Make new compare() method more reliable.
      Fixed conversion of color to palette color mode.
      Documented DCMTK's C++ cast macros.
      Fixed installation and added CHANGES file.
      Disable built-in dictionary for CMake Unix builds.
      Make sure presentation contexts do not interfer.
      Fixed iterator type.
      Introduced new modules dcmiod, dcmfg and dcmseg.
      Removed accidentially checked in test files.
      Removed more accidentially checked in test files.
      Fixed iterator dereference.
      Fixed iterator constness.
      Fixed possible DICOM VR problems.
      Removed unused method.
      Fixed mostly constness for some compilers.
      Fixed various doxygen formatting issues.
      Fixed compilers errors (mostly STL-specific).
      Removed unused link libraries.
      Made copyright header consistent in new modules.
      Build flags for internal and external dictionary.
      Updated dictionary build and code documentation.
      Added shared library export maro to IODModule.
      Added more files to be ignored by git.
      Added mising "check-exhaustive" targets.
      Replaced tab characters with spaces.
      Use static_cast instead of dynamic_cast.
      Renamed dictionary configuration build options.
      Simplified builtin dictionary infrastructure.
      Fixed typo in CMake script that can cause warnings.
      Fixed typo and made documentation more consistent.
      Fixed another typo.
      Enable private tags in builtin dictionary on CMake.

Nikolas Goldhammer (1):
      Replaced deprecated CMake expressions.

Uli Schlachter (13):
      Fixed wrong definition of Value Representation Person Name (PN)
      Removed unused local variable which shadowed a variable with the same name.
      Use ".NOTPARALLEL:" to make parallel builds (e.g. -j4) possible.
      Update rootconf for changes which were done directly to generated files.
      Fixed various issues found via cppcheck.
      Use DcmTagKey's output operator where possible.
      Don't include intrin.h on Visual Studio 2005 because of build errors.
      Fixed bug in OFString::copy() and improved unit tests.
      Fixed compiler warnings in ConvertIntegerToString with unsigned integers.
      Worked around compiler warnings on 32bit systems for too large shifts.
      Fixed crash if less than four transfer syntaxes are enabled.
      Silence some more compiler warnings about implicit casts.
      Don't set the defines for thread local storage support incorrectly.

Revision 24584  Directory Listing
Modified Tue Sep 29 21:48:06 2015 UTC (23 months, 3 weeks ago) by naucoin
ENH: remove doubled extenions before saving

Some nodes when they are read in by the node readers end up with names that
include the extension, such as vol.vp. This change ensures that the
known extension will not be added to the end of the name to create a file
name with a doubled extension, such as vol.vp.vp.
Fixed a typo in a variable name.

Issue #3956

Revision 24571  Directory Listing
Modified Tue Sep 22 15:31:31 2015 UTC (2 years ago) by msmolens
BUG: Fix libpng warnings in console when loading images with Qt 4.8.7

This commit eliminates the following libpng warning seen when loading certain
PNG images using libpng 1.6.x, which is included in Qt 4.8.7:

    libpng warning: iCCP: known incorrect sRGB profile

To fix the images I ran them through ImageMagick, which removes the incorrect
profiles, as suggested in [1]:

    convert image.png image.png

libpng 1.6.17 describes the warning in png.c line 2308:

    /* These profiles are known to have bad data that may cause
     * problems if they are used, therefore attempt to
     * discourage their use, skip the 'have_md5' warning below,
     * which is made irrelevant by this error.
     */

[1] http://stackoverflow.com/questions/22745076/libpng-warning-iccp-known-incorrect-srgb-profile

From: Max Smolens <max.smolens@kitware.com>

Revision 24569  Directory Listing
Modified Tue Sep 22 13:58:25 2015 UTC (2 years ago) by msmolens
ENH: Support writing scripted modules and widgets as new-style Python classes

This commit adds support for writing scripted module and widget classes as
new-style Python classes [1].

The motivation for this change is to allow widget classes to take advantage of
convenience classes such as VTKObservationMixin.

While old-style classes are used with PyClass_XXX and PyInstance_XXX functions
[2], new-style classes are used with PyType_XXX functions [3]. A new-style class
can be identified programatically by checking whether PyType_Check() returns
true. In C, like in Python code, calling the type creates an object; the
PyObject_CallXXX functions accomplish this [4].

The Python error that occurred when attempting to instanciate a new-style Python
module or widget class before this change was:

    SystemError: ../Objects/classobject.c:521: bad argument to internal function

Fixes the following issues:

    http://www.na-mic.org/Bug/view.php?id=1890:
    ("Python doesn't support new-style classes")

    http://www.na-mic.org/Bug/view.php?id=2994:
    ("Old style python classes in "Programming in Slicer4"? What's the superclass?")

[1] https://docs.python.org/2/reference/datamodel.html#newstyle
[2] https://docs.python.org/2/c-api/class.html
[3] https://docs.python.org/2/c-api/type.html
[4] https://docs.python.org/2/c-api/object.html

From: Max Smolens <max.smolens@kitware.com>

Revision 24564  Directory Listing
Modified Mon Sep 21 13:08:10 2015 UTC (2 years ago) by msmolens
BUG: Fix memory leaks associated with py_DTINotReproducibleIssue3977 test

In a debug build running py_DTINotReproducibleIssue3977 reports that a number of VTK
class instances leak.

This commit fixes a regression introduced in r24291 (ENH: Use vtkMRMLLabelMapVolumeNode
class for labelmap volumes) that caused leaks due to incorrect memory management on an
instance of vtkMRMLDiffusionTensorVolumeDisplayNode.

Fixes #4050

From: Max Smolens <max.smolens@kitware.com>

Revision 24558  Directory Listing
Modified Thu Sep 17 17:21:34 2015 UTC (2 years ago) by pieper
BUG: don't add keyword arguments to unittest.TestCase constructor

The superclass generates an error when the subclass has keyword
arguments it doesn't know.

Instead we enforce the default value when used.

For a subclass or a user or the class to change the value of this
instance variable they can just set it directly, as in:

self.messageDelay = 50

which can be done from anywhere in the code.

See discussion here:
http://massmail.spl.harvard.edu/public-archives/slicer-devel/2015/018624.html

Revision 24556  Directory Listing
Modified Thu Sep 17 13:12:45 2015 UTC (2 years ago) by lassoan
BUG: Fixed CLI module node GUI initial node selection

Fixes:
https://www.na-mic.org/Mantis/view.php?id=3240
https://www.na-mic.org/Mantis/view.php?id=3468

Revision 24553  Directory Listing
Modified Tue Sep 15 23:01:13 2015 UTC (2 years ago) by jcfr
STYLE: Facilitate integration with python IDE

This commit introduces slicer/kits.py and rename slicer/__init__.py.in
to slicer/__init__,py. This will facilitate integration with IDE like
PyCharm when simply adding the "Slicer/Base/Python" folder as dependent
project for scripted module.

Ideally, on platform supporting it, python script shouldn't be copied
into the build directory. Instead they should be symlinked similarly to
what is done with the option "develop" of setup.py or the option "--editable"
of pip.

Revision 24537  Directory Listing
Modified Mon Sep 14 17:23:55 2015 UTC (2 years ago) by jcfr
ENH: Display module name in qSlicerCLIProgressBar

This commit allows to display the name of the CLI module node in
the top left corner of the progressbar. This new feature follows
the same implementation than for the status visibility and the
progressbar visibility. By default the CLI Module node name is
always hidden.

Rational :

When creating a python module running a pipeline of CLI modules,
we usually link our main progressbar to the current CLI node.
This practice helps following the progress of one module, but was
lacking information regarding our progress in the whole pipeline.
Displaying the name of the CLI module node above the progressbar
allows for more explicit information.

From: Alexis Girault <alexis.girault@kitware.com>

Revision 24533  Directory Listing
Modified Sun Sep 13 03:19:13 2015 UTC (2 years ago) by lassoan
ENH: Added method to convert any transform to a grid transform

Useful for creating transforms that are compatible with software that cannot use inverse transforms or can only use grid transforms.

Revision 24527  Directory Listing
Modified Wed Sep 9 17:58:55 2015 UTC (2 years ago) by pieper
STYLE: fix typo in variable name and add some extra documentation

Revision 24523  Directory Listing
Modified Tue Sep 8 22:43:22 2015 UTC (2 years ago) by jcfr
BUG: Fix constructor of ScriptedLoadableModuleTest

This commit fixes a regression introduced in r24514 (ENH: allow self
tests to set a default message display) where the constructor
of the ScriptedLoadableModuleTest test case was specialized to set
a default value for messageDelay ivar.

Since the original constructor of a unittest.TestCase accept both
regular arguments and keyword arguments, constructor in derived class
have to use the form "*args, **kwargs".

This commit fixes the following tests:

  py_DTINotReproducibleIssue3977
  py_ColorsScalarBarSelfTest

Associated error was of the form:

//----------------
Traceback (most recent call last):
  File "/home/kitware/Dashboards/Nightly/Slicer-0-build/Slicer-build/lib/Slicer-4.4/qt-scripted-modules/ColorsScalarBarSelfTest.py", line 120, in runTest
    self.test_ColorsScalarBarSelfTest1()
  File "/home/kitware/Dashboards/Nightly/Slicer-0-build/Slicer-build/lib/Slicer-4.4/qt-scripted-modules/ColorsScalarBarSelfTest.py", line 124, in test_ColorsScalarBarSelfTest1
    self.delayDisplay("Starting the scalarbar test")
  File "/home/kitware/Dashboards/Nightly/Slicer-0-build/Slicer-build/bin/Python/slicer/ScriptedLoadableModule.py", line 269, in delayDisplay
    slicer.util.delayDisplay(message, msec)
  File "/home/kitware/Dashboards/Nightly/Slicer-0-build/Slicer-build/bin/Python/slicer/util.py", line 637, in delayDisplay
    qt.QTimer.singleShot(autoCloseMsec, messagePopup.close)
  File "/home/kitware/Dashboards/Nightly/Slicer-0-build/Slicer-build/bin/Python/slicer/slicerqt.py", line 74, in _singleShot
    timer.start( msec )
ValueError: Could not find matching overload for given arguments:
('test_ColorsScalarBarSelfTest1',)
 The following slots are available:
start(int msec)
start()
//----------------

Revision 24518  Directory Listing
Modified Thu Sep 3 14:28:50 2015 UTC (2 years ago) by cpinter
BUG: Fixed python module tests by calling base constructor for ScriptedLoadableModuleTest

Revision 24515  Directory Listing
Modified Tue Sep 1 18:00:04 2015 UTC (2 years ago) by jcfr
BUG: qSlicerNodeWriter: Default parameters allowed incorrect usage

This commit fixes the following warning obtained when compiling
using clang and c++11.

  Slicer/Modules/Loadable/Models/qSlicerModelsModule.cxx:165:44: warning: 'this' pointer cannot be null in
        well-defined C++ code; pointer may be assumed to always convert to true [-Wundefined-bool-conversion]
        QStringList() << "vtkMRMLModelNode", this));
                                           ^~~~

The 'this' pointer was interpreted as boolean.  To ensure complete proper
usage, the default parameters were removed, thus forcing compiler errors
that were easy to identify and fix.

From: Hans Johnson <hans-johnson@uiowa.edu>

Revision 24514  Directory Listing
Modified Mon Aug 31 15:43:23 2015 UTC (2 years ago) by pieper
ENH: allow self tests to set a default message display

The default message delay for self.delayDisplay for a scripted
module test is still 1 second, but can be set to a smaller value
to speed up testing.  It's still possible to override the delay
time on a per-call basis, for example to highlight transitions
between test sections by giving a longer timeout.

Revision 24500  Directory Listing
Modified Sat Aug 15 00:10:09 2015 UTC (2 years, 1 month ago) by pinter
BUG: Fixed crash when opening save dialog with node names starting with "#:"

Where # is not a drive letter, but a number, for example in case of DICOM series numbers. This commit fixes the scenario described in issue 3991, with the additional condition that the node was loaded from file.

Re #3991

Revision 24498  Directory Listing
Modified Thu Aug 13 22:21:47 2015 UTC (2 years, 1 month ago) by msmolens
BUG: Fix running self tests for scripted modules generated by Extension Wizard

An error occurs when running the self tests for certain scripted modules
through the SelfTests module GUI. For example, running the
SurfaceToolbox self test results in:

  NameError: name 'SurfaceToolboxTest' is not defined

The affected modules are those that inherit from ScriptedLoadableModule.
That includes all modules generated by Extension Wizard; see the
template.

This commit fixes how ScriptedLoadableModule finds and instantiates the
self test.

Additionally, for consistency with the above change, this commit changes
how the ScriptedLoadableModuleWidget runs the self test when the user
clicks "Reload and Test".

From: Max Smolens <max.smolens@kitware.com>

Revision 24483  Directory Listing
Modified Tue Aug 4 03:52:36 2015 UTC (2 years, 1 month ago) by fedorov
BUG: fix support for DCMTK DICOM dictionaries

See issue 4013, followup on commit 24473. Dictionaries passed to DCMTK in
DCMDICPATH override embedded dictionaries, and standard dictionary needs to be
specified together with the private one, as shown in example here:

http://support.dcmtk.org/redmine/projects/dcmtk/wiki/Howto_Dictionaries

This commit installs dicom.dic and initializes the environment variable.

Revision 24473  Directory Listing
Modified Wed Jul 29 23:44:26 2015 UTC (2 years, 1 month ago) by jcfr
ENH: Add support for DCMTK private dictionary

See issue 4013 and related discussion here:

  http://slicer-devel.65872.n3.nabble.com/Enabling-support-for-DCMTK-private-dictionary-td4034305.html

This change implements the following changes:

 (1) install private.dic of DCMTK in a runtime location

 (2) update launcher setting to set DCMDICTPATH environment
     variable

 (3) on MacOSX, update application to ensure DCMDICTPATH is set when
     Slicer is started using Slicer.app bundle (in that case no launcher
     is used)

This will allow for more robust interpretation of DICOM private tags
based on the information contained in the DCMTK private dictionary.

Co-authored-by: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

Revision 24465  Directory Listing
Modified Fri Jul 24 23:25:11 2015 UTC (2 years, 2 months ago) by jcfr
BUG: Ensure packaged Slicer.app MacOSX application find its Qt plugins

The assumption that an installed Slicer.app bundle would find and load the
file "Slicer.app/Contents/Resources/qt.conf" is wrong.

Since within "Application/SlicerApp/Main.cxx", both methods (a) "QSettings()"
and (b) "QApplication::setStyle()" are called before the QApplication
is instantiated, the "QLibraryInfoPrivate::findConfiguration()" was
not calling "CFBundleGetMainBundle()" and couldn't locate the "qt.conf"
file relatively to the Slicer.app directory.

As a consequence:
  (1) the correct plugin couldn't be loaded and
  (2) trying to run an installed Slicer.app in the environment where it
was build was failing because "QLibraryInfo::location()" was defaulting
to the plugin location associated with the build tree.

Since calling "QSettings()" and "QApplication::setStyle()" is not possible.
This commit implements a different strategy. It adds the "qt.conf" file to
the resource system (See [1] for details about this).

[1] http://doc.qt.io/qt-4.8/qt-conf.html

This approach will ensure:

 (1) the installed Slicer.app finds its plugin: "QLibraryInfoPrivate::findConfiguration()
 will check if the resource exists independently of the QCoreApplication
 instance.

 (2) the application in the build tree still work. The plugin will be found
 because of the path hardcoded in "QLibraryInfo::location()"

References:
 * https://forum.qt.io/topic/50305/qt-5-3-and-5-4-mac-application-crashes-on-startup-after-using-macdeployqt-app-unable-to-load-plugin-cocoa/7

Co-authored-by: Alexis Girault <alexis.girault@kitware.com>

Revision 24459  Directory Listing
Modified Tue Jul 21 21:13:45 2015 UTC (2 years, 2 months ago) by naucoin
ENH: support fiducial file transfer between Slicer and CLIs

Requires the updates to the SlicerExecutionModel to define the new XML
tag --pointfile, the pull request was merged, so the external project
file is updated.
Expands the application logic to support reading and writing fiducial files.
Expands the CLI module UI helper to create a fiducial node selection combo
box when a point file type is detected.
Expands the CLI module logic to manage fiducial files. Need to link to the
Markups storage node to set the coordinate system flag, and to remove a circular
dependency between the Markups Module and QTCLI, moved that class into Libs MRML Core.
Currently setting an attribute on the fiducial node to pass the coordinate
system flag along to ApplyTask where the files get written to disk.
Added CreateDefaultDisplayNodes for the fiducial node so it can be called for
output node setup.
Add input and output fiducial file examples with coordinate
systems set to LPS to the execution model tour.

Revision 24440  Directory Listing
Modified Fri Jul 17 05:00:49 2015 UTC (2 years, 2 months ago) by jcfr
BUG: Fix memory leak in vtkSlicerApplicationLogic

This commit fixes the error(s) reported below by valgrind memcheck tool.

Valgrind was used on Ubuntu 14.04 against a Debug build of Slicer. It was
exected doing the following:
 (1) Start a terminal with the appropriate environment: ./Slicer --gnome-terminal
 (2) Start Slicer using valgrind: valgrind --log-file=2015-07-16-Slicer-memcheck.txt --tool=memcheck --leak-check=yes ./bin/SlicerApp-real --disable-python --disable-cli-modules
 (3) Exit Slicer and inspect valgrind log file

Valgrind error:

==29339== 336 bytes in 1 blocks are possibly lost in loss record 2,088 of 2,448
==29339==    at 0x4C2CC70: calloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
==29339==    by 0x4012E54: _dl_allocate_tls (dl-tls.c:296)
==29339==    by 0x1E25BDA0: pthread_create@@GLIBC_2.2.5 (allocatestack.c:589)
==29339==    by 0x18D6A33E: itk::MultiThreader::SpawnThread(void* (*)(void*), void*) (itkMultiThreaderPThreads.cxx:186)
==29339==    by 0x9259575: vtkSlicerApplicationLogic::CreateProcessingThread() (vtkSlicerApplicationLogic.cxx:354)
==29339==    by 0x8E82DC8: qSlicerCoreApplicationPrivate::init() (qSlicerCoreApplication.cxx:255)
==29339==    by 0x59272A7: qSlicerApplicationPrivate::init() (qSlicerApplication.cxx:180)
==29339==    by 0x5927FDF: qSlicerApplication::qSlicerApplication(int&, char**) (qSlicerApplication.cxx:319)
==29339==    by 0x406039: (anonymous namespace)::SlicerAppMain(int, char**) (Main.cxx:125)
==29339==    by 0x406D30: main (Main.cxx:254)

Revision 24423  Directory Listing
Modified Wed Jul 15 18:23:29 2015 UTC (2 years, 2 months ago) by jcfr
ENH: Update wiki URLs in module panel to reference correct documentation.

For Slicer release, wiki pages in the X.Y namespace will be used, for
nightly build, pages in the Nightly namespace will be used used.

Revision 24422  Directory Listing
Modified Wed Jul 15 18:23:27 2015 UTC (2 years, 2 months ago) by jcfr
ENH: Extend qSlicerUtils API adding function to replace version in wiki urls

Revision 24421  Directory Listing
Modified Wed Jul 15 18:23:25 2015 UTC (2 years, 2 months ago) by jcfr
ENH: Extend core application API adding "isRelease" property.

Note that ideally the properties associated with "isRelease" and
"isInstalled" accessor functions should respectively be named "release"
and "installed". For sake of consistency and to maintain backward
compatibility, this new property is also named after its accessor function.

Revision 24420  Directory Listing
Modified Wed Jul 15 18:23:23 2015 UTC (2 years, 2 months ago) by jcfr
STYLE: Add missing space in CLI help text.

Revision 24415  Directory Listing
Modified Wed Jul 15 06:40:07 2015 UTC (2 years, 2 months ago) by jcfr
ENH: Extend IOManager to allow python script to invoke  "newFileLoaded" signal

Revision 24395  Directory Listing
Modified Tue Jul 7 17:54:42 2015 UTC (2 years, 2 months ago) by naucoin
BUG: update file list members, scene vars, update test

Update the MRB save/restore test to use the slicer util delayDisplay method,
as well as not counting file paths that point to the deleted bundle
expansion directory.
In scene view nodes make sure to also reset the file list
Restore the url and root direcotry after saving a scene to the data bundle
directory so that absolute paths can be calculatediproperly

Issue #3956

Revision 24390  Directory Listing
Modified Tue Jul 7 17:54:03 2015 UTC (2 years, 2 months ago) by naucoin
ENH: stress test saving and restoring MRBs, util methods added

Add a test to save and restore MRBs in a loop, fixing the bug note in the
save restore test as well.
Clean up the testing of saving and loading MRBs by exposing the core io
manager loadScene method to Python, and adding a saveScene one. This will
simplify testing since it uses detects that it needs to use the scene writer
which will use the application logic save to MRB bundle directory + zip calls,
so from python you won't need to make the two calls with attendant managing of
temporary directories. Added a note to the application logic header file
pointing to saveScene for general use.

Issue #3956

Revision 24388  Directory Listing
Modified Tue Jul 7 17:53:52 2015 UTC (2 years, 2 months ago) by naucoin
BUG: double check for dot preceding file suffixes

GUI testing showed that renaming a node could lead to a file name of label..nrrd,
this fix only adds the leading dot if the complete Slicer writable suffix call
doesn't start with it.

Issue# 3956

Revision 24385  Directory Listing
Modified Tue Jul 7 17:53:41 2015 UTC (2 years, 2 months ago) by naucoin
ENH: factor out adding data io to the scene

Encapsulated setting up the remote IO logic and the data manager IO
in the application so that it can work as an example template.
Moved the hooking up of the data logic to the scene to the application
logic so that it can be called by classes with access to the
application logic, and use it in the volumes logic for the mini
scene.
Added some comments to direct developers to the places they need
to look to hook up a mini scene that can do data management both
locally and remotely.

Issue #3956

Revision 24381  Directory Listing
Modified Tue Jul 7 17:53:20 2015 UTC (2 years, 2 months ago) by naucoin
BUG: function name clarification, add getting readable extensions

Thanks to comments from JC:
Renamed completeSlicerSuffix to ompleteSlicerWritableFileNameSuffix
in order to make it explicit that this was only checking writable extensions.
Renamed allFileExtensions to allWritableFileExtensions to be more clear
as well as adding the equivalent call for readable extensions, allReadableFileExtensions

Issue #3956

Revision 24380  Directory Listing
Modified Tue Jul 7 17:53:15 2015 UTC (2 years, 2 months ago) by naucoin
BUG: implement a Slicer specific Qt file suffix

In the MRML storage node it is dealing correctly with tricky
file names like brain.1.nii.gz to return the proper suffix. In
Qt we were relying on completeSuffix but that was returning
everything after the first dot in the file name and would fail
on that example case. This change leverages the storage nodes
to gather a list of valid file suffixes and compares them against
the file name endings and returns a matching one. Special case
included if .* is a valid Slicer suffix, that goes back to
Qt's completeSuffix call.
Note: tried calling fileWriterExtensions and ran into a crash
as it was trying to add new storage nodes to the scene.
Use the new suffix in the save data dialog and node writer.
Added testing, more file name cases can be added easily.

Issue #3956

Revision 24372  Directory Listing
Modified Tue Jul 7 17:52:48 2015 UTC (2 years, 2 months ago) by naucoin
BUG: check for compressed file names

Get the complete extension when files have paths that end in X.gz.
This fixes bugs that came from multiple saves where a file might
end up with the name brain.nii.nii.nii.nii.gz.

Issue #3956

Revision 24351  Directory Listing
Modified Fri Jun 19 22:06:26 2015 UTC (2 years, 3 months ago) by jcfr
ENH: Improve CLI image widget type handling

* show both LabelMap and scalar volume nodes if "scalar" type
is specified (to restore behavior before vtkMRMLLabelMapVolumeNode
was added)

* allow adding either vtkMRMLScalarVolumeNode or vtkMRMLLabelMapVolumeNode
if "scalar" type is specified

* allow adding of multiple output node types if "any" type is specified
as output

Reviewed-by: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

From: Andras Lasso <lasso@queensu.ca>

Revision 24349  Directory Listing
Modified Fri Jun 19 21:08:00 2015 UTC (2 years, 3 months ago) by jcfr
BUG: sitkUtils: Add 'LabelMap' to list of volume types supported by SimpleITK

This commit fixes support for vtkMRMLLabelMapVolumeNode added
in r24291 (ENH: Use vtkMRMLLabelMapVolumeNode class for labelmap volumes)

Fixes #4004

Revision 24347  Directory Listing
Modified Fri Jun 19 18:53:27 2015 UTC (2 years, 3 months ago) by jcfr
STYLE: Remove unused import statement from util.py

This commit removes an unused import statement introduced in r24320 (STYLE:
 Editor-helperBox: Add "getNodeByName()" to slicer.util and rename it)

Revision 24343  Directory Listing
Modified Fri Jun 19 04:12:32 2015 UTC (2 years, 3 months ago) by jcfr
BUG: String containing list of dependencies was not split. Fixes #4007

If one was creating an extension that depended on multiple other
extensions and was giving, as specified in the s4ext files, a list of
extensions separated by spaces, Slicer did not split that list when
looking for dependencies upon download, and was trying to find an
extension with all the names.

e.g. If your s4ext file contained the following line:

   depends     DTIProcess ResampleDTIlogEuclidean

Slicer was trying to resolve the dependencies and was trying
to find the extension named "DTIProcess ResampleDTIlogEuclidean",
instead of finding both extensions separately.

From: Francois Budin <fbudin@email.unc.edu>

Revision 24320  Directory Listing
Modified Wed Jun 17 15:44:19 2015 UTC (2 years, 3 months ago) by jcfr
STYLE: Editor-helperBox: Add "getNodeByName()" to slicer.util and rename it

Revision 24310  Directory Listing
Modified Wed Jun 17 15:43:57 2015 UTC (2 years, 3 months ago) by jcfr
BUG: VTKObservationMixin: Fix removeObservers method and add unittests

Revision 24304  Directory Listing
Modified Tue Jun 9 14:45:22 2015 UTC (2 years, 3 months ago) by lassoan
BUG: Fixed FOV reset during volume selection propagation

FOV of all slice views were reset during volume selection propagation. Even for views where volume selection propagation was disabled.

Fixes (at least partially) http://www.na-mic.org/Bug/view.php?id=4000

Revision 24302  Directory Listing
Modified Fri Jun 5 13:51:41 2015 UTC (2 years, 3 months ago) by lassoan
BUG: Attempt to fix py_nomainwindow_MRMLCreateNodeByClassWithSetReferenceCountToOne test

Revision 24294  Directory Listing
Modified Thu Jun 4 21:45:36 2015 UTC (2 years, 3 months ago) by pinter
BUG: Fixed save data dialog cras in case of certain node names

Save data dialog crashed if node name started with a non-drive-letter character followed by a colon. A zero is prepended to node names if it is in the form "1: Something", which is "cleaned up" by Qt to "1:\Something" on Windows, and crashes because the first character is not a letter in the path.

Fixed indentation issue in vtkSlicerApplicationLogic.cxx

Revision 24293  Directory Listing
Modified Thu Jun 4 21:28:22 2015 UTC (2 years, 3 months ago) by pinter
ENH: Added labelmap node support to subject hierarchy

Subject hierarchy knew about the single vtkMRMLScalarVolumeNode class, but now that the vtkMRMLLabelMapVolumeNode has been introduced, a separate subject hierarchy plugin was created for labelmaps. This way it is cleaner that one role plugin assigns one icon and the same set of functionality to its owned nodes.

Fixed issue in sitkUtils: it created a scalar volume node regardless whether a labelmap was already created

Removed temporary contour references from model slice displayable manager (segmentations has its own displayable manager)

Added concept of virtual subject hierarchy branches, which is a branch for which its parent is solely reaponsible, i.e. the child nodes do not correspond to actual MRML nodes, but to items contained in the parent node to enable per-item handling from subject hierarchy (e.g. segments in segmentations and fiducials in markups)

Create and expose cloneSubjectHierarchyNode method in qSlicerSubjectHierarchyCloneNodePlugin to enable easy cloning of any node (clone SH node, data node, display and storage nodes)

Revision 24291  Directory Listing
Modified Thu Jun 4 20:12:02 2015 UTC (2 years, 3 months ago) by lassoan
ENH: Use vtkMRMLLabelMapVolumeNode class for labelmap volumes

Before vtkMRMLScalarVolumeNode was used for both scalar and label map
volumes and the LabelMap custom MRML node attribute was used for
distinguishing between them (0=scalar; 1=label map volume).
This made conversion between labelmap/scalar volumes very easy but made
it difficult to customize behavior, display, processing of segmentation
information.

Now a new vtkMRMLLabelMapVolumeNode class is used for storing segmentation
information (still using vtkMRMLScalarVolume used as base class for backward
compatibility; but in the future the base class may be changed to reflect
that segmentation can be represented in various ways, not just as volumes).

Notes:

A new "segmentation" node has been developed that is based on vtkMRMLLabelMapVolumeNode,
which can store segmentation information in various ways (not just labelmaps but planar
contours, closed surfaces, etc). To allow using of this new segmentation node,
first the vtkMRMLLabelMapVolumeNode has to be integrated into the Slicer core.

When reading a scene that was saved with an old version of Slicer, label maps are stored
in vtkMRMLScalarVolumeNode with label map attribute set to 1. Added a check for this case
and handle it by converting the vtkMRMLScalarVolumeNode to a vtkMRMLLabelMapVolumeNode during import.

Revision 24270  Directory Listing
Modified Wed May 20 18:19:15 2015 UTC (2 years, 4 months ago) by lassoan
BUG: Fixed application information logging

displayApplicationInformations() was called in qSlicerApplication before initializing the logging.
Therefore the application information (that is essential for troubleshooting) was not included in the application log.

Revision 24250  Directory Listing
Modified Wed May 13 13:22:32 2015 UTC (2 years, 4 months ago) by lassoan
ENH: Made default startup and favorite module configurable

When building custom applications based on Slicer it is often required to change the default startup module (Welcome) and favorite modules (on toolbar). Made these settings configurable from CMake, without requiring patching of source files.

Revision 24239  Directory Listing
Modified Mon May 11 23:06:50 2015 UTC (2 years, 4 months ago) by jcfr
BUG: Ensure scripted module are deleted when exiting Slicer

Similarly to what was done in r24230 (ENH: Ensure slicer.(modules|moduleNames)
is updated when a module is unloaded), this commit also ensures that
"slicer.selfTests" dictionary is updated when a module is unloaded.

This change has been tested by adding a print statement in the "__del__"
function of both the script module and module widget python class for the
DataProbe, Editor and Endoscopy module.

After this change, it could only confirm that the "__del__" function for
the module class was called for all three modules. More work is required
to also ensure the scripted module widget class is deleted.

Instead of explicitly updating the selfTests dict, an other possible
approach would be to use a WeakValueDictionary [1]

[1] https://docs.python.org/2/library/weakref.html#weakref.WeakValueDictionary

Revision 24238  Directory Listing
Modified Mon May 11 23:06:48 2015 UTC (2 years, 4 months ago) by jcfr
BUG: Fix SliceViewAnnotations AttributeError happening on closing Slicer

This commit fixes the following error introducing a weak pointer to keep
track of the layout manager.

8<----8<----8<----8<----8<----8<----8<----8<----8<----8<----8<----8<----
File "/home/jcfr/Projects/Slicer-Debug/Slicer-build/lib/Slicer-4.4/qt-scripted-modules/DataProbeLib/SliceViewAnnotations.py", line 628, in updateCornerAnnotations
  sliceViewNames = slicer.app.layoutManager().sliceViewNames()
AttributeError: 'NoneType' object has no attribute 'sliceViewNames'
8<----8<----8<----8<----8<----8<----8<----8<----8<----8<----8<----8<----

Revision 24236  Directory Listing
Modified Mon May 11 23:06:45 2015 UTC (2 years, 4 months ago) by jcfr
BUG: Fix potential leaks in qSlicerPythonCppAPI using PythonQtObjectPtr

This commit introduces PythonQtObjectPtr to manage PythonSelf
and PythonAPIMethods references.

Revision 24235  Directory Listing
Modified Mon May 11 23:06:43 2015 UTC (2 years, 4 months ago) by jcfr
BUG: Fix leaks in qSlicerScriptedLoadableModule[Widget]::setPythonSource()

Since PyDict_New() and PyObject_GetAttrString() return a new reference,
this commit now ensures the reference count is decremented when getting
out of scope.

Revision 24234  Directory Listing
Modified Mon May 11 23:06:41 2015 UTC (2 years, 4 months ago) by jcfr
STYLE: Facilitate debugging associating ObjectName with qSlicerPythonCppAPI

This commit improves error message by displaying the name of the object
that instantiated the qSlicerPythonCppAPI.

Revision 24233  Directory Listing
Modified Mon May 11 02:51:45 2015 UTC (2 years, 4 months ago) by jcfr
ENH: Refactor scripted module classes to use setModuleAttribute()

Revision 24232  Directory Listing
Modified Mon May 11 02:51:43 2015 UTC (2 years, 4 months ago) by jcfr
ENH: Refactor addVTKObjectToPythonMain to use setModuleAttribute()

Revision 24231  Directory Listing
Modified Mon May 11 02:51:41 2015 UTC (2 years, 4 months ago) by jcfr
ENH: Introduce qSlicerScriptedUtils::setModuleAttribute()

Revision 24230  Directory Listing
Modified Mon May 11 02:51:38 2015 UTC (2 years, 4 months ago) by jcfr
ENH: Ensure slicer.(modules|moduleNames) is updated when a module is unloaded

Explicit call to "unloadModules()" in qSlicerCoreApplicationPrivate
destructor ensures the signal "moduleAboutToBeUnloaded()" is invoked.

Revision 24226  Directory Listing
Modified Mon May 11 02:51:30 2015 UTC (2 years, 4 months ago) by jcfr
ENH: Associated docstring with "slicer.(modules,moduleName)" python modules

This commit introduces the help function "_createModule()". Note that
module are now added to 'sys.modules' dictionary. This will allow
call to "import slicer.modules" to succeed.

Revision 24186  Directory Listing
Modified Wed Apr 22 12:41:12 2015 UTC (2 years, 5 months ago) by pieper
ENH: fix Diffusion dicom plugin; add utility function

* use a temp directory to isolate the diffusion series
so as not to confuse DWIConvert with dicom files that
are not part of the diffusion scan.

* increase the priority so that scans recognized as diffusion will
preferentially load using the converter.

* fix usage of DICOMLib

* add slicer.util.tempDirectory to easily access a scratch
area.

From: Steve Pieper <pieper@bwh.harvard.edu>

Revision 24181  Directory Listing
Modified Sat Apr 18 05:05:28 2015 UTC (2 years, 5 months ago) by jcfr
ENH: Display application information only if starting the application.

If command line argument like "--help", "--version", "--program-path",
"--home", "--settings-path" or "--temporary-path" are used, application
infos will not be displayed.

Revision 24180  Directory Listing
Modified Sat Apr 18 05:05:26 2015 UTC (2 years, 5 months ago) by jcfr
STYLE: Simplify code introducing displayMessageAndExit()

Revision 24179  Directory Listing
Modified Sat Apr 18 05:05:23 2015 UTC (2 years, 5 months ago) by jcfr
STYLE: Fix doxygen comment associated with displayTemporaryPathAndExit()

Revision 24178  Directory Listing
Modified Sat Apr 18 05:05:21 2015 UTC (2 years, 5 months ago) by jcfr
STYLE: Mark qSlicerCommandOptions readonly Qt properties as CONSTANT

From Qt documentation:

The presence of the CONSTANT attribute indicates that the property value
is constant. For a given object instance, the READ method of a constant
property must return the same value every time it is called. This constant
value may be different for different instances of the object. A constant
property cannot have a WRITE method or a NOTIFY signal.

Revision 24177  Directory Listing
Modified Sat Apr 18 05:05:19 2015 UTC (2 years, 5 months ago) by jcfr
STYLE: Nicely pad information logged at startup.

After this commit:

// --------------
Session start time .......: 2015-04-17 17:40:37
Slicer version ...........: 4.4.0-2015-04-13 (revision 24173) linux-amd64 - not installed
Operating system .........: Linux / 3.13.0-45-generic / #74-Ubuntu SMP Tue Jan 13 19:36:28 UTC 2015 - 64-bit
Memory ...................: 7975 MB physical, 0 MB virtual
CPU ......................: GenuineIntel 1.199 MHz, 1 cores
Developer mode enabled ...: no
Prefer executable CLI ....: no
Additional module paths ..: (none)
// --------------

Before this commit:

// --------------
Session start time: 2015-04-17 17:40:37
Slicer version: 4.4.0-2015-04-13 (revision 24173) linux-amd64 - not installed
Operating system: Linux / 3.13.0-45-generic / #74-Ubuntu SMP Tue Jan 13 19:36:28 UTC 2015 - 64-bit
Memory: 7975 MB physical, 0 MB virtual
CPU: GenuineIntel 1.199 MHz, 1 cores
Developer mode enabled: no
Prefer executable CLI: no
Additional module paths: (none)
// --------------

Revision 24176  Directory Listing
Modified Sat Apr 18 05:05:17 2015 UTC (2 years, 5 months ago) by jcfr
STYLE: Fix indent in qSlicerApplication

Revision 24173  Directory Listing
Modified Mon Apr 13 15:07:19 2015 UTC (2 years, 5 months ago) by jcfr
BUG: Prevent crash in vtkSlicerApplicationLogic checking pointer validity

From: Andras Lasso <lasso@queensu.ca>

Revision 24172  Directory Listing
Modified Mon Apr 13 15:07:18 2015 UTC (2 years, 5 months ago) by jcfr
STYLE: Simplify memory management in vtkSlicerApplicationLogic

From: Andras Lasso <lasso@queensu.ca>

Revision 24169  Directory Listing
Modified Mon Apr 13 15:07:13 2015 UTC (2 years, 5 months ago) by jcfr
STYLE: Fix indentation in vtkSlicerApplicationLogic

From: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

Revision 24166  Directory Listing
Modified Thu Apr 9 08:15:27 2015 UTC (2 years, 5 months ago) by jcfr
STYLE: Fix typos in qSlicerLoadableModule doxygen comments

From: Sergey Aleshin <4memph@gmail.com>

Revision 24161  Directory Listing
Modified Thu Apr 9 02:12:39 2015 UTC (2 years, 5 months ago) by jcfr
ENH: Extend ModulePanel API to control if Help&Ack section is visible

This commit adds the property allowing to programmatically show/hide
the Help & Acknowledgment collapsible button within the ModulePanel
widget.

If the current module doesn't have a help string, the section will remain
hidden.

Co-authored-by: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

From: Sergey Aleshin <4memph@gmail.com>

Revision 24155  Directory Listing
Modified Sat Apr 4 00:42:28 2015 UTC (2 years, 5 months ago) by jcfr
ENH: Fixes #3549. Import scripted module as python module

This will allow each scripted module to defined top-level variables that
will not clobber each other.

For example, if we consider these two modules:

8<----8<----8<----8<----8<----8<----8<----8<----
File: ModuleA.py

FOO = 1

class ModuleA(ScriptedLoadableModule):
  def __init__(self, parent):
    ModuleA.__init__(self, parent)
    [...]
  def doSomething(self):
    if FOO == 1:
      [...]
    else:
      [...]
8<----8<----8<----8<----8<----8<----8<----8<----

8<----8<----8<----8<----8<----8<----8<----8<----
File: ModuleB.py

FOO = 2

class ModuleB(ScriptedLoadableModule):
  def __init__(self, parent):
    ModuleB.__init__(self, parent)
    [...]
  def doSomething(self):
    if FOO == 1:
      [...]
    else:
      [...]
8<----8<----8<----8<----8<----8<----8<----8<----

Assuming ModuleA, and then ModuleB are imported. Before this commit,
both scripts were executed in the __main__ scope and FOO variable would
have the value associated with the last imported module.

After this commit, both module will see their own copy of the FOO
variable with the expected value.

It also avoid the hack when we explicitly save/set/restore
both "__name__" and "__file__" variable.

Changes to "DICOMScalarVolumePlugin" fixes the test failing test
"py_RSNAVisTutorial" and "py_SubjectHierarchyGenericSelfTest". It basically
fixes the following error by ensuring all object are imported:

//--------------
test_SubjectHierarchyGenericSelfTest_FullTest1 (SubjectHierarchyGenericSelfTest.SubjectHierarchyGenericSelfTestTest) ... Traceback (most recent call last):
  File "/path/to/Slicer-build/lib/Slicer-4.4/qt-scripted-modules/DICOMLib/DICOMWidgets.py", line 615, in getLoadablesFromFileLists
    loadablesByPlugin[plugin] = plugin.examineForImport(fileLists)
  File "/path/to/Slicer-build/lib/Slicer-4.4/qt-scripted-modules/DICOMScalarVolumePlugin.py", line 47, in examineForImport
    loadablesForFiles = self.examineFiles(files)
  File "/path/to/Slicer-build/lib/Slicer-4.4/qt-scripted-modules/DICOMScalarVolumePlugin.py", line 71, in examineFiles
    loadable = DICOMLib.DICOMLoadable()
NameError: global name 'DICOMLib' is not defined
//--------------

Revision 24152  Directory Listing
Modified Fri Apr 3 04:23:39 2015 UTC (2 years, 5 months ago) by jcfr
ENH: Extend module API with "widgetRepresentationCreationEnabled" property

By default, (1) all modules are expected to be able to create
representations and (b) module with representation creation
disabled will be hidden (not visible in the module selector)
if the property was False at loading time.

In the case of scripted module, if not widget class could be found when
loading the main script, the property is set to False.

Revision 24151  Directory Listing
Modified Fri Apr 3 02:43:48 2015 UTC (2 years, 5 months ago) by jcfr
STYLE: List attribute to export in ScriptedLoadableModule

This will allow to keep module namespace clean and will facilitate
introspection and access to relevant attribute.

Revision 24150  Directory Listing
Modified Fri Apr 3 02:43:46 2015 UTC (2 years, 5 months ago) by jcfr
BUG: Fix qSlicerScriptedLoadableModuleWidgetTest broken by previous commit

This commit fixes a regression introduced by previous
commit r24149 (BUG: Ensure "qSlicerScriptedUtils::executeFile()"
set "__file__" property.

Revision 24149  Directory Listing
Modified Thu Apr 2 19:44:30 2015 UTC (2 years, 5 months ago) by jcfr
BUG: Ensure "qSlicerScriptedUtils::executeFile()" set "__file__" property.

This is a hack. Instead the "imp" module should be used as outline
in issue #3549 (Import scripted module as python module).

Revision 24147  Directory Listing
Modified Thu Apr 2 19:07:14 2015 UTC (2 years, 5 months ago) by jcfr
STYLE: Simplify scripted module introducing SlicerPythonCppAPI

Revision 24146  Directory Listing
Modified Thu Apr 2 19:07:11 2015 UTC (2 years, 5 months ago) by jcfr
STYLE: Refactor code introducing qSlicerScriptedUtils::executeFile

Revision 24142  Directory Listing
Modified Wed Apr 1 19:05:00 2015 UTC (2 years, 5 months ago) by lassoan
STYLE: Added comment explaining FD message handler usage

Revision 24141  Directory Listing
Modified Wed Apr 1 17:13:32 2015 UTC (2 years, 5 months ago) by lassoan
ENH: Allow slicelets and Slicer tests to handle log messages

Two main applications:
* Errors are logged to file, which makes troubleshooting much easier.
* Errors can be captured during tests and the test can return with failure in case of unexpected errors occurred (work in progress).

Revision 24140  Directory Listing
Modified Wed Apr 1 12:54:38 2015 UTC (2 years, 5 months ago) by lassoan
BUG: Fixed 0003876: All python modules fail after uninstalling an extension 

Wrong PYTHONPATH setting was set in wrong format in qSlicerExtensionsManagerModelPrivate::removeExtensionPathFromLauncherSettings.
Fixed by updating the setting the same way as in qSlicerExtensionsManagerModelPrivate::addExtensionPathToLauncherSettings.

http://na-mic.org/Mantis/bug_view_advanced_page.php?bug_id=3876

Revision 24139  Directory Listing
Modified Wed Apr 1 08:55:12 2015 UTC (2 years, 5 months ago) by jcfr
STYLE: Fix compilation warnings

This commit fixes the following warnings:

 * vtkAnnotationROIRepresentation2D.cxx:426: warning: missing braces around initializer for 'double [3]' [-Wmissing-braces]

 * qMRMLSortFilterSubjectHierarchyProxyModel.cxx:80: warning: unused variable 'd' [-Wunused-variable]

 * qSlicerApplication.cxx: In member function 'void qSlicerApplication::setupFileLogging()':
   qSlicerApplication.cxx:740: warning: format '%d' expects type 'int', but argument 2 has type 'size_t' [-Wformat]
   qSlicerApplication.cxx:740: warning: format '%d' expects type 'int', but argument 3 has type 'size_t' [-Wformat]
   Related article: http://stackoverflow.com/questions/2524611/how-to-print-size-t-variable-portably

Revision 24138  Directory Listing
Modified Wed Apr 1 08:55:10 2015 UTC (2 years, 5 months ago) by jcfr
STYLE: Fix compilation warnings

This commit fixes the following warnings:

 * vtkAnnotationROIRepresentation2D.cxx:426: warning: missing braces around initializer for 'double [3]' [-Wmissing-braces]

 * qMRMLSortFilterSubjectHierarchyProxyModel.cxx:80: warning: unused variable 'd' [-Wunused-variable]

 * qSlicerApplication.cxx: In member function 'void qSlicerApplication::setupFileLogging()':
   qSlicerApplication.cxx:740: warning: format '%d' expects type 'int', but argument 2 has type 'size_t' [-Wformat]
   qSlicerApplication.cxx:740: warning: format '%d' expects type 'int', but argument 3 has type 'size_t' [-Wformat]

Revision 24132  Directory Listing
Modified Tue Mar 31 03:05:04 2015 UTC (2 years, 5 months ago) by jcfr
ENH: Added option for setting the layoutManager in the main application

It is useful for slicelets, where the main window is not created and this the slicer.app.layoutManager() is not set.

Example for setting up a layout manager in a slicelet:

layoutWidget = slicer.qMRMLLayoutWidget()
layoutManager = slicer.qSlicerLayoutManager()
layoutManager.setMRMLScene(slicer.mrmlScene)
layoutManager.setScriptedDisplayableManagerDirectory(slicer.app.slicerHome + "/bin/Python/mrmlDisplayableManager")
layoutWidget.setLayoutManager(layoutManager)
slicer.app.setLayoutManager(layoutManager)
layoutWidget.setLayout(slicer.vtkMRMLLayoutNode.SlicerLayoutFourUpView)

somelayout.addWidget(layoutWidget)

From: Andras Lasso <lasso@queensu.ca>

Revision 24119  Directory Listing
Modified Fri Mar 27 02:40:01 2015 UTC (2 years, 6 months ago) by jcfr
ENH: Lookup launcher and default settings files based on application name

Since following r24004 (ENH: Allow application name to be defined by
argv0) , we are sure the application name is set appropriately.
This commit will also ensure the application executable will lookup
launcher and default settings files based on the application name.

Revision 24118  Directory Listing
Modified Thu Mar 26 23:30:21 2015 UTC (2 years, 6 months ago) by jcfr
ENH: Add support for default settings

If the file "<Slicer_HOME>/share/slicer-X.Y/SlicerDefaultSettings.ini"
exists, the corresponding key/value pairs are set into the user settings
if not already set.

Macro "slicerMacroBuildApplication" has also been updated to optionally
accept a "DEFAULT_SETTINGS_FILE" parameter.

Revision 24115  Directory Listing
Modified Thu Mar 26 17:19:07 2015 UTC (2 years, 6 months ago) by jcfr
ENH: Extend slicer.util API introducing 'settingsValue' and 'toBool'

Revision 24064  Directory Listing
Modified Fri Mar 13 18:25:44 2015 UTC (2 years, 6 months ago) by jcfr
STYLE: Fix typo in qSlicerCoreCommandOptions.cxx

From: Francois Budin <fbudin@unc.edu>

Revision 24062  Directory Listing
Modified Fri Mar 13 14:26:48 2015 UTC (2 years, 6 months ago) by jcfr
STYLE: Display module loading stats only once

Since (1) following r24059 (ENH: Write all info to the log file as
formatted log messages), module stats are displayed using qDebug() and
(2) following r24052 , module stats are displayed if verboseModuleDiscovery is
enabled, this commit revert r24052 and ensure stats are displayed once.

Revision 24059  Directory Listing
Modified Thu Mar 12 13:34:10 2015 UTC (2 years, 6 months ago) by lassoan
ENH: Write all info to the log file as formatted log messages

Writing unstructured raw text data to the log file breaks automatic log formatting and analysis.
To fix this, use logging functions instead of appending raw data to the log file.
Removed appendToLogFile to discourage developers from writing unformatted raw data to the log file.

Revision 24054  Directory Listing
Modified Tue Mar 10 21:44:07 2015 UTC (2 years, 6 months ago) by jcfr
BUG: Do not expect log file to exist to try to append text for the first time

This commit fixes a regression introduced in r24051 (ENH: Add convenience
function to append text to current log file.)

Revision 24052  Directory Listing
Modified Tue Mar 10 21:30:41 2015 UTC (2 years, 6 months ago) by jcfr
ENH: Append module loading stats to log file.

Revision 24051  Directory Listing
Modified Tue Mar 10 21:30:27 2015 UTC (2 years, 6 months ago) by jcfr
ENH: Add convenience function to append text to current log file.

Revision 24049  Directory Listing
Modified Tue Mar 10 18:18:25 2015 UTC (2 years, 6 months ago) by jcfr
STYLE: Fix typo in comment

Revision 24046  Directory Listing
Modified Tue Mar 10 15:50:50 2015 UTC (2 years, 6 months ago) by jcfr
BUG: Set scene to MRB directory instead of temp

When loading an MRB the MRML scene url was left pointing to
the deleted temporary directory. This change resets the URL
to point to a mrml file in the same location as the MRB so
that on subsequent saves the default location is correct.
Since the temporary directory is deleted after loading,
mark all the storable nodes as modified since read so that
they will be properly flagged in the save data dialog for
writing.
Support relative paths for loading MRBs (the unzip call
needs an absolute path).

Issue #3698

From: Nicole Aucoin <nicole@bwh.harvard.edu>

Revision 24039  Directory Listing
Modified Tue Mar 10 02:30:03 2015 UTC (2 years, 6 months ago) by lassoan
ENH: Added vtkInfoMacro

Added in a new vtkAddon library, which contains Slicer's VTK add-ons that eventually could be moved to VTK proper.

Resolves https://github.com/Slicer/Slicer/pull/205

Revision 24018  Directory Listing
Modified Thu Mar 5 08:46:05 2015 UTC (2 years, 6 months ago) by jcfr
STYLE: Remove unused dead code

Revision 24017  Directory Listing
Modified Thu Mar 5 08:45:43 2015 UTC (2 years, 6 months ago) by jcfr
ENH: Add qMRMLLayoutViewFactory

This gives the ability to instantiate a different QWidget for any view
(e.g. 3D, slice, chart). Limited support is given to handle a new type
view (subclass of vtkMRMLAbstractViewNode). For full support, the layout
logic would need a similar plugin mechanism.

/// MRML layout manager that instantiates the QT widgets and layouts from the
/// layout node and the view nodes in the scene.
/// The management (creation, configuration and deletion) of the view widgets
/// are delegated to qMRMLLayoutViewFactory.
/// Example to change a default factory:
/// \code
/// qMRMLLayoutSliceViewFactory* mrmlSliceViewFactory =
///   qobject_cast<qMRMLLayoutSliceViewFactory*>(
///     app->layoutManager()->mrmlViewFactory("vtkMRMLSliceNode"));
/// MySliceViewFactory* mySliceViewFactory =
///   new MySliceViewFactory(app->layoutManager());
/// mySliceViewFactory->setSliceLogics(mrmlSliceViewFactory->sliceLogics());
///
/// app->layoutManager()->unregisterViewFactory(mrmlSliceViewFactory);
/// app->layoutManager()->registerViewFactory(mySliceViewFactory);
/// \endcode
/// You can also register ctkLayoutViewFactories that are not related to MRML
/// view nodes.

From: Julien Finet <julien.finet@kitware.com>

Revision 23994  Directory Listing
Modified Sun Mar 1 16:47:03 2015 UTC (2 years, 6 months ago) by jcfr
BUG: Fix isExtensionInstalled to do an exact match when searching extensions

Fixes #3928

Tested-by: Francois Budin <fbudin@unc.edu>
Thanks: Francois Budin <fbudin@unc.edu>

Revision 23993  Directory Listing
Modified Fri Feb 27 15:46:01 2015 UTC (2 years, 6 months ago) by alexy
BUG: Fixed passing hierarchy node miniscene to CLI: Fixed references to associated node and multiple display nodes.

Revision 23991  Directory Listing
Modified Thu Feb 26 03:22:02 2015 UTC (2 years, 6 months ago) by jcfr
COMP: Fix SlicerBaseQTCoreCxxTests link error when disabling extension support

The link error happen because:
  (1) qRestAPI is not link against qSlicerBaseQTCore
  (2) qRestAPI was exporting QtTest libraries in qRestAPIExports.cmake

Revision 23976  Directory Listing
Modified Fri Feb 20 17:03:46 2015 UTC (2 years, 7 months ago) by alexy
ENH: Jim Miller's fix for enabling Hierarchy sub-scenes to be passed to CLI

Revision 23972  Directory Listing
Modified Sun Feb 15 19:24:00 2015 UTC (2 years, 7 months ago) by pieper
ENH: add accessor for vertex points of models as numpy array

Revision 23961  Directory Listing
Modified Thu Feb 5 00:11:16 2015 UTC (2 years, 7 months ago) by jcfr
ENH: Improve build targets organization in IDE that support folders

This commit set the FOLDER property on all targets to group them
into meaningful "units". This will make development easier ensuring
it is possible to quickly re-build and open the source files associated
with the targets of either a given module, the core libraries or even
the Slicer application.

Currently the grouping is:
* App-SlicerApp
* CMakePredefinedTargets
* Core-Base
* Core-Libs
 * FreeSurfer
 * ITKFactoryRegistration
 * [...]
* Module-<NameOfModule>
* [...]

If for some reason, the folder organization needs to be disabled. Slicer
could be configured with Slicer_USE_FOLDERS set to OFF.

Projects updated in this commit:
* CTK
* SlicerExecutionModel
* OtsuThresholdImageFilter

Notes:

 (1) some of the targets (EMSegment, BRAINSTools, MultiVolume, ...)
are still associated to the root and not yet categorized.

 (2) ideally few more  macros/functions should be introduced: one to
easily configure subject hierarchy plugin, and one to easily configure
tests associated with a CLI.


CTK changes:

// -------------
commit commontk/CTK@ac1370e
Author: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>
Date:   Wed Feb 4 14:47:09 2015 -0500

    Add FOLDER parameter to ctkMacroBuildQtPlugin

    If specified, the target(s) associated with designer, icon engine and
    style plugins will be added into the specified folder when the project is
    configured for an IDE supporting it.

    For more details, see http://www.cmake.org/cmake/help/v2.8.9/cmake.html#prop_tgt:FOLDER
// -------------


SlicerExecutionModel changes:

// -------------
commit Slicer/SlicerExecutionModel@0b780eb
Author: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>
Date:   Wed Feb 4 18:06:25 2015 -0500

    ENH: SEMMacroBuildCLI - Add possibility to associate FOLDER with CLI targets

    In project building a lot of modules (i.e Slicer), whenever possible, it
    is better to keep the huge list of targets organized. To help with this,
    CMake allows to set a FOLDER target property.

    See http://www.cmake.org/cmake/help/v2.8.3/cmake.html#prop_tgt:FOLDER

    This commit extends the SEMMacroBuildCLI API to accept an optional FOLDER
    parameter. If not set, the folder name will default to:

      <SlicerExecutionModel_DEFAULT_CLI_TARGETS_FOLDER_PREFIX><MODULE_NAME>

    By default the prefix is set to an empty string and the folder will be
    named after the module name.

    There are two ways to specify a default prefix value:

     (1) Set the variable SlicerExecutionModel_DEFAULT_CLI_TARGETS_FOLDER_PREFIX
    in the current scope before calling 'SEMMacroBuildCLI'

     (2) Configure the SlicerExecutionModel project with the option
    SlicerExecutionModel_DEFAULT_CLI_TARGETS_FOLDER_PREFIX

    Note that:
     - FOLDER support has been introduced in CMake >= 2.8.3
    and
     - it can optionally be enabled in a project by setting the global
    property named USE_FOLDERS.

    See http://www.cmake.org/cmake/help/v2.8.3/cmake.html#prop_global:USE_FOLDERS

    Finally, to associate CLI test expected to be in the same "FOLDER",
    a variable named <MODULE_NAME>_TARGETS_FOLDER is conveniently set in the
    current scope each time the macro SEMMacroBuildCLI is called.

commit Slicer/SlicerExecutionModel@e84d231
Author: Matt McCormick <matt.mccormick@kitware.com>
Date:   Thu Aug 7 11:09:39 2014 -0400

    BUG: Fix ModuleDescriptionParser test data dir.

    Fixes Parser1Test{1,2}.

    Simplify by consolidation of variables.
// -------------


OtsuThresholdImageFilter changes:

// -------------
commit :Slicer/Slicer-OtsuThresholdImageFilter@5efe412
Author: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>
Date:   Wed Feb 4 18:08:28 2015 -0500

    Associate folder with test targets.
    [...]
// -------------

Revision 23952  Directory Listing
Modified Tue Feb 3 06:43:55 2015 UTC (2 years, 7 months ago) by jcfr
COMP: Workaround to fix HAVE_STAT redefined warning in qSlicerCoreApplication

This commit fixes the following warning:

//-------------
In file included from /path/to/Slicer-build/DCMTK/dcmdata/include/dcmtk/dcmdata/dcdatset.h:26:0,
                 from /path/to/Slicer-build/CTK/Libs/DICOM/Core/ctkDICOMItem.h:28,
                 from /path/to/Slicer-build/CTK/Libs/DICOM/Core/ctkDICOMDatabase.h:29,
                 from /path/to/Slicer/Base/QTCore/qSlicerCoreApplication.cxx:101:
/path/to/Slicer-build/DCMTK-build/config/include/dcmtk/config/osconfig.h:540:0: warning: "HAVE_STAT" redefined [enabled by default]
 #define HAVE_STAT 1
 ^
In file included from /path/to/Slicer-build/python-install/include/python2.7/Python.h:58:0,
                 from /path/to/Slicer-build/CTK-build/CMakeExternals/Install/include/PythonQt/PythonQtPythonInclude.h:93,
                 from /path/to/Slicer-build/CTK-build/CMakeExternals/Install/include/PythonQt/PythonQtInstanceWrapper.h:45,
                 from /path/to/Slicer-build/CTK-build/CMakeExternals/Install/include/PythonQt/PythonQt.h:46,
                 from /path/to/Slicer/Base/QTCore/qSlicerCoreApplication.cxx:52:
/path/to/Slicer-build/python-install/include/python2.7/pyport.h:361:0: note: this is the location of the previous definition
 #define HAVE_STAT
 ^
//-------------

Revision 23950  Directory Listing
Modified Tue Feb 3 06:28:52 2015 UTC (2 years, 7 months ago) by jcfr
COMP: Fix redefined _POSIX_C_SOURCE warning

As detailed in kitware/VTK@0c8d479, the Python documentation
clearly states the proper approach:

 "Since Python may define some pre-processor definitions which
 affect the standard headers on some systems, you must include
 Python.h before any standard headers are included."
 (http://docs.python.org/c-api/intro.html#include-files)

Include "vtkPython.h" prior to any system header in all translation
units that need Python.

Revision 23932  Directory Listing
Modified Thu Jan 29 07:25:13 2015 UTC (2 years, 7 months ago) by jcfr
ENH: Associate loaded node IDs with core IOManager newFileLoaded signal

This commit generalizes the usage of the signal originally added
in r20685 (ENH: Adds 'Recently Loaded' File menu entry) by allowing
client code to know the list of node IDs associated with a file.

Revision 23931  Directory Listing
Modified Thu Jan 29 04:16:24 2015 UTC (2 years, 7 months ago) by jcfr
STYLE: Fixed typos in doxygen comments

From: Sergey Aleshin <4memph@gmail.com>

Revision 23924  Directory Listing
Modified Thu Jan 29 03:36:14 2015 UTC (2 years, 7 months ago) by jcfr
STYLE: Fix spell check in qSlicerAbstractModuleRepresentation doxygen

Revision 23914  Directory Listing
Modified Fri Jan 23 17:55:26 2015 UTC (2 years, 8 months ago) by jcfr
BUG: Fix qSlicerLoadableModuleWithPythonTest

To fix the failing test due to a regression introduced by r23828,
this commit
  (1) updates CTK to include update to ctk/__init__.py
  (2) update slicer/__init__.py
to ensure "slicer" module can be imported without an instantiated
  (3) update launcher settings associated with CTK external project to
allow ctk module to be imported without having a qSlicerCoreApplication
instantiated. (See function "pythonPaths" at line 65 of
qSlicerCorePythonManager.cpp)
QApplication.

CTK changes:

$ git shortlog a3d8aa9..e23537d --no-merges
Andreas Fetzer (32):
      Use same way to display data like in the ctkXnatTreeModel
      Make root object protected to allow access to the root object from     within subclasses.
      Use lower case property keys consistently.
      Use label instead of abstractresourceid since a newly generated resource may not have an id yet
      Fixed resource uri for ctkXnatFile
      Added new file which contains all the xnat object fields that are accessible via the xnat rest api
      Use properties for fields that are accessible via the rest api instead of members     of the private implementation.     Use the object field constants for accessing the properties.
      Use constants for accessing the properties of an object
      Use constants for accessing the properties of an subject
      Use constants for accessing the properties of an xnat object
      Added convenience methods for setting file properties
      Added missing includes
      Use constant for accessing properties
      Added functions for getting/setting the description of a project
      The description which is displayed as a tooltip by the Tree- and TableModel     must not be synchronized with the XNAT server.     Hence it should be a member of the private implementation
      Don't store the ID within a property. Since the ID is created automatically     and cannot be changed afterwards it should be stored as a field of the private     implementation.
      Added convenience methods for setting xnatScan properties
      Overwrote the ID and name accessors for xnatResource
      Fixed return type
      Fixed fetching xnatObjects by using the correct properties/fields
      Reverted changes regarding ID handling. ID is no longer stored within the private     implementation but as property again.     Overwrote ID getters and setter where this was necessary.
      Added get/set label methods to xnatResource, since the xnatResource object has no     field name.
      Fixed access to reconstruction file names
      Removed debug messages
      Fixed property access
      Stylistic improvements
      Made id getter and setter virtual
      Added more missing virtual declarations
      Fixed compiler warning. No longer returning reference to local temporary object.
      Removed file with xnat constants. The respective constants are now located in     the according xnat object implementation
      Removed unused includes
      Removed commented-out legacy code

Ivo Wolf (1):
      Refactored and extended download

Jean-Christophe Fillion-Robin (1):
      BUG: Allow ctk to be imported if neither Core or Widget kit are loaded

Revision 23886  Directory Listing
Modified Tue Jan 20 00:18:29 2015 UTC (2 years, 8 months ago) by jcfr
ENH: Update code to be independent of KWSys function signature changes

Future version of VTK depends on a more recent version of KWSys changing
signatures of function like SystemTools::FileIsDirectory to accept only
a "std::string" instead of a "const char*". This commit anticipates
build error like the one reported below by either depending on Qt/CTK API
where possible and/or providing a "const char*" instead of "QByteArray*"
that can be implicitly converted to a "std::string".

The KWSYS commits introducing these changes are:

  kitware/KWSys@6cc2451
  kitware/KWSys@f3fb01c
  kitware/KWSys@0dfbe56
  kitware/KWSys@4690fc8
  kitware/KWSys@9927862
  kitware/KWSys@e9204f8
  kitware/KWSys@d2dbff0
  kitware/KWSys@4b409aa
  kitware/KWSys@84db9ee
  kitware/KWSys@2c2f660
  kitware/KWSys@153f6df
  kitware/KWSys@b07b5fc

Example of build error:

/path/to/Slicer/Base/QTCore/qSlicerSceneBundleReader.cxx: In member function ‘virtual bool qSlicerSceneBundleReader::load(const IOProperties&)’:
/path/to/Slicer/Base/QTCore/qSlicerSceneBundleReader.cxx:80:65: error: no matching function for call to ‘vtksys::SystemTools::FileIsDirectory(QByteArray)’
   if (vtksys::SystemTools::FileIsDirectory(unpackPath.toLatin1()))
                                                                 ^
/path/to/Slicer/Base/QTCore/qSlicerSceneBundleReader.cxx:80:65: note: candidate is:
In file included from /path/to/Slicer/Base/QTCore/qSlicerSceneBundleReader.cxx:39:0:
/path/to/Slicer-SuperBuild-Debug/VTKv6-build/Utilities/KWSys/vtksys/SystemTools.hxx:633:15: note: static bool vtksys::SystemTools::FileIsDirectory(const string&)
   static bool FileIsDirectory(const kwsys_stl::string& name);
               ^
/path/to/Slicer-SuperBuild-Debug/VTKv6-build/Utilities/KWSys/vtksys/SystemTools.hxx:633:15: note:   no known conversion for argument 1 from ‘QByteArray’ to ‘const string& {aka const std::basic_string<char>&}’
/path/to/Slicer/Base/QTCore/qSlicerSceneBundleReader.cxx:82:70: error: no matching function for call to ‘vtksys::SystemTools::RemoveADirectory(QByteArray)’
     if ( !vtksys::SystemTools::RemoveADirectory(unpackPath.toLatin1()) )

Revision 23877  Directory Listing
Modified Mon Jan 12 21:53:41 2015 UTC (2 years, 8 months ago) by millerjv
STYLE: adding comments to multivolume changes to ProcessReadData()

From: Jim Miller <millerjv@ge.com>

Revision 23876  Directory Listing
Modified Mon Jan 12 21:53:39 2015 UTC (2 years, 8 months ago) by millerjv
BUG: fix loading multivolumes produced by CLIs

This addresses Slicer issue http://www.na-mic.org/Bug/view.php?id=3382.

The patch has been suggested by Jim Miller (see the Slicer issue).

Jim wants to add more comments before this is merged with the Slicer master.

From: Andrey Fedorov <fedorov@bwh.harvard.edu>

Revision 23867  Directory Listing
Modified Fri Jan 9 06:50:05 2015 UTC (2 years, 8 months ago) by jcfr
ENH: Re-factor code introducing "slicer.util.toVTKString"

Co-authored-by: Andras Lasso <lasso@queensu.ca>

From: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

Revision 23857  Directory Listing
Modified Thu Jan 8 17:49:00 2015 UTC (2 years, 8 months ago) by jcfr
COMP: Deprecate ITK function ::Zero and ::One to fix clang link error

These were deprecated in 2012; just before the ITK 4.2 release.
ZeroValue() and OneValue() should be used instead.

-- This coforms to ITKv4 changes made in
    InsightSoftwareConsortium/ITK@6c23e1da
    InsightSoftwareConsortium/ITK@3f712cd0

When building with clang on 10.9 where ITKv4 is a shared library,
a linking error occured for unfound symbols: NumericTraits<
OutputPixelType >::Zero but using the
NumericTraits< OutputPixelType >::ZeroValue() allows linkage to occur properly.

From: Hans Johnson <hans-johnson@uiowa.edu>

Revision 23828  Directory Listing
Modified Wed Dec 10 22:10:30 2014 UTC (2 years, 9 months ago) by jcfr
ENH: Use Python logging framework for scripted module logging

Use Python's built-in logging module to manage logging. A direct advantage is that line number, file name, method name can be logged, too. Also, it follows the convention of using qt-style logging in qt classes, vtk-style logging in vtk classes, etc.

Default behavior of log levels:
 DEBUG: log to application log only, includes file name, line number, thread
 INFO: log to stdout (appears in application log, too)
 WARNING: log to stderr (appears in application log, too)
 ERROR: log to stderr (appears in application log, too)

Usage:
 import logging

 [...]

 logging.debug("this is a debug message")
 logging.info("this is an info message")
 logging.warning("this is a warning message")
 logging.error("this is a error message")

From: Andras Lasso <lasso@queensu.ca>

Revision 23826  Directory Listing
Modified Wed Dec 10 21:12:21 2014 UTC (2 years, 9 months ago) by jcfr
ENH: Added support for thin plate spline transforms

Added full support for thin plate spline transforms:
* save/load forward and inverse transform from ITK files
* verification that ITK and VTK thin plate spline transform computes exactly the same values
* basic storage and inversion tests

Thin plate spline transform is used by the Landmark Registration module, so now the computed transform can be saved to the scene or exported.

From: Andras Lasso <lasso@queensu.ca>

Revision 23819  Directory Listing
Modified Sat Dec 6 05:55:58 2014 UTC (2 years, 9 months ago) by jcfr
ENH: Update scripted module base class to leverage "slicer.log" functionality

From: Andras Lasso <lasso@cs.queensu.ca>

Revision 23818  Directory Listing
Modified Sat Dec 6 05:55:56 2014 UTC (2 years, 9 months ago) by jcfr
ENH: Added logging functions for Python

Added info and error logging macros for Python modules.

Usage examples:

```
import slicer.log

slicer.log.info("This is an info message, logged as an INFO type message")
slicer.log.info("This is an info message, logged and also displayed in a popup for a short time", True)
slicer.log.info("This is an info message, logged and also displayed in a popup for 5 seconds", True, 5000)
slicer.log.info("This is an info message, logged and also displayed in a popup, the user has to click OK to continue", True, 0)

slicer.log.error("This is an error message, logged as an ERROR type message")
slicer.log.error("This is an error message, logged and also displayed in a popup, the user has to click OK to continue", True, 0)
```

From: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

Revision 23807  Directory Listing
Modified Thu Nov 27 03:39:59 2014 UTC (2 years, 9 months ago) by lassoan
BUG: Fixed composite transform problems

By hardening a non-linear transform on a vtkMRMLLinearTransformNode makes the contents of the linear transform node non-linear. This causes errors in many places in the code where linearity of the transform is tested by checking the class type instead of calling transform->IsLinear() or transform->IsTransformToParentLinear().

In the long term all specific transform nodes (linear, bspline, grid) should be removed and only the generic vtkMRMLTransformNode should be used everywhere. The specific classes are already “empty”, they do not contain any useful functionality, but they are be used in extensions (and still have not removed from everywhere in the Slicer core), so they have to be phased out gradually.

Specific problems:
* If affine transform is applied to bspline then bspline component is ignored
* If affine transform is applied to bspline and affine is hardened then the bspline component is lost.
* Hardening multiple nonlinear transforms on a transform sometimes results in incorrect composite transform

Fixes:
* Instead of casting to vtkMRMLLinearTransform IsLinear or IsTransformToWorldLinear has to be called to decide if a transform is linear (checking the class type does not work correctly for composite transforms)
* Fixed vtkMRMLTransformNode::ApplyTransform
* Moved full implementation of get/set transform matrix functions in vtkMRMLTransformNode (it further prepares removal of obsolete linear/bspline/grid transform node classes)

Enhancements:
* Allow splitting of composite transforms to its components (Transforms module: Split button – only displayed for composite transforms)

Revision 23802  Directory Listing
Modified Wed Nov 26 16:15:46 2014 UTC (2 years, 9 months ago) by lassoan
ENH: Filter testing modules in module list depending on DeveloperMode

In the module selector only show modules in Testing category if DeveloperMode is enabled in application settings
Fixes http://www.na-mic.org/Bug/view.php?id=3903

Revision 23799  Directory Listing
Modified Mon Nov 24 21:17:37 2014 UTC (2 years, 10 months ago) by johan.andruejol
ENH: Add access to the currently selected module for testing convenience

This commit adds a Q_PROPERTY to qSlicerModuleSelectorToolBar to ensure it is
available from python. It also adds the convenience method to the
slicer.util python module.

Revision 23780  Directory Listing
Modified Thu Nov 6 10:05:53 2014 UTC (2 years, 10 months ago) by jcfr
STYLE: Associate a pimpl to qSlicerCLI{Executable, Loadable}ModuleFactory

This is done in anticipation of future tweaking of the factory related
to integration of CTK CLI framework.

Revision 23773  Directory Listing
Modified Sun Nov 2 15:07:38 2014 UTC (2 years, 10 months ago) by jcfr
ENH: Update Documentation to 4.4

Revision 23749  Directory Listing
Modified Fri Oct 17 21:10:55 2014 UTC (2 years, 11 months ago) by jcfr
ENH: Add function "removeObserver" to slicer.util.VTKObservationMixin

Revision 23687  Directory Listing
Modified Tue Sep 16 21:11:52 2014 UTC (3 years ago) by lassoan
ENH: Added helper methods to ScriptedLoadableModuleLogic for managing parameter nodes

Revision 23677  Directory Listing
Modified Mon Sep 15 00:52:48 2014 UTC (3 years ago) by jcfr
BUG: Ensure volume node without default storage node can be saved.

This commit allows volume to be saved from python using
"slicer.util.saveNode()".

More specifically, this commit (1) factors out the code allowing to
create and add the default storage node to the scene  and (2) ensures a
call to "qSlicerCoreIOManager::saveNodes" work when there are no storage
node associated with a volume node.

This is needed because within the "saveNodes" function, calling the
function "qSlicerNodeWriter::extensions(node)" expects a storage node
to be present.

Thanks to Julien Finet for reviewing.

Revision 23676  Directory Listing
Modified Sun Sep 14 11:28:09 2014 UTC (3 years ago) by jcfr
ENH: Added icon loading for scripted module base class

Python scripted modules that use the ScriptedLoadableModule base class
now load their icon from Resources/Icons/<ModuleName>.png.
If the icon file does not exist then the default icon is kept.
Modules can override the icon setting in the module __init__ function to
use any other custom icon.

Updated extension wizard template and extension test.

Updated one more module (VectorToScalarVolume) to use
ScriptedLoadableModule base class.

From: Andras Lasso <lasso@queensu.ca>

Revision 23674  Directory Listing
Modified Sat Sep 13 03:07:29 2014 UTC (3 years ago) by jcfr
STYLE: Display a warning message if no writers is found when using saveNodes

From: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

Revision 23661  Directory Listing
Modified Tue Sep 9 20:56:52 2014 UTC (3 years ago) by jcfr
ENH: Change required ITK version from 4.5 to 4.6

Starting with r23373 ITK 4.6.x is used to build and test Slicer.

$ git shortlog c127db8..6b5fa1a SuperBuild/External_ITKv4.cmake
jcfr (8):
      ENH: Update (1) ITKv4 from v4.5.2 to v4.6rc01 and (2) update BRAINSTools
      BUG: Update ITKv4 project to backport fix related to GDCMIO
      BUG: Update ITKv4 - Attempt to fix ResampleDTI tests
      COMP: Update ITKv4 - Fix "unused-local-typedefs" warning
      COMP: Move most of find_package calls into each Slicer sub-project.
      ENH: Move ITKv4 towards 4.6.0rc20140719
      ENH: Update ITKv4 and BRAINSTools
      BUG: Update ITKv4 and BRAINSTools - BRAINSFit performance improvement.

Revision 23658  Directory Listing
Modified Mon Sep 8 07:08:33 2014 UTC (3 years ago) by jcfr
ENH: slicer.util: Update getNode methods to optionally use a custom scene

This is particularly useful to retrieve node from a scene different
from the main slicer scene.

Revision 23654  Directory Listing
Modified Sat Sep 6 17:07:23 2014 UTC (3 years ago) by pieper
ENH: improve the script template by adding documentation link

From: Steve Pieper <pieper@bwh.harvard.edu>

Revision 23651  Directory Listing
Modified Fri Sep 5 22:00:15 2014 UTC (3 years ago) by jcfr
ENH: Update to Testing::ComparisionImageFilter

Update deprecated usage of ComparisonImageFilter to
TestingComparisonImageFilter.

Migration:
http://itk.org/migrationv4/index.php?action=artikel&cat=3&id=113&artlang=en&highlight=ComparisonImageFilter

From: Bradley Lowekamp <blowekamp@mail.nih.gov>

Revision 23647  Directory Listing
Modified Fri Sep 5 16:00:21 2014 UTC (3 years ago) by pieper
ENH: add a testing clickAndDrag utility to the scripted module

Revision 23643  Directory Listing
Modified Wed Sep 3 15:08:39 2014 UTC (3 years ago) by jcfr
ENH: Moved error log copying to separate error reporting dialog

Error reporting dialog accessible from menu: Help / Report a bug

From: Andras Lasso <lasso@queensu.ca>

Revision 23641  Directory Listing
Modified Mon Sep 1 22:46:38 2014 UTC (3 years ago) by jcfr
ENH: Added option to copy log file contents

Available in application settings / Developer panel

From: Andras Lasso <lasso@queensu.ca>

Revision 23634  Directory Listing
Modified Fri Aug 29 19:01:48 2014 UTC (3 years ago) by jcfr
ENH: slicer.util: Add NodeModify context manager

This commit adds a convenience context manager allowing to easily
disable modified event associated with a node, and automatically re-enable
them and invoking them if it applies.

Revision 23631  Directory Listing
Modified Fri Aug 29 18:23:46 2014 UTC (3 years ago) by jcfr
ENH: slicer.util.VTKObservationMixin: removeObservers now accept no params

The method 'removeObservers' allows to easily remove all observers without
specifying all the method one by one.

Revision 23624  Directory Listing
Modified Wed Aug 27 00:29:21 2014 UTC (3 years, 1 month ago) by jcfr
BUG: Fix qSlicerPersistentCookieJarTester

Cookie file is not expected to exist.

Revision 23619  Directory Listing
Modified Tue Aug 26 23:41:12 2014 UTC (3 years, 1 month ago) by jcfr
COMP: Link against vtkWrappingPythonCore to use vtkPythonUtil fucntions

Revision 23602  Directory Listing
Modified Wed Aug 20 21:26:52 2014 UTC (3 years, 1 month ago) by jcfr
COMP: Fix sign-compare warning in qSlicerApplication

This commit fixes the following warning:

/path/to/Slicer/Base/QTGUI/qSlicerApplication.cxx: In member function ‘void qSlicerApplication::setupFileLogging()’:
/path/to/Slicer/Base/QTGUI/qSlicerApplication.cxx:626:46: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
   for (unsigned int fileNumber=0; fileNumber<numberOfFilesToKeep; ++fileNumber)

Revision 23601  Directory Listing
Modified Wed Aug 20 21:26:50 2014 UTC (3 years, 1 month ago) by jcfr
COMP: Fix unused variable warning in qSlicerCoreApplication

This commit fixes the following warning occurring when Slicer is build
with extension support is disabled.

/path/to/Slicer/Base/QTCore/qSlicerCoreApplication.cxx: In member function ‘QString qSlicerCoreApplication::defaultExtensionsInstallPath() const’:
/path/to/Slicer/Base/QTCore/qSlicerCoreApplication.cxx:1159:14: warning: unused variable ‘appSettings’ [-Wunused-variable]
   QSettings* appSettings = this->userSettings();

Revision 23600  Directory Listing
Modified Wed Aug 20 21:26:48 2014 UTC (3 years, 1 month ago) by jcfr
COMP: Fix qSlicerApplication compile error when ExtensionSupport is disabled.

This commit fixes the following error:

/path/to/Slicer/Base/QTGUI/qSlicerApplication.cxx:660:7: error: ‘QFile’ has not been declared
       QFile::remove(filePath);

Revision 23583  Directory Listing
Modified Sun Aug 17 23:45:59 2014 UTC (3 years, 1 month ago) by jcfr
ENH: Linear transforms now use vtkTransform for transform storage. See #3788

Main limitation was that the vtkMatrixToLinearTransform did not
have a GetInverseFlag() method.

Couple of other smaller fixes.

From: Andras Lasso <lasso@queensu.ca>

Revision 23582  Directory Listing
Modified Sun Aug 17 23:45:55 2014 UTC (3 years, 1 month ago) by jcfr
ENH: Always save transforms as FromParent. See #3788

Kept readWriteTransformAsToParent flag just for backward
compatibility, when reading an old scene.

If in the future we want to save the ToParent transform or
both FromParent and ToParent then the flag has to be added
to the storage node (and not the transform node).

From: Andras Lasso <lasso@queensu.ca>

Revision 23580  Directory Listing
Modified Sun Aug 17 23:30:31 2014 UTC (3 years, 1 month ago) by jcfr
ENH: Always send transform "from parent" to CLI. See #3788

From: Andras Lasso <lasso@queensu.ca>

Revision 23579  Directory Listing
Modified Sun Aug 17 23:30:28 2014 UTC (3 years, 1 month ago) by jcfr
ENH: Simplified transform storage node. See #3788

From: Andras Lasso <lasso@queensu.ca>

Revision 23576  Directory Listing
Modified Sun Aug 17 23:30:18 2014 UTC (3 years, 1 month ago) by jcfr
ENH: Implemented composite transform reading. See #3788

Not just BSpline but any combination of bspline and linear
can be read from composite transforms.

Reading of grid transforms from transform file is not implemented yet.

From: Andras Lasso <lasso@queensu.ca>

Revision 23572  Directory Listing
Modified Sun Aug 17 23:30:06 2014 UTC (3 years, 1 month ago) by jcfr
ENH: In developer mode do not remove CLI input and output files

In developer mode do not remove CLI input and output files. This
allows re-running of CLI with the input data that normally would
have been deleted right after the CLI execution completes.

From: Andras Lasso <lasso@queensu.ca>

Revision 23567  Directory Listing
Modified Thu Aug 14 19:11:47 2014 UTC (3 years, 1 month ago) by jcfr
BUG: Ensure application can be killed using CTRL-C. Fixes #3804

This commits fixes a regression introduced by the addition of the
SlicerExtensionWizard module. See inlined comment for more details.

Revision 23564  Directory Listing
Modified Tue Aug 12 20:53:10 2014 UTC (3 years, 1 month ago) by pinter
ENH: Log to file

Enabled file logging in CTK error log model, bumping up hash. The number of files to keep and the log file paths are stored in the revision settings. The log files are saved in the temp folder with file name Slicer_[revision]_[date]_[time].log. If number of log files is larger than number of files to keep, then the old log file is deleted.

Revision 23557  Directory Listing
Modified Wed Aug 6 07:11:36 2014 UTC (3 years, 1 month ago) by jcfr
ENH: Do not log when module UI is successfully displayed

Displaying that everything went well is not useful and add extra "noise"
to the regular Slicer output.

Revision 23555  Directory Listing
Modified Wed Aug 6 06:40:25 2014 UTC (3 years, 1 month ago) by jcfr
ENH: For sake of consistency, systematically load Slicer SSL certificates

Revision 23554  Directory Listing
Modified Wed Aug 6 06:40:21 2014 UTC (3 years, 1 month ago) by jcfr
ENH: Update Slicer.crt based on Base/QtCore/Resources/Certs/README

Update summary:

$ ./make-ca.sh                                         &&
>  ./remove-expired-certs.sh certs                      &&
>  REVISION=$(grep CVS_ID certdata.txt | cut -f4 -d'$') &&
>  VERSION=$(echo $REVISION | cut -f2 -d" ")            &&
>  mv "BLFS-ca-bundle-${VERSION}.crt"  "Slicer.crt"     &&
>  unset REVISION VERSION
rm: cannot remove ‘certs/*’: No such file or directory
Created 2e5ac55d.pem
Created cb357862.pem
Created 790a7190.pem
Created 88f89ea7.pem
Created 039c618a.pem
Created a8dee976.pem
Created 4f316efb.pem
Created 57bcb2da.pem
Created 480720ec.pem
Created 2e4eed3c.pem
Created b204d74a.pem
Created 1ec4d31a.pem
Created f39fc864.pem
Created b66938e9.pem
Created 40547a79.pem
Created 4304c5e5.pem
Created 7d5a75e4.pem
Created eed8c118.pem
Certificate 8f111d69 is not trusted!  Removing...
Created 3ee7e181.pem
Created 9d520b32.pem
Created b1b8a7f3.pem
Created 0d1b923b.pem
Created 5ad8a5d6.pem
Created 024dc131.pem
Created e113c810.pem
Created 6f2c1157.pem
Created a5fd78f0.pem
Created 5620c4aa.pem
Created c8841d13.pem
Created 812e17de.pem
Created bb2d49a0.pem
Created 4a6481c9.pem
Created 2251b13a.pem
Created 76cb8f92.pem
Created ca6e4ad9.pem
Created 65b876bd.pem
Created cfa1c2ee.pem
Created 8e52d3cd.pem
Created 3b2716e5.pem
Created 8d86cdd1.pem
Created bd1910d4.pem
Created 20d096ba.pem
Created 57bbd831.pem
Created e2799e36.pem
Created c089bbbd.pem
Created ba89ed3b.pem
Created 116bf586.pem
Created c01cdfa2.pem
Created 7d0b38bd.pem
Created 988a38cb.pem
Created 5c44d531.pem
Created 55a10908.pem
Created b6c5745d.pem
Created fcac10e3.pem
Created 3e45d192.pem
Created 18856ac4.pem
Created 381ce4dd.pem
Created 24ad0b63.pem
Created 415660c1.pem
Created 8160b96c.pem
Created 0b759015.pem
Created 062cdee6.pem
Created 9af9f759.pem
Created 9818ca0b.pem
Created 3bde41ac.pem
Created cc450945.pem
Created 6cc3c4c3.pem
Created c47d9980.pem
Created 0c4c9b6c.pem
Certificate 1bc668cc is not trusted!  Removing...
Certificate 72de6920 is not trusted!  Removing...
Certificate 6a680ea5 is not trusted!  Removing...
Created ee1365c0.pem
Certificate 476182b1 is not trusted!  Removing...
Certificate eeaa6d5c is not trusted!  Removing...
Certificate c75dd286 is not trusted!  Removing...
Certificate c75dd286 is not trusted!  Removing...
Certificate c75dd286 is not trusted!  Removing...
Certificate 804c2a3a is not trusted!  Removing...
Certificate ad6c2ff9 is not trusted!  Removing...
Created cbf06781.pem
Created 4bfab552.pem
Created dc45b0bd.pem
Created 09789157.pem
Created 2b349938.pem
Created 93bc0acc.pem
Created b727005e.pem
Created 9c8dfbd4.pem
Created 48bec511.pem
Created d957f522.pem
Created 0810ba98.pem
Created 9c472bf7.pem
Created b7a5b843.pem
Certificate 46f053f0 is not trusted!  Removing...
Created c0ff1f52.pem
Certificate 20533f91 is not trusted!  Removing...
Certificate 84009bc3 is not trusted!  Removing...
Certificate cc154c6e is not trusted!  Removing...
Certificate cee8e824 is not trusted!  Removing...
Certificate 856583ec is not trusted!  Removing...
Certificate ce486240 is not trusted!  Removing...
Certificate 94010abc is not trusted!  Removing...
Created cd58d51e.pem
Created 349f2832.pem
Created 1636090b.pem
Created bad35b78.pem
Created 930ac5d2.pem
Created d853d49e.pem
Created ae8153b9.pem
Created 876f1e28.pem
Created 54657681.pem
Created e8de2f56.pem
Created 5443e9e3.pem
Created 128805a3.pem
Created 5f267794.pem
Created aee5f10d.pem
Created 653b494a.pem
Created ef2f636c.pem
Created 79ad8b43.pem
Created 4597689c.pem
Created 98ec67f0.pem
Created 861a399d.pem
Created 157753a5.pem
Created 8b59b1ad.pem
Created e536d871.pem
Created 6b99d060.pem
Created c99398f3.pem
Created 2c543cd1.pem
Created cbeee9e2.pem
Created ad088e1d.pem
Created 8867006a.pem
Created 578d5c04.pem
Created 57b0f75e.pem
Created eacdeb40.pem
Created 201cada0.pem
Created a760e1bd.pem
Created 442adcac.pem
Created ee64a828.pem
Created c9f83a1c.pem
Created 56657bde.pem
Created a6a593ba.pem
Created 080911ac.pem
Created d7e8dc79.pem
Created 76faf6c0.pem
Created f3377b1b.pem
Created 67d559d1.pem
Created 9c2e7d30.pem
Created b42ff584.pem
Created 9b353c9a.pem
Created 2cfc4974.pem
Created 9f541fb4.pem
Created 778e3cb0.pem
Created c5e082db.pem
Created b13cc6df.pem
Created 2c3e3f84.pem
Created f90208f7.pem
Created c692a373.pem
Created cb59f961.pem
Created 861e0100.pem
Created 415660c1.pem
Created d9d12c58.pem
Created b7e7231a.pem
Created 2ab3b959.pem
Created 706f604c.pem
Created f081611a.pem
Created f387163d.pem
Created ae8153b9.pem
Created b8e83700.pem
Created 6410666e.pem
Created ce026bf8.pem
Created 03f0efa4.pem
Created 667c66d4.pem
Created b1159c4c.pem
Created 3513523f.pem
Created 244b5494.pem
Created f060240e.pem
certs/ce026bf8.pem expired on 20131024! Removing...

Revision 23545  Directory Listing
Modified Sun Aug 3 20:08:26 2014 UTC (3 years, 1 month ago) by pinter
ENH: Minor subject hierarchy enhancements

If a subject hierarchy node is deleted that has children, the user is given the option to delete branch.
Subject hierarchy added to favorite module list (still not appearing, because QSettings is pre-loaded from somewhere)

Revision 23537  Directory Listing
Modified Fri Aug 1 20:03:56 2014 UTC (3 years, 1 month ago) by pinter
BUG: Fixed SimpleITK to Slicer volume push

Color node as not set when creating display node for volumes pushed from SimpleITK to Slicer, so it could not be displayed. See http://slicer-users.65878.n3.nabble.com/Multiplying-volume-voxel-values-by-scalar-using-SimpleITK-output-garbled-td4027804.html

Revision 23517  Directory Listing
Modified Wed Jul 30 18:39:02 2014 UTC (3 years, 1 month ago) by mwoehlke
ENH: Add logging to extension update check

Add logging messages to report status when checking for updates, and
when an update is scheduled. (In particular, this reports a warning if
the server extension information query fails.)

Issue #3784

Revision 23510  Directory Listing
Modified Wed Jul 30 06:03:53 2014 UTC (3 years, 1 month ago) by jcfr
STYLE: Remove unused/commented CMake code from Base/Logic/CMakeLists.txt

Revision 23506  Directory Listing
Modified Tue Jul 29 23:59:34 2014 UTC (3 years, 1 month ago) by jcfr
ENH: Added developer mode and base classes for scripted modules

* Added "Enable developer mode" option in the application settings
(Developer section, next to Enable QtTesting)

* Added base classes for scripted module, widget, logic, and test: they
make scripted modules simpler and shorter and also more functions and
helper methods can be added in the future without changing each scripted
module
** Module handles selftest registration
** Widget handles reload&test (shown on GUI only in developer mode)
** Logic and Test contains delayDisplay utility function

* As an example, updated ScriptedLoadableModuleTemplate and SurfaceToolbox to use the new base classes

From: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

Revision 23504  Directory Listing
Modified Tue Jul 29 23:24:04 2014 UTC (3 years, 1 month ago) by mwoehlke
ENH: Implement installation of updates

Implement installation of updates to extensions (consisting of first
removing the old version, then installing the new version). Note that
this will attempt to install new dependencies as well. Also, change
handling of update downloads to additionally write the metadata for the
update (in addition to the archive), as we'll want it when we install
the update and need to persist it across a restart.

Issue #2089

Revision 23503  Directory Listing
Modified Tue Jul 29 23:24:03 2014 UTC (3 years, 1 month ago) by mwoehlke
BUG: Improve UI update scheduling

Improve update handling to enable 'restart' button when appropriate due
to update-related actions. Disable updating of extensions scheduled to
be uninstalled (the model already does this, but having the button
enabled makes for a confusing user experience where clicking the update
button does nothing).

Issue #2089

Revision 23502  Directory Listing
Modified Tue Jul 29 23:24:02 2014 UTC (3 years, 1 month ago) by mwoehlke
ENH: Hook up UI for updating extensions

Hook up update availability and download progress reporting in extension
model. Add UI to extension manager to report update availability and
allow requesting updates and canceling such requests. This brings update
management almost to full functionality, missing only to actually
install the update on restart.

Issue #2089

Revision 23501  Directory Listing
Modified Tue Jul 29 23:24:00 2014 UTC (3 years, 1 month ago) by mwoehlke
ENH: Improve extension manager info icons

Tweak the information icons used in the extension manager to have whiter
glyphs, and a less muddy glyph for the 'i' (update available) icon.

Revision 23500  Directory Listing
Modified Tue Jul 29 23:23:59 2014 UTC (3 years, 1 month ago) by mwoehlke
ENH: Download updates

Refactor update download logic, introducing a new 'task' class to
manager downloads, rather than trying everything through the network
manager's signals. Also, move the code to start such a task to a helper
function. Leverage these to hook up downloading of updates, now that
tasks can have different completion handlers assigned. Write update
archive file and scheduling information on update download completion.

Issue #2089

Revision 23499  Directory Listing
Modified Tue Jul 29 23:23:58 2014 UTC (3 years, 1 month ago) by mwoehlke
ENH: Start adding logic to check for updates

Add logic to issue server API calls to check for updates to extensions,
and to manage the same. This is still missing anything to actually
download or apply said updates.

Issue #2089

Revision 23498  Directory Listing
Modified Tue Jul 29 23:23:57 2014 UTC (3 years, 1 month ago) by mwoehlke
ENH: Adding API to check for extension updates

Add some initial API to manage scheduling extensions for update, similar
to how we schedule extensions for uninstall (as the implementation will
necessarily be similar). For now, the settings management should be
working; the rest (including a checkForUpdates() method) is mostly
placeholder that is needed to start implementing UI and underlying
logic.

Issue #2089

Revision 23497  Directory Listing
Modified Tue Jul 29 23:23:56 2014 UTC (3 years, 1 month ago) by mwoehlke
ENH: Remember if updates are automatic

Store if the user has enabled automatic extension updates in QSettings.

Issue #2089

Revision 23482  Directory Listing
Modified Thu Jul 24 06:16:04 2014 UTC (3 years, 2 months ago) by jcfr
BUG: Properly serialize python paths when installing extension. Fixes #3772

Following r23036 environment variable specifying list of path were
handled differently. This commit ensures that python paths associated
with extension are also serialized into the settings by following the
new convention introduced in r23036.

For example, before this commit, after installing an extension named
"Foo", the settings contained:

// ----------------------
[Modules]
AdditionalPaths=/home/jchris/.config/NA-MIC/Extensions-23473/Foo/lib/Slicer-4.3/qt-scripted-modules

[...]

[EnvironmentVariables]
PYTHONPATH=/home/jchris/.config/NA-MIC/Extensions-23473/Foo/lib/Slicer-4.3/qt-scripted-modules
// ----------------------

whereas the following is now written:

// ----------------------
[Modules]
AdditionalPaths=/home/jchris/.config/NA-MIC/Extensions-23473/Foo/lib/Slicer-4.3/qt-scripted-modules

[...]

[PYTHONPATH]
1\path=/home/jchris/.config/NA-MIC/Extensions-23473/Foo/lib/Slicer-4.3/qt-scripted-modules
size=1
// ----------------------

Revision 23479  Directory Listing
Modified Wed Jul 23 16:38:13 2014 UTC (3 years, 2 months ago) by mwoehlke
BUG: Fix missing icons in extension manager

Update qSlicerBaseQTGUI.qrc[1] to include icons for new tool menu in
extension manager. This fixes the button for the same having no icon on
systems that lack the themed icon, as the non-themed icon was being
specified and exists in the source tree, but was missing from the
aforementioned .qrc.

(1: http://www.slicer.org/slicerWiki/index.php/Documentation/Nightly/Developers/Build_system/Qt_resource_files)

Revision 23472  Directory Listing
Modified Mon Jul 21 20:50:56 2014 UTC (3 years, 2 months ago) by pieper
BUG: 3688 unicode characters from dicom

Add a utility to handle unicode conversion.  It works in the
ScalarVolume plugin but not in the Subject Hiearchy
code.  I want to run this by @pinter for help.

Revision 23453  Directory Listing
Modified Fri Jul 18 04:45:59 2014 UTC (3 years, 2 months ago) by jcfr
COMP: Fix doxygen warnings and tweak doxygen layout

This commit also updated the main page to include an "important link"
section. It has been inspired by the Blender main page.

Revision 23451  Directory Listing
Modified Fri Jul 18 00:08:55 2014 UTC (3 years, 2 months ago) by jcfr
COMP: Silence widget name already in use in qSlicerSettingsModulesPanel

This commit fixes the following warning:

/path/to/Slicer/Base/QTGUI/Resources/UI/qSlicerSettingsModulesPanel.ui: Warning: The name 'horizontalLayout_4' (QHBoxLayout) is already in use, defaulting to 'horizontalLayout_41'

Revision 23413  Directory Listing
Modified Fri Jul 4 01:34:23 2014 UTC (3 years, 2 months ago) by jcfr
COMP: Move most of find_package calls into each Slicer sub-project.

To help address issue #3741 [1], call to find_package associated to CTK,
DCMTK, ITK and SlicerExecutionModel have been moved in every Slicer
sub project, library or module expecting it.

This allows to reduce both the number of include directories and
the number of libraries passed to the compiler.

Moving forward, every Slicer sub project, library or module will be
responsible to call find_package (optionally specifying a list of
components) and (if it applies) include the associated "use file".

Note that call to find_package(VTK) is still done at the top-level, before
moving the call to the expected sub-directories, the CTKConfig.cmake
will have to be updated to call find_package(VTK) specifying the required
components where it is needed.

[1] http://na-mic.org/Mantis/view.php?id=3741

Revision 23412  Directory Listing
Modified Fri Jul 4 01:33:36 2014 UTC (3 years, 2 months ago) by jcfr
COMP: Disable VTK find_package/use_file_include in sub directory.

Calling "find_package(VTK)/include(${VTK_USE_FILE})" in both the top-level
directory and sub-directories is undefined. Indeed, If we include
VTK_USE_FILE (UseVTK.cmake) in the top level then it is probably adding
the autoinit definitions to the COMPILE_DEFINITIONS directory property.
Then that inherits to the sub-directory and could conflict with any such
property defined there. Thanks to Brad King for his insight.

Revision 23404  Directory Listing
Modified Mon Jun 30 21:18:35 2014 UTC (3 years, 2 months ago) by mwoehlke
COMP: Silence unused parameter warning

Revision 23403  Directory Listing
Modified Mon Jun 30 21:18:34 2014 UTC (3 years, 2 months ago) by mwoehlke
ENH: Show messages while installing extension file

Tweak extension 'install from file' logic to catch and display (via
QMessageBox) any messages reported relevant to the install process. This
includes errors and the success message added in the previous commit.

Revision 23402  Directory Listing
Modified Mon Jun 30 21:18:33 2014 UTC (3 years, 2 months ago) by mwoehlke
ENH: Add logging message for installed extension

Add helper to qSlicerExtensionsManagerModel to spit out info-level
logging messages from the same. Add such message on successful install
of an extension.

Revision 23401  Directory Listing
Modified Mon Jun 30 21:18:32 2014 UTC (3 years, 2 months ago) by mwoehlke
ENH: Add ability to install extension from file

Hook up 'install from file' action in extension manager. Create an
overload of qSlicerExtensionsManagerModel::installExtension taking only
an archive file name, which uses the new list_archive method to
determine the extension name and then hands off to the existing method.
Modify the existing overload to cope with the lack of server metadata
that occurs in this case, and to fill in a sufficient subset from common
information (i.e. the os/arch/revision of currently running Slicer) and
the description file provided in the extension archive.

This should allow users to install extensions from externally obtained
archives of the same (e.g. manually downloading from the server with an
external web browser).

Issue #2145

Revision 23400  Directory Listing
Modified Mon Jun 30 21:18:31 2014 UTC (3 years, 2 months ago) by mwoehlke
BUG: Correctly encode archive file name

Use qPrintable() (which uses QString::toLocal8Bit() under the hood) to
encode the QString archive file name to char const* for passing to
extract_tar, rather than QString::toLatin1(), which is unlikely to
produce the correct bytes (the underlying system calls are more likely
to want system locale encoding) in case of a non-ASCII file name.

This sort of thing appears to be endemic to Slicer, but I don't care to
propagate that to the forthcoming call to list_archive(); thus, making
it consistent in this file at least.

Revision 23399  Directory Listing
Modified Mon Jun 30 21:18:30 2014 UTC (3 years, 2 months ago) by mwoehlke
ENH: Add function to list archives

Add a function to vtkArchive.cxx to obtain the list of files in an
archive without extracting the archive. Also, fix parameter name in
(misnamed) extract_tar to make at least some kind of sense.
("archiveFileName", as in list_archive(), would be better, since
extract_tar likewise works on non-tar archives, but for now leaving it
consistent with the function name.)

Revision 23398  Directory Listing
Modified Mon Jun 30 21:18:28 2014 UTC (3 years, 2 months ago) by mwoehlke
ENH: Initial refactoring of extension manager UI

Refactor right corner area of extension manager into a .ui file, similar
to how the left corner area (navigation buttons) is already handled.
This allows us to have separate search widgets per tab (allowing for
independent search states, if/when support for searching installed
extensions is added), and also to add a 'configure' button (which we do)
that provides independent menus per tab.

The menus are created, but not yet functional. Icons (from the Public
Domain Tango theme) are also added. (The 'check for updates' icon uses
the theme pixmaps. Tango does not provide a 'configure' icon as such, so
the modified svg from which the pixmaps were generated is also being
committed.)

Issue #2089
Issue #2145

Revision 23356  Directory Listing
Modified Sat Jun 21 16:20:05 2014 UTC (3 years, 3 months ago) by jcfr
COMP: Find qRestAPI package only where required.

This commits moved the discovery of the qRestAPI module in both QTCore
library and DataStore remote module.

Revision 23355  Directory Listing
Modified Sat Jun 21 16:20:03 2014 UTC (3 years, 3 months ago) by jcfr
COMP: Find LibArchive/CURL/OpenIGTLink/ZLIB package where required.

This commit complements commit r23350 and will help reducing the number
of parameters passed to the compiler/linker. See #3741

Revision 23343  Directory Listing
Modified Wed Jun 18 15:02:14 2014 UTC (3 years, 3 months ago) by jcfr
COMP: Fix Slicer build warnings

This commit addresses two types of warnings:
 - unused variable warnings
 - RCC: Warning: No resources in '/path/to/foo.qrc

Revision 23333  Directory Listing
Modified Tue Jun 17 02:56:24 2014 UTC (3 years, 3 months ago) by jcfr
ENH: Tweak Multi-sampling option

This commits improve the user experience related to
new multi sample option introduced in r23305. It now
allows to specify the number of samples.

Finally the code has been refactored to improve
the flow of changes and to use a cleaner signal/slot
interface.

From: Eric Larson <larson.eric.d@gmail.com>

Revision 23326  Directory Listing
Modified Wed Jun 11 19:23:08 2014 UTC (3 years, 3 months ago) by pieper
STYLE: remove unused backwards compatibility code

This snippet of code was used during the initial porting of code
from slicer3 to slicer4 but has since been replaced with direct access
to the corresponding items via the regular layoutManager API.

This code also had the unwanted restriction that all Slice View
layout names had to be valid python identifiers (no hyphens or
spaces) which led to spurious syntax error messages for some use
cases.

Revision 23322  Directory Listing
Modified Mon Jun 9 19:18:24 2014 UTC (3 years, 3 months ago) by mwoehlke
ENH: Clean up icon usage

Create new "XSmall" icon size for 16x16 icons, enabling us to provide
separate 16x16 (e.g. menu) and 22x22 (e.g. tool bar) icon sizes. Replace
ugly undo/redo icons with icons from the (public domain) Tango[1] theme.
Replace home icon with its Tango version for better consistency. Create
a script to generate qSlicerBaseQTGUI.qrc, as manually adding as many as
five entries per new icon is unnecessarily awkward. Arrange to use
themed icons when possible.

(1: http://tango.freedesktop.org/Tango_Icon_Library)

Revision 23321  Directory Listing
Modified Mon Jun 9 19:18:22 2014 UTC (3 years, 3 months ago) by mwoehlke
STYLE: Remove unused icons

Remove some icon files from the repository that are not used anywhere.
This is in preparation for a major clean-up and refactoring.

Revision 23320  Directory Listing
Modified Mon Jun 9 19:18:21 2014 UTC (3 years, 3 months ago) by mwoehlke
ENH: Improvements to extension notification icons

Clean up the SVG for the existing extension notification icons, and
change the error icon from a circle to a box (matches oxygen, and
"frees" the circle for the information icon, such that all three have
different shapes). Add an information icon. It's not in use yet, but
will be used for updates.

Revision 23319  Directory Listing
Modified Mon Jun 9 17:02:03 2014 UTC (3 years, 3 months ago) by mwoehlke
BUG: Don't stop uninstall on first error

Change how we process scheduled extension uninstall operations to
continue trying to uninstall all extensions, rather than stopping the
process after the first error. The old behavior is a result of operand
order to the '&&' operator, which employs short-circuit evaluation to
skip evaluation of the second argument (the call to uninstall the
extension) if the first argument (the overall result 'accumulator') is
false, and was likely unintentional, due to overlooking the short
circuit evaluation.

Revision 23318  Directory Listing
Modified Mon Jun 9 17:02:02 2014 UTC (3 years, 3 months ago) by mwoehlke
STYLE: Fix spelling error in comment

Revision 23305  Directory Listing
Modified Wed Jun 4 18:42:43 2014 UTC (3 years, 3 months ago) by jcfr
ENH: Add Multi-sampling option

This commits leverage the functionality already added in CTK [1] by
adding "Views" settings panel allowing to enable/disable
anti-aliasing.

[1] https://github.com/commontk/CTK/commit/b39d95edd9be0965a85bcd9fbc12bb64edb9041a

From: Eric Larson <larson.eric.d@gmail.com>

Revision 23299  Directory Listing
Modified Tue Jun 3 19:07:40 2014 UTC (3 years, 3 months ago) by mwoehlke
BUG: Avoid unneeded copy of resource bytes

Modify qSlicerCoreApplication::[un]registerResource to use the
QByteArray's constData() rather than mutable data() in order to avoid an
unnecessary detach of the internally shared data. (Our usage does not
require a mutable pointer at any time.)

Revision 23298  Directory Listing
Modified Mon Jun 2 04:13:27 2014 UTC (3 years, 3 months ago) by jcfr
BUG: Ensure Slicer ITKFactory plugins are loaded

After the update of CTK in r23256, the instantiation of the ctkErrorLogModel
was done before calling qSlicerCoreApplication::init(). This commit moves
the instantiation after the call to init() where the ITK_AUTOLOAD_PATH
was set. This will ensure the dynamic factories are discovered and loaded.

Revision 23293  Directory Listing
Modified Fri May 30 22:43:30 2014 UTC (3 years, 3 months ago) by mwoehlke
ENH: Also find templates in build (source) tree

Add slicer.util.sourceDir() convenience method to retrieve the Slicer
source directory, when running from a local build tree. Change Extension
Wizard module to prefer to use templates from the same, if available.

Revision 23290  Directory Listing
Modified Fri May 30 22:43:25 2014 UTC (3 years, 3 months ago) by mwoehlke
ENH: Add support for real Qt resources in Python

Add methods to qSlicerCoreApplication to allow Python code to invoke the
raw data overloads of QResource::[un]registerResource (which otherwise
cannot be invoked, as the requisite uchar* overloads are hidden by the
QString overloads). Create a Python script to generate a Python compiled
resource script (similar to pyrcc4 or pyside-rcc, except leveraging Qt's
native rcc rather than reimplementing it). Create CMake functions to
invoke this in an appropriate manner, and to create necessary target
dependencies so that the resulting Python files are created before the
ctkFunctionAddCompilePythonScriptTargets targets try to copy them to
their final build locations.

This system will allow Python loadable modules to use Qt resources by
creating a .qrc file and loading the resources using ':/path' notation,
in the same manner as C++ code (rather than individually copying every
resource file and loading them relative to the module's directory).

Revision 23286  Directory Listing
Modified Fri May 30 22:43:20 2014 UTC (3 years, 3 months ago) by mwoehlke
ENH: Expose Slicer share path

Make Slicer_SHARE_DIR accessible via a property on the
qSlicerCoreApplication, which makes it available via Python without
relying on the SLICER_SHARE_DIR environment variable.

Revision 23283  Directory Listing
Modified Fri May 30 22:43:17 2014 UTC (3 years, 3 months ago) by mwoehlke
ENH: Allow access to settings dialog from Python

Make qSlicerApplication::settingsDialog Q_INVOKABLE, in order to allow
access to the settings dialog from Python (e.g. scripted modules).

Revision 23280  Directory Listing
Modified Fri May 30 22:43:14 2014 UTC (3 years, 3 months ago) by mwoehlke
ENH: Allow loading modules [from Python]

Move qSlicerAbstractModuleFactoryManager::registerModule(QFileInfo) from
protected to public Q_INVOKABLE, so that users (Python users in
particular) can manually register additional modules at run time. Add
new (also public Q_INVOKABLE) method to qSlicerModuleFactoryManager
allowing users to request that a specific list of modules be loaded (and
instantiated, if necessary).

This allows e.g. a user at the Python console to dynamically load a
module that is not in the search paths at run time, without modifying
the search paths. In particular, this will be useful to the Extension
Wizard module.

Revision 23258  Directory Listing
Modified Thu May 29 01:37:23 2014 UTC (3 years, 3 months ago) by hjohnson
ENH: Simplify logic for pushing sitk objects to slicer

After reviewing the SimpleFilters code a simpler and
more robust methods of pushing SimpleITK images to
slicer was identified.

Revision 23256  Directory Listing
Modified Wed May 28 22:04:19 2014 UTC (3 years, 3 months ago) by jcfr
BUG: Update CTK - Fix "No such slot" warning and optimize ctkVTKConnection

* Fixes #3361: Fix "No such slot" warning and optimize ctkVTKConnection

* Fixes #3719: py_SubjectHierarchyGenericSelfTest passes but it output warning about slot disconnection

* Improve performance of ctkVTKConnection creation/removal

* Add Qt5 support to CTK

* Thanks to Eric Larson. ctkAbstractView now provides a method allowing to
set multisampling.

* Since ctkErrorLogModel has been moved from CTKCore to CTKWidget (because
QStandardItemModel belongs to QtGUI), similarly the error log model has
been moved from qSlicerCoreApplication to qSlicerApplication.

Details:

$ git shortlog daaf705c..6f2c55809 --no-merges
Eric Larson (1):
      Added static method to set multisampling.

Jean-Christophe Fillion-Robin (18):
      Fix compilation of tests against VTK6
      Fix qDebug operator to handle case when VTKObject is null
      Improve documentation of setStrictTypeCheck() method
      Remove unused signal "isBroke()"
      Refactor ctkVTKConnectionTest1 for easier maintenance and readability
      Update ctkVTKConnectionTest1 to use ctkCallback
      Update ctkVTKConnectionTest1 to allow each test case to be run independently
      Split disconnect function
      Allow ctkVTKConnection pimpl to be subclassed
      Add method to return VTK object associated with ctkVTKConnection
      Add ctkVTKConnectionTestObjectDelete
      Fix ctkVTKConnectionTestObjectDelete
      Improve performance disabling "deletion" observation
      Fix ctkVTKConnectionTest1 removing connection time ratio test
      ENH: Pass Qt CMake variable using "mark_as_superbuild"
      Fixes configuration when enabling PythonQt wrapping
      Remove extra CMake debug statement introduced by commit 47b34216
      Update CTKWidget PythonQt decorator to fix build error following Qt5 transition

Julien Finet (1):
      Add support for Qt5

Matthew Woehlke (1):
      Allow compiling/installing generated Python files

Sascha Zelzer (8):
      First set of build system patches for Qt5 support.
      This commit enables Qt5 support for the CTK Core library, issue #277.
      Use Qt5 CMake 2.8.12 features.
      Qt5 compatibility for almost all libraries.
      Do not assume a specific Qt5 install structure.
      Make more libs and apps compatible with Qt5.
      Use Qt5 compatible qRestAPI version.
      Fix Qt5 dependencies in case only CTK_BUILD_ALL is enabled.

Revision 23253  Directory Listing
Modified Wed May 28 15:43:15 2014 UTC (3 years, 3 months ago) by mwoehlke
BUG: Don't install already-installed dependencies

When considering an extension's dependencies, don't prompt about (or
attempt to (re)install) dependencies that are already installed.

Issue #2912

Revision 23246  Directory Listing
Modified Tue May 27 23:05:35 2014 UTC (3 years, 4 months ago) by jcfr
BUG: Added error reporting for scene file writing

The problem was that when the scene file (.mrml) saving
failed (e.g., because target was a read-only directory) then
no error was reported.

No error was reported for the sceneview thumbnail image
saving failure either.

From: Andras Lasso <lasso@queensu.ca>

Revision 23232  Directory Listing
Modified Fri May 23 17:24:09 2014 UTC (3 years, 4 months ago) by jcfr
ENH: Improved scripted module loading error message

It happened multiple times in our group that a developer spent a lot of time trying to find errors in a scripted module, simplify the class, make it more similar to the template, etc. to find what can be wrong in the class because "Failed to load scripted pythonqt module class definition" error was reported. Then it turned out that the module class is perfect, only the name does not match the filename.

Implemented fix: changed the error message to "class ... not found in file ..." to make it clear that the problem is not in implementation of the class but in the name.

From: Andras Lasso <lasso@queensu.ca>

Revision 23231  Directory Listing
Modified Fri May 23 03:43:45 2014 UTC (3 years, 4 months ago) by jcfr
BUG: Fix failing qSlicerExtensionsManagerModelTest

Commit r23200 added icon URL to extension metadata and commit 9dc157 [1]
updated the server to return the iconurl, this commit
fixes the server mock data also adding iconurl .

[1] https://github.com/midasplatform/slicerpackages/commit/9dc1575d2bf9d3c053700f541cdb5034f8328eee

Revision 23229  Directory Listing
Modified Fri May 23 03:43:40 2014 UTC (3 years, 4 months ago) by jcfr
STYLE: Remove forgotten debug statement in installExtension

Revision 23212  Directory Listing
Modified Mon May 19 21:38:57 2014 UTC (3 years, 4 months ago) by mwoehlke
ENH: Install extension dependencies

When installing an extension, also query the extension's internal
description file for its list of dependencies, and prompt to install
them as well.

Issue #2912

Revision 23204  Directory Listing
Modified Mon May 19 18:18:44 2014 UTC (3 years, 4 months ago) by mwoehlke
BUG: Always use same size for extension icon

Change how we generate extension icons to first resize the raw icon to
the list icon size (and then adjust the rounding radius accordingly).
While not strictly necessary for "normal" sized (128x128) icons, doing
the resize up front saves doing it on each paint, and also gives a more
consistent result for icons of other than the "normal" size. (In
particular, it fixes the text being misaligned in case of smaller icons,
which previously would not be upscaled.)

Revision 23203  Directory Listing
Modified Mon May 19 18:18:43 2014 UTC (3 years, 4 months ago) by mwoehlke
BUG: Remove extension icon on uninstall

Tweak the extension uninstall logic to also find and remove the
extension icon, if any.

Revision 23202  Directory Listing
Modified Mon May 19 18:18:42 2014 UTC (3 years, 4 months ago) by mwoehlke
ENH: Implement downloading of extension icons

Change qSlicerExtensionsManageWidget to attempt to download icons for
extensions that don't already have an icon on disk. On successful
download, the icon is saved and applied to the extension list item.

Note that we will retry downloads for missing icons on first showing of
the extension manager. This seems like reasonable behavior. Missing
icons fall back to the default icon as before, and download errors are
silent.

Issue #1907

Revision 23201  Directory Listing
Modified Mon May 19 18:18:41 2014 UTC (3 years, 4 months ago) by mwoehlke
ENH: Load extension icon from disk

Change extension manager to attempt to load the icon for the extension
from disk, given the URL (which serves to provide a reasonable file
type, hopefully). For now this assumes that the icon already exists;
next, we'll want to try to download it if not.

Note that, rather than using the icon image directly, we render it as a
rounded rectangle in order to apply some rounding to the icon's corners,
for consistency with the web view which does something similar.

Issue #1907

Revision 23200  Directory Listing
Modified Mon May 19 18:18:40 2014 UTC (3 years, 4 months ago) by mwoehlke
ENH: Add icon URL to extension metadata

Revision 23199  Directory Listing
Modified Mon May 19 18:18:39 2014 UTC (3 years, 4 months ago) by mwoehlke
STYLE: Use a delegate to control extension icon

Change how we manage icons in the extension manager to always set a
'normal' icon on the list item, and to use a delegate to override
whether the item is drawn 'disabled'. This allows us to set an
unchanging icon on the item, and take advantage of the normal drawing
code to draw a disabled icon when appropriate, rather than having to
reset the icon. Right now there is no visible change, but this will
simplify things significantly when we start using 'real' extension icons
rather than the default icon.

Revision 23182  Directory Listing
Modified Thu May 15 21:05:37 2014 UTC (3 years, 4 months ago) by finetjul
COMP: Reduce the number of duplicated include directories

Too many included directories may fail to build on Windows but also on
Linux because it generates very long command lines.

Revision 23176  Directory Listing
Modified Wed May 14 05:01:02 2014 UTC (3 years, 4 months ago) by jcfr
COMP: Fix unused variable / unused typdefs warnings.

From: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

Revision 23174  Directory Listing
Modified Tue May 13 22:11:02 2014 UTC (3 years, 4 months ago) by mwoehlke
BUG: Don't store style settings per version

Move the settings location where the user's selected style and
additional style paths are stored from the per-version store to the
general user store, as there is no particular reason why these would be
version specific, and having to set them after every update (especially
in a developer environment) is a little annoying.

Issue #3691

Revision 23173  Directory Listing
Modified Tue May 13 17:42:49 2014 UTC (3 years, 4 months ago) by mwoehlke
ENH: Always return to extensions list

Tweak extension manager to navigate the manage browser back to the
initial page on changing tabs, so that when the user changes to the
'install' tab and back to the 'manage' tab, they always see the list of
installed extensions.

Revision 23172  Directory Listing
Modified Tue May 13 17:42:48 2014 UTC (3 years, 4 months ago) by mwoehlke
ENH: Add 'More' link in extension manager (2/2)

Add another web browser to extension manager to show details pages for
installed extensions Refactor navigation buttons so that they are
available for both tabs (different set of actual buttons, but same
concept). Tweak qSlicerExtensionsInstallWidget (which we need to use as
the browser, for various reasons, including so that we have 'uninstall'
rather than 'download' buttons) to have an option to not load the
'browse available extensions' page.

Issue #3608

Revision 23171  Directory Listing
Modified Tue May 13 17:42:47 2014 UTC (3 years, 4 months ago) by mwoehlke
ENH: Add 'More' link in extension manager (1/2)

Use the newly available extension ID to provide a 'More' link in the
extension manager. Add necessary code to implement link signals in
qSlicerExtensionsDescriptionLabel.

This is part 1 of 2; the links are not yet functional as we currently
lack a way to open the page. (We don't want to use the web view for
installing, as that would cause an undesired switch to the 'install'
tab.)

Note that the QSignalMapper for links is removed, as it is not needed;
the link URL provides the necessary information and can be used
directly.

Issue #3608

Revision 23170  Directory Listing
Modified Tue May 13 17:42:46 2014 UTC (3 years, 4 months ago) by mwoehlke
STYLE: Simplify metadata stripping

Rather than iterating over the whole metadata and copying keys one at a
time if not in the 'ignore' set, just copy the whole thing en-masse and
remove the unwanted values. This gives simpler code.

Revision 23169  Directory Listing
Modified Tue May 13 17:42:45 2014 UTC (3 years, 4 months ago) by mwoehlke
ENH: Include ID in extension model

Change qSlicerExtensionsManagerModel to not remove the extension_id from
the extension metadata. The ID is needed to find the extension
information page, which we would eventually like to be accessible for
installed extensions.

Revision 23168  Directory Listing
Modified Tue May 13 17:42:44 2014 UTC (3 years, 4 months ago) by mwoehlke
ENH: Improve display of disabled extensions

Change extension manager to append '(disabled)' after the extension name
when an extension is disabled, and to use disabled text color, which is
both more consistent with the icon display, and improves recognizability
of disabled extensions.

Revision 23167  Directory Listing
Modified Tue May 13 17:42:43 2014 UTC (3 years, 4 months ago) by mwoehlke
BUG: Fix extension manager item sizing

Refactor qSlicerExtensionsDescriptionLabel to manage the text internally
as our own QTextDocument instance, and to do the painting ourselves.
This gives us greater control over the painting with less work, and
greatly simplifies producing a correct size hint, since we can just ask
the document for its size and get a correct answer regardless of
formatting, rather than trying to compute it ourselves from font
metrics. Now that we have a reasonable size hint, also use it to set the
item size hint, which ensures that the items are sufficiently tall e.g.
in case of the extra text line when an extension is incompatible.

Revision 23166  Directory Listing
Modified Tue May 13 17:42:42 2014 UTC (3 years, 4 months ago) by mwoehlke
ENH: Initial work refactoring extension manager

After a losing battle trying to make the tree widget not use half the
space for the buttons, replace it with a list widget. Change the buttons
to have a stacked layout without enforced horizontal size, which gives
much more space to the extension text, add some padding so the icons
aren't so tight against each other, and increase the font size of the
extension name. Also, replace the random clipart icons with our own.

NOTE: Minimum size for the list items is not working correctly at the
moment. The text rendering needs some additional refactoring in order to
provide a correct minimum size, and a size hint needs to be set
explicitly on the list items.

Revision 23152  Directory Listing
Modified Tue May 13 03:52:15 2014 UTC (3 years, 4 months ago) by jcfr
COMP: Simplify MRML Scene API removing "Edited()" method. Fixes #3472

For sake of consistency, remove Edited method. Indeed, this was the only
event triggered using this approach and it was not observed. For reference,
this method was first introduced by commit r7727.

Revision 23146  Directory Listing
Modified Fri May 9 16:04:22 2014 UTC (3 years, 4 months ago) by mwoehlke
BUG: Replace improperly licensed icons

Replace icons which were taking from the Oxygen theme and being used in
violation of their license (LGPLv3, which would require us to at minimum
be providing the scalable versions) with icons from the Tango theme,
instead, which are Public Domain.

Note that the statement in r21618 that the icons were licensed under
CC-BY-SA 3.0 appears to be incorrect. While that claim is indeed made by
Open Icon Library, I was unable to find any evidence to substantiate it,
and all other sources (including the canonical kde.org distribution
tarball) give LGPLv3 as the only applicable license.

See also http://techbase.kde.org/Projects/Oxygen/Licensing,
http://commons.wikimedia.org/wiki/Tango_icons and
http://en.wikipedia.org/wiki/Tango_Desktop_Project.

PNG's copied from tango-icon-theme-0.8.90-6.fc17.noarch.

Revision 23143  Directory Listing
Modified Thu May 8 17:28:24 2014 UTC (3 years, 4 months ago) by finetjul
BUG: Fix VTK python library paths on Windows for VTKv6

Issue #3514

Revision 23131  Directory Listing
Modified Mon May 5 20:27:53 2014 UTC (3 years, 4 months ago) by mwoehlke
BUG: Don't rely on URL change to update search

Also set the current search text (used to avoid unnecessary updates)
when applying the search filter. This way, the test still works if we
never get the URL changed signal (which seems to happen on some machines
for reasons unknown). In theory, since the URL change is being triggered
by JavaScript and not waiting on a server response, it should happen
immediately anyway, possibly even synchronous in the call to
evaluateJavaScript().

This should fix inability to clear the search text on some machines
(because failure to update the last search text means we always think
we have no search, and therefore don't need to do anything to clear the
search text).

Revision 23130  Directory Listing
Modified Mon May 5 20:27:52 2014 UTC (3 years, 4 months ago) by mwoehlke
ENH: Disable search on extension details page

Tweak handling of the extension search field to disable it when looking
at the detail page of an extension, as it makes no sense in this case.
Also disable it (for now) when managing installed extensions.

Revision 23129  Directory Listing
Modified Mon May 5 20:27:51 2014 UTC (3 years, 4 months ago) by mwoehlke
BUG: Fix missing search icon on some platforms

Use the CTK built-in fallback icon for the clear button in case loading
of the themed icon fails. This avoids having an invisible active click
area.

Revision 23128  Directory Listing
Modified Mon May 5 20:27:50 2014 UTC (3 years, 4 months ago) by mwoehlke
ENH: Add search to extension manager

Note that this requires that the extension server also support search
functionality.

Issue #3564

Revision 23122  Directory Listing
Modified Fri May 2 21:55:04 2014 UTC (3 years, 4 months ago) by finetjul
ENH: Add VTK 6 support 2/2

Issue #3514

Revision 23121  Directory Listing
Modified Fri May 2 21:49:48 2014 UTC (3 years, 4 months ago) by finetjul
ENH: Add VTK 6 support 1/2

1) Support vtk6 to build system.
http://www.vtk.org/Wiki/VTK/Build_System_Migration
Give users a build option between vtk5 and vtk6.
Solve vtk library python wrapping for VTK 6
Use system zlib (this is a hack)
Use system png (this is a hack)

2) Update dependency projects in superbuild including VTK, CTK, OpenIGTLinkIF, MultiVolumeExplorer.

3) Remove deprecated Macro.
The following two macros were deprecated in VTK 5.0 that were still supported, but have now been eliminated:
vtkTypeRevisionMacro has been replaced with vtkTypeMacro; vtkCxxRevisionMacro has been removed.
http://www.visitusers.org/index.php?title=VTK_6.0_Upgrade

The following two macros were deprecated in VTK 6.0 if VTK_LEGACY_REMOVE is on:
VTK_LARGE_INTEGER and VTK_LARGE_FLOAT
https://github.com/Kitware/VTK/blob/9a0fbb8da1a1701dc1b44c71467b969b3302efad/Common/Core/vtkType.h#L158-159

vtkFloatingPointType is replaced with double.
http://review.source.kitware.com/#/t/1667/

vtkType deprecations
http://www.vtk.org/Wiki/VTK/VTK_6_Migration/vtkType_deprecations

4) Replace SetInput() with SetInputData() and SetInputConnection(), the same kind of functions include SetInput1(), SetInput2(), AddInput() and SetSource().
http://www.vtk.org/Wiki/VTK/VTK_6_Migration/Replacement_of_SetInput

5) Remove GetProducerPort() from vtkDataObject.
http://www.vtk.org/Wiki/VTK/VTK_6_Migration/Removal_of_GetProducerPort

6) Remove Execute
http://www.vtk.org/Wiki/VTK/VTK_6_Migration/Removal_of_Execute

7) Remove SetWholeExtent() from vtkDataObject
http://www.vtk.org/Wiki/VTK/VTK_6_Migration/Removal_of_SetWholeExtent

8) Remove Methods for Manipulating Update Extent
http://www.vtk.org/Wiki/VTK/VTK_6_Migration/Removal_of_Methods_for_Manipulating_Update_Extent

9) Change AllocateOutputData() in vtkImageAlgorithm.
http://www.vtk.org/Wiki/VTK/VTK_6_Migration/Change_to_AllocateOutputData

10) Remove CopyInformation and CopyTypeSpecificInformation from vtkDataObject and vtkImageData.
http://www.vtk.org/Wiki/VTK/VTK_6_Migration/Removal_of_CopyInformation

11) Remove GetPipelineInformation and GetExecutive from vtkDataObject.
http://www.vtk.org/Wiki/VTK/VTK_6_Migration/Removal_of_GetPipelineInformation

12) VTK6 requires #include <vtkVersion.h> to use the VTK_xxx_VERSION preprocessor directives.
http://vtk.org/Wiki/VTK/VTK6/Migration/WikiExamples#Improve

13) Remove Methods for Manipulating Update Extent.
http://www.vtk.org/Wiki/VTK/VTK_6_Migration/Removal_of_Methods_for_Manipulating_Update_Extent.
http://vtk.org/Wiki/VTK/VTK6/Migration/WikiExamples#Improve.

14) Change scalars manipulation functions
http://www.vtk.org/Wiki/VTK/VTK_6_Migration/Changes_to_Scalars_Manipulation_Functions.
http://vtk.org/Wiki/VTK/VTK6/Migration/WikiExamples#Improve.

15) Remove Pipeline Update Methods from vtkDataObject.
http://www.vtk.org/Wiki/VTK/VTK_6_Migration/Removal_of_Update

16) Remove Pipeline Update Methods from vtkDataObject.
http://www.vtk.org/Wiki/VTK/VTK_6_Migration/Removal_of_Update.

17) Refactor functions in vtkMRMLModelNode and sublcasses.

18) Refactor functions in vtkMRMLVolumeNode and its subclasses.
Use ImageDataPort instead of ImageData

Issue #3514

From Yuzheng Zhou <yuzheng.zhou@kitware.com>

Revision 23119  Directory Listing
Modified Fri May 2 21:48:56 2014 UTC (3 years, 4 months ago) by finetjul
ENH: Remove VTK 4 backwards compatibility

Removed vtkSource, vtkProcessObject and subclasses.
http://www.vtk.org/Wiki/VTK/VTK_6_Migration/Overview#Removal_of_VTK_4_Backwards_Compatibility_Superclasses
http://www.vtk.org/Wiki/VTK/Tutorials/New_Pipeline#Converting_an_Existing_Filter_to_the_New_Pipeline

Closes #3485
From Yuzheng Zhou <yuzheng.zhou@kitware.com>

Revision 23105  Directory Listing
Modified Thu Apr 17 16:39:37 2014 UTC (3 years, 5 months ago) by lassoan
COMP: Fixed linux build warnings

Revision 23102  Directory Listing
Modified Wed Apr 16 17:40:24 2014 UTC (3 years, 5 months ago) by lassoan
ENH: Added visualization of transforms

New features:
* Support non-linear transforms in the Transforms module: allow Apply, Harden, Invert transform
* Transform information displayed in the Transforms module (type of transform, basic properties)
* Transform visualization:
** Built into the Transforms module
** Three main modes: Glyphs (show an array of arrows, cones, spheres), Grid (show a deformed grid), or Contour (show isolines/isosurfaces for specified displacement magnitude values)
** All transform types are supported (chains of transforms as well)
** Visualization in the slice viewers
** Visualization in the 3D viewers, in the specified region (region can be a slice viewer, a volume, or a ROI widget)
** Real-time update: if the transform (or any visualization parameter) is changed then the visualization is updated immediately (interactive visualization while editing the transform)
** Built-in colormap editor
* MetaImage (mha), NIFTI (nii) vector volumes can be loaded as displacement field (grid) transform

Revision 23077  Directory Listing
Modified Fri Apr 11 04:10:41 2014 UTC (3 years, 5 months ago) by jcfr
ENH: Remove ITKv3 support

As discussed on the mailing list [1] and reported on the Roadmap [2],
this commit removes all conditional code that was allowing Slicer4 to be
compiled against ITKv3.

Code that was building only against ITKv3 has also been removed. This
includes DicomToNrrdConverter CLI module
and SlicerITKv3N4MRIBiasFieldCorrectionImageFilter class.

[1] http://slicer-devel.65872.n3.nabble.com/Removal-of-ITKv3-support-tt4031364.html

[2] http://wiki.slicer.org/slicerWiki/index.php/Roadmap#Deprecation_.2F_API_Changes

Revision 23066  Directory Listing
Modified Thu Apr 10 00:56:05 2014 UTC (3 years, 5 months ago) by pieper
BUG: #3561 handle paths for windows

Earlier versions of the tpycl (tcl/python) layer worked on all
platforms, but apparently a change occured (maybe the
cmakeified python?) that led to a different interpretation
of this path and now native windows paths with backslashes
are returned from os.path.  As a result we need to convert the
paths before sending them to tcl, which always uses forward
slashes for standard directory operations on all platforms.

Revision 23062  Directory Listing
Modified Wed Apr 9 06:58:19 2014 UTC (3 years, 5 months ago) by jcfr
COMP: Fix build error introduced in commit r23061

Revision 23061  Directory Listing
Modified Wed Apr 9 06:25:58 2014 UTC (3 years, 5 months ago) by jcfr
ENH: Add support for scripted module available as ".pyc" file

Revision 23058  Directory Listing
Modified Tue Apr 8 17:41:15 2014 UTC (3 years, 5 months ago) by jcfr
ENH: Associate a component with install rules

Revision 23047  Directory Listing
Modified Fri Apr 4 22:34:32 2014 UTC (3 years, 5 months ago) by finetjul
BUG: Don't synchronize the number of decimals in CLI slider widgets

Remove ctkSliderWidget::SynchronizeDecimals default behavior.
Closes #3642

Revision 23041  Directory Listing
Modified Thu Apr 3 15:39:07 2014 UTC (3 years, 5 months ago) by mwoehlke
BUG: Use a safe temporary path for download

Change extension downloading to use a temporary file for the download
location. This ensures that a: we don't clutter the temporary directory
with old downloads, b: multiple users can download the same extension
using a shared temporary directory (e.g. most UNIX-like systems), and c:
the file name is not predictable, which is a security vulnerability.

Issue #3552

Revision 23021  Directory Listing
Modified Wed Mar 26 17:45:15 2014 UTC (3 years, 6 months ago) by hjohnson
STYLE: Remove end of line spaces

Spaces at the end of lines can cause noise in patch sets
when editors or git gobbles them up during other relatively
minor changes to files.

Removing end of line changes makes long term maintenance easier as
well.

When reviewing git histories or patch sets, the "--ignore-space-change"
option can be useful in filtering out changes due only to spacing.

i.e.
git diff HEAD~2 --ignore-space-change

Revision 23008  Directory Listing
Modified Wed Mar 19 17:41:09 2014 UTC (3 years, 6 months ago) by lassoan
ENH: Several fixes and improvements in transform handling

Major fixes:
* Added mechanism to prevent immediate invocation of TransformModified events (similarly to Modified events) to allow atomic changes of transforms and prevent multiple event invocations (fixes #3610, #3611).
* Fixed vtkITKBSplineTransform inverse computation (the bulk component was ignored in the inverse computation due to a shadow variable)
* Fixed DeepCopy of vtkITKBSplineTransform.cxx (InternalDeepCopy method had to be implemented)
* Use vtkTransform's ability to compute inverse transforms instead of keeping separate transforms for forward and inverse transforms (still kept the two member variables in the transform node base class to allow storing of forward and inverse transform if they are both computed, e.g., some Demons registration provides both the forward and inverse transforms as outputs).
* Fixed ReadWriteAsTransformToParent logic in the storage node class (as inverse warp transforms usually cannot be written, the flag should point to the forward transform class). For convenience, the flag is updated automatically when a To/FromParentTransform is set in the transform node.
* Fixed transform node copy: now a true deep copy is performed (earlier only the pointer of the transforms were copied, therefore changing a transform in a node changed the copied node, too)
* Removed vtkMRMLNonlinearTransformNode, as non-linear transforms are not special cases anymore: the base transform class can manage them the same way as linear transforms.
* Changed Get/SetMatrixTransformToParent and Get/SetMatrixTransformFromParent method to make it clear that it makes a copy of the input and output, so changing a matrix is only possible by using the Set... method (and not Get...()->DeepCopy(...)). Kept the old functions to prevent build errors, but they are deprecated and a warning is logged if they are used (as the behavior of the Get... function is changed from a shallow copy to a deep copy). This API change required changing of a lot of file in the Slicer core and extensions.

Minor fixes:
* Made vtkMRMLTransformNode non-abstract: this is the class that can handle arbitrarily complex composite transforms (e.g., grid transform hardened on a bspline transform).
* Fixed invalid NonLinearTransformScene.mrml scene: wrong storage node ref ID caused warnings in the tests
* Changed the Bspline-f-m.tfm test data to include larger bulk component to make errors more detectable
* Added tests for composite transforms (e.g., hardened combination of grid and bspline transform)
* Split the transform node's huge read/write methods to separate smaller methods (one for each transform type)
* Added the option of loading a .mha file as a grid transform

Extensions updated according to the API change: OpenIGTLinkIF, SlicerIGT, SlicerRT, and TransformVisualizer. See details at:
https://github.com/openigtlink/OpenIGTLinkIF/pull/25
https://github.com/SlicerIGT/FiducialRegistrationWizard/pull/14
https://github.com/SlicerIGT/BreachWarning/pull/1
https://github.com/SlicerIGT/PivotCalibration/pull/13
https://github.com/SlicerIGT/TransformFusion/pull/2
https://www.assembla.com/spaces/slicerrt/tickets/563

Tests performed:

* All automatic tests passed (except those that are known to fail in the nightly builds)

* Load MRBrainTumor1 & MRBrainTumor2 sample
* Create model of MRBrainTumor2, threshold=50
* Linear registration with BRAINS (fixed: MRBrainTumor1 & moving: MRBrainTumor2)
* VERIFY: the resampled output image should look the same as the dynamically transformed moving volume, checked on several slices
* Save the transform as tfm from file, load the transform from file, apply the transform to the moving image
* VERIFY: the resampled output image should look the same as the dynamically transformed moving volume
* Apply transform to the model
* VERIFY: model is deformed in the 3D view, aligned with the volume slices
* Harden transform to the model
* VERIFY: model in the 3D view doesn’t change, model slice intersections are aligned with the volume
* Harden the transform on the volume
* VERIFY: the image doesn’t change too much

* BSpline registration with BRAINS (fixed: MRBrainTumor1 & moving: MRBrainTumor2)
* VERIFY: the resampled output image should look the same as the dynamically transformed moving volume
* Save the transform as tfm from file, load the transform from file, apply the transform to the moving image
* VERIFY: the resampled output image should look the same as the dynamically transformed moving volume
* Apply transform to the model
* VERIFY: model is deformed in the 3D view, aligned with the volume slices
* Harden transform to the model
* VERIFY: model in the 3D view doesn’t change, model slice intersections are aligned with the volume
* Insert linear transform between bspline and volume, move sliders
* VERIFY: volume deforms as it travels through the BSpline region
* Harden the transform on the volume
* VERIFY: the image doesn’t change too much

* Create a two markup list (each having 15 points), all but 3 in the same position
* Landwarp registration with Plastimatch with the markup lists, save the displacement field to file
* Load the displacement field
* VERIFY: the resampled output image should look the same as the dynamically transformed moving volume
* Apply the displacement field to the moving fiducials
* VERIFY: all the fiducials are now in the same position
* Harden the transform on the fiducials
* VERIFY: the fiducials don’t move
* Apply transform to the model
* VERIFY: model is deformed in the 3D view, aligned with the volume slices
* Harden transform to the model
* VERIFY: model in the 3D view doesn’t change, model slice intersections are aligned with the volume
* Harden the transform on the volume
* VERIFY: the image doesn’t change too much

* Load MRI head, create new linear transform, apply to the volume, move the sliders
* VERIFY: the volume moves in the slice viewer, the numbers change in the matrix
* Click Invert, Identity
* VERIFY: volume jumps to other side, to the center
* Connect to an OpenIGTLink server, apply a transform to a volume
* VERIFY: transform matrix values updated in transforms module, volume moves

Revision 22941  Directory Listing
Modified Tue Mar 11 14:33:46 2014 UTC (3 years, 6 months ago) by pieper
BUG: helper method does not have access to slicer module

Before this change, calling the method from a module gave this error:

"/Applications/Slicer-2014-02-07.app/Contents/bin/Python/slicer/util.py",
line 383, in resetSliceViews
    manager = slicer.app.layoutManager().resetSliceViews()
    NameError: global name 'slicer' is not defined

Importing slicer in each method seems wrong so,
TODO: explore importing at the top of util.py

Revision 22932  Directory Listing
Modified Mon Mar 10 15:21:53 2014 UTC (3 years, 6 months ago) by jcfr
BUG: SlicerAbstractCoreModule - Properly delete representations

Representation instances must both be deleted and removed from
the associated representation list.

Co-authored-by: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

From: Linus Sherrill <linus.sherrill@kitware.com>

Revision 22918  Directory Listing
Modified Mon Mar 3 16:21:23 2014 UTC (3 years, 6 months ago) by jcfr
BUG: Ensure node name is set when vtkSlicerCLIModuleLogic::CreateNode

Similarly to node created from the UI, node created
with the help of the logic will also have their name set with the
module title as basename.

For example, with the title of the module is:

   General Registration (BRAINS)

Note name will be:

   General Registration (BRAINS)
   General Registration (BRAINS)_1
   General Registration (BRAINS)_2
   ...

Revision 22916  Directory Listing
Modified Mon Mar 3 02:51:57 2014 UTC (3 years, 6 months ago) by jcfr
BUG: Fixed various errors in the save scene dialog for mrb format

There were 3 problems:
1. When the save scene dialog is shown first, the file format selector is empty
2. When a scene is saved as .mrb and then the save dialog is opened again the format is still .mrb, but the populated items are not disabled
3. When a scene is saved as .mrb and then the save dialog is opened again the target directory is not the same (it’s the parent directory of the directory where the scene was saved the last time)

From: Andras Lasso <lasso@queensu.ca>

Revision 22903  Directory Listing
Modified Tue Feb 25 23:10:55 2014 UTC (3 years, 6 months ago) by naucoin
BUG: get CLI module logic temp dir from application

Resetting the temporary directory at the application settings level
wasn't propagated to the CLI module logic. This change has the CLI
module logic getting the temporary directory from the application
as necessary.

Issue #3587


Revision 22896  Directory Listing
Modified Mon Feb 24 22:28:42 2014 UTC (3 years, 7 months ago) by jcfr
ENH: Improve readability using vtkNew where possible

In addition to be shorter, it simply conveys the idea of locally
instantiating an object.

Indeed, vtkNew allow to instantiate an object on the heap and deleting it
when it goes out of scope if its reference count has not been incremented by
either assigning the object to a smart pointer or calling Register.

This commit continues the work initiated in commit r22539

Revision 22895  Directory Listing
Modified Fri Feb 21 17:48:39 2014 UTC (3 years, 7 months ago) by jcfr
ENH: Disable slice view reset (volume propagation) if CLI Autorun is enabled.

Disable slice view reset (volume propagation) is important, because when
we change a CLI parameter we want to keep all the carefully chosen slice
view settings (background/foreground volume selection, slice selection,
transparency, zoom, etc.). Before this change all the slice view settings
had to be set again after each parameter change, which basically rendered
the Autorun feature useless for modules with volume output.

From: Andras Lasso <lasso@queensu.ca>

Revision 22864  Directory Listing
Modified Thu Feb 6 13:44:34 2014 UTC (3 years, 7 months ago) by jcfr
ENH: Add convenience function 'slicer.util.getFirstNodeByClassAndName'

This is required because the function vtkMRMLScene::GetFirstNode
is not wrapped. Indeed, his third parameter is a pointer to
an integer.

Revision 22860  Directory Listing
Modified Wed Feb 5 20:59:56 2014 UTC (3 years, 7 months ago) by jcfr
ENH: Set default value for slicer.util.loadLabelVolume 'properties' parameter

Revision 22855  Directory Listing
Modified Mon Jan 27 23:15:43 2014 UTC (3 years, 7 months ago) by jcfr
ENH: slicer.util - Add VTKObservationMixin python convenience class

This class provides a convenience interface to keep track of VTK
observations.

Assuming you have a class Foo already deriving from class Bar, you could
do:

class Foo(Bar, VTKObservationMixin):
  def __init__(self):
    super(Foo, self).__init__()

Revision 22854  Directory Listing
Modified Mon Jan 27 23:15:40 2014 UTC (3 years, 7 months ago) by jcfr
ENH: slicer.util - Add convenience methods resetThreeDViews/resetSliceViews

Revision 22853  Directory Listing
Modified Mon Jan 27 21:33:51 2014 UTC (3 years, 7 months ago) by jcfr
BUG: Fix convenience method slicer.util.modulePath introduced in r22851

Since "eval" is executed in the context where it is called, the 'slicer'
module should be imported.

Revision 22851  Directory Listing
Modified Mon Jan 27 14:29:54 2014 UTC (3 years, 7 months ago) by jcfr
ENH: slicer.util - Add convenience method "modulePath(moduleName)"

Revision 22850  Directory Listing
Modified Fri Jan 24 09:03:31 2014 UTC (3 years, 8 months ago) by jcfr
BUG: Fix "Reload and Test" function

While commit r22839 re-factored the code associated with "Reload" function,
it also made the "Reload and Test" function fails.

This commit fixes the issue by setting the "<moduleName>" key into
the global dictionary of the reloaded module so that it can be
referenced in the "onReloadAndTest()" function.

Note that the overall approach to reload modules could be revisited to
leverage either the "rollback importer" method or a more sophisticated one
like the "python-reloader" [2][3]

Thanks to "Csaba Pinter <csaba.pinter@queensu.ca>" for reporting the issue.

[1] http://pyunit.sourceforge.net/notes/reloading.html
[2] http://www.indelible.org/ink/python-reloading/
[3] https://github.com/jparise/python-reloader

Revision 22849  Directory Listing
Modified Fri Jan 24 09:03:06 2014 UTC (3 years, 8 months ago) by jcfr
BUG: slicer.util.reloadScriptedModule - Ensure cleanup function can be called

Revision 22848  Directory Listing
Modified Fri Jan 24 09:03:01 2014 UTC (3 years, 8 months ago) by jcfr
STYLE: slicer.util.reloadScriptedModule - Reorganized code comments

Minimize confusion by associating a single comment with each section
of code.

Revision 22840  Directory Listing
Modified Sun Jan 19 15:19:43 2014 UTC (3 years, 8 months ago) by jcfr
STYLE: In reloadScriptedModule - Use 'with' statement to open file

See http://freepythontips.wordpress.com/2014/01/15/the-open-function-explained/

Revision 22839  Directory Listing
Modified Sun Jan 19 07:59:22 2014 UTC (3 years, 8 months ago) by jcfr
ENH: Factor out scripted module reload function into 'slicer.util'

At least two versions of the code were used to reload a scripted module
were existing. This commit add the most recent version into
the function 'slicer.util.reloadScriptedModule' and update the
Slicer modules to use it.

Note that since not all module implements the 'cleanup' function,
an additional test has been added to check if the method is available.

Revision 22820  Directory Listing
Modified Tue Jan 14 18:58:25 2014 UTC (3 years, 8 months ago) by jcfr
COMP: C++11 require space between string constants

C++11 now allows for custom type specifiers so needs
a space when two string constants are to be concatenated.

Co-authored-by: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

From: Hans Johnson <hans-johnson@uiowa.edu>

Revision 22816  Directory Listing
Modified Sun Jan 12 20:24:40 2014 UTC (3 years, 8 months ago) by pieper
COMP: expose the displable manager and other MRML libs in python

The MRMLDisplayableManager code is needed to access the picker
from a python module.  This feature was added to support
DTI/Tractography processing tools being written by Lauren
O'Donnel.

From: Steve Pieper <pieper@isomics.com>

Revision 22813  Directory Listing
Modified Fri Jan 10 20:24:10 2014 UTC (3 years, 8 months ago) by jcfr
BUG: Protect FilterWatcher from Progress before Start events

If the ShowProgress method is executed as an observer before
StartFilter method the ITK time probe will be stopped before the it's
started. This causes an exception. This case is just caught and ignored.

From: Bradley Lowekamp <blowekamp@mail.nih.gov>

Revision 22799  Directory Listing
Modified Mon Jan 6 17:50:04 2014 UTC (3 years, 8 months ago) by jcfr
COMP: Fix error when building against Qt not having SSL support.

Commit r22782 was done under the assumption that Qt would be built with SSL
support. This commit ensures Qt with/without SSL support is supported.

Note that the build system could be improved to detect with Qt has
OpenSSL support, if this is the case, the OpenSSL project could be
automatically enabled unless explicitly disabled.

Revision 22796  Directory Listing
Modified Mon Jan 6 02:16:04 2014 UTC (3 years, 8 months ago) by jcfr
ENH: Kill CLI executable process on Slicer exit.

The use of a MutexLock is required because the process have been
initiated from a thread and they are killed by calling "itksysProcess_Kill()"
from the main thread.

In "ApplyTask()", the MutexLock is Locked/Unlocked at the position:

1) After calling "itksysProcess_Kill()" in "KillProcesses()", the call to
"itksysProcess_WaitForExit()" in "ApplyTask()" leads to a call
"kwsysProcessCleanup". Since calling "kwsysProcessCleanup" frees the memory
(i.e free ForkPIDs, RealWorkingDirectory and also cleanup descriptor)
 and that "kwsysProcess_Kill" expects the ForkPIDs array to be available,
it is required to use a mutex to make sure the call to "kwsysProcess_Kill"
completes before "itksysProcess_WaitForExit" is executed.

2) When calling "itksysProcess_Delete()" and updating the vector of
"Processes" that is accessed from both the main thread and the ApplyTask
thread.

Fixes #3395

Revision 22795  Directory Listing
Modified Mon Jan 6 02:15:58 2014 UTC (3 years, 8 months ago) by jcfr
STYLE: Simplify code using "vtkNew" to create "vtkSlicerTask" in CLI logic

Revision 22791  Directory Listing
Modified Fri Dec 20 03:21:24 2013 UTC (3 years, 9 months ago) by jcfr
ENH: Fix module history to keep most recent selected module last

The current implementation is a dysfunctional mix between
a "module history navigator" and "fixed workflow navigator".

This commit implements "module history navigator" behavior,
which is useful for generic Slicer use.

A "fixed workflow navigator" is a very special case, it is only
applicable when all the modules are part of the workflow,
there are no loops, skipping of steps, auxiliary modules, etc.

Considering the following convention, the update is illustrated
below.

Legend:

  -> X : Go to module X
  P    : List of module in the "previous stack"
  N    : List of module in the "next stack"

Current behaviour:

   A     P: -    |  N: -
-> B     P: A    |  N: -
-> C     P: BA   |  N: -
-> D     P: CBA  |  N: -
-> A     P: -    |  N: BCD
-> E     P: A    |  N: -

After integrating this commit, the behaviour is then:

   A     P: -    |  N: -
-> B     P: A    |  N: -
-> C     P: BA   |  N: -
-> D     P: CBA  |  N: -
-> A     P: DCB  |  N: -
-> E     P: ADCB |  N: -

where

A: Welcome module
B: Annotations
C: Data
D: DataStore
E: SampleData

Fixes #3533

From: Andras Lasso <lasso@queensu.ca>

Revision 22783  Directory Listing
Modified Tue Dec 17 17:09:54 2013 UTC (3 years, 9 months ago) by jcfr
COMP: Fix build issue #0003522 due to nice() and getpid() calls.

From: Junichi Tokuda <tokuda@bwh.harvard.edu>

Revision 22782  Directory Listing
Modified Tue Dec 17 17:09:05 2013 UTC (3 years, 9 months ago) by jcfr
BUG: Fix "No handleSslErrors" slot run time error

Since by default moc (MetaObject compiler) doesn't understand ifdef, let
simply expect that SSL headers are available and unconditionally include
the "handleSslErrors". For this to work, we would have to associated a
compile definition with moc.

Since the QSslError header was already unconditionally included, defining
the slot is not a problem.

Error was:
 Object::connect: No such slot qSlicerWebWidget::handleSslErrors(QNetworkReply*, const QList<QSslError> & ) in /home/jchris/Projects/Slicer/Base/QTGUI/qSlicerWebWidget.cxx:99
 Object::connect:  (receiver name: 'qSlicerWebWidget')

From: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

Revision 22777  Directory Listing
Modified Tue Dec 17 07:30:49 2013 UTC (3 years, 9 months ago) by jcfr
STYLE: Add warning in pimpl headers explaining it is not part of Slicer API

From: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

Revision 22765  Directory Listing
Modified Thu Dec 5 14:45:26 2013 UTC (3 years, 9 months ago) by jcfr
BUG: Fix EMSegment test by completely removing python wrapping of RemoteIO

This will fix EMSegment tests that broke following commit r22745.

Revision 22762  Directory Listing
Modified Wed Dec 4 20:29:48 2013 UTC (3 years, 9 months ago) by jcfr
COMP: For consistency, rename qSlicer.*IO classes into qSlicer.*Reader

Since the classes derive from qSlicerFileReader, change their suffixes
into "Reader" to prevent confusion.

Revision 22759  Directory Listing
Modified Tue Dec 3 23:03:32 2013 UTC (3 years, 9 months ago) by jcfr
COMP: Remove unnecessary includes in vtkMRMLAbstractLogic header

This has the side effect of having a faster compilation

External module OpenIGTLinkIF and MultiVolumeExplorer have already been
updated according to change in vtkMRMLAbstractLogic header.
See #3493 / r22712  and  #3494 / r22693

On the other hand, no test build have been done for the extension. Issue
will be resolved on case by case following the dashboard results.

Co-authored-by: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

From: Julien <julien.finet@kitware.com>

Revision 22753  Directory Listing
Modified Mon Dec 2 21:52:56 2013 UTC (3 years, 9 months ago) by jcfr
BUG: Made file extension comparisons case-insensitive. Fixes #3511

Co-authored-by: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

From: Andras Lasso <lasso@queensu.ca>

Revision 22711  Directory Listing
Modified Mon Nov 18 16:41:39 2013 UTC (3 years, 10 months ago) by jcfr
COMP: Explicitly set CTKDICOMCore as dependency of qSlicerBaseQTCore

Since qSlicerCoreApplication.h include ctkDICOMDatabase.h, this commit
add an explicit dependency between the two libraries.

Revision 22707  Directory Listing
Modified Fri Nov 15 03:38:47 2013 UTC (3 years, 10 months ago) by finetjul
ENH: Dynamically populate top-level module categories

Closes #3399

Revision 22688  Directory Listing
Modified Thu Nov 7 15:33:06 2013 UTC (3 years, 10 months ago) by jcfr
BUG: In Slicer session, keep track of Scene file format used to save

Within a given a Slicer session, the selected Scene file format will
be remembered if the scene could be successfully saved/exported.
Note that the corresponding value won't be saved into the settings.

See #2948

Revision 22687  Directory Listing
Modified Thu Nov 7 15:33:04 2013 UTC (3 years, 10 months ago) by jcfr
BUG: Properly support extension

Revert commit r22148 that was setting the path to saved MRB as MRMLScene URL.
The MRML scene URL knows remains associated with the mrml file after either
a read or save to mrml, or even export (MRB, Kiwi.zip, ...) operation.

To be able to properly switch between different available file formats
while supporting filename containing dots. The extension of a filename
needs to be removed based on a list of known extensions. For that purpose,
the following two functions have been introduced:
  - extractKnownExtension
  - stripKnownExtension

These functions rely on the existing IOManager function "fileWriterExtensions"
able to return a list of name filters associated with either a storage node
or a mrml scene.

For any fileName item, in order to get the associated storage node or mrml scene,
a new role named "UIDRole" has been introduced. For a given fileName item,
if a nodeID is set with the "UIDRole", it is understood that it will
be the nodeID of the corresponding storage node. If it is not set, it means
the fileName item is associated the scene.

See #2948

Revision 22686  Directory Listing
Modified Thu Nov 7 15:33:02 2013 UTC (3 years, 10 months ago) by jcfr
STYLE: Avoid confusion creating enum for custom SaveDataDialog role.

Revision 22676  Directory Listing
Modified Sun Nov 3 23:07:48 2013 UTC (3 years, 10 months ago) by jcfr
STYLE: Avoid confusion renaming SceneView API: "Nodes" into "StoredScene"

The following renaming have been done:
 - ivar Nodes -> StoredScene
 - method "UpdateSnapshotScene" -> "UpdateStoredScene"
 - method "GetNodes" -> "GetStoredScene"

Also remove the unused parameter from "UpdateStoredScene"

Revision 22674  Directory Listing
Modified Sun Nov 3 23:07:39 2013 UTC (3 years, 10 months ago) by jcfr
COMP: Remove redundant Scene methods: GetClassNameList, GetNodeClasses

The method "GetNodeClassesList" fulfills the same goal.

Revision 22658  Directory Listing
Modified Wed Oct 30 18:52:27 2013 UTC (3 years, 10 months ago) by jcfr
BUG: Ensure python script argument are not loaded as image. Fixes #3463

Co-authored-by: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

From: Felix Veysseyre <felix.veysseyre@kitware.com>

Revision 22618  Directory Listing
Modified Fri Oct 18 20:44:29 2013 UTC (3 years, 11 months ago) by lassoan
ENH: Changed type of mrb file loading log messages from error to debug

The messages were logged as errors, while they are actually debug messages.

Revision 22597  Directory Listing
Modified Fri Oct 4 03:10:03 2013 UTC (3 years, 11 months ago) by jcfr
BUG: Attempt to fix random failure of qSlicerSslTest on windows

Execute the event loop just after queuing the request with the
networkAccessManager.

Revision 22570  Directory Listing
Modified Thu Oct 3 02:34:11 2013 UTC (3 years, 11 months ago) by jcfr
BUG: Prevent leaks when factory methods are used from python

There is currently no automatic/clean mechanism to release the object
created by factory methods.

The only "hack" that exists for now is to decrease the reference
count manually in your code:

For more details, see [1], [2], [3] and [4]

[1] http://wiki.slicer.org/slicerWiki/index.php/Documentation/Nightly/Developers/Tutorials/MemoryManagement
[2] http://massmail.spl.harvard.edu/public-archives/slicer-devel/2011/007513.html
[3] http://www.vtk.org/Bug/view.php?id=12139
[4] http://www.vtk.org/pipermail/vtk-developers/2011-April/009757.html

Revision 22564  Directory Listing
Modified Wed Oct 2 04:26:05 2013 UTC (3 years, 11 months ago) by jcfr
BUG: Fix qSlicerExtensionsManagerModelTest.testExtractExtensionArchive

By using QFile static function each time permission are set/get, we
ensure that the permissions of the file are fully re-stated [1]. Indeed,
internally it create a QFile object for each call.

Doing so fix the test ensuring the call to:

  QFile(this->Tmp.absolutePath()).permissions() & QFile::WriteUser)

returns the expected value just after permission has been set.

This is a know Qt issue. See https://bugreports.qt-project.org/browse/QTBUG-7211

[1] http://en.wikipedia.org/wiki/Stat_%28system_call%29

Revision 22563  Directory Listing
Modified Tue Oct 1 23:16:39 2013 UTC (3 years, 11 months ago) by jcfr
BUG: Fix qSlicerUtilsTest1

Following Qt 4.8.1, setting permission on a folder with a parent folder
not being executable leads to an error.

As it should always have:

$ mkdir bar/foo
$ chmod u-x bar
$ chmod u-x bar/foo
chmod: cannot access ‘bar/foo’: Permission denied

This commit implement the correct behavior by setting flags in the
right order depending if Executable but is passed or not.

Since it is not possible to change permission of directory without executable
bit set to off, if flag "with executable bit off" is recursively set to
path /a/b/c/d, permission should be set to d, c, b and then a.

[1] and probably 4.8.0 but this hasn't been tested.

Revision 22562  Directory Listing
Modified Tue Oct 1 23:16:37 2013 UTC (3 years, 11 months ago) by jcfr
COMP: Fix [-Wconversion-null] in qSlicerScriptedFileWriter.cxx

Revision 22539  Directory Listing
Modified Tue Oct 1 19:25:00 2013 UTC (3 years, 11 months ago) by jcfr
ENH: Improve readability using vtkNew where possible

In addition to be shorter, it simply conveys the idea of locally
instantiating an object.

Indeed, vtkNew allow to instantiate an object on the heap and deleting it
when it goes out of scope if its reference count has been incremented by
either assigning the object to a smart pointer or calling Register.

Revision 22538  Directory Listing
Modified Tue Oct 1 19:24:47 2013 UTC (3 years, 11 months ago) by jcfr
ENH: Improve readability of MRML tests using vtkNew where possible

Simplify code removing tests for null object already being done
in the helper macro "EXERCISE_BASIC_OBJECT_METHODS"

For example, the following should not be needed:

  vtkNew<vtkFoo> foo;
  if (foo.GetPointer() == 0)
  {
    std::cerr << "Failed to instantiate vtkFoo" << std::endl;
  }

Instead, the following should be used:

  EXERCISE_BASIC_OBJECT_METHODS(foo.GetPointer())

Remove use of unnecessary vtkSmartPointer to check return value. Indeed,
since the operator "==" of the vtkSmartPointer is overloaded to compare with
the pointed object, there is no need to used a smart pointer. [1]

// ---------
vtkSmartPointer<vtkMRMLDisplayableNode> pnode = node1->GetDisplayableNode();
std::cout << "GetDisplayableNode returned "
          << (pnode == NULL ? "null" : "not null")
          << std::endl;
// ---------

has been changed into

// ---------
vtkMRMLDisplayableNode* pnode = node1->GetDisplayableNode();
std::cout << "GetDisplayableNode returned "
          << (pnode == NULL ? "null" : "not null")
          << std::endl;
// ---------

[1] https://github.com/Kitware/VTK/blob/0e0674a3695fdeaf01ce87dfc04e32111b7402e0/Common/vtkSmartPointerBase.h#L104

Revision 22487  Directory Listing
Modified Wed Sep 25 22:19:05 2013 UTC (4 years ago) by jcfr
BUG: Explicitly tell the user if extensions can't be installed

In case either the Slicer settings file or, the extensions install
directory are not readable/writable, a nicely formatted message will
be displayed to the user instead of the app-store page,

Note that the associated messages are also logged.

Fixes #3179

Revision 22482  Directory Listing
Modified Tue Sep 24 22:33:45 2013 UTC (4 years ago) by naucoin
BUG: update the CLIs to create new Markup fiduicals from point node selector

The command line module GUI helper hadn't been updated to create Markups
Fiducial nodes by default when creating new nodes was enabled. It was still
set up to create Slicer3 vtkMRMLFiducialListNodes. 
Now by default a vtkMRMLMarkupsFiducialNode will be created when Create New is
selected.
Update the Markups module logic to detect node added events and add a display
node if not in batch processing, import or restore modes.
Updated the simple region growing segmentation help documentation to refer to the
Markups module.

Issue #3417


Revision 22477  Directory Listing
Modified Mon Sep 23 14:43:07 2013 UTC (4 years ago) by jcfr
COMP: Remove unused includes in qSlicerWebWidget

From: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

Revision 22476  Directory Listing
Modified Mon Sep 23 14:43:04 2013 UTC (4 years ago) by jcfr
COMP: Fix conversion-null warnings in qSlicerExtensionsManagerModel

From: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

Revision 22474  Directory Listing
Modified Mon Sep 23 10:28:57 2013 UTC (4 years ago) by jcfr
BUG: Update CTK - Filter out readonly directory in Save data dialog.

$ git shortlog b759ef7..0e21d85
Chrystel Juan (1):
      Extend ctkDirectoryButton to optionally filter out readOnly folders.

Jean-Christophe Fillion-Robin (1):
      Merge branch '365-filter-out-read-only-directory'

Fixes #3366

Co-authored-by: Jean-Christophe Fillion-Robin <JChris.FillionR@kitware.com>

From: Chrystel Juan <chrystel.juan@kitware.com>

Revision 22473  Directory Listing
Modified Mon Sep 23 08:26:29 2013 UTC (4 years ago) by jcfr
COMP: Fix warning: variable ‘checkedAction’ set but not used

Within function "updateWidgetToAnnotation" of MouseModeToolBar,
checkedAction local variable has been introduced by commit r19943. It has
then been revised in commit r19989. Finally its usage has been removed
by commit r21555.

Note that function "updateWidgetToAnnotation" has been renamed into
"updateWidgetToPlace" in commit r22310.

This commit completely remove references to this variable since it is
set but not used.

Revision 22472  Directory Listing
Modified Mon Sep 23 08:26:27 2013 UTC (4 years ago) by jcfr
BUG: Fix crash after Slicer is restarted and text printed on stdout/stderr

Revert commit r22400 "BUG: Disable AutoRestart to workaround issue #2535"

After restarting Slicer, message were still printed on stdout/stderr.
The associated descriptors didn't have any "consumers". It was
then causing Slicer to be unresponsive.

By introducing a new command line option "--disable-terminal-outputs",
it allows to disable the display of message on the terminal. This new
option is pre-pended to the list of arguments on Slicer restart. That
was the restarted Slicer instance is not associated with any
stderr/stdout file descriptor.

Note that on windows, in the case Slicer is built without console support,
the new command line option won't be available.

Fixes #2535

Revision 22471  Directory Listing
Modified Mon Sep 23 08:26:23 2013 UTC (4 years ago) by jcfr
BUG: Remove program name from arguments when restarting

This commit prevent warning on restart mentionning that Slicer attempted
to load itself as an image and failed. Parameters of "startDetached"
function should be the program arguments without the program name.

See #2535

Revision 22465  Directory Listing
Modified Sun Sep 22 02:44:59 2013 UTC (4 years ago) by jcfr
ENH: Add option to disable loading of either any module or only the builtin

Before this commit, starting slicer with option
like --disable-{cli|loadable|scripted-loadable}-modules was preventing
the registration of the associated factories. It means that even if
an additional path was provided, it wasn't possible for the user to
disable the loading of the builtin module and enabling only the loading
of modules associated with the provided path.

This commit differentiate the concept of "any modules" vs "built-in" modules
by adding new command line options:

 disable-builtin-cli-modules

 disable-builtin-loadable-modules

 disable-builtin-scripted-loadable-modules

 disable-builtin-modules  (disable loading of all builtin modules)

 disable-modules (disable loading of any modules)

The modules settings panel has also been updated, it is now possible
to selectively disable the loading of either any modules or only the
built-in ones.

Revision 22464  Directory Listing
Modified Sun Sep 22 02:44:52 2013 UTC (4 years ago) by jcfr
BUG: Fix crash in CLIModuleFactoryHelper when used without SlicerApp

The "isInstalled" method will alaways return false if no Slicer
application has been instantiated.

Ideally the application home should be externally set. This is
tracked by issue #3411

Revision 22463  Directory Listing
Modified Sun Sep 22 02:44:49 2013 UTC (4 years ago) by jcfr
ENH: Skip loading of loadable python module if loadable module are disabled

Before this commit even after disabling the loading of loadable module
the python module corresponding to "logic", "Widgets, "displayable
manager" and "mrml" where still imported. This commit prevent this.

Note that if a given loadable module is disabled with the application
settings the associated python modules will still be imported.

Ideally python module should be imported on a per module basis as it is
done for extension. This will be possible only after python module specific
to a loadable module are located in dedicated directory. This is
somewhat related to issue #1365

Revision 22429  Directory Listing
Modified Thu Sep 12 21:57:36 2013 UTC (4 years ago) by jcfr
BUG: Set module name / objectName in GenericTests

In addition to be consistent with what is done in the "instantiateModule"
method of the "qSlicerAbstractModuleFactoryManager".

It also ensure that the "ModuleShareDirectory" set in the "logic" method
of the "qSlicerAbstractCoreModule" class is done using the expected
value for the module name.

This will allow generic tests instantiating module using
"GetModuleShareDirectory" method to get the correct value (i.e Reporting
module)

Revision 22400  Directory Listing
Modified Tue Sep 3 23:22:49 2013 UTC (4 years ago) by jcfr
BUG: Disable AutoRestart to workaround issue #2535

Instead of asking the user if he would like to restart, he is asked
if he would like to exit Slicer and manually restart.

The restart confirm dialog is associated with the
settings key "MainWindow/DontConfirmExit"

See #2535

Revision 22391  Directory Listing
Modified Tue Sep 3 18:29:38 2013 UTC (4 years ago) by jcfr
COMP: Fix unused variable warnings in vtkSlicerCLIModuleLogic

Revision 22379  Directory Listing
Modified Sat Aug 31 12:39:35 2013 UTC (4 years ago) by alexy
BUG: 3290. Fixed handling of ROIs and Annotation nodes in CLI modules. Added CLI_ROI_Test module.

Revision 22378  Directory Listing
Modified Sat Aug 31 05:46:46 2013 UTC (4 years ago) by jcfr
ENH: Increase maximum size for Recently loaded menu

See #1669

Revision 22372  Directory Listing
Modified Fri Aug 30 22:33:44 2013 UTC (4 years ago) by jcfr
STYLE: Refactor function onShowToolButtonTextToggled re-using existing code

See #2164

Revision 22369  Directory Listing
Modified Fri Aug 30 18:41:01 2013 UTC (4 years ago) by naucoin
BUG: update WriteCLI to fill a vector of strings, honor mutiple = false

Because Markups define multiple markups (with potentially multiple points) in one node,
it was writting multiple instances of a string + coordinates to the string stream passed
in to WriteCLI. This causes a problem for the parsing of the arguments in CLIs such as
FiducialRegistration which needed a separate string for each point.
With this change, the markup points are writen into a vector of strings, one string
for each point in each Markup.
Added the multipleFlag to be passed to WriteCLI, and if it's false, only write the
first selected markup to the output vector. If that markup has multiple points, it will
write all of those points.
Updated the Annotation control point to use the new WriteCLI signature, but because
of the way the points are written, it will only write the first point in a multi point
annotation (such as a ruler) if multiple is false, so it ignores it and the
CLI module logic takes care of ensuring that only the first child in an
annotation hierachy is written out. Write out a warning message if this is the case.
Added a test for FiducialRegistration, updated the Markups node test 1 to test the single point flag.
Removed trailing white spaces.

Issue #1910 #3345 #3340


Revision 22362  Directory Listing
Modified Fri Aug 30 00:01:33 2013 UTC (4 years ago) by jcfr
ENH: Ensure objectName is set for all type of modules and moduleWidgets

This commit revert r22359

ObjectName associated with ...

  ... module is now "<ModuleName>Module"

  ... module widget is now "<ModuleName>ModuleWidget"

The objectName will always be set by set externally by ...

  ... qSlicerAbstractModuleFactoryManager for the module

  ... qSlicerAbstractModuleWidget::setup() method for the module widget

See #2808

Co-authored-by: Chrystel Juan <chrystel.juan@kitware.com>

Revision 22359  Directory Listing
Modified Thu Aug 29 22:22:52 2013 UTC (4 years ago) by jcfr
ENH: Ensure scripted module and scripted module widget are named.

Naming object is helpful when both introspecting/debugging the application
or when recording QtTesting macros.

See #2808

Co-authored-by: Chrystel Juan <chrystel.juan@kitware.com>

Revision 22356  Directory Listing
Modified Thu Aug 29 07:24:22 2013 UTC (4 years ago) by jcfr
BUG: DirectoryListView - Allow path with same root to be added

Before this commit, if two existing paths with the same root were added, the
second one wasn't considered.

For example, after successively calling "addDirectory" with the
following paths:

 "/tmp/foo"
 "/tmp"

, the second path "/tmp" wasn't added.

This commit fixes the "hasDirectory()" method so that it uses an "Exact"
match instead of "StartWith" match.

Revision 22348  Directory Listing
Modified Wed Aug 28 19:58:38 2013 UTC (4 years ago) by jcfr
BUG: Add back/forward button to extension manager

Fixes #2191

Revision 22347  Directory Listing
Modified Wed Aug 28 19:58:36 2013 UTC (4 years ago) by jcfr
BUG: Fix opening of link in extension manager

Opening of links different from slicer.kitware.com host into regular
browser has been initially introduced by r21897. Then, when commit r22220
introduced qSlicerWebWidget, the management of external links has been
broken.

This commit fixes the issue by ensuring the qSlicerWebWidget always open
link within its associated webview. The slot "onLinkClicked" from
"qSlicerExtensionsInstallWidget" will check what is the host and open
into a regular browser if needed.

See #3045

Revision 22345  Directory Listing
Modified Wed Aug 28 03:48:39 2013 UTC (4 years ago) by jcfr
BUG: Hide initialization info when running Slicer as python interpreter.

Add method "qSlicerCoreCommandOptions::verbos" currently returning false
only  if slicer runs a python script directly passed as a command line
argument.

Later on, the system could be extended so that all initialization
information are hidden by default. They would be displayed
only if --verbose is explicitly passed.

Fixes #3285

Revision 22341  Directory Listing
Modified Tue Aug 27 19:24:18 2013 UTC (4 years ago) by jcfr
STYLE: Fix authorship of qSlicerScriptedFileWriter

Revision 22338  Directory Listing
Modified Tue Aug 27 03:29:57 2013 UTC (4 years, 1 month ago) by jcfr
ENH: Add qSlicerScriptedFileWriter interface

User can now register python based file writer.

For example:

# File MyCustomSceneExporter.py

import json
import os
import zipfile
import contextlib
import datetime
import vtk, slicer

class MyCustomSceneExporter:
  def __init__(self, parent):
    parent.title = "[...]"
    parent.categories = ["..."]
    parent.dependencies = []
    parent.contributors = ["..."]
    parent.helpText = """[...]"""
    parent.acknowledgementText = """[...]"""
    self.parent = parent

class MyCustomSceneExporterFileWriter:
    def __init__(self, parent):
        self.parent = parent

    def description(self):
        return 'Custom Scene File'

    def fileType(self):
        return 'SceneFile'

    def canWriteObject(self, obj):
        return isinstance(obj, slicer.vtkMRMLScene)

    def extensions(self, obj):
        return ['CustomScene File (*.customscene.zip)']

    def write(self, properties):
        self.exportModels(properties['fileName'])
        return True

    [...]

Revision 22337  Directory Listing
Modified Tue Aug 27 03:29:53 2013 UTC (4 years, 1 month ago) by jcfr
BUG: Consider specific file writer before generic one.

Ideally the file reader/writer should be reworked to have a more
consistent API. More specifically after the user select a file type
in the "save dialog", the corresponding "file writer id" should be
passed down the qSlicerCoreIOManager::saveScene/saveNodes methods.

This would prevent confusion for the user. Indeed, if a writer fails a
clear error message would be displated and the system wouldn't try an other
possible writer.

See issue #3322

Revision 22321  Directory Listing
Modified Fri Aug 23 01:31:19 2013 UTC (4 years, 1 month ago) by naucoin
ENH: Replace Annotations with Markups in default favorite modules list.

See issue #2606

Revision 22320  Directory Listing
Modified Fri Aug 23 01:31:16 2013 UTC (4 years, 1 month ago) by naucoin
ENH: Deprecating annotation fiducials

Edit properties in the Data module will go to the Markups module for
both Markups and Annotations fiducials, so that annotation fids
can be converted.

Unregister the Annotations fiducials IO, Markups can read .acsv files.
Add a label in the Annotations GUI that fiducials can be found in the Markups module.

See issue #2606

Revision 22319  Directory Listing
Modified Fri Aug 23 01:25:04 2013 UTC (4 years, 1 month ago) by naucoin
ENH: Support passing Markup fiducials to CLIs

Use the coordinate system flag to support RAS or LPS coordinates
for the points.

See issue #2606

Revision 22318  Directory Listing
Modified Fri Aug 23 01:25:00 2013 UTC (4 years, 1 month ago) by naucoin
ENH: Add annotation and markup file loading

Add utility methods to allow loading Markup fiducials
from the python console, as well as a backward
compatible Annotation reader

See issue #2606

Revision 22316  Directory Listing
Modified Fri Aug 23 00:32:58 2013 UTC (4 years, 1 month ago) by naucoin
ENH: Expose module displayable managers to Python

Before this change, you could get at module displayable managers but not
call any of their specific methods in python. This change follows the
pattern of the module logic init file.

To get at the module displayable managers for the first 3D window:
lm = slicer.app.layoutManager()
td = lm.threeDWidget(0)
dms = td.getDisplayableManagers()

The markups fiducial displayable manager was at index 7 in my test:
mfdm = dms.GetItemAsObject(7)
h = mfdm.GetHelper()
from there you can debug the seed widgets

Annotation, Volume Rendering and Tractography displayable managers
are now also accessible from python.

Revision 22310  Directory Listing
Modified Fri Aug 23 00:27:48 2013 UTC (4 years, 1 month ago) by naucoin
ENH: Re-factor selection node

Use the class name so modules can register a node to place
via mouse more generally.

Use the new functionality in the mouse mode tool bar,
annotations, testing.

Revision 22303  Directory Listing
Modified Tue Aug 20 18:53:42 2013 UTC (4 years, 1 month ago) by jcfr
BUG: Revert r22301 - Change ctkDirectoryButton into ctkPathLineEdit

This commit has been integrated by error

Revision 22301  Directory Listing
Modified Tue Aug 20 18:50:03 2013 UTC (4 years, 1 month ago) by jcfr
BUG: Change ctkDirectoryButton into ctkPathLineEdit

*DO NOT INTEGRATE*

Know issue: When updating the Cache directory in setting panel, each
key stroke leads to the creation of path.

Fixes #1672

From: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

Revision 22296  Directory Listing
Modified Mon Aug 19 18:01:05 2013 UTC (4 years, 1 month ago) by jcfr
ENH: Script to version the na-mic data tree on Midas

This script can be used to duplicate the Nightly NA-MIC data tree on
Midas to a new folder tagged by the release version. The script used the
pydas api as well as some of Midas web-api for the methods not yet
ported to pydas. The script does not take any input arguments. All the
arguments should be provided as options using the option flags. For a
full list of options: "python release.py --help".
For now, it is assumed this script does not depend on slicer python. It
can be used from the regular python interpreter.

Added a function called versionData that takes the same arguments as
input as the command line module. This facilitates the use of this
script as a python importable module.
Improved documentation. Added docstring style documentation for
functions.

Added a new directory called release that will contain all scripts
that can be used when tagging Slicer for a new release. For example,
versioning Midas NA-MIC data tree, documentation generation, etc.

Added dry run functionality that prints the structure of the source
folder that is going to be duplicated. Made changes to test script as
well.

Added a an "_" before all functions that are not required by the user to
hide them.
Added an __all__ in the __init__.py for the package to know which module
it can import.
So, when you do a
           from release import *
only, midasdata should be imported and not the unittest.

Fixes #2561
Fixes #2704

Co-authored-by: Jean-Christophe Fillion-Robin <JChris.FillionR@kitware.com>

From: Sankhesh Jhaveri <sankhesh.jhaveri@kitware.com>

Revision 22291  Directory Listing
Modified Sun Aug 18 21:14:58 2013 UTC (4 years, 1 month ago) by jcfr
BUG: Update default module icon color

Commit r22288 associated a default icon with all modules. Then, as
suggested by Wendy Plesniak this commit changes the icon color to
be "SlicerBlue".

See #3293

Co-authored-by: Wendy Plesniak <wjp@bwh.harvard.edu>

Revision 22288  Directory Listing
Modified Thu Aug 15 22:38:49 2013 UTC (4 years, 1 month ago) by jcfr
BUG: Associate default icon with all modules.

Doing so will allow module to be added to the module toolbar by updating
the list of favorite modules in the application settings.

Fixes #3293

Co-authored-by: Julien Finet <julien.finet@kitware.com>

Revision 22283  Directory Listing
Modified Mon Aug 12 13:21:41 2013 UTC (4 years, 1 month ago) by finetjul
BUG: Fix crash when using slicer dark style

When painting a tab, Cleanlooks style expects to have a gradient in the
Window palette brush when it finds a gradient in the Button palette
brush.
Issue #3251

Revision 22273  Directory Listing
Modified Fri Aug 9 14:12:42 2013 UTC (4 years, 1 month ago) by pieper
BUG: #1832 #3140 #3209 avoid crashes by catching exceptions

Some libraries and systems throw exceptions, but Qt's default
event processing does not catch them[1].  For example, slicer
could crash when ctkDICOMItem is pointed to a file that does
not exist.  Wrapping event processing in try/catch should handle
other conditions, like out of memory exceptions thrown from
inside render operations (e.g. due to overly complex glyph
rendering).

[1] http://qt-project.org/doc/qt-4.8/exceptionsafety.html

http://stackoverflow.com/questions/10665655/how-to-log-uncatched-exceptions-of-a-qapplication

Revision 22272  Directory Listing
Modified Fri Aug 9 14:12:40 2013 UTC (4 years, 1 month ago) by pieper
STYLE: remove some trailing spaces

Revision 22270  Directory Listing
Modified Thu Aug 8 17:08:07 2013 UTC (4 years, 1 month ago) by finetjul
BUG: Fix inactive button color for dark style

Issue #3251

Revision 22269  Directory Listing
Modified Thu Aug 8 05:22:12 2013 UTC (4 years, 1 month ago) by finetjul
ENH: Improve Dark style

Issue #3251

Revision 22267  Directory Listing
Modified Wed Aug 7 19:56:35 2013 UTC (4 years, 1 month ago) by finetjul
ENH: Select DICOM reader by default on drag&drop

Issue #3081

Revision 22262  Directory Listing
Modified Tue Aug 6 17:06:32 2013 UTC (4 years, 1 month ago) by finetjul
COMP: Always build qSlicerPersistentCookieJar

It is being used by qSlicerWebWidget which is not conditionally built by
Slicer_BUILD_EXTENSIONMANAGER_SUPPORT

Revision 22260  Directory Listing
Modified Tue Aug 6 13:43:58 2013 UTC (4 years, 1 month ago) by pieper
BUG: #2326 mark a node as modified if the name has changed

When the user has changed the name of a node this is
reflected in the suggested name of the file (see issue #3125).
With this fix the node is also marked as modified so that
it will be checked for saving.

This means that changing the name of a node in the scene will
cause it to be saved to a new file on disk which is a slight change
in behavior and may cause people to use more disk space.  But in
general I think this is safer and more clear, since file names will
always match the name of the node in the scene and users will
prefer that I believe.

Revision 22259  Directory Listing
Modified Tue Aug 6 13:20:50 2013 UTC (4 years, 1 month ago) by pieper
BUG: #3125 filename not changed if it is still default from load

The file load mechanism assigns a default node name based on
the filename.  If the node no longer has that default name, update
the filename to match what the user provided.

Revision 22255  Directory Listing
Modified Fri Aug 2 18:13:42 2013 UTC (4 years, 1 month ago) by millerjv
BUG: #3204. Crosshair selection overridden by cross hair toggle.

This addresses a bug involving toggling and switching crosshairs:

1. If crosshair display is in mode "A"
2. Crosshair it toggled off in the GUI
3. Crosshair is set to mode "B" in the GUI

then the cross would display as "A" and not as "B".

The issue is in the order in which the "selection" signals are raised
relative to the "toggle" signals. When switching from off to any mode
the selection signals are raised first and then the toggled signals.

This ordering was aligned with the order in which the crosshair
node was modified relative to how the mode was cached (to set up for
toggling).

Caching the mode before setting mode addressed the issue.

Revision 22254  Directory Listing
Modified Fri Aug 2 14:44:20 2013 UTC (4 years, 1 month ago) by millerjv
BUG: "reference" attributes on transform were not editting scene

In Slicer3, then an output transform of a CLI had a "reference",
the MRML scene would be editted automatically to place the "reference"
image under the transform.

The implementation in Slicer3 performed the hierarchy editing by passing
a string of Tcl commands from the processing thread to the gui thread. This
approach was never ported to Slicer4.

This patch uses the Command/Observer to request that an event be
issued in the main thread. In this case, the event is one to edit
the transform hierarchy.  The details of how the transform hierarchy
is be editted are encoded in a callback function. Two layers of callback
functions are used.  One layer is a generic callback function which
accepts another callback in its calldata. It then delegates to that
second callback.  In this manner, the same structure can be used
for other hierarchy edits by switching the callback passed as calldata.
The second callback is a one shot callback. The first callback will
delete the second callback upon completion.

This patch should resolve bug #3091. Unfortunately, I cannot test it on
my system as BrainsFit crashes for a different reason.  But this patch
does restore the transform hierarchy behavior for the RigidRegistration
module accessible under "Legacy" modules.

Revision 22246  Directory Listing
Modified Tue Jul 30 18:08:47 2013 UTC (4 years, 1 month ago) by pieper
BUG: #3125 preserve .nii.gz extension on scene save

Use completeSuffix per suggestion from jcfr.

Note this code may still change as I work on fixes for #2326.

Revision 22239  Directory Listing
Modified Fri Jul 26 20:58:32 2013 UTC (4 years, 2 months ago) by johan.andruejol
BUG: Remove forgotten Qt style

The style Macintosh (aqua) was still available on MacOS in the settings
even though it's a default Qt style.
Adding it to the list of Qt default style removes it.

Revision 22236  Directory Listing
Modified Thu Jul 25 20:33:11 2013 UTC (4 years, 2 months ago) by johan.andruejol
ENH: Group appearance related settings together

The settings in General that are related to the slicer's look were moved
to the style setting panel. At this occasion, this panel was renamed
Appearance.
This allow a better grouping of the application customization option for
an easier user experience.

Also used the occasion to add tooltips to these options.

Revision 22235  Directory Listing
Modified Thu Jul 25 20:33:00 2013 UTC (4 years, 2 months ago) by johan.andruejol
ENH: Custom style for slicer

Allow the slicer to use custom styles. This rests on the Qt style plugin
framework. The style plugins must be compiled with the same Qt as slicer,
in the same mode (debug, release...) and in shared library mode.
To facilitate the creation of new plugins, a cmake macro was added to
slicer cmake directory.
Every slicer style must inherits from qSlicerStyle. They are not detected
by the application otherwise.

The new styles can be set like modules. A setting page is added for them
where user can specify the directory containing his plugin. The additionnal
paths and the style key are added as settings. This means that the next
time slicer's session is opened, the application will automatically load
the custom style if it still exists.
Adding or removing paths necessit the application to be restarted. This
comes from the fact that the QStyleFactory is only updated upon its
creation which only happens when starting the application.
Changing the style however doesn't need to restart the application.
At this occasion, a Slicer dark style was added to the list of available
styles.

On the implementation side, the designer plugin export definition was
shortened and includes the "DESIGNER" term so it is different than the
style export macro.

Finaly, adding a fix to the slice controller widget label style so
it can work with the new dark style.

Revision 22229  Directory Listing
Modified Mon Jul 22 20:39:04 2013 UTC (4 years, 2 months ago) by jcfr
ENH: Allow temporary directory to be accessible in MRML logics.

TemporaryPath is added to vtkMRMLApplicationLogic, so that the temporary directory can be directly accessible from MRML logics.

Also add associated tests

Fixes #2416

From: Yuzheng Zhou <yuzheng.zhou@kitware.com>

Revision 22226  Directory Listing
Modified Mon Jul 22 14:59:46 2013 UTC (4 years, 2 months ago) by jcfr
COMP: Fix build error occurring when OpenSSL support is disabled

While commit r22220 added SSL support ensuring the CMake option
"Slicer_USE_PYTHONQT_WITH_OPENSSL" was disabled by default. Not all OpenSSL
related code was properly excluded, this commit ensures Slicer can be
compiled with OpenSSL support disabled.

Discussion: http://slicer-devel.65872.n3.nabble.com/Windows-build-fails-due-to-missing-QSslSocket-class-tt4029446.html

See issue #2998 and #2355

Revision 22220  Directory Listing
Modified Sat Jul 20 02:16:35 2013 UTC (4 years, 2 months ago) by jcfr
ENH: Add SSL support

Having the application interacting with services or downloading resources
served over https protocol is now required. More particularly,
it became necessary to access resources stored on Github (extension
manager - issue #2354) or to download python packages from pip server
at run time.

The CMake option "Slicer_USE_PYTHONQT_WITH_OPENSSL" allowing to enable or
disable OpenSSL support has been introduced is set to OFF by default.

Building OpenSSL
================

On Windows, since Perl is required, OpenSSL binaries have been
generated and uploaded on kitware packages server. See [1]

The project allowing to re-generate the Windows OpenSSL archive is currently
hosted here [2].

On unix-like system, OpenSSL is built has part of the Superbuild. To ensure
is can be built in parallel, a patch is also applied [3].

Finally, since python is built with OpenSSL support, the python launcher
is now configured on all platform so that python can properly load the built
OpenSSL shared library when it is used to build project like numpy.

[1] http://packages.kitware.com/packages/application/view?applicationId=20
[2] https://gist.github.com/jcfr/6030240
[3] https://raw.github.com/Alexpux/Qt-builds/master/patches/openssl/openssl-1.0.1-parallel-build.patch

OpenSSL support in Qt, python, curl
===================================

Practically, it means that library like Qt, python, curl need to be
built with OpenSSL support.

This commit only address OpenSSL support for Python and Qt.

Curl support is not yet enabled.

For Qt OpenSSL support, Qt has to be built with the flags:
  -openssl
  -I /path/to/OpenSSL/include
  -L /path/to/OpenSSL/lib

On unix-like system, available binaries are already OpenSSL ready, Qt
has to be explicitly built only on windows. On windows, Qt will have to
be built.

Certificates
============

In case X.509v3 certificates are available on the system where Slicer is
executed, a certificate bundle "Slicer.crt" is also provided. The set of
scripts allowing to generate the bundle are provided by BLFS
(Beyond Linux From Scratch).
More details in Base/QTCore/Resources/Certs/README

Application integration
=======================

The Slicer core application will load the Slicer.crt bundle if needed.

qSlicerExtensionsInstallWidget now derives from a re-usable widget
named qSlicerWebWidget.

qSlicerSslTest has been added to check that "https" connection can
be established using Qt library.

Fixes #2998
Fixes #2355
Fixes #2354

Revision 22213  Directory Listing
Modified Thu Jul 18 22:01:19 2013 UTC (4 years, 2 months ago) by finetjul
BUG: Block/Redirect display node events in CLI node writing

Closes #2966, #2915

Revision 22208  Directory Listing
Modified Wed Jul 17 23:44:48 2013 UTC (4 years, 2 months ago) by finetjul
ENH: Cleanup shortcuts(actions) dialog

Closes #1819

Revision 22204  Directory Listing
Modified Wed Jul 17 17:47:52 2013 UTC (4 years, 2 months ago) by finetjul
ENH: Add SHIFT support to change file type to checked files.

Holding the shift key when changing the file type changes the other checked
files of same type to the new file type.
Closes #3109

Revision 22196  Directory Listing
Modified Mon Jul 15 15:41:09 2013 UTC (4 years, 2 months ago) by finetjul
BUG: Fix random crash in CLI when writing in output volume node

itkMRMLIDImageIO::Write was triggering node events (such as
vtkMRMLVolumeNode::ImageDataModifiedEvent) in a thread other than
the main thread.
The solution is to catch those events before any observer is notified,
and reschedule those events in the main thread.

Closes #2915

Revision 22195  Directory Listing
Modified Mon Jul 15 15:41:07 2013 UTC (4 years, 2 months ago) by finetjul
ENH: Make vtkMRMLApplicationLogic::InvokeEventWithDelay thread-safe

If InvokeEventWithDelay was called from a different thread,
the AutoConnection in qSlicerCoreApplication was queuing the signal
therefore the InvokeRequest was deleted before the requestInvokeEvent()
slot was called.
Issue #2915

Revision 22194  Directory Listing
Modified Mon Jul 15 15:41:05 2013 UTC (4 years, 2 months ago) by finetjul
BUG: Disable Apply button when CLI has a Completing status

If the user clicks frenetically on the Apply button, it was eventually
generating an assert in vtkSlicerCLIModuleLogic::ProcessMRMLLogicsEvents
because the button was clicked when the CLI was still "Completing".
Issue #2915

Revision 22189  Directory Listing
Modified Mon Jul 15 15:24:11 2013 UTC (4 years, 2 months ago) by finetjul
BUG: Restore the selection node units on scene close

Re-enable Units module.
Closes #3176, #3152

Revision 22151  Directory Listing
Modified Mon Jul 8 20:29:02 2013 UTC (4 years, 2 months ago) by finetjul
ENH: Give user control over the number of decimals in spinboxes

Adding decimals is now possible in spinboxes.
Note that this work is orthogonal to units but not incompatible.
Closes #2973, #2986

Revision 22139  Directory Listing
Modified Thu Jul 4 22:20:40 2013 UTC (4 years, 2 months ago) by finetjul
ENH: Disable scrolling everywhere there is an active scrollarea

Don't do it only for comboboxes.
Closes #1820, #1462

Revision 22135  Directory Listing
Modified Thu Jul 4 13:22:07 2013 UTC (4 years, 2 months ago) by finetjul
ENH: Don't scroll comboboxes that are inside a scroll area

Using the mouse in a scroll area could inadvertently change combobox
current index (on mouse over).
For conveniency, all the qMRMLNodeComboBoxes won't scroll in scrollarea by
default.
Closes #1820, #1462

Revision 22128  Directory Listing
Modified Fri Jun 28 22:49:43 2013 UTC (4 years, 2 months ago) by finetjul
COMP: Propagate CTK renaming: ctkSpinBox to ctkDoubleSpinBox

Revision 22126  Directory Listing
Modified Thu Jun 27 18:22:44 2013 UTC (4 years, 2 months ago) by finetjul
COMP: Build SlicerBaseCLI only if VTK is found.

This CMakeLists can be configured by projects others than Slicer
(e.g. TubeTK) that may not have VTK.
This time (see r22122 and r22125), the condition on SlicerBaseCLI_SRC
is correct.

Revision 22125  Directory Listing
Modified Thu Jun 27 17:14:42 2013 UTC (4 years, 2 months ago) by pieper
BUG: Revert "COMP: Build SlicerBaseCLI only if VTK is found."

This reverts commit 0692c63d8a06c912258e1f368a9a7c318cc0621a.

This revert is needed bacause CLIs in slicer builds failed to find
SlicerBaseCLI for linking (checked on Mac).

From: Steve Pieper <pieper@isomics.com>

Revision 22122  Directory Listing
Modified Thu Jun 27 14:34:13 2013 UTC (4 years, 2 months ago) by finetjul
COMP: Build SlicerBaseCLI only if VTK is found.

This CMakeLists can be configured by projects others than Slicer
(e.g. TubeTK) that may not have VTK.

Revision 22117  Directory Listing
Modified Fri Jun 21 12:17:59 2013 UTC (4 years, 3 months ago) by finetjul
ENH: Adding function to create a new WidgetRepresentation for a module

This can allow the user to "import" a module's GUI into another.
This is particularly interesting for work-flow modules.
The function getModuleGui can grab the existing GUI for the given module,
but the widget representation can only exist in one place. So when using
the GUI in another module with getModuleGui would cause one of the modules
to be empty.

From: Guillaume Sala <guillaume.sala@kitware.com>

Revision 22110  Directory Listing
Modified Wed Jun 19 20:27:33 2013 UTC (4 years, 3 months ago) by finetjul
ENH: Make a Qt Designer plugin for qSlicerCLIProgressBar

* Add qSlicerCLIProgressBar::statusVisibility
* Add qSlicerCLIProgressBar::progressVisibility

Revision 22109  Directory Listing
Modified Wed Jun 19 20:27:24 2013 UTC (4 years, 3 months ago) by finetjul
ENH: Add loadedNodes return in qSlicerIOManager::openDialog

* loadedNodes: It can be useful to know which nodes have been loaded
by the dialog.
* qSlicerStandardFileDialog supports "defaultFileName" property

Conflicts:
	Base/QTGUI/qSlicerFileDialog.cxx
	Base/QTGUI/qSlicerFileDialog.h

Revision 22097  Directory Listing
Modified Tue Jun 11 19:38:06 2013 UTC (4 years, 3 months ago) by jcfr
BUG: Fixes calls to slicer.util.moduleNames()

In commit r19334 [1], the moduleNames() function has been renamed
to "loadedModuleNames" but the corresponding function in slicer.util
hasn't been renamed.

This commit fixes slicer.util.moduleNames() so that it calls
"loadedModuleNames" function.

Fixes #2591

[1]http://viewvc.slicer.org/viewvc.cgi/Slicer4?view=revision&revision=19334

From: Christopher Mullins <christopher.mullins@kitware.com>

Revision 22095  Directory Listing
Modified Mon Jun 10 20:51:52 2013 UTC (4 years, 3 months ago) by jcfr
BUG: Disable units module

Considering Na-mic week is happening next week, we decided to force
the "units" module to be ignored. Waiting the underlying issues are
resolved, this commit will prevent issue #3152 from occurring.

See http://www.na-mic.org/Bug/view.php?id=3152

Revision 22082  Directory Listing
Modified Wed Jun 5 21:57:39 2013 UTC (4 years, 3 months ago) by pieper
BUG: #3029 use 'setlocale' to force C over native language

It turns out that it is not enough to set Qt's locale and we must
also set the c standard library locale in order to avoid data
corruption when the decimalpoint is not period.

Many thanks to Marine Clogenson of EPFL for noticing and helping
figure out how to reproduce this issue!

Revision 22077  Directory Listing
Modified Tue Jun 4 21:23:22 2013 UTC (4 years, 3 months ago) by pieper
ENH: add shortcuts for module navigation

Per discussion on developer hangout, added a shortcut:

Cmd/Control+F : search for module

Then I decided to add these as well:

Cmd/Control+Left : previous module
Cmd/Control+Right : next module

Revision 22074  Directory Listing
Modified Tue Jun 4 15:17:13 2013 UTC (4 years, 3 months ago) by pieper
BUG: #3029 force slicer to be in the C locale to avoid data truncation


Set the locale to be "C" to avoid issues related to reading and writing
of floating point numbers.  For example, when the decimal point is set to be
a comma instead of a period, there can be truncation of data.
See these previous commits and the
+  // http://viewvc.slicer.org/viewvc.cgi/Slicer4?view=revision&revision=21856
+  // http://viewvc.slicer.org/viewvc.cgi/Slicer4?view=revision&revision=21865
+  // http://slicer-devel.65872.n3.nabble.com/Re-Rounding-to-integer-tt4027985.html
+  // http://slicer-devel.65872.n3.nabble.com/Re-slicer-users-Slicer4-can-t-really-use-it-yet-td4028040.html
+  // http://slicer-users.65878.n3.nabble.com/Slicer4-DICOM-many-problems-td4025919.html
+  // and issue #3029

Revision 22071  Directory Listing
Modified Mon Jun 3 19:17:58 2013 UTC (4 years, 3 months ago) by pieper
ENH: provide direct access to tensor arrays from python

Revision 22058  Directory Listing
Modified Wed May 29 17:56:33 2013 UTC (4 years, 3 months ago) by pieper
BUG: fix build error on mac (can't return false for pointer)

Revision 22052  Directory Listing
Modified Wed May 29 16:53:05 2013 UTC (4 years, 3 months ago) by johan.andruejol
ENH: Harmonize qMRMLNodeComboBox properties

Previously, the property currentNodeId of the node combobox was set with an
id (QString) and sent a signal with a node (vtkMRMLNode*) which can be
confusing in the widgets using it. Now, the node combobox as an id
property or a node property.

See Issue #1694

Revision 22044  Directory Listing
Modified Mon May 27 20:48:48 2013 UTC (4 years, 4 months ago) by jcfr
BUG: Fix extractExtensionArchive test on MacOSX

Similarly to what has been done on Windows platform in
r20083 [1] this commit also excludes the readonly destination
path test on MacOSX.

[1] http://viewvc.slicer.org/viewvc.cgi/Slicer4?view=revision&revision=20083

See also issue #2053

Revision 22043  Directory Listing
Modified Mon May 27 20:48:46 2013 UTC (4 years, 4 months ago) by jcfr
BUG: Fix ExtensionsManager model tests on MacOSX and Windows

By default [1], on macosx and windows, settings format is not Ini.
This commit ensure this is the case.

[1] http://qt-project.org/doc/qt-4.8/qsettings.html#Format-enum

Revision 22029  Directory Listing
Modified Wed May 22 22:02:30 2013 UTC (4 years, 4 months ago) by jcfr
COMP: Use qRestAPI instead of deprecated qMidasAPI project

In addition to provide Midas support, qRestAPI also provides
support for XNat (qXnatAPI.h)

See https://github.com/commontk/qRestAPI

Revision 22023  Directory Listing
Modified Fri May 17 22:05:19 2013 UTC (4 years, 4 months ago) by jcfr
BUG: Ensure library can be loaded from different place using @rpath

Before this commit, attempt have been made (r18311, r18325, r18581) to
install both built-in CLI and extension CLI executable in a folder
located at some depth of the main Slicer executable. This was needed
because all libraries were referenced based on the location of the main
Slicer executable using "@executable_path". This was working *only* in the
case of built-in CLI but wasn't scaling very well for the extension CLI
executable. Indeed, being able to both differentiate the different
installed extension and keeping the depth to 1 level wasn't easily
feasible:

  /path/to/Slicer.app/Contents/MacOS/Slicer
  /path/to/Slicer.app/Contents/cli-modules/MyCLI
  /path/to/Slicer.app/Contents/Extensions-21855/SkullStripper/cli-modules/MyCLI

A solution could have been to install extensions directly in "Slicer.app"
folder and update the cli install sub dir to get something like:

  /path/to/Slicer.app/Extensions-21855/SkullStripper/MyCLI

While possible, it would have remain a special case to maintain.

Instead, by using "@rpath", CLI modules can now be installed in the Slicer
standard location "Slicer_CLIMODULES_LIB_DIR" instead of "Slicer_CLIMODULES_SUBDIR".
This commit remove the special case which never worked (issue #3051)

Waiting the topic "tweak-bundleutilities-for-rpath" is fully matured and
integrated in CMake, use custom version of BundleUtilities and GetPrerequisites.
See http://cmake.org/gitweb?p=stage/cmake.git;a=shortlog;h=refs/heads/tweak-bundleutilities-for-rpath

Since our custom version of the CMake modules now consider "~/usr/.*/lib",
the implementation of "gp_resolved_file_type_override" has been removed.

Remove the hack specific to LibArchive (introduced by commit r19615), since
the library is fixed up using the default library matching pattern, it
will be installed in the expected location.

SlicerExecutionModel has also been updated to link the CLI executable
and library with "-rpath" so that they can resolve the location of Slicer
libraries.

Revision 22016  Directory Listing
Modified Fri May 17 22:05:05 2013 UTC (4 years, 4 months ago) by jcfr
ENH: Simplify logic by appending path to CLI factory only if they exist.

Revision 22015  Directory Listing
Modified Fri May 17 22:05:04 2013 UTC (4 years, 4 months ago) by jcfr
ENH: Move MacOSX configuration code for CLI factory to a better place.

As a slight improvement, the path is also appended only if it exists.

Revision 22004  Directory Listing
Modified Thu May 16 15:17:33 2013 UTC (4 years, 4 months ago) by pieper
BUG: #2326 make save dialog name match node name

With this change, the file save name will be made to match the
name of the node.  This way when a user has specified a
meaningful name in the GUI it will be transferred to the
filename as well for consistency.

http://www.na-mic.org/Bug/view.php?id=2326#c8637

Revision 21984  Directory Listing
Modified Mon May 13 15:44:26 2013 UTC (4 years, 4 months ago) by jcfr
COMP: Fix unused variable warnings

Revision 21980  Directory Listing
Modified Sat May 11 17:09:13 2013 UTC (4 years, 4 months ago) by hjohnson
ENH: Add MGH test suite for reading/writing.

Revision 21973  Directory Listing
Modified Wed May 8 22:22:43 2013 UTC (4 years, 4 months ago) by pieper
ENH: expose module instance and module widget python objects

With this change it's possible to directly access the module widget
of a scripted module as slicer.modules.<module>Widget (i.e. the
actual instance that is visible when the module is selected).  This
makes it possible to access internal variables for debugging or
to access widget and logic instances for self-tests or automation.

For symmetry slicer.modules.<module>Instance is also exposed,
although there is generally not anything useful in that class
instance since it is primarily declaritive.  But sometimes it can
have global helper methods, so making it available can be useful.

Revision 21960  Directory Listing
Modified Wed May 1 03:34:50 2013 UTC (4 years, 4 months ago) by jcfr
COMP: Remove python patch step related to "dll boundaries" hack

As explained in r21863, patching pythonrun.h and pythonrun.c was
required to prevent crash (related to dll boundaries [1][2]) when
building Slicer debug against a released python.

[1] http://stackoverflow.com/questions/2322095/why-does-this-program-crash-passing-of-stdstring-between-dlls
[2] http://social.msdn.microsoft.com/Forums/en-US/vcgeneral/thread/57e0d522-a42c-4add-963d-c87c6e76f161

Applying the approach discussed on the Blender mailing list[3], the
hack is not required anymore. This is made possible by using
"PyRun_String" function combined with the "execfile" statement.

[3] http://lists.blender.org/pipermail/bf-python/2008-May/005253.html

When transitioning to Python3 [4], use of "exec" and "compile" could be
considered:

  with open('foo.py', 'r') as fh:
    code = compile(fh.read(), 'foo.py', 'exec'); exec(code);

[4] http://stackoverflow.com/questions/436198/what-is-an-alternative-to-execfile-in-python-3-0

Approach making use of the "imp"  module could also be investigated [5][6]

[5] http://www.ragestorm.net/blogs/?tag=execfile
[6] http://docs.python.org/2/library/imp.html

Finally, let's note that overall approach to load module could be
revised to prevent side effect as the one described in
"qSlicerScriptedFileDialog::setPythonSource"

Revision 21956  Directory Listing
Modified Tue Apr 30 15:55:02 2013 UTC (4 years, 4 months ago) by finetjul
BUG: Fix ApplyAndWait Completed CLI node status

By not observing the application logic, the cli logic was never notified
when the CLI node was completed and could not set the status accordingly.

Revision 21954  Directory Listing
Modified Mon Apr 29 22:56:04 2013 UTC (4 years, 4 months ago) by pohl
BUG: QInputdialog does not exist - changed it to QInputDialog

Revision 21953  Directory Listing
Modified Mon Apr 29 15:35:13 2013 UTC (4 years, 4 months ago) by pieper
COMP: fix duplicate metatype declaration (Issue #3081)

See also r21951

Revision 21951  Directory Listing
Modified Mon Apr 29 14:12:03 2013 UTC (4 years, 4 months ago) by finetjul
ENH: Add qSlicerScriptedFileDialog

* Add qSlicerFileDialog::description
* Add input dialog to select reader when multiple readers accept the same mime data


How to create a FileDialog in python?

+class XYZFileDialog:
+  def __init__(self, parent):
+    self.parent = parent
+    parent.fileType = 'XYZ'
+    parent.description = 'XYZ'
+    parent.action = slicer.qSlicerFileDialog.Read
+  def isMimeDataAccepted(self):
+    accept = self.parent.mimeData().hasFormat("text/uri-list")
+    self.parent.acceptMimeData(accept)
+  def dropEvent(self):
+    self.parent.dropEvent().accept()
+  def execDialog(self):
+    print 'exec'

How to order the list (make the module reader by default):
Make the module depend on "Data" -> instantiated after "Data" module
   def __init__(self, parent):
+    parent.dependencies = ["Data"]

Issue #3081

Revision 21950  Directory Listing
Modified Sat Apr 27 22:35:11 2013 UTC (4 years, 4 months ago) by jcfr
BUG: Ensure ITK IOFactory are registered for EXECUTABLE_ONLY cli modules

The library wrapper are now used when compiling either the [executable] or
[executable + shared library] cli module. It allows to call the
"itk::itkFactoryRegistration();" in both cases.

Associated SlicerExecutionModel commit is:

// ---------------------------------------------------
ENH: Use library wrapper in the "EXECUTABLE_ONLY" case
This will allow custom wrapper to execute some code before the main
entry point in both the [exec + shared lib] and [exec only] cases.

The macro "MODULE_STATIC" has also been introduced and can be tested
within the wrapper to discriminate both cases.

Change the component associated with Archive target from RuntimeLibraries
to Development. That way, static library won't be packaged.
// ---------------------------------------------------


See http://na-mic.org/Bug/view.php?id=3008
Fixes #3008

Revision 21939  Directory Listing
Modified Thu Apr 25 15:13:44 2013 UTC (4 years, 5 months ago) by finetjul
ENH: Add vtkMRMLCommandLineModuleNode::Completing

* Add vtkMRMLCommandLineModuleNode::Completing: state before the outputs
are loaded into the scene
* Add vtkMRMLCommandLineModuleNode::StatusModifiedEvent: event invoked when
status is changed.
* Remove unused wait_for_module(module, time_pause=5): should use the
Completing/Completed mechanism instead.

Revision 21938  Directory Listing
Modified Thu Apr 25 15:13:41 2013 UTC (4 years, 5 months ago) by finetjul
BUG: Discard AutoRun calls with obsolete mtime requests

Revision 21936  Directory Listing
Modified Thu Apr 25 15:13:37 2013 UTC (4 years, 5 months ago) by finetjul
ENH: Expose qSlicerIOManager::openDialog to python

Issue #2991

Revision 21935  Directory Listing
Modified Thu Apr 25 15:13:35 2013 UTC (4 years, 5 months ago) by finetjul
STYLE: Align CLI Progress bar "Status:" label to the right

It is better for the "Status:" label to be closer to the current status.
Otherwise the user just glances over it without really noticing the
relation between both.

See Issue #2988

Revision 21934  Directory Listing
Modified Thu Apr 25 15:13:33 2013 UTC (4 years, 5 months ago) by finetjul
ENH: Add VisibleAfterExecution option for CLI Progress bar

This option defines if the progress bard stay visible at the end of the
execution of the CLI or not.

See Issue #2988

Revision 21933  Directory Listing
Modified Thu Apr 25 15:13:32 2013 UTC (4 years, 5 months ago) by finetjul
ENH: Fix CLI progress bar setup

The progress bar was only initialized on setDefaultValue when it should be
initialized everytime a new command line module node is selected.

See Issue #2988

Revision 21931  Directory Listing
Modified Thu Apr 25 15:13:28 2013 UTC (4 years, 5 months ago) by finetjul
ENH: Split AutoRun into AutoRun&AutoRunMode, add AutoRunOnOtherInputEvents

To limit confusion, split the AutoRun options from the AutoRun state (On/Off).
Add AutoRunOnOtherInputEvents to observe events other than ModifiedEvent.

Revision 21929  Directory Listing
Modified Thu Apr 25 15:13:23 2013 UTC (4 years, 5 months ago) by finetjul
ENH: Add vtkMRMLCommandLineModuleNode::Cancel() to cancel from python

Use int as return type for GetStatus() because python can't get enum types.
Use Cancel() to request a cancelling.

Revision 21928  Directory Listing
Modified Thu Apr 25 15:13:21 2013 UTC (4 years, 5 months ago) by finetjul
ENH: Add vtkMRMLCommandLineModuleNode::SetAutoRun()

It gives the ability to automatically run a CLI when input parameters
changed.
Closes #2940

Revision 21927  Directory Listing
Modified Thu Apr 25 15:13:18 2013 UTC (4 years, 5 months ago) by finetjul
ENH: Move CLI progress bar above Cancel/Apply buttons

It makes more sense to have all the CLI module controls to be grouped
together.

Revision 21926  Directory Listing
Modified Thu Apr 25 15:13:17 2013 UTC (4 years, 5 months ago) by finetjul
STYLE: Add comments to CLI node/logic/widget

Rename "Default" pushbutton into "Restore Defaults"

Revision 21925  Directory Listing
Modified Thu Apr 25 15:13:13 2013 UTC (4 years, 5 months ago) by finetjul
ENH: Add vtkMRMLCommandLineModuleNode::Cancelling

There was no difference between a requested cancel and the module being
cancelled.

Revision 21924  Directory Listing
Modified Thu Apr 25 15:13:11 2013 UTC (4 years, 5 months ago) by finetjul
ENH: Add vtkMRMLCommandLineModuleNode::SetParameterAsNode

Convenient function that will be useful when observing parameter nodes.

Revision 21923  Directory Listing
Modified Thu Apr 25 15:13:08 2013 UTC (4 years, 5 months ago) by finetjul
ENH: Add vtkMRMLApplicationLogic::InvokeEventWithDelay()

This allows an event to be fired with a slight delay.

Revision 21904  Directory Listing
Modified Sat Apr 20 22:06:25 2013 UTC (4 years, 5 months ago) by finetjul
ENH: Add drag&drop support for registered IO dialogs.

To support drag&drop, a qSlicerFileDialog derived class should reimplement:
 * qSlicerFileDialog::dragEnterEvent()
 * qSlicerFileDialog::dropEvent()

By default, qSlicerDataDialog supports drag&drop.

Issue #3081

Revision 21902  Directory Listing
Modified Fri Apr 19 22:56:32 2013 UTC (4 years, 5 months ago) by johan.andruejol
BUG: Fix lost on focus when modifying spinbox

Previously, the spinbox would lose focus when modifying the value due to
an update by the node. Using the new ctkSpinBox that actually checks
if the values are the same before updating fixes this.

See Issue #2986

Revision 21901  Directory Listing
Modified Fri Apr 19 18:49:33 2013 UTC (4 years, 5 months ago) by alexy
BUG: 2970. Reverted changes to Chart colormaps.

Revision 21897  Directory Listing
Modified Wed Apr 17 22:11:53 2013 UTC (4 years, 5 months ago) by jcfr
BUG: External link in extension manager now open in browser. Fixes #3045

To determine if a link should be open in the extension manager or in an
external browser, the "host" of the clicked url and the server url are
compared.

See http://qt-project.org/doc/qt-4.8/qurl.html#setAuthority for more details.

See http://www.na-mic.org/Bug/view.php?id=3045

Revision 21886  Directory Listing
Modified Fri Apr 12 19:26:46 2013 UTC (4 years, 5 months ago) by mccormic
COMP: Use ${VTK_LIBRARIES} instead of vtkCommon.

Forwards-compatibility with VTK6.

Revision 21883  Directory Listing
Modified Tue Apr 9 22:19:31 2013 UTC (4 years, 5 months ago) by naucoin
STYLE: avoid print out of nodes not found on start up

Took out the call to update the widget from mrml on init, 
it gets called from setMRMLScene which is when it should be
updated.
Swapped warning for debug print outs as not having interaction
or selection nodes is not an error case.


Revision 21865  Directory Listing
Modified Fri Apr 5 03:20:20 2013 UTC (4 years, 5 months ago) by jcfr
COMP: Do not include or use i18n macros if Slicer_BUILD_I18N_SUPPORT is OFF

Commit r21856 disabled internationalization support by default and
it introduced the option Slicer_BUILD_I18N_SUPPORT allowing to enable it.

This commit takes care of excluding the associated CMake macro and its
invocation if the option is disabled.

Revision 21856  Directory Listing
Modified Tue Apr 2 18:16:44 2013 UTC (4 years, 5 months ago) by jcfr
COMP: Add option allowing to enable internationalization support.

STATUS
 Internationalization support has been discussed during March 26th 2013
developer hangout.

 We reach consensus: Official support for i18n will be disabled. A CMake
option named Slicer_BUILD_I18N_SUPPORT will be added and the option
won't be actively supported or tested.

 Why? Supporting internationalization properly would require to test
all ITK/VTK/Teem/.. readers and we don't have the funding or resources
to support that effort. If it is something you are interested in, make
sure to drop an email on the developer list. We will be happy to provide
 more information.

DISCUSSION
 http://slicer-devel.65872.n3.nabble.com/Re-Rounding-to-integer-tt4027985.html
 http://slicer-devel.65872.n3.nabble.com/Re-slicer-users-Slicer4-can-t-really-use-it-yet-td4028040.html
 http://slicer-users.65878.n3.nabble.com/Slicer4-DICOM-many-problems-td4025919.html

ISSUES
 3029 - Image spacing not read correctly in Slicer 4.2.2

Revision 21853  Directory Listing
Modified Mon Apr 1 22:17:24 2013 UTC (4 years, 5 months ago) by jcfr
BUG: Disable ITK_AUTOLOAD_PATH/itkMRMLIDIOPlugin for executable CLIs

Follow up of commit r21440, unset environment variable ITK_AUTOLOAD_PATH
consistently:

Unset ITK_AUTOLOAD_PATH environment variable to prevent the CLI from
loading the itkMRMLIDIOPlugin plugin because executable CLIs read images
from file and not from shared memory. Worst the plugin in the CLI
could clash by loading libraries (ITK, VTK, MRML) other than the
statically linked to the executable.
Historically, there was an nvidia driver bug that causes the module
to fail on exit with undefined symbol.


// ------------------
This fixes the following error (Ubuntu 10.04 / gcc 4.4.3):

Error(s):
    CLI executable: /home/jchris/Projects/Slicer-AHM-Superbuild-Debug/Slicer-build/lib/Slicer-4.2/cli-modules/AddScalarVolumes
    /home/jchris/Projects/Slicer-AHM-Superbuild-Debug/Slicer-build/lib/Slicer-4.2/cli-modules/AddScalarVolumes: symbol lookup error: /home/jchris/Projects/QtSDK-1.2/Desktop/Qt/474/gcc/lib/libQtGui.so.4: undefined symbol: _ZN11QMetaObject11removeGuardEPP7QObject

    CLI executable: /home/jchris/Projects/Slicer-AHM-Superbuild-Debug/Slicer-build/lib/Slicer-4.2/cli-modules/AddScalarVolumes
    Failed to retrieve Xml Description

// ------------------
.. and also the following warnings (MacOSX 10.8.3 / Gcc 4.2.1):

Error(s):
    CLI executable: /Volumes/Dashboards/Experimental/Slicer-1-Superbuild-Release-cmake-2.8.11-rc1/Slicer-build/lib/Slicer-4.2/cli-modules/ProbeVolumeWithModel
    WARNING: In /Volumes/Dashboards/Experimental/Slicer-1-Superbuild-Release-cmake-2.8.11-rc1/ITKv4/Modules/Core/Common/src/itkObjectFactoryBase.cxx, line 514
/Volumes/Dashboards/Experimental/Slicer-1-Superbuild-Release-cmake-2.8.11-rc1/Slicer-build/lib/Slicer-4.2/ITKFactories/libMGHIOPlugin.so is already loaded

WARNING: In /Volumes/Dashboards/Experimental/Slicer-1-Superbuild-Release-cmake-2.8.11-rc1/ITKv4/Modules/Core/Common/src/itkObjectFactoryBase.cxx, line 514
/Volumes/Dashboards/Experimental/Slicer-1-Superbuild-Release-cmake-2.8.11-rc1/Slicer-build/lib/Slicer-4.2/ITKFactories/libMRMLIDIOPlugin.so is already loaded


// ------------------
This fixes the problem without explaining completely the underlying cause, more
investigation is required to have a clear understanding of the problem.

Revision 21848  Directory Listing
Modified Fri Mar 29 02:15:04 2013 UTC (4 years, 5 months ago) by jcfr
COMP: Add HAVE_PYRUN_{CLOSE, OPEN}FILE anticipating build against system python

Anticipating the possibility to build Slicer against a system python,
introduced variable HAVE_PYRUN_CLOSEFILE and HAVE_PYRUN_OPENFILE variable
to be able to conditionally build Slicer library with fopen/fclose
built-in the python library.

Revision 21847  Directory Listing
Modified Thu Mar 28 04:27:50 2013 UTC (4 years, 5 months ago) by jcfr
COMP: Update version PythonQt to integrate latest fixes

The "patched-3" branch is rebased against r244 of PythonQt, it integrates
all backported changes specific to "patched-2" and also
include improvements by the upstream team. For a detailed list,
see https://github.com/commontk/PythonQt/compare/e2dce4...0a2486

Revision 21831  Directory Listing
Modified Fri Mar 22 17:29:03 2013 UTC (4 years, 6 months ago) by naucoin
STYLE: set the title on the loading window, replace the app name

Revision 21830  Directory Listing
Modified Fri Mar 22 14:47:03 2013 UTC (4 years, 6 months ago) by alexy
BUG: 2970. Shifted LUT for label maps to start with 1 rather than 0. 0 is reserved for "no value"

Revision 21805  Directory Listing
Modified Wed Mar 13 05:24:55 2013 UTC (4 years, 6 months ago) by jcfr
COMP: Update ExternalData and remove hack in SLICER_ADD_PYTHON_UNITTEST

ExternalData module has been updated to preserve escaped semicolons during
argument expansion.

Details: http://cmake.org/gitweb?p=cmake.git;a=commit;h=1823ab4d76d8efe79bed85328a3f8c74c7d625bd

Revision 21797  Directory Listing
Modified Tue Mar 12 11:20:19 2013 UTC (4 years, 6 months ago) by jcfr
ENH: Add python unitTest testing slicer.util.{saveNode, saveScene} methods

Revision 21796  Directory Listing
Modified Tue Mar 12 11:20:16 2013 UTC (4 years, 6 months ago) by jcfr
ENH: Add saveNode and saveScene to python API

Example:

  n = slicer.util.GetNode('MRHead')
  slicer.util.saveNode(n, '/tmp/foo.nrrd')  # Save node data

  slicer.util.saveScene('/tmp/currentscene.mrml') # Save scene as MRML file

  slicer.util.saveScene('/tmp/currentscene.mrb') # Save scene as MRB file

  slicer.util.saveScene('/tmp/currentscene') # Save scene as directory

Revision 21795  Directory Listing
Modified Tue Mar 12 11:20:14 2013 UTC (4 years, 6 months ago) by jcfr
ENH: Clean code and add command line option "--temporary-path"

Remove unused headers

Remove tempDirectory initially added with r11985,
qSlicerCoreApplication::temporaryPath  (added with r15424) should be used
instead.

Calling slicer with both --testing and --temporary-path options returns
the directory associated with testing.

$ ./Slicer --temporary-path
/tmp/Slicer

$ ./Slicer --testing --temporary-path
/tmp/Slicer-tmp

Revision 21794  Directory Listing
Modified Tue Mar 12 11:20:11 2013 UTC (4 years, 6 months ago) by jcfr
COMP: Update Slicer test macros to support ExternalData

Revision 21767  Directory Listing
Modified Fri Feb 22 04:44:46 2013 UTC (4 years, 7 months ago) by jcfr
COMP: Move Editor logic Cpp classes from "Base/Logic" to "EditorLib/Logic"

These classes implementing the logic associated with editor effects, it
make sens to move them along side the EditorLib module.

Revision 21766  Directory Listing
Modified Fri Feb 22 03:37:20 2013 UTC (4 years, 7 months ago) by jcfr
COMP: Move "Slicer3Adapters.tcl" into "Python/slicer/tcl"

The historical folder GUI that was specific to Slicer3 had been removed
and "Slicer3Adapters.tcl" has been moved to a more suitable home. It is now
copied/installed as a python resources available within the python
directory.

Revision 21765  Directory Listing
Modified Fri Feb 22 02:20:57 2013 UTC (4 years, 7 months ago) by jcfr
COMP: Move Editor icons from "Base/Logic" into "EditorLib/Resources/Icons"

Also introduced the python constant EditorLib.ICON_DIR allowing
to easily resolve icon filepaths.

The variable is set using the __file__ attribute of EditorLib module.

Since the file/directory organization of either (1) source code, (2) file copied
into the build dir or (3) installed files is the same, the ICON_DIR
variable will allow to resolve the icon file paths successfully.

Revision 21759  Directory Listing
Modified Thu Feb 21 18:57:55 2013 UTC (4 years, 7 months ago) by fedorov
ENH: make sure the error is printed once, otherwise the otput slows down the execution of the filter too much

Revision 21758  Directory Listing
Modified Thu Feb 21 18:49:53 2013 UTC (4 years, 7 months ago) by fedorov
ENH: adding FastMarching effect to Editor; see issue #2454

Revision 21744  Directory Listing
Modified Wed Feb 20 00:35:50 2013 UTC (4 years, 7 months ago) by jcfr
COMP: Remove unused "vtkSlicerROILogic" class

Not user anywhere. This class was originally used by vtkSlicerROIGUI
which has been removed with r16260.

"API changes Roadmap" wiki page has also been updated.

Revision 21739  Directory Listing
Modified Tue Feb 19 05:32:29 2013 UTC (4 years, 7 months ago) by jcfr
COMP: Remove unused class "Base/Logic/vtkSlicerIGTDemoLogic"

This class has originally been added with Slicer r1840  (back in 2006) and
was first used by vtkSlicerIGTDemoGUI added at r1843. Then, at r4954 the
GUI classes have been removed while keeping around the Logic.

Afterward, considering that (1) logic class hasn't been used anywhere
and (2) wasn't build. It's is safe to remove this class.

Revision 21724  Directory Listing
Modified Sat Feb 16 19:11:43 2013 UTC (4 years, 7 months ago) by fedorov
ENH: return the number of seeds used in the initialization

Revision 21721  Directory Listing
Modified Sat Feb 16 02:38:34 2013 UTC (4 years, 7 months ago) by jcfr
BUG: Ensure ITKv4 IO Factory are registered within tests

* Include directories associated with ITKFactoryRegistration are also
appended to ITK_INLCUDE_DIRS to ensure that the method itk::itkFactoryRegistration
could be called.

* Code allowing to register the factory has been manually added to the
tests.

* Would it make sens to have this library ITKFactoryIORegistration
being built/provided by ITKv4 proper ?

See #2813 - http://www.na-mic.org/Bug/view.php?id=2813
See #2951 - http://www.na-mic.org/Bug/view.php?id=2951

Revision 21720  Directory Listing
Modified Sat Feb 16 02:38:18 2013 UTC (4 years, 7 months ago) by jcfr
STYLE: Fix indent

Revision 21717  Directory Listing
Modified Sat Feb 16 02:38:03 2013 UTC (4 years, 7 months ago) by jcfr
COMP: Remove extra include from SEMCommandLineLibraryWrapper

Since ITK_VERSION_MAJOR is already set while configuring the file, it is
not needed to include "itkConfigure.h".

Revision 21704  Directory Listing
Modified Thu Feb 14 22:05:23 2013 UTC (4 years, 7 months ago) by jcfr
STYLE: For consistency, change CMake macro from "SIMPLE_TEST" to "simple_test"

Use of lower case CMake function/macro when including underscore has been
first introduced with r17191.

See http://viewvc.slicer.org/viewvc.cgi/Slicer4?view=revision&revision=17191

Revision 21702  Directory Listing
Modified Thu Feb 14 18:11:14 2013 UTC (4 years, 7 months ago) by fedorov
STYLE: remove unused variable

Revision 21701  Directory Listing
Modified Thu Feb 14 17:53:33 2013 UTC (4 years, 7 months ago) by fedorov
ENH: added utility function for seed initialization

See issue 2454. This utility function is for optimized seed initialization, as
compared to traversing the image from the python Editor effect code.

Revision 21691  Directory Listing
Modified Tue Feb 12 19:26:09 2013 UTC (4 years, 7 months ago) by jcfr
BUG: Update CLI test driver to ensure registration of ITKv4 IO Factories

See #2813 - http://www.na-mic.org/Bug/view.php?id=2813

Revision 21663  Directory Listing
Modified Mon Feb 4 22:16:32 2013 UTC (4 years, 7 months ago) by pieper
ENH: improve reporting for --verbose-module-discovery

This adds extra information that is helpful for debugging
module discovery.

Revision 21662  Directory Listing
Modified Mon Feb 4 22:16:23 2013 UTC (4 years, 7 months ago) by pieper
ENH: allow .bat files to be used as command line modules (issue #2039)

This way people can write simple wrapper scripts on windows
for other executable types, such as matlab scripts.

Revision 21660  Directory Listing
Modified Mon Feb 4 21:45:50 2013 UTC (4 years, 7 months ago) by jcfr
BUG: Prevent extensions from being loaded twice when "Install" tab initially hidden

For details: https://github.com/midasplatform/slicerappstore/pull/36

See http://na-mic.org/Mantis/view.php?id=2911

Fixes #2911

Revision 21657  Directory Listing
Modified Fri Feb 1 23:32:24 2013 UTC (4 years, 7 months ago) by naucoin
BUG: adjust hidden flag on model hierarchy nodes to get back to previous behaviour

Libs/MRML/Core/vtkMRMLModelHierarchyNode.cxx - set hide from editors to false as a default
Modules/Loadable/Models/Resources/UI/qSlicerModelsModuleWidget.ui - set showHidden to false
Modules/Loadable/Models/qSlicerModelsModuleWidget.cxx - take out call to setShowHiddenForTypes
Libs/MRML/Widgets/qMRMLSceneHierarchyModel.cxx - set hidden true on new 1:1 hierarchy nodes
Modules/CLI/ModelMaker/ModelMaker.cxx - ditto
Base/QTCLI/qSlicerCLIModuleUIHelper.cxx - set show hidden to false and setting the node type by directly checking multiple and aggregate.

Issue #2906


Revision 21652  Directory Listing
Modified Wed Jan 30 22:00:44 2013 UTC (4 years, 7 months ago) by jcfr
COMP: Ensure itkFactoryRegistration code is included when building against ITKv4

See http://www.na-mic.org/Bug/view.php?id=2900

Fixes #2900

Revision 21632  Directory Listing
Modified Wed Jan 23 22:58:14 2013 UTC (4 years, 8 months ago) by jcfr
STYLE: For consistency, rename "*[Ee]xtensionManager*" methods into "*[Ee]xtensionsManager*"

Note the extra "s" added to the word "Extension".

Revision 21631  Directory Listing
Modified Wed Jan 23 22:58:11 2013 UTC (4 years, 8 months ago) by jcfr
ENH: Update ExtensionsManager webview when ExtensionsServer url is updated in the settings panel

Revision 21622  Directory Listing
Modified Fri Jan 18 23:21:28 2013 UTC (4 years, 8 months ago) by finetjul
BUG: Remote filter-end and filter-type from CLI output

Because filter-type was not removed, filter-end couldn't be removed.

Revision 21621  Directory Listing
Modified Fri Jan 18 23:13:00 2013 UTC (4 years, 8 months ago) by naucoin
ENH: add the ability to import multi level model hierarchies from CLIs

Added to support passing a template scene to the Model Maker 
that contains a multi level model hierarchy. 

TODO: decide the best practice when a hierarchy is imported twice (for 
example, running the model maker on the same label map more than once)
right now this will make a new hierarchy rather than over writing
the old one.


Revision 21619  Directory Listing
Modified Fri Jan 18 22:42:53 2013 UTC (4 years, 8 months ago) by naucoin
BUG: copy the correct model display node, fixing a copy/paste error

Revision 21618  Directory Listing
Modified Fri Jan 18 22:21:47 2013 UTC (4 years, 8 months ago) by jcfr
ENH: Associated icon with copy, cut and paste action

Icons are licensed under Creative Commons License (CC-BY-SA 3.0)
See http://creativecommons.org/licenses/by-sa/3.0/

They have respectivaly been downloaded from:
 http://openiconlibrary.sourceforge.net/gallery2/?./Icons/actions/edit-copy-6.png
 http://openiconlibrary.sourceforge.net/gallery2/?./Icons/actions/edit-cut-6.png
 http://openiconlibrary.sourceforge.net/gallery2/?./Icons/actions/edit-paste-6.png

Before being uploaded on "openiconlibrary", the icons originally have
been obtained from http://www.oxygen-icons.org/

Revision 21604  Directory Listing
Modified Fri Jan 11 21:31:03 2013 UTC (4 years, 8 months ago) by jcfr
COMP: Make sure itkTestMain.h is available when building extension

From: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

Revision 21600  Directory Listing
Modified Fri Jan 11 21:30:42 2013 UTC (4 years, 8 months ago) by jcfr
COMP: Ensure that module relying "DWIConvert" also work when build against ITKv3

Backward compatibility with ITKv3 is maintained by aliasing the module.

From: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

Revision 21592  Directory Listing
Modified Fri Jan 11 21:29:52 2013 UTC (4 years, 8 months ago) by jcfr
COMP: Add ITKFactoryRegistration library centralizing ITK IO factory registration

This commit will ensure that ITK IO factory are properly registered on all
supported platforms.

When ITKv4 is build shared, the library holding the factory registration code
are build statically. As a consequence, when CLI module are loaded as library
the factory are registered multiple times. Around 800 factories where registered
and this was leading to poor performance when loading images.

This commit enable the building of a shared library named ITKFactoryRegistration
that should be linked against to ensure loading of the factory. This approach
can succeed thanks to the help of the ITK variable ITK_NO_IO_FACTORY_REGISTER_MANAGER.

This variable allow to disable the automatic registration of factory in selected part
of the code.

The following two cases are handled:
 - Registration of the factories within the Slicer executable.
 - Registration of the factories within CLI executable.

Fixes #2813

From: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>

Revision 21590  Directory Listing
Modified Fri Jan 11 19:14:41 2013 UTC (4 years, 8 months ago) by jcfr
BUG: Fix processing of "additional-module-paths" command line option

When multiple paths were passed, they were incorrectly converted to a single
path containing a space instead of a list of paths.

Revision 21579  Directory Listing
Modified Thu Jan 10 17:51:01 2013 UTC (4 years, 8 months ago) by finetjul
ENH: Add Scene Performance test

It measures time spent by some scene actions such as loading, closing,
restoring, relayouting a scene or modifying/adding nodes.
Issue #2642

Example of performance on a MacBookPro laptop (2.4GHz):
AddData (BrainAtlas2012.mrb) took 44865 msecs
CloseScene () took 28706 msecs
AddData (BrainAtlas2012.mrb) took 44579 msecs
ModifyNode (vtkMRMLScalarVolumeNode1) took 4 msecs
ModifyNode (vtkMRMLScalarVolumeNode2) took 35 msecs
ModifyNode (vtkMRMLScalarVolumeNode3) took 20 msecs
ModifyNode (vtkMRMLModelHierarchyNode2) took 14 msecs
ModifyNode (vtkMRMLModelNode4) took 0 msecs
ModifyNode (vtkMRMLModelDisplayNode5) took 14 msecs
ModifyNode (vtkMRMLModelHierarchyNode3) took 13 msecs
ModifyNode (vtkMRMLModelStorageNode1) took 4 msecs
ModifyNode (vtkMRMLModelHierarchyNode301) took 18 msecs
ModifyNode (vtkMRMLModelDisplayNode304) took 23 msecs
ModifyNode (vtkMRMLModelHierarchyNode51) took 19 msecs
AddNode (vtkMRMLModelNode302) took 46 msecs

Revision 21575  Directory Listing
Modified Thu Jan 10 16:03:39 2013 UTC (4 years, 8 months ago) by jcfr
ENH: Load translation only if "Internationalization" is enabled

Revision 21566  Directory Listing
Modified Tue Jan 8 21:06:16 2013 UTC (4 years, 8 months ago) by jcfr
BUG: Ensure MacOSX package can be renamed from "Slicer.app" to "Something.app"

Fixes #2848

Revision 21560  Directory Listing
Modified Thu Jan 3 20:54:21 2013 UTC (4 years, 8 months ago) by finetjul
BUG: Fix ctkCheckBox and nested style isssue in general.

Revision 21559  Directory Listing
Modified Wed Jan 2 17:50:29 2013 UTC (4 years, 8 months ago) by sankhesh
BUG: Load translations before instantiating the GUI

Moved loadTranslations() and loadLanguage() methods from qSlicerApplicationHelper
to qSlicerCoreApplication. This enables loading them before instantiating the
main Slicer GUI.
Many thanks to zengwenye <iamzengwenye@163.com> for submitting the patch.
Fixes issue 2836

Revision 21557  Directory Listing
Modified Mon Dec 31 13:02:28 2012 UTC (4 years, 8 months ago) by finetjul
COMP: qSlicerCoreApplication::defaultExtensionsInstallPath() when

Slicer_BUILD_EXTENSIONMANAGER_SUPPORT is OFF

Revision 21555  Directory Listing
Modified Mon Dec 31 12:49:25 2012 UTC (4 years, 8 months ago) by finetjul
ENH: Cleanup qSlicerMouseModeToolBar

Allows to programatically set the default action without activating
the place mode:
 - vtkMRMLSelectionNode::SetActiveAnnotationID
Don't listen to unnecessary events like ActiveAnnotationIDChangedEvent,
AnnotationIDListModifiedEvent, InteractionModePersistenceChangedEvent.
Listening to ModifiedEvent is enough.
Todo: remove the unnecessary events.

Revision 21554  Directory Listing
Modified Mon Dec 31 12:49:15 2012 UTC (4 years, 8 months ago) by finetjul
BUG: qSlicerModulesMenu triggers action when current module becomes loaded

If qSlicerModulesMenu::setCurrentModule() is called before the module has
been loaded, qSlicerModulesMenu was not triggering the action which could
result in observers not being notified. (the module selection toolbar)

Revision 21553  Directory Listing
Modified Mon Dec 31 12:49:08 2012 UTC (4 years, 8 months ago) by finetjul
ENH: CLI now support more than 1 category

Categories are separated with ; character.
Empty categories are allowed (become top level)

Revision 21534  Directory Listing
Modified Mon Dec 31 11:53:35 2012 UTC (4 years, 8 months ago) by finetjul
STYLE: Minor style changes in qSlicerMouseModeToolBar

Improve readability.

Revision 21522  Directory Listing
Modified Thu Dec 20 15:54:22 2012 UTC (4 years, 9 months ago) by pieper
BUG: fix the disable-python command line option

By some oversight this feature wasn't working before.

Revision 21521  Directory Listing
Modified Wed Dec 19 19:16:03 2012 UTC (4 years, 9 months ago) by sankhesh
BUG: Issue 2240. Removed code repetition.

Revision 21519  Directory Listing
Modified Tue Dec 18 16:15:22 2012 UTC (4 years, 9 months ago) by sankhesh
BUG: Issue 2240. Added mount Volumes to sidebar

Revision 21516  Directory Listing
Modified Wed Dec 12 08:51:57 2012 UTC (4 years, 9 months ago) by jcfr
COMP: Remove unused code from qSlicerCLIModuleWidget

Revision 21495  Directory Listing
Modified Fri Dec 7 19:56:27 2012 UTC (4 years, 9 months ago) by naucoin
BUG: remove unintended check ins

Revision 21494  Directory Listing
Modified Fri Dec 7 19:53:01 2012 UTC (4 years, 9 months ago) by naucoin
BUG: fix fiducial display in light box mode.

Use the renderer from the light box proxy manager if it's defined
When in light box mode, switch to using 2d point handles for fiducials.
Avoid seed widget and representation having different renderers on creation.
Unify light box index calculation.
Fix the annotations showing up in the 0th light box when the annotation
should be in the -1th. 
Take into account volume spacing, calculate the distance between the fiducial
and the slice at this light box index using distance from the fiducial point and the slice plane.
Reset the glyph type when changing in and out of lightbox mode.

Issue #1690

Revision 21491  Directory Listing
Modified Fri Dec 7 19:14:17 2012 UTC (4 years, 9 months ago) by jcfr
BUG: Fix crash by ensuring private member is initialized.

Thanks to Bill Lorensen, Alex Yarmarkovich and Csaba Pinter for pointing
out the problem.

To provide some background:

  While working on the commit r21482 that introduced the problem, the
variable was automatically initialized to 0 on my workstattion and I didn't
 face the issue.

  Having valgrind reporting uninitialized variable on the dashboard would
also be helpful.

Revision 21490  Directory Listing
Modified Fri Dec 7 19:14:15 2012 UTC (4 years, 9 months ago) by jcfr
STYLE: Remove private member to be consistent with setter/getter function name

Function is named "userRevisionSettings()" and associated member is now
named "RevisionUserSettings" instead of "RevisionSpecificUserSettings"

Revision 21482  Directory Listing
Modified Fri Dec 7 00:23:59 2012 UTC (4 years, 9 months ago) by jcfr
ENH: Support per user per revision extensions settings

There is now a clear distinction between:
 - userSettings -> i.e. ~/.config/NA-MIC/Slicer.ini
 - revisionUserSettings -> i.e. ~/.config/NA-MIC/Slicer-<revision>.ini

The following slicer settings are now revision specific:
 - Extensions/ManagerEnabled
 - Extensions/ServerUrl
 - Extensions/InstallPath
 - Modules/AdditonalPath
 - Modules/IgnoreModules

Additionally, the launcher version has also been updated to be able to
consider settings associated with a user, application and revision. This is
captured by the new parameter APPLICATION_REVISION, ORGANIZATION_DOMAIN,
ORGANIZATION_NAME and USER_ADDITIONAL_SETTINGS_FILEBASENAME passed to the CMake
function "ctkAppLauncherConfigure".

qSlicerCoreApplication API has also been extended and now includes methods
like:
  - QSettings* userSettings()  [settings() method is deprecated and kept for backward compatibility]
  - QSettings* revisionUserSettings()
  - QString launcherRevisionUserSettingsFilePath()
  - QString slicerUserSettingsFilePath()
  - QString slicerRevisionUserSettingsFilePath()

In addition to the settings, the extensions install path is also revision
specific, it means that it's now possible to have multiple version of slicer
running with different set of extensions.

Fixes #2791, #2143, #2720, #2533


Since the version of the launcher is updated, launcher will return EXIT_FAILURE
also when no application is been set in the launcher settings.

Fixes #2767

Revision 21481  Directory Listing
Modified Fri Dec 7 00:23:51 2012 UTC (4 years, 9 months ago) by jcfr
COMP: Remove unused file "slicerPython.h"

Similar role is now fulfilled by https://github.com/commontk/PythonQt/blob/patched-2/src/PythonQtPythonInclude.h

Revision 21480  Directory Listing
Modified Fri Dec 7 00:23:50 2012 UTC (4 years, 9 months ago) by jcfr
COMP: Remove unused file "point.h"

Revision 21479  Directory Listing
Modified Fri Dec 7 00:23:48 2012 UTC (4 years, 9 months ago) by jcfr
COMP: Remove unused file vtkSlicerExtensionsLogic.{cxx,h}

Revision 21440  Directory Listing
Modified Sat Nov 17 22:29:12 2012 UTC (4 years, 10 months ago) by finetjul
BUG: Disable ITK_AUTOLOAD_PATH/itkMRMLIDIOPlugin for executable CLIs

Unset ITK_AUTOLOAD_PATH environment variable to prevent the CLI from
loading the itkMRMLIDIOPlugin plugin because executable CLIs read images
from file and not from shared memory. Worst the plugin in the CLI
could clash by loading libraries (ITK, VTK, MRML) other than the
statically linked to the executable.
Historically, there was an nvidia driver bug that causes the module
to fail on exit with undefined symbol.

Regression from r12053 (always broken in Slicer4, works in Slicer3)

Issues #2773 #1635

Revision 21419  Directory Listing
Modified Thu Nov 15 18:26:08 2012 UTC (4 years, 10 months ago) by jcfr
COMP: Fix build error occurring when disabling QtTesting

See http://www.na-mic.org/Bug/view.php?id=2760

Fixes #2760

Revision 21410  Directory Listing
Modified Wed Nov 14 18:05:02 2012 UTC (4 years, 10 months ago) by jcfr
BUG: Remove extra initialization associated with "pkgIndex.tcl"

Since the file "pkgIndex.tcl" has been removed with r21407, it shouldn't
be imported.


See http://www.na-mic.org/Bug/view.php?id=2735
Fixes #2735

Revision 21407  Directory Listing
Modified Wed Nov 14 16:26:54 2012 UTC (4 years, 10 months ago) by jcfr
COMP: Remove SWidget tcl related code

Keep the Slicer3Adapter.tcl around since it's still required by EMSegment

Later on should also remove the slicer.sliceWidet* object since these
ones can be accessed using the slicer.app.layoutManager() object.

See http://na-mic.org/Mantis/view.php?id=2735
Fixes #2735

Revision 21365  Directory Listing
Modified Wed Nov 14 15:37:16 2012 UTC (4 years, 10 months ago) by jcfr
BUG: Add editor icons removed by error

This is a follow up of commit r21328 associated with issue #2735

See http://na-mic.org/Mantis/view.php?id=2757
Fixes #2757

Revision 21353  Directory Listing
Modified Wed Nov 14 14:32:48 2012 UTC (4 years, 10 months ago) by pieper
STYLE: remove unused script (performance test cleanup)

Revision 21335  Directory Listing
Modified Fri Nov 9 21:38:03 2012 UTC (4 years, 10 months ago) by jcfr
BUG: Do not pass "--attach-process" when setting sys.argv

It avoid some python script to complain about unknown argument.

Revision 21331  Directory Listing
Modified Thu Nov 8 23:00:46 2012 UTC (4 years, 10 months ago) by jcfr
BUG: Add support for installation of distribute and pip

Connect the signal "systemExitExceptionRaised" and so that the
application can be cleanup and terminate nicely. This will allow
the installation of distribute to terminate nicely. Indeed "sys.exit"
is called within the "distribute_setup.py" script.

Also add the "isatty" method to PythonQtRedirectStdOut so that logging
framework can check if the output is a tty-like device. Log mechanism
associated with pip install will now be happy since the call "sys.stdout.isatty"
will be valid.

See http://na-mic.org/Mantis/view.php?id=2694

Fixes #2694

Revision 21330  Directory Listing
Modified Thu Nov 8 14:58:39 2012 UTC (4 years, 10 months ago) by jcfr
BUG: Fix generic test ensuring qSlicerApplication instantiate ctkSettings

Fix is a follow up of commit r21323

Revision 21329  Directory Listing
Modified Thu Nov 8 03:37:48 2012 UTC (4 years, 10 months ago) by jcfr
COMP: Remove unused VolumeDisplaySWidget.tcl - W/L implemented in vtkSliceViewInteractorStyle

See http://na-mic.org/Bug/view.php?id=2735

Fixes #2735

Revision 21328  Directory Listing
Modified Thu Nov 8 02:46:09 2012 UTC (4 years, 10 months ago) by jcfr
COMP: Remove unused *.png files from Base/GUI/ImageData and Base/GUI/Tcl/ImageData

Also verified that non of these png module were used using the
following one-liner:

cd /home/jchris/Projects/Slicer4
for i in `ls -1 ~/Projects/Slicer4/Base/GUI/ImageData/*.png`; do bn=`basename $i`; echo "Checking for ${bn%.png}"; ack --no-mrml  "^[A-Za-z0-9]${bn%.png}"; done
for i in `ls -1 ~/Projects/Slicer4/Base/GUI/Tcl/ImageData/*.png`; do bn=`basename $i`; echo "Checking for ${bn%.png}"; ack --no-mrml  "^[A-Za-z0-9]${bn%.png}"; done

Using the one-liner ack --py "png", I found that the editor module was using the editor effect images from the
Tcl/ImageData folder. Only the effect used by the module have been kept
in the folder.

Revision 21327  Directory Listing
Modified Thu Nov 8 02:45:33 2012 UTC (4 years, 10 months ago) by jcfr
COMP: Remove unused *.tcl files from Base/Tcl

Also verified that non of these tcl modules were used in EMSegment using the
following one-liner:

cd /home/jchris/Projects/Slicer4-Superbuild-Debug/EMSegment
$ for i in `ls -1 ~/Projects/Slicer4/Base/GUI/Tcl/*.tcl`; do bn=`basename $i`; ack --no-mrml  "[^A-Za-z0-9]${bn%.tcl}"; done

See http://na-mic.org/Bug/view.php?id=2735

Fixes #2735

Revision 21323  Directory Listing
Modified Wed Nov 7 21:30:10 2012 UTC (4 years, 10 months ago) by jcfr
BUG: Simplify mechanism to ignore settings (options --testing and --disable-settings)

This commit ensure that the method instantiateSettings is called once after
the argument are parsed.

Doing so allows to avoid the following issues:

1) Settings application name after the method instantiateSettings was called
wasn't affecting the already instantiated object.

2) Side effect of (1) was the deletion of the original "Slicer.ini" settings
file

3) Creating a QSettings using the constructor taking filename as a parameter
is NOT updating the convenience QSettings singleton.


Note also that the method qSlicerCoreApplication::handlePreApplicationCommandLineArguments
is not called anymore by "qSlicerCoreApplicationPrivate::parseArguments"
but is called directly after all core objects have been instantiated.

See http://www.na-mic.org/Bug/view.php?id=2719

Fixes #2719

Revision 21302  Directory Listing
Modified Fri Nov 2 15:19:15 2012 UTC (4 years, 10 months ago) by jcfr
STYLE: Fix indent in CMakeLists.txt

Revision 21297  Directory Listing
Modified Wed Oct 31 20:42:02 2012 UTC (4 years, 10 months ago) by jcfr
BUG: Extension manager dialog default size is based on Slicer application size

See http://www.na-mic.org/Bug/view.php?id=2331

Partial fixes for #2331

Revision 21288  Directory Listing
Modified Tue Oct 30 22:47:19 2012 UTC (4 years, 10 months ago) by alexy
BUG 2707. If the scene root directory does not exist set it to current dir.

Revision 21276  Directory Listing
Modified Mon Oct 29 23:35:06 2012 UTC (4 years, 10 months ago) by jcfr
BUG: Make sure terminal output associated with generic test is enabled

When building Slicer without Slicer_BUILD_WIN32_CONSOLE enabled, terminal outputs
are disabled and ctkErrorLogFDMessageHandler is not registered.
See http://slicer.cdash.org/testDetails.php?test=3076851&build=45360

This will have to be revisited since ctkErrorLogFDMessageHandler should
also be registered. Given the fact Slicer 4.2 will be released very soon,
qSlicerCoreApplication won't be changed.

See http://www.na-mic.org/Bug/view.php?id=2349

Fixes #2349

Revision 21237  Directory Listing
Modified Wed Oct 24 14:57:46 2012 UTC (4 years, 11 months ago) by jcfr
ENH: Print warnings if python libraries of non embedded loadable module failed to load

Revision 21211  Directory Listing
Modified Thu Oct 18 19:10:01 2012 UTC (4 years, 11 months ago) by jcfr
BUG: Display "Usage" and "Options" when using installed MacOSX Slicer executable

See http://www.na-mic.org/Bug/view.php?id=2376

Fixes #2376

Revision 21208  Directory Listing
Modified Wed Oct 17 22:48:19 2012 UTC (4 years, 11 months ago) by jcfr
BUG: Ensure __file__ attribute is defined when running python script

See http://www.na-mic.org/Bug/view.php?id=2649

Fixes #2649

Revision 21203  Directory Listing
Modified Wed Oct 17 16:21:58 2012 UTC (4 years, 11 months ago) by jcfr
ENH: Move initialization function from Main.cxx to qSlicerApplicationHelper

The idea is to promote re-use of the initialization function and avoid
code duplication.

Revision 21200  Directory Listing
Modified Tue Oct 16 19:39:23 2012 UTC (4 years, 11 months ago) by jcfr
BUG: Fix windows assert associated with extension tests

To ensure existing tests pass, the Cxx folder has been added to the list
of sub dirs to consider when looking up IntDir.

That said, the recommended solution is to set the target property
RUNTIME_OUTPUT_DIRECTORY for the test executable. The value of this property
should be ${CMAKE_BINARY_DIR}/${Slicer_BIN_DIR}

See http://na-mic.org/Mantis/view.php?id=2348

Fixes #2348

Revision 21193  Directory Listing
Modified Mon Oct 15 22:54:26 2012 UTC (4 years, 11 months ago) by sankhesh
BUG: 2609 Case-insensitive alphabetical insertion of modules in menu

Revision 21190  Directory Listing
Modified Mon Oct 15 20:23:04 2012 UTC (4 years, 11 months ago) by jcfr
BUG: Check for invalid filepath in GetModuleHomeDirectory

See http://www.na-mic.org/Bug/view.php?id=2641

Fixes #2461

Revision 21169  Directory Listing
Modified Fri Oct 12 20:52:53 2012 UTC (4 years, 11 months ago) by jcfr
COMP: Export qSlicerBaseQTCLIPythonD library so that extensions can link it

See http://slicer-devel.65872.n3.nabble.com/Build-error-in-SlicerRT-extension-cannot-open-input-file-qSlicerBaseQTCLIPythonD-lib-tc4026390.html

Thanks to Csaba for reporting the issue.

Revision 21164  Directory Listing
Modified Fri Oct 12 16:00:26 2012 UTC (4 years, 11 months ago) by sankhesh
ENH: 2532 Start with a new settings file

Delete the old testing settings file and creates a new one for current
testing.

Revision 21137  Directory Listing
Modified Tue Oct 9 05:04:33 2012 UTC (4 years, 11 months ago) by finetjul
STYLE: Volume logic CreateLabelVolume should not add node to scene

Only CreateAndAddLabelVolume() can add a node to the scene.
Closes #2626

Revision 21125  Directory Listing
Modified Sat Oct 6 22:11:47 2012 UTC (4 years, 11 months ago) by pieper
ENH: add additional extensions to support .zip and .xar files

Allow any .zip file to be loaded if it contains for a *.mrml file.

.xar files are generated by xnat, but are just a zip file.

Revision 21123  Directory Listing
Modified Sat Oct 6 13:11:05 2012 UTC (4 years, 11 months ago) by alexy
BUG 2546. Don't save storable nodes in the Main Scene View since they either in the main scene or are deleted on purpose.

Revision 21115  Directory Listing
Modified Fri Oct 5 16:26:48 2012 UTC (4 years, 11 months ago) by naucoin
STYLE: flag the Loading and Uninstantiating module print outs via the verbose module discovery flag rather than the testing one

Revision 21110  Directory Listing
Modified Thu Oct 4 21:23:01 2012 UTC (4 years, 11 months ago) by naucoin
STYLE: don't print out loading module debugging statement during testing as it can cause dashboard output to be truncated before the extension test output is shown

Revision 21101  Directory Listing
Modified Wed Oct 3 20:48:01 2012 UTC (4 years, 11 months ago) by jcfr
ENH: Simplify vtkMRMLCommandLineModuleNode API

* SetParameterAs* methods now return a boolean to indicate if the call was
successful

* Now python wrapping support std::string, remove duplicated methods

Revision 21098  Directory Listing
Modified Wed Oct 3 16:24:57 2012 UTC (4 years, 11 months ago) by jcfr
BUG: Ensure command line module parameter are saved to the scene

See http://na-mic.org/Mantis/view.php?id=2604

Fixes #2604

Revision 21097  Directory Listing
Modified Wed Oct 3 16:24:06 2012 UTC (4 years, 11 months ago) by jcfr
STYLE: Split declaration from definition, document code

See #2600 / http://na-mic.org/Mantis/view.php?id=2600

Revision 21083  Directory Listing
Modified Sun Sep 30 05:25:06 2012 UTC (4 years, 11 months ago) by finetjul
BUG: Don't sort files in Add Data dialog by default

Closes #1816

Revision 21075  Directory Listing
Modified Fri Sep 28 22:11:19 2012 UTC (4 years, 11 months ago) by jcfr
BUG: Ensure "slicer.module{mrml, logic, widget}" are populated for MacOSX extensions

Also revert commit r20784 which wasn't solving the root cause of the
problem. Additional invalid python paths were added.

Commit r20852 should also probably be reverted, more investigation will
be required to confirm that hypothesis.

See http://na-mic.org/Mantis/view.php?id=2358

Fixes #2358

Revision 21066  Directory Listing
Modified Thu Sep 27 04:13:55 2012 UTC (4 years, 11 months ago) by jcfr
BUG: "additional-module-path" command line option is a string not a stringlist

Revision 21064  Directory Listing
Modified Thu Sep 27 03:09:35 2012 UTC (4 years, 11 months ago) by finetjul
BUG: Crash when module fails to be instantiated

Regression due to r21059

Revision 21059  Directory Listing
Modified Wed Sep 26 19:05:39 2012 UTC (4 years, 11 months ago) by jcfr
ENH: Add method allowing to get list of module dependees

See #2251 / http://www.na-mic.org/Bug/view.php?id=2251

Revision 21058  Directory Listing
Modified Wed Sep 26 19:05:37 2012 UTC (4 years, 11 months ago) by jcfr
BUG: Ensure that dependency of explicit modules are also instantiated

Note that the module settings panel does NOT yet allow to differentiate
between module that have been ignored, failed to load or not specified in
the explicit list.

See #2251 / http://www.na-mic.org/Bug/view.php?id=2251

Revision 21054  Directory Listing
Modified Wed Sep 26 17:03:02 2012 UTC (4 years, 11 months ago) by jcfr
COMP: Simplify how dependencies in generic Cxx module tests are handled

Based on suggestion of Julien Finet

See #2251 / http://www.na-mic.org/Bug/view.php?id=2251

Revision 21052  Directory Listing
Modified Wed Sep 26 14:25:02 2012 UTC (5 years ago) by jcfr
COMP: Ensure QTApp library can use Module/Core headers

See #2251 / http://www.na-mic.org/Bug/view.php?id=2251

Revision 21046  Directory Listing
Modified Tue Sep 25 22:20:26 2012 UTC (5 years ago) by jcfr
BUG: Update module cxx generic test to load dependent modules

See http://www.na-mic.org/Bug/view.php?id=2251

Fixes #2251

Revision 21045  Directory Listing
Modified Tue Sep 25 22:20:23 2012 UTC (5 years ago) by jcfr
ENH: Factor code allowing to setup factory manager into library SlicerBaseQTApp

See http://www.na-mic.org/Bug/view.php?id=2251

Partial fix for #2251

Revision 21044  Directory Listing
Modified Tue Sep 25 22:20:20 2012 UTC (5 years ago) by jcfr
ENH: Add concept of "explicitModules" to module factory manager

This new option allows to specify an explicit list of modules to
register/instantiate/load. All other discovered modules won't be loaded.

See http://www.na-mic.org/Bug/view.php?id=2251

Partial fix for #2251

Revision 21041  Directory Listing
Modified Tue Sep 25 22:20:14 2012 UTC (5 years ago) by jcfr
BUG: Ensure python error are considered when running cxx generic tests

See http://www.na-mic.org/Bug/view.php?id=2542

Fixes #2542

Revision 21040  Directory Listing
Modified Tue Sep 25 22:20:12 2012 UTC (5 years ago) by jcfr
COMP: Remove unused / extra translation files

Revision 21039  Directory Listing
Modified Tue Sep 25 04:09:17 2012 UTC (5 years ago) by finetjul
COMP: Fix extension manager to compile with Slicer_USE_PYTHONQT OFF

Revision 21026  Directory Listing
Modified Fri Sep 21 15:47:07 2012 UTC (5 years ago) by christopher.mullins
BUG: Slicer extension install path missing '/' character.

See http://na-mic.org/Mantis/view.php?id=2358

Partial fix #2358

Revision 21018  Directory Listing
Modified Thu Sep 20 13:46:17 2012 UTC (5 years ago) by jcfr
BUG: Fix MacOSX startup crash related to ExtensionsModelManager

Calling "q->setExtensionsInstallPath()" expects the model to be
instantiated.

Fixes issue introduced by commit r20996

See http://na-mic.org/Mantis/view.php?id=2358

Partial fix to #2358

Revision 21017  Directory Listing
Modified Thu Sep 20 02:27:06 2012 UTC (5 years ago) by finetjul
BUG: Crash if timeout when downloading extension

Revision 21001  Directory Listing
Modified Wed Sep 19 00:47:34 2012 UTC (5 years ago) by mccormic
STYLE: Fix class doxygen doc in MRML/Core.

Also MRML/CLI.  Also fix spelling/grammatical errors etc.

This ensure the class documentation is associated by doxygen and shows
up in the output HTML.

Revision 20996  Directory Listing
Modified Mon Sep 17 20:52:23 2012 UTC (5 years ago) by christopher.mullins
BUG: Extensions directory is not created on Macs.

See http://na-mic.org/Mantis/view.php?id=2358

Partial fix to #2358

Revision 20976  Directory Listing
Modified Wed Sep 12 18:59:54 2012 UTC (5 years ago) by naucoin
BUG: fix missing index in color file

Revision 20974  Directory Listing
Modified Wed Sep 12 15:38:47 2012 UTC (5 years ago) by pieper
BUG: fix crash when bringing up save dialog

The mrml scene is not a storable node - maybe other objects
aren't either.

Revision 20973  Directory Listing
Modified Wed Sep 12 13:09:22 2012 UTC (5 years ago) by finetjul
ENH: Expose qSlicerCoreIOManager::saveNodes to python

Ease the use of writers by automatically creating storage node if needed.

Revision 20971  Directory Listing
Modified Tue Sep 11 19:58:59 2012 UTC (5 years ago) by pieper
BUG: be sure to mark the scene as in Batch mode during import

Otherwise displayable managers may respond to node events when
scene has incorrect IDs.

Revision 20962  Directory Listing
Modified Mon Sep 10 22:42:32 2012 UTC (5 years ago) by pieper
ENH: add option to preserve intermediate CLI data directories

Useful for testing and debugging

Revision 20953  Directory Listing
Modified Fri Sep 7 16:33:02 2012 UTC (5 years ago) by naucoin
BUG: issue 2030 unifty how screen shots are taken, using the ctk::grabVTKWidget and passing QImages to the scene writer. Fixes white background screen shots in saving mrml and mrb

Revision 20917  Directory Listing
Modified Mon Sep 3 21:11:11 2012 UTC (5 years ago) by pieper
ENH: expand array method to support multivolumes

Revision 20915  Directory Listing
Modified Mon Sep 3 15:58:16 2012 UTC (5 years ago) by jcfr
BUG: In slicer/util.py, update python method "loadScene" to use loadNodeFromFile

See http://www.na-mic.org/Bug/view.php?id=2441

Fixes #2441

Revision 20910  Directory Listing
Modified Fri Aug 31 22:35:41 2012 UTC (5 years ago) by finetjul
ENH: Add VTK demand driven pipeline to Model display nodes

Similar to what is done in the volume display nodes, it is now supported
to have a pipeline of VTK filters in the model display nodes.

Revision 20901  Directory Listing
Modified Fri Aug 31 16:15:48 2012 UTC (5 years ago) by pieper
ENH: add access to vector (rgb, rgba) volumes as numpy arrays

This way you can open a png file or series of files
and access or manipulate the pixels directly.

Revision 20893  Directory Listing
Modified Wed Aug 29 20:17:50 2012 UTC (5 years ago) by hjohnson
ENH: Added flag to PushToSlicer to allow overwriting of image nodes\n ENH: Added ability to push label volumes to Slicer MRML scene

Revision 20891  Directory Listing
Modified Wed Aug 29 15:24:44 2012 UTC (5 years ago) by naucoin
BUG: issue 2435 tweak left vs right wm color

Revision 20886  Directory Listing
Modified Tue Aug 28 13:02:49 2012 UTC (5 years ago) by pieper
BUG: avoid crash from pointer to deallocated std::string internals

The QString::toLatin1 method returns a QByteArray on the stack.
Using a pointer to the internals of this without saving a reference
ends up with a transient std::string that can go away before
you are done using it so we save a copy of the byte array inside
the scope.

I found this using the Guard Malloc tool in Xcode, which did crash
on this line.

Revision 20873  Directory Listing
Modified Mon Aug 27 19:30:36 2012 UTC (5 years ago) by pieper
BUG: database attribute did not need to be a QSharedPointer

As a shared pointer things worked until we try to change the
database directory with the directory button.  When doing this,
we get a message like the following and then a crash.
QSharedPointer: pointer 0x2384d70 already has reference counting

Making this a regular pointer seems to work, since the memory is
handled by the python code in the DICOM module.

Revision 20871  Directory Listing
Modified Mon Aug 27 18:54:10 2012 UTC (5 years ago) by naucoin
ENH: updated color file for brain atlas to fix issue 2435, with some updated colors from Marianna and Ron

Revision 20859  Directory Listing
Modified Fri Aug 24 17:44:04 2012 UTC (5 years, 1 month ago) by alexy
BUG 2229. Save data for storable nodes that are present in SceneViews but not in the main scene.

Revision 20852  Directory Listing
Modified Thu Aug 23 23:06:40 2012 UTC (5 years, 1 month ago) by jcfr
BUG: Ensure extension python paths are set on MacOSX

See http://www.na-mic.org/Bug/view.php?id=2391
and http://www.na-mic.org/Bug/view.php?id=2358

Fixes 2358#, #2391

Revision 20851  Directory Listing
Modified Thu Aug 23 23:03:10 2012 UTC (5 years, 1 month ago) by pieper
COMP: include ctkDICOMDatbase.h to avoid us of incomplete class

Although slicer can compile without this header included, there
are warnings about use of an incomplete class and this could
cause problems for Qt and PythonQt wrapping.

Unfortunately, with this header included there are multiply
defined symbols between dcmtk's osconfig.h and pyconfig.h
that will need to be sorted out.

Revision 20850  Directory Listing
Modified Thu Aug 23 23:03:05 2012 UTC (5 years, 1 month ago) by pieper
BUG: wrap references to DICOM classes in conditional compilation

Also remove include file ctkDICOMDatabase.h that caused
build errors on windows.

Revision 20846  Directory Listing
Modified Thu Aug 23 21:14:32 2012 UTC (5 years, 1 month ago) by jcfr
BUG: In extension manager, ensure scroll bar is always visible.

See http://www.na-mic.org/Bug/view.php?id=2333

Fixes #2333

Revision 20842  Directory Listing
Modified Thu Aug 23 19:05:23 2012 UTC (5 years, 1 month ago) by naucoin
BUG: issue 1951 the module description parser allows the string any rather than all to use subclasses of the scalar volume node

Revision 20831  Directory Listing
Modified Thu Aug 23 12:40:40 2012 UTC (5 years, 1 month ago) by pieper
ENH: add ctkDICOMDatabase holder to qSlicerCoreApplication per 2418

This allows the DICOM module to register it's configured instance
of the ctkDICOMDatabase so that other modules can make use of it.
The use case for this is for modules to insert new data in the
database and trigger updates in the GUI components of the module.

A more ideal solution would have been for the GUI to be responsive
to changes in the sqlite database itself so that modules could create
their own instances of ctkDICOMDatabase.  Unfortunately Qt's sqlite
driver does not pass on triggers via the notifications interface.

https://bugreports.qt-project.org/browse/QTBUG-10775

http://doc.qt.nokia.com/4.7-snapshot/qsqldriver.html#subscribeToNotification

Revision 20814  Directory Listing
Modified Wed Aug 22 03:43:16 2012 UTC (5 years, 1 month ago) by finetjul
BUG: One click activates items in color picker dialog

This makes it easier for the QtTesting to record actions.

Closes #2187

Revision 20808  Directory Listing
Modified Tue Aug 21 19:58:03 2012 UTC (5 years, 1 month ago) by Michael.jeulinl
BUG: Fix the download sample data module.

The bug was introduced by the previous commit on the IOFileType:
"ENH: Make the file type support mode more flexible"
8b3f66ff9aafc7d264a62f8df117f6d1919cb502

Revision 20805  Directory Listing
Modified Tue Aug 21 15:34:01 2012 UTC (5 years, 1 month ago) by Michael.jeulinl
ENH: Make the file type support mode more flexible

Remove the IOFileType enum and use instead a QString.

Revision 20797  Directory Listing
Modified Mon Aug 20 22:00:58 2012 UTC (5 years, 1 month ago) by millerjv
ENH: Added DoubleArray nodes as parameters in the GUI for CLI

Revision 20795  Directory Listing
Modified Mon Aug 20 22:00:48 2012 UTC (5 years, 1 month ago) by millerjv
ENH: removed debugging message

Revision 20784  Directory Listing
Modified Fri Aug 17 21:47:19 2012 UTC (5 years, 1 month ago) by christopher.mullins
BUG: Fixes loading of python bundled with an extension

See http://na-mic.org/Mantis/view.php?id=2391

Fixes #2391

Revision 20710  Directory Listing
Modified Sat Jul 28 08:02:53 2012 UTC (5 years, 1 month ago) by jcfr
BUG: Add option "additional-module-path" to ensure following argument are processed

See http://www.na-mic.org/Bug/view.php?id=2251

Fixes #2251

Revision 20709  Directory Listing
Modified Fri Jul 27 20:02:37 2012 UTC (5 years, 1 month ago) by jcfr
COMP: Fix unused variable warning related to addModule(Name)ToSlicerModule(Name)s

This warning was occurring when building Slicer with python support disabled.

Revision 20706  Directory Listing
Modified Fri Jul 27 17:08:59 2012 UTC (5 years, 2 months ago) by jcfr
ENH: More descriptive error message when CLI failed to execute.

The description have been copied and adapted from the help text
associated with the QProcess::ProcessError enum.

The discussion leading to this change is documented here:
See http://slicer-devel.65872.n3.nabble.com/Integrating-standalone-executables-as-CLI-td4025764.html

Revision 20699  Directory Listing
Modified Thu Jul 26 12:49:18 2012 UTC (5 years, 2 months ago) by christopher.mullins
ENH: Enables loading of data as command line argument(s).

If any unparsed argument is a path to a file, the IO Manager tries to load it.

TODO:  What should happen if a directory is passed in?
       Currently nothing happens.

See http://na-mic.org/Mantis/view.php?id=1594

Fixes #1594

Revision 20697  Directory Listing
Modified Thu Jul 26 08:14:45 2012 UTC (5 years, 2 months ago) by jcfr
BUG: Ensure generic module tests update "slicer.{modules, moduleNames}"

Fixes #2251 / See http://www.na-mic.org/Bug/view.php?id=2251

Revision 20696  Directory Listing
Modified Thu Jul 26 08:14:43 2012 UTC (5 years, 2 months ago) by jcfr
ENH: Add cpp function allowing to update "slicer.{modules, moduleNames}" modules

Also added corresponding test in "qSlicerLoadableModuleWithPythonTest"

See issue #2251 / http://www.na-mic.org/Bug/view.php?id=2251

Revision 20695  Directory Listing
Modified Thu Jul 26 08:14:41 2012 UTC (5 years, 2 months ago) by jcfr
ENH: "modules" and "moduleNames" module added to within slicer init file

Doing so ensure that by importing "slicer" module, these two modules
will be set.

Revision 20685  Directory Listing
Modified Wed Jul 25 07:27:52 2012 UTC (5 years, 2 months ago) by christopher.mullins
ENH: Adds 'Recently Loaded' File menu entry

This commit result from a collaborative work between Christopher Mullins
and Jean-Christophe Fillion-Robin.

See http://na-mic.org/Mantis/view.php?id=1669

Fixes #1669

Revision 20673  Directory Listing
Modified Tue Jul 24 10:20:03 2012 UTC (5 years, 2 months ago) by jcfr
COMP: Fix "unused-but-set-variable" warning in vtkImageErodeExecute

Revision 20670  Directory Listing
Modified Tue Jul 24 10:12:20 2012 UTC (5 years, 2 months ago) by jcfr
COMP: Fix "unused-but-set-variable" warning in vtkSlicerROILogic

Revision 20665  Directory Listing
Modified Tue Jul 24 07:39:53 2012 UTC (5 years, 2 months ago) by jcfr
COMP: Fix unused variable warnings

Revision 20660  Directory Listing
Modified Tue Jul 24 03:43:03 2012 UTC (5 years, 2 months ago) by jcfr
STYLE: Remove debug statements from qSlicerDataDialog

Revision 20602  Directory Listing
Modified Wed Jul 11 20:23:38 2012 UTC (5 years, 2 months ago) by jcfr
BUG: Register VTK PythonQt wrapper

See issue #2046 / http://www.na-mic.org/Bug/view.php?id=2046

Revision 20589  Directory Listing
Modified Fri Jul 6 22:28:52 2012 UTC (5 years, 2 months ago) by jcfr
COMP: Remove unused code

"createAction()" was a "left-over" from a previous refactoring.

See http://viewvc.slicer.org/viewvc.cgi/Slicer4?view=revision&revision=14375

Revision 20586  Directory Listing
Modified Fri Jul 6 17:38:31 2012 UTC (5 years, 2 months ago) by naucoin
BUG: respect the sorted order of fiducials in a hierarchy by using GetNthChildNode. Closes bug 1889

Revision 20584  Directory Listing
Modified Fri Jul 6 06:25:50 2012 UTC (5 years, 2 months ago) by jcfr
STYLE: Remove extra comments from Base/Python/CMakeLists.txt

Revision 20583  Directory Listing
Modified Fri Jul 6 04:55:16 2012 UTC (5 years, 2 months ago) by jcfr
BUG: Prevent Slicer freeze when network connection is slow

Setting the model associated with the extension manager dialog only when
it's needed prevents the webview associated with the qSlicerExtensionsInstallWidget
from loading the "extension server" page at startup time.

See http://www.na-mic.org/Bug/view.php?id=2181

Fixes #2181

Revision 20575  Directory Listing
Modified Thu Jul 5 20:48:43 2012 UTC (5 years, 2 months ago) by mccormic
COMP: Fix warning about unused cdUpRes.

Revision 20568  Directory Listing
Modified Wed Jul 4 21:31:47 2012 UTC (5 years, 2 months ago) by jcfr
ENH: Add loadLabelVolume() function to "util.py"

Thanks to "David Welch" for contributing this patch :)

Documenting what are the available properties would also be nice. Currently,
it's required to browse through the Cpp code to find out what are the name
of the different properties.

Would be nice to document them at one location, and have a pointer to it.

See http://www.na-mic.org/Bug/view.php?id=2268

Fixes #2268

Revision 20547  Directory Listing
Modified Mon Jul 2 21:47:43 2012 UTC (5 years, 2 months ago) by christopher.mullins
ENH: Remove home module from module toolbar.

Additionally, in Application settings, label "Home" has been renamed into
"Default startup module".

See http://na-mic.org/Mantis/view.php?id=2180

Fixes #2180

Revision 20517  Directory Listing
Modified Fri Jun 29 02:25:33 2012 UTC (5 years, 2 months ago) by finetjul
BUG: Save Data dialog - Complete file name with extension if missing

When changing the filename of a scene/node in the Save Data Dialog,
the user is supposed to press Enter or Return. If the lineeditor doesn't
disappear it's because the name is invalid (due to the QRegExpValidator)
however, the user can always click on a different entry or press tab.
In that case, the entry is validated, even if the file name doesn't
contain an extension.
Before the filename is transfered from the line edit to the underlying
model, the extension is added if not there yet.

Closes #1817, #2277

Revision 20514  Directory Listing
Modified Thu Jun 28 20:40:21 2012 UTC (5 years, 2 months ago) by benjamin.long
ENH: Internationalized Slicer

Added Internationalization setting panel to enable/disable this behavior.
Added language combo box into general setting panel if enabled.
Added function to load language when we start the application.

Revision 20492  Directory Listing
Modified Tue Jun 26 21:44:02 2012 UTC (5 years, 3 months ago) by finetjul
BUG: Save data dialog - Changing extension could truncate file name

If the name is "filename-0.1.vtk" and the extension is changed into "stl",
the result name should be "filename-0.1.stl"

Revision 20479  Directory Listing
Modified Mon Jun 25 13:46:04 2012 UTC (5 years, 3 months ago) by jcfr
BUG: Ensure intDir is properly computed

This fix a regression introduced by r20456

See http://www.na-mic.org/Bug/view.php?id=2248

Fixes #2248

Revision 20469  Directory Listing
Modified Fri Jun 22 18:08:31 2012 UTC (5 years, 3 months ago) by millerjv
ENH: simplified staging data by operating at a more abstract level.

Removed special case handling of many node types and operating at a more
abstract level.

Revision 20466  Directory Listing
Modified Fri Jun 22 18:08:15 2012 UTC (5 years, 3 months ago) by millerjv
ENH: adding more image types to node selectors, specifically to support DCE-MRI

Revision 20463  Directory Listing
Modified Fri Jun 22 15:32:04 2012 UTC (5 years, 3 months ago) by hjohnson
COMP: Remove deprecated functions from use

In ITKv4 the itkLegacyMacro allows deprecated
functions to be easily identified.  These functions
have been replaced with their modern equivalents.

Revision 20459  Directory Listing
Modified Fri Jun 22 15:24:51 2012 UTC (5 years, 3 months ago) by inorton
ENH: remove volume window/level control from tcl interactor

Revision 20456  Directory Listing
Modified Fri Jun 22 06:53:56 2012 UTC (5 years, 3 months ago) by jcfr
BUG: Ensure generic loadable module test compiled externally can be executed

There are two cases:
 1) Test compiled within Slicer build tree: located along with SlicerApp-real
 2) Test compiled outside of Slicer build tree

In the second case, when qSlicer(Core)Application is instantiated within
a test, the applicationDirPath resolved to the test executable itself.
The method "QCoreApplication::applicationDirPath" being used, it was NOT
returning the SlicerApp-real path.
This was causing problem and the SlicerBin could NOT be computed adequately:

1: ASSERT: "qSlicerUtils::pathEndsWith(this->SlicerBin, Slicer_BIN_DIR)" in file /Users/millerjv/Projects/Slicer4-git/Slicer4/Base/QTCore/qSlicerCoreApplication.cxx, line 414


The implemented solution attempts to compute the SlicerBin only if SLICER_HOME
hasn't been set. The launcher taking care of setting this environment
variable, test instantiating a qSlicer(Core)Application will work
as expected.

See http://www.na-mic.org/Bug/view.php?id=2248

Fixes #2248

Revision 20418  Directory Listing
Modified Wed Jun 20 14:43:26 2012 UTC (5 years, 3 months ago) by vrnova
BUGFIX: line 19 #include <QToolButton.h> failed compilation under Ubuntu 12.04. Changed to #include <QToolButton>

Revision 20409  Directory Listing
Modified Tue Jun 19 19:20:19 2012 UTC (5 years, 3 months ago) by finetjul
BUG: File command line parameter was represented via a QLineEdit

A ctkPathLineEdit is better to select files than a QLineEdit
Closes #2217

Revision 20393  Directory Listing
Modified Mon Jun 18 07:40:03 2012 UTC (5 years, 3 months ago) by jcfr
COMP: Slicer CLIs can now be built using SEMMacroBuildCLI macro

Revision 20379  Directory Listing
Modified Sat Jun 16 21:05:05 2012 UTC (5 years, 3 months ago) by finetjul
COMP: Fix unused variable warnings

Revision 20378  Directory Listing
Modified Sat Jun 16 21:05:03 2012 UTC (5 years, 3 months ago) by finetjul
COMP: Fix multiple inheritance compilation error with gcc

In file included from
/home/gsharp/build/slicer-4/Slicer4/Base/QTGUI/qSlicerFileDialog.cxx:32:0:
/home/gsharp/build/slicer-4/Slicer4/Base/QTGUI/qSlicerIOOptionsWidget.h: In
member function ‘qSlicerIOOptionsPrivate* qSlicerIOOptionsWidget::d_func()’:
/home/gsharp/build/slicer-4/Slicer4/Base/QTGUI/qSlicerIOOptionsWidget.h:52:3:
error: reference to ‘d_ptr’ is ambiguous

Revision 20375  Directory Listing
Modified Sat Jun 16 05:56:41 2012 UTC (5 years, 3 months ago) by finetjul
ENH: Add "Compress" option for saving MRML nodes

Some nodes might not support the "Compress" option.

Closes #986

Revision 20373  Directory Listing
Modified Fri Jun 15 17:12:17 2012 UTC (5 years, 3 months ago) by finetjul
BUG: Only select modified since read scene/nodes by default

Closes #1817

Revision 20372  Directory Listing
Modified Fri Jun 15 17:12:13 2012 UTC (5 years, 3 months ago) by finetjul
ENH: Add shortcut to save scene as MRB in Save Data dialog

Issue #2098

Revision 20371  Directory Listing
Modified Fri Jun 15 15:24:13 2012 UTC (5 years, 3 months ago) by finetjul
STYLE: Fix doxygen comments with \code \endcode blocks

Revision 20370  Directory Listing
Modified Thu Jun 14 22:03:55 2012 UTC (5 years, 3 months ago) by naucoin
STYLE: mark fiducial list classes as deprecated

Revision 20368  Directory Listing
Modified Thu Jun 14 21:26:00 2012 UTC (5 years, 3 months ago) by finetjul
COMP: Propagate obsolete SetModifiedSinceRead to Scripts

Issue #2082

Revision 20366  Directory Listing
Modified Thu Jun 14 20:11:59 2012 UTC (5 years, 3 months ago) by benjamin.long
STYLE: Moved slicerappdatapaths.py.in into SlicerApp/Testing/Python

Revision 20363  Directory Listing
Modified Thu Jun 14 18:04:13 2012 UTC (5 years, 3 months ago) by benjamin.long
BUG: Fix wrong path to slicerappdatapaths.py

Close #2194

Revision 20360  Directory Listing
Modified Thu Jun 14 16:15:20 2012 UTC (5 years, 3 months ago) by finetjul
ENH: Redesign ModifiedSinceRead

ModifiedSinceRead can no longer be set externally, it's the nodes themselves that computes it based on the last time the data was stored and on the modifications.
ModifiedSinceRead is no longer a vtkMRMLNode property but a vtkMRMLStorableNode property.
The storage nodes have been cleaned-up (factorized) in the process.
At exit time, the scene is checked to see if it has been modified or if its storable nodes have been modified since read/write.

Some other changes:
Removed vtkMRMLModelNode::GetDefaultWriteFileExtension() it is a duplicate from vtkMRMLModelStorageNdoe::GetDefaultWriteFileExtension()
Removed vtkMRMLColorNode::AddColorName() as it is not used and increase code complexity
Removed vtkMRMLAnnotation*StorageNode::WriteData(vtkMRMLNode* refNode) as it was doing the same than vtkMRMLAnnotationStorageNode::WriteData(vtkMRMLNode* refNode)

Remaining issues:
The check on the modified scene is not perfect and can be fine tuned.
The loading of annotations are marking the nodes as ModifiedSinceRead but it shouldn't.
The loading of a vtkMRMLVolumePropertyNode from within a scene load incorrectly marks the node as ModifiedSinceRead

Revision 20357  Directory Listing
Modified Wed Jun 13 23:32:47 2012 UTC (5 years, 3 months ago) by finetjul
STYLE: Rename "Add DICOM" menu entry into "DICOM"

Closes #1740

Revision 20354  Directory Listing
Modified Wed Jun 13 22:26:08 2012 UTC (5 years, 3 months ago) by benjamin.long
BUG: Move ApplicationSlicerAppData.py into Base/Python/slicer/slicerappdatapaths.py

Close #2194

Revision 20335  Directory Listing
Modified Fri Jun 8 06:48:20 2012 UTC (5 years, 3 months ago) by finetjul
ENH: Save Data dialog now selects default extension if any

Closes #1817

Revision 20333  Directory Listing
Modified Fri Jun 8 04:51:13 2012 UTC (5 years, 3 months ago) by finetjul
ENH: Add option to save scene as Data Bundle in Save Data dialog

+ minor bugs due to previous commits
Closes #2097

Revision 20332  Directory Listing
Modified Fri Jun 8 00:10:55 2012 UTC (5 years, 3 months ago) by finetjul
ENH: Reorder the Save Data columns

Issue #2098

Revision 20331  Directory Listing
Modified Thu Jun 7 20:14:10 2012 UTC (5 years, 3 months ago) by finetjul
ENH: SaveData dialog uses qSlicerFileWriters for improved scalability

Custom file writers can easily be added for each node or scene.
Options specific to scene/nodes could easily be added via the qSlicerFileWriters::options

Issue #2098

Revision 20330  Directory Listing
Modified Thu Jun 7 20:04:51 2012 UTC (5 years, 3 months ago) by finetjul
ENH: Split qSlicerIO into qSlicerFileReader

qSlicerFileReader is too different from qSlicerFileWriter to have their methods shared in qSlicerIO.
Add qSlicerNodeWriter, a utility class to simplify file writers

Revision 20321  Directory Listing
Modified Mon Jun 4 20:19:29 2012 UTC (5 years, 3 months ago) by benjamin.long
BUG: Instance TestingUtilily wasn't released when slicer was closing

Revision 20317  Directory Listing
Modified Mon Jun 4 15:34:18 2012 UTC (5 years, 3 months ago) by finetjul
BUG: Disable Colors module GUI

Issue #2141

Revision 20303  Directory Listing
Modified Fri Jun 1 03:11:11 2012 UTC (5 years, 3 months ago) by jcfr
BUG: Consider extension support libraries installed in either lib/Slicer-X.Y or bin

See http://www.na-mic.org/Bug/view.php?id=2148

Closes #2148

Revision 20301  Directory Listing
Modified Fri Jun 1 01:01:34 2012 UTC (5 years, 3 months ago) by jcfr
BUG: Show progress while extensions manager web page are loading.

See http://www.na-mic.org/Bug/view.php?id=2133

Revision 20296  Directory Listing
Modified Thu May 31 23:13:55 2012 UTC (5 years, 3 months ago) by jcfr
BUG: Fail to install extension if associated settings file are read-only

Installing an extension will fail if either Slicer settings or the launcher
settings are not readable and writable, a warning message will be displayed
to the user.

See http://www.na-mic.org/Bug/view.php?id=2144

Closes #2144

Revision 20290  Directory Listing
Modified Wed May 30 16:13:53 2012 UTC (5 years, 3 months ago) by finetjul
BUG: Fix sizing issue in Tractography Fiducial Seeding module

Also remove unnecessary margin around stack widget.
Closes #2093

Revision 20278  Directory Listing
Modified Tue May 29 05:36:25 2012 UTC (5 years, 3 months ago) by jcfr
ENH: Describe actions of extension manager widget by adding tooltip

Uninstall: Tell the application to uninstall this extension
           when it will restart.

Cancel Uninstall: Tell the application to keep this extension installed.

Disable: Tell the application to skip loading of this extension
         by removing all associated module paths from the
         application settings.

Enable: Tell the application to load this extension by adding
        all associated module paths to the application settings.

See http://www.na-mic.org/Bug/view.php?id=1945

Closes #1945

Revision 20272  Directory Listing
Modified Mon May 28 21:52:09 2012 UTC (5 years, 3 months ago) by jcfr
BUG: Fix extension bundling and simplify mechanism used to specify the main application

1) In Applications/SlicerApp/CMakeLists.txt:

  Improve comment explaining what should be considered when adding an other
application into Applications folder.

  Given the fact Slicer_APPLICATION_NAME is used locally, minimize confusion
by renaming variable renaming it into SlicerApp_APPLICATION_NAME.

  In case the application being configured is the *Main* application,
explicitly compare "PROJECT_NAME" with "Slicer_MAIN_PROJECT".


2) Rename variable Slicer_APPLICATION_NAME used to identified the main
application into Slicer_MAIN_PROJECT_APPLICATION_NAME. This will
minimize confusion and help maintaining the code.

3) Let's note that the mechanism used to fixup application should probably
be extended to account for other application build in the Applications folder.

4) In top-level CMakeLists, move code specific to main application description
into its own section.

5) Configure variable "Slicer_MAIN_PROJECT" and "Slicer_MAIN_PROJECT_APPLICATION_NAME"
into SlicerConfig so that "SlicerExtensionCPackBundleFixup" could successfully
refer to Slicer_MAIN_PROJECT_APPLICATION_NAME. This closes #2130

See http://www.na-mic.org/Bug/view.php?id=2130

Revision 20158  Directory Listing
Modified Fri May 25 21:34:54 2012 UTC (5 years, 4 months ago) by jcfr
BUG: Incompatible extensions are disabled when Slicer starts

An extension is considered incompatible when the version of Slicer used
to build the extension is different from the version of Slicer attempting
to load the extension.

ExtensionsManagerModel API now includes the following functions:
  isExtensionCompatible
  identifyIncompatibleExtensions
and also the signal:
  extensionIdentifedAsIncompatible

The extensions manager widget will show which extension are incompatible
by displaying a message of the form:
 "Incompatible with Slicer rXXXX (build for rYYYYY)"

See http://www.na-mic.org/Bug/view.php?id=2088

Closes #2088

Revision 20157  Directory Listing
Modified Fri May 25 21:34:51 2012 UTC (5 years, 4 months ago) by jcfr
BUG: Disabling extension now works as expected.

See http://www.na-mic.org/Bug/view.php?id=2107

Closes 2107

Revision 20156  Directory Listing
Modified Fri May 25 21:34:49 2012 UTC (5 years, 4 months ago) by jcfr
BUG: Un-install extensions after Slicer restarts.

Extensions are now scheduled to be un-installed. When doing so the extension name
will be added to list in the settings identified by "Extensions/ScheduledForUninstall"
and the extensions will be effectively uninstalled when Slicer restarts.

User has also the possibility to cancel the extension scheduled for uninstall.

Note that the uninstall mechanism does NOT yet account for extension dependencies.

See http://www.na-mic.org/Bug/view.php?id=1906

Closes #1906

Revision 20155  Directory Listing
Modified Fri May 25 20:25:45 2012 UTC (5 years, 4 months ago) by Michael.jeulinl
ENH: Provide a mechanism to build several applications

Configure the applications and packaging with
two variables to configure the build:
- Slicer_MAIN_PROJECT # main project
- ${Slicer_MAIN_PROJECT}_APPLICATION_NAME # application name

Make the packaging given the main application name.

Revision 20154  Directory Listing
Modified Fri May 25 14:13:20 2012 UTC (5 years, 4 months ago) by demian
ENH: Improved efficiency of the CLI modules receiving DWI images by using uncompressed images for the input by default (Steve Pieper's idea and most of its execution)

Revision 20143  Directory Listing
Modified Wed May 23 04:30:36 2012 UTC (5 years, 4 months ago) by finetjul
BUG: Save Data dialog: Apply directory to selected items on accept

Even if the directory didn't change, accepting the browse dialog shall apply the directory to all selected items.

Closes #1825, #1866

Revision 20142  Directory Listing
Modified Wed May 23 04:30:34 2012 UTC (5 years, 4 months ago) by finetjul
ENH: Save Data dialog: Move Change Diretory for all selected in button box

It saves screen real estate to move the button in the dialog button box
Change the text of the directory button as the directory path is not important.

Issue #2098

Revision 20139  Directory Listing
Modified Tue May 22 19:13:34 2012 UTC (5 years, 4 months ago) by benjamin.long
STYLE: Rename funtion, restore old behavior to open Dialog

Restore old behavior for qSlicerIOManager::openDialog()
Renamed funciton to set dialog default name.
  getUniqueDialogName --> createUniqueDialogName

Close #1733

Revision 20136  Directory Listing
Modified Tue May 22 15:23:13 2012 UTC (5 years, 4 months ago) by benjamin.long
ENH: Added functionality to set automatically unique name to dialog.

Revision 20135  Directory Listing
Modified Mon May 21 22:39:34 2012 UTC (5 years, 4 months ago) by finetjul
ENH: Add loading options to MRML Scene file

Option to clear the scene (equivalent to Load Scene) or not (equivalent to Import).
If the scene is imported, then the option Copy Cameras (enabled by default) copy the properties of the scene-to-import camera nodes into the existing nodes with the same name.
Move qSlicerSceneIO into the Data module to add an OptionsWidget to control the options.

Closes #1952

Revision 20133  Directory Listing
Modified Mon May 21 19:20:49 2012 UTC (5 years, 4 months ago) by christopher.mullins
ENH: Adds ability to dynamically change python shell font size/family

See http://www.na-mic.org/Bug/view.php?id=1829

Closes #1829

Revision 20129  Directory Listing
Modified Mon May 21 02:56:35 2012 UTC (5 years, 4 months ago) by finetjul
STYLE: Add comments to the slicer icon engine

Revision 20121  Directory Listing
Modified Sun May 20 04:49:34 2012 UTC (5 years, 4 months ago) by finetjul
ENH: Enlarge Modules list in Modules Settings panel

Issue #1870

Revision 20120  Directory Listing
Modified Sun May 20 04:33:11 2012 UTC (5 years, 4 months ago) by finetjul
ENH: Open Extension Manager dialog from Extensions settings panel

Issue #1870

Revision 20118  Directory Listing
Modified Sat May 19 06:34:26 2012 UTC (5 years, 4 months ago) by finetjul
STYLE: Rename settings panel titles, and Favorite Modules toolbar

Issue #1870

Revision 20117  Directory Listing
Modified Sat May 19 06:11:11 2012 UTC (5 years, 4 months ago) by finetjul
STYLE: Simplify RestartRequested use in Settings panel

Adds asterisk when panel is modified.
Issue #1870

Revision 20116  Directory Listing
Modified Sat May 19 05:52:32 2012 UTC (5 years, 4 months ago) by finetjul
ENH: Display font size in Font settings panel button

Issue #1870

Revision 20115  Directory Listing
Modified Fri May 18 18:40:31 2012 UTC (5 years, 4 months ago) by jcfr
ENH: Show download progress when installing extension.

See http://www.na-mic.org/Bug/view.php?id=1905

Closes #1905

Revision 20112  Directory Listing
Modified Fri May 18 05:34:45 2012 UTC (5 years, 4 months ago) by finetjul
BUG: Don't ask for scene overwrite if not needed

If the scene item is unchecked, that means the scene is not saved.
So even if the scene file already exists, don't show a dialog asking to the
user if it's ok to overwrite.
Make sure in that case that the scene RootDirectory is restored.
Closes #2010

Revision 20083  Directory Listing
Modified Wed May 16 02:46:37 2012 UTC (5 years, 4 months ago) by jcfr
BUG: Fix testExtractExtensionArchive setting copied resource permissions. Fixes #1944

On windows, in the case of resources, they are read-only and when
copied to the filesystem these permissions are propagated. See [1]

We just need to make sure the copied file is both readable and writable.

Also exclude test associated to "readlonly" directory on windows platform.
More work is required to find out why it fails to check the permissions of
the directory.

[1] https://bugreports.qt-project.org/browse/QTBUG-5401

Revision 20079  Directory Listing
Modified Tue May 15 13:04:11 2012 UTC (5 years, 4 months ago) by joe.snyder
ENH: Improve Data Dialog Usability

Removed the word-wrap option on the data dialog to eliminate the end of
imported file being included in the ellipsis.

Revision 20078  Directory Listing
Modified Tue May 15 03:41:25 2012 UTC (5 years, 4 months ago) by jcfr
ENH: Display message associated with extension manager install widget. Fixes #1944

Error happening while installing an extension are now displayed with the
webpage using the midas "createNotice" function.

See http://na-mic.org/Mantis/view.php?id=1944

Revision 20071  Directory Listing
Modified Sat May 12 04:53:08 2012 UTC (5 years, 4 months ago) by jcfr
BUG: Ensure permissions are checked in "extractExtensionArchive()" when using NTFS. Fixes #1944

From QFile documentation:

  Note that Qt does not by default check for permissions on NTFS file
  systems, as this may decrease the performance of file handling
  considerably.

  It is possible to force permission checking on NTFS by using
  qt_ntfs_permission_lookup ... see [1]

Since both QFile::permission and QFileInfo use QFileEngineFS under the hood,
it means using 'qt_ntfs_permission_lookup' is required in both case.

Note that using QFileInfo instead of QFile just simplify the syntax.

For reference: http://www.na-mic.org/Bug/view.php?id=1944

[1] http://doc.qt.nokia.com/4.7-snapshot/qfile.html#Permission-enum

Revision 20060  Directory Listing
Modified Thu May 10 17:02:37 2012 UTC (5 years, 4 months ago) by pieper
COMP: remove conditional compilation of LibArchive code

Since archives are now used in slicer data bundles there
is no reason to build slicer without libarchive - it is
a core requirement.

Revision 20048  Directory Listing
Modified Wed May 9 22:14:39 2012 UTC (5 years, 4 months ago) by jcfr
BUG: Gracefully fail if user try to install extension in non readable/writable/executable directory. Fixes #1944

Also updated associated unit test. Cases when directory is "non writable" or
is "non existent" are both tested.

See http://www.na-mic.org/Bug/view.php?id=1944

Revision 20042  Directory Listing
Modified Wed May 9 06:12:50 2012 UTC (5 years, 4 months ago) by jcfr
STYLE: Return error as boolean instead of integer in "bool qSlicerModuleFactoryManager::loadModule"

Revision 20041  Directory Listing
Modified Wed May 9 06:12:48 2012 UTC (5 years, 4 months ago) by jcfr
ENH: Expose to python "modulesNames" function associated with qSlicerModuleManager and qSlicerModuleFactoryManager

This could reveal to be useful when debugging.

Revision 20040  Directory Listing
Modified Wed May 9 06:12:46 2012 UTC (5 years, 4 months ago) by jcfr
BUG: Ensure state of modules listed in Module panel is appropriately updated. Fixes #1955

Since by default the QStandardItemModel::match does a "Qt::MatchStartsWith | Qt::MatchWrap",
the module updated could be different from the expected module.

See http://www.na-mic.org/Bug/view.php?id=1955

Revision 20039  Directory Listing
Modified Tue May 8 20:35:44 2012 UTC (5 years, 4 months ago) by Michael.jeulinl
ENH: Conditionally build the LibArchive associated with vtkMRMLApplicationLogic

The MRML_USE_LibArchive option depends on
Slicer_BUILD_EXTENSIONMANAGER_SUPPORT.

Revision 20036  Directory Listing
Modified Tue May 8 18:32:42 2012 UTC (5 years, 4 months ago) by jcfr
ENH: Remember extension catalog login implementing cookies persistence. Fixes #1946

See http://www.na-mic.org/Bug/view.php?id=1946

Revision 20013  Directory Listing
Modified Fri May 4 15:50:00 2012 UTC (5 years, 4 months ago) by pieper
BUG: avoid colons in filenames for windows

Explicitly specify the date format for the temp file
since ISODate includes a colon and that is not valid
on windows.

Revision 20010  Directory Listing
Modified Fri May 4 00:10:30 2012 UTC (5 years, 4 months ago) by pieper
ENH: added zip/unzip tests (1962, 1963)

Revision 20008  Directory Listing
Modified Fri May 4 00:06:41 2012 UTC (5 years, 4 months ago) by pieper
COMP: enable libarchive even if extensions not enabled

The library is now used by the core data bundle code as
well as the extensions so it should not be conditional.

Revision 20005  Directory Listing
Modified Fri May 4 00:06:35 2012 UTC (5 years, 4 months ago) by pieper
ENH: add scene bundle load option

Integrates with file dialog structure for loading or
importing

Revision 19998  Directory Listing
Modified Fri May 4 00:06:19 2012 UTC (5 years, 4 months ago) by pieper
COMP: move vtkArchive to Libs/MRML/Logic

From here it can be used in MRMLApplicationLogic for
slicer data bundles

Revision 19997  Directory Listing
Modified Fri May 4 00:06:16 2012 UTC (5 years, 4 months ago) by pieper
STYLE: remove reference to cmake in file

Use vtkArchiveTools rather than cmSystemTools for
local class.

Revision 19990  Directory Listing
Modified Thu May 3 17:49:49 2012 UTC (5 years, 4 months ago) by naucoin
ENH: make the fiducial annotation the default when it gets added

Revision 19989  Directory Listing
Modified Thu May 3 17:17:14 2012 UTC (5 years, 4 months ago) by naucoin
ENH: bug 1593, take out the view transform mode action, update the test

Revision 19987  Directory Listing
Modified Thu May 3 04:23:09 2012 UTC (5 years, 4 months ago) by jcfr
COMP: Fix unused variable warning in qSlicerSettingsQtTestingPanel

Revision 19985  Directory Listing
Modified Thu May 3 01:05:04 2012 UTC (5 years, 4 months ago) by finetjul
COMP: Fix compilation warnings and typo

* unused variable
* signed vs unsigned comparison
* old copy paste settings label

Closes #1970

Revision 19975  Directory Listing
Modified Wed May 2 01:04:45 2012 UTC (5 years, 4 months ago) by finetjul
ENH: Add option in settings to enable QtTesting. Off by default

Revision 19972  Directory Listing
Modified Tue May 1 00:11:16 2012 UTC (5 years, 4 months ago) by jcfr
BUG: Make sure more than one PythonQt module could be loaded in a given directory.

In case the regular expression doesn't match, the other filename should
be considered.

This is a follow up of r19695

Revision 19960  Directory Listing
Modified Mon Apr 30 23:11:25 2012 UTC (5 years, 4 months ago) by benjamin.long
BUG: Fix set annotationID in qSlicerMouseModeToolBar.

As long as, annotationID is set in action.setData(), to recover the
good annotationID, we need to call the function data() instead of
text().

Revision 19959  Directory Listing
Modified Mon Apr 30 23:11:21 2012 UTC (5 years, 4 months ago) by benjamin.long
ENH: Add Qt Testing support

Expose signals/slots on some widget APIs for qttesting recording/replay

Revision 19958  Directory Listing
Modified Mon Apr 30 21:40:57 2012 UTC (5 years, 4 months ago) by Michael.jeulinl
ENH: Rename Slicer application classes

- Use to make distinction between inner and outer files.
- Make it more generic to be able to derive SlicerApp.
- Decouple resource usage between core and application.

Revision 19956  Directory Listing
Modified Mon Apr 30 21:31:34 2012 UTC (5 years, 4 months ago) by millerjv
BUG: Configure Slicer to use system proxy settings

Extension manager did not work behind a firewall. Added call
to QNetworkProxyFactory::setUseSystemConfiguration(true) so
the system level proxy is honored by Slicer.

This fixes the Extension manager for Jim.

Interestingly, it also keeps the Sample Data download from
crashing my Slicer.  But it still does not download the data.

Revision 19949  Directory Listing
Modified Thu Apr 26 22:51:27 2012 UTC (5 years, 5 months ago) by jcfr
COMP: Prevent confusion by consistently using platform as concatenation of "Os" and "architecture". See #1204

* Rename macro SlicerMacroGetPlatformArchitectureBitness and change its
associate return value from PLATFORM to OS.

Revision 19948  Directory Listing
Modified Thu Apr 26 21:59:13 2012 UTC (5 years, 5 months ago) by jcfr
BUG: Centralize revision/version information into version header file. Fixes 1204

* Remove SlicerVersion.txt that provide redundant information and
remove associated "discoverRepository" function.

* Note that slicer revision associated with extension manager can be overwritten
at runtime from within python using:

   slicer.app.extensionManagerModel().slicerRevision = "12345"

* See http://www.na-mic.org/Bug/view.php?id=1204

Revision 19945  Directory Listing
Modified Wed Apr 25 21:46:15 2012 UTC (5 years, 5 months ago) by naucoin
BUG: use the qSlicerApplication to set up the mouse mode tool bar, add icons so can test it properly

Revision 19944  Directory Listing
Modified Wed Apr 25 21:25:41 2012 UTC (5 years, 5 months ago) by naucoin
STYLE: update the tool tip to give users a hint about placing annotations

Revision 19943  Directory Listing
Modified Wed Apr 25 20:20:37 2012 UTC (5 years, 5 months ago) by naucoin
ENH: resolves bug reports 1645 and 1593. Make the mouse mode tool bar more compact, and if a user clicks on the place X action a second time, switch to view transform mode. Added testing and null pointer checks.

Revision 19936  Directory Listing
Modified Tue Apr 24 18:23:06 2012 UTC (5 years, 5 months ago) by finetjul
COMP: Build ExtensionsManager test with Slicer_USE_PYTHONQT OFF

Revision 19930  Directory Listing
Modified Mon Apr 23 19:05:22 2012 UTC (5 years, 5 months ago) by finetjul
ENH: Add qSlicerFileWriter to customize Save Data dialog

It works the same way than for loading qSlicerIOs. It can be registered by
any module. It adds an entry in the File Format combobox of the SaveData
dialog.

Revision 19922  Directory Listing
Modified Sat Apr 21 00:07:37 2012 UTC (5 years, 5 months ago) by jcfr
COMP: Prevent confusion by removing unused Testing code

Revision 19921  Directory Listing
Modified Sat Apr 21 00:07:22 2012 UTC (5 years, 5 months ago) by jcfr
COMP: Ensure that Slicer can compile with Python support disabled

Fix typo and add #ifdef were it was missing.

Revision 19893  Directory Listing
Modified Fri Apr 13 00:20:30 2012 UTC (5 years, 5 months ago) by finetjul
ENH: Activate Extension Manager by default

Revision 19852  Directory Listing
Modified Wed Apr 11 10:56:33 2012 UTC (5 years, 5 months ago) by jcfr
BUG: Ensure generic Python module tests pass when build as extension

After commit r19844 that ensure that python unittest will fail if it applies,
a problem associated with generic python module tests has been discovered.

The following error message was displayed:

   AttributeError: 'module' object has no attribute 'scriptedloadableextensiontemplate'


This was explained by the fact the path where the module was located
wasn't considered by the module factory manager.

To address that problem, a new command line option named

  --additional-module-paths

has been added.


The given list of path will added to the factory module manager.

Revision 19851  Directory Listing
Modified Wed Apr 11 10:56:30 2012 UTC (5 years, 5 months ago) by jcfr
COMP: List of command line option is now consistent with build option

* disable-scripted-loadable-modules is added only if build with Python support

* disable-cli-modules is added only if build with CLI support

Revision 19850  Directory Listing
Modified Wed Apr 11 10:56:28 2012 UTC (5 years, 5 months ago) by jcfr
STYLE: Fix doxygen comment of qSlicerCoreCommandOptions::isTestingEnabled function

Revision 19848  Directory Listing
Modified Wed Apr 11 10:56:25 2012 UTC (5 years, 5 months ago) by jcfr
BUG: Ensure that failing python unit tests are reported as failing test

* This regression was introduced following r19581 [1]

* To prevent this issue from occurring again, a regression test
is also added.

[1] http://viewvc.slicer.org/viewvc.cgi/Slicer4?view=revision&revision=19581

Revision 19809  Directory Listing
Modified Sat Apr 7 08:41:27 2012 UTC (5 years, 5 months ago) by jcfr
ENH: Add python module 'saferef' allowing to create weak reference to method/function.

* This module is the equivalent of built-in module 'weakref'. The difference
is that 'saferef' safely create weak reference to any function,
including bound methods whereas the 'weakref' module deals "only"
with objects [1].

[1] http://docs.python.org/library/weakref.html

* This module has been imported from "django" code base at revision 17875
See https://code.djangoproject.com/browser/django/trunk/django/dispatch/saferef.py?rev=17875

* The license associated is BSD. Since the code has been originally imported
from PyDispatcher and modified by django, both the license of (a) PyDispatched
and (b) Django are included at the top of the file.

 a) https://code.djangoproject.com/browser/django/trunk/django/dispatch/license.txt?rev=17875

 b) https://code.djangoproject.com/browser/django/trunk/LICENSE?rev=17875

* The associated unittest has also been added. Currently living in
"Base/Python/tests" and added within "Application/SlicerQT/Testing/Python/CMakeLists.txt",
this may change. The macro "SLICER_ADD_PYTHON_UNITTEST" has also been
adapted to understand absolute path.

* Currently, the test itself isn't installed, this may also change in
the future.

Revision 19807  Directory Listing
Modified Sat Apr 7 02:46:13 2012 UTC (5 years, 5 months ago) by jcfr
COMP: Make sure qSlicerApplication compile with extensions manager support disabled

* Exclude code dealing with qSlicerSettingsExtensionsPanel
if Slicer_BUILD_EXTENSIONMANAGER_SUPPORT is OFF.

* Thanks to Dominique Belhachemi for reporting the issue :)

Revision 19806  Directory Listing
Modified Sat Apr 7 01:12:16 2012 UTC (5 years, 5 months ago) by jcfr
ENH: Add settings allowing to enable Extension Manager

* Edit -> Application Settings -> Extensions Settings -> "Enable extensions manager"

Revision 19802  Directory Listing
Modified Fri Apr 6 13:46:05 2012 UTC (5 years, 5 months ago) by jcfr
BUG: Ensure qSlicerExtensionsManagerModelTest properly clean temporary file.

Two issues have been addressed:

 1) To make sure the created "query file" could be deleted, the
QNetworkReply associated with the query is now closed.
See https://github.com/Slicer/qMidasAPI/issues/4

 2) Files copied from a resource onto the hardrive need to have their
permission set so that they could be deleted.
See https://bugreports.qt-project.org/browse/QTBUG-5401


Additionally, the temporary directory is also conditionally created
within "prepareJson".

Revision 19801  Directory Listing
Modified Fri Apr 6 08:43:22 2012 UTC (5 years, 5 months ago) by jcfr
BUG: Update qSlicerUtilsTest1 to consider operating system differences.

* Part of the test relying on the fact directory could be assigned
the "Exe permission" has been excluded from windows.

Indeed, reading the documentation related to the function `_wchmod` [1],
it is explained that only `_S_IWRITE` and `_S_IREAD` are used.
Additionally, looking at Qt source code, we can notice that within Qt 4.7.4,
`QFile::Exe{Owner, User, Group, Other}` property are ignored [2].

* An extra step consisting in checking if files have write permission
allow to validate the proper functioning of the function on windows.

[1] http://msdn.microsoft.com/en-us/library/1z319a54(v=vs.90).aspx
[2] https://qt.gitorious.org/qt/qt/blobs/092cd760d5fddf9640a310214fe01929f0fff3a8/src/corelib/io/qfsfileengine_win.cpp#line1781

Revision 19800  Directory Listing
Modified Fri Apr 6 08:43:20 2012 UTC (5 years, 5 months ago) by jcfr
STYLE: Prevent confusion removing unused commented code from qSlicerExtensionsManagerModelTest

Revision 19798  Directory Listing
Modified Fri Apr 6 04:08:42 2012 UTC (5 years, 5 months ago) by jcfr
ENH: Add function to recursively set permission of a directory and all its descendant.

* Note that the unit test simply ensure that permission can be set recursively.
It doesn't check that all permission permutations could be set. It's indeed
assumed that the function "QFile::setPersmissions()" is working as expected.

Revision 19797  Directory Listing
Modified Thu Apr 5 22:53:51 2012 UTC (5 years, 5 months ago) by jcfr
BUG: Ensure "local file" serverUrl is properly set in qSlicerExtensionsManagerModelTest

* For each test, the Midas server url is set to be a local file, that
way when the model manager attempt to query the server it gets the content
of the file.

For example, if the server url is set to be "file:///foo" and if the query
is "file:///foo/api/json?method=midas.version", the content of the file
"/foo/api/json" will correspond to the reply.

On windows, an extra "/" has to be added when specifying a local file as Url.
Since we were manually pre-pending "file://", it was working for unix-like
system but not for windows. See [1] for more details.

This commit make use of "QUrl::fromLocalFile" to address that issue. Note
also that the unit test has been updated.

[1] http://en.wikipedia.org/wiki/File_URI_scheme#Windows_2

Revision 19780  Directory Listing
Modified Tue Apr 3 16:08:18 2012 UTC (5 years, 5 months ago) by jcfr
BUG: Ensure test qSlicerCLIModuleTest1 passes also if Slicer_BUILD_CLI is OFF

* Since CLIModule4Test is not conditionally built, checking if CLIModule4Test
can be loaded  shouldn't be conditionally checked.

* Additionally, building with Slicer_BUILD_CLI:BOOL=OFF doesn't mean
that Slicer_BUILD_CLI_SUPPORT:BOOL is also OFF.

* This fix a regression introduced in r19334

Revision 19773  Directory Listing
Modified Mon Apr 2 06:54:42 2012 UTC (5 years, 5 months ago) by jcfr
BUG: Prevent crashes by not using vtkMRMLScene::CreateNodeByClass in python

As explained in commit r19772, using CreateNodeByClass could easily lead
to bugs and crashes.

See http://viewvc.slicer.org/viewvc.cgi/Slicer4?view=revision&revision=19772

Revision 19766  Directory Listing
Modified Mon Apr 2 06:30:04 2012 UTC (5 years, 5 months ago) by jcfr
BUG: Ensure python extension are loaded when running Generic Cxx tests.

* Note that ideally, the code within qSlicerLoadableModule::setup()
should be "smart" enough to check if the import is needed.

* After making sure it doesn't impact starting/loading of Slicer,
may be the call to "isEmbeddedModule" in "qSlicerLoadableModule::setup"
could be avoided.

Revision 19765  Directory Listing
Modified Mon Apr 2 06:30:02 2012 UTC (5 years, 5 months ago) by jcfr
ENH: Improve modularization by moving code related to loadable module into qSlicerLoadableModule.{h,cxx}

* The code allowing to import the python module extensions associated with
a loadable module used to be in qSlicerLoadableModuleFactoryItem and
couldn't be re-used.

This commit factor out the code into a static function associated with the
qSlicerLoadableModule that could be easily re-used.

Revision 19764  Directory Listing
Modified Mon Apr 2 06:30:00 2012 UTC (5 years, 5 months ago) by jcfr
BUG: Generic Cxx test - Ensure modulePath is properly set on generator relying an IntDir

* For a definition of IntDir, consider reading:
http://www.cmake.org/cmake/help/cmake-2-8-docs.html#variable:CMAKE_CFG_INTDIR

* The main idea is to generate the full path to the module at runtime where
qSlicerCoreApplication::intDir() returns the current IntDir if any.

Revision 19729  Directory Listing
Modified Wed Mar 28 21:20:14 2012 UTC (5 years, 5 months ago) by jcfr
BUG: Allow python module associated with a scripted module to be imported.

Revision 19728  Directory Listing
Modified Wed Mar 28 21:20:12 2012 UTC (5 years, 5 months ago) by jcfr
STYLE: Improve readability by renaming function to a semantically correct name.

* Change "IsExtension" into "IsEmbeddedModule"

* The concept of extension and module are decoupled, a module doesn't have
to be an extension to be externally loaded.

Revision 19727  Directory Listing
Modified Wed Mar 28 21:20:10 2012 UTC (5 years, 5 months ago) by jcfr
STYLE: Prevent later confusion removing commented code

Revision 19726  Directory Listing
Modified Wed Mar 28 21:20:08 2012 UTC (5 years, 5 months ago) by jcfr
COMP: Add unit test for vtkSlicerApplicationLogic::IsExtension

Revision 19723  Directory Listing
Modified Wed Mar 28 15:50:18 2012 UTC (5 years, 5 months ago) by jcfr
BUG: Ensure extension download page can be accessed within the manager.

* To obtain the "bare" view, the param changed from "slicerView=slicerView"
to "layout=empty".

See https://github.com/midasplatform/slicerappstore/issues/23

Revision 19722  Directory Listing
Modified Wed Mar 28 04:30:37 2012 UTC (5 years, 5 months ago) by jcfr
ENH: Python object associated with scripted widget representation can now be accessed.

* For example:
 s = slicer.modules.endoscopy.widgetRepresentation().self()

Revision 19717  Directory Listing
Modified Tue Mar 27 22:07:05 2012 UTC (5 years, 6 months ago) by naucoin
BUG: adding missing cyst label, resolving bug 1840

Revision 19709  Directory Listing
Modified Mon Mar 26 19:48:22 2012 UTC (5 years, 6 months ago) by jcfr
BUG: Display result of python command into the qt console.

* This fix a regression introduced in r19700

Revision 19708  Directory Listing
Modified Mon Mar 26 15:28:54 2012 UTC (5 years, 6 months ago) by jcfr
STYLE: Consistently name unit test function.

* By convention, unit test function are expected to start with the "test" prefix.

Revision 19707  Directory Listing
Modified Mon Mar 26 04:32:00 2012 UTC (5 years, 6 months ago) by jcfr
COMP: Remove unused code. Revert r16982

Revision 19706  Directory Listing
Modified Mon Mar 26 04:20:49 2012 UTC (5 years, 6 months ago) by jcfr
BUG: Only code passed using '-c' is executed in "shebang" mode.

* Restore the original behavior associated with '--python-code', if this
option is used, all modules will be loaded and Slicer won't exit.

* Code passed using the option '-c' is executed similarly to what's done
with the regular python interpreter. See http://docs.python.org/tutorial/interpreter.html

* Main.cxx has been simplified, function "initializePython" has been
removed and corresponding code has been moved into qSlicerCoreCommandOption.
Commit 19377 make it possible because the "parseArgument" has been moved into
the "init" method of qSlicerCoreApplication pimpl.

Revision 19705  Directory Listing
Modified Mon Mar 26 00:28:42 2012 UTC (5 years, 6 months ago) by jcfr
BUG: Syntax error in one scripted module do not prevent other modules from loading.

Revision 19704  Directory Listing
Modified Mon Mar 26 00:28:39 2012 UTC (5 years, 6 months ago) by jcfr
ENH: Add unit test for qSlicerScriptedLoadableModule

* Add method pythonSource()

* Prevent crash if setPythonSource is called before python has been initialized.

* Remove commented code

* Improve error message by specifying the class where the error occurs.

Revision 19703  Directory Listing
Modified Sun Mar 25 23:08:19 2012 UTC (5 years, 6 months ago) by jcfr
COMP: Add test data associated with qSlicerScriptedLoadableModuleWidget unit test

Revision 19702  Directory Listing
Modified Sun Mar 25 23:03:34 2012 UTC (5 years, 6 months ago) by jcfr
ENH: Add unit test for qSlicerScriptedLoadableModuleWidget

* Added method pythonSource()

* Ensure that method setup() of qSlicerScriptedLoadableModuleWidget
can be called if no qSlicerScriptedLoadableModule has been set.

* Prevent crash if setPythonSource is called before python has been initialized.

* Remove commented code

* Improve error message by specifying the class where the error occurs.

Revision 19701  Directory Listing
Modified Sun Mar 25 23:03:31 2012 UTC (5 years, 6 months ago) by jcfr
BUG: qSlicer(Core)PythonManager can now be initialized without qSlicer(Core)Application

Revision 19700  Directory Listing
Modified Sun Mar 25 23:02:49 2012 UTC (5 years, 6 months ago) by jcfr
BUG: Ensure python stderr are not redirected into stdout

Revision 19699  Directory Listing
Modified Sun Mar 25 17:57:14 2012 UTC (5 years, 6 months ago) by jcfr
ENH: Error printed within 'slicer.util' are now written on stderr

Revision 19695  Directory Listing
Modified Fri Mar 23 23:29:13 2012 UTC (5 years, 6 months ago) by jcfr
BUG: Do not display "false" error message when loading PythonQt module on windows.

* To illustrate the issue, if we consider a python module named FooBar.pyd,
the build directory would also contain a file named "foobar.idb".

Since on windows the python function 'glob.glob. is case insensitive. The
function importQtClassesFromDirectory was reporting an error while
trying to first load the lower case version of the module. Then, the correct
cased module was successfully imported. Reporting an error that
didn't really occurred was confusing the user.

* The solution consisted in matching the filename using the provided
"filematch" expression.


* Note also that the code has been re-factored, the function
"importClassesFromDirectory" has been introduced.

Revision 19688  Directory Listing
Modified Thu Mar 22 08:54:11 2012 UTC (5 years, 6 months ago) by jcfr
COMP: Avoid confusion by removing unused tcl test from Base/GUI/Testing

Revision 19687  Directory Listing
Modified Thu Mar 22 08:48:01 2012 UTC (5 years, 6 months ago) by jcfr
COMP: Avoid confusion by removing unused files from "Base/GUI/Python"

Revision 19686  Directory Listing
Modified Thu Mar 22 08:37:24 2012 UTC (5 years, 6 months ago) by jcfr
COMP: Avoid confusion by removing unused "*_ImageData.h" from Base/GUI/Resources

Revision 19685  Directory Listing
Modified Thu Mar 22 08:13:38 2012 UTC (5 years, 6 months ago) by jcfr
COMP: Remove cxx tests based on KWWidgets

Revision 19684  Directory Listing
Modified Thu Mar 22 08:13:30 2012 UTC (5 years, 6 months ago) by jcfr
COMP: Allow extension to include testing macros.

* Split CMake/TestingMacros.h into MRML/Core/{vtkMRMLCoreTestingMacros, vtkMRMLDebugLeaksMacro}

* MRML/Core being a directory already included, when building extension
the header providing the testing macro will be found.

* Also split the macro allowing to consider leaks as error into "vtkMRMLDebugLeaksMacro.h"

Revision 19669  Directory Listing
Modified Wed Mar 21 08:42:49 2012 UTC (5 years, 6 months ago) by jcfr
BUG: Fix SlicerSceneObserverTest ensuring Python interpreter is properly "terminated". Fixes #1656

* See https://github.com/commontk/CTK/commit/7cca40da98809ccb8c4b352357ac1f0c576e08b5https://github.com/commontk/CTK/commit/d488c63e5d9f8b11fa501d88ebc3ca7b5d3064b4

Revision 19664  Directory Listing
Modified Tue Mar 20 15:49:30 2012 UTC (5 years, 6 months ago) by finetjul
BUG: Remove empty search path

An empty search path might lead to have ./Slicer executable being taken as a CLI. Which eventually calls
./Slicer --xml
It then runs slicer again which discover a Slicer CLi and runs Slicer one more time.
-> infinite creation of slicer processes.
This was caused by the following line in Slicer.ini:
Modules/AdditionalPaths=
instead of
Modules/AdditionalPaths=@Invalid@

Revision 19662  Directory Listing
Modified Tue Mar 20 08:15:28 2012 UTC (5 years, 6 months ago) by jcfr
COMP: Minimize confusion and improve readability by consistently using ".toLatin1()"

* There were occurrences of:
   .toLatin1().data()
   .toStdString().c_str()
   .toAscii().data()

these ones have been replaced with the shorter and equivalent form ".toLatin1()"

* The function qPrintable() is also used to print a QString within a std stream.

Revision 19655  Directory Listing
Modified Mon Mar 19 07:02:07 2012 UTC (5 years, 6 months ago) by jcfr
COMP: Avoid confusion by defining SIMPLE_TEST macro only once.

* Consistently set the variable KIT within the Testing/Cxx/CMakeLists.txt of
each library.

* Fix name inconsistency. See #1615

Revision 19654  Directory Listing
Modified Mon Mar 19 04:22:03 2012 UTC (5 years, 6 months ago) by jcfr
ENH: Simplify mechanism allowing to retrieve expected metadata in qSlicerExtensionsManagerModel test

* Fully test "testExtensionLauncherSettingsUpdated" with both linux and macosx extension

* Introduce "ExtensionIdType", a tuple <OperatingSystem, ExtensionId> allowing
to easily retrieve the input data associated with an extension.

* Remove "initializeModel" method and explicitly set the slicer version when
it applies.

Revision 19653  Directory Listing
Modified Mon Mar 19 04:21:59 2012 UTC (5 years, 6 months ago) by jcfr
ENH: Refactor code and add "qSlicerExtensionsManagerModel::serverToExtensionDescriptionKey"

Revision 19652  Directory Listing
Modified Mon Mar 19 04:21:57 2012 UTC (5 years, 6 months ago) by jcfr
ENH: Add test for "qSlicerExtensionsManagerModelTester::serverKeysToIgnore"

Revision 19649  Directory Listing
Modified Mon Mar 19 04:21:52 2012 UTC (5 years, 6 months ago) by jcfr
BUG: Prevent assertion from happening in when registering a module

* On macosx, when a plugin is improperly fixed, the assertion occurred. This
commit remove the assertion and emit the "moduleIgnored" signal if the
associated condition happen.

Revision 19648  Directory Listing
Modified Mon Mar 19 04:21:51 2012 UTC (5 years, 6 months ago) by jcfr
ENH: Ensure extensionsInstallPath is properly set on MacOSX

* Since extension libraries and executable are fixed up, there are expected
to be located within the "Slicer.app/Contents" folder. For that purpose,
the following changes have been introduced:

 -  Introduce method "defaultExtensionsInstallPathForMacOSX" in the pimpl
of qSlicerCoreApplication. This method is used to force the extensionsInstallPath
to have always the same value on macosx.

 - The ExtensionsInstallPathButton in extension settings panel is now
always disabled if the operating system is macosx.

 - In case of non-installed Slicer on macosx, the path prefixed with
"bin/Slicer.app/Contents/<Slicer_BUNDLE_EXTENSIONS_DIRNAME>" are added as search paths.

Revision 19647  Directory Listing
Modified Mon Mar 19 04:21:47 2012 UTC (5 years, 6 months ago) by jcfr
ENH: Update qSlicerExtensionsManagerModel extraction mechanism to consider macosx extensions.

* On macosx, the extraction process is different from windows and linux.

Indeed, within a macosx extension archive, files are all contained within
the "Slicer.app/Contents/<Slicer_BUNDLE_EXTENSIONS_DIRNAME>/..." directory. After extraction, files will
be located in the folder "/<extensionsPath>/<archiveBaseName>/Slicer.app/Contents/Plugins/..."

Then, they will be copied from:

  "/<extensionsPath>/<archiveBaseName>/Slicer.app/Contents/<Slicer_BUNDLE_EXTENSIONS_DIRNAME>/<extensionName>/..."

into

  "/<extensionsPath>/<extensionName>"

It is assume that, to successfully load the extension, the application will
have to set the extensions path to "/path/to/Slicer.app/Contents/<Slicer_BUNDLE_EXTENSIONS_DIRNAME>".

Revision 19646  Directory Listing
Modified Mon Mar 19 04:21:43 2012 UTC (5 years, 6 months ago) by jcfr
BUG: Make sure qSlicerExtensionsManagerModel tests pass even if Slicer version is updated

* Test are now version agnostic. qSlicerExtensionsManagerModelTester class
has now the member "SlicerVersion" allowing to specify which version
of Slicer has been used to generate the baseline data.

* Add qSlicerExtensionsManagerModel::setSlicerVersion/slicerVersion

* Note also that the temporary Settings file associated with the test
will now be deleted.

Conflicts:

	Base/QTCore/qSlicerExtensionsManagerModel.cxx

Revision 19645  Directory Listing
Modified Mon Mar 19 04:21:41 2012 UTC (5 years, 6 months ago) by jcfr
ENH: Improve readability factoring out code used to extract the extension archive.

* Note also the addition of the convenience typedef "Pimpl".

Revision 19644  Directory Listing
Modified Mon Mar 19 04:21:39 2012 UTC (5 years, 6 months ago) by jcfr
ENH: Extension package are now properly "fixed up" on MacOX

* Disable CMAKE_INSTALL_NAME_TOOL when packaging extension, that way all
installed library will contain the full path to their direct dependencies provided
by the extension itself. Doing so will allow the to properly fix all libraries.

* Copy SlicerCompleteBundle.cmake.in into SlicerExtensionCompleteBundle.cmake.in,
also copy function "get_bundle_keys" and "fixup_bundle" from BundleUtilities.cmake
and respectively rename them into "get_extension_keys" and "fixup_extension".
This has been motivated by the fact there is no executable available within the
"Slicer.app/Contents/MacOS" directory. It means we have to "fake" it by
commenting the function which was explicitly checking for the existence
of an executable. For instance, "get_bundle_and_executable" has been commented out.
The variable "exepath" is now explicitly set within the function "fixup_extension"
and "get_extension_keys"

* To speed up the "fixup" process, "get_prerequisites" is called with
"recurse" parameter set to "0".

* Note also that since all the libraries available under the Slicer superbuild
directory have already been fixed up, the "fixup_extension" function
check if a given item is located within a sub directory of "Slicer_SUPERBUILD_DIR".
If it's the case, the item will be skipped.

* The install directory being different within the bundle, the CMake block
"SlicerBlockUploadExtensionPrerequisites" has been updated to "patch"
the *MODULES_*_DIR" variable with "Slicer_BUNDLE_EXTENSIONS_LOCATION".

Revision 19628  Directory Listing
Modified Fri Mar 16 18:02:19 2012 UTC (5 years, 6 months ago) by pieper
BUG: remove incorrect error message

Revision 19624  Directory Listing
Modified Fri Mar 16 00:17:43 2012 UTC (5 years, 6 months ago) by finetjul
BUG: Calling methods from python with IOProperties arguments fail in Qt4.6

Qt 4.6 handles metatypes differently from Qt 4.7
https://bugreports.qt-project.org/browse/QTBUG-11485?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#issue-tabs

The problem here is that for Qt,  loadNodes() takes an IOProperties and not a QVariantMap (QMap<QString, QVariant>) even if they are the same.
So it gets confused when calling the slot because PythonQt gives a QVariantMap as argument, and Qt thinks it's different than IOProperties.
d of IOProperties. What I don't know yet is if this IOProperties makes sense or not, I'm tempted to use QVariantMap instead.

Closes #1813

Revision 19623  Directory Listing
Modified Fri Mar 16 00:17:41 2012 UTC (5 years, 6 months ago) by finetjul
COMP: Don't add qSlicerExtensionsManagerModelTest when extensions support is not ON

Revision 19608  Directory Listing
Modified Wed Mar 14 18:45:50 2012 UTC (5 years, 6 months ago) by finetjul
ENH: Upgrade documentation to 4.1

Revision 19585  Directory Listing
Modified Tue Mar 13 17:51:12 2012 UTC (5 years, 6 months ago) by jcfr
ENH: Exit Slicer after code specified using '-c' or '--python-code' is executed.

* This is done toward having Slicer behaving like the python interpreter.

* Note that more or work is required to consolidate the command line API
and write the corresponding documentation.

* The use case motivating that change is the possibility to execute the
script 'get-pip.py'.
See https://github.com/pypa/pip/blob/develop/pip/req.py#L222

Revision 19583  Directory Listing
Modified Tue Mar 13 14:19:06 2012 UTC (5 years, 6 months ago) by jcfr
STYLE: Ease collaboration and improve readability by ordering element alphabetically in CMakeLists.txt

Revision 19582  Directory Listing
Modified Tue Mar 13 14:19:03 2012 UTC (5 years, 6 months ago) by jcfr
ENH: Slicer can be used as python interpreter with minimum overhead.

* Introduced property "runPythonAndExit" indicating that Slicer should
exit after execution of a given python script.

* This applied to python scripts executed using the following syntax:
   ./Slicer <scriptname>

* Ideally, it should be possible to lazily load slicer modules.

Revision 19581  Directory Listing
Modified Tue Mar 13 14:19:00 2012 UTC (5 years, 6 months ago) by jcfr
ENH: More reliable mechanism to check if error occurred when executing python script.

Revision 19580  Directory Listing
Modified Tue Mar 13 14:18:57 2012 UTC (5 years, 6 months ago) by jcfr
ENH: Make sure python script expecting 'sys.executable' remains happy

Revision 19579  Directory Listing
Modified Tue Mar 13 14:18:55 2012 UTC (5 years, 6 months ago) by jcfr
BUG: Ensure script name is not appended twice when running a python script

* Before that change, by calling "./Slicer foo.py --bar", the list
'sys.argv' contained: ["foo.py", "foo.py", "--bar"]

* Following that change, the same list will contain the values: ["foo.py", "--bar"]

Revision 19578  Directory Listing
Modified Tue Mar 13 14:18:52 2012 UTC (5 years, 6 months ago) by jcfr
COMP: qSlicerCoreCommandOptions - Anticipate possible reuse by moving initialization code into "init()"

* Doing so ensure that the initialization code won't be duplicated in case
the pimpl is derived.

Revision 19575  Directory Listing
Modified Mon Mar 12 21:17:16 2012 UTC (5 years, 6 months ago) by pieper
ENH: pure-python implementation of editor module

ENH: add stub of draw effect

More work in progress for conversion of core
editor functionality from tcl to python

ENH: further migration of editor effects to new design

Make a functioning paint effect as an editor builtin

BUG: disconnect pipeline when making label volume

This allows modified events on the label map to trigger
render without pulling original pipeline.

EHN: more porting of Paint Effect

Fix LabelEffect options gui and parameter node
settings for threshold paint, etc.

Hook up undo/redo for paint effect.

ENH: remove 'embedded' mode and clean up code

Per discussion with Danielle at 2012 Winter
Project Week, embedded mode is no longer needed and
we can accomplish our goals with editor extensions
and other methods.

Also remove some other dead code and comments.

EHN: work in progress for new editor

ENH: further editor porting and helper methods

ENH: code refactor and porting for DrawEffect in Editor

Porting to python and better distinction between tool and
logic classes with better abstraction of LabelEffect superclass
to handle rasterization tasks.

BUG: minor porting syntax differences

Tcl to python issues and naming convention change from
EditOptions to Options/Tool/Logic effect convention.

BUG: fixes to Label and Draw effects

better allocation of work between superclass and subclass
and new it actually works.

BUG: fix draw effect

- button release detected
- visibility fixed on enter/leave
- delete with 'x' key fixed

BUG: avoid crash in threaded routine

Make sure the thread is terminated before allowing
destructor to complete

BUG: fix smudge mode in new paint tool

ENH: remove workaround for updating other slice views

After paint, a call to labelNode.Modified() is enough
to trigger a scheduleRender in all other slice views

BUG: Fix typos in util methods

also clean up style of arg list

ENH: port editor's threshold effect to python

BUG: fixes for undo/redo buttons and gui creation

BUG: fix logic of undo/redo to store only specified number of steps

BUG: fix setting threshold paint from thresholdeffect

ENH: port rectangle effect to python

ENH: add level tracing python port

(still some debugging to do)

BUG: fix level tracing preview and apply

Add scheduleRender and transform correct points

BUG: fix crash in level tracing

Avoid case where one pixel difference in xy space
mapped to same ijk pixel leading to abmiguity in
the definition of extraction plane.

Use an offset value that is the max size of screen space,
but catch the case where we map back to the same
pixel.

ENH: fix pan/zoom while level trace is active

BUG: observe middle mouse button for pan in level tracing

ENH: add a scope option for all effects

If the effect defines a custom list of scopeOptions from
the Effect's list of availableScopeOptions then
a combobox will be displayed to give the user the option
of scope contexts.  This controls the input and output volume
behavior for the effect (still being ported)

EHN: Port of Erode effect and related fixes to class hierarchy

ENH: add dilate effect and fix up morphology

Now erode and dilate working as expected with mrml,
undoRedo, etc.

ENH: add ChangeLabelEffect

ENH: add MakeModelEffect

BUG: restrict morphology operations to scope of 'All'

Really no convenient way to have the operation apply only
to the visible region since it does not get applied
with respect to a slice.

Real solution for these would be to give a scope option of
'Window' in which case the EffectOptions would present a
combo box of the current views and the user could select
the one to apply the operation in - add this to the TODO list.

BUG: use the class name in the parameter node

ENH: add new effects

Add to the __init__.py, the CMakeLists.txt and to the
EditBox.

ENH: adopt explicit declaration of connections for guis

By adding the connections list to each class instance it is
possible for users of the class to explicitly turn off the connection
before updating the widget values.  This avoids having
updateMRMLFromGUI calls interfering with the updating
of the gui itself.

Label and Paint have been updated with this behavior, other
effects to follow.

ENH: switch more effects to use the connections list

Includes other minor debugging fixes too

STYLE: better method names: now (dis)connectWidgets

was (dis)connectConnections

ENH: add RemoveIslands and IdentifyIslands effects

STYLE: better comment

ENH: add converted save island effect

ENH: remove unused widgets and fix undo/redo for save island

ENH: add ChangeIslandEffect

Finishes out porting of core effects

ENH: detect missing model maker module and provide error dialog

ENH: port GrowCut to new effect architecture

GrowCut no longer inherits from PaintEffect - instead
users will use ordinary tools to draw gestures and
then invoke the grow cut.  If they want to edit the
gestures they can use Undo.

Note: Still needs some debugging in the apply logic
of growCut

STYLE: remove some dead code (pauseEffect)

BUG: fix status message call

ENH: improve label name and set default step for range

Per feedback from Sonia, the step size now adapts to the
scalar range of the background data

BUG: turn off effect when leaving the module

BUG: avoid crash in GrowCut by ensuring segmentated data is valid

BUG: fix grow cut effect

Now all effects have been ported and the editor invokes
only the pure-python versions of the code.

ENH: reorganize icons for better flow

Now growcut is near erode and dilate, which it is somehow
similar to.  Make Model is at the end, since it is often
the final step.

Revision 19557  Directory Listing
Modified Fri Mar 9 23:20:39 2012 UTC (5 years, 6 months ago) by jcfr
STYLE: qSlicerSettingsExtensionsPanel - Give credit to the original author

Revision 19538  Directory Listing
Modified Wed Mar 7 22:26:14 2012 UTC (5 years, 6 months ago) by finetjul
COMP: Support Slicer_BUILD_EXTENSIONMANAGER_SUPPORT and Slicer_USE_PYTHONQT

Revision 19537  Directory Listing
Modified Wed Mar 7 22:26:07 2012 UTC (5 years, 6 months ago) by finetjul
STYLE: Make vtkArchive::extract_tar more verbose

Report error in copy_data()

Revision 19536  Directory Listing
Modified Wed Mar 7 21:51:56 2012 UTC (5 years, 6 months ago) by finetjul
ENH: Add cache manager settings

Default cache directory is $TEMP/Slicer/RemoteIO

vtkCacheManager::SettingsUpdateEvent is not needed, use ModifiedEvent instead.

Warning, the cache manager is not properly configured if the application runs in GUI-less environment

Revision 19535  Directory Listing
Modified Wed Mar 7 21:03:54 2012 UTC (5 years, 6 months ago) by dpace
ENH: Word wrap tooltips

Closes #1527

Revision 19528  Directory Listing
Modified Wed Mar 7 00:13:36 2012 UTC (5 years, 6 months ago) by finetjul
BUG: In CLI modules, if volume type is specified, don't allow subclass as valid node

Example:
Don't allow DTI nodes as output of Diffusion Tensor Scalar Measurements, only Scalar volumes.

Revision 19525  Directory Listing
Modified Tue Mar 6 21:03:56 2012 UTC (5 years, 6 months ago) by naucoin
BUG: closing bug 1783. Don't clear out nodes on scene close as it removes hierarchy display nodes.

Revision 19518  Directory Listing
Modified Tue Mar 6 15:59:57 2012 UTC (5 years, 6 months ago) by finetjul
BUG: Exit current module before closing Slicer

Exiting the current module in the module panel destructor is not enough.
It happens too late, ideally it should happen before the layout manager
is destructed but also before the current layout is saved into settings as
exiting a module can "revert" the current layout.

qSlicerModuleSelectorToolBar::actionSelected was crashing when the QAction
was 0.

Closes #1787

Revision 19509  Directory Listing
Modified Mon Mar 5 04:18:07 2012 UTC (5 years, 6 months ago) by finetjul
ENH: Improve default scene name in Save dialog

Closes #1784

Revision 19505  Directory Listing
Modified Sun Mar 4 08:52:10 2012 UTC (5 years, 6 months ago) by finetjul
BUG: Make sure that exit is called when enter is called in a module.

Revision 19504  Directory Listing
Modified Sat Mar 3 21:33:27 2012 UTC (5 years, 6 months ago) by naucoin
BUG: backing out changes to make hierarchy nodes storable (bug 1717) as it's not stable enough for the release

Revision 19501  Directory Listing
Modified Sat Mar 3 15:06:06 2012 UTC (5 years, 6 months ago) by pieper
BUG: fix typo in attribute

Revision 19498  Directory Listing
Modified Sat Mar 3 08:17:42 2012 UTC (5 years, 6 months ago) by finetjul
STYLE: Add Favorite title to groupbox in modules settings.

Revision 19495  Directory Listing
Modified Fri Mar 2 06:46:55 2012 UTC (5 years, 6 months ago) by finetjul
BUG: Update display with output of CLI execution

During the port from Slicer3 to Slicer4, the role of
vtkSlicerCLIModuleLogic::CommandLineModuleNode has been discarded.
It was used to know which CLI module node was updating the display (->
updating the SelectionNode). This was done by expressively setting
the command line module node from the GUI panel (or scripts) and run it.

Here, we take a different approach and the decision has to be taken
when the CLI is run.
This has the advantage of having multiple CLI to update the selection node
at the same time (more thread safe)
Closes #1776

Revision 19493  Directory Listing
Modified Fri Mar 2 01:54:12 2012 UTC (5 years, 6 months ago) by finetjul
BUG: Prevent user from choosing invalid file name in SaveData dialog

Valid characters are arbitrarilly been chosen. They can be changed if
required.

Closes #1773

Revision 19483  Directory Listing
Modified Thu Mar 1 02:33:59 2012 UTC (5 years, 6 months ago) by finetjul
BUG: Resize the Options column after each options insertion

Despite the fact that the Options column is already in ResizeToContents
mode, adding a widget into the column doesn't seem to resize the column.
Do it manually.
Closes #1754

Revision 19476  Directory Listing
Modified Wed Feb 29 23:49:14 2012 UTC (5 years, 6 months ago) by jcfr
COMP: Facilitate the integration of CMake upstream code related to archive extraction

* Introduce convenient class cmSystemTools in the anonymous namespace
of vtkArchive.cxx. Doing so will prevent possible mistake when copy pasting
the code from cmSystemTools.cxx

* Additionally, "cout", "endl" and "flush" are now used to ensure the
outputted message are displayed timely.

Revision 19472  Directory Listing
Modified Wed Feb 29 22:23:40 2012 UTC (5 years, 6 months ago) by jcfr
BUG: Properly discover modules when Slicer started on Windows from a build tree

* Compute properly IntDir when qSlicerCoreApplication is instantiated within Slicer itself.

* This new issue a side effect of the "fix" (r19408) implemented to allow the command line
module like EMSEgmentCommandLine to instantiate a qSlicerApplication directly
and have the intermediate directory properly computed.

* With this commit, it tries to recompute the IndDir only if it's empty.

* See http://viewvc.slicer.org/viewvc.cgi/Slicer4?view=revision&revision=19408

Revision 19470  Directory Listing
Modified Wed Feb 29 21:01:39 2012 UTC (5 years, 6 months ago) by finetjul
BUG: Alphabetically (case insenstively) order modules in Modules model

Revision 19469  Directory Listing
Modified Wed Feb 29 21:01:38 2012 UTC (5 years, 6 months ago) by finetjul
BUG: Random position of Scripted modules (DICOM, Editor) in menu

The index variable was not initialized and being optional, some modules
were not setting it, leading to a random position when inserting the
modules in the list.

Revision 19468  Directory Listing
Modified Wed Feb 29 21:01:36 2012 UTC (5 years, 6 months ago) by finetjul
ENH: Add Modules/PreferExecutableCLI setting

In order to limit memory consumption, when Slicer has the choice,
it can load executable CLI instead of loadable CLI.
The setting can be set into the Appication Settings Modules panel.
Closes #1762

Revision 19463  Directory Listing
Modified Wed Feb 29 00:09:58 2012 UTC (5 years, 6 months ago) by jcfr
STYLE: Help string associated with loadable and scripted module will match slicer version.

* This has been done by relying on Slicer_VERSION_MAJOR and Slicer_VERSION_MINOR
within the loadable module and using 'slicer.app.majorVersion' and 'slicer.app.minorVersion'
within the scripted module.

* Ideally, we could define a small meta langage including special string
like: '<WIKIURL>" "<VERSION>" "<MODULENAME>", "<CONTRIBUTOR1>", ... that could
be used. the module manager would take of the substituation so that
the correct is rendered.

Revision 19460  Directory Listing
Modified Tue Feb 28 21:37:37 2012 UTC (5 years, 6 months ago) by naucoin
BUG: disable ruler nodes in a list file until get it reading properly

Revision 19453  Directory Listing
Modified Tue Feb 28 03:11:30 2012 UTC (5 years, 6 months ago) by pieper
ENH: better handling for toplevels with no children

Revision 19450  Directory Listing
Modified Tue Feb 28 01:40:38 2012 UTC (5 years, 6 months ago) by naucoin
ENH: Support reading a list of annotations from a single file, bug 1717

* Make the hierarchy nodes storable (storable and transformable methods need to be tested further! ApplyTransform TBD)
* Add the annotation hierarchy storage node to the IO widget
* Skip Read/Write in the storage nodes if the nodes are in a hierarchy
* Wrote utility methods to read from an open file


Revision 19447  Directory Listing
Modified Mon Feb 27 22:00:09 2012 UTC (5 years, 6 months ago) by jcfr
ENH: Setup method can now be defined in loadable scripted module

* This could be useful for module without widget that expect to provide
to provide some python based modules.

Revision 19435  Directory Listing
Modified Mon Feb 27 08:16:59 2012 UTC (5 years, 6 months ago) by jcfr
ENH: Add convenient command line flag --attach-process

* If passed, Slicer will popup a message box just before starting the
initialization of qSlicerCoreApplication. This could be used to attach
a debugger in order to debug issue happening at startup time.

* The message also indicates what the current Process Id.

Revision 19433  Directory Listing
Modified Mon Feb 27 08:16:55 2012 UTC (5 years, 6 months ago) by jcfr
ENH: Remove "legacy" extension wizard

* The "ExtensionManager" menu item is also hidden

Revision 19432  Directory Listing
Modified Mon Feb 27 08:16:52 2012 UTC (5 years, 6 months ago) by jcfr
ENH: Add ExtensionManagerWidget allowing to install/uninstall extensions

Revision 19431  Directory Listing
Modified Mon Feb 27 08:16:48 2012 UTC (5 years, 6 months ago) by jcfr
ENH: Improve usability by adding a dedicated settings panel for extensions options

* Currently it allows the user to set:
 - Extensions/InstallPath
 - Extensions/ServerUrl

Revision 19430  Directory Listing
Modified Mon Feb 27 08:16:45 2012 UTC (5 years, 6 months ago) by jcfr
ENH: qSlicerCoreApplication - Add method allowing to set/get extensionsManagerModel

* Note also that a model is created in the qSlicerCoreApplicationPrivate::init()
method. It means that calling extensionManagerModel() on a newly
instantiated qSlicerCoreApplication will return a valid model.

Revision 19429  Directory Listing
Modified Mon Feb 27 08:16:41 2012 UTC (5 years, 6 months ago) by jcfr
ENH: Add ExtensionManagerModel allowing to install/uninstall extensions

Revision 19428  Directory Listing
Modified Mon Feb 27 08:16:36 2012 UTC (5 years, 6 months ago) by jcfr
ENH: Ensure environment variable associated with launcher are considered on restart

* Update the "restart()" method to use "launcherExecutableFilePath()"
if it points to an existing file.

Revision 19427  Directory Listing
Modified Mon Feb 27 08:16:34 2012 UTC (5 years, 6 months ago) by jcfr
STYLE: Re-organize code allowing to make sure extensions install directory exists

* Decouple the creation of the directory from the method "extensionsInstallPath"

* Use more robust way to compose the default extension path. It now
relies on dir()/filePath() methods.

Revision 19423  Directory Listing
Modified Mon Feb 27 08:16:26 2012 UTC (5 years, 6 months ago) by jcfr
ENH: Improve qSlicerCoreApplication API allowing to set/get extension install path

Revision 19422  Directory Listing
Modified Mon Feb 27 08:16:23 2012 UTC (5 years, 6 months ago) by jcfr
ENH: Improve settings organization related to Extensions

* Extensions settings are now stored in their own group.

Revision 19421  Directory Listing
Modified Mon Feb 27 08:16:21 2012 UTC (5 years, 6 months ago) by jcfr
ENH: Add "launcherExecutableFilePath()" and "launcherSettingsFilePath()" methods to qSlicerCoreApplication

* Note that it's plan to modify the slicerHome() method so that
it returns a QDir.

* Then, code like:

 return this->slicerHome() + "/Slicer" + qSlicerUtils::executableExtension();

will be changed into:

 return this->slicerHome().filePath(QString("Slicer%1").arg(qSlicerUtils::executableExtension());

Revision 19420  Directory Listing
Modified Mon Feb 27 08:16:18 2012 UTC (5 years, 6 months ago) by jcfr
ENH: Remove extensions related settings from Modules panel

* A panel specific to extension will be integrated later.

Revision 19419  Directory Listing
Modified Mon Feb 27 08:16:16 2012 UTC (5 years, 6 months ago) by jcfr
STYLE: Improve qSlicerCoreApplication documentation by updating doxygen comment

* Also use the "see also" doxygen tag '\sa'

Revision 19418  Directory Listing
Modified Mon Feb 27 08:16:14 2012 UTC (5 years, 6 months ago) by jcfr
ENH: Add "os()" and "arch()" to qSlicerCoreApplication

Revision 19408  Directory Listing
Modified Mon Feb 27 01:36:34 2012 UTC (5 years, 6 months ago) by jcfr
BUG: IntDir is now set properly when qSlicerCoreApplication is used from CLI modules.

* This will accommodate module like EMSegmentCommandLine that are
instantiating qSlicerCoreApplication.

Revision 19396  Directory Listing
Modified Sun Feb 26 04:50:32 2012 UTC (5 years, 7 months ago) by finetjul
BUG: Fix generic tests for loadable modules resource dependent

qSlicerMultiVolumeModule is one of them, it needs to find the python path
to instantiate the module widget.

Revision 19392  Directory Listing
Modified Sat Feb 25 22:05:33 2012 UTC (5 years, 7 months ago) by finetjul
BUG: Remove favorite module was not working when module name != title

Support favorite module removal with delete key.
Add more explicit tooltips

Revision 19388  Directory Listing
Modified Sat Feb 25 21:23:22 2012 UTC (5 years, 7 months ago) by fedorov
ENH: expose index property to be able to order scripted modules of the same category

Revision 19387  Directory Listing
Modified Sat Feb 25 19:34:42 2012 UTC (5 years, 7 months ago) by finetjul
ENH: Control Favorites Modules in toolbar using settings

Revision 19383  Directory Listing
Modified Sat Feb 25 07:53:59 2012 UTC (5 years, 7 months ago) by finetjul
ENH: Modules filter was counter intuitive

Checked filter button now means show.
Resize the filter panel to a smaller width that doesn't expand.

Revision 19379  Directory Listing
Modified Sat Feb 25 00:05:59 2012 UTC (5 years, 7 months ago) by pohl
BUG: Not all widgets where loaded in under windows

Revision 19377  Directory Listing
Modified Fri Feb 24 22:36:20 2012 UTC (5 years, 7 months ago) by finetjul
ENH: Add --testing launcher argument

By being in testing mode, it uses different settings than user settings.

Revision 19376  Directory Listing
Modified Fri Feb 24 20:48:18 2012 UTC (5 years, 7 months ago) by wjp@bwh.harvard.edu
ENH: adding requested icon mods

Revision 19371  Directory Listing
Modified Fri Feb 24 18:54:48 2012 UTC (5 years, 7 months ago) by finetjul
ENH: Don't restart Slicer if the modules to ignore are not changed

Revision 19368  Directory Listing
Modified Fri Feb 24 08:53:37 2012 UTC (5 years, 7 months ago) by finetjul
ENH: Add show/hide filters to modules list in settings

Revision 19361  Directory Listing
Modified Fri Feb 24 02:41:32 2012 UTC (5 years, 7 months ago) by pieper
BUG: wrong arguments to python api

Revision 19360  Directory Listing
Modified Thu Feb 23 23:45:35 2012 UTC (5 years, 7 months ago) by jcfr
COMP: Add missing include

* Including the "algorithm" header allow to compile properly on linux (ubuntu 10.04, gcc 4.4.3)

Revision 19359  Directory Listing
Modified Thu Feb 23 23:34:08 2012 UTC (5 years, 7 months ago) by finetjul
BUG: Enable "Apply" button after cancelling a module

Closes #1651

Revision 19358  Directory Listing
Modified Thu Feb 23 23:15:58 2012 UTC (5 years, 7 months ago) by jcfr
BUG: qSlicerScriptedLoadableModuleWidget - Use PyRun_{Open|Close}File on windows

* Even if Slicer is built in Debug mode, python is built in Release mode.
Windows doesn't like when data is instantiated in a Debug
library (qSlicerScriptedLoadableModule -> fopen) and then used in
a Release library (python26 -> PyRun_File()).

Revision 19357  Directory Listing
Modified Thu Feb 23 22:18:48 2012 UTC (5 years, 7 months ago) by finetjul
ENH: Module factory manager handles more use cases.

Support failed to load modules (in red)
Unload modules in the reverse order they were loaded.
No duplicated module (if registered when factory manager was set, and
initialized after that).

Revision 19346  Directory Listing
Modified Thu Feb 23 01:54:09 2012 UTC (5 years, 7 months ago) by finetjul
ENH: Make the "ignore modules" setting more understandable

Revision 19341  Directory Listing
Modified Wed Feb 22 20:51:59 2012 UTC (5 years, 7 months ago) by wjp@bwh.harvard.edu
ENH: finishing up misc icons for file menu

Revision 19337  Directory Listing
Modified Wed Feb 22 19:23:54 2012 UTC (5 years, 7 months ago) by finetjul
COMP: Missing header inclusion in qSlicerAbstractModuleFactoryManager

#include <typeinfo> was missing

Revision 19336  Directory Listing
Modified Wed Feb 22 19:23:53 2012 UTC (5 years, 7 months ago) by finetjul
STYLE: Align center of Copyright cells

Nudge the layout.

Revision 19334  Directory Listing
Modified Wed Feb 22 18:13:00 2012 UTC (5 years, 7 months ago) by finetjul
ENH: Register factories and scan directories only once.

Only module names (QString) can be used as method/slot parameters. No module
pointer directly.

Move module registration/instantiation/loading in a unique factory manager class.
qSlicerModuleManager is a placeholder for module specific actions with the scene
and the application: "Edit properties...", setCurrentModule, ...

Add modulesToIgnore property to prevent modules from being loaded for
performance (and clarity) reasons.

Revision 19331  Directory Listing
Modified Wed Feb 22 16:38:21 2012 UTC (5 years, 7 months ago) by joe.snyder
ENH: Update Slicer 'About' dialog links

Added the correct Html code to make the "NIHRoadmap" a working link.
Corrected the library links to not include spaces as part of the
link.
Add an HTML table to the SlicerLinksTextBrowser to eliminate the need for
manually spacing the links.

Revision 19325  Directory Listing
Modified Tue Feb 21 20:33:12 2012 UTC (5 years, 7 months ago) by wjp@bwh.harvard.edu
ENH: using smaller versions of load/save toolbar icons for crisper presentation

Revision 19324  Directory Listing
Modified Tue Feb 21 20:30:34 2012 UTC (5 years, 7 months ago) by wjp@bwh.harvard.edu
ENH: made smaller version of icons for crisper presentation

Revision 19323  Directory Listing
Modified Tue Feb 21 20:29:07 2012 UTC (5 years, 7 months ago) by wjp@bwh.harvard.edu
ENH: new icons for load/save toolbar

Revision 19317  Directory Listing
Modified Tue Feb 21 03:56:00 2012 UTC (5 years, 7 months ago) by wjp@bwh.harvard.edu
ENH: Modifying Slicer's load/save toolbar as per Ron's request

Revision 19316  Directory Listing
Modified Tue Feb 21 03:53:30 2012 UTC (5 years, 7 months ago) by wjp@bwh.harvard.edu
ENH: modifying icons for the Load/Save toolbar in Slicer

Revision 19304  Directory Listing
Modified Fri Feb 17 20:09:27 2012 UTC (5 years, 7 months ago) by millerjv
BUG: LlghtPaleChartColors was actually converted from the wiki page.

The file was a mistakenly a duplicate of the MediumChartColors.txt

Revision 19303  Directory Listing
Modified Fri Feb 17 19:45:28 2012 UTC (5 years, 7 months ago) by millerjv
ENH: new color tables for charts based on paper by Stephen Few

Revision 19290  Directory Listing
Modified Tue Feb 14 21:38:09 2012 UTC (5 years, 7 months ago) by joe.snyder
STYLE: Improve layout of 'About dialog'

Change the image used in the 'About' dialog from the splash screen to the vertical logo.
Remove the button from the bottom of the dialog box.
Change the layout of the box from a verical layout (QVBoxLayout) to a horizonal one (QHBoxLayout).

Change the QTextEdit box used in the dialog to a QTextBrowser which lets HTML links be clickable.

Change the qSlicerAboutDialog.cxx to have have the QText browser change the size of the font for
more impotant text and to change the order to put the thanks text above the copyright messages.

Change the qSlicerCoreApplication pair to include a new function called 'thanks' which returns
the thanks text in the About dialog, this was created to separate this text from the copyrights
text.  Also change the 'copyrights' text to be in HTML with the links taking you to each of
the used libraries main page.

Revision 19276  Directory Listing
Modified Mon Feb 13 16:50:28 2012 UTC (5 years, 7 months ago) by jcfr
STYLE: In CLI description, 'description' and 'acknowledgment' tags are wrapped using CData

* Doing so allow to embed HTML tag within the XML description.

* Using the previously escaped version where '<p>' was written like '&lt;p&gt;'
was also valid but less easy to read and maintain.

* See https://en.wikipedia.org/wiki/CDATA#CDATA_sections_in_XML

Revision 19272  Directory Listing
Modified Sun Feb 12 21:56:07 2012 UTC (5 years, 7 months ago) by finetjul
ENH: Add vtkMRMLColorLogic::GetDefaultChartNodeID

Revision 19268  Directory Listing
Modified Thu Feb 9 23:55:40 2012 UTC (5 years, 7 months ago) by finetjul
STYLE: Move Slicer color logic into Colors module

Revision 19265  Directory Listing
Modified Thu Feb 9 18:18:23 2012 UTC (5 years, 7 months ago) by pieper
BUG: handle case where a toplevel widget has no name attribute

Revision 19253  Directory Listing
Modified Tue Feb 7 22:03:13 2012 UTC (5 years, 7 months ago) by millerjv
ENH: allow a ColorNode to be assigned to a Chart or to an Array

Added a default color table for Slicer Charts, GenericChartColors.txt

ColorNodes can be assigned to a chart which will assign the colors for
each series.

ColorNodes can be assigned to an array which for bar charts (and perhaps
someday pie charts) will allow each bar to be colored differently.

Revision 19248  Directory Listing
Modified Tue Feb 7 16:08:05 2012 UTC (5 years, 7 months ago) by finetjul
STYLE: Rename qSlicerModuleTest1.py.in into qSlicerModuleGenericTest.py.in

Move testing of Modules/Scripted/Scripts into a Python subdirectory

Revision 19241  Directory Listing
Modified Tue Feb 7 05:20:58 2012 UTC (5 years, 7 months ago) by finetjul
STYLE: Rename qSlicerAbstractCoreModule::contributor to contributors

Revision 19239  Directory Listing
Modified Tue Feb 7 04:01:16 2012 UTC (5 years, 7 months ago) by jcfr
COMP: Use "std" version of vector, string and sstream.

* This class are now consistenly used accross the code base. There is no
more mix of both vtksys and std headers.

* See http://www.vtk.org/pipermail/vtk-developers/2012-February/010806.html

* Details of the updates:

 #include <vtksys/ios/sstream> -> #include <sstream>
 vtksys_ios::ostringstream     -> std::ostringstream

 #include <vtksys/stl/string> -> #include <string>
 vtksys_stl::string           -> std::string


 #include <vtkstd/vector> -> #include <vector>
 vtksys_stl::vector       -> std::vector

Revision 19238  Directory Listing
Modified Tue Feb 7 03:42:35 2012 UTC (5 years, 7 months ago) by jcfr
ENH: Clean XML description file

* Remove empty lines

* Fix indent

* See https://github.com/jcfr/Scriptacular/blob/master/trimxml.py
and https://github.com/jcfr/Scriptacular/blob/master/trimxml.sh

Revision 19232  Directory Listing
Modified Mon Feb 6 23:28:14 2012 UTC (5 years, 7 months ago) by finetjul
ENH: Improve generic module tests

qSlicerAbstractCoreModule::categories() and contributor() are mandatory
minimumSizeHint width is 500px

Revision 19229  Directory Listing
Modified Mon Feb 6 23:20:38 2012 UTC (5 years, 7 months ago) by finetjul
BUG: Fix width of module panel

The dock widget could resize to a size smaller than the "minimumSizeHint"
of the module representations. Because the modules are contained by a
 scrollarea, the size hints don't work properly, they must be reimplemented.
Note that the sizing of a dockwidget or a scrollarea is controlled by the
observed widget (QDockWidget::widget() or QScrollArea::widget()). There
is no impact to change teh size policy of the dockwidget or scrollarea
directly.

Closes #1681

Revision 19226  Directory Listing
Modified Mon Feb 6 21:04:30 2012 UTC (5 years, 7 months ago) by jcfr
ENH: Update slicerpackages web API call to match new naming convention

Revision 19225  Directory Listing
Modified Mon Feb 6 21:04:28 2012 UTC (5 years, 7 months ago) by jcfr
ENH: Extensions are now downloaded from Midas instead of CDash

* Use qMidasAPI library instead of qCDashAPI

* Configuring an extension description file using package name is not required
anymore. Metadata associated with a package will be directly sent to MIDAS
using the web API.

Revision 19223  Directory Listing
Modified Mon Feb 6 21:04:23 2012 UTC (5 years, 7 months ago) by jcfr
ENH: vtkArchive::extract_tar now returns the list of extracted files.

Revision 19146  Directory Listing
Modified Fri Jan 27 22:57:24 2012 UTC (5 years, 7 months ago) by pieper
BUG: check for reported error condition (bug 1667) where image data is deleted but still in data structure

Revision 19133  Directory Listing
Modified Wed Jan 25 20:25:28 2012 UTC (5 years, 8 months ago) by finetjul
ENH: Add support for modules to be in more than 1 category

Categories are a way to "sort" modules, a module can semantically be part of
multiple categories.

Rename QString qSlicerAbstractCoreModule::category into
QStringList qSlicerAbstractCoreModule::categories

Issue #1602

Revision 19125  Directory Listing
Modified Sun Jan 22 07:02:56 2012 UTC (5 years, 8 months ago) by finetjul
STYLE: Expose the color logic to the qMRMLColorPickerWidget API

Revision 19123  Directory Listing
Modified Fri Jan 20 23:49:29 2012 UTC (5 years, 8 months ago) by finetjul
STYLE: Move vtkSlicerModelsLogic into Models module logic

Revision 19122  Directory Listing
Modified Fri Jan 20 23:49:26 2012 UTC (5 years, 8 months ago) by finetjul
STYLE: Move Hierarchy node automatic removal into hiearchylogic

instead of in the tree view.
This has the benefit to remove the hierarchy dependency in the treeview.
That method was not scalable for other nodes.
The mechanism already exists in vtkSlicerModelsLogic to remove displayable
and storage nodes automatically.

Revision 19115  Directory Listing
Modified Fri Jan 20 21:09:21 2012 UTC (5 years, 8 months ago) by finetjul
ENH: vtkMRMLTransformableNode::SetAndObserveTransformNodeID automatically fires TransformModifiedEvent

It used to be the caller's responsibility which was not systematic. It is now done automatically.

Avoid cycles when setting a transform to a transformable node.

Revision 19111  Directory Listing
Modified Fri Jan 20 17:31:37 2012 UTC (5 years, 8 months ago) by naucoin
ENH: add in ability to remove annotation nodes from the selection node, and deal with the reduced list of nodes in the mouse mode tool bar, adding a test

Revision 19108  Directory Listing
Modified Fri Jan 20 02:22:30 2012 UTC (5 years, 8 months ago) by finetjul
BUG: Don't use vtkMRMLScene::AddNodeNoNotify

Adding a node to the scene should always fire events. It's the observer's
role to decide whether it ignores the event or not.

If performance is an issue,
vtkMRMLScene::Start/EndState(vtkMRMLScene::BatchProcessState) can be
used to inform the scene observers that a lot of changes (node insertion, removals) is happening.

Closes #1633

Revision 19099  Directory Listing
Modified Wed Jan 18 20:57:36 2012 UTC (5 years, 8 months ago) by pieper
BUG: avoid run-time warning due to new widget type (chart) that has a text property of None rather than empty string

Revision 19095  Directory Listing
Modified Tue Jan 17 20:06:45 2012 UTC (5 years, 8 months ago) by finetjul
STYLE: Add tooltip to the label of CLI module parameter label.

Give the same tooltip as the optional widget.
Take the opportunity to refactorize the code.

Revision 19078  Directory Listing
Modified Fri Jan 13 00:24:37 2012 UTC (5 years, 8 months ago) by jcfr
ENH: Scripted loadable module can now specify module dependencies.

* It could be achieved using the following syntax:

class Foo:
  def __init__( self, parent ):
    parent.title = """Foo"""
    parent.category = """Wizards"""
    parent.dependencies = ['Bar']

Revision 19076  Directory Listing
Modified Thu Jan 12 21:55:20 2012 UTC (5 years, 8 months ago) by jcfr
ENH: Make sure python error are printed after each invocation of "PyObject_CallObject"

* Note that is may be a better way of achieving this. There is probably some
sort of hook to catch error.

Revision 19073  Directory Listing
Modified Thu Jan 12 20:38:13 2012 UTC (5 years, 8 months ago) by jcfr
COMP: Since r18229, linking BaseQTCore against CTKDICOMCore is not required.

See http://viewvc.slicer.org/viewvc.cgi/Slicer4?view=revision&revision=18229

Revision 19067  Directory Listing
Modified Thu Jan 12 07:42:56 2012 UTC (5 years, 8 months ago) by jcfr
STYLE: Scripted loadable module factory - Rename variable "modulePath" into "modulePathWithoutIntDir"

Revision 19066  Directory Listing
Modified Thu Jan 12 07:42:53 2012 UTC (5 years, 8 months ago) by jcfr
BUG: Loadable factory - On multi-configuration system, the path comprising "Intermediate directory" should be added to PYTHON_PATH

Revision 19064  Directory Listing
Modified Thu Jan 12 05:56:03 2012 UTC (5 years, 8 months ago) by inorton
BUG: revert changes to SliceViewInteractorStyle because the editor and annotation nodes do not get the events. re-enable tcl w/l hanlder until some better fix is developed

Revision 19062  Directory Listing
Modified Wed Jan 11 22:05:37 2012 UTC (5 years, 8 months ago) by jcfr
BUG: Make sure Scripted module factory update PYTHON_PATH

* This will allow scripted module to import "python module" located
in the same folder.

Revision 19053  Directory Listing
Modified Mon Jan 9 23:13:34 2012 UTC (5 years, 8 months ago) by inorton
ENH: remove VolumeDisplaySWidget, now w/l control is in c++ code

Revision 19048  Directory Listing
Modified Mon Jan 9 07:35:29 2012 UTC (5 years, 8 months ago) by finetjul
COMP: Fix various compilation warnings

Revision 19042  Directory Listing
Modified Sun Jan 8 04:41:11 2012 UTC (5 years, 8 months ago) by jcfr
COMP: Remove empty directories

Revision 19040  Directory Listing
Modified Sun Jan 8 04:34:35 2012 UTC (5 years, 8 months ago) by jcfr
COMP: Move Core modules from "Base/QtCoreModules" into "Modules/Core"

* All Slicer modules are now all located in the Modules subdirectory

Revision 19039  Directory Listing
Modified Sun Jan 8 02:57:31 2012 UTC (5 years, 8 months ago) by finetjul
STYLE: Add Cameras module documentation

Revision 19026  Directory Listing
Modified Fri Jan 6 01:51:47 2012 UTC (5 years, 8 months ago) by finetjul
ENH: Python module unittest now instantiates the widget

Module widget is only instantiated the first time the module is set current

Revision 19018  Directory Listing
Modified Thu Jan 5 01:58:57 2012 UTC (5 years, 8 months ago) by finetjul
COMP: Install the Qt plugins in the same location lib/QtPlugins

qt.conf doesn't support more than 1 plugin path so the plugins must be
in a unique location ?

Revision 19012  Directory Listing
Modified Wed Jan 4 05:33:18 2012 UTC (5 years, 8 months ago) by finetjul
COMP: Use ctkMacroBuildQtPlugin.cmake to build designer plugins

Use also ctkMacroBuildQtPlugin.cmake to build iconengines plugins.

Revision 19007  Directory Listing
Modified Sat Dec 31 22:47:11 2011 UTC (5 years, 8 months ago) by finetjul
ENH: Allow Qt events to be processed before executing python code

This gives time for the views to render at least one (initialize the openGL
buffer) in case the script needs to do some action in the view.

Revision 19006  Directory Listing
Modified Sat Dec 31 22:47:09 2011 UTC (5 years, 8 months ago) by finetjul
ENH: ctkConfirmExitDialog is obsolete, ctkMessageBox is the new version

Move the disclaimer dialog in the main window.

Revision 19004  Directory Listing
Modified Fri Dec 30 20:06:57 2011 UTC (5 years, 8 months ago) by Michael.jeulinl
STYLE: Allow Drag & Drop to add data from the explorer.

Change comments and group drag&drop functions.
Declare qSlicerDataDialog as friend in the pimple as it is not possible
to make a Q_DECLARE_PUBLIC due to the following:
FIXME give qSlicerDataDialog as a parent of qSlicerDataDialogPrivate;

Revision 19003  Directory Listing
Modified Fri Dec 30 18:33:44 2011 UTC (5 years, 8 months ago) by Michael.jeulinl
ENH: Allow Drag & Drop to add data from the explorer.

Authorize the drag&drop action within qSlicerMainWindow and qSlicerDataDialog.

Revision 18996  Directory Listing
Modified Wed Dec 28 00:28:04 2011 UTC (5 years, 8 months ago) by finetjul
BUG: Python utility cli function createNode takes a module not a name

Revision 18990  Directory Listing
Modified Tue Dec 27 16:28:22 2011 UTC (5 years, 9 months ago) by finetjul
BUG: Memory leak when using vtkSlicerCLIModuleLogic::CreateNode

The returned node in CreateNode() needs to be manually deleted by the caller.
To prevent that requirement and to restore the original behavior,
CreateNodeInScene() adds the node into the scene.
The caller still (optionally) needs to remove the node from the scene.

Revision 18986  Directory Listing
Modified Mon Dec 26 17:21:46 2011 UTC (5 years, 9 months ago) by jcfr
STYLE: Use C++ header

See http://viewvc.slicer.org/viewvc.cgi/Slicer4?view=revision&revision=18967

Revision 18985  Directory Listing
Modified Mon Dec 26 17:21:44 2011 UTC (5 years, 9 months ago) by jcfr
ENH: Use "SetMRMLApplicationLogic" and remove extra method "SetApplicationLogic"

Revision 18980  Directory Listing
Modified Sat Dec 24 07:32:51 2011 UTC (5 years, 9 months ago) by finetjul
ENH: Remove vtkSlicerCropVolumeLogic dependency on the module manager

It should be the CropVolume module that sets the ResampleVolume2 module logic to the CropVolumeLogic, and not the CropVolumeLogic that searches for the ResampleVolume2 module and take its logic.
Remove any logic from qSlicerCLIModule, and move it into vtkSlicerCLIModuleLogic (CreateNode)
Move the default ModuleDescription into the cli module logic (instead of the widget).
Remove unused CLIModuleWidget properties such as Name, Category, Contributor
Don't store default module description properties in the cli module widget but query them when needed (Title and ParametersGroups)

Revision 18978  Directory Listing
Modified Sat Dec 24 05:26:34 2011 UTC (5 years, 9 months ago) by finetjul
ENH: Add dependencies between modules

In order for modules to initialize their logics that depend on other module logics, the modules must be initialized in a specific order controlled by the graph of module dependencies.
The logics shouldn't have to access data from the application, if they need a logic, it should be set externally by the logic instantiator (in the case of vtkSlicerCropVolumeLogic it is qSlicerCropVolumeModule).
The CLI module logic still needs to be split away from the module (in a comming commit).

Revision 18977  Directory Listing
Modified Fri Dec 23 23:26:46 2011 UTC (5 years, 9 months ago) by naucoin
ENH: add an annotation file

Revision 18973  Directory Listing
Modified Fri Dec 23 06:36:51 2011 UTC (5 years, 9 months ago) by finetjul
COMP: Typo in the name of the help and acknowledgementText properties

Revision 18972  Directory Listing
Modified Fri Dec 23 02:37:05 2011 UTC (5 years, 9 months ago) by finetjul
ENH: Remove qSlicerAbstractCoreModule::enabled

It is historic and not used anywhere in Slicer.
Add doc for acknowledgement/help

Revision 18971  Directory Listing
Modified Fri Dec 23 02:19:13 2011 UTC (5 years, 9 months ago) by finetjul
STYLE: Add property doc to qSlicerAbstractCoreModule API

Revision 18970  Directory Listing
Modified Thu Dec 22 23:09:35 2011 UTC (5 years, 9 months ago) by finetjul
BUG: Fix main window toolbar buttons style to support Qt::ToolButtonTextUnderIcon

The tool button style is controlled in the Advanced Settings General panel.

From Qt 4.6.3 doc:
QToolBar::toolButtonStyle - "Note that if you add a QToolButton with the addWidget() method, it will not get this button style"

The following behavior does not seem  to work:
QToolButton::toolButtonStyle - QToolButton automatically connects this slot to the relevant signal in the QMainWindow in which is resides.

Revision 18967  Directory Listing
Modified Tue Dec 20 22:20:05 2011 UTC (5 years, 9 months ago) by jcfr
COMP: Change stdio.h, errno.h, stdlib.h into their corresponding c++ includes.

See http://www.cplusplus.com/reference/clibrary/

The C++ library includes the same definitions as the C language library
organized in the same structure of header files, with the following
differences:

    Each header file has the same name as the C language version but
with a "c" prefix and no extension. For example, the C++ equivalent
for the C language header file <stdlib.h> is <cstdlib>.
    Every element of the library is defined within the std namespace.

Nevertheless, for compatibility with C, the traditional header names
name.h (like stdlib.h) are also provided with the same definitions
within the global namespace. In the examples provided in this reference,
this version is used so that the examples are fully C-compatible,
although its use is deprecated in C++.

Revision 18962  Directory Listing
Modified Tue Dec 20 19:35:36 2011 UTC (5 years, 9 months ago) by jcfr
COMP: Rename variable Slicer_*_VERSION into Slicer_VERSION_* to be consistent with CMake convention.

See http://www.cmake.org/cmake/help/cmake-2-8-docs.html#command:find_package

Revision 18961  Directory Listing
Modified Tue Dec 20 16:08:40 2011 UTC (5 years, 9 months ago) by jcfr
COMP: Explicitly list VTK dependencies (in attempt) to avoid overlinking

* Overlinking has multiple issues:
      - Packaging is more difficult
      - Debugging dependency issue is more tedious
      - Loading time of binaries could increase

Revision 18955  Directory Listing
Modified Mon Dec 19 22:42:31 2011 UTC (5 years, 9 months ago) by finetjul
BUG: Don't instantiate widgets if Slicer is run in no-mainwindow mode

Revision 18946  Directory Listing
Modified Thu Dec 15 23:44:04 2011 UTC (5 years, 9 months ago) by benjamin.long
ENH: Set object name of the different dialogs

* This is done anticipating the integration of QtTesting

Revision 18944  Directory Listing
Modified Thu Dec 15 23:44:00 2011 UTC (5 years, 9 months ago) by benjamin.long
BUG: ModuleSelectorToolBar - Parent of qSlicerModulesMenu should be ctkMenuComboBox

* Doing so allows QtTesting framework to work adequately

Revision 18941  Directory Listing
Modified Thu Dec 15 20:10:14 2011 UTC (5 years, 9 months ago) by jcfr
COMP: Change minimum required version of CMake 2.8.4

* This is now consistent to the documented requirement.
See http://wiki.slicer.org/slicerWiki/index.php?title=Documentation/4.0/Developers/Build_Instructions&oldid=22880

Revision 18931  Directory Listing
Modified Thu Dec 15 07:45:25 2011 UTC (5 years, 9 months ago) by jcfr
ENH: Add Slicer_BUILD_EXTENSIONMANAGER_SUPPORT option

* If disabled:
 - extension manager won't be integrated
 - external project qCDashAPI and LibArchive won't be checkedout

Revision 18929  Directory Listing
Modified Thu Dec 15 07:45:18 2011 UTC (5 years, 9 months ago) by jcfr
COMP: Add Slicer_BUILD_CLI_SUPPORT

* When disabled, neither the CLI factories or the CLI modules will be built.

Revision 18926  Directory Listing
Modified Thu Dec 15 02:59:22 2011 UTC (5 years, 9 months ago) by jcfr
STYLE: Remove unused code

Revision 18919  Directory Listing
Modified Wed Dec 14 14:20:33 2011 UTC (5 years, 9 months ago) by finetjul
BUG: Don't execute module tests if no CLI is built

Revision 18913  Directory Listing
Modified Tue Dec 13 14:21:42 2011 UTC (5 years, 9 months ago) by finetjul
BUG: Inverted logic when checking if cli modules are enabled

Revision 18911  Directory Listing
Modified Mon Dec 12 22:42:42 2011 UTC (5 years, 9 months ago) by finetjul
ENH: More verbose outputs for CLI XML description parsing

Revision 18909  Directory Listing
Modified Mon Dec 12 20:04:44 2011 UTC (5 years, 9 months ago) by jcfr
COMP: Fix typo - Add missing double quote

Revision 18906  Directory Listing
Modified Mon Dec 12 14:24:03 2011 UTC (5 years, 9 months ago) by finetjul
BUG: qSlicerCLIModuleTest1 must fail when CLIs are disabled

Revision 18905  Directory Listing
Modified Mon Dec 12 14:16:57 2011 UTC (5 years, 9 months ago) by pieper
BUG: set global variable used by some tests and scripts

Revision 18902  Directory Listing
Modified Sun Dec 11 23:24:59 2011 UTC (5 years, 9 months ago) by finetjul
STYLE: Update link to acknowledgments

Revision 18901  Directory Listing
Modified Sat Dec 10 23:30:30 2011 UTC (5 years, 9 months ago) by finetjul
BUG: Python module names are not lowercase

However, they are accessible with their lowercase version
(i.e. slicer.modules.modulenameinlowercase) in python.
DICOM2FullBrainTractographyModuleTest1 was failing

Revision 18896  Directory Listing
Modified Sat Dec 10 01:08:08 2011 UTC (5 years, 9 months ago) by finetjul
STYLE: Decrease confusion by renaming slicer home TCL variable

The TCL variable confusively looks a lot like the environment variable
SLICER_HOME, it is renamed to give a more propert name.

Revision 18895  Directory Listing
Modified Fri Dec 9 20:53:54 2011 UTC (5 years, 9 months ago) by finetjul
ENH: Remove vtkMRMLScene::ActiveScene

The current MRML scene should be set to a logic via SetMRMLScene().
Logics shouldn't try to guess what is the current scene.
If really there is a need for it, it is still accessible from the vtkMRMLApplicationLogic singleton.

Revision 18894  Directory Listing
Modified Fri Dec 9 16:21:51 2011 UTC (5 years, 9 months ago) by finetjul
COMP: Fix various warnings (Debug + Release)

Mostly unused or initialized variable.

Revision 18878  Directory Listing
Modified Thu Dec 8 06:08:35 2011 UTC (5 years, 9 months ago) by finetjul
ENH: Add generic way to handle batch node insertion/removal in vtkMRMLScene

vtkMRMLScene has now a notion of state. If the scene is loading a mrml scene file, its state is ImportState( ::BatchProcessState

The previous scene behavior has been kept (pseudo backward compatible), the scene still fires the same (renamed) events for each Close, Import and Restore calls.
Events have been renamed:
 SceneAboutToBeClosedEvent -> StartCloseEvent
 SceneClosedEvent -> EndCloseEvent
 SceneAboutToBeImportedEvent -> StartImportEvent
 SceneImportedEvent -> EndImportEvent
 SceneAboutToBeRestoredEvent -> StartRestoreEvent
 SceneRestoredEvent -> EndRestoreEvent

New events are added:
 - StartBatchProcessEvent: notably (but not only) fired when StartCloseEvent, StartImportEvent, and StartRestoredEvent are fired
 - EndBatchProcessEvent: notably (but not only) fired when EndCloseEvent, EndImportEvent, and EndRestoredEvent are fired
 - ProgressBatchProcessEvent, ProgressCloseEvent, ProgressImportEvent, ProgressRestoreEvent: not yet fired
 - StartSaveEvent: fired when the scene starts to be saved
 - EndSaveEvent: fired when the scene finished to be saved

StartState(vtkMRMLScene::StateType) and EndState(vtkMRMLScene::StateType) control the scene state. Nested states are supported, but each state events are fired only once (e.g. two successive call to StartState(BatchProcessState) fire StartBatchProcessEvent only once).
Internally, the methods Clear(), Connect(), Import() and Commit() set the scene states.
In addition, the state can be set externally by any node (e.g. vtkMRMLSceneViewNode) or logic (e.g. vtkMRMLColorLogic)

Preliminary work has been started to fire progress events, but it hasn't been completed (needs to be implemented in AddNode(), RemoveNode(), Import() and Close()).

Revision 18875  Directory Listing
Modified Wed Dec 7 22:15:48 2011 UTC (5 years, 9 months ago) by finetjul
COMP: Error including qMRMLWidgets.qrc in Base/QTGUI

MRMLWidgets_SOURCE_DIR doesn't exist, qMRMLWidgets_SOURCE_DIR does

Revision 18872  Directory Listing
Modified Wed Dec 7 12:28:43 2011 UTC (5 years, 9 months ago) by jcfr
BUG: mrml.py - Import MRMLCorePythonD instead of MRMLPythonD

Revision 18869  Directory Listing
Modified Tue Dec 6 20:53:50 2011 UTC (5 years, 9 months ago) by jcfr
BUG: qSlicerCoreApplication - Initialize pythonQt only if pythonManager is valid

Revision 18866  Directory Listing
Modified Tue Dec 6 20:53:14 2011 UTC (5 years, 9 months ago) by jcfr
COMP: Move all MRML libraries into Libs/MRML sub-directory

* Also rename MRML library into MRMLCore library

Revision 18865  Directory Listing
Modified Tue Dec 6 20:50:21 2011 UTC (5 years, 9 months ago) by jcfr
COMP: Remove unused files

Revision 18864  Directory Listing
Modified Tue Dec 6 20:49:19 2011 UTC (5 years, 9 months ago) by jcfr
COMP: Source code of all modules is now located in Modules sub-directory

Revision 18819  Directory Listing
Modified Tue Dec 6 00:09:42 2011 UTC (5 years, 9 months ago) by jcfr
COMP: Move qSlicerExport.h.in into CMake sub-directory

Revision 18804  Directory Listing
Modified Mon Dec 5 21:24:43 2011 UTC (5 years, 9 months ago) by jcfr
COMP: qSlicerCoreApplication - Include updatePythonOsEnviron if both Slicer_USE_PYTHONQT and Q_WS_WIN are defined

Revision 18794  Directory Listing
Modified Fri Dec 2 01:36:09 2011 UTC (5 years, 9 months ago) by finetjul
STYLE: vtkMRMLScene doesn't inherit from vtkCollection but vtkObject

The nodes are contained in vtkCollection* vtkMRMLScene::Nodes

Revision 18783  Directory Listing
Modified Mon Nov 28 23:45:41 2011 UTC (5 years, 9 months ago) by pieper
BUG: fix to adapt to API change

Revision 18762  Directory Listing
Modified Thu Nov 24 22:22:24 2011 UTC (5 years, 10 months ago) by jcfr
ENH: Initialization of python context done within qSlicerCoreApplication

Revision 18744  Directory Listing
Modified Wed Nov 23 15:05:24 2011 UTC (5 years, 10 months ago) by finetjul
STYLE: Change the url text of the CLI online help

Revision 18734  Directory Listing
Modified Tue Nov 22 23:09:32 2011 UTC (5 years, 10 months ago) by finetjul
ENH: Add <a> html tag to link on CLI online documentation in the help tab

Revision 18720  Directory Listing
Modified Mon Nov 21 22:21:24 2011 UTC (5 years, 10 months ago) by pieper
BUG: fix radius update of paint brush to address bug 1534

Revision 18717  Directory Listing
Modified Mon Nov 21 21:49:53 2011 UTC (5 years, 10 months ago) by pieper
ENH: allow searching for children by class name

Revision 18716  Directory Listing
Modified Mon Nov 21 21:17:12 2011 UTC (5 years, 10 months ago) by pieper
BUG: fix ChangeIslandEffect with correct event label

Revision 18710  Directory Listing
Modified Fri Nov 18 17:55:55 2011 UTC (5 years, 10 months ago) by alexy
BUG 1539  Fixed displayable manager and CLI scene importer to display output of model maker

Revision 18708  Directory Listing
Modified Fri Nov 18 03:54:55 2011 UTC (5 years, 10 months ago) by inorton
ENH: re-enable slice intersection gui controls now that DM is available (reverses gui part of r18637)

Revision 18707  Directory Listing
Modified Fri Nov 18 01:33:16 2011 UTC (5 years, 10 months ago) by jcfr
ENH: ctkLogger has been deprecated - Use q{Debug, Critical, Warning}() instead

Revision 18706  Directory Listing
Modified Thu Nov 17 20:12:48 2011 UTC (5 years, 10 months ago) by hjohnson
ENH: Improved usability of sitk/Slicer

Revision 18698  Directory Listing
Modified Wed Nov 16 22:54:58 2011 UTC (5 years, 10 months ago) by jcfr
ENH: qSlicerModuleSelectorToolBar::setModuleManager is now a slot

* This allow to instantiate a module selector toolbar from python and
associate its corresponding module manager.

Revision 18695  Directory Listing
Modified Wed Nov 16 20:54:53 2011 UTC (5 years, 10 months ago) by haehn
BUG: Catch a null pointer when using --python-code or --python-script which is triggered by the DataProbe module (to get UI children)


Revision 18691  Directory Listing
Modified Tue Nov 15 22:30:28 2011 UTC (5 years, 10 months ago) by hjohnson
ENH: Add slicer/sitk python interface.

Revision 18677  Directory Listing
Modified Fri Nov 11 23:27:29 2011 UTC (5 years, 10 months ago) by finetjul
ENH: Add option to build Slicer with no console on Windows

Add Slicer_BUILD_WIN32_CONSOLE at superbuild and build level

Revision 18666  Directory Listing
Modified Thu Nov 10 19:58:30 2011 UTC (5 years, 10 months ago) by naucoin
BUG: use TakeReference to avoid memory leaks

Revision 18656  Directory Listing
Modified Thu Nov 10 00:00:49 2011 UTC (5 years, 10 months ago) by pieper
ENH: provide extra feedback in the case of script errors that prevent modules from loading or instantiating

Revision 18654  Directory Listing
Modified Wed Nov 9 23:03:42 2011 UTC (5 years, 10 months ago) by naucoin
BUG: the change in default naming led to not finding the master scene view node from file save points. Just use the bare name, no unique numbers, so only get one master scene view

Revision 18653  Directory Listing
Modified Wed Nov 9 22:27:35 2011 UTC (5 years, 10 months ago) by pieper
ENH: handle case where no main window exists for data probe in findChildren

Revision 18647  Directory Listing
Modified Wed Nov 9 08:43:56 2011 UTC (5 years, 10 months ago) by jcfr
ENH: Add SlicerWikiURL to the settings

Revision 18645  Directory Listing
Modified Wed Nov 9 08:43:43 2011 UTC (5 years, 10 months ago) by jcfr
ENH: Add mechanism to select a module using the layout manager

* When module will be managed by the layoutManager, this should be
revisited.

Revision 18642  Directory Listing
Modified Wed Nov 9 08:43:22 2011 UTC (5 years, 10 months ago) by jcfr
COMP: Move slicer2sitk.py into appropriate folder

Revision 18641  Directory Listing
Modified Wed Nov 9 08:43:16 2011 UTC (5 years, 10 months ago) by jcfr
ENH: Re-enable stdout/stderr message handler on Mac OSX. See #1516

Revision 18637  Directory Listing
Modified Tue Nov 8 23:25:08 2011 UTC (5 years, 10 months ago) by pieper
ENH: turn off SliceSWidget and disable gui for missing model intersections

Almost all functionality of SliceSWidget is now in other parts of the
code so don't even create instances of the class now.  This means much 
functionality is much faster now (yay!) but there is some features have
not yet been re-implemented in the new architecture - in particular the 
slice intersection features for models and slices are not 
available so they are disabled in the GUI for now.


Revision 18622  Directory Listing
Modified Mon Nov 7 05:26:59 2011 UTC (5 years, 10 months ago) by jcfr
BUG: #1516 - Update CTK - Added multi-thread support to ErrorLogModel

See https://github.com/commontk/CTK/commit/6aa64670b25e0cd0c20d267cca12635e8718748c

Revision 18619  Directory Listing
Modified Sat Nov 5 22:41:47 2011 UTC (5 years, 10 months ago) by hjohnson
STYLE: Addressing module menu ordering request

Hans,

I would like to reorganize the module listings for registration. I am
proposing to highlight brainsfit and resample image and tuck everything
else under a listing called specialized. I did this reorganization on
the wiki pages already. If you concur, please do.

While you are at it, would you mind also moving Legacy and Utilities to
the bottom of the module listing in Slicer. I did it already on the
wiki.

Thanks
Ron

Revision 18605  Directory Listing
Modified Fri Nov 4 21:13:13 2011 UTC (5 years, 10 months ago) by jcfr
BUG: slicerqt.py - slicer.modulenames list module keep the orginal case

* For example, "Add" will be listed instead of "add"

Revision 18604  Directory Listing
Modified Fri Nov 4 21:13:11 2011 UTC (5 years, 10 months ago) by jcfr
STYLE: slicerqt.py - Update comment and remove extra spaces

Revision 18598  Directory Listing
Modified Fri Nov 4 18:53:42 2011 UTC (5 years, 10 months ago) by pieper
ENH: expose volumes logic to support EMSegment portability

Revision 18596  Directory Listing
Modified Fri Nov 4 16:41:31 2011 UTC (5 years, 10 months ago) by pieper
ENH: expose application logic to support EMSegment portability

Revision 18581  Directory Listing
Modified Thu Nov 3 20:26:30 2011 UTC (5 years, 10 months ago) by jcfr
COMP: Use Slicer_CLIMODULES_SUBDIR instead of hardcoded value

* See also http://viewvc.slicer.org/viewvc.cgi/Slicer3?view=revision&revision=16902

Revision 18577  Directory Listing
Modified Thu Nov 3 15:32:15 2011 UTC (5 years, 10 months ago) by jcfr
STYLE: Remove extra doxygen comments

Revision 18543  Directory Listing
Modified Mon Oct 31 15:46:50 2011 UTC (5 years, 10 months ago) by pieper
ENH: add missing backwards compatibility method

Revision 18542  Directory Listing
Modified Mon Oct 31 15:46:23 2011 UTC (5 years, 10 months ago) by pieper
BUG: remove out-of-date code

Revision 18528  Directory Listing
Modified Fri Oct 28 20:37:23 2011 UTC (5 years, 10 months ago) by naucoin
BUG: use smart pointers for the collections to try and get rid of memory leaks

Revision 18499  Directory Listing
Modified Thu Oct 27 18:32:17 2011 UTC (5 years, 11 months ago) by finetjul
BUG: Fix qSlicerModulePanelTest2

Some core modules have been moved into loadable modules, test modules that are still core.

Revision 18497  Directory Listing
Modified Thu Oct 27 17:56:14 2011 UTC (5 years, 11 months ago) by millerjv
ENH: added crosshair thickness controls

Revision 18496  Directory Listing
Modified Thu Oct 27 17:35:52 2011 UTC (5 years, 11 months ago) by millerjv
ENH: update checked state on slice intersections on change in MRML

Revision 18493  Directory Listing
Modified Thu Oct 27 15:24:11 2011 UTC (5 years, 11 months ago) by millerjv
ENH: added slice intersections to the ViewersToolBar

Revision 18492  Directory Listing
Modified Wed Oct 26 22:13:27 2011 UTC (5 years, 11 months ago) by jcfr
BUG: qSlicerCoreApplication::discoverSlicerBinDirectory - Properly handle build tree / install tree cases on macosx

Revision 18491  Directory Listing
Modified Wed Oct 26 21:47:57 2011 UTC (5 years, 11 months ago) by jcfr
BUG: Fix qSlicerUtils::endWith implementation

* Thanks to Julien for its feedback

Revision 18482  Directory Listing
Modified Wed Oct 26 11:20:11 2011 UTC (5 years, 11 months ago) by jcfr
COMP: Remove \\ETX \\BTX comments

* VTK parser is now smart enough

Revision 18481  Directory Listing
Modified Wed Oct 26 11:19:21 2011 UTC (5 years, 11 months ago) by jcfr
COMP: vtkSlicerApplicationLogic - Remove deprecated/unused methods Connect()/Commit()

Revision 18480  Directory Listing
Modified Wed Oct 26 11:19:19 2011 UTC (5 years, 11 months ago) by jcfr
COMP: vtkSlicerApplicationLogic - Remove unused Views/Modules related methods

Revision 18479  Directory Listing
Modified Wed Oct 26 11:19:17 2011 UTC (5 years, 11 months ago) by jcfr
STYLE: vtkSlicerApplicationLogic - Remove unused/deprecated code

Revision 18460  Directory Listing
Modified Tue Oct 25 19:26:10 2011 UTC (5 years, 11 months ago) by jcfr
BUG: qSlicerCoreApplicationPrivate::discoverSlicerBinDirectory - Properly handle MacOSX case

* pathWithoutIntDir can't be used, the directory structure needs to be
explicitly traversed.

Revision 18459  Directory Listing
Modified Tue Oct 25 19:26:08 2011 UTC (5 years, 11 months ago) by jcfr
ENH: SlicerUtils::pathWithoutIntDir - Add additional test and documentation

Revision 18457  Directory Listing
Modified Tue Oct 25 17:58:44 2011 UTC (5 years, 11 months ago) by jcfr
BUG: qSlicerCoreApplication - Use Slicer_BIN_DIR to compute SlicerBin

Revision 18451  Directory Listing
Modified Tue Oct 25 07:49:11 2011 UTC (5 years, 11 months ago) by jcfr
ENH: Use "qSlicerUtils::pathWithoutIntDir" in qSlicerCoreApplication

* Simplify the code and improve readability

Revision 18450  Directory Listing
Modified Tue Oct 25 07:49:04 2011 UTC (5 years, 11 months ago) by jcfr
ENH: qSlicerUtils - Add functions "pathWithoutIntDir" and "pathEndsWith"

Revision 18448  Directory Listing
Modified Tue Oct 25 02:28:13 2011 UTC (5 years, 11 months ago) by millerjv
ENH: new toolbar to control viewers.

Currently just presents a control for managing the crosshair.

Revision 18445  Directory Listing
Modified Mon Oct 24 21:23:40 2011 UTC (5 years, 11 months ago) by finetjul
COMP: Add cassert include for release mode on windows

When using assert, the cassert file header must be included.

Revision 18435  Directory Listing
Modified Mon Oct 24 14:18:47 2011 UTC (5 years, 11 months ago) by finetjul
ENH: Split qMRMLAbstractLogic::ProcessMRMLEvents into qMRMLAbstractLogic::ProcessMRMLSceneEvents and qMRMLAbstractLogic::ProcessMRMLNodesEvents

In order to reduce the confusion inside qMRMLAbstractLogic::ProcessMRMLEvents, we separate the processing of the scene events from the nodes events.
Add qMRMLAbstractDisplayableManager::ProcessWidgetsEvents to process graphical user interactions (typically via vtk widgets).

Revision 18422  Directory Listing
Modified Sat Oct 22 19:38:10 2011 UTC (5 years, 11 months ago) by finetjul
STYLE: Cleanup vtkSlicerApplicationLogic::CreateSliceLogics

The scene observation is already done in vtkMRMLSliceLogic::SetMRMLSceneInternal
STYLE: Remove useless macro (you never want to not fire Modified(), if you really do, you can use the block mechanism).

Revision 18398  Directory Listing
Modified Thu Oct 20 20:32:04 2011 UTC (5 years, 11 months ago) by finetjul
STYLE: Move ViewControllers module to loadable module directory

Revision 18397  Directory Listing
Modified Thu Oct 20 20:31:59 2011 UTC (5 years, 11 months ago) by finetjul
STYLE: Move ScalarOverlay IO to Models module

Revision 18396  Directory Listing
Modified Thu Oct 20 20:31:55 2011 UTC (5 years, 11 months ago) by finetjul
STYLE: Move Transforms module to loadable module directory

Revision 18395  Directory Listing
Modified Thu Oct 20 20:31:49 2011 UTC (5 years, 11 months ago) by finetjul
STYLE: Move Data module to loadable module directory

Revision 18394  Directory Listing
Modified Thu Oct 20 20:31:44 2011 UTC (5 years, 11 months ago) by finetjul
STYLE: Move Colors module to the loadable module directory

Revision 18378  Directory Listing
Modified Thu Oct 20 03:25:29 2011 UTC (5 years, 11 months ago) by wjp@bwh.harvard.edu
ENH: updated button text for clarity

Revision 18353  Directory Listing
Modified Mon Oct 17 23:31:54 2011 UTC (5 years, 11 months ago) by Michael.jeulinl
ENH: ImplicitPlaneWidget2 Implementation LockNormalToCamera

Delete TCL module and use the widget throught a MRMLDisplayableManager:
vtkMRMLThreeDReformatDisplayableManager.

Revision 18351  Directory Listing
Modified Mon Oct 17 21:35:43 2011 UTC (5 years, 11 months ago) by finetjul
ENH: the application logic is now available in the displayable managers

Revision 18341  Directory Listing
Modified Mon Oct 17 15:47:16 2011 UTC (5 years, 11 months ago) by pieper
BUG: avoid trying to work with gui class instance that doesn't exist

Revision 18329  Directory Listing
Modified Fri Oct 14 16:45:58 2011 UTC (5 years, 11 months ago) by millerjv
ENH: Crosshair as a DisplayableManager

The behavior is incomplete. This checkin will allow others to see the
performance.

Revision 18325  Directory Listing
Modified Wed Oct 12 22:56:34 2011 UTC (5 years, 11 months ago) by jcfr
COMP: Mac - Install CLI executabled in a dedicated folder.

* This change has been motivated by the fact no all executables within bin folder
are CLI executables and some of them are not exiting gracefull and they are
causing Slicer to crash when invoked within the "--xml" option.

* The CLI executables are now installed "cli-executables" folder

Revision 18312  Directory Listing
Modified Wed Oct 12 00:35:00 2011 UTC (5 years, 11 months ago) by jcfr
STYLE: qSlicerCLIModuleFactoryHelper - Use Slicer_CLIMODULES_LIB_DIR instead of Slicer_CLIMODULES_BIN_DIR

Revision 18311  Directory Listing
Modified Wed Oct 12 00:34:58 2011 UTC (5 years, 11 months ago) by jcfr
COMP: On mac, install CLI executables in "Slicer_BIN_DIR"

* This is a temporary solution to allow CLI executable to run as expected.

* A more elegant solution would be to create a "Slicer.framework" on which both "Slicer.app"
and the plugins/extensions (or loadable bundles) would depend on.

Revision 18296  Directory Listing
Modified Sun Oct 9 23:04:52 2011 UTC (5 years, 11 months ago) by finetjul
COMP: Unused variable in qSlicerViewControllersModuleWidget

Revision 18285  Directory Listing
Modified Thu Oct 6 15:33:53 2011 UTC (5 years, 11 months ago) by benjamin.long
ENH: Fix the module selector's behavior at the default behavior.

Revision 18278  Directory Listing
Modified Tue Oct 4 19:36:28 2011 UTC (5 years, 11 months ago) by jcfr
COMP: QTCLI - Enable PythonQt wrapping

Revision 18276  Directory Listing
Modified Tue Oct 4 19:36:25 2011 UTC (5 years, 11 months ago) by jcfr
STYLE: Clean empty white spaces, update debug statements, re-order includes

Revision 18275  Directory Listing
Modified Tue Oct 4 19:03:27 2011 UTC (5 years, 11 months ago) by jcfr
COMP: Remove empty directories

Revision 18269  Directory Listing
Modified Mon Oct 3 19:45:46 2011 UTC (5 years, 11 months ago) by naucoin
ENH: updated table to include fat and move unknown to end as a new entry at 308

Revision 18265  Directory Listing
Modified Mon Oct 3 16:26:15 2011 UTC (5 years, 11 months ago) by ilknur.kabul
BUG: Missing comma after qSlicerBaseQTCLIPythonQT is added.

Revision 18264  Directory Listing
Modified Mon Oct 3 15:46:59 2011 UTC (5 years, 11 months ago) by ilknur.kabul
ENH: Python wrapping for QTCLIs is added.

Revision 18263  Directory Listing
Modified Mon Oct 3 15:46:54 2011 UTC (5 years, 11 months ago) by ilknur.kabul
ENH: qSlicerCLIProgressBar is used in qSlicerCLIModuleWidget.

Instead of using two progressbars and a status label, qSlicerCLIProgressBar is used in qSlicerCLIModuleWidget.

Revision 18262  Directory Listing
Modified Mon Oct 3 15:40:28 2011 UTC (5 years, 11 months ago) by ilknur.kabul
ENH: qSlicerCLIProgressBar is added.

This part is refactored from qSlicerCLIModuleWidget.

Revision 18252  Directory Listing
Modified Sat Oct 1 02:23:21 2011 UTC (5 years, 11 months ago) by jcfr
ENH: Object associated with a qSlicer*PythonQt python module are added to "slicer.modulewidget" namespace

Revision 18251  Directory Listing
Modified Sat Oct 1 02:23:18 2011 UTC (5 years, 11 months ago) by jcfr
BUG: Python/C++ bridge - Fix memory leak

* Since "PyObject_GetAttrString" returns a new reference, this one will
have to be decremented when it is not needed anymore.

Revision 18250  Directory Listing
Modified Sat Oct 1 02:23:16 2011 UTC (5 years, 11 months ago) by jcfr
BUG: Python/C++ bridge - Had check to avoid AttributeError related to nonexistent method

* When a python class definition is loaded, some of the methods may not
be defined. Checking explicitly if a given method or attribute exists
will avoid "AttributeError".

Revision 18242  Directory Listing
Modified Fri Sep 30 18:16:46 2011 UTC (5 years, 11 months ago) by millerjv
ENH: completing the renaming of SliceControllerModule to ViewControllersModule

Revision 18241  Directory Listing
Modified Fri Sep 30 18:16:44 2011 UTC (5 years, 11 months ago) by millerjv
ENH: still renaming module

Revision 18240  Directory Listing
Modified Fri Sep 30 18:16:42 2011 UTC (5 years, 11 months ago) by millerjv
ENH: renaming SliceControllerModule to ViewControllerModule (part 2)

Revision 18239  Directory Listing
Modified Fri Sep 30 18:16:39 2011 UTC (5 years, 11 months ago) by millerjv
ENH: adding 3D view controllers to the View Controllers module.

Adding 3D controllers to the View Controllers module. Operations are
functional. This is checkin 1 of 3. The remaining checkins will rename
the files and classes for the SliceControllerModule.

Revision 18238  Directory Listing
Modified Fri Sep 30 13:40:30 2011 UTC (5 years, 11 months ago) by finetjul
COMP: Don't define export macro for PythonQt decorators

No need to export the symbols.
Errors on Windows because of inconsistent dll linkage: Q_SLICER_BASE_QTGUI_EXPORT instead of Q_SLICER_BASE_QTGUI_PYTHONQT_EXPORT

Revision 18237  Directory Listing
Modified Fri Sep 30 13:30:51 2011 UTC (5 years, 11 months ago) by finetjul
COMP: Don't define export macro for PythonQt decorators

No need to export the symbols.
Errors on Windows because of inconsistent dll linkage: Q_SLICER_BASE_QTCORE_EXPORT instead of Q_SLICER_BASE_QTCORE_PYTHONQT_EXPORT

Revision 18229  Directory Listing
Modified Thu Sep 29 07:24:00 2011 UTC (5 years, 11 months ago) by jcfr
ENH: Wrapped Qt libraries can now be loaded as regular python module

Revision 18228  Directory Listing
Modified Thu Sep 29 07:23:48 2011 UTC (5 years, 11 months ago) by jcfr
STYLE: Remove end-of-line space, remove extra/unused code, fix indent

Revision 18226  Directory Listing
Modified Thu Sep 29 07:23:37 2011 UTC (5 years, 11 months ago) by jcfr
BUG: Fix memory leak related to vtkMRMLAbstractLogic

* By having MRMLApplicationLogic has a smartpointer within vtkMRMLAbstractLogic,
a cycle between vtkMRMLApplicationLogic and vtkMRMLSliceLinkLogic was created
and it was preventing vtkMRMLApplictionLogic do be deleted.

* Simplify code within vtkMRMLApplicationLogic by using vtkSmartPointer to
keep track of SelectionNode and InteractionNode.

Revision 18225  Directory Listing
Modified Wed Sep 28 03:03:47 2011 UTC (5 years, 11 months ago) by wjp@bwh.harvard.edu
ENH: adding new image data for better contrast on blue or grey-selected rows in listbox.

Revision 18224  Directory Listing
Modified Wed Sep 28 02:50:46 2011 UTC (5 years, 11 months ago) by wjp@bwh.harvard.edu
ENH: adding new image data for better contrast on blue or grey-selected rows in listbox.

Revision 18223  Directory Listing
Modified Wed Sep 28 02:50:28 2011 UTC (5 years, 11 months ago) by wjp@bwh.harvard.edu
ENH: adding new image data for better contrast on blue or grey-selected rows in listbox.

Revision 18222  Directory Listing
Modified Wed Sep 28 02:50:22 2011 UTC (5 years, 11 months ago) by wjp@bwh.harvard.edu
ENH: adding new image data for better contrast on blue or grey-selected rows in listbox.

Revision 18221  Directory Listing
Modified Wed Sep 28 02:50:13 2011 UTC (5 years, 11 months ago) by wjp@bwh.harvard.edu
ENH: adding new image data for better contrast on blue or grey-selected rows in listbox.

Revision 18220  Directory Listing
Modified Wed Sep 28 02:50:07 2011 UTC (5 years, 11 months ago) by wjp@bwh.harvard.edu
ENH: adding new image data for better contrast on blue or grey-selected rows in listbox.

Revision 18219  Directory Listing
Modified Wed Sep 28 02:49:42 2011 UTC (5 years, 11 months ago) by wjp@bwh.harvard.edu
ENH: adding new image data for better contrast on blue or grey-selected rows in listbox.

Revision 18218  Directory Listing
Modified Wed Sep 28 02:49:35 2011 UTC (5 years, 11 months ago) by wjp@bwh.harvard.edu
ENH: adding new image data for better contrast on blue or grey-selected rows in listbox.

Revision 18217  Directory Listing
Modified Wed Sep 28 02:49:29 2011 UTC (5 years, 11 months ago) by wjp@bwh.harvard.edu
ENH: adding new image data for better contrast on blue or grey-selected rows in listbox.

Revision 18216  Directory Listing
Modified Wed Sep 28 02:49:20 2011 UTC (5 years, 11 months ago) by wjp@bwh.harvard.edu
ENH: adding new image data for better contrast on blue or grey-selected rows in listbox.

Revision 18215  Directory Listing
Modified Wed Sep 28 02:49:12 2011 UTC (5 years, 11 months ago) by wjp@bwh.harvard.edu
ENH: adding new image data for better contrast on blue or grey-selected rows in listbox.

Revision 18214  Directory Listing
Modified Wed Sep 28 02:48:47 2011 UTC (5 years, 11 months ago) by wjp@bwh.harvard.edu
ENH: adding new image data for better contrast on blue or grey-selected rows in listbox.

Revision 18213  Directory Listing
Modified Wed Sep 28 02:48:34 2011 UTC (5 years, 11 months ago) by wjp@bwh.harvard.edu
ENH: adding new image data for better contrast on blue or grey-selected rows in listbox.

Revision 18212  Directory Listing
Modified Wed Sep 28 02:48:27 2011 UTC (5 years, 11 months ago) by wjp@bwh.harvard.edu
ENH: adding new image data for better contrast on blue or grey-selected rows in listbox.

Revision 18211  Directory Listing
Modified Wed Sep 28 02:48:17 2011 UTC (5 years, 11 months ago) by wjp@bwh.harvard.edu
ENH: adding new image data for better contrast on blue or grey-selected rows in listbox.

Revision 18210  Directory Listing
Modified Wed Sep 28 02:48:09 2011 UTC (5 years, 11 months ago) by wjp@bwh.harvard.edu
ENH: adding new image data for better contrast on blue or grey-selected rows in listbox.

Revision 18209  Directory Listing
Modified Wed Sep 28 02:47:41 2011 UTC (5 years, 11 months ago) by wjp@bwh.harvard.edu
ENH: adding new image data for better contrast on blue or grey-selected rows in listbox.

Revision 18208  Directory Listing
Modified Wed Sep 28 02:47:28 2011 UTC (5 years, 11 months ago) by wjp@bwh.harvard.edu
ENH: adding new image data for better contrast on blue or grey-selected rows in listbox.

Revision 18207  Directory Listing
Modified Wed Sep 28 02:47:22 2011 UTC (5 years, 11 months ago) by wjp@bwh.harvard.edu
ENH: adding new image data for better contrast on blue or grey-selected rows in listbox.

Revision 18206  Directory Listing
Modified Wed Sep 28 02:47:12 2011 UTC (5 years, 11 months ago) by wjp@bwh.harvard.edu
ENH: adding new image data for better contrast on blue or grey-selected rows in listbox.

Revision 18205  Directory Listing
Modified Wed Sep 28 02:46:58 2011 UTC (5 years, 11 months ago) by wjp@bwh.harvard.edu
ENH: adding new image data for better contrast on blue or grey-selected rows in listbox.

Revision 18181  Directory Listing
Modified Mon Sep 26 13:27:16 2011 UTC (6 years ago) by demian
COMP: Modified __init__.py to use python's tools for OS compatibility in path names

Revision 18180  Directory Listing
Modified Mon Sep 26 12:32:27 2011 UTC (6 years ago) by demian
COMP: Modified __init__.py to use python's tools for OS compatibility in path names

Revision 18172  Directory Listing
Modified Fri Sep 23 18:23:18 2011 UTC (6 years ago) by jcfr
BUG: Update module{logic, mrml}/__init__.py to look in the appropriate folder

Revision 18171  Directory Listing
Modified Fri Sep 23 18:23:16 2011 UTC (6 years ago) by jcfr
ENH: qSlicerCoreApplication - Add Slicer majorVersion and minorVersion to meta object system

* Also add CONSTANT qualified where it applies. See http://doc.qt.nokia.com/latest/properties.html

Revision 18169  Directory Listing
Modified Thu Sep 22 19:42:27 2011 UTC (6 years ago) by millerjv
BUG: SliceControllers in the SliceControllersModule didn't have colors.

Revision 18166