Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Comments in Qt qrc file

Tags:

resources

qt

How to add comments to Qt qrc file? I tried // and /* */, but this gives me an error "RCC Parse error ... [unexpected text]". Sample file:

<RCC>
<qresource>
    // images
    <file>image1.png</file>
    <file>image2.png</file>

    // qml documents
    <file>doc1.qml</file>
    <file>doc2.qml</file>
</qresource>
</RCC>
like image 333
lightstep Avatar asked Jun 29 '15 11:06

lightstep


2 Answers

A format of .qrc files is based on XML. Therefore you can use XML-style for comments:

    Comment    ::=      '<!--' ((Char - '-') | ('-' (Char - '-')))* '-->'

An example of a comment:

<!-- declarations for <head> & <body> -->

XML spec

like image 149
Pavel Matrenin Avatar answered Oct 12 '22 04:10

Pavel Matrenin


You can use <!-- --> e.g.

<!-- this is my comment in qrc file -->
like image 4
Amol Saindane Avatar answered Oct 12 '22 03:10

Amol Saindane