work in progress
This commit is contained in:
parent
914cbd7568
commit
2c97a83e1a
3 changed files with 3 additions and 14 deletions
|
@ -191,6 +191,7 @@ public abstract class MapObject implements Comparable<MapObject> {
|
|||
}
|
||||
|
||||
public String getEnName(boolean transliterate) {
|
||||
System.out.println("Get name");
|
||||
if (!Algorithms.isEmpty(enName)) {
|
||||
return this.enName;
|
||||
} else if (!Algorithms.isEmpty(getName()) && transliterate) {
|
||||
|
|
|
@ -138,14 +138,7 @@ public class NominatimPoiFilter extends PoiUIFilter {
|
|||
a.setId(Long.parseLong(parser.getAttributeValue("", "place_id"))); //$NON-NLS-1$ //$NON-NLS-2$
|
||||
String name = parser.getAttributeValue("", "display_name"); //$NON-NLS-1$//$NON-NLS-2$
|
||||
a.setName(name);
|
||||
log.debug("Setting english name:");
|
||||
log.debug("is CJK sign? : " + CustomTransliterationHelper.isCharCJK(name.charAt(0)));
|
||||
if (CustomTransliterationHelper.isCharCJK(name.charAt(0))) {
|
||||
a.setEnName(CustomTransliterationHelper.japanese2Romaji(name));
|
||||
} else {
|
||||
a.setEnName(Junidecode.unidecode(name));
|
||||
}
|
||||
|
||||
a.setSubType(parser.getAttributeValue("", "type")); //$NON-NLS-1$//$NON-NLS-2$
|
||||
PoiType pt = poiTypes.getPoiTypeByKey(a.getSubType());
|
||||
a.setType(pt != null ? pt.getCategory() : poiTypes.getOtherPoiCategory());
|
||||
|
|
|
@ -237,13 +237,8 @@ public class TextRenderer {
|
|||
TextDrawInfo text = rc.textToDraw.get(i);
|
||||
if (text.text != null && text.text.length() > 0) {
|
||||
if (preferredLocale.length() > 0) {
|
||||
|
||||
if (CustomTransliterationHelper.isCharCJK(text.text.charAt(0))) {
|
||||
text.text = CustomTransliterationHelper.japanese2Romaji(text.text);
|
||||
} else {
|
||||
text.text = Junidecode.unidecode(text.text);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue