Avoid redundant updates to line style and stroke width