renamed over.core.textui to over.core.text
This commit is contained in:
parent
2f778e7c79
commit
93e8c12547
6 changed files with 14 additions and 13 deletions
12
core/app.py
12
core/app.py
|
@ -5,10 +5,10 @@ import sys
|
|||
import re
|
||||
|
||||
from . import file
|
||||
from . import textui
|
||||
from . import text
|
||||
from ..version import _version
|
||||
|
||||
prefix = textui.prefix
|
||||
prefix = text.prefix
|
||||
|
||||
# FIXME This very seriously needs to be heavily simplified and de-duplicated
|
||||
# TODO same parser for cmdline and Config
|
||||
|
@ -55,8 +55,8 @@ _over_help_texts = [
|
|||
|
||||
# --------------------------------------------------
|
||||
|
||||
def _output(text, indent=0, newlines=1):
|
||||
sys.stdout.write(textui.render(textui.paragraph(text, indent=indent), True))
|
||||
def _output(raw, indent=0, newlines=1):
|
||||
sys.stdout.write(text.render(text.paragraph(raw, indent=indent), True))
|
||||
sys.stdout.write(newlines * '\n')
|
||||
sys.stdout.flush()
|
||||
|
||||
|
@ -229,7 +229,7 @@ class Main:
|
|||
self.cmdline = cmdline
|
||||
self.help_texts = [] # (chapter, [paragraphs])
|
||||
self.allow_exit = allow_exit
|
||||
self._print = textui.Output('over.core.app.Main')
|
||||
self._print = text.Output('over.core.app.Main')
|
||||
|
||||
if cfg_file:
|
||||
self.cfg_file = file.File(cfg_file, encoding='utf-8')
|
||||
|
@ -575,7 +575,7 @@ class Main:
|
|||
else:
|
||||
self._print('updating config file with option §B--§y%s§/' %(opt.name))
|
||||
new_lines.append('')
|
||||
new_lines.append(textui.paragraph(textui.render(opt.description, colors=False), prefix='#', width=80))
|
||||
new_lines.append(text.paragraph(text.render(opt.description, colors=False), prefix='#', width=80))
|
||||
new_lines.append('# *** data type: %s' %(opt.dtype))
|
||||
|
||||
if opt.plural:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue