### Godot version

4.1 

### System information

Win 10

### Issue description

![image](https://github.com/godotengine/godot/assets/3350340/fb4d82dc-0301-46d4-85e8-032c32b09fcf)

When causing _"output oveflow"_ by printing a lot of text, formating breaks. Possible because enclosing tag get flushed.

Suggested solution: clear text formating after _output oveflow_ warning.

### Steps to reproduce

Print a lot of text with different text tags (like [color] or [bgcolor]) to console. For example in _process function.

### Minimal reproduction project

N/A
return st_args;
}
Control::TextDirection RichTextLabel::get_text_direction() const {
	return text_direction;
}
void RichTextLabel::set_language(const String &p_language) {
	if (language != p_language) {
		_stop_thread();
		language = p_language;
		main->first_invalid_line.store(0); 
		_validate_line_caches();
		queue_redraw();
	}
}
String RichTextLabel::get_language() const {
	return language;
}
void RichTextLabel::set_autowrap_mode(TextServer::AutowrapMode p_mode) {
	if (autowrap_mode != p_mode) {
		_stop_thread();
		autowrap_mode = p_mode;
		main->first_invalid_line = 0; 
		_validate_line_caches();
		queue_redraw();
	}
}
TextServer::AutowrapMode RichTextLabel::get_autowrap_mode() const {
	return autowrap_mode;
}
void RichTextLabel::set_visible_ratio(float p_ratio) {