Add the ability to fake bold text in the MapTextLayer

This commit is contained in:
Alex Sytnyk 2018-07-25 17:25:23 +03:00
parent b04b7b085e
commit c876c0aadb
4 changed files with 18 additions and 0 deletions

View file

@ -263,6 +263,11 @@ public class FavouritesLayer extends OsmandMapLayer implements ContextMenuLayer.
return settings.SHOW_POI_LABEL.get();
}
@Override
public boolean isFakeBoldText() {
return false;
}
@Override
public boolean isObjectMovable(Object o) {

View file

@ -637,6 +637,11 @@ public class GPXLayer extends OsmandMapLayer implements ContextMenuLayer.IContex
return view.getSettings().SHOW_POI_LABEL.get();
}
@Override
public boolean isFakeBoldText() {
return false;
}
public void setGivenGpx(GPXFile gpx) {
this.gpx = gpx;

View file

@ -36,6 +36,8 @@ public class MapTextLayer extends OsmandMapLayer {
String getText(T o);
boolean isTextVisible();
boolean isFakeBoldText();
}
public void putData(OsmandMapLayer ml, Collection<?> objects) {
@ -60,6 +62,7 @@ public class MapTextLayer extends OsmandMapLayer {
continue;
}
paintTextIcon.setFakeBoldText(provider.isFakeBoldText());
for (Object o : textObjects.get(l)) {
double lat = provider.getTextLocation(o).getLatitude();
double lon = provider.getTextLocation(o).getLongitude();

View file

@ -420,6 +420,11 @@ public class POIMapLayer extends OsmandMapLayer implements ContextMenuLayer.ICon
return app.getSettings().SHOW_POI_LABEL.get();
}
@Override
public boolean isFakeBoldText() {
return false;
}
@Override
public void newRouteIsCalculated(boolean newRoute, ValueHolder<Boolean> showToast) {
}