Skip to content

Commit

Permalink
chore: moves draw clear freehand region button closer to eraser
Browse files Browse the repository at this point in the history
  • Loading branch information
ElpadoCan committed Feb 11, 2025
1 parent 10825f6 commit 5578caf
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 12 deletions.
2 changes: 1 addition & 1 deletion cellacdc/docs/source/tooltips.rst
Original file line number Diff line number Diff line change
Expand Up @@ -437,7 +437,7 @@ Edit tools: Segmentation and tracking
* Add custom poly-line deletion ROI. Every ID touched by the ROI will be automatically deleted.
* Moving and reshaping the ROI will restore deleted IDs if they are not touched by it anymore.
* To delete the ROI ``right-click on it --> remove``.
* **Clear freehand region (** |drawClearRegionButton| **):** Draw a freehand region and clear all objects present in the region. Once activated, additional options will appear in a new toolbar.
* **Clear freehand region (** |drawClearRegionButton| **"O"):** Draw a freehand region and clear all objects present in the region. Once activated, additional options will appear in a new toolbar.
* **Delete bordering objects (** |delBorderObjAction| **):** Remove segmented objects touching the border of the image.
* **Repeat tracking (** |repeatTrackingAction| **"Shift+T"):** Repeat tracking on current frame. Tracking method can be changed in ``Tracking --> Select real-time tracking algorithm``
* **Manual tracking (** |manualTrackingButton| **"T"):** Select ID to track and right-click on an object to assign that ID.
Expand Down
23 changes: 12 additions & 11 deletions cellacdc/gui.py
Original file line number Diff line number Diff line change
Expand Up @@ -1866,6 +1866,18 @@ def gui_createToolBars(self):
self.LeftClickButtons.append(self.wandToolButton)
self.functionsNotTested3D.append(self.wandToolButton)
self.widgetsWithShortcut['Magic wand'] = self.wandToolButton

self.drawClearRegionButton = QToolButton(self)
self.drawClearRegionButton.setCheckable(True)
self.drawClearRegionButton.setIcon(QIcon(":clear_freehand_region.svg"))
self.widgetsWithShortcut['Clear freehand region'] = self.drawClearRegionButton

self.checkableButtons.append(self.drawClearRegionButton)
self.LeftClickButtons.append(self.drawClearRegionButton)

self.drawClearRegionAction = editToolBar.addWidget(
self.drawClearRegionButton
)

self.widgetsWithShortcut['Annotate mother/daughter pairing'] = (
self.assignBudMothButton
Expand Down Expand Up @@ -2065,10 +2077,6 @@ def gui_createToolBars(self):
)
self.addDelPolyLineRoiAction.roiType = 'polyline'

self.drawClearRegionAction = editToolBar.addWidget(
self.drawClearRegionButton
)

editToolBar.addAction(self.delBorderObjAction)

self.addDelRoiAction.toolbar = editToolBar
Expand Down Expand Up @@ -3413,13 +3421,6 @@ def gui_createActions(self):

self.checkableButtons.append(self.addDelPolyLineRoiButton)
self.LeftClickButtons.append(self.addDelPolyLineRoiButton)

self.drawClearRegionButton = QToolButton(self)
self.drawClearRegionButton.setCheckable(True)
self.drawClearRegionButton.setIcon(QIcon(":clear_freehand_region.svg"))

self.checkableButtons.append(self.drawClearRegionButton)
self.LeftClickButtons.append(self.drawClearRegionButton)

self.delBorderObjAction = QAction(self)
self.delBorderObjAction.setIcon(QIcon(":delBorderObj.svg"))
Expand Down

0 comments on commit 5578caf

Please sign in to comment.