flutter/dev/integration_tests/flutter_gallery/lib/demo
Mitchell Goodwin e84f1296ac
Refactor to use Apple system fonts (#137275)
Addresses #63507, and is a follow up to the engine PR https://github.com/flutter/engine/pull/46857

Changes the font family string when attempting to use Apple system fonts to the new proxies added by the engine. For the "Text" font this will be more secure in the future against possible changes to Apple's API. For the "Display" font, this will now work correctly when it didn't before.

I checked the letter spacing values against a native app for all font sizes between 17-28. I made a few adjustments to better match native, but especially for the "Text" font we were either really close, or close enough to not make a large breaking change to default fonts worth it.

| Before  | After |
| ------------- | ------------- |
| <img width="466" alt="Screenshot 2023-11-02 at 11 45 12 AM" src="https://github.com/flutter/flutter/assets/58190796/627ed8ac-d848-4f71-aa62-a467b8aac62d"> | <img width="383" alt="Screenshot 2023-11-02 at 11 46 25 AM" src="https://github.com/flutter/flutter/assets/58190796/9a502021-7d2b-4e14-98f1-86971b3830a5"> |

The smaller text in both the before and after should be the same. The large system font that Flutter used before was incorrect, which caused it to look more spread out. Now we use the correct font.
2023-11-29 21:03:32 +00:00
..
animation Reland "Remove single-view assumption from ScrollPhysics (#117503)" (#117916) 2023-01-03 21:34:08 +00:00
calculator Implement switch expressions in dev/ (#139048) 2023-11-28 23:40:28 +00:00
cupertino Refactor to use Apple system fonts (#137275) 2023-11-29 21:03:32 +00:00
fortnightly Enable use_colored_box lint (#117370) 2022-12-20 14:09:55 -08:00
material Implement switch expressions in dev/ (#139048) 2023-11-28 23:40:28 +00:00
shrine Implement switch expressions in dev/ (#139048) 2023-11-28 23:40:28 +00:00
transformations implement Iterator and Comparable instead of extending them (#123282) 2023-03-23 17:10:31 +00:00
all.dart
animation_demo.dart Prepare flutter_gallery for use_super_parameters (#100515) 2022-03-28 16:04:22 -07:00
calculator_demo.dart Prepare flutter_gallery for use_super_parameters (#100515) 2022-03-28 16:04:22 -07:00
colors_demo.dart Deprecate 2018 text theme parameters (#109817) 2022-08-22 20:00:34 +00:00
contacts_demo.dart Dev, examples/api, etc updated for Material 3 by default (#129683) 2023-06-28 09:41:58 -07:00
images_demo.dart Prepare flutter_gallery for use_super_parameters (#100515) 2022-03-28 16:04:22 -07:00
pesto_demo.dart Update Gallery demo app themes for Material3 compatibility (#131093) 2023-07-24 15:06:07 +00:00
shrine_demo.dart Prepare flutter_gallery for use_super_parameters (#100515) 2022-03-28 16:04:22 -07:00
typography_demo.dart Deprecate 2018 text theme parameters (#109817) 2022-08-22 20:00:34 +00:00
video_demo.dart Roll dependencies (#139203) 2023-11-29 20:12:59 +00:00