Fix small issues with font size

This commit is contained in:
2021-05-15 20:22:42 -05:00
parent fcadbe7c38
commit c973f93424
3 changed files with 3 additions and 1 deletions

View File

@@ -4,6 +4,7 @@
### Fixed ### Fixed
- Fix crash caused by numerical habits with zero target (#903) - Fix crash caused by numerical habits with zero target (#903)
- Fix small issues with font size
## [2.0.1] - 2021-05-09 ## [2.0.1] - 2021-05-09

View File

@@ -153,7 +153,7 @@ class CheckmarkButtonView(
paint.style = Paint.Style.FILL paint.style = Paint.Style.FILL
} }
paint.textSize = when (value) { paint.textSize = when (id) {
UNKNOWN -> dim(R.dimen.smallerTextSize) UNKNOWN -> dim(R.dimen.smallerTextSize)
else -> dim(R.dimen.smallTextSize) else -> dim(R.dimen.smallTextSize)
} }

View File

@@ -136,6 +136,7 @@ class BarChart(
canvas.drawLine(0.0, y, width, y) canvas.drawLine(0.0, y, width, y)
canvas.setColor(theme.mediumContrastTextColor) canvas.setColor(theme.mediumContrastTextColor)
canvas.setTextAlign(TextAlign.CENTER) canvas.setTextAlign(TextAlign.CENTER)
canvas.setFontSize(theme.smallTextSize)
var prevMonth = -1 var prevMonth = -1
var prevYear = -1 var prevYear = -1
val isLargeInterval = axis.size < 2 || (axis[0].distanceTo(axis[1]) > 300) val isLargeInterval = axis.size < 2 || (axis[0].distanceTo(axis[1]) > 300)