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

Add Unicode 14.0 math script style variation selector mappings #218

Open
tiroj opened this issue Oct 11, 2021 · 9 comments
Open

Add Unicode 14.0 math script style variation selector mappings #218

tiroj opened this issue Oct 11, 2021 · 9 comments
Assignees
Milestone

Comments

@tiroj
Copy link
Contributor

tiroj commented Oct 11, 2021

Unicode 14.0 defines new standardised variation selector sequences for chancery vs roundhand script styles of math alphabetics, but only for uppercase letters and only in regular weight:

# Mathematical alphabet script variants

1D49C FE00; chancery style; #  MATHEMATICAL SCRIPT CAPITAL A
212C FE00;  chancery style; #  SCRIPT CAPITAL B
1D49E FE00; chancery style; #  MATHEMATICAL SCRIPT CAPITAL C
1D49F FE00; chancery style; #  MATHEMATICAL SCRIPT CAPITAL D
2130 FE00;  chancery style; #  SCRIPT CAPITAL E
2131 FE00;  chancery style; #  SCRIPT CAPITAL F
1D4A2 FE00; chancery style; #  MATHEMATICAL SCRIPT CAPITAL G
210B FE00;  chancery style; #  SCRIPT CAPITAL H
2110 FE00;  chancery style; #  SCRIPT CAPITAL I
1D4A5 FE00; chancery style; #  MATHEMATICAL SCRIPT CAPITAL J
1D4A6 FE00; chancery style; #  MATHEMATICAL SCRIPT CAPITAL K
2112 FE00;  chancery style; #  SCRIPT CAPITAL L
2133 FE00;  chancery style; #  SCRIPT CAPITAL M
1D4A9 FE00; chancery style; #  MATHEMATICAL SCRIPT CAPITAL N
1D4AA FE00; chancery style; #  MATHEMATICAL SCRIPT CAPITAL O
1D4AB FE00; chancery style; #  MATHEMATICAL SCRIPT CAPITAL P
1D4AC FE00; chancery style; #  MATHEMATICAL SCRIPT CAPITAL Q
211B FE00;  chancery style; #  SCRIPT CAPITAL R
1D4AE FE00; chancery style; #  MATHEMATICAL SCRIPT CAPITAL S
1D4AF FE00; chancery style; #  MATHEMATICAL SCRIPT CAPITAL T
1D4B0 FE00; chancery style; #  MATHEMATICAL SCRIPT CAPITAL U
1D4B1 FE00; chancery style; #  MATHEMATICAL SCRIPT CAPITAL V
1D4B2 FE00; chancery style; #  MATHEMATICAL SCRIPT CAPITAL W
1D4B3 FE00; chancery style; #  MATHEMATICAL SCRIPT CAPITAL X
1D4B4 FE00; chancery style; #  MATHEMATICAL SCRIPT CAPITAL Y
1D4B5 FE00; chancery style; #  MATHEMATICAL SCRIPT CAPITAL Z

1D49C FE01; roundhand style; #  MATHEMATICAL SCRIPT CAPITAL A
212C FE01;  roundhand style; #  SCRIPT CAPITAL B
1D49E FE01; roundhand style; #  MATHEMATICAL SCRIPT CAPITAL C
1D49F FE01; roundhand style; #  MATHEMATICAL SCRIPT CAPITAL D
2130 FE01;  roundhand style; #  SCRIPT CAPITAL E
2131 FE01;  roundhand style; #  SCRIPT CAPITAL F
1D4A2 FE01; roundhand style; #  MATHEMATICAL SCRIPT CAPITAL G
210B FE01;  roundhand style; #  SCRIPT CAPITAL H
2110 FE01;  roundhand style; #  SCRIPT CAPITAL I
1D4A5 FE01; roundhand style; #  MATHEMATICAL SCRIPT CAPITAL J
1D4A6 FE01; roundhand style; #  MATHEMATICAL SCRIPT CAPITAL K
2112 FE01;  roundhand style; #  SCRIPT CAPITAL L
2133 FE01;  roundhand style; #  SCRIPT CAPITAL M
1D4A9 FE01; roundhand style; #  MATHEMATICAL SCRIPT CAPITAL N
1D4AA FE01; roundhand style; #  MATHEMATICAL SCRIPT CAPITAL O
1D4AB FE01; roundhand style; #  MATHEMATICAL SCRIPT CAPITAL P
1D4AC FE01; roundhand style; #  MATHEMATICAL SCRIPT CAPITAL Q
211B FE01;  roundhand style; #  SCRIPT CAPITAL R
1D4AE FE01; roundhand style; #  MATHEMATICAL SCRIPT CAPITAL S
1D4AF FE01; roundhand style; #  MATHEMATICAL SCRIPT CAPITAL T
1D4B0 FE01; roundhand style; #  MATHEMATICAL SCRIPT CAPITAL U
1D4B1 FE01; roundhand style; #  MATHEMATICAL SCRIPT CAPITAL V
1D4B2 FE01; roundhand style; #  MATHEMATICAL SCRIPT CAPITAL W
1D4B3 FE01; roundhand style; #  MATHEMATICAL SCRIPT CAPITAL X
1D4B4 FE01; roundhand style; #  MATHEMATICAL SCRIPT CAPITAL Y
1D4B5 FE01; roundhand style; #  MATHEMATICAL SCRIPT CAPITAL Z

