mirror of
https://github.com/siemens-mobile-hacks/doxygen.git
synced 2026-11-25 22:27:34 +00:00
The <sp> element in <programlisting> has a new optional attribute `value`, which contains value of given invalid ASCII character. In case of space, the `value` attribute is omitted. Use cases for this: including snippets of *very esoteric* languages, markup that makes use of the advanced ASCII formatting characters or for example highlighting a console output containing ANSI color codes (which is my case, in fact). Regarding backwards compatibility -- as files with such ASCII characters are very rare, I don't expect this minor difference in the output to be a problem. Besides that, such ASCII characters are often replaced by a space in many applications anyway. A test snippet was extended to contain a special character so this difference in behavior could be verified.
10 lines
1.6 KiB
XML
10 lines
1.6 KiB
XML
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
|
<doxygen xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="compound.xsd" version="">
|
|
<compounddef id="example_test_8cpp-example" kind="example">
|
|
<compoundname>example_test.cpp</compoundname>
|
|
<detaileddescription>
|
|
<para>This is an example of how to use the <ref refid="class_test" kindref="compound">Test</ref> class.</para>
|
|
<para>More details about this example. <programlisting filename="example_test.cpp"><codeline><highlight class="keywordtype">void</highlight><highlight class="normal"><sp/>main()</highlight></codeline><codeline><highlight class="normal">{</highlight></codeline><codeline><highlight class="normal"><sp/><sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal">*<sp/>a<sp/>=<sp/></highlight><highlight class="stringliteral">"Some<sp/>special<sp/>character<sp/>here:<sp/><sp value="7"/><sp/>"</highlight><highlight class="normal">;</highlight></codeline><codeline><highlight class="normal"/></codeline><codeline><highlight class="normal"><sp/><sp/><ref refid="class_test" kindref="compound">Test</ref><sp/>t;</highlight></codeline><codeline><highlight class="normal"><sp/><sp/>t.<ref refid="class_test_1a47b775f65718978f1ffcd96376f8ecfa" kindref="member">example</ref>();</highlight></codeline><codeline><highlight class="normal">}</highlight></codeline><codeline><highlight class="normal"/></codeline></programlisting> </para>
|
|
</detaileddescription>
|
|
</compounddef>
|
|
</doxygen>
|