Example #1
0
def print(msg):
    if hasattr(msg, 'get_pixel'):
        for y in range(5):
            for x in range(5):
                set_pixel(x, y, msg.get_pixel(x, y))
    else:
        _print(msg)
Example #2
0
def spool_print(*args, **kwargs):
    with _print_lock:
        if framework.Framework._spool:
            framework.Framework._spool.write(f"{args[0]}{os.linesep}")
            framework.Framework._spool.flush()
        if 'console' in kwargs and kwargs['console'] is False:
            return
        # new print function must still use the old print function via the backup
        builtins._print(*args, **kwargs)
Example #3
0
def spool_print(*args, **kwargs):
    with _print_lock:
        if framework.Framework._spool:
            framework.Framework._spool.write(f"{args[0]}{os.linesep}")
            framework.Framework._spool.flush()
        # disable terminal output for server jobs
        if framework.Framework._mode == Mode.JOB:
            return
        # new print function must still use the old print function via the backup
        builtins._print(*args, **kwargs)
Example #4
0
 def print(message, color=None, end='\n'):
     _print(message, end=end)
Example #5
0
 def print(message, color=None, end='\n'):
     _print((colored(message, color)), end=end)
Example #6
0
def print(*objects, indent=0, markup='', **print_kwargs):
    _print('\t' * indent, markup, *objects, **print_kwargs)
Example #7
0
from builtins import print as _print

_print("Hello Worlds")
Example #8
0
def print(*args, first=[True], **kwargs):
    _print(*args, **kwargs)
    if first and first.pop():
        _print(f"follow me on twitter @sushtend".rjust(80, " "))
    else:
        _print(f"@sushtend".rjust(80, " "))
Example #9
0
def print(*args, **kwargs):
    from builtins import print as _print
    nargs = [remove_accent(arg) if isinstance(arg, str) else arg for arg in args]
    _print(*nargs, **kwargs)
Example #10
0
def scroll(msg):
    # TODO: Font.
    _print(msg)
Example #11
0
 def print(self, *args, **kwargs):
     cf = sys._getframe(self.level + 1)
     _print(
         '{}:{} in '.format(compress(cf.f_code.co_filename), cf.f_lineno,
                            cf.f_code.co_name), '|', *args, **kwargs)