mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-03-13 23:22:54 +00:00
fix last example. Add example of adding code blocks that are not shown in docbook output.
Original commit message from CVS: * docs/manual/elements-api.xml: * docs/manual/helloworld.xml: * examples/manual/extract.pl: fix last example. Add example of adding code blocks that are not shown in docbook output.
This commit is contained in:
parent
c1ab023379
commit
5ebd92789b
6 changed files with 32 additions and 14 deletions
|
@ -1,3 +1,11 @@
|
|||
2004-12-15 Thomas Vander Stichele <thomas at apestaart dot org>
|
||||
|
||||
* docs/manual/elements-api.xml:
|
||||
* docs/manual/helloworld.xml:
|
||||
* examples/manual/extract.pl:
|
||||
fix last example. Add example of adding code blocks that are not
|
||||
shown in docbook output.
|
||||
|
||||
2004-12-15 Thomas Vander Stichele <thomas at apestaart dot org>
|
||||
|
||||
* docs/manual/dynamic.xml:
|
||||
|
|
|
@ -16,8 +16,9 @@
|
|||
</para>
|
||||
|
||||
<programlisting>
|
||||
/* example-begin helloworld.c */
|
||||
#include <gst/gst.h>
|
||||
<!-- example-begin helloworld.c a -->
|
||||
<![CDATA[
|
||||
#include <gst/gst.h>
|
||||
|
||||
int
|
||||
main (int argc, char *argv[])
|
||||
|
@ -64,7 +65,8 @@ main (int argc, char *argv[])
|
|||
|
||||
exit (0);
|
||||
}
|
||||
/* example-end helloworld.c */
|
||||
]]>
|
||||
<!-- example-end helloworld.c a -->
|
||||
</programlisting>
|
||||
|
||||
<para>
|
||||
|
|
|
@ -60,6 +60,12 @@ main (int argc, char *argv[])
|
|||
]]>
|
||||
<!-- example-end elementmake.c b -->
|
||||
</programlisting>
|
||||
<!-- example-begin elementmake.c c -->
|
||||
<!--
|
||||
/* Hi Ronald. Block c is an example of a piece of code that will end up
|
||||
* in the extracted code file, but is not shown in the docbook output */
|
||||
-->
|
||||
<!-- example-end elementmake.c c -->
|
||||
<para>
|
||||
<function>gst_element_factory_make</function> is actually a shorthand
|
||||
for a combination of two functions.
|
||||
|
|
|
@ -16,8 +16,9 @@
|
|||
</para>
|
||||
|
||||
<programlisting>
|
||||
/* example-begin helloworld.c */
|
||||
#include <gst/gst.h>
|
||||
<!-- example-begin helloworld.c a -->
|
||||
<![CDATA[
|
||||
#include <gst/gst.h>
|
||||
|
||||
int
|
||||
main (int argc, char *argv[])
|
||||
|
@ -64,7 +65,8 @@ main (int argc, char *argv[])
|
|||
|
||||
exit (0);
|
||||
}
|
||||
/* example-end helloworld.c */
|
||||
]]>
|
||||
<!-- example-end helloworld.c a -->
|
||||
</programlisting>
|
||||
|
||||
<para>
|
||||
|
|
|
@ -8,9 +8,7 @@
|
|||
|
||||
# decodes xml by translating & < > back to what they should be
|
||||
# and also ignore
|
||||
# <![CDATA[
|
||||
# and
|
||||
# ]]>
|
||||
# <![CDATA[ and ]]> and <!-- and -->
|
||||
sub
|
||||
xml_decode ($)
|
||||
{
|
||||
|
@ -22,6 +20,8 @@ xml_decode ($)
|
|||
|
||||
if ($input =~ /<!\[CDATA\[/) { $input = ""; }
|
||||
if ($input =~ /]]>/) { $input = ""; }
|
||||
if ($input =~ /<!--/) { $input = ""; }
|
||||
if ($input =~ /-->/) { $input = ""; }
|
||||
|
||||
#print "Returning line $input";
|
||||
return $input;
|
||||
|
@ -72,7 +72,7 @@ open OUTPUT, ">$output";
|
|||
@block_ids = keys %blocks;
|
||||
foreach $block_id (sort @block_ids)
|
||||
{
|
||||
print "Writing block with id $block_id\n";
|
||||
print "Writing $output block $block_id\n";
|
||||
print OUTPUT $blocks{$block_id};
|
||||
}
|
||||
close OUTPUT;
|
||||
|
|
|
@ -8,9 +8,7 @@
|
|||
|
||||
# decodes xml by translating & < > back to what they should be
|
||||
# and also ignore
|
||||
# <![CDATA[
|
||||
# and
|
||||
# ]]>
|
||||
# <![CDATA[ and ]]> and <!-- and -->
|
||||
sub
|
||||
xml_decode ($)
|
||||
{
|
||||
|
@ -22,6 +20,8 @@ xml_decode ($)
|
|||
|
||||
if ($input =~ /<!\[CDATA\[/) { $input = ""; }
|
||||
if ($input =~ /]]>/) { $input = ""; }
|
||||
if ($input =~ /<!--/) { $input = ""; }
|
||||
if ($input =~ /-->/) { $input = ""; }
|
||||
|
||||
#print "Returning line $input";
|
||||
return $input;
|
||||
|
@ -72,7 +72,7 @@ open OUTPUT, ">$output";
|
|||
@block_ids = keys %blocks;
|
||||
foreach $block_id (sort @block_ids)
|
||||
{
|
||||
print "Writing block with id $block_id\n";
|
||||
print "Writing $output block $block_id\n";
|
||||
print OUTPUT $blocks{$block_id};
|
||||
}
|
||||
close OUTPUT;
|
||||
|
|
Loading…
Reference in a new issue