- Timestamp:
- 2014-05-02T00:04:06+02:00 (11 years ago)
- Location:
- trunk/src/org/openstreetmap/josm/data/osm/visitor/paint
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/data/osm/visitor/paint/LineClip.java
r6920 r7040 18 18 private final Rectangle clipBounds; 19 19 20 /** 21 * Constructs a new {@code LineClip}. 22 * @param p1 start point of the clipped line 23 * @param p2 end point of the clipped line 24 * @param clipBounds Clip bounds 25 */ 20 26 public LineClip(Point p1, Point p2, Rectangle clipBounds) { 21 27 this.p1 = p1; … … 29 35 */ 30 36 public boolean execute() { 37 if (clipBounds == null) { 38 return false; 39 } 31 40 return cohenSutherland(p1.x, p1.y, p2.x, p2.y, clipBounds.x , clipBounds.y, clipBounds.x + clipBounds.width, clipBounds.y + clipBounds.height); 32 41 } … … 35 44 * @return start point of the clipped line 36 45 */ 37 public Point getP1() 38 { 46 public Point getP1() { 39 47 return p1; 40 48 } -
trunk/src/org/openstreetmap/josm/data/osm/visitor/paint/StyledMapRenderer.java
r7023 r7040 1175 1175 GeneralPath onewayArrowsCasing = showOneway ? new GeneralPath() : null; 1176 1176 Rectangle bounds = g.getClipBounds(); 1177 bounds.grow(100, 100); // avoid arrow heads at the border 1177 if (bounds != null) { 1178 // avoid arrow heads at the border 1179 bounds.grow(100, 100); 1180 } 1178 1181 1179 1182 double wayLength = 0;
Note:
See TracChangeset
for help on using the changeset viewer.