<div dir="ltr">Hi!<div>I'm pretty much beginner of vtk and its application.</div><div><br></div><div>I applied vtkContourWidget on renderWindow and hope to add a new keyPressEvent on it.</div><div>So I am now trying to change the vtkContourWidget.cxx file directly and add</div><div><br></div><div><div><br></div><div><b>this->CallbackMapper->SetCallbackMethod(vtkCommand::KeyPressEvent,</b></div><div><b><span style="white-space:pre">                                                                               </span>  vtkEvent::NoModifier, 13, 1, "Return",</b></div><div><b><span style="white-space:pre">                                                                                </span>  vtkWidgetEvent::Reset,</b></div><div><b><span style="white-space:pre">                                                                          </span>  this, vtkContourWidget::ResetAction);</b></div></div><div><br></div><div>this for new Action when I pressed Return(I guess it is "Enter"), which acts ResetAction when Shift+Del is pressed like behind</div><div><div><br></div><div><b>this->CallbackMapper->SetCallbackMethod(vtkCommand::KeyPressEvent,</b></div><div><b>                                          vtkEvent::ShiftModifier, 127, 1, "Delete",</b></div><div><b>                                          vtkWidgetEvent::Reset,</b></div><div><b>                                          this, vtkContourWidget::ResetAction);</b></div></div><div><br></div><div>However, "Return" doesn't work and I couldn't figure it out.</div><div>I am pretty much sure that I am not supposed to add the keyPressEvent in this way,</div><div>but I don't know what to do.</div><div><br></div><div>How can I add a new keyPressEvent for a new key on vtkWidget?</div><div><div><br></div>-- <br><div class="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div style="font-size:12.8px"><font color="#000000">--------------------------------------------------------------------------------------------------------------</font></div><div style="font-size:12.8px"><font color="#000000"><b>Minsuk Park</b></font></div><div style="font-size:12.8px"><font color="#000000">Mobile: +82-10-7329-9912</font></div><div style="font-size:12.8px"><font color="#000000">Email: <a href="mailto:ashtonpark7@gmail.com" target="_blank">ashtonpark7@gmail.com</a></font></div><div style="font-size:12.8px"><span style="color:rgb(0,0,0)">--------------------------------------------------------------------------------------------------------------</span></div></div></div></div></div>
</div></div>