Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow db:modifier after db:methodname and the parameters in db:constructorsynopsis #232

Closed
wants to merge 1 commit into from

Conversation

dourouc05
Copy link
Contributor

@dourouc05 dourouc05 commented May 26, 2022

This allows the description to match more language syntaxes, like C++. My use case is the following:

<db:constructorsynopsis>
<db:methodname>QXmlStreamWriter</db:methodname>
<db:methodparam>
<db:type>QString *</db:type>
<db:parameter>string</db:parameter>
</db:methodparam>
<db:modifier>overload</db:modifier>
<db:synopsisinfo role="meta">constructor</db:synopsisinfo>
<db:synopsisinfo role="overload-number">3</db:synopsisinfo>
<db:synopsisinfo role="signature">QXmlStreamWriter(QString *string)</db:synopsisinfo>
<db:synopsisinfo role="access">public</db:synopsisinfo>
<db:synopsisinfo role="status">active</db:synopsisinfo>
<db:synopsisinfo role="threadsafeness">unspecified</db:synopsisinfo>
</db:constructorsynopsis>

This is a description of https://doc.qt.io/qt-6/qxmlstreamwriter.html#QXmlStreamWriter-3

dourouc05 added a commit to dourouc05/QtDocTools that referenced this pull request May 29, 2022
@ndw
Copy link
Contributor

ndw commented Jun 1, 2022

More generally, it looks like db:modifier should be allowed after classname in ooclass, interfacename in oointerface, exceptionname in ooexception, varname in fieldsynopsis, methodname in constructorsynopsis (as you suggest), methodname in destructorsynopsis, and enumname in enumsynopsis.

I see that it's already allowed after parameter in methodparam, templatename in template, package in packagesynopsis, macroname in macrosynopsis, macrodef in macroprototype, unionname in unionsynopsis,
and typedefname in typedefsynopsis.

qtprojectorg pushed a commit to qt/qttools that referenced this pull request Jun 2, 2022
This matches C++ syntax. This is not yet allowed in DocBook 5.2 (the previous situation is not either), but the change is suggested: docbook/docbook#232

Also, don't output a type for constructors or destructors.

Change-Id: I38805fbc9146473a2e94fa94155298bd029a9f52
Reviewed-by: Luca Di Sera <luca.disera@qt.io>
@ndw ndw mentioned this pull request Jul 2, 2022
@ndw
Copy link
Contributor

ndw commented Jul 2, 2022

Subsumed by #235.

@ndw ndw closed this Jul 2, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants