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

CLDR Ticket #10798(closed tools: fixed)

Opened 8 months ago

Last modified 5 months ago

Provide width checking for emoji names

Reported by: mark Owned by: mark
Component: unknown Data Locale:
Phase: dsub Review: pedberg
Weeks: Data Xpath:
Xref:

Description (last modified by mark) (diff)

We have gotten complaints that emoji are too long, a special problem for TTS. I have a locale copy of preliminary changes to CheckWidth to test for that.

Note that the code can parameterize in the following ways:

  1. type of check
    1. Check # of code points VS
    2. Check width (average widths of characters in fonts).
  2. limits
    1. Minimum value for warning (above that the user gets warnings like "Warning: Too wide by about 20%")
    2. Minimum value for error (above that the user gets errors like "Error: Too wide by about 90%")

For a test, I used width values based off of a long English name, subtracting a percent for the minimum warning limit, and adding a percent for the minimum error limit.

.add("//ldml/annotations/annotation[@cp=%A][@type=%A]", new Limit[] {
  new Limit(
   ApproximateWidth.getWidth("grinning cat face with smiling eyes")/1.25, 
   ApproximateWidth.getWidth("grinning cat face with smiling eyes")*1.25, 
   Measure.DISPLAY_WIDTH, LimitType.MAXIMUM, Special.NONE)
})

Here is one run with output.
https://drive.google.com/open?id=190xbqjU53nhJb1RgQjR6edZlAz8W8JUx

Attachments

Change History

comment:1 Changed 8 months ago by pedberg

  • Cc fredrik, pedberg added

Note, Apple disagrees with the premise here. We often prefer longer and more-clear names for tts, and would object to overly strong discouragement of those. Any warning should indicate that the issue is platform specific, e.g. "on some platforms, names of this length are discouraged...". We don't want an outright error.

Last edited 8 months ago by pedberg (previous) (diff)

comment:2 Changed 8 months ago by mark

  • Description modified (diff)

comment:3 Changed 8 months ago by mark

Ok, if changed to error limit = 100EM. Mark to try it out and make sure it doesn’t cause more than dozen or so errors.

comment:4 Changed 8 months ago by mark

  • Owner changed from anybody to mark
  • Priority changed from assess to major
  • Type changed from unknown to tools
  • Status changed from new to accepted
  • Milestone changed from UNSCH to 33

comment:5 Changed 8 months ago by mark

  • Priority changed from major to assess
  • Type changed from tools to unknown
  • Milestone changed from 33 to UNSCH

comment:6 Changed 5 months ago by mark

  • Priority changed from assess to major
  • Status changed from accepted to reviewing
  • Type changed from unknown to tools
  • Review set to pedberg
  • Milestone changed from UNSCH to 33

comment:7 Changed 5 months ago by pedberg

  • Status changed from reviewing to closed
  • Resolution set to fixed
View

Add a comment

Modify Ticket

Action
as closed
Next status will be 'new'
Next status will be 'closed'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.