Coder Social home page Coder Social logo

More in-depth docs/API about pyfiglet HOT 2 OPEN

pwaller avatar pwaller commented on May 21, 2024 1
More in-depth docs/API

from pyfiglet.

Comments (2)

pwaller avatar pwaller commented on May 21, 2024

Thanks for raising this. I agree it's not clear to a newcomer. Improvements welcomed. I don't have time to address the general complaint very well myself but I will review changes which improve the situation. The smaller the changes the better.

At the moment I'd recommend reading the source code if you want to know how it works and the API and have a need which isn't immediately addressed by just poking around. (e.g. search for "color" and look for relevant-looking code).

Addressing your colour question in particular:

def print_figlet(text, font=DEFAULT_FONT, colors=":", **kwargs):
ansiColors = parse_color(colors)
if ansiColors:
sys.stdout.write(ansiColors)
print(figlet_format(text, font, **kwargs))
if ansiColors:
sys.stdout.write(RESET_COLORS.decode('UTF-8', 'replace'))
sys.stdout.flush()

from pyfiglet.

pwaller avatar pwaller commented on May 21, 2024

Another request from #105, merging into this issue:

Are there any docs containing list of colors, fonts, and functions/classes as well as their args(that the user is supposed to use)?

from pyfiglet.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.