For 2.20, the second (roundhand) set of these has been added to the format 14 cmap subtable. The chancery set of variation selector sequences is not needed in the STIX Two Math font because the chancery forms are default. [Note: if someone were to fork the STIX Two Math font to make a version in which the roundhand forms were default, it would be necessary to update the format 14 cmap subtable accordingly.]

The roundhand script style glyphs—including the lowercase and the bold style—are still also mapped in the Stylistic Set ss01 feature, as in v2.10

@tiroj tiroj added this to the v2.20 milestone Oct 11, 2021
@tiroj tiroj self-assigned this Oct 11, 2021
@tiroj tiroj closed this as completed Oct 11, 2021
@tiroj
Copy link
Contributor Author

tiroj commented Oct 11, 2021

Duplicate issue. Deleted.

@ctrlcctrlv
Copy link

I think this issue was wrongly closed.

Has anyone actually confirmed that this works?

I did a TTX dump of STIXTwoMath-Regular:

ttx ~/.fonts/s/STIXTwoMath-Regular.ttf

Making sure I have the right version:

fred@mapache:/opt/share/sile$ ftdump ~/.fonts/s/STIXTwoMath-Regular.ttf
There is 1 face in this file.

----- Face number: 0 -----

font name entries
   family:              STIX Two Math
   style:               Regular
   postscript:          STIXTwoMath-Regular
   created:             2020-12-16
   modified:            2021-05-17
   revision:            2.13
   glyph count:         6760
      simple:           6041
      composite:        699
      empty:            20

font type entries
   FreeType driver:     truetype
   sfnt wrapped:        yes
   type:                scalable
   direction:           horizontal
   fixed width:         no
   glyph names:         yes
   EM size:             1000
   global BBox:         (-978,-1641):(3072,2627)
   ascender:            762
   descender:           -238
   height:              1250
   max_advance_width:   3072
   max_advance_height:  1250
   underline_position:  -103
   underline_thickness: 51

charmaps (5)
   0: unic, platform 0, encoding  3, format  4, language 0 
   1: unic, platform 0, encoding  4, format 12, language 0 
   2: unic, platform 0, encoding  5, format 14, UVS
   3: unic, platform 3, encoding  1, format  4, language 0 
 * 4: unic, platform 3, encoding 10, format 12, language 0

This just cannot work how you think it does.

rg uvs= /home/fred/.fonts/s/STIXTwoMath-Regular.ttx |bat --language=xml

image

Right?? Am I going nuts or are the mathematical script characters not even in the UVS cmap??

@pkra
Copy link

pkra commented Aug 8, 2022

This was a duplicate of #187 -- but both issues are slated for the 2.20 release so no current release has these.

@ctrlcctrlv
Copy link

why were they both closed as completed then :\

@pkra
Copy link

pkra commented Aug 8, 2022

Very likely because they are fixed in the source files.

@ctrlcctrlv
Copy link

i see but they require a proprietary editor to build and i lost like an hour debugging SILE before deciding to make sure the font actually works as advertised

i'm not complaining, i should have verified sooner, but maybe don't mark issues closed in future if they aren't in a release or at least in master :-)

@firai
Copy link

firai commented Aug 8, 2022

John explained his process and rationale for closing issues that he fixed in the sources in #227.

@tiroj
Copy link
Contributor Author

tiroj commented Aug 8, 2022

Hi Fred. Sorry about that. The STIX development is a little complicated because issues are collected in the public repo but STI Pub like to have delivery of beta fonts privately before releasing them into the wild. I agree that it isn’t ideal to be closing the public issues before the fixes are applied to the public release, and now regret doing that: I was not anticipating the public release being delayed so long.

I’ll go back and reopen issues to ensure appropriate review when the new versions are pushed, and use labels to indicate source fixes delivered to STI Pub.

[I am on sabbatical at the moment, but will be touching base with @davidmjones in September re. some math kerning testing outcomes that remain a concern.]

@tiroj
Copy link
Contributor Author

tiroj commented Aug 16, 2022

Updated sources and fonts delivered to STI Pub for testing. Issue reopened pending public release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants