Normalize line endings and whitespace

This commit is contained in:
OpenCV Buildbot
2012-10-17 03:18:30 +04:00
committed by Andrey Kamaev
parent 69020da607
commit 04384a71e4
1516 changed files with 258846 additions and 258162 deletions

34
modules/java/generator/rst_parser.py Normal file → Executable file
View File

@@ -202,8 +202,8 @@ class RstParser(object):
# skip lines if line-skipping mode is activated
if skip_code_lines:
if not l:
continue
if not l:
continue
if l.startswith(" "):
None
else:
@@ -211,12 +211,12 @@ class RstParser(object):
if ll.startswith(".. code-block::") or ll.startswith(".. image::"):
skip_code_lines = True
continue
# todo: parse structure members; skip them for now
if ll.startswith(".. ocv:member::"):
#print ll
#print ll
skip_code_lines = True
continue
@@ -293,19 +293,19 @@ class RstParser(object):
# record other lines as long description
if (skip_code_lines):
ll = ll.replace("/*", "/ *")
ll = ll.replace("*/", "* /")
if (was_code_line):
func["long"] = func.get("long", "") + "\n" + ll + "\n"
else:
was_code_line = True;
func["long"] = func.get("long", "") + ll +"\n<code>\n\n // C++ code:\n\n"
else:
if (was_code_line):
func["long"] = func.get("long", "") + "\n" + ll + "\n</code>\n";
was_code_line = False;
else:
func["long"] = func.get("long", "") + "\n" + ll
ll = ll.replace("/*", "/ *")
ll = ll.replace("*/", "* /")
if (was_code_line):
func["long"] = func.get("long", "") + "\n" + ll + "\n"
else:
was_code_line = True;
func["long"] = func.get("long", "") + ll +"\n<code>\n\n // C++ code:\n\n"
else:
if (was_code_line):
func["long"] = func.get("long", "") + "\n" + ll + "\n</code>\n";
was_code_line = False;
else:
func["long"] = func.get("long", "") + "\n" + ll
# endfor l in lines
if fdecl.balance != 0: