add all stages back in, modify word search
This commit is contained in:
parent
eda408308e
commit
bcacc3f4e4
@ -87,8 +87,8 @@ class ThermalPrinter():
|
||||
todo_text = textwrap.wrap(x[1], todo_text_max_len)
|
||||
# t_text = textwrap.wrap()
|
||||
fele = todo_text.pop(0)
|
||||
print(todo_text_max_len-len(fele))
|
||||
print(fele)
|
||||
# print(todo_text_max_len-len(fele))
|
||||
# print(fele)
|
||||
self.p.text(" " + " "*(todo_text_max_len-len(fele)) + fele + "\n")
|
||||
|
||||
todo_text = textwrap.wrap(' '.join(todo_text), 32)
|
||||
@ -154,8 +154,8 @@ class ThermalPrinter():
|
||||
def print_wordsearch(self):
|
||||
# words = ("gugu,gaga")
|
||||
r = RandomWord()
|
||||
words = r.random_words(15, include_parts_of_speech=["nouns", "verbs", "adjectives"])
|
||||
w = WordSearch(','.join(words), 32, 16)
|
||||
words = r.random_words(15, include_parts_of_speech=["nouns", "verbs", "adjectives"], word_max_length=16)
|
||||
w = WordSearch(','.join(words), 16, 16)
|
||||
|
||||
self.p.set(align="left")
|
||||
self.p.text("Word Search:")
|
||||
@ -187,25 +187,25 @@ class ThermalPrinter():
|
||||
# print(w.wordPosition)
|
||||
|
||||
def print_default(self):
|
||||
print('start 1')
|
||||
# print('start 1')
|
||||
self.print_greeting()
|
||||
print('end 1')
|
||||
# print('end 1')
|
||||
|
||||
print('start 2')
|
||||
# print('start 2')
|
||||
self.print_todos()
|
||||
print('end 2')
|
||||
# print('end 2')
|
||||
|
||||
print('start 3')
|
||||
# self.print_sudoku()
|
||||
print('end 3')
|
||||
# print('start 3')
|
||||
self.print_sudoku()
|
||||
# print('end 3')
|
||||
|
||||
print('start 4')
|
||||
# self.print_wordsearch()
|
||||
print('end 4')
|
||||
# print('start 4')
|
||||
self.print_wordsearch()
|
||||
# print('end 4')
|
||||
|
||||
print('start 5')
|
||||
# self.print_random_quote()
|
||||
print('end 5')
|
||||
# print('start 5')
|
||||
self.print_random_quote()
|
||||
# print('end 5')
|
||||
self.finished_printing()
|
||||
|
||||
def _parse_todos(self, data):
|
||||
|
@ -216,9 +216,9 @@ if __name__ == '__main__':
|
||||
from wonderwords import RandomWord
|
||||
|
||||
r = RandomWord()
|
||||
words = r.random_words(15, include_parts_of_speech=["nouns", "verbs", "adjectives"])
|
||||
w = WordSearch(','.join(words), 32, 16)
|
||||
words = r.random_words(5, include_parts_of_speech=["nouns", "verbs", "adjectives"], word_max_length=16)
|
||||
print(words)
|
||||
w = WordSearch(','.join(words), 16, 16)
|
||||
|
||||
def printGrid(grid):
|
||||
for row in grid:
|
||||
|
Loading…
Reference in New Issue
Block a user