Output plain text :param texts: Texts need to output. The type can be any object, and the `str()` function will be used for non-string objects. :param str sep: The separator between the texts :param bool inline: Use text as an inline element (no line break at the end of the text).
(*texts: Any, sep: str = ' ', inline: bool = False, scope: str = None,
position: int = OutputPosition.BOTTOM)
| 381 | |
| 382 | |
| 383 | def put_text(*texts: Any, sep: str = ' ', inline: bool = False, scope: str = None, |
| 384 | position: int = OutputPosition.BOTTOM) -> Output: |
| 385 | """ |
| 386 | Output plain text |
| 387 | |
| 388 | :param texts: Texts need to output. The type can be any object, and the `str()` function will be used for non-string objects. |
| 389 | :param str sep: The separator between the texts |
| 390 | :param bool inline: Use text as an inline element (no line break at the end of the text). Default is ``False`` |
| 391 | :param str scope: The target scope to output. If the scope does not exist, no operation will be performed. |
| 392 | |
| 393 | Can specify the scope name or use a integer to index the runtime scope stack. |
| 394 | :param int position: The position where the content is output in target scope |
| 395 | |
| 396 | For more information about ``scope`` and ``position`` parameter, please refer to :ref:`User Manual <scope_param>` |
| 397 | """ |
| 398 | content = sep.join(str(i) for i in texts) |
| 399 | spec = _get_output_spec('text', content=content, inline=inline, scope=scope, position=position) |
| 400 | return Output(spec) |
| 401 | |
| 402 | |
| 403 | def _put_message(color, contents, closable=False, scope=None, position=OutputPosition.BOTTOM) -> Output: |
searching dependent graphs…