Skip to main content

A Python library for customizing and managing the terminal and console.

Project description

NovaTerm


What's NovaTerm?

  • NovaTerm is a python library that helps customize and manage the console and system. In future updates i'll try to add more functions. The current version is 1.0.0.

  • NovaTerm is made by a single developer.


Instalation:

  • In the terminal, run pip install novaterm

How to use?

  • in NovaTerm, you can color the foreground with: print(novaterm.colors.red_text("Hello, world!")).

  • At the top of your file, you have to add import novaterm or from novaterm import colors, functions....

  • You can use an object with a name you want like in the exemple below:

import novaterm

colors = novaterm.colors()
functions = novaterm.functions()
system = novaterm.system()
environment = novaterm.environment()


print(colors.red_text("Hello!"))

# OR

print(colors.red_text("Hello!"), end="")
  • You can also use the normal proprieties of print().

  • Threr are various colors in novaterm.colors: red_text(), blue_text(), green_text(), orange_text(), purple_text(), pink_text(), yellow_text(), black_text(), white_text().

  • There's a novaterm.functions.clear() function that clears the output in a console.

  • There are functions in novaterm.system like shutdown(), restart(), logout() that interact with your operating system.

  • In novaterm.environment are functions like terminate(), wich ends the execution of the program and error(), that intentionaly ends the program with an error.

  • Threr's also a function in novaterm.colors caled custom_rgb_text(), that takes as parameters custom_rgb_text(r, g, b, text) which are int, int, int, string.

  • There are special caracters in novaterm.characters.

  • novaterm.boxes allows you to use boxes.

  • novaterm.progressbar allows you to have a progressbar in your code!

  • novaterm.styles can give your text a better look.

Exemples:

import novaterm


# OR:
# from novaterm import colors, functions, environment, system

# Colors
colors = novaterm.colors()
functions = novaterm.functions()
system = novaterm.system()
environment = novaterm.environment()

print(nc.red_text("Hello!"))
print(nc.red_text("Hello!"), end="")

# System
system.shutdown()
system.logout()
system.restart()

# Environment
environment.terminate()
environment.error()
environment.title("MyApp")

# Functions
functions.clear()

Characters:

Characters
Variabilă Caracter
PILCROW
SECTION §
COPYRIGHT ©
REGISTERED ®
DEGREE °
OPEN_DOUBLE_ANGLE «
CLOSE_DOUBLE_ANGLE »
PLUS_MINUS ±
QUARTER ¼
HALF ½
THREE_QUARTERS ¾
DIVISION ÷
ORNAMENT ֍
BULLET
BITCOIN
NUMERO
SOUND_COPYRIGHT
TRADEMARK
ONE_THIRD
TWO_THIRDS
LEFT_ARROW
UP_ARROW
RIGHT_ARROW
DOWN_ARROW
LEFT_RIGHT_ARROW
UP_DOWN_ARROW
DELTA
SIGMA
SQUARE_ROOT
INFINITY
APPROXIMATELY_EQUALS
UPPER_HALF_BLOCK
LOWER_HALF_BLOCK
FULL_BLOCK
LEFT_HALF_BLOCK
RIGHT_HALF_BLOCK
BLACK_SQUARE
WHITE_SQUARE
SMALL_BLACK_SQUARE
SMALL_WHITE_SQUARE
BLACK_RECTANGLE
UP_TRIANGLE
RIGHT_TRIANGLE
DOWN_TRIANGLE
LEFT_TRIANGLE
BLACK_CIRCLE
BEAMED_EIGHTH_NOTES
EIGHTH_NOTE
POKER_DIAMOND
POKER_HEART
POKER_CLUB
POKER_SPADE
MALE
FEMALE
SUN
SMILE
SHADE
Boxes
Variabilă Caracter
HORIZONTAL
VERTICAL
TOP_LEFT
TOP_RIGHT
BOTTOM_LEFT
BOTTOM_RIGHT
LEFT_T
RIGHT_T
TOP_T
BOTTOM_T
CROSS

Exemple:

import novaterm

characters = novaterm.characters()
colors = novaterm.colors()

print(colors.green_text(characters.BLACK_CIRCLE))

novaterm.boxes gives you the characters necesary to build a box.


Progressbar:

  • In order for the progressbar to look exactly how you want, you have to declare the atributes first! It's optional, but usefull!
  • You can show the progressbar with novaterm.progressbar.show().
  • You can increase and decrease it with novaterm.progressbar.increase(VALUE) and novaterm.progressbar.decrease(VALUE).

Exemple:

import novaterm

bar = novaterm.progressbar()
characters = novaterm.characters()

# Default look:
bar.current = 0
bar.total = 100
bar.width = 40
bar.symbol_fill = characters.FULL_BLOCK
bar.symbol_empty = "-"

bar.show()
bar.increase(10)
bar.decrease(5)

bar.close() # Move to next line

Styles:

  • novaterm.styles can make your text bold, italic or underlined.

Exemple:

import novaterm

styles = novaterm.styles()

# Bold:
print(novaterm.bold("Bold text!"))

# Italic:
print(novaterm.italic("Italic text!"))

# Underlined:
print(novaterm.underline("Underlined text!"))

About the developer:

  • My name is Cristea Razvan and i'm a 13 year old developer who likes making free and open source software. I made this library because I realy need a way to make my console apps beautifull without stressing with ANSI escape codes or complex code to make the program more powerfull.

Contact Me

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

novaterm-1.1.7.tar.gz (5.0 kB view details)

Uploaded Source

Built Distribution

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

novaterm-1.1.7-py3-none-any.whl (5.4 kB view details)

Uploaded Python 3

File details

Details for the file novaterm-1.1.7.tar.gz.

File metadata

  • Download URL: novaterm-1.1.7.tar.gz
  • Upload date:
  • Size: 5.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.0

File hashes

Hashes for novaterm-1.1.7.tar.gz
Algorithm Hash digest
SHA256 bed7d90c81a9e189db896be6b618f0da689cd20532791d8d6b69d4ee7566e66a
MD5 e7344fee6e987b54a2fd9e925eb9eb7b
BLAKE2b-256 a66379a8e160b42946f039d13b3eb26eb73d02a5238dc6d918b673946d8876d4

See more details on using hashes here.

File details

Details for the file novaterm-1.1.7-py3-none-any.whl.

File metadata

  • Download URL: novaterm-1.1.7-py3-none-any.whl
  • Upload date:
  • Size: 5.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.0

File hashes

Hashes for novaterm-1.1.7-py3-none-any.whl
Algorithm Hash digest
SHA256 26b7bb4cd17a6664a1e57aa1d8573b8cb89288f0371faa76fd05c98830b91b07
MD5 a935331cd1b5c770b73e12239984bfab
BLAKE2b-256 3168f9b2328c878ca49b1012fabed059916219650d50106a6296f9f12a3a7fc5

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