Tweak warning/error formatting in EditorLog to be closer to console output

This makes the output easier to understand when it's copied to a plain
text file (without visible colors).
This commit is contained in:
Hugo Locurcio 2024-08-02 17:55:58 +02:00
parent 3978628c6c
commit 29291b3bba
No known key found for this signature in database
GPG Key ID: 39E8F8BE30B0A49C
1 changed files with 6 additions and 2 deletions

View File

@ -362,14 +362,18 @@ void EditorLog::_add_log_line(LogMessage &p_message, bool p_replace_previous) {
log->push_color(theme_cache.error_color);
Ref<Texture2D> icon = theme_cache.error_icon;
log->add_image(icon);
log->add_text(" ");
log->push_bold();
log->add_text(" ERROR: ");
log->pop(); // bold
tool_button->set_icon(icon);
} break;
case MSG_TYPE_WARNING: {
log->push_color(theme_cache.warning_color);
Ref<Texture2D> icon = theme_cache.warning_icon;
log->add_image(icon);
log->add_text(" ");
log->push_bold();
log->add_text(" WARNING: ");
log->pop(); // bold
tool_button->set_icon(icon);
} break;
case MSG_TYPE_EDITOR: {