From b14584ff33f85a349f27273575c26b2fc84bd4cc Mon Sep 17 00:00:00 2001 From: Lucas Heitzmann Gabrielli Date: Sun, 11 Sep 2016 09:42:37 -0300 Subject: [PATCH] Release 1.0 --- .gitignore | 1 + README.md | 6 ++++++ docs/conf.py | 3 +-- docs/construction.rst | 17 ++++++++++++++--- docs/myfactory.py | 15 --------------- examples/tutorial.py | 4 ++-- gdspy/__init__.py | 2 +- setup.py | 2 +- 8 files changed, 26 insertions(+), 24 deletions(-) delete mode 100755 docs/myfactory.py mode change 100755 => 100644 examples/tutorial.py diff --git a/.gitignore b/.gitignore index d493914..1eb98c2 100644 --- a/.gitignore +++ b/.gitignore @@ -1,5 +1,6 @@ MANIFEST test.sh +compile_extensions.sh debug.py winbuild* *.gds diff --git a/README.md b/README.md index 63f06f4..b359bfb 100644 --- a/README.md +++ b/README.md @@ -52,6 +52,12 @@ Help support Gdspy development by [donating via PayPal](https://www.paypal.com/c ## History of changes +### Version 1.0 (Sep 11, 2016) +* Changed to "new style" classes (thanks to Adam McCaughan for the contribution). +* Added a per-point radius specification for `Polygon.fillet` (thanks to Adam McCaughan for the contribution). +* Added `inside` fucntion to perform point-in-polygon tests (thanks to @okianus for the contribution). +* Moved from distutils to setuptools for better Windows support. + ### Version 0.9 (Jul 17, 2016) * Added option to join polygons before applying an `offset`. * Added a `translate` method to geometric entities (thanks John Bell for the commit). diff --git a/docs/conf.py b/docs/conf.py index 6b9a717..a5b2c30 100755 --- a/docs/conf.py +++ b/docs/conf.py @@ -20,7 +20,6 @@ # If extensions (or modules to document with autodoc) are in another directory, # add these directories to sys.path here. If the directory is relative to the # documentation root, use os.path.abspath to make it absolute, like shown here. -sys.path.insert(0, os.path.abspath('.')) sys.path.insert(0, os.path.abspath('../../gdspy')) # -- General configuration ------------------------------------------------ @@ -33,7 +32,7 @@ # ones. extensions = [ 'sphinx.ext.autodoc', - 'myfactory', + 'numpydoc', ] # Add any paths that contain templates here, relative to this directory. diff --git a/docs/construction.rst b/docs/construction.rst index 06cc86a..a613c83 100755 --- a/docs/construction.rst +++ b/docs/construction.rst @@ -126,6 +126,11 @@ fast_boolean .. autofunction:: gdspy.fast_boolean +boolean +------- + +.. autofunction:: gdspy.boolean + offset ------ @@ -138,8 +143,14 @@ slice .. autofunction:: gdspy.slice -boolean -------- +inside +------ -.. autofunction:: gdspy.boolean +.. autofunction:: gdspy.inside + + +copy +---- + +.. autofunction:: gdspy.copy diff --git a/docs/myfactory.py b/docs/myfactory.py deleted file mode 100755 index 8ba6fe4..0000000 --- a/docs/myfactory.py +++ /dev/null @@ -1,15 +0,0 @@ -import re -#import sphinx.ext.autodoc - -def myfactory(app, what, name, obj, options, lines): - regex = re.compile('-+$') - i = len(lines) - 3 - while i > 1: - if regex.match(lines[i].strip()): - lines[i] = '' - lines[i-1] = '**' + lines[i-1] + '**' - i -= 2 - i -= 1 - -def setup(app): - app.connect('autodoc-process-docstring', myfactory) diff --git a/examples/tutorial.py b/examples/tutorial.py old mode 100755 new mode 100644 index c5a5f41..c0797da --- a/examples/tutorial.py +++ b/examples/tutorial.py @@ -199,6 +199,7 @@ def dspiral_dt(t): ## POLYGON OPERATIONS ## ------------------------------------------------------------------ ## + ## Boolean operations can be executed with either gdspy polygons or ## point lists). The operations are union, intersection, subtraction, ## symmetric subtracion (respectively 'or', 'and', 'not', 'xor'). @@ -285,6 +286,7 @@ def dspiral_dt(t): ## Translation ## ------------------------------------------------------------------ ## + trans_cell = gdspy.Cell('TRANS') ## Any geometric object can be translated by providing the distance to @@ -307,7 +309,6 @@ def dspiral_dt(t): trans_cell.add(ref2) - ## Same goes for Labels & Text text1 = gdspy.Text('Created with gsdpy ' + gdspy.__version__, 7, (-7, -35), layer=6) @@ -321,7 +322,6 @@ def dspiral_dt(t): trans_cell.add(label2) - ## ------------------------------------------------------------------ ## ## OUTPUT ## ------------------------------------------------------------------ ## diff --git a/gdspy/__init__.py b/gdspy/__init__.py index 7a35626..3857cf3 100644 --- a/gdspy/__init__.py +++ b/gdspy/__init__.py @@ -45,7 +45,7 @@ from gdspy import clipper from gdspy.viewer import LayoutViewer -__version__ = '0.9' +__version__ = '1.0' _halfpi = 0.5 * numpy.pi diff --git a/setup.py b/setup.py index d8f56a3..75c91ff 100644 --- a/setup.py +++ b/setup.py @@ -24,7 +24,7 @@ setup( name = 'gdspy', - version = '0.9', + version = '1.0', author = 'Lucas Heitzmann Gabrielli', author_email = 'heitzmann@gmail.com', license = 'GNU General Public License v3 (GPLv3)',