### Godot version

4.0 stable

### System information

Manjaro Linux, kernel 6.1.1-1-MANJARO, AMD Ryzen 5 3600, AMD RX 580

### Issue description

The `wrap_mode` property of the `TextEdit` node doesn't seem to really do anything. Setting it to `LINE_WRAPPING_BOUNDARY` simply means that there won't be an horizontal scrollbar if the text overshoots the boundary, instead of actually forcing the text to the next line so that it stays visible.

### Steps to reproduce

Create a TextEdit node and set its `wrap_mode` property to `LINE_WRAPPING_BOUNDARY`

### Minimal reproduction project

[WrapBugDemo.zip](https://github.com/godotengine/godot/files/10875969/WrapBugDemo.zip)

ERR_FAIL_INDEX_V(p_line, text.size(), false);
	return text.is_hidden(p_line);
}
void TextEdit::_unhide_all_lines() {
	for (int i = 0; i < text.size(); i++) {
		text.set_hidden(i, false);
	}
	_update_scrollbars();
	queue_redraw();
}
void TextEdit::_set_line_as_hidden(int p_line, bool p_hidden) {
	ERR_FAIL_INDEX(p_line, text.size());
	if (text.is_hidden(p_line) == p_hidden) {
		return;
	}
	if (_is_hiding_enabled() || !p_hidden) {
		text.set_hidden(p_line, p_hidden);
	}
	queue_redraw();
}
void TextEdit::_set_symbol_lookup_word(const String &p_symbol) {
	if (lookup_symbol_word == p_symbol) {
		return;
	}
	lookup_symbol_word = p_symbol;
	queue_redraw();
}
void TextEdit::_handle_unicode_input_internal(const uint32_t p_unicode, int p_caret) {