Skip to content

Commit 6dbc570

Browse files
committed
1 parent 203c12e commit 6dbc570

File tree

2 files changed

+5
-4
lines changed

2 files changed

+5
-4
lines changed

src/modules/console/consolemodel.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ void Model::execCmd(QList<QByteArray> cmd)
7777
}
7878

7979
QVariant value = result.value();
80-
emit addOutput(RedisClient::Response::valueToHumanReadString(value),
80+
emit addOutput(RedisClient::Response::valueToHumanReadString(value).replace("\r\n", "\n"),
8181
"part");
8282
});
8383

@@ -98,7 +98,7 @@ void Model::execCmd(QList<QByteArray> cmd)
9898
}
9999

100100
QVariant value = result.value();
101-
emit addOutput(RedisClient::Response::valueToHumanReadString(value),
101+
emit addOutput(RedisClient::Response::valueToHumanReadString(value).replace("\r\n", "\n"),
102102
"complete");
103103
});
104104

src/qml/console/RedisConsole.qml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,9 +46,10 @@ Rectangle {
4646
+ appSettings.valueEditorFont + "'>"
4747
+ qmlUtils.escapeHtmlEntities(text) + '</span>')
4848
} else {
49-
textArea.append("<pre style='color: white; font-family: "
49+
console.log(qmlUtils.escapeHtmlEntities(text))
50+
textArea.append("<code style='color: white;white-space: pre-wrap;font-family: "
5051
+ appSettings.valueEditorFont + "'>"
51-
+ qmlUtils.escapeHtmlEntities(text) + '</pre>')
52+
+ qmlUtils.escapeHtmlEntities(text) + '</code>')
5253
}
5354

5455
if (type == "complete" || type == "error") {

0 commit comments

Comments
 (0)