plint

French poetry validator (local mirror of https://gitlab.com/a3nm/plint)
git clone https://a3nm.net/git/plint/
Log | Files | Refs | README

commit 80bb667f98d979be2994ad24cb2c7a4d180e4020
parent 851516e4d8356ff002fa8ca4f4859aa5ee99c6a2
Author: Antoine Amarilli <a3nm@a3nm.net>
Date:   Sun, 10 Jul 2011 21:53:42 -0400

remove old code

Diffstat:
poetlint.py | 28----------------------------
1 file changed, 0 insertions(+), 28 deletions(-)

diff --git a/poetlint.py b/poetlint.py @@ -63,34 +63,6 @@ def nullify(chunk): else: return chunk -def align2(result): - align, feminine, c, hemi = result - l2 = [('{:^2}').format(str(c))] - l2 += ['f'] if feminine else ["m"] - l2 += '-H' - l2 += [('{:^3}').format(hemi)] - l2 += ' ' - count = 0 - for x in align: - if isinstance(x, tuple): - l2 += ('{:^'+str(len(x[0]))+'}').format(str(x[1])) - count += x[1] - else: - if x == ' ' and count == hemistiche_pos: - l2 += '/' - else: - l2 += ' ' * len(x) - return ''.join(l2) - -def align1(result, success): - l1 = '-------- ' if success else '!!!ERROR ' - for x in result[0]: - if isinstance(x, tuple): - l1 += x[0] - else: - l1 += x - return ''.join(l1) - def parse(text, bound): original_text = normalize(text) text = re.sub("qu", 'q', original_text)