- Timestamp:
- 2018-01-08T20:06:39+01:00 (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/gui/mappaint/styleelement/AreaElement.java
r13173 r13301 20 20 import org.openstreetmap.josm.tools.HiDPISupport; 21 21 import org.openstreetmap.josm.tools.Utils; 22 import org.openstreetmap.josm.tools.bugreport.BugReport; 22 23 23 24 /** … … 86 87 // cast to BufferedImage and get pixel value at the center of the image 87 88 img = HiDPISupport.getBaseImage(img); 88 color = new Color(((BufferedImage) img).getRGB( 89 fillImage.getWidth() / 2, fillImage.getHeight() / 2) 90 ); 89 try { 90 color = new Color(((BufferedImage) img).getRGB( 91 fillImage.getWidth() / 2, fillImage.getHeight() / 2) 92 ); 93 } catch (ArrayIndexOutOfBoundsException e) { 94 throw BugReport.intercept(e).put("env.osm", env.osm).put("iconRef", iconRef).put("fillImage", fillImage).put("img", img); 95 } 91 96 92 97 fillImage.alpha = Utils.clamp(Config.getPref().getInt("mappaint.fill-image-alpha", 255), 0, 255);
Note:
See TracChangeset
for help on using the changeset viewer.