-
-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
Define standard font specifications and update new beatmap panel designs accordingly #32673
Conversation
337fbfc
to
48575f4
Compare
/// <summary> | ||
/// Equivalent to Torus with 32px size and semi-bold weight. | ||
/// </summary> | ||
public static FontUsage Display => GetFont(size: 32, weight: FontWeight.SemiBold); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What does "Display" mean here? I think we need to choose a better term.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It seems to be a terminology in fonts indicating large text, but it's more commonly used for font variation rather than sizes. Better terminologies could be Headline
or Title
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/// <summary> | ||
/// Equivalent to Torus with 12px size and regular weight. | ||
/// </summary> | ||
public static FontUsage Tiny => GetFont(size: 12, weight: FontWeight.Regular); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Having these next to definitions like "Numeric" doesn't work well for me. Maybe all these should be prefixed with Default
or DefaultFor
or something else.
Alternatively we remove or move the Numeric
and Torus
definitions below. Or move the new definitions somewhere else.
Open to suggestions.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm in favour of removing all the properties below it as I foresee all components in the game using only any of the specifications defined here.
However, removing will be a tough process to go through, so I would at least temporarily prefix those with Legacy
/Old
so it's clear that they shouldn't be used anymore.
For existing usages of these definitions, I foresee them using the new specifications with the typeface swapped with alternate, i.e. OsuFont.Title.With(typeface: FontWeight.TorusAlternate)
or OsuFont.Body.With(typeface: FontWeight.Numeric)
.
@@ -99,12 +99,13 @@ private void load(OverlayColourProvider colourProvider) | |||
{ | |||
Anchor = Anchor.CentreLeft, | |||
Origin = Anchor.CentreLeft, | |||
Scale = new Vector2(OsuFont.Caption.Size / OsuFont.Body.Size), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what on earth???
@@ -122,22 +123,22 @@ private void load(OverlayColourProvider colourProvider) | |||
{ | |||
keyCountText = new OsuSpriteText | |||
{ | |||
Font = OsuFont.GetFont(size: 18, weight: FontWeight.SemiBold), | |||
Font = OsuFont.Body.With(weight: FontWeight.SemiBold), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the weights should be part of the spec, not an afterthought.
Closing this PR as un-reviewable due to chained PRs with unclear dependencies. For changes of this size, it's nigh impossible to review on a per-PR basis. Some PRs in the sequence are very unclear on why they "depend" on the previous PR. There are hundreds of commits but individual commits are not meaningful. #32673 -> #32480 -> #32496 -> #32533 -> #32715 will (attempt) review of #32715 alone |
@frenzibyte if you have concerns over my actions here, i'm open to sit through this with you in voice or text or otherwise. |
This PR features an important change meant to be eventually applied throughout the game. That is,
OsuFont
now contains standard font size definitions that should be used appropriately to keep a form of consistency in the scaling of all game components (whereas currently, some components appear larger than others, such as context menus in online overlays for example). For now, these definitions are only used on the implementation of the new song select screen, but they shall later on be expanded to cover the entire codebase.This PR also features a minor change applied to the beatmap card title, where it's displayed in alternate/styled typeface similar to the wedge title.
Before:
After: