- Timestamp:
- 2012-07-28T15:23:00+02:00 (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/data/osm/visitor/paint/MapPainter.java
r5374 r5375 440 440 441 441 if (p1 == null || p2 == null) 442 442 return; 443 443 444 444 double angleOffset; … … 466 466 double[] p = pointAt(t, poly, pathLength); 467 467 if (p != null) { 468 469 470 471 472 468 AffineTransform trfm = AffineTransform.getTranslateInstance(p[0] - rect.getX(), p[1]); 469 trfm.rotate(p[2]+angleOffset); 470 double off = -rect.getY() - rect.getHeight()/2 + text.yOffset; 471 trfm.translate(-rect.getWidth()/2, off); 472 gv.setGlyphTransform(i, trfm); 473 473 } 474 474 } … … 504 504 } 505 505 return new double[] { 506 506 poly.xpoints[i-1]+(totalLen - curLen)/segLen*dx, 507 507 poly.ypoints[i-1]+(totalLen - curLen)/segLen*dy, 508 508 Math.atan2(dy, dx)};
Note:
See TracChangeset
for help on using the changeset viewer.