# How to detect the event when one fiducial is clicked (focused) and how to set the state of this?

**URL:** <https://discourse.slicer.org/t/how-to-detect-the-event-when-one-fiducial-is-clicked-focused-and-how-to-set-the-state-of-this/19119>\
**Category:** Support\
**Created:** [August 9, 2021, 1:59pm UTC](https://discourse.slicer.org/t/how-to-detect-the-event-when-one-fiducial-is-clicked-focused-and-how-to-set-the-state-of-this/19119 "2021-08-09T13:59:46Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![slicer](https://avatars.discourse-cdn.com/v4/letter/s/8c91f0/32.png) [@slicer](https://discourse.slicer.org/u/slicer)\
**Post date:** [August 9, 2021, 1:59pm UTC](https://discourse.slicer.org/t/how-to-detect-the-event-when-one-fiducial-is-clicked-focused-and-how-to-set-the-state-of-this/19119/1 "2021-08-09T13:59:46Z")

</div>

Operating system: Windows  
Slicer version: 4.11  
Expected behavior:  
Actual behavior:

When we click a fiducial in the view window, this fiducial will be focused and three views will be adjusted according to this fiducial. I want to ask how to detect this event when clicking a fiducial in python interactor? Also, I want to ask how to set this state for a particular fiducial, let’s say, seems like clicking it?

Hope for your help.

---

<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 9, 2021, 11:56pm UTC](https://discourse.slicer.org/t/how-to-detect-the-event-when-one-fiducial-is-clicked-focused-and-how-to-set-the-state-of-this/19119/2 "2021-08-09T23:56:51Z")

</div>

You can change the interaction → widget event translation so that left-click is mapped to a custom widget event that you observe (see example [here](https://slicer.readthedocs.io/en/latest/developer_guide/script_repository.html#assign-custom-actions-to-markups)). You need to remember vr the original translation and do the julep-to-slice and your custom actions in your callback function.
