/[thuban]/branches/WIP-pyshapelib-bramz/ChangeLog
ViewVC logotype

Diff of /branches/WIP-pyshapelib-bramz/ChangeLog

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 2556 by bernhard, Mon Feb 7 13:46:53 2005 UTC revision 2623 by bh, Mon May 9 18:12:12 2005 UTC
# Line 1  Line 1 
1    2005-05-09  Bernhard Herzog  <[email protected]>
2    
3            * Thuban/Model/postgisdb.py (PostGISConnection.connect): Set the
4            connection to autoconnect.  Fixes RT#3148.
5    
6            * test/test_postgis_db.py
7            (TestPostGISSpecialCases.test_simple_error_handling): New test
8            that attempts to reproduce RT#3148.
9    
10    2005-05-06  Jonathan Coles <[email protected]>
11    
12            Add support for saving and loading the opacity and mask type
13            properties of RasterLayers. Also add support for proper use
14            of alpha information while drawing images not in 'RAW' format.
15            If transparency in an image format (e.g, PNG) is supported by
16            wxWidgets then the image would previously have been draw with
17            transparent regions, but the opaque regions would have been
18            unaffected by a change in the layer's opacity. This patch
19            corrects the problem.
20    
21            * Thuban/Model/layer.py (RasterLayer): Added opacity and
22            masktype parameters to the constructor, and set the
23            appropriate variables to those values.
24    
25            * Thuban/Model/load.py (SessionLoader.start_rasterlayer): Added
26            code to read the opacity and mask type of the layer and construct
27            a new layer with the additional parameters.
28    
29            * Thuban/Model/save.py (SessionSaver.write_layer): Added code
30            to save the opacity and mask type of a layer.
31    
32            * Thuban/UI/baserenderer.py (BaseRenderer.draw_raster_layer): Pass
33            the opacity of the layer to draw_raster_data rather than the layer.
34            (BaseRenderer.draw_raster_data): Remove the layer parameter because
35            the function doesn't need to know about the layer. Add the optional
36            opacity parameter whose default is 1.0. Add 'PNG' as a supported
37            graphics format.
38    
39            * Thuban/UI/renderer.py (MapRenderer.draw_raster_data): Fixed
40            signature to match that in BaseRenderer. Use the new opacity argument
41            in place of calling layer.Opacity(). In the case where the
42            format is not 'RAW', alpha_data is None and the loaded image has
43            alpha information, use the file's alpha information. This is
44            still subject to the layer's opacity setting.
45    
46            * test/test_baserenderer.py (SimpleRenderer.draw_raster_data):
47            Fixed signature to match that in BaseRenderer.
48    
49            * test/test_load.py (TestRasterLayer): Change file_contents to
50            include opacity and masktype variables.
51            (TestRasterLayer.test): Include tests for opacity and masktype
52            changes.
53    
54            * test/test_save.py (SaveSessionTest.testRasterLayer): Restructure
55            test to cover a variety of combinations of masktype and opacity
56            settings.
57    
58    2005-05-02  Jan-Oliver Wagner <[email protected]>
59    
60            * debian/rules: add --use-wx-python-swig-hack
61            to the build command.
62            Thanks to Moritz Lennert for pointing this out.
63    
64    2005-04-28  Jan-Oliver Wagner <[email protected]>
65    
66            Introduce OGRFileShapeStore in ogr extension.
67            This allows at least that loaded shapefile shape stores
68            can be saved correctly in the thuban session file
69            and reloaded again (reload is via core shapefile
70            routine, not OGR). For other types, .thuban files
71            can not be reloaded for the time being.
72    
73            * Extensions/ogr/ogrshapes.py (OGRFileShapeStore): New. This
74            class ist to be used for any file-based shape stores
75            accessed through OGR.
76    
77            * Extensions/ogr/ogrstart.py (open_with_ogr): Added
78            forgotten _ for i18n. Adapted call OpenFileShapestore
79            regarding new parameter.
80            (OpenFileShapestore): Use OGRFileShapeStore instead of
81            OGRShapeStore. Fix return value (None instead of null).
82            Add new parameter "mainwindow" to avoid accessing global
83            context.
84    
85    2005-04-27  Jan-Oliver Wagner <[email protected]>
86    
87            Introduce FileShapeStore as generalization for
88            file-based shape stores. In a first instance
89            this allows additional modules to handle shapefile
90            format as well, namely the OGR extension.
91    
92            * Thuban/Model/data.py: Various small fixes in doc-strings.
93            (FileShapeStore): New class.
94            (ShapefileStore): Derive from FileShapeStore.
95            (ShapefileStore.__init__): Call __init__ of FileShapeStore,
96            rename self.table to self._table, initialize self._bbox
97            (ShapefileStore._open_shapefile): Use self._bbox instead of self.bbox
98            and self.FileName() instead of self.filename.
99            (ShapefileStore.Table): Use self._table instead of self.table.
100            (ShapefileStore.FileName): Removed (moved to FileShapeStore).
101            (ShapefileStore.BoundingBox):  Use self._bbox instead of self.bbox.
102    
103            * Thuban/Model/save.py: Replace ShapefileStore by FileShapeStore.
104            (SessionSaver.write_data_containers): Only use methods of the
105            base class FileShapeStore.
106    
107    2005-04-26  Martin Schulze  <[email protected]>
108    
109            * Extensions/wms/wms.py (render_wms_layer): Adjusted the render
110            function to the modified render engine
111    
112    2005-04-25  Martin Schulze  <[email protected]>
113    
114            * Thuban/UI/renderer.py (MapRenderer.projected_raster_layer):
115            Added a description according to the CVS log message
116    
117    2005-04-23  Martin Schulze  <[email protected]>
118    
119            * Thuban/UI/renderer.py: Added a missing import
120    
121    2005-04-23  Russell Nelson  <[email protected]>
122    
123            * Thuban/UI/view.py (MapCanvas.OnMiddle{Up,Down}): Changed the
124            way the previous tool is remembered, so that middle-button
125            panning works even if you haven't selected a tool.
126    
127    2005-04-11  Bernhard Herzog  <[email protected]>
128    
129            * libraries/thuban/wxproj.cpp: Move the compatibility code that
130            deals with the wxPython 2.4 version of wxPython.h into the #ifdef
131            branch that includes wxPython.h because it's only needed when
132            wxPython.h is used.  Also, it won't compile when
133            USE_WX_PYTHON_SWIG_HACK is set otherwise.
134    
135    2005-04-07  Bernhard Herzog  <[email protected]>
136    
137            * Thuban/UI/classifier.py (ClassGrid.__init__): Use -1 as the ID.
138            (ID_CLASS_TABLE): Removed. It wasn't used anywhere except in
139            ClassGrid.__init__ and it's value is outside of the valid
140            range (must be < 32768).  wxPython 2.5 complains about it with an
141            exception.
142    
143    2005-04-05  Jan-Oliver Wagner <[email protected]>
144    
145            * Doc/manual/thuban-manual-de.xml: More translations.
146    
147    2005-04-05  Bernhard Herzog  <[email protected]>
148    
149            * libraries/thuban/wxproj.cpp: Make it work with a wxPython.h from
150            wxPython 2.4 as well.  Also, remove a now obsolete comment.
151    
152    2005-04-05  Bernhard Herzog  <[email protected]>
153    
154            Use wxPython.h by default but provide a workaround when it isn't
155            available.
156    
157            * setup.py (wxproj_extension): New variable.  Assign the Extension
158            instance for Lib.wxproj to this variable instead of putting it
159            directly into the listso that it can be accessed by other code
160            later.
161            (thuban_build_ext.user_options): Added boolean option
162            --use-wx-python-swig-hack.
163            (thuban_build_ext.initialize_options): Initialize the new option
164            to False.
165            (thuban_build_ext.finalize_options): If the new option was given,
166            define the preprocesser macro USE_WX_PYTHON_SWIG_HACK.
167            (thuban_build_ext): Update the doc-string
168    
169            * libraries/thuban/wxproj.cpp: Normally we use
170            wx/wxPython/wxPython.h now.  Only if USE_WX_PYTHON_SWIG_HACK is
171            defined, use swigPtrConvertHack.h instead.
172    
173            * libraries/thuban/swigPtrConvertHack.h: Remove the code that was
174            copied over from wxPython.h.
175            (decode_pointer_new): New.  Equivalent of decode_pointer for
176            wxPython 2.5.
177            (wxPyConvertSwigPtr): Modified to cope with wxPython 2.5 as well.
178    
179            * README: Add section on potential build problems which explains
180            how the work-around for a missing wxPython.h is activated.
181    
182    2005-03-29  Bernhard Herzog  <[email protected]>
183    
184            * test/postgissupport.py (find_postgis_sql): Added yet another
185            potential location for (lw)postgis.sql because the file has moved
186            again in postgis 1.0.0 rc4.
187    
188    2005-03-29  Bernhard Herzog  <[email protected]>
189    
190            * Thuban/UI/legend.py (BMP_SIZE_W, BMP_SIZE_H): Set both to 16 to
191            match the site of the legend_icon_layer icon.  Otherwise wxpython
192            2.5 complains when the legend is created with the error:
193    
194            PyAssertionError: C++ assertion "(bitmap.GetWidth() == m_width &&
195            bitmap.GetHeight() == m_height) || (m_width == 0 && m_height ==
196            0)" failed in ./src/generic/imaglist.cpp(81): invalid bitmap size
197            in wxImageList: this might work on this platform but definitely
198            won't under Windows.
199    
200    2005-03-23  Jonathan Coles <[email protected]>
201    
202            These changes add support for adjusting the opacity of a raster layer.
203    
204            * Thuban/Model/layer.py (RasterLayer.Opacity): Replaces AlphaOpacity.
205            (RasterLayer.SetOpacity): Replaces SetAlphaOpacity. Also triggers
206            a LAYER_CHANGED event if the opacity actually changes.
207    
208            * Thuban/UI/baserenderer.py (BaseRenderer.draw_raster_data): Added
209            layer parameter needed in the implementation of this method in
210            renderer.py.
211    
212            * Thuban/UI/layerproperties.py (LayerProperties.dialog_layout): Fixed
213            typo 00 -> 0.
214    
215            * Thuban/UI/rasterlayerproperties.py (RasterLayerProperties): Added
216            control to adjust opacity.
217    
218            * Thuban/UI/renderer.py (MapRenderer.draw_raster_data): Scale the
219            alpha data based on the opacity level of the layer.
220    
221            * test/test_baserenderer.py (SimpleRenderer.draw_raster_data): Now
222            accepts a layer parameter.
223    
224            * test/test_layer.py (TestLayerModification.test_raster_layer):
225            Rename opacity method calls and add test for LAYER_CHANGED.
226    
227    2005-03-16  Bernhard Herzog  <[email protected]>
228    
229            * test/test_connector.py (DeletionTestMixin.check_deletions)
230            (DeletionTestMixin.check_deletetions): renamed to check_deletions.
231            update the callers.
232    
233    2005-03-14  Jan-Oliver Wagner <[email protected]>
234    
235            * Doc/manual/thuban-manual-de.xml: More translations.
236    
237    2005-03-10  Jan-Oliver Wagner <[email protected]>
238    
239            Introducing initialization callbacks for extensions.
240    
241            * Thuban/UI/extensionregistry.py (ExtensionDesc.__init__): Added
242            optional parameter init_callback.
243            (ExtensionDesc.init_ext): New. Executes the callback and sets
244            a status.
245    
246            * Thuban/UI/application.py (ThubanApplication.OnInit): Add the
247            initialization of the extensions.
248            (ThubanApplication.init_extensions): Init all extensions.
249    
250            * Thuban/UI/about.py (About.__init__): Added status of the extensions
251            to the about text.
252    
253            * Extensions/gns2shp/__init__.py: Added init method for Extension
254            description.
255            (init): New. Contains the initialization of the module.
256    
257    2005-03-04  Nina H�ffmeyer <[email protected]>
258    
259            * Extensions/ogr/ogrdialog.py: Added a dialog, which asks for
260            OGRConnection to open a datasource. Removed dialog to display all
261            available drivers. Added some doc strings.
262    
263            * Extensions/ogr/ogrstart.py: Added menu entry for opening an
264            OGRDatasource with a string. Added two opening methods which return an
265            OGRDatasource (either data from file or from DB).
266    
267            * Extensions/ogr/ogrshapes.py: Added class OGRGeometry, which
268            represents a geometry reference of an OGRFeature. OGRShape now has a
269            list of referenced geometry objects (important for geometry
270            collections).
271            For OGRShapeStores loaded from a DB an ID column can be specified now.
272    
273    2005-02-22  Jan-Oliver Wagner <[email protected]>
274    
275            * test/test_map.py (TestMapWithContents.test_tree_info):
276            Added label layer for comparison.
277    
278    2005-02-18  Jonathan Coles <[email protected]>
279    
280            * libraries/thuban/gdalwarp.cpp (GetImageData): Optimize the loop
281            which builds a mask. Handle the majority of an image in a loop,
282            creating 8 bits at a time. Later, handle the edge case where less
283            than 8 bits are packed.
284    
285    2005-02-18  Bernhard Herzog  <[email protected]>
286    
287            * test/test_baserenderer.py (TestBaseRenderer.setUp): Fix
288            doc-string
289    
290    2005-02-18  Jonathan Coles <[email protected]>
291    
292            * setup.py: Remove wx_cs_params from gdal compile options.
293    
294    2005-02-18  Jonathan Coles <[email protected]>
295    
296            Refactored baserenderer.py and renderer.py to remove baserenderer.py's
297            dependencies on wxPython. Added a new method projected_raster_layer()
298            that returns a raster layer image in projected space. This must be
299            implemented in classes derived from BaseRenderer. This also eliminates
300            the dependency on gdal in baserenderer.py.
301    
302            * Thuban/UI/baserenderer.py (BaseRenderer.draw_raster_layer): Call
303            new projected_raster_layer() to get projected raster image instead
304            of directly calling ProjectRasterFile().
305            (BaseRenderer.projected_raster_layer): New. This must be implemented
306            by derived classes. It takes almost the same arguments as ProjectRasterFile
307            did and returns a projected image with mask and alpha data (if requested).
308            (BaseRenderer.render_map_incrementally): Remove the check for gdal since
309            that check will be done in MapRenderer.projected_raster_layer(). This
310            also allows other implementations to use different projection code.
311    
312            * Thuban/UI/renderer.py (MapRenderer.projected_raster_layer):
313            Implementation of BaseRenderer.projected_raster_layer. Checks for
314            gdal support and wxPython version. Also handles exceptions from
315            ProjectRasterFile.
316    
317            * libraries/thuban/gdalwarp.cpp: Removed checks for wxPython versions
318            and added a variable which can be set through the options argument
319            of ProjectRasterFile.
320    
321            * test/test_baserenderer.py (SimpleRenderer.projected_raster_layer): New.
322            Calls ProjectRasterFile and returns the result.
323            (TestBaseRenderer.test_projected_raster_layer): New. Tests the results
324            of calling projected_raster_layer() with different options.
325            (TestBaseRenderer.test_raster_no_projection): Removed tests based on
326            wxPython version and all tests of masks and alpha channels. These are
327            now in test_projected_raster_layer().
328    
329    2005-02-17  Jan-Oliver Wagner <[email protected]>
330    
331            * Thuban/Model/map.py, Thuban/Model/label.py: Fixed
332            doc-strings to comply with coding_guidelines.
333    
334    2005-02-17  Jan-Oliver Wagner <[email protected]>
335    
336            Docstring improvements and minor fixes for labellayer.
337    
338            * Thuban/Model/map.py:
339            (Map, Map.Destroy, Map.RemoveLayer, Map.ClearLayers,
340            Map.Layers, Map.HasLayers, Map.MoveLayerToTop,
341            Map.RaiseLayer, Map.LowerLayer, Map.MoveLayerToBottom,
342            Map.ProjectedBoundingBox, Map.GetProjection): Improved/added
343            doc string.
344            (Map.BoundingBox): Removed superfluous test for label_layer
345            and improved doc string.
346            (Map.TreeInfo): Added label_layer and improved sdo string.
347    
348            * Thuban/Model/label.py: Added import of _.
349            (Label, Label.__init__): Improved/added doc string.
350            (LabelLayer, LabelLayer.__init__, LabelLayer.Labels,
351            LabelLayer.RemoveLabel, LabelLayer.ClearLabels):
352            Improved/added doc string.
353            (LabelLayer.AddLabel): Use already defined names for
354            align strings and improved doc string.
355            (LabelLayer.TreeInfo): New. Return the object data for
356            the tree view.
357    
358    2005-02-16  Jonathan Coles <[email protected]>
359    
360            Further wxPython 2.5 changes using patches from Daniel Calvelo Aros
361            so that that wxproj doesn't crash. Added GUI support for selecting
362            alpha channel (opacity can't be selected yet).
363    
364            NOTE: If wxPython.h is including in future distribution packages
365            then it will not be necessary to have the files swigPtrConvertHack.h
366            and wxPython_int.h included with Thuban. This is hopefully
367            a temporary workaround.
368    
369            * setup.py (thuban_build_ext.finalize_options): gdalwarp needs
370            access to the macro wxCHECK_VERSION so that it will properly
371            generate a bit mask. There was a problem between wx2.4 and wx2.5
372            that this works around.
373    
374            * Thuban/Model/layer.py (RasterLayer.UseMask): Removed in favor
375            of RasterLayer.MaskType.
376            (RasterLayer.SetUseMask): Removed in favor of RasterLayer.SetMaskType
377            (RasterLayer.MaskType): New. Returns the type of mask to use. Can
378            specify none, a bitmap, or an alpha channel.
379            (RasterLayer.SetMaskType): New. Set what kind of mask to use.
380    
381            * Thuban/UI/baserenderer.py (BaseRenderer.draw_raster_layer):
382            Set the raster warping options for the mask based on the value
383            of RasterLayer.MaskType.
384    
385            * Thuban/UI/legend.py (LegendTree.__FillTreeLayer): Remove
386            deprecated calls to SetItemSelectedImage in favor of SetItemImage
387            with wxTreeItemIcon_Selected.
388    
389            * Thuban/UI/rasterlayerproperties.py: Support selecting to use
390            an alpha channel for the mask.
391    
392            * Thuban/UI/renderer.py (MapRenderer.draw_raster_data): Use alpha
393            data if it is available and an alpha channel is supported under
394            the current version of wxPython.
395    
396            * libraries/thuban/gdalwarp.cpp (GetImageData): Added compiler define
397            to select whether 1's or 0's select the desired portion of an image
398            in the bit mask. wx2.4 has a bug where the documentation is the opposite
399            from behavior.
400            (ProjectRasterFile): Only generate an alpha channel if the version
401            of wxPython is >= 2.5.3.
402    
403            * libraries/thuban/wxproj.cpp: Applied patches from Daniel Calvelo Aros.
404            When wxPython >= 2.5.3 use the special swig functions to decode an
405            object's address.
406    
407            * libraries/thuban/swigPtrConvertHack.h: Includes conditional code
408            based on the version of wxPython. If >= 2.5.3 use the special swig
409            functions from wxPython to decode wxPython objects, otherwise use
410            the old method of retrieving the address from the object __repr__ string.
411    
412            * libraries/thuban/wxPython_int.h: Copied from wxPython source.
413            Unnecessary code was removed to make it smaller.
414    
415            * test/test_baserenderer.py (TestBaseRenderer.test_raster_no_projection):
416            Add tests for returning an alpha channel.
417    
418            * test/test_layer.py (TestLayerModification.test_raster_layer): Fix
419            tests that used removed functions UseMask and SetUseMask
420    
421    
422    2005-02-08  Bernhard Herzog  <[email protected]>
423    
424            More wxPython 2.5 changes.  This time taken from a patch from
425            Daniel Calvelo Aros.
426    
427            * Thuban/UI/tableview.py (QueryTableFrame.__init__)
428            (QueryTableFrame.__init__): Pass the size of a spacer as a single
429            item.
430    
431            * Thuban/UI/projdialog.py (ProjFrame.build_dialog)
432            (ProjFrame.build_dialog): Pass the size of a spacer as a single
433            item.
434    
435            * Thuban/UI/dbdialog.py (ChooseDBTableDialog.__init__): Pass the
436            size of a spacer as a single item.
437    
438            * Thuban/UI/classifier.py (Classifier.dialog_layout): Pass the
439            size of a spacer as a single item.
440    
441    2005-02-08  Bernhard Herzog  <[email protected]>
442    
443            Compatibility with wxPython 2.5.  The changes should make it work
444            better with 2.5 while still keeping compatibility with 2.4.  There
445            are still problems with 2.5, though.
446    
447            * Thuban/UI/dock.py (DockableWindow.__CreateBorder): Pass the size
448            of a spacer as a single item.
449    
450            * Thuban/UI/classifier.py (ClassGroupPropertiesCtrl): Derive only
451            from wxControl
452    
453            * Thuban/UI/legend.py (LegendTree): When running with wxPython <
454            2.5, add an implementation of the GetFirstChild method that does
455            not require the second parameter.
456            (LegendTree.find_layer, LegendTree._OnMsgMapLayersAdded)
457            (LegendTree._OnMsgMapLayersRemoved, LegendTree.DeleteAllItems)
458            (LegendTree.DeleteChildren, LegendTree.__ShowHideLayer): Do not
459            pass the second parameter to GetFirstChild
460    
461    2005-02-08  Nina H�ffmeyer <[email protected]>
462    
463            * Extensions/ogr/ogrshapes.py: Removed some print commands.
464    
465            * Extensions/ogr/ogrstart.py: Changed the GUI. OGR is no longer an
466            additional menu but appears as a possibility in the menu Map.
467    
468    2005-02-07  Jonathan Coles <[email protected]>
469            * libraries/thuban/gdalwarp.cpp: Removed the macros PYTHON_ERR
470            and PYTHON_ERRF since they were no longer necessary.
471    
472  2005-02-07  Bernhard Reiter <[email protected]>  2005-02-07  Bernhard Reiter <[email protected]>
473          * Thuban/UI/classifier.py (ClassGrid.DeleteSelectedRows):          * Thuban/UI/classifier.py (ClassGrid.DeleteSelectedRows):
474          Enable translation for message string.          Enable translation for message string.

Legend:
Removed from v.2556  
changed lines
  Added in v.2623

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26