Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

c-print

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

c-print

Small python package for printing text in different colours and typography.

  • 1.0.1
  • PyPI
  • Socket score

Maintainers
1

cprint

Small python package for printing text in different colours and typography.

Installation

pip install c-print

Prerequisites

You need to have a Python2.7+ or Python3+ installation with the following libraries:

Usage

The cprint() function simply adds one keyword argument, c, to the python print() function. This extra keyword argument can change the output of print() to one colour and any number of given styles. Colours are given in lower case and styles in upper case. Any other keyword arguments are passed on to print().

CharacterColour
'k'black
'r'red
'g'green
'y'yellow
'b'blue
'm'magenta
'c'cyan
'w'white
CharacterStyle
'B'bold
'D'dark
'I'italic
'U'underline
'F'flash
'R'reverse colour
'C'crossed through

Example:

from cprint import cprint
cprint('Hello World!', c='rB')
cprint('Hello World!', 'Monty Python', c='bUI', end='!')

FAQs


Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc