Skip to main content

Professional modding to the terminal and changing the font of string texts

Project description

xTerm

Alpha Mode (Convert Font String)

Convert String Text To Unicode Font Display

from xTerm import Alpha
# shortcut class
alpha = Alpha.Maths(font_type="Sans_Serif_bold_italic")
# text string for convert
converted_text = alpha.Convert("Hello World")
# Print Output
print(converted_text)
# Hello World

Table Mode (Create Table Data on Terminal)

Draw Table Data On Any Terminal

from xTerm import Table
table = Table([["User01", "34"], ["User02", "56"]], ["User", "ID"], "simple_grid")
print(table)

Output:

┌────────┬──────┐
│ User   │   ID │
├────────┼──────┤
│ User01 │   34 │
├────────┼──────┤
│ User02 │   56 │
└────────┴──────┘

from xTerm import Table
# Create Table Data List
table = Table([
    ["File 01", 233345],
    ["File 02", 545660],
    ["File 03", 100057],
    ["File 04", 438103]],
    ["File Name", "Download"]
    , "simple_grid")
# Output:
# ┌─────────────┬────────────┐
# │ File Name   │   Download │
# ├─────────────┼────────────┤
# │ File 01     │     233345 │
# ├─────────────┼────────────┤
# │ File 02     │     545660 │
# ├─────────────┼────────────┤
# │ File 03     │     100057 │
# ├─────────────┼────────────┤
# │ File 04     │     438103 │
# └─────────────┴────────────┘

Table Funcation

  • table_data: Any,
  • headers: tuple = (),
  • tablefmt: str = "simple",
  • floatfmt: str = _DEFAULT_FLOATFMT,
  • intfmt: str = _DEFAULT_INTFMT,
  • numalign: str = _DEFAULT_ALIGN,
  • stralign: str = _DEFAULT_ALIGN,
  • missingval: str = _DEFAULT_MISSINGVAL,
  • showindex: str = "default",
  • disable_numparse: bool = False,
  • colglobalalign: Any = None,
  • colalign: Any = None,
  • maxcolwidths: Any = None,
  • headersglobalalign: Any = None,
  • headersalign: Any = None,
  • rowalign: Any = None,
  • maxheadercolwidths: Any = None) -> JupyterHTMLStr | LiteralString | str

More details : table

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

xterm-1.3.3.tar.gz (31.0 kB view hashes)

Uploaded Source

Built Distribution

xTerm-1.3.3-py3-none-any.whl (30.0 kB view hashes)

Uploaded Python 3

Supported by

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