Skip to content

Incorrect baseline and size for U+2032 (prime) #42

Closed

Description

@Enivex

Font

NotoSansMath-Regular.otf

Where the font came from, and when

Site: https://github.com/notofonts/math/suites/11937022112/artifacts/625592892
Date: 2023-04-10

Font Version

2.539

OS name and version

Windows 11 22621.1546

Issue

Use font with LuaLaTeX and unicode-math. The symbol will be placed too high, and is too small.

Noto Sans Math:
Screenshot 2023-04-10 145844
Screenshot 2023-04-10 145903

Stix Two Math has proper positioning:
Screenshot 2023-04-10 150256
Screenshot 2023-04-10 150243

Activity

  1. simoncozens commented on May 3, 2023

    @simoncozens
    Contributor

    I suspect this is some MATH table weirdness. When used outside of a math typesetting environment, then both Noto and Stix look reasonable and similarly proportioned:

    shapeshape

    It's probably something to do with the ScriptPercentScaleDown constant or something similar, but I don't have enough math typesetting understanding to know which value is causing this, and certainly not to fiddle with it.

  2. simoncozens commented on May 3, 2023

    @simoncozens
    Contributor

    @khaledhosny or @tiroj, any quick thoughts?

  3. khaledhosny commented on May 3, 2023

    @khaledhosny
    Collaborator

    This is handled by the ssty feature

  4. tiroj commented on May 3, 2023

    @tiroj

    The ssty feature substitutes the form of the glyph to be scaled down, if available. Not all characters get ssty variants, so one thing to check is whether this symbol does in the Noto Math font. If not, it may end up too small when scaled for subscript positioning.

    As I recall, there are a couple of data points in the MATH table that determine the default scaling for superscripts and for their height position.

  5. khaledhosny commented on May 3, 2023

    @khaledhosny
    Collaborator

    To elaborate, in Unicode primes are scaled down and positioned at superscript position, in Computer Modern they were drawn full size and on the baseline and TeX input handles prime as a superscript character so it gets scaled down and positioned the same like any other superscript. The trick in OpenType MATH fonts is to design the default glyph as it is now, and add ssty variant(s) that are full size on the baseline so that when used as superscript it does not get double scaled down.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions