mirror of
https://github.com/ppy/osu
synced 2025-01-04 13:22:08 +00:00
Remove width specifications
This commit is contained in:
parent
de8f502871
commit
663f34d3d8
@ -24,6 +24,7 @@ namespace osu.Game.Overlays.Chat.Tabs
|
||||
Icon.Alpha = 0;
|
||||
|
||||
Text.Font = Text.Font.With(size: 45);
|
||||
Text.Truncate = false;
|
||||
}
|
||||
|
||||
[BackgroundDependencyLoader]
|
||||
|
@ -87,12 +87,16 @@ namespace osu.Game.Overlays.Chat.Tabs
|
||||
},
|
||||
Text = new OsuSpriteText
|
||||
{
|
||||
Margin = new MarginPadding(5),
|
||||
Origin = Anchor.CentreLeft,
|
||||
Anchor = Anchor.CentreLeft,
|
||||
Text = value.ToString(),
|
||||
Font = OsuFont.GetFont(size: 18),
|
||||
Width = 115f,
|
||||
Padding = new MarginPadding(5)
|
||||
{
|
||||
Left = LeftTextPadding,
|
||||
Right = RightTextPadding,
|
||||
},
|
||||
RelativeSizeAxes = Axes.X,
|
||||
Truncate = true,
|
||||
},
|
||||
CloseButton = new TabCloseButton
|
||||
@ -111,6 +115,10 @@ namespace osu.Game.Overlays.Chat.Tabs
|
||||
};
|
||||
}
|
||||
|
||||
protected virtual float LeftTextPadding => 5;
|
||||
|
||||
protected virtual float RightTextPadding => IsRemovable ? 40 : 5;
|
||||
|
||||
protected virtual IconUsage DisplayIcon => FontAwesome.Solid.Hashtag;
|
||||
|
||||
protected virtual bool ShowCloseOnHover => true;
|
||||
|
@ -62,12 +62,10 @@ namespace osu.Game.Overlays.Chat.Tabs
|
||||
});
|
||||
|
||||
avatar.OnLoadComplete += d => d.FadeInFromZero(300, Easing.OutQuint);
|
||||
|
||||
Text.X = ChatOverlay.TAB_AREA_HEIGHT;
|
||||
|
||||
Text.Width = 100f;
|
||||
}
|
||||
|
||||
protected override float LeftTextPadding => base.LeftTextPadding + ChatOverlay.TAB_AREA_HEIGHT;
|
||||
|
||||
protected override bool ShowCloseOnHover => false;
|
||||
|
||||
protected override void FadeActive()
|
||||
|
Loading…
Reference in New Issue
Block a user