Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Consonant clusters with a visible virama should only have the first consonant+virama highlighted #115

Open
r12a opened this issue Mar 30, 2021 · 1 comment
Labels
doc:beng doc:deva gap i:initials Styling initials l:bn Bengali language & script l:hi Hindi, Devanagari script p:advanced s:beng Bengali script s:deva Devanagari script x:beng x:blink x:deva x:webkit

Comments

@r12a
Copy link
Contributor

r12a commented Mar 30, 2021

This issue is applicable to most languages that form conjuncts from consonant clusters using a visible virama.

When the start of a line contains a 2-consonant cluster that uses a visible virama, ::first-letter should highlight only the first consonant+virama. This corresponds to a grapheme cluster, as defined by Unicode.

Specs:
css-text-3 CSS uses the concept of 'typographic character unit', which defaults to a grapheme cluster. The spec doesn't provide details about the support needed for each language.

The Unicode Consortium defines grapheme clusters to, by default, stop after the first virama in a cluster.

Tests & results:
Interactive test, When ::first-letter is applied to Devanagari the browser will NOT select a 2-consonant cluster as a unit if the virama is visible

Interactive test, When ::first-letter is applied to Bengali the browser will only select the first consonant+virama in a cluster if the virama is visible

Gecko only highlights the initial character+virama. Blink, and Webkit select all clusters as a single unit, whether or not they are conjuncts or are rendered with a visible virama.

Browser bug reports:
BlinkWebKit

Priority:
This choice needs to be discussed. If a cluster is rendered as a conjunct, it should be selected as a single unit. If, instead, the virama is displayed (ie. it is not a conjunct) then only the initial part of the cluster should be selected. Since the underlying code points are identical if a cluster is displayed as a conjunct or instead with visible viramas, it's not possible to distinguish one situation from another by working with the code points. In the absence of a technical solution that examines what the font used does when rendering, this is a difficult problem to solve. This priority rating says that, in the absence of a perfect solution, it is better to select a whole non-conjunct cluster than to break a conjunct. So it is labelled advanced, rather than basic.

@r12a r12a changed the title Consonant clusters with a visible virama are selected as a single unit Consonant clusters with a visible virama should only have the first consonant+virama highlighted Mar 30, 2021
@r12a
Copy link
Contributor Author

r12a commented Mar 30, 2021

The first comment in this issue contains text that will automatically appear in one or more gap-analysis documents as a subsection with the same title as this issue. Any edits made to that comment will be immediately available in the document. Proposals for changes or discussion of the content can be made in comments below this point.

Relevant gap analysis documents include:
BengaliDevanagari

@r12a r12a added the doc:beng label Mar 30, 2021
@r12a r12a added l:hi Hindi, Devanagari script l:bn Bengali language & script labels May 1, 2024
@r12a r12a added s:beng Bengali script s:deva Devanagari script labels Jul 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
doc:beng doc:deva gap i:initials Styling initials l:bn Bengali language & script l:hi Hindi, Devanagari script p:advanced s:beng Bengali script s:deva Devanagari script x:beng x:blink x:deva x:webkit
Projects
Status: Browser bug raised
Development

No branches or pull requests

1 participant