Is there any way to know if a vtkMRMLNode has been renamed?

Hi all,
If you create a markup node(vtkMRMLMarkupsNode) and add control points to it, the control points are named using a default format(“%N-%d”) with respect to the current name of the markup node.

Renaming a markup node doesn’t modify the names of the existing control points of the respective markup. If there was any event in vtkMRMLMarkupsNode or its parents that fires when the node is renamed, I could react to it and update the labels.

I was able to achieve what I wanted using vtkCommand::ModifiedEvent; however, this event also fires for several other cases. I just wanted to ask if there was an event I missed, so that my function is not called for every vtkCommand::ModifiedEvent and is more optimized.

Thanks!

I don’t see a name change event here or elsewhere so I think I agree with the way you approached it.

1 Like

What would you like to achieve? Rename all the other control points if the user renames one control point (e.g., user specifies for one vertebra that it is T5 and you want to update the labels for all the others accordingly)?