Commit a4d6bc84 authored by Roland Levillain's avatar Roland Levillain
Browse files

Prepare doc source files for the automation of output splitting.

	* doc/examples/tuto3/println.cc,
	* doc/examples/tuto4/site_set_create.cc:
	Use doc::begin_output and doc::end_output instead of hand-made
	delimiters.
parent 8293184f
2010-03-18 Roland Levillain <roland@lrde.epita.fr>
Prepare doc source files for the automation of output splitting.
* doc/examples/tuto3/println.cc,
* doc/examples/tuto4/site_set_create.cc:
Use doc::begin_output and doc::end_output instead of hand-made
delimiters.
2010-03-17 Roland Levillain <roland@lrde.epita.fr>
 
Have split_sample.sh announce the right number of output files.
......@@ -5,29 +5,31 @@
#include <mln/debug/println.hh>
#include <mln/debug/println_with_border.hh>
#include <doc/tools/sample_utils.hh>
int main()
{
using namespace mln;
using namespace mln::value;
{
std::cout << "// \\{" << std::endl;
doc::begin_output();
// \{
image2d<int_u8> ima(5,5);
data::fill(ima, 2);
debug::println(ima);
// \}
std::cout << "// \\}" << std::endl;
doc::end_output();
}
{
std::cout << "// \\{" << std::endl;
doc::begin_output();
// \{
image2d<int_u8> ima(5,5);
data::fill(ima, 2);
border::fill(ima, 7);
debug::println_with_border(ima);
// \}
std::cout << "// \\}" << std::endl;
doc::end_output();
}
}
......@@ -2,6 +2,8 @@
#include <mln/core/site_set/p_array.hh>
#include <mln/make/box2d.hh>
#include <doc/tools/sample_utils.hh>
int main()
{
using namespace mln;
......@@ -10,14 +12,14 @@ int main()
box2d b(4,4);
// \}
std::cout << "// \\{" << std::endl;
doc::begin_output();
// \{
mln_piter_(box2d) p(b);
for_all(p)
std::cout << p << ", ";
std::cout << std::endl;
// \}
std::cout << "// \\}" << std::endl;
doc::end_output();
{
......@@ -27,14 +29,14 @@ int main()
arr.append(point2d(1,2));
// \}
std::cout << "// \\{" << std::endl;
doc::begin_output();
// \{
mln_piter_(p_array<point2d>) p(arr);
for_all(p)
std::cout << p << ", ";
std::cout << std::endl;
// \}
std::cout << "// \\}" << std::endl;
doc::end_output();
}
{
......@@ -42,11 +44,11 @@ int main()
box2d b = make::box2d(-2,-2, 2, 2);
// \}
std::cout << "// \\{" << std::endl;
doc::begin_output();
mln_piter_(box2d) p(b);
for_all(p)
std::cout << p << ", ";
std::cout << std::endl;
std::cout << "// \\}" << std::endl;
doc::end_output();
}
}
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment