mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 03:17:35 +00:00
Everywhere: Add sv suffix to strings relying on StringView(char const*)
Each of these strings would previously rely on StringView's char const* constructor overload, which would call __builtin_strlen on the string. Since we now have operator ""sv, we can replace these with much simpler versions. This opens the door to being able to remove StringView(char const*). No functional changes.
This commit is contained in:
parent
e5f09ea170
commit
3f3f45580a
762 changed files with 8315 additions and 8316 deletions
|
@ -83,7 +83,7 @@ void ElementSizePreviewWidget::paint_event(GUI::PaintEvent& event)
|
|||
draw_borders(margin_rect, Color::Black);
|
||||
margin_rect.shrink(1, 1, 1, 1);
|
||||
margin_rect.shrink(text_height_padding, text_width_padding, text_height_padding, text_width_padding);
|
||||
painter.draw_text(margin_rect, "margin", font(), Gfx::TextAlignment::TopLeft, Color::Black);
|
||||
painter.draw_text(margin_rect, "margin"sv, font(), Gfx::TextAlignment::TopLeft, Color::Black);
|
||||
draw_size_texts(margin_rect, Color::Black, m_node_box_sizing.margin);
|
||||
|
||||
// paint border box
|
||||
|
@ -91,7 +91,7 @@ void ElementSizePreviewWidget::paint_event(GUI::PaintEvent& event)
|
|||
draw_borders(border_rect, Color::Black);
|
||||
border_rect.shrink(1, 1, 1, 1);
|
||||
border_rect.shrink(text_height_padding, text_width_padding, text_height_padding, text_width_padding);
|
||||
painter.draw_text(border_rect, "border", font(), Gfx::TextAlignment::TopLeft, Color::Black);
|
||||
painter.draw_text(border_rect, "border"sv, font(), Gfx::TextAlignment::TopLeft, Color::Black);
|
||||
draw_size_texts(border_rect, Color::Black, m_node_box_sizing.border);
|
||||
|
||||
// paint padding box
|
||||
|
@ -99,7 +99,7 @@ void ElementSizePreviewWidget::paint_event(GUI::PaintEvent& event)
|
|||
draw_borders(padding_rect, Color::Black);
|
||||
padding_rect.shrink(1, 1, 1, 1);
|
||||
padding_rect.shrink(text_height_padding, text_width_padding, text_height_padding, text_width_padding);
|
||||
painter.draw_text(padding_rect, "padding", font(), Gfx::TextAlignment::TopLeft, Color::Black);
|
||||
painter.draw_text(padding_rect, "padding"sv, font(), Gfx::TextAlignment::TopLeft, Color::Black);
|
||||
draw_size_texts(padding_rect, Color::Black, m_node_box_sizing.padding);
|
||||
|
||||
// paint content box
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue