Details
-
Bug
-
Resolution: Done
-
P1: Critical
-
None
-
Qt Creator 4.6.2
-
None
Description
Steps to reproduce:
- Create a new QtQuick UI File
- Drag in one Text element from the Qt Quick Basic collection
- Write something including a single, non-escaped quote, e.g: holler"
Console output:
*** Possible problem: QML file wasn't parsed correctly. *** QML text: "import QtQuick 2.4\n\nItem {\n width: 400\n height: 400\n\n Text {\n id: text1\n x: 161\n y: 141\n text: qsTr(\"holler\"\")\n font.pixelSize: 12\n }\n}\n" *** "Expected token \")\"." RewriterException: Error rewriting document Content: import QtQuick 2.4 Item { width: 400 height: 400 Text { id: text1 x: 161 y: 141 text: qsTr("holler"") font.pixelSize: 12 } } Exception: "RewritingException" Function: "applyChanges" File: "/work/build/qt-creator/src/plugins/qmldesigner/designercore/model/rewriterview.cpp" Line: 427
As you can see, the quote is not escaped correctly, which leads to a crash.
Attachments
For Gerrit Dashboard: QTCREATORBUG-20684 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
233800,2 | QmlDesigner: Fix crash | 4.7 | qt-creator/qt-creator | Status: MERGED | +2 | 0 |