MPAndroidChart - Legend labels are being cut off

后端 未结 9 1382
自闭症患者
自闭症患者 2020-12-15 17:18

I am using MPAndroidChart library. Anybody has this problem? When I put the labels in BOTTOM position, these are cut.

Thank you

9条回答
  •  星月不相逢
    2020-12-15 18:10

    Here I will show you an easy way by "Traditional Android Way", it's quite simple, my code is below:

    
    

    Just need to add some padding to the container layout, or some margin to the chart view, and finally set clipChildren&clipToPadding to false.

    Result below:

    the blue area is padding or margin area.

    enter image description here

提交回复
热议问题