Skip to content

Commit

Permalink
Update README, bump version
Browse files Browse the repository at this point in the history
  • Loading branch information
mportesdev committed Apr 28, 2021
1 parent edf5e16 commit 4be22e8
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 15 deletions.
27 changes: 15 additions & 12 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,22 +3,25 @@
Save pictures to PDF from the command line or from your Python programs.

Requirements
------------
============

Python 3.6 or higher is required. The only third-party dependency is `reportlab <https://pypi.org/project/reportlab/>`__.
- Python 3.6 or higher
- `Pillow <https://pypi.org/project/Pillow/>`__
- `reportlab <https://pypi.org/project/reportlab/>`__

Installation
------------
============

.. code::
pip install pictureshow
Usage
=====

As a command line tool
----------------------

Usage:

.. code::
usage: pictureshow [-h] [-p SIZE] [-L] [-m MARGIN] [-l LAYOUT] [-s] [-f]
Expand Down Expand Up @@ -55,29 +58,29 @@ Save a single picture to PDF.
.. code::
$ pictureshow pics/mandelbrot.png mandelbrot.pdf
Saved 1 picture (1 page) to '/.../mandelbrot.pdf'
Saved 1 picture (1 page) to 'mandelbrot.pdf'
Example 2
~~~~~~~~~

Select pictures using a glob pattern [#]_, set page to landscape Letter-sized [#]_.
Save pictures using a glob pattern [#]_, set page to landscape Letter-sized [#]_.

.. code::
$ pictureshow pics/plots/gauss* gauss.pdf --landscape --page-size=LETTER
Saved 2 pictures (2 pages) to '/.../gauss.pdf'
Saved 2 pictures (2 pages) to 'gauss.pdf'
Example 3
~~~~~~~~~

Select pictures using a glob pattern, set half-inch margin and layout of 1x3 pictures per page.
Save pictures using a URL pattern, set layout of 1x2 pictures per page.

.. code::
$ pictureshow -m36 -l1x3 pics/blender/* 3d_pics.pdf
Saved 4 pictures (2 pages) to '/.../3d_pics.pdf'
$ pictureshow -l1x2 https://wiki.openttd.org/uploads/en/Manual/Town-{2x2,3x3}.png towns.pdf
Saved 2 pictures (1 page) to 'towns.pdf'
As a Python library
Expand Down Expand Up @@ -126,7 +129,7 @@ Another example, demonstrating all available keyword-only arguments:
Footnotes
~~~~~~~~~
=========

.. [#] Please note that glob patterns are not expanded by the Windows command line shell.
.. [#] Available page sizes are:
Expand Down
2 changes: 1 addition & 1 deletion pictureshow/__init__.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
from pictureshow.exceptions import PageSizeError, MarginError, LayoutError
from pictureshow.core import PictureShow, pictures_to_pdf

__version__ = '0.6.3'
__version__ = '0.6.4'

__all__ = ['__version__', 'PictureShow', 'pictures_to_pdf',
'PageSizeError', 'MarginError', 'LayoutError']
2 changes: 1 addition & 1 deletion pictureshow/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ def _number(number, noun):
def main():
parser = argparse.ArgumentParser(
prog='pictureshow',
description='Save pictures to PDF',
description='Save pictures to PDF.',
epilog='https://pypi.org/project/pictureshow/'
)
parser.version = pictureshow.__version__
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
version=pictureshow.__version__,
author='Michal Porteš',
author_email='michalportes1@gmail.com',
description='Save pictures to PDF',
description='Save pictures to PDF.',
long_description=long_description,
long_description_content_type='text/x-rst',
url='https://github.com/mportesdev/pictureshow',
Expand Down

0 comments on commit 4be22e8

Please sign in to comment.