Skip to main content

a python package for styling the terminal. how original, i know.

Project description

tastystyle

a small python package for styling the terminal. how original, i know.

tastystyle supports colours, bold text, dim text, italics, underlined, background and foreground reversal and strikethrough text.

please note not all styles work on windows

colours

text is coloured with the bg() and fg() commands. it support keywords, rgb colours, and hex colours.

example:

from tastystyle import colors as c

# keyword
print(f'{c.FG("GREEN")}Green!{c.RESET()}')
# rgb
print(f'{c.FG(65, 214, 62)}Green!{c.RESET()}')
# hex
print(f'{c.FG("#41d63e")}Green!{c.RESET()}')
all keywords
name rgb hex
RED 214, 62, 62 #d63e3e
ORANGE 214, 143, 62 #d68f3e
YELLOW 211, 214, 62 #d3d63e
L_GREEN 98, 214, 96 #62d660
GREEN 65, 214, 62 #41d63e
CYAN 62, 214, 199 #3ed6c7
L_BLUE 62, 161, 214 #3ea1d6
BLUE 62, 65, 214 #3e41d6
PURPLE 181, 62, 214 #b53ed6
VIOLEET 214, 62, 209 #d63ed1

other

text can be styled in other ways with the following:

from tastystyle import styles as s

# bold
print(f'{s.BOLD()}bold text{s.RESET()}')
# italic
print(f'{s.ITALIC()}italic text{s.RESET()}')
# underline
print(f'{s.UNDER()}underlined text{s.RESET()}')
# strikethrough
print(f'{s.STRIKE()}strikethrough text{s.RESET()}')
# dim
print(f'{s.DIM()}dim text{s.RESET()}')
# reversed
print(f'{s.REVERSE()}reversed text{s.RESET()}')

created with ❤ by tastyl

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

tastystyle-0.0.1.tar.gz (2.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

tastystyle-0.0.1-py3-none-any.whl (3.5 kB view details)

Uploaded Python 3

File details

Details for the file tastystyle-0.0.1.tar.gz.

File metadata

  • Download URL: tastystyle-0.0.1.tar.gz
  • Upload date:
  • Size: 2.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.9.7

File hashes

Hashes for tastystyle-0.0.1.tar.gz
Algorithm Hash digest
SHA256 55db36c78f4096750f0c31d555011297e2ff2807ad264e89f73c2f96533f1cd3
MD5 6cd379aa9752af5ef1b636d242e1f398
BLAKE2b-256 bacae486685019161dae231b0212e09a7c5c778bc4d86a9b5e3ca71a65d17acc

See more details on using hashes here.

File details

Details for the file tastystyle-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: tastystyle-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 3.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.9.7

File hashes

Hashes for tastystyle-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 3809aaa33271e8cbd50b7c5f27f8deabb67146c6d6da819921199b6c63f13ec1
MD5 d1c44bec70d7ba2386a912de7f0ea084
BLAKE2b-256 99d393cdb113c30d89d1cd7070fa9c7a3e99f00a793895b9a89bb9e569104213

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page