An open API service indexing awesome lists of open source software.

https://github.com/jonghwanhyeon/python-tml

A terminal markup language, inspired by tml
https://github.com/jonghwanhyeon/python-tml

Last synced: 3 months ago
JSON representation

A terminal markup language, inspired by tml

Awesome Lists containing this project

README

        

# Terminal Markup Language (tml)
- A python library to make the output of colored text in the terminal easier and more readable.

## Example
```python
from tml import markup
print(markup("this text is red and the following is green"))
```

Alternatively, you can use the `mprint()` function, which is a convenient shortcut.
```python
from tml import mprint
mprint("this text is red and the following is green")
```

You don't need to close the tag explicitly if it is not needed.
```python
print(markup("this text has blue foreground on green background colors"))
```

If you would like to print brackets, use them in doubles:
```python
print(markup("This is <>"))
```

## Available Tags
### Foreground
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``

### Background
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``

### Attributes
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``
- ``

## Acknowledgement
- This library is inspired by [tml](https://github.com/liamg/tml)