'Send text data. This will pre-process the text for
color-replacement, conversion to html etc.
Args:
text (str): Text to send.
Kwargs:
options (dict): Options-dict with the following keys understood:
- raw (bool): No parsing at all (leave ansi-to-html markers unparsed).
- nocolor (bool): Remove all color.
- screenreader (bool): Use Screenreader mode.
- send_prompt (bool): Send a prompt with parsed html'

def send_text(self, *args, **kwargs):

    if args:
        args = list(args)
        text = args[0]
        if (text is None):
            return
    else:
        return
    flags = self.protocol_flags
    text = utils.to_str(text, force_string=True)
    options = kwargs.pop('options', {})
    raw = options.get('raw', flags.get('RAW', False))
    xterm256 = options.get('xterm256', flags.get('XTERM256', True))
    useansi = options.get('ansi', flags.get('ANSI', True))
    nocolor = options.get('nocolor', (flags.get('NOCOLOR') or (not (xterm256 or useansi))))
    screenreader = options.get('screenreader', flags.get('SCREENREADER', False))
    prompt = options.get('send_prompt', False)
    if screenreader:
        text = parse_ansi(text, strip_ansi=True, xterm256=False, mxp=False)
        text = _RE_SCREENREADER_REGEX.sub('', text)
    cmd = ('prompt' if prompt else 'text')
    if raw:
        args[0] = text
    else:
        args[0] = parse_html(text, strip_ansi=nocolor)
    self.client.lineSend(self.csessid, [cmd, args, kwargs])
