<html>
<head>
<style><!--
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 10pt;
font-family:Verdana
}
--></style>
</head>
<body class='hmmessage'>
Hi Clinton,<br>thanks a lot for the answer. I just would like to make an example.<br>Let's say that if I have a QVTKWidget in my QT interface and I press W on the keyword, that event is<br>detected by QT (first) which forward it to the QVTKWidget and then the interactor. is that right?<br><br>So I wonder, if I make QT managing the press of W first and then I would like QVTKWidget doing whatever is programmed to do,<br>would it be enough to add the correspondent handler in my QT Class (whatever it is? )<br><br>Thanks<br>Giancarlo<br><br><hr id="stopSpelling">Subject: Re: [vtkusers] QT and VTK interactor how to manage the signals<br>From: clinton@elemtech.com<br>Date: Tue, 2 Mar 2010 07:59:21 -0700<br>CC: vtkusers@vtk.org; qt-interest@trolltech.com<br>To: ilferraresebono@hotmail.it<br><br>
<base><br><div><div>On Mar 2, 2010, at 2:46 AM, Giancarlo Amati wrote:</div><br class="ecxApple-interchange-newline"><blockquote><span class="ecxApple-style-span" style="border-collapse: separate; font-family: Helvetica; font-size: medium; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px;"><div class="ecxhmmessage" style="font-size: 10pt; font-family: Verdana;">Hello everybody,<br><br>I've addressed this question to both the QT and VTK group.<span class="ecxApple-converted-space"> </span><br>I'm doing my software and the GUI is with QT while the visualization is with VTK.<br>The VTK widget I used is the QVTKWidget produced when I compiled VTK using QT.<br>so the problem I have is that having an interactor linked to the VTKWidget somehow it intercepts all the events for the mouse<br>and for the keyboard.<br><br>What I would like to do is letting QT managing the same events capture but the vtkWindowInteractor one the interactor has them processed.<br></div></span></blockquote><div><br></div><div>Qt is already capturing the events, but it delgates the processing of those events to vtkRenderWindowInteractor, which in turn works with vtkInteractorObservers.</div><div><br></div><div>If you want to customize event processing, it is recommended that you make a vtkInteractorStyle class to do that, so that any other vtkInteractorObservers you decide to use will also work.</div><div><br></div><div>Otherwise, if you really want to, just overload the normal QWidget functions for capturing events and process them yourself. Its just like any other QWidget.</div><div><br></div><div>Clint</div><div><br></div></div>                                            <br /><hr />Navighi con quello giusto? <a href='http://www.microsoft.com/italy/windows/internet-explorer/msn.aspx' target='_new'>Scarica gratis Internet Explorer 8</a></body>
</html>