# Qt5 build : a few hiccups

**URL:** <https://discourse.slicer.org/t/qt5-build-a-few-hiccups/952>\
**Category:** Development\
**Tags:** build, qt\
**Created:** [August 26, 2017, 11:26am UTC](https://discourse.slicer.org/t/qt5-build-a-few-hiccups/952 "2017-08-26T11:26:06Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![chir.set](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/chir.set/32/66982_2.png) [@chir.set](https://discourse.slicer.org/u/chir.set)\
**Post date:** [August 26, 2017, 11:26am UTC](https://discourse.slicer.org/t/qt5-build-a-few-hiccups/952/1 "2017-08-26T11:26:07Z")

</div>

After using the Qt5 build for one week, here are some minor problems.

1. Whenever an item is selected in the Fiducial/ROI/Ruler tool, the items get duplicated to an certain number of items that I didn’t count.  
 ![Screenshot_20170826_130740](https://us1.discourse-cdn.com/flex002/uploads/slicer/original/3X/f/f/ffa89445d8ab2550bf6afb8aa8a380eced2c674b.png)

2. In Volume Rending module, the items of the ‘View’ combobox are no longer checkable.  
 ![Screenshot_20170826_130856](https://us1.discourse-cdn.com/flex002/uploads/slicer/original/3X/0/f/0f53338b31288eca77f18452a785b3a736ff594f.png)

3. Switching to module ‘SceneViews’ crashes Slicer :

- _Switch to module: “SceneViews”_
- _qSlicerSceneViewsModuleWidgetPrivate::setupUi - Capture link not implemented with Qt5_
- _qSlicerSceneViewsModuleWidgetPrivate::setupUi - Restore scroll bar position not implemented with Qt5_  
As it says, it has yet to be implemented.

All these are found on today’s build after ‘git pull’ (2017-08-26).

I think developers might be interested in this post.

Regards.

---

<div class="post-metadata">

**Author:** ![lassoan](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/lassoan/32/13_2.png) [@lassoan](https://discourse.slicer.org/u/lassoan)\
**Post date:** [August 27, 2017, 12:02am UTC](https://discourse.slicer.org/t/qt5-build-a-few-hiccups/952/2 "2017-08-27T00:02:16Z")

</div>

Thanks a lot for reporting - it’s very useful. I’ve added these issues to the [Qt5 migration lab page](https://www.slicer.org/wiki/Documentation/Labs/Qt5-and-VTK8#Slicer).

---

<div class="post-metadata">

**Author:** ![chir.set](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/chir.set/32/66982_2.png) [@chir.set](https://discourse.slicer.org/u/chir.set)\
**Post date:** [September 23, 2017, 3:14pm UTC](https://discourse.slicer.org/t/qt5-build-a-few-hiccups/952/3 "2017-09-23T15:14:45Z")

</div>

May I report one more crash source with the QT5/VTK8 build:

Any tool in the _new_ segment editor crashes Slicer as soon as the corresponding button is pressed. The old segment editor is still functional.

Best.

---

<div class="post-metadata">

**Author:** ![lassoan](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/lassoan/32/13_2.png) [@lassoan](https://discourse.slicer.org/u/lassoan)\
**Post date:** [September 23, 2017, 6:57pm UTC](https://discourse.slicer.org/t/qt5-build-a-few-hiccups/952/4 "2017-09-23T18:57:34Z")

</div>

Thanks, we’ll look into this! What operating system do you use?

---

<div class="post-metadata">

**Author:** ![chir.set](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/chir.set/32/66982_2.png) [@chir.set](https://discourse.slicer.org/u/chir.set)\
**Post date:** [September 24, 2017, 8:06am UTC](https://discourse.slicer.org/t/qt5-build-a-few-hiccups/952/5 "2017-09-24T08:06:32Z")

</div>

I use ArchLinux to build and run.

---

<div class="post-metadata">

**Author:** ![cpinter](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/cpinter/32/7995_2.png) [@cpinter](https://discourse.slicer.org/u/cpinter)\
**Post date:** [October 12, 2017, 2:43pm UTC](https://discourse.slicer.org/t/qt5-build-a-few-hiccups/952/6 "2017-10-12T14:43:42Z")

</div>

@chir.set The issue has been fixed just now in [https://github.com/Slicer/Slicer/commit/7de0d6a6e71694ac808a2e73da3fd3c3300f708c](https://github.com/Slicer/Slicer/commit/7de0d6a6e71694ac808a2e73da3fd3c3300f708c)

---

<div class="post-metadata">

**Author:** ![chir.set](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/chir.set/32/66982_2.png) [@chir.set](https://discourse.slicer.org/u/chir.set)\
**Post date:** [October 16, 2017, 9:03am UTC](https://discourse.slicer.org/t/qt5-build-a-few-hiccups/952/7 "2017-10-16T09:03:06Z")

</div>

Thanks. But when I click on ‘Show details’ as per attached image, Slicer crashes immediately.

![Screenshot_20171016_105921](https://us1.discourse-cdn.com/flex002/uploads/slicer/original/3X/b/6/b689d74f3748a75e410a3fc80cd18adbb036daa6.png)

---

<div class="post-metadata">

**Author:** ![cpinter](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/cpinter/32/7995_2.png) [@cpinter](https://discourse.slicer.org/u/cpinter)\
**Post date:** [October 16, 2017, 2:13pm UTC](https://discourse.slicer.org/t/qt5-build-a-few-hiccups/952/8 "2017-10-16T14:13:05Z")

</div>

Thanks for testing! Unfortunately I cannot reproduce this, as I only have a Windows build with Qt5. I’m building one on Mac now and see if it can be reproduced there. In the meantime @Davide_Punzo Can you please try to see if this is as easy to fix as the previous one? Thanks a lot!

---

<div class="post-metadata">

**Author:** ![Davide\_Punzo](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/davide_punzo/32/66104_2.png) [@Davide\_Punzo](https://discourse.slicer.org/u/Davide_Punzo)\
**Post date:** [October 16, 2017, 2:47pm UTC](https://discourse.slicer.org/t/qt5-build-a-few-hiccups/952/9 "2017-10-16T14:47:13Z")

</div>

[https://github.com/Slicer/Slicer/pull/819](https://github.com/Slicer/Slicer/pull/819) should fix it

---

<div class="post-metadata">

**Author:** ![cpinter](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/cpinter/32/7995_2.png) [@cpinter](https://discourse.slicer.org/u/cpinter)\
**Post date:** [October 16, 2017, 3:01pm UTC](https://discourse.slicer.org/t/qt5-build-a-few-hiccups/952/10 "2017-10-16T15:01:01Z")

</div>

Thanks a lot, @Davide_Punzo! I integrated the pull request in [https://github.com/Slicer/Slicer/commit/0c3f2cca8d11ed49d55724bca9ca166b08309d0d](https://github.com/Slicer/Slicer/commit/0c3f2cca8d11ed49d55724bca9ca166b08309d0d)

@chir.set Please don’t get discourdaged and keep sending us any issues you find 🙂

---

<div class="post-metadata">

**Author:** ![chir.set](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/chir.set/32/66982_2.png) [@chir.set](https://discourse.slicer.org/u/chir.set)\
**Post date:** [January 12, 2018, 8:08pm UTC](https://discourse.slicer.org/t/qt5-build-a-few-hiccups/952/11 "2018-01-12T20:08:31Z")

</div>

Slicer crashes in Threshold Scalar Volume on ‘Apply’, if ‘Below’ a threshold value is selected. It doesn’t crash if ‘Above’ or ‘Outside’ is chosen. Using Qt5/VTK9 build on Linux.

---

<div class="post-metadata">

**Author:** ![chir.set](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/chir.set/32/66982_2.png) [@chir.set](https://discourse.slicer.org/u/chir.set)\
**Post date:** [January 12, 2018, 8:12pm UTC](https://discourse.slicer.org/t/qt5-build-a-few-hiccups/952/12 "2018-01-12T20:12:04Z")

</div>

Slicer will crash on application exit if the ‘Standard Quantitative’ pane has been shown, whether it is shown or not on exit. Using Qt5/VTK9 build on Linux.

---

<div class="post-metadata">

**Author:** ![hherhold](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/hherhold/32/12199_2.png) [@hherhold](https://discourse.slicer.org/u/hherhold)\
**Post date:** [January 14, 2018, 3:35pm UTC](https://discourse.slicer.org/t/qt5-build-a-few-hiccups/952/13 "2018-01-14T15:35:32Z")

</div>

Qt5 build failing on OS X 10.12.6. Was working a few days ago, sorry I can’t be more specific than that.

Configured with:

/Applications/CMake.app/Contents/MacOS/CMake -DQt5\_DIR:PATH=/usr/local/opt/qt

First errors:

- Skipping extension packaging: DataStore - Slicer\_SOURCE\_DIR is defined.

* * *

– Configuring remote module: CompareVolumes  
– Configuring Scripted module: CompareVolumes

* * *

– Configuring remote module: LandmarkRegistration  
– Configuring Scripted module: LandmarkRegistration  
CMake Warning at Utilities/Scripts/SlicerWizard/doc/CMakeLists.txt:41 (message):  
Warning: sphinx-build not found: Python documentation will not be created

– Setting ‘CTEST\_MODEL’ variable with default value ‘Experimental’  
– Setting ‘MIDAS\_PACKAGE\_URL’ variable with default value ‘[http://slicer.kitware.com/midas3](http://slicer.kitware.com/midas3)’  
– Setting ‘MIDAS\_PACKAGE\_EMAIL’ variable with default value ‘OBFUSCATED’  
– Setting ‘MIDAS\_PACKAGE\_API\_KEY’ variable with default value ‘OBFUSCATED’  
– Setting CPACK\_PACKAGE\_NAME to ‘Slicer’  
– Setting CPACK\_PACKAGE\_VENDOR to ‘NA-MIC’  
– Setting CPACK\_PACKAGE\_VERSION\_MAJOR to ‘4’  
– Setting CPACK\_PACKAGE\_VERSION\_MINOR to ‘9’  
– Setting CPACK\_PACKAGE\_VERSION\_PATCH to ‘0’  
– Setting CPACK\_PACKAGE\_VERSION to ‘4.9.0-2018-01-13’  
– Setting CPACK\_PACKAGE\_INSTALL\_DIRECTORY to ‘Slicer 4.9.0-2018-01-13’  
– Setting CPACK\_PACKAGE\_DESCRIPTION\_FILE to ‘/Users/hherhold/Development/slicer/Slicer/README.txt’  
– Setting CPACK\_RESOURCE\_FILE\_LICENSE to ‘/Users/hherhold/Development/slicer/Slicer/License.txt’  
– Setting CPACK\_PACKAGE\_DESCRIPTION\_SUMMARY to ‘Medical Visualization and Processing Environment for Research’  
– Setting CPACK\_PACKAGE\_ICON to ‘/Users/hherhold/Development/slicer/Slicer/Applications/SlicerApp/Resources/Slicer.icns’  
– Configuring done  
CMake Error at Libs/vtkAddon/CMakeLists.txt:94 (add\_library):  
Cannot find source file:

```
/Users/hherhold/Development/slicer/build-qt5/Slicer-build/Libs/vtkAddon/vtkAddonHierarchy.stamp.txt

```

Tried extensions .c .C .c++ .cc .cpp .cxx .m .M .mm .h .hh .h++ .hm .hpp  
.hxx .in .txx

CMake Error at Libs/vtkTeem/CMakeLists.txt:87 (add\_library):  
Cannot find source file:

```
/Users/hherhold/Development/slicer/build-qt5/Slicer-build/Libs/vtkTeem/vtkTeemHierarchy.stamp.txt

```

Tried extensions .c .C .c++ .cc .cpp .cxx .m .M .mm .h .hh .h++ .hm .hpp  
.hxx .in .txx

---

<div class="post-metadata">

**Author:** ![cpinter](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/cpinter/32/7995_2.png) [@cpinter](https://discourse.slicer.org/u/cpinter)\
**Post date:** [January 14, 2018, 4:48pm UTC](https://discourse.slicer.org/t/qt5-build-a-few-hiccups/952/14 "2018-01-14T16:48:24Z")

</div>

Thanks! I will check out both issues on Monday.

---

<div class="post-metadata">

**Author:** ![cpinter](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/cpinter/32/7995_2.png) [@cpinter](https://discourse.slicer.org/u/cpinter)\
**Post date:** [January 16, 2018, 3:23pm UTC](https://discourse.slicer.org/t/qt5-build-a-few-hiccups/952/15 "2018-01-16T15:23:41Z")

</div>

@hherhold I’ve started a Mac build (although it’s 10.13.1), will let you know how it went.

@chir.set I wasn’t able to reproduce the crash with either way, but I tried on Windows. If anyone uses Linux for development, please test this one. @jcfr could you try? Otherwise I’ll need to do a build on a VM. Thanks!

---

<div class="post-metadata">

**Author:** ![jcfr](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/jcfr/32/17825_2.png) [@jcfr](https://discourse.slicer.org/u/jcfr)\
**Post date:** [January 16, 2018, 3:30pm UTC](https://discourse.slicer.org/t/qt5-build-a-few-hiccups/952/16 "2018-01-16T15:30:44Z")

</div>

> Qt5 build failing on OS X 10.12.6. Was working a few days ago, sorry I can’t be more specific than that  
> Cannot find source file: … Libs/vtkTeem/vtkTeemHierarchy.stamp.txt

Thanks to @adamrankin, the issue related to VTK hierarchy stamps file should be fixed in [r26834](http://viewvc.slicer.org/viewvc.cgi/Slicer4?view=revision&revision=26834)

> ArchLinux … Any tool in the new segment editor crashes Slicer as soon as the corresponding button is pressed.

I am not able to reproduce the crash.

If this is still an issue, setting up a VM may be the best way forward.

---

<div class="post-metadata">

**Author:** ![Davide\_Punzo](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/davide_punzo/32/66104_2.png) [@Davide\_Punzo](https://discourse.slicer.org/u/Davide_Punzo)\
**Post date:** [January 16, 2018, 10:57pm UTC](https://discourse.slicer.org/t/qt5-build-a-few-hiccups/952/17 "2018-01-16T22:57:13Z")

</div>

> [@jcfr](#):
>
> Any tool in the new segment editor crashes Slicer as soon as the corresponding button is pressed.

this was fixed in the past in [Dual 3D mode: loading a scene with a single view node, second view is uninitialised · Issue #819 · Slicer/Slicer · GitHub](https://github.com/Slicer/Slicer/pull/819) and [https://github.com/Slicer/Slicer/commit/0c3f2cca8d11ed49d55724bca9ca166b08309d0d](https://github.com/Slicer/Slicer/commit/0c3f2cca8d11ed49d55724bca9ca166b08309d0d)

Instead I confirm this one:

> [@chir.set](#):
>
> Slicer will crash on application exit if the ‘Standard Quantitative’ pane has been shown, whether it is shown or not on exit. Using Qt5/VTK9 build on Linux.

Sorry, but I didn’t understand this other one:

> [@chir.set](#):
>
> Slicer crashes in Threshold Scalar Volume on ‘Apply’, if ‘Below’ a threshold value is selected. It doesn’t crash if ‘Above’ or ‘Outside’ is chosen. Using Qt5/VTK9 build on Linux.

---

<div class="post-metadata">

**Author:** ![Davide\_Punzo](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/davide_punzo/32/66104_2.png) [@Davide\_Punzo](https://discourse.slicer.org/u/Davide_Punzo)\
**Post date:** [January 16, 2018, 11:01pm UTC](https://discourse.slicer.org/t/qt5-build-a-few-hiccups/952/18 "2018-01-16T23:01:57Z")

</div>

In addition the linux version (at least my build)

1. some & still appear in the comboboxes and icons in modules and views seems much smaller  
 ![image](https://us1.discourse-cdn.com/flex002/uploads/slicer/original/3X/2/5/2542091231050f85e26ae6f524fdd4c39f5f086f.jpeg)  
2)some menu have some misalignment. E.g. settings and data module:  
 ![image](https://us1.discourse-cdn.com/flex002/uploads/slicer/original/3X/5/9/59159746568065e24b2c5aa8cd1bd94452a20e38.jpeg)  
 ![image](https://us1.discourse-cdn.com/flex002/uploads/slicer/original/3X/8/9/89f33fe030c2057c3552ddd3ac985e9efffebeb1.jpeg)

---

<div class="post-metadata">

**Author:** ![cpinter](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/cpinter/32/7995_2.png) [@cpinter](https://discourse.slicer.org/u/cpinter)\
**Post date:** [January 16, 2018, 11:58pm UTC](https://discourse.slicer.org/t/qt5-build-a-few-hiccups/952/19 "2018-01-16T23:58:21Z")

</div>

Thanks Davide! Was the module name in the module selector like this before (“Se&gment Editor”)?  
Update: Nevermind I see the marking on the first screenshot.

---

<div class="post-metadata">

**Author:** ![Davide\_Punzo](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/davide_punzo/32/66104_2.png) [@Davide\_Punzo](https://discourse.slicer.org/u/Davide_Punzo)\
**Post date:** [January 17, 2018, 8:44am UTC](https://discourse.slicer.org/t/qt5-build-a-few-hiccups/952/20 "2018-01-17T08:44:04Z")

</div>

you are welcome! the & issue (it shows in many places like the module menu, titles in plotting views, etc. ) was present before [https://github.com/Slicer/Slicer/pull/864](https://github.com/Slicer/Slicer/pull/864)

The smaller icons (?), menu misalignment (ctkCollapsiblegroupbox?) and smaller ctkCollapsibleButton are a result of the new style set in [https://github.com/Slicer/Slicer/pull/864](https://github.com/Slicer/Slicer/pull/864).

[Next page](https://discourse.slicer.org/t/qt5-build-a-few-hiccups/952.md?page=2)
