# slicer.modules.SegmentEditorWidget does not exists anymore

**URL:** <https://discourse.slicer.org/t/slicer-modules-segmenteditorwidget-does-not-exists-anymore/47334>\
**Category:** Support\
**Tags:** python, slicerrc, development\
**Created:** [June 14, 2026, 6:29pm UTC](https://discourse.slicer.org/t/slicer-modules-segmenteditorwidget-does-not-exists-anymore/47334 "2026-06-14T18:29:30Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![joachim](https://avatars.discourse-cdn.com/v4/letter/j/a87d85/32.png) [@joachim](https://discourse.slicer.org/u/joachim)\
**Post date:** [June 14, 2026, 6:29pm UTC](https://discourse.slicer.org/t/slicer-modules-segmenteditorwidget-does-not-exists-anymore/47334/1 "2026-06-14T18:29:30Z")

</div>

I haven’t updated Slicer for a while, but now my `.slicerrc` does not work as usual. I have the line `slicer.modules.SegmentEditorWidget.editor.findChild( "QWidget", "EffectsGroupBox" )`, but in the newest Slicer version the `SegmentEditorWidget` is not there unless I have opened that module in Slicer window (for example by `slicer.utils.selectModule( "SegmentEditor" )`). However, opening that module creates a Segmentation node which I do not want.

How do I get access to the `SegmentEditorWidget`, without creating a Segmentation node?

* * *

My context: I use the following code in my startup file in order to set up shortcuts which I can access with my Wacom tablet menu:

```python
def setupSegmentEditorShortcuts():
    # find buttons
    widget = slicer.modules.SegmentEditorWidget.editor.findChild("QWidget", "EffectsGroupBox")
    def addEffectShortcut(name, keysequence ):
        but = widget.findChild( 'QToolButton', name )
        shortcut = qt.QShortcut( mainWindow() ) # ^TODO: use SegmentEditorWidget for focused shortcut, does thtat work?
        shortcut.setKey( keysequence )
        shortcut.connect( 'activated()', lambda: but.click() )
    addEffectShortcut( "NULL", qt.QKeySequence( 'Shift+F4' ) )
    addEffectShortcut( "Paint", qt.QKeySequence( 'Shift+F5' ) )
    addEffectShortcut( "Draw", qt.QKeySequence( 'Shift+F6' ) )
    addEffectShortcut( "Erase", qt.QKeySequence( 'Shift+F7' ) )
    addEffectShortcut( "Scissors", qt.QKeySequence( 'Shift+F8' ) )
    # add shortcut for brush size
    qt.QShortcut( qt.QKeySequence( "Shift+F9"), mainWindow() ).connect( 'activated()', lambda: updateBrushSize( -1 ) )
    qt.QShortcut( qt.QKeySequence( "Shift+F10"), mainWindow() ).connect( 'activated()', lambda: updateBrushSize( 1 ) )

```

---

<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:** [June 15, 2026, 9:24am UTC](https://discourse.slicer.org/t/slicer-modules-segmenteditorwidget-does-not-exists-anymore/47334/2 "2026-06-15T09:24:10Z")

</div>

You can simply create a segment editor widget for your own purposes

```auto
segmentEditorWidget = slicer.qMRMLSegmentEditorWidget()
segmentEditorWidget.setMRMLScene(slicer.mrmlScene)

```

then set a `vtkMRMLSegmentEditorNode`, segmentation node, source volume node, etc. just as you would with “the” segment editor widget. If you look at the Segment Editor module code, you’ll see that it’s basically a placeholder for a segment editor widget instance, which is completely reusable.

---

<div class="post-metadata">

**Author:** ![joachim](https://avatars.discourse-cdn.com/v4/letter/j/a87d85/32.png) [@joachim](https://discourse.slicer.org/u/joachim)\
**Post date:** [June 21, 2026, 10:34pm UTC](https://discourse.slicer.org/t/slicer-modules-segmenteditorwidget-does-not-exists-anymore/47334/3 "2026-06-21T22:34:36Z")

</div>

Using `slicer.qMRMLSegmentEditorWidget()`instead of `slicer.modules.SegmentEditorWidget` did not work. However, turned out that there is another way that works: `slicer.util.getModuleWidget("SegmentEditor")`

So now I am able to add my shortcuts again, and hence use my Wacom tablet for efficient segmentation works 🙂

---

<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:** [June 22, 2026, 8:19am UTC](https://discourse.slicer.org/t/slicer-modules-segmenteditorwidget-does-not-exists-anymore/47334/4 "2026-06-22T08:19:42Z")

</div>

It is always useful to tell about your use case, because without it, one can only assume things and possibly give you an answer that does not help.
