Details
-
Technical task
-
Resolution: Fixed
-
P2: Important
-
None
-
None
-
4f0b19cda (dev), 47e76e83b (dev), a8cb8731c (dev), c5100d5b8 (dev), 5b8cb2f96 (dev)
Description
To generate the semantic token data, dom elements are visited and their source location in the file is used to encode semantic token, as described in the protocol.
The way to obtain source code using the Dom API is usually by creating a locationRegion and associate it with DomItem's source location. Then it is registered under FileLocationsTree field of the Qmlfile. A plenty of FileLocationRegions has already been implemented but for semantic highlighting to be completed a few of them still seem missing.
In this subtask, implement file location regions for:
– Import related regions, (import, as, versionNumber, import uris)
– Function declarations (function keyword, identifier, and type annotations)
– Enum keyword and items as well as identifiers
– Pragma keyword and values as well as identifiers
Attachments
For Gerrit Dashboard: QTBUG-123775 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
551335,7 | Add missing file locations in Import | dev | qt/qtdeclarative | Status: MERGED | +2 | 0 |
551336,7 | Add missing file locations in Function Declarations | dev | qt/qtdeclarative | Status: MERGED | +2 | 0 |
551337,7 | Add file locations for Pragma keyword, id and the values | dev | qt/qtdeclarative | Status: MERGED | +2 | 0 |
551338,7 | Add property type identifier locations | dev | qt/qtdeclarative | Status: MERGED | +2 | 0 |
551339,7 | Add file locations for enum keyword and values | dev | qt/qtdeclarative | Status: MERGED | +2 | 0 |