Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-111231

qmlformat does not preserve whitespace in comments and whitespace following header comments

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • P2: Important
    • 6.5
    • 6.5.0 Beta2
    • QML: Tooling
    • None

    Description

      Currently qmlformat doesn't respect REUSE-compliant SPDX header formatting. Ideally, such headers look something like this:

      // SPDX-FileCopyrightText: 2023 Joe Smith
      //
      // SPDX-License-Identifier: GPL-3.0-or-later 
      
      import QtQuick

      (In this case, the import statement shows where the actual code begins.)

      However, qmlformat will format the above to look like this:

      // SPDX-FileCopyrightText: 2023 Joe Smith
      // SPDX-License-Identifier: GPL-3.0-or-later
      import QtQuick

      Ideally, qmlformat would recognize and respect SPDX headers when formatting code.

      Attachments

        Activity

          People

            semih.yavuz Semih Yavuz
            lorendb Loren Burkholder
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated: