2005-06-30 Bernhard Herzog <bh@intevation.de>
* shapelib.i (new_SHPObject): Fix the test for the length of the
part types. It used the wrong variable.
* shapelib_wrap.c: Regenerated from shapelib.i
* pytest.py (make_shapefile): Add some more comments and add an
example with a polygon with a hole.
2004-12-27 Bernhard Reiter <bernhard@intevation.de>
* README: Refering to the new homepage shapelib.maptools.org now.
2004-12-13 Bernhard Herzog <bh@intevation.de>
* dbflib.py: Updated from difflib.i with SWIG.
* dbflib.i: Work around a bug in the generated python code which
leads to exception in the __del__ method when the constructor
fails. See the comments in the code for more details.
2004-05-28 Bernhard Herzog <bh@intevation.de>
* README: Flesh out the some more. Correct the shapelib
requirements.
* NEWS: Update the date of the actual release of 0.3
2004-05-28 Bernhard Herzog <bh@intevation.de>
* setup.py: Determine shp_dir correctly when run with bdist_rpm
(dbf_macros): Remove a debug print
* NEWS: Also mention the new (compared to 0.2) setup.py
* MANIFEST.in: New. Define which files belong into a source
distribution
2004-05-17 Bernhard Herzog <bh@intevation.de>
* README: Update for new release
* setup.py (dbf_macros): New. Return the preprocessor macros
needed to compile the dbflib wrapper. Determine whether
DBFUpdateHeader is available and define the right value of
HAVE_UPDATE_HEADER
(extensions): Use dbf_macros for the dbflibc extension
* dbflib_wrap.c, dbflib.py: Update from dbflib.i
* dbflib.i (DBFInfo_commit): New. Implementation of the commit
method. This new indirection is necessary because we use the
DBFUpdateHeader function now which is not available in shapelib <=
1.2.10
(DBFFile::commit): Use DBFInfo_commit as implementation
(pragma __class__): New. Kludge to remove the commit method when
the DBFUpdateHeader function isn't available
(_have_commit): New. Helper for the pragma kludge.
2003-11-03 Bernhard Herzog <bh@intevation.de>
* dbflib.i (do_read_attribute): New helper function for reading
one attribute as a python object
(DBFInfo_read_attribute): New. Implement the read_attribute method
(DBFInfo_read_record): Use do_read_attribute to read the
individual values
(struct DBFFile): Add the read_attribute method.
* dbflib_wrap.c, dbflib.py: Update from dbflib.i.
2003-09-29 Bernhard Herzog <bh@intevation.de>
* dbflib.i: Add exception typemap for the add_field method. Fixes
Thuban bug RT#1842
* dbflib_wrap.c: Update from dbflib.i
* testdbf.py: New. Test cases for the dbflib bindings based on the
unittest module
2003-08-18 Bernhard Herzog <bh@intevation.de>
* dbflib.i (DBFInfo_write_record): Use PySequence_Check instead of
PyMapping_Check to distinguish between sequences and mappings
because in Python 2.3, PyMapping_Check returns true for tuples and
lists too.
2003-05-28 Bernhard Herzog <bh@intevation.de>
* dbflib.i (DBFInfo_read_record): Read NULL fields as None unless
it's a string field. DBF files can't distinguish between NULL and
an empty string. Also, check the return value of
DBFReadStringAttribute which may return NULL to indicate errors.
* dbflib_wrap.c: Updated from dbflib.i
2002-08-27 Bernhard Herzog <bh@intevation.de>
* dbflib.i: Raise an exception if open or create fails.
* shapelib.i: Slightly better wording for the IOError exception
that open and create may raise.
* shapelib_wrap.c, dbflib_wrap.c: Regenerated
2002-08-22 Bernhard Herzog <bh@intevation.de>
* dbflib.i (DBFFile::commit): New method for DBFCommit.
* dbflib_wrap.c, dbflib.py: Update from dbflib.i
2002-08-15 Bernhard Herzog <bh@intevation.de>
* shapelib.i, dbflib.i: Make the NOCHECK trick for the ShapeFile *
check typemap work with SWIG 1.3.
* shapelib_wrap.c, dbflib_wrap.c: Regenerate from the .i files.
2002-05-10 Bernhard Herzog <bh@intevation.de>
* dbflib.i (DBFInfo_write_record): Only DECREF if the return value
of PyMapping_GetItemString is not NULL. Also, test the return
value of PySequence_GetItem
(write_field): Remove some debug prints
* dbflib_wrap.c: Updated from dbflib.i
2002-05-07 Bernhard Herzog <bh@intevation.de>
* shptreemodule.c (SHPTreeType, initshptree): Set SHPTreeType's
PyType_Type pointer in the init function.
(shptree_methods): Use METH_VARARGS
(shptree_dealloc): Use PyMem_DEL
(shptree_find_shapes): Add a missing return
2002-05-07 Bernhard Herzog <bh@intevation.de>
* shptreemodule.c: New file with a simple wrapper for shapelib's
quadtree
* setup.py: Some fixes to use explicit forward slashes as
directory separators because of distutils.
(extensions): Add the shptree module.
* pytest.py (read_shapefile): Add some demo calls for the shptree
module
* pyshapelib_api.h (PyShapeLibAPI): Add some of the shptree
functions.
(PYSHAPELIB_IMPORT_API): New macro to import the API
* shapelib.i (the_api): add the tree API functions.
* shapelib_wrap.c: Updated from shapelib.i with SWIG.
2002-04-11 Bernhard Herzog <bh@intevation.de>
* pyshapelib_api.h: New file with a limited C-level API for
accessing shapilib functions from other Python-extensions.
* shapelib.i: Export the C-level API with the c_api function.
* shapelib.py, shapelib_wrap.c: Updated from shapelib.i. Still
done with a very old version of SWIG, but it's probably not worth
it to try it with a newer version as long as this still works.
2001-07-18 Bernhard Herzog <bh@intevation.de>
* shapelib.i (open_ShapeFile): declare the swig prototype
correctly with ShapeFile* as return type
(ShapeFile.cobject): New method returning the SHPHandle* as a
CObject
* Makefile (VERSION): Increase to 0.3
* setup.py, MANIFEST.in: New files for python distutils.
2001-06-15 Bernhard Herzog <bh@intevation.de>
* Makefile (VERSION): Increase to 0.2
2001-06-14 Bernhard Herzog <bh@intevation.de>
* shapelib.i: Add the functions SHPTypeName as type_name and
SHPPartTypeName as part_type_name
(SHPObject_vertices):
(build_vertex_list): Put building a list of vertices into the
separate function build_vertex_list so that SHPObject_vertices can
support SHPT_POINT too.
* ChangeLog: create ChangeLog