diff options
author | Martin Matusiak <numerodix@gmail.com> | 2014-03-09 12:37:55 +0100 |
---|---|---|
committer | Martin Matusiak <numerodix@gmail.com> | 2014-03-09 12:37:55 +0100 |
commit | 85c527f7508638be9a2f9e65a9a0bad4d466c4ea (patch) | |
tree | 2e076f951e110ba2cfe892d6caa38536cfb1a434 /README.rst | |
parent | 57102b2a30b726b881718f7727b9dfe8bc0b7f9d (diff) | |
download | ansicolor-85c527f7508638be9a2f9e65a9a0bad4d466c4ea.tar.gz |
expand docs
Diffstat (limited to 'README.rst')
-rw-r--r-- | README.rst | 11 |
1 files changed, 2 insertions, 9 deletions
@@ -33,16 +33,9 @@ Getting started To highlight using colors: -.. code:: python - - from ansicolor import green - from ansicolor import red - from ansicolor import white +.. literalinclude:: snippets/getting_started_1.py - print("Let's try two colors: %s and %s!" % (red("red"), green("green"))) - print("It's also easy to produce text in %s," % (red("bold", bold=True))) - print("...%s," % (green("reverse", reverse=True))) - print("...and %s." % (cyan("bold and reverse", bold=True, reverse=True))) +.. figure:: snippets/getting_started_1.png This will emit ansi escapes into the string: one when starting a color, another |