[vtkusers] i cant see the arrow and line part of vtkCaptionWidget, just the caption part appears...
David Doria
daviddoria+vtk at gmail.com
Mon Feb 15 09:18:04 EST 2010
On Mon, Feb 15, 2010 at 8:13 AM, circass <circass at gmail.com> wrote:
>
> Now my widget's arrow part is not showing itself. it is in a different
> dimension or something like that. when i zoomout i can see the arrow part
> and the line but when i want to see it closer it s disappearing.
> Is there any body who knows what is the problem or what can be the
> problem...
> here is my code.
>
> vtkCaptionWidget *m_capWidget = vtkCaptionWidget::New();
> vtkCaptionActor2D *Dactor = vtkCaptionActor2D::New();
> Dactor->SetCaption("!!!Test Warning!!!");
> m_capWidget->SetCaptionActor2D(Dactor);
> m_capWidget->SetSelectable(321);
> //m_capWidget->PlaceWidget
> m_absWidget = m_capWidget;
>
> m_absWidget->CreateDefaultRepresentation();
> m_absWidget->AddObserver(vtkCommand::StartInteractionEvent,
> StartInteractionCallBack::New());
> m_absWidget->AddObserver(vtkCommand::EndInteractionEvent,
> EndInteractionCallBack::New());
>
>
> widget is turning on when mouse enters the renderwindow.
>
> so the "m_absWidget->On();" part is in the mouse enter event function.
>
> Thanx
> Circass
>
>
Here is a demo of the captionWidget. The only thing I couldn't get to change
properly was the font size.
http://www.vtk.org/Wiki/VTK/Examples/Widgets/Cxx/Caption
Does this help? The arrow seems always visible to me?
Thanks,
David
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20100215/2cc22b12/attachment.htm>
More information about the vtkusers
mailing list