Use full available width for text in some places.

Fixes #28384.
This commit is contained in:
John Preston 2024-09-10 12:22:50 +04:00
parent c2d5924508
commit ca3c179b75
4 changed files with 4 additions and 0 deletions

View file

@ -931,6 +931,7 @@ void Document::draw(
.pausedSpoiler = context.paused || On(PowerSaving::kChatSpoiler), .pausedSpoiler = context.paused || On(PowerSaving::kChatSpoiler),
.selection = selection, .selection = selection,
.highlight = highlightRequest ? &*highlightRequest : nullptr, .highlight = highlightRequest ? &*highlightRequest : nullptr,
.useFullWidth = true,
}); });
} }
} }

View file

@ -280,6 +280,7 @@ void Game::draw(Painter &p, const PaintContext &context) const {
.selection = toDescriptionSelection(context.selection), .selection = toDescriptionSelection(context.selection),
.elisionHeight = _descriptionLines * lineHeight, .elisionHeight = _descriptionLines * lineHeight,
.elisionRemoveFromEnd = endskip, .elisionRemoveFromEnd = endskip,
.useFullWidth = true,
}); });
tshift += _descriptionLines * lineHeight; tshift += _descriptionLines * lineHeight;
} }

View file

@ -245,6 +245,7 @@ void Invoice::draw(Painter &p, const PaintContext &context) const {
.pausedEmoji = context.paused || On(PowerSaving::kEmojiChat), .pausedEmoji = context.paused || On(PowerSaving::kEmojiChat),
.pausedSpoiler = context.paused || On(PowerSaving::kChatSpoiler), .pausedSpoiler = context.paused || On(PowerSaving::kChatSpoiler),
.selection = toDescriptionSelection(context.selection), .selection = toDescriptionSelection(context.selection),
.useFullWidth = true,
}); });
tshift += _descriptionHeight; tshift += _descriptionHeight;
} }

View file

@ -1085,6 +1085,7 @@ void WebPage::draw(Painter &p, const PaintContext &context) const {
? (_descriptionLines * lineHeight) ? (_descriptionLines * lineHeight)
: 0), : 0),
.elisionRemoveFromEnd = (_descriptionLines > 0) ? endskip : 0, .elisionRemoveFromEnd = (_descriptionLines > 0) ? endskip : 0,
.useFullWidth = true,
}); });
tshift += (_descriptionLines > 0) tshift += (_descriptionLines > 0)
? (_descriptionLines * lineHeight) ? (_descriptionLines * lineHeight)