[Unicode]   Common Locale Data Repository : Bug Tracking Home | Site Map | Search
 

Changeset 11610


Ignore:
Timestamp:
05/06/15 08:34:02 (4 years ago)
Author:
mdavis
Message:

cldrbug 8396: added NESW

Location:
trunk
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • trunk/common/dtd/ldml.dtd

    r11553 r11610  
    22232223    <!--@METADATA--> 
    22242224 
    2225 <!ELEMENT unitLength ( alias | ( compoundUnit*, unit*, special* ) ) > 
     2225<!ELEMENT unitLength ( alias | ( compoundUnit*, unit*, coordinateUnit*, special* ) ) > 
    22262226<!ATTLIST unitLength type (long | short | narrow) #REQUIRED > 
    22272227<!ATTLIST unitLength alt NMTOKENS #IMPLIED > 
     
    22542254    <!--@VALUE--> 
    22552255    <!--@DEPRECATED--> 
     2256     
     2257<!ELEMENT coordinateUnit ( alias | ( coordinateUnitPattern*, special* ) ) > 
     2258<!ATTLIST coordinateUnit alt NMTOKENS #IMPLIED > 
     2259<!ATTLIST coordinateUnit draft (approved | contributed | provisional | unconfirmed) #IMPLIED > 
     2260    <!--@METADATA--> 
     2261 
     2262<!ELEMENT coordinateUnitPattern ( #PCDATA ) > 
     2263<!ATTLIST coordinateUnitPattern type (north | east | south | west) #REQUIRED > 
     2264<!ATTLIST coordinateUnitPattern alt NMTOKENS #IMPLIED > 
     2265<!ATTLIST coordinateUnitPattern draft (approved | contributed | provisional | unconfirmed) #IMPLIED > 
     2266    <!--@METADATA--> 
    22562267 
    22572268<!ELEMENT durationUnit ( alias | ( durationUnitPattern*, special* ) ) > 
  • trunk/common/main/root.xml

    r11572 r11610  
    44294429                                <unitPattern count="other">{0} atsp</unitPattern> 
    44304430                        </unit> 
     4431                        <coordinateUnit> 
     4432                            <coordinateUnitPattern type="north">{0}N</coordinateUnitPattern> 
     4433                            <coordinateUnitPattern type="east">{0}E</coordinateUnitPattern> 
     4434                            <coordinateUnitPattern type="south">{0}S</coordinateUnitPattern> 
     4435                            <coordinateUnitPattern type="west">{0}W</coordinateUnitPattern> 
     4436                        </coordinateUnit> 
    44314437                </unitLength> 
    44324438                <unitLength type="narrow"> 
  • trunk/common/supplemental/coverageLevels.xml

    r11609 r11610  
    510510        <coverageLevel value="modern" match="units/unitLength[@type='%unitNonNarrowLengths']/unit[@type='%unitsNonEnglish']/perUnitPattern"/> 
    511511        <coverageLevel value="modern" match="units/unitLength[@type='%unitLengths']/compoundUnit[@type='%compoundUnitTypes']/compoundUnitPattern"/> 
     512        <coverageLevel value="modern" match="units/unitLength[@type='%unitLengths']/coordinateUnit/coordinateUnitPattern[@type='%anyAlphaNum']"/> 
    512513                <coverageLevel inLanguage="en" value="modern" match="units/unitLength[@type='%unitLengths']/unit[@type='%unitsEnglish']/unitPattern[@count='${Target-Plurals}']"/> 
    513514                <coverageLevel inLanguage="en" value="modern" match="units/unitLength[@type='%unitLengths']/unit[@type='%unitsEnglish']/displayName"/> 
  • trunk/tools/java/org/unicode/cldr/icu/ldml2icu_locale.txt

    r11548 r11610  
    232232//ldml/units/unitLength[@type="long"]/compoundUnit[@type="(%A)"]/compoundUnitPattern ; /units/compound/$1 
    233233 
     234//ldml/units/unitLength[@type="narrow"]/coordinateUnit/coordinateUnitPattern[@type="(%A)"] ; /unitsNarrow/coordinate/$1 
     235//ldml/units/unitLength[@type="short"]/coordinateUnit/coordinateUnitPattern[@type="(%A)"] ; /unitsShort/coordinate/$1 
     236//ldml/units/unitLength[@type="long"]/coordinateUnit/coordinateUnitPattern[@type="(%A)"] ; /units/coordinate/$1 
     237 
    234238//ldml/units/unitLength[@type="narrow"]/unit[@type="(\w++)-(%A)"]/perUnitPattern ; /unitsNarrow/$1/$2/per 
    235239//ldml/units/unitLength[@type="short"]/unit[@type="(\w++)-(%A)"]/perUnitPattern ; /unitsShort/$1/$2/per 
  • trunk/tools/java/org/unicode/cldr/test/CheckDisplayCollisions.java

    r11503 r11610  
    292292        //ldml/units/unitLength[@type="narrow"]/unit[@type="duration-day-future"]/unitPattern[@count="one"] 
    293293        if (myType == Type.UNITS) { 
    294             XPathParts parts = new XPathParts().set(path); 
    295             String myUnit = parts.getAttributeValue(3, "type"); 
     294            XPathParts parts = XPathParts.getInstance(path); 
     295            int typeLocation = parts.getElement(-1).equals("coordinateUnitPattern") ? -1 : 3; 
     296            String myUnit = parts.getAttributeValue(typeLocation, "type"); 
    296297            boolean isDuration = myUnit.startsWith("duration"); 
    297298            Iterator<String> iterator = paths.iterator(); 
     
    299300                String curVal = iterator.next(); 
    300301                parts.set(curVal); 
    301                 String unit = parts.getAttributeValue(3, "type"); 
     302                String unit = parts.getAttributeValue(typeLocation, "type"); 
    302303                // we also break the units into two groups: durations and others. Also never collide with a compoundUnitPattern. 
    303304                if (myUnit.equals(unit) || unit != null && isDuration != unit.startsWith("duration") || 
  • trunk/tools/java/org/unicode/cldr/util/data/PathDescription.txt

    r11563 r11610  
    6060 
    6161^//ldml/units/unitLength\[@type="([^"]*)"]/compoundUnit\[@type="([^"]*)"]/compoundUnitPattern ; Special pattern used to compose forms of two units, such as meters per second. Note: before translating, be sure to read http://cldr.org/translation/units. 
     62^//ldml/units/unitLength\[@type="([^"]*)"]/coordinateUnit/coordinateUnitPattern\[@type="([^"]*)"] ; Special pattern used in latitude and longitude, such as 12°N. Note: before translating, be sure to read http://cldr.org/translation/units. 
    6263 
    6364^//ldml/units/unitLength\[@type="([^"]*)"]/unit\[@type="area-acre"]/displayName ; Display name ({1} form) for “area-acre”, referring specifically to an English acre. Note: before translating, be sure to read http://cldr.org/translation/plurals. 
  • trunk/tools/java/org/unicode/cldr/util/data/PathHeader.txt

    r11561 r11610  
    160160//ldml/units/durationUnit[@type="(hms|hm|ms)"]                                                          ; Units ; Duration ; Duration Patterns ; $1 
    161161 
     162//ldml/units/unitLength[@type="%L"]/coordinateUnit/coordinateUnitPattern[@type="%A"]                    ; Units ; Other Units ; coordinate-$2 ; $1  
     163 
    162164### Miscellaneous 
    163165//ldml/listPatterns/listPattern/listPatternPart[@type="%A"] ; Misc ; Displaying Lists ; Regular Lists ; &listOrder($1) 
  • trunk/tools/java/org/unicode/cldr/util/data/Placeholders.txt

    r10172 r11610  
    160160 
    161161^//ldml/units/unitLength\[@type="%L"]/compoundUnit\[@type="%A"]/compoundUnitPattern ; locale ; {0}=DIVIDEND UNIT meters ; {1}=DIVIDEND UNIT second 
     162^//ldml/units/unitLength\[@type="%L"]/coordinateUnit/coordinateUnitPattern\[@type="%A"] ; locale ; {0}=DEGREES 12° 
    162163 
    163164^//ldml/units/unitLength\[@type="%L"]/unit\[@type="duration-day%A"]/unitPattern\[@count="\w+"] ; locale ; {0}=NUMBER_OF_DAYS 3 
Note: See TracChangeset for help on using the changeset viewer.