Skip to content

Scale text on Cupertino widgets to match iOS text sizes #12158

Open
@gspencergoog

Description

@gspencergoog

For Cupertino widgets, we need to figure out how to scale our text sizes so that when someone asks for a "headline" or other named sizes on iOS, they get the size that they expect.

On Android, there is a single FONT_SCALE (a double) that scales the font based on a system preference, but on iOS, the font size preference doesn't scale linearly with the different font usages. For instance, an Extra Extra Extra Large headline on iOS is 18% larger, whereas a footnote is only 15% larger, and an "Extra Large" headline is 5% larger, while an "Extra Large" caption3 doesn't change size at all.

iOS Font Size Table
(table from this stackoverflow post)

In order to make sure that Cupertino assets get the sizes that match what iOS does, we'll probably need to change the tables in typography.dart so that instead of fixed values for the font sizes, we do something more clever on each platform based on the preferred type size and the usage for the font.

Metadata

Metadata

Assignees

No one assigned

    Labels

    P3Issues that are less important to the Flutter projecta: accessibilityAccessibility, e.g. VoiceOver or TalkBack. (aka a11y)a: fidelityMatching the OEM platforms betterf: cupertinoflutter/packages/flutter/cupertino repositoryframeworkflutter/packages/flutter repository. See also f: labels.platform-iosiOS applications specificallyteam-iosOwned by iOS platform teamtriaged-iosTriaged by iOS platform team

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      pFad - Phonifier reborn

      Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

      Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


      Alternative Proxies:

      Alternative Proxy

      pFad Proxy

      pFad v3 Proxy

      pFad v4 Proxy