summaryrefslogtreecommitdiffstats
path: root/src/display/drawing-shape.cpp
diff options
context:
space:
mode:
authorRick Yorgason <rick@firefang.com>2018-10-18 08:21:15 +0000
committerRick Yorgason <rick@firefang.com>2018-10-18 08:21:15 +0000
commit83bf2fdf80496f0368438e16bc3adb8ee0e86fb7 (patch)
tree83d50e748c8fb85ea4bbcd267c9b5364722e4841 /src/display/drawing-shape.cpp
parentNew "Outline thin strokes" view mode which draws thin strokes in outline mode... (diff)
downloadinkscape-83bf2fdf80496f0368438e16bc3adb8ee0e86fb7.tar.gz
inkscape-83bf2fdf80496f0368438e16bc3adb8ee0e86fb7.zip
Renamed "Outline thin strokes" to "visible hairlines" to make the intent clearer.
Diffstat (limited to 'src/display/drawing-shape.cpp')
-rw-r--r--src/display/drawing-shape.cpp28
1 files changed, 14 insertions, 14 deletions
diff --git a/src/display/drawing-shape.cpp b/src/display/drawing-shape.cpp
index c2208d161..05123297e 100644
--- a/src/display/drawing-shape.cpp
+++ b/src/display/drawing-shape.cpp
@@ -186,13 +186,13 @@ DrawingShape::_renderStroke(DrawingContext &dc)
}
_nrstyle.applyStroke(dc);
- // Special handling for thin outline mode when we're drawing lines smaller than half a
- // pixel
- if (_drawing.outlineThin()) {
- double outline_thin_size = 0.5, trash = 0.5;
- dc.device_to_user_distance(outline_thin_size, trash);
- if (_nrstyle.stroke_width < outline_thin_size) {
- dc.setLineWidth(outline_thin_size);
+ // If the draw mode is set to visible hairlines, don't let them get smaller than half a
+ // pixel.
+ if (_drawing.visibleHairlines()) {
+ double half_pixel_size = 0.5, trash = 0.5;
+ dc.device_to_user_distance(half_pixel_size, trash);
+ if (_nrstyle.stroke_width < half_pixel_size) {
+ dc.setLineWidth(half_pixel_size);
}
}
@@ -267,13 +267,13 @@ DrawingShape::_renderItem(DrawingContext &dc, Geom::IntRect const &area, unsigne
if (has_stroke) {
_nrstyle.applyStroke(dc);
- // Special handling for thin outline mode when we're drawing lines smaller than
- // half a pixel
- if (_drawing.outlineThin()) {
- double outline_thin_size = 0.5, trash = 0.5;
- dc.device_to_user_distance(outline_thin_size, trash);
- if (_nrstyle.stroke_width < outline_thin_size) {
- dc.setLineWidth(outline_thin_size);
+ // If the draw mode is set to visible hairlines, don't let anything get smaller
+ // than half a pixel.
+ if (_drawing.visibleHairlines()) {
+ double half_pixel_size = 0.5, trash = 0.5;
+ dc.device_to_user_distance(half_pixel_size, trash);
+ if (_nrstyle.stroke_width < half_pixel_size) {
+ dc.setLineWidth(half_pixel_size);
}
}