mirror of
https://github.com/ppy/osu
synced 2024-12-11 01:19:26 +00:00
Merge pull request #28075 from peppy/fix-chat-ui-scale
Fix chat overlay being far too large
This commit is contained in:
commit
3840e92576
@ -49,7 +49,7 @@ namespace osu.Game.Overlays.Chat.ChannelList
|
||||
[BackgroundDependencyLoader]
|
||||
private void load()
|
||||
{
|
||||
Height = 30;
|
||||
Height = 25;
|
||||
RelativeSizeAxes = Axes.X;
|
||||
|
||||
Children = new Drawable[]
|
||||
@ -87,7 +87,7 @@ namespace osu.Game.Overlays.Chat.ChannelList
|
||||
Anchor = Anchor.CentreLeft,
|
||||
Origin = Anchor.CentreLeft,
|
||||
Text = Channel.Name,
|
||||
Font = OsuFont.Torus.With(size: 17, weight: FontWeight.SemiBold),
|
||||
Font = OsuFont.Torus.With(size: 14, weight: FontWeight.SemiBold),
|
||||
Colour = colourProvider.Light3,
|
||||
Margin = new MarginPadding { Bottom = 2 },
|
||||
RelativeSizeAxes = Axes.X,
|
||||
|
@ -47,7 +47,7 @@ namespace osu.Game.Overlays.Chat
|
||||
|
||||
public IReadOnlyCollection<Drawable> DrawableContentFlow => drawableContentFlow;
|
||||
|
||||
protected virtual float FontSize => 20;
|
||||
protected virtual float FontSize => 14;
|
||||
|
||||
protected virtual float Spacing => 15;
|
||||
|
||||
|
@ -19,6 +19,8 @@ namespace osu.Game.Overlays.Chat
|
||||
{
|
||||
public partial class ChatTextBar : Container
|
||||
{
|
||||
public const float HEIGHT = 40;
|
||||
|
||||
public readonly BindableBool ShowSearch = new BindableBool();
|
||||
|
||||
public event Action<string>? OnChatMessageCommitted;
|
||||
@ -45,7 +47,7 @@ namespace osu.Game.Overlays.Chat
|
||||
private void load(OverlayColourProvider colourProvider)
|
||||
{
|
||||
RelativeSizeAxes = Axes.X;
|
||||
Height = 60;
|
||||
Height = HEIGHT;
|
||||
|
||||
Children = new Drawable[]
|
||||
{
|
||||
@ -76,7 +78,7 @@ namespace osu.Game.Overlays.Chat
|
||||
Child = chattingText = new TruncatingSpriteText
|
||||
{
|
||||
MaxWidth = chatting_text_width - padding * 2,
|
||||
Font = OsuFont.Torus.With(size: 20),
|
||||
Font = OsuFont.Torus,
|
||||
Colour = colourProvider.Background1,
|
||||
Anchor = Anchor.CentreRight,
|
||||
Origin = Anchor.CentreRight,
|
||||
@ -91,7 +93,7 @@ namespace osu.Game.Overlays.Chat
|
||||
Icon = FontAwesome.Solid.Search,
|
||||
Origin = Anchor.CentreRight,
|
||||
Anchor = Anchor.CentreRight,
|
||||
Size = new Vector2(20),
|
||||
Size = new Vector2(OsuFont.DEFAULT_FONT_SIZE),
|
||||
Margin = new MarginPadding { Right = 2 },
|
||||
},
|
||||
},
|
||||
@ -101,6 +103,7 @@ namespace osu.Game.Overlays.Chat
|
||||
Padding = new MarginPadding { Right = padding },
|
||||
Child = chatTextBox = new ChatTextBox
|
||||
{
|
||||
FontSize = OsuFont.DEFAULT_FONT_SIZE,
|
||||
Anchor = Anchor.CentreLeft,
|
||||
Origin = Anchor.CentreLeft,
|
||||
RelativeSizeAxes = Axes.X,
|
||||
|
@ -44,7 +44,7 @@ namespace osu.Game.Overlays.Chat.Listing
|
||||
[Resolved]
|
||||
private OverlayColourProvider colourProvider { get; set; } = null!;
|
||||
|
||||
private const float text_size = 18;
|
||||
private const float text_size = 14;
|
||||
private const float icon_size = 14;
|
||||
|
||||
private const float vertical_margin = 1.5f;
|
||||
|
@ -55,7 +55,6 @@ namespace osu.Game.Overlays
|
||||
private const int transition_length = 500;
|
||||
private const float top_bar_height = 40;
|
||||
private const float side_bar_width = 190;
|
||||
private const float chat_bar_height = 60;
|
||||
|
||||
protected override string PopInSampleName => @"UI/overlay-big-pop-in";
|
||||
protected override string PopOutSampleName => @"UI/overlay-big-pop-out";
|
||||
@ -136,7 +135,7 @@ namespace osu.Game.Overlays
|
||||
Padding = new MarginPadding
|
||||
{
|
||||
Left = side_bar_width,
|
||||
Bottom = chat_bar_height,
|
||||
Bottom = ChatTextBar.HEIGHT,
|
||||
},
|
||||
Children = new Drawable[]
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user