Details
-
Type:
Task
-
Status: In Progress
-
Priority:
P2: Important
-
Resolution: Unresolved
-
Affects Version/s: None
-
Fix Version/s: None
-
Component/s: QML: Tooling
-
Labels:
-
Technical Risk:Normal
Description
We need to write out the Dom back to QML after in memory modifications.
Unfortunately the approach taken by qmlformat is a bit a dead end mainly because:
- it cannot reformat a prt of the document, or a code snippet
- it cannot reindent part of the document keeping in account the choices done by the user in the rest
These two features are needed by the LSP, and a rewriter able to do these can do a global reformatting, whereas the opposite is not true.
Fortunately the Qmljs library in creator has these, but lot of the reindenting is tightly connected to Qt/Creator (QTextBlock,...).
So one should abstract away those parts and bring them to the Dom to avoid having duplicated code later.
Attachments
Issue Links
- is required for
-
QTBUG-89392 Make the Dom Model usable for LSP
-
- Open
-
-
QTBUG-89415 Tooling changes for 6.0
-
- Open
-
-
QTBUG-89391 Make DomModel usable by QML Design Studio
-
- In Progress
-
Gerrit Reviews
For Gerrit Dashboard: QTBUG-89395 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
326813,1 | qmldom: port QmlFormatter from qmljs | dev | qt/qtdeclarative | Status: NEW | 0 | 0 |