void StrokeSnappedEdgesOfRect(const Rect& aRect, DrawTarget& aDrawTarget, const ColorPattern& aColor, const StrokeOptions& aStrokeOptions) { if (aRect.IsEmpty()) { return; } Point p1 = aRect.TopLeft(); Point p2 = aRect.BottomLeft(); SnapLineToDevicePixelsForStroking(p1, p2, aDrawTarget); aDrawTarget.StrokeLine(p1, p2, aColor, aStrokeOptions); p1 = aRect.BottomLeft(); p2 = aRect.BottomRight(); SnapLineToDevicePixelsForStroking(p1, p2, aDrawTarget); aDrawTarget.StrokeLine(p1, p2, aColor, aStrokeOptions); p1 = aRect.TopLeft(); p2 = aRect.TopRight(); SnapLineToDevicePixelsForStroking(p1, p2, aDrawTarget); aDrawTarget.StrokeLine(p1, p2, aColor, aStrokeOptions); p1 = aRect.TopRight(); p2 = aRect.BottomRight(); SnapLineToDevicePixelsForStroking(p1, p2, aDrawTarget); aDrawTarget.StrokeLine(p1, p2, aColor, aStrokeOptions); }