[vtkusers] Recent problems with vtkScalarBarWidget on relaese candidate

David Thompson david.thompson at kitware.com
Wed Jun 5 13:48:13 EDT 2013


Hi David,

> @David Thompson. Will http://review.source.kitware.com/#/t/2845/ fix this?

I don't think so; it appears that the scalar bar height is being computed incorrectly. The topic you mention just changes font sizes, not the rectangle for the scalar bar.

If I had to guess... it might be related to changing the coordinate system of one of the actor's control points with SetCoordinateSystemToNormalizedViewport(). But doing the same to some test code didn't cause a similar problem.

	David


> On Wed, Jun 5, 2013 at 11:54 AM, Alexandre Boucher <afboucher at gmail.com> wrote:
> Hello all,
> 
> I am having problems with vtkScalarBarWidget with the release candidate (on Windows 7).  When in vertical mode the bar is either very tall or not positioned properly.  The white bounding box that shows up when the cursor move on top the widget is displaying correctly   It is fine in horizontal mode (see attached figures.)
> 
> Here how the widget is created
> 
>   cbar_widget_ = vtkScalarBarWidget::New();
>   cbar_widget_->GetScalarBarActor()->GetLabelTextProperty()->BoldOff();
>   cbar_widget_->GetScalarBarActor()->GetLabelTextProperty()->ShadowOff();
>   cbar_widget_->GetScalarBarActor()->GetLabelTextProperty()->SetFontSize(8);
>   cbar_widget_->GetScalarBarActor()->GetPositionCoordinate()->SetCoordinateSystemToNormalizedViewport();
> 
> and later on:
> cbar_widget_->SetInteractor( renderer_->GetRenderWindow()->GetInteractor() );
> 
> Does anyone has an idea of what is going on?
> 
> Best,
> Alex
> 
> _______________________________________________
> Powered by www.kitware.com
> 
> Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html
> 
> Please keep messages on-topic and check the VTK FAQ at: http://www.vtk.org/Wiki/VTK_FAQ
> 
> Follow this link to subscribe/unsubscribe:
> http://www.vtk.org/mailman/listinfo/vtkusers
> 
> 
> _______________________________________________
> Powered by www.kitware.com
> 
> Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html
> 
> Please keep messages on-topic and check the VTK FAQ at: http://www.vtk.org/Wiki/VTK_FAQ
> 
> Follow this link to subscribe/unsubscribe:
> http://www.vtk.org/mailman/listinfo/vtkusers




More information about the vtkusers mailing list