[vtkusers] Axis range of vtkchartxy [solved]

curator curator at gmx.de
Mon Aug 19 12:09:33 EDT 2013


Hi,

interesting idea, but that doesn't seem to help, because my minumum was 
in the valid range. However, that
m_vtkPoints->GetXAxis()->SetBehavior(vtkAxis::FIXED);

that solved the problem, also I do not know exactly why.

regards,
curator

Am 19.08.2013 17:50, schrieb David Thompson:
> Hi curator,
>
> You might want to print GetXAxis()->GetMinimumLimit(); the minimum is not allowed to go below this value. User interaction like panning calls SetMinimum, and the limit is a way to prevent users from getting lost.
>
> 	David
>
>
> On Aug 19, 2013, at 5:25 AM, curator <curator at gmx.de> wrote:
>
>> Hi all,
>>
>> I am working for the first time with vtkchartxy, and I already managed to have multiple graphs shown by using a vtkTable.
>>
>> For each line, I do
>> for (all i)
>> {
>> m_vtkPoints = m_vtkChart->AddPlot(vtkChart::LINE);
>> m_vtkPoints->SetInputData(m_vtkTable, 0, i+1);
>> }
>> m_vtkPoints->GetXAxis()->SetTitle("axis name"); // that works
>> m_vtkPoints->GetXAxis()->SetMinimum(0.01f); // that does not work
>>
>> As written in the code, I can change axis labels, but not minimum and maximum. Any ideas, why this does not work out of the box?
>>
>> regards,
>> curator
>> _______________________________________________
>> 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