This code duplication is unfortunate. I'd like to see the `StrokeOptions` at least factored out. Also if you did the app-unit-to-pixel-conversion up at once I think it would make the code clearer.