/[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 924 by frank, Mon May 19 09:12:42 2003 UTC revision 2211 by jan, Sun May 16 09:50:09 2004 UTC
# Line 1  Line 1 
1    2004-05-16  Jan-Oliver Wagner <[email protected]>
2    
3            Finished introduction of Menu.FindOrInsertMenu.
4    
5            * Extensions/drawshape/drawshape.py: Add the command
6            to the experimental menu additionally to the toolbar.
7    
8            * Extensions/svgexport/svgsaver.py: Use FindOrInsertMenu() instead of
9            finding menu on its own.
10    
11            * Doc/manual/thuban-manual.xml: updated sample file
12            to use FindOrInsertMenu().
13    
14            * Examples/simple_extensions/hello_world.py: Use FindOrInsertMenu()
15            instead of finding menu on its own.
16    
17    2004-05-11  Jan-Oliver Wagner <[email protected]>
18    
19            * test/test_menu.py (MenuTest.test): Added testing
20            of method Menu.FindOrInsertMenu.
21    
22    2004-05-10  Jan-Oliver Wagner <[email protected]>
23    
24            Introduce and use Menu.FindOrInsertMenu.
25    
26            * Thuban/UI/menu.py (Menu.FindOrInsertMenu): New. Find a
27              given menu or, if not found, insert it.
28    
29            * Extensions/bboxdump/bboxdump.py, /Extensions/gns2shp/gns2shp.py,
30            /Extensions/importAPR/importAPR.py, Extensions/profiling/profiling.py,
31            /Extensions/wms/wms.py: Use FindOrInsertMenu() instead of finding
32            menu on its own.
33    
34    2004-05-06  Jan-Oliver Wagner <[email protected]>
35    
36            Introduce a abstract ColorDialog class and remove
37            and outdated file.
38    
39            * Thuban/UI/proj4dialog.py: Removed. It is has been
40            replaced by projdialog for quite a while and is not used
41            anymore.
42    
43            * Thuban/UI/colordialog.py: New. Abstraction for color selection
44            dialog(s).
45    
46            * Thuban/UI/classifier.py (SelectPropertiesDialog.__GetColor):
47            Now calls the abstract ColorDialog instead of wxColourDialog.
48            This also removed the dependency to Color class conversion
49            from this function.
50    
51    2004-05-04  Frank Koormann  <[email protected]>
52    
53            * Extensions/bboxdump/__init__.py: Fixed string left over from
54            copying.
55    
56            * Extensions/bboxdump/bboxdump.py (bboxdump):
57            Use layer.ShapeStore().AllShapes() to loop over shapes instead of
58            xrange(layer.NumShapes()). Compile the bboxmessage from a list
59            of formatted outputs (string.join) instead of appending to the
60            message. Two progress bar dialogs to report progress on the sometimes
61            lenghty processing.
62    
63    2004-04-22  Frank Koormann  <[email protected]>
64    
65            New Extension to dump bounding boxes of all shapes of the selected
66            layer. An optional column can be specified to group the objects,
67            in this case the bounding box is a union of the separate boxes.
68            Dump can be displayed in a ScrolledMessageDialog or written to file.
69            The Extension is simply a combination of available and well tested
70            Thuban functionality.
71    
72            * Extensions/bboxdump/__init__.py: New: Init to make this
73            directory a package.
74    
75            * Extensions/bboxdump/bboxdump.py: New: Dump bounding boxes of
76            all shapes of the selected layer.
77    
78    2004-04-22  Jan-Oliver Wagner <[email protected]>
79    
80            * Thuban/UI/classgen.py (GenUniquePanel.__init__): Fixed two
81            strings to be i18n now.
82    
83    2004-04-18  Jan-Oliver Wagner <[email protected]>
84    
85            Changing popup menu of legend from direct building
86            to using the Menu construction as used for the mainwindow.
87    
88            * Thuban/UI/mainwindow.py: New method commands: layer_to_top,
89            layer_to_bottom, layer_visibility
90            (MainWindow.LayerToTop): New. Put current layer to the top.
91            (MainWindow.LayerToBottom): New. Put current layer to bottom.
92            (MainWindow.HideLayer, MainWindow.ShowLayer, _has_visible_map):
93            Replace 1,0 by True, False.
94            (MainWindow.ToggleLayerVisibility): New. Toggle visibility of
95            current layer.
96            (MainWindow.LayerShowTable): Removed raising of dialog.
97            (_has_selected_layer_visible): New. Support function.
98    
99            * Thuban/UI/legend.py: ID_POP_xxx: removed.
100            (LegendPanel.__init__): Removed EVT_MENU bindings.
101            (LegendTree._OnRightClick): Replace direct creation of
102            menu via wx Classes by applying the menu definition
103            as of Menu class of menu.py.
104            
105    2004-04-16  Jan-Oliver Wagner <[email protected]>
106    
107            * Thuban/UI/exceptiondialog.py (ExceptionDialog.dialog_layout): Improved
108        button string to stronger clearify that Thuban will be closed when hitting
109            the button.
110    
111            * Thuban/UI/mainwindow.py (MainWindow.LayerShowTable): Added docstring.
112            Now for layers without a ShapeStore a corresponding message is given
113            to the user, that this layer has no table to show.
114    
115    2004-04-15  Martin Schulze  <[email protected]>
116    
117            * Extensions/wms/layer.py (WMSLayer.setWMSFormat): Need to
118            recalculate the format for the internal render engine as well.
119    
120            * Extensions/wms/properties.py (wmsProperties): First start for a
121            properties dialog.  It's functional for a first selection of
122            layers, but still has some weired wxWidgets/GTK problems but
123            beautification can be done later.
124    
125            * Extensions/wms/layer.py: Added more documentation
126            (WMSLayer.getFormats): New: Return list of supported image formats
127            by the WMS server
128            (WMSLayer.getLayers): New: Return the list of layer names
129            supported by the WMS server
130            (WMSLayer.getLayerTitle): New: Return the title of the named layer
131            (WMSLayer.getWMSFormat): New: Return the image format that is used
132            for WMS GetMap requests
133            (WMSLayer.setWMSFormat): New: Set the image format that is used
134            for WMS GetMap requests
135            (WMSLayer.__init__): Move away from using only one layer to using
136            a list of layers (unsorted at the moment, though).
137            (WMSLayer.getVisibleLayers): New: Return the list of names for all
138            visible layers
139            (WMSLayer.setVisibleLayers): New: Set the list of names for all
140            visible layers
141    
142            * Extensions/wms/wms.py: Moved the WMS layer into layer.py in
143            order to establish a clean structure.
144    
145            * Extensions/wms/layer.py: Moved the WMS layer into a file on its
146            own in order to establish a clean structure.
147    
148    2004-04-13  Martin Schulze  <[email protected]>
149    
150            * Extensions/wms/parser.py (WMSCapabilitiesParser.grok): Added
151            support for oldstyle (WMS 1.0 apparently) image format
152            specification.
153    
154            * Extensions/wms/wms.py (WMSLayer.calcFormat): Reduce the list of
155            supported graphic formats back to JPEG and BMP, PNG and others are
156            too *cough* experimental...  Sorry, I meant to filter this out
157            before I committed this part.  This should make the WMS extension
158            run from CVS again.
159            (wms_dialog): Reset an empty URL to None so that the subsequent
160            program can depend on this, since the dialog will indeed return an
161            empty URL, causing another declaration of love by Python.
162    
163            * Extensions/wms/parser.py (WMSCapabilitiesParser.getLayerBBox):
164            Whenever a native BoundingBox request cannot be fulfilled, check
165            whether the requested SRS is EPSG:3426, in which case return the
166            LatLonBoundingBox values.
167    
168            * Extensions/wms/test/test_parser.py
169            (TestWMSCapabilitiesParser.test_LayerSRS): Added a test for
170            ignoring AUTO:* SRS.
171            (TestWMSCapabilitiesParser.test_LatLonBoundingBoxes_as_bboxes):
172            Added another test method to test whether the LatLonBoundingBox
173            values will be returned if BoundingBox values are requested with
174            SRS set to EPSG:3426.
175    
176            * Extensions/wms/parser.py (WMSCapabilitiesParser.peekLayers):
177            Added rudimentary support for non-EPSG SRS, i.e. ignore them for
178            the moment by placing them into a variable which is currently
179            unused.  Also test whether the EPSG SRS is numerical as it should
180            be and add an error message if it is not.
181    
182            * Extensions/wms/test/sample.xml: Added AUTO:* SRS since they
183            appear in the real world as well.  Since we cannot handle them yet
184            (OGCLib can't either), we will ignore them for the moment.
185    
186            * Extensions/wms/parser.py: Use a variable for denoting the sample
187            filename
188            (WMSCapabilitiesParser.peekLayers): Added support for error
189            messages during grok().  They will be aggregated in an array and
190            may be displayed later.  We may have to add a classification
191            "Warning" and "Error" to this.  That requires more experience,
192            though, since not every error may be lethal.
193    
194            * Thuban/UI/mainwindow.py (MainWindow.LayerShowTable): Raise the
195            ShowTable() dialog/frame when the user attempts to display it
196            while it has been opened before already and not closed again.
197    
198    2004-04-11  Martin Schulze  <[email protected]>
199    
200            * Extensions/wms/infodialog.py: Adjusted the class documentation
201    
202            * Extensions/wms/wms.py (WMSLayer.__init__, WMSLayer.GetMapImg):
203            Switch to using Thuban{Begin,End}BusyCursor instead of the pure
204            wxWidgets variants.
205            (WMSLayer.__init__): The epsg_id variable is named top_srs now.
206    
207            * Extensions/wms/infodialog.py: Added an information dialog that
208            will display various information about the WMS current resource,
209            so that additional information such as the title, the abstract,
210            fees and access constraints can be displayed for the user if they
211            are documented in the WMS XML.
212    
213    2004-04-10  Martin Schulze  <[email protected]>
214    
215            * Extensions/wms/parser.py (WMSCapabilitiesParser.grok): Adjusted
216            string handling.  It's "foo".lower() and not lower(foo) without
217            lower imported from strings or something.
218    
219            * Extensions/wms/wms.py (WMSLayer): Incorporated WMSCapabilities
220            from capabilities.py and parser.py.  Implement priority list for
221            supported graphics formats, take care of wbmp != bmp.  PNG, TIFF
222            and GIF are supported here, but not yet by main Thuban.  Hence,
223            support for them may be removed later.  Special contribution to
224            usability: get wxWidgets to change the cursor when we're waiting
225            for data from the network so the user won't start to worry.  This
226            causes a redrawing error/warning, though.
227    
228            * Extensions/wms/parser.py (WMSCapabilitiesParser.grok): Unlink
229            the DOM object.
230    
231    2004-04-01  Martin Schulze  <[email protected]>
232    
233            * Extensions/wms/capabilities.py: Adjusted documentation
234            (WMSCapabilities.__init__): Improved documentation, fixed syntax
235            (WMSCapabilities.saveCapabilities): Only catch IOError when
236            handling files
237            (WMSCapabilities.loadCapabilities): Only catch IOError when
238            handling files
239            __main__: corrected variable naming
240            (WMSCapabilities.fetchCapabilities,loadCapabilities): Make this
241            class a specialisation of WMSCapabilitiesParser as well.  Also
242            execute grok() after loading or fetching capabilities, if that
243            went well, so that subsequent calls can already access the data.
244            (WMSCapabilities.getVersion): Export the used version of the
245            GetCapabilities request, so we can use it for subsequent calls,
246            i.e. for GetMap requests.
247            (WMSCapabilities.fetchCapabilities): Added proper error handling
248            when the GetCapabilities request failed, so that the surrounding
249            program can act accordingly.
250    
251    2004-03-30  Martin Schulze  <[email protected]>
252    
253            * Extensions/wms/parser.py (WMSCapabilitiesParser.getLayerSRS):
254            Adjusted the getLayerSRS method to return the list of SRSes
255            extracted from <SRS> elements instead of <BoundingBox> elements.
256            Added a bit of documentation as well.
257            (WMSCapabilitiesParser.checkLayerSRS): Removed integrity test
258            since it was only implemented due to a misunderstanding.
259    
260            * Extensions/wms/test/test_parser.py
261            (TestWMSCapabilitiesParser.test_LayerSRS): Adjust the tests to
262            reflect the corrected interpretation of the standard: i.e. a layer
263            does not have to define a BoundingBox for all SRSes it supports.
264            Hence the <SRS></SRS> specification is authoritative, not the list
265            of BoundingBoxes.
266            (TestWMSCapabilitiesParser.test_BoundingBoxes): Added a new test
267            to ensure None is returned for a non-existing SRS.
268            (TestWMSCapabilitiesParser.test_grok): Removed test_grok method
269            since it is not applicable anymore.  Listing more SRSes in <SRS>
270            elements is valid according to the specs.
271    
272    2004-03-26  Bernhard Reiter <[email protected]>
273    
274            * README: Nicer formatting of text. Improved descriptions.
275            Reflected wxWidgets name change.
276            
277            * Thuban/UI/about.py: Extended copyright to 2004 and added
278            information about the thuban-devel mailinglist.
279    
280    2004-03-24  Martin Schulze  <[email protected]>
281    
282            * Extensions/wms/capabilities.py: Renamed the class to contain
283            'WMS', also added a linebreak where required
284    
285            * Extensions/wms/parser.py: Finally added the XML parser for the
286            GetCapabilities response.
287    
288            * Extensions/wms/test/sample.xml: Adjusted the sample file so that
289            <SRS> elements match the <BoundingBox> elements, except for the
290            layer 'beschriftung'.
291    
292            * Extensions/wms/test/test_parser.py: Encode non-ascii strings
293            since Python uses unicode strings internally, otherwise
294            comparisons will fail.  Removed tests for getLayerBBoxSRS() since
295            the SRS will be calculated anyway and this method is obsoleted by
296            getLayerSRS().  Denote SRS as strings and not as cardinal numbers.
297            Move loading the sample file into the setUp method.  Added a test
298            for finding the integrity problem in the sample response.
299            Improved formatting.
300    
301            * Extensions/wms/domutils.py: Added convenience routines for
302            handling of Document Object Model (DOM) nodes.
303    
304            * Extensions/wms/test/test_domutils.py: Added a test for the
305            domutils module
306    
307    2004-03-19  Martin Schulze  <[email protected]>
308    
309            * Extensions/wms/test/test_parser.py (TestWMSCapabilitiesParser):
310            Moved path detection and adding into a module of its own,
311            adjustpath, which exports thubandir as main Thuban directory.
312    
313            * Extensions/wms/test/test_ogclib.py (TestWMSLib): Moved path
314            detection and adding into a module of its own, adjustpath, which
315            exports thubandir as main Thuban directory.  Reorganised the
316            module in order to support the SkipTest feature for Thuban test
317            cases.
318    
319            * Extensions/wms/test/adjustpath.py: Moved path detection and
320            adding into a module of its own.
321    
322    2004-03-18  Martin Schulze  <[email protected]>
323    
324            * Extensions/wms/test/test_parser.py: Added another test for
325            checking whether the WMS XML parser (to be implemented) returns
326            the information we expect.  This requires a sample WMS WML file
327            (sample.xml) which has been extracted from the frida server and
328            "improved" manually.
329    
330            * Extensions/wms/test/test_ogclib.py: Added legacy code to add the
331            main Thuban directory to the path in order to be able to import
332            random modules.  Adjusted the PyOGCLib detection to reuse the
333            information gathered.  Also added a note about the PYTHONPATH
334            environment variable.
335    
336            * Extensions/wms/test/test_ogclib.py: The format specification is
337            a mime-type, not a graphic format, hence image/jpeg wou ld be the
338            proper format and not JPEG.  We'll also have to take care of the
339            encoding of / as %2F.
340    
341    2004-03-16  Martin Schulze  <[email protected]>
342    
343            * Extensions/wms/test/test_ogclib.py: Added a (hopefully)
344            comprehensive test for the getMapURL method, built compare URLs
345            according to the documentation in OGC 01-068r3
346    
347            * Extensions/wms/capabilities.py (WMSCapabilities): Added the
348            class WMSCapabilities to manage capabilites, will incorporate
349            parsing the capabilities response and provide details for other
350            classes.
351    
352    2004-03-12  Bernhard Herzog  <[email protected]>
353    
354            Support views in addition to normal tables in the postgis
355            shapestore
356    
357            * Thuban/Model/postgisdb.py
358            (PostGISShapeStore._fetch_table_information): Add a fallback for
359            the case where the table name is not in the geometry_columns
360            table.  This is usually the case for views.  Also, set
361            self.shapestore here.
362            (PostGISShapeStore.ShapeType): No need to query the database all
363            the time.  The shape type is now determined in
364            _fetch_table_information
365    
366            * test/postgissupport.py (PostgreSQLServer.new_postgis_db)
367            (PostgreSQLServer.get_static_data_db, PostGISDatabase.__init__):
368            New parameter to specify views.
369            (PostGISDatabase.has_data): Also compare the views.  New views
370            parameter
371            (PostGISDatabase.initdb): Create the views.
372            (PostgreSQLServer.get_default_static_data_db): Add the v_landmarks
373            view
374    
375            * test/test_postgis_db.py
376            (TestPostGISShapestorePointFromViews): New.  Test a
377            PostGISShapeStore with a view
378            (TestPostGISShapestorePointOIDAsGIDColumn.setUp): Pass the name of
379            the geometry_column explicitly to test whether that works
380    
381    2004-03-12  Bernhard Herzog  <[email protected]>
382    
383            Final step for explicit id/geometry columns: Loading and saving
384    
385            * Resources/XML/thuban-1.1.dtd: New.  Derived from thuban-1.0.dtd
386            with the following changes:
387            (dbshapesource): Two new attributes id_column and geometry_column
388    
389            * Thuban/Model/save.py (SessionSaver.write): Use the new dtd
390            (SessionSaver.write_session): Use the new namespace
391            (SessionSaver.write_data_containers): Write the new dbshapesource
392            parameters
393    
394            * Thuban/Model/load.py (SessionLoader.__init__): New namespace for
395            the new file format version
396            (SessionLoader.start_dbshapesource): Handle the new db parameters
397    
398            * test/test_save.py: Update to the new dtd and namespace
399            (SaveSessionTest.test_save_postgis): Update the NonConnectionStore
400            mock object to provide a working IDColumn method.
401    
402            * test/test_load_1_0.py: New.  Copy of the test_load.py before
403            today's changes but with the round-trip tests removed.
404    
405            * test/test_load_0_9.py: Update doc-string.
406    
407            * test/test_load.py: Update all .thuban files to the new dtd and
408            namespace.
409            (TestPostGISLayer.file_contents): Add the new dbshapesource
410            paramters
411    
412    2004-03-11  Bernhard Herzog  <[email protected]>
413    
414            Next step for explicit id/geometry columns: User interaction
415    
416            * Thuban/UI/dbdialog.py (ChooseDBTableDialog.__init__): Rework how
417            the dialog is constructed. Add combo boxes to select id and
418            geometry column.  Rename some instance variables.
419            (ChooseDBTableDialog.GetTable): Return id and geometry column
420            names
421            (ChooseDBTableDialog.OnTableSelect): New. Event handler for
422            selections in the table list
423    
424            * Thuban/UI/mainwindow.py (MainWindow.AddDBLayer): Use id_column
425            and geometry_column
426    
427            * Thuban/Model/session.py (Session.OpenDBShapeStore): Add the new
428            parameters for id_column and geometry column of PostGISShapeStore
429            here as well.
430    
431            * Thuban/Model/postgisdb.py (type_map): Add ROWID psycog type.
432            (_raw_type_map): New. Map raw PostgreSQL type ints to thuban types
433            (PostGISConnection.GeometryTables): Use a better query to
434            determine which relations in the database might be usable for
435            shapestores.  Now supports views as well but is more PostgreSQL
436            specific
437            (PostGISConnection.table_columns): New. Somewhat experimental
438            method to let the db dialogs provide lists of columns to users so
439            that they can select id and geometry columns.
440            (PostGISTable.__init__): The default value of the id_column
441            parameter is now None it still means "gid" effectively, though.
442            (PostGISTable.IDColumn): New introspection method to return a
443            column object for the id column
444            (PostGISShapeStore.GeometryColumn): New introspection method to
445            return a column object for the geometry column
446    
447            * test/test_postgis_db.py
448            (TestPostGISConnection.test_gis_tables_non_empty):
449            Removed. Subsumed by the new:
450            (TestPostGISConnection.test_gis_tables_with_views_and_tables):
451            New. Tes the GeometryTables and table_columns methods with actual
452            tables and views.
453            (PointTests.test_id_column, PointTests.test_geometry_column):
454            New. tests for the new methods.
455            (TestPostGISShapestorePoint.setUp)
456            (TestPostGISShapestorePointSRID.setUp)
457            (TestPostGISShapestorePointExplicitGIDColumn.setUp): Fill the
458            instance variables needed by the new tests
459    
460    2004-03-11  Bernhard Herzog  <[email protected]>
461    
462            * Thuban/UI/classgen.py (GenQuantilesPanel.GetList): The row
463            numbers given to ReadValue are ordinals.
464    
465    2004-03-11  Bernhard Herzog  <[email protected]>
466    
467            Elimiate the requirement for PostGIS tables to have a column
468            called "gid".
469    
470            * Thuban/Model/postgisdb.py (PostGISTable.__init__): New parameter
471            id_column to specify which column to use to identify rows.  Also
472            new instance variables id_column and quoted_id_column
473            (PostGISTable.RowIdToOrdinal, PostGISTable.RowOrdinalToId)
474            (PostGISTable.ReadRowAsDict, PostGISTable.ReadValue)
475            (PostGISTable.SimpleQuery): Use the id column name provided to the
476            constructor instead of "gid"
477            (PostGISShapeStore.__init__): New parameter id_column analogously
478            to PostGISTable.__init__.  This parameter is simply passed through
479            to the base class constructor
480            (PostGISShapeStore._create_col_from_description): Fix typo in
481            doc-string
482            (PostGISShapeStore.Shape, PostGISShapeStore.AllShapes)
483            (PostGISShapeStore.ShapesInRegion): Use the id column name
484            provided to the constructor instead of "gid"
485    
486            * test/postgissupport.py
487            (PostgreSQLServer.get_default_static_data_db): New static table
488            landmarks_point_id with an id column != "gid.  Update the comments
489            a bit.
490            (skip_if_addgeometrycolumn_does_not_use_quote_ident): Fix typo in
491            doc-
492            (upload_shapefile): New parameter gid_column to use a name other
493            than "gid" for the column to store the shape ids
494    
495            * test/test_postgis_db.py (TableTests): New.  Mixin-class
496            containing all tests previously in TestPostGISTable.  The actual
497            tests are the same but the code is a bit more configurable to
498            allow for different id columns etc.
499            (TestPostGISTable): Derive from TableTests now for the actual
500            tests.
501            (TestPostGISTableExplicitGIDColumn): New. Like TestPostGISTable
502            except that it the landmarks_point_id table to test the id_column
503            parameter
504            (PointTests): Extend the doc-string
505            (TestPostGISShapestorePointExplicitGIDColumn)
506            (TestPostGISShapestorePointOIDAsGIDColumn): New classes derived
507            from PointTests to test the explicit id_column parameter.  One
508            tests with the name of the column holding the shape ids, the other
509            uses PostgreSQL's OID column.  For the latter a number of methods
510            have to be overwritten to make them independent of the actual id
511            values.
512    
513    2004-03-08  Silke Reimer  <[email protected]>
514    
515            Update debian directory:
516    
517            * debian/changelog: Added new version.
518            * deiban/rules: Updated management of patches (with cbds)
519            * debian/control: Added cbds to dependencies
520            * debian/patches/*: New. Adds better support for patches of thuban in
521                            debian
522            * debian/menu: Syntax of menu changed slightly
523            * debian/setup.py.patch: removed because it has been moved to
524                            debian/patechs/setup.py.patch
525            
526    
527    2004-02-26  Bernhard Herzog  <[email protected]>
528    
529            Create the Doc/technotes directory for text files with information
530            for developers
531    
532            * Doc/technotes/README: New. README for the technotes
533    
534            * Doc/technotes/coding_guidelines.txt: New. Coding guidelines for
535            Thuban
536    
537            * Doc/technotes/release_process.txt: New. Used to be
538            HOWTO-Release.  Now slightly adapted to technote formatting style.
539    
540            * HOWTO-Release: Removed.  It's contents are now in
541            Doc/technotes/release_process.txt
542    
543    2004-02-25  Bernhard Herzog  <[email protected]>
544    
545            * libraries/thuban/wxproj.cpp (get_wx_version): New.  Return the
546            version of wxWindows the module was compiled with so we can check
547            that against the wxPython version.
548    
549            * Thuban/version.py (thuban_branch, thuban_release): New variables
550            controlling which and how Thuban versions are shown.  See the
551            comments for details.
552            (verify_versions): Also check that the wx version that wxproj is
553            compiled against matches that of the wxPython we use at runtime
554    
555    2004-02-20  Bernhard Herzog  <[email protected]>
556    
557            * Extensions/wms/wms.py (epsg_code_to_projection): Use
558            get_system_proj_file to read the epsg projections.  The old way
559            depended on the current directory being the top Thuban directory.
560    
561    2004-02-20  Bernhard Herzog  <[email protected]>
562    
563            * Extensions/svgexport/test/test_svgmapwriter.py
564            (TestVirtualDC.test_clippath): Remove a debug print
565    
566    2004-02-20  Bernhard Herzog  <[email protected]>
567    
568            * Extensions/svgexport/__init__.py: New.  Turn
569            Extensions/svgexport into a package.
570    
571            * Extensions/svgexport/svgmapwriter.py: Reorder the imports and
572            doc-string a bit.  The doc-string must come first, otherwise it's
573            not a doc-string.  The __future__ import must be the first thing
574            after the doc-string.  Use only double quotes in doc-strings.
575            Single quotes trip up emacs syntax highlighting if the text
576            contains apostrophes.
577    
578    2004-02-20  Bernhard Herzog  <[email protected]>
579    
580            * Extensions/svgexport/test/__init__.py,
581            Extensions/svgexport/test/test_svgmapwriter.py: New. Initial test
582            suite for svgexport
583    
584            * test/runtests.py (find_test_modules): New. Function with the
585            module finding code from main.
586            (main): Use find_test_modules to figure out the default test
587            modules and take modules from Extensions.svgexport.test too.
588    
589    2004-02-19  Bernhard Herzog  <[email protected]>
590    
591            * Thuban/UI/application.py (ThubanApplication.OnInit): Make sure
592            the mainwindow has a reference to the map of the initial session.
593            This fixes a bug introduced with the fix for RT#2245
594    
595    2004-02-19  Bernhard Herzog  <[email protected]>
596    
597            * Extensions/svgexport/svgsaver.py,
598            Extensions/svgexport/svgmapwriter.py,
599            Extensions/svgexport/maplegend.py: Added again.  This time in the
600            correct place.
601    
602    2004-02-17  Bernhard Herzog  <[email protected]>
603    
604            Fix for RT#2245
605    
606            * Thuban/UI/application.py (ThubanApplication.OnInit): Initialize
607            instance variables before trying to create any windows.  Creating
608            windows can start an event loop if e.g. message boxes are popped
609            up for some reason, and event handlers, especially EVT_UPDATE_UI
610            may want to access things from the application.
611            (ThubanApplication.maps_changed): The mainwindow may not have been
612            created yet, so check whether it has been created before calling
613            its methods
614    
615            * Thuban/UI/view.py (MapCanvas.OnIdle): Only try to redraw if we
616            have a map
617    
618    2004-02-17  Bernhard Herzog  <[email protected]>
619    
620            * test/test_svgmapwriter.py, Extensions/svgsaver.py,
621            Extensions/svgmapwriter.py, Extensions/maplegend.py,
622            extensions/svgexport/svgsaver.py,
623            extensions/svgexport/svgmapwriter.py,
624            extensions/svgexport/maplegend.py: Removed.  These files were in
625            the wrong places or didn't work at all.
626    
627    2004-02-16  Bernhard Herzog  <[email protected]>
628    
629            * Thuban/UI/view.py (MapCanvas.Export): Remove accidentally added
630            line
631    
632    2004-02-16  Bernhard Herzog  <[email protected]>
633    
634            * Thuban/UI/view.py (MapCanvas.Export): Avoid UnboundLocalError.
635    
636    2004-02-15  Markus Rechtien  <[email protected]>
637            
638            * Extensions/svgexport/svgmapwriter.py: New. Adds the capability
639            to write a session to a file in SVG format.
640            * Extensions/svgexport/svgsaver.py: New. Uses svgmapwriter.py
641            to write a SVG map of a session.
642            * Extensions/svgexport/maplegend: New. Writes a basic maplegend
643            in SVG format for the current session.
644    
645    2004-02-13  Bernhard Herzog  <[email protected]>
646    
647            * Thuban/UI/mainwindow.py (MainWindow.AddDBLayer): When the layer
648            can't be created, return immediately after displaying the error
649            message.
650    
651    2004-02-11  Bernhard Herzog  <[email protected]>
652    
653            Handle postgis tables with more than one geometry column.
654    
655            * Thuban/Model/postgisdb.py
656            (PostGISTable._fetch_table_information): Delegate the creation of
657            column objects to a different method so that we can extend that in
658            derived classes
659            (PostGISTable._create_col_from_description): New. Column object
660            creation part of _fetch_table_information
661            (PostGISShapeStore._create_col_from_description): New. Extend
662            inherited method to handle geometry columns
663            (PostGISShapeStore.__init__): New parameter geometry_column to
664            specify which geometry column to use.  Optional but mandatory for
665            tables with more than one geometry column
666            (PostGISShapeStore._fetch_table_information): Also use the name of
667            the geometry column when looking for the srid
668            (PostGISShapeStore.ShapeType): Also use the name of the geometry
669            column when looking for the shape type
670    
671            * test/test_save.py (SaveSessionTest.test_save_postgis): Adapt
672            NonConnectionStore to changes in the PostGISShapeStore
673    
674            * test/test_postgis_db.py
675            (TestPostGISSpecialCases.test_shapestore_two_geom_cols): Test
676            PostGISShapeStore with tables having two geometry columns.
677    
678    2004-02-10  Bernhard Herzog  <[email protected]>
679    
680            Fix some postgis problems.  What remains to be done is real
681            handling of SRIDs as they affect how reprojection is done
682    
683            * Thuban/Model/postgisdb.py (quote_identifier): Fix typo in
684            doc-string
685            (PostGISShapeStore._fetch_table_information): New. Extend
686            inherited method to retrieve srid
687            (PostGISShapeStore.BoundingBox): Handle tables without data.
688            extent yields NULL for those
689            (PostGISShapeStore.ShapesInRegion): Use the srid of the table.
690    
691            * test/test_postgis_db.py
692            (TestPostGISSpecialCases.test_shapestore_empty_table): New test
693            for the special case of a table without any data
694            (TestPostGISShapestorePointSRID): New class with tests for a table
695            that uses srids
696            (PolygonTests): Fix a doc-string typo
697    
698            * test/postgissupport.py (PostGISDatabase.__init__): New parameter
699            reference_systems with a specification of spacial reference
700            systems to create in the new db.
701            (PostgreSQLServer.new_postgis_db)
702            (PostgreSQLServer.get_static_data_db): New parameter
703            reference_systems to be passed through ultimately to
704            PostGISDatabase.  In new_postgis_db also check whether an existing
705            db already has the right srids
706            (PostgreSQLServer.get_default_static_data_db): Add srids and a
707            table that uses srids
708            (PostGISDatabase.initdb): Create the entries for the reference
709            systems
710            (PostGISDatabase.has_data): Add reference_systems parameter to
711            check for those too
712            (upload_shapefile): New parameter srid to create tables with a
713            specific srid
714    
715    2004-02-06  Frank Koormann  <[email protected]>
716    
717            * po/pt_BR.po: Fixed charset
718    
719    2004-02-05  Frank Koormann  <[email protected]>
720    
721            * po/pt_BR.po: Fixed format string for error message, missing %s
722            added (Thuban/UI/application.py:273)
723    
724    2004-02-03  Frank Koormann  <[email protected]>
725            
726            First version of Portuguese (Brazilian) translation
727    
728            * po/pt_BR.po: New, translation of pot (2004-01-15 16:07+0300) for
729            Brazilian Portuguese by Eduardo Patto Kanegae.
730    
731            * Thuban/UI/about.py (About.__init.py__): Added Eduardo to the list of
732            translators.
733    
734    
735    2004-01-22  Frank Koormann  <[email protected]>
736    
737            * Doc/manual/thuban-manual.xml: Added section on installation of
738            Thuban under Win32 systems. Fixed image path references in the postgis
739            section. Some minor source formattings.
740    
741    2004-01-21  Frank Koormann  <[email protected]>
742    
743            Make Thuban remember path selections (at least for one application run).
744    
745            * Thuban/UI/application.py (Application.OnInit): Initialize path as a
746            attribute of application object. Path is a dictionary of
747            strings, currently with the items "data" and "projection".  
748            (Application.SetPath): New, stores path for the specified item.
749            (Application.Path): New, return path for the specified item.
750    
751            * Thuban/UI/mainwindow.py
752            (MainWindow.OpenSession, MainWindow.SaveSessionAs,
753            MainWindow.AddLayer, MainWindow.AddRasterLayer,
754            MainWindow.TableOpen): Access "data" path information of the
755            application.
756            
757            * Thuban/UI/projdialog.py (ProjFrame._OnImport, ProjFrame._OnExport):
758            Access "projection" path information of the application.
759    
760    2004-01-05  Bernhard Herzog  <[email protected]>
761    
762            * po/ru.po: Updated translations from Alex Shevlakov
763    
764    2004-01-05  Bernhard Herzog  <[email protected]>
765    
766            * po/Makefile, po/README: Move the description of how to generate
767            the translation statistics to the README.
768    
769    2003-12-23  Bernhard Herzog  <[email protected]>
770    
771            * NEWS: Update for 1.0.0
772    
773            * po/it.po: Another update from Maurizio Napolitano
774    
775    2003-12-23  Bernhard Herzog  <[email protected]>
776    
777            * po/it.po: Updated translation from Maurizio Napolitano
778    
779    2003-12-23  Bernhard Herzog  <[email protected]>
780    
781            * Thuban/UI/join.py (JoinDialog.__init__): Mark one more string
782            for translation
783    
784            * Thuban/UI/mainwindow.py (MainWindow.TableRename)
785            (MainWindow.RenameMap, MainWindow.RenameLayer): Mark some more
786            strings for translation
787    
788            * po/de.po: Update with the newly marked strings.
789    
790    2003-12-22  Bernhard Herzog  <[email protected]>
791    
792            * HOWTO-Release: Fix the places where version numbers have to be
793            updated
794    
795    2003-12-22  Bernhard Herzog  <[email protected]>
796    
797            * setup.py (setup call): 1.0.0, yeah!
798    
799            * Thuban/version.py (longversion): 1.0.0, yeah!
800    
801            * Thuban/Model/load.py (SessionLoader.__init__): Accept the
802            1.0.0 namespace too
803    
804            * Thuban/Model/save.py (SessionSaver.write_session): Save with
805            1.0.0 namespace
806    
807            * test/test_load.py (LoadSessionTest.dtd)
808            (TestSingleLayer.file_contents)
809            (TestNonAsciiColumnName.file_contents)
810            (TestLayerVisibility.file_contents)
811            (TestClassification.file_contents, TestLabels.file_contents)
812            (TestLayerProjection.file_contents)
813            (TestRasterLayer.file_contents, TestJoinedTable.file_contents)
814            (TestLabelLayer.file_contents, TestPostGISLayer.file_contents)
815            (TestPostGISLayerPassword.file_contents)
816            (TestLoadError.file_contents, TestLoadError.test): Update for
817            1.0.0 namespace
818    
819            * test/test_save.py (SaveSessionTest.dtd)
820            (SaveSessionTest.testEmptySession)
821            (SaveSessionTest.testSingleLayer)
822            (SaveSessionTest.testLayerProjection)
823            (SaveSessionTest.testRasterLayer)
824            (SaveSessionTest.testClassifiedLayer)
825            (SaveSessionTest.test_dbf_table)
826            (SaveSessionTest.test_joined_table)
827            (SaveSessionTest.test_save_postgis): Update for 1.0.0 namespace
828    
829    2003-12-22  Bernhard Herzog  <[email protected]>
830    
831            * Thuban/Model/load.py (SessionLoader.start_label): Make sure the
832            alignment flags are byte strings not unicode and that they have
833            valid values
834    
835            * test/test_load.py (TestLabelLayer): New. Test loading (and
836            indirectly saving) of maps with labels.
837    
838    2003-12-22  Bernhard Herzog  <[email protected]>
839    
840            * Thuban/UI/tableview.py (TableGrid.OnDestroy)
841            (TableGrid.__init__): Handle EVT_WINDOW_DESTROY in the grid to
842            unsubscribe all subscribers.
843            (LayerTableFrame.OnDestroy): Do not unsubscribe any messages from
844            self.grid since it may already have been destroyed.
845            Fixes RT #2256
846    
847    2003-12-19  Bernhard Herzog  <[email protected]>
848    
849            * po/fr.po, po/es.po: Updated translations from Daniel Calvelo
850    
851    2003-12-16  Bernhard Herzog  <[email protected]>
852            
853            * debian/bitmappath.patch, debian/setup.py.patch:
854                    added to ensure compliance with FHS for debian
855            * debian/rules, debian/changelog:
856                added patches in rules to ensure compliance with FHS for debian
857    
858    2003-12-16  Bernhard Herzog  <[email protected]>
859    
860            * po/Makefile (mo): Make the output a bit nicer so that it prints
861            statistics about the translations. Add a comment how produce even
862            nicer statistics with sed.
863    
864    2003-12-09  Frank Koormann   <[email protected]>
865    
866            * Resources/Projections/defaults.proj:
867            French projection sample with correct accents (UNICODE).
868    
869    2003-12-05  Bernhard Herzog  <[email protected]>
870    
871            * MANIFEST.in: Add the devtools directory
872    
873            * setup.py (setup call): Use license instead of licence. This
874            silences a deprecation warning on Python 2.3
875    
876    2003-12-05  Frank Koormann   <[email protected]>
877    
878            Documentation synced with 1.0rc1
879    
880            * Doc/manual/thuban-manual.xml:
881            Minor formatting changes and references to database layers .
882            Introduction.Internationalization: New section on i18n.
883            MapManagement.AddingandRemovingLayers: Added item on database layers.  
884            MapManagement.TheLegend: Added section and screenshot on popup menu.
885            ProjectionManagement: Updated screenshot and sentence on EPSG.
886            Appendix.SupportedDataSources: Added PostGIS.
887            Appendix.WorkingwithPostGIS: New section.
888    
889            * Doc/manual/images/6_projection.png: Updated screenshot including
890            EPSG checkboxes.
891    
892            * Doc/manual/images/3_5_popup_menu.png: New, popup menu screenshot.
893    
894            * Doc/manual/images/app_postgis_add_layer.png,
895            Doc/manual/images/app_postgis_db_add.png,
896            Doc/manual/images/app_postgis_db_management.png:
897            New screenshots focussing on database layers
898    
899    2003-12-05  Frank Koormann   <[email protected]>
900    
901            * Thuban/UI/projdialog.py (load_user_proj): If user.proj is missing
902            write warning to stderr instead of rising a warning dialog
903    
904    2003-12-03  Bernhard Herzog  <[email protected]>
905    
906            Fix for RT #2243
907    
908            * Thuban/UI/mainwindow.py (MainWindow.has_selected_shape_layer):
909            New. Like has_selected_layer but for shape layers only
910            (_has_selected_shape_layer): New. Like _has_selected_layer but for
911            shape layers only
912            (layer_show_table command, layer_jointable command): Use these
913            commands should only be available for shape layers
914    
915    2003-12-03  Bernhard Herzog  <[email protected]>
916    
917            * Thuban/UI/mainwindow.py (MainWindow.Unsubscribe): Deal with
918            publishers that are wx objects and may have been destroyed by wx
919            already. Fixes RT #2242.
920    
921    2003-12-03  Bernhard Herzog  <[email protected]>
922    
923            * po/ru.po: Updates from Alex Shevlakov
924    
925    2003-12-03  Silke Reimer <silkeintevation.de>
926    
927            * debian/control, debian/changelog: Added gdal-support to
928                    debian package, updated to new thuban version
929    
930    
931    2003-12-03  Bernhard Herzog  <[email protected]>
932    
933            * Thuban/Lib/version.py: New. Module for version number
934            manipulations. The version of make_tuple here also deals better
935            with more unusual version number strings, such as e.g.
936            "1.2+cvs20031111"
937    
938            * Thuban/version.py (make_tuple): Removed. It's now in
939            Thuban.Lib.version. Use that implementation instead.
940    
941            * test/test_lib_version.py: New. Tests for Thuban/Lib/version.py
942    
943    2003-12-02  Bernhard Herzog  <[email protected]>
944    
945            * MANIFEST.in: Add debian files
946    
947            * setup.py (setup call): Add packages for the Extensions so that
948            they're installed too
949            (data_files): Add READMEs and sample data from some Extensions
950    
951            * NEWS: Add note about the extensions in binary packages
952    
953    2003-12-02  Bernhard Herzog  <[email protected]>
954    
955            * Thuban/Model/save.py (SessionSaver.write_session): Save files
956            with the thuban-1.0rc1
957    
958            * Thuban/Model/load.py (SessionLoader.__init__): Recognize the
959            thuban-1.0rc1 namespace too
960    
961            * test/test_save.py (SaveSessionTest.dtd)
962            (SaveSessionTest.testEmptySession)
963            (SaveSessionTest.testSingleLayer)
964            (SaveSessionTest.testLayerProjection)
965            (SaveSessionTest.testRasterLayer)
966            (SaveSessionTest.testClassifiedLayer)
967            (SaveSessionTest.test_dbf_table)
968            (SaveSessionTest.test_joined_table)
969            (SaveSessionTest.test_save_postgis): Update to thuban-1.0rc1
970            namespace
971    
972            * test/test_load.py (LoadSessionTest.dtd): Update to thuban-1.0rc1
973            namespace
974            (TestSingleLayer.file_contents)
975            (TestNonAsciiColumnName.file_contents)
976            (TestLayerVisibility.file_contents)
977            (TestClassification.file_contents, TestLabels.file_contents)
978            (TestLayerProjection.file_contents)
979            (TestRasterLayer.file_contents, TestJoinedTable.file_contents)
980            (TestPostGISLayer.file_contents)
981            (TestPostGISLayerPassword.file_contents)
982            (TestLoadError.file_contents, TestLoadError.test): Update to
983            thuban-1.0rc1 namespace
984    
985    2003-12-01  Bernhard Herzog  <[email protected]>
986    
987            * setup.py (proj4_prefix, wx_prefix, gdal_prefix): Fix these for
988            nt to better match Intevation's current w32 setup
989    
990            * HOWTO-Release: Add note about updating MANIFEST.in
991    
992            * MANIFEST.in: Add the Extensions
993    
994            * NEWS: Update for 1.0rc1
995    
996    2003-12-01  Bernhard Herzog  <[email protected]>
997    
998            * Thuban/UI/mainwindow.py (MainWindow.AddLayer): Change the wild
999            cards for the dialog so that shapefiles ending in all uppercase
1000            SHP are listed too
1001    
1002    2003-11-28  Bernhard Herzog  <[email protected]>
1003    
1004            * Thuban/version.py (longversion): Update to 1.0rc1
1005    
1006            * setup.py (setup call): Update version to 1.0rc1. Use the
1007            [email protected] email address as author email instead of my
1008            personal one.
1009    
1010    2003-11-28  Bernhard Herzog  <[email protected]>
1011    
1012            * po/de.po: Update german translation.
1013    
1014    2003-11-28  Bernhard Herzog  <[email protected]>
1015    
1016            Unify the filenames stored in .thuban files so that the .thuban
1017            files are more platform independend
1018    
1019            * Thuban/Model/save.py (unify_filename): New. Unify filenames so
1020            that they can be used on both windows and unix
1021            (SessionSaver.prepare_filename): New. Handle all filename
1022            transformations for filenames stored in the thuban file
1023            (SessionSaver.write_data_containers, SessionSaver.write_layer):
1024            Use prepare_filename
1025    
1026            * test/test_save.py (SaveSessionTest.testSingleLayer)
1027            (SaveSessionTest.testLayerProjection)
1028            (SaveSessionTest.testRasterLayer)
1029            (SaveSessionTest.testClassifiedLayer)
1030            (SaveSessionTest.test_dbf_table)
1031            (SaveSessionTest.test_joined_table): Filenames are always stored
1032            with slashes on all currently supported platforms so adapt all
1033            tests to this
1034    
1035            * test/test_load.py (LoadSessionTest.filenames): With the new
1036            filename scheme the filenames in the tests should be
1037            understandable on all currently supported platforms so we turn
1038            this into an empty list because we don't have to normalize them
1039            anymore
1040    
1041    2003-11-28  Bernhard Herzog  <[email protected]>
1042    
1043            * test/test_layer.py (TestLayer.test_arc_layer_with_projection):
1044            Add the ellipsoid to the projection since some Proj versions
1045            complain if it's missing.
1046    
1047    2003-11-27  Bernhard Herzog  <[email protected]>
1048    
1049            Corect some bounding box projection problems
1050    
1051            * Thuban/Model/proj.py (Projection.InverseBBox): New. Inverse
1052            version of ForwardBBox
1053            (Projection._transform_bbox): New. common implementation of
1054            ForwardBBox and InverseBBox
1055            (Projection.ForwardBBox): Use _transform_bbox.
1056    
1057            * test/test_proj.py (TestProjection.test): Add test for
1058            InverseBBox
1059    
1060            * Thuban/Model/layer.py (Layer.LatLongBoundingBox)
1061            (Layer.ShapesBoundingBox, RasterLayer.LatLongBoundingBox): Use the
1062            new InverseBBox method to determine the unprojected bounding box
1063            (Layer.ShapesInRegion): Use the ForwardBBox method to project the
1064            bbox.
1065    
1066            * test/test_layer.py (TestLayer.test_point_layer_with_projection):
1067            Removed.
1068            (TestLayer.test_arc_layer_with_projection): New. This test is
1069            better able to test whether bounding boxes are projected correctly
1070            than test_point_layer_with_projection
1071    
1072            * Thuban/UI/viewport.py (ViewPort.map_projection_changed): Use
1073            InverseBBox to unproject bboxes
1074    
1075    2003-11-25  Bernhard Herzog  <[email protected]>
1076    
1077            * Thuban/UI/about.py (About.__init__): Make sure we have ASCII
1078            source code.
1079    
1080    2003-11-25  Bernhard Herzog  <[email protected]>
1081    
1082            * Thuban/Model/layer.py (Layer.__getattr__): Removed. It was only
1083            there for backwards compatibility and all code relying on that
1084            should have been updated by now.
1085    
1086    2003-11-25  Bernhard Herzog  <[email protected]>
1087    
1088            * test/test_load.py (TestClassification.test): Add the missing
1089            round trip test.
1090            (TestClassification.file_contents): Update to the newest file
1091            format
1092    
1093    2003-11-25  Bernhard Herzog  <[email protected]>
1094    
1095            Add very experimental (and possibly dangerous) extension to draw
1096            polygons:
1097    
1098            * Extensions/drawshape/README: New. Brief installation
1099            instructions
1100    
1101            * Extensions/drawshape/drawshape.py: New. Implementation of the
1102            drawshape extensions
1103    
1104            * Extensions/drawshape/patch.diff: Patch to apply before the
1105            extension can be used.
1106    
1107    2003-11-24  Bernhard Herzog  <[email protected]>
1108    
1109            * Thuban/Model/data.py (ShapefileStore._open_shapefile)
1110            (ShapefileStore.__init__): Factor opening the shapefile into a
1111            separate method (the new _open_shapefile). This makes the code a
1112            bit more readable but the real reason is that it makes some evil
1113            hacks easier. :-)
1114    
1115    2003-11-24  Bernhard Herzog  <[email protected]>
1116    
1117            * Thuban/Model/load.py (SessionLoader.check_attrs): If no
1118            converter is specified for an attribute assume it's a string
1119            containing only Latin1 characters. Update doc-string accordingly.
1120            This change should fix many places where unicode objects might
1121            accidentally enter Thuban.
1122    
1123            * test/test_load.py (TestNonAsciiColumnName): New test to check
1124            what happens with column names in DBF files that contain non-ascii
1125            characters
1126    
1127    2003-11-21  Bernhard Herzog  <[email protected]>
1128    
1129            Enable the experimental attribute editing again and introduce a
1130            command line switch to actually activate it
1131    
1132            * Thuban/UI/main.py (options): New. Container for options set on
1133            the commmand line
1134            (main): Add the --enable-attribute-editing flag.
1135    
1136            * Thuban/UI/identifyview.py (IdentifyView.__init__): If attribute
1137            editing is enabled use the grid ctrl which allows editing of the
1138            values
1139    
1140            * Thuban/Model/transientdb.py (AutoTransientTable.write_record):
1141            New. Just delegate this to the underlying table.
1142    
1143    2003-11-20  Bernhard Herzog  <[email protected]>
1144    
1145            * test/test_proj.py (ProjFileReadTests.test_read_unreadable_file):
1146            Skip this test if run under non-posix systems since it only works
1147            there
1148    
1149    2003-11-19  Bernhard Herzog  <[email protected]>
1150    
1151            * Thuban/Model/resource.py: Rework the way gdal support is
1152            determined so that we can give a reason in the about why gdal is
1153            not supported.
1154            (gdal_support_status): New. Variable holding a string with the
1155            reason for no gdal support
1156    
1157            * Thuban/UI/about.py (About.__init__): Add the reason why gdal is
1158            not supported to the message
1159    
1160    2003-11-19  Bernhard Herzog  <[email protected]>
1161    
1162            Remove the old table interface and its test cases
1163    
1164            * Thuban/Model/table.py (OldTableInterfaceMixin): Removed.
1165            (DBFTable, MemoryTable): Do not derive from OldTableInterfaceMixin
1166            anymore
1167    
1168            * Thuban/Model/transientdb.py (TransientTableBase)
1169            (AutoTransientTable): Do not derive from OldTableInterfaceMixin
1170            anymore
1171    
1172            * test/test_table.py: Removed since the old interface it tests is
1173            gone.
1174    
1175            * test/runtests.py (main): The old table interface is gone and
1176            with it the deprecation warnings so remove the code that turns
1177            these warnings into errors
1178    
1179    2003-11-19  Bernhard Herzog  <[email protected]>
1180    
1181            * test/test_table.py: Revert to revision 1.5 again. Changing the
1182            tests to use the new table interface is completely wrong since the
1183            whole purpose of the tests in this module is to test the old
1184            interface.
1185    
1186    2003-11-18  Bernhard Herzog  <[email protected]>
1187    
1188            * Thuban/Model/postgisdb.py (PostGISConnection.MatchesParameters):
1189            New. Test whether the connection matches a set of connection
1190            parameters
1191    
1192            * Thuban/UI/dbdialog.py (DBFrame.conns_changed): Fix doc-string
1193            (DBFrame.OnAdd): Use the new MatchesParameters method when looking
1194            for existing connections with the same parameters and break out of
1195            the loop correctly.
1196    
1197            * test/test_postgis_db.py (TestBriefDescription)
1198            (TestPostGISSimple.test_brief_description): Rename
1199            TestBriefDescription to TestPostGISSimple and the test method to
1200            test_brief_description so that we can add more test methods.
1201            (TestPostGISSimple.test_matches_parameters): New. Test the new
1202            MatchesParameters method
1203    
1204    2003-11-18  Bernhard Herzog  <[email protected]>
1205    
1206            * Thuban/Lib/connector.py (Publisher): Introduce a new flag,
1207            _was_destroyed, to indicate whether an publisher instance has
1208            already been destroyed.
1209            (Publisher.Unsubscribe): Only disconnect if the publisher has not
1210            been destroyed yet.
1211            (Publisher.Destroy): Set the _was_destroyed flag to true.
1212    
1213            * test/test_connector.py
1214            (TestPublisher.test_unsubscribe_after_destroy): New. Test that
1215            calling Unsubscribe after Destroy doesn't raise an exception
1216    
1217    2003-11-14  Bernhard Herzog  <[email protected]>
1218    
1219            * Thuban/UI/identifyview.py (IdentifyView.selected_shape): Fix
1220            typo in doc-string
1221    
1222    2003-11-13  Bernhard Herzog  <[email protected]>
1223    
1224            Quote table and column names properly for postgis.
1225    
1226            * Thuban/Model/postgisdb.py (quote_identifier): New. Function to
1227            quote an identifier for use in an sql statement
1228            (PostGISColumn.__init__): Add the quoted_name attribute
1229            (PostGISTable.__init__): New instance variable quoted_tablename
1230            (PostGISTable._fetch_table_information): Use the quoted table
1231            name. New isntance variable quoted_geo_col with a quoted version
1232            of geometry_column
1233            (PostGISTable.NumRows, PostGISTable.RowIdToOrdinal)
1234            (PostGISTable.RowOrdinalToId): Use the quoted table name
1235            (PostGISTable.ReadValue, PostGISTable.ValueRange)
1236            (PostGISTable.UniqueValues, PostGISTable.SimpleQuery)
1237            (PostGISShapeStore.BoundingBox, PostGISShapeStore.Shape)
1238            (PostGISShapeStore.AllShapes, PostGISShapeStore.ShapesInRegion):
1239            Use quoted table and column names
1240    
1241            * test/test_postgis_db.py (TestPostGISSpecialCases)
1242            (TestPostGISIgnoredColumns): Rename the class to
1243            TestPostGISSpecialCases because that better describes the new
1244            cases
1245            (TestPostGISSpecialCases.test_unsupported_types)
1246            (TestPostGISSpecialCases.test): Rename the method to
1247            test_unsupported_types because we need a more descriptive name now
1248            that there are more methods
1249            (TestPostGISSpecialCases.test_table_name_quoting)
1250            (TestPostGISSpecialCases.test_column_name_quoting)
1251            (TestPostGISSpecialCases.test_shapestore_name_quoting): New test
1252            cases to test quoting of table and column names in PostGISTable
1253            and PostGISShapeStore
1254    
1255            * test/postgissupport.py
1256            (skip_if_addgeometrycolumn_does_not_use_quote_ident): New. Skip if
1257            AddGeometryColumn desn't support table or column names with sapces
1258            or double quotes
1259    
1260    2003-11-12  Jan-Oliver Wagner <[email protected]>
1261    
1262            * Extensions/wms/__init__.py: New: Init to make this
1263            directory a package.
1264    
1265            * Extensions/wms/wms.py: New: Provide layers via OGC WMS.
1266    
1267    2003-11-11  Bernhard Herzog  <[email protected]>
1268    
1269            * Thuban/Model/resource.py (EPSG_DEPRECATED_PROJ_FILE): New.
1270            Constant for the file woth deprecated epsg projections
1271            (get_system_proj_file): Update doc-string
1272    
1273            * Thuban/UI/projdialog.py (ProjFrame.build_dialog): Add a space
1274            above the EPS widgets, introduce a check box for the deprecated
1275            eps projections and a label for the epsg widgets
1276            (ProjFrame._OnShowEPSG): Handle the deprecated EPSG projections
1277            too
1278    
1279    2003-11-11  Bernhard Herzog  <[email protected]>
1280    
1281            Avoid warnings when run under Python 2.3
1282    
1283            * Thuban/UI/baserenderer.py (BaseRenderer.draw_point_shape)
1284            (BaseRenderer.draw_label_layer): Coordinates must be ints.
1285    
1286            * Thuban/UI/renderer.py (MapRenderer.make_point): Turn this into a
1287            real method so that we can convert to int.
1288            (MapRenderer.label_font): The font size mist be an int.
1289    
1290            * Thuban/UI/common.py (Color2wxColour): The color values must be
1291            ints. Also, remove the unnecessary asserts.
1292    
1293            * test/test_load_0_8.py (TestUnicodeStrings.file_contents)
1294            (TestUnicodeStrings.test): Python source code should not contain
1295            non-ascii characters unless an encoding is specified in the file.
1296            Therefore use \x escapes in the string literals for non-ascii
1297            characters.
1298    
1299    2003-11-11  Bernhard Herzog  <[email protected]>
1300    
1301            * Thuban/Model/resource.py (get_system_proj_file): Add a filename
1302            parameter so that this function can be used for all proj files in
1303            Resource/Projections
1304            (DEFAULT_PROJ_FILE, EPSG_PROJ_FILE): New. Predefined filenames for
1305            get_system_proj_file
1306    
1307            * Thuban/UI/projdialog.py (ProjFrame.__init__): Instead of one
1308            ProjFile self.__sysProjFile use a dictionary of system ProjFile
1309            objects self._sys_proj_files
1310            (ProjFrame.build_dialog): Adapt to the new changes in the
1311            ProjectionList constructor. Add a check button to toggle whether
1312            EPSG projections are shown
1313            (ProjFrame._OnShowEPSG): New. Handler for the epsg check button
1314            events.
1315            (ProjFrame.load_user_proj, ProjFrame.load_system_proj): Only show
1316            the busy cursor if the files have not yet been loaded by the
1317            dialog.
1318            (ProjFrame.load_system_proj): Add a parameter for the name of the
1319            proj file. Maintain the dictionary of system projections
1320            self._sys_proj_files
1321    
1322            * Thuban/UI/projlist.py (ProjectionList): Merge the system_projs,
1323            user_projs parameters into one parameter proj_files which is a
1324            list of proj files.
1325            (ProjectionList._subscribe_proj_files)
1326            (ProjectionList._unsubscribe_proj_files): New. Move
1327            subscription/unsubscription of projfile messages to separate
1328            methods
1329            (ProjectionList.Destroy): The unsubscribe is now done in
1330            _unsubscribe_proj_files
1331            (ProjectionList.update_projections): We now have a list of proj
1332            file objects
1333            (ProjectionList.SetProjFiles): New method to set a new list of
1334            proj file objects
1335    
1336            * test/test_proj.py (ProjFileReadTests.test_get_system_proj_file):
1337            Specify explicitly which system proj file to load.
1338    
1339    2003-11-11  Bernhard Herzog  <[email protected]>
1340    
1341            * Thuban/Model/load.py (SessionLoader.Destroy): New. Clear all
1342            instance variables to cut cyclic references. The GC would have
1343            collected the loader eventually but it can happen that it doesn't
1344            run at all until thuban is closed (2.3 but not 2.2 tries a bit
1345            harder and forces a collection when the interpreter terminates)
1346            (load_session): Call the handler's Destroy method to make sure
1347            that it gets garbage collected early. Otherwise it will be
1348            collected very late if at all and it holds some references to e.g.
1349            shapestores and the session which can lead to leaks (of e.g. the
1350            temporary files)
1351    
1352            * test/test_load.py (TestSingleLayer.test_leak): New. test for the
1353            resource leak in load_session
1354    
1355    2003-11-10  Bernhard Herzog  <[email protected]>
1356    
1357            * Thuban/UI/baserenderer.py: Add a way to specify how layers in
1358            extensions are to be rendered.
1359            (_renderer_extensions): New. List with renderer for layers in
1360            extensions
1361            (add_renderer_extension): New. Add a renderer extension
1362            (init_renderer_extensions): New. Init the renderer extensions
1363            (BaseRenderer.render_map_incrementally): Search
1364            _renderer_extensions for how to draw unknown layer types
1365            (BaseRenderer.draw_raster_data): Add format parameter so that
1366            formats other than BMP can be drawn
1367            (BaseRenderer.draw_raster_layer): Pass an explicit format to
1368            draw_raster_data
1369    
1370            * Thuban/UI/renderer.py (raster_format_map): New. Mapping form the
1371            strings of the format parameter of draw_raster_data method to wx
1372            constants
1373            (MapRenderer.draw_raster_data): Add the format parameter and use
1374            raster_format_map to map it to the right wxwindows constant for
1375            wxImageFromStream
1376    
1377            * test/test_baserenderer.py (SimpleRenderer.draw_raster_data): Add
1378            the format parameter and record it
1379            (TestBaseRenderer.test_raster_no_projection): check the format
1380            paramter of the draw_raster_data method
1381            (TestBaseRenderer.test_renderer_extension): New. Test the renderer
1382            extension facility
1383    
1384    2003-11-07  Bernhard Herzog  <[email protected]>
1385    
1386            Tweak the usage of the sqlite database to make common use cases
1387            more responsive. In most cases copying the data to the sqlite
1388            database takes so long that using sqlite doesn't have enough
1389            advantages.
1390    
1391            * Thuban/Model/transientdb.py (TransientTableBase.ValueRange): Add
1392            comments about performance and query the min and max in separate
1393            statements because only that way will indexes be used.
1394            (TransientTableBase.UniqueValues): Add some comments about
1395            performance.
1396            (AutoTransientTable.ValueRange, AutoTransientTable.UniqueValues):
1397            Do not copy the data to the transient DB but use the transient
1398            copy if it exists. See the new comments for the performance trade
1399            offs
1400    
1401            * test/test_transientdb.py
1402            (TestTransientTable.test_auto_transient_table): Make sure that the
1403            data is copied to the transient database at some point.
1404    
1405    2003-11-03  Bernhard Herzog  <[email protected]>
1406    
1407            * Thuban/Model/data.py (ShapefileStore.ShapesInRegion): Bind some
1408            globals to locals so that it's a bit faster
1409    
1410    2003-11-03  Bernhard Herzog  <[email protected]>
1411    
1412            * Thuban/UI/baserenderer.py
1413            (BaseRenderer.draw_shape_layer_incrementally): Use the ReadValue
1414            method. ReadValue is faster than ReadRowAsDict since it only reads
1415            one cell especially now that the dbf file objects actually
1416            implement it.
1417    
1418            * Thuban/Model/table.py (DBFTable.ReadValue): Use the new
1419            read_attribute method of the dbf objects
1420    
1421    2003-11-03  Bernhard Herzog  <[email protected]>
1422    
1423            * Extensions/profiling/profiling.py (popup_dialog_box): New config
1424            variable to indicate whether the result should be shown in a
1425            dialog box
1426            (profile_screen_renderer, time_screen_renderer): Only show a
1427            dialog box if popup_dialog_box is true.
1428            (profile_screen_renderer): Flush stdout after the printing the
1429            first part of the "profiling..." message
1430    
1431            * Thuban/UI/baserenderer.py
1432            (BaseRenderer.draw_shape_layer_incrementally): Cache the pens and
1433            brushes for the groups so that they're not created over and over
1434            again
1435    
1436            * Thuban/Model/classification.py (Classification.__getattr__)
1437            (Classification._compile_classification)
1438            (Classification._clear_compiled_classification): New. Methods to
1439            manage a 'compiled' representation of the classification groups
1440            which is created on demand
1441            (Classification.InsertGroup, Classification.RemoveGroup)
1442            (Classification.ReplaceGroup): reset the compiled representation
1443            (Classification.FindGroup): Use the compiled representation to
1444            find the matching group
1445            (ClassGroupRange.GetRangeTuple): New. Return the range as a tuple
1446    
1447    2003-10-31  Bernhard Herzog  <[email protected]>
1448    
1449            * Thuban/Model/classification.py (Classification.SetDefaultGroup):
1450            Send a CLASS_CHANGED message
1451            (Classification.RemoveGroup): Send a CLASS_CHANGED message and do
1452            not return the removed group since it wasn't used.
1453    
1454            * test/test_classification.py
1455            (TestClassification.test_set_default_group): New. Test the
1456            SetDefaultGroup method
1457            (TestClassification.test_insert_group): New. Test the InsertGroup
1458            method
1459            (TestClassification.test_remove_group): New. Test the RemoveGroup
1460            method
1461            (TestClassification.test_replace_group): New. Test the
1462            ReplaceGroup method
1463    
1464    2003-10-31  Bernhard Herzog  <[email protected]>
1465    
1466            * test/test_classification.py (TestClassification.setUp):
1467            Subscribe to the CLASS_CHANGED messages
1468            (TestClassification.tearDown): New. Destroy the classification
1469            properly
1470            (TestClassification.test_defaults): Add tests for the default line
1471            width and whether no messages were sent yet
1472            (TestClassification.test_set_default_properties): Add tests for
1473            messages and setting the default line width
1474            (TestClassification.test_add_singleton)
1475            (TestClassification.test_add_range)
1476            (TestClassification.test_multiple_groups): Add tests for messages
1477    
1478    2003-10-31  Bernhard Herzog  <[email protected]>
1479    
1480            Some more refactoring in preparation for new tests:
1481    
1482            * test/test_classification.py (TestClassification.setUp): New.
1483            Instantiate the classification here. Update the test methods
1484            accordingly.
1485            (TestClassification.test_multiple_groups): Make sure that the two
1486            singletons matching 1 are considered different.
1487    
1488    2003-10-31  Bernhard Herzog  <[email protected]>
1489    
1490            * test/test_classification.py (red, green, blue): New. These
1491            constants were used in several cases. Update the relevant methods.
1492            (TestClassification.test_defaults)
1493            (TestClassification.test_set_default_properties)
1494            (TestClassification.test_add_singleton)
1495            (TestClassification.test_add_range)
1496            (TestClassification.test_multiple_groups)
1497            (TestClassification.test_deepcopy): New. These were formerly all
1498            part of the single method test.
1499            (TestClassification.test_deepcopy): Removed.
1500            (TestClassIterator): Removed. The test case is now a method of
1501            TestClassification since it tests part of the public interface of
1502            Classification
1503            (TestClassification.test_iterator): New. Used to be
1504            TestClassIterator effectively
1505    
1506    2003-10-31  Jan-Oliver Wagner <[email protected]>
1507    
1508            GUIfied the functions of the profiling extension.
1509    
1510            * /Extensions/profiling/__init__.py: New: Init to make this
1511            directory a package.
1512    
1513            * Extensions/profiling/profiling.py: Moved menu entries to
1514            the Extensions menu. Applied _() for strings.
1515            (profile_screen_renderer): Catch the detailed printout and present
1516            it in a dialog.
1517            (time_screen_renderer): Raise a dialog to present the result instead
1518            of printing it to stdout.
1519    
1520    2003-10-31  Bernhard Herzog  <[email protected]>
1521    
1522            * test/test_classification.py (TestClassGroupProperties)
1523            (TestClassGroup, TestClassGroupDefault, TestClassGroupRange)
1524            (TestClassGroupSingleton, TestClassIterator, TestClassification):
1525            Split TestClassification into several classes, one for each class
1526            being tested. TestClassification itself now only tests
1527            Classification. This split makes changes to the tests a bit easier
1528    
1529    2003-10-31  Bernhard Herzog  <[email protected]>
1530    
1531            * Extensions/profiling/profiling.py: New. Extension to measure
1532            Thuban performance
1533    
1534    2003-10-31  Frank Koormann <[email protected]>
1535    
1536            Added two items to legend popup menu: Remove Layer and Show Layer Table
1537    
1538            * Thuban/UI/legend.py (LegendPanel._OnRemoveLayer,
1539            LegendPanel._OnShowTable): New event handlers, call the corresponding
1540            mainwindow methods.
1541            (LegendTree._OnRightClick): Added items to popup menu.
1542    
1543    2003-10-30  Bernhard Herzog  <[email protected]>
1544    
1545            * Thuban/UI/dialogs.py (ThubanFrame.__init__): Handle
1546            EVT_WINDOW_DESTROY
1547            (ThubanFrame.OnDestroy): New. Handler for EVT_WINDOW_DESTROY. Does
1548            nothing but is convenient for the derived classes.
1549    
1550            * Thuban/UI/tableview.py
1551            (TableFrame.OnDestroy, LayerTableFrame.OnDestroy): New.
1552            Unsubscribe the messages here not in OnClose because that might
1553            get called multiple times. Fixes RT #2196
1554            (TableFrame.OnClose, LayerTableFrame.OnClose): Removed. Not needed
1555            anymore.
1556    
1557            * README: Update the minimum requirement for wxPython. Since we
1558            now use the EVT_WINDOW_DESTROY event, we need at least 2.4.0.4,
1559            the version in which that was introduced for all platforms
1560    
1561    2003-10-30  Frank Koormann <[email protected]>
1562    
1563            * Thuban/UI/join.py (JoinDialog.OnJoin): Wrapped the major parts of
1564            the join process in a ThubanBeginBusyCursor, ThubanEndBusyCursor
1565            frame.
1566    
1567    2003-10-30  Jan-Oliver Wagner <[email protected]>
1568    
1569            Improved APR import extension, added further EPSG definitions
1570            and some cleanup regarding string class.
1571    
1572            * test/test_proj.py (TestProjection.test_get_projection_units_geo):
1573            Added test for alias 'longlat'.
1574    
1575            * Resources/Projections/epsg-deprecated.proj: New. Contains
1576            deprecated EPSG definitions.
1577    
1578            * Extensions/importAPR/odb.py (ODBBaseObject.TreeInfo): Added
1579            the variable names for objects.
1580    
1581            * Extensions/importAPR/apr.py (APR_BLnSym, APR_BMkSym, APR_BShSym): New.
1582            Copied from importAPR and provided with documentation.
1583    
1584            * Extensions/importAPR/importAPR.py (APR_BLnSym, APR_BMkSym, APR_BShSym):
1585            Moved to apr.py.
1586            (APR_View): Added object ref 'ITheme'.
1587    
1588            * Thuban/Lib/fileutil.py, Thuban/UI/proj4dialog.py: Replaced string
1589            split function by corresponding use of the string class method.
1590    
1591            * Thuban/Model/xmlwriter.py: Replaced string replace function by
1592            corresponding string method.
1593    
1594    2003-10-29  Bernhard Herzog  <[email protected]>
1595    
1596            * Thuban/UI/baserenderer.py
1597            (BaseRenderer.draw_shape_layer_incrementally): Speed up the
1598            special case of a classification that only has the default group
1599    
1600    2003-10-27  Bernhard Herzog  <[email protected]>
1601    
1602            * po/fr.po, po/es.po: Updated translations from Daniel Calvelo
1603    
1604            * po/de.po: Update.
1605    
1606            * Thuban/UI/application.py
1607            (ThubanApplication.ShowExceptionDialog): Handle translation of the
1608            dialog message properly
1609    
1610    2003-10-27  Bernhard Herzog  <[email protected]>
1611    
1612            Rework how localization works so that we use wx's translation
1613            functions when running Thuban as a normal application but not when
1614            we don't need any UI, such as in the test suite. See the comment
1615            in Thuban/__init__.py for details
1616    
1617            * Thuban/__init__.py (_): Add one level of indirection to make the
1618            translation handling more flexible and to make it possible to use
1619            either wx's translation services or not.
1620            (gettext_identity, translation_function_installed)
1621            (install_translation_function): New function to help with this
1622    
1623            * Thuban/UI/__init__.py: Install the wx specific translation
1624            function if it's OK to do that
1625    
1626            * test/support.py (initthuban): Install a dummy translation
1627            function so that importing Thuban.UI doesn't install a wx specific
1628            one for which would need to import wxPython
1629    
1630    2003-10-27  Bernhard Herzog  <[email protected]>
1631    
1632            * HOWTO-Release: Source archives should be created first and the
1633            binary packages should be created from the source archives.
1634            There's an official debian package now so there's no need to test
1635            the rpm on debian anymore
1636    
1637    2003-10-27  Bernhard Herzog  <[email protected]>
1638    
1639            Several rendering changes:
1640    
1641             - Render the selection into a separate bitmap so that only that
1642               bitmap needs to be redrawn when the selection changes
1643    
1644             - Render incrementally showing previews and allowing interaction
1645               before rendering is complete
1646    
1647             - Update the renderer interface a bit. Most parameters of
1648               RenderMap are now parameters of the constructor
1649    
1650            * Thuban/UI/baserenderer.py (BaseRenderer.__init__): Add the map
1651            and the update region as parameters. Update the doc-string
1652            (BaseRenderer.render_map_incrementally): New. Generator function
1653            to renders the map incrementally
1654            (BaseRenderer.render_map): Remove the map argument (it's now in
1655            the constructor) and simply iterate over the
1656            render_map_incrementally generator to draw the map.
1657            (BaseRenderer.draw_shape_layer_incrementally)
1658            (BaseRenderer.draw_shape_layer): Renamed to
1659            draw_shape_layer_incrementally and changed into a generator that
1660            yields True every 500 shapes. Used by render_map_incrementally to
1661            render shape layers incrementally
1662    
1663            * Thuban/UI/renderer.py (ScreenRenderer.RenderMap): Removed the
1664            map and region parameters which are now in the constructor
1665            (ScreenRenderer.RenderMapIncrementally): New. Public frontend for
1666            the inherited render_map_incrementally.
1667            (BaseRenderer.draw_shape_layer): Removed.
1668            (ScreenRenderer.draw_selection_incrementally): New. The selection
1669            drawing part of the removed draw_shape_layer as a generator
1670            (ScreenRenderer.layer_shapes): Update because of the region
1671            parameter change
1672            (ExportRenderer.__init__): New. Extend the inherited constructor
1673            with the destination region for the drawing
1674            (ExportRenderer.RenderMap): Removed the map and region parameters
1675            which are now in the constructor
1676    
1677            * Thuban/UI/view.py (MapCanvas.PreviewBitmap): New. Return a
1678            bitmap suitable for a preview in a tool
1679            (CanvasPanTool.MouseMove): Use the PreviewBitmap method to get the
1680            bitmap
1681            (MapPrintout.draw_on_dc): Adapt to new renderer interface
1682            (MapCanvas.OnPaint): Handle drawing the selection bitmap if it
1683            exists
1684            (MapCanvas.OnIdle): Update the logic to deal with incremental
1685            rendering and the selection bitmap
1686            (MapCanvas._do_redraw): Handle the instantiation of the render
1687            iterator and the redraws during rendering
1688            (MapCanvas._render_iterator): New. Generator to incrementally
1689            redraw both bitmaps
1690            (MapCanvas.Export): Adapt to new renderer interface.
1691            (MapCanvas.full_redraw): Reset the selection bitmap and the
1692            renderer iterator too
1693            (MapCanvas.redraw_selection): New. Force a redraw of the selection
1694            bitmap
1695            (MapCanvas.shape_selected): Only redraw the selection bitmap
1696    
1697            * test/test_baserenderer.py
1698            (TestBaseRenderer.test_polygon_no_projection)
1699            (TestBaseRenderer.test_raster_no_projection)
1700            (TestBaseRenderer.test_point_map_projection)
1701            (TestBaseRenderer.test_point_layer_and_map_projection)
1702            (TestBaseRenderer.test_point_layer_projection)
1703            (TestBaseRenderer.test_point_with_classification): Adapt to new
1704            renderer interface
1705    
1706    2003-10-24  Bernhard Herzog  <[email protected]>
1707    
1708            * libraries/thuban/wxproj.cpp (draw_polygon_shape)
1709            (point_in_polygon_shape, shape_centroid): Raise an exception if
1710            the shape can't be read. Previously invalid shape ids would lead
1711            to a segfault.
1712    
1713            * test/test_wxproj.py (TestShapeCentroid.test_invalid_shape_id):
1714            New. test whether an exception is raised for invalid shape ids
1715    
1716    2003-10-24  Jan-Oliver Wagner <[email protected]>
1717    
1718            * Thuban/Model/proj.py (Projection.GetProjectedUnits): Added 'longlat'
1719            as alias for 'latlong'.
1720    
1721            * Thuban/UI/projdialog.py (ProjFrame.__init__): Added 'longlat'
1722            as alias for 'latlong'.
1723    
1724    2003-10-24  Jan-Oliver Wagner <[email protected]>
1725    
1726            * Thuban/UI/projdialog.py (ProjFrame.proj_selection_changed): Set
1727            the projection even for the UnknownPanel.
1728            (UnknownProjPanel.__init__): Define the text and create the textctrl
1729            widget.
1730            (UnknownProjPanel._DoLayout): Replaced static text widget by the
1731            textctrl created in __init__.
1732            (UnknownProjPanel.SetProjection): Set the text for the text ctrl
1733            including the parameters of the projection.
1734            
1735    2003-10-24  Jan-Oliver Wagner <[email protected]>
1736    
1737            * Resources/Projections/epsg.proj: New. This is a list of
1738            EPSG codes with parameters for proj. The list has been
1739            generated using devtools/create_epsg.py based on the
1740            file nad/epsg of the proj 4.4.7 package. Four projection
1741            definitions have been deleted as they are not accepted by proj:
1742            "CH1903+ / LV95", "Bern 1898 (Bern) / LV03C", "CH1903 / LV03"
1743            and "HD72 / EOV".
1744    
1745    2003-10-22  Bernhard Herzog  <[email protected]>
1746    
1747            Some more tweaks to the projection dialog which should fix RT
1748            #1886.
1749    
1750            * Thuban/UI/projlist.py (ProjectionList.Destroy): Unsubscribe from
1751            the ProjFile's messages and call the base class methods correctly
1752            (ProjectionList.SelectProjection): Set the wxLIST_STATE_FOCUSED
1753            flag on the newly selected item too. Otherwise some other item is
1754            focused and the first time the focus is moved with the keyboard
1755            the selection moves in unexpected ways.
1756    
1757            * Thuban/UI/projdialog.py (ProjFrame.__init__): Do not set the
1758            focus on the OK button, only on the projection list. That way the
1759            list really has the focus initially
1760            (ProjFrame.OnClose): Call the projection list's Destroy method to
1761            make it unsubscribe all messages
1762    
1763    2003-10-21  Bernhard Herzog  <[email protected]>
1764    
1765            Rework the projection dialog to fix a few bugs, including RT 2166
1766            and most of 2168
1767    
1768            * Thuban/UI/projlist.py: New. The class ProjectionList is a
1769            special wxListCtrl to show a list of projections in a more MVC
1770            fashion
1771    
1772            * Thuban/UI/projdialog.py (ProjFrame): Substantial changes
1773            throughout the class. The main change is to use the ProjectionList
1774            class instead of a normal wxListBox. Also, add an explicit
1775            "Unknown" projection to the projection choice control.
1776            (ProjPanel.__init__): Add an "unknown" ellipsoid
1777            (TMPanel.__init__, LCCPanel.__init__): Tweak the order of
1778            instantiation of the panel's controls to make the tab-order more
1779            natural
1780    
1781    2003-10-21  Bernhard Herzog  <[email protected]>
1782    
1783            * test/test_load.py (TestSingleLayer.file_contents)
1784            (TestSingleLayer.test): Add non-ascii characters to the titles of
1785            session, map and layer. This is effectively a port of the
1786            TestUnicodeStrings test in test_load_0_8.py which for some reason
1787            was only added there.
1788    
1789            * test/test_load_0_9.py (TestSingleLayer.file_contents)
1790            (TestSingleLayer.test): Same as in test_load.py: add non-ascii
1791            characters to the titles of session, map and layer,.
1792    
1793    2003-10-21  Bernhard Herzog  <[email protected]>
1794    
1795            Add EPSG projection handling to .thuban files
1796    
1797            * test/test_save.py (SaveSessionTest.dtd)
1798            (SaveSessionTest.testEmptySession)
1799            (SaveSessionTest.testLayerProjection)
1800            (SaveSessionTest.testRasterLayer)
1801            (SaveSessionTest.testClassifiedLayer)
1802            (SaveSessionTest.test_dbf_table)
1803            (SaveSessionTest.test_joined_table)
1804            (SaveSessionTest.test_save_postgis): Update to 1.0-dev namespace
1805            (SaveSessionTest.testSingleLayer): Update to 1.0-dev namespace and
1806            use a and epsg projection to test saving them
1807    
1808            * test/test_load.py (LoadSessionTest.dtd): Update to 1.0-dev
1809            namespace
1810            (TestLayerVisibility.file_contents, TestLabels.file_contents)
1811            (TestLayerProjection.file_contents)
1812            (TestRasterLayer.file_contents, TestJoinedTable.file_contents)
1813            (TestPostGISLayer.file_contents)
1814            (TestPostGISLayerPassword.file_contents)
1815            (TestLoadError.file_contents, TestLoadError.test): Update to use
1816            1.0-dev namespace
1817            (TestSingleLayer.file_contents, TestSingleLayer.test): Update to
1818            use 1.0-dev namespace and use an EPSG projection to test whether
1819            loading it works
1820    
1821            * test/test_load_0_9.py: New. Effectively a copy of test_load.py
1822            as of Thuban 0.9. These are now tests to determine whether Thuban
1823            can still read files generated by Thuban 0.9
1824    
1825            * Thuban/Model/save.py (SessionSaver.write)
1826            (SessionSaver.write_session): Use the 1.0 dtd and 1.0-dev
1827            namespace
1828            (SessionSaver.write_projection): Write the projection's epsg
1829            attribute
1830    
1831            * Thuban/Model/load.py (SessionLoader.__init__): Also accept the
1832            thuban-1.0-dev.dtd namespace
1833            (SessionLoader.check_attrs): Allow a callable object as conversion
1834            too
1835            (SessionLoader.start_projection, SessionLoader.end_projection)
1836            (SessionLoader.start_parameter): Handle the epsg attribute and
1837            rename a few instance variables to lower case
1838    
1839            * Resources/XML/thuban-1.0.dtd: New. Only difference to
1840            thuban-0.9.dtd is the epsg attribute for projections.
1841    
1842    2003-10-21  Bernhard Herzog  <[email protected]>
1843    
1844            * test/runtests.py (main): Let the user specify which tests to run
1845            on the command line
1846    
1847            * test/support.py (ThubanTestResult.getDescription): Override to
1848            give a better short description. The description can be used as a
1849            parameter to run_tests to run that particular test in isolation.
1850    
1851    2003-10-21  Frank Koormann   <[email protected]>
1852    
1853            Popup menu for legend. Scheduled for the 1.2 release this was too
1854            simple to implement: The popup menu is bound to the legend tree, while
1855            the events are hanlded by its anchestor, the legend panel. This
1856            allows reuse of all the event handlers already implemented for the
1857            legend toolbar buttons.
1858    
1859            * Thuban/UI/legend.py (LegendPanel.__init__): EVT_MENU macros
1860            to add handlers for the events issued by the popup menu.
1861            (LegendPanel._OnToggleVisibility): Handler for toggling layer
1862            visibility event
1863            (LegendPanel._OnProjection): Handler for layer projection event.
1864            (LegendTree.__init__): Added EVT_TREE_ITEM_RIGHT_CLICK
1865            (LegendTree._OnRightClick): Event handler for right click, select item
1866            and pop up menu.
1867            (LegendTree.ToggleVisibility): Toggle layer visibility
1868            (LegendTree.LayerProjection): Raise layer projection dialog for
1869            current layer.
1870    
1871    2003-10-21  Bernhard Herzog  <[email protected]>
1872    
1873            * Resources/Projections/defaults.proj: Use correct DOCTYPE
1874            declaration. The top-level element is projectionlist not projfile
1875    
1876    2003-10-20  Bernhard Herzog  <[email protected]>
1877    
1878            * Thuban/UI/projdialog.py (ProjFrame.write_proj_file): New. helper
1879            method to write a projfile and display a busy cursor and error
1880            dialogs.
1881            (ProjFrame._OnSave, ProjFrame._OnAddToList, ProjFrame._OnImport)
1882            (ProjFrame._OnExport, ProjFrame._OnRemove): Use write_proj_file
1883            (ProjFrame.__FillAvailList): Translate "<None>" too and display a
1884            busy cursor while loading the user and system prj files.
1885    
1886    2003-10-16  Bernhard Herzog  <[email protected]>
1887    
1888            * Thuban/Model/resource.py (projfile_cache): Introduce a cache for
1889            ProjFile objects
1890            (clear_proj_file_cache): New function to clear the cache. Mainly
1891            useful for use by the test suite
1892            (read_proj_file): Use the cache.
1893    
1894            * test/test_proj.py (TestProjFile): Clarify the doc-string
1895            (ProjFileReadTests): Update doc-string
1896            (ProjFileReadTests.test_get_system_proj_file): Check whether the
1897            system proj files is cached.
1898            (ProjFileLoadTestCase): New base class for the proj file tests
1899            derived from support.FileLoadTestCase to provide some common
1900            behavior.
1901            (TestLoadingProjFile)
1902            (TestLoadingProjFileWithEmptyProjectionlist.file_contents)
1903            (TestProjFileWithInvalidParameters.file_contents): Derive from
1904            ProjFileLoadTestCase
1905            (TestLoadingProjFile.test_caching): New. Test whether the cache
1906            works
1907    
1908    2003-10-16      Silke Reimer    <[email protected]>
1909    
1910            * debian/*: New directory with configuration files for building a thuban
1911              deb-package.
1912    
1913    2003-10-14  Bernhard Herzog  <[email protected]>
1914    
1915            * test/test_proj.py: Execute support.run_tests when run as
1916            __main__ so that missing unsubscribes are detected
1917            (TestProjFile.tearDown): Destroy the proj_file properly
1918    
1919    2003-10-14  Bernhard Herzog  <[email protected]>
1920    
1921            * Thuban/Model/messages.py (PROJECTION_ADDED)
1922            (PROJECTION_REPLACED, PROJECTION_REMOVED): New message types for
1923            the ProjFile objects
1924    
1925            * Thuban/Model/proj.py (ProjFile): Derive from Publisher so we can
1926            easily send messages when the projections change
1927            (ProjFile.Add, ProjFile.Remove, ProjFile.Replace): Issue messages
1928            when the change was successful
1929    
1930            * test/test_proj.py (TestProjFile.setUp): Subscribe to some of the
1931            proj file messages
1932            (TestProjFile.test_add_remove)
1933            (TestProjFile.test_remove_non_existing)
1934            (TestProjFile.test_replace)
1935            (TestProjFile.test_replace_non_existing): Test whether the right
1936            messages are sent
1937    
1938    2003-10-14  Bernhard Herzog  <[email protected]>
1939    
1940            * test/test_proj.py (TestProjFile.test): Refactor into several
1941            tests
1942            (TestProjFile.test_add_remove)
1943            (TestProjFile.test_remove_non_existing)
1944            (TestProjFile.test_replace)
1945            (TestProjFile.test_replace_non_existing): Some of the new
1946            individual test cases
1947            (TestProjFileSimple): New class for the rest of the test cases
1948            that came out of the refactoring
1949            (ProjFileTest): Derive from xmlsupport.ValidationTest so that the
1950            derived classes don't have to
1951    
1952    2003-10-13  Bernhard Herzog  <[email protected]>
1953    
1954            Add an optional EPSG code to the projection objects and extend the
1955            .proj file format accordingly.
1956    
1957            * Resources/XML/projfile.dtd (element projection): Add epsg
1958            attribute
1959    
1960            * Thuban/Model/proj.py (Projection.__init__): New parameter and
1961            instance variable epsg. Update doc-string
1962            (Projection.EPSGCode, Projection.Label): New methods to provide
1963            access to EPSG code and a label for use in dialogs
1964    
1965            * Thuban/Model/resource.py (ProjFileReader.start_projection)
1966            (ProjFileReader.end_projection, ProjFileSaver.write_projfile):
1967            Handle the epsg code attribute when reading or writing proj files
1968    
1969            * Thuban/UI/projdialog.py (ProjFrame._OnSave)
1970            (ProjFrame._OnAddToList, ProjFrame.__DoOnProjAvail)
1971            (ProjFrame.__FillAvailList): Use the projection's Label method to
1972            get the string for the list box
1973    
1974            * test/test_proj.py (TestProjection.test_label)
1975            (TestProjection.test_label_epsg)
1976            (TestProjection.test_epsgcode_for_non_epsg_projection)
1977            (TestProjection.test_epsgcode_for_real_epsg_projection): New tests
1978            for the label and EPSGCode methods
1979            (WriteProjFileTests.doTestWrite, WriteProjFileTests.test_write)
1980            (WriteProjFileTests.test_write_empty_file): Create the ProjFile
1981            objects in the test cases and put the expected contents into the
1982            test case methods too. Update doTestWrite accordingly
1983            (TestLoadingProjFile)
1984            (TestLoadingProjFileWithEmptyProjectionlist): New classes with the
1985            read tests from TestProjFile.
1986            (TestProjFile.doTestRead, TestProjFile.testRead): Removed. These
1987            tests are now in the new classes.
1988            (sample_projfile, sample_projfile_data)
1989            (sample_projfile2, sample_projfile_data2): Removed. Not used
1990            anymore.
1991            (TestProjFile.test_read_unreadable_file): No need to reset the
1992            permissions at the end anymore since we use a unique filename
1993    
1994    2003-10-13  Bernhard Herzog  <[email protected]>
1995    
1996            * test/test_proj.py: Some more refactoring of the test cases
1997            (ProjFileTest): New base class for the proj file tests.
1998            (TestProjFile): Derive from ProjFileTest
1999            (TestProjFile.test_read_unreadable_file)
2000            (TestProjFile.test_read_empty_file, TestProjFile.doTestRead): Use
2001            the new filename method to get a unique filename
2002            (TestProjFile.doTestWrite, TestProjFile.testWrite): Removed.
2003            (WriteProjFileTests): New class for proj file write tests.
2004            Contains the write test that were in TestProjFile originally.
2005    
2006    2003-10-13  Bernhard Herzog  <[email protected]>
2007    
2008            * test/test_proj.py (TestProjFile.testRead)
2009            (TestProjFile.test_read_non_existing_file)
2010            (TestProjFile.test_read_unreadable_file)
2011            (TestProjFile.test_read_empty_file): Split into several methods.
2012    
2013    2003-10-10  Bernhard Herzog  <[email protected]>
2014    
2015            * Thuban/UI/sizers.py: New file with custom sizers.
2016    
2017            * Thuban/UI/projdialog.py (ProjFrame.build_dialog): Instantiate
2018            all projection type specific panels and put them into a
2019            NotebookLikeSizer. This way the dialog doesn't change its size
2020            when a different projection is selected
2021            (ProjFrame.__init__): Rename projection_panels
2022            projection_panel_defs and reuse projection_panels for a list of
2023            the instantiated panels.
2024            (ProjFrame._show_proj_panel, ProjFrame.__DoOnProjAvail)
2025            (ProjFrame.__DoOnProjChoice): Changes due to the new handling of
2026            the panels
2027            (UnknownProjPanel._DoLayout): Place the newlines in the message
2028            differently to make the panel narrower.
2029            (TMPanel._DoLayout): Layout the parameters in one column.
2030    
2031    2003-10-10  Bernhard Herzog  <[email protected]>
2032    
2033            * Thuban/UI/projdialog.py (ProjFrame.build_dialog): New method
2034            that contains all the setup for the dialog's widgets, layout and
2035            event handling.
2036            (__): Call build_dialog to build the dialog.
2037            (ProjFrame.__set_properties, ProjFrame.__do_layout): Removed.
2038            Their functionality is now in build_dialog
2039            (ProjFrame.__VerifyButtons, ProjFrame.__VerifyButtons)
2040            (ProjFrame.__DoOnProjAvail, ProjFrame.__DoOnProjAvail)
2041            (ProjFrame.__DoOnProjChoice): Small updates due to slightly
2042            different widget names and hierarchy introduced with build_dialog.
2043    
2044    2003-10-10  Bernhard Herzog  <[email protected]>
2045    
2046            * README: Fix typo.
2047    
2048    2003-10-09  Bernhard Herzog  <[email protected]>
2049    
2050            * Thuban/Model/proj.py (ProjFile.Add): Do not check whether the
2051            projection is already in the list. This is *a lot* faster when
2052            loading files with hundreds of projections since it saves a linear
2053            search. OTOH this will allow adding the same projection to the
2054            user.proj file multiple times in the projection dialog but we'll
2055            deal with that later
2056    
2057    2003-10-09  Jan-Oliver Wagner <[email protected]>
2058    
2059            * devtools: New. Directory for developer tools that are not intended
2060            for the regular user.
2061    
2062            * devtools/create_epsg.py: New. Convert the epsg file of proj into
2063            a python .proj file.
2064    
2065    2003-10-09  Bernhard Herzog  <[email protected]>
2066    
2067            * test/test_proj.py
2068            (TestProjection.test_get_parameter_without_equals_sign): New. Test
2069            whether GetParameter handles parameters without "=" sign correctly
2070    
2071            * Thuban/Model/proj.py (Projection.GetParameter): Handle
2072            parameters that do not contain a "=". Update the doc-string
2073    
2074    2003-10-08  Bernhard Herzog  <[email protected]>
2075    
2076            * Thuban/UI/projdialog.py (ProjFrame.__set_properties): Remove the
2077            length limit on the projname text control
2078    
2079    2003-10-08  Bernhard Herzog  <[email protected]>
2080    
2081            * test/test_proj.py (TestProjection.test_get_projection_units_geo)
2082            (TestProjection.test_get_projection_units_normal): New. Tests for
2083            the Projection.GetProjectedUnits method
2084    
2085    2003-10-08  Jan-Oliver Wagner <[email protected]>
2086    
2087            * Thuban/Model/resource.py (get_user_proj_file): small bug-fix:
2088            Added missing 'val' parameter.
2089    
2090    2003-10-08  Bernhard Herzog  <[email protected]>
2091    
2092            * Thuban/UI/projdialog.py (ProjFrame.__DoOnProjAvail): When the
2093            projection type of the currently selected projection is not known,
2094            i.e. there's no panel for it, use the UnknownProjPanel
2095            (ProjFrame.__DoOnProjChoice, ProjFrame._show_proj_panel): Split
2096            the actual replacing of the proj panel into the new method
2097            _show_proj_panel.
2098            (UnknownProjPanel): Add doc-string.
2099            (UnknownProjPanel._DoLayout): Insert a newline into the text so
2100            that the panel is not so wide.
2101    
2102    2003-10-08  Bernhard Herzog  <[email protected]>
2103    
2104            * Thuban/Model/resource.py (read_proj_file): Return the warnings
2105            too. Update the doc-string
2106            (get_proj_files): Removed. It wasn't used anywhere
2107            (get_system_proj_files, get_system_proj_file): Rename to
2108            get_system_proj_file and return the ProjFile object and not a list
2109            of ProjFile objects. Update the callers.
2110            (get_user_proj_files, get_user_proj_file): Rename to
2111            get_user_proj_file return the ProjFile object and not a list of
2112            ProjFile objects. Update the callers.
2113            (ProjFileReader.__init__): New instance variable for the warnings.
2114            Rename the __pf ivar to projfile. Update the methods referring to
2115            __pf
2116            (ProjFileReader.end_projection): Catch any errors raised when
2117            instantiating the projection and record that as an error. The
2118            projection will not be in the final ProjFile object.
2119            (ProjFileReader.GetWarnings): New method to return the warnings.
2120    
2121            * Thuban/UI/projdialog.py (ProjFrame.show_warnings): New method to
2122            show the warnings from the projfile reader
2123            (ProjFrame._OnImport): Deal with any warnings returned by
2124            read_proj_file
2125            (ProjFrame.__FillAvailList): Deal with any warnings returned by
2126            get_system_proj_file or get_user_proj_file.
2127    
2128            * test/test_proj.py (TestProjFile.doTestRead): Check the warnings.
2129            (TestProjFileWithInvalidParameters.file_contents): New test cases
2130            to test whether read_proj_file handles invalid projection
2131            parameters correctly
2132            (TestProjFile.test_get_system_proj_file): New. Simple test for
2133            resource.get_system_proj_file
2134    
2135    2003-10-07  Bernhard Herzog  <[email protected]>
2136    
2137            * test/test_derivedshapestore.py
2138            (TestDerivedShapeStoreExceptions.tearDown): Clear the session
2139            properly so that the temporary directories get deleted correctly
2140    
2141    2003-10-06  Bernhard Herzog  <[email protected]>
2142    
2143            Handle the title changes in a proper MVC way.
2144    
2145            * Thuban/UI/mainwindow.py (MainWindow.__init__): Subscribe to the
2146            canvas' TITLE_CHANGED messages
2147            (MainWindow.update_title): New. Update the main window's title
2148            (MainWindow.__SetTitle): Removed. Use update_title instead.
2149            (MainWindow.SetMap): Use update_title instead of __SetTitle
2150            (MainWindow.RenameMap): Do change the window title explicitly
2151            here. That's handled in a proper MVC way now.
2152            (MainWindow.title_changed): New. Subscriber for the TITLE_CHANGED
2153            messages
2154    
2155            * Thuban/Lib/connector.py (Conduit): New class to help classes
2156            that forward messages
2157    
2158            * Thuban/UI/viewport.py: Forward the map's TITLE_CHANGED messages
2159            (ViewPort): Derive from Conduit instead of Publisher
2160            (ViewPort.Subscribe, ViewPort.Unsubscribe): Use the new base class
2161            when calling the inherited versions
2162            (ViewPort._subscribe_map, ViewPort._unsubscribe_map): New helper
2163            methods to subscribe and unsubscribe map messages
2164            (ViewPort.SetMap, ViewPort.Destroy): Use the new helper methods to
2165            handle the map subscriptions
2166            (ViewPort.Map, ViewPort.map_projection_changed)
2167            (ViewPort.layer_projection_changed): Add or update doc-strings
2168    
2169            * test/test_connector.py (TestPublisher.test_issue_simple): Fix
2170            typo
2171            (MyConduit): Helper class for the Conduit test.
2172            (TestConduit): Test cases for Conduit
2173    
2174            * test/test_connector.py: Use support.run_tests as main.
2175    
2176            * test/test_viewport.py (ViewPortTest.setUp): Also subscribe to
2177            the TITLE_CHANGED messages
2178            (ViewPortTest.test_forwarding_title_changed): New test to check
2179            whether the viewport forwards the map's TITLE_CHANGED messages
2180            (TestViewportWithPostGIS.tearDown): Call the map's Destroy method
2181            after the port's because the latter may require a still functional
2182            map.
2183    
2184    2003-10-06  Bernhard Herzog  <[email protected]>
2185    
2186            * Thuban/UI/application.py (ThubanApplication.maps_changed): Add
2187            doc-string
2188    
2189    2003-10-06  Bernhard Herzog  <[email protected]>
2190    
2191            * test/test_viewport.py (ViewPortTest.setUp)
2192            (SimpleViewPortTest.test_init_with_size): Move the test for the
2193            initial size as a constructor parameter from ViewPortTest.setUp
2194            method to a new separate test in SimpleViewPortTest.
2195    
2196    2003-10-06  Bernhard Herzog  <[email protected]>
2197    
2198            * test/test_viewport.py (MockView): New class derived from
2199            ViewPort with a mock implementation of GetTextExtent to be used in
2200            the test cases
2201            (ViewPortTest.setUp): Use MockView instead of ViewPort
2202    
2203            * Thuban/UI/viewport.py (ViewPort.GetTextExtent): Turn this method
2204            into what would be a "pure virtual function" in C++: always raise
2205            NotImplementedError. Mock implementations for test cases don't
2206            belong into the real code
2207    
2208    2003-10-02  Bernhard Herzog  <[email protected]>
2209    
2210            * test/test_layer.py (TestLayer.test_empty_layer): Explicitly
2211            close the dbf file we create so that it's contents have been
2212            written properly.
2213    
2214            * libraries/shapelib/shptree.c, libraries/shapelib/shpopen.c,
2215            libraries/shapelib/shapefil.h, libraries/shapelib/dbfopen.c:
2216            Update to shapelib 1.2.10
2217    
2218    2003-10-01  Jan-Oliver Wagner <[email protected]>
2219    
2220            * Thuban/UI/tree.py, Thuban/UI/main.py: Remove the #! line as
2221            it annoys lintian which warns about these files not being
2222            executable. The #! isn't necessary here since if you absolutely
2223            must execute them you can always say "python <filename>".
2224    
2225    2003-09-26  Bernhard Herzog  <[email protected]>
2226    
2227            * Thuban/Model/classgen.py (GenQuantiles0): Removed since it's
2228            only used in GREAT-ER but not used in Thuban itself. When GREAT-ER
2229            is ported to a newer the import will fail, so it should be noticed
2230            immediately that this function is gone.
2231            Fixes RT#1919
2232    
2233    2003-09-26  Bernhard Herzog  <[email protected]>
2234    
2235            Add a DTD for the projection files and make thuban write valid
2236            projection files
2237    
2238            * Resources/XML/projfile.dtd: New. DTD for thuban's projection
2239            files
2240    
2241            * Thuban/Model/resource.py (ProjFileSaver.write): Use
2242            'projectionlist' as the name in the document type declaration so
2243            that it matches the element type of the root element.
2244    
2245            * test/test_proj.py (sample_projfile, sample_projfile2): Use
2246            'projectionlist' as the name in the document type declaration just
2247            as it is done now in the files thuban would write
2248            (sample_projfile, sample_projfile_data): Fix spelling of
2249            "Mercator"
2250            (TestProjFile.doTestWrite): Validate the written and the expected
2251            XML data
2252            (TestProjFile): Derive from ValidationTest so that we can run xml
2253            validation tests
2254    
2255    2003-09-24  Bernhard Herzog  <[email protected]>
2256    
2257            * Thuban/UI/renderer.py (ExportRenderer.render_legend): Do not
2258            modify the list returned by map.Layers() in place since it is the
2259            actual list of layers used by the map.
2260    
2261    2003-09-23  Jan-Oliver Wagner <[email protected]>
2262    
2263            * Doc/manual/thuban-manual.xml: Added subsection to chapter
2264            Extensions to describe the extensions coming with the Thuban
2265            standard package (gns2shp and importAPR).
2266    
2267    2003-09-23  Bernhard Herzog  <[email protected]>
2268    
2269            * libraries/thuban/wxproj.cpp (project_point): if there's an
2270            inverse but no forward projection, convert to degrees after
2271            applying the inverse projection. Fixes RT#2096
2272    
2273            * test/test_wxproj.py: New. Test cases for wxproj.so. One test
2274            implicitly tests for the fix to RT#2096
2275    
2276            * test/support.py (FloatComparisonMixin.assertFloatSeqEqual):
2277            Check that the sequences have the same lengths
2278    
2279            * Resources/Projections/defaults.proj (Geographic projection): Use
2280            a much more precise value for the to_meter attribute.
2281    
2282    2003-09-22  Bernhard Herzog  <[email protected]>
2283    
2284            * test/support.py (initthuban): Make sure to unset the LANG env.
2285            var. so that tests that compare translated strings work. Solves RT
2286            #2094
2287    
2288    2003-09-22  Jan-Oliver Wagner <[email protected]>
2289    
2290            Small improvement of APR import.
2291    
2292            * Extensions/importAPR/test/test_apr.py (aprTest.test_LClass):
2293            Added tests for text-ranges.
2294    
2295            * Extensions/importAPR/apr.py (APR_LClass.GetThubanRange): Now
2296            returns a string object if the range is based on text.
2297    
2298            * Extensions/importAPR/importAPR.py (import_apr_dialog): Unified
2299            range retrieval.
2300    
2301    2003-09-22  Jan-Oliver Wagner <[email protected]>
2302    
2303            Initial version of the importAPR extension which is in
2304            experimental state.
2305    
2306            * /Extensions/importAPR/, /Extensions/importAPR/samples/,
2307            /Extensions/importAPR/test/: New directories.
2308    
2309            * /Extensions/importAPR/samples/README: New: Howto load the samples.
2310    
2311            * /Extensions/importAPR/samples/iceland.apr: New: A sample APR
2312            file which refers to the Thuban Iceland demo data.
2313    
2314            * /Extensions/importAPR/test/README: New: Howto execute the tests.
2315    
2316            * /Extensions/importAPR/test/test_apr.py: New: Tests for APR classes.
2317    
2318            * /Extensions/importAPR/apr.py: New: Classes for ArcView Objects
2319            as in '.apr'-files.
2320    
2321            * /Extensions/importAPR/odb.py: New: Classes for generic ArcView
2322            ODB Objects as in '.apr', '.avl' and other files.
2323    
2324            * /Extensions/importAPR/__init__.py: New: Init to make this
2325            directory a package.
2326    
2327            * /Extensions/importAPR/importAPR.py: New: Import a ArcView
2328            project file (.apr) and convert it to Thuban.
2329    
2330    2003-09-22  Jan-Oliver Wagner <[email protected]>
2331    
2332            * Extensions/gns2shp.gns2shp.py: The main module of gns2shp.
2333    
2334    2003-09-19  Jan-Oliver Wagner <[email protected]>
2335    
2336            * Doc/manual/thuban-manual.xml: Extended section 'Installation'
2337            with description on RPM installation and RPM binary package
2338            creation.
2339    
2340    2003-09-18  Bernhard Herzog  <[email protected]>
2341    
2342            * setup.py (data_files): Only add the mo files if the Locales
2343            directory actually exists, so that setup.py works with a fresh CVS
2344            checkout
2345    
2346    2003-09-12  Jan-Oliver Wagner <[email protected]>
2347    
2348            * Examples/simple_extensions/simple_tool.py: bugfix: Tool is now
2349            in viewport, not anymore in view
2350    
2351    2003-09-04  Jan-Oliver Wagner <[email protected]>
2352    
2353            Introducing first Extension (gns2shp).
2354    
2355            * Extensions, Extensions/gns2shp, Extensions/gns2shp/test: New.
2356    
2357            * Extensions/__init__.py: New. init to make this dir a package.
2358    
2359            * Extensions/gns2shp/__init__.py: New. init to make this dir a package.
2360    
2361            * Extensions/gns2shp/test/README: New. some info on this test directory.
2362    
2363            * Extensions/gns2shp/test/ls.txt: New. test data set (Liechtenstein).
2364    
2365            * Extensions/gns2shp/test/test_gns2shp.py: New. Test for correct creation
2366            of Shapefile from GNS text file format
2367    
2368    2003-09-03  Jan-Oliver Wagner <[email protected]>
2369    
2370            Fix/workaround for bug #2019:
2371            https://intevation.de/rt/webrt?serial_num=2019
2372    
2373            * Thuban/UI/identifyview.py (IdentifyView.ID_STOP): New.
2374            (IdentifyView.__init__): Added another button that allows to
2375            stop the identify mode.
2376            (IdentifyView.OnStop): New. Stops the identify mode.
2377    
2378    2003-09-03  Jan-Oliver Wagner <[email protected]>
2379    
2380            Introducing a new exception dialog that allows to exit the
2381            application immediately.
2382            This fixes bug #2060: https://intevation.de/rt/webrt?serial_num=2060
2383    
2384            * Thuban/UI/exceptiondialog.py: New. A special exception dialog.
2385    
2386            * Thuban/UI/application.py (ThubanApplication.ShowExceptionDialog):
2387            Made strings available to translations. Exchanged the simple
2388            ScrolledMessageDialog by the new ExceptionDialog.
2389    
2390    2003-09-01  Bernhard Herzog  <[email protected]>
2391    
2392            * NEWS: New. Summary of changes and release notes.
2393    
2394            * MANIFEST.in: Add NEWS
2395    
2396    2003-09-01  Bernhard Herzog  <[email protected]>
2397    
2398            * MANIFEST.in: Correct the include statement for the mo-files and
2399            include the documentation too.
2400    
2401            * setup.py (data_files): Add the .mo files
2402            (setup call): Up to version 0.9.0
2403    
2404    2003-09-01  Bernhard Herzog  <[email protected]>
2405    
2406            * Thuban/UI/dbdialog.py (ChooseDBTableDialog.__init__): Change the
2407            parameter list to just parent and session
2408            (ChooseDBTableDialog.__set_properties): Removed. Setting the
2409            selection of empty list boxes is not allowed (and produces C++
2410            assertion errors) and the rest of the setup is better done in
2411            __init__ anyway.
2412            (ChooseDBTableDialog.OnCancel, ChooseDBTableDialog.OnOK)
2413            (ChooseDBTableDialog.OnLBDClick, DBDialog.OnOK): Use the Python
2414            builtins True/False for booleans to avoid warnings from wxPython
2415    
2416            * Thuban/UI/mainwindow.py (MainWindow.AddDBLayer): Adapt to new
2417            ChooseDBTableDialog constructor parameters.
2418    
2419    2003-09-01  Bernhard Herzog  <[email protected]>
2420    
2421            * Thuban/Model/postgisdb.py
2422            (PostGISTable): Extend doc-string
2423            (PostGISTable._fetch_table_information): Set the column index
2424            correctly, pretending ignored columns don't exist.
2425    
2426            * test/test_postgis_db.py (TestPostGISIgnoredColumns): New tests
2427            for postgis tables with data types not yet supported by thuban.
2428    
2429    2003-08-29  Bernhard Herzog  <[email protected]>
2430    
2431            * HOWTO-Release: Tweak item about running the tests.
2432    
2433    2003-08-29  Jan-Oliver Wagner <[email protected]>
2434    
2435            * /Doc/manual/thuban-manual.xml: updated to version 1.0pre2.
2436    
2437    2003-08-29  Bernhard Herzog  <[email protected]>
2438    
2439            Add some missing parameters to projections. Proj complains about
2440            them on windows but for some reason not on Linux.
2441    
2442            * test/test_save.py (SaveSessionTest.testLayerProjection): Add
2443            missing required projection parameters
2444    
2445            * test/test_proj.py (TestProjFile.test): Add missing required
2446            projection parameters
2447    
2448            * test/test_load_0_8.py (TestLayerProjection.file_contents)
2449            (TestLayerProjection.test): Add missing required projection
2450            parameters and tests for them
2451    
2452            * test/test_load.py (TestLayerProjection.file_contents)
2453            (TestLayerProjection.test): Add missing required projection
2454            parameters and tests for them
2455    
2456            * test/test_layer.py (TestLayer.test_base_layer): Add missing
2457            required projection parameters
2458    
2459    2003-08-29  Bernhard Herzog  <[email protected]>
2460    
2461            * libraries/pyprojection/Projection.i: Use pj_get_errno_ref to
2462            access the pj_errno because directly accessing pj_errno doesn't
2463            work on windows if the proj library is in a DLL
2464    
2465            * libraries/pyprojection/Projection_wrap.c: Update from Projection.i
2466    
2467    2003-08-28  Bernhard Herzog  <[email protected]>
2468    
2469            * test/test_proj.py: Import things from Thuban after calling
2470            initthuban
2471    
2472            * test/test_load.py (LoadSessionTest.filenames): New class
2473            variable with the filename attributes to normalize
2474            (LoadSessionTest.check_format): Pass self.filenames to
2475            sax_eventlist to normalize the filename attributes
2476    
2477            * test/xmlsupport.py: Add cvs keywords
2478            (SaxEventLister.__init__): New parameter filenames which indicates
2479            attributes that contain filenames
2480            (SaxEventLister.startElementNS): Normalize the filename attributes
2481            with os.path.normpath
2482            (sax_eventlist): New parameter filenames to pass through to
2483            SaxEventLister
2484    
2485            * test/test_derivedshapestore.py: Make this file callable as a
2486            program to execute the tests
2487            (TestDerivedShapeStoreExceptions.test_table_with_wrong_size): Bind
2488            the session to self.session so that it gets destroyed properly
2489    
2490            * test/test_layer.py (TestLayer.tearDown): Call the session's
2491            Destroy method
2492    
2493            * test/test_map.py (TestMapBase.tearDown): Destroy self.session
2494            too if it exists
2495            (TestMapAddLayer.test_add_layer): Bind the session to self.session
2496            so that it gets destroyed properly
2497    
2498            * test/postgissupport.py (reason_for_not_running_tests): Add a
2499            test for the existence of popen2.Popen4.
2500    
2501            * test/test_save.py (SaveSessionTest.tearDown): New. Provide a
2502            reliable way to destroy the sessions created in the test cases
2503            (SaveSessionTest.test_dbf_table): Bind the session to self.session
2504            so that it gets destroyed properly
2505            (SaveSessionTest.testLayerProjection): Bind the session to
2506            self.session so that it gets destroyed properly
2507    
2508            * test/test_session.py (UnreferencedTablesTests.tearDown): Make
2509            sure that the session is destroyed properly
2510    
2511            * test/test_shapefilestore.py: Make this callable as a program to
2512            execute the tests
2513    
2514            * test/test_scalebar.py: Remove unnecessary import of _ from
2515            Thuban
2516    
2517            * test/support.py (print_garbage_information): Call initthuban
2518            here because it may be called indirectly from test cases that test
2519            test support modules which do not use anything from thuban itself
2520            (ThubanTestProgram.runTests): Remove unnecessary debug print
2521    
2522    2003-08-28  Bernhard Herzog  <[email protected]>
2523    
2524            * Thuban/version.py (longversion): Update to 0.9
2525    
2526            * Thuban/UI/mainwindow.py: Remove some unused imports
2527    
2528            * README: Add section about required additional software. Add date
2529            and revision CVS keywords
2530    
2531            * HOWTO-Release: Add item about the translations. Add date and
2532            revision CVs keywords and change formatting to match README a bit
2533            better
2534    
2535            * po/de.po: Update for 0.9
2536    
2537            * test/README: Tweak the wording a little because many tests are
2538            not really unittest.
2539    
2540    2003-08-27  Bernhard Herzog  <[email protected]>
2541    
2542            As preparation for the 0.9 release, switch thuban files to a
2543            non-dev namespace
2544    
2545            * Thuban/Model/save.py (SessionSaver.write_session): Write files
2546            with the http://thuban.intevation.org/dtds/thuban-0.9.dtd
2547            namespace
2548    
2549            * Thuban/Model/load.py (SessionLoader.__init__): Accept the
2550            http://thuban.intevation.org/dtds/thuban-0.9.dtd namespace too
2551    
2552            * test/test_save.py (SaveSessionTest.dtd)
2553            (SaveSessionTest.testEmptySession)
2554            (SaveSessionTest.testSingleLayer)
2555            (SaveSessionTest.testLayerProjection)
2556            (SaveSessionTest.testRasterLayer)
2557            (SaveSessionTest.testClassifiedLayer)
2558            (SaveSessionTest.test_dbf_table)
2559            (SaveSessionTest.test_joined_table)
2560            (SaveSessionTest.test_save_postgis): Update for new namespace
2561    
2562            * test/test_load.py (LoadSessionTest.dtd, TestSingleLayer)
2563            (TestLayerVisibility.file_contents, TestLabels.file_contents)
2564            (TestLayerProjection.file_contents)
2565            (TestRasterLayer.file_contents, TestJoinedTable.file_contents)
2566            (TestPostGISLayer.file_contents)
2567            (TestPostGISLayerPassword.file_contents)
2568            (TestLoadError.file_contents, TestLoadError.test): Update for new
2569            namespace
2570    
2571    2003-08-27  Bernhard Herzog  <[email protected]>
2572    
2573            Make the table interface distinguish between row ids (an integer
2574            that uniquely identifies a row) and row ordinals (a simple row
2575            count from 0 to NumRows() - 1)
2576    
2577            * Thuban/Model/postgisdb.py (PostGISTable.RowIdToOrdinal)
2578            (PostGISTable.RowOrdinalToId): New methods to conver between row
2579            ids and row ordinals
2580            (PostGISTable.ReadRowAsDict, PostGISTable.ReadValue): New keyword
2581            parameter row_is_ordinal to indicate whether the row parameter is
2582            the row id or the ordinal
2583    
2584            * Thuban/Model/transientdb.py (TransientTableBase.RowIdToOrdinal)
2585            (TransientTableBase.RowOrdinalToId)
2586            (AutoTransientTable.RowIdToOrdinal)
2587            (AutoTransientTable.RowOrdinalToId): Same new methods as in
2588            PostGISTable.
2589            (TransientTableBase.ReadRowAsDict, TransientTableBase.ReadValue)
2590            (AutoTransientTable.ReadRowAsDict, AutoTransientTable.ReadValue):
2591            Same new parameter as in PostGISTable.
2592    
2593            * Thuban/Model/table.py (DBFTable.RowIdToOrdinal)
2594            (DBFTable.RowOrdinalToId, MemoryTable.RowIdToOrdinal)
2595            (MemoryTable.RowOrdinalToId): Same new methods as in PostGISTable.
2596            (DBFTable.ReadValue, DBFTable.ReadRowAsDict)
2597            (MemoryTable.ReadValue, MemoryTable.ReadRowAsDict): Same new
2598            parameter as in PostGISTable.
2599    
2600            * Thuban/UI/tableview.py (DataTable.RowIdToOrdinal)
2601            (DataTable.RowOrdinalToId): New methods to convert between row ids
2602            and row ordinals.
2603            (TableGrid.SelectRowById): New method to select a row based on its
2604            ID as opposed to its ordinal
2605            (DataTable.GetValue, TableGrid.OnRangeSelect)
2606            (TableGrid.OnSelectCell, LayerTableGrid.select_shapes)
2607            (QueryTableFrame.OnQuery, QueryTableFrame.get_selected)
2608            (LayerTableFrame.__init__): Convert between row ids and row
2609            ordinals as appropriate
2610    
2611            * test/postgissupport.py (PostGISDatabase.__init__): Add
2612            doc-string.
2613            (PostGISDatabase.initdb): The optional third item in a tuple in
2614            tables is now a (key, value) list with additional arguments to
2615            pass to upload_shapefile
2616            (upload_shapefile): New parameter gid_offset to allow gids that
2617            are not the same as the shapeids in the shapefile
2618            (PostgreSQLServer.get_default_static_data_db): Use the new
2619            gid_offset to make the gids in landmarks 1000 higher than the
2620            shapeids in the shapefile
2621    
2622            * test/test_viewport.py
2623            (TestViewportWithPostGIS.test_find_shape_at_point): Adapt to the
2624            new shapeids in the landmarks table
2625    
2626            * test/test_transientdb.py
2627            (TestTransientTable.run_iceland_political_tests)
2628            (TestTransientTable.test_transient_joined_table): Add tests for
2629            the new table methods and new keywords arguments.
2630    
2631            * test/test_postgis_db.py
2632            (TestPostGISTable.test_read_row_as_dict_row_count_mode)
2633            (TestPostGISTable.test_read_value_row_count_mode)
2634            (TestPostGISTable.test_row_id_to_ordinal)
2635            (TestPostGISTable.test_row_oridnal_to_id): New test for the new
2636            table methods and the new arguments
2637            (TestPostGISShapestorePoint.test_shapes_in_region)
2638            (TestPostGISShapestorePoint.test_shape_raw_data)
2639            (TestPostGISShapestorePoint.test_shape_points)
2640            (TestPostGISShapestorePoint.test_shape_shapeid)
2641            (TestPostGISShapestorePoint.test_all_shapes)
2642            (TestPostGISTable.test_simple_query)
2643            (TestPostGISTable.test_simple_query)
2644            (TestPostGISTable.test_simple_query)
2645            (TestPostGISTable.test_read_value)
2646            (TestPostGISTable.test_read_row_as_dict): Adapt to the new
2647            shapeids in the landmarks table
2648    
2649            * test/test_memory_table.py
2650            (TestMemoryTable.test_read_row_as_dict_row_count_mode)
2651            (TestMemoryTable.test_read_value_row_count_mode)
2652            (TestMemoryTable.test_row_id_to_ordinal)
2653            (TestMemoryTable.test_row_oridnal_to_id): New test for the new
2654            table methods and the new arguments
2655    
2656            * test/test_dbf_table.py
2657            (TestDBFTable.test_read_row_as_dict_row_count_mode)
2658            (TestDBFTable.test_read_value_row_count_mode)
2659            (TestDBFTable.test_row_id_to_ordinal)
2660            (TestDBFTable.test_row_oridnal_to_id): New test for the new table
2661            methods and the new arguments
2662    
2663    2003-08-26  Bernhard Herzog  <[email protected]>
2664    
2665            * Thuban/Model/postgisdb.py (PostGISShapeStore.BoundingBox): Use a
2666            more postgis specific but much faster method to get the bounding
2667            box
2668    
2669    2003-08-26  Bernhard Herzog  <[email protected]>
2670    
2671            * Thuban/Model/postgisdb.py (PostGISTable.Title)
2672            (PostGISShapeStore.AllShapes): Add these missing methods.
2673            (PostGISShapeStore.ShapesInRegion): No need to raise
2674            StopIteration. We can simply return
2675    
2676            * test/test_postgis_db.py (TestPostGISTable.test_title)
2677            (TestPostGISShapestorePoint.test_all_shapes): New tests for the
2678            new methods
2679    
2680    2003-08-25  Bernhard Herzog  <[email protected]>
2681    
2682            * Thuban/Model/postgisdb.py (shapetype_map): Add MUTLIPOLYGON.
2683    
2684            * test/test_postgis_db.py (PolygonTests): New class containing
2685            those tests from TestPostGISShapestorePolygon that can also be
2686            used to test MUTLIPOLYGON tables
2687            (TestPostGISShapestorePolygon): Most tests are now in PolygonTests
2688            so derive from that
2689            (TestPostGISShapestoreMultiPolygon): New class with tests for
2690            MUTLIPOLYGON tables
2691    
2692            * test/postgissupport.py (PostGISDatabase.initdb): Allow the
2693            tables argument to have tuples with three items to override the
2694            WKT type used.
2695            (PostgreSQLServer.get_default_static_data_db): Use the above to
2696            create a polygon table with MUTLIPOLYGONs
2697            (point_to_wkt, coords_to_point, polygon_to_wkt, coords_to_polygon)
2698            (arc_to_wkt, coords_to_multilinestring): Rename from *_to_wkt to
2699            coords_to*
2700            (coords_to_multipolygon): New. Convert to MUTLIPOLYGON
2701            (wkt_converter): New. Map WKT types to converters
2702            (upload_shapefile): New parameter force_wkt_type to use a
2703            different WKT type than the default
2704    
2705    2003-08-25  Bernhard Herzog  <[email protected]>
2706    
2707            * Thuban/UI/application.py
2708            (ThubanApplication.run_db_param_dialog): New. Suitable as a
2709            db_connection_callback. Main difference is that the dialog run
2710            from this method doesn't have a parent so it can be used even when
2711            there is no main window
2712            (ThubanApplication.OpenSession): Use self.run_db_param_dialog if
2713            no db_connection_callback was given. This way the dialog pops up
2714            even when the .thuban file was given as a command line parameter.
2715    
2716    2003-08-25  Bernhard Herzog  <[email protected]>
2717    
2718            * Thuban/UI/view.py (MapCanvas.OnLeftUp): Release the the mouse
2719            before calling MouseLeftUp. MouseLeftUp may pop up modal dialogs
2720            which leads to an effectively frozen X session because the user
2721            can only interact with the dialog but the mouse is still grabbed
2722            by the canvas.
2723            Also, call the tool's Hide method before MouseLeftUp because
2724            MouseLeftUp may change the tool's coordinates.
2725    
2726    2003-08-25  Bernhard Herzog  <[email protected]>
2727    
2728            * Thuban/UI/application.py (ThubanApplication.OpenSession): Catch
2729            LoadCancelled exceptions and handle them by returning immediately.
2730    
2731    2003-08-25  Bernhard Herzog  <[email protected]>
2732    
2733            GUI part of loading sessions with postgis connections which may
2734            require user interaction to get passwords or updated parameters
2735    
2736            * Thuban/UI/dbdialog.py (DBDialog): Reimplement to make it look a
2737            bit nucer and be more generic.
2738            (DBFrame.OnAdd): Adapt to new DBDialog interface
2739    
2740            * Thuban/UI/application.py (ThubanApplication.OpenSession): New
2741            optional parameter db_connection_callback which is passed to
2742            load_session.
2743    
2744            * Thuban/UI/mainwindow.py (MainWindow.run_db_param_dialog): New.
2745            Suitable as a db_connection_callback
2746            (MainWindow.OpenSession): Use self.run_db_param_dialog as the
2747            db_connection_callback of the application's OpenSession method
2748    
2749    
2750    2003-08-25  Bernhard Herzog  <[email protected]>
2751    
2752            Basic loading of sessions containing postgis connections:
2753    
2754            * Thuban/Model/load.py (LoadError): Add doc-string
2755            (LoadCancelled): New exception class to indicate a cancelled load
2756            (SessionLoader.__init__): Add the db_connection_callback parameter
2757            which will be used by the loader to get updated parameters and a
2758            password for a database connection
2759            (SessionLoader.__init__): Add the new XML elements to the
2760            dispatchers dictionary
2761            (SessionLoader.check_attrs): Two new conversions, ascii to convert
2762            to a byte-string object and idref as a generic id reference
2763            (SessionLoader.start_dbconnection)
2764            (SessionLoader.start_dbshapesource): New. Handlers for the new XML
2765            elements
2766            (load_session): Add the db_connection_callback to pass through the
2767            SessionLoader
2768    
2769            * test/test_load.py (TestPostGISLayer, TestPostGISLayerPassword):
2770            New classes to test loading of sessions with postgis database
2771            connections.
2772    
2773    2003-08-25  Bernhard Herzog  <[email protected]>
2774    
2775            * Thuban/UI/mainwindow.py (__ThubanVersion__): Remove this and
2776            replace it and the comment with __BuildDate__ by the Source: and
2777            Id: cvs keywords as used in the other files.
2778    
2779    2003-08-25  Bernhard Herzog  <[email protected]>
2780    
2781            * Thuban/Model/load.py (SessionLoader.check_attrs): Raise a
2782            LoadError when a required attribute is missing. The code used to
2783            be commented out for some reason, but probably should have been
2784            active.
2785    
2786            * test/test_load.py (TestLoadError.test): Test the message in the
2787            LoadError too to make sure it really is about the missing
2788            attribute
2789    
2790    2003-08-22  Bernhard Herzog  <[email protected]>
2791    
2792            * test/test_save.py (SaveSessionTest.test_dbf_table)
2793            (SaveSessionTest.test_joined_table): Add XML validation tests.
2794    
2795    2003-08-22  Bernhard Herzog  <[email protected]>
2796    
2797            Implement saving a session with a postgis connection
2798    
2799            * Resources/XML/thuban-0.9.dtd (dbconnection, dbshapesource) New
2800            elements for database connections and shapestores using db
2801            connections
2802            (session): Add the dbconnections to the content model
2803    
2804            * Thuban/Model/save.py (SessionSaver.write_db_connections): New.
2805            Write the db connections
2806            (SessionSaver.write_session): Call write_db_connections to write
2807            the connection before the data sources
2808            (SessionSaver.write_data_containers): Handle postgis shapestores
2809    
2810            * test/test_save.py (SaveSessionTest.thubanids)
2811            (SaveSessionTest.thubanidrefs): Update for new DTD
2812            (SaveSessionTest.test_save_postgis): New. Test saving a session
2813            with postgis connections
2814    
2815            * Thuban/Model/postgisdb.py (PostGISTable.DBConnection)
2816            (PostGISTable.TableName): New accessor methods for the connection
2817            and table name
2818    
2819            * test/test_postgis_db.py (TestPostGISTable.test_dbconn)
2820            (TestPostGISTable.test_dbname): New methods to test the new
2821            PostGISConnection methods
2822    
2823    2003-08-22  Bernhard Herzog  <[email protected]>
2824    
2825            * Thuban/Model/postgisdb.py (ConnectionError): New exception class
2826            for exceptions occurring when establishing a Database connection
2827            (PostGISConnection.connect): Catch psycopg.OperationalError during
2828            connects and raise ConnectionError.
2829    
2830            * test/test_postgis_db.py (TestPostgisDBExceptions): New class for
2831            tests for database exceptions
2832    
2833    2003-08-22  Bernhard Herzog  <[email protected]>
2834    
2835            Prepare the test suite for tests with required authentication
2836    
2837            * test/postgissupport.py (PostgreSQLServer.__init__): Add instance
2838            variables with two predefined users/passwords, one for the admin
2839            and one for a non-privileged user.
2840            (PostgreSQLServer.createdb): Pass the admin name to initdb and add
2841            the non-privileged user to the database and set the admin password
2842            (PostgreSQLServer.wait_for_postmaster): Use the admin user name.
2843            Better error reporting
2844            (PostgreSQLServer.connection_params)
2845            (PostgreSQLServer.connection_string): New methods to return
2846            information about how to connect to the server
2847            (PostgreSQLServer.execute_sql): New. Convenience method to execute
2848            SQL statements
2849            (PostgreSQLServer.require_authentication): Toggle whether the
2850            server requires authentication
2851            (PostgreSQLServer.create_user, PostgreSQLServer.alter_user): New.
2852            Add or alter users
2853            (PostGISDatabase.initdb): Pass the admin name one the
2854            subprocesses' command lines. Grant select rights on
2855            geometry_columns to everybody.
2856            (upload_shapefile): Use the admin name and password when
2857            connecting. Grant select rights on the new table to everybody.
2858    
2859            * test/test_viewport.py (TestViewportWithPostGIS.setUp): Use the
2860            server's new methods to get the connection parameters.
2861    
2862            * test/test_postgis_session.py (TestSessionWithPostGIS.setUp)
2863            (TestSessionWithPostGIS.test_remove_dbconn_exception): Use the
2864            server's new methods to get the connection parameters.
2865    
2866            * test/test_postgis_db.py
2867            (TestPostGISConnection.test_gis_tables_empty)
2868            (TestPostGISConnection.test_gis_tables_non_empty)
2869            (PostGISStaticTests.setUp): Use the server's new methods to get
2870            the connection parameters.
2871    
2872    2003-08-22  Bernhard Herzog  <[email protected]>
2873    
2874            * Thuban/UI/about.py (About.__init__): Add the psycopg version.
2875    
2876            * Thuban/version.py: Add psycopg version
2877    
2878            * Thuban/Model/postgisdb.py (psycopg_version): New. Return the
2879            version of the psycopg module
2880    
2881    2003-08-22  Bernhard Herzog  <[email protected]>
2882    
2883            * Thuban/UI/dbdialog.py (DBPwdDlg): Removed because it's not used.
2884            (DBFrame.OnEdit): Removed because it's not used and wouldn't work
2885            at the moment. The functionality should probably be implemented
2886            some time, though.
2887            (DBFrame.OnRemove): Display a message if the connection can't be
2888            removed because it's still in use.
2889    
2890    2003-08-22  Jan-Oliver Wagner <[email protected]>
2891    
2892            * Thuban/UI/about.py (About.__init__): split up the huge about
2893            text into elements/lists for easier translation. This fixes bug
2894            https://intevation.de/rt/webrt?serial_num=2058
2895            Also, made some forgotten string available for the i18n.
2896    
2897    2003-08-21  Bernhard Herzog  <[email protected]>
2898    
2899            Make postgis support really optional including insensitive menu
2900            items.
2901    
2902            * Thuban/Model/postgisdb.py (has_postgis_support): New. Return
2903            whether the postgis is supported.
2904    
2905            * Thuban/UI/dbdialog.py: Put the psycopg import into try..except
2906            to make postgis support optional
2907    
2908            * Thuban/UI/mainwindow.py (_has_postgis_support): New. Context
2909            version of Thuban.Model.postgisdb.has_postgis_support
2910            (database_management command): Make it only sensitive if postgis
2911            is supported.
2912    
2913    2003-08-21  Jan-Oliver Wagner <[email protected]>
2914    
2915            * Doc/manual/thuban-manual.xml: Added CVS revision for rev-history.
2916            (section Adding and Removing Layers): Added text and described
2917            multi-selection.
2918            (chapter Extensions): New.
2919    
2920    2003-08-21  Jan-Oliver Wagner <[email protected]>
2921    
2922            * Thuban/UI/mainwindow.py (MainWindow.AddLayer): Changed dialog
2923            settings to allow multiple files to load into the map.
2924            Also reduced selection to *.shp as a default.
2925    
2926    2003-08-20  Bernhard Herzog  <[email protected]>
2927    
2928            Add dialogs and commands to open database connections and add
2929            database layers.
2930    
2931            * Thuban/UI/mainwindow.py (MainWindow.DatabaseManagement): New
2932            method to open the database connection management dialog
2933            (MainWindow.AddDBLayer): New method to add a layer from a database
2934            (_has_dbconnections): New helper function to use for sensitivity
2935            (database_management command, layer_add_db command): New commands
2936            that call the above new methods.
2937            (main_menu): Add the new commands to the menu.
2938    
2939            * Thuban/Model/postgisdb.py (PostGISConnection.__init__)
2940            (PostGISConnection.connect): Establish the actual connection in a
2941            separate method and call it in __init__. This makes it easier to
2942            override the behavior in test cases
2943            (PostGISConnection.BriefDescription): New method to return a brief
2944            description for use in dialogs.
2945    
2946            * test/test_postgis_db.py (NonConnection): DB connection that
2947            doesn't actually connect
2948            (TestBriefDescription): New class with tests for the new
2949            BriefDescription method
2950    
2951    2003-08-19  Jan-Oliver Wagner <[email protected]>
2952    
2953            Moved anything from extensions to libraries.
2954    
2955            * libraries: New.
2956    
2957            * libraries/ pyprojection, pyshapelib, shapelib, thuban: New.
2958    
2959            * libraries/pyprojection/ LICENSE, MANIFEST.in, Projection.i,
2960            Projection.py, Projection_wrap.c, setup.py, swighelp.txt: These files have
2961            been moved here from thuban/extensions/pyprojection/
2962            See there in the Attic for the older history.
2963    
2964            * libraries/pyshapelib/ COPYING, ChangeLog, NEWS, README, dbflib.i,
2965            dbflib.py, dbflib_wrap.c, pyshapelib_api.h, pytest.py, setup.py,
2966            shapelib.i, shapelib.py, shapelib_wrap.c, shptreemodule.c: These files
2967            have been moved here from thuban/extensions/pyshapelib/
2968            See there in the Attic for the older history.
2969    
2970            * libraries/shapelib/ dbfopen.c, shapefil.h, shpopen.c, shptree.c: These
2971            files have been moved here from thuban/extensions/shapelib/
2972            See there in the Attic for the older history.
2973    
2974            * libraries/thuban/ bmpdataset.cpp, cpl_mfile.cpp, cpl_mfile.h,
2975            gdalwarp.cpp, wxproj.cpp: These files have been moved here from
2976            thuban/extensions/thuban/
2977            See there in the Attic for the older history.
2978    
2979            * MANIFEST.in, setup.cfg, setup.py: renamed extensions to libraries.
2980    
2981            * extensions/thuban/ bmpdataset.cpp, cpl_mfile.cpp, cpl_mfile.h,
2982            gdalwarp.cpp, wxproj.cpp: Moved to libraries/thuban.
2983    
2984            * extensions/shapelib/ dbfopen.c, shapefil.h, shpopen.c, shptree.c:
2985            Moved to libraries/shapelib.
2986    
2987            * extensions/pyshapelib/ COPYING, NEWS, dbflib.py, pytest.py,
2988            shapelib.py, README, dbflib_wrap.c, setup.py, shapelib_wrap.c,
2989            ChangeLog, dbflib.i, pyshapelib_api.h, shapelib.i, shptreemodule.c:
2990            Moved to libraries/pyshapelib.
2991    
2992            * extensions/pyprojection/ MANIFEST.in, Projection.py, setup.py,
2993            LICENSE, Projection.i, Projection_wrap.c, swighelp.txt:
2994            Moved to libraries/pyprojection.
2995    
2996            * extensions/ pyprojection, pyshapelib, shapelib, thuban: Removed.
2997    
2998            * extensions: Removed.
2999    
3000    2003-08-19  Bernhard Herzog  <[email protected]>
3001    
3002            * test/test_viewport.py (ViewPortTest): We don't use the
3003            facilities of FileTestMixin so don't derive from it.
3004            (TestViewportWithPostGIS): New class with tests for using a
3005            viewport on a map with postgis layers.
3006    
3007    2003-08-19  Bernhard Herzog  <[email protected]>
3008    
3009            Add the db connection management to the session.
3010    
3011            * Thuban/Model/session.py (Session.__init__): New instance
3012            variable db_connections
3013            (Session.AddDBConnection, Session.DBConnections)
3014            (Session.HasDBConnections, Session.CanRemoveDBConnection)
3015            (Session.RemoveDBConnection): New methods to manage and query the
3016            db connections managed by the session
3017            (Session.OpenDBShapeStore): New method to open a shapestore from a
3018            db connection
3019    
3020            * Thuban/Model/messages.py (DBCONN_REMOVED, DBCONN_ADDED): New
3021            messages for the db connection handling in the session
3022    
3023            * test/test_postgis_session.py: New. test cases for the session's
3024            db connection handling with postgis connections
3025    
3026    2003-08-19  Bernhard Herzog  <[email protected]>
3027    
3028            Add very basic postgis database support and the corresponding test
3029            cases. The test cases require a PostgreSQL + postgis installation
3030            but no existing database. The database will be created
3031            automatically by the test cases
3032    
3033            * test/README: Add note about skipped tests and the requirements
3034            of the postgis tests.
3035    
3036            * Thuban/Model/postgisdb.py: New. Basic postgis database support.
3037    
3038            * test/test_postgis_db.py: New. Test cases for the postgis
3039            support.
3040    
3041            * Thuban/Model/wellknowntext.py: New. Parser for well-known-text
3042            format
3043    
3044            * test/test_wellknowntext.py: New. Test cases for the
3045            wellknowntext parser
3046    
3047            * test/postgissupport.py: New. Support module for tests involving
3048            a postgis database.
3049    
3050            * test/support.py (execute_as_testsuite): Shut down the postmaster
3051            if it's still running after the tests
3052    
3053            * Thuban/Model/data.py (RAW_WKT): New constant for raw data in
3054            well known text format
3055    
3056    2003-08-19  Jan-Oliver Wagner <[email protected]>
3057    
3058            * Examples/simple_extensions/hello_world.py: New. Raises a Hello World
3059            message dialog.
3060    
3061    2003-08-18  Bernhard Herzog  <[email protected]>
3062    
3063            * test/support.py (ThubanTestResult.printErrors): Indent the
3064            reason for the skips in the output to make it a bit more readable.
3065            (execute_as_testsuite): New helper function to run a test suite
3066            and print some more information.
3067            (run_tests): Use execute_as_testsuite to run the tests
3068    
3069            * test/runtests.py (main): Use execute_as_testsuite to run the
3070            tests
3071    
3072    2003-08-18  Bernhard Herzog  <[email protected]>
3073    
3074            Fix some bugs in Thuban and the test suite that were uncovered by
3075            changes introduced in Python 2.3:
3076    
3077            * Thuban/Model/table.py (DBFTable.__init__): Make sure the
3078            filename is an absolute name
3079    
3080            * Thuban/Model/layer.py (RasterLayer.__init__): Make sure the
3081            filename is an absolute name
3082    
3083            * test/test_save.py (SaveSessionTest.testRasterLayer): Use a
3084            unique filename to save to and use the correct relative filename
3085            in the expected output.
3086            (SaveSessionTest.test_dbf_table): Use the correct relative
3087            filename in the expected output.
3088    
3089            * test/test_layer.py (TestLayer.test_raster_layer): Update the
3090            test to check whether the filename is absolute.
3091    
3092    2003-08-18  Jan-Oliver Wagner <[email protected]>
3093    
3094            * Thuban/UI/about.py (About.__init__): Added Silke Reimer.
3095    
3096    2003-08-15  Bernhard Herzog  <[email protected]>
3097    
3098            Change the way shapes are returned by a shape store. The
3099            ShapesInRegion method returns an iterator over actual shape
3100            objects instead of a list of shape ids.
3101    
3102            * Thuban/Model/data.py (ShapefileShape.ShapeID): New. Return shape
3103            id.
3104            (ShapefileStore.ShapesInRegion): Return an iterator over the
3105            shapes which yields shape objects instead of returning a list of
3106            shape ids
3107            (ShapefileStore.AllShapes): New. Return an iterator over all
3108            shapes in the shape store
3109            (DerivedShapeStore.AllShapes): New. Like in ShapefileStore
3110    
3111            * Thuban/Model/layer.py (Layer.ShapesInRegion): Update
3112            doc-string.
3113    
3114            * Thuban/UI/baserenderer.py
3115            (BaseRenderer.layer_ids, BaseRenderer.layer_shapes): Rename to
3116            layer_shapes and make it return an iterator containg shapes
3117            instead of a list of ids.
3118            (BaseRenderer.draw_shape_layer): Update doc-string; Adapt to
3119            layer_shapes() change
3120    
3121            * Thuban/UI/renderer.py (ScreenRenderer.layer_ids)
3122            (ScreenRenderer.layer_shapes): Rename as in BaseRenderer
3123    
3124            * Thuban/UI/viewport.py (ViewPort._find_shape_in_layer): Adapt to
3125            changes in the ShapesInRegion return value.
3126            (ViewPort._get_hit_tester): Remove commented out code
3127    
3128            * test/mockgeo.py (SimpleShapeStore.ShapesInRegion): Adapt to the
3129            new return value.
3130            (SimpleShapeStore.AllShapes): New. Implement this method too.
3131    
3132            * test/test_layer.py (TestLayer.test_arc_layer)
3133            (TestLayer.test_polygon_layer, TestLayer.test_point_layer)
3134            (TestLayer.test_point_layer_with_projection)
3135            (TestLayer.test_derived_store): Adapt to changes in the
3136            ShapesInRegion return value.
3137    
3138            * test/test_shapefilestore.py
3139            (TestShapefileStoreArc.test_shapes_in_region)
3140            (TestShapefileStorePolygon.test_shapes_in_region)
3141            (TestShapefileStorePoint.test_shapes_in_region): Adapt to changes
3142            in the ShapesInRegion return value.
3143            (TestShapefileStorePoint.test_all_shapes)
3144            (TestShapefileStoreArc.test_shape_shapeid): New tests for the new
3145            methods
3146    
3147            * test/test_derivedshapestore.py
3148            (TestDerivedShapeStore.test_shapes_in_region): Adapt to changes in
3149            the ShapesInRegion return value.
3150            (TestDerivedShapeStore.test_all_shapes)
3151            (TestDerivedShapeStore.test_shape_shapeid): New tests for the new
3152            methods
3153    
3154    2003-08-15  Bernhard Herzog  <[email protected]>
3155    
3156            Make the renderers deal correctly with raw vs. python level
3157            representation of shape geometries
3158    
3159            * Thuban/UI/baserenderer.py (BaseRenderer.low_level_renderer):
3160            Return a flag useraw in addition to the callable and the parameter
3161            to indicate whether the callable can deal with the raw shape data
3162            or uses the higher level python lists of coordinates. The callable
3163            now should accept either the raw data or the return value of the
3164            shape's Points() method.
3165            (BaseRenderer.draw_shape_layer): Adapt to the low_level_renderer
3166            change
3167            (BaseRenderer.projected_points): Instead of the shape id use the
3168            points list as parameter.
3169            (BaseRenderer.draw_polygon_shape, BaseRenderer.draw_arc_shape)
3170            (BaseRenderer.draw_point_shape): Adapt to projected_points()
3171            change and accept the points list as parameter instead of the
3172            shape id.
3173    
3174            * Thuban/UI/renderer.py (MapRenderer.low_level_renderer): Return
3175            the useraw flag as required by the BaseRenderer
3176            (ScreenRenderer.draw_shape_layer): Adapt to low-level renderer
3177            changes.
3178    
3179            * test/test_baserenderer.py
3180            (TestBaseRenderer.test_point_with_classification): New test for
3181            rendering a map with classifications.
3182    
3183    2003-08-15  Bernhard Herzog  <[email protected]>
3184    
3185            * Thuban/UI/viewport.py (ViewPort.find_shape_at)
3186            (ViewPort._find_shape_in_layer, ViewPort._find_shape_in_layer)
3187            (ViewPort._get_hit_tester, ViewPort.projected_points)
3188            (ViewPort._hit_point, ViewPort._hit_arc, ViewPort._hit_polygon)
3189            (ViewPort._find_label_at): Split the find_shape_at method into
3190            several new methods and use the functions in the hit-test module.
3191    
3192            * Thuban/UI/hittest.py: New module with Python-level hit-testing
3193            functions
3194    
3195            * test/test_hittest.py: New. Test for the new hittest module
3196    
3197    2003-08-15  Bernhard Herzog  <[email protected]>
3198    
3199            * Thuban/Model/layer.py (Layer.ShapesInRegion): Apply the layer
3200            projection to all corners of the bounding box to get a better
3201            approximation of the projected bounding box
3202    
3203            * test/test_layer.py (TestLayer.test_point_layer_with_projection):
3204            New. Test coordinate handling of a layer with a projection.
3205            Catches the bug fixed in Layer.ShapesInRegion
3206    
3207    2003-08-15  Bernhard Herzog  <[email protected]>
3208    
3209            Move some of the mock objects in test_baserenderer into their own
3210            module so they can easily be used from other tests
3211    
3212            * test/mockgeo.py: New test helper module with some mock objects
3213            for geometry related things like shapes, shapestores and
3214            projections.
3215    
3216            * test/test_mockgeo.py: New. Tests for the new helper module
3217    
3218            * test/test_baserenderer.py: Some of the mock-objects are in
3219            mockgeo now.
3220    
3221    2003-08-12  Jan-Oliver Wagner <[email protected]>
3222    
3223            * Thuban/UI/about.py (About.__init__): Added Bj�rn Broscheit.
3224    
3225    2003-08-12  Bernhard Herzog  <[email protected]>
3226    
3227            * po/de.po: New. German translations by Bjoern Broscheit
3228    
3229    2003-08-12  Bernhard Herzog  <[email protected]>
3230    
3231            * Thuban/UI/projdialog.py (UnknownProjPanel._DoLayout): Translated
3232            strings have to be one string literal.
3233    
3234    2003-08-11  Bernhard Herzog  <[email protected]>
3235    
3236            * test/support.py (FloatComparisonMixin.assertPointListEquals):
3237            New. This method was used in various derived classes, but it's
3238            better to have it here.
3239    
3240            * test/test_shapefilestore.py
3241            (ShapefileStoreTests.assertPointListEquals): Removed. It's now in
3242            FloatComparisonMixin
3243    
3244            * test/test_layer.py (TestLayer.assertPointListEquals): Removed.
3245            It's now in FloatComparisonMixin
3246    
3247            * test/test_derivedshapestore.py
3248            (TestDerivedShapeStore.assertPointListEquals): Removed. It's now
3249            in FloatComparisonMixin
3250    
3251    2003-08-11  Bernhard Herzog  <[email protected]>
3252    
3253            * Thuban/UI/join.py (JoinDialog.OnJoin): Add missing space to
3254            error message
3255    
3256    2003-08-08  Jan-Oliver Wagner <[email protected]>
3257    
3258            * Doc/manual/thuban-manual.xml: Now use authorgroup. Added revhistory
3259            with version number.
3260            Changed title to reflect version number of Thuban.
3261    
3262    2003-08-08  Jan-Oliver Wagner <[email protected]>
3263    
3264            * Thuban/UI/about.py (About.__init__): Reworked the hall of fame. Now
3265            the list corresponds to the "About" web page.
3266    
3267    2003-08-08  Bernhard Herzog  <[email protected]>
3268    
3269            * Thuban/UI/projdialog.py (UTMProposeZoneDialog.dialogLayout):
3270            Make sure translated strings are recognized as one string literal.
3271    
3272            * Thuban/UI/proj4dialog.py (UTMProposeZoneDialog.dialogLayout):
3273            Make sure translated strings are recognized as one string literal.
3274    
3275            * Thuban/UI/classgen.py (ClassGenDialog.OnOK): Make sure
3276            translated strings are recognized as one string literal.
3277    
3278            * Thuban/UI/application.py (ThubanApplication.OpenSession): Make
3279            sure translated strings are recognized as one string literal.
3280    
3281    2003-08-07  Bernhard Herzog  <[email protected]>
3282    
3283            * Thuban/Model/data.py (DerivedShapeStore.RawShapeFormat): New.
3284            Simply delegates to the original shapestore.
3285    
3286            * test/test_derivedshapestore.py
3287            (TestDerivedShapeStore.test_raw_format): New. Test case for
3288            DerivedShapeStore.RawShapeFormat
3289    
3290    2003-08-07  Bernhard Herzog  <[email protected]>
3291    
3292            Add raw data interface to shape objects.
3293    
3294            * Thuban/Model/data.py (ShapefileShape, Shape): Rname the shape
3295            class to ShapefileShape which now holds shapefile specific
3296            information.
3297            (ShapefileShape.compute_bbox): Simplified to not cache any
3298            information. The way this method is used that shouldn't matter
3299            performance wise.
3300            (ShapefileShape.RawData): New. Return the shapeid which is the raw
3301            data format for shapes from shapefiles.
3302            (ShapefileStore.RawShapeFormat): New. Return the raw datatype used
3303            in the shape objects returned by a shapestore. For a
3304            ShapefileStore this is always RAW_SHAPEFILE.
3305            (RAW_PYTHON, RAW_SHAPEFILE): Constants for the RawShapeFormat
3306            method.
3307    
3308            * test/test_shapefilestore.py
3309            (TestShapefileStore.test_raw_format): New test to test the raw
3310            format feature of shapes.
3311    
3312            * Thuban/Model/layer.py: Remove the unused import of Shape from
3313            data. It was only there for interface compatibility but it's not
3314            used inside of Thuban and the generic Shape class has gone away.
3315    
3316            * Thuban/UI/renderer.py (MapRenderer.low_level_renderer): Check
3317            the raw data format and only use an optimized version of its a
3318            shapefile.
3319    
3320    2003-08-07  Bernhard Herzog  <[email protected]>
3321    
3322            * test/test_baserenderer.py (SimpleShape): Shape class for the
3323            tests.
3324            (SimpleShapeStore.Shape): Use SimpleShape instead of
3325            Thuban.Model.data.Shape to make the tests independed of the coming
3326            changes.
3327    
3328    2003-08-07  Bernhard Herzog  <[email protected]>
3329    
3330            * test/support.py (SkipTest, ThubanTestResult, ThubanTestRunner)
3331            (ThubanTestProgram): New classes that extend the respective
3332            classes from unittest. These new version support skipping tests
3333            under certain expected conditions. In the Thuban test suite we
3334            uses this for tests that require the optional gdal support.
3335            (run_tests): Use ThubanTestProgram instead of the unittest.main()
3336    
3337            * test/runtests.py (main): Use the new ThubanTestRunner instead of
3338            the normal one from unittest
3339    
3340            * test/test_layer.py (TestLayer.test_raster_layer): If this test
3341            is not run because gdal support isn't available report this to the
3342            runner.
3343    
3344            * test/test_baserenderer.py
3345            (TestBaseRenderer.test_raster_no_projection): Do not run this test
3346            if gdal support isn't available and report this to the runner.
3347    
3348    2003-08-06  Bernhard Herzog  <[email protected]>
3349    
3350            Rearrange the renderers a bit, partly in preparation for changes
3351            required for the postgis merge, partly to make it more testable.
3352            Also make the representation of coordinates in Shapes more
3353            consistent.
3354    
3355            * Thuban/UI/renderer.py (MapRenderer): Most of the code/methods in
3356            this class is now in BaseRenderer. This class is now practically
3357            only a specialization of BaseRenderer for rendering to an actual
3358            wx DC.
3359            (ScreenRenderer.draw_shape_layer): Use self.low_level_renderer()
3360            to get the shapetype specific rendering functions.
3361    
3362            * Thuban/UI/baserenderer.py: New file with the basic rendering
3363            logic. The code in this file is completely independend of wx.
3364            (BaseRenderer): Class with the basic rendering logic
3365    
3366            * test/test_baserenderer.py: New. Test cases for BaseRenderer
3367    
3368            * Thuban/UI/view.py (MapCanvas.__init__): New instance variable
3369            error_on_redraw to guard agains endless loops and stack overflows
3370            when there's a bug in the rendering code that raises exceptions.
3371            (MapCanvas.OnIdle, MapCanvas._do_redraw): Split the actual
3372            rendering into a separate method _do_redraw so that error handling
3373            is a bit easier. When an exception occurs, set error_on_redraw to
3374            true. When it's true on entry to OnIdle do nothing and return
3375            immediately.
3376    
3377            * Thuban/Model/data.py (ShapefileStore.Shape): For consistency, a
3378            Shape object will always have the coordinates as a list of list of
3379            coordinate pairs (tuples).
3380            (Shape.compute_bbox): Adapt to new representation.
3381    
3382            * Thuban/UI/viewport.py (ViewPort.find_shape_at)
3383            (ViewPort.LabelShapeAt): Adapt to new coordinate representation in
3384            Shape objects.
3385    
3386            * test/test_shapefilestore.py
3387            (ShapefileStoreTests.assertFloatTuplesEqual)
3388            (ShapefileStoreTests.assertPointListEquals): Rename to
3389            assertPointListEquals and change purpose to checking equality of
3390            the lists returned by Shape.Points().
3391            (TestShapefileStoreArc.test_shape)
3392            (TestShapefileStorePolygon.test_shape)
3393            (TestShapefileStorePoint.test_shape): Use the new
3394            assertPointListEquals instead of assertFloatTuplesEqual
3395    
3396            * test/test_layer.py (TestLayer.assertFloatTuplesEqual)
3397            (TestLayer.assertPointListEquals): Rename to assertPointListEquals
3398            and change purpose to checking equality of the lists returned by
3399            Shape.Points().
3400            (TestLayer.test_arc_layer, TestLayer.test_arc_layer)
3401            (TestLayer.test_polygon_layer, TestLayer.test_point_layer)
3402            (TestLayer.test_derived_store): Use the new assertPointListEquals
3403            instead of assertFloatTuplesEqual
3404    
3405            * test/test_derivedshapestore.py
3406            (TestDerivedShapeStore.assertFloatTuplesEqual)
3407            (TestDerivedShapeStore.assertPointListEquals): Rename to
3408            assertPointListEquals and change purpose to checking equality of
3409            the lists returned by Shape.Points().
3410            (TestDerivedShapeStore.test_shape): Use the new
3411            assertPointListEquals instead of assertFloatTuplesEqual
3412    
3413    2003-08-06  Jan-Oliver Wagner <[email protected]>
3414    
3415            * Thuban/UI/projdialog.py (UTMPanel._OnPropose): Added test for
3416            a bounding box. A dialog is raised in case, no bounding box
3417            is found. This fixes bug #2043:
3418            https://intevation.de/rt/webrt?serial_num=2043
3419    
3420    2003-08-05  Bernhard Herzog  <[email protected]>
3421    
3422            * Thuban/Model/color.py (Color.__repr__): Make the repr of a color
3423            object look like a Color instantiation. Formerly it looked like a
3424            tuple.
3425    
3426            * test/test_color.py (TestColor.test_repr)
3427            (TestColor.test_equality, TestColor.test_inequality): New. test
3428            some more apects of the Color class
3429            (TestTransparent.test_repr, TestTransparent.test_hex)
3430            (TestTransparent.test_equality): New. Test cases for the
3431            Transparent object.
3432    
3433    2003-08-04  Jan-Oliver Wagner <[email protected]>
3434    
3435            * Doc/manual/thuban-manual.xml: a number of small improvements.
3436            The resulting file is the version submitted for GREAT-ER II.
3437    
3438    2003-08-01  Bernhard Herzog  <[email protected]>
3439    
3440            * Thuban/UI/resource.py, Thuban/UI/projdialog.py,
3441            Thuban/UI/join.py, Thuban/UI/classgen.py, Thuban/UI/about.py,
3442            Thuban/Model/resource.py: Insert cvs keywords and doc-strings.
3443    
3444            * Thuban/UI/common.py: Insert cvs keywords and doc-strings.
3445            (Color2wxColour, wxColour2Color, ThubanBeginBusyCursor)
3446            (ThubanEndBusyCursor): Add doc-strings
3447    
3448    2003-08-01  Bernhard Herzog  <[email protected]>
3449    
3450            First step towards PostGIS integration. More abstraction by movin
3451            more code from the layer to the shapestore. More methods of the
3452            layer are now simply delegated to the equivalent method of the
3453            shapestore. The SHAPETYPE_* constants are now in data not in
3454            layer.
3455    
3456            * Thuban/Model/data.py (SHAPETYPE_POLYGON, SHAPETYPE_ARC)
3457            (SHAPETYPE_POINT, Shape): Move these constants and classes from
3458            layer.py to data.py
3459            (ShapefileStore.__init__): More Initialization for the new methods
3460            and functionality.
3461            (ShapefileStore.ShapeType, ShapefileStore.NumShapes)
3462            (ShapefileStore.BoundingBox, ShapefileStore.ShapesInRegion)
3463            (ShapefileStore.Shape): New methods that were formerly implemented
3464            in the layer.
3465            (DerivedShapeStore.Shape, DerivedShapeStore.ShapesInRegion)
3466            (DerivedShapeStore.ShapeType, DerivedShapeStore.NumShapes)
3467            (DerivedShapeStore.BoundingBox): New. DerivedShapeStore
3468            equivalents of the new shape methods. These versions are simply
3469            delegated to the original shapstore.
3470    
3471            * Thuban/Model/layer.py (SHAPETYPE_POLYGON, SHAPETYPE_ARC)
3472            (SHAPETYPE_POINT, Shape): Removed. They're now in data.py
3473            (Layer.SetShapeStore): Removed the initializatin of instance
3474            variables that were needed for the stuff that's now in
3475            ShapefileStore
3476            (Layer.BoundingBox, Layer.NumShapes, Layer.ShapeType)
3477            (Layer.Shape, Layer.ShapesInRegion): Simply delegate to the
3478            shapestore.
3479    
3480            * Thuban/UI/classifier.py, Thuban/UI/renderer.py,
3481            Thuban/UI/viewport.py: Import the SHAPETYPE_* constants from data
3482            instead of layer.
3483    
3484            * test/test_shapefilestore.py: New. Tests for ShapefileStore.
3485    
3486            * test/test_derivedshapestore.py: New. Tests for DerivedShapeStore.
3487    
3488            * test/test_layer.py: Import the SHAPETYPE_* constants from data
3489            instead of layer.
3490            (TestLayer.test_derived_store): Remove the test for the exception
3491            when instantiating the DerivedShapeStore with an incompatible
3492            table which is now in test_derivedshapestore.py. Add some more
3493            tests of the layer methods to determine whether they work for a
3494            DerivedShapeStore as well.
3495    
3496    2003-07-31  Jonathan Coles   <[email protected]>
3497    
3498            * Doc/manual/thuban-manual.xml: Fix the list of required packages
3499            by just listing the name and where they can be found.
3500    
3501    2003-07-31  Frank Koormann   <[email protected]>
3502    
3503            * Doc/manual/thuban-manual.xml:
3504            Changed the screenshot elements to figure.
3505            Changed some variablelist elements to itemizedlist.
3506            Added section on GDAL formats.
3507    
3508    2003-07-31  Jonathan Coles   <[email protected]>
3509    
3510            * Doc/manual/thuban-manual.xml: Added a few sentences about
3511            the Fix Border Color option when generating classes.
3512    
3513    2003-07-30  Jonathan Coles   <[email protected]>
3514    
3515            * Thuban/Model/classgen.py: Add docstrings. Rename specific
3516            Ramp instances to use lower_case_style.
3517    
3518            * Thuban/UI/classgen.py: Use renamed Ramp instances.
3519            
3520            * Thuban/UI/classifier.py: Add docstrings.
3521    
3522            * Thuban/UI/dock.py: Add docstrings.
3523    
3524            * test/test_classgen.py: Use renamed Ramp instances.
3525    
3526    2003-07-30  Bernhard Herzog  <[email protected]>
3527    
3528            * Thuban/Lib/connector.py (QueueingPublisher): Removed. This class
3529            was never used in Thuban.
3530    
3531    2003-07-30  Bernhard Herzog  <[email protected]>
3532    
3533            * Thuban/UI/join.py (JoinDialog.__init__): Use the table's Title()
3534            method directly instead of going through the transient_table
3535            method. This faster because transient_table may force the copy of
3536            a DBF file into the transient database and setting a table's title
3537            doesnm't affect the title of the associated transient table, so
3538            this fixes RT #2042
3539    
3540            * Thuban/UI/main.py (__version__): Don't import the already
3541            removed show_exception_dialog.
3542    
3543    2003-07-29  Jonathan Coles   <[email protected]>
3544    
3545            * Thuban/UI/application.py (ThubanApplication.ShowExceptionDialog):
3546            Put back this method and remove the equivalent function since we
3547            are setting the exception hook from within this class (OnInit).
3548    
3549    2003-07-29  Jonathan Coles   <[email protected]>
3550    
3551            * Doc/manual/images/5_2_custom_ramp.png,
3552            Doc/manual/images/5_2_quantiles.png,
3553            Doc/manual/images/5_2_uniform_dist.png,
3554            Doc/manual/images/5_2_unique_values.png,
3555            Doc/manual/images/8_int_error.png: New screen shots.
3556    
3557            * Doc/manual/thuban-manual.xml: Fixed typos and wording, clarified
3558            some points, and added more screen shots.
3559    
3560    2003-07-29  Bernhard Herzog  <[email protected]>
3561    
3562            * Thuban/Model/data.py: Remove the now unused import of warnings
3563    
3564    2003-07-29  Bernhard Herzog  <[email protected]>
3565    
3566            * Thuban/Model/data.py (SimpleStore): Removed. This class has been
3567            deprecated since before the 0.8 release and isn't used in Thuban
3568            itself anymore.
3569    
3570            * Thuban/Model/transientdb.py: Remove some unnecessary imports
3571    
3572    2003-07-29  Jonathan Coles   <[email protected]>
3573    
3574            * Thuban/UI/application.py (ThubanApplication.OnInit): set the
3575            python exception hook here so that we are sure to catch any
3576            Thuban exception that happen during initialization.
3577    
3578            * Thuban/UI/main.py (main): Don't set the exception hook here,
3579            it will get set in ThubanApplication.OnInit.
3580    
3581    2003-07-29  Jonathan Coles   <[email protected]>
3582                                                                                
3583            * Thuban/UI/application.py (ThubanApplication.ShowExceptionDialog):
3584            Removed and called it show_exception_dialog() so that the exception
3585            handler can be set before the class is created.
3586                                                                                
3587            * Thuban/UI/main.py (main): Install the exception handler before
3588            a ThubanApplication is created.
3589                                                                                    
3590    2003-07-29  Bernhard Herzog  <[email protected]>
3591    
3592            * po/it.po: New. Italian translation by Maurizio Napolitano
3593    
3594            * po/ru.po: New. Russian translation by Alex Shevlakov
3595    
3596    2003-07-29  Frank Koormann   <[email protected]>
3597    
3598            * Doc/manual/thuban-manual.xml: Extended section on supported
3599            projections.
3600            
3601    2003-07-29  Frank Koormann   <[email protected]>
3602    
3603            * Doc/manual/thuban-manual.xml: gaspell-checked.
3604    
3605    2003-07-29  Jonathan Coles   <[email protected]>
3606    
3607            * Doc/manual/images/3_5_legend.png: Added border to improve look
3608            on white background.
3609    
3610    2003-07-29  Jonathan Coles   <[email protected]>
3611    
3612            * Doc/manual/thuban-manual.xml: Fixed grammar and typos. Added
3613            descriptions for the legend toolbar.
3614    
3615            * Doc/manual/images/4_2_raster_layer_properties.png: Removed
3616            cursor from dialog box.
3617    
3618    2003-07-28  Jonathan Coles   <[email protected]>
3619    
3620            * Doc/manual/thuban-manual.xml: More screenshots and more chapters.
3621    
3622            * Doc/manual/images/2_4_session_tree.png,
3623            Doc/manual/images/3_5_legend.png, Doc/manual/images/3_rename_map.png,
3624            Doc/manual/images/4_2_layer_properties.png,
3625            Doc/manual/images/4_2_raster_layer_properties.png,
3626            Doc/manual/images/5_3_genclass.png,
3627            Doc/manual/images/5_classification.png,
3628            Doc/manual/images/6_projection.png,
3629            Doc/manual/images/7_1_table_view.png,
3630            Doc/manual/images/7_2_5_join.png: New screenshots.
3631    
3632    2003-07-24  Jonathan Coles   <[email protected]>
3633    
3634            * Doc/manual/thuban-manual.xml: Chapter on Projection Management.
3635    
3636    2003-07-24  Jonathan Coles   <[email protected]>
3637    
3638            * Doc/manual/thuban-manual.xml: Added EPS images and wrote
3639            chapter on Layer Management.
3640    
3641            * Doc/manual/Makefile: New. Makefile to generate all formats for the
3642            manual and images.
3643    
3644    2003-07-24  Bernhard Herzog  <[email protected]>
3645    
3646            * Thuban/Model/range.py, Thuban/version.py: Remove the #! line as
3647            it annoys lintian which warns about these files not being
3648            executable. The #! isn't necessary here since if you absolutely
3649            must execute them you can always say "python <filename>".
3650    
3651            * Thuban/UI/renderer.py (ScreenRenderer.draw_shape_layer): Remove
3652            superfluous code to set brush and pen for point shapes
3653    
3654            * Thuban/UI/viewport.py: Remove commented out code that wouldn't
3655            belong in viewport anyway
3656    
3657    2003-07-24  Frank Koormann   <[email protected]>
3658    
3659            * Doc/manual/thuban-manual.xml: Added section on table management.
3660    
3661    2003-07-24  Bernhard Herzog  <[email protected]>
3662    
3663            * test/runtests.py (main): Recognize the long "verbose" option
3664            correctly.
3665    
3666    2003-07-22  Jonathan Coles   <[email protected]>
3667    
3668            * Doc/manual/thuban-manual.xml: Continue to write first revision
3669            of the manual.
3670    
3671            * Thuban/UI/renderer.py (MapRenderer.render_map): Wrap method
3672            with Begin/EndDrawing() calls to ensure we aren't doing to
3673            many updates to the dc during rendering.
3674            (ScreenRenderer.draw_shape_layer): self.draw_point_shape takes
3675            a pen and brush argument so they need to be passed to the function.
3676    
3677            * Thuban/UI/viewport.py (ViewPort.calc_min_max_scales): New.
3678            Calculates the minimum and maximum scale values. Factored out
3679            of set_view_transform so that it could be used to zoom all the
3680            way into a single point.
3681            (ViewPort.set_view_transform): Call calc_min_max_scales().
3682            (ViewPort.FitSelectedToWindow): Zoom to the maximum scale
3683            if only a single point is selected.
3684    
3685            * Doc/manual/images/1_2_legend_close.png,
3686            Doc/manual/images/1_2_legend_dock.png,
3687            Doc/manual/images/1_2_mainwindow.png,
3688            Doc/manual/images/1_2_mainwindow.ps,
3689            Doc/manual/images/1_2_mainwindow.sk,
3690            Doc/manual/images/3_2_fullextent.png,
3691            Doc/manual/images/3_2_fulllayerextent.png,
3692            Doc/manual/images/3_2_fullshapeextent.png,
3693            Doc/manual/images/3_2_pan.png,
3694            Doc/manual/images/3_2_zoomin.png,
3695            Doc/manual/images/3_2_zoomout.png,
3696            Doc/manual/images/3_3_identify.png,
3697            Doc/manual/images/3_3_label.png,
3698            Doc/manual/images/3_5_invisible.png,
3699            Doc/manual/images/3_5_movedown.png,
3700            Doc/manual/images/3_5_moveup.png,
3701            Doc/manual/images/3_5_props.png,
3702            Doc/manual/images/3_5_tobottom.png,
3703            Doc/manual/images/3_5_totop.png,
3704            Doc/manual/images/3_5_visible.png: New. Images for the documentation.
3705    
3706    2003-07-18  Bernhard Herzog  <[email protected]>
3707    
3708            * Thuban/UI/messages.py (MAP_REPLACED): New message.
3709    
3710            * Thuban/UI/viewport.py (ViewPort.SetMap): Issue MAP_REPLACED
3711            after the new map has been assigned
3712    
3713            * Thuban/UI/mainwindow.py (MainWindow.delegated_messages):
3714            Delegate MAP_REPLACED to the canvas too
3715            (MainWindow.prepare_new_session): Removed. Thanks to the new
3716            MAP_REPLACED message it's no longer needed
3717            (MainWindow.OpenSession, MainWindow.NewSession):
3718            prepare_new_session has been removed.
3719    
3720            * Thuban/UI/classifier.py (Classifier.__init__): Subscribe to
3721            MAP_REPLACED so that we can close the dialog if a new map is set.
3722            (Classifier.unsubscribe_messages): Unsubscribe from MAP_REPLACED
3723            (Classifier.map_replaced): Handle MAP_REPLACED by closing the
3724            dialog
3725    
3726            * test/test_viewport.py (SimpleViewPortTest)
3727            (SimpleViewPortTest.test_default_size): Add doc-strings
3728            (ViewPortTest.setUp): Bind map to self.map so we can use it in
3729            tests. Subscribe to MAP_REPLACED messages too.
3730            (ViewPortTest.tearDown): No need to explicitly unsubscribe
3731            (ViewPortTest.test_set_map): New test for the SetMap method.
3732    
3733    2003-07-18  Bernhard Herzog  <[email protected]>
3734    
3735            * test/test_viewport.py (SimpleViewPortTest.test_default_size):
3736            Move this test from ViewPortTest.setUp to this new separate test
3737            case. setUp is not the place for the actual tests.
3738            (ViewPortTest.test_inital_settings, ViewPortTest.setUp): Move some
3739            more of the test from setUp to the new test test_inital_settings.
3740            (ViewPortTest.test_win_to_proj, ViewPortTest.test_proj_to_win)
3741            (ViewPortTest.test_proj_conv): Split test_proj_conv into
3742            test_win_to_proj and test_proj_to_win and make the tests easier to
3743            understand
3744            (ViewPortTest.testFitRectToWindow, ViewPortTest.testZoomFactor)
3745            (ViewPortTest.testZoomOutToRect, ViewPortTest.testTranslate)
3746            (ViewPortTest.test_unprojected_rect_around_point)
3747            (ViewPortTest.test_find_shape_at, ViewPortTest.testTools):
3748            Reformat to increase readability.
3749    
3750    2003-07-18  Bernhard Herzog  <[email protected]>
3751    
3752            * Thuban/UI/view.py (MapCanvas.OnLeftDown): Capture the mouse.
3753    
3754    2003-07-18  Bernhard Herzog  <[email protected]>
3755    
3756            * test/runtests.py: The test suite can now be run without an X
3757            connection. To make sure this remains true, remove the DISPLAY
3758            environment variable so that an error occurs if the wxGTK is
3759            imported accidentally
3760    
3761    2003-07-18  Bernhard Herzog  <[email protected]>
3762    
3763            * Thuban/UI/viewport.py: Remove unused imports
3764    
3765            * Thuban/UI/view.py: Remove unused imports
3766    
3767    2003-07-18  Bernhard Herzog  <[email protected]>
3768    
3769            * test/test_export.py Remove unused imports. The OutputTransform
3770            function is now in viewport.py and is called output_transform
3771            (TestScalebar.test_output_transform)
3772            (TestScalebar.test_OutputTransform): Renamed to
3773            test_output_transform and updated to use output_transform instead
3774            of OutputTransform
3775    
3776            * Thuban/UI/view.py (OutputTransform): Moved to viewport.py and
3777            renamed.
3778            (MapCanvas.Export, MapPrintout.draw_on_dc): OutputTransform was
3779            renamed to output_transform
3780    
3781            * Thuban/UI/viewport.py (OutputTransform, output_transform):
3782            Rename to output_transform
3783    
3784    2003-07-18  Bernhard Herzog  <[email protected]>
3785    
3786            * Thuban/Model/layer.py (Layer.__init__): Rename
3787            classificationField to classificatin_column and init it here so
3788            that it can be used in SetClassificationColumn
3789            (Layer.GetClassificationColumn, Layer.GetClassificationField):
3790            Rename to GetClassificationColumn.
3791            (Layer.SetClassificationColumn, Layer.SetClassificationField):
3792            Rename to SetClassificationColumn and issue a LAYER_CHANGED
3793            message if the column changes.
3794            (Layer._classification_changed, Layer.ClassChanged): Rename to
3795            _classification_changed. Update the callers.
3796            (Layer.SetShapeStore): Further field->column renames.
3797    
3798            * Thuban/Model/load.py (SessionLoader.start_classification)
3799            (SessionLoader.start_clpoint): Updates because of
3800            field->column method name changes in the Layer class
3801    
3802            * Thuban/Model/save.py (SessionSaver.write_classification): Updates
3803            because of field->column method name changes in the Layer class
3804    
3805            * Thuban/UI/classifier.py (Classifier.__init__)
3806            (Classifier._OnTry, Classifier._OnRevert): Updates because of
3807            field->column method name changes in the Layer class
3808    
3809            * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Updates
3810            because of field->column method name changes in the Layer class
3811    
3812            * Thuban/UI/viewport.py (ViewPort.find_shape_at): Updates because
3813            of field->column method name changes in the Layer class
3814    
3815            * test/test_save.py (SaveSessionTest.testClassifiedLayer)
3816            (SaveSessionTest.testClassifiedLayer): Update because of
3817            field->column method name changes in the Layer class
3818    
3819            * test/test_layer.py (SetShapeStoreTests.setUp)
3820            (SetShapeStoreTests.test_sanity): Update because of field->column
3821            method name changes in the Layer class
3822            (TestLayerModification.setUp): Subscribe to LAYER_CHANGED as well
3823            (TestLayerModification.test_sanity)
3824            (TestLayerModification.test_initial_settings): remove unsued code
3825            and rename to test_sanity.
3826            (TestLayerModification.test_set_classification): New test for
3827            SetClassification and SetClassificationField.
3828    
3829    2003-07-18  Bernhard Herzog  <[email protected]>
3830    
3831            * test/test_classgen.py (TestFixedRamp.test): Extend test to check
3832            the non-fixed values as well. The old test would have accepted a
3833            fixed ramp that only returnes the fixed properties
3834    
3835    2003-07-17  Jonathan Coles   <[email protected]>
3836    
3837            * Doc/manual/mainwindow.png, Doc/manual/mainwindow.xcf: Screen
3838            shots for the manual. The XCF file is the source image and
3839            has additional layers to support changes.
3840    
3841            * Doc/manual/thuban-manual.xml: Wrote an initial Introduction.
3842    
3843            * Thuban/UI/classifier.py (Classifier.__BuildClassification):
3844            Return both the new class and the field name.
3845    
3846            * Thuban/UI/mainwindow.py (MainWindow.ToggleLegend): Don't
3847            fit the map to the window as this changes any zoom level that
3848            the user may have set.
3849    
3850    2003-07-16  Jonathan Coles   <[email protected]>
3851    
3852            * Thuban/Model/classgen.py (generate_singletons,
3853            generate_uniform_distribution, generate_quantiles): Remove
3854            fixes parameter, but maintain the same functionality by having
3855            the calling function pass a FixedRamp object for the ramp.
3856            (FixedRamp): New. Adapts a ramp to have fixed property values.
3857    
3858            * Thuban/Model/classification.py: Use new CLASS_CHANGED message.
3859            (Classification): Inherit from Publisher.
3860            (Classification.__init__): Remove the layer parameter.
3861            Classifications no longer need to have a parent layer.
3862            (Classification.GetField, Classification.GetFieldType,
3863            Classification.SetFieldInfo): Removed. The field name is stored
3864            in the layer, and the type can be retreived by calling
3865            Layer.GetFieldType().
3866            (Classification._set_layer, Classification.GetLayer): Removed.
3867            Classifications no longer have a parent layer.
3868    
3869            * Thuban/Model/layer.py (Layer.Destroy): Unsubscribe from the
3870            classification.
3871            (Layer.SetShapeStore): Reset the classification first while
3872            we still have the old shape store to work with.
3873            (Layer.GetClassificationField, Layer.SetClassificationField):
3874            New. Method for getting/setting the field to classify on.
3875            (Layer.SetClassification): Simplified now that the layer
3876            simply has to hold a reference to the classification and not
3877            tell the classification who owns it.
3878            Fixes RTbug #2023.
3879    
3880            * Thuban/Model/load.py (SessionLoader.start_classification):
3881            Set the field name on the layer, not the classification.
3882    
3883            * Thuban/Model/messages.py: Add CLASS_CHANGED for when a
3884            classification is modified.
3885    
3886            * Thuban/Model/save.py (SessionSaver.write_classification):
3887            Get the field name and type from the layer.
3888    
3889            * Thuban/Model/table.py (table_to_dbf, table_to_csv): Renamed
3890            parameter records to rows and add docstring. Fixes RTbug #1997.
3891    
3892            * Thuban/UI/classgen.py (ClassGenDialog.OnOK): Use a fixed
3893            ramp when we need to fix certain values of a ramp rather than
3894            using the old fixes parameter. Fixes RTbug #2024.
3895    
3896            * Thuban/UI/classifier.py (ClassGrid.CreateTable): Add fieldType
3897            parameter.
3898            (ClassTable.Reset): Add fieldType parameter and use it, rather
3899            than asking the classification.
3900            (Classifier.__init__): Remember the original class's field
3901            and ask the layer for the field type, rather than the classification.
3902            (Classifier.__SetGridTable): Retrieve the field and field type
3903            for the table because they are not in the classification.
3904            (Classifier._OnTry, Classifier._OnRevert): Set the classification
3905            field on the layer in addition to the classification itself.
3906    
3907            * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Get the
3908            classification field from layer.
3909    
3910            * Thuban/UI/viewport.py (ViewPort.find_shape_at): Get the
3911            classification field from layer. Split up tests and remove
3912            *-imports. Fixes RTbug #1992.
3913    
3914            * test/test_classgen.py (TestFixedRamp): Test for the FixedRamp class.
3915    
3916            * test/test_classification.py
3917            (TestClassification.test_classification): Remove tests for methods
3918            that no longer exist.
3919    
3920            * test/test_layer.py (SetShapeStoreTests.setUp): Classification
3921            __init__ no longer has a field parameter, use SetClassificationField.
3922            (SetShapeStoreTests.test_sanity): Use layer object to get class
3923            field info.
3924    
3925            * test/test_save.py (SaveSessionTest.testClassifiedLayer): Use
3926            SetClassificationField on layer to set class field info.
3927    
3928            * test/test_viewport.py: Renamed from test/test_view.py.
3929    
3930    2003-07-16  Jan-Oliver Wagner <[email protected]>
3931    
3932            * Doc/manual/thuban-manual.xml: Added authors and an initial
3933            coarse structure.
3934    
3935    2003-07-15  Bernhard Herzog  <[email protected]>
3936    
3937            * test/support.py (FloatComparisonMixin): This is a mix-in class
3938            and therefore should not be derived from any other class.
3939    
3940            * test/test_range.py (RangeTest): FloatComparisonMixin is a
3941            mix-in, so derive from TestCase as well.
3942    
3943    2003-07-15  Bernhard Herzog  <[email protected]>
3944    
3945            * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Rework the
3946            draw_func handling a bit to remove one layer of indirection. This
3947            makes the renderer about 10% faster in the non-classifying case
3948            and the code a bit cleaner
3949            (MapRenderer.draw_point_shape): Add the pen and brush parameters
3950            and set them in the dc. Now the draw_point_shape method and
3951            wxproj's draw_polygon_shape function have basically the same
3952            signature so that both can be directly used as draw_func
3953    
3954    2003-07-15  Bernhard Herzog  <[email protected]>
3955    
3956            * Thuban/Model/save.py (SessionSaver.write_classification): Encode
3957            string values (in addition to the labels) as UTF 8
3958    
3959            * Thuban/Model/load.py (SessionLoader.start_clpoint): Decode the
3960            values if the field type is string
3961    
3962            * test/test_save.py (SaveSessionTest.testClassifiedLayer): Test
3963            saving a session with non-ascii string classification values.
3964    
3965            * test/test_load.py (TestClassification.file_contents)
3966            (TestClassification.test): Check for non-ascii values in string
3967            classifications
3968    
3969    2003-07-14  Jonathan Coles   <[email protected]>
3970    
3971            * test/test_view.py: New. Tests for ViewPort.
3972    
3973    2003-07-14  Frank Koormann   <[email protected]>
3974    
3975            * Thuban/Model/load.py (SessionLoader.start_map): Encode map
3976            title to latin1.  Fixes https://intevation.de/rt/webrt?serial_num=2013
3977    
3978            * test/test_load_0_8.py (TestUnicodeStrings): New, test load of
3979            unicode strings from session file: session title, map title and
3980            projection name.
3981            
3982    2003-07-10  Jonathan Coles   <[email protected]>
3983    
3984            * Thuban/UI/viewport.py (Tool.MouseUp): Should have called
3985            drag_stop, not drag_move when the mouse is released.
3986    
3987    2003-07-10  Jonathan Coles   <[email protected]>
3988    
3989            The most important part of this is the seperation of view.py into
3990            two pieces. viewport.py now has a class called ViewPort which
3991            contains all the non-wx parts of view.py and can therefore be
3992            tested. view.py contains only the wx-specific parts and is fairly
3993            simple.
3994    
3995            * Thuban/UI/view.py: Stripped out all non-wx functionality. Fixes
3996            RTTbug #1992.
3997            * Thuban/UI/viewport.py: New. Contains non-wx view functionality.
3998            RTTbug #1992.
3999    
4000            * Thuban/Model/classgen.py (generate_singletons,
4001            generate_uniform_distribution, generate_quantiles):
4002            Added 'fixes' parameter so that property attributes can
4003            be held constant over the generated classification groups.
4004            (CustomRamp.GetProperties): Remove unused variables.
4005    
4006            * Thuban/Model/map.py (Map.SetProjection): Send the old
4007            projection as an argument to listeners of the MAP_PROJECTION_CHANGED
4008            event.
4009    
4010            * Thuban/Model/table.py (table_to_dbf, table_to_csv): Added 'records'
4011            parameter which is a list of records that restricts which
4012            records are saved. Fixes RTbug #1997.
4013    
4014            * Thuban/UI/application.py (ThubanApplication.ShowExceptionDialog):
4015            Port exception dialog from GREAT-ER. Fixes RTbug #1993.
4016    
4017            * Thuban/UI/classgen.py (ClassGenDialog.__init__): Add controls
4018            to allow the user to fix line color/width on generated groups.
4019            (ClassGenDialog.OnOK): Use new 'fixes' parameter of the generate_*
4020            functions to optionally fix group properties.
4021    
4022            * Thuban/UI/main.py (main): Set exception hook to the
4023            ShowExceptionDialog. Fixes RTbug #1993.
4024    
4025            * Thuban/UI/mainwindow.py (MainWindow.ShowTableView): Raise
4026            the table window when it is selectd to be shown.
4027    
4028            * Thuban/UI/tableview.py (QueryTableFrame.__init__): Add an
4029            Export Selection button and move the export buttons underneath
4030            the table.
4031            (QueryTableFrame.UpdateStatusText): Added event argument so
4032            that it can respond to grid selection events. The status text
4033            is now updated even when the table is not associated with a
4034            layer as was previously assumed.
4035            (QueryTableFrame.OnGridSelectRange, OnGridSelectCell): Removed.
4036            UpdateStatusText responds to these events.
4037            (QueryTableFrame.OnSaveAs): Renamed to doExport.
4038            (QueryTableFrame.doExport): Helper function that saves the
4039            entire table, or selected rows, to a file.
4040            (QueryTableFrame.OnExport, QueryTableFrame.OnExportSel): New.
4041            Respond to export button events and call doExport.
4042    
4043            * extensions/thuban/gdalwarp.cpp (ProjectRasterFile): Make sure
4044            the function doesn't return NULL without first setting a Python
4045            Error.
4046    
4047            * test/runtests.py (main): Only print "Unknown option" for
4048            unsupported options.
4049    
4050            * test/support.py (FloatComparisonMixin.assertFloatEqual): Take
4051            optional epsilon argument to specify floating point accuracy.
4052            (FloatComparisonMixin.assertFloatSeqEqual): Call assertFloatEqual
4053            for each item test.
4054    
4055            * test/test_csv_table.py (TestCSVTable.test_table_to_cvs): Add
4056            tests for saving selected records.
4057    
4058            * test/test_dbf_table.py (TestTableToDBF.test_table_to_dbf): Add
4059            tests for saving selected records.
4060    
4061            * test/test_map.py (TestMapWithContents.test_set_projection):
4062            MAP_PROJECTION_CHANGED events send the old projection.
4063    
4064            * test/test_session.py
4065            (TestSessionWithContent.test_forward_map_projection):
4066            MAP_PROJECTION_CHANGED events send the old projection.
4067    
4068            * test/test_table.py (TableTest): Update tests to use non-deprecated
4069            functions.
4070    
4071    2003-07-08  Bernhard Herzog  <[email protected]>
4072    
4073            * Thuban/Model/transientdb.py (TransientTableBase.Width): The type
4074            constants in the column objects are the standard ones defined in
4075            the table module.
4076    
4077            * test/test_transientdb.py
4078            (TestTransientTable.test_transienttable_to_dbf): New. Test whether
4079            exporting transient tables as DBF works. This should catch the bug
4080            just fixed in TransientTableBase.Width.
4081    
4082    2003-07-08  Bernhard Herzog  <[email protected]>
4083    
4084            * Thuban/Model/classgen.py (CustomRamp.GetProperties): Compute the
4085            interpolated colors correctly.
4086    
4087            * test/test_classgen.py (TestCustomRamp.test_color_interpolation):
4088            New. Test case for the fix in classgen.py
4089    
4090    2003-07-08  Bernhard Herzog  <[email protected]>
4091    
4092            * test/runtests.py (main): Make the default output less verbose
4093            and add a verbosity option (-v) to get the old output
4094    
4095    2003-07-08  Bernhard Herzog  <[email protected]>
4096    
4097            * Resources/XML/thuban-0.9.dtd: New. This will become the DTD for
4098            0.9.
4099    
4100            * Thuban/Model/transientdb.py (TransientJoinedTable.JoinType):
4101            New. Return the join type
4102    
4103            * Thuban/Model/save.py (SessionSaver.write_session): Use new 0.9
4104            DTD
4105            (SessionSaver.write_data_containers): Save the join type for
4106            joined tables
4107    
4108            * Thuban/Model/load.py (SessionLoader.__init__): Add the new 0.9
4109            namespace
4110            (SessionLoader.start_jointable): Handle the jointype attribute
4111    
4112            * test/test_load_0_8.py: New. Effectively a copy of test_load.py
4113            as of Thuban 0.8. These are now tests to determine whether Thuban
4114            can still read files generated by Thuban 0.8
4115    
4116            * test/test_load.py (LoadSessionTest.dtd)
4117            (TestSingleLayer.file_contents)
4118            (TestLayerVisibility.file_contents, TestLabels.file_contents)
4119            (TestLayerProjection.file_contents)
4120            (TestRasterLayer.file_contents, TestJoinedTable.file_contents)
4121            (TestJoinedTable.file_contents)
4122            (TestLoadError.file_contents): Update for new DTD
4123            (TestJoinedTable.file_contents, TestJoinedTable.setUp): Add test
4124            for new join type attribute
4125    
4126            * test/test_save.py (SaveSessionTest.dtd)
4127            (SaveSessionTest.testEmptySession)
4128            (SaveSessionTest.testSingleLayer)
4129            (SaveSessionTest.testLayerProjection)
4130            (SaveSessionTest.testRasterLayer)
4131            (SaveSessionTest.testClassifiedLayer)
4132            (SaveSessionTest.test_dbf_table)
4133            (SaveSessionTest.test_joined_table): Update for new DTD
4134            (SaveSessionTest.test_joined_table): Add test for new join type
4135            attribute
4136    
4137    2003-07-04  Bernhard Herzog  <[email protected]>
4138    
4139            * Thuban/Model/table.py (_find_dbf_column_names): New. Helper
4140            function for table_to_dbf
4141            (table_to_dbf): Deal with names longer than the 10 character limit
4142    
4143            * test/test_dbf_table.py (TestTableToDBF.test_table_to_dbf): Add
4144            doc-string
4145            (TestTableToDBF.test_table_to_dbf_long_col_names): New test for
4146            long column names
4147    
4148    2003-07-03  Bernhard Herzog  <[email protected]>
4149    
4150            * Doc/manual/thuban-manual.xml: Fix the CVS Revision Tag syntax
4151    
4152    2003-07-03  Bernhard Herzog  <[email protected]>
4153    
4154            * Doc/manual/thuban-manual.xml, Doc/manual/README: New. Skeleton
4155            for the Thuban manual and README with some basic information about
4156            the manual
4157    
4158    2003-07-03  Bernhard Herzog  <[email protected]>
4159    
4160            * Thuban/Model/transientdb.py (TransientJoinedTable.__init__):
4161            Update doc-string
4162            (TransientJoinedTable.create): Do not modify the column objects of
4163            the input tables in place and copy all columns of the input tables
4164            into the joined table after all.
4165    
4166            * test/test_transientdb.py
4167            (TestTransientTable.test_transient_joined_table_same_column_name):
4168            Update to reflect the new behavior
4169            (TestTransientTable.test_transient_joined_table_with_equal_column_names):
4170            Update to reflect the new behavior
4171            (TestTransientTable.test_transient_joined_table_name_collisions_dont_modify_in_place):
4172            New test case for a bug which modified the column objects in place
4173    
4174    2003-07-02  Jonathan Coles   <[email protected]>
4175    
4176            * Thuban/Model/classgen.py (generate_singletons,
4177            generate_uniform_distribution, generate_quantiles,
4178            GenQuantiles0): Make sure maxValue isn't less than
4179            one, otherwise we could divide by zero.
4180    
4181            * test/test_classgen.py (ClassGenTest.doClassRangeTest,
4182            ClassGenTest.doClassSingleTest): Call doBoundsTest to
4183            check the end classification groups against the
4184            proper property values.
4185            (ClassGenTest.doBoundsTest): New. Checks the first and
4186            last classification groups to make sure their properties
4187            are the correct upper and lower bounds for a color ramp.
4188    
4189    2003-07-02  Jonathan Coles   <[email protected]>
4190    
4191            * Thuban/Model/classgen.py (generate_singletons,
4192            generate_uniform_distribution, generate_quantiles,
4193            GenQuantiles0): The denominator was one to high when
4194            calculating the index for the ramp causing the index
4195            to never to reach one.
4196    
4197    2003-07-02  Jonathan Coles   <[email protected]>
4198    
4199            Changed the singature of ClassGroupRange.__init__ and
4200            ClassGroupRange.SetRange() so that the min/max values are
4201            passed as a tuple. This makes a better calling scheme for
4202            when a Range object is passed instead.
4203    
4204            * Thuban/Model/classgen.py: Fixed parameters to
4205            ClassGroupRange constructor.
4206    
4207            * Thuban/Model/classification.py (ClassGroupRange.__init__):
4208            Consolidate the min/max parameters into a single _range which
4209            can either be a tuple or a Range object.
4210            (ClassGroupRange.SetRange): Consolidate the min/max parameters
4211            into a single _range which can either be a tuple or a Range object.
4212    
4213            * Thuban/Model/load.py (SessionLoader.start_clrange): Fix
4214            call to ClassGroupRange constructor to use a tuple.
4215    
4216            * Thuban/Model/layer.py (Layer.SetClassification): Switch
4217            the classification instance variable to the new class
4218            before calling _set_layer otherwise subscribers to a
4219            LAYER_CHANGED event will not see any difference.
4220    
4221            * test/test_classification.py: Fix tests of ClassGroupRange
4222            so that they use the new signature.
4223    
4224            * test/test_load.py: Fix use of ClassGroupRange so that it
4225            uses the new signature.
4226    
4227            * test/test_load_0_2.py: Fix use of ClassGroupRange so that it
4228            uses the new signature.
4229    
4230            * test/test_save.py: Fix use of ClassGroupRange so that it
4231            uses the new signature.
4232    
4233    
4234    2003-07-01  Jonathan Coles   <[email protected]>
4235    
4236            * Thuban/Model/classgen.py: Fixes RTbug #1972, 1971.
4237            Import used objects/class from color.
4238            (generate_singletons): We don't
4239            need the numGroups parameter anymore because we are using
4240            the new ramps with GetProperties().
4241            (generate_uniform_distribution): Use new ramp method
4242            GetProperties().
4243            (generate_quantiles, GenQuantiles0): Use new ramp method
4244            GetProperties().
4245            (CustomRamp.SetNumGroups): Removed. The ramps now map
4246            a value from 0 to 1 to class properties so the number
4247            of groups is not needed ahead of time.
4248            (CustomRamp.next): Removed. CustomRamp does not support
4249            interation anymore.
4250            (CustomRamp.GetProperties): Returns a ClassGroupProperties
4251            object based on the index value from 0 to 1 that is
4252            passed to it.
4253            (GreyRamp, RedRamp, GreenRamp, BlueRamp, GreenToRedRamp):
4254            Made into instances of Monochromatic class instread of
4255            deriving from it.
4256            (HotToCold.SetNumGroups): Removed. See CustomRamp.
4257            (HotToCold.next): Removed. See CustomRamp.
4258    
4259            * Thuban/Model/classification.py: Fixes RTbug #1973, 1971.
4260            (Classification.SetField, Classification.SetFieldType):
4261            Replaced with SetFieldInfo.
4262            (Classification.SetFieldInfo): New. Does a better job of
4263            what SetField and SetFieldType used to do by combining
4264            their function since they should really always be done
4265            at the same time.
4266            (Classification.SetLayer): Renamed to _set_layer.
4267            (Classification._set_layer): Should only be called from
4268            Layer's SetClassification. This does not cause a recursive
4269            call as SetLayer did because we know that Layer knows about
4270            the classification.
4271    
4272            * Thuban/Model/color.py: Fixes RTbug #1971.
4273            (_Transparent): Renamed from Transparent so it doesn't
4274            conflict with the module variable.
4275            (Transparent, Black): Renamed from Color.Transparent,
4276            Color.Black so they are not class variables.
4277    
4278            * Thuban/Model/layer.py: Fixes RTbug #1971, 1973.
4279            (Layer.Destroy): We don't need to call SetClassification
4280            anymore to clear out the back reference in the classifcation
4281            to the layer. It's better to set it to None using _set_layer,
4282            and we won't be creating another clas object too.
4283            (Layer.SetClassification): Classification._set_layer is not
4284            recursive so remove all the locking variables. Also clean
4285            up the code so that it remains unchanged if something fails.
4286    
4287            * Thuban/Model/load.py: Fixes RTbug #1971.
4288            (SessionLoader.start_classification): Call
4289            Classification.SetFieldInfo().
4290    
4291            * Thuban/Model/save.py: Removed import of Color which wasn't
4292            being used.
4293    
4294            * Thuban/UI/classgen.py: Fixes RTbug #1972.
4295            (ClassGenDialog.__init__): Color ramps are now instances
4296            already so we don't need to create any new objects.
4297            (ClassGenDialog.OnOK): Check for numGroups is no longer
4298            necessary because we never use it.
4299    
4300            * Thuban/UI/classifier.py: Fixes RTbug #1971.
4301            (Classifier.__BuildClassification, Classifier.__SetGridTable):
4302            Call Classification.SetFieldInfo() instead of SetFieldType.
4303    
4304            * Thuban/UI/renderer.py: Fixes RTbug #1971.
4305    
4306            * Thuban/UI/view.py: Fixes RTbug #1974, 1971.
4307            (MapCanvas.__init__): Subscribe to the idle time event. Set
4308            background color to white.
4309            (MapCanvas.OnPaint): Set a flag indicating that we should
4310            render the map during idle time. If we already have a bitmap
4311            just draw it now.
4312            (MapCanvas.OnIdle): New. Render the map only during idle time.
4313            This also fixes a problem with the busy cursor under gtk.
4314    
4315            * test/test_classgen.py (ClassGenTest.test_generate_singletons):
4316            Fix calls to generate_singletons because the signature changed.
4317    
4318            * test/test_classification.py: Fix color references and
4319            change calls to Classification.[SetField|SetFieldType] to
4320            SetFieldInfo.
4321    
4322            * test/test_load.py: Fix color references.
4323    
4324            * test/test_load_0_2.py: Fix color references.
4325    
4326            * test/test_save.py (SaveSessionTest.testClassifiedLayer):
4327            Change calls to Classification.[SetField|SetFieldType] to
4328            SetFieldInfo.
4329    
4330    2003-07-01  Frank Koormann   <[email protected]>
4331    
4332            MERGE from the greater-ms3 branch.
4333    
4334            * test/test_transientdb.py
4335            (TestTransientTable.test_transient_joined_table_with_equal_column_names):
4336            New. Test join of two tables with partly equal column names.
4337    
4338            * Thuban/Model/transientdb.py (TransientJoinedTable.create):
4339            If duplicates in left and right tables column names are found,
4340            append '_' (underscores) to the name until it is unique.
4341            Create always new internal names for the resulting table and reference
4342            columns in the join statement with <table>.<column>
4343    
4344    2003-07-01  Bernhard Herzog  <[email protected]>
4345    
4346            * test/test_transientdb.py
4347            (TestTransientTable.test_transient_joined_table_same_column_name):
4348            New. Test whether joining on columns with the same names in both
4349            tables works.
4350            
4351            * Thuban/Model/transientdb.py (TransientJoinedTable.create): Make
4352            sure to use the right internal names even when joining on field
4353            with the same names in both tables. Also, detect duplicate names
4354            in the joined table correctly.
4355    
4356    2003-07-01  Frank Koormann   <[email protected]>
4357    
4358            * Thuban/UI/renderer.py (ExportRenderer.render_legend):
4359            Reverse List of layers to render in same order as in desktop legend.
4360    
4361    2003-06-30  Jonathan Coles   <[email protected]>
4362    
4363            * Thuban/version.py (make_tuple): Takes a version string
4364            and splits it into a tuple of at most three integers.
4365            Used make_tuple() to make tuple versions of the version
4366            numbers.
4367    
4368            * Thuban/UI/about.py: Add Thuban email addresses.
4369    
4370    2003-06-30  Jonathan Coles   <[email protected]>
4371    
4372            * Thuban/version.py: SQLite/PySQLite version dependencies
4373            were too high.
4374    
4375    2003-06-30  Jonathan Coles   <[email protected]>
4376    
4377            * Thuban/version.py: Update version to 0.8.1
4378            
4379            * MANIFEST.in: Added Projections so that default.proj is
4380            included.
4381    
4382    2003-06-26  Jonathan Coles   <[email protected]>
4383    
4384            New About box with lots more information including library
4385            versions and credits. More/better version checking before
4386            Thuban starts.
4387    
4388            * Thuban/UI/about.py: New. New About box that displays
4389            library version information and credits.
4390    
4391            * Thuban/version.py: Added new 'versions' dictionary which
4392            contains the verions of various libraries which are checked
4393            when the module loads.
4394            (verify_versions): Check all version numbers and returns
4395            a list of errors.
4396    
4397            * Thuban/UI/classifier.py (Classifier.__EnableButtons):
4398            Reset the status of the buttons as the situation warrants,
4399            but in a better more reliable way by not relying on the
4400            current status to determine what needs to change.
4401    
4402            * Thuban/UI/main.py (wxCHECK_VERSION): Removed. Not needed.
4403            (verify_versions): Remove most of the code since it is
4404            now in Thuban.version.verify_versions.o
4405    
4406            * Thuban/UI/mainwindow.py (MainWindow.About): Call new
4407            About box in Thuban.UI.about.
4408    
4409            * extensions/thuban/gdalwarp.cpp (get_gdal_version): New.
4410            Returns the version of gdal library being used as a string.
4411    
4412            * extensions/thuban/wxproj.cpp (check_version, check_version_gtk):
4413            Removed.
4414            (get_proj_version): Return the version of PROJ that the file
4415            was compiled with.
4416            (get_gtk_version): Return th version of GTK that the file
4417            was compiled with.
4418    
4419    2003-06-25  Jonathan Coles   <[email protected]>
4420    
4421            * Thuban/UI/classifier.py (Classifier.EditSymbol): The parent
4422            of the SelectPropertiesDialog should be self so the window
4423            appears on top.
4424            (ClassGroupPropertiesCtrl.DoEdit): The parent
4425            of the SelectPropertiesDialog should be self so the window
4426            appears on top.
4427    
4428            * Thuban/UI/resource.py: Cleaned up how we determine file
4429            extensions.
4430            (GetImageResource): Return an wxImage from our Resources.
4431    
4432    2003-06-24  Jonathan Coles   <[email protected]>
4433    
4434            * Thuban/UI/renderer.py (ExportRenderer.render_legend):
4435            Check that a layer has a classification before trying
4436            to get it. Raster layers don't have classifications.
4437    
4438    2003-06-23  Jonathan Coles   <[email protected]>
4439            
4440            * setup.py: Add Resources/XML to resource list.
4441        
4442    2003-06-23  Jonathan Coles   <[email protected]>
4443    
4444            * setup.cfg: Fix copyright dates
4445        
4446    2003-06-23  Jonathan Coles   <[email protected]>
4447    
4448            * MANIFEST.in: Update with Resources/XML
4449    
4450            * setup.py: Don't include Locale resources yet as we don't
4451            have any and it causes problems building the distribution
4452            for Windows. Update version to 0.8.0.
4453    
4454            * Doc/thuban.dtd: Removed since it is now in Resources/XML.
4455    
4456            * Thuban/UI/mainwindow.py: Add blank line at the end because
4457            file was not being read correctly building the Windows
4458            distribution.
4459    
4460    2003-06-23  Jonathan Coles   <[email protected]>
4461    
4462            * Thuban/UI/mainwindow.py (MainWindow.About): Fix text.
4463    
4464            * Thuban/version.py: Temporarily update longversion for
4465            the 0.8 release so that it doesn't have the cvs revision.
4466    
4467    2003-06-23  Jonathan Coles   <[email protected]>
4468    
4469            * Thuban/UI/common.py (ThubanBeginBusyCursor): Call wxSafeYield
4470            to make sure that we don't create reentrant possibilities with
4471            wxYield.
4472    
4473            * Thuban/UI/view.py (MapCanvas.OnPaint): Call wxBeginBusyCursor()
4474            directly to avoid the wxSafeYield() call which generates an
4475            OnPaint event causing infinite recursion. Don't try to catch
4476            exception anymore. This was for before there were limits on map
4477            scaling.
4478    
4479    2003-06-23  Bernhard Herzog  <[email protected]>
4480    
4481            Bug fix for RT #1961:
4482    
4483            * Thuban/Model/load.py (SessionLoader.start_derivedshapesource):
4484            Register DerivedShapestores with the session
4485    
4486            * Thuban/Model/session.py (Session.Tables): Make sure each table
4487            is only listed once.
4488    
4489            * test/test_load.py (TestJoinedTable.test): Add check_format call.
4490            Update file contents to match the one written out.
4491    
4492    2003-06-20  Bernhard Herzog  <[email protected]>
4493    
4494            * test/xmlsupport.py (SaxEventLister.startElementNS)
4495            (SaxEventLister.endElementNS): Do not include the qname. Python
4496            2.2.1 and 2.2.2 and 2.2.3 differ in this regard. In 2.2.1 qname it
4497            is (presumably incorrectly) None, whereas it's a string with the
4498            element name in the later versions.
4499    
4500            * test/test_xmlsupport.py (TestEventList.test_even_list_simple)
4501            (TestEventList.test_even_list_namespace): Update tests to reflect
4502            the new behaviour
4503            (TestEventList.test_even_list_id_normalization): Fix doc-string
4504    
4505    2003-06-20  Jonathan Coles   <[email protected]>
4506    
4507            * Thuban/Model/layer.py (BaseLayer.HasShapes): New. Overridden
4508            by deriving classes to determine if that layer supports shapes.
4509            (Layer): Override HasShapes and return true.
4510    
4511            * Thuban/UI/classgen.py: Use Thuban[Begin|End]BusyCursor()
4512            instead of a direct call to wx[Begin|End]CusyCursor().
4513            (GenUniquePanel._OnRetrieve): Set busy cursor while retrieving
4514            table data.
4515    
4516            * Thuban/UI/common.py (ThubanBeginBusyCursor, ThubanEndBusyCursor):
4517            New. Wrappers around the wxWindows functions that allow us to
4518            make additional calls such as wxYield which gives the native
4519            system a chance to update the cursor correctly.
4520    
4521            * Thuban/UI/tableview.py: Use Thuban[Begin|End]BusyCursor()
4522            instead of a direct call to wx[Begin|End]CusyCursor().
4523    
4524            * Thuban/UI/view.py: Use Thuban[Begin|End]BusyCursor()
4525            instead of a direct call to wx[Begin|End]CusyCursor().
4526            (MapCanvas.find_shape_at): Check if the current search layer
4527            support shapes, otherwise go on to the next layer.
4528    
4529            * test/test_layer.py: Add tests in each type of layer for
4530            HasClassification() and HasShapes()
4531    
4532    2003-06-20  Jonathan Coles   <[email protected]>
4533    
4534            * Thuban/UI/view.py (MapCanvas.OnPaint): Call wxYield after
4535            turning on the busy cursor to allow the system to change the
4536            cursor before we begin painting. This fixes a problem that
4537            was occuring only under GTK. Fixes RTbug #1840.
4538    
4539    2003-06-20  Bernhard Herzog  <[email protected]>
4540    
4541            * Resources/XML/thuban-0.8.dtd: New DTD for the new file format
4542            version.
4543    
4544            * Thuban/Model/save.py (sort_data_stores): New. Make topological
4545            sort of the data sources so they can be written with sources that
4546            data sources that depend on other data sources come after the
4547            sources they depend on.
4548            (SessionSaver.__init__): Add idmap instance variable to map from
4549            objects to the ids used in the file.
4550            (SessionSaver.get_id, SessionSaver.define_id)
4551            (SessionSaver.has_id): New. Methods to manage the idmap
4552            (SessionSaver.write): Use thuban-0.8.dtd
4553            (SessionSaver.write_session): Add a namespace on the session and
4554            write out the data sources before the maps.
4555            (SessionSaver.write_data_containers): New. Write the data
4556            containers.
4557            (SessionSaver.write_layer): Layer elements now refer to a
4558            shapestore and don't contain filenames anymore.
4559    
4560            * Thuban/Model/load.py (LoadError): Exception class to raise when
4561            errors in the files are discovered
4562            (SessionLoader.__init__): Define dispatchers for elements with a
4563            thuban-0.8 namespace too.
4564            (SessionLoader.check_attrs): New helper method to check and
4565            convert attributes
4566            (AttrDesc): New. Helper class for SessionLoader.check_attrs
4567            (SessionLoader.start_fileshapesource)
4568            (SessionLoader.start_derivedshapesource)
4569            (SessionLoader.start_filetable, SessionLoader.start_jointable):
4570            Handlers for the new elements in the new fileformat
4571            (SessionLoader.start_layer): Handle the shapestore attribute in
4572            addition to filename.
4573            (SessionLoader.start_table, SessionLoader.end_table): Removed.
4574            They were never used in the old formats and aren't needed for the
4575            new.
4576    
4577            * Thuban/Model/session.py (Session.DataContainers): New method to
4578            return all "data containers", i.e. shapestores and tables
4579    
4580            * test/xmlsupport.py (SaxEventLister.__init__)
4581            (SaxEventLister.startElementNS, sax_eventlist): Add support to
4582            normalize IDs.
4583    
4584            * test/test_xmlsupport.py
4585            (TestEventList.test_even_list_id_normalization): New test case for
4586            id normalization
4587    
4588            * test/test_load.py (LoadSessionTest.check_format): Use ID
4589            normalization
4590            (LoadSessionTest.thubanids, LoadSessionTest.thubanidrefs): New
4591            class atrributes used for ID normalization
4592            (TestSingleLayer, TestLayerVisibility, TestLabels.test)
4593            (TestLayerProjection.test, TestRasterLayer.test): Adapt to new
4594            file format
4595            (TestJoinedTable): New test for loading sessions with joined
4596            tables.
4597            (TestLoadError): New. Test whether missing required attributes
4598            cause a LoadError.
4599    
4600            * test/test_save.py (SaveSessionTest.thubanids)
4601            (SaveSessionTest.thubanidrefs): New class attributes for ID
4602            normalization in .thuban files.
4603            (SaveSessionTest.compare_xml): Use id-normalization.
4604            (SaveSessionTest.testEmptySession)
4605            (SaveSessionTest.testLayerProjection)
4606            (SaveSessionTest.testRasterLayer)
4607            (SaveSessionTest.testClassifiedLayer): Adapt to new file format.
4608            (SaveSessionTest.testLayerProjection): The filename used was the
4609            same as for testSingleLayer. Use a different one.
4610            (SaveSessionTest.test_dbf_table)
4611            (SaveSessionTest.test_joined_table): New test cases for saving the
4612            new data sources structures.
4613            (TestStoreSort, MockDataStore): Classes to test the sorting of the
4614            data stores for writing.
4615    
4616            * test/runtests.py: Add CVS keywords
4617    
4618    2003-06-20  Jonathan Coles   <[email protected]>
4619    
4620            * test/test_session.py
4621            (UnreferencedTablesTests.test_unreferenced_tables_with_joins):
4622            Use the cultural_landmark-point.dbf file for the store so that
4623            the table rows and shape count match.
4624    
4625    2003-06-20  Jonathan Coles   <[email protected]>
4626    
4627            * Thuban/Model/data.py (DerivedShapeStore.__init__): Raise
4628            an exception if the number of shapes is different from the
4629            number of rows in the table. Address RTbug #1933.
4630    
4631            * test/test_layer.py (TestLayer.test_derived_store): Add
4632            a test for the new exception in DerivedShapeStore.__init__.
4633    
4634            * test/support.py (FloatTestCase): Removed since there is
4635            already FloatComparisonMixin. Fixes RTbug #1954.
4636            (FloatComparisonMixin.assertFloatEqual): Include test for
4637            infinity that was part of FloatTestCase.
4638    
4639            * test/test_range.py (RangeTest): Inherit from
4640            support.FloatComparisonMixin now that we don't have
4641            support.FloatTestCase.
4642    
4643    2003-06-20  Bernhard Herzog  <[email protected]>
4644    
4645            * test/test_save.py (SaxEventLister, sax_eventlist): Removed. Use
4646            the implementation in xmlsupport instead.
4647            (SaveSessionTest.compare_xml): sax_eventlist is now in xmlsupport
4648    
4649            * test/test_proj.py: Import sax_eventlist from xmlsupport instead
4650            of test_save
4651    
4652    2003-06-20  Bernhard Herzog  <[email protected]>
4653    
4654            * test/test_load.py (LoadSessionTest.check_format): New helper
4655            method to make sure the test files we load might have been written
4656            by the current thuban version.
4657            (ClassificationTest.TestLayers, TestSingleLayer.test)
4658            (TestLayerVisibility.test, TestClassification.test)
4659            (TestLabels.test, TestLayerProjection.test, TestRasterLayer.test):
4660            Add check_format() calls and fix the thuban data to match the data
4661            that would be written by saving the session loaded from it.
4662    
4663            * test/xmlsupport.py (SaxEventLister, sax_eventlist): Copies of
4664            the same class and function in test_save.
4665    
4666            * test/test_xmlsupport.py (TestEventList): New. test cases for
4667            sax_eventlist
4668    
4669    2003-06-20  Bernhard Herzog  <[email protected]>
4670    
4671            * Resources/XML/thuban.dtd: Add comment about which versions of
4672            Thuban are covered by this DTD
4673            (map): Fix content model for layers and raster layers. There can
4674            be any number or layers and raster layers in any order.
4675    
4676    2003-06-20  Jonathan Coles   <[email protected]>
4677    
4678            This is mainly about fixing RTbug #1949.
4679    
4680            * Thuban/Model/classification.py: Remove "from __future__"
4681            import statement since python 2.2 is the earliest supported
4682            version.
4683    
4684            * Thuban/Model/proj.py (Projection.GetProjectedUnits): New.
4685            Currently returns PROJ_UNITS_METERS or PROJ_UNITS_DEGREES
4686            depending on the units this projection *forwards* into.
4687    
4688            * Thuban/Model/save.py (SessionSaver.write_classification):
4689            Remove unnecessary use of lambdas and nested functions.
4690    
4691            * Thuban/UI/legend.py (ScaleBarBitmap.__SetScale): Do scale
4692            adjustment here if the map projection uses degrees.
4693    
4694            * Thuban/UI/scalebar.py (ScaleBar.DrawScaleBar): Remove
4695            scale adjust code since it is now done before calling
4696            this method. Don't do anything if the map projection
4697            is None.
4698    
4699    2003-06-19  Bernhard Herzog  <[email protected]>
4700    
4701            Move version specific load tests to their own file.
4702    
4703            * test/test_load.py: Expand the doc-string to explain a bit how to
4704            handle file format changes.
4705            (TestClassification.test): Update the docstring as this test is
4706            not about Thuban 0.2 anymore.
4707    
4708            * test/test_load_0_2.py: New file with the load tests for thuban
4709            files created with Thuban 0.2 and earlier.
4710    
4711    2003-06-19  Bernhard Herzog  <[email protected]>
4712    
4713            Add XML validation to some of the tests. Validation will only be
4714            done if pyRXP is installed (http://reportlab.com/xml/pyrxp.html).
4715            To make the DTD available to the test cases it's moved into
4716            Resources/XML
4717    
4718            * Resources/XML/thuban.dtd: New. This is now the real Thuban DTD
4719            for versions up to and including 0.2. Two slight changes: added an
4720            encoding specification and fixed the comment which refered to
4721            GRASS, not Thuban
4722    
4723            * test/xmlsupport.py: New support module for tests involving XML.
4724            Currently there's a mix-in class for XML validation.
4725    
4726            * test/test_xmlsupport.py: New. Tests for the xmlsupport module
4727    
4728            * test/test_save.py (SaveSessionTest): Derive from ValidationTest
4729            so that we can validate the
4730            (SaveSessionTest.testEmptySession)
4731            (SaveSessionTest.testSingleLayer)
4732            (SaveSessionTest.testSingleLayer)
4733            (SaveSessionTest.testLayerProjection)
4734            (SaveSessionTest.testRasterLayer)
4735            (SaveSessionTest.testClassifiedLayer): Validate the generated XML
4736    
4737            * test/runtests.py (main): Call print_additional_summary instead
4738            of print_garbage_information
4739    
4740            * test/support.py (resource_dir): New function to return the
4741            "Resource" subdirectory
4742            (print_additional_summary): New function to combine several
4743            summary functions
4744            (run_tests): Use print_additional_summary instead of calling
4745            print_garbage_information directly
4746    
4747    2003-06-19  Bernhard Herzog  <[email protected]>
4748    
4749            * Doc/thuban.dtd (classification): Correct the content model of
4750            the classification element.
4751            (projection): Add the "name" attribute
4752    
4753    2003-06-19  Frank Koormann   <[email protected]>
4754    
4755            MERGE from the greater-ms3 branch.
4756    
4757            * Thuban/UI/scalebar.py (ScaleBar.DrawScaleBar): Apply conversion to
4758            scale if projection is latlong to get better estimate.
4759    
4760            Fix problem of hidden properties dialog under windows after double
4761            click on layer tree:
4762            The tree control always gets an Expanded / Collapsed event after
4763            the ItemActivated  on double click, which raises the main window again.
4764            We add a second ItemActivated event to the queue, which simply
4765            raises the already displayed window.
4766    
4767            * Thuban/UI/legend.py (LegendTree.__init__): Instance variable
4768            raiseProperties initialized to prevent endless loops
4769            (LegendTree._OnItemActivated): Depending on self.raiseProperties
4770            simply raise the properties or open the dialog and issue a second
4771            event.
4772    
4773    2003-06-18  Jonathan Coles   <[email protected]>
4774    
4775            * setup.py: Fix a few problems that occured under Windows.
4776    
4777    2003-06-18  Jonathan Coles   <[email protected]>
4778    
4779            When Thuban loaded the map was redrawn twice because the
4780            legend was being opened after the mainwindow was created
4781            and not during its creation. This meant the map was drawn
4782            initially and then had to be redrawn when the legend
4783            caused the display to change. Now the legend is opened
4784            in the mainwindow constructor which resolves this issue.
4785    
4786            Also, although we were checking for the existence of
4787            gdal and gdalwarp modules, the gdalwarp extension was
4788            still being compiled (which may fail if the system doesn't
4789            have gdal installed). the build_ext command to setup.py
4790            now accepts the flags --with-gdal and --without-gdal.
4791            If --without-gdal is specified setup.py will try to
4792            use the gdal parameters specified by gdal-config. Under
4793            windows, those parameters have to be set in setup.py
4794            as with proj4 an wxWindows.
4795    
4796            * setup.py: Use a list instead of seperate variables for
4797            extension parameters so we can create a generic function
4798            that runs an appropriate *-config script.
4799            (run_cs_script): Renamed from run_wx_script and modified
4800            to accept a second argument which is a list of lists to
4801            be filled in by the values returned from running the command.
4802            (thuban_build_ext): New. Extends the build_ext command and
4803            provides the options --with-gdal/--without-gdal which then
4804            optionally includes the gdalwarp extension.
4805    
4806            * Thuban/Model/resource.py: First check if we can import
4807            the gdalwarp Thuban extension before checking for gdal.
4808            Also added some comments.
4809            
4810            * Thuban/UI/legend.py (ScaleBarBitmap.__SetScale): Check if
4811            the map is None which may be the case if none has been loaded
4812            yet.
4813    
4814            * Thuban/UI/main.py (main): Remove call to ShowLegend.
4815    
4816            * Thuban/UI/mainwindow.py (MainWindow.__init__): Call ShowLegend().
4817    
4818            * Thuban/UI/renderer.py: Check for gdal support before importing
4819            gdalwarp.
4820            (MapRenderer.render_map): Only try to optimize if we have gdal
4821            support otherwise nothing will get drawn.
4822    
4823            * Thuban/UI/view.py (MapCanvas.FitMapToWindow): This may be called
4824            during startup before a map has been created. Check if map is None
4825            before using it and do nothing if it is.
4826    
4827    2003-06-17  Jonathan Coles   <[email protected]>
4828    
4829            Fix the problem with raster layers under Windows that caused
4830            Thuban to crash. The view should respond to layer projection
4831            changed events to update the display. Changes to a projection
4832            should not cause the map to be set to full extent.
4833            
4834            * Thuban/UI/view.py (MapCanvas.__init__): New instance variable
4835            current_map_proj to remember the current map projection so that
4836            when the projection changes we know what the previous projection
4837            was.
4838            (MapCanvas.SetMap): Unsubscribe and subscribe to
4839            LAYER_PROJECTION_CHANGED events.
4840            (MapCanvas.projection_changed): Split into two methods that respond
4841            to map and layer projection changes.
4842            (MapCanvas.map_projection_changed): New. Takes the current view and
4843            projects it using the new projection. This does not cause the
4844            map to be redrawn at full extent.
4845            (MapCanvas.layer_projection_changed): New. Cause a redraw which
4846            will draw each layer in its new projection.
4847            
4848            * extensions/thuban/bmpdataset.cpp (BMPDataset::Open): Call
4849            VSIFClose() not VSIFCloseL() to close the file. Fixes a crash
4850            under Windows.
4851            
4852            * extensions/thuban/gdalwarp.cpp (MFILENAME): Padding should be
4853            to twice sizeof(void*) because there are two digits for each
4854            hex byte.
4855    
4856    2003-06-16  Bernhard Herzog  <[email protected]>
4857    
4858            Update to the layer interface: Direct access to the table,
4859            shapetable, shapefile and filename attributes is now actively
4860            deprecated by issuing deprecation warnings for all places where
4861            this happens.
4862    
4863            * Thuban/Model/layer.py (Layer.__getattr__): New. Implement access
4864            to the instance variables table, shapetable, shapefile and
4865            filename via __getattr__ so that we can issue a deprecation
4866            warning.
4867            (Layer.SetShapeStore): Don't set the deprecated instance variables
4868            any more
4869            (Layer.SetShapeStore): Don't use deprecated layer instance
4870            variables
4871            (Layer.Destroy): No need to explicitly remove the instance
4872            variables any more
4873            (Layer.GetFieldType, Layer.Shape): Don't use deprecated layer
4874            instance variables
4875    
4876            * Thuban/UI/classgen.py (ClassGenDialog.__init__)
4877            (GenUniformPanel._OnRetrieve, GenUniquePanel._OnRetrieve)
4878            (GenQuantilesPanel.GetList, GenQuantilesPanel.OnRetrieve): Don't
4879            use deprecated layer instance variables
4880    
4881            * Thuban/UI/classifier.py (Classifier.__init__): Don't use
4882            deprecated layer instance variables
4883    
4884            * Thuban/UI/identifyview.py (IdentifyListCtrl.selected_shape)
4885            (IdentifyGridCtrl.selected_shape): Don't set the deprecated layer
4886            instance variables
4887    
4888            * Thuban/UI/tableview.py (LayerTableGrid.select_shapes): Don't use
4889            deprecated layer instance variables
4890    
4891            * Thuban/UI/mainwindow.py (MainWindow.LayerShowTable): Don't use
4892            deprecated layer instance variables
4893    
4894            * Thuban/Model/save.py (SessionSaver.write_layer): Don't use
4895            deprecated layer instance variables
4896    
4897            * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer)
4898            (MapRenderer.polygon_render_param): Don't use deprecated layer instance
4899            variables
4900    
4901            * test/runtests.py (main): Turn Thuban's deprecation warnings into
4902            errors so that they're cought by the tests
4903    
4904            * test/test_load.py (TestSingleLayer.test): Don't use deprecated
4905            layer instance variables
4906    
4907    2003-06-16  Jonathan Coles   <[email protected]>
4908    
4909            Fix a problem under Windows whereby if the user double-clicks on a
4910            layer in the legend that tree item will expand or collapse as well
4911            as open the layer properties dialog. The state of the tree item
4912            should not be affected.
4913    
4914            * Thuban/UI/legend.py (LegendTree.__init__): Add instance variable
4915            preventExpandCollapse and subscribe to expanding and collapsing
4916            events.
4917            (LegendTree.OnItemExpandCollapse): New. Responds to expanding and
4918            collapsing events and will veto the event if it has been triggered
4919            by the user double clicking on a layer.
4920            (LegendTree._OnItemActivated): Set preventExpandCollapse to indicate
4921            that an expanding/collapsing event should be vetoed.
4922    
4923    2003-06-13  Bernhard Herzog  <[email protected]>
4924    
4925            * Thuban/UI/classifier.py (Classifier.OnClose)
4926            (Classifier.map_layers_removed)
4927            (Classifier.layer_shapestore_replaced): Unsubscribe the messages
4928            in OnClose and not in map_layers_removed or
4929            layer_shapestore_replaced to make sure it always happens when the
4930            dialog is closed
4931    
4932    2003-06-13  Jonathan Coles   <[email protected]>
4933    
4934            This puts back a fix for Windows where a panel is needed so that
4935            the background of the table view appears correctly.
4936    
4937            * Thuban/UI/tableview.py (TableFrame.__init__): Add a panel
4938            object that can be used by derived classes to place any
4939            controls (including the grid) onto.
4940            (QueryTableFrame.__init__): Use the panel as the parent window
4941            for all the controls. Reparent the grid so that the panel is
4942            the parent. Call UpdateStatusText() to correctly initialize
4943            the status bar.
4944    
4945    2003-06-13  Jonathan Coles   <[email protected]>
4946    
4947            * Thuban/UI/dialogs.py (ThubanFrame): New: a class that inherits
4948            from wxFrame (as opposed to wxDialog like the other classes)
4949            but otherwise behaves like the other classes. This is needed
4950            for the TableView which isn't really a dialog and needs to
4951            have a status bar and control buttons.
4952    
4953            * Thuban/UI/tableview.py (TableGrid.__init__): Create an
4954            instance variable to keep track of how many rows are selected.
4955            Subscribe once to the the events we are interested in.
4956            (ThubanGrid.OnRangeSelect): Only handle event if event handling
4957            hasn't been turned off.
4958            (ThubanGrid.OnSelectCell): Only handle event if event handling
4959            hasn't been turned off.
4960            (ThubanGrid.ToggleEventListeners): Rather than subscribe None
4961            as an event listener (which changes the event handler stack)
4962            simply set an instance variable to False. This is checked in
4963            the event handlers.
4964            (ThubanGrid.GetNumberSelected): Return the number of currently
4965            selected rows.
4966            (TableFrame): Inherit from ThubanFrame so we can have a
4967            status bar and control buttons.
4968            (QueryTableFrame.__init__): Create a status bar. Fixes RTbug #1942.
4969            Explicitly set which items are selected in the operator choice and
4970            action choice so there is always a valid selection. Fixes RTbug #1941.
4971            Subscribe to grid cell selection events so we can update the
4972            status bar.
4973            (QueryTableFrame.UpdateStatusText): Update the status bar with
4974            how many rows are in the grid, how many columns, and how many
4975            rows are selected.
4976            (QueryTableFrame.OnGridSelectRange, QueryTableFrame.OnGridSelectCell):
4977            Call UpdateStatusText when cells are (de)selected.
4978            (QueryTableFrame.OnQuery): Use the string value in the value
4979            combo if either the selected item index is 0 or if the string
4980            cannot be found in the predefined list (this happens if the
4981            user changes the text). Fixes RTbug #1940.
4982            Only turn off the grid event listeners if there a query comes
4983            back with a none empty list of ids. in the case that the list
4984            is empty this causes a grid.ClearSelection() call to actually
4985            clear the grid selection which causes the selected items in
4986            the map to be deselected. Fixes RTbug #1939.
4987    
4988            * test/test_save.py (XMLWriterTest.Encode): Check return values.
4989            Fixes RTbug #1851.
4990    
4991    2003-06-13  Bernhard Herzog  <[email protected]>
4992    
4993            * Thuban/UI/identifyview.py (IdentifyView.__init__): Call
4994            self.selected_shape with the current selection to make sure the
4995            contents of the dialog are up to date when it's shown for the
4996            first time.
4997            The dialog used to work without this by luck. The recent fix to
4998            the connector module 'broke' a 'feature' the identify view was
4999            relying on, i.e that subscribing to a message in response to
5000            receiving a message of that type would mean that the new
5001            subscriber would also be called for the same message.
5002            
5003    2003-06-12  Jonathan Coles   <[email protected]>
5004    
5005            * extensions/thuban/gdalwarp.cpp: Removed debug printing as
5006            the image is rendered. Fixes RTbug #1937.
5007    
5008    2003-06-12  Jonathan Coles   <[email protected]>
5009    
5010            * Thuban/Lib/fileutil.py: As is done under Windows, create the
5011            user directory if it doesn't exist on a posix system.
5012            Fixes RTbug #1815.
5013    
5014            * Thuban/Model/resource.py (get_user_proj_files): Moved the
5015            called to get_application_dir here, so that the directory
5016            will only be called if this method is invoked.
5017    
5018            * Thuban/UI/projdialog.py (ProjFrame.__DoOnProjAvail): Clear
5019            the projfilepath if no projection is selected.
5020    
5021    2003-06-12  Jonathan Coles   <[email protected]>
5022    
5023            * Thuban/UI/legend.py (ScaleBarBitmap.__SetScale): Don't draw
5024            the scalebar if the current map has no projection set.
5025    
5026            * Thuban/UI/projdialog.py (ProjFrame.__DoOnProjAvail): Set the
5027            projfilepath label to just the basename of the projection file
5028            rather than include the entire path.
5029    
5030            * Thuban/Model/resource.py: Fix missed proj functions that
5031            needed to be renamed.
5032    
5033    2003-06-12  Jonathan Coles   <[email protected]>
5034    
5035            * Thuban/Model/classification.py: Removed assert statements that
5036            tested if the variable was an instance of Color.
5037    
5038            * Thuban/Model/color.py (Color): Remove commented code that isn't
5039            used.
5040            (Transparent): Renamed from NoColor. Doesn't inherit from Color.
5041            Fixes RTbug #1835.
5042            (Transparent.__eq__, Transparent.__ne, Transparent.__repr): New.
5043            Needed now that the class doesn't inherit from Color.
5044    
5045    2003-06-12  Jonathan Coles   <[email protected]>
5046    
5047            * test/test_save.py (XMLWriterTest.testEncode): Explicitly
5048            check unicode strings.
5049    
5050            * test/test_layer.py: Check for existence of gdal.
5051    
5052    2003-06-12  Jonathan Coles   <[email protected]>
5053        
5054            * Thuban/Model/xmlreader.py: New. Contains the XMLReader class
5055            that was in load.py
5056    
5057            * Thuban/Model/xmlwriter.py: New. Contains the XMLWriter class
5058            that was in save.py
5059    
5060    2003-06-12  Jonathan Coles   <[email protected]>
5061    
5062            This is largely a collection of bug fixes. We also handle the
5063            case where gdal is not on the system. The XMLReader and XMLWriter
5064            classes were moved into there own files to resolve some circular
5065            import references and because they shouldn't really be in the
5066            file that is dediciated to reading/writing session files since
5067            they are also used elsewhere.
5068    
5069            * Thuban/Model/classgen.py: Renamed functions to follow the
5070            function_names_with_underscores style. Fixes RTbug #1903.
5071            (calculate_quantiles): Raise ValueError if 'percents' is invalid.
5072    
5073            * Thuban/Model/layer.py: Import gdal only if it available.
5074            (RasterLayer): Handle the case where the gdal library is unavailable.
5075            Addresses RTbug #1877.
5076    
5077            * Thuban/Model/load.py (XMLReader): Moved into seperate file
5078            xmlreader.py.
5079    
5080    2003-06-12  Jonathan Coles   <[email protected]>
5081    
5082            This is largely a collection of bug fixes. We also handle the
5083            case where gdal is not on the system. The XMLReader and XMLWriter
5084            classes were moved into there own files to resolve some circular
5085            import references and because they shouldn't really be in the
5086            file that is dediciated to reading/writing session files since
5087            they are also used elsewhere.
5088    
5089            * Thuban/Model/classgen.py: Renamed functions to follow the
5090            function_names_with_underscores style. Fixes RTbug #1903.
5091            (calculate_quantiles): Raise ValueError if 'percents' is invalid.
5092    
5093            * Thuban/Model/layer.py: Import gdal only if it available.
5094            (RasterLayer): Handle the case where the gdal library is unavailable.
5095            Addresses RTbug #1877.
5096    
5097            * Thuban/Model/load.py (XMLReader): Moved into seperate file
5098            xmlreader.py.
5099    
5100            * Thuban/Model/save.py (escape, XMLWriter): Moved into seperate
5101            file xmlwriter.py.
5102    
5103            * Thuban/Model/resource.py: Renamed functions to following the
5104            function_names_with_underscores style.
5105            (has_gdal_support): New function that returns true if the gdal
5106            library is available. Addresses RTbug #1877.
5107    
5108            * Thuban/UI/application.py (ThubanApplication.OpenSession):
5109            Display a message box if the gdal library is not available, but
5110            only if there are any layers that would use it. Addresses RTbug #1877.
5111    
5112            * Thuban/UI/classgen.py: Use renamed projection resource functions.
5113            (GenUniformPanel.__CalcStepping): Fix a slight discrepency
5114            when using integers versus floats.
5115    
5116            * Thuban/UI/mainwindow.py (_has_gdal_support): New. Used to
5117            determine if the "Add Image Layer" menu option should be
5118            greyed out or not. Addresses RTbug #1877.
5119    
5120            * Thuban/UI/projdialog.py: Use renamed projection resource functions.
5121    
5122            * Thuban/UI/renderer.py (MapRenderer.render_map): Only try to
5123            optimize if a raster layer is visible. Fixes RTbug #1931.
5124            Only draw the raster layer if the gdal library is available.
5125            Addresses RTbug #1877.
5126    
5127            * test/test_classgen.py: Add tests for generate_singletons,
5128            generate_uniform_distribution, generate_quantiles. Fixes RTbug #1903.
5129            (test_calculate_quantiles): Fix some tests to catch the new
5130            ValueError that is raised.
5131    
5132            * test/test_proj.py: Use renamed projection resource functions.
5133    
5134            * test/test_save.py (SaveSessionTest.testClassifiedLayer): New
5135            test for saving classified layers. Fixes RTbug #1902.
5136            (XMLWriterTest): New. Tests the XMLWriter class. Fixes RTbug #1851.
5137    
5138    2003-06-12  Jan-Oliver Wagner <[email protected]>
5139    
5140            Fix for http://intevation.de/rt/webrt?serial_num=1900.
5141    
5142            * Thuban/UI/multiplechoicedialog.py: New. A multiple choice dialog.
5143    
5144            * Thuban/UI/mainwindow.py: import wxMultipleChoiceDialog from
5145            multiplechoicedialog.py rather than from the wxPython library.
5146    
5147    2003-06-11  Frank Koormann  <[email protected]>
5148    
5149            * Thuban/Lib/fileutil.py (get_application_dir): Minor stability
5150            update.
5151    
5152    2003-06-11  Frank Koormann  <[email protected]>
5153    
5154            * Thuban/Lib/fileutil.py (get_application_dir): New function to
5155            determine the absolute .thuban/thuban directory under
5156            "posix" (os.expanduser) and "nt" (read AppData registry key).
5157    
5158            * Thuban/Model/resource.py: Use get_application_dir
5159    
5160            * Thuban/UI/application.py (ThubanApplication.read_startup_files):
5161            Use get_application_dir.
5162    
5163    2003-06-10  Bernhard Herzog  <[email protected]>
5164    
5165            * Thuban/UI/tableview.py (LayerTableFrame.__init__): Subscribe to
5166            the messages MAP_LAYERS_REMOVED messages
5167            (LayerTableFrame.OnClose): Unsubscribe from it.
5168            (LayerTableFrame.map_layers_removed): New. Receiver for
5169            MAP_LAYERS_REMOVED. Close the dialog when the layer whose the
5170            dialog is showing is removed.
5171    
5172    2003-06-10  Bernhard Herzog  <[email protected]>
5173    
5174            * Thuban/Lib/connector.py (Connector.Issue): Iterate over a copy
5175            of the receivers list so that unsubscribing in a receiver doesn't
5176            modify it while iterating over it.
5177    
5178            * test/test_connector.py
5179            (ConnectorTest.test_disconnect_in_receiver): New. Test whether
5180            unsubscribing in a receiver works correctly. See docstring for
5181            details
5182    
5183    2003-06-10  Bernhard Herzog  <[email protected]>
5184    
5185            * Thuban/Model/messages.py (LAYER_SHAPESTORE_REPLACED): New
5186            message.
5187    
5188            * Thuban/Model/layer.py (Layer.SetShapeStore): Send
5189            LAYER_SHAPESTORE_REPLACED when the shapestore changes. A
5190            LAYER_CHANGED will still be sent if the classification changes.
5191    
5192            * Thuban/UI/classifier.py (Classifier.__init__): Add the map as
5193            parameter so we can subscribe to some of its messages
5194            (Classifier.__init__): Subscribe to the map's MAP_LAYERS_REMOVED
5195            and the layer's LAYER_SHAPESTORE_REPLACED
5196            (Classifier.unsubscribe_messages): New. Unsubscribe from message
5197            subscribed to in __init__
5198            (Classifier.map_layers_removed)
5199            (Classifier.layer_shapestore_replaced): receivers for the messages
5200            subscribed to in __init__. Unsubscribe and close the dialog
5201    
5202            * Thuban/UI/mainwindow.py (MainWindow.OpenLayerProperties): Pass
5203            the map to the Classifier dialog
5204    
5205            * test/test_layer.py (SetShapeStoreTests): Derive from
5206            SubscriberMixin as well so we can test messages
5207            (SetShapeStoreTests.setUp): Subscribe to some of the layer's
5208            messages
5209            (SetShapeStoreTests.tearDown): Clear the messages again
5210            (SetShapeStoreTests.test_sanity): Expand the doc-string and check
5211            for the modified flag too
5212            (SetShapeStoreTests.test_set_shape_store_modified_flag): New test
5213            to check whether SetShapeStore sets the modified flag
5214            (SetShapeStoreTests.test_set_shape_store_different_field_name)
5215            (SetShapeStoreTests.test_set_shape_store_same_field)
5216            (SetShapeStoreTests.test_set_shape_store_same_field_different_type):
5217            Add tests for the messages. This checks both the new
5218            LAYER_SHAPESTORE_REPLACED and the older LAYER_CHANGED
5219    
5220    2003-06-06  Jan-Oliver Wagner <[email protected]>
5221    
5222            * Thuban/UI/mainwindow.py: Improved and partly added help texts for
5223            the menu items.
5224    
5225    2003-06-05  Frank Koormann  <[email protected]>
5226    
5227            * Thuban/UI/identifyview.py (IdentifyView.__init__):
5228            Layout reimplemented without panel. Make life easier to fit the list
5229            in the dialog.
5230    
5231    2003-06-05  Frank Koormann  <[email protected]>
5232    
5233            * Thuban/UI/projdialog.py (ProjFrame.__init__): Fill the projchoice
5234            once on initialisation (Former implementation resulted in multiple
5235            entries for each projection).
5236            (ProjFrame.__FillAvailList): selectProj as second optional parameter,
5237            if set, select the projection found under the specified name. This
5238            overwrites any other selection estimate.
5239            Removed projchoice filling from this method.
5240            (ProjFrame._OnSave, ProjFrame._OnAddToList):
5241            Updated call of ProjFrame.__FillAvailList
5242            (LCCPanel._DoLayout): Moved parameter controls in more common order.
5243    
5244            * Resources/Projections/defaults.proj: Extended defaults representing
5245            various common European projections.
5246    
5247    2003-06-05  Frank Koormann  <[email protected]>
5248    
5249            * Thuban/UI/identifyview.py (IdentifyView.__init__):
5250            Use ListCtrl instead of GridCtrl
5251    
5252            * Thuban/Model/resource.py:
5253            Guess location of .thuban directory from tempdir parent directory.
5254    
5255            * Thuban/UI/application.py (ThubanApplication.read_startup_files):
5256            Guess location of .thuban directory from tempdir parent directory.
5257    
5258    2003-06-04  Bernhard Herzog  <[email protected]>
5259    
5260            Do not cache the values returned by the tree widget's
5261            GetFirstChild and GetNextChild methods because it led to lots of
5262            segfaults. The new way requires more brute force but is more
5263            reliable.
5264    
5265            * Thuban/UI/legend.py (LegendTree.__init__): Remove instance
5266            variable layer2id
5267            (LegendTree.find_layer): New method to do with brute force what
5268            layer2id tried to accomplish
5269            (LegendTree._OnMsgLayerChanged)
5270            (LegendTree._OnMsgLayerTitleChanged, LegendTree.__ShowHideLayer):
5271            Use find_layer instead of layer2id
5272            (LegendTree.__RemoveLayer, LegendTree.__AddLayer): No need to
5273            update layer2id anymore
5274            (LegendTree._OnMsgMapLayersRemoved)
5275            (LegendTree._OnMsgMapLayersAdded): Get by without layer2id.
5276    
5277    2003-06-03  Thomas Koester  <[email protected]>
5278    
5279            * Thuban/Model/classgen.py (GenQuantiles0): New function.
5280    
5281    2003-06-02  Bernhard Herzog  <[email protected]>
5282    
5283            * Thuban/UI/mainwindow.py (layer_rename command, table_rename command):
5284            New commands.
5285            (main_menu): Add the new commands.
5286            (MainWindow.TableRename): New. Implementation of the table_rename
5287            command.
5288            (MainWindow.RenameLayer): New. Implementation of the layer_rename
5289            command.
5290    
5291            * Thuban/Model/session.py (Session.AddTable): call self.changed to
5292            set the modified flag
5293    
5294            * test/test_session.py (TestSessionSimple.test_add_table): Test
5295            whether the modified flag is set properly
5296    
5297            * Thuban/Model/base.py (TitledObject.SetTitle): Call changed
5298            instead of issue so that the modified flags get updated.
5299    
5300            * test/test_base.py (SomeTitledObject): Derive from Modifiable
5301            instead of Publisher to reflect reality better and to accomodate
5302            the fact that SetTitle now calls changed instead of issue
5303    
5304    2003-06-02  Bernhard Herzog  <[email protected]>
5305    
5306            * Thuban/UI/classgen.py (GenQuantilesPanel.GetList): Resource
5307            acquisition has to happen before the try in a try-finally.
5308    
5309    2003-06-02  Bernhard Herzog  <[email protected]>
5310    
5311            * Thuban/UI/legend.py (LegendTree._OnMsgMapLayersRemoved): It's
5312            possible that a layer is removed that is not currently selected in
5313            the legend so don't check for this.
5314    
5315    2003-05-30  Bernhard Herzog  <[email protected]>
5316    
5317            * Thuban/Model/layer.py (Layer.Destroy): Set all instance
5318            variables to None that have direct or indirect references to
5319            shapefiles or dbf files to make sure that they do go away and the
5320            files are closed.
5321    
5322    2003-05-30  Bernhard Herzog  <[email protected]>
5323    
5324            * Thuban/UI/legend.py (LegendTree.GetRootItem): Reset
5325            availImgListIndices when a new image list is created
5326            
5327    2003-05-30  Bernhard Herzog  <[email protected]>
5328    
5329            * Thuban/UI/legend.py (LegendTree.__init__): New instance variable
5330            changing_selection to indicate whether the LegendTree code itself
5331            is currently changing the selection
5332            (LegendTree.normalize_selection): New method to normalize the
5333            selection by selecting the layer item even if the user clicked on
5334            the classification.
5335            (LegendTree._OnSelChanged): normalize the selection. This works
5336            around a bug in wx which doesn't keep track of the selection
5337            properly when subtrees are deleted.
5338    
5339    2003-05-30  Bernhard Herzog  <[email protected]>
5340    
5341            * Thuban/UI/view.py (MapCanvas.set_view_transform): Limit the
5342            maximum and minimum scale factors.
5343    
5344            * test/test_classgen.py (ClassGenTest.test): Update to reflect the
5345            changes in classgen.py
5346    
5347    2003-05-30  Jonathan Coles   <[email protected]>
5348    
5349            * Thuban/Model/classgen.py: Remove ClassGenerator class but make
5350            all the methods functions. Fixes RTBug #1903.
5351    
5352            * Thuban/Model/map.py (Map.TopLayer, Map.BottomLayer): Renamed
5353            to MoveLayerToTop and MoveLayerToBottom respectively. Fixes
5354            RTBug #1907.
5355    
5356            * Thuban/UI/classgen.py: Use classgen functions that were part
5357            of the ClassGenerator class. Put try/finally blocks around
5358            code that uses wxBeginBusyCursor()/wxEndBusyCursor(). Fixes
5359            RTBug #1904.
5360    
5361            * Thuban/UI/classifier.py: Remove unused import of ClassGenerator.
5362    
5363            * Thuban/UI/legend.py: The legend was cleared and repopulated any
5364            time something changed which caused some state to be lost such
5365            as which children were expanded or collapsed. Fixes RTBug #1901.
5366            (LegendTree._OnMsgMapLayersAdded): Add only new layers.
5367            (LegendTree.__OnMsgMapLayersRemoved): Remove layers that exist in
5368            the legend but not in the map.
5369            (LegendTree.__FillTree): Move main functionality out into smaller
5370            methods that can be used by other methods.
5371            (LegendTree.__FillTreeLayer): Reuse old slots in the image list
5372            if they are available.
5373            (LegendTree.DeleteAllItems): Renamed from __DeleteAllItems so
5374            that we override the wxTreeCtrl method. Iterate over children
5375            and call __RemoveLayer.
5376            (LegendTree.__AddLayer): New. Add a new layer to the legend.
5377            (LegendTree.__RemoveLayer): Remove a layer from the legend.
5378            (LegendTree.DeleteChildren): New, overrides wxTreeCtrl method.
5379            Should only be called with the id of a layer branch.
5380            (LegendTree.GetRootItem): New, overrides wxTreeCtrl method.
5381            Returns the root item or creates one if necessary.
5382    
5383            * Thuban/UI/renderer.py (MapRenderer.draw_raster_layer): Call
5384            ProjectRasterFile with tuple arguments instead of strings.
5385    
5386            * Thuban/UI/tableview.py (QueryTableFrame.OnQuery): Wrap code
5387            with try/finally. Fixes RTBug #1904.
5388    
5389            * Thuban/UI/view.py (MapCanvas.OnPaint): Wrap code
5390            with try/finally. Fixes RTBug #1904.
5391            (MapCanvas.FitSelectedToWindow): If a single point is selected
5392            simply center it on the display. Fixes RTBug #1849.
5393    
5394            * extensions/thuban/gdalwarp.cpp: Removed code that allowed gdalwarp
5395            to be compiled as a standalone app. Now the code can only be
5396            called from Python which simplifies the parameter passing.
5397            (ProjectRasterFile): Handle Python arguments. Remove code that
5398            checks for a destination dataset. Add more clean up code.
5399    
5400            * test/test_map.py (TestMapWithContents.test_raise_layer_top,
5401            TestMapWithContents.test_lower_layer_bottom):
5402            Test Map.MoveLayerToTop() and Map.MoveLayerToBottom() respectively.
5403            Fixes RTBug #1907.
5404    
5405            * Thuban/UI/mainwindow.py (MainWindow.ToggleLegend): Apply a full
5406            extent to the map when the legend is toggled. Fixes RTBug #1881.
5407    
5408    2003-05-29  Jan-Oliver Wagner <[email protected]>
5409    
5410            * Thuban/UI/tableview.py (LayerTableFrame.OnClose): Bug-fix: Now
5411            unsubscribes all that is subcribed in __init__.
5412    
5413    2003-05-28  Bernhard Herzog  <[email protected]>
5414    
5415            * Thuban/UI/mainwindow.py (MainWindow.DuplicateLayer)
5416            (MainWindow.CanDuplicateLayer): New methods to implement the
5417            Layer/Duplicate command.
5418            (layer_duplicate command): New.
5419            (main_menu): Add layer_duplicate to the Layer menu.
5420    
5421    2003-05-28  Bernhard Herzog  <[email protected]>
5422    
5423            * Thuban/UI/tableview.py (NullRenderer.Draw): New. Our own
5424            renderer so that NULL/None values get displayed differently (by a
5425            gray rectangle).
5426            (TableGrid.__init__): Override the default renderers
5427    
5428    2003-05-28  Bernhard Herzog  <[email protected]>
5429    
5430            * Thuban/Model/layer.py (Layer.SetShapeStore): Set the
5431            classification to "None" if the type of the field has changed.
5432    
5433            * test/test_layer.py (SetShapeStoreTests): New. Class with a few
5434            test for the Layer.SetShapeStore method
5435    
5436    2003-05-28  Jan-Oliver Wagner <[email protected]>
5437    
5438            * Thuban/Model/layer.py (Layer.TreeInfo): Fixed a bug (a layer
5439            does not necessarily have a filename).
5440    
5441    2003-05-28  Jan-Oliver Wagner <[email protected]>
5442    
5443            * Thuban/UI/mainwindow.py (MainWindow.TableClose, MainWindow.TableShow):
5444            sort the selection list for the dialog.
5445    
5446    2003-05-28  Frank Koormann  <[email protected]>
5447    
5448            * extensions/thuban/wxproj.cpp
5449            (project_point): Removed cast to int for projected point coordinates.
5450            (shape_centroid): Return last point if all polygon vertices fall
5451            to one point.
5452    
5453    2003-05-28  Bernhard Herzog  <[email protected]>
5454    
5455            * Thuban/UI/mainwindow.py (_can_unjoin): Add doc-string and cope
5456            with layers that don't have shapestores, i.e. raster layers.
5457    
5458    2003-05-28  Bernhard Herzog  <[email protected]>
5459    
5460            * Thuban/Model/table.py (DBFTable.__init__): Omit the extension
5461            when determining the title from the filename.
5462    
5463            * test/test_dbf_table.py (TestDBFTable.test_title): Update to
5464            reflect changes in the way the title is derived from the filename
5465    
5466    2003-05-28  Frank Koormann  <[email protected]>
5467    
5468            * Thuban/UI/mainwindow.py (MainWindow.TableShow):
5469            Added wxDEFAULT_DIALOG_STYLE to show table dialog styles.
5470    
5471    2003-05-27  Bernhard Herzog  <[email protected]>
5472    
5473            * Thuban/UI/mainwindow.py (MainWindow.delegated_messages): Also
5474            delegate SelectedLayer.
5475            (MainWindow.LayerUnjoinTable): Implement.
5476            (_can_unjoin): New. Helper function for the sensitivity of the
5477            layer/unjoin command.
5478    
5479            * Thuban/Model/data.py (ShapefileStore.OrigShapeStore)
5480            (DerivedShapeStore.OrigShapeStore): New. Return the original
5481            shapestore. Used to figure out how to unjoin.
5482            (DerivedShapeStore.Shapefile): Fix a typo.
5483    
5484    2003-05-27  Bernhard Herzog  <[email protected]>
5485    
5486            * Thuban/UI/join.py (JoinDialog): Extend to handle layer joins as
5487            well
5488            (JoinDialog.__init__): Use the layer parameter and only build the
5489            left choice when a layer is given
5490            (JoinDialog.OnJoin): Handle layer joins as well
5491            (JoinDialog.OnLeftTable, JoinDialog.OnRightTable): Handle the case
5492            that the user selects the "Select..." item. The sensitivitly
5493            updating is now in update_sensitivity
5494            (JoinDialog.y): New method to refactor the sensitivity update of
5495            the join button into its own method.
5496    
5497            * Thuban/UI/mainwindow.py (MainWindow.LayerJoinTable): Implement.
5498    
5499    2003-05-27  Bernhard Herzog  <[email protected]>
5500    
5501            * Thuban/UI/mainwindow.py (table_close command): Make it sensitive
5502            iff there are unreferenced tables in the session
5503    
5504    2003-05-27  Bernhard Herzog  <[email protected]>
5505    
5506            * Thuban/Model/messages.py (TABLE_REMOVED): New message.
5507    
5508            * Thuban/Model/session.py (Session.UnreferencedTables): New method
5509            to return tables that are not referenced by other tables or shape
5510            stores and can be removed.
5511            (Session.RemoveTable): Issue a TABLE_REMOVED message after
5512            removing the table
5513    
5514            * Thuban/UI/mainwindow.py: Remove unused imports
5515            (MainWindow.TableClose): Implement.
5516    
5517            * Thuban/UI/tableview.py (TableFrame.__init__): Subscribe to some
5518            messages so that the frame will be automatically closed when a new
5519            session is opened or the table is removed.
5520            (TableFrame.OnClose): Unsubscribe the Subscriptions made in
5521            __init__
5522            (TableFrame.close_on_session_replaced)
5523            (TableFrame.close_on_table_removed): New. Subscribers that close
5524            the window
5525    
5526            * test/test_session.py (TestSessionMessages.test_remove_table)
5527            (TestSessionSimple.test_remove_table): Move the test to
5528            TestSessionSimple and add test for the TABLE_REMOVED message
5529            (TestSessionBase.setUp): Also subscribe to TABLE_REMOVED
5530            (TestSessionSimple.test_unreferenced_tables) New. Test for the
5531            UnreferencedTables method.
5532            (UnreferencedTablesTests): New. Class with some more sophisticated
5533            tests for UnreferencedTables.
5534    
5535    2003-05-27  Frank Koormann  <[email protected]>
5536    
5537            * Thuban/UI/tableview.py (QueryTableFrame.__init__): The "_S_election"
5538            display has some unwanted side effects. Removed again.
5539    
5540    2003-05-27  Frank Koormann  <[email protected]>
5541    
5542            * Resources/Bitmaps/legend_icon_layer.xpm: New, icon for legend.
5543    
5544            * Thuban/UI/legend.py (LegendTree.__FillTree): Use "legend_icon_layer"
5545    
5546    2003-05-27  Jan-Oliver Wagner <[email protected]>
5547    
5548            * test/test_menu.py (MenuTest.test): Added test for
5549            Menu.RemoveItem().
5550    
5551            * Thuban/UI/menu.py (Menu.RemoveItem): New. Remove an item from
5552            the menu.
5553    
5554    2003-05-27  Frank Koormann  <[email protected]>
5555            
5556            Nonmodal dialogs without parent (i.e. they can fall behind the main
5557            window)
5558    
5559            * Thuban/UI/mainwindow.py (MainWindow.OnClose): Explicitly destroy
5560            all dialogs in the dialogs dictionary and the canvas.
5561    
5562            * Thuban/UI/dialogs.py (NonModalNonParentDialog): New class, without
5563            parent, i.e. can fall behind other windows.
5564            (NonModalDialog.OnClose): Check is dialog is in mainwindow.dialog
5565            dictionary before removing it.
5566    
5567            * Thuban/UI/classifier.py: Dialog derived from NonModalNonParentDialog
5568    
5569            * Thuban/UI/projdialog.py: Dialog derived from NonModalNonParentDialog
5570            * Thuban/UI/tableview.py: Dialog derived from NonModalNonParentDialog
5571            * Thuban/UI/tree.py: Dialog derived from NonModalNonParentDialog
5572    
5573    2003-05-27  Bernhard Herzog  <[email protected]>
5574    
5575            * Thuban/UI/mainwindow.py (MainWindow.ShowTableView): New. Open a
5576            tableview dialog
5577            (MainWindow.TableShow): Use ShowTableView to open the dialogs.
5578            Also, don't use the table's titles as the dialog names. The titles
5579            aren't guaranteed to be unique.
5580            (MainWindow.TableOpen): Open a table view dialog after opening the
5581            table
5582    
5583    2003-05-27  Bernhard Herzog  <[email protected]>
5584    
5585            * Thuban/UI/mainwindow.py: Remove the Table/Hide menu item. Its
5586            effect can be achieved by simply closing the window showing the
5587            table.
5588            (MainWindow.TableHide): Removed.
5589            (main_menu): Removed "table_hide"
5590    
5591    2003-05-27  Frank Koormann  <[email protected]>
5592    
5593            Fix legend tree display problems under Win32
5594    
5595            * Thuban/UI/legend.py:  BMP_SIZE_W = 15
5596            (LegendTree.__FillTree): Display "legend_icon_map.xpm" with layer title.
5597            (LegendTree.__FillTreeLayer): Explicitely set SelectedImage.
5598    
5599            * Resources/Bitmaps/legend_icon_map.xpm: New icon for legend.
5600    
5601    2003-05-27  Jan-Oliver Wagner <[email protected]>
5602    
5603            * Thuban/UI/menu.py (Menu.InsertSeparator): Additional optional parameter
5604            'after' now allows to insert separators almost anywhere in the menu.
5605    
5606    2003-05-27  Frank Koormann  <[email protected]>
5607    
5608            * Thuban/UI/tableview.py (QueryTableFrame.__init__): Underline the
5609            "S" of selection box label to hint on hot key (Alt-S). Works under
5610            Win32 but is ignored under GTK.
5611    
5612    2003-05-26  Frank Koormann  <[email protected]>
5613    
5614            * Thuban/UI/projdialog.py (ProjFrame.__do_layout, ProjPanel._DoLayout):
5615            Center Choices.
5616    
5617    2003-05-26  Bernhard Herzog  <[email protected]>
5618    
5619            Remove the Precision methods again. They're too DBF specific to be
5620            part of the table interface and they're only used in table_to_dbf
5621            anyway.
5622            
5623            * Thuban/Model/transientdb.py (TransientTableBase.Width):Use a
5624            fixed precision of 12 for doubles.
5625            (TransientTableBase.Precision): Removed
5626            (AutoTransientTable.Width): Delegate to self.table.
5627    
5628            * Thuban/Model/table.py (DBFTable.Precision)
5629            (MemoryTable.Precision): Removed.
5630            (MemoryTable.Width): Use a fixed precision of 12 for doubles.
5631            (table_to_dbf): Use a fixed precision of 12 for floats unless the
5632            column object specifies something else.
5633    
5634            * test/test_dbf_table.py (TestTableToDBF.test_table_to_dbf): New.
5635            test for table_to_dbf
5636    
5637    2003-05-26  Bernhard Herzog  <[email protected]>
5638    
5639            * test/test_transientdb.py
5640            (TestTransientTable.run_iceland_political_tests): Fix a comment.
5641    
5642    2003-05-26  Bernhard Herzog  <[email protected]>
5643    
5644            * Thuban/UI/mainwindow.py (MainWindow.TableOpen): Real
5645            implementation. Mark parts of the file format strings for
5646            localization.
5647    
5648            * Thuban/Model/session.py (Session.OpenTableFile): New. Open a dbf
5649            file and add the table to the tables managed by the session
5650    
5651            * test/test_session.py (TestSessionSimple.test_open_table_file):
5652            New. test case for OpenTableFile
5653    
5654    2003-05-26  Jan-Oliver Wagner <[email protected]>
5655    
5656            * Thuban/UI/controls.py, Thuban/UI/identifyview.py, Thuban/UI/join.py,
5657            Thuban/UI/labeldialog.py, Thuban/UI/mainwindow.py,
5658            Thuban/UI/proj4dialog.py, Thuban/UI/tableview.py, Thuban/UI/view.py:
5659            Replace the true/false of wxWindows by True/False of Python 2.2.1.
5660    
5661    2003-05-26  Jan-Oliver Wagner <[email protected]>
5662    
5663            * Thuban/UI/tableview.py (LayerTableFrame.__init__): If there is
5664            already a selection present, update the grid accordingly.
5665    
5666            * Thuban/UI/mainwindow.py (MainWindow.TableShow): Make the dialog
5667            resizeable and increase its initial size.
5668    
5669    2003-05-26  Frank Koormann  <[email protected]>
5670    
5671            Table export functionality
5672    
5673            * Thuban/Model/table.py (DBFTable.Width, MemoryTable.Width):
5674            Return width (in characters) for a column.
5675            (DBFTable.Precision, MemoryTable.Precision): Return decimal precision.
5676            (table_to_dbf): Write table to dbf file.
5677            (table_to_csv): Write table to csv file.
5678    
5679            * Thuban/Model/transientdb.py (TransientTableBase.Width,
5680            TransientTableBase.Precision): Return column width and precision.
5681    
5682            * Thuban/UI/tableview.py (QueryTableFrame.OnSaveAs): Call table_to_dbf
5683            or table_to_csv depending on file selection.
5684    
5685            * test/test_dbf_table.py:
5686            Test table_to_dbf (extension of former part of test).
5687    
5688            * test/test_csv_table.py:
5689            Test table_to_csv.
5690    
5691    2003-05-23  Jan-Oliver Wagner <[email protected]>
5692    
5693            * Thuban/UI/join.py (JoinDialog.OnJoin): Use _() for strings.
5694            Use QueryTableFrame instead of TableFrame.
5695    
5696            * Thuban/UI/mainwindow.py (MainWindow.LayerShowTable): Prefix the
5697            table window with 'Layer Table:' instead of 'Table:'.
5698    
5699    2003-05-23  Jan-Oliver Wagner <[email protected]>
5700    
5701            Give all tables a title via mix-in TitledObject.LayerShowTable
5702    
5703            * Thuban/Model/base.py (TitledObject.SetTitle): Call method 'issue'
5704            only if it exists.
5705    
5706            * Thuban/Model/table.py (DBFTable, MemoryTable): mix-in TitledObject
5707            and call its init-method with a default title. Remove Title() method.
5708    
5709            * Thuban/Model/transientdb.py (TransientTable, TransientJoinedTable,
5710            AutoTransientTable): mix-in TitledObject and call its init-method with
5711            a default title. Remove Title() method.
5712    
5713    2003-05-23  Bernhard Herzog  <[email protected]>
5714    
5715            * Thuban/Model/session.py (Session.AddShapeStore): Define
5716            AddShapeStore analogously to AddTable.
5717    
5718            * test/test_session.py (TestSessionSimple.test_add_shapestore):
5719            New. Test for AddShapeStore
5720    
5721    2003-05-23  Jan-Oliver Wagner <[email protected]>
5722    
5723            Introducing QueryTableFrame and a very coarse ShowTable implementation.
5724    
5725            * Thuban/UI/tableview.py (LayerTableFrame, QueryTableFrame): Split the
5726            class LayerTableFrame into two classes, LayerTableFrame and QueryTableFrame.
5727            The latter implements the selection GUI without dependency on a layer.
5728            LayerTableFrame now is derived from QueryTableFrame and connects
5729            to a layer.
5730    
5731            * Thuban/UI/mainwindow.py (MainWindow.TableShow): A very coarse
5732            implementation that still needs work.
5733    
5734            * Thuban/Model/layer.py (Layer.TreeInfo): Added filename.
5735    
5736    2003-05-22  Frank Koormann  <[email protected]>
5737    
5738            * Thuban/Model/transientdb.py (TransientJoinedTable.__init__):
5739            Added "outer_join = False" as optional parameter.
5740            (TransientJoinedTable.create): If outer join is true, perform a
5741            "LEFT OUTER JOIN" instead of "JOIN", which preserves all records of
5742            the left table. Records not matching are filled with 0 / None.
5743    
5744            * Thuban/UI/join.py (JoinDialog.__init__): Checkbox for outer join.
5745            (JoinDialog.OnJoin): Consider outer join check box.
5746    
5747    2003-05-22  Bernhard Herzog  <[email protected]>
5748    
5749            * Thuban/UI/join.py (JoinDialog.OnJoin): Use exc_info in a
5750            somewhat safer way. Storing the traceback in a local variable can
5751            lead to memory leaks
5752    
5753    2003-05-22  Bernhard Herzog  <[email protected]>
5754    
5755            * Thuban/UI/join.py (JoinDialog.OnJoin): Make sure to really call
5756            the wxMessageDialog's Destroy() method.
5757    
5758    2003-05-22  Frank Koormann  <[email protected]>
5759    
5760            * Thuban/UI/join.py (JoinDialog.__init__): Make use of
5761            TransientTable.Title()
5762    
5763    2003-05-22  Frank Koormann  <[email protected]>
5764    
5765            Join Dialog, initial version.
5766    
5767            * Thuban/UI/mainwindow.py (MainWindow.TableJoin): Removed print.
5768    
5769            * Thuban/UI/join.py (JoinDialog): Functional implementation of
5770            former framework. Renamed Table1/Table2 to LeftTable/RightTable
5771            in all occurences.
5772    
5773            * Thuban/Model/transientdb.py (TransientJoinedTable.__doc__):
5774            Typo fixed.
5775    
5776    2003-05-22  Bernhard Herzog  <[email protected]>
5777    
5778            Give the tables titles so that the GUI can display more meaningful
5779            names. For now the titles are fixed but depend on e.g. filenames
5780            or the titles of the joined tables.
5781    
5782            * Thuban/Model/transientdb.py (TransientTable.Title)
5783            (TransientJoinedTable.Title, AutoTransientTable.Title): New.
5784    
5785            * Thuban/Model/table.py (DBFTable.Title, MemoryTable.Title): New.
5786    
5787            * test/test_transientdb.py
5788            (TestTransientTable.test_auto_transient_table_title): New. Test
5789            for the Title method
5790            (TestTransientTable.test_transient_joined_table)
5791            (TestTransientTable.test_transient_table): Add test for the Title
5792            methods
5793    
5794            * test/test_memory_table.py (TestMemoryTable.test_title): New.
5795            Test for the Title method
5796    
5797            * test/test_dbf_table.py (TestDBFTable.test_title): New. Test for
5798            the Title method
5799    
5800    2003-05-22  Bernhard Herzog  <[email protected]>
5801    
5802            * test/test_layer.py (TestLayer.setUp, TestLayer.tearDown):
5803            Provide a better way to destroy the layers
5804            (TestLayer.test_base_layer, TestLayer.test_arc_layer)
5805            (TestLayer.test_point_layer, TestLayer.test_empty_layer)
5806            (TestLayer.test_polygon_layer, TestLayer.test_get_field_type): Use
5807            the new way to destroy the layers.
5808            (TestLayer.test_derived_store): New. Test for using a layer with a
5809            DerivedShapeStore
5810    
5811            * Thuban/Model/layer.py (Layer.SetShapeStore): Only set the
5812            filename if the shape store actually has one.
5813    
5814    2003-05-22  Bernhard Herzog  <[email protected]>
5815    
5816            * Thuban/Model/table.py (DBFTable.FileName): New. Accessor method
5817            for the filename
5818    
5819            * test/test_dbf_table.py (TestDBFTable.test_filename): New. Test
5820            for the FileName method
5821            (TestDBFTableWriting.test_write): Fix spelling of filename
5822    
5823    2003-05-22  Thomas Koester  <[email protected]>
5824    
5825            * Thuban/Model/range.py, test/test_range.py: Brought over new Range
5826            from SciParam that now really is immutable.
5827    
5828    2003-05-22  Frank Koormann  <[email protected]>
5829    
5830            Layer Top/Bottom placement added to legend.
5831    
5832            * Thuban/UI/legend.py
5833            (LegendPanel._OnMoveTop(), LayerPanel._OnMoveBottom): New, methods
5834            bound to tool events.
5835            (LegendTree.MoveCurrentItemTop(), LegendTree.MoveCurrentItemBottom):
5836            New, methods binding the event methods with the map methods.
5837    
5838            * Thuban/Model/map.py (Map.TopLayer(), Map.BottomLayer()): New, place
5839            layer at top/bottom of layer stack.
5840    
5841            * Resources/Bitmaps/top_layer.xpm: New button icon.
5842    
5843            * Resources/Bitmaps/bottom_layer.xpm: New button icon.
5844    
5845    2003-05-22  Bernhard Herzog  <[email protected]>
5846    
5847            * Thuban/Model/session.py (Session.RemoveTable): New method to
5848            remove tables
5849    
5850            * test/test_session.py (TestSessionSimple.test_remove_table): New.
5851            Test for RemoveTable
5852    
5853    2003-05-22  Thomas Koester  <[email protected]>
5854    
5855            * Thuban/Model/classgen.py: Added short module doc string and CVS id.
5856            (ClassGenerator.GenUniformDistribution): Use new Range __init__, too.
5857    
5858    2003-05-22  Bernhard Herzog  <[email protected]>
5859    
5860            Implement a way to discover dependencies between tables and
5861            shapestores.
5862    
5863            * Thuban/Model/transientdb.py (TransientTableBase.Dependencies)
5864            (TransientJoinedTable.Dependencies)
5865            (AutoTransientTable.SimpleQuery): New. Implement the dependencies
5866            interface
5867            (TransientJoinedTable.__init__): Keep tack of the original table
5868            objects in addition to the corresponding transient tables.
5869    
5870            * Thuban/Model/table.py (DBFTable.Dependencies)
5871            (MemoryTable.Dependencies): New. Implement the dependencies
5872            interface
5873    
5874            * Thuban/Model/data.py (ShapeTable): New. Helper class for
5875            ShapefileStore
5876            (ShapefileStore.__init__): Use ShapeTable instead of
5877            AutoTransientTable
5878            (ShapefileStore.Table, ShapefileStore.Shapefile): Add doc-strings
5879            (ShapefileStore.FileName, ShapefileStore.FileType): New. Accessor
5880            methods for filename and type
5881            (ShapefileStore.Dependencies): New. Implement the dependencies
5882            interface
5883            (DerivedShapeStore): New class to replace SimpleStore. The main
5884            difference to SimpleStore is that it depends not on a shapefile
5885            but another shapestore which expresses the dependencies a bit
5886            better
5887            (SimpleStore.__init__): Add deprecation warning.
5888    
5889            * test/test_dbf_table.py (TestDBFTable.test_dependencies): New.
5890            Test for the Dependencies method.
5891    
5892            * test/test_memory_table.py (TestMemoryTable.test_dependencies):
5893            New. Test for the Dependencies method.
5894    
5895            * test/test_transientdb.py
5896            (TestTransientTable.test_auto_transient_table_dependencies): New.
5897            Test for the Dependencies method.
5898            (TestTransientTable.test_transient_joined_table): Add test for the
5899            Dependencies method.
5900    
5901            * test/test_session.py (TestSessionSimple.setUp)
5902            (TestSessionSimple.tearDown): New. Implement a better way to
5903            destroy the sessions.
5904            (TestSessionSimple.test_initial_state)
5905            (TestSessionSimple.test_add_table): Bind session to self.session
5906            so that it's destroyed by tearDown
5907            (TestSessionSimple.test_open_shapefile): New. Test for
5908            OpenShapefile and the object it returns
5909    
5910    2003-05-22  Bernhard Herzog  <[email protected]>
5911    
5912            * Thuban/Model/session.py (Session.AddTable): New method to
5913            register tables with the session.
5914            (Session.Tables): Return the tables registered with AddTable too.
5915    
5916            * test/test_session.py (TestSessionSimple.test_add_table): New.
5917            Test case for the AddTable method
5918    
5919    2003-05-22  Frank Koormann  <[email protected]>
5920    
5921            UI polishing updates: Place main buttons (OK, Cancel, etc) in the
5922            lower right corner, center labels for selections, initialize controls
5923            in reasonable order for keyboard navigation.
5924    
5925            * Thuban/UI/projdialog.py (ProjFrame.__init__, ProjFrame.__doLayout)
5926            (ProjFrame.__DoOnProjAvail): Determine position of current projection
5927            using the wxListBox.FindString() method. Still a problem (#1886)
5928    
5929            * Thuban/UI/classifier.py
5930            (Classifier.__init__, SelectPropertiesDialog.__init__)
5931    
5932            * Thuban/UI/classgen.py (ClassGenDialog.__init__,
5933            (ClassGenDialog.__DoOnGenTypeSelect): Moved initialization of the
5934            different classification types from here to __init__.
5935            (GenUniquePanel.__init__): Set the column width of the first field
5936            in the Field ListCtrl to the full width.
5937    
5938            * Thuban/UI/tableview.py (LayerTableFrame.__init__): Rename 'Save As'
5939            Button to 'Export'. Center Buttons in Selection Box, set Focus to
5940            Grid.
5941            (LayerTableFrame.OnKeyDown()): New, bound to the grid with EVT_KEY_DOWN,
5942            changes focus to the Selection when pressing "Alt-S".
5943    
5944            * Thuban/UI/legend.py (LegendTree.__SetVisibilityStyle): Only gray out
5945            the text if not visible. The italic font sometimes exceeds the
5946            rendering area.
5947    
5948    2003-05-21  Jonathan Coles   <[email protected]>
5949    
5950            * Thuban/UI/dock.py (DockFrame): Rename references to _OnClose
5951            to OnClose so that Thuban closes correctly.
5952    
5953            * Thuban/UI/mainwindow.py (MainWindow.OnClose): Call
5954            DockFrame.OnClose, not DockFrame._OnClose.
5955    
5956    2003-05-21  Jonathan Coles   <[email protected]>
5957    
5958            * Thuban/Model/classgen.py (ClassGenerator.GenQuantiles): Remove
5959            references to 'inf' and use new Range __init__ to pass floats
5960            directly rather than converting them to strings first.
5961            Fixes RTBug #1876.
5962    
5963            * Thuban/Model/classification.py (ClassGroupRange.SetRange):
5964            Use new Range ___init__ to pass floats.
5965    
5966            * Thuban/Model/layer.py (RasterLayer.__init__): Test if the
5967            filename is a valid image file. Throw IOError otherwise.
5968    
5969            * Thuban/Model/range.py: Brought over new Range from SciParam that
5970            is immutable and has an __init__ which can accept floats.
5971    
5972            * Thuban/UI/mainwindow.py (MainWindow.AddLayer): Move OpenShapefile
5973            into try block. AddLayer doesn't throw any exceptions anymore.
5974            (MainWindow.AddRasterLayer): Move constructor of RasterLayer into
5975            try block.
5976    
5977            * Thuban/UI/projdialog.py (GeoPanel.__init__): Put Degrees as
5978            the first item in choices. Fixes RTBug #1882.
5979    
5980            * Thuban/UI/renderer.py (MapRenderer.render_map): Check if scale
5981            has gone to 0 which is a serious problem. abort.
5982            (MapRenderer.draw_raster_layer): Catch IOError seperately and
5983            print the error from GDAL.
5984    
5985            * Thuban/UI/tableview.py (TableGrid.__init__): Call
5986            ToggleEventListeners to turn on listening.
5987            (TableGrid.ToggleEventListeners): New. Turns event listening on
5988            and off so as to prevent excessive messages.
5989            (LayerTableFrame.OnQuery): Use TableGrid.ToggleEventListeners
5990            to suppress excessive messages when selecting many rows.
5991            Fixes RTBug #1880.
5992    
5993            * Thuban/UI/view.py: Added checks against if scale == 0. This
5994            is a serious problem that can occur when an image without
5995            geo data is loading and causes the map projection bounds to
5996            go to infinity. Right now, the solution is to simply try
5997            to recover.
5998    
5999            * extensions/thuban/cpl_mfile.cpp (MFILEClose): Make sure
6000            to set the MFILEReceiver attributes even if the data is NULL.
6001    
6002            * extensions/thuban/gdalwarp.cpp: Improved the error handling
6003            and passed GDAL messages back up to the Python layer. Also
6004            tried to fix some memory leaks that were present in the original
6005            utility but didn't matter because the program aborted.
6006    
6007            * test/test_range.py: Copied over tests from SciParam. Removed
6008            tests against importing. Fixes RTBug #1867.
6009    
6010    2003-05-21  Bernhard Herzog  <[email protected]>
6011    
6012            * test/test_load.py: Remove unused imports and restructure the
6013            test code
6014            (LoadSessionTest): Split into one class for each test and turn
6015            LoadSessionTest itself into the base class for all such session
6016            tests.
6017            (ClassificationTest): New base class for load tests that test
6018            classifications
6019            (TestSingleLayer, TestLayerVisibility, TestClassification)
6020            (TestLabels, TestLayerProjection, TestRasterLayer): New classes
6021            for the individual tests
6022    
6023            * test/support.py (FileLoadTestCase.filename): New base class for
6024            file loading tests
6025    
6026    2003-05-21  Jan-Oliver Wagner <[email protected]>
6027    
6028            * Resources/Projections/defaults.proj: Renamed 'Universal Transverse
6029            Mercator' to 'UTM Zone 32' as a more convenient example.
6030            Added 'Gauss Krueger Zone 6'.
6031    
6032            * Data/iceland_sample_raster.thuban: political polygon now
6033            filled transparent to have the raster image visible at once.
6034    
6035    2003-05-21  Frank Koormann  <[email protected]>
6036    
6037            * Thuban/UI/mainwindow.py (MainWindow): Renamed _OnClose() back to
6038            OnClose() to keep in sync with extensions. Internally Thuban
6039            still uses "underscored" names.
6040    
6041    2003-05-20  Jonathan Coles   <[email protected]>
6042    
6043            This puts back Raster layer support. These layers support projections
6044            through the GDAL library. Currently, the CVS version is being used.
6045            There are no Debian packages available although this may change soon.
6046            A GDAL driver was extended to support writing to memory rather to
6047            files.
6048    
6049            There is still some work that needs to be done, such as some error
6050            handling when loading invalid images or when there is a problem
6051            projecting the image. This putback simply checks in the majority
6052            of the work.
6053    
6054            * setup.py: Add gdalwarp library extension.
6055    
6056            * Thuban/Model/layer.py (BaseLayer.HasClassification): New.
6057            Defaults to False, but can be overridden by subclasses if they
6058            support classification.
6059            (RasterLayer): New. Defines a new layer that represents an
6060            image.
6061    
6062            * Thuban/Model/load.py (SessionLoader.__init__): Add rasterlayer
6063            tag handler.
6064            (SessionLoader.start_layer): Encode the filename.
6065            (SessionLoader.start_rasterlayer, SessionLoader.end_rasterlayer):
6066            New. Supports reading a rasterlayer tag.
6067    
6068            * Thuban/Model/map.py (Map.BoundingBox): Fix typo in comment.
6069    
6070            * Thuban/Model/save.py (XMLWriter.encode): Don't assume that we
6071            get a string in Latin1. If we get such as string convert it to
6072            unicode first, otherwise leave if alone before encoding.
6073            (SessionSaver.write_layer): Add support for writing both Layers
6074            and RasterLayers.
6075    
6076            * Thuban/Model/transientdb.py (AutoTransientTable.SimpleQuery):
6077            The right argument may not be a string, it could also be a Column.
6078    
6079            * Thuban/UI/application.py (ThubanApplication.CreateMainWindow):
6080            Make initial window size 600x400. Fixes RTBug #1872.
6081    
6082            * Thuban/UI/classifier.py (Classifier.__init__): Rearrange how
6083            the dialog is constructed so that we can support layers that
6084            do not have classifications.
6085            (Classifier._OnTry): Only build a classification if the layer
6086            supports one.
6087    
6088            * Thuban/UI/legend.py: Change all checks that a layer is an
6089            instance of Layer into checks against BaseLayer.
6090            (LegendTree.__FillTreeLayer): Only add children to a branch if
6091            the layer supports classification.
6092    
6093            * Thuban/UI/mainwindow.py (MainWindow.NewSession,
6094            MainWindow.OpenSession): Don't proceed with an action if the
6095            user chooses Cancel when they are asked to save changes.
6096            (MainWindow.AddRasterLayer): New. Open a dialog to allow the
6097            user to select an image file. Create a new RasterLayer and add
6098            it to the map.
6099    
6100            * Thuban/UI/renderer.py (MapRenderer.render_map): Add support
6101            for rendering RasterLayer layers.
6102            (MapRenderer.draw_raster_layer): Actually method that calls
6103            the GDALWarp python wrapper and constructs an image from the
6104            data returned.
6105    
6106            * Thuban/UI/tableview.py (LayerTableFrame.__init__): Change the
6107            Choices symbols to match those used in the table query method.
6108            Replace deprecated method calls on table with new method names.
6109    
6110            * Thuban/UI/view.py (MapCanvas.set_view_transform): Try to limit
6111            how small the scale can get. This still needs more testing.
6112    
6113            * extensions/thuban/bmpdataset.cpp: New, but copied from GDAL.
6114            Provides a driver to output in .bmp format.
6115    
6116            * extensions/thuban/cpl_mfile.cpp, extensions/thuban/cpl_mfile.h:
6117            New. Provides IO routines which write to memory, rather than a file.
6118    
6119            * extensions/thuban/gdalwarp.cpp: New, but basically a direct copy
6120            of the gdalwarp utility provided in GDAL. Added function calls
6121            that can be accessed from python.
6122    
6123            * Data/iceland_sample_raster.thuban: New. Sample file that uses
6124            a raster layer.
6125    
6126            * Data/iceland/island.tfw, Data/iceland/island.tif: New. Raster
6127            layer image data.
6128    
6129            * Doc/thuban.dtd: Added rasterlayer attribute definition.
6130    
6131            * test/test_layer.py, test/test_load.py, test/test_save.py: Added
6132            tests associated with the raster layer code.
6133    
6134            * test/test_transientdb.py
6135            (TestTransientTable.test_auto_transient_table_query): Added a test
6136            for using a Column object as the "right" parameter to a query.
6137    
6138    2003-05-19  Frank Koormann  <[email protected]>
6139    
6140            * Thuban/version.py (get_changelog_date):
6141            Catch exceptions if ChangeLog does not exist.
6142    
6143            * Thuban/UI/view.py (MapCanvas.Export): Bugfix
6144    
6145  2003-05-19  Frank Koormann  <[email protected]>  2003-05-19  Frank Koormann  <[email protected]>
6146    
6147          Extended version information for Thuban          Extended version information for Thuban

Legend:
Removed from v.924  
changed lines
  Added in v.2211

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26