### Godot version

4.2.dev1

### System information

Manjaro Linux (DE: Cinnamon v5.8.4) 64 bits

### Issue description

The title already explains it. Take a look at the steps to reproduce below.

### Steps to reproduce

In a GDScript `_ready()` function write this:
```print_rich("[color=red]Red line\n2nd red line[/color]")```

the second line is not red and the output is as follow:
![Capture d’écran du 2023-07-29 05-50-16](https://github.com/godotengine/godot/assets/102065761/554038c6-d128-40c9-8c88-237b44b35b12)

I tested all the the possible BBCodes for the print_rich() method (as stated in the documentation), and of course they all failed.

The RichTextLabel in my projects works as expected.

### Minimal reproduction project

N/A
const Ref<Font> normal_font = get_theme_font(SNAME("output_source"), SNAME("EditorFonts"));
	if (normal_font.is_valid()) {
		log->add_theme_font_override("normal_font", normal_font);
	}
	const Ref<Font> bold_font = get_theme_font(SNAME("output_source_bold"), SNAME("EditorFonts"));
	if (bold_font.is_valid()) {
		log->add_theme_font_override("bold_font", bold_font);
	}
	const Ref<Font> italics_font = get_theme_font(SNAME("output_source_italic"), SNAME("EditorFonts"));
	if (italics_font.is_valid()) {
		log->add_theme_font_override("italics_font", italics_font);
	}
	const Ref<Font> bold_italics_font = get_theme_font(SNAME("output_source_bold_italic"), SNAME("EditorFonts"));
	if (bold_italics_font.is_valid()) {
		log->add_theme_font_override("bold_italics_font", bold_italics_font);
	}
	const Ref<Font> mono_font = get_theme_font(SNAME("output_source_mono"), SNAME("EditorFonts"));
	if (mono_font.is_valid()) {
		log->add_theme_font_override("mono_font", mono_font);