Skip to main content
ALomb
Senior
August 30, 2019
Solved

PieChart Resize

  • August 30, 2019
  • 2 replies
  • 824 views

I refer to the source code for "Model UI Demo 1 TouchGFX".

I would like to enlarge the PieChart, but I can't figure out how to do it.

In the GraphView::setupScreen function I modified the values for center, height and width.

// GraphView.cpp - GraphView::setupScreen
 pieChartX = 0;
 pieChartY = -16;
 donutX = pieChartX;
 donutY = 34;
 pieChart.setPosition(pieChartX, pieChartY, 300, 300); /* <- modified */
 pieChart.setCenter(150, 150); /* <- modified */
 pieChart.setPieChart(0, 0, 0, 0);
 pieChart.recalculatePieChart();

However, the PieChart radius does not change.

how to do ?

//Antonello

This topic has been closed for replies.
Best answer by ALomb

Solved!

Calls to startPieChartAnimation method must also be changed (toMinRadius toMaxRadius)

Thanks

//Antonello

2 replies

ALomb
ALombAuthorBest answer
Senior
August 30, 2019

Solved!

Calls to startPieChartAnimation method must also be changed (toMinRadius toMaxRadius)

Thanks

//Antonello

Martin KJELDSEN
Principal III
September 2, 2019

Great. Glad you found that :)

/Martin