fix crlf for clipboard
This commit is contained in:
parent
173ebe4872
commit
0107550cf1
1 changed files with 1 additions and 1 deletions
|
@ -170,7 +170,7 @@ void DisplayServerWindows::clipboard_set(const String &p_text) {
|
|||
|
||||
// Convert LF line endings to CRLF in clipboard content
|
||||
// Otherwise, line endings won't be visible when pasted in other software
|
||||
String text = p_text.replace("\n", "\r\n");
|
||||
String text = p_text.replace("\r\n", "\n").replace("\n", "\r\n"); // avoid \r\r\n
|
||||
|
||||
if (!OpenClipboard(windows[last_focused_window].hWnd)) {
|
||||
ERR_FAIL_MSG("Unable to open clipboard.");
|
||||
|
|
Loading…
Reference in a new issue