Always use gray textColor because dynamic colors are not supported when used with DrawContext

Percent-Values were invisible in the videt and only visible in the scriptable.app.
This commit is contained in:
Stefan Seiz 2021-01-02 18:10:29 +01:00
parent da9005bb5a
commit cfbcbe677d

View file

@ -156,7 +156,7 @@ function getDiagram(percentage) {
canvTextSize canvTextSize
) )
canvas.setTextAlignedCenter() canvas.setTextAlignedCenter()
canvas.setTextColor(Color.dynamic(Color.black(), Color.white())) canvas.setTextColor(Color.gray())
canvas.setFont(Font.boldSystemFont(canvTextSize)) canvas.setFont(Font.boldSystemFont(canvTextSize))
canvas.drawTextInRect(`${percentage}%`, canvTextRect) canvas.drawTextInRect(`${percentage}%`, canvTextRect)