https://bugs.kde.org/show_bug.cgi?id=483329

            Bug ID: 483329
           Summary: QML: syntax-highlighting does not allow comments
                    during property definitions
    Classification: Frameworks and Libraries
           Product: frameworks-syntax-highlighting
           Version: 5.115.0
          Platform: openSUSE
                OS: Linux
            Status: REPORTED
          Severity: normal
          Priority: NOR
         Component: syntax
          Assignee: kwrite-bugs-n...@kde.org
          Reporter: jackhill3...@gmail.com
                CC: walter.von.entfer...@posteo.net
  Target Milestone: ---

SUMMARY
It is common to document a type like

    property var /*ComplexDataType*/ myData
    property int /*MyEnum*/ enumValue

but the syntax-highlighting engine does not seem to detect the comments here.
This happens when putting a comment anywhere between the word "property" and
either the matching colon or a new line (whichever comes first).

STEPS TO REPRODUCE
1. Open a new qml file in Kate
2. Enter the following code:

    property /*Comment1*/ var myData: xyz
    property var /*Comment2*/ myData: xyz
    property var myData /*Comment3*/: xyz
    property var myData: /*Comment4*/ xyz
    property var myData /*Comment5*/

OBSERVED RESULT
Only Comment4 is displayed as a comment

EXPECTED RESULT
All comments should be displayed as a comment

SOFTWARE/OS VERSIONS
Operating System: openSUSE Tumbleweed 20240306
KDE Plasma Version: 5.27.10
KDE Frameworks Version: 5.115.0
Qt Version: 5.15.12
Kernel Version: 6.7.7-1-default (64-bit)
Graphics Platform: X11

ADDITIONAL INFORMATION

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to