any encoding available...
This commit is contained in:
@@ -16,13 +16,7 @@ def setup_options():
|
||||
type = str,
|
||||
default = "cp437",
|
||||
nargs = '?',
|
||||
choices = [
|
||||
"ascii",
|
||||
"cp437",
|
||||
"cp850",
|
||||
"cp1250",
|
||||
"latin1",
|
||||
]
|
||||
help = "Character set to show, ex. ascii, cp437, cp850, cp1250, latin1 ..."
|
||||
)
|
||||
opts=parser.parse_args()
|
||||
return opts
|
||||
@@ -65,7 +59,8 @@ if __name__ == "__main__":
|
||||
table.pop(0)
|
||||
bc = ansi.code()
|
||||
bc.clear()
|
||||
print(bc.color_string("="*20 + " ${Y}%s${Z} "%( opts.cs, ) + "="*20))
|
||||
lines = int(32 - len(opts.cs)/2 - 2)
|
||||
print(bc.color_string("="*lines + " ${Y}%s${Z} "%( opts.cs, ) + "="*lines))
|
||||
if opts.v:
|
||||
long_format(table)
|
||||
else:
|
||||
|
||||
Reference in New Issue
Block a user