do not prepend stroke "none" with a hashtag

This commit is contained in:
tibbi 2017-08-29 22:24:10 +02:00
parent 1159ed07e3
commit 1149834364
2 changed files with 2 additions and 2 deletions

View File

@ -3,5 +3,5 @@ package com.simplemobiletools.draw
import android.graphics.Color
data class PaintOptions(var color: Int = Color.BLACK, var strokeWidth: Float = 5f, var isEraser: Boolean = false) {
fun getColorToExport() = if (isEraser) "none" else Integer.toHexString(color).substring(2)
fun getColorToExport() = if (isEraser) "none" else "#${Integer.toHexString(color).substring(2)}"
}

View File

@ -43,7 +43,7 @@ object Svg {
write(" ")
}
write("\" fill=\"none\" stroke=\"#")
write("\" fill=\"none\" stroke=\"")
write(options.getColorToExport())
write("\" stroke-width=\"")
write(options.strokeWidth.toString())