MCPcopy Create free account
hub / github.com/Kitware/VTK / GetSize

Method GetSize

Rendering/Core/vtkTextActor.cxx:161–171  ·  view source on GitHub ↗

------------------------------------------------------------------------------

Source from the content-addressed store, hash-verified

159
160//------------------------------------------------------------------------------
161void vtkTextActor::GetSize(vtkViewport* vport, double size[2])
162{
163 double bds[4];
164 // If we have a viewport, use it. Otherwise, GetBoundingBox() calls
165 // UpdateRectange(nullptr) which builds a (probably-too-low-resolution) image
166 // to determine its size.
167 this->UpdateRectangle(vport);
168 this->GetBoundingBox(vport, bds);
169 size[0] = bds[1] - bds[0];
170 size[1] = bds[3] - bds[2];
171}
172
173//------------------------------------------------------------------------------
174int vtkTextActor::SetConstrainedFontSize(vtkViewport* viewport, int targetWidth, int targetHeight)

Callers 4

RenderOpaqueGeometryMethod · 0.45
GetFontScaleMethod · 0.45

Calls 2

UpdateRectangleMethod · 0.95
GetBoundingBoxMethod · 0.95

Tested by

no test coverage detected