Skip to content

Commit 6966b81

Browse files
author
Patrick Ivarsson
committed
Fix for default text size being set in PX instead of DP
The default text size in ComponentBase was defined as 10 pixels instead of 10dp, which causes tiny text and does not reflect the javadoc and the general behavior of setTextSize(...)
1 parent ccf6b7e commit 6966b81

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

MPChartLib/src/main/java/com/github/mikephil/charting/components/ComponentBase.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ public abstract class ComponentBase {
3636
/**
3737
* the text size of the labels
3838
*/
39-
protected float mTextSize = 10f;
39+
protected float mTextSize = Utils.convertDpToPixel(10f);
4040

4141
/**
4242
* the text color to use for the labels

0 commit comments

Comments
 (0)