Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在使用 achartengine api 绘制饼图。默认情况下,饼图显示在中心,但我想将其移动到布局的左角,我使用了“setMargin()”,但它不起作用。
如果您PieChart自己创建实例,则可以设置图表的centerXandcenterY以更改其位置。
PieChart
centerX
centerY
PieChart chart = new PieChart(dataset, renderer); chart.setCenterX(someValue); chart.setCenterY(someValue); mChartView = new GraphicalView(context, chart);