Changeset 6410 in josm
- Timestamp:
- 2013-11-25T01:23:30+01:00 (11 years ago)
- Location:
- trunk
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/data/ignoretags.cfg
r6404 r6410 20 20 S:is_in 21 21 S:wikipedia 22 S:source: 22 23 S:source_ref: 23 24 ; -
trunk/src/org/openstreetmap/josm/tools/Utils.java
r6362 r6410 701 701 char c = str.charAt(start); 702 702 // '\u200B' (ZERO WIDTH SPACE character) needs to be handled manually because of change in Unicode 6.0 (Java 7, see #8918) 703 leadingWhite = (Character.isWhitespace(c) || Character.isSpaceChar(c) || c == '\u200B'); 703 // same for '\uFEFF' (ZERO WIDTH NO-BREAK SPACE) 704 leadingWhite = (Character.isWhitespace(c) || Character.isSpaceChar(c) || c == '\u200B' || c == '\uFEFF'); 704 705 if (leadingWhite) { 705 706 start++; … … 709 710 while (trailingWhite && end > start+1) { 710 711 char c = str.charAt(end-1); 711 trailingWhite = (Character.isWhitespace(c) || Character.isSpaceChar(c) || c == '\u200B'); 712 trailingWhite = (Character.isWhitespace(c) || Character.isSpaceChar(c) || c == '\u200B' || c == '\uFEFF'); 712 713 if (trailingWhite) { 713 714 end--; -
trunk/test/unit/org/openstreetmap/josm/tools/UtilsTest.java
r6175 r6410 31 31 "\u2007"+ // FIGURE SPACE 32 32 "\u200B"+ // ZERO WIDTH SPACE 33 "\uFEFF"+ // ZERO WIDTH NO-BREAK SPACE 33 34 "\u3000"; // IDEOGRAPHIC SPACE 34 35 Assert.assertNull(Utils.strip(null));
Note:
See TracChangeset
for help on using the changeset viewer.