Skip to content

Commit

Permalink
lang-check: add missing rulers
Browse files Browse the repository at this point in the history
  • Loading branch information
wavexx committed Apr 29, 2021
1 parent 8edecc9 commit a98bc16
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions lang/lang-check.py
Original file line number Diff line number Diff line change
Expand Up @@ -159,12 +159,15 @@ def parse_txt(lang, no_warning):

# Check for potential errors in the definition
if not no_warning:
# Incorrect number of rows/cols on the definition
if rows == 1 and (len(source) > cols or rows_count_source > rows):
print(yellow('[W]: Source text longer than %d cols as defined on line %d:' % (cols, lines)))
print_ruler(4, cols);
print_truncated(source, cols)
print()
elif rows_count_source > rows:
print(yellow('[W]: Wrapped source text longer than %d rows as defined on line %d:' % (rows, lines)))
print_ruler(6, cols);
print_wrapped(wrapped_source, rows, cols)
print()

Expand Down

0 comments on commit a98bc16

Please sign in to comment.