GNOME Bugzilla – Bug 684222
add API to access unicode grapheme break property
Last modified: 2018-05-24 14:34:16 UTC
We should add API to access the unicode character's GraphemeBreakProperty. This will be neccessary for the update to PCRE 8.32 (which uses this character property to implement \X ) and also be useful for pango. Proposed API on wip/unicode-graphemebreak branch, using the same approach as the line break property API.
Looks good in general. Two points: 1. The Hangul values can be calculated algorithmically. That would be a huge saving and worth trying IMO. 2. In general I'm hesitant about adding more Unicode properties to glib, but that's a lost battle... Grapheme break is useful to a wide variety of applications, so I like this proposal.
FWIW, I need this, and WordBreak and SentenceBreak properties for pango_break() rework. I was thinking about adding them in Pango privately, but seems like maybe there's more use to them?
IMHO if we're going to have those tables in our stack, we might just as well have them in glib :-) I'm not sure when I'm going to have time to work on this patch again, however, so if you need them *now* and don't want to work on glib, it should be fine to add them to pango first and later change to use glib once the API's there.
I'm in no rush either. If I end up wanting to hack on it during the holidays, I'll go ahead and push them into glib. The problem with these types is, they are really only relevant to the specific algorithms using them, which are in pango. But who care... The extra api is not gonna kill anyone.
Christian, do you have an updated branch for 7.0 ?
I haven't worked on this since the original wip branch, so no, I don't have an updated branch. The patch also needs work to at least handle hangul algorithmically (comment 1).
-- GitLab Migration Automatic Message -- This bug has been migrated to GNOME's GitLab instance and has been closed from further activity. You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.gnome.org/GNOME/glib/issues/603.