Changeset 12285 in josm for trunk/src/org/openstreetmap
- Timestamp:
- 2017-05-31T17:07:52+02:00 (8 years ago)
- Location:
- trunk/src/org/openstreetmap/josm
- Files:
-
- 1 deleted
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/data/osm/visitor/paint/StyledMapRenderer.java
r12208 r12285 392 392 * polygons) 393 393 * @param disabled If this should be drawn with a special disabled style. 394 * @param text Ignored. Use {@link #drawText(OsmPrimitive, TextLabel)} instead.395 394 */ 396 395 protected void drawArea(MapViewPath path, Color color, 397 MapImage fillImage, Float extent, Path2D.Double pfClip, boolean disabled , TextLabel text) {396 MapImage fillImage, Float extent, Path2D.Double pfClip, boolean disabled) { 398 397 if (!isOutlineOnly && color.getAlpha() != 0) { 399 398 Shape area = path; … … 455 454 * be replaced by plain fill, when it covers a certain fraction of the total area 456 455 * @param disabled If this should be drawn with a special disabled style. 457 * @param text The text to write on the area. 458 */ 456 * @param text Ignored. Use {@link #drawText(OsmPrimitive, TextLabel)} instead. 457 * @deprecated use {@link #drawArea(Relation r, Color color, MapImage fillImage, Float extent, Float extentThreshold, boolean disabled)} 458 */ 459 @Deprecated 459 460 public void drawArea(Relation r, Color color, MapImage fillImage, Float extent, Float extentThreshold, boolean disabled, TextLabel text) { 461 drawArea(r, color, fillImage, extent, extentThreshold, disabled); 462 } 463 464 /** 465 * Draws a multipolygon area. 466 * @param r The multipolygon relation 467 * @param color The color to fill the area with. 468 * @param fillImage The image to fill the area with. Overrides color. 469 * @param extent if not null, area will be filled partially; specifies, how 470 * far to fill from the boundary towards the center of the area; 471 * if null, area will be filled completely 472 * @param extentThreshold if not null, determines if the partial filled should 473 * be replaced by plain fill, when it covers a certain fraction of the total area 474 * @param disabled If this should be drawn with a special disabled style. 475 * @since 12285 476 */ 477 public void drawArea(Relation r, Color color, MapImage fillImage, Float extent, Float extentThreshold, boolean disabled) { 460 478 Multipolygon multipolygon = MultipolygonCache.getInstance().get(r); 461 479 if (!r.isDisabled() && !multipolygon.getOuterWays().isEmpty()) { … … 477 495 drawArea(p, 478 496 pd.isSelected() ? paintSettings.getRelationSelectedColor(color.getAlpha()) : color, 479 fillImage, extent, pfClip, disabled , text);497 fillImage, extent, pfClip, disabled); 480 498 } 481 499 } … … 493 511 * be replaced by plain fill, when it covers a certain fraction of the total area 494 512 * @param disabled If this should be drawn with a special disabled style. 495 * @param text The text to write on the area. 496 */ 513 * @param text Ignored. Use {@link #drawText(OsmPrimitive, TextLabel)} instead. 514 * @deprecated use {@link #drawArea(Way w, Color color, MapImage fillImage, Float extent, Float extentThreshold, boolean disabled)} 515 */ 516 @Deprecated 497 517 public void drawArea(Way w, Color color, MapImage fillImage, Float extent, Float extentThreshold, boolean disabled, TextLabel text) { 518 drawArea(w, color, fillImage, extent, extentThreshold, disabled); 519 } 520 521 /** 522 * Draws an area defined by a way. They way does not need to be closed, but it should. 523 * @param w The way. 524 * @param color The color to fill the area with. 525 * @param fillImage The image to fill the area with. Overrides color. 526 * @param extent if not null, area will be filled partially; specifies, how 527 * far to fill from the boundary towards the center of the area; 528 * if null, area will be filled completely 529 * @param extentThreshold if not null, determines if the partial filled should 530 * be replaced by plain fill, when it covers a certain fraction of the total area 531 * @param disabled If this should be drawn with a special disabled style. 532 * @since 12285 533 */ 534 public void drawArea(Way w, Color color, MapImage fillImage, Float extent, Float extentThreshold, boolean disabled) { 498 535 Path2D.Double pfClip = null; 499 536 if (extent != null) { … … 504 541 } 505 542 } 506 drawArea(getPath(w), color, fillImage, extent, pfClip, disabled , text);543 drawArea(getPath(w), color, fillImage, extent, pfClip, disabled); 507 544 } 508 545 … … 1156 1193 } 1157 1194 } 1158 }1159 1160 /**1161 * Draws a text along a given way.1162 * @param way The way to draw the text on.1163 * @param text The text definition (font/.../text content) to draw.1164 * @deprecated Use {@link #drawText(OsmPrimitive, TextLabel)} instead.1165 */1166 @Deprecated1167 public void drawTextOnPath(Way way, TextLabel text) {1168 // NOP.1169 1195 } 1170 1196 -
trunk/src/org/openstreetmap/josm/gui/PleaseWaitDialog.java
r11673 r12285 12 12 13 13 import javax.swing.BorderFactory; 14 import javax.swing.BoundedRangeModel;15 14 import javax.swing.JButton; 16 15 import javax.swing.JDialog; … … 37 36 private final JLabel currentAction = new JLabel(""); 38 37 private final JLabel customText = new JLabel(""); 39 /** 40 * The direct progress access. 41 * @deprecated To be removed in mid-2017. Use {@link #updateProgress(int)} 42 */ 43 @Deprecated 44 public final transient BoundedRangeModel progress = progressBar.getModel(); 38 45 39 private JButton btnCancel; 46 40 private JButton btnInBackground; -
trunk/src/org/openstreetmap/josm/gui/dialogs/LatLonDialog.java
r12279 r12285 320 320 } 321 321 322 /**323 * Parses the given string as lat/lon.324 * @param coord String to parse325 * @return parsed lat/lon326 * @deprecated use {@link LatLon#parse(String)} instead327 */328 @Deprecated329 public static LatLon parseLatLon(final String coord) {330 return LatLon.parse(coord);331 }332 333 322 public static EastNorth parseEastNorth(String s) { 334 323 String[] en = s.split("[;, ]+"); -
trunk/src/org/openstreetmap/josm/gui/mappaint/styleelement/AreaElement.java
r11811 r12285 40 40 */ 41 41 public MapImage fillImage; 42 43 /**44 * The text that should be written on this area.45 * @deprecated Use {@link TextElement} instead.46 */47 @Deprecated48 public TextLabel text;49 42 50 43 /** … … 127 120 } 128 121 } 129 painter.drawArea((Way) osm, myColor, fillImage, extent, extentThreshold, painter.isInactiveMode() || osm.isDisabled() , text);122 painter.drawArea((Way) osm, myColor, fillImage, extent, extentThreshold, painter.isInactiveMode() || osm.isDisabled()); 130 123 } else if (osm instanceof Relation) { 131 124 if (color != null && (selected || outermember)) { 132 125 myColor = paintSettings.getRelationSelectedColor(color.getAlpha()); 133 126 } 134 painter.drawArea((Relation) osm, myColor, fillImage, extent, extentThreshold, painter.isInactiveMode() || osm.isDisabled() , text);127 painter.drawArea((Relation) osm, myColor, fillImage, extent, extentThreshold, painter.isInactiveMode() || osm.isDisabled()); 135 128 } 136 129 } -
trunk/src/org/openstreetmap/josm/gui/mappaint/styleelement/TextLabel.java
r12082 r12285 15 15 import org.openstreetmap.josm.gui.mappaint.styleelement.LabelCompositionStrategy.StaticLabelCompositionStrategy; 16 16 import org.openstreetmap.josm.gui.mappaint.styleelement.LabelCompositionStrategy.TagLookupCompositionStrategy; 17 import org.openstreetmap.josm.gui.mappaint.styleelement.placement.CompletelyInsideAreaStrategy;18 17 import org.openstreetmap.josm.gui.mappaint.styleelement.placement.PositionForAreaStrategy; 19 18 import org.openstreetmap.josm.tools.CheckParameterUtil; … … 61 60 */ 62 61 private final PositionForAreaStrategy labelPositionStrategy; 63 64 /**65 * Creates a new text element66 *67 * @param strategy the strategy indicating how the text is composed for a specific {@link OsmPrimitive} to be rendered.68 * If null, no label is rendered.69 * @param font the font to be used. Must not be null.70 * @param xOffset x offset71 * @param yOffset y offset72 * @param color the color to be used. Must not be null73 * @param haloRadius halo radius74 * @param haloColor halo color75 * @deprecated since 11722, To be removed in mid-201776 */77 @Deprecated78 public TextLabel(LabelCompositionStrategy strategy, Font font, int xOffset, int yOffset, Color color, Float haloRadius, Color haloColor) {79 this(strategy, font, xOffset, yOffset, color, haloRadius, haloColor, CompletelyInsideAreaStrategy.INSTANCE);80 }81 62 82 63 /**
Note:
See TracChangeset
for help on using the changeset viewer.