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

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

Parent Directory Parent Directory | Revision Log Revision Log


Revision 2242 - (hide annotations)
Tue Jun 15 09:22:01 2004 UTC (20 years, 8 months ago) by jschuengel
Original Path: trunk/thuban/ChangeLog
File size: 377029 byte(s)
added README for UMN MapServer Extension

1 jschuengel 2242 2004-06-10 Jan Schüngel <[email protected]>
2    
3     * Extensions/umn_mapserver/README: New. Install instruction.
4    
5 bernhard 2240 2004-06-14 Bernhard Reiter <[email protected]>
6    
7     * libraries/thuban/cpl_mfile.h: Added copyright header.
8    
9     * libraries/thuban/ cpl_mfile.cpp, cpl_mfile.h: Added non-protecting
10     Free Software License so that it is most useful with gdalwarp
11     and bmpdataset.
12    
13 bh 2239 2004-06-14 Bernhard Herzog <[email protected]>
14    
15     * Thuban/UI/multiplechoicedialog.py (__version__): Add missing
16     import of wxPython.wx itself (as opposed to the contents of
17     wxPython.wx). For some reason wxPython.wx is available as
18     wxPython.wx.wx in at least some 2.4 releases. Fixes RT#2482
19     wrt. wxPython 2.4.
20    
21 jschuengel 2238 2004-06-10 Jan Schüngel <[email protected]>
22    
23     Initial version of new extension "umn_mapserver". This extension aims
24     to manage configuration for the UMN MapServer application. This
25     inital version just imports the .map-files and displays all, Thuban is
26     capable of.
27    
28     * Extensions/umn_mapserver, Extensions/umn_mapserver/test: New.
29    
30     * Extensions/umn_mapserver/test/README: New. Describes how to run the
31     tests.
32    
33     * Extensions/umn_mapserver/test/test.map: New. This is a test
34     .map-file for automated tests of the umn_mapserver extension of
35     Thuban.
36    
37     * Extensions/umn_mapserver/test/test_mapserver.py: New. Tests for
38     UMN Mapserver classes.
39    
40     * Extensions/umn_mapserver/__init__.py: New. Init to make this
41     directory a package.
42    
43     * Extensions/umn_mapserver/mapfile.py: New. Classes to represent
44     '.map'-file objects.
45    
46     * Extensions/umn_mapserver/mf_import.py: New. This module extends
47     Thuban with the possibility to handle UMN MapServer mapfiles.
48    
49 bh 2230 2004-06-03 Bernhard Herzog <[email protected]>
50    
51     * Thuban/Model/layer.py (Layer.TreeInfo): Convert the bounding box
52     to a tuple before using it as arguments to the % operator. This
53     fixes the formatting issue filed in RT#2239 on 2004-01-13 and
54     reported today on thuban-list by Jan Schüngel
55    
56     * test/test_layer.py (TestLayerModification.setUp): Save the
57     filename as an instance variable so we can refer to it in tests
58     (TestLayerModification.test_tree_info): Uncomment this method
59     again and make it work. This tests for the formatting issue
60     filed in RT#2239 on 2004-01-13
61    
62 bh 2224 2004-05-28 Bernhard Herzog <[email protected]>
63    
64     * Thuban/UI/baserenderer.py: Fix some typos.
65    
66 jan 2217 2004-05-18 Jan-Oliver Wagner <[email protected]>
67    
68     * Extensions/gns2shp/gns2shp.py (gns2shp): Fixed a bug
69     by increasing a field size.
70    
71 bh 2213 2004-05-17 Bernhard Herzog <[email protected]>
72    
73     Update to newest shapelib and get rid of Thuban specific
74     extensions, i.e. use the new DBFUpdateHeader instead of our
75     DBFCommit kludge
76    
77     * libraries/shapelib/shpopen.c: Update to version from current
78     shapelib CVS.
79    
80     * libraries/shapelib/shapefil.h: Update to version from current
81     shapelib CVS.
82    
83     * libraries/shapelib/dbfopen.c: Update to version from current
84     shapelib CVS.
85     (DBFCommit): Effectively removed since shapelib itself has
86     DBFUpdateHeader now which is better for what DBFCommit wanted to
87     achieve.
88     We're now using an unmodified version of dbfopen.
89    
90     * setup.py (extensions): Add the HAVE_UPDATE_HEADER macro with
91     value '1' to the Lib.dbflibc extension. This simply reflects the
92     shapelib and pyshapelib updates
93    
94 jan 2211 2004-05-16 Jan-Oliver Wagner <[email protected]>
95    
96     Finished introduction of Menu.FindOrInsertMenu.
97    
98     * Extensions/drawshape/drawshape.py: Add the command
99     to the experimental menu additionally to the toolbar.
100    
101     * Extensions/svgexport/svgsaver.py: Use FindOrInsertMenu() instead of
102     finding menu on its own.
103    
104     * Doc/manual/thuban-manual.xml: updated sample file
105     to use FindOrInsertMenu().
106    
107     * Examples/simple_extensions/hello_world.py: Use FindOrInsertMenu()
108     instead of finding menu on its own.
109    
110 jan 2206 2004-05-11 Jan-Oliver Wagner <[email protected]>
111    
112     * test/test_menu.py (MenuTest.test): Added testing
113     of method Menu.FindOrInsertMenu.
114    
115 jan 2204 2004-05-10 Jan-Oliver Wagner <[email protected]>
116    
117     Introduce and use Menu.FindOrInsertMenu.
118    
119     * Thuban/UI/menu.py (Menu.FindOrInsertMenu): New. Find a
120     given menu or, if not found, insert it.
121    
122     * Extensions/bboxdump/bboxdump.py, /Extensions/gns2shp/gns2shp.py,
123     /Extensions/importAPR/importAPR.py, Extensions/profiling/profiling.py,
124     /Extensions/wms/wms.py: Use FindOrInsertMenu() instead of finding
125     menu on its own.
126    
127 jan 2201 2004-05-06 Jan-Oliver Wagner <[email protected]>
128    
129     Introduce a abstract ColorDialog class and remove
130     and outdated file.
131    
132     * Thuban/UI/proj4dialog.py: Removed. It is has been
133     replaced by projdialog for quite a while and is not used
134     anymore.
135    
136     * Thuban/UI/colordialog.py: New. Abstraction for color selection
137     dialog(s).
138    
139     * Thuban/UI/classifier.py (SelectPropertiesDialog.__GetColor):
140     Now calls the abstract ColorDialog instead of wxColourDialog.
141     This also removed the dependency to Color class conversion
142     from this function.
143    
144 frank 2197 2004-05-04 Frank Koormann <[email protected]>
145    
146     * Extensions/bboxdump/__init__.py: Fixed string left over from
147     copying.
148    
149     * Extensions/bboxdump/bboxdump.py (bboxdump):
150     Use layer.ShapeStore().AllShapes() to loop over shapes instead of
151     xrange(layer.NumShapes()). Compile the bboxmessage from a list
152     of formatted outputs (string.join) instead of appending to the
153     message. Two progress bar dialogs to report progress on the sometimes
154     lenghty processing.
155    
156 frank 2196 2004-04-22 Frank Koormann <[email protected]>
157    
158     New Extension to dump bounding boxes of all shapes of the selected
159     layer. An optional column can be specified to group the objects,
160     in this case the bounding box is a union of the separate boxes.
161     Dump can be displayed in a ScrolledMessageDialog or written to file.
162     The Extension is simply a combination of available and well tested
163     Thuban functionality.
164    
165     * Extensions/bboxdump/__init__.py: New: Init to make this
166     directory a package.
167    
168     * Extensions/bboxdump/bboxdump.py: New: Dump bounding boxes of
169     all shapes of the selected layer.
170    
171 jan 2192 2004-04-22 Jan-Oliver Wagner <[email protected]>
172    
173     * Thuban/UI/classgen.py (GenUniquePanel.__init__): Fixed two
174     strings to be i18n now.
175    
176 jan 2188 2004-04-18 Jan-Oliver Wagner <[email protected]>
177    
178     Changing popup menu of legend from direct building
179     to using the Menu construction as used for the mainwindow.
180    
181     * Thuban/UI/mainwindow.py: New method commands: layer_to_top,
182     layer_to_bottom, layer_visibility
183     (MainWindow.LayerToTop): New. Put current layer to the top.
184     (MainWindow.LayerToBottom): New. Put current layer to bottom.
185     (MainWindow.HideLayer, MainWindow.ShowLayer, _has_visible_map):
186     Replace 1,0 by True, False.
187     (MainWindow.ToggleLayerVisibility): New. Toggle visibility of
188     current layer.
189     (MainWindow.LayerShowTable): Removed raising of dialog.
190     (_has_selected_layer_visible): New. Support function.
191    
192     * Thuban/UI/legend.py: ID_POP_xxx: removed.
193     (LegendPanel.__init__): Removed EVT_MENU bindings.
194     (LegendTree._OnRightClick): Replace direct creation of
195     menu via wx Classes by applying the menu definition
196     as of Menu class of menu.py.
197    
198 jan 2185 2004-04-16 Jan-Oliver Wagner <[email protected]>
199    
200     * Thuban/UI/exceptiondialog.py (ExceptionDialog.dialog_layout): Improved
201     button string to stronger clearify that Thuban will be closed when hitting
202     the button.
203    
204     * Thuban/UI/mainwindow.py (MainWindow.LayerShowTable): Added docstring.
205     Now for layers without a ShapeStore a corresponding message is given
206     to the user, that this layer has no table to show.
207    
208 joey 2182 2004-04-15 Martin Schulze <[email protected]>
209    
210     * Extensions/wms/layer.py (WMSLayer.setWMSFormat): Need to
211     recalculate the format for the internal render engine as well.
212    
213     * Extensions/wms/properties.py (wmsProperties): First start for a
214     properties dialog. It's functional for a first selection of
215     layers, but still has some weired wxWidgets/GTK problems but
216     beautification can be done later.
217    
218     * Extensions/wms/layer.py: Added more documentation
219     (WMSLayer.getFormats): New: Return list of supported image formats
220     by the WMS server
221     (WMSLayer.getLayers): New: Return the list of layer names
222     supported by the WMS server
223     (WMSLayer.getLayerTitle): New: Return the title of the named layer
224     (WMSLayer.getWMSFormat): New: Return the image format that is used
225     for WMS GetMap requests
226     (WMSLayer.setWMSFormat): New: Set the image format that is used
227     for WMS GetMap requests
228     (WMSLayer.__init__): Move away from using only one layer to using
229     a list of layers (unsorted at the moment, though).
230     (WMSLayer.getVisibleLayers): New: Return the list of names for all
231     visible layers
232     (WMSLayer.setVisibleLayers): New: Set the list of names for all
233     visible layers
234    
235     * Extensions/wms/wms.py: Moved the WMS layer into layer.py in
236     order to establish a clean structure.
237    
238     * Extensions/wms/layer.py: Moved the WMS layer into a file on its
239     own in order to establish a clean structure.
240    
241 joey 2174 2004-04-13 Martin Schulze <[email protected]>
242    
243     * Extensions/wms/parser.py (WMSCapabilitiesParser.grok): Added
244     support for oldstyle (WMS 1.0 apparently) image format
245     specification.
246    
247     * Extensions/wms/wms.py (WMSLayer.calcFormat): Reduce the list of
248     supported graphic formats back to JPEG and BMP, PNG and others are
249     too *cough* experimental... Sorry, I meant to filter this out
250     before I committed this part. This should make the WMS extension
251     run from CVS again.
252     (wms_dialog): Reset an empty URL to None so that the subsequent
253     program can depend on this, since the dialog will indeed return an
254     empty URL, causing another declaration of love by Python.
255    
256     * Extensions/wms/parser.py (WMSCapabilitiesParser.getLayerBBox):
257     Whenever a native BoundingBox request cannot be fulfilled, check
258     whether the requested SRS is EPSG:3426, in which case return the
259     LatLonBoundingBox values.
260    
261     * Extensions/wms/test/test_parser.py
262     (TestWMSCapabilitiesParser.test_LayerSRS): Added a test for
263     ignoring AUTO:* SRS.
264     (TestWMSCapabilitiesParser.test_LatLonBoundingBoxes_as_bboxes):
265     Added another test method to test whether the LatLonBoundingBox
266     values will be returned if BoundingBox values are requested with
267     SRS set to EPSG:3426.
268    
269     * Extensions/wms/parser.py (WMSCapabilitiesParser.peekLayers):
270     Added rudimentary support for non-EPSG SRS, i.e. ignore them for
271     the moment by placing them into a variable which is currently
272     unused. Also test whether the EPSG SRS is numerical as it should
273     be and add an error message if it is not.
274    
275     * Extensions/wms/test/sample.xml: Added AUTO:* SRS since they
276     appear in the real world as well. Since we cannot handle them yet
277     (OGCLib can't either), we will ignore them for the moment.
278    
279     * Extensions/wms/parser.py: Use a variable for denoting the sample
280     filename
281     (WMSCapabilitiesParser.peekLayers): Added support for error
282     messages during grok(). They will be aggregated in an array and
283     may be displayed later. We may have to add a classification
284     "Warning" and "Error" to this. That requires more experience,
285     though, since not every error may be lethal.
286    
287     * Thuban/UI/mainwindow.py (MainWindow.LayerShowTable): Raise the
288     ShowTable() dialog/frame when the user attempts to display it
289     while it has been opened before already and not closed again.
290    
291 joey 2161 2004-04-11 Martin Schulze <[email protected]>
292    
293     * Extensions/wms/infodialog.py: Adjusted the class documentation
294    
295     * Extensions/wms/wms.py (WMSLayer.__init__, WMSLayer.GetMapImg):
296     Switch to using Thuban{Begin,End}BusyCursor instead of the pure
297     wxWidgets variants.
298     (WMSLayer.__init__): The epsg_id variable is named top_srs now.
299    
300     * Extensions/wms/infodialog.py: Added an information dialog that
301     will display various information about the WMS current resource,
302     so that additional information such as the title, the abstract,
303     fees and access constraints can be displayed for the user if they
304     are documented in the WMS XML.
305    
306 joey 2156 2004-04-10 Martin Schulze <[email protected]>
307    
308     * Extensions/wms/parser.py (WMSCapabilitiesParser.grok): Adjusted
309     string handling. It's "foo".lower() and not lower(foo) without
310     lower imported from strings or something.
311    
312     * Extensions/wms/wms.py (WMSLayer): Incorporated WMSCapabilities
313     from capabilities.py and parser.py. Implement priority list for
314     supported graphics formats, take care of wbmp != bmp. PNG, TIFF
315     and GIF are supported here, but not yet by main Thuban. Hence,
316     support for them may be removed later. Special contribution to
317     usability: get wxWidgets to change the cursor when we're waiting
318     for data from the network so the user won't start to worry. This
319     causes a redrawing error/warning, though.
320    
321     * Extensions/wms/parser.py (WMSCapabilitiesParser.grok): Unlink
322     the DOM object.
323    
324     2004-04-01 Martin Schulze <[email protected]>
325    
326     * Extensions/wms/capabilities.py: Adjusted documentation
327     (WMSCapabilities.__init__): Improved documentation, fixed syntax
328     (WMSCapabilities.saveCapabilities): Only catch IOError when
329     handling files
330     (WMSCapabilities.loadCapabilities): Only catch IOError when
331     handling files
332     __main__: corrected variable naming
333     (WMSCapabilities.fetchCapabilities,loadCapabilities): Make this
334     class a specialisation of WMSCapabilitiesParser as well. Also
335     execute grok() after loading or fetching capabilities, if that
336     went well, so that subsequent calls can already access the data.
337     (WMSCapabilities.getVersion): Export the used version of the
338     GetCapabilities request, so we can use it for subsequent calls,
339     i.e. for GetMap requests.
340     (WMSCapabilities.fetchCapabilities): Added proper error handling
341     when the GetCapabilities request failed, so that the surrounding
342     program can act accordingly.
343    
344 joey 2146 2004-03-30 Martin Schulze <[email protected]>
345    
346     * Extensions/wms/parser.py (WMSCapabilitiesParser.getLayerSRS):
347     Adjusted the getLayerSRS method to return the list of SRSes
348     extracted from <SRS> elements instead of <BoundingBox> elements.
349     Added a bit of documentation as well.
350     (WMSCapabilitiesParser.checkLayerSRS): Removed integrity test
351     since it was only implemented due to a misunderstanding.
352    
353     * Extensions/wms/test/test_parser.py
354     (TestWMSCapabilitiesParser.test_LayerSRS): Adjust the tests to
355     reflect the corrected interpretation of the standard: i.e. a layer
356     does not have to define a BoundingBox for all SRSes it supports.
357     Hence the <SRS></SRS> specification is authoritative, not the list
358     of BoundingBoxes.
359     (TestWMSCapabilitiesParser.test_BoundingBoxes): Added a new test
360     to ensure None is returned for a non-existing SRS.
361     (TestWMSCapabilitiesParser.test_grok): Removed test_grok method
362     since it is not applicable anymore. Listing more SRSes in <SRS>
363     elements is valid according to the specs.
364    
365 bernhard 2140 2004-03-26 Bernhard Reiter <[email protected]>
366 joey 2146
367 bernhard 2140 * README: Nicer formatting of text. Improved descriptions.
368     Reflected wxWidgets name change.
369    
370     * Thuban/UI/about.py: Extended copyright to 2004 and added
371     information about the thuban-devel mailinglist.
372    
373 joey 2138 2004-03-24 Martin Schulze <[email protected]>
374 joey 2120
375 joey 2138 * Extensions/wms/capabilities.py: Renamed the class to contain
376     'WMS', also added a linebreak where required
377    
378     * Extensions/wms/parser.py: Finally added the XML parser for the
379     GetCapabilities response.
380    
381     * Extensions/wms/test/sample.xml: Adjusted the sample file so that
382     <SRS> elements match the <BoundingBox> elements, except for the
383     layer 'beschriftung'.
384    
385     * Extensions/wms/test/test_parser.py: Encode non-ascii strings
386     since Python uses unicode strings internally, otherwise
387     comparisons will fail. Removed tests for getLayerBBoxSRS() since
388     the SRS will be calculated anyway and this method is obsoleted by
389     getLayerSRS(). Denote SRS as strings and not as cardinal numbers.
390     Move loading the sample file into the setUp method. Added a test
391     for finding the integrity problem in the sample response.
392     Improved formatting.
393    
394     * Extensions/wms/domutils.py: Added convenience routines for
395     handling of Document Object Model (DOM) nodes.
396    
397     * Extensions/wms/test/test_domutils.py: Added a test for the
398     domutils module
399    
400     2004-03-19 Martin Schulze <[email protected]>
401    
402 joey 2120 * Extensions/wms/test/test_parser.py (TestWMSCapabilitiesParser):
403     Moved path detection and adding into a module of its own,
404     adjustpath, which exports thubandir as main Thuban directory.
405    
406     * Extensions/wms/test/test_ogclib.py (TestWMSLib): Moved path
407     detection and adding into a module of its own, adjustpath, which
408     exports thubandir as main Thuban directory. Reorganised the
409     module in order to support the SkipTest feature for Thuban test
410     cases.
411    
412     * Extensions/wms/test/adjustpath.py: Moved path detection and
413     adding into a module of its own.
414    
415 joey 2115 2004-03-18 Martin Schulze <[email protected]>
416    
417     * Extensions/wms/test/test_parser.py: Added another test for
418     checking whether the WMS XML parser (to be implemented) returns
419     the information we expect. This requires a sample WMS WML file
420     (sample.xml) which has been extracted from the frida server and
421     "improved" manually.
422    
423     * Extensions/wms/test/test_ogclib.py: Added legacy code to add the
424     main Thuban directory to the path in order to be able to import
425     random modules. Adjusted the PyOGCLib detection to reuse the
426     information gathered. Also added a note about the PYTHONPATH
427     environment variable.
428    
429     * Extensions/wms/test/test_ogclib.py: The format specification is
430     a mime-type, not a graphic format, hence image/jpeg wou ld be the
431     proper format and not JPEG. We'll also have to take care of the
432     encoding of / as %2F.
433    
434 joey 2111 2004-03-16 Martin Schulze <[email protected]>
435    
436     * Extensions/wms/test/test_ogclib.py: Added a (hopefully)
437     comprehensive test for the getMapURL method, built compare URLs
438     according to the documentation in OGC 01-068r3
439    
440     * Extensions/wms/capabilities.py (WMSCapabilities): Added the
441     class WMSCapabilities to manage capabilites, will incorporate
442     parsing the capabilities response and provide details for other
443     classes.
444    
445 bh 2105 2004-03-12 Bernhard Herzog <[email protected]>
446    
447 bh 2107 Support views in addition to normal tables in the postgis
448     shapestore
449    
450     * Thuban/Model/postgisdb.py
451     (PostGISShapeStore._fetch_table_information): Add a fallback for
452     the case where the table name is not in the geometry_columns
453     table. This is usually the case for views. Also, set
454     self.shapestore here.
455     (PostGISShapeStore.ShapeType): No need to query the database all
456     the time. The shape type is now determined in
457     _fetch_table_information
458    
459     * test/postgissupport.py (PostgreSQLServer.new_postgis_db)
460     (PostgreSQLServer.get_static_data_db, PostGISDatabase.__init__):
461     New parameter to specify views.
462     (PostGISDatabase.has_data): Also compare the views. New views
463     parameter
464     (PostGISDatabase.initdb): Create the views.
465     (PostgreSQLServer.get_default_static_data_db): Add the v_landmarks
466     view
467    
468     * test/test_postgis_db.py
469     (TestPostGISShapestorePointFromViews): New. Test a
470     PostGISShapeStore with a view
471     (TestPostGISShapestorePointOIDAsGIDColumn.setUp): Pass the name of
472     the geometry_column explicitly to test whether that works
473    
474     2004-03-12 Bernhard Herzog <[email protected]>
475    
476 bh 2105 Final step for explicit id/geometry columns: Loading and saving
477    
478     * Resources/XML/thuban-1.1.dtd: New. Derived from thuban-1.0.dtd
479     with the following changes:
480     (dbshapesource): Two new attributes id_column and geometry_column
481    
482     * Thuban/Model/save.py (SessionSaver.write): Use the new dtd
483     (SessionSaver.write_session): Use the new namespace
484     (SessionSaver.write_data_containers): Write the new dbshapesource
485     parameters
486    
487     * Thuban/Model/load.py (SessionLoader.__init__): New namespace for
488     the new file format version
489     (SessionLoader.start_dbshapesource): Handle the new db parameters
490    
491     * test/test_save.py: Update to the new dtd and namespace
492     (SaveSessionTest.test_save_postgis): Update the NonConnectionStore
493     mock object to provide a working IDColumn method.
494    
495     * test/test_load_1_0.py: New. Copy of the test_load.py before
496     today's changes but with the round-trip tests removed.
497    
498     * test/test_load_0_9.py: Update doc-string.
499    
500     * test/test_load.py: Update all .thuban files to the new dtd and
501     namespace.
502     (TestPostGISLayer.file_contents): Add the new dbshapesource
503     paramters
504    
505 bh 2100 2004-03-11 Bernhard Herzog <[email protected]>
506    
507 bh 2103 Next step for explicit id/geometry columns: User interaction
508    
509     * Thuban/UI/dbdialog.py (ChooseDBTableDialog.__init__): Rework how
510     the dialog is constructed. Add combo boxes to select id and
511     geometry column. Rename some instance variables.
512     (ChooseDBTableDialog.GetTable): Return id and geometry column
513     names
514     (ChooseDBTableDialog.OnTableSelect): New. Event handler for
515     selections in the table list
516    
517     * Thuban/UI/mainwindow.py (MainWindow.AddDBLayer): Use id_column
518     and geometry_column
519    
520     * Thuban/Model/session.py (Session.OpenDBShapeStore): Add the new
521     parameters for id_column and geometry column of PostGISShapeStore
522     here as well.
523    
524     * Thuban/Model/postgisdb.py (type_map): Add ROWID psycog type.
525     (_raw_type_map): New. Map raw PostgreSQL type ints to thuban types
526     (PostGISConnection.GeometryTables): Use a better query to
527     determine which relations in the database might be usable for
528     shapestores. Now supports views as well but is more PostgreSQL
529     specific
530     (PostGISConnection.table_columns): New. Somewhat experimental
531     method to let the db dialogs provide lists of columns to users so
532     that they can select id and geometry columns.
533     (PostGISTable.__init__): The default value of the id_column
534     parameter is now None it still means "gid" effectively, though.
535     (PostGISTable.IDColumn): New introspection method to return a
536     column object for the id column
537     (PostGISShapeStore.GeometryColumn): New introspection method to
538     return a column object for the geometry column
539    
540     * test/test_postgis_db.py
541     (TestPostGISConnection.test_gis_tables_non_empty):
542     Removed. Subsumed by the new:
543     (TestPostGISConnection.test_gis_tables_with_views_and_tables):
544     New. Tes the GeometryTables and table_columns methods with actual
545     tables and views.
546     (PointTests.test_id_column, PointTests.test_geometry_column):
547     New. tests for the new methods.
548     (TestPostGISShapestorePoint.setUp)
549     (TestPostGISShapestorePointSRID.setUp)
550     (TestPostGISShapestorePointExplicitGIDColumn.setUp): Fill the
551     instance variables needed by the new tests
552    
553     2004-03-11 Bernhard Herzog <[email protected]>
554    
555 bh 2100 * Thuban/UI/classgen.py (GenQuantilesPanel.GetList): The row
556     numbers given to ReadValue are ordinals.
557    
558     2004-03-11 Bernhard Herzog <[email protected]>
559    
560     Elimiate the requirement for PostGIS tables to have a column
561     called "gid".
562    
563     * Thuban/Model/postgisdb.py (PostGISTable.__init__): New parameter
564     id_column to specify which column to use to identify rows. Also
565     new instance variables id_column and quoted_id_column
566     (PostGISTable.RowIdToOrdinal, PostGISTable.RowOrdinalToId)
567     (PostGISTable.ReadRowAsDict, PostGISTable.ReadValue)
568     (PostGISTable.SimpleQuery): Use the id column name provided to the
569     constructor instead of "gid"
570     (PostGISShapeStore.__init__): New parameter id_column analogously
571     to PostGISTable.__init__. This parameter is simply passed through
572     to the base class constructor
573     (PostGISShapeStore._create_col_from_description): Fix typo in
574     doc-string
575     (PostGISShapeStore.Shape, PostGISShapeStore.AllShapes)
576     (PostGISShapeStore.ShapesInRegion): Use the id column name
577     provided to the constructor instead of "gid"
578    
579     * test/postgissupport.py
580     (PostgreSQLServer.get_default_static_data_db): New static table
581     landmarks_point_id with an id column != "gid. Update the comments
582     a bit.
583     (skip_if_addgeometrycolumn_does_not_use_quote_ident): Fix typo in
584     doc-
585     (upload_shapefile): New parameter gid_column to use a name other
586     than "gid" for the column to store the shape ids
587    
588     * test/test_postgis_db.py (TableTests): New. Mixin-class
589     containing all tests previously in TestPostGISTable. The actual
590     tests are the same but the code is a bit more configurable to
591     allow for different id columns etc.
592     (TestPostGISTable): Derive from TableTests now for the actual
593     tests.
594     (TestPostGISTableExplicitGIDColumn): New. Like TestPostGISTable
595     except that it the landmarks_point_id table to test the id_column
596     parameter
597     (PointTests): Extend the doc-string
598     (TestPostGISShapestorePointExplicitGIDColumn)
599     (TestPostGISShapestorePointOIDAsGIDColumn): New classes derived
600     from PointTests to test the explicit id_column parameter. One
601     tests with the name of the column holding the shape ids, the other
602     uses PostgreSQL's OID column. For the latter a number of methods
603     have to be overwritten to make them independent of the actual id
604     values.
605    
606 silke 2095 2004-03-08 Silke Reimer <[email protected]>
607    
608     Update debian directory:
609    
610     * debian/changelog: Added new version.
611     * deiban/rules: Updated management of patches (with cbds)
612     * debian/control: Added cbds to dependencies
613     * debian/patches/*: New. Adds better support for patches of thuban in
614     debian
615     * debian/menu: Syntax of menu changed slightly
616     * debian/setup.py.patch: removed because it has been moved to
617     debian/patechs/setup.py.patch
618    
619    
620 bh 2094 2004-02-26 Bernhard Herzog <[email protected]>
621    
622     Create the Doc/technotes directory for text files with information
623     for developers
624    
625     * Doc/technotes/README: New. README for the technotes
626    
627     * Doc/technotes/coding_guidelines.txt: New. Coding guidelines for
628     Thuban
629    
630     * Doc/technotes/release_process.txt: New. Used to be
631     HOWTO-Release. Now slightly adapted to technote formatting style.
632    
633     * HOWTO-Release: Removed. It's contents are now in
634     Doc/technotes/release_process.txt
635    
636 bh 2089 2004-02-25 Bernhard Herzog <[email protected]>
637    
638     * libraries/thuban/wxproj.cpp (get_wx_version): New. Return the
639     version of wxWindows the module was compiled with so we can check
640     that against the wxPython version.
641    
642     * Thuban/version.py (thuban_branch, thuban_release): New variables
643     controlling which and how Thuban versions are shown. See the
644     comments for details.
645     (verify_versions): Also check that the wx version that wxproj is
646     compiled against matches that of the wxPython we use at runtime
647    
648 bh 2080 2004-02-20 Bernhard Herzog <[email protected]>
649    
650 bh 2087 * Extensions/wms/wms.py (epsg_code_to_projection): Use
651     get_system_proj_file to read the epsg projections. The old way
652     depended on the current directory being the top Thuban directory.
653    
654     2004-02-20 Bernhard Herzog <[email protected]>
655    
656 bh 2085 * Extensions/svgexport/test/test_svgmapwriter.py
657     (TestVirtualDC.test_clippath): Remove a debug print
658    
659     2004-02-20 Bernhard Herzog <[email protected]>
660    
661 bh 2083 * Extensions/svgexport/__init__.py: New. Turn
662     Extensions/svgexport into a package.
663    
664     * Extensions/svgexport/svgmapwriter.py: Reorder the imports and
665     doc-string a bit. The doc-string must come first, otherwise it's
666     not a doc-string. The __future__ import must be the first thing
667     after the doc-string. Use only double quotes in doc-strings.
668     Single quotes trip up emacs syntax highlighting if the text
669     contains apostrophes.
670    
671     2004-02-20 Bernhard Herzog <[email protected]>
672    
673 bh 2080 * Extensions/svgexport/test/__init__.py,
674     Extensions/svgexport/test/test_svgmapwriter.py: New. Initial test
675     suite for svgexport
676    
677     * test/runtests.py (find_test_modules): New. Function with the
678     module finding code from main.
679     (main): Use find_test_modules to figure out the default test
680     modules and take modules from Extensions.svgexport.test too.
681    
682 bh 2075 2004-02-19 Bernhard Herzog <[email protected]>
683    
684 bh 2077 * Thuban/UI/application.py (ThubanApplication.OnInit): Make sure
685     the mainwindow has a reference to the map of the initial session.
686     This fixes a bug introduced with the fix for RT#2245
687    
688     2004-02-19 Bernhard Herzog <[email protected]>
689    
690 bh 2075 * Extensions/svgexport/svgsaver.py,
691     Extensions/svgexport/svgmapwriter.py,
692     Extensions/svgexport/maplegend.py: Added again. This time in the
693     correct place.
694    
695 bh 2070 2004-02-17 Bernhard Herzog <[email protected]>
696    
697 bh 2073 Fix for RT#2245
698    
699     * Thuban/UI/application.py (ThubanApplication.OnInit): Initialize
700     instance variables before trying to create any windows. Creating
701     windows can start an event loop if e.g. message boxes are popped
702     up for some reason, and event handlers, especially EVT_UPDATE_UI
703     may want to access things from the application.
704     (ThubanApplication.maps_changed): The mainwindow may not have been
705     created yet, so check whether it has been created before calling
706     its methods
707    
708     * Thuban/UI/view.py (MapCanvas.OnIdle): Only try to redraw if we
709     have a map
710    
711     2004-02-17 Bernhard Herzog <[email protected]>
712    
713 bh 2070 * test/test_svgmapwriter.py, Extensions/svgsaver.py,
714     Extensions/svgmapwriter.py, Extensions/maplegend.py,
715     extensions/svgexport/svgsaver.py,
716     extensions/svgexport/svgmapwriter.py,
717     extensions/svgexport/maplegend.py: Removed. These files were in
718     the wrong places or didn't work at all.
719    
720 bh 2067 2004-02-16 Bernhard Herzog <[email protected]>
721    
722 bh 2069 * Thuban/UI/view.py (MapCanvas.Export): Remove accidentally added
723     line
724    
725     2004-02-16 Bernhard Herzog <[email protected]>
726    
727 bh 2067 * Thuban/UI/view.py (MapCanvas.Export): Avoid UnboundLocalError.
728    
729 mrechtie 2064 2004-02-15 Markus Rechtien <[email protected]>
730    
731     * Extensions/svgexport/svgmapwriter.py: New. Adds the capability
732     to write a session to a file in SVG format.
733     * Extensions/svgexport/svgsaver.py: New. Uses svgmapwriter.py
734     to write a SVG map of a session.
735     * Extensions/svgexport/maplegend: New. Writes a basic maplegend
736     in SVG format for the current session.
737    
738 bh 2062 2004-02-13 Bernhard Herzog <[email protected]>
739    
740     * Thuban/UI/mainwindow.py (MainWindow.AddDBLayer): When the layer
741     can't be created, return immediately after displaying the error
742     message.
743    
744 bh 2060 2004-02-11 Bernhard Herzog <[email protected]>
745    
746     Handle postgis tables with more than one geometry column.
747    
748     * Thuban/Model/postgisdb.py
749     (PostGISTable._fetch_table_information): Delegate the creation of
750     column objects to a different method so that we can extend that in
751     derived classes
752     (PostGISTable._create_col_from_description): New. Column object
753     creation part of _fetch_table_information
754     (PostGISShapeStore._create_col_from_description): New. Extend
755     inherited method to handle geometry columns
756     (PostGISShapeStore.__init__): New parameter geometry_column to
757     specify which geometry column to use. Optional but mandatory for
758     tables with more than one geometry column
759     (PostGISShapeStore._fetch_table_information): Also use the name of
760     the geometry column when looking for the srid
761     (PostGISShapeStore.ShapeType): Also use the name of the geometry
762     column when looking for the shape type
763    
764     * test/test_save.py (SaveSessionTest.test_save_postgis): Adapt
765     NonConnectionStore to changes in the PostGISShapeStore
766    
767     * test/test_postgis_db.py
768     (TestPostGISSpecialCases.test_shapestore_two_geom_cols): Test
769     PostGISShapeStore with tables having two geometry columns.
770    
771 bh 2058 2004-02-10 Bernhard Herzog <[email protected]>
772    
773     Fix some postgis problems. What remains to be done is real
774     handling of SRIDs as they affect how reprojection is done
775    
776     * Thuban/Model/postgisdb.py (quote_identifier): Fix typo in
777     doc-string
778     (PostGISShapeStore._fetch_table_information): New. Extend
779     inherited method to retrieve srid
780     (PostGISShapeStore.BoundingBox): Handle tables without data.
781     extent yields NULL for those
782     (PostGISShapeStore.ShapesInRegion): Use the srid of the table.
783    
784     * test/test_postgis_db.py
785     (TestPostGISSpecialCases.test_shapestore_empty_table): New test
786     for the special case of a table without any data
787     (TestPostGISShapestorePointSRID): New class with tests for a table
788     that uses srids
789     (PolygonTests): Fix a doc-string typo
790    
791     * test/postgissupport.py (PostGISDatabase.__init__): New parameter
792     reference_systems with a specification of spacial reference
793     systems to create in the new db.
794     (PostgreSQLServer.new_postgis_db)
795     (PostgreSQLServer.get_static_data_db): New parameter
796     reference_systems to be passed through ultimately to
797     PostGISDatabase. In new_postgis_db also check whether an existing
798     db already has the right srids
799     (PostgreSQLServer.get_default_static_data_db): Add srids and a
800     table that uses srids
801     (PostGISDatabase.initdb): Create the entries for the reference
802     systems
803     (PostGISDatabase.has_data): Add reference_systems parameter to
804     check for those too
805     (upload_shapefile): New parameter srid to create tables with a
806     specific srid
807    
808 frank 2055 2004-02-06 Frank Koormann <[email protected]>
809    
810     * po/pt_BR.po: Fixed charset
811    
812 frank 2054 2004-02-05 Frank Koormann <[email protected]>
813    
814     * po/pt_BR.po: Fixed format string for error message, missing %s
815     added (Thuban/UI/application.py:273)
816    
817 frank 2053 2004-02-03 Frank Koormann <[email protected]>
818    
819     First version of Portuguese (Brazilian) translation
820    
821     * po/pt_BR.po: New, translation of pot (2004-01-15 16:07+0300) for
822     Brazilian Portuguese by Eduardo Patto Kanegae.
823    
824     * Thuban/UI/about.py (About.__init.py__): Added Eduardo to the list of
825     translators.
826    
827    
828 frank 2052 2004-01-22 Frank Koormann <[email protected]>
829    
830     * Doc/manual/thuban-manual.xml: Added section on installation of
831     Thuban under Win32 systems. Fixed image path references in the postgis
832     section. Some minor source formattings.
833    
834 frank 2051 2004-01-21 Frank Koormann <[email protected]>
835    
836     Make Thuban remember path selections (at least for one application run).
837    
838     * Thuban/UI/application.py (Application.OnInit): Initialize path as a
839     attribute of application object. Path is a dictionary of
840     strings, currently with the items "data" and "projection".
841     (Application.SetPath): New, stores path for the specified item.
842     (Application.Path): New, return path for the specified item.
843    
844     * Thuban/UI/mainwindow.py
845     (MainWindow.OpenSession, MainWindow.SaveSessionAs,
846     MainWindow.AddLayer, MainWindow.AddRasterLayer,
847     MainWindow.TableOpen): Access "data" path information of the
848     application.
849    
850     * Thuban/UI/projdialog.py (ProjFrame._OnImport, ProjFrame._OnExport):
851     Access "projection" path information of the application.
852    
853 bh 2048 2004-01-05 Bernhard Herzog <[email protected]>
854    
855 bh 2050 * po/ru.po: Updated translations from Alex Shevlakov
856    
857     2004-01-05 Bernhard Herzog <[email protected]>
858    
859 bh 2048 * po/Makefile, po/README: Move the description of how to generate
860     the translation statistics to the README.
861    
862 bh 2042 2003-12-23 Bernhard Herzog <[email protected]>
863    
864 bh 2045 * NEWS: Update for 1.0.0
865    
866     * po/it.po: Another update from Maurizio Napolitano
867    
868     2003-12-23 Bernhard Herzog <[email protected]>
869    
870 bh 2042 * po/it.po: Updated translation from Maurizio Napolitano
871    
872     2003-12-23 Bernhard Herzog <[email protected]>
873    
874     * Thuban/UI/join.py (JoinDialog.__init__): Mark one more string
875     for translation
876    
877     * Thuban/UI/mainwindow.py (MainWindow.TableRename)
878     (MainWindow.RenameMap, MainWindow.RenameLayer): Mark some more
879     strings for translation
880    
881     * po/de.po: Update with the newly marked strings.
882    
883 bh 2033 2003-12-22 Bernhard Herzog <[email protected]>
884    
885 bh 2039 * HOWTO-Release: Fix the places where version numbers have to be
886     updated
887    
888     2003-12-22 Bernhard Herzog <[email protected]>
889    
890 bh 2037 * setup.py (setup call): 1.0.0, yeah!
891    
892     * Thuban/version.py (longversion): 1.0.0, yeah!
893    
894     * Thuban/Model/load.py (SessionLoader.__init__): Accept the
895     1.0.0 namespace too
896    
897     * Thuban/Model/save.py (SessionSaver.write_session): Save with
898     1.0.0 namespace
899    
900     * test/test_load.py (LoadSessionTest.dtd)
901     (TestSingleLayer.file_contents)
902     (TestNonAsciiColumnName.file_contents)
903     (TestLayerVisibility.file_contents)
904     (TestClassification.file_contents, TestLabels.file_contents)
905     (TestLayerProjection.file_contents)
906     (TestRasterLayer.file_contents, TestJoinedTable.file_contents)
907     (TestLabelLayer.file_contents, TestPostGISLayer.file_contents)
908     (TestPostGISLayerPassword.file_contents)
909     (TestLoadError.file_contents, TestLoadError.test): Update for
910     1.0.0 namespace
911    
912     * test/test_save.py (SaveSessionTest.dtd)
913     (SaveSessionTest.testEmptySession)
914     (SaveSessionTest.testSingleLayer)
915     (SaveSessionTest.testLayerProjection)
916     (SaveSessionTest.testRasterLayer)
917     (SaveSessionTest.testClassifiedLayer)
918     (SaveSessionTest.test_dbf_table)
919     (SaveSessionTest.test_joined_table)
920     (SaveSessionTest.test_save_postgis): Update for 1.0.0 namespace
921    
922     2003-12-22 Bernhard Herzog <[email protected]>
923    
924 bh 2035 * Thuban/Model/load.py (SessionLoader.start_label): Make sure the
925     alignment flags are byte strings not unicode and that they have
926     valid values
927    
928     * test/test_load.py (TestLabelLayer): New. Test loading (and
929     indirectly saving) of maps with labels.
930    
931     2003-12-22 Bernhard Herzog <[email protected]>
932    
933 bh 2033 * Thuban/UI/tableview.py (TableGrid.OnDestroy)
934     (TableGrid.__init__): Handle EVT_WINDOW_DESTROY in the grid to
935     unsubscribe all subscribers.
936     (LayerTableFrame.OnDestroy): Do not unsubscribe any messages from
937     self.grid since it may already have been destroyed.
938     Fixes RT #2256
939    
940 bh 2031 2003-12-19 Bernhard Herzog <[email protected]>
941    
942     * po/fr.po, po/es.po: Updated translations from Daniel Calvelo
943    
944 bh 2028 2003-12-16 Bernhard Herzog <[email protected]>
945 silke 2029
946     * debian/bitmappath.patch, debian/setup.py.patch:
947     added to ensure compliance with FHS for debian
948     * debian/rules, debian/changelog:
949     added patches in rules to ensure compliance with FHS for debian
950 bh 2028
951 silke 2029 2003-12-16 Bernhard Herzog <[email protected]>
952    
953 bh 2028 * po/Makefile (mo): Make the output a bit nicer so that it prints
954     statistics about the translations. Add a comment how produce even
955     nicer statistics with sed.
956    
957 frank 2026 2003-12-09 Frank Koormann <[email protected]>
958    
959     * Resources/Projections/defaults.proj:
960     French projection sample with correct accents (UNICODE).
961    
962 bh 2025 2003-12-05 Bernhard Herzog <[email protected]>
963    
964     * MANIFEST.in: Add the devtools directory
965    
966     * setup.py (setup call): Use license instead of licence. This
967     silences a deprecation warning on Python 2.3
968    
969 frank 2022 2003-12-05 Frank Koormann <[email protected]>
970    
971 frank 2023 Documentation synced with 1.0rc1
972    
973     * Doc/manual/thuban-manual.xml:
974     Minor formatting changes and references to database layers .
975     Introduction.Internationalization: New section on i18n.
976     MapManagement.AddingandRemovingLayers: Added item on database layers.
977     MapManagement.TheLegend: Added section and screenshot on popup menu.
978     ProjectionManagement: Updated screenshot and sentence on EPSG.
979     Appendix.SupportedDataSources: Added PostGIS.
980     Appendix.WorkingwithPostGIS: New section.
981    
982     * Doc/manual/images/6_projection.png: Updated screenshot including
983     EPSG checkboxes.
984    
985     * Doc/manual/images/3_5_popup_menu.png: New, popup menu screenshot.
986    
987     * Doc/manual/images/app_postgis_add_layer.png,
988     Doc/manual/images/app_postgis_db_add.png,
989     Doc/manual/images/app_postgis_db_management.png:
990     New screenshots focussing on database layers
991    
992     2003-12-05 Frank Koormann <[email protected]>
993    
994 frank 2022 * Thuban/UI/projdialog.py (load_user_proj): If user.proj is missing
995     write warning to stderr instead of rising a warning dialog
996    
997 bh 2016 2003-12-03 Bernhard Herzog <[email protected]>
998    
999 bh 2021 Fix for RT #2243
1000    
1001 bh 2020 * Thuban/UI/mainwindow.py (MainWindow.has_selected_shape_layer):
1002     New. Like has_selected_layer but for shape layers only
1003     (_has_selected_shape_layer): New. Like _has_selected_layer but for
1004     shape layers only
1005     (layer_show_table command, layer_jointable command): Use these
1006     commands should only be available for shape layers
1007    
1008     2003-12-03 Bernhard Herzog <[email protected]>
1009    
1010 bh 2018 * Thuban/UI/mainwindow.py (MainWindow.Unsubscribe): Deal with
1011     publishers that are wx objects and may have been destroyed by wx
1012     already. Fixes RT #2242.
1013    
1014     2003-12-03 Bernhard Herzog <[email protected]>
1015    
1016 bh 2016 * po/ru.po: Updates from Alex Shevlakov
1017    
1018 silke 2013 2003-12-03 Silke Reimer <silkeintevation.de>
1019    
1020     * debian/control, debian/changelog: Added gdal-support to
1021     debian package, updated to new thuban version
1022    
1023    
1024 bh 2012 2003-12-03 Bernhard Herzog <[email protected]>
1025    
1026     * Thuban/Lib/version.py: New. Module for version number
1027     manipulations. The version of make_tuple here also deals better
1028     with more unusual version number strings, such as e.g.
1029     "1.2+cvs20031111"
1030    
1031     * Thuban/version.py (make_tuple): Removed. It's now in
1032     Thuban.Lib.version. Use that implementation instead.
1033    
1034     * test/test_lib_version.py: New. Tests for Thuban/Lib/version.py
1035    
1036 bh 2005 2003-12-02 Bernhard Herzog <[email protected]>
1037    
1038 bh 2010 * MANIFEST.in: Add debian files
1039    
1040 bh 2008 * setup.py (setup call): Add packages for the Extensions so that
1041     they're installed too
1042     (data_files): Add READMEs and sample data from some Extensions
1043    
1044     * NEWS: Add note about the extensions in binary packages
1045    
1046     2003-12-02 Bernhard Herzog <[email protected]>
1047    
1048 bh 2005 * Thuban/Model/save.py (SessionSaver.write_session): Save files
1049     with the thuban-1.0rc1
1050    
1051     * Thuban/Model/load.py (SessionLoader.__init__): Recognize the
1052     thuban-1.0rc1 namespace too
1053    
1054     * test/test_save.py (SaveSessionTest.dtd)
1055     (SaveSessionTest.testEmptySession)
1056     (SaveSessionTest.testSingleLayer)
1057     (SaveSessionTest.testLayerProjection)
1058     (SaveSessionTest.testRasterLayer)
1059     (SaveSessionTest.testClassifiedLayer)
1060     (SaveSessionTest.test_dbf_table)
1061     (SaveSessionTest.test_joined_table)
1062     (SaveSessionTest.test_save_postgis): Update to thuban-1.0rc1
1063     namespace
1064    
1065     * test/test_load.py (LoadSessionTest.dtd): Update to thuban-1.0rc1
1066     namespace
1067     (TestSingleLayer.file_contents)
1068     (TestNonAsciiColumnName.file_contents)
1069     (TestLayerVisibility.file_contents)
1070     (TestClassification.file_contents, TestLabels.file_contents)
1071     (TestLayerProjection.file_contents)
1072     (TestRasterLayer.file_contents, TestJoinedTable.file_contents)
1073     (TestPostGISLayer.file_contents)
1074     (TestPostGISLayerPassword.file_contents)
1075     (TestLoadError.file_contents, TestLoadError.test): Update to
1076     thuban-1.0rc1 namespace
1077    
1078 bh 1996 2003-12-01 Bernhard Herzog <[email protected]>
1079    
1080 bh 2003 * setup.py (proj4_prefix, wx_prefix, gdal_prefix): Fix these for
1081     nt to better match Intevation's current w32 setup
1082    
1083 bh 2001 * HOWTO-Release: Add note about updating MANIFEST.in
1084    
1085     * MANIFEST.in: Add the Extensions
1086    
1087 bh 1998 * NEWS: Update for 1.0rc1
1088    
1089     2003-12-01 Bernhard Herzog <[email protected]>
1090    
1091 bh 1996 * Thuban/UI/mainwindow.py (MainWindow.AddLayer): Change the wild
1092     cards for the dialog so that shapefiles ending in all uppercase
1093     SHP are listed too
1094    
1095 bh 1988 2003-11-28 Bernhard Herzog <[email protected]>
1096    
1097 bh 1996 * Thuban/version.py (longversion): Update to 1.0rc1
1098    
1099     * setup.py (setup call): Update version to 1.0rc1. Use the
1100     [email protected] email address as author email instead of my
1101     personal one.
1102    
1103     2003-11-28 Bernhard Herzog <[email protected]>
1104    
1105 bh 1992 * po/de.po: Update german translation.
1106    
1107     2003-11-28 Bernhard Herzog <[email protected]>
1108    
1109 bh 1990 Unify the filenames stored in .thuban files so that the .thuban
1110     files are more platform independend
1111    
1112     * Thuban/Model/save.py (unify_filename): New. Unify filenames so
1113     that they can be used on both windows and unix
1114     (SessionSaver.prepare_filename): New. Handle all filename
1115     transformations for filenames stored in the thuban file
1116     (SessionSaver.write_data_containers, SessionSaver.write_layer):
1117     Use prepare_filename
1118    
1119     * test/test_save.py (SaveSessionTest.testSingleLayer)
1120     (SaveSessionTest.testLayerProjection)
1121     (SaveSessionTest.testRasterLayer)
1122     (SaveSessionTest.testClassifiedLayer)
1123     (SaveSessionTest.test_dbf_table)
1124     (SaveSessionTest.test_joined_table): Filenames are always stored
1125     with slashes on all currently supported platforms so adapt all
1126     tests to this
1127    
1128     * test/test_load.py (LoadSessionTest.filenames): With the new
1129     filename scheme the filenames in the tests should be
1130     understandable on all currently supported platforms so we turn
1131     this into an empty list because we don't have to normalize them
1132     anymore
1133    
1134     2003-11-28 Bernhard Herzog <[email protected]>
1135    
1136 bh 1988 * test/test_layer.py (TestLayer.test_arc_layer_with_projection):
1137     Add the ellipsoid to the projection since some Proj versions
1138     complain if it's missing.
1139    
1140 bh 1984 2003-11-27 Bernhard Herzog <[email protected]>
1141    
1142     Corect some bounding box projection problems
1143    
1144     * Thuban/Model/proj.py (Projection.InverseBBox): New. Inverse
1145     version of ForwardBBox
1146     (Projection._transform_bbox): New. common implementation of
1147     ForwardBBox and InverseBBox
1148     (Projection.ForwardBBox): Use _transform_bbox.
1149    
1150     * test/test_proj.py (TestProjection.test): Add test for
1151     InverseBBox
1152    
1153     * Thuban/Model/layer.py (Layer.LatLongBoundingBox)
1154     (Layer.ShapesBoundingBox, RasterLayer.LatLongBoundingBox): Use the
1155     new InverseBBox method to determine the unprojected bounding box
1156     (Layer.ShapesInRegion): Use the ForwardBBox method to project the
1157     bbox.
1158    
1159     * test/test_layer.py (TestLayer.test_point_layer_with_projection):
1160     Removed.
1161     (TestLayer.test_arc_layer_with_projection): New. This test is
1162     better able to test whether bounding boxes are projected correctly
1163     than test_point_layer_with_projection
1164    
1165 bh 1986 * Thuban/UI/viewport.py (ViewPort.map_projection_changed): Use
1166     InverseBBox to unproject bboxes
1167    
1168 bh 1975 2003-11-25 Bernhard Herzog <[email protected]>
1169    
1170 bh 1981 * Thuban/UI/about.py (About.__init__): Make sure we have ASCII
1171     source code.
1172    
1173     2003-11-25 Bernhard Herzog <[email protected]>
1174    
1175 bh 1979 * Thuban/Model/layer.py (Layer.__getattr__): Removed. It was only
1176     there for backwards compatibility and all code relying on that
1177     should have been updated by now.
1178    
1179     2003-11-25 Bernhard Herzog <[email protected]>
1180    
1181 bh 1977 * test/test_load.py (TestClassification.test): Add the missing
1182     round trip test.
1183     (TestClassification.file_contents): Update to the newest file
1184     format
1185    
1186     2003-11-25 Bernhard Herzog <[email protected]>
1187    
1188 bh 1975 Add very experimental (and possibly dangerous) extension to draw
1189     polygons:
1190    
1191     * Extensions/drawshape/README: New. Brief installation
1192     instructions
1193    
1194     * Extensions/drawshape/drawshape.py: New. Implementation of the
1195     drawshape extensions
1196    
1197     * Extensions/drawshape/patch.diff: Patch to apply before the
1198     extension can be used.
1199    
1200 bh 1971 2003-11-24 Bernhard Herzog <[email protected]>
1201    
1202 bh 1973 * Thuban/Model/data.py (ShapefileStore._open_shapefile)
1203     (ShapefileStore.__init__): Factor opening the shapefile into a
1204     separate method (the new _open_shapefile). This makes the code a
1205     bit more readable but the real reason is that it makes some evil
1206     hacks easier. :-)
1207    
1208     2003-11-24 Bernhard Herzog <[email protected]>
1209    
1210 bh 1971 * Thuban/Model/load.py (SessionLoader.check_attrs): If no
1211     converter is specified for an attribute assume it's a string
1212     containing only Latin1 characters. Update doc-string accordingly.
1213     This change should fix many places where unicode objects might
1214     accidentally enter Thuban.
1215    
1216     * test/test_load.py (TestNonAsciiColumnName): New test to check
1217     what happens with column names in DBF files that contain non-ascii
1218     characters
1219    
1220 bh 1969 2003-11-21 Bernhard Herzog <[email protected]>
1221    
1222     Enable the experimental attribute editing again and introduce a
1223     command line switch to actually activate it
1224    
1225     * Thuban/UI/main.py (options): New. Container for options set on
1226     the commmand line
1227     (main): Add the --enable-attribute-editing flag.
1228    
1229     * Thuban/UI/identifyview.py (IdentifyView.__init__): If attribute
1230     editing is enabled use the grid ctrl which allows editing of the
1231     values
1232    
1233     * Thuban/Model/transientdb.py (AutoTransientTable.write_record):
1234     New. Just delegate this to the underlying table.
1235    
1236 bh 1967 2003-11-20 Bernhard Herzog <[email protected]>
1237    
1238     * test/test_proj.py (ProjFileReadTests.test_read_unreadable_file):
1239     Skip this test if run under non-posix systems since it only works
1240     there
1241    
1242 bh 1960 2003-11-19 Bernhard Herzog <[email protected]>
1243    
1244 bh 1965 * Thuban/Model/resource.py: Rework the way gdal support is
1245     determined so that we can give a reason in the about why gdal is
1246     not supported.
1247     (gdal_support_status): New. Variable holding a string with the
1248     reason for no gdal support
1249    
1250     * Thuban/UI/about.py (About.__init__): Add the reason why gdal is
1251     not supported to the message
1252    
1253     2003-11-19 Bernhard Herzog <[email protected]>
1254    
1255 bh 1963 Remove the old table interface and its test cases
1256    
1257     * Thuban/Model/table.py (OldTableInterfaceMixin): Removed.
1258     (DBFTable, MemoryTable): Do not derive from OldTableInterfaceMixin
1259     anymore
1260    
1261     * Thuban/Model/transientdb.py (TransientTableBase)
1262     (AutoTransientTable): Do not derive from OldTableInterfaceMixin
1263     anymore
1264    
1265     * test/test_table.py: Removed since the old interface it tests is
1266     gone.
1267    
1268     * test/runtests.py (main): The old table interface is gone and
1269     with it the deprecation warnings so remove the code that turns
1270     these warnings into errors
1271    
1272     2003-11-19 Bernhard Herzog <[email protected]>
1273    
1274 bh 1960 * test/test_table.py: Revert to revision 1.5 again. Changing the
1275     tests to use the new table interface is completely wrong since the
1276     whole purpose of the tests in this module is to test the old
1277     interface.
1278    
1279 bh 1954 2003-11-18 Bernhard Herzog <[email protected]>
1280    
1281 bh 1958 * Thuban/Model/postgisdb.py (PostGISConnection.MatchesParameters):
1282     New. Test whether the connection matches a set of connection
1283     parameters
1284    
1285     * Thuban/UI/dbdialog.py (DBFrame.conns_changed): Fix doc-string
1286     (DBFrame.OnAdd): Use the new MatchesParameters method when looking
1287     for existing connections with the same parameters and break out of
1288     the loop correctly.
1289    
1290     * test/test_postgis_db.py (TestBriefDescription)
1291     (TestPostGISSimple.test_brief_description): Rename
1292     TestBriefDescription to TestPostGISSimple and the test method to
1293     test_brief_description so that we can add more test methods.
1294     (TestPostGISSimple.test_matches_parameters): New. Test the new
1295     MatchesParameters method
1296    
1297     2003-11-18 Bernhard Herzog <[email protected]>
1298    
1299 bh 1960 * Thuban/Lib/connector.py (Publisher): Introduce a new flag,
1300 bh 1954 _was_destroyed, to indicate whether an publisher instance has
1301     already been destroyed.
1302     (Publisher.Unsubscribe): Only disconnect if the publisher has not
1303     been destroyed yet.
1304     (Publisher.Destroy): Set the _was_destroyed flag to true.
1305    
1306     * test/test_connector.py
1307     (TestPublisher.test_unsubscribe_after_destroy): New. Test that
1308     calling Unsubscribe after Destroy doesn't raise an exception
1309    
1310 bh 1951 2003-11-14 Bernhard Herzog <[email protected]>
1311    
1312     * Thuban/UI/identifyview.py (IdentifyView.selected_shape): Fix
1313     typo in doc-string
1314    
1315 bh 1949 2003-11-13 Bernhard Herzog <[email protected]>
1316    
1317     Quote table and column names properly for postgis.
1318    
1319     * Thuban/Model/postgisdb.py (quote_identifier): New. Function to
1320     quote an identifier for use in an sql statement
1321     (PostGISColumn.__init__): Add the quoted_name attribute
1322     (PostGISTable.__init__): New instance variable quoted_tablename
1323     (PostGISTable._fetch_table_information): Use the quoted table
1324     name. New isntance variable quoted_geo_col with a quoted version
1325     of geometry_column
1326     (PostGISTable.NumRows, PostGISTable.RowIdToOrdinal)
1327     (PostGISTable.RowOrdinalToId): Use the quoted table name
1328     (PostGISTable.ReadValue, PostGISTable.ValueRange)
1329     (PostGISTable.UniqueValues, PostGISTable.SimpleQuery)
1330     (PostGISShapeStore.BoundingBox, PostGISShapeStore.Shape)
1331     (PostGISShapeStore.AllShapes, PostGISShapeStore.ShapesInRegion):
1332     Use quoted table and column names
1333    
1334     * test/test_postgis_db.py (TestPostGISSpecialCases)
1335     (TestPostGISIgnoredColumns): Rename the class to
1336     TestPostGISSpecialCases because that better describes the new
1337     cases
1338     (TestPostGISSpecialCases.test_unsupported_types)
1339     (TestPostGISSpecialCases.test): Rename the method to
1340     test_unsupported_types because we need a more descriptive name now
1341     that there are more methods
1342     (TestPostGISSpecialCases.test_table_name_quoting)
1343     (TestPostGISSpecialCases.test_column_name_quoting)
1344     (TestPostGISSpecialCases.test_shapestore_name_quoting): New test
1345     cases to test quoting of table and column names in PostGISTable
1346     and PostGISShapeStore
1347    
1348     * test/postgissupport.py
1349     (skip_if_addgeometrycolumn_does_not_use_quote_ident): New. Skip if
1350     AddGeometryColumn desn't support table or column names with sapces
1351     or double quotes
1352    
1353 jan 1945 2003-11-12 Jan-Oliver Wagner <[email protected]>
1354    
1355     * Extensions/wms/__init__.py: New: Init to make this
1356     directory a package.
1357    
1358     * Extensions/wms/wms.py: New: Provide layers via OGC WMS.
1359    
1360 bh 1932 2003-11-11 Bernhard Herzog <[email protected]>
1361    
1362 bh 1942 * Thuban/Model/resource.py (EPSG_DEPRECATED_PROJ_FILE): New.
1363     Constant for the file woth deprecated epsg projections
1364     (get_system_proj_file): Update doc-string
1365    
1366     * Thuban/UI/projdialog.py (ProjFrame.build_dialog): Add a space
1367     above the EPS widgets, introduce a check box for the deprecated
1368     eps projections and a label for the epsg widgets
1369     (ProjFrame._OnShowEPSG): Handle the deprecated EPSG projections
1370     too
1371    
1372     2003-11-11 Bernhard Herzog <[email protected]>
1373    
1374 bh 1939 Avoid warnings when run under Python 2.3
1375    
1376     * Thuban/UI/baserenderer.py (BaseRenderer.draw_point_shape)
1377     (BaseRenderer.draw_label_layer): Coordinates must be ints.
1378    
1379     * Thuban/UI/renderer.py (MapRenderer.make_point): Turn this into a
1380     real method so that we can convert to int.
1381     (MapRenderer.label_font): The font size mist be an int.
1382    
1383     * Thuban/UI/common.py (Color2wxColour): The color values must be
1384     ints. Also, remove the unnecessary asserts.
1385    
1386     * test/test_load_0_8.py (TestUnicodeStrings.file_contents)
1387     (TestUnicodeStrings.test): Python source code should not contain
1388     non-ascii characters unless an encoding is specified in the file.
1389     Therefore use \x escapes in the string literals for non-ascii
1390     characters.
1391    
1392     2003-11-11 Bernhard Herzog <[email protected]>
1393    
1394 bh 1934 * Thuban/Model/resource.py (get_system_proj_file): Add a filename
1395     parameter so that this function can be used for all proj files in
1396     Resource/Projections
1397     (DEFAULT_PROJ_FILE, EPSG_PROJ_FILE): New. Predefined filenames for
1398     get_system_proj_file
1399    
1400     * Thuban/UI/projdialog.py (ProjFrame.__init__): Instead of one
1401     ProjFile self.__sysProjFile use a dictionary of system ProjFile
1402     objects self._sys_proj_files
1403     (ProjFrame.build_dialog): Adapt to the new changes in the
1404     ProjectionList constructor. Add a check button to toggle whether
1405     EPSG projections are shown
1406     (ProjFrame._OnShowEPSG): New. Handler for the epsg check button
1407     events.
1408     (ProjFrame.load_user_proj, ProjFrame.load_system_proj): Only show
1409     the busy cursor if the files have not yet been loaded by the
1410     dialog.
1411     (ProjFrame.load_system_proj): Add a parameter for the name of the
1412     proj file. Maintain the dictionary of system projections
1413     self._sys_proj_files
1414    
1415     * Thuban/UI/projlist.py (ProjectionList): Merge the system_projs,
1416     user_projs parameters into one parameter proj_files which is a
1417     list of proj files.
1418     (ProjectionList._subscribe_proj_files)
1419     (ProjectionList._unsubscribe_proj_files): New. Move
1420     subscription/unsubscription of projfile messages to separate
1421     methods
1422     (ProjectionList.Destroy): The unsubscribe is now done in
1423     _unsubscribe_proj_files
1424     (ProjectionList.update_projections): We now have a list of proj
1425     file objects
1426     (ProjectionList.SetProjFiles): New method to set a new list of
1427     proj file objects
1428    
1429     * test/test_proj.py (ProjFileReadTests.test_get_system_proj_file):
1430     Specify explicitly which system proj file to load.
1431    
1432     2003-11-11 Bernhard Herzog <[email protected]>
1433    
1434 bh 1932 * Thuban/Model/load.py (SessionLoader.Destroy): New. Clear all
1435     instance variables to cut cyclic references. The GC would have
1436     collected the loader eventually but it can happen that it doesn't
1437     run at all until thuban is closed (2.3 but not 2.2 tries a bit
1438     harder and forces a collection when the interpreter terminates)
1439     (load_session): Call the handler's Destroy method to make sure
1440     that it gets garbage collected early. Otherwise it will be
1441     collected very late if at all and it holds some references to e.g.
1442     shapestores and the session which can lead to leaks (of e.g. the
1443     temporary files)
1444    
1445     * test/test_load.py (TestSingleLayer.test_leak): New. test for the
1446     resource leak in load_session
1447    
1448 bh 1929 2003-11-10 Bernhard Herzog <[email protected]>
1449    
1450     * Thuban/UI/baserenderer.py: Add a way to specify how layers in
1451     extensions are to be rendered.
1452     (_renderer_extensions): New. List with renderer for layers in
1453     extensions
1454     (add_renderer_extension): New. Add a renderer extension
1455     (init_renderer_extensions): New. Init the renderer extensions
1456     (BaseRenderer.render_map_incrementally): Search
1457     _renderer_extensions for how to draw unknown layer types
1458     (BaseRenderer.draw_raster_data): Add format parameter so that
1459     formats other than BMP can be drawn
1460     (BaseRenderer.draw_raster_layer): Pass an explicit format to
1461     draw_raster_data
1462    
1463     * Thuban/UI/renderer.py (raster_format_map): New. Mapping form the
1464     strings of the format parameter of draw_raster_data method to wx
1465     constants
1466     (MapRenderer.draw_raster_data): Add the format parameter and use
1467     raster_format_map to map it to the right wxwindows constant for
1468     wxImageFromStream
1469    
1470     * test/test_baserenderer.py (SimpleRenderer.draw_raster_data): Add
1471     the format parameter and record it
1472     (TestBaseRenderer.test_raster_no_projection): check the format
1473     paramter of the draw_raster_data method
1474     (TestBaseRenderer.test_renderer_extension): New. Test the renderer
1475     extension facility
1476    
1477 bh 1925 2003-11-07 Bernhard Herzog <[email protected]>
1478    
1479     Tweak the usage of the sqlite database to make common use cases
1480     more responsive. In most cases copying the data to the sqlite
1481     database takes so long that using sqlite doesn't have enough
1482     advantages.
1483    
1484     * Thuban/Model/transientdb.py (TransientTableBase.ValueRange): Add
1485     comments about performance and query the min and max in separate
1486     statements because only that way will indexes be used.
1487     (TransientTableBase.UniqueValues): Add some comments about
1488     performance.
1489     (AutoTransientTable.ValueRange, AutoTransientTable.UniqueValues):
1490     Do not copy the data to the transient DB but use the transient
1491     copy if it exists. See the new comments for the performance trade
1492     offs
1493    
1494     * test/test_transientdb.py
1495     (TestTransientTable.test_auto_transient_table): Make sure that the
1496     data is copied to the transient database at some point.
1497    
1498 bh 1913 2003-11-03 Bernhard Herzog <[email protected]>
1499    
1500 bh 1922 * Thuban/Model/data.py (ShapefileStore.ShapesInRegion): Bind some
1501     globals to locals so that it's a bit faster
1502    
1503     2003-11-03 Bernhard Herzog <[email protected]>
1504    
1505 bh 1920 * Thuban/UI/baserenderer.py
1506     (BaseRenderer.draw_shape_layer_incrementally): Use the ReadValue
1507     method. ReadValue is faster than ReadRowAsDict since it only reads
1508     one cell especially now that the dbf file objects actually
1509     implement it.
1510    
1511     * Thuban/Model/table.py (DBFTable.ReadValue): Use the new
1512     read_attribute method of the dbf objects
1513    
1514     2003-11-03 Bernhard Herzog <[email protected]>
1515    
1516 bh 1916 * Extensions/profiling/profiling.py (popup_dialog_box): New config
1517     variable to indicate whether the result should be shown in a
1518     dialog box
1519     (profile_screen_renderer, time_screen_renderer): Only show a
1520     dialog box if popup_dialog_box is true.
1521     (profile_screen_renderer): Flush stdout after the printing the
1522     first part of the "profiling..." message
1523    
1524     * Thuban/UI/baserenderer.py
1525     (BaseRenderer.draw_shape_layer_incrementally): Cache the pens and
1526     brushes for the groups so that they're not created over and over
1527     again
1528    
1529 bh 1913 * Thuban/Model/classification.py (Classification.__getattr__)
1530     (Classification._compile_classification)
1531     (Classification._clear_compiled_classification): New. Methods to
1532     manage a 'compiled' representation of the classification groups
1533     which is created on demand
1534     (Classification.InsertGroup, Classification.RemoveGroup)
1535     (Classification.ReplaceGroup): reset the compiled representation
1536     (Classification.FindGroup): Use the compiled representation to
1537     find the matching group
1538     (ClassGroupRange.GetRangeTuple): New. Return the range as a tuple
1539    
1540 bh 1904 2003-10-31 Bernhard Herzog <[email protected]>
1541    
1542 bh 1911 * Thuban/Model/classification.py (Classification.SetDefaultGroup):
1543     Send a CLASS_CHANGED message
1544     (Classification.RemoveGroup): Send a CLASS_CHANGED message and do
1545     not return the removed group since it wasn't used.
1546    
1547     * test/test_classification.py
1548     (TestClassification.test_set_default_group): New. Test the
1549     SetDefaultGroup method
1550     (TestClassification.test_insert_group): New. Test the InsertGroup
1551     method
1552     (TestClassification.test_remove_group): New. Test the RemoveGroup
1553     method
1554     (TestClassification.test_replace_group): New. Test the
1555     ReplaceGroup method
1556    
1557     2003-10-31 Bernhard Herzog <[email protected]>
1558    
1559 bh 1908 * test/test_classification.py (TestClassification.setUp):
1560     Subscribe to the CLASS_CHANGED messages
1561     (TestClassification.tearDown): New. Destroy the classification
1562     properly
1563     (TestClassification.test_defaults): Add tests for the default line
1564     width and whether no messages were sent yet
1565     (TestClassification.test_set_default_properties): Add tests for
1566     messages and setting the default line width
1567     (TestClassification.test_add_singleton)
1568     (TestClassification.test_add_range)
1569     (TestClassification.test_multiple_groups): Add tests for messages
1570    
1571     2003-10-31 Bernhard Herzog <[email protected]>
1572    
1573 bh 1906 Some more refactoring in preparation for new tests:
1574    
1575     * test/test_classification.py (TestClassification.setUp): New.
1576     Instantiate the classification here. Update the test methods
1577     accordingly.
1578     (TestClassification.test_multiple_groups): Make sure that the two
1579     singletons matching 1 are considered different.
1580    
1581     2003-10-31 Bernhard Herzog <[email protected]>
1582    
1583 bh 1904 * test/test_classification.py (red, green, blue): New. These
1584     constants were used in several cases. Update the relevant methods.
1585     (TestClassification.test_defaults)
1586     (TestClassification.test_set_default_properties)
1587     (TestClassification.test_add_singleton)
1588     (TestClassification.test_add_range)
1589     (TestClassification.test_multiple_groups)
1590     (TestClassification.test_deepcopy): New. These were formerly all
1591     part of the single method test.
1592     (TestClassification.test_deepcopy): Removed.
1593     (TestClassIterator): Removed. The test case is now a method of
1594     TestClassification since it tests part of the public interface of
1595     Classification
1596     (TestClassification.test_iterator): New. Used to be
1597     TestClassIterator effectively
1598    
1599 jan 1902 2003-10-31 Jan-Oliver Wagner <[email protected]>
1600    
1601     GUIfied the functions of the profiling extension.
1602    
1603     * /Extensions/profiling/__init__.py: New: Init to make this
1604     directory a package.
1605    
1606     * Extensions/profiling/profiling.py: Moved menu entries to
1607     the Extensions menu. Applied _() for strings.
1608     (profile_screen_renderer): Catch the detailed printout and present
1609     it in a dialog.
1610 bh 1904 (time_screen_renderer): Raise a dialog to present the result instead
1611 jan 1902 of printing it to stdout.
1612    
1613 bh 1897 2003-10-31 Bernhard Herzog <[email protected]>
1614    
1615 bh 1899 * test/test_classification.py (TestClassGroupProperties)
1616     (TestClassGroup, TestClassGroupDefault, TestClassGroupRange)
1617     (TestClassGroupSingleton, TestClassIterator, TestClassification):
1618     Split TestClassification into several classes, one for each class
1619     being tested. TestClassification itself now only tests
1620     Classification. This split makes changes to the tests a bit easier
1621    
1622     2003-10-31 Bernhard Herzog <[email protected]>
1623    
1624 bh 1897 * Extensions/profiling/profiling.py: New. Extension to measure
1625     Thuban performance
1626    
1627 frank 1895 2003-10-31 Frank Koormann <[email protected]>
1628    
1629     Added two items to legend popup menu: Remove Layer and Show Layer Table
1630    
1631     * Thuban/UI/legend.py (LegendPanel._OnRemoveLayer,
1632     LegendPanel._OnShowTable): New event handlers, call the corresponding
1633     mainwindow methods.
1634     (LegendTree._OnRightClick): Added items to popup menu.
1635    
1636 bh 1894 2003-10-30 Bernhard Herzog <[email protected]>
1637    
1638     * Thuban/UI/dialogs.py (ThubanFrame.__init__): Handle
1639     EVT_WINDOW_DESTROY
1640     (ThubanFrame.OnDestroy): New. Handler for EVT_WINDOW_DESTROY. Does
1641     nothing but is convenient for the derived classes.
1642    
1643     * Thuban/UI/tableview.py
1644     (TableFrame.OnDestroy, LayerTableFrame.OnDestroy): New.
1645     Unsubscribe the messages here not in OnClose because that might
1646     get called multiple times. Fixes RT #2196
1647     (TableFrame.OnClose, LayerTableFrame.OnClose): Removed. Not needed
1648     anymore.
1649    
1650     * README: Update the minimum requirement for wxPython. Since we
1651     now use the EVT_WINDOW_DESTROY event, we need at least 2.4.0.4,
1652     the version in which that was introduced for all platforms
1653    
1654 frank 1890 2003-10-30 Frank Koormann <[email protected]>
1655    
1656     * Thuban/UI/join.py (JoinDialog.OnJoin): Wrapped the major parts of
1657     the join process in a ThubanBeginBusyCursor, ThubanEndBusyCursor
1658     frame.
1659    
1660 jan 1889 2003-10-30 Jan-Oliver Wagner <[email protected]>
1661    
1662     Improved APR import extension, added further EPSG definitions
1663     and some cleanup regarding string class.
1664    
1665     * test/test_proj.py (TestProjection.test_get_projection_units_geo):
1666     Added test for alias 'longlat'.
1667    
1668     * Resources/Projections/epsg-deprecated.proj: New. Contains
1669     deprecated EPSG definitions.
1670    
1671     * Extensions/importAPR/odb.py (ODBBaseObject.TreeInfo): Added
1672     the variable names for objects.
1673    
1674     * Extensions/importAPR/apr.py (APR_BLnSym, APR_BMkSym, APR_BShSym): New.
1675     Copied from importAPR and provided with documentation.
1676    
1677     * Extensions/importAPR/importAPR.py (APR_BLnSym, APR_BMkSym, APR_BShSym):
1678     Moved to apr.py.
1679     (APR_View): Added object ref 'ITheme'.
1680    
1681     * Thuban/Lib/fileutil.py, Thuban/UI/proj4dialog.py: Replaced string
1682     split function by corresponding use of the string class method.
1683    
1684     * Thuban/Model/xmlwriter.py: Replaced string replace function by
1685     corresponding string method.
1686    
1687 bh 1880 2003-10-29 Bernhard Herzog <[email protected]>
1688    
1689     * Thuban/UI/baserenderer.py
1690     (BaseRenderer.draw_shape_layer_incrementally): Speed up the
1691     special case of a classification that only has the default group
1692    
1693 bh 1868 2003-10-27 Bernhard Herzog <[email protected]>
1694    
1695 bh 1878 * po/fr.po, po/es.po: Updated translations from Daniel Calvelo
1696    
1697 bh 1876 * po/de.po: Update.
1698    
1699     * Thuban/UI/application.py
1700     (ThubanApplication.ShowExceptionDialog): Handle translation of the
1701     dialog message properly
1702    
1703     2003-10-27 Bernhard Herzog <[email protected]>
1704    
1705 bh 1873 Rework how localization works so that we use wx's translation
1706     functions when running Thuban as a normal application but not when
1707     we don't need any UI, such as in the test suite. See the comment
1708     in Thuban/__init__.py for details
1709    
1710     * Thuban/__init__.py (_): Add one level of indirection to make the
1711     translation handling more flexible and to make it possible to use
1712     either wx's translation services or not.
1713     (gettext_identity, translation_function_installed)
1714     (install_translation_function): New function to help with this
1715    
1716     * Thuban/UI/__init__.py: Install the wx specific translation
1717     function if it's OK to do that
1718    
1719     * test/support.py (initthuban): Install a dummy translation
1720     function so that importing Thuban.UI doesn't install a wx specific
1721     one for which would need to import wxPython
1722    
1723     2003-10-27 Bernhard Herzog <[email protected]>
1724    
1725 bh 1870 * HOWTO-Release: Source archives should be created first and the
1726     binary packages should be created from the source archives.
1727     There's an official debian package now so there's no need to test
1728     the rpm on debian anymore
1729    
1730     2003-10-27 Bernhard Herzog <[email protected]>
1731    
1732 bh 1868 Several rendering changes:
1733    
1734     - Render the selection into a separate bitmap so that only that
1735     bitmap needs to be redrawn when the selection changes
1736    
1737     - Render incrementally showing previews and allowing interaction
1738     before rendering is complete
1739    
1740     - Update the renderer interface a bit. Most parameters of
1741     RenderMap are now parameters of the constructor
1742    
1743     * Thuban/UI/baserenderer.py (BaseRenderer.__init__): Add the map
1744     and the update region as parameters. Update the doc-string
1745     (BaseRenderer.render_map_incrementally): New. Generator function
1746     to renders the map incrementally
1747     (BaseRenderer.render_map): Remove the map argument (it's now in
1748     the constructor) and simply iterate over the
1749     render_map_incrementally generator to draw the map.
1750     (BaseRenderer.draw_shape_layer_incrementally)
1751     (BaseRenderer.draw_shape_layer): Renamed to
1752     draw_shape_layer_incrementally and changed into a generator that
1753     yields True every 500 shapes. Used by render_map_incrementally to
1754     render shape layers incrementally
1755    
1756     * Thuban/UI/renderer.py (ScreenRenderer.RenderMap): Removed the
1757     map and region parameters which are now in the constructor
1758     (ScreenRenderer.RenderMapIncrementally): New. Public frontend for
1759     the inherited render_map_incrementally.
1760     (BaseRenderer.draw_shape_layer): Removed.
1761     (ScreenRenderer.draw_selection_incrementally): New. The selection
1762     drawing part of the removed draw_shape_layer as a generator
1763     (ScreenRenderer.layer_shapes): Update because of the region
1764     parameter change
1765     (ExportRenderer.__init__): New. Extend the inherited constructor
1766     with the destination region for the drawing
1767     (ExportRenderer.RenderMap): Removed the map and region parameters
1768     which are now in the constructor
1769    
1770     * Thuban/UI/view.py (MapCanvas.PreviewBitmap): New. Return a
1771     bitmap suitable for a preview in a tool
1772     (CanvasPanTool.MouseMove): Use the PreviewBitmap method to get the
1773     bitmap
1774     (MapPrintout.draw_on_dc): Adapt to new renderer interface
1775     (MapCanvas.OnPaint): Handle drawing the selection bitmap if it
1776     exists
1777     (MapCanvas.OnIdle): Update the logic to deal with incremental
1778     rendering and the selection bitmap
1779     (MapCanvas._do_redraw): Handle the instantiation of the render
1780     iterator and the redraws during rendering
1781     (MapCanvas._render_iterator): New. Generator to incrementally
1782     redraw both bitmaps
1783     (MapCanvas.Export): Adapt to new renderer interface.
1784     (MapCanvas.full_redraw): Reset the selection bitmap and the
1785     renderer iterator too
1786     (MapCanvas.redraw_selection): New. Force a redraw of the selection
1787     bitmap
1788     (MapCanvas.shape_selected): Only redraw the selection bitmap
1789    
1790     * test/test_baserenderer.py
1791     (TestBaseRenderer.test_polygon_no_projection)
1792     (TestBaseRenderer.test_raster_no_projection)
1793     (TestBaseRenderer.test_point_map_projection)
1794     (TestBaseRenderer.test_point_layer_and_map_projection)
1795     (TestBaseRenderer.test_point_layer_projection)
1796     (TestBaseRenderer.test_point_with_classification): Adapt to new
1797     renderer interface
1798    
1799 bh 1865 2003-10-24 Bernhard Herzog <[email protected]>
1800    
1801     * libraries/thuban/wxproj.cpp (draw_polygon_shape)
1802     (point_in_polygon_shape, shape_centroid): Raise an exception if
1803     the shape can't be read. Previously invalid shape ids would lead
1804     to a segfault.
1805    
1806     * test/test_wxproj.py (TestShapeCentroid.test_invalid_shape_id):
1807     New. test whether an exception is raised for invalid shape ids
1808    
1809 jan 1857 2003-10-24 Jan-Oliver Wagner <[email protected]>
1810    
1811 jan 1862 * Thuban/Model/proj.py (Projection.GetProjectedUnits): Added 'longlat'
1812     as alias for 'latlong'.
1813    
1814     * Thuban/UI/projdialog.py (ProjFrame.__init__): Added 'longlat'
1815     as alias for 'latlong'.
1816    
1817     2003-10-24 Jan-Oliver Wagner <[email protected]>
1818    
1819 jan 1859 * Thuban/UI/projdialog.py (ProjFrame.proj_selection_changed): Set
1820     the projection even for the UnknownPanel.
1821     (UnknownProjPanel.__init__): Define the text and create the textctrl
1822     widget.
1823     (UnknownProjPanel._DoLayout): Replaced static text widget by the
1824     textctrl created in __init__.
1825     (UnknownProjPanel.SetProjection): Set the text for the text ctrl
1826     including the parameters of the projection.
1827    
1828     2003-10-24 Jan-Oliver Wagner <[email protected]>
1829    
1830 jan 1857 * Resources/Projections/epsg.proj: New. This is a list of
1831     EPSG codes with parameters for proj. The list has been
1832     generated using devtools/create_epsg.py based on the
1833     file nad/epsg of the proj 4.4.7 package. Four projection
1834     definitions have been deleted as they are not accepted by proj:
1835     "CH1903+ / LV95", "Bern 1898 (Bern) / LV03C", "CH1903 / LV03"
1836     and "HD72 / EOV".
1837    
1838 bh 1855 2003-10-22 Bernhard Herzog <[email protected]>
1839    
1840     Some more tweaks to the projection dialog which should fix RT
1841     #1886.
1842    
1843     * Thuban/UI/projlist.py (ProjectionList.Destroy): Unsubscribe from
1844     the ProjFile's messages and call the base class methods correctly
1845     (ProjectionList.SelectProjection): Set the wxLIST_STATE_FOCUSED
1846     flag on the newly selected item too. Otherwise some other item is
1847     focused and the first time the focus is moved with the keyboard
1848     the selection moves in unexpected ways.
1849    
1850     * Thuban/UI/projdialog.py (ProjFrame.__init__): Do not set the
1851     focus on the OK button, only on the projection list. That way the
1852     list really has the focus initially
1853     (ProjFrame.OnClose): Call the projection list's Destroy method to
1854     make it unsubscribe all messages
1855    
1856 bh 1840 2003-10-21 Bernhard Herzog <[email protected]>
1857    
1858 bh 1852 Rework the projection dialog to fix a few bugs, including RT 2166
1859     and most of 2168
1860    
1861     * Thuban/UI/projlist.py: New. The class ProjectionList is a
1862     special wxListCtrl to show a list of projections in a more MVC
1863     fashion
1864    
1865     * Thuban/UI/projdialog.py (ProjFrame): Substantial changes
1866     throughout the class. The main change is to use the ProjectionList
1867     class instead of a normal wxListBox. Also, add an explicit
1868     "Unknown" projection to the projection choice control.
1869     (ProjPanel.__init__): Add an "unknown" ellipsoid
1870     (TMPanel.__init__, LCCPanel.__init__): Tweak the order of
1871     instantiation of the panel's controls to make the tab-order more
1872     natural
1873    
1874     2003-10-21 Bernhard Herzog <[email protected]>
1875    
1876 bh 1849 * test/test_load.py (TestSingleLayer.file_contents)
1877     (TestSingleLayer.test): Add non-ascii characters to the titles of
1878     session, map and layer. This is effectively a port of the
1879     TestUnicodeStrings test in test_load_0_8.py which for some reason
1880     was only added there.
1881    
1882     * test/test_load_0_9.py (TestSingleLayer.file_contents)
1883     (TestSingleLayer.test): Same as in test_load.py: add non-ascii
1884     characters to the titles of session, map and layer,.
1885    
1886     2003-10-21 Bernhard Herzog <[email protected]>
1887    
1888 bh 1847 Add EPSG projection handling to .thuban files
1889    
1890     * test/test_save.py (SaveSessionTest.dtd)
1891     (SaveSessionTest.testEmptySession)
1892     (SaveSessionTest.testLayerProjection)
1893     (SaveSessionTest.testRasterLayer)
1894     (SaveSessionTest.testClassifiedLayer)
1895     (SaveSessionTest.test_dbf_table)
1896     (SaveSessionTest.test_joined_table)
1897     (SaveSessionTest.test_save_postgis): Update to 1.0-dev namespace
1898     (SaveSessionTest.testSingleLayer): Update to 1.0-dev namespace and
1899     use a and epsg projection to test saving them
1900    
1901     * test/test_load.py (LoadSessionTest.dtd): Update to 1.0-dev
1902     namespace
1903     (TestLayerVisibility.file_contents, TestLabels.file_contents)
1904     (TestLayerProjection.file_contents)
1905     (TestRasterLayer.file_contents, TestJoinedTable.file_contents)
1906     (TestPostGISLayer.file_contents)
1907     (TestPostGISLayerPassword.file_contents)
1908     (TestLoadError.file_contents, TestLoadError.test): Update to use
1909     1.0-dev namespace
1910     (TestSingleLayer.file_contents, TestSingleLayer.test): Update to
1911     use 1.0-dev namespace and use an EPSG projection to test whether
1912     loading it works
1913    
1914     * test/test_load_0_9.py: New. Effectively a copy of test_load.py
1915     as of Thuban 0.9. These are now tests to determine whether Thuban
1916     can still read files generated by Thuban 0.9
1917    
1918     * Thuban/Model/save.py (SessionSaver.write)
1919     (SessionSaver.write_session): Use the 1.0 dtd and 1.0-dev
1920     namespace
1921     (SessionSaver.write_projection): Write the projection's epsg
1922     attribute
1923    
1924     * Thuban/Model/load.py (SessionLoader.__init__): Also accept the
1925     thuban-1.0-dev.dtd namespace
1926     (SessionLoader.check_attrs): Allow a callable object as conversion
1927     too
1928     (SessionLoader.start_projection, SessionLoader.end_projection)
1929     (SessionLoader.start_parameter): Handle the epsg attribute and
1930     rename a few instance variables to lower case
1931    
1932     * Resources/XML/thuban-1.0.dtd: New. Only difference to
1933     thuban-0.9.dtd is the epsg attribute for projections.
1934    
1935     2003-10-21 Bernhard Herzog <[email protected]>
1936    
1937 bh 1840 * test/runtests.py (main): Let the user specify which tests to run
1938     on the command line
1939    
1940     * test/support.py (ThubanTestResult.getDescription): Override to
1941     give a better short description. The description can be used as a
1942     parameter to run_tests to run that particular test in isolation.
1943    
1944 frank 1837 2003-10-21 Frank Koormann <[email protected]>
1945    
1946     Popup menu for legend. Scheduled for the 1.2 release this was too
1947     simple to implement: The popup menu is bound to the legend tree, while
1948     the events are hanlded by its anchestor, the legend panel. This
1949     allows reuse of all the event handlers already implemented for the
1950     legend toolbar buttons.
1951    
1952     * Thuban/UI/legend.py (LegendPanel.__init__): EVT_MENU macros
1953     to add handlers for the events issued by the popup menu.
1954     (LegendPanel._OnToggleVisibility): Handler for toggling layer
1955     visibility event
1956     (LegendPanel._OnProjection): Handler for layer projection event.
1957     (LegendTree.__init__): Added EVT_TREE_ITEM_RIGHT_CLICK
1958     (LegendTree._OnRightClick): Event handler for right click, select item
1959     and pop up menu.
1960     (LegendTree.ToggleVisibility): Toggle layer visibility
1961     (LegendTree.LayerProjection): Raise layer projection dialog for
1962     current layer.
1963    
1964 bh 1836 2003-10-21 Bernhard Herzog <[email protected]>
1965    
1966     * Resources/Projections/defaults.proj: Use correct DOCTYPE
1967     declaration. The top-level element is projectionlist not projfile
1968    
1969 bh 1834 2003-10-20 Bernhard Herzog <[email protected]>
1970    
1971     * Thuban/UI/projdialog.py (ProjFrame.write_proj_file): New. helper
1972     method to write a projfile and display a busy cursor and error
1973     dialogs.
1974     (ProjFrame._OnSave, ProjFrame._OnAddToList, ProjFrame._OnImport)
1975     (ProjFrame._OnExport, ProjFrame._OnRemove): Use write_proj_file
1976     (ProjFrame.__FillAvailList): Translate "<None>" too and display a
1977     busy cursor while loading the user and system prj files.
1978    
1979 bh 1832 2003-10-16 Bernhard Herzog <[email protected]>
1980    
1981     * Thuban/Model/resource.py (projfile_cache): Introduce a cache for
1982     ProjFile objects
1983     (clear_proj_file_cache): New function to clear the cache. Mainly
1984     useful for use by the test suite
1985     (read_proj_file): Use the cache.
1986    
1987     * test/test_proj.py (TestProjFile): Clarify the doc-string
1988     (ProjFileReadTests): Update doc-string
1989     (ProjFileReadTests.test_get_system_proj_file): Check whether the
1990     system proj files is cached.
1991     (ProjFileLoadTestCase): New base class for the proj file tests
1992     derived from support.FileLoadTestCase to provide some common
1993     behavior.
1994     (TestLoadingProjFile)
1995     (TestLoadingProjFileWithEmptyProjectionlist.file_contents)
1996     (TestProjFileWithInvalidParameters.file_contents): Derive from
1997     ProjFileLoadTestCase
1998     (TestLoadingProjFile.test_caching): New. Test whether the cache
1999     works
2000    
2001 silke 1829 2003-10-16 Silke Reimer <[email protected]>
2002    
2003     * debian/*: New directory with configuration files for building a thuban
2004     deb-package.
2005    
2006 bh 1822 2003-10-14 Bernhard Herzog <[email protected]>
2007    
2008 bh 1828 * test/test_proj.py: Execute support.run_tests when run as
2009     __main__ so that missing unsubscribes are detected
2010     (TestProjFile.tearDown): Destroy the proj_file properly
2011    
2012     2003-10-14 Bernhard Herzog <[email protected]>
2013    
2014 bh 1826 * Thuban/Model/messages.py (PROJECTION_ADDED)
2015     (PROJECTION_REPLACED, PROJECTION_REMOVED): New message types for
2016     the ProjFile objects
2017    
2018     * Thuban/Model/proj.py (ProjFile): Derive from Publisher so we can
2019     easily send messages when the projections change
2020     (ProjFile.Add, ProjFile.Remove, ProjFile.Replace): Issue messages
2021     when the change was successful
2022    
2023     * test/test_proj.py (TestProjFile.setUp): Subscribe to some of the
2024     proj file messages
2025     (TestProjFile.test_add_remove)
2026     (TestProjFile.test_remove_non_existing)
2027     (TestProjFile.test_replace)
2028     (TestProjFile.test_replace_non_existing): Test whether the right
2029     messages are sent
2030    
2031     2003-10-14 Bernhard Herzog <[email protected]>
2032    
2033 bh 1822 * test/test_proj.py (TestProjFile.test): Refactor into several
2034     tests
2035     (TestProjFile.test_add_remove)
2036     (TestProjFile.test_remove_non_existing)
2037     (TestProjFile.test_replace)
2038     (TestProjFile.test_replace_non_existing): Some of the new
2039     individual test cases
2040     (TestProjFileSimple): New class for the rest of the test cases
2041     that came out of the refactoring
2042     (ProjFileTest): Derive from xmlsupport.ValidationTest so that the
2043     derived classes don't have to
2044    
2045 bh 1812 2003-10-13 Bernhard Herzog <[email protected]>
2046    
2047 bh 1820 Add an optional EPSG code to the projection objects and extend the
2048     .proj file format accordingly.
2049    
2050     * Resources/XML/projfile.dtd (element projection): Add epsg
2051     attribute
2052    
2053     * Thuban/Model/proj.py (Projection.__init__): New parameter and
2054     instance variable epsg. Update doc-string
2055     (Projection.EPSGCode, Projection.Label): New methods to provide
2056     access to EPSG code and a label for use in dialogs
2057    
2058     * Thuban/Model/resource.py (ProjFileReader.start_projection)
2059     (ProjFileReader.end_projection, ProjFileSaver.write_projfile):
2060     Handle the epsg code attribute when reading or writing proj files
2061    
2062     * Thuban/UI/projdialog.py (ProjFrame._OnSave)
2063     (ProjFrame._OnAddToList, ProjFrame.__DoOnProjAvail)
2064     (ProjFrame.__FillAvailList): Use the projection's Label method to
2065     get the string for the list box
2066    
2067     * test/test_proj.py (TestProjection.test_label)
2068     (TestProjection.test_label_epsg)
2069     (TestProjection.test_epsgcode_for_non_epsg_projection)
2070     (TestProjection.test_epsgcode_for_real_epsg_projection): New tests
2071     for the label and EPSGCode methods
2072     (WriteProjFileTests.doTestWrite, WriteProjFileTests.test_write)
2073     (WriteProjFileTests.test_write_empty_file): Create the ProjFile
2074     objects in the test cases and put the expected contents into the
2075     test case methods too. Update doTestWrite accordingly
2076     (TestLoadingProjFile)
2077     (TestLoadingProjFileWithEmptyProjectionlist): New classes with the
2078     read tests from TestProjFile.
2079     (TestProjFile.doTestRead, TestProjFile.testRead): Removed. These
2080     tests are now in the new classes.
2081     (sample_projfile, sample_projfile_data)
2082     (sample_projfile2, sample_projfile_data2): Removed. Not used
2083     anymore.
2084     (TestProjFile.test_read_unreadable_file): No need to reset the
2085     permissions at the end anymore since we use a unique filename
2086    
2087     2003-10-13 Bernhard Herzog <[email protected]>
2088    
2089 bh 1814 * test/test_proj.py: Some more refactoring of the test cases
2090     (ProjFileTest): New base class for the proj file tests.
2091     (TestProjFile): Derive from ProjFileTest
2092     (TestProjFile.test_read_unreadable_file)
2093     (TestProjFile.test_read_empty_file, TestProjFile.doTestRead): Use
2094     the new filename method to get a unique filename
2095     (TestProjFile.doTestWrite, TestProjFile.testWrite): Removed.
2096     (WriteProjFileTests): New class for proj file write tests.
2097     Contains the write test that were in TestProjFile originally.
2098    
2099     2003-10-13 Bernhard Herzog <[email protected]>
2100    
2101 bh 1812 * test/test_proj.py (TestProjFile.testRead)
2102     (TestProjFile.test_read_non_existing_file)
2103     (TestProjFile.test_read_unreadable_file)
2104     (TestProjFile.test_read_empty_file): Split into several methods.
2105    
2106 bh 1805 2003-10-10 Bernhard Herzog <[email protected]>
2107    
2108 bh 1810 * Thuban/UI/sizers.py: New file with custom sizers.
2109    
2110     * Thuban/UI/projdialog.py (ProjFrame.build_dialog): Instantiate
2111     all projection type specific panels and put them into a
2112     NotebookLikeSizer. This way the dialog doesn't change its size
2113     when a different projection is selected
2114     (ProjFrame.__init__): Rename projection_panels
2115     projection_panel_defs and reuse projection_panels for a list of
2116     the instantiated panels.
2117     (ProjFrame._show_proj_panel, ProjFrame.__DoOnProjAvail)
2118     (ProjFrame.__DoOnProjChoice): Changes due to the new handling of
2119     the panels
2120     (UnknownProjPanel._DoLayout): Place the newlines in the message
2121     differently to make the panel narrower.
2122     (TMPanel._DoLayout): Layout the parameters in one column.
2123    
2124     2003-10-10 Bernhard Herzog <[email protected]>
2125    
2126 bh 1807 * Thuban/UI/projdialog.py (ProjFrame.build_dialog): New method
2127     that contains all the setup for the dialog's widgets, layout and
2128     event handling.
2129     (__): Call build_dialog to build the dialog.
2130     (ProjFrame.__set_properties, ProjFrame.__do_layout): Removed.
2131     Their functionality is now in build_dialog
2132     (ProjFrame.__VerifyButtons, ProjFrame.__VerifyButtons)
2133     (ProjFrame.__DoOnProjAvail, ProjFrame.__DoOnProjAvail)
2134     (ProjFrame.__DoOnProjChoice): Small updates due to slightly
2135     different widget names and hierarchy introduced with build_dialog.
2136    
2137     2003-10-10 Bernhard Herzog <[email protected]>
2138    
2139 bh 1805 * README: Fix typo.
2140    
2141 bh 1803 2003-10-09 Bernhard Herzog <[email protected]>
2142    
2143     * Thuban/Model/proj.py (ProjFile.Add): Do not check whether the
2144     projection is already in the list. This is *a lot* faster when
2145     loading files with hundreds of projections since it saves a linear
2146     search. OTOH this will allow adding the same projection to the
2147     user.proj file multiple times in the projection dialog but we'll
2148     deal with that later
2149    
2150 jan 1801 2003-10-09 Jan-Oliver Wagner <[email protected]>
2151    
2152     * devtools: New. Directory for developer tools that are not intended
2153     for the regular user.
2154    
2155     * devtools/create_epsg.py: New. Convert the epsg file of proj into
2156     a python .proj file.
2157    
2158 bh 1799 2003-10-09 Bernhard Herzog <[email protected]>
2159    
2160     * test/test_proj.py
2161     (TestProjection.test_get_parameter_without_equals_sign): New. Test
2162     whether GetParameter handles parameters without "=" sign correctly
2163    
2164     * Thuban/Model/proj.py (Projection.GetParameter): Handle
2165     parameters that do not contain a "=". Update the doc-string
2166    
2167 bh 1794 2003-10-08 Bernhard Herzog <[email protected]>
2168    
2169 bh 1796 * Thuban/UI/projdialog.py (ProjFrame.__set_properties): Remove the
2170     length limit on the projname text control
2171    
2172     2003-10-08 Bernhard Herzog <[email protected]>
2173    
2174 bh 1794 * test/test_proj.py (TestProjection.test_get_projection_units_geo)
2175     (TestProjection.test_get_projection_units_normal): New. Tests for
2176     the Projection.GetProjectedUnits method
2177    
2178 jan 1792 2003-10-08 Jan-Oliver Wagner <[email protected]>
2179    
2180     * Thuban/Model/resource.py (get_user_proj_file): small bug-fix:
2181     Added missing 'val' parameter.
2182    
2183 bh 1788 2003-10-08 Bernhard Herzog <[email protected]>
2184    
2185 bh 1790 * Thuban/UI/projdialog.py (ProjFrame.__DoOnProjAvail): When the
2186     projection type of the currently selected projection is not known,
2187     i.e. there's no panel for it, use the UnknownProjPanel
2188     (ProjFrame.__DoOnProjChoice, ProjFrame._show_proj_panel): Split
2189     the actual replacing of the proj panel into the new method
2190     _show_proj_panel.
2191     (UnknownProjPanel): Add doc-string.
2192     (UnknownProjPanel._DoLayout): Insert a newline into the text so
2193     that the panel is not so wide.
2194    
2195     2003-10-08 Bernhard Herzog <[email protected]>
2196    
2197 bh 1788 * Thuban/Model/resource.py (read_proj_file): Return the warnings
2198     too. Update the doc-string
2199     (get_proj_files): Removed. It wasn't used anywhere
2200     (get_system_proj_files, get_system_proj_file): Rename to
2201     get_system_proj_file and return the ProjFile object and not a list
2202     of ProjFile objects. Update the callers.
2203     (get_user_proj_files, get_user_proj_file): Rename to
2204     get_user_proj_file return the ProjFile object and not a list of
2205     ProjFile objects. Update the callers.
2206     (ProjFileReader.__init__): New instance variable for the warnings.
2207     Rename the __pf ivar to projfile. Update the methods referring to
2208     __pf
2209     (ProjFileReader.end_projection): Catch any errors raised when
2210     instantiating the projection and record that as an error. The
2211     projection will not be in the final ProjFile object.
2212     (ProjFileReader.GetWarnings): New method to return the warnings.
2213    
2214     * Thuban/UI/projdialog.py (ProjFrame.show_warnings): New method to
2215     show the warnings from the projfile reader
2216     (ProjFrame._OnImport): Deal with any warnings returned by
2217     read_proj_file
2218     (ProjFrame.__FillAvailList): Deal with any warnings returned by
2219     get_system_proj_file or get_user_proj_file.
2220    
2221     * test/test_proj.py (TestProjFile.doTestRead): Check the warnings.
2222     (TestProjFileWithInvalidParameters.file_contents): New test cases
2223     to test whether read_proj_file handles invalid projection
2224     parameters correctly
2225     (TestProjFile.test_get_system_proj_file): New. Simple test for
2226     resource.get_system_proj_file
2227    
2228 bh 1785 2003-10-07 Bernhard Herzog <[email protected]>
2229    
2230     * test/test_derivedshapestore.py
2231     (TestDerivedShapeStoreExceptions.tearDown): Clear the session
2232     properly so that the temporary directories get deleted correctly
2233    
2234 bh 1773 2003-10-06 Bernhard Herzog <[email protected]>
2235    
2236 bh 1783 Handle the title changes in a proper MVC way.
2237    
2238     * Thuban/UI/mainwindow.py (MainWindow.__init__): Subscribe to the
2239     canvas' TITLE_CHANGED messages
2240     (MainWindow.update_title): New. Update the main window's title
2241     (MainWindow.__SetTitle): Removed. Use update_title instead.
2242     (MainWindow.SetMap): Use update_title instead of __SetTitle
2243     (MainWindow.RenameMap): Do change the window title explicitly
2244     here. That's handled in a proper MVC way now.
2245     (MainWindow.title_changed): New. Subscriber for the TITLE_CHANGED
2246     messages
2247    
2248     * Thuban/Lib/connector.py (Conduit): New class to help classes
2249     that forward messages
2250    
2251     * Thuban/UI/viewport.py: Forward the map's TITLE_CHANGED messages
2252     (ViewPort): Derive from Conduit instead of Publisher
2253     (ViewPort.Subscribe, ViewPort.Unsubscribe): Use the new base class
2254     when calling the inherited versions
2255     (ViewPort._subscribe_map, ViewPort._unsubscribe_map): New helper
2256     methods to subscribe and unsubscribe map messages
2257     (ViewPort.SetMap, ViewPort.Destroy): Use the new helper methods to
2258     handle the map subscriptions
2259     (ViewPort.Map, ViewPort.map_projection_changed)
2260     (ViewPort.layer_projection_changed): Add or update doc-strings
2261    
2262     * test/test_connector.py (TestPublisher.test_issue_simple): Fix
2263     typo
2264     (MyConduit): Helper class for the Conduit test.
2265     (TestConduit): Test cases for Conduit
2266    
2267     * test/test_connector.py: Use support.run_tests as main.
2268    
2269     * test/test_viewport.py (ViewPortTest.setUp): Also subscribe to
2270     the TITLE_CHANGED messages
2271     (ViewPortTest.test_forwarding_title_changed): New test to check
2272     whether the viewport forwards the map's TITLE_CHANGED messages
2273     (TestViewportWithPostGIS.tearDown): Call the map's Destroy method
2274     after the port's because the latter may require a still functional
2275     map.
2276    
2277     2003-10-06 Bernhard Herzog <[email protected]>
2278    
2279 bh 1777 * Thuban/UI/application.py (ThubanApplication.maps_changed): Add
2280     doc-string
2281    
2282     2003-10-06 Bernhard Herzog <[email protected]>
2283    
2284 bh 1775 * test/test_viewport.py (ViewPortTest.setUp)
2285     (SimpleViewPortTest.test_init_with_size): Move the test for the
2286     initial size as a constructor parameter from ViewPortTest.setUp
2287     method to a new separate test in SimpleViewPortTest.
2288    
2289     2003-10-06 Bernhard Herzog <[email protected]>
2290    
2291 bh 1773 * test/test_viewport.py (MockView): New class derived from
2292     ViewPort with a mock implementation of GetTextExtent to be used in
2293     the test cases
2294     (ViewPortTest.setUp): Use MockView instead of ViewPort
2295    
2296     * Thuban/UI/viewport.py (ViewPort.GetTextExtent): Turn this method
2297     into what would be a "pure virtual function" in C++: always raise
2298     NotImplementedError. Mock implementations for test cases don't
2299     belong into the real code
2300    
2301 bh 1770 2003-10-02 Bernhard Herzog <[email protected]>
2302    
2303     * test/test_layer.py (TestLayer.test_empty_layer): Explicitly
2304     close the dbf file we create so that it's contents have been
2305     written properly.
2306    
2307     * libraries/shapelib/shptree.c, libraries/shapelib/shpopen.c,
2308     libraries/shapelib/shapefil.h, libraries/shapelib/dbfopen.c:
2309     Update to shapelib 1.2.10
2310    
2311 jan 1767 2003-10-01 Jan-Oliver Wagner <[email protected]>
2312    
2313     * Thuban/UI/tree.py, Thuban/UI/main.py: Remove the #! line as
2314     it annoys lintian which warns about these files not being
2315     executable. The #! isn't necessary here since if you absolutely
2316     must execute them you can always say "python <filename>".
2317    
2318 bh 1757 2003-09-26 Bernhard Herzog <[email protected]>
2319    
2320 bh 1760 * Thuban/Model/classgen.py (GenQuantiles0): Removed since it's
2321     only used in GREAT-ER but not used in Thuban itself. When GREAT-ER
2322     is ported to a newer the import will fail, so it should be noticed
2323     immediately that this function is gone.
2324     Fixes RT#1919
2325    
2326     2003-09-26 Bernhard Herzog <[email protected]>
2327    
2328 bh 1757 Add a DTD for the projection files and make thuban write valid
2329     projection files
2330    
2331     * Resources/XML/projfile.dtd: New. DTD for thuban's projection
2332     files
2333    
2334     * Thuban/Model/resource.py (ProjFileSaver.write): Use
2335     'projectionlist' as the name in the document type declaration so
2336     that it matches the element type of the root element.
2337    
2338     * test/test_proj.py (sample_projfile, sample_projfile2): Use
2339     'projectionlist' as the name in the document type declaration just
2340     as it is done now in the files thuban would write
2341     (sample_projfile, sample_projfile_data): Fix spelling of
2342     "Mercator"
2343     (TestProjFile.doTestWrite): Validate the written and the expected
2344     XML data
2345     (TestProjFile): Derive from ValidationTest so that we can run xml
2346     validation tests
2347    
2348 bh 1751 2003-09-24 Bernhard Herzog <[email protected]>
2349    
2350     * Thuban/UI/renderer.py (ExportRenderer.render_legend): Do not
2351     modify the list returned by map.Layers() in place since it is the
2352     actual list of layers used by the map.
2353    
2354 jan 1745 2003-09-23 Jan-Oliver Wagner <[email protected]>
2355    
2356     * Doc/manual/thuban-manual.xml: Added subsection to chapter
2357     Extensions to describe the extensions coming with the Thuban
2358     standard package (gns2shp and importAPR).
2359    
2360 bh 1743 2003-09-23 Bernhard Herzog <[email protected]>
2361    
2362     * libraries/thuban/wxproj.cpp (project_point): if there's an
2363     inverse but no forward projection, convert to degrees after
2364     applying the inverse projection. Fixes RT#2096
2365    
2366     * test/test_wxproj.py: New. Test cases for wxproj.so. One test
2367     implicitly tests for the fix to RT#2096
2368    
2369     * test/support.py (FloatComparisonMixin.assertFloatSeqEqual):
2370     Check that the sequences have the same lengths
2371    
2372     * Resources/Projections/defaults.proj (Geographic projection): Use
2373     a much more precise value for the to_meter attribute.
2374    
2375 bh 1737 2003-09-22 Bernhard Herzog <[email protected]>
2376    
2377     * test/support.py (initthuban): Make sure to unset the LANG env.
2378     var. so that tests that compare translated strings work. Solves RT
2379     #2094
2380    
2381 jan 1730 2003-09-22 Jan-Oliver Wagner <[email protected]>
2382    
2383 jan 1735 Small improvement of APR import.
2384    
2385     * Extensions/importAPR/test/test_apr.py (aprTest.test_LClass):
2386     Added tests for text-ranges.
2387    
2388     * Extensions/importAPR/apr.py (APR_LClass.GetThubanRange): Now
2389     returns a string object if the range is based on text.
2390    
2391     * Extensions/importAPR/importAPR.py (import_apr_dialog): Unified
2392     range retrieval.
2393    
2394     2003-09-22 Jan-Oliver Wagner <[email protected]>
2395    
2396 jan 1730 Initial version of the importAPR extension which is in
2397     experimental state.
2398    
2399     * /Extensions/importAPR/, /Extensions/importAPR/samples/,
2400     /Extensions/importAPR/test/: New directories.
2401    
2402     * /Extensions/importAPR/samples/README: New: Howto load the samples.
2403    
2404     * /Extensions/importAPR/samples/iceland.apr: New: A sample APR
2405     file which refers to the Thuban Iceland demo data.
2406    
2407     * /Extensions/importAPR/test/README: New: Howto execute the tests.
2408    
2409     * /Extensions/importAPR/test/test_apr.py: New: Tests for APR classes.
2410    
2411     * /Extensions/importAPR/apr.py: New: Classes for ArcView Objects
2412     as in '.apr'-files.
2413    
2414     * /Extensions/importAPR/odb.py: New: Classes for generic ArcView
2415     ODB Objects as in '.apr', '.avl' and other files.
2416    
2417     * /Extensions/importAPR/__init__.py: New: Init to make this
2418     directory a package.
2419    
2420     * /Extensions/importAPR/importAPR.py: New: Import a ArcView
2421     project file (.apr) and convert it to Thuban.
2422    
2423     2003-09-22 Jan-Oliver Wagner <[email protected]>
2424    
2425     * Extensions/gns2shp.gns2shp.py: The main module of gns2shp.
2426    
2427 jan 1720 2003-09-19 Jan-Oliver Wagner <[email protected]>
2428    
2429     * Doc/manual/thuban-manual.xml: Extended section 'Installation'
2430     with description on RPM installation and RPM binary package
2431     creation.
2432    
2433 bh 1718 2003-09-18 Bernhard Herzog <[email protected]>
2434    
2435     * setup.py (data_files): Only add the mo files if the Locales
2436     directory actually exists, so that setup.py works with a fresh CVS
2437     checkout
2438    
2439 jan 1716 2003-09-12 Jan-Oliver Wagner <[email protected]>
2440    
2441     * Examples/simple_extensions/simple_tool.py: bugfix: Tool is now
2442     in viewport, not anymore in view
2443    
2444 jan 1714 2003-09-04 Jan-Oliver Wagner <[email protected]>
2445    
2446     Introducing first Extension (gns2shp).
2447    
2448     * Extensions, Extensions/gns2shp, Extensions/gns2shp/test: New.
2449    
2450     * Extensions/__init__.py: New. init to make this dir a package.
2451    
2452     * Extensions/gns2shp/__init__.py: New. init to make this dir a package.
2453    
2454     * Extensions/gns2shp/test/README: New. some info on this test directory.
2455    
2456     * Extensions/gns2shp/test/ls.txt: New. test data set (Liechtenstein).
2457    
2458     * Extensions/gns2shp/test/test_gns2shp.py: New. Test for correct creation
2459     of Shapefile from GNS text file format
2460    
2461 jan 1705 2003-09-03 Jan-Oliver Wagner <[email protected]>
2462    
2463 jan 1707 Fix/workaround for bug #2019:
2464     https://intevation.de/rt/webrt?serial_num=2019
2465    
2466     * Thuban/UI/identifyview.py (IdentifyView.ID_STOP): New.
2467     (IdentifyView.__init__): Added another button that allows to
2468     stop the identify mode.
2469     (IdentifyView.OnStop): New. Stops the identify mode.
2470    
2471     2003-09-03 Jan-Oliver Wagner <[email protected]>
2472    
2473 jan 1705 Introducing a new exception dialog that allows to exit the
2474     application immediately.
2475     This fixes bug #2060: https://intevation.de/rt/webrt?serial_num=2060
2476    
2477     * Thuban/UI/exceptiondialog.py: New. A special exception dialog.
2478    
2479     * Thuban/UI/application.py (ThubanApplication.ShowExceptionDialog):
2480     Made strings available to translations. Exchanged the simple
2481     ScrolledMessageDialog by the new ExceptionDialog.
2482    
2483 bh 1694 2003-09-01 Bernhard Herzog <[email protected]>
2484    
2485 bh 1701 * NEWS: New. Summary of changes and release notes.
2486    
2487     * MANIFEST.in: Add NEWS
2488    
2489     2003-09-01 Bernhard Herzog <[email protected]>
2490    
2491 bh 1699 * MANIFEST.in: Correct the include statement for the mo-files and
2492     include the documentation too.
2493    
2494     * setup.py (data_files): Add the .mo files
2495     (setup call): Up to version 0.9.0
2496    
2497     2003-09-01 Bernhard Herzog <[email protected]>
2498    
2499 bh 1696 * Thuban/UI/dbdialog.py (ChooseDBTableDialog.__init__): Change the
2500     parameter list to just parent and session
2501     (ChooseDBTableDialog.__set_properties): Removed. Setting the
2502     selection of empty list boxes is not allowed (and produces C++
2503     assertion errors) and the rest of the setup is better done in
2504     __init__ anyway.
2505     (ChooseDBTableDialog.OnCancel, ChooseDBTableDialog.OnOK)
2506     (ChooseDBTableDialog.OnLBDClick, DBDialog.OnOK): Use the Python
2507     builtins True/False for booleans to avoid warnings from wxPython
2508    
2509     * Thuban/UI/mainwindow.py (MainWindow.AddDBLayer): Adapt to new
2510     ChooseDBTableDialog constructor parameters.
2511    
2512     2003-09-01 Bernhard Herzog <[email protected]>
2513    
2514 bh 1694 * Thuban/Model/postgisdb.py
2515     (PostGISTable): Extend doc-string
2516     (PostGISTable._fetch_table_information): Set the column index
2517     correctly, pretending ignored columns don't exist.
2518    
2519     * test/test_postgis_db.py (TestPostGISIgnoredColumns): New tests
2520     for postgis tables with data types not yet supported by thuban.
2521    
2522 bh 1692 2003-08-29 Bernhard Herzog <[email protected]>
2523    
2524     * HOWTO-Release: Tweak item about running the tests.
2525    
2526 jan 1690 2003-08-29 Jan-Oliver Wagner <[email protected]>
2527    
2528     * /Doc/manual/thuban-manual.xml: updated to version 1.0pre2.
2529    
2530 bh 1688 2003-08-29 Bernhard Herzog <[email protected]>
2531    
2532     Add some missing parameters to projections. Proj complains about
2533     them on windows but for some reason not on Linux.
2534    
2535     * test/test_save.py (SaveSessionTest.testLayerProjection): Add
2536     missing required projection parameters
2537    
2538     * test/test_proj.py (TestProjFile.test): Add missing required
2539     projection parameters
2540    
2541     * test/test_load_0_8.py (TestLayerProjection.file_contents)
2542     (TestLayerProjection.test): Add missing required projection
2543     parameters and tests for them
2544    
2545     * test/test_load.py (TestLayerProjection.file_contents)
2546     (TestLayerProjection.test): Add missing required projection
2547     parameters and tests for them
2548    
2549     * test/test_layer.py (TestLayer.test_base_layer): Add missing
2550     required projection parameters
2551    
2552     2003-08-29 Bernhard Herzog <[email protected]>
2553    
2554     * libraries/pyprojection/Projection.i: Use pj_get_errno_ref to
2555     access the pj_errno because directly accessing pj_errno doesn't
2556     work on windows if the proj library is in a DLL
2557    
2558     * libraries/pyprojection/Projection_wrap.c: Update from Projection.i
2559    
2560 bh 1672 2003-08-28 Bernhard Herzog <[email protected]>
2561    
2562 bh 1685 * test/test_proj.py: Import things from Thuban after calling
2563     initthuban
2564    
2565     * test/test_load.py (LoadSessionTest.filenames): New class
2566     variable with the filename attributes to normalize
2567     (LoadSessionTest.check_format): Pass self.filenames to
2568     sax_eventlist to normalize the filename attributes
2569    
2570     * test/xmlsupport.py: Add cvs keywords
2571     (SaxEventLister.__init__): New parameter filenames which indicates
2572     attributes that contain filenames
2573     (SaxEventLister.startElementNS): Normalize the filename attributes
2574     with os.path.normpath
2575     (sax_eventlist): New parameter filenames to pass through to
2576     SaxEventLister
2577    
2578     * test/test_derivedshapestore.py: Make this file callable as a
2579     program to execute the tests
2580     (TestDerivedShapeStoreExceptions.test_table_with_wrong_size): Bind
2581     the session to self.session so that it gets destroyed properly
2582    
2583     * test/test_layer.py (TestLayer.tearDown): Call the session's
2584     Destroy method
2585    
2586     * test/test_map.py (TestMapBase.tearDown): Destroy self.session
2587     too if it exists
2588     (TestMapAddLayer.test_add_layer): Bind the session to self.session
2589     so that it gets destroyed properly
2590    
2591     * test/postgissupport.py (reason_for_not_running_tests): Add a
2592     test for the existence of popen2.Popen4.
2593    
2594     * test/test_save.py (SaveSessionTest.tearDown): New. Provide a
2595     reliable way to destroy the sessions created in the test cases
2596     (SaveSessionTest.test_dbf_table): Bind the session to self.session
2597     so that it gets destroyed properly
2598     (SaveSessionTest.testLayerProjection): Bind the session to
2599     self.session so that it gets destroyed properly
2600    
2601     * test/test_session.py (UnreferencedTablesTests.tearDown): Make
2602     sure that the session is destroyed properly
2603    
2604     * test/test_shapefilestore.py: Make this callable as a program to
2605     execute the tests
2606    
2607     * test/test_scalebar.py: Remove unnecessary import of _ from
2608     Thuban
2609    
2610     * test/support.py (print_garbage_information): Call initthuban
2611     here because it may be called indirectly from test cases that test
2612     test support modules which do not use anything from thuban itself
2613     (ThubanTestProgram.runTests): Remove unnecessary debug print
2614    
2615     2003-08-28 Bernhard Herzog <[email protected]>
2616    
2617 bh 1672 * Thuban/version.py (longversion): Update to 0.9
2618    
2619     * Thuban/UI/mainwindow.py: Remove some unused imports
2620    
2621     * README: Add section about required additional software. Add date
2622     and revision CVS keywords
2623    
2624     * HOWTO-Release: Add item about the translations. Add date and
2625     revision CVs keywords and change formatting to match README a bit
2626     better
2627    
2628     * po/de.po: Update for 0.9
2629    
2630     * test/README: Tweak the wording a little because many tests are
2631     not really unittest.
2632    
2633 bh 1663 2003-08-27 Bernhard Herzog <[email protected]>
2634    
2635 bh 1665 As preparation for the 0.9 release, switch thuban files to a
2636     non-dev namespace
2637    
2638     * Thuban/Model/save.py (SessionSaver.write_session): Write files
2639     with the http://thuban.intevation.org/dtds/thuban-0.9.dtd
2640     namespace
2641    
2642     * Thuban/Model/load.py (SessionLoader.__init__): Accept the
2643     http://thuban.intevation.org/dtds/thuban-0.9.dtd namespace too
2644    
2645     * test/test_save.py (SaveSessionTest.dtd)
2646     (SaveSessionTest.testEmptySession)
2647     (SaveSessionTest.testSingleLayer)
2648     (SaveSessionTest.testLayerProjection)
2649     (SaveSessionTest.testRasterLayer)
2650     (SaveSessionTest.testClassifiedLayer)
2651     (SaveSessionTest.test_dbf_table)
2652     (SaveSessionTest.test_joined_table)
2653     (SaveSessionTest.test_save_postgis): Update for new namespace
2654    
2655     * test/test_load.py (LoadSessionTest.dtd, TestSingleLayer)
2656     (TestLayerVisibility.file_contents, TestLabels.file_contents)
2657     (TestLayerProjection.file_contents)
2658     (TestRasterLayer.file_contents, TestJoinedTable.file_contents)
2659     (TestPostGISLayer.file_contents)
2660     (TestPostGISLayerPassword.file_contents)
2661     (TestLoadError.file_contents, TestLoadError.test): Update for new
2662     namespace
2663    
2664     2003-08-27 Bernhard Herzog <[email protected]>
2665    
2666 bh 1663 Make the table interface distinguish between row ids (an integer
2667     that uniquely identifies a row) and row ordinals (a simple row
2668     count from 0 to NumRows() - 1)
2669    
2670     * Thuban/Model/postgisdb.py (PostGISTable.RowIdToOrdinal)
2671     (PostGISTable.RowOrdinalToId): New methods to conver between row
2672     ids and row ordinals
2673     (PostGISTable.ReadRowAsDict, PostGISTable.ReadValue): New keyword
2674     parameter row_is_ordinal to indicate whether the row parameter is
2675     the row id or the ordinal
2676    
2677     * Thuban/Model/transientdb.py (TransientTableBase.RowIdToOrdinal)
2678     (TransientTableBase.RowOrdinalToId)
2679     (AutoTransientTable.RowIdToOrdinal)
2680     (AutoTransientTable.RowOrdinalToId): Same new methods as in
2681     PostGISTable.
2682     (TransientTableBase.ReadRowAsDict, TransientTableBase.ReadValue)
2683     (AutoTransientTable.ReadRowAsDict, AutoTransientTable.ReadValue):
2684     Same new parameter as in PostGISTable.
2685    
2686     * Thuban/Model/table.py (DBFTable.RowIdToOrdinal)
2687     (DBFTable.RowOrdinalToId, MemoryTable.RowIdToOrdinal)
2688     (MemoryTable.RowOrdinalToId): Same new methods as in PostGISTable.
2689     (DBFTable.ReadValue, DBFTable.ReadRowAsDict)
2690     (MemoryTable.ReadValue, MemoryTable.ReadRowAsDict): Same new
2691     parameter as in PostGISTable.
2692    
2693     * Thuban/UI/tableview.py (DataTable.RowIdToOrdinal)
2694     (DataTable.RowOrdinalToId): New methods to convert between row ids
2695     and row ordinals.
2696     (TableGrid.SelectRowById): New method to select a row based on its
2697     ID as opposed to its ordinal
2698     (DataTable.GetValue, TableGrid.OnRangeSelect)
2699     (TableGrid.OnSelectCell, LayerTableGrid.select_shapes)
2700     (QueryTableFrame.OnQuery, QueryTableFrame.get_selected)
2701     (LayerTableFrame.__init__): Convert between row ids and row
2702     ordinals as appropriate
2703    
2704     * test/postgissupport.py (PostGISDatabase.__init__): Add
2705     doc-string.
2706     (PostGISDatabase.initdb): The optional third item in a tuple in
2707     tables is now a (key, value) list with additional arguments to
2708     pass to upload_shapefile
2709     (upload_shapefile): New parameter gid_offset to allow gids that
2710     are not the same as the shapeids in the shapefile
2711     (PostgreSQLServer.get_default_static_data_db): Use the new
2712     gid_offset to make the gids in landmarks 1000 higher than the
2713     shapeids in the shapefile
2714    
2715     * test/test_viewport.py
2716     (TestViewportWithPostGIS.test_find_shape_at_point): Adapt to the
2717     new shapeids in the landmarks table
2718    
2719     * test/test_transientdb.py
2720     (TestTransientTable.run_iceland_political_tests)
2721     (TestTransientTable.test_transient_joined_table): Add tests for
2722     the new table methods and new keywords arguments.
2723    
2724     * test/test_postgis_db.py
2725     (TestPostGISTable.test_read_row_as_dict_row_count_mode)
2726     (TestPostGISTable.test_read_value_row_count_mode)
2727     (TestPostGISTable.test_row_id_to_ordinal)
2728     (TestPostGISTable.test_row_oridnal_to_id): New test for the new
2729     table methods and the new arguments
2730     (TestPostGISShapestorePoint.test_shapes_in_region)
2731     (TestPostGISShapestorePoint.test_shape_raw_data)
2732     (TestPostGISShapestorePoint.test_shape_points)
2733     (TestPostGISShapestorePoint.test_shape_shapeid)
2734     (TestPostGISShapestorePoint.test_all_shapes)
2735     (TestPostGISTable.test_simple_query)
2736     (TestPostGISTable.test_simple_query)
2737     (TestPostGISTable.test_simple_query)
2738     (TestPostGISTable.test_read_value)
2739     (TestPostGISTable.test_read_row_as_dict): Adapt to the new
2740     shapeids in the landmarks table
2741    
2742     * test/test_memory_table.py
2743     (TestMemoryTable.test_read_row_as_dict_row_count_mode)
2744     (TestMemoryTable.test_read_value_row_count_mode)
2745     (TestMemoryTable.test_row_id_to_ordinal)
2746     (TestMemoryTable.test_row_oridnal_to_id): New test for the new
2747     table methods and the new arguments
2748    
2749     * test/test_dbf_table.py
2750     (TestDBFTable.test_read_row_as_dict_row_count_mode)
2751     (TestDBFTable.test_read_value_row_count_mode)
2752     (TestDBFTable.test_row_id_to_ordinal)
2753     (TestDBFTable.test_row_oridnal_to_id): New test for the new table
2754     methods and the new arguments
2755    
2756 bh 1659 2003-08-26 Bernhard Herzog <[email protected]>
2757    
2758 bh 1661 * Thuban/Model/postgisdb.py (PostGISShapeStore.BoundingBox): Use a
2759     more postgis specific but much faster method to get the bounding
2760     box
2761    
2762     2003-08-26 Bernhard Herzog <[email protected]>
2763    
2764 bh 1659 * Thuban/Model/postgisdb.py (PostGISTable.Title)
2765     (PostGISShapeStore.AllShapes): Add these missing methods.
2766     (PostGISShapeStore.ShapesInRegion): No need to raise
2767     StopIteration. We can simply return
2768    
2769     * test/test_postgis_db.py (TestPostGISTable.test_title)
2770     (TestPostGISShapestorePoint.test_all_shapes): New tests for the
2771     new methods
2772    
2773 bh 1643 2003-08-25 Bernhard Herzog <[email protected]>
2774    
2775 bh 1657 * Thuban/Model/postgisdb.py (shapetype_map): Add MUTLIPOLYGON.
2776    
2777     * test/test_postgis_db.py (PolygonTests): New class containing
2778     those tests from TestPostGISShapestorePolygon that can also be
2779     used to test MUTLIPOLYGON tables
2780     (TestPostGISShapestorePolygon): Most tests are now in PolygonTests
2781     so derive from that
2782     (TestPostGISShapestoreMultiPolygon): New class with tests for
2783     MUTLIPOLYGON tables
2784    
2785     * test/postgissupport.py (PostGISDatabase.initdb): Allow the
2786     tables argument to have tuples with three items to override the
2787     WKT type used.
2788     (PostgreSQLServer.get_default_static_data_db): Use the above to
2789     create a polygon table with MUTLIPOLYGONs
2790     (point_to_wkt, coords_to_point, polygon_to_wkt, coords_to_polygon)
2791     (arc_to_wkt, coords_to_multilinestring): Rename from *_to_wkt to
2792     coords_to*
2793     (coords_to_multipolygon): New. Convert to MUTLIPOLYGON
2794     (wkt_converter): New. Map WKT types to converters
2795     (upload_shapefile): New parameter force_wkt_type to use a
2796     different WKT type than the default
2797    
2798     2003-08-25 Bernhard Herzog <[email protected]>
2799    
2800 bh 1655 * Thuban/UI/application.py
2801     (ThubanApplication.run_db_param_dialog): New. Suitable as a
2802     db_connection_callback. Main difference is that the dialog run
2803     from this method doesn't have a parent so it can be used even when
2804     there is no main window
2805     (ThubanApplication.OpenSession): Use self.run_db_param_dialog if
2806     no db_connection_callback was given. This way the dialog pops up
2807     even when the .thuban file was given as a command line parameter.
2808    
2809     2003-08-25 Bernhard Herzog <[email protected]>
2810    
2811 bh 1653 * Thuban/UI/view.py (MapCanvas.OnLeftUp): Release the the mouse
2812     before calling MouseLeftUp. MouseLeftUp may pop up modal dialogs
2813     which leads to an effectively frozen X session because the user
2814     can only interact with the dialog but the mouse is still grabbed
2815     by the canvas.
2816     Also, call the tool's Hide method before MouseLeftUp because
2817     MouseLeftUp may change the tool's coordinates.
2818    
2819     2003-08-25 Bernhard Herzog <[email protected]>
2820    
2821 bh 1651 * Thuban/UI/application.py (ThubanApplication.OpenSession): Catch
2822     LoadCancelled exceptions and handle them by returning immediately.
2823    
2824     2003-08-25 Bernhard Herzog <[email protected]>
2825    
2826 bh 1649 GUI part of loading sessions with postgis connections which may
2827     require user interaction to get passwords or updated parameters
2828    
2829     * Thuban/UI/dbdialog.py (DBDialog): Reimplement to make it look a
2830     bit nucer and be more generic.
2831     (DBFrame.OnAdd): Adapt to new DBDialog interface
2832    
2833     * Thuban/UI/application.py (ThubanApplication.OpenSession): New
2834     optional parameter db_connection_callback which is passed to
2835     load_session.
2836    
2837     * Thuban/UI/mainwindow.py (MainWindow.run_db_param_dialog): New.
2838     Suitable as a db_connection_callback
2839     (MainWindow.OpenSession): Use self.run_db_param_dialog as the
2840     db_connection_callback of the application's OpenSession method
2841    
2842    
2843     2003-08-25 Bernhard Herzog <[email protected]>
2844    
2845 bh 1647 Basic loading of sessions containing postgis connections:
2846    
2847     * Thuban/Model/load.py (LoadError): Add doc-string
2848     (LoadCancelled): New exception class to indicate a cancelled load
2849     (SessionLoader.__init__): Add the db_connection_callback parameter
2850     which will be used by the loader to get updated parameters and a
2851     password for a database connection
2852     (SessionLoader.__init__): Add the new XML elements to the
2853     dispatchers dictionary
2854     (SessionLoader.check_attrs): Two new conversions, ascii to convert
2855     to a byte-string object and idref as a generic id reference
2856     (SessionLoader.start_dbconnection)
2857     (SessionLoader.start_dbshapesource): New. Handlers for the new XML
2858     elements
2859     (load_session): Add the db_connection_callback to pass through the
2860     SessionLoader
2861    
2862     * test/test_load.py (TestPostGISLayer, TestPostGISLayerPassword):
2863     New classes to test loading of sessions with postgis database
2864     connections.
2865    
2866     2003-08-25 Bernhard Herzog <[email protected]>
2867    
2868 bh 1645 * Thuban/UI/mainwindow.py (__ThubanVersion__): Remove this and
2869     replace it and the comment with __BuildDate__ by the Source: and
2870     Id: cvs keywords as used in the other files.
2871    
2872     2003-08-25 Bernhard Herzog <[email protected]>
2873    
2874 bh 1643 * Thuban/Model/load.py (SessionLoader.check_attrs): Raise a
2875     LoadError when a required attribute is missing. The code used to
2876     be commented out for some reason, but probably should have been
2877     active.
2878    
2879     * test/test_load.py (TestLoadError.test): Test the message in the
2880     LoadError too to make sure it really is about the missing
2881     attribute
2882    
2883 bh 1632 2003-08-22 Bernhard Herzog <[email protected]>
2884 bh 1641
2885     * test/test_save.py (SaveSessionTest.test_dbf_table)
2886     (SaveSessionTest.test_joined_table): Add XML validation tests.
2887    
2888     2003-08-22 Bernhard Herzog <[email protected]>
2889    
2890 bh 1639 Implement saving a session with a postgis connection
2891 bh 1632
2892 bh 1639 * Resources/XML/thuban-0.9.dtd (dbconnection, dbshapesource) New
2893     elements for database connections and shapestores using db
2894     connections
2895     (session): Add the dbconnections to the content model
2896    
2897     * Thuban/Model/save.py (SessionSaver.write_db_connections): New.
2898     Write the db connections
2899     (SessionSaver.write_session): Call write_db_connections to write
2900     the connection before the data sources
2901     (SessionSaver.write_data_containers): Handle postgis shapestores
2902    
2903     * test/test_save.py (SaveSessionTest.thubanids)
2904     (SaveSessionTest.thubanidrefs): Update for new DTD
2905     (SaveSessionTest.test_save_postgis): New. Test saving a session
2906     with postgis connections
2907    
2908     * Thuban/Model/postgisdb.py (PostGISTable.DBConnection)
2909     (PostGISTable.TableName): New accessor methods for the connection
2910     and table name
2911    
2912     * test/test_postgis_db.py (TestPostGISTable.test_dbconn)
2913     (TestPostGISTable.test_dbname): New methods to test the new
2914     PostGISConnection methods
2915    
2916     2003-08-22 Bernhard Herzog <[email protected]>
2917    
2918 bh 1637 * Thuban/Model/postgisdb.py (ConnectionError): New exception class
2919     for exceptions occurring when establishing a Database connection
2920     (PostGISConnection.connect): Catch psycopg.OperationalError during
2921     connects and raise ConnectionError.
2922    
2923     * test/test_postgis_db.py (TestPostgisDBExceptions): New class for
2924     tests for database exceptions
2925    
2926     2003-08-22 Bernhard Herzog <[email protected]>
2927    
2928 bh 1635 Prepare the test suite for tests with required authentication
2929    
2930     * test/postgissupport.py (PostgreSQLServer.__init__): Add instance
2931     variables with two predefined users/passwords, one for the admin
2932     and one for a non-privileged user.
2933     (PostgreSQLServer.createdb): Pass the admin name to initdb and add
2934     the non-privileged user to the database and set the admin password
2935     (PostgreSQLServer.wait_for_postmaster): Use the admin user name.
2936     Better error reporting
2937     (PostgreSQLServer.connection_params)
2938     (PostgreSQLServer.connection_string): New methods to return
2939     information about how to connect to the server
2940     (PostgreSQLServer.execute_sql): New. Convenience method to execute
2941     SQL statements
2942     (PostgreSQLServer.require_authentication): Toggle whether the
2943     server requires authentication
2944     (PostgreSQLServer.create_user, PostgreSQLServer.alter_user): New.
2945     Add or alter users
2946     (PostGISDatabase.initdb): Pass the admin name one the
2947     subprocesses' command lines. Grant select rights on
2948     geometry_columns to everybody.
2949     (upload_shapefile): Use the admin name and password when
2950     connecting. Grant select rights on the new table to everybody.
2951    
2952     * test/test_viewport.py (TestViewportWithPostGIS.setUp): Use the
2953     server's new methods to get the connection parameters.
2954    
2955     * test/test_postgis_session.py (TestSessionWithPostGIS.setUp)
2956     (TestSessionWithPostGIS.test_remove_dbconn_exception): Use the
2957     server's new methods to get the connection parameters.
2958    
2959     * test/test_postgis_db.py
2960     (TestPostGISConnection.test_gis_tables_empty)
2961     (TestPostGISConnection.test_gis_tables_non_empty)
2962     (PostGISStaticTests.setUp): Use the server's new methods to get
2963     the connection parameters.
2964    
2965     2003-08-22 Bernhard Herzog <[email protected]>
2966    
2967 bh 1632 * Thuban/UI/about.py (About.__init__): Add the psycopg version.
2968    
2969     * Thuban/version.py: Add psycopg version
2970    
2971     * Thuban/Model/postgisdb.py (psycopg_version): New. Return the
2972     version of the psycopg module
2973    
2974     2003-08-22 Bernhard Herzog <[email protected]>
2975    
2976     * Thuban/UI/dbdialog.py (DBPwdDlg): Removed because it's not used.
2977     (DBFrame.OnEdit): Removed because it's not used and wouldn't work
2978     at the moment. The functionality should probably be implemented
2979     some time, though.
2980 bh 1633 (DBFrame.OnRemove): Display a message if the connection can't be
2981     removed because it's still in use.
2982 bh 1632
2983 jan 1629 2003-08-22 Jan-Oliver Wagner <[email protected]>
2984    
2985     * Thuban/UI/about.py (About.__init__): split up the huge about
2986     text into elements/lists for easier translation. This fixes bug
2987     https://intevation.de/rt/webrt?serial_num=2058
2988     Also, made some forgotten string available for the i18n.
2989    
2990 bh 1627 2003-08-21 Bernhard Herzog <[email protected]>
2991    
2992     Make postgis support really optional including insensitive menu
2993     items.
2994    
2995     * Thuban/Model/postgisdb.py (has_postgis_support): New. Return
2996     whether the postgis is supported.
2997    
2998     * Thuban/UI/dbdialog.py: Put the psycopg import into try..except
2999     to make postgis support optional
3000    
3001     * Thuban/UI/mainwindow.py (_has_postgis_support): New. Context
3002     version of Thuban.Model.postgisdb.has_postgis_support
3003     (database_management command): Make it only sensitive if postgis
3004     is supported.
3005    
3006 jan 1623 2003-08-21 Jan-Oliver Wagner <[email protected]>
3007    
3008 jan 1626 * Doc/manual/thuban-manual.xml: Added CVS revision for rev-history.
3009     (section Adding and Removing Layers): Added text and described
3010     multi-selection.
3011     (chapter Extensions): New.
3012    
3013     2003-08-21 Jan-Oliver Wagner <[email protected]>
3014    
3015 jan 1623 * Thuban/UI/mainwindow.py (MainWindow.AddLayer): Changed dialog
3016     settings to allow multiple files to load into the map.
3017     Also reduced selection to *.shp as a default.
3018    
3019 bh 1621 2003-08-20 Bernhard Herzog <[email protected]>
3020    
3021     Add dialogs and commands to open database connections and add
3022     database layers.
3023    
3024     * Thuban/UI/mainwindow.py (MainWindow.DatabaseManagement): New
3025     method to open the database connection management dialog
3026     (MainWindow.AddDBLayer): New method to add a layer from a database
3027     (_has_dbconnections): New helper function to use for sensitivity
3028     (database_management command, layer_add_db command): New commands
3029     that call the above new methods.
3030     (main_menu): Add the new commands to the menu.
3031    
3032     * Thuban/Model/postgisdb.py (PostGISConnection.__init__)
3033     (PostGISConnection.connect): Establish the actual connection in a
3034     separate method and call it in __init__. This makes it easier to
3035     override the behavior in test cases
3036     (PostGISConnection.BriefDescription): New method to return a brief
3037     description for use in dialogs.
3038    
3039     * test/test_postgis_db.py (NonConnection): DB connection that
3040     doesn't actually connect
3041     (TestBriefDescription): New class with tests for the new
3042     BriefDescription method
3043    
3044 jan 1619 2003-08-19 Jan-Oliver Wagner <[email protected]>
3045    
3046     Moved anything from extensions to libraries.
3047    
3048     * libraries: New.
3049    
3050     * libraries/ pyprojection, pyshapelib, shapelib, thuban: New.
3051    
3052     * libraries/pyprojection/ LICENSE, MANIFEST.in, Projection.i,
3053     Projection.py, Projection_wrap.c, setup.py, swighelp.txt: These files have
3054     been moved here from thuban/extensions/pyprojection/
3055     See there in the Attic for the older history.
3056    
3057     * libraries/pyshapelib/ COPYING, ChangeLog, NEWS, README, dbflib.i,
3058     dbflib.py, dbflib_wrap.c, pyshapelib_api.h, pytest.py, setup.py,
3059     shapelib.i, shapelib.py, shapelib_wrap.c, shptreemodule.c: These files
3060     have been moved here from thuban/extensions/pyshapelib/
3061     See there in the Attic for the older history.
3062    
3063     * libraries/shapelib/ dbfopen.c, shapefil.h, shpopen.c, shptree.c: These
3064     files have been moved here from thuban/extensions/shapelib/
3065     See there in the Attic for the older history.
3066    
3067     * libraries/thuban/ bmpdataset.cpp, cpl_mfile.cpp, cpl_mfile.h,
3068     gdalwarp.cpp, wxproj.cpp: These files have been moved here from
3069     thuban/extensions/thuban/
3070     See there in the Attic for the older history.
3071    
3072     * MANIFEST.in, setup.cfg, setup.py: renamed extensions to libraries.
3073    
3074     * extensions/thuban/ bmpdataset.cpp, cpl_mfile.cpp, cpl_mfile.h,
3075     gdalwarp.cpp, wxproj.cpp: Moved to libraries/thuban.
3076    
3077     * extensions/shapelib/ dbfopen.c, shapefil.h, shpopen.c, shptree.c:
3078     Moved to libraries/shapelib.
3079    
3080     * extensions/pyshapelib/ COPYING, NEWS, dbflib.py, pytest.py,
3081     shapelib.py, README, dbflib_wrap.c, setup.py, shapelib_wrap.c,
3082     ChangeLog, dbflib.i, pyshapelib_api.h, shapelib.i, shptreemodule.c:
3083     Moved to libraries/pyshapelib.
3084    
3085     * extensions/pyprojection/ MANIFEST.in, Projection.py, setup.py,
3086     LICENSE, Projection.i, Projection_wrap.c, swighelp.txt:
3087     Moved to libraries/pyprojection.
3088    
3089     * extensions/ pyprojection, pyshapelib, shapelib, thuban: Removed.
3090    
3091     * extensions: Removed.
3092    
3093 bh 1606 2003-08-19 Bernhard Herzog <[email protected]>
3094    
3095 bh 1609 * test/test_viewport.py (ViewPortTest): We don't use the
3096     facilities of FileTestMixin so don't derive from it.
3097     (TestViewportWithPostGIS): New class with tests for using a
3098     viewport on a map with postgis layers.
3099    
3100     2003-08-19 Bernhard Herzog <[email protected]>
3101    
3102     Add the db connection management to the session.
3103    
3104     * Thuban/Model/session.py (Session.__init__): New instance
3105     variable db_connections
3106     (Session.AddDBConnection, Session.DBConnections)
3107     (Session.HasDBConnections, Session.CanRemoveDBConnection)
3108     (Session.RemoveDBConnection): New methods to manage and query the
3109     db connections managed by the session
3110     (Session.OpenDBShapeStore): New method to open a shapestore from a
3111     db connection
3112    
3113     * Thuban/Model/messages.py (DBCONN_REMOVED, DBCONN_ADDED): New
3114     messages for the db connection handling in the session
3115    
3116     * test/test_postgis_session.py: New. test cases for the session's
3117     db connection handling with postgis connections
3118    
3119     2003-08-19 Bernhard Herzog <[email protected]>
3120    
3121 bh 1606 Add very basic postgis database support and the corresponding test
3122     cases. The test cases require a PostgreSQL + postgis installation
3123     but no existing database. The database will be created
3124     automatically by the test cases
3125    
3126     * test/README: Add note about skipped tests and the requirements
3127     of the postgis tests.
3128    
3129     * Thuban/Model/postgisdb.py: New. Basic postgis database support.
3130    
3131     * test/test_postgis_db.py: New. Test cases for the postgis
3132     support.
3133    
3134     * Thuban/Model/wellknowntext.py: New. Parser for well-known-text
3135     format
3136    
3137     * test/test_wellknowntext.py: New. Test cases for the
3138     wellknowntext parser
3139    
3140     * test/postgissupport.py: New. Support module for tests involving
3141     a postgis database.
3142    
3143     * test/support.py (execute_as_testsuite): Shut down the postmaster
3144     if it's still running after the tests
3145    
3146     * Thuban/Model/data.py (RAW_WKT): New constant for raw data in
3147     well known text format
3148    
3149 jan 1604 2003-08-19 Jan-Oliver Wagner <[email protected]>
3150    
3151     * Examples/simple_extensions/hello_world.py: New. Raises a Hello World
3152     message dialog.
3153    
3154 bh 1600 2003-08-18 Bernhard Herzog <[email protected]>
3155    
3156 bh 1602 * test/support.py (ThubanTestResult.printErrors): Indent the
3157     reason for the skips in the output to make it a bit more readable.
3158     (execute_as_testsuite): New helper function to run a test suite
3159     and print some more information.
3160     (run_tests): Use execute_as_testsuite to run the tests
3161    
3162     * test/runtests.py (main): Use execute_as_testsuite to run the
3163     tests
3164    
3165     2003-08-18 Bernhard Herzog <[email protected]>
3166    
3167 bh 1600 Fix some bugs in Thuban and the test suite that were uncovered by
3168     changes introduced in Python 2.3:
3169    
3170     * Thuban/Model/table.py (DBFTable.__init__): Make sure the
3171     filename is an absolute name
3172    
3173     * Thuban/Model/layer.py (RasterLayer.__init__): Make sure the
3174     filename is an absolute name
3175    
3176     * test/test_save.py (SaveSessionTest.testRasterLayer): Use a
3177     unique filename to save to and use the correct relative filename
3178     in the expected output.
3179     (SaveSessionTest.test_dbf_table): Use the correct relative
3180     filename in the expected output.
3181    
3182     * test/test_layer.py (TestLayer.test_raster_layer): Update the
3183     test to check whether the filename is absolute.
3184    
3185 jan 1596 2003-08-18 Jan-Oliver Wagner <[email protected]>
3186    
3187     * Thuban/UI/about.py (About.__init__): Added Silke Reimer.
3188    
3189 bh 1586 2003-08-15 Bernhard Herzog <[email protected]>
3190    
3191 bh 1594 Change the way shapes are returned by a shape store. The
3192     ShapesInRegion method returns an iterator over actual shape
3193     objects instead of a list of shape ids.
3194    
3195     * Thuban/Model/data.py (ShapefileShape.ShapeID): New. Return shape
3196     id.
3197     (ShapefileStore.ShapesInRegion): Return an iterator over the
3198     shapes which yields shape objects instead of returning a list of
3199     shape ids
3200     (ShapefileStore.AllShapes): New. Return an iterator over all
3201     shapes in the shape store
3202     (DerivedShapeStore.AllShapes): New. Like in ShapefileStore
3203    
3204     * Thuban/Model/layer.py (Layer.ShapesInRegion): Update
3205     doc-string.
3206    
3207     * Thuban/UI/baserenderer.py
3208     (BaseRenderer.layer_ids, BaseRenderer.layer_shapes): Rename to
3209     layer_shapes and make it return an iterator containg shapes
3210     instead of a list of ids.
3211     (BaseRenderer.draw_shape_layer): Update doc-string; Adapt to
3212     layer_shapes() change
3213    
3214     * Thuban/UI/renderer.py (ScreenRenderer.layer_ids)
3215     (ScreenRenderer.layer_shapes): Rename as in BaseRenderer
3216    
3217     * Thuban/UI/viewport.py (ViewPort._find_shape_in_layer): Adapt to
3218     changes in the ShapesInRegion return value.
3219     (ViewPort._get_hit_tester): Remove commented out code
3220    
3221     * test/mockgeo.py (SimpleShapeStore.ShapesInRegion): Adapt to the
3222     new return value.
3223     (SimpleShapeStore.AllShapes): New. Implement this method too.
3224    
3225     * test/test_layer.py (TestLayer.test_arc_layer)
3226     (TestLayer.test_polygon_layer, TestLayer.test_point_layer)
3227     (TestLayer.test_point_layer_with_projection)
3228     (TestLayer.test_derived_store): Adapt to changes in the
3229     ShapesInRegion return value.
3230    
3231     * test/test_shapefilestore.py
3232     (TestShapefileStoreArc.test_shapes_in_region)
3233     (TestShapefileStorePolygon.test_shapes_in_region)
3234     (TestShapefileStorePoint.test_shapes_in_region): Adapt to changes
3235     in the ShapesInRegion return value.
3236     (TestShapefileStorePoint.test_all_shapes)
3237     (TestShapefileStoreArc.test_shape_shapeid): New tests for the new
3238     methods
3239    
3240     * test/test_derivedshapestore.py
3241     (TestDerivedShapeStore.test_shapes_in_region): Adapt to changes in
3242     the ShapesInRegion return value.
3243     (TestDerivedShapeStore.test_all_shapes)
3244     (TestDerivedShapeStore.test_shape_shapeid): New tests for the new
3245     methods
3246    
3247     2003-08-15 Bernhard Herzog <[email protected]>
3248    
3249 bh 1592 Make the renderers deal correctly with raw vs. python level
3250     representation of shape geometries
3251    
3252     * Thuban/UI/baserenderer.py (BaseRenderer.low_level_renderer):
3253     Return a flag useraw in addition to the callable and the parameter
3254     to indicate whether the callable can deal with the raw shape data
3255     or uses the higher level python lists of coordinates. The callable
3256     now should accept either the raw data or the return value of the
3257     shape's Points() method.
3258     (BaseRenderer.draw_shape_layer): Adapt to the low_level_renderer
3259     change
3260     (BaseRenderer.projected_points): Instead of the shape id use the
3261     points list as parameter.
3262     (BaseRenderer.draw_polygon_shape, BaseRenderer.draw_arc_shape)
3263     (BaseRenderer.draw_point_shape): Adapt to projected_points()
3264     change and accept the points list as parameter instead of the
3265     shape id.
3266    
3267     * Thuban/UI/renderer.py (MapRenderer.low_level_renderer): Return
3268     the useraw flag as required by the BaseRenderer
3269     (ScreenRenderer.draw_shape_layer): Adapt to low-level renderer
3270     changes.
3271    
3272     * test/test_baserenderer.py
3273     (TestBaseRenderer.test_point_with_classification): New test for
3274     rendering a map with classifications.
3275    
3276     2003-08-15 Bernhard Herzog <[email protected]>
3277    
3278 bh 1590 * Thuban/UI/viewport.py (ViewPort.find_shape_at)
3279     (ViewPort._find_shape_in_layer, ViewPort._find_shape_in_layer)
3280     (ViewPort._get_hit_tester, ViewPort.projected_points)
3281     (ViewPort._hit_point, ViewPort._hit_arc, ViewPort._hit_polygon)
3282     (ViewPort._find_label_at): Split the find_shape_at method into
3283     several new methods and use the functions in the hit-test module.
3284    
3285     * Thuban/UI/hittest.py: New module with Python-level hit-testing
3286     functions
3287    
3288     * test/test_hittest.py: New. Test for the new hittest module
3289    
3290     2003-08-15 Bernhard Herzog <[email protected]>
3291    
3292 bh 1588 * Thuban/Model/layer.py (Layer.ShapesInRegion): Apply the layer
3293     projection to all corners of the bounding box to get a better
3294     approximation of the projected bounding box
3295    
3296     * test/test_layer.py (TestLayer.test_point_layer_with_projection):
3297     New. Test coordinate handling of a layer with a projection.
3298     Catches the bug fixed in Layer.ShapesInRegion
3299    
3300     2003-08-15 Bernhard Herzog <[email protected]>
3301    
3302 bh 1586 Move some of the mock objects in test_baserenderer into their own
3303     module so they can easily be used from other tests
3304    
3305     * test/mockgeo.py: New test helper module with some mock objects
3306     for geometry related things like shapes, shapestores and
3307     projections.
3308    
3309     * test/test_mockgeo.py: New. Tests for the new helper module
3310    
3311     * test/test_baserenderer.py: Some of the mock-objects are in
3312     mockgeo now.
3313    
3314 jan 1584 2003-08-12 Jan-Oliver Wagner <[email protected]>
3315    
3316     * Thuban/UI/about.py (About.__init__): Added Björn Broscheit.
3317    
3318 bh 1580 2003-08-12 Bernhard Herzog <[email protected]>
3319    
3320 bh 1582 * po/de.po: New. German translations by Bjoern Broscheit
3321    
3322     2003-08-12 Bernhard Herzog <[email protected]>
3323    
3324 bh 1580 * Thuban/UI/projdialog.py (UnknownProjPanel._DoLayout): Translated
3325     strings have to be one string literal.
3326    
3327 bh 1573 2003-08-11 Bernhard Herzog <[email protected]>
3328    
3329 bh 1578 * test/support.py (FloatComparisonMixin.assertPointListEquals):
3330     New. This method was used in various derived classes, but it's
3331     better to have it here.
3332    
3333     * test/test_shapefilestore.py
3334     (ShapefileStoreTests.assertPointListEquals): Removed. It's now in
3335     FloatComparisonMixin
3336    
3337     * test/test_layer.py (TestLayer.assertPointListEquals): Removed.
3338     It's now in FloatComparisonMixin
3339    
3340     * test/test_derivedshapestore.py
3341     (TestDerivedShapeStore.assertPointListEquals): Removed. It's now
3342     in FloatComparisonMixin
3343    
3344     2003-08-11 Bernhard Herzog <[email protected]>
3345    
3346 bh 1573 * Thuban/UI/join.py (JoinDialog.OnJoin): Add missing space to
3347     error message
3348    
3349 jan 1569 2003-08-08 Jan-Oliver Wagner <[email protected]>
3350    
3351 jan 1571 * Doc/manual/thuban-manual.xml: Now use authorgroup. Added revhistory
3352     with version number.
3353     Changed title to reflect version number of Thuban.
3354    
3355     2003-08-08 Jan-Oliver Wagner <[email protected]>
3356    
3357 jan 1569 * Thuban/UI/about.py (About.__init__): Reworked the hall of fame. Now
3358     the list corresponds to the "About" web page.
3359    
3360 bh 1567 2003-08-08 Bernhard Herzog <[email protected]>
3361    
3362     * Thuban/UI/projdialog.py (UTMProposeZoneDialog.dialogLayout):
3363     Make sure translated strings are recognized as one string literal.
3364    
3365     * Thuban/UI/proj4dialog.py (UTMProposeZoneDialog.dialogLayout):
3366     Make sure translated strings are recognized as one string literal.
3367    
3368     * Thuban/UI/classgen.py (ClassGenDialog.OnOK): Make sure
3369     translated strings are recognized as one string literal.
3370    
3371     * Thuban/UI/application.py (ThubanApplication.OpenSession): Make
3372     sure translated strings are recognized as one string literal.
3373    
3374 bh 1556 2003-08-07 Bernhard Herzog <[email protected]>
3375    
3376 bh 1565 * Thuban/Model/data.py (DerivedShapeStore.RawShapeFormat): New.
3377     Simply delegates to the original shapestore.
3378    
3379     * test/test_derivedshapestore.py
3380     (TestDerivedShapeStore.test_raw_format): New. Test case for
3381     DerivedShapeStore.RawShapeFormat
3382    
3383     2003-08-07 Bernhard Herzog <[email protected]>
3384    
3385 bh 1561 Add raw data interface to shape objects.
3386    
3387     * Thuban/Model/data.py (ShapefileShape, Shape): Rname the shape
3388     class to ShapefileShape which now holds shapefile specific
3389     information.
3390     (ShapefileShape.compute_bbox): Simplified to not cache any
3391     information. The way this method is used that shouldn't matter
3392     performance wise.
3393     (ShapefileShape.RawData): New. Return the shapeid which is the raw
3394     data format for shapes from shapefiles.
3395     (ShapefileStore.RawShapeFormat): New. Return the raw datatype used
3396     in the shape objects returned by a shapestore. For a
3397     ShapefileStore this is always RAW_SHAPEFILE.
3398     (RAW_PYTHON, RAW_SHAPEFILE): Constants for the RawShapeFormat
3399     method.
3400    
3401     * test/test_shapefilestore.py
3402     (TestShapefileStore.test_raw_format): New test to test the raw
3403     format feature of shapes.
3404    
3405 bh 1560 * Thuban/Model/layer.py: Remove the unused import of Shape from
3406     data. It was only there for interface compatibility but it's not
3407 bh 1561 used inside of Thuban and the generic Shape class has gone away.
3408 bh 1560
3409 bh 1563 * Thuban/UI/renderer.py (MapRenderer.low_level_renderer): Check
3410     the raw data format and only use an optimized version of its a
3411     shapefile.
3412    
3413 bh 1561 2003-08-07 Bernhard Herzog <[email protected]>
3414    
3415 bh 1559 * test/test_baserenderer.py (SimpleShape): Shape class for the
3416     tests.
3417     (SimpleShapeStore.Shape): Use SimpleShape instead of
3418     Thuban.Model.data.Shape to make the tests independed of the coming
3419     changes.
3420    
3421     2003-08-07 Bernhard Herzog <[email protected]>
3422    
3423 bh 1556 * test/support.py (SkipTest, ThubanTestResult, ThubanTestRunner)
3424     (ThubanTestProgram): New classes that extend the respective
3425     classes from unittest. These new version support skipping tests
3426     under certain expected conditions. In the Thuban test suite we
3427     uses this for tests that require the optional gdal support.
3428     (run_tests): Use ThubanTestProgram instead of the unittest.main()
3429    
3430     * test/runtests.py (main): Use the new ThubanTestRunner instead of
3431     the normal one from unittest
3432    
3433     * test/test_layer.py (TestLayer.test_raster_layer): If this test
3434     is not run because gdal support isn't available report this to the
3435     runner.
3436    
3437     * test/test_baserenderer.py
3438     (TestBaseRenderer.test_raster_no_projection): Do not run this test
3439     if gdal support isn't available and report this to the runner.
3440    
3441 bh 1553 2003-08-06 Bernhard Herzog <[email protected]>
3442    
3443     Rearrange the renderers a bit, partly in preparation for changes
3444     required for the postgis merge, partly to make it more testable.
3445     Also make the representation of coordinates in Shapes more
3446     consistent.
3447    
3448     * Thuban/UI/renderer.py (MapRenderer): Most of the code/methods in
3449     this class is now in BaseRenderer. This class is now practically
3450     only a specialization of BaseRenderer for rendering to an actual
3451     wx DC.
3452     (ScreenRenderer.draw_shape_layer): Use self.low_level_renderer()
3453     to get the shapetype specific rendering functions.
3454    
3455     * Thuban/UI/baserenderer.py: New file with the basic rendering
3456     logic. The code in this file is completely independend of wx.
3457     (BaseRenderer): Class with the basic rendering logic
3458    
3459     * test/test_baserenderer.py: New. Test cases for BaseRenderer
3460    
3461     * Thuban/UI/view.py (MapCanvas.__init__): New instance variable
3462     error_on_redraw to guard agains endless loops and stack overflows
3463     when there's a bug in the rendering code that raises exceptions.
3464     (MapCanvas.OnIdle, MapCanvas._do_redraw): Split the actual
3465     rendering into a separate method _do_redraw so that error handling
3466     is a bit easier. When an exception occurs, set error_on_redraw to
3467     true. When it's true on entry to OnIdle do nothing and return
3468     immediately.
3469    
3470     * Thuban/Model/data.py (ShapefileStore.Shape): For consistency, a
3471     Shape object will always have the coordinates as a list of list of
3472     coordinate pairs (tuples).
3473     (Shape.compute_bbox): Adapt to new representation.
3474    
3475     * Thuban/UI/viewport.py (ViewPort.find_shape_at)
3476     (ViewPort.LabelShapeAt): Adapt to new coordinate representation in
3477     Shape objects.
3478    
3479     * test/test_shapefilestore.py
3480     (ShapefileStoreTests.assertFloatTuplesEqual)
3481     (ShapefileStoreTests.assertPointListEquals): Rename to
3482     assertPointListEquals and change purpose to checking equality of
3483     the lists returned by Shape.Points().
3484     (TestShapefileStoreArc.test_shape)
3485     (TestShapefileStorePolygon.test_shape)
3486     (TestShapefileStorePoint.test_shape): Use the new
3487     assertPointListEquals instead of assertFloatTuplesEqual
3488    
3489     * test/test_layer.py (TestLayer.assertFloatTuplesEqual)
3490     (TestLayer.assertPointListEquals): Rename to assertPointListEquals
3491     and change purpose to checking equality of the lists returned by
3492     Shape.Points().
3493     (TestLayer.test_arc_layer, TestLayer.test_arc_layer)
3494     (TestLayer.test_polygon_layer, TestLayer.test_point_layer)
3495     (TestLayer.test_derived_store): Use the new assertPointListEquals
3496     instead of assertFloatTuplesEqual
3497    
3498     * test/test_derivedshapestore.py
3499     (TestDerivedShapeStore.assertFloatTuplesEqual)
3500     (TestDerivedShapeStore.assertPointListEquals): Rename to
3501     assertPointListEquals and change purpose to checking equality of
3502     the lists returned by Shape.Points().
3503     (TestDerivedShapeStore.test_shape): Use the new
3504     assertPointListEquals instead of assertFloatTuplesEqual
3505    
3506 jan 1550 2003-08-06 Jan-Oliver Wagner <[email protected]>
3507    
3508     * Thuban/UI/projdialog.py (UTMPanel._OnPropose): Added test for
3509     a bounding box. A dialog is raised in case, no bounding box
3510     is found. This fixes bug #2043:
3511     https://intevation.de/rt/webrt?serial_num=2043
3512    
3513 bh 1548 2003-08-05 Bernhard Herzog <[email protected]>
3514    
3515     * Thuban/Model/color.py (Color.__repr__): Make the repr of a color
3516     object look like a Color instantiation. Formerly it looked like a
3517     tuple.
3518    
3519     * test/test_color.py (TestColor.test_repr)
3520     (TestColor.test_equality, TestColor.test_inequality): New. test
3521     some more apects of the Color class
3522     (TestTransparent.test_repr, TestTransparent.test_hex)
3523     (TestTransparent.test_equality): New. Test cases for the
3524     Transparent object.
3525    
3526 jan 1545 2003-08-04 Jan-Oliver Wagner <[email protected]>
3527    
3528     * Doc/manual/thuban-manual.xml: a number of small improvements.
3529     The resulting file is the version submitted for GREAT-ER II.
3530    
3531 bh 1540 2003-08-01 Bernhard Herzog <[email protected]>
3532    
3533 bh 1543 * Thuban/UI/resource.py, Thuban/UI/projdialog.py,
3534     Thuban/UI/join.py, Thuban/UI/classgen.py, Thuban/UI/about.py,
3535     Thuban/Model/resource.py: Insert cvs keywords and doc-strings.
3536    
3537     * Thuban/UI/common.py: Insert cvs keywords and doc-strings.
3538     (Color2wxColour, wxColour2Color, ThubanBeginBusyCursor)
3539     (ThubanEndBusyCursor): Add doc-strings
3540    
3541     2003-08-01 Bernhard Herzog <[email protected]>
3542    
3543 bh 1540 First step towards PostGIS integration. More abstraction by movin
3544     more code from the layer to the shapestore. More methods of the
3545     layer are now simply delegated to the equivalent method of the
3546     shapestore. The SHAPETYPE_* constants are now in data not in
3547     layer.
3548    
3549     * Thuban/Model/data.py (SHAPETYPE_POLYGON, SHAPETYPE_ARC)
3550     (SHAPETYPE_POINT, Shape): Move these constants and classes from
3551     layer.py to data.py
3552     (ShapefileStore.__init__): More Initialization for the new methods
3553     and functionality.
3554     (ShapefileStore.ShapeType, ShapefileStore.NumShapes)
3555     (ShapefileStore.BoundingBox, ShapefileStore.ShapesInRegion)
3556     (ShapefileStore.Shape): New methods that were formerly implemented
3557     in the layer.
3558     (DerivedShapeStore.Shape, DerivedShapeStore.ShapesInRegion)
3559     (DerivedShapeStore.ShapeType, DerivedShapeStore.NumShapes)
3560     (DerivedShapeStore.BoundingBox): New. DerivedShapeStore
3561     equivalents of the new shape methods. These versions are simply
3562     delegated to the original shapstore.
3563    
3564     * Thuban/Model/layer.py (SHAPETYPE_POLYGON, SHAPETYPE_ARC)
3565     (SHAPETYPE_POINT, Shape): Removed. They're now in data.py
3566     (Layer.SetShapeStore): Removed the initializatin of instance
3567     variables that were needed for the stuff that's now in
3568     ShapefileStore
3569     (Layer.BoundingBox, Layer.NumShapes, Layer.ShapeType)
3570     (Layer.Shape, Layer.ShapesInRegion): Simply delegate to the
3571     shapestore.
3572    
3573     * Thuban/UI/classifier.py, Thuban/UI/renderer.py,
3574     Thuban/UI/viewport.py: Import the SHAPETYPE_* constants from data
3575     instead of layer.
3576    
3577     * test/test_shapefilestore.py: New. Tests for ShapefileStore.
3578    
3579     * test/test_derivedshapestore.py: New. Tests for DerivedShapeStore.
3580    
3581     * test/test_layer.py: Import the SHAPETYPE_* constants from data
3582     instead of layer.
3583     (TestLayer.test_derived_store): Remove the test for the exception
3584     when instantiating the DerivedShapeStore with an incompatible
3585     table which is now in test_derivedshapestore.py. Add some more
3586     tests of the layer methods to determine whether they work for a
3587     DerivedShapeStore as well.
3588    
3589 jonathan 1534 2003-07-31 Jonathan Coles <[email protected]>
3590    
3591     * Doc/manual/thuban-manual.xml: Fix the list of required packages
3592     by just listing the name and where they can be found.
3593    
3594 frank 1532 2003-07-31 Frank Koormann <[email protected]>
3595    
3596     * Doc/manual/thuban-manual.xml:
3597     Changed the screenshot elements to figure.
3598     Changed some variablelist elements to itemizedlist.
3599     Added section on GDAL formats.
3600    
3601 jonathan 1531 2003-07-31 Jonathan Coles <[email protected]>
3602    
3603     * Doc/manual/thuban-manual.xml: Added a few sentences about
3604     the Fix Border Color option when generating classes.
3605    
3606 jonathan 1529 2003-07-30 Jonathan Coles <[email protected]>
3607    
3608     * Thuban/Model/classgen.py: Add docstrings. Rename specific
3609     Ramp instances to use lower_case_style.
3610    
3611     * Thuban/UI/classgen.py: Use renamed Ramp instances.
3612    
3613     * Thuban/UI/classifier.py: Add docstrings.
3614    
3615     * Thuban/UI/dock.py: Add docstrings.
3616    
3617     * test/test_classgen.py: Use renamed Ramp instances.
3618    
3619 bh 1522 2003-07-30 Bernhard Herzog <[email protected]>
3620    
3621 bh 1524 * Thuban/Lib/connector.py (QueueingPublisher): Removed. This class
3622     was never used in Thuban.
3623    
3624     2003-07-30 Bernhard Herzog <[email protected]>
3625    
3626 bh 1522 * Thuban/UI/join.py (JoinDialog.__init__): Use the table's Title()
3627     method directly instead of going through the transient_table
3628     method. This faster because transient_table may force the copy of
3629     a DBF file into the transient database and setting a table's title
3630     doesnm't affect the title of the associated transient table, so
3631     this fixes RT #2042
3632    
3633     * Thuban/UI/main.py (__version__): Don't import the already
3634     removed show_exception_dialog.
3635    
3636 jonathan 1517 2003-07-29 Jonathan Coles <[email protected]>
3637    
3638 jonathan 1519 * Thuban/UI/application.py (ThubanApplication.ShowExceptionDialog):
3639     Put back this method and remove the equivalent function since we
3640     are setting the exception hook from within this class (OnInit).
3641    
3642     2003-07-29 Jonathan Coles <[email protected]>
3643    
3644 jonathan 1517 * Doc/manual/images/5_2_custom_ramp.png,
3645     Doc/manual/images/5_2_quantiles.png,
3646     Doc/manual/images/5_2_uniform_dist.png,
3647     Doc/manual/images/5_2_unique_values.png,
3648     Doc/manual/images/8_int_error.png: New screen shots.
3649    
3650     * Doc/manual/thuban-manual.xml: Fixed typos and wording, clarified
3651     some points, and added more screen shots.
3652    
3653 bh 1512 2003-07-29 Bernhard Herzog <[email protected]>
3654    
3655 bh 1516 * Thuban/Model/data.py: Remove the now unused import of warnings
3656    
3657     2003-07-29 Bernhard Herzog <[email protected]>
3658    
3659 bh 1514 * Thuban/Model/data.py (SimpleStore): Removed. This class has been
3660     deprecated since before the 0.8 release and isn't used in Thuban
3661     itself anymore.
3662    
3663 bh 1512 * Thuban/Model/transientdb.py: Remove some unnecessary imports
3664    
3665 jonathan 1503 2003-07-29 Jonathan Coles <[email protected]>
3666 jonathan 1506
3667     * Thuban/UI/application.py (ThubanApplication.OnInit): set the
3668     python exception hook here so that we are sure to catch any
3669     Thuban exception that happen during initialization.
3670    
3671     * Thuban/UI/main.py (main): Don't set the exception hook here,
3672     it will get set in ThubanApplication.OnInit.
3673    
3674     2003-07-29 Jonathan Coles <[email protected]>
3675 jonathan 1503
3676     * Thuban/UI/application.py (ThubanApplication.ShowExceptionDialog):
3677     Removed and called it show_exception_dialog() so that the exception
3678     handler can be set before the class is created.
3679    
3680     * Thuban/UI/main.py (main): Install the exception handler before
3681     a ThubanApplication is created.
3682    
3683 bh 1500 2003-07-29 Bernhard Herzog <[email protected]>
3684    
3685     * po/it.po: New. Italian translation by Maurizio Napolitano
3686    
3687     * po/ru.po: New. Russian translation by Alex Shevlakov
3688    
3689 frank 1497 2003-07-29 Frank Koormann <[email protected]>
3690    
3691 frank 1508 * Doc/manual/thuban-manual.xml: Extended section on supported
3692     projections.
3693    
3694     2003-07-29 Frank Koormann <[email protected]>
3695    
3696 frank 1497 * Doc/manual/thuban-manual.xml: gaspell-checked.
3697    
3698 jonathan 1493 2003-07-29 Jonathan Coles <[email protected]>
3699    
3700 jonathan 1495 * Doc/manual/images/3_5_legend.png: Added border to improve look
3701     on white background.
3702    
3703     2003-07-29 Jonathan Coles <[email protected]>
3704    
3705 jonathan 1493 * Doc/manual/thuban-manual.xml: Fixed grammar and typos. Added
3706     descriptions for the legend toolbar.
3707    
3708     * Doc/manual/images/4_2_raster_layer_properties.png: Removed
3709     cursor from dialog box.
3710    
3711     2003-07-28 Jonathan Coles <[email protected]>
3712    
3713     * Doc/manual/thuban-manual.xml: More screenshots and more chapters.
3714    
3715     * Doc/manual/images/2_4_session_tree.png,
3716     Doc/manual/images/3_5_legend.png, Doc/manual/images/3_rename_map.png,
3717     Doc/manual/images/4_2_layer_properties.png,
3718     Doc/manual/images/4_2_raster_layer_properties.png,
3719     Doc/manual/images/5_3_genclass.png,
3720     Doc/manual/images/5_classification.png,
3721     Doc/manual/images/6_projection.png,
3722     Doc/manual/images/7_1_table_view.png,
3723     Doc/manual/images/7_2_5_join.png: New screenshots.
3724    
3725     2003-07-24 Jonathan Coles <[email protected]>
3726    
3727     * Doc/manual/thuban-manual.xml: Chapter on Projection Management.
3728    
3729     2003-07-24 Jonathan Coles <[email protected]>
3730    
3731     * Doc/manual/thuban-manual.xml: Added EPS images and wrote
3732     chapter on Layer Management.
3733    
3734     * Doc/manual/Makefile: New. Makefile to generate all formats for the
3735     manual and images.
3736    
3737 bh 1483 2003-07-24 Bernhard Herzog <[email protected]>
3738    
3739     * Thuban/Model/range.py, Thuban/version.py: Remove the #! line as
3740     it annoys lintian which warns about these files not being
3741 jan 1767 executable. The #! isn't necessary here since if you absolutely
3742 bh 1483 must execute them you can always say "python <filename>".
3743    
3744     * Thuban/UI/renderer.py (ScreenRenderer.draw_shape_layer): Remove
3745     superfluous code to set brush and pen for point shapes
3746    
3747     * Thuban/UI/viewport.py: Remove commented out code that wouldn't
3748     belong in viewport anyway
3749    
3750 frank 1479 2003-07-24 Frank Koormann <[email protected]>
3751    
3752     * Doc/manual/thuban-manual.xml: Added section on table management.
3753    
3754 bh 1477 2003-07-24 Bernhard Herzog <[email protected]>
3755    
3756     * test/runtests.py (main): Recognize the long "verbose" option
3757     correctly.
3758    
3759 jonathan 1470 2003-07-22 Jonathan Coles <[email protected]>
3760    
3761     * Doc/manual/thuban-manual.xml: Continue to write first revision
3762     of the manual.
3763    
3764     * Thuban/UI/renderer.py (MapRenderer.render_map): Wrap method
3765     with Begin/EndDrawing() calls to ensure we aren't doing to
3766     many updates to the dc during rendering.
3767     (ScreenRenderer.draw_shape_layer): self.draw_point_shape takes
3768     a pen and brush argument so they need to be passed to the function.
3769    
3770     * Thuban/UI/viewport.py (ViewPort.calc_min_max_scales): New.
3771     Calculates the minimum and maximum scale values. Factored out
3772     of set_view_transform so that it could be used to zoom all the
3773     way into a single point.
3774     (ViewPort.set_view_transform): Call calc_min_max_scales().
3775     (ViewPort.FitSelectedToWindow): Zoom to the maximum scale
3776     if only a single point is selected.
3777    
3778     * Doc/manual/images/1_2_legend_close.png,
3779     Doc/manual/images/1_2_legend_dock.png,
3780     Doc/manual/images/1_2_mainwindow.png,
3781     Doc/manual/images/1_2_mainwindow.ps,
3782     Doc/manual/images/1_2_mainwindow.sk,
3783     Doc/manual/images/3_2_fullextent.png,
3784     Doc/manual/images/3_2_fulllayerextent.png,
3785     Doc/manual/images/3_2_fullshapeextent.png,
3786     Doc/manual/images/3_2_pan.png,
3787     Doc/manual/images/3_2_zoomin.png,
3788     Doc/manual/images/3_2_zoomout.png,
3789     Doc/manual/images/3_3_identify.png,
3790     Doc/manual/images/3_3_label.png,
3791     Doc/manual/images/3_5_invisible.png,
3792     Doc/manual/images/3_5_movedown.png,
3793     Doc/manual/images/3_5_moveup.png,
3794     Doc/manual/images/3_5_props.png,
3795     Doc/manual/images/3_5_tobottom.png,
3796     Doc/manual/images/3_5_totop.png,
3797     Doc/manual/images/3_5_visible.png: New. Images for the documentation.
3798    
3799 bh 1451 2003-07-18 Bernhard Herzog <[email protected]>
3800    
3801 bh 1465 * Thuban/UI/messages.py (MAP_REPLACED): New message.
3802    
3803     * Thuban/UI/viewport.py (ViewPort.SetMap): Issue MAP_REPLACED
3804     after the new map has been assigned
3805    
3806     * Thuban/UI/mainwindow.py (MainWindow.delegated_messages):
3807     Delegate MAP_REPLACED to the canvas too
3808     (MainWindow.prepare_new_session): Removed. Thanks to the new
3809     MAP_REPLACED message it's no longer needed
3810     (MainWindow.OpenSession, MainWindow.NewSession):
3811     prepare_new_session has been removed.
3812    
3813     * Thuban/UI/classifier.py (Classifier.__init__): Subscribe to
3814     MAP_REPLACED so that we can close the dialog if a new map is set.
3815     (Classifier.unsubscribe_messages): Unsubscribe from MAP_REPLACED
3816     (Classifier.map_replaced): Handle MAP_REPLACED by closing the
3817     dialog
3818    
3819     * test/test_viewport.py (SimpleViewPortTest)
3820     (SimpleViewPortTest.test_default_size): Add doc-strings
3821     (ViewPortTest.setUp): Bind map to self.map so we can use it in
3822     tests. Subscribe to MAP_REPLACED messages too.
3823     (ViewPortTest.tearDown): No need to explicitly unsubscribe
3824     (ViewPortTest.test_set_map): New test for the SetMap method.
3825    
3826     2003-07-18 Bernhard Herzog <[email protected]>
3827    
3828 bh 1463 * test/test_viewport.py (SimpleViewPortTest.test_default_size):
3829     Move this test from ViewPortTest.setUp to this new separate test
3830     case. setUp is not the place for the actual tests.
3831     (ViewPortTest.test_inital_settings, ViewPortTest.setUp): Move some
3832     more of the test from setUp to the new test test_inital_settings.
3833     (ViewPortTest.test_win_to_proj, ViewPortTest.test_proj_to_win)
3834     (ViewPortTest.test_proj_conv): Split test_proj_conv into
3835     test_win_to_proj and test_proj_to_win and make the tests easier to
3836     understand
3837     (ViewPortTest.testFitRectToWindow, ViewPortTest.testZoomFactor)
3838     (ViewPortTest.testZoomOutToRect, ViewPortTest.testTranslate)
3839     (ViewPortTest.test_unprojected_rect_around_point)
3840     (ViewPortTest.test_find_shape_at, ViewPortTest.testTools):
3841     Reformat to increase readability.
3842    
3843     2003-07-18 Bernhard Herzog <[email protected]>
3844    
3845 bh 1461 * Thuban/UI/view.py (MapCanvas.OnLeftDown): Capture the mouse.
3846    
3847     2003-07-18 Bernhard Herzog <[email protected]>
3848    
3849 bh 1459 * test/runtests.py: The test suite can now be run without an X
3850     connection. To make sure this remains true, remove the DISPLAY
3851     environment variable so that an error occurs if the wxGTK is
3852     imported accidentally
3853    
3854     2003-07-18 Bernhard Herzog <[email protected]>
3855    
3856 bh 1457 * Thuban/UI/viewport.py: Remove unused imports
3857    
3858     * Thuban/UI/view.py: Remove unused imports
3859    
3860     2003-07-18 Bernhard Herzog <[email protected]>
3861    
3862 bh 1455 * test/test_export.py Remove unused imports. The OutputTransform
3863     function is now in viewport.py and is called output_transform
3864     (TestScalebar.test_output_transform)
3865     (TestScalebar.test_OutputTransform): Renamed to
3866     test_output_transform and updated to use output_transform instead
3867     of OutputTransform
3868    
3869     * Thuban/UI/view.py (OutputTransform): Moved to viewport.py and
3870     renamed.
3871     (MapCanvas.Export, MapPrintout.draw_on_dc): OutputTransform was
3872     renamed to output_transform
3873    
3874     * Thuban/UI/viewport.py (OutputTransform, output_transform):
3875     Rename to output_transform
3876    
3877     2003-07-18 Bernhard Herzog <[email protected]>
3878    
3879 bh 1453 * Thuban/Model/layer.py (Layer.__init__): Rename
3880     classificationField to classificatin_column and init it here so
3881     that it can be used in SetClassificationColumn
3882     (Layer.GetClassificationColumn, Layer.GetClassificationField):
3883     Rename to GetClassificationColumn.
3884     (Layer.SetClassificationColumn, Layer.SetClassificationField):
3885     Rename to SetClassificationColumn and issue a LAYER_CHANGED
3886     message if the column changes.
3887     (Layer._classification_changed, Layer.ClassChanged): Rename to
3888     _classification_changed. Update the callers.
3889     (Layer.SetShapeStore): Further field->column renames.
3890    
3891     * Thuban/Model/load.py (SessionLoader.start_classification)
3892     (SessionLoader.start_clpoint): Updates because of
3893     field->column method name changes in the Layer class
3894    
3895     * Thuban/Model/save.py (SessionSaver.write_classification): Updates
3896     because of field->column method name changes in the Layer class
3897    
3898     * Thuban/UI/classifier.py (Classifier.__init__)
3899     (Classifier._OnTry, Classifier._OnRevert): Updates because of
3900     field->column method name changes in the Layer class
3901    
3902     * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Updates
3903     because of field->column method name changes in the Layer class
3904    
3905     * Thuban/UI/viewport.py (ViewPort.find_shape_at): Updates because
3906     of field->column method name changes in the Layer class
3907    
3908     * test/test_save.py (SaveSessionTest.testClassifiedLayer)
3909     (SaveSessionTest.testClassifiedLayer): Update because of
3910     field->column method name changes in the Layer class
3911    
3912     * test/test_layer.py (SetShapeStoreTests.setUp)
3913     (SetShapeStoreTests.test_sanity): Update because of field->column
3914     method name changes in the Layer class
3915     (TestLayerModification.setUp): Subscribe to LAYER_CHANGED as well
3916     (TestLayerModification.test_sanity)
3917     (TestLayerModification.test_initial_settings): remove unsued code
3918     and rename to test_sanity.
3919     (TestLayerModification.test_set_classification): New test for
3920     SetClassification and SetClassificationField.
3921    
3922     2003-07-18 Bernhard Herzog <[email protected]>
3923    
3924 bh 1451 * test/test_classgen.py (TestFixedRamp.test): Extend test to check
3925     the non-fixed values as well. The old test would have accepted a
3926     fixed ramp that only returnes the fixed properties
3927    
3928 jonathan 1449 2003-07-17 Jonathan Coles <[email protected]>
3929    
3930     * Doc/manual/mainwindow.png, Doc/manual/mainwindow.xcf: Screen
3931     shots for the manual. The XCF file is the source image and
3932     has additional layers to support changes.
3933    
3934     * Doc/manual/thuban-manual.xml: Wrote an initial Introduction.
3935    
3936     * Thuban/UI/classifier.py (Classifier.__BuildClassification):
3937     Return both the new class and the field name.
3938    
3939     * Thuban/UI/mainwindow.py (MainWindow.ToggleLegend): Don't
3940     fit the map to the window as this changes any zoom level that
3941     the user may have set.
3942    
3943 jonathan 1442 2003-07-16 Jonathan Coles <[email protected]>
3944    
3945     * Thuban/Model/classgen.py (generate_singletons,
3946     generate_uniform_distribution, generate_quantiles): Remove
3947     fixes parameter, but maintain the same functionality by having
3948     the calling function pass a FixedRamp object for the ramp.
3949     (FixedRamp): New. Adapts a ramp to have fixed property values.
3950    
3951     * Thuban/Model/classification.py: Use new CLASS_CHANGED message.
3952     (Classification): Inherit from Publisher.
3953     (Classification.__init__): Remove the layer parameter.
3954     Classifications no longer need to have a parent layer.
3955     (Classification.GetField, Classification.GetFieldType,
3956     Classification.SetFieldInfo): Removed. The field name is stored
3957     in the layer, and the type can be retreived by calling
3958     Layer.GetFieldType().
3959     (Classification._set_layer, Classification.GetLayer): Removed.
3960     Classifications no longer have a parent layer.
3961    
3962     * Thuban/Model/layer.py (Layer.Destroy): Unsubscribe from the
3963     classification.
3964     (Layer.SetShapeStore): Reset the classification first while
3965     we still have the old shape store to work with.
3966     (Layer.GetClassificationField, Layer.SetClassificationField):
3967     New. Method for getting/setting the field to classify on.
3968     (Layer.SetClassification): Simplified now that the layer
3969     simply has to hold a reference to the classification and not
3970     tell the classification who owns it.
3971     Fixes RTbug #2023.
3972    
3973     * Thuban/Model/load.py (SessionLoader.start_classification):
3974     Set the field name on the layer, not the classification.
3975    
3976     * Thuban/Model/messages.py: Add CLASS_CHANGED for when a
3977     classification is modified.
3978    
3979     * Thuban/Model/save.py (SessionSaver.write_classification):
3980     Get the field name and type from the layer.
3981    
3982     * Thuban/Model/table.py (table_to_dbf, table_to_csv): Renamed
3983     parameter records to rows and add docstring. Fixes RTbug #1997.
3984    
3985     * Thuban/UI/classgen.py (ClassGenDialog.OnOK): Use a fixed
3986     ramp when we need to fix certain values of a ramp rather than
3987     using the old fixes parameter. Fixes RTbug #2024.
3988    
3989     * Thuban/UI/classifier.py (ClassGrid.CreateTable): Add fieldType
3990     parameter.
3991     (ClassTable.Reset): Add fieldType parameter and use it, rather
3992     than asking the classification.
3993     (Classifier.__init__): Remember the original class's field
3994     and ask the layer for the field type, rather than the classification.
3995     (Classifier.__SetGridTable): Retrieve the field and field type
3996     for the table because they are not in the classification.
3997     (Classifier._OnTry, Classifier._OnRevert): Set the classification
3998     field on the layer in addition to the classification itself.
3999    
4000     * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Get the
4001     classification field from layer.
4002    
4003     * Thuban/UI/viewport.py (ViewPort.find_shape_at): Get the
4004     classification field from layer. Split up tests and remove
4005     *-imports. Fixes RTbug #1992.
4006    
4007     * test/test_classgen.py (TestFixedRamp): Test for the FixedRamp class.
4008    
4009     * test/test_classification.py
4010     (TestClassification.test_classification): Remove tests for methods
4011     that no longer exist.
4012    
4013     * test/test_layer.py (SetShapeStoreTests.setUp): Classification
4014     __init__ no longer has a field parameter, use SetClassificationField.
4015     (SetShapeStoreTests.test_sanity): Use layer object to get class
4016     field info.
4017    
4018     * test/test_save.py (SaveSessionTest.testClassifiedLayer): Use
4019     SetClassificationField on layer to set class field info.
4020    
4021     * test/test_viewport.py: Renamed from test/test_view.py.
4022    
4023 jan 1424 2003-07-16 Jan-Oliver Wagner <[email protected]>
4024    
4025     * Doc/manual/thuban-manual.xml: Added authors and an initial
4026     coarse structure.
4027    
4028 bh 1418 2003-07-15 Bernhard Herzog <[email protected]>
4029    
4030 bh 1422 * test/support.py (FloatComparisonMixin): This is a mix-in class
4031     and therefore should not be derived from any other class.
4032    
4033     * test/test_range.py (RangeTest): FloatComparisonMixin is a
4034     mix-in, so derive from TestCase as well.
4035    
4036     2003-07-15 Bernhard Herzog <[email protected]>
4037    
4038 bh 1420 * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Rework the
4039     draw_func handling a bit to remove one layer of indirection. This
4040     makes the renderer about 10% faster in the non-classifying case
4041     and the code a bit cleaner
4042     (MapRenderer.draw_point_shape): Add the pen and brush parameters
4043     and set them in the dc. Now the draw_point_shape method and
4044     wxproj's draw_polygon_shape function have basically the same
4045     signature so that both can be directly used as draw_func
4046    
4047     2003-07-15 Bernhard Herzog <[email protected]>
4048    
4049 bh 1418 * Thuban/Model/save.py (SessionSaver.write_classification): Encode
4050     string values (in addition to the labels) as UTF 8
4051    
4052     * Thuban/Model/load.py (SessionLoader.start_clpoint): Decode the
4053     values if the field type is string
4054    
4055     * test/test_save.py (SaveSessionTest.testClassifiedLayer): Test
4056     saving a session with non-ascii string classification values.
4057    
4058     * test/test_load.py (TestClassification.file_contents)
4059     (TestClassification.test): Check for non-ascii values in string
4060     classifications
4061    
4062 jonathan 1416 2003-07-14 Jonathan Coles <[email protected]>
4063    
4064     * test/test_view.py: New. Tests for ViewPort.
4065    
4066 frank 1409 2003-07-14 Frank Koormann <[email protected]>
4067    
4068     * Thuban/Model/load.py (SessionLoader.start_map): Encode map
4069     title to latin1. Fixes https://intevation.de/rt/webrt?serial_num=2013
4070    
4071 frank 1411 * test/test_load_0_8.py (TestUnicodeStrings): New, test load of
4072     unicode strings from session file: session title, map title and
4073     projection name.
4074    
4075 jonathan 1403 2003-07-10 Jonathan Coles <[email protected]>
4076    
4077 jonathan 1406 * Thuban/UI/viewport.py (Tool.MouseUp): Should have called
4078     drag_stop, not drag_move when the mouse is released.
4079    
4080     2003-07-10 Jonathan Coles <[email protected]>
4081    
4082 jonathan 1403 The most important part of this is the seperation of view.py into
4083     two pieces. viewport.py now has a class called ViewPort which
4084     contains all the non-wx parts of view.py and can therefore be
4085     tested. view.py contains only the wx-specific parts and is fairly
4086     simple.
4087    
4088     * Thuban/UI/view.py: Stripped out all non-wx functionality. Fixes
4089     RTTbug #1992.
4090     * Thuban/UI/viewport.py: New. Contains non-wx view functionality.
4091     RTTbug #1992.
4092    
4093     * Thuban/Model/classgen.py (generate_singletons,
4094     generate_uniform_distribution, generate_quantiles):
4095     Added 'fixes' parameter so that property attributes can
4096     be held constant over the generated classification groups.
4097     (CustomRamp.GetProperties): Remove unused variables.
4098    
4099     * Thuban/Model/map.py (Map.SetProjection): Send the old
4100     projection as an argument to listeners of the MAP_PROJECTION_CHANGED
4101     event.
4102    
4103     * Thuban/Model/table.py (table_to_dbf, table_to_csv): Added 'records'
4104     parameter which is a list of records that restricts which
4105     records are saved. Fixes RTbug #1997.
4106    
4107     * Thuban/UI/application.py (ThubanApplication.ShowExceptionDialog):
4108     Port exception dialog from GREAT-ER. Fixes RTbug #1993.
4109    
4110     * Thuban/UI/classgen.py (ClassGenDialog.__init__): Add controls
4111     to allow the user to fix line color/width on generated groups.
4112     (ClassGenDialog.OnOK): Use new 'fixes' parameter of the generate_*
4113     functions to optionally fix group properties.
4114    
4115     * Thuban/UI/main.py (main): Set exception hook to the
4116     ShowExceptionDialog. Fixes RTbug #1993.
4117    
4118     * Thuban/UI/mainwindow.py (MainWindow.ShowTableView): Raise
4119     the table window when it is selectd to be shown.
4120    
4121     * Thuban/UI/tableview.py (QueryTableFrame.__init__): Add an
4122     Export Selection button and move the export buttons underneath
4123     the table.
4124     (QueryTableFrame.UpdateStatusText): Added event argument so
4125     that it can respond to grid selection events. The status text
4126     is now updated even when the table is not associated with a
4127     layer as was previously assumed.
4128     (QueryTableFrame.OnGridSelectRange, OnGridSelectCell): Removed.
4129     UpdateStatusText responds to these events.
4130     (QueryTableFrame.OnSaveAs): Renamed to doExport.
4131     (QueryTableFrame.doExport): Helper function that saves the
4132     entire table, or selected rows, to a file.
4133     (QueryTableFrame.OnExport, QueryTableFrame.OnExportSel): New.
4134     Respond to export button events and call doExport.
4135    
4136     * extensions/thuban/gdalwarp.cpp (ProjectRasterFile): Make sure
4137     the function doesn't return NULL without first setting a Python
4138     Error.
4139    
4140     * test/runtests.py (main): Only print "Unknown option" for
4141     unsupported options.
4142    
4143     * test/support.py (FloatComparisonMixin.assertFloatEqual): Take
4144     optional epsilon argument to specify floating point accuracy.
4145     (FloatComparisonMixin.assertFloatSeqEqual): Call assertFloatEqual
4146     for each item test.
4147    
4148     * test/test_csv_table.py (TestCSVTable.test_table_to_cvs): Add
4149     tests for saving selected records.
4150    
4151     * test/test_dbf_table.py (TestTableToDBF.test_table_to_dbf): Add
4152     tests for saving selected records.
4153    
4154     * test/test_map.py (TestMapWithContents.test_set_projection):
4155     MAP_PROJECTION_CHANGED events send the old projection.
4156    
4157     * test/test_session.py
4158     (TestSessionWithContent.test_forward_map_projection):
4159     MAP_PROJECTION_CHANGED events send the old projection.
4160    
4161     * test/test_table.py (TableTest): Update tests to use non-deprecated
4162     functions.
4163    
4164 bh 1376 2003-07-08 Bernhard Herzog <[email protected]>
4165    
4166 bh 1382 * Thuban/Model/transientdb.py (TransientTableBase.Width): The type
4167     constants in the column objects are the standard ones defined in
4168     the table module.
4169    
4170     * test/test_transientdb.py
4171     (TestTransientTable.test_transienttable_to_dbf): New. Test whether
4172     exporting transient tables as DBF works. This should catch the bug
4173     just fixed in TransientTableBase.Width.
4174    
4175     2003-07-08 Bernhard Herzog <[email protected]>
4176    
4177 bh 1380 * Thuban/Model/classgen.py (CustomRamp.GetProperties): Compute the
4178     interpolated colors correctly.
4179    
4180     * test/test_classgen.py (TestCustomRamp.test_color_interpolation):
4181     New. Test case for the fix in classgen.py
4182    
4183     2003-07-08 Bernhard Herzog <[email protected]>
4184    
4185 bh 1378 * test/runtests.py (main): Make the default output less verbose
4186     and add a verbosity option (-v) to get the old output
4187    
4188     2003-07-08 Bernhard Herzog <[email protected]>
4189    
4190 bh 1376 * Resources/XML/thuban-0.9.dtd: New. This will become the DTD for
4191     0.9.
4192    
4193     * Thuban/Model/transientdb.py (TransientJoinedTable.JoinType):
4194     New. Return the join type
4195    
4196     * Thuban/Model/save.py (SessionSaver.write_session): Use new 0.9
4197     DTD
4198     (SessionSaver.write_data_containers): Save the join type for
4199     joined tables
4200    
4201     * Thuban/Model/load.py (SessionLoader.__init__): Add the new 0.9
4202     namespace
4203     (SessionLoader.start_jointable): Handle the jointype attribute
4204    
4205     * test/test_load_0_8.py: New. Effectively a copy of test_load.py
4206     as of Thuban 0.8. These are now tests to determine whether Thuban
4207     can still read files generated by Thuban 0.8
4208    
4209     * test/test_load.py (LoadSessionTest.dtd)
4210     (TestSingleLayer.file_contents)
4211     (TestLayerVisibility.file_contents, TestLabels.file_contents)
4212     (TestLayerProjection.file_contents)
4213     (TestRasterLayer.file_contents, TestJoinedTable.file_contents)
4214     (TestJoinedTable.file_contents)
4215     (TestLoadError.file_contents): Update for new DTD
4216     (TestJoinedTable.file_contents, TestJoinedTable.setUp): Add test
4217     for new join type attribute
4218    
4219     * test/test_save.py (SaveSessionTest.dtd)
4220     (SaveSessionTest.testEmptySession)
4221     (SaveSessionTest.testSingleLayer)
4222     (SaveSessionTest.testLayerProjection)
4223     (SaveSessionTest.testRasterLayer)
4224     (SaveSessionTest.testClassifiedLayer)
4225     (SaveSessionTest.test_dbf_table)
4226     (SaveSessionTest.test_joined_table): Update for new DTD
4227     (SaveSessionTest.test_joined_table): Add test for new join type
4228     attribute
4229    
4230 bh 1372 2003-07-04 Bernhard Herzog <[email protected]>
4231    
4232     * Thuban/Model/table.py (_find_dbf_column_names): New. Helper
4233     function for table_to_dbf
4234     (table_to_dbf): Deal with names longer than the 10 character limit
4235    
4236     * test/test_dbf_table.py (TestTableToDBF.test_table_to_dbf): Add
4237     doc-string
4238     (TestTableToDBF.test_table_to_dbf_long_col_names): New test for
4239     long column names
4240    
4241 bh 1365 2003-07-03 Bernhard Herzog <[email protected]>
4242    
4243 bh 1370 * Doc/manual/thuban-manual.xml: Fix the CVS Revision Tag syntax
4244    
4245     2003-07-03 Bernhard Herzog <[email protected]>
4246    
4247 bh 1368 * Doc/manual/thuban-manual.xml, Doc/manual/README: New. Skeleton
4248     for the Thuban manual and README with some basic information about
4249     the manual
4250    
4251     2003-07-03 Bernhard Herzog <[email protected]>
4252    
4253 bh 1365 * Thuban/Model/transientdb.py (TransientJoinedTable.__init__):
4254     Update doc-string
4255     (TransientJoinedTable.create): Do not modify the column objects of
4256     the input tables in place and copy all columns of the input tables
4257     into the joined table after all.
4258    
4259     * test/test_transientdb.py
4260     (TestTransientTable.test_transient_joined_table_same_column_name):
4261     Update to reflect the new behavior
4262     (TestTransientTable.test_transient_joined_table_with_equal_column_names):
4263     Update to reflect the new behavior
4264     (TestTransientTable.test_transient_joined_table_name_collisions_dont_modify_in_place):
4265     New test case for a bug which modified the column objects in place
4266    
4267 jonathan 1360 2003-07-02 Jonathan Coles <[email protected]>
4268 jonathan 1349
4269 jonathan 1360 * Thuban/Model/classgen.py (generate_singletons,
4270     generate_uniform_distribution, generate_quantiles,
4271 jonathan 1363 GenQuantiles0): Make sure maxValue isn't less than
4272     one, otherwise we could divide by zero.
4273    
4274     * test/test_classgen.py (ClassGenTest.doClassRangeTest,
4275     ClassGenTest.doClassSingleTest): Call doBoundsTest to
4276     check the end classification groups against the
4277     proper property values.
4278     (ClassGenTest.doBoundsTest): New. Checks the first and
4279     last classification groups to make sure their properties
4280     are the correct upper and lower bounds for a color ramp.
4281    
4282     2003-07-02 Jonathan Coles <[email protected]>
4283    
4284     * Thuban/Model/classgen.py (generate_singletons,
4285     generate_uniform_distribution, generate_quantiles,
4286 jonathan 1360 GenQuantiles0): The denominator was one to high when
4287     calculating the index for the ramp causing the index
4288     to never to reach one.
4289    
4290     2003-07-02 Jonathan Coles <[email protected]>
4291    
4292 jonathan 1358 Changed the singature of ClassGroupRange.__init__ and
4293     ClassGroupRange.SetRange() so that the min/max values are
4294     passed as a tuple. This makes a better calling scheme for
4295     when a Range object is passed instead.
4296    
4297     * Thuban/Model/classgen.py: Fixed parameters to
4298     ClassGroupRange constructor.
4299    
4300     * Thuban/Model/classification.py (ClassGroupRange.__init__):
4301     Consolidate the min/max parameters into a single _range which
4302     can either be a tuple or a Range object.
4303     (ClassGroupRange.SetRange): Consolidate the min/max parameters
4304     into a single _range which can either be a tuple or a Range object.
4305    
4306     * Thuban/Model/load.py (SessionLoader.start_clrange): Fix
4307     call to ClassGroupRange constructor to use a tuple.
4308    
4309     * Thuban/Model/layer.py (Layer.SetClassification): Switch
4310     the classification instance variable to the new class
4311     before calling _set_layer otherwise subscribers to a
4312     LAYER_CHANGED event will not see any difference.
4313    
4314     * test/test_classification.py: Fix tests of ClassGroupRange
4315     so that they use the new signature.
4316    
4317     * test/test_load.py: Fix use of ClassGroupRange so that it
4318     uses the new signature.
4319    
4320     * test/test_load_0_2.py: Fix use of ClassGroupRange so that it
4321     uses the new signature.
4322    
4323     * test/test_save.py: Fix use of ClassGroupRange so that it
4324     uses the new signature.
4325    
4326    
4327     2003-07-01 Jonathan Coles <[email protected]>
4328    
4329 jonathan 1349 * Thuban/Model/classgen.py: Fixes RTbug #1972, 1971.
4330     Import used objects/class from color.
4331     (generate_singletons): We don't
4332     need the numGroups parameter anymore because we are using
4333     the new ramps with GetProperties().
4334     (generate_uniform_distribution): Use new ramp method
4335     GetProperties().
4336     (generate_quantiles, GenQuantiles0): Use new ramp method
4337     GetProperties().
4338     (CustomRamp.SetNumGroups): Removed. The ramps now map
4339     a value from 0 to 1 to class properties so the number
4340     of groups is not needed ahead of time.
4341     (CustomRamp.next): Removed. CustomRamp does not support
4342     interation anymore.
4343     (CustomRamp.GetProperties): Returns a ClassGroupProperties
4344     object based on the index value from 0 to 1 that is
4345     passed to it.
4346     (GreyRamp, RedRamp, GreenRamp, BlueRamp, GreenToRedRamp):
4347     Made into instances of Monochromatic class instread of
4348     deriving from it.
4349     (HotToCold.SetNumGroups): Removed. See CustomRamp.
4350     (HotToCold.next): Removed. See CustomRamp.
4351    
4352     * Thuban/Model/classification.py: Fixes RTbug #1973, 1971.
4353     (Classification.SetField, Classification.SetFieldType):
4354     Replaced with SetFieldInfo.
4355     (Classification.SetFieldInfo): New. Does a better job of
4356     what SetField and SetFieldType used to do by combining
4357     their function since they should really always be done
4358     at the same time.
4359     (Classification.SetLayer): Renamed to _set_layer.
4360     (Classification._set_layer): Should only be called from
4361     Layer's SetClassification. This does not cause a recursive
4362     call as SetLayer did because we know that Layer knows about
4363     the classification.
4364    
4365     * Thuban/Model/color.py: Fixes RTbug #1971.
4366     (_Transparent): Renamed from Transparent so it doesn't
4367     conflict with the module variable.
4368     (Transparent, Black): Renamed from Color.Transparent,
4369     Color.Black so they are not class variables.
4370    
4371     * Thuban/Model/layer.py: Fixes RTbug #1971, 1973.
4372     (Layer.Destroy): We don't need to call SetClassification
4373     anymore to clear out the back reference in the classifcation
4374     to the layer. It's better to set it to None using _set_layer,
4375     and we won't be creating another clas object too.
4376     (Layer.SetClassification): Classification._set_layer is not
4377     recursive so remove all the locking variables. Also clean
4378     up the code so that it remains unchanged if something fails.
4379    
4380     * Thuban/Model/load.py: Fixes RTbug #1971.
4381     (SessionLoader.start_classification): Call
4382     Classification.SetFieldInfo().
4383    
4384     * Thuban/Model/save.py: Removed import of Color which wasn't
4385     being used.
4386    
4387     * Thuban/UI/classgen.py: Fixes RTbug #1972.
4388     (ClassGenDialog.__init__): Color ramps are now instances
4389     already so we don't need to create any new objects.
4390     (ClassGenDialog.OnOK): Check for numGroups is no longer
4391     necessary because we never use it.
4392    
4393     * Thuban/UI/classifier.py: Fixes RTbug #1971.
4394     (Classifier.__BuildClassification, Classifier.__SetGridTable):
4395     Call Classification.SetFieldInfo() instead of SetFieldType.
4396    
4397     * Thuban/UI/renderer.py: Fixes RTbug #1971.
4398    
4399     * Thuban/UI/view.py: Fixes RTbug #1974, 1971.
4400     (MapCanvas.__init__): Subscribe to the idle time event. Set
4401     background color to white.
4402     (MapCanvas.OnPaint): Set a flag indicating that we should
4403     render the map during idle time. If we already have a bitmap
4404     just draw it now.
4405     (MapCanvas.OnIdle): New. Render the map only during idle time.
4406     This also fixes a problem with the busy cursor under gtk.
4407    
4408     * test/test_classgen.py (ClassGenTest.test_generate_singletons):
4409     Fix calls to generate_singletons because the signature changed.
4410    
4411     * test/test_classification.py: Fix color references and
4412     change calls to Classification.[SetField|SetFieldType] to
4413     SetFieldInfo.
4414    
4415     * test/test_load.py: Fix color references.
4416    
4417     * test/test_load_0_2.py: Fix color references.
4418    
4419     * test/test_save.py (SaveSessionTest.testClassifiedLayer):
4420     Change calls to Classification.[SetField|SetFieldType] to
4421     SetFieldInfo.
4422    
4423 frank 1334 2003-07-01 Frank Koormann <[email protected]>
4424    
4425     MERGE from the greater-ms3 branch.
4426    
4427     * test/test_transientdb.py
4428     (TestTransientTable.test_transient_joined_table_with_equal_column_names):
4429     New. Test join of two tables with partly equal column names.
4430    
4431     * Thuban/Model/transientdb.py (TransientJoinedTable.create):
4432     If duplicates in left and right tables column names are found,
4433     append '_' (underscores) to the name until it is unique.
4434     Create always new internal names for the resulting table and reference
4435     columns in the join statement with <table>.<column>
4436    
4437 bh 1329 2003-07-01 Bernhard Herzog <[email protected]>
4438    
4439     * test/test_transientdb.py
4440     (TestTransientTable.test_transient_joined_table_same_column_name):
4441     New. Test whether joining on columns with the same names in both
4442     tables works.
4443 frank 1334
4444 bh 1329 * Thuban/Model/transientdb.py (TransientJoinedTable.create): Make
4445     sure to use the right internal names even when joining on field
4446     with the same names in both tables. Also, detect duplicate names
4447     in the joined table correctly.
4448    
4449 frank 1325 2003-07-01 Frank Koormann <[email protected]>
4450    
4451     * Thuban/UI/renderer.py (ExportRenderer.render_legend):
4452     Reverse List of layers to render in same order as in desktop legend.
4453    
4454 jonathan 1318 2003-06-30 Jonathan Coles <[email protected]>
4455    
4456 jonathan 1349 * Thuban/version.py (make_tuple): Takes a version string
4457     and splits it into a tuple of at most three integers.
4458     Used make_tuple() to make tuple versions of the version
4459     numbers.
4460    
4461     * Thuban/UI/about.py: Add Thuban email addresses.
4462    
4463     2003-06-30 Jonathan Coles <[email protected]>
4464    
4465 jonathan 1320 * Thuban/version.py: SQLite/PySQLite version dependencies
4466     were too high.
4467    
4468     2003-06-30 Jonathan Coles <[email protected]>
4469    
4470 jonathan 1318 * Thuban/version.py: Update version to 0.8.1
4471    
4472     * MANIFEST.in: Added Projections so that default.proj is
4473     included.
4474    
4475 jonathan 1312 2003-06-26 Jonathan Coles <[email protected]>
4476    
4477     New About box with lots more information including library
4478     versions and credits. More/better version checking before
4479     Thuban starts.
4480    
4481     * Thuban/UI/about.py: New. New About box that displays
4482     library version information and credits.
4483    
4484     * Thuban/version.py: Added new 'versions' dictionary which
4485     contains the verions of various libraries which are checked
4486     when the module loads.
4487     (verify_versions): Check all version numbers and returns
4488     a list of errors.
4489    
4490     * Thuban/UI/classifier.py (Classifier.__EnableButtons):
4491     Reset the status of the buttons as the situation warrants,
4492     but in a better more reliable way by not relying on the
4493     current status to determine what needs to change.
4494    
4495     * Thuban/UI/main.py (wxCHECK_VERSION): Removed. Not needed.
4496     (verify_versions): Remove most of the code since it is
4497     now in Thuban.version.verify_versions.o
4498    
4499     * Thuban/UI/mainwindow.py (MainWindow.About): Call new
4500     About box in Thuban.UI.about.
4501    
4502     * extensions/thuban/gdalwarp.cpp (get_gdal_version): New.
4503     Returns the version of gdal library being used as a string.
4504    
4505     * extensions/thuban/wxproj.cpp (check_version, check_version_gtk):
4506     Removed.
4507     (get_proj_version): Return the version of PROJ that the file
4508     was compiled with.
4509     (get_gtk_version): Return th version of GTK that the file
4510     was compiled with.
4511    
4512 jonathan 1304 2003-06-25 Jonathan Coles <[email protected]>
4513    
4514     * Thuban/UI/classifier.py (Classifier.EditSymbol): The parent
4515     of the SelectPropertiesDialog should be self so the window
4516     appears on top.
4517     (ClassGroupPropertiesCtrl.DoEdit): The parent
4518     of the SelectPropertiesDialog should be self so the window
4519     appears on top.
4520    
4521     * Thuban/UI/resource.py: Cleaned up how we determine file
4522     extensions.
4523     (GetImageResource): Return an wxImage from our Resources.
4524    
4525 jonathan 1299 2003-06-24 Jonathan Coles <[email protected]>
4526    
4527     * Thuban/UI/renderer.py (ExportRenderer.render_legend):
4528     Check that a layer has a classification before trying
4529     to get it. Raster layers don't have classifications.
4530    
4531 jonathan 1286 2003-06-23 Jonathan Coles <[email protected]>
4532 jonathan 1297
4533     * setup.py: Add Resources/XML to resource list.
4534    
4535     2003-06-23 Jonathan Coles <[email protected]>
4536 jonathan 1286
4537 jonathan 1297 * setup.cfg: Fix copyright dates
4538    
4539     2003-06-23 Jonathan Coles <[email protected]>
4540    
4541 jonathan 1294 * MANIFEST.in: Update with Resources/XML
4542    
4543     * setup.py: Don't include Locale resources yet as we don't
4544     have any and it causes problems building the distribution
4545     for Windows. Update version to 0.8.0.
4546    
4547     * Doc/thuban.dtd: Removed since it is now in Resources/XML.
4548    
4549     * Thuban/UI/mainwindow.py: Add blank line at the end because
4550     file was not being read correctly building the Windows
4551     distribution.
4552    
4553     2003-06-23 Jonathan Coles <[email protected]>
4554    
4555 jonathan 1289 * Thuban/UI/mainwindow.py (MainWindow.About): Fix text.
4556    
4557     * Thuban/version.py: Temporarily update longversion for
4558     the 0.8 release so that it doesn't have the cvs revision.
4559    
4560     2003-06-23 Jonathan Coles <[email protected]>
4561    
4562 jonathan 1286 * Thuban/UI/common.py (ThubanBeginBusyCursor): Call wxSafeYield
4563     to make sure that we don't create reentrant possibilities with
4564     wxYield.
4565    
4566     * Thuban/UI/view.py (MapCanvas.OnPaint): Call wxBeginBusyCursor()
4567     directly to avoid the wxSafeYield() call which generates an
4568     OnPaint event causing infinite recursion. Don't try to catch
4569     exception anymore. This was for before there were limits on map
4570     scaling.
4571    
4572 bh 1283 2003-06-23 Bernhard Herzog <[email protected]>
4573    
4574     Bug fix for RT #1961:
4575    
4576     * Thuban/Model/load.py (SessionLoader.start_derivedshapesource):
4577     Register DerivedShapestores with the session
4578    
4579     * Thuban/Model/session.py (Session.Tables): Make sure each table
4580     is only listed once.
4581    
4582     * test/test_load.py (TestJoinedTable.test): Add check_format call.
4583     Update file contents to match the one written out.
4584    
4585 bh 1281 2003-06-20 Bernhard Herzog <[email protected]>
4586    
4587     * test/xmlsupport.py (SaxEventLister.startElementNS)
4588     (SaxEventLister.endElementNS): Do not include the qname. Python
4589     2.2.1 and 2.2.2 and 2.2.3 differ in this regard. In 2.2.1 qname it
4590     is (presumably incorrectly) None, whereas it's a string with the
4591     element name in the later versions.
4592    
4593     * test/test_xmlsupport.py (TestEventList.test_even_list_simple)
4594     (TestEventList.test_even_list_namespace): Update tests to reflect
4595     the new behaviour
4596     (TestEventList.test_even_list_id_normalization): Fix doc-string
4597    
4598 jonathan 1272 2003-06-20 Jonathan Coles <[email protected]>
4599    
4600 jonathan 1279 * Thuban/Model/layer.py (BaseLayer.HasShapes): New. Overridden
4601     by deriving classes to determine if that layer supports shapes.
4602     (Layer): Override HasShapes and return true.
4603    
4604     * Thuban/UI/classgen.py: Use Thuban[Begin|End]BusyCursor()
4605     instead of a direct call to wx[Begin|End]CusyCursor().
4606     (GenUniquePanel._OnRetrieve): Set busy cursor while retrieving
4607     table data.
4608    
4609     * Thuban/UI/common.py (ThubanBeginBusyCursor, ThubanEndBusyCursor):
4610     New. Wrappers around the wxWindows functions that allow us to
4611     make additional calls such as wxYield which gives the native
4612     system a chance to update the cursor correctly.
4613    
4614     * Thuban/UI/tableview.py: Use Thuban[Begin|End]BusyCursor()
4615     instead of a direct call to wx[Begin|End]CusyCursor().
4616    
4617     * Thuban/UI/view.py: Use Thuban[Begin|End]BusyCursor()
4618     instead of a direct call to wx[Begin|End]CusyCursor().
4619     (MapCanvas.find_shape_at): Check if the current search layer
4620     support shapes, otherwise go on to the next layer.
4621    
4622     * test/test_layer.py: Add tests in each type of layer for
4623     HasClassification() and HasShapes()
4624    
4625     2003-06-20 Jonathan Coles <[email protected]>
4626    
4627 jonathan 1272 * Thuban/UI/view.py (MapCanvas.OnPaint): Call wxYield after
4628     turning on the busy cursor to allow the system to change the
4629     cursor before we begin painting. This fixes a problem that
4630     was occuring only under GTK. Fixes RTbug #1840.
4631    
4632 bh 1270 2003-06-20 Bernhard Herzog <[email protected]>
4633    
4634     * Resources/XML/thuban-0.8.dtd: New DTD for the new file format
4635     version.
4636    
4637     * Thuban/Model/save.py (sort_data_stores): New. Make topological
4638     sort of the data sources so they can be written with sources that
4639     data sources that depend on other data sources come after the
4640     sources they depend on.
4641     (SessionSaver.__init__): Add idmap instance variable to map from
4642     objects to the ids used in the file.
4643     (SessionSaver.get_id, SessionSaver.define_id)
4644     (SessionSaver.has_id): New. Methods to manage the idmap
4645     (SessionSaver.write): Use thuban-0.8.dtd
4646     (SessionSaver.write_session): Add a namespace on the session and
4647     write out the data sources before the maps.
4648     (SessionSaver.write_data_containers): New. Write the data
4649     containers.
4650     (SessionSaver.write_layer): Layer elements now refer to a
4651     shapestore and don't contain filenames anymore.
4652    
4653     * Thuban/Model/load.py (LoadError): Exception class to raise when
4654     errors in the files are discovered
4655     (SessionLoader.__init__): Define dispatchers for elements with a
4656     thuban-0.8 namespace too.
4657     (SessionLoader.check_attrs): New helper method to check and
4658     convert attributes
4659     (AttrDesc): New. Helper class for SessionLoader.check_attrs
4660     (SessionLoader.start_fileshapesource)
4661     (SessionLoader.start_derivedshapesource)
4662     (SessionLoader.start_filetable, SessionLoader.start_jointable):
4663     Handlers for the new elements in the new fileformat
4664     (SessionLoader.start_layer): Handle the shapestore attribute in
4665     addition to filename.
4666     (SessionLoader.start_table, SessionLoader.end_table): Removed.
4667     They were never used in the old formats and aren't needed for the
4668     new.
4669    
4670     * Thuban/Model/session.py (Session.DataContainers): New method to
4671     return all "data containers", i.e. shapestores and tables
4672    
4673     * test/xmlsupport.py (SaxEventLister.__init__)
4674     (SaxEventLister.startElementNS, sax_eventlist): Add support to
4675     normalize IDs.
4676    
4677     * test/test_xmlsupport.py
4678     (TestEventList.test_even_list_id_normalization): New test case for
4679     id normalization
4680    
4681     * test/test_load.py (LoadSessionTest.check_format): Use ID
4682     normalization
4683     (LoadSessionTest.thubanids, LoadSessionTest.thubanidrefs): New
4684     class atrributes used for ID normalization
4685     (TestSingleLayer, TestLayerVisibility, TestLabels.test)
4686     (TestLayerProjection.test, TestRasterLayer.test): Adapt to new
4687     file format
4688     (TestJoinedTable): New test for loading sessions with joined
4689     tables.
4690     (TestLoadError): New. Test whether missing required attributes
4691     cause a LoadError.
4692    
4693     * test/test_save.py (SaveSessionTest.thubanids)
4694     (SaveSessionTest.thubanidrefs): New class attributes for ID
4695     normalization in .thuban files.
4696     (SaveSessionTest.compare_xml): Use id-normalization.
4697     (SaveSessionTest.testEmptySession)
4698     (SaveSessionTest.testLayerProjection)
4699     (SaveSessionTest.testRasterLayer)
4700     (SaveSessionTest.testClassifiedLayer): Adapt to new file format.
4701     (SaveSessionTest.testLayerProjection): The filename used was the
4702     same as for testSingleLayer. Use a different one.
4703     (SaveSessionTest.test_dbf_table)
4704     (SaveSessionTest.test_joined_table): New test cases for saving the
4705     new data sources structures.
4706     (TestStoreSort, MockDataStore): Classes to test the sorting of the
4707     data stores for writing.
4708    
4709     * test/runtests.py: Add CVS keywords
4710    
4711 jonathan 1265 2003-06-20 Jonathan Coles <[email protected]>
4712    
4713 jonathan 1267 * test/test_session.py
4714     (UnreferencedTablesTests.test_unreferenced_tables_with_joins):
4715     Use the cultural_landmark-point.dbf file for the store so that
4716     the table rows and shape count match.
4717    
4718     2003-06-20 Jonathan Coles <[email protected]>
4719    
4720 jonathan 1265 * Thuban/Model/data.py (DerivedShapeStore.__init__): Raise
4721     an exception if the number of shapes is different from the
4722     number of rows in the table. Address RTbug #1933.
4723    
4724     * test/test_layer.py (TestLayer.test_derived_store): Add
4725     a test for the new exception in DerivedShapeStore.__init__.
4726    
4727     * test/support.py (FloatTestCase): Removed since there is
4728     already FloatComparisonMixin. Fixes RTbug #1954.
4729     (FloatComparisonMixin.assertFloatEqual): Include test for
4730     infinity that was part of FloatTestCase.
4731    
4732     * test/test_range.py (RangeTest): Inherit from
4733     support.FloatComparisonMixin now that we don't have
4734     support.FloatTestCase.
4735    
4736 bh 1256 2003-06-20 Bernhard Herzog <[email protected]>
4737    
4738 bh 1260 * test/test_save.py (SaxEventLister, sax_eventlist): Removed. Use
4739     the implementation in xmlsupport instead.
4740     (SaveSessionTest.compare_xml): sax_eventlist is now in xmlsupport
4741    
4742     * test/test_proj.py: Import sax_eventlist from xmlsupport instead
4743     of test_save
4744    
4745     2003-06-20 Bernhard Herzog <[email protected]>
4746    
4747 bh 1258 * test/test_load.py (LoadSessionTest.check_format): New helper
4748     method to make sure the test files we load might have been written
4749     by the current thuban version.
4750     (ClassificationTest.TestLayers, TestSingleLayer.test)
4751     (TestLayerVisibility.test, TestClassification.test)
4752     (TestLabels.test, TestLayerProjection.test, TestRasterLayer.test):
4753     Add check_format() calls and fix the thuban data to match the data
4754     that would be written by saving the session loaded from it.
4755    
4756     * test/xmlsupport.py (SaxEventLister, sax_eventlist): Copies of
4757     the same class and function in test_save.
4758    
4759     * test/test_xmlsupport.py (TestEventList): New. test cases for
4760     sax_eventlist
4761    
4762     2003-06-20 Bernhard Herzog <[email protected]>
4763    
4764 bh 1256 * Resources/XML/thuban.dtd: Add comment about which versions of
4765     Thuban are covered by this DTD
4766     (map): Fix content model for layers and raster layers. There can
4767     be any number or layers and raster layers in any order.
4768    
4769 jonathan 1254 2003-06-20 Jonathan Coles <[email protected]>
4770    
4771 jonathan 1265 This is mainly about fixing RTbug #1949.
4772    
4773 jonathan 1254 * Thuban/Model/classification.py: Remove "from __future__"
4774     import statement since python 2.2 is the earliest supported
4775     version.
4776    
4777     * Thuban/Model/proj.py (Projection.GetProjectedUnits): New.
4778     Currently returns PROJ_UNITS_METERS or PROJ_UNITS_DEGREES
4779     depending on the units this projection *forwards* into.
4780    
4781     * Thuban/Model/save.py (SessionSaver.write_classification):
4782     Remove unnecessary use of lambdas and nested functions.
4783    
4784     * Thuban/UI/legend.py (ScaleBarBitmap.__SetScale): Do scale
4785     adjustment here if the map projection uses degrees.
4786    
4787     * Thuban/UI/scalebar.py (ScaleBar.DrawScaleBar): Remove
4788     scale adjust code since it is now done before calling
4789     this method. Don't do anything if the map projection
4790     is None.
4791    
4792 bh 1244 2003-06-19 Bernhard Herzog <[email protected]>
4793    
4794 bh 1248 Move version specific load tests to their own file.
4795    
4796     * test/test_load.py: Expand the doc-string to explain a bit how to
4797     handle file format changes.
4798     (TestClassification.test): Update the docstring as this test is
4799     not about Thuban 0.2 anymore.
4800    
4801     * test/test_load_0_2.py: New file with the load tests for thuban
4802     files created with Thuban 0.2 and earlier.
4803    
4804     2003-06-19 Bernhard Herzog <[email protected]>
4805    
4806 bh 1246 Add XML validation to some of the tests. Validation will only be
4807     done if pyRXP is installed (http://reportlab.com/xml/pyrxp.html).
4808     To make the DTD available to the test cases it's moved into
4809     Resources/XML
4810    
4811     * Resources/XML/thuban.dtd: New. This is now the real Thuban DTD
4812     for versions up to and including 0.2. Two slight changes: added an
4813     encoding specification and fixed the comment which refered to
4814     GRASS, not Thuban
4815    
4816     * test/xmlsupport.py: New support module for tests involving XML.
4817     Currently there's a mix-in class for XML validation.
4818    
4819     * test/test_xmlsupport.py: New. Tests for the xmlsupport module
4820    
4821     * test/test_save.py (SaveSessionTest): Derive from ValidationTest
4822     so that we can validate the
4823     (SaveSessionTest.testEmptySession)
4824     (SaveSessionTest.testSingleLayer)
4825     (SaveSessionTest.testSingleLayer)
4826     (SaveSessionTest.testLayerProjection)
4827     (SaveSessionTest.testRasterLayer)
4828     (SaveSessionTest.testClassifiedLayer): Validate the generated XML
4829    
4830     * test/runtests.py (main): Call print_additional_summary instead
4831     of print_garbage_information
4832    
4833     * test/support.py (resource_dir): New function to return the
4834     "Resource" subdirectory
4835     (print_additional_summary): New function to combine several
4836     summary functions
4837     (run_tests): Use print_additional_summary instead of calling
4838     print_garbage_information directly
4839    
4840     2003-06-19 Bernhard Herzog <[email protected]>
4841    
4842 bh 1244 * Doc/thuban.dtd (classification): Correct the content model of
4843     the classification element.
4844     (projection): Add the "name" attribute
4845    
4846 frank 1242 2003-06-19 Frank Koormann <[email protected]>
4847    
4848     MERGE from the greater-ms3 branch.
4849    
4850     * Thuban/UI/scalebar.py (ScaleBar.DrawScaleBar): Apply conversion to
4851     scale if projection is latlong to get better estimate.
4852    
4853     Fix problem of hidden properties dialog under windows after double
4854     click on layer tree:
4855     The tree control always gets an Expanded / Collapsed event after
4856 joey 2162 the ItemActivated on double click, which raises the main window again.
4857     We add a second ItemActivated event to the queue, which simply
4858 frank 1242 raises the already displayed window.
4859    
4860     * Thuban/UI/legend.py (LegendTree.__init__): Instance variable
4861     raiseProperties initialized to prevent endless loops
4862     (LegendTree._OnItemActivated): Depending on self.raiseProperties
4863     simply raise the properties or open the dialog and issue a second
4864     event.
4865    
4866 jonathan 1235 2003-06-18 Jonathan Coles <[email protected]>
4867    
4868 jonathan 1239 * setup.py: Fix a few problems that occured under Windows.
4869    
4870     2003-06-18 Jonathan Coles <[email protected]>
4871    
4872 jonathan 1235 When Thuban loaded the map was redrawn twice because the
4873     legend was being opened after the mainwindow was created
4874     and not during its creation. This meant the map was drawn
4875     initially and then had to be redrawn when the legend
4876     caused the display to change. Now the legend is opened
4877     in the mainwindow constructor which resolves this issue.
4878    
4879     Also, although we were checking for the existence of
4880     gdal and gdalwarp modules, the gdalwarp extension was
4881     still being compiled (which may fail if the system doesn't
4882     have gdal installed). the build_ext command to setup.py
4883     now accepts the flags --with-gdal and --without-gdal.
4884     If --without-gdal is specified setup.py will try to
4885     use the gdal parameters specified by gdal-config. Under
4886     windows, those parameters have to be set in setup.py
4887     as with proj4 an wxWindows.
4888    
4889     * setup.py: Use a list instead of seperate variables for
4890     extension parameters so we can create a generic function
4891     that runs an appropriate *-config script.
4892     (run_cs_script): Renamed from run_wx_script and modified
4893     to accept a second argument which is a list of lists to
4894     be filled in by the values returned from running the command.
4895     (thuban_build_ext): New. Extends the build_ext command and
4896     provides the options --with-gdal/--without-gdal which then
4897     optionally includes the gdalwarp extension.
4898    
4899     * Thuban/Model/resource.py: First check if we can import
4900     the gdalwarp Thuban extension before checking for gdal.
4901     Also added some comments.
4902    
4903     * Thuban/UI/legend.py (ScaleBarBitmap.__SetScale): Check if
4904     the map is None which may be the case if none has been loaded
4905     yet.
4906    
4907     * Thuban/UI/main.py (main): Remove call to ShowLegend.
4908    
4909     * Thuban/UI/mainwindow.py (MainWindow.__init__): Call ShowLegend().
4910    
4911     * Thuban/UI/renderer.py: Check for gdal support before importing
4912     gdalwarp.
4913     (MapRenderer.render_map): Only try to optimize if we have gdal
4914     support otherwise nothing will get drawn.
4915    
4916 jonathan 1237 * Thuban/UI/view.py (MapCanvas.FitMapToWindow): This may be called
4917     during startup before a map has been created. Check if map is None
4918     before using it and do nothing if it is.
4919    
4920 jonathan 1224 2003-06-17 Jonathan Coles <[email protected]>
4921    
4922     Fix the problem with raster layers under Windows that caused
4923     Thuban to crash. The view should respond to layer projection
4924     changed events to update the display. Changes to a projection
4925     should not cause the map to be set to full extent.
4926    
4927     * Thuban/UI/view.py (MapCanvas.__init__): New instance variable
4928     current_map_proj to remember the current map projection so that
4929     when the projection changes we know what the previous projection
4930     was.
4931     (MapCanvas.SetMap): Unsubscribe and subscribe to
4932     LAYER_PROJECTION_CHANGED events.
4933     (MapCanvas.projection_changed): Split into two methods that respond
4934     to map and layer projection changes.
4935     (MapCanvas.map_projection_changed): New. Takes the current view and
4936     projects it using the new projection. This does not cause the
4937     map to be redrawn at full extent.
4938     (MapCanvas.layer_projection_changed): New. Cause a redraw which
4939     will draw each layer in its new projection.
4940    
4941     * extensions/thuban/bmpdataset.cpp (BMPDataset::Open): Call
4942     VSIFClose() not VSIFCloseL() to close the file. Fixes a crash
4943     under Windows.
4944    
4945     * extensions/thuban/gdalwarp.cpp (MFILENAME): Padding should be
4946     to twice sizeof(void*) because there are two digits for each
4947     hex byte.
4948    
4949 bh 1220 2003-06-16 Bernhard Herzog <[email protected]>
4950    
4951     Update to the layer interface: Direct access to the table,
4952     shapetable, shapefile and filename attributes is now actively
4953     deprecated by issuing deprecation warnings for all places where
4954     this happens.
4955    
4956     * Thuban/Model/layer.py (Layer.__getattr__): New. Implement access
4957     to the instance variables table, shapetable, shapefile and
4958     filename via __getattr__ so that we can issue a deprecation
4959     warning.
4960     (Layer.SetShapeStore): Don't set the deprecated instance variables
4961     any more
4962     (Layer.SetShapeStore): Don't use deprecated layer instance
4963     variables
4964     (Layer.Destroy): No need to explicitly remove the instance
4965     variables any more
4966     (Layer.GetFieldType, Layer.Shape): Don't use deprecated layer
4967     instance variables
4968    
4969     * Thuban/UI/classgen.py (ClassGenDialog.__init__)
4970     (GenUniformPanel._OnRetrieve, GenUniquePanel._OnRetrieve)
4971     (GenQuantilesPanel.GetList, GenQuantilesPanel.OnRetrieve): Don't
4972     use deprecated layer instance variables
4973    
4974     * Thuban/UI/classifier.py (Classifier.__init__): Don't use
4975     deprecated layer instance variables
4976    
4977     * Thuban/UI/identifyview.py (IdentifyListCtrl.selected_shape)
4978     (IdentifyGridCtrl.selected_shape): Don't set the deprecated layer
4979     instance variables
4980    
4981     * Thuban/UI/tableview.py (LayerTableGrid.select_shapes): Don't use
4982     deprecated layer instance variables
4983    
4984     * Thuban/UI/mainwindow.py (MainWindow.LayerShowTable): Don't use
4985     deprecated layer instance variables
4986    
4987     * Thuban/Model/save.py (SessionSaver.write_layer): Don't use
4988     deprecated layer instance variables
4989    
4990     * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer)
4991     (MapRenderer.polygon_render_param): Don't use deprecated layer instance
4992     variables
4993    
4994     * test/runtests.py (main): Turn Thuban's deprecation warnings into
4995     errors so that they're cought by the tests
4996    
4997     * test/test_load.py (TestSingleLayer.test): Don't use deprecated
4998     layer instance variables
4999    
5000 jonathan 1212 2003-06-16 Jonathan Coles <[email protected]>
5001    
5002     Fix a problem under Windows whereby if the user double-clicks on a
5003     layer in the legend that tree item will expand or collapse as well
5004     as open the layer properties dialog. The state of the tree item
5005     should not be affected.
5006    
5007     * Thuban/UI/legend.py (LegendTree.__init__): Add instance variable
5008     preventExpandCollapse and subscribe to expanding and collapsing
5009     events.
5010     (LegendTree.OnItemExpandCollapse): New. Responds to expanding and
5011     collapsing events and will veto the event if it has been triggered
5012     by the user double clicking on a layer.
5013     (LegendTree._OnItemActivated): Set preventExpandCollapse to indicate
5014     that an expanding/collapsing event should be vetoed.
5015    
5016 bh 1208 2003-06-13 Bernhard Herzog <[email protected]>
5017    
5018     * Thuban/UI/classifier.py (Classifier.OnClose)
5019     (Classifier.map_layers_removed)
5020     (Classifier.layer_shapestore_replaced): Unsubscribe the messages
5021     in OnClose and not in map_layers_removed or
5022     layer_shapestore_replaced to make sure it always happens when the
5023     dialog is closed
5024    
5025 jonathan 1201 2003-06-13 Jonathan Coles <[email protected]>
5026    
5027 jonathan 1203 This puts back a fix for Windows where a panel is needed so that
5028     the background of the table view appears correctly.
5029    
5030     * Thuban/UI/tableview.py (TableFrame.__init__): Add a panel
5031     object that can be used by derived classes to place any
5032     controls (including the grid) onto.
5033     (QueryTableFrame.__init__): Use the panel as the parent window
5034     for all the controls. Reparent the grid so that the panel is
5035     the parent. Call UpdateStatusText() to correctly initialize
5036     the status bar.
5037    
5038     2003-06-13 Jonathan Coles <[email protected]>
5039    
5040 jonathan 1201 * Thuban/UI/dialogs.py (ThubanFrame): New: a class that inherits
5041     from wxFrame (as opposed to wxDialog like the other classes)
5042     but otherwise behaves like the other classes. This is needed
5043     for the TableView which isn't really a dialog and needs to
5044     have a status bar and control buttons.
5045    
5046     * Thuban/UI/tableview.py (TableGrid.__init__): Create an
5047     instance variable to keep track of how many rows are selected.
5048     Subscribe once to the the events we are interested in.
5049     (ThubanGrid.OnRangeSelect): Only handle event if event handling
5050     hasn't been turned off.
5051     (ThubanGrid.OnSelectCell): Only handle event if event handling
5052     hasn't been turned off.
5053     (ThubanGrid.ToggleEventListeners): Rather than subscribe None
5054     as an event listener (which changes the event handler stack)
5055     simply set an instance variable to False. This is checked in
5056     the event handlers.
5057     (ThubanGrid.GetNumberSelected): Return the number of currently
5058     selected rows.
5059     (TableFrame): Inherit from ThubanFrame so we can have a
5060     status bar and control buttons.
5061     (QueryTableFrame.__init__): Create a status bar. Fixes RTbug #1942.
5062     Explicitly set which items are selected in the operator choice and
5063     action choice so there is always a valid selection. Fixes RTbug #1941.
5064     Subscribe to grid cell selection events so we can update the
5065     status bar.
5066     (QueryTableFrame.UpdateStatusText): Update the status bar with
5067     how many rows are in the grid, how many columns, and how many
5068     rows are selected.
5069     (QueryTableFrame.OnGridSelectRange, QueryTableFrame.OnGridSelectCell):
5070     Call UpdateStatusText when cells are (de)selected.
5071     (QueryTableFrame.OnQuery): Use the string value in the value
5072     combo if either the selected item index is 0 or if the string
5073     cannot be found in the predefined list (this happens if the
5074     user changes the text). Fixes RTbug #1940.
5075     Only turn off the grid event listeners if there a query comes
5076     back with a none empty list of ids. in the case that the list
5077     is empty this causes a grid.ClearSelection() call to actually
5078     clear the grid selection which causes the selected items in
5079     the map to be deselected. Fixes RTbug #1939.
5080    
5081     * test/test_save.py (XMLWriterTest.Encode): Check return values.
5082     Fixes RTbug #1851.
5083    
5084 bh 1195 2003-06-13 Bernhard Herzog <[email protected]>
5085    
5086     * Thuban/UI/identifyview.py (IdentifyView.__init__): Call
5087     self.selected_shape with the current selection to make sure the
5088     contents of the dialog are up to date when it's shown for the
5089     first time.
5090     The dialog used to work without this by luck. The recent fix to
5091     the connector module 'broke' a 'feature' the identify view was
5092     relying on, i.e that subscribing to a message in response to
5093     receiving a message of that type would mean that the new
5094     subscriber would also be called for the same message.
5095    
5096 jonathan 1169 2003-06-12 Jonathan Coles <[email protected]>
5097 jonathan 1175
5098 jonathan 1193 * extensions/thuban/gdalwarp.cpp: Removed debug printing as
5099     the image is rendered. Fixes RTbug #1937.
5100    
5101     2003-06-12 Jonathan Coles <[email protected]>
5102    
5103 jonathan 1191 * Thuban/Lib/fileutil.py: As is done under Windows, create the
5104 jonathan 1193 user directory if it doesn't exist on a posix system.
5105     Fixes RTbug #1815.
5106 jonathan 1191
5107     * Thuban/Model/resource.py (get_user_proj_files): Moved the
5108     called to get_application_dir here, so that the directory
5109     will only be called if this method is invoked.
5110    
5111     * Thuban/UI/projdialog.py (ProjFrame.__DoOnProjAvail): Clear
5112     the projfilepath if no projection is selected.
5113    
5114     2003-06-12 Jonathan Coles <[email protected]>
5115    
5116 jonathan 1182 * Thuban/UI/legend.py (ScaleBarBitmap.__SetScale): Don't draw
5117     the scalebar if the current map has no projection set.
5118    
5119     * Thuban/UI/projdialog.py (ProjFrame.__DoOnProjAvail): Set the
5120     projfilepath label to just the basename of the projection file
5121     rather than include the entire path.
5122    
5123     * Thuban/Model/resource.py: Fix missed proj functions that
5124     needed to be renamed.
5125    
5126     2003-06-12 Jonathan Coles <[email protected]>
5127    
5128 jonathan 1178 * Thuban/Model/classification.py: Removed assert statements that
5129     tested if the variable was an instance of Color.
5130    
5131     * Thuban/Model/color.py (Color): Remove commented code that isn't
5132     used.
5133     (Transparent): Renamed from NoColor. Doesn't inherit from Color.
5134     Fixes RTbug #1835.
5135     (Transparent.__eq__, Transparent.__ne, Transparent.__repr): New.
5136     Needed now that the class doesn't inherit from Color.
5137    
5138     2003-06-12 Jonathan Coles <[email protected]>
5139    
5140 jonathan 1175 * test/test_save.py (XMLWriterTest.testEncode): Explicitly
5141     check unicode strings.
5142    
5143     * test/test_layer.py: Check for existence of gdal.
5144    
5145     2003-06-12 Jonathan Coles <[email protected]>
5146 jonathan 1172
5147     * Thuban/Model/xmlreader.py: New. Contains the XMLReader class
5148     that was in load.py
5149 jonathan 1169
5150 jonathan 1172 * Thuban/Model/xmlwriter.py: New. Contains the XMLWriter class
5151     that was in save.py
5152    
5153     2003-06-12 Jonathan Coles <[email protected]>
5154    
5155 jonathan 1169 This is largely a collection of bug fixes. We also handle the
5156     case where gdal is not on the system. The XMLReader and XMLWriter
5157     classes were moved into there own files to resolve some circular
5158     import references and because they shouldn't really be in the
5159     file that is dediciated to reading/writing session files since
5160     they are also used elsewhere.
5161    
5162     * Thuban/Model/classgen.py: Renamed functions to follow the
5163     function_names_with_underscores style. Fixes RTbug #1903.
5164     (calculate_quantiles): Raise ValueError if 'percents' is invalid.
5165    
5166     * Thuban/Model/layer.py: Import gdal only if it available.
5167     (RasterLayer): Handle the case where the gdal library is unavailable.
5168     Addresses RTbug #1877.
5169    
5170     * Thuban/Model/load.py (XMLReader): Moved into seperate file
5171     xmlreader.py.
5172    
5173 jonathan 1172 2003-06-12 Jonathan Coles <[email protected]>
5174    
5175     This is largely a collection of bug fixes. We also handle the
5176     case where gdal is not on the system. The XMLReader and XMLWriter
5177     classes were moved into there own files to resolve some circular
5178     import references and because they shouldn't really be in the
5179     file that is dediciated to reading/writing session files since
5180     they are also used elsewhere.
5181    
5182     * Thuban/Model/classgen.py: Renamed functions to follow the
5183     function_names_with_underscores style. Fixes RTbug #1903.
5184     (calculate_quantiles): Raise ValueError if 'percents' is invalid.
5185    
5186     * Thuban/Model/layer.py: Import gdal only if it available.
5187     (RasterLayer): Handle the case where the gdal library is unavailable.
5188     Addresses RTbug #1877.
5189    
5190     * Thuban/Model/load.py (XMLReader): Moved into seperate file
5191     xmlreader.py.
5192    
5193 jonathan 1169 * Thuban/Model/save.py (escape, XMLWriter): Moved into seperate
5194     file xmlwriter.py.
5195    
5196     * Thuban/Model/resource.py: Renamed functions to following the
5197     function_names_with_underscores style.
5198     (has_gdal_support): New function that returns true if the gdal
5199     library is available. Addresses RTbug #1877.
5200    
5201     * Thuban/UI/application.py (ThubanApplication.OpenSession):
5202     Display a message box if the gdal library is not available, but
5203     only if there are any layers that would use it. Addresses RTbug #1877.
5204    
5205     * Thuban/UI/classgen.py: Use renamed projection resource functions.
5206     (GenUniformPanel.__CalcStepping): Fix a slight discrepency
5207     when using integers versus floats.
5208    
5209     * Thuban/UI/mainwindow.py (_has_gdal_support): New. Used to
5210     determine if the "Add Image Layer" menu option should be
5211     greyed out or not. Addresses RTbug #1877.
5212    
5213     * Thuban/UI/projdialog.py: Use renamed projection resource functions.
5214    
5215     * Thuban/UI/renderer.py (MapRenderer.render_map): Only try to
5216     optimize if a raster layer is visible. Fixes RTbug #1931.
5217     Only draw the raster layer if the gdal library is available.
5218     Addresses RTbug #1877.
5219    
5220     * test/test_classgen.py: Add tests for generate_singletons,
5221     generate_uniform_distribution, generate_quantiles. Fixes RTbug #1903.
5222     (test_calculate_quantiles): Fix some tests to catch the new
5223     ValueError that is raised.
5224    
5225     * test/test_proj.py: Use renamed projection resource functions.
5226    
5227     * test/test_save.py (SaveSessionTest.testClassifiedLayer): New
5228     test for saving classified layers. Fixes RTbug #1902.
5229     (XMLWriterTest): New. Tests the XMLWriter class. Fixes RTbug #1851.
5230    
5231 jan 1156 2003-06-12 Jan-Oliver Wagner <[email protected]>
5232    
5233     Fix for http://intevation.de/rt/webrt?serial_num=1900.
5234    
5235     * Thuban/UI/multiplechoicedialog.py: New. A multiple choice dialog.
5236    
5237     * Thuban/UI/mainwindow.py: import wxMultipleChoiceDialog from
5238     multiplechoicedialog.py rather than from the wxPython library.
5239    
5240 frank 1151 2003-06-11 Frank Koormann <[email protected]>
5241    
5242 frank 1152 * Thuban/Lib/fileutil.py (get_application_dir): Minor stability
5243     update.
5244    
5245     2003-06-11 Frank Koormann <[email protected]>
5246    
5247 frank 1151 * Thuban/Lib/fileutil.py (get_application_dir): New function to
5248     determine the absolute .thuban/thuban directory under
5249     "posix" (os.expanduser) and "nt" (read AppData registry key).
5250    
5251     * Thuban/Model/resource.py: Use get_application_dir
5252    
5253     * Thuban/UI/application.py (ThubanApplication.read_startup_files):
5254     Use get_application_dir.
5255    
5256 bh 1143 2003-06-10 Bernhard Herzog <[email protected]>
5257    
5258 bh 1147 * Thuban/UI/tableview.py (LayerTableFrame.__init__): Subscribe to
5259     the messages MAP_LAYERS_REMOVED messages
5260     (LayerTableFrame.OnClose): Unsubscribe from it.
5261     (LayerTableFrame.map_layers_removed): New. Receiver for
5262     MAP_LAYERS_REMOVED. Close the dialog when the layer whose the
5263     dialog is showing is removed.
5264    
5265     2003-06-10 Bernhard Herzog <[email protected]>
5266    
5267 bh 1145 * Thuban/Lib/connector.py (Connector.Issue): Iterate over a copy
5268     of the receivers list so that unsubscribing in a receiver doesn't
5269     modify it while iterating over it.
5270    
5271     * test/test_connector.py
5272     (ConnectorTest.test_disconnect_in_receiver): New. Test whether
5273     unsubscribing in a receiver works correctly. See docstring for
5274     details
5275    
5276     2003-06-10 Bernhard Herzog <[email protected]>
5277    
5278 bh 1143 * Thuban/Model/messages.py (LAYER_SHAPESTORE_REPLACED): New
5279     message.
5280    
5281     * Thuban/Model/layer.py (Layer.SetShapeStore): Send
5282     LAYER_SHAPESTORE_REPLACED when the shapestore changes. A
5283     LAYER_CHANGED will still be sent if the classification changes.
5284    
5285     * Thuban/UI/classifier.py (Classifier.__init__): Add the map as
5286     parameter so we can subscribe to some of its messages
5287     (Classifier.__init__): Subscribe to the map's MAP_LAYERS_REMOVED
5288     and the layer's LAYER_SHAPESTORE_REPLACED
5289     (Classifier.unsubscribe_messages): New. Unsubscribe from message
5290     subscribed to in __init__
5291     (Classifier.map_layers_removed)
5292     (Classifier.layer_shapestore_replaced): receivers for the messages
5293     subscribed to in __init__. Unsubscribe and close the dialog
5294    
5295     * Thuban/UI/mainwindow.py (MainWindow.OpenLayerProperties): Pass
5296     the map to the Classifier dialog
5297    
5298     * test/test_layer.py (SetShapeStoreTests): Derive from
5299     SubscriberMixin as well so we can test messages
5300     (SetShapeStoreTests.setUp): Subscribe to some of the layer's
5301     messages
5302     (SetShapeStoreTests.tearDown): Clear the messages again
5303     (SetShapeStoreTests.test_sanity): Expand the doc-string and check
5304     for the modified flag too
5305     (SetShapeStoreTests.test_set_shape_store_modified_flag): New test
5306     to check whether SetShapeStore sets the modified flag
5307     (SetShapeStoreTests.test_set_shape_store_different_field_name)
5308     (SetShapeStoreTests.test_set_shape_store_same_field)
5309     (SetShapeStoreTests.test_set_shape_store_same_field_different_type):
5310     Add tests for the messages. This checks both the new
5311     LAYER_SHAPESTORE_REPLACED and the older LAYER_CHANGED
5312    
5313 jan 1141 2003-06-06 Jan-Oliver Wagner <[email protected]>
5314    
5315     * Thuban/UI/mainwindow.py: Improved and partly added help texts for
5316     the menu items.
5317    
5318 frank 1134 2003-06-05 Frank Koormann <[email protected]>
5319    
5320 frank 1139 * Thuban/UI/identifyview.py (IdentifyView.__init__):
5321     Layout reimplemented without panel. Make life easier to fit the list
5322     in the dialog.
5323    
5324     2003-06-05 Frank Koormann <[email protected]>
5325    
5326 frank 1137 * Thuban/UI/projdialog.py (ProjFrame.__init__): Fill the projchoice
5327     once on initialisation (Former implementation resulted in multiple
5328     entries for each projection).
5329     (ProjFrame.__FillAvailList): selectProj as second optional parameter,
5330     if set, select the projection found under the specified name. This
5331     overwrites any other selection estimate.
5332     Removed projchoice filling from this method.
5333     (ProjFrame._OnSave, ProjFrame._OnAddToList):
5334     Updated call of ProjFrame.__FillAvailList
5335     (LCCPanel._DoLayout): Moved parameter controls in more common order.
5336    
5337     * Resources/Projections/defaults.proj: Extended defaults representing
5338     various common European projections.
5339    
5340     2003-06-05 Frank Koormann <[email protected]>
5341    
5342 frank 1134 * Thuban/UI/identifyview.py (IdentifyView.__init__):
5343     Use ListCtrl instead of GridCtrl
5344    
5345     * Thuban/Model/resource.py:
5346     Guess location of .thuban directory from tempdir parent directory.
5347    
5348     * Thuban/UI/application.py (ThubanApplication.read_startup_files):
5349     Guess location of .thuban directory from tempdir parent directory.
5350    
5351 bh 1130 2003-06-04 Bernhard Herzog <[email protected]>
5352    
5353     Do not cache the values returned by the tree widget's
5354     GetFirstChild and GetNextChild methods because it led to lots of
5355     segfaults. The new way requires more brute force but is more
5356     reliable.
5357    
5358     * Thuban/UI/legend.py (LegendTree.__init__): Remove instance
5359     variable layer2id
5360     (LegendTree.find_layer): New method to do with brute force what
5361     layer2id tried to accomplish
5362     (LegendTree._OnMsgLayerChanged)
5363     (LegendTree._OnMsgLayerTitleChanged, LegendTree.__ShowHideLayer):
5364     Use find_layer instead of layer2id
5365     (LegendTree.__RemoveLayer, LegendTree.__AddLayer): No need to
5366     update layer2id anymore
5367     (LegendTree._OnMsgMapLayersRemoved)
5368     (LegendTree._OnMsgMapLayersAdded): Get by without layer2id.
5369    
5370 tkoester 1128 2003-06-03 Thomas Koester <[email protected]>
5371    
5372     * Thuban/Model/classgen.py (GenQuantiles0): New function.
5373    
5374 bh 1120 2003-06-02 Bernhard Herzog <[email protected]>
5375    
5376 bh 1127 * Thuban/UI/mainwindow.py (layer_rename command, table_rename command):
5377     New commands.
5378     (main_menu): Add the new commands.
5379     (MainWindow.TableRename): New. Implementation of the table_rename
5380     command.
5381     (MainWindow.RenameLayer): New. Implementation of the layer_rename
5382     command.
5383    
5384     * Thuban/Model/session.py (Session.AddTable): call self.changed to
5385     set the modified flag
5386    
5387     * test/test_session.py (TestSessionSimple.test_add_table): Test
5388     whether the modified flag is set properly
5389    
5390     * Thuban/Model/base.py (TitledObject.SetTitle): Call changed
5391     instead of issue so that the modified flags get updated.
5392    
5393     * test/test_base.py (SomeTitledObject): Derive from Modifiable
5394     instead of Publisher to reflect reality better and to accomodate
5395     the fact that SetTitle now calls changed instead of issue
5396    
5397     2003-06-02 Bernhard Herzog <[email protected]>
5398    
5399     * Thuban/UI/classgen.py (GenQuantilesPanel.GetList): Resource
5400     acquisition has to happen before the try in a try-finally.
5401    
5402     2003-06-02 Bernhard Herzog <[email protected]>
5403    
5404 bh 1120 * Thuban/UI/legend.py (LegendTree._OnMsgMapLayersRemoved): It's
5405     possible that a layer is removed that is not currently selected in
5406     the legend so don't check for this.
5407    
5408 bh 1112 2003-05-30 Bernhard Herzog <[email protected]>
5409    
5410 bh 1118 * Thuban/Model/layer.py (Layer.Destroy): Set all instance
5411     variables to None that have direct or indirect references to
5412     shapefiles or dbf files to make sure that they do go away and the
5413     files are closed.
5414    
5415     2003-05-30 Bernhard Herzog <[email protected]>
5416    
5417 bh 1116 * Thuban/UI/legend.py (LegendTree.GetRootItem): Reset
5418     availImgListIndices when a new image list is created
5419    
5420     2003-05-30 Bernhard Herzog <[email protected]>
5421    
5422 bh 1114 * Thuban/UI/legend.py (LegendTree.__init__): New instance variable
5423     changing_selection to indicate whether the LegendTree code itself
5424     is currently changing the selection
5425     (LegendTree.normalize_selection): New method to normalize the
5426     selection by selecting the layer item even if the user clicked on
5427     the classification.
5428     (LegendTree._OnSelChanged): normalize the selection. This works
5429     around a bug in wx which doesn't keep track of the selection
5430     properly when subtrees are deleted.
5431    
5432     2003-05-30 Bernhard Herzog <[email protected]>
5433    
5434 bh 1112 * Thuban/UI/view.py (MapCanvas.set_view_transform): Limit the
5435     maximum and minimum scale factors.
5436    
5437     * test/test_classgen.py (ClassGenTest.test): Update to reflect the
5438     changes in classgen.py
5439    
5440 jonathan 1109 2003-05-30 Jonathan Coles <[email protected]>
5441    
5442     * Thuban/Model/classgen.py: Remove ClassGenerator class but make
5443     all the methods functions. Fixes RTBug #1903.
5444    
5445     * Thuban/Model/map.py (Map.TopLayer, Map.BottomLayer): Renamed
5446     to MoveLayerToTop and MoveLayerToBottom respectively. Fixes
5447     RTBug #1907.
5448    
5449     * Thuban/UI/classgen.py: Use classgen functions that were part
5450     of the ClassGenerator class. Put try/finally blocks around
5451     code that uses wxBeginBusyCursor()/wxEndBusyCursor(). Fixes
5452     RTBug #1904.
5453    
5454     * Thuban/UI/classifier.py: Remove unused import of ClassGenerator.
5455    
5456     * Thuban/UI/legend.py: The legend was cleared and repopulated any
5457     time something changed which caused some state to be lost such
5458     as which children were expanded or collapsed. Fixes RTBug #1901.
5459     (LegendTree._OnMsgMapLayersAdded): Add only new layers.
5460     (LegendTree.__OnMsgMapLayersRemoved): Remove layers that exist in
5461     the legend but not in the map.
5462     (LegendTree.__FillTree): Move main functionality out into smaller
5463     methods that can be used by other methods.
5464     (LegendTree.__FillTreeLayer): Reuse old slots in the image list
5465     if they are available.
5466     (LegendTree.DeleteAllItems): Renamed from __DeleteAllItems so
5467     that we override the wxTreeCtrl method. Iterate over children
5468     and call __RemoveLayer.
5469     (LegendTree.__AddLayer): New. Add a new layer to the legend.
5470     (LegendTree.__RemoveLayer): Remove a layer from the legend.
5471     (LegendTree.DeleteChildren): New, overrides wxTreeCtrl method.
5472     Should only be called with the id of a layer branch.
5473     (LegendTree.GetRootItem): New, overrides wxTreeCtrl method.
5474     Returns the root item or creates one if necessary.
5475    
5476     * Thuban/UI/renderer.py (MapRenderer.draw_raster_layer): Call
5477     ProjectRasterFile with tuple arguments instead of strings.
5478    
5479     * Thuban/UI/tableview.py (QueryTableFrame.OnQuery): Wrap code
5480     with try/finally. Fixes RTBug #1904.
5481    
5482     * Thuban/UI/view.py (MapCanvas.OnPaint): Wrap code
5483     with try/finally. Fixes RTBug #1904.
5484     (MapCanvas.FitSelectedToWindow): If a single point is selected
5485     simply center it on the display. Fixes RTBug #1849.
5486    
5487     * extensions/thuban/gdalwarp.cpp: Removed code that allowed gdalwarp
5488     to be compiled as a standalone app. Now the code can only be
5489     called from Python which simplifies the parameter passing.
5490     (ProjectRasterFile): Handle Python arguments. Remove code that
5491     checks for a destination dataset. Add more clean up code.
5492    
5493     * test/test_map.py (TestMapWithContents.test_raise_layer_top,
5494     TestMapWithContents.test_lower_layer_bottom):
5495     Test Map.MoveLayerToTop() and Map.MoveLayerToBottom() respectively.
5496     Fixes RTBug #1907.
5497    
5498     * Thuban/UI/mainwindow.py (MainWindow.ToggleLegend): Apply a full
5499     extent to the map when the legend is toggled. Fixes RTBug #1881.
5500    
5501 jan 1097 2003-05-29 Jan-Oliver Wagner <[email protected]>
5502    
5503     * Thuban/UI/tableview.py (LayerTableFrame.OnClose): Bug-fix: Now
5504     unsubscribes all that is subcribed in __init__.
5505    
5506 bh 1089 2003-05-28 Bernhard Herzog <[email protected]>
5507    
5508 bh 1095 * Thuban/UI/mainwindow.py (MainWindow.DuplicateLayer)
5509     (MainWindow.CanDuplicateLayer): New methods to implement the
5510     Layer/Duplicate command.
5511     (layer_duplicate command): New.
5512     (main_menu): Add layer_duplicate to the Layer menu.
5513    
5514     2003-05-28 Bernhard Herzog <[email protected]>
5515    
5516 bh 1093 * Thuban/UI/tableview.py (NullRenderer.Draw): New. Our own
5517     renderer so that NULL/None values get displayed differently (by a
5518     gray rectangle).
5519     (TableGrid.__init__): Override the default renderers
5520    
5521     2003-05-28 Bernhard Herzog <[email protected]>
5522    
5523 bh 1089 * Thuban/Model/layer.py (Layer.SetShapeStore): Set the
5524     classification to "None" if the type of the field has changed.
5525    
5526     * test/test_layer.py (SetShapeStoreTests): New. Class with a few
5527     test for the Layer.SetShapeStore method
5528    
5529 jan 1087 2003-05-28 Jan-Oliver Wagner <[email protected]>
5530 jan 1085
5531 jan 1087 * Thuban/Model/layer.py (Layer.TreeInfo): Fixed a bug (a layer
5532     does not necessarily have a filename).
5533    
5534     2003-05-28 Jan-Oliver Wagner <[email protected]>
5535    
5536 jan 1085 * Thuban/UI/mainwindow.py (MainWindow.TableClose, MainWindow.TableShow):
5537     sort the selection list for the dialog.
5538    
5539 frank 1083 2003-05-28 Frank Koormann <[email protected]>
5540    
5541     * extensions/thuban/wxproj.cpp
5542     (project_point): Removed cast to int for projected point coordinates.
5543     (shape_centroid): Return last point if all polygon vertices fall
5544     to one point.
5545    
5546 bh 1079 2003-05-28 Bernhard Herzog <[email protected]>
5547    
5548 bh 1081 * Thuban/UI/mainwindow.py (_can_unjoin): Add doc-string and cope
5549     with layers that don't have shapestores, i.e. raster layers.
5550    
5551     2003-05-28 Bernhard Herzog <[email protected]>
5552    
5553 bh 1079 * Thuban/Model/table.py (DBFTable.__init__): Omit the extension
5554     when determining the title from the filename.
5555    
5556     * test/test_dbf_table.py (TestDBFTable.test_title): Update to
5557     reflect changes in the way the title is derived from the filename
5558    
5559 frank 1077 2003-05-28 Frank Koormann <[email protected]>
5560    
5561     * Thuban/UI/mainwindow.py (MainWindow.TableShow):
5562     Added wxDEFAULT_DIALOG_STYLE to show table dialog styles.
5563    
5564 bh 1069 2003-05-27 Bernhard Herzog <[email protected]>
5565    
5566 bh 1075 * Thuban/UI/mainwindow.py (MainWindow.delegated_messages): Also
5567     delegate SelectedLayer.
5568     (MainWindow.LayerUnjoinTable): Implement.
5569     (_can_unjoin): New. Helper function for the sensitivity of the
5570     layer/unjoin command.
5571    
5572     * Thuban/Model/data.py (ShapefileStore.OrigShapeStore)
5573     (DerivedShapeStore.OrigShapeStore): New. Return the original
5574     shapestore. Used to figure out how to unjoin.
5575     (DerivedShapeStore.Shapefile): Fix a typo.
5576    
5577     2003-05-27 Bernhard Herzog <[email protected]>
5578    
5579 bh 1073 * Thuban/UI/join.py (JoinDialog): Extend to handle layer joins as
5580     well
5581     (JoinDialog.__init__): Use the layer parameter and only build the
5582     left choice when a layer is given
5583     (JoinDialog.OnJoin): Handle layer joins as well
5584     (JoinDialog.OnLeftTable, JoinDialog.OnRightTable): Handle the case
5585     that the user selects the "Select..." item. The sensitivitly
5586     updating is now in update_sensitivity
5587     (JoinDialog.y): New method to refactor the sensitivity update of
5588     the join button into its own method.
5589    
5590     * Thuban/UI/mainwindow.py (MainWindow.LayerJoinTable): Implement.
5591    
5592     2003-05-27 Bernhard Herzog <[email protected]>
5593    
5594 bh 1071 * Thuban/UI/mainwindow.py (table_close command): Make it sensitive
5595     iff there are unreferenced tables in the session
5596    
5597     2003-05-27 Bernhard Herzog <[email protected]>
5598    
5599 bh 1069 * Thuban/Model/messages.py (TABLE_REMOVED): New message.
5600    
5601     * Thuban/Model/session.py (Session.UnreferencedTables): New method
5602     to return tables that are not referenced by other tables or shape
5603     stores and can be removed.
5604     (Session.RemoveTable): Issue a TABLE_REMOVED message after
5605     removing the table
5606    
5607     * Thuban/UI/mainwindow.py: Remove unused imports
5608     (MainWindow.TableClose): Implement.
5609    
5610     * Thuban/UI/tableview.py (TableFrame.__init__): Subscribe to some
5611     messages so that the frame will be automatically closed when a new
5612     session is opened or the table is removed.
5613     (TableFrame.OnClose): Unsubscribe the Subscriptions made in
5614     __init__
5615     (TableFrame.close_on_session_replaced)
5616     (TableFrame.close_on_table_removed): New. Subscribers that close
5617     the window
5618    
5619     * test/test_session.py (TestSessionMessages.test_remove_table)
5620     (TestSessionSimple.test_remove_table): Move the test to
5621     TestSessionSimple and add test for the TABLE_REMOVED message
5622     (TestSessionBase.setUp): Also subscribe to TABLE_REMOVED
5623     (TestSessionSimple.test_unreferenced_tables) New. Test for the
5624     UnreferencedTables method.
5625     (UnreferencedTablesTests): New. Class with some more sophisticated
5626     tests for UnreferencedTables.
5627    
5628 frank 1065 2003-05-27 Frank Koormann <[email protected]>
5629    
5630 frank 1067 * Thuban/UI/tableview.py (QueryTableFrame.__init__): The "_S_election"
5631     display has some unwanted side effects. Removed again.
5632    
5633     2003-05-27 Frank Koormann <[email protected]>
5634    
5635 frank 1065 * Resources/Bitmaps/legend_icon_layer.xpm: New, icon for legend.
5636    
5637     * Thuban/UI/legend.py (LegendTree.__FillTree): Use "legend_icon_layer"
5638    
5639 jan 1062 2003-05-27 Jan-Oliver Wagner <[email protected]>
5640    
5641 bh 1069 * test/test_menu.py (MenuTest.test): Added test for
5642     Menu.RemoveItem().
5643 jan 1062
5644 bh 1069 * Thuban/UI/menu.py (Menu.RemoveItem): New. Remove an item from
5645     the menu.
5646 jan 1062
5647 frank 1059 2003-05-27 Frank Koormann <[email protected]>
5648    
5649     Nonmodal dialogs without parent (i.e. they can fall behind the main
5650     window)
5651    
5652     * Thuban/UI/mainwindow.py (MainWindow.OnClose): Explicitly destroy
5653     all dialogs in the dialogs dictionary and the canvas.
5654    
5655     * Thuban/UI/dialogs.py (NonModalNonParentDialog): New class, without
5656     parent, i.e. can fall behind other windows.
5657     (NonModalDialog.OnClose): Check is dialog is in mainwindow.dialog
5658     dictionary before removing it.
5659    
5660     * Thuban/UI/classifier.py: Dialog derived from NonModalNonParentDialog
5661    
5662     * Thuban/UI/projdialog.py: Dialog derived from NonModalNonParentDialog
5663     * Thuban/UI/tableview.py: Dialog derived from NonModalNonParentDialog
5664     * Thuban/UI/tree.py: Dialog derived from NonModalNonParentDialog
5665    
5666 bh 1053 2003-05-27 Bernhard Herzog <[email protected]>
5667    
5668 bh 1055 * Thuban/UI/mainwindow.py (MainWindow.ShowTableView): New. Open a
5669     tableview dialog
5670     (MainWindow.TableShow): Use ShowTableView to open the dialogs.
5671     Also, don't use the table's titles as the dialog names. The titles
5672     aren't guaranteed to be unique.
5673     (MainWindow.TableOpen): Open a table view dialog after opening the
5674     table
5675    
5676     2003-05-27 Bernhard Herzog <[email protected]>
5677    
5678 bh 1053 * Thuban/UI/mainwindow.py: Remove the Table/Hide menu item. Its
5679     effect can be achieved by simply closing the window showing the
5680     table.
5681     (MainWindow.TableHide): Removed.
5682     (main_menu): Removed "table_hide"
5683    
5684 frank 1051 2003-05-27 Frank Koormann <[email protected]>
5685    
5686     Fix legend tree display problems under Win32
5687    
5688     * Thuban/UI/legend.py: BMP_SIZE_W = 15
5689     (LegendTree.__FillTree): Display "legend_icon_map.xpm" with layer title.
5690     (LegendTree.__FillTreeLayer): Explicitely set SelectedImage.
5691    
5692     * Resources/Bitmaps/legend_icon_map.xpm: New icon for legend.
5693    
5694 jan 1048 2003-05-27 Jan-Oliver Wagner <[email protected]>
5695    
5696     * Thuban/UI/menu.py (Menu.InsertSeparator): Additional optional parameter
5697     'after' now allows to insert separators almost anywhere in the menu.
5698    
5699 frank 1046 2003-05-27 Frank Koormann <[email protected]>
5700    
5701     * Thuban/UI/tableview.py (QueryTableFrame.__init__): Underline the
5702     "S" of selection box label to hint on hot key (Alt-S). Works under
5703     Win32 but is ignored under GTK.
5704    
5705     2003-05-26 Frank Koormann <[email protected]>
5706    
5707     * Thuban/UI/projdialog.py (ProjFrame.__do_layout, ProjPanel._DoLayout):
5708     Center Choices.
5709    
5710 bh 1038 2003-05-26 Bernhard Herzog <[email protected]>
5711    
5712 bh 1044 Remove the Precision methods again. They're too DBF specific to be
5713     part of the table interface and they're only used in table_to_dbf
5714     anyway.
5715    
5716     * Thuban/Model/transientdb.py (TransientTableBase.Width):Use a
5717     fixed precision of 12 for doubles.
5718     (TransientTableBase.Precision): Removed
5719     (AutoTransientTable.Width): Delegate to self.table.
5720    
5721     * Thuban/Model/table.py (DBFTable.Precision)
5722     (MemoryTable.Precision): Removed.
5723     (MemoryTable.Width): Use a fixed precision of 12 for doubles.
5724     (table_to_dbf): Use a fixed precision of 12 for floats unless the
5725     column object specifies something else.
5726    
5727     * test/test_dbf_table.py (TestTableToDBF.test_table_to_dbf): New.
5728     test for table_to_dbf
5729    
5730     2003-05-26 Bernhard Herzog <[email protected]>
5731    
5732     * test/test_transientdb.py
5733     (TestTransientTable.run_iceland_political_tests): Fix a comment.
5734    
5735     2003-05-26 Bernhard Herzog <[email protected]>
5736    
5737 bh 1038 * Thuban/UI/mainwindow.py (MainWindow.TableOpen): Real
5738     implementation. Mark parts of the file format strings for
5739     localization.
5740    
5741     * Thuban/Model/session.py (Session.OpenTableFile): New. Open a dbf
5742     file and add the table to the tables managed by the session
5743    
5744 bh 1040 * test/test_session.py (TestSessionSimple.test_open_table_file):
5745     New. test case for OpenTableFile
5746    
5747 jan 1033 2003-05-26 Jan-Oliver Wagner <[email protected]>
5748    
5749 jan 1035 * Thuban/UI/controls.py, Thuban/UI/identifyview.py, Thuban/UI/join.py,
5750     Thuban/UI/labeldialog.py, Thuban/UI/mainwindow.py,
5751     Thuban/UI/proj4dialog.py, Thuban/UI/tableview.py, Thuban/UI/view.py:
5752     Replace the true/false of wxWindows by True/False of Python 2.2.1.
5753    
5754     2003-05-26 Jan-Oliver Wagner <[email protected]>
5755    
5756 bh 1038 * Thuban/UI/tableview.py (LayerTableFrame.__init__): If there is
5757     already a selection present, update the grid accordingly.
5758 jan 1033
5759     * Thuban/UI/mainwindow.py (MainWindow.TableShow): Make the dialog
5760     resizeable and increase its initial size.
5761    
5762 frank 1030 2003-05-26 Frank Koormann <[email protected]>
5763    
5764     Table export functionality
5765    
5766     * Thuban/Model/table.py (DBFTable.Width, MemoryTable.Width):
5767     Return width (in characters) for a column.
5768     (DBFTable.Precision, MemoryTable.Precision): Return decimal precision.
5769     (table_to_dbf): Write table to dbf file.
5770     (table_to_csv): Write table to csv file.
5771    
5772     * Thuban/Model/transientdb.py (TransientTableBase.Width,
5773     TransientTableBase.Precision): Return column width and precision.
5774    
5775     * Thuban/UI/tableview.py (QueryTableFrame.OnSaveAs): Call table_to_dbf
5776     or table_to_csv depending on file selection.
5777    
5778     * test/test_dbf_table.py:
5779     Test table_to_dbf (extension of former part of test).
5780    
5781     * test/test_csv_table.py:
5782     Test table_to_csv.
5783    
5784 jan 1021 2003-05-23 Jan-Oliver Wagner <[email protected]>
5785    
5786 jan 1024 * Thuban/UI/join.py (JoinDialog.OnJoin): Use _() for strings.
5787     Use QueryTableFrame instead of TableFrame.
5788 jan 1021
5789 jan 1024 * Thuban/UI/mainwindow.py (MainWindow.LayerShowTable): Prefix the
5790     table window with 'Layer Table:' instead of 'Table:'.
5791    
5792     2003-05-23 Jan-Oliver Wagner <[email protected]>
5793    
5794     Give all tables a title via mix-in TitledObject.LayerShowTable
5795    
5796 jan 1021 * Thuban/Model/base.py (TitledObject.SetTitle): Call method 'issue'
5797     only if it exists.
5798    
5799     * Thuban/Model/table.py (DBFTable, MemoryTable): mix-in TitledObject
5800     and call its init-method with a default title. Remove Title() method.
5801    
5802     * Thuban/Model/transientdb.py (TransientTable, TransientJoinedTable,
5803     AutoTransientTable): mix-in TitledObject and call its init-method with
5804     a default title. Remove Title() method.
5805    
5806 bh 1017 2003-05-23 Bernhard Herzog <[email protected]>
5807    
5808     * Thuban/Model/session.py (Session.AddShapeStore): Define
5809     AddShapeStore analogously to AddTable.
5810    
5811     * test/test_session.py (TestSessionSimple.test_add_shapestore):
5812     New. Test for AddShapeStore
5813    
5814 jan 1015 2003-05-23 Jan-Oliver Wagner <[email protected]>
5815    
5816     Introducing QueryTableFrame and a very coarse ShowTable implementation.
5817    
5818     * Thuban/UI/tableview.py (LayerTableFrame, QueryTableFrame): Split the
5819     class LayerTableFrame into two classes, LayerTableFrame and QueryTableFrame.
5820     The latter implements the selection GUI without dependency on a layer.
5821     LayerTableFrame now is derived from QueryTableFrame and connects
5822     to a layer.
5823    
5824     * Thuban/UI/mainwindow.py (MainWindow.TableShow): A very coarse
5825     implementation that still needs work.
5826    
5827     * Thuban/Model/layer.py (Layer.TreeInfo): Added filename.
5828    
5829 frank 1011 2003-05-22 Frank Koormann <[email protected]>
5830    
5831     * Thuban/Model/transientdb.py (TransientJoinedTable.__init__):
5832     Added "outer_join = False" as optional parameter.
5833     (TransientJoinedTable.create): If outer join is true, perform a
5834     "LEFT OUTER JOIN" instead of "JOIN", which preserves all records of
5835     the left table. Records not matching are filled with 0 / None.
5836    
5837     * Thuban/UI/join.py (JoinDialog.__init__): Checkbox for outer join.
5838     (JoinDialog.OnJoin): Consider outer join check box.
5839    
5840 bh 1006 2003-05-22 Bernhard Herzog <[email protected]>
5841    
5842 bh 1008 * Thuban/UI/join.py (JoinDialog.OnJoin): Use exc_info in a
5843     somewhat safer way. Storing the traceback in a local variable can
5844     lead to memory leaks
5845    
5846     2003-05-22 Bernhard Herzog <[email protected]>
5847    
5848 bh 1006 * Thuban/UI/join.py (JoinDialog.OnJoin): Make sure to really call
5849     the wxMessageDialog's Destroy() method.
5850    
5851 frank 1004 2003-05-22 Frank Koormann <[email protected]>
5852    
5853     * Thuban/UI/join.py (JoinDialog.__init__): Make use of
5854     TransientTable.Title()
5855    
5856     2003-05-22 Frank Koormann <[email protected]>
5857    
5858     Join Dialog, initial version.
5859    
5860     * Thuban/UI/mainwindow.py (MainWindow.TableJoin): Removed print.
5861    
5862     * Thuban/UI/join.py (JoinDialog): Functional implementation of
5863     former framework. Renamed Table1/Table2 to LeftTable/RightTable
5864     in all occurences.
5865    
5866     * Thuban/Model/transientdb.py (TransientJoinedTable.__doc__):
5867     Typo fixed.
5868    
5869 bh 995 2003-05-22 Bernhard Herzog <[email protected]>
5870    
5871 bh 999 Give the tables titles so that the GUI can display more meaningful
5872     names. For now the titles are fixed but depend on e.g. filenames
5873     or the titles of the joined tables.
5874    
5875     * Thuban/Model/transientdb.py (TransientTable.Title)
5876     (TransientJoinedTable.Title, AutoTransientTable.Title): New.
5877    
5878     * Thuban/Model/table.py (DBFTable.Title, MemoryTable.Title): New.
5879    
5880     * test/test_transientdb.py
5881     (TestTransientTable.test_auto_transient_table_title): New. Test
5882     for the Title method
5883     (TestTransientTable.test_transient_joined_table)
5884     (TestTransientTable.test_transient_table): Add test for the Title
5885     methods
5886    
5887     * test/test_memory_table.py (TestMemoryTable.test_title): New.
5888     Test for the Title method
5889    
5890     * test/test_dbf_table.py (TestDBFTable.test_title): New. Test for
5891     the Title method
5892    
5893     2003-05-22 Bernhard Herzog <[email protected]>
5894    
5895 bh 997 * test/test_layer.py (TestLayer.setUp, TestLayer.tearDown):
5896     Provide a better way to destroy the layers
5897     (TestLayer.test_base_layer, TestLayer.test_arc_layer)
5898     (TestLayer.test_point_layer, TestLayer.test_empty_layer)
5899     (TestLayer.test_polygon_layer, TestLayer.test_get_field_type): Use
5900     the new way to destroy the layers.
5901     (TestLayer.test_derived_store): New. Test for using a layer with a
5902     DerivedShapeStore
5903    
5904     * Thuban/Model/layer.py (Layer.SetShapeStore): Only set the
5905     filename if the shape store actually has one.
5906    
5907     2003-05-22 Bernhard Herzog <[email protected]>
5908    
5909 bh 995 * Thuban/Model/table.py (DBFTable.FileName): New. Accessor method
5910     for the filename
5911    
5912     * test/test_dbf_table.py (TestDBFTable.test_filename): New. Test
5913     for the FileName method
5914     (TestDBFTableWriting.test_write): Fix spelling of filename
5915    
5916 tkoester 993 2003-05-22 Thomas Koester <[email protected]>
5917    
5918     * Thuban/Model/range.py, test/test_range.py: Brought over new Range
5919     from SciParam that now really is immutable.
5920    
5921 frank 992 2003-05-22 Frank Koormann <[email protected]>
5922    
5923     Layer Top/Bottom placement added to legend.
5924    
5925     * Thuban/UI/legend.py
5926     (LegendPanel._OnMoveTop(), LayerPanel._OnMoveBottom): New, methods
5927     bound to tool events.
5928     (LegendTree.MoveCurrentItemTop(), LegendTree.MoveCurrentItemBottom):
5929     New, methods binding the event methods with the map methods.
5930    
5931     * Thuban/Model/map.py (Map.TopLayer(), Map.BottomLayer()): New, place
5932     layer at top/bottom of layer stack.
5933    
5934     * Resources/Bitmaps/top_layer.xpm: New button icon.
5935    
5936     * Resources/Bitmaps/bottom_layer.xpm: New button icon.
5937    
5938 bh 988 2003-05-22 Bernhard Herzog <[email protected]>
5939    
5940     * Thuban/Model/session.py (Session.RemoveTable): New method to
5941     remove tables
5942    
5943     * test/test_session.py (TestSessionSimple.test_remove_table): New.
5944     Test for RemoveTable
5945    
5946 tkoester 986 2003-05-22 Thomas Koester <[email protected]>
5947    
5948     * Thuban/Model/classgen.py: Added short module doc string and CVS id.
5949     (ClassGenerator.GenUniformDistribution): Use new Range __init__, too.
5950    
5951 bh 983 2003-05-22 Bernhard Herzog <[email protected]>
5952    
5953 bh 985 Implement a way to discover dependencies between tables and
5954     shapestores.
5955    
5956     * Thuban/Model/transientdb.py (TransientTableBase.Dependencies)
5957     (TransientJoinedTable.Dependencies)
5958     (AutoTransientTable.SimpleQuery): New. Implement the dependencies
5959     interface
5960     (TransientJoinedTable.__init__): Keep tack of the original table
5961     objects in addition to the corresponding transient tables.
5962    
5963     * Thuban/Model/table.py (DBFTable.Dependencies)
5964     (MemoryTable.Dependencies): New. Implement the dependencies
5965     interface
5966    
5967     * Thuban/Model/data.py (ShapeTable): New. Helper class for
5968     ShapefileStore
5969     (ShapefileStore.__init__): Use ShapeTable instead of
5970     AutoTransientTable
5971     (ShapefileStore.Table, ShapefileStore.Shapefile): Add doc-strings
5972     (ShapefileStore.FileName, ShapefileStore.FileType): New. Accessor
5973     methods for filename and type
5974     (ShapefileStore.Dependencies): New. Implement the dependencies
5975     interface
5976     (DerivedShapeStore): New class to replace SimpleStore. The main
5977     difference to SimpleStore is that it depends not on a shapefile
5978     but another shapestore which expresses the dependencies a bit
5979     better
5980     (SimpleStore.__init__): Add deprecation warning.
5981    
5982     * test/test_dbf_table.py (TestDBFTable.test_dependencies): New.
5983     Test for the Dependencies method.
5984    
5985     * test/test_memory_table.py (TestMemoryTable.test_dependencies):
5986     New. Test for the Dependencies method.
5987    
5988     * test/test_transientdb.py
5989     (TestTransientTable.test_auto_transient_table_dependencies): New.
5990     Test for the Dependencies method.
5991     (TestTransientTable.test_transient_joined_table): Add test for the
5992     Dependencies method.
5993    
5994     * test/test_session.py (TestSessionSimple.setUp)
5995     (TestSessionSimple.tearDown): New. Implement a better way to
5996     destroy the sessions.
5997     (TestSessionSimple.test_initial_state)
5998     (TestSessionSimple.test_add_table): Bind session to self.session
5999     so that it's destroyed by tearDown
6000     (TestSessionSimple.test_open_shapefile): New. Test for
6001     OpenShapefile and the object it returns
6002    
6003     2003-05-22 Bernhard Herzog <[email protected]>
6004    
6005 bh 983 * Thuban/Model/session.py (Session.AddTable): New method to
6006     register tables with the session.
6007     (Session.Tables): Return the tables registered with AddTable too.
6008    
6009     * test/test_session.py (TestSessionSimple.test_add_table): New.
6010     Test case for the AddTable method
6011    
6012 frank 981 2003-05-22 Frank Koormann <[email protected]>
6013    
6014     UI polishing updates: Place main buttons (OK, Cancel, etc) in the
6015     lower right corner, center labels for selections, initialize controls
6016     in reasonable order for keyboard navigation.
6017    
6018     * Thuban/UI/projdialog.py (ProjFrame.__init__, ProjFrame.__doLayout)
6019     (ProjFrame.__DoOnProjAvail): Determine position of current projection
6020     using the wxListBox.FindString() method. Still a problem (#1886)
6021    
6022     * Thuban/UI/classifier.py
6023     (Classifier.__init__, SelectPropertiesDialog.__init__)
6024    
6025     * Thuban/UI/classgen.py (ClassGenDialog.__init__,
6026     (ClassGenDialog.__DoOnGenTypeSelect): Moved initialization of the
6027     different classification types from here to __init__.
6028     (GenUniquePanel.__init__): Set the column width of the first field
6029     in the Field ListCtrl to the full width.
6030    
6031     * Thuban/UI/tableview.py (LayerTableFrame.__init__): Rename 'Save As'
6032     Button to 'Export'. Center Buttons in Selection Box, set Focus to
6033     Grid.
6034     (LayerTableFrame.OnKeyDown()): New, bound to the grid with EVT_KEY_DOWN,
6035     changes focus to the Selection when pressing "Alt-S".
6036    
6037     * Thuban/UI/legend.py (LegendTree.__SetVisibilityStyle): Only gray out
6038     the text if not visible. The italic font sometimes exceeds the
6039     rendering area.
6040    
6041 jonathan 972 2003-05-21 Jonathan Coles <[email protected]>
6042 jonathan 971
6043 jonathan 975 * Thuban/UI/dock.py (DockFrame): Rename references to _OnClose
6044     to OnClose so that Thuban closes correctly.
6045    
6046     * Thuban/UI/mainwindow.py (MainWindow.OnClose): Call
6047     DockFrame.OnClose, not DockFrame._OnClose.
6048    
6049     2003-05-21 Jonathan Coles <[email protected]>
6050    
6051 jonathan 971 * Thuban/Model/classgen.py (ClassGenerator.GenQuantiles): Remove
6052     references to 'inf' and use new Range __init__ to pass floats
6053     directly rather than converting them to strings first.
6054     Fixes RTBug #1876.
6055    
6056     * Thuban/Model/classification.py (ClassGroupRange.SetRange):
6057     Use new Range ___init__ to pass floats.
6058    
6059     * Thuban/Model/layer.py (RasterLayer.__init__): Test if the
6060     filename is a valid image file. Throw IOError otherwise.
6061    
6062     * Thuban/Model/range.py: Brought over new Range from SciParam that
6063     is immutable and has an __init__ which can accept floats.
6064    
6065     * Thuban/UI/mainwindow.py (MainWindow.AddLayer): Move OpenShapefile
6066     into try block. AddLayer doesn't throw any exceptions anymore.
6067     (MainWindow.AddRasterLayer): Move constructor of RasterLayer into
6068     try block.
6069    
6070     * Thuban/UI/projdialog.py (GeoPanel.__init__): Put Degrees as
6071     the first item in choices. Fixes RTBug #1882.
6072    
6073     * Thuban/UI/renderer.py (MapRenderer.render_map): Check if scale
6074     has gone to 0 which is a serious problem. abort.
6075     (MapRenderer.draw_raster_layer): Catch IOError seperately and
6076     print the error from GDAL.
6077    
6078     * Thuban/UI/tableview.py (TableGrid.__init__): Call
6079     ToggleEventListeners to turn on listening.
6080     (TableGrid.ToggleEventListeners): New. Turns event listening on
6081     and off so as to prevent excessive messages.
6082     (LayerTableFrame.OnQuery): Use TableGrid.ToggleEventListeners
6083     to suppress excessive messages when selecting many rows.
6084     Fixes RTBug #1880.
6085    
6086     * Thuban/UI/view.py: Added checks against if scale == 0. This
6087     is a serious problem that can occur when an image without
6088     geo data is loading and causes the map projection bounds to
6089     go to infinity. Right now, the solution is to simply try
6090     to recover.
6091    
6092     * extensions/thuban/cpl_mfile.cpp (MFILEClose): Make sure
6093     to set the MFILEReceiver attributes even if the data is NULL.
6094    
6095     * extensions/thuban/gdalwarp.cpp: Improved the error handling
6096     and passed GDAL messages back up to the Python layer. Also
6097     tried to fix some memory leaks that were present in the original
6098     utility but didn't matter because the program aborted.
6099    
6100     * test/test_range.py: Copied over tests from SciParam. Removed
6101     tests against importing. Fixes RTBug #1867.
6102    
6103 bh 958 2003-05-21 Bernhard Herzog <[email protected]>
6104    
6105     * test/test_load.py: Remove unused imports and restructure the
6106     test code
6107     (LoadSessionTest): Split into one class for each test and turn
6108     LoadSessionTest itself into the base class for all such session
6109     tests.
6110     (ClassificationTest): New base class for load tests that test
6111     classifications
6112     (TestSingleLayer, TestLayerVisibility, TestClassification)
6113     (TestLabels, TestLayerProjection, TestRasterLayer): New classes
6114     for the individual tests
6115    
6116     * test/support.py (FileLoadTestCase.filename): New base class for
6117     file loading tests
6118    
6119 jan 955 2003-05-21 Jan-Oliver Wagner <[email protected]>
6120    
6121     * Resources/Projections/defaults.proj: Renamed 'Universal Transverse
6122     Mercator' to 'UTM Zone 32' as a more convenient example.
6123     Added 'Gauss Krueger Zone 6'.
6124    
6125     * Data/iceland_sample_raster.thuban: political polygon now
6126     filled transparent to have the raster image visible at once.
6127    
6128 frank 952 2003-05-21 Frank Koormann <[email protected]>
6129    
6130     * Thuban/UI/mainwindow.py (MainWindow): Renamed _OnClose() back to
6131     OnClose() to keep in sync with extensions. Internally Thuban
6132     still uses "underscored" names.
6133    
6134 jonathan 949 2003-05-20 Jonathan Coles <[email protected]>
6135    
6136     This puts back Raster layer support. These layers support projections
6137     through the GDAL library. Currently, the CVS version is being used.
6138     There are no Debian packages available although this may change soon.
6139     A GDAL driver was extended to support writing to memory rather to
6140     files.
6141    
6142     There is still some work that needs to be done, such as some error
6143     handling when loading invalid images or when there is a problem
6144     projecting the image. This putback simply checks in the majority
6145     of the work.
6146    
6147     * setup.py: Add gdalwarp library extension.
6148    
6149     * Thuban/Model/layer.py (BaseLayer.HasClassification): New.
6150     Defaults to False, but can be overridden by subclasses if they
6151     support classification.
6152     (RasterLayer): New. Defines a new layer that represents an
6153     image.
6154    
6155     * Thuban/Model/load.py (SessionLoader.__init__): Add rasterlayer
6156     tag handler.
6157     (SessionLoader.start_layer): Encode the filename.
6158     (SessionLoader.start_rasterlayer, SessionLoader.end_rasterlayer):
6159     New. Supports reading a rasterlayer tag.
6160    
6161     * Thuban/Model/map.py (Map.BoundingBox): Fix typo in comment.
6162    
6163     * Thuban/Model/save.py (XMLWriter.encode): Don't assume that we
6164     get a string in Latin1. If we get such as string convert it to
6165     unicode first, otherwise leave if alone before encoding.
6166     (SessionSaver.write_layer): Add support for writing both Layers
6167     and RasterLayers.
6168    
6169     * Thuban/Model/transientdb.py (AutoTransientTable.SimpleQuery):
6170     The right argument may not be a string, it could also be a Column.
6171    
6172     * Thuban/UI/application.py (ThubanApplication.CreateMainWindow):
6173     Make initial window size 600x400. Fixes RTBug #1872.
6174    
6175     * Thuban/UI/classifier.py (Classifier.__init__): Rearrange how
6176     the dialog is constructed so that we can support layers that
6177     do not have classifications.
6178     (Classifier._OnTry): Only build a classification if the layer
6179     supports one.
6180    
6181     * Thuban/UI/legend.py: Change all checks that a layer is an
6182     instance of Layer into checks against BaseLayer.
6183     (LegendTree.__FillTreeLayer): Only add children to a branch if
6184     the layer supports classification.
6185    
6186     * Thuban/UI/mainwindow.py (MainWindow.NewSession,
6187     MainWindow.OpenSession): Don't proceed with an action if the
6188     user chooses Cancel when they are asked to save changes.
6189     (MainWindow.AddRasterLayer): New. Open a dialog to allow the
6190     user to select an image file. Create a new RasterLayer and add
6191     it to the map.
6192    
6193     * Thuban/UI/renderer.py (MapRenderer.render_map): Add support
6194     for rendering RasterLayer layers.
6195     (MapRenderer.draw_raster_layer): Actually method that calls
6196     the GDALWarp python wrapper and constructs an image from the
6197     data returned.
6198    
6199     * Thuban/UI/tableview.py (LayerTableFrame.__init__): Change the
6200     Choices symbols to match those used in the table query method.
6201     Replace deprecated method calls on table with new method names.
6202    
6203     * Thuban/UI/view.py (MapCanvas.set_view_transform): Try to limit
6204     how small the scale can get. This still needs more testing.
6205    
6206     * extensions/thuban/bmpdataset.cpp: New, but copied from GDAL.
6207     Provides a driver to output in .bmp format.
6208    
6209     * extensions/thuban/cpl_mfile.cpp, extensions/thuban/cpl_mfile.h:
6210     New. Provides IO routines which write to memory, rather than a file.
6211    
6212     * extensions/thuban/gdalwarp.cpp: New, but basically a direct copy
6213     of the gdalwarp utility provided in GDAL. Added function calls
6214     that can be accessed from python.
6215    
6216     * Data/iceland_sample_raster.thuban: New. Sample file that uses
6217     a raster layer.
6218    
6219     * Data/iceland/island.tfw, Data/iceland/island.tif: New. Raster
6220     layer image data.
6221    
6222     * Doc/thuban.dtd: Added rasterlayer attribute definition.
6223    
6224     * test/test_layer.py, test/test_load.py, test/test_save.py: Added
6225     tests associated with the raster layer code.
6226    
6227     * test/test_transientdb.py
6228     (TestTransientTable.test_auto_transient_table_query): Added a test
6229     for using a Column object as the "right" parameter to a query.
6230    
6231 frank 924 2003-05-19 Frank Koormann <[email protected]>
6232    
6233 frank 927 * Thuban/version.py (get_changelog_date):
6234     Catch exceptions if ChangeLog does not exist.
6235    
6236     * Thuban/UI/view.py (MapCanvas.Export): Bugfix
6237    
6238     2003-05-19 Frank Koormann <[email protected]>
6239    
6240 frank 924 Extended version information for Thuban
6241    
6242     * Thuban/version.py: New, version information for Thuban: Last
6243     modification date and last ChangeLog entry date.
6244    
6245     * Thuban/UI/mainwindow.py (MainWindow.About()): Extended version
6246     information: Display Thuban, wxPython and Python version.
6247    
6248 bh 919 2003-05-16 Bernhard Herzog <[email protected]>
6249    
6250 bh 921 * Thuban/Model/save.py: Remove some unused imports including the
6251     __future__ import for nested_scopes as Thuban relies on Python 2.2
6252     now.
6253     (XMLWriter.encode): Remove the special case for a None argument.
6254     In the saver encode is always called with a string argument.
6255    
6256     2003-05-16 Bernhard Herzog <[email protected]>
6257    
6258 bh 919 * Thuban/UI/__init__.py: Remove the work-around for the locale bug
6259     in wxPython (at least when usinvg wxGTK) prior to 2.4. The symptom
6260     of the bug was that e.g. float("1.2") would fail. Thuban now
6261     requires 2.4.x.
6262    
6263 frank 917 2003-05-16 Frank Koormann <[email protected]>
6264    
6265     Printing enhancement and WMF export (under Win32)
6266    
6267     * Thuban/UI/renderer.py (ExportRenderer): New, derived from
6268     ScreenRenderer. Renders Map, Legend and Scalebar for export.
6269     (PrinterRenderer): New, derived from ExportRenderer. Replaces the old
6270     PrintRender.
6271    
6272     * Thuban/UI/view.py (MapPrintout.__init__): Enhanced parameter set
6273     to fullfil information needed for PrinterRenderer.
6274     (MapCanvas.Export): New. Export Map (currently only to WMF on Win32).
6275     (MapCanvas.Print): Adapted to new MapPrintout.
6276     (OutputTransform): General calculations to transform from canvas
6277     coordinates to export/printing devices.
6278    
6279     * Thuban/UI/mainwindow.py (MainWindow.ExportMap()): New. Added also
6280     new method_command to call ExportMap, with platform dependency (only
6281     __WXMSW__)
6282    
6283     * Thuban/UI/scalebar.py (ScaleBar.DrawScaleBar): Position and Size
6284     of scalebar drawing area as new parameters.
6285    
6286     * Thuban/Model/scalebar.py (roundInterval): round long instead of int
6287    
6288     * Thuban/UI/legend.py (ScalebarBitmap.__SetScale):
6289     Update to extended scalebar.DrawScalebar header.
6290    
6291     * test/test_export.py: New, test Thuban.UI.view.OutputTransform()
6292    
6293     * test/test_scalebar.py: Made test executable as standalone.
6294    
6295 bh 908 2003-05-16 Bernhard Herzog <[email protected]>
6296    
6297     * Thuban/Model/table.py (Table): Remove this compatibility alias
6298     for DBFTable.
6299    
6300     * test/test_table.py: Import DBFTable as Table because that alias
6301     doesn't exist anymore.
6302    
6303     * Thuban/UI/classgen.py: Remove some unused imports
6304    
6305 jonathan 906 2003-05-14 Jonathan Coles <[email protected]>
6306    
6307     * Thuban/Model/classgen.py (ClassGenerator.GenSingletonsFromList):
6308     Fix docstring.
6309     (ClassGenerator.GenUniformDistribution): Fix spelling of method name.
6310     (ClassGenerator.GenQuantiles): Use the left/right brackets and min/max
6311     values of the supplied range to determine the beginning and end
6312     bounds of the generated classes.
6313    
6314     * Thuban/Model/range.py (Range.number_re): Now accepts floats that
6315     do not have a leading 0 (.5 is now accepted as well as 0.5).
6316    
6317     * Thuban/UI/classgen.py (ClassGenDialog.OnOK): Fix name of method
6318     call to ClassGenerator.GenUniformDistribution.
6319    
6320     * Thuban/UI/projdialog.py (ProjFrame.__do_layout): Fix Windows
6321     layout bug with the 'Projection' label.
6322    
6323     * test/support.py (FloatTestCase): New. Needed for the Range tests.
6324    
6325     * test/test_range.py: New. Imported from SciParam.
6326    
6327 jonathan 897 2003-05-12 Jonathan Coles <[email protected]>
6328    
6329 jonathan 899 * Thuban/UI/classgen.py (GenQuantilesPanel.GetList): Replace call
6330     to table.UniqueValues() with calls that retrieve all the values
6331     from the table. This will need to be replaced by a method on table
6332     which can simply return the list (perhaps more efficiently).
6333    
6334     2003-05-12 Jonathan Coles <[email protected]>
6335    
6336 jonathan 897 The return value of ClassGenerator.CalculateQuantiles has changed.
6337     Refer to the documentation for details.
6338    
6339     * test/test_classgen.py: Modified Quantile tests to use the
6340     new return values.
6341    
6342     * Thuban/Model/classgen.py
6343     (ClassGenerator.GenQuantiles): Add comments describing the parameters,
6344     use new return values from CalculateQuantiles to produce the correct
6345     range bounds in the Classification.
6346     (ClassGenerator.CalculateQuantiles): Add more comments describing
6347     the return values and parameters. Make minor adjustments to improve
6348     the legibility of the code. Fix problem with adjusted not being set
6349     in most cases.
6350    
6351 frank 893 2003-05-12 Frank Koormann <[email protected]>
6352    
6353     * Thuban/Model/save.py (XMLWriter.encode()): Explicite call to unicode
6354     and latin1. Fixes #1851 finally.
6355    
6356 jonathan 889 2003-05-09 Jonathan Coles <[email protected]>
6357    
6358 jonathan 897 * test/test_classgen.py: New. Tests the Quantile algorithm.
6359    
6360     * Thuban/Model/classgen.py (ClassGenerator.CalculateQuantiles):
6361     Clean up debugging statement, add comments, fix a small bug in the
6362     returned adjusted percentiles.
6363    
6364     2003-05-09 Jonathan Coles <[email protected]>
6365    
6366 jonathan 889 Introduces Range class from SciParam into the ClassGroupRange class,
6367     and such ranges can now be saved and loaded from disk.
6368    
6369     Quantiles are now available in the Classification Generator.
6370    
6371     Initial support for building Queries on a table. Doesn't do anything
6372     but run some tests.
6373    
6374     * Thuban/Model/classification.py: Explicit imports.
6375     (ClassGroupRange): Use the Range class to store the underlying
6376     range information. The interface remains the same, except for
6377     GetRange(), and you can also supply a Range object as the min
6378     parameter to SetRange or __init__.
6379    
6380     * Thuban/Model/load.py (XMLReader.encode): New. Encodes the given
6381     string appropriately for use in Thuban. Fixes RTbug #1851.
6382     (SessionLoader.end_projection): Handle the context of the
6383     projection tag a bit better by looking at what objects are not
6384     None. There was an assumption that a projection tag for a map
6385     could occur before any layers.
6386     (SessionLoader.start_clrange): Provide backward compatibility for
6387     reading min/max values as well as the new range parameter.
6388    
6389     * Thuban/Model/map.py: Explicit imports.
6390    
6391     * Thuban/Model/resource.py: Import _.
6392     (ProjFileSaver.write): write header using projfile.dtd.
6393    
6394     * Thuban/Model/save.py: Explicit imports.
6395     (XMLWriter.encode): New. Encode the given string from a format
6396     used by Thuban into UTF-8. Fixes RTbug #1851.
6397    
6398     * Thuban/UI/classgen.py: Explicit imports.
6399     (ClassGenDialog.__init__): Clean up the code and add support
6400     for Quantiles.
6401     (ClassGenDialog.OnOK): Add support for Quantiles.
6402     (GenQuantilesPanel): New. Input panel for Quantiles.
6403     (ClassGenerator, CustomRamp, MonochromaticRamp, GreyRamp, RedRamp,
6404     GreenRamp, BlueRamp, HotToColdRamp): Move to Thuban/Model/classgen.py
6405    
6406     * Thuban/Model/classgen.py: New. Contains all the classes named above.
6407    
6408     * Thuban/UI/classifier.py: Explicit imports.
6409     (ClassTable.GetValueAsCust, ClassTable.__ParseInput,
6410     ClassTable.SetValueAsCustom): Reworked to use new Range class.
6411    
6412     * Thuban/UI/legend.py: Explicit imports.
6413    
6414     * Thuban/UI/mainwindow.py: Add support for the Join Dialog. Added
6415     a Table menu and associated method calls.
6416     (MainWindow.choose_color): Removed. No longer needed.
6417    
6418     * Thuban/UI/projdialog.py (ProjFrame.__VerifyButtons): Save button
6419     should be disabled if no projection is selected in the available
6420     list.
6421    
6422     * Thuban/UI/renderer.py: Explicit imports.
6423    
6424     * Thuban/UI/tableview.py (TableGrid.OnRangeSelect): Fix some issues
6425     with correctly selecting the rows and issuing the right events.
6426     Be sure to call Skip() to allow the grid to do some of its own
6427     handling which allows the rows to actually be selected.
6428     (LayerTableGrid.select_shapes): Rename from select_shape. Supports
6429     selecting multiple shapes.
6430     (LayerTableFrame): Support for building Queries.
6431     (LayerTableFrame.select_shapes): Allow multiple shapes to be selected.
6432    
6433     * Thuban/UI/tree.py: Explicit imports.
6434    
6435     * Thuban/UI/view.py (MapCanvas): Delegate "SelectedShapes" so the
6436     table view can call it.
6437    
6438     * test/test_classification.py: Explicit imports.
6439     (TestClassification.test_ClassGroupRange): Fix test for new
6440     Range class.
6441    
6442     * Doc/thuban.dtd: Add range parameter for clrange.
6443    
6444     * Thuban/Model/range.py: Taken from SciParam. Used as the underlying
6445     object in ClassGroupRange, and also uesd for inputting ranges in
6446     the classifer table and elsewhere.
6447    
6448     * Thuban/UI/join.py: New. Initial Join dialog. No real functionality
6449     yet.
6450    
6451 frank 872 2003-05-09 Frank Koormann <[email protected]>
6452    
6453     * Thuban/UI/scalebar.py (DrawScaleBar): Draw only if interval > 0.0.
6454    
6455 frank 860 2003-05-08 Frank Koormann <[email protected]>
6456    
6457 frank 870 Coding style updates
6458    
6459     * test/test_scalebar.py: Replaced tab indentation by spaces.
6460    
6461     * Thuban/UI/scalebar.py: Explicit imports.
6462    
6463     2003-05-08 Frank Koormann <[email protected]>
6464    
6465 frank 867 * Thuban/UI/scalebar.py
6466     (ScaleBar.DrawScalebar): Format string bug fixed.
6467    
6468     2003-05-08 Frank Koormann <[email protected]>
6469    
6470 frank 865 Reorganization of scalebar component (no wx in Thuban/Model)
6471    
6472     * Thuban/Model/scalebar.py: Rendering moved to Thuban/UI/scalebar.py
6473     (deriveInterval):
6474     Calculate scalebar interval and unit which fits in width for scale.
6475     (roundInterval): Round float.
6476    
6477     * Thuban/UI/scalebar.py (ScaleBar): Scalebar rendering
6478    
6479     * test/test_scalebar.py: Test for Thuban/Model/scalebar.py methods.
6480    
6481     * Thuban/UI/legend.py: Import Thuban.UI.scalebar
6482    
6483     2003-05-08 Frank Koormann <[email protected]>
6484    
6485 frank 860 * Thuban/UI/legend.py (ScalebarBitmap.SetCanvas):
6486     Initialize ScaleBar with canvas.map
6487    
6488     * Thuban/Model/scalebar.py (ScaleBar.roundInterval()): New,
6489     round intervals to display smarter lengths
6490     (ScaleBar.DrawScalebar): Draw Scalebar only if the map contains a
6491     layer. If the maps has no projection applied grey the scalebar.
6492    
6493 frank 857 2003-05-07 Frank Koormann <[email protected]>
6494    
6495     Basic Scalebar features added.
6496    
6497     * Thuban/Model/scalebar.py (ScaleBar): New, scalebar rendering.
6498    
6499     * Thuban/UI/legend.py (LegendPanel): Added scalebar bitmap
6500     (ScaleBarBitmap): New, links the scalebar bitmap with view messages
6501     and the renderer.
6502    
6503     * Thuban/UI/view.py (MapCanvas.set_view_transform): Issue SCALE_CHANGED.
6504    
6505     * Thuban/UI/messages.py: SCALE_CHANGED added.
6506    
6507 bh 850 2003-05-07 Bernhard Herzog <[email protected]>
6508    
6509 bh 852 * Thuban/Model/session.py (Session.__init__): New instance
6510     variable shapestores to hold a list of all open shapestore objects
6511     (Session.ShapeStores): New. Accessor method for the shapestores
6512     list.
6513     (Session._add_shapestore, Session._clean_weak_store_refs): New.
6514     Internal methods to maintain the shapestores list.
6515     (Session.Tables): New. Return all tables open in the session.
6516     (Session.OpenShapefile): Insert the new ShapeStore into the
6517     shapestores list.
6518    
6519     * test/test_session.py (TestSessionSimple.test_initial_state): Add
6520     tests for ShapeStores and Tables
6521     (TestSessionWithContent.test_shape_stores)
6522     (TestSessionWithContent.test_tables): New. Test cases for
6523     ShapeStores and Tables
6524    
6525     2003-05-07 Bernhard Herzog <[email protected]>
6526    
6527 bh 850 * Thuban/Model/transientdb.py (TransientTableBase.ReadRowAsDict):
6528     Add comments about the optimizations used.
6529     (AutoTransientTable.ReadValue, TransientTableBase.ReadValue): New.
6530     Implement the ReadValue table interface method.
6531    
6532     * test/test_transientdb.py
6533     (TestTransientTable.run_iceland_political_tests)
6534     (TestTransientTable.test_transient_joined_table): Add tests for
6535     ReadValue
6536    
6537 frank 848 2003-05-07 Frank Koormann <[email protected]>
6538    
6539     * Resources/Bitmaps/fulllayerextent.xpm,
6540     Resources/Bitmaps/fullselextent.xpm: Replaced the place holders with
6541     new icons.
6542    
6543 bh 840 2003-05-06 Bernhard Herzog <[email protected]>
6544    
6545 bh 846 * Thuban/Model/transientdb.py (AutoTransientTable.SimpleQuery):
6546     New. Simply delegate to the transient table's version.
6547    
6548     * test/test_transientdb.py
6549     (TestTransientTable.test_auto_transient_table_query): New. Test
6550     case for AutoTransientTable's SimpleQuery
6551    
6552     2003-05-06 Bernhard Herzog <[email protected]>
6553    
6554 bh 843 * Thuban/Model/transientdb.py (TransientTableBase.SimpleQuery):
6555     Implement a simple query method for the query dialog
6556     (TransientTableBase.create): Add an INTEGER PRIMARY KEY that holds
6557     the row index or shapeid.
6558     (TransientTable.create): Insert the right value of the row index
6559     (TransientJoinedTable.create): Copy the row index of the left
6560     table to the joined result table
6561    
6562     * test/test_transientdb.py
6563     (TestTransientTable.test_transient_table_read_twice): Fix
6564     doc-string
6565     (TestTransientTable.test_transient_table_query): New. Test for the
6566     SimpleQuery method
6567    
6568     2003-05-06 Bernhard Herzog <[email protected]>
6569    
6570 bh 840 Convert all table users to use the new table interface. This only
6571     covers Thuban itself, not GREAT-ER or other applications built on
6572     Thuban yet, so the compatibility interface stays in place for the
6573     time being but it now issues DeprecationWarnings.
6574    
6575     Finally, the new Table interface has a new method, HasColumn.
6576    
6577     * Thuban/Model/table.py (OldTableInterfaceMixin): All methods
6578     issue deprecation warnings when they're. The warnings refer to the
6579     caller of the method.
6580     (OldTableInterfaceMixin.__deprecation_warning): New. Helper method
6581     for the deprecation warnings
6582    
6583     * test/test_table.py: Ignore the deprecation warnings for the old
6584     table in the tests in this module. The purpose of the tests is to
6585     test the old interface, after all.
6586    
6587     * test/test_transientdb.py
6588     (TestTransientTable.run_iceland_political_tests): Use the
6589     constants for the types. Add a test for HasColumn
6590     (TestTransientTable.test_transient_joined_table): Adapt to new
6591     table interface. Add a test for HasColumn
6592     (TestTransientTable.test_transient_table_read_twice): Adapt to new
6593     table interface
6594    
6595     * Thuban/UI/tableview.py (DataTable.SetTable, DataTable.GetValue):
6596     Adapt to new table interface
6597    
6598     * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Adapt to
6599     new table interface
6600    
6601     * Thuban/UI/controls.py (RecordListCtrl.fill_list)
6602     (RecordTable.SetTable): Adapt to new table interface
6603    
6604     * Thuban/UI/classifier.py (Classifier.__init__)
6605     (Classifier.__init__): Adapt to new table interface
6606    
6607     * Thuban/UI/classgen.py (ClassGenDialog.__init__)
6608     (GenUniformPanel._OnRetrieve, GenUniquePanel._OnRetrieve): Adapt
6609     to new table interface
6610    
6611     * Thuban/Model/transientdb.py (TransientTableBase.HasColumn)
6612     (AutoTransientTable.HasColumn): Implement the new table interface
6613     method
6614     (AutoTransientTable.ReadRowAsDict, AutoTransientTable.ValueRange)
6615     (AutoTransientTable.UniqueValues): Adapt to new table interface
6616    
6617     * Thuban/Model/layer.py (Layer.SetShapeStore, Layer.GetFieldType):
6618     Adapt to new table interface
6619    
6620     * test/test_layer.py (TestLayer.open_shapefile): Helper method to
6621     simplify opening shapefiles a bit easier.
6622     (TestLayer.test_arc_layer, TestLayer.test_polygon_layer)
6623     (TestLayer.test_point_layer): Use the new helper method
6624     (TestLayer.test_get_field_type): New. Test for the GetFieldType
6625     method
6626    
6627     * test/test_dbf_table.py (TestDBFTable.test_has_column): Test for
6628     the new table method
6629    
6630     * test/test_memory_table.py (TestMemoryTable.test_has_column):
6631     Test for the new table method HasColumn
6632    
6633 jonathan 833 2003-05-06 Jonathan Coles <[email protected]>
6634    
6635     Addresses the "Selection Extent" wish of RTbug #1787.
6636    
6637     * Resources/Bitmaps/fulllayerextent.xpm,
6638     Resources/Bitmaps/fullselextent.xpm: Bitmaps for layer and selection
6639     extent. These are just place holders for the real bitmaps.
6640    
6641     * Thuban/Model/layer.py (Shape): Since a Shape is immutable only
6642     calculate the bounding box once (the first time compute_bbox() is
6643     called).
6644     (Layer.ShapesBoundingBox): New. Given a list of shape ids, return
6645     the bounding box for the shapes in lat/long coordinates.
6646    
6647     * Thuban/UI/mainwindow.py: Added new "Full selection extent" menu
6648     option.
6649     (MainWindow.has_selected_shapes): New. Returns true if there are
6650     any selected shapes.
6651     (MainWindow.FullSelectionExtent): New. Calls
6652     MapCanvas.FitSelectedToWindow() when the user selects the menu option.
6653     (_has_selected_shapes): New. Returns true if there are any
6654     selected shapes.
6655    
6656     * Thuban/UI/selection.py (Selection.HasSelectedShapes): New. Returns
6657     true if there are any selected shapes.
6658    
6659     * Thuban/UI/view.py (MapCanvas): Added delegated method
6660     HasSelectedShapes.
6661     (MapCanvas.FitSelectedToWindow): New. Centers and scales any selected
6662     shapes on the canvas using the map projection (if any).
6663    
6664     * test/test_layer.py (TestLayer.test_arc_layer): Add some tests
6665     for Layer.ShapesBoundingBox().
6666    
6667 bh 826 2003-05-06 Bernhard Herzog <[email protected]>
6668    
6669     * Resources/Projections/defaults.proj: Fix spelling of Mercator
6670    
6671 jonathan 823 2003-05-05 Jonathan Coles <[email protected]>
6672    
6673     Addresses the "Full Layer Extent" wish of RTbug #1787.
6674    
6675     * Resources/Projections/defaults.proj: Added UK National Grid.
6676    
6677     * Thuban/UI/mainwindow.py: Added new "Full layer extent" menu option.
6678     (MainWindow.FullLayerExtent): New. Calls MapCanvas.FitLayerToWindow()
6679     when the user selects the menu option.
6680    
6681     * Thuban/UI/view.py (MapCanvas.FitLayerToWindow): New. Centers and
6682     scales the given layer on the canvas using the map projection.
6683    
6684 bh 819 2003-05-05 Bernhard Herzog <[email protected]>
6685    
6686     Convert the table implementations to a new table interface. All
6687     tables use a common mixin class to provide backwards compatibility
6688     until all table users have been updated.
6689    
6690     * Thuban/Model/table.py (OldTableInterfaceMixin): Mixin class to
6691     provide backwards compatibility for table classes implementing the
6692     new interface
6693     (DBFTable, MemoryTable): Implement the new table interface. Use
6694     OldTableInterfaceMixin as base for compatibility
6695     (DBFColumn, MemoryColumn): New. Column description for DBFTable
6696     and MemoryTable resp.
6697    
6698     * test/test_dbf_table.py: New. Test cases for the DBFTable with
6699     the new table interface.
6700    
6701     * test/test_memory_table.py: New. Test cases for the MemoryTable
6702     with the new table interface.
6703    
6704     * test/test_table.py: Document the all tests in this file as only
6705     for backwards compatibility. The equivalent tests for the new
6706     interface are in test_memory_table.py and test_dbf_table.py
6707     (MemoryTableTest.test_read): field_info should be returning tuples
6708     with four items
6709     (MemoryTableTest.test_write): Make doc-string a more precise.
6710    
6711     * Thuban/Model/transientdb.py (TransientTableBase): Convert to new
6712     table interface. Derive from from OldTableInterfaceMixin for
6713     compatibility.
6714     (TransientTableBase.create): New intance variable column_map to
6715     map from names and indices to column objects
6716     (TransientTable.create): Use the new table interface of the input
6717     table
6718     (AutoTransientTable): Convert to new table interface. Derive from
6719     from OldTableInterfaceMixin for compatibility.
6720     (AutoTransientTable.write_record): Removed. It's not implemented
6721     yet and we still have to decide how to handle writing with the new
6722     table and data framework.
6723    
6724     * test/test_transientdb.py
6725     (TestTransientTable.run_iceland_political_tests)
6726     (TestTransientTable.test_transient_joined_table): Use the new
6727     table interface
6728    
6729 jonathan 817 2003-05-05 Jonathan Coles <[email protected]>
6730    
6731     This is namely a collection of UI updates to improve user interactivity.
6732     Tabbing between controls now exists and you can use ESC to close dialog
6733     boxes; ENTER will active the default button.
6734    
6735     * Thuban/UI/classgen.py (ClassGenDialog.__init__): Rearrange the
6736     order that the controls are created so that tabbing works correctly.
6737     (ClassGenDialog.OnOK): Renamed from _OnGenerate() so that the
6738     wxDialog can handle the default button correctly.
6739     (ClassGenDialog.OnCancel): Renamed from _OnCloseBtn() for the
6740     same reasons as for OnOK.
6741     (GenUniformPanel._OnRetrieve): Call wxBeginBusyCursor/wxEndBusyCursor
6742     when we ask the table for the maximum/minimum values of a field
6743     which could take a very long time.
6744    
6745     * Thuban/UI/classifier.py (Classifier.__init__): Rearrange the
6746     order that the controls are created so that tabbing works correctly.
6747     (SelectPropertiesDialog.__init__): Rearrange the order that the
6748     controls are created so that tabbing works correctly.
6749    
6750     * Thuban/UI/dialogs.py: Copied NonModalDialog box and changed it
6751     to derive from a wxDialog but behave like the original implementation
6752     which was derived from a wxFrame. wxDialog provides useful key
6753     handling functionality like ESC calling OnCancel and ENTER calling
6754     OnOK which is lost with wxFrame.
6755    
6756     * Thuban/UI/mainwindow.py: Add "..." to menu items that will open
6757     new dialogs.
6758    
6759     * Thuban/UI/projdialog.py (ProjFrame.__init__): Rearrange the
6760     order that the controls are created so that tabbing works correctly.
6761     (ProjFrame.OnApply): Renamed from _OnTry() to use wxDialog behaviour.
6762     (ProjFrame.OnOK): Renamed from _OnOK() to use wxDialog behaviour.
6763     (ProjFrame.OnCancel): Renamed from _OnClose() to use wxDialog behaviour.
6764     (ProjPanel.__init__): Add "Airy" to the list of ellipsoids so we
6765     can provide the "UK National Grid" as a default projection.
6766     (UTMPanel.__init__): Rearrange the order that the controls are
6767     created so that tabbing works correctly.
6768    
6769 bh 809 2003-05-05 Bernhard Herzog <[email protected]>
6770    
6771 bh 811 * extensions/thuban/wxproj.cpp: Fix some of the comments.
6772     (project_point): If a map projection but no layer projection is
6773     given, convert degrees to radians before applying the map
6774     projection.
6775    
6776 bh 809 * Thuban/UI/tableview.py (TableGrid.disallow_messages)
6777     (TableGrid.allow_messages): New methods to make it possible to
6778     inhibit message sending.
6779     (TableGrid.issue): Only send the message if not inhibited.
6780     (LayerTableGrid.select_shape): Use the new methods to make sure
6781     that no ROW_SELECTED message is sent while we're updating the
6782     selected rows to match the selected shapes.
6783    
6784 jan 807 2003-05-02 Jan-Oliver Wagner <[email protected]>
6785    
6786     Implementation of MemoryTable.
6787    
6788     * Thuban/Model/table.py (MemoryTable): New. Quite simple table
6789     implementation that operates on a list of tuples. All of the data
6790     are kept in the memory.
6791    
6792     * test/test_table.py (MemoryTableTest): New.
6793    
6794     * test/test_transientdb.py (SimpleTable): Removed.
6795     (TestTransientTable.test_transient_joined_table,
6796     (TestTransientTable.test_transient_table_read_twice): Replaced
6797     SimpleTable by MemoryTable.
6798    
6799 jonathan 793 2003-04-30 Jonathan Coles <[email protected]>
6800    
6801 jonathan 803 * Data/iceland_sample.thuban: Now contains correct projections
6802     for each of the layers.
6803    
6804     * Resources/Projections/defaults.proj: Geographic projection
6805     contains unit conversion parameter.
6806    
6807     2003-04-30 Jonathan Coles <[email protected]>
6808    
6809 jonathan 793 The most important part of this putback is the projection changes.
6810     It should now be possible to specify the projection that a layer
6811     is in and then specify a different projection for the map. The
6812     projection dialog has an extra parameter for a geographic projection
6813     which lets the user select if the input is in degrees or radians.
6814    
6815     * Thuban/Model/layer.py (Layer.ShapesInRegion): Fix docstring
6816     to say that the parameter is a tuple of unprojected
6817     points (which is what the callers to this method were assuming).
6818     Also, since the points are unprojected we need to projected them.
6819    
6820     * Thuban/UI/legend.py (LegendTree.MoveCurrentItemUp,
6821     LegendTree.MoveCurrentItemDown): If the layer or any of the layer's
6822     groups are selected, move the layer up/down. Fixes RTbug #1833.
6823    
6824     * Thuban/UI/mainwindow.py: Move menu item map_rename up.
6825    
6826     * Thuban/UI/projdialog.py (ProjFrame._OnSave): Add missing
6827     parameter in call to SetClientData.
6828     (GeoPanel): Add support for selecting the units that the
6829     source data is in (Radians or Degrees).
6830    
6831     * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Optimize
6832     the rendering loop by reducing the number of if's, removing the
6833     unnecessary try/except block, and checking if the old group
6834     is the same as the new one (which happens a lot if there is
6835     no classification, or lots of shapes are in the same group).
6836    
6837     * Thuban/UI/view.py (MapCanvas.OnPaint): Add a try/except block
6838     around the redraw routine to try to catch problems that the user
6839     may create by selecting invalid projections for the data set and
6840     map. Clears the display if there are any problems and prints the
6841     error.
6842     (MapCanvas.do_redraw): Use DC.Clear() instead of drawing a filled
6843     rectangle.
6844    
6845     * extensions/thuban/wxproj.cpp (project_point): First invert the
6846     supplied point (which should be in projected coordinates) using
6847     the layer's projection and then project the point using the
6848     map's projection.
6849     (project_points): Use project_point() to project each point.
6850    
6851 jan 792 2003-04-30 Jan-Oliver Wagner <[email protected]>
6852    
6853     * Thuban/Model/layer.py (Layer.SetShapeStore): Fixed a bug:
6854     don't set the Classification to None if the classfication field
6855     is None (ie only a DEFAULT).
6856    
6857 bh 786 2003-04-30 Bernhard Herzog <[email protected]>
6858    
6859 bh 790 * Thuban/UI/view.py: Fix some typos.
6860    
6861 bh 788 * Thuban/UI/mainwindow.py (MainWindow.identify_view_on_demand): Do
6862     not pop up the dialog if the selection becomes empty (this could
6863     happen if e.g. a new selection is opened while the identify tool
6864     is active and dialog had been closed)
6865    
6866     2003-04-30 Bernhard Herzog <[email protected]>
6867    
6868 bh 786 * Thuban/Model/transientdb.py (TransientTableBase.__init__): New
6869     instance variable read_record_last_result
6870     (TransientTableBase.read_record): Make sure reading the same
6871     record twice works. The implementation uses the new instance
6872     variable read_record_last_result
6873    
6874     * test/test_transientdb.py
6875     (TestTransientTable.test_transient_table_read_twice): New test
6876     case for the above bug-fix.
6877    
6878 jonathan 793 2003-04-29 Jonathan Coles <[email protected]>
6879    
6880     * Thuban/common.py: Removed. No longer needed Str2Num. RTbug #1832.
6881    
6882     * Thuban/UI/classgen.py: Remove all uses of Str2Num.
6883    
6884     * Thuban/UI/classifier.py: Remove all uses of Str2Num.
6885     (ClassTable.SetValueAsCustom): Rename keyword argument in
6886     ClassGroup* constructors to match argument name.
6887    
6888 bh 779 2003-04-29 Bernhard Herzog <[email protected]>
6889    
6890     * Thuban/Model/session.py (Session.Destroy): Explicitly close the
6891     transient DB if it exists to make sure it doesn't leave a journal
6892     file in the temp directory.
6893    
6894     * Thuban/Model/transientdb.py (TransientDatabase.close): Set
6895     self.conn to None after closing the connection to make sure it's
6896     not closed twice
6897    
6898 jonathan 767 2003-04-29 Jonathan Coles <[email protected]>
6899    
6900 jonathan 769 Add a visible parameter in the layer XML tag. The default value is
6901     "true". If anything other than "false" is specified we also assume
6902 jonathan 776 "true". Addresses RTbug #1025.
6903 jonathan 769
6904     * Doc/thuban.dtd: Add visible parameter to a layer.
6905    
6906     * Thuban/Model/layer.py (BaseLayer.__init__): Change default value
6907     of visible from 1 to True.
6908     (Layer.__init__): Change default value of visible from 1 to True.
6909    
6910     * Thuban/Model/load.py (SessionLoader.start_layer): Read visible
6911     parameter.
6912    
6913     * Thuban/Model/save.py (SessionSaver.write_layer): Save visible
6914     parameter.
6915    
6916     * test/test_load.py: Add new test data contents_test_visible.
6917     (LoadSessionTest.setUp): save test data.
6918     (LoadSessionTest.testLayerVisibility): Test if the visible flag
6919     is loaded correctly.
6920    
6921     * test/test_save.py (SaveSessionTest.testSingleLayer): Add test
6922     for saving an invisible layer.
6923    
6924     2003-04-29 Jonathan Coles <[email protected]>
6925    
6926 jonathan 767 * Thuban/UI/mainwindow.py (MainWindow.SetMap): Look up the
6927     legend dialog box and tell it to change its map to the one
6928     supplied to SetMap(). Fixes RTbug #1770.
6929    
6930 bh 764 2003-04-29 Bernhard Herzog <[email protected]>
6931    
6932 bh 766 Next step of table implementation. Introduce a transient database
6933     using SQLite that some of the data is copied to on demand. This
6934     allows us to do joins and other operations that require an index
6935     for good performance with reasonable efficiency. Thuban now needs
6936     SQLite 2.8.0 and pysqlite 0.4.1. Older versions may work but I
6937     haven't tested that.
6938    
6939     * Thuban/Model/transientdb.py: New. Transient database
6940     implementation.
6941    
6942     * test/test_transientdb.py: New. Tests for the transient DB
6943     classes.
6944    
6945     * Thuban/Model/session.py (AutoRemoveFile, AutoRemoveDir): New
6946     classes to help automatically remove temporary files and
6947     directories.
6948     (Session.__init__): New instance variables temp_dir for the
6949     temporary directory and transient_db for the SQLite database
6950     (Session.temp_directory): New. Create a temporary directory if not
6951     yet done and return its name. Use AutoRemoveDir to have it
6952     automatically deleted
6953     (Session.TransientDB): Instantiate the transient database if not
6954     done yet and return it.
6955    
6956     * Thuban/Model/data.py (ShapefileStore.__init__): Use an
6957     AutoTransientTable so that data is copied to the transient DB on
6958     demand.
6959     (SimpleStore): New class that simply combines a table and a
6960     shapefile
6961    
6962     * Thuban/Model/table.py (Table, DBFTable): Rename Table into
6963     DBFTable and update its doc-string to reflect the fact that this
6964     is only the table interface to a DBF file. Table is now an alias
6965     for DBFTable for temporary backwards compatibility.
6966    
6967     * Thuban/UI/application.py (ThubanApplication.OnExit): Make sure
6968     the last reference to the session goes away so that the temporary
6969     files are removed properly.
6970    
6971     * test/test_load.py (LoadSessionTest.tearDown): Remove the
6972     reference to the session to make sure the temporary files are
6973     removed.
6974    
6975     2003-04-29 Bernhard Herzog <[email protected]>
6976    
6977 bh 764 * Thuban/Model/load.py (XMLReader.__init__, XMLReader.read): Turn
6978     the __parser instance variable into a normal local variable in
6979     read. It's only used there and read will never be called more than
6980     once. Plus it introduces a reference cycle that keeps can keep the
6981     session object alive for a long time.
6982    
6983 jonathan 767 2003-04-29 Jonathan Coles <[email protected]>
6984 jonathan 735
6985 jonathan 762 * Thuban/Model/proj.py (Projection): Removed Set*() methods to make
6986     Projection an immutable item. Fixes RTbug #1825.
6987     (Projection.__init__): Initialize instance variables here.
6988     (ProjFile.Replace): New. Replace the given projection object with
6989     the new projection object. This solves the problem of needing the
6990     mutator Projection.SetProjection() in the ProjFrame class and
6991     allows a projection to change parameters without changing its
6992     location in the file.
6993    
6994     * Thuban/UI/mainwindow.py (MainWindow.SaveSessionAs): Dialog should
6995     be of type wxSAVE and should verify overwriting a file.
6996    
6997     * Thuban/UI/projdialog.py (ProjFrame._OnSave): Use the new
6998     ProjFile.Replace() method instead of the mutator
6999     Projection.SetProjection(). Also requires that we reassign the
7000     client data to the new projection.
7001    
7002     * test/test_proj.py (TestProjection.test): Test GetName() and
7003     GetAllParameters()
7004     (TestProjFile.test): Remove tests for Set*() methods. Add tests
7005     for Replace().
7006    
7007     2003-04-25 Jonathan Coles <[email protected]>
7008    
7009 jonathan 756 * Thuban/Model/save.py (SessionSaver.write_projection): Make sure
7010     to save the name of the projection.
7011    
7012     * test/test_save.py (SaveSessionTest.testLayerProjection): New
7013     test to verify layer projections are saved correctly.
7014    
7015     2003-04-25 Jonathan Coles <[email protected]>
7016    
7017 jonathan 753 * Thuban/Model/proj.py (Projection.SetName): Set the name
7018     to "Unknown" if name is None.
7019     (Projection.SetAllParameters): New. Set the projection's
7020     parameter list to the one supplied.
7021     (Projection.SetProjection): New. Set the projection's
7022     properties to those of the supplied Projection.
7023    
7024     * Thuban/UI/mainwindow.py (MainWindow.MapProjection): Set
7025     the dialog title to include the map's title.
7026     (MainWindow.LayerProjection): Set the dialog title to include
7027     the layer's title.
7028    
7029     * Thuban/UI/projdialog.py (ProjFrame.__ShowError): Consolidate
7030     error dialogs into a single method call.
7031     (ProjFrame.__VerifyButtons): Add more states to check.
7032     (ProjFrame.__GetProjection): Return the current state of an
7033     edited projection or None.
7034     (ProjFrame.__FillAvailList): Remove checks for states that
7035     shouldn't exist.
7036     (ProjFrame._OnNew): Clear all selected items and supply
7037     a projection panel if necessary.
7038    
7039     * test/test_proj.py (TestProjFile.test): Add tests for
7040     ProjFile.SetAllParameters, ProjFile.SetProjection,
7041     ProjFile.SetName.
7042    
7043     2003-04-25 Jonathan Coles <[email protected]>
7044    
7045 jonathan 748 * Thuban/UI/projdialog.py (ProjFrame.__FillAvailList): Now
7046     takes an optional argument to select the current projection.
7047     This does not guarantee that the item is visible due to
7048     limited wxWindows functionality. Fixes RTBug #1821.
7049    
7050     2003-04-25 Jonathan Coles <[email protected]>
7051    
7052 jonathan 743 * Thuban/Model/load.py (SessionLoader.start_projection): Remember
7053     the projection name and use it when constructing the Projection
7054     object.
7055    
7056     * Thuban/Model/proj.py (Projection.__init__): Change the default
7057     value for 'name' to None and then test if name is equal to None
7058     in the body of the constructor. This way the caller doesn't have to
7059     know what the default value should be. Namely, useful in load.py
7060     where we have to pick a default value if the 'name' parameter
7061     doesn't exist in the XML file.
7062    
7063     * test/test_load.py (LoadSessionTest.testLayerProjection): New.
7064     Tests a file where a layer has a projection.
7065    
7066     2003-04-25 Jonathan Coles <[email protected]>
7067    
7068 jonathan 735 * Thuban/Model/layer.py (Layer.TreeInfo): Add an item to the
7069     tree for projection information.
7070    
7071     * Thuban/Model/load.py (XMLReader.GetFilename): Renamed from
7072     XMLReader.GetFileName.
7073     (SessionLoader): Added support for loading projection tags that
7074     appear inside a layer.
7075    
7076     * Thuban/Model/proj.py (ProjFile): Document the class. Move
7077     back to using a list because the order of the projections in
7078     the file is important to maintain. Fixes RTbug #1817.
7079    
7080     * Thuban/Model/resource.py: Rename calls to ProjFile.GetFileName
7081     to ProjFile.GetFilename.
7082    
7083     * Thuban/Model/save.py (SessionSaver.write_layer): Save projection
7084     information.
7085    
7086     * Thuban/UI/projdialog.py (ProjFrame._OnAddToList): Renamed from
7087     ProjFrame._OnSaveAs. Removed old dead code from previous
7088     implementation.
7089     (ProjFrame._OnExport): Add support for exporting more than one
7090     projection to a single file.
7091     (ProjFrame.__FillAvailList): use string formatting (% operator)
7092     to build strings that are (partly) translated. Fixes RTbug #1818.
7093    
7094     * test/test_proj.py (TestProjFile.test): New. Tests the base ProjFile
7095     class.
7096    
7097 bh 734 2003-04-24 Bernhard Herzog <[email protected]>
7098    
7099     * po/es.po: Updated Spanish translation by Daniel Calvelo Aros
7100    
7101     * po/fr.po: New. French translation by Daniel Calvelo Aros
7102    
7103     * Thuban/UI/projdialog.py (ProjFrame._OnSaveAs): Don't translate
7104     empty strings.
7105    
7106 jonathan 735 2003-04-24 Jonathan Coles <[email protected]>
7107 jonathan 724
7108     * Thuban/Model/layer.py (Layer.GetProjection): New. Needed to
7109     implement the interface that the ProjFrame dialog expects.
7110    
7111     * Thuban/Model/proj.py (Projection.SetName): New. Allows the
7112     name of the projection to be changed.
7113     (ProjFile): Use a dictionary instead of a list so that removing
7114     projections is easier and we are sure about uniqueness.
7115     (ProjFile.Remove): Remove the given projection object.
7116    
7117     * Thuban/Model/resource.py (GetSystemProjFiles, GetUserProjFiles):
7118     Return a list with only one projection file instead of searching for
7119     any projection file. This simplifies many things if the user can
7120     only have one system file and one user file.
7121    
7122     * Thuban/UI/classgen.py: Change all references to
7123     genCombo to genChoice.
7124    
7125     * Thuban/UI/mainwindow.py: Add a Projection option under the
7126     layer menu.
7127     (MainWindow.LayerProjection): New. Open up a projection window
7128     for a layer.
7129    
7130     * Thuban/UI/projdialog.py: Large changes to how the dialog is
7131     laid out. Use three panels instead of one. One for the list of
7132     projections, one for the edit controls, and one for the buttons.
7133     Fixed resizing problems so that the dialog resizes correctly
7134     when the projection panel changes. Added import/export, save, and
7135     new buttons/functionality.
7136    
7137 bh 723 2003-04-24 Bernhard Herzog <[email protected]>
7138    
7139     First step towards table management. Introduce a simple data
7140     abstraction so that we replace the data a layer uses more easily
7141     in the next step.
7142    
7143     * Thuban/Model/data.py: New file with a simple data abstraction
7144     that bundles shapefile and dbffile into one object.
7145    
7146     * Thuban/Model/session.py (Session.OpenShapefile): New method to
7147     open shapefiles and return a shape store object
7148    
7149     * Thuban/Model/layer.py (Layer.__init__): Pass the data as a store
7150     object instead of a shapefile filename. This introduces a new
7151     instance variable store holding the datastore. For intermediate
7152     backwards compatibility keep the old instance variables.
7153     (open_shapefile): Removed. No longer needed with the shape store.
7154     (Layer.SetShapeStore, Layer.ShapeStore): New methods to set and
7155     get the shape store used by a layer.
7156     (Layer.Destroy): No need to explicitly destroy the shapefile or
7157     table anymore.
7158    
7159     * Thuban/UI/mainwindow.py (MainWindow.AddLayer)
7160     (MainWindow.AddLayer): Use the session's OpenShapefile method to
7161     open shapefiles
7162    
7163     * Thuban/Model/load.py (ProcessSession.start_layer): Use the
7164     session's OpenShapefile method to open shapefiles
7165    
7166     * test/test_classification.py
7167     (TestClassification.test_classification): Use the session's
7168     OpenShapefile method to open shapefiles and build the filename in
7169     a more platform independed way
7170    
7171     * test/test_layer.py (TestLayer.setUp, TestLayer.tearDown):
7172     Implement to have a session to use in the tests
7173     (TestLayer.test_arc_layer, TestLayer.test_polygon_layer)
7174     (TestLayer.test_point_layer, TestLayer.test_empty_layer): Use the
7175     session's OpenShapefile method to open shapefiles
7176     (TestLayerLegend.setUp): Instantiate a session so that we can use
7177     it to open shapefiles.
7178     (TestLayerLegend.tearDown): Make sure that all references to
7179     layers and session are removed otherwise we may get a resource
7180     leak
7181    
7182     * test/test_map.py (TestMapAddLayer.test_add_layer)
7183     (TestMapWithContents.setUp): Instantiate a session so that we can
7184     use it to open shapefiles.
7185     (TestMapWithContents.tearDown): Make sure that all references to
7186     layers, maps and sessions are removed otherwise we may get a
7187     resource leak
7188     ("__main__"): use support.run_tests() so that more info about
7189     uncollected garbage is printed
7190    
7191     * test/test_save.py (SaveSessionTest.testSingleLayer): Use the
7192     session's OpenShapefile method to open shapefiles
7193     ("__main__"): use support.run_tests() so that more info about
7194     uncollected garbage is printed
7195    
7196     * test/test_selection.py (TestSelection.tearDown): Make sure that
7197     all references to the session and the selection are removed
7198     otherwise we may get a resource leak
7199     (TestSelection.get_layer): Instantiate a session so that we can
7200     use it to open shapefiles.
7201     ("__main__"): use support.run_tests() so that more info about
7202     uncollected garbage is printed
7203    
7204     * test/test_session.py (TestSessionBase.tearDown)
7205     (TestSessionWithContent.tearDown): Make sure that all references
7206     to the session and layers are removed otherwise we may get a
7207     resource leak
7208     (TestSessionWithContent.setUp): Use the session's OpenShapefile
7209     method to open shapefiles
7210    
7211 jonathan 721 2003-04-24 Jonathan Coles <[email protected]>
7212    
7213     * Thuban/Model/load.py (XMLReader.read): Should have been checking
7214     if the file_or_filename object had the 'read' attribute.
7215    
7216 jonathan 715 2003-04-23 Jonathan Coles <[email protected]>
7217    
7218 jonathan 720 * Thuban/Model/resource.py: Fixes RTbug #1813.
7219     (ReadProjFile): Add documentation about which exceptions are raised.
7220     Always pass the exceptions up to the caller.
7221     (GetProjFiles): If the directory can't be read return an empty list.
7222     If any of the proj files can't be read skip that file and go
7223     on to the next one.
7224    
7225     * test/test_proj.py: Added test cases to handle nonexistent files,
7226     unreadable files, and files that don't parse correctly.
7227    
7228     2003-04-23 Jonathan Coles <[email protected]>
7229    
7230 jonathan 716 Projection dialog. Allows the user to select from a list
7231     of projection templates and optionally edit them and save new ones.
7232    
7233     * Thuban/UI/projdialog.py (ProjFrame): New. Main dialog.
7234     (ProjPanel): Base class for projection specific panels.
7235     (TMPanel): Projection panel for Transverse Mercartor.
7236     (UTMPanel): Projection panel for Universal Transverse Mercartor.
7237     (LCCPanel): Projection panel for Lambert Conic Conformal.
7238     (GeoPanel): Projetion panel for Geographic Projection.
7239    
7240     2003-04-23 Jonathan Coles <[email protected]>
7241    
7242 jonathan 715 * Thuban/Model/load.py (XMLReader): Renamed from XMLProcessor to
7243     promote symmetry. There now exists XMLReader and XMLWriter.
7244     (XMLReader.read): New. Call to read the given file descriptor or
7245     filename.
7246     (XMLReader.close): New. Make sure the file is closed.
7247     (XMLReader.GetFileName): New. Return just the file name that is being
7248     read from.
7249     (XMLReader.GetDirectory): New. Return just the directory of the file
7250     that is being read.
7251     (XMLReader.AddDispatchers): New. Take a dictionary which contains
7252     the names of functions to call as the XML tree is parsed.
7253     (XMLReader.startElementNS): Updated to use new dispatcher dictionary.
7254     (XMLReader.endElementNS): Updated to use new dispatcher dictionary.
7255     (SessionLoader): Removed class variables start_dispatcher and
7256     end_dispatcher since this functionality is now part of a class
7257     instance. Fixes RTbug #1808.
7258     (SessionLoader.__init__): Add dispatcher functions.
7259     (load_xmlfile): Code was moved into the XMLReader.read().
7260     (load_session): Use modified SessionLoader.
7261    
7262     * Thuban/Model/map.py (Map.GetProjection): New. Returns the
7263     map's projection.
7264    
7265     * Thuban/Model/proj.py (Projection.GetParameters): Renamed to
7266     GetAllParameters.
7267     (Projection.GetParameter): Returns the value for the given parameter.
7268    
7269     * Thuban/Model/resource.py: Use XMLReader and XMLWriter.
7270     (GetProjFiles): Renamed from GetProjections. Now returns a list
7271     of ProjFile objects.
7272     (GetSystemProjFiles): Renamed from GetSuppliedProjections. Returns
7273     a list of ProjFile objects whose files are not user defined.
7274     (GetUserProjFiles): Renamed from GetUserProjections. Returns a
7275     list of ProjFile objects whose files are user defined.
7276     (ProjFileReader): Extend new XMLReader.
7277    
7278     * Thuban/Model/save.py (XMLWriter): Renamed from XMLSaver to
7279     promote symmetry.
7280    
7281     * Thuban/UI/classgen.py (ClassGenDialog.__init__): Use a wxChoice
7282     control instead of a wxComboBox. wxChoice controls do not generate
7283     events as the uses highlights possible choices which fixes problems
7284     with resizing the dialog when the use selects an option.
7285    
7286     * Thuban/UI/classifier.py (Classifier.__init__): Use a wxChoice
7287     control instead of a wxComboBox.
7288    
7289     * Thuban/UI/mainwindow.py (MainWindow.Projection): Use new projection
7290     dialog.
7291    
7292     * test/test_proj.py (TestProjection.test): New tests for GetParameter
7293     method.
7294    
7295 bh 703 2003-04-22 Bernhard Herzog <[email protected]>
7296    
7297 bh 705 * Thuban/UI/mainwindow.py: Remove some unused imports and global
7298     constants
7299    
7300 bh 703 * Thuban/UI/identifyview.py (IdentifyListCtrl.selected_shape)
7301     (IdentifyGridCtrl.selected_shape): Use table, not shapetable.
7302    
7303 bh 700 2003-04-17 Bernhard Herzog <[email protected]>
7304    
7305 bh 701 * Thuban/Model/layer.py: Don't import LAYER_LEGEND_CHANGED.
7306     (Layer): Update doc-string since LAYER_LEGEND_CHANGED is not used
7307     anymore.
7308     (Layer.BoundingBox, Layer.GetFieldType, Layer.NumShapes)
7309     (Layer.ShapeType, Layer.Shape): No need to call
7310     self.open_shapefile since it's always called in __init__
7311    
7312 bh 700 * Thuban/UI/application.py (ThubanApplication.MainLoop): Removed.
7313     In wxPython 2.4 there's no need to extend MainLoop anymore since
7314     wxPython itself makes sure OnExit is called.
7315    
7316 jonathan 688 2003-04-16 Jonathan Coles <[email protected]>
7317    
7318 jonathan 693 Initial putback of projection management code. Includes new
7319     classes to read and write projection files. The current load
7320     and save classes were abstracted a bit so they could be reused.
7321     The Projection class was extended to provide new methods and
7322     have a name.
7323    
7324     * Thuban/Model/load.py (XMLProcessor): New. Contains all the
7325     general XML reading methods that were part of ProcessSession.
7326    
7327     * Thuban/Model/proj.py (Projection.__init__): Accepts an optional
7328     name.
7329     (ProjFile): New. Represents a file that contains projection
7330     information.
7331    
7332     * Thuban/Model/resource.py: New. Contains general utilities
7333     for read and writing projection files.
7334    
7335     * Thuban/Model/save.py (XMLSaver): New. Contains all the
7336     general XML writing methods that were part of SessionSaver.
7337     (SessionSaver): Renamed from Saver.
7338    
7339     * test/test_proj.py: New test cases for the projection
7340     file read and write functions.
7341    
7342     2003-04-16 Jonathan Coles <[email protected]>
7343    
7344 jonathan 688 * Thuban/Model/classification.py: Use repr() around values
7345     in the ClassGroup*.__repr__() methods so it is clearer when
7346     a value is a string and when it is a number.
7347    
7348     * test/test_load.py: Rework the classification test to test
7349     that we can load old files.
7350     (testLabels): Test a file where the groups have labels.
7351    
7352 bh 687 2003-04-16 Bernhard Herzog <[email protected]>
7353    
7354     Safer implementation of the performance enhancements of the
7355     low-level renderer:
7356    
7357     * extensions/thuban/wxproj.cpp (extract_projection)
7358     (extract_pointer): Rename extract_projection to extract_pointer
7359     and redefine its purpose to return the pointer stored in a CObject
7360     returned by the object's cobject method. Update all callers.
7361     (s_draw_info, free_draw_info, draw_polygon_init): Implement the
7362     handling of these low-level parameters so that each s_draw_info
7363     instance is handled as a CObject at python level that also
7364     contains real references to the actual python objects which
7365     contain the values in the struct. Add free_draw_info as the
7366     destructor.
7367     (draw_polygon_shape): Add the py_draw_info parameter which must a
7368     cobject containing an s_draw_info pointer.
7369    
7370     * Thuban/UI/renderer.py (MapRenderer.polygon_render_param): New
7371     method to instantiat the low-level render parameter
7372     (MapRenderer.draw_shape_layer): Use the new method. Remove some
7373     commented out code.
7374     (MapRenderer.draw_polygon_shape): Make the first parameter not the
7375     layer but the low-level render parameter
7376     (ScreenRenderer.draw_shape_layer): Use the low-level render
7377     parameter.
7378    
7379 jonathan 673 2003-04-15 Jonathan Coles <[email protected]>
7380    
7381 jonathan 680 * Thuban/Model/classification.py: Implemented __repr__ for
7382     the ClassGroup* classes to make debugging a bit easier.
7383     (ClassGroup.SetLabel): Check that the string is an instance
7384     of StringTypes not StringType. Accounts for Unicode strings.
7385    
7386     * Thuban/Model/color.py: Implemented __repr__ to make
7387     debugging a bit easier.
7388    
7389     * Thuban/Model/save.py (Saver.write_classification): Need to
7390     save the group label.
7391    
7392     * test/test_load.py (testClassification): New. Loads the
7393     iceland_sample_test.thuban file and checks if it was loaded
7394     correctly.
7395    
7396     2003-04-15 Jonathan Coles <[email protected]>
7397    
7398 jonathan 673 * extensions/thuban/wxproj.cpp (draw_polygon_init): New. Used
7399     to improve rendering performance by initializing the variables
7400     that are not change each time draw_polygon_shape() is called.
7401     The values are stored in a global struct draw_info.
7402     (draw_polygon_shape): Removed initialization code that is
7403     now in draw_polygon_init().
7404    
7405     * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Make
7406 jonathan 674 drawing initialization call to draw_polygon_init()
7407     (MapRenderer.draw_polygon_shape): Use new signature of
7408     draw_polygon_shape.
7409 jonathan 673
7410 jonathan 674 * Thuban/UI/classgen.py (GenUniformPanel): Fix spin control
7411     weirdness by setting the range to (1, maxint).
7412 jonathan 673
7413 jonathan 674 * Thuban/Model/classification.py (ClassGroupProperties): Make
7414     instance variables private and optimize comparison operator
7415     by first checking if the color references are the same.
7416     (ClassGroupSingleton): Make instance variables private.
7417     (ClassGroupRange): Make instance variables private.
7418 jonathan 673
7419 jonathan 674 * HOWTO-Release: Filled in missing steps for releasing packages.
7420    
7421 bh 672 2003-04-15 Bernhard Herzog <[email protected]>
7422    
7423     First stab at internationalized messages:
7424    
7425     * Thuban/__init__.py (_): Implement the translation function for
7426     real using the python gettext module.
7427    
7428     * Thuban/UI/classifier.py (ClassTable.GetRowLabelValue): Don't
7429     translate empty strings.
7430    
7431     * Thuban/UI/application.py (ThubanApplication.read_startup_files):
7432     Add a missing space to a warning message
7433    
7434     * po/README: New. Notes about the management of the translation
7435     files.
7436    
7437     * po/Makefile: New. Makefile to help manage the translation files.
7438    
7439     * po/es.po: New. Spanish translation by Daniel Calvelo Aros
7440    
7441     * MANIFEST.in: Include the *.mo files in Resources/Locale and the
7442     translations and support files in po/
7443    
7444     * setup.py (data_files): Add the *.mo files to the data_files too
7445    
7446     * README: Add note about the translations when building from CVS
7447    
7448 jonathan 669 2003-04-14 Jonathan Coles <[email protected]>
7449    
7450     * Thuban/UI/dock.py: Fixes some window resizing problems most
7451     noticable under windows. Always assume the button bitmaps will
7452     be there. Code clean up.
7453     (DockabelWindow.Dock, DockableWindow.UnDock): Force all the
7454     images for the dock/undock button to the same images.
7455     Work around for RTbug #1801.
7456    
7457     * Thuban/UI/legend.py (LegendPanel.__init__): The toolbar should
7458     be allowed to grow within the sizer. Fixes a bug under Windows
7459     where the toolbar wasn't being drawn.
7460    
7461 frank 664 2003-04-14 Frank Koormann <[email protected]>
7462    
7463     * Resources/Bitmaps/dock_12.xpm, Resources/Bitmaps/undock_12.xpm:
7464     Updated design to try to make the button functionality more
7465     transparent.
7466    
7467 jonathan 662 2003-04-14 Jonathan Coles <[email protected]>
7468    
7469     * Thuban/UI/legend.py (LegendPanel.__init__): Call Create() to
7470     finalize the intialization of the panel.
7471    
7472     * Thuban/UI/dock.py (DockPanel.Create): New. Finalizes the
7473     creation of the panel. Should be the last thing called in the
7474     initializer of a subclass.
7475    
7476     * Thuban/UI/classgen.py (ClassGenDialog.__init__): Actively
7477     set the current selections in the combo boxes. This is needed
7478     under Windows.
7479    
7480     * Thuban/UI/classifier.py (Classifier.__init__): Add a top
7481     level panel to the dialog so that the background colors are
7482     consistent under Windows.
7483    
7484 jonathan 646 2003-04-11 Jonathan Coles <[email protected]>
7485    
7486 jonathan 662 * Thuban/UI/classgen.py: Change color ramps to start at white
7487     not black.
7488    
7489     * Thuban/UI/legend.py: Enable/disable the legend buttons when
7490     the legend changes. Fixes RTbug #1793.
7491    
7492     * test/test_classification.py: Added test for copying of
7493     classifications.
7494    
7495     2003-04-11 Jonathan Coles <[email protected]>
7496    
7497 jonathan 647 * Thuban/UI/resource.py: New. Centralize the loading of resources
7498     such as bitmaps.
7499    
7500     * Thuban/UI/classgen.py (GenUniquePanel.__init__): Reordered buttons,
7501     added images to the move buttons, added 'reverse' button.
7502     (CustomRampPanel.__init__): Added images to the move buttons.
7503     (GreyRamp): New. Generates a ramp from white to black.
7504     (HotToColdRamp): New. Generates a ramp from cold to hot colors.
7505    
7506     * Thuban/UI/classifier.py: Refactored ID's from ID_CLASSIFY_* to
7507     ID_PROPERTY_*.
7508     (Classifier.__init__): Minor changes to the layout.
7509     (Classifier._OnTitleChanged): Listen for when the user edits the
7510     title and update the dialog's title and the layer's title.
7511    
7512     * Thuban/UI/dock.py: Use new bitmaps for the control buttons.
7513    
7514     * Thuban/UI/legend.py: Use new bitmaps for the control buttons.
7515     (LegendTree._OnMsgLayerTitleChanged): Change the displayed title
7516     if the layer's title changes.
7517    
7518     * Thuban/UI/mainwindow.py: Added new menu item and associated code
7519     to open a dialog to rename the map.
7520     (MainWindow): Use new resource class to import bitmaps.
7521    
7522     2003-04-11 Jonathan Coles <[email protected]>
7523    
7524 jonathan 646 * Resources/Bitmaps/close_12.xpm, Resources/Bitmaps/dock_12.xpm,
7525 jonathan 647 Resources/Bitmaps/group_use.xpm, Resources/Bitmaps/group_use_all.xpm,
7526     Resources/Bitmaps/group_use_none.xpm,
7527     Resources/Bitmaps/group_use_not.xpm,
7528     Resources/Bitmaps/hide_layer.xpm,
7529     Resources/Bitmaps/layer_properties.xpm,
7530     Resources/Bitmaps/lower_layer.xpm, Resources/Bitmaps/raise_layer.xpm,
7531     Resources/Bitmaps/show_layer.xpm, Resources/Bitmaps/undock_12.xpm:
7532     New.
7533 jonathan 646
7534 jonathan 636 2003-04-10 Jonathan Coles <[email protected]>
7535    
7536 jonathan 644 * Thuban/Model/classification.py: (ClassGroupRange.__init__):
7537     Should pass group to ClassGroup constructor.
7538    
7539     2003-04-10 Jonathan Coles <[email protected]>
7540    
7541 jonathan 636 * Thuban/Model/classification.py: (ClassGroup): Move all the common
7542     methods of the derived classes ([Set|Get]Properties(), __eq__, __ne__)
7543     here. Implement SetVisible(), IsVisible().
7544     (ClassGroup.__init__): Add group parameter which acts as a copy
7545     constructor.
7546    
7547     * Thuban/UI/classifier.py (ClassTable): Add a new column for the
7548     "Visible" check boxes.
7549     (Classifier): Rename the buttons and refactor the code to match
7550     the new labels.
7551    
7552     * Thuban/UI/legend.py: Classify button is now called "Properties".
7553     Refactored the code to change variable names.
7554     (LegendTree.__FillTreeLayer): Only list a group if it is visible.
7555    
7556     * Thuban/UI/mainwindow.py: MainWindow.OpenClassifier renamed to
7557     MainWindow.OpenLayerProperties. MainWindow.LayerEditProperties
7558     renamed to MainWindow.LayerEditProperties.
7559     (MainWindow.ToggleLegend): Don't include map name in legend title.
7560     (MainWindow.SetMap): Added the map name to the window title.
7561     (MainWindow.LayerFillColor, MainWindow.LayerTransparentFill,
7562     MainWindow.LayerOutlineColor, MainWindow.LayerNoOutline): Removed.
7563     Functionality is found in the layer properties dialog.
7564    
7565     * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Only
7566     draw visible groups.
7567    
7568 jonathan 626 2003-04-09 Jonathan Coles <[email protected]>
7569    
7570 jonathan 634 * Thuban/UI/classgen.py: Modifications to allow simple
7571     addition and selection of new color schemes.
7572     (MonochromaticRamp): New. Generates a ramp between two colors.
7573     (RedRamp): New. Generates a ramp of all red.
7574     (GreenRamp): New. Generates a ramp of all green.
7575     (BlueRamp): New. Generates a ramp of all blue.
7576    
7577     2003-04-09 Jonathan Coles <[email protected]>
7578    
7579 jonathan 626 * Thuban/Model/classification.py (Classification.__deepcopy__):
7580     Need to copy over field and fieldType attributes.
7581    
7582     * Thuban/Model/table.py (Table.field_range): New. Retrive the
7583     maximum and minimum values over the entire table for a given
7584     field.
7585     (Table.GetUniqueValues): New. Retrieve all the unique values
7586     in the table for a given field.
7587    
7588     * Thuban/UI/classgen.py: Renamed GenRangePanel to GenUniformPanel.
7589     (GenUniquePanel): New. Controls to allow the user to select
7590     which unique field values they would like in the classification.
7591     (CustomRampPanel): Code that was in ClassGenDialog that allows
7592     the user to select the properties for a custom ramp.
7593     (ClassGenerator.GenUniformDistribution): Was called GenerateRanges.
7594    
7595     * Thuban/UI/classifier.py: Removed a lot of debugging code.
7596     (Classifier._SetClassification): Callback method so that the
7597     class generator can set the classification in the grid.
7598     (ClassGroupPropertiesCtrl): New. Encapsulates the drawing and
7599     editing of a group properties class into a wxWindows control.
7600    
7601     * Thuban/UI/dock.py: It was decided that if the user closes
7602     a dockable window the window should simply hide itself. That
7603     way if the user wants to show the dock again it appears in the
7604     same place as it was when it was closed.
7605     (DockableWindow.Destroy): Call renamed method OnDockDestroy().
7606     (DockableWindow._OnButtonClose): Hide the window instead of
7607     destroying it.
7608     (DockableWindow._OnClose): Hide the window instead of
7609     destroying it.
7610    
7611     * Thuban/UI/legend.py (LegendTree): Use a private method to
7612     consistently set the font and style of the text. Fixes RTbug #1786.
7613    
7614     * Thuban/UI/mainwindow.py: Import just the Classifier class.
7615    
7616 bh 623 2003-04-07 Bernhard Herzog <[email protected]>
7617    
7618 bh 625 * Thuban/UI/mainwindow.py (main_menu): Move the toggle_legend item
7619     to the map module
7620    
7621     2003-04-07 Bernhard Herzog <[email protected]>
7622    
7623 bh 623 * Thuban/UI/mainwindow.py (MainWindow.ShowSessionTree): Removed in
7624     favor of ToggleSessionTree
7625     (MainWindow.ToggleSessionTree): New method to toggle visibility of
7626     the session tree.
7627     (MainWindow.SessionTreeShown): New method to return whether the
7628     session tree is currently shown.
7629     (MainWindow.ToggleLegend): New method to toggle visibility of the
7630     legend
7631     (MainWindow.ShowLegend): Implement in terms of ToggleLegend and
7632     LegendShown
7633     (MainWindow.LegendShown): New method to return whether the legend
7634     is currently shown.
7635     (_method_command): Add checked parameter so we can define check
7636     menu items
7637     (_has_tree_window_shown, _has_legend_shown): Use the appropriate
7638     mainwindow methods.
7639     (show_session_tree, show_legend commands): Removed.
7640     (toggle_session_tree, toggle_legend commands): New commands to
7641     toggle the visibility of the dialogs
7642    
7643 jonathan 612 2003-04-07 Jonathan Coles <[email protected]>
7644    
7645 jonathan 619 * Thuban/UI/classgen.py: Fix Windows problem.
7646    
7647     * Thuban/UI/dock.py: Fix Windows problem.
7648    
7649     * Thuban/UI/mainwindow.py: Use False instead of false.
7650     (MainWindow.ShowLegend): Remove unnecessary switch parameter.
7651    
7652     2003-04-07 Jonathan Coles <[email protected]>
7653    
7654 jonathan 612 Since we now say that the order of the groups in a classification
7655     matters, it makes sense to be able to manipulate that order. Most
7656     of the changes to Thuban/Model/classification.py are to that end.
7657    
7658     * Thuban/Model/classification.py (Classification.AppendGroup,
7659     Classification.InsertGroup, Classification.ReplaceGroup,
7660     Classification.RemoveGroup, Classification.GetGroup): Do as the
7661     names imply.
7662     (Classification.FindGroup): This was called GetGroup, but GetGroup
7663     takes an index, while FindGroup takes a value.
7664     (Classification.__deepcopy__): Copy all the groups, BUT NOT THE LAYER
7665     REFERENCE. Currently there is a cyclic reference between the layer
7666     and its classification. If the classification doesn't need to know
7667     its owning layer we can change this, since it may make sense to be
7668     able to use the same classification with different layers.
7669    
7670     * Thuban/Model/load.py: Use Classification.AppendGroup(), not AddGroup()
7671    
7672     * Thuban/UI/classgen.py: Use Classification.AppendGroup(),
7673     not AddGroup()
7674    
7675     * Thuban/UI/classifier.py: Now that we can depend on the order in
7676     a Classification and have methods to manipulate that order we don't
7677     need to use our own data structures in the grid. We can simply make
7678     the grid/table access the information they need from a copy of
7679     the classification object.
7680     (Classifier._OnCloseBtn): Event handler for when the user clicks
7681     'Close'. This is needed so if the user applies changes and then
7682     continues to change the table the user has the option of discarding
7683     the most recent changes and keeping what they applied.
7684    
7685     * Thuban/UI/mainwindow.py: Put "Show Legend" and "Show Session Tree"
7686     into the same group.
7687    
7688     * extensions/thuban/wxproj.cpp (check_version): If Thuban is compiled
7689     with a really old version of proj, PJ_VERSION won't even be defined.
7690     If it isn't defined then just compile so that the function always
7691     returns Py_False.
7692    
7693     * test/test_classification.py: Fix tests to use the renamed methods.
7694     Still need to write tests for the new methods.
7695    
7696 jonathan 601 2003-04-04 Jonathan Coles <[email protected]>
7697 jonathan 608
7698 jonathan 612 * Thuban/UI/classifier.py (Classifier.__SelectField): Move the
7699     call to SetSelection out of the method and before the call
7700     to __SelectField in __init__. This prevents a recursion of events
7701     when _OnFieldSelect is triggered by the user.
7702    
7703     2003-04-04 Jonathan Coles <[email protected]>
7704    
7705 jonathan 608 * Thuban/Model/classification.py: Rename Color.None to
7706     Color.Transparent.
7707     (ClassGroupProperties.SetLineColori, ClassGroupProperties.SetFill):
7708     Don't bother copying the color, since Colors are immutable.
7709    
7710     * Thuban/Model/color.py, Thuban/Model/layer.py, Thuban/Model/load.py,
7711     Thuban/UI/classifier.py, Thuban/UI/mainwindow.py,
7712     Thuban/UI/renderer.py, Thuban/UI/view.py:
7713     Rename Color.None to Color.Transparent.
7714    
7715     * test/test_classification.py, test/test_load.py: Rename Color.None
7716     to Color.Transparent.
7717    
7718     2003-04-04 Jonathan Coles <[email protected]>
7719 jonathan 603
7720     * Thuban/Model/classification.py: Fix assert calls.
7721     (ClassGroupProperties.SetLineColor, ClassGroupProperties.SetFill):
7722     Copy the color parameter rather than hold onto a reference.
7723 jonathan 601
7724 jonathan 603 * Thuban/Model/color.py (Color.__copy__, Color.__deepcopy): Copy
7725     the color object.
7726     (NoColor.__copy__, NoColor.__deepcopy): Return 'self' so that we
7727     are sure there exists only one refernce to Color.None in the system.
7728     This allows us to use 'is' rather than the comparision functions.
7729    
7730     * Thuban/Model/save.py: Fix assert calls.
7731    
7732     * Thuban/UI/classifier.py: Fix assert calls.
7733     (ClassGrid._OnCellDClick): Call up to the classifier to open the
7734     dialog to edit the groups properties.
7735     (ClassGrid._OnCellResize): Make sure that the scollbars are drawn
7736     correctly if a cell is resized.
7737     (ClassTable.SetClassification): New. Changes the classification
7738     that is in the table.
7739     (ClassTable.__SetRow): Allow groups to be prepended.
7740     (Classifier): New code for opening the EditProperties and
7741     GenerateRanges dialogs.
7742     (SelectPropertiesDialog.__GetColor): Only set the color in the
7743     color dialog if the current color is not None.
7744    
7745     * Thuban/UI/dock.py: Fix assert calls.
7746    
7747     * Thuban/UI/legend.py: Fix assert calls.
7748    
7749     * Thuban/UI/renderer.py: Fix assert calls.
7750    
7751     * Thuban/UI/classgen.py (ClassGenDialog): Dialog for generating
7752     classifications.
7753     (GenRangePanel): Panel specific to range generation.
7754     (GenSingletonPanel): Panel specific to singleton generation.
7755     (ClassGenerator): Class responsible for actually generating
7756     the classification from the data gathered in the dialog box.
7757     (PropertyRamp): Generates properties whose values range from
7758     a starting property to an ending property.
7759 jonathan 601
7760 bh 600 2003-04-03 Bernhard Herzog <[email protected]>
7761    
7762     * test/support.py (print_garbage_information): New function that
7763     prints information about still connected messages and memory
7764     leaks.
7765     (run_suite): Removed.
7766     (run_tests): New function for use as a replacement of
7767     unittest.main in the test_* files. This one calls
7768     print_garbage_information at the end.
7769    
7770     * test/runtests.py (main): Use support.print_garbage_information
7771    
7772     * test/test_layer.py: Use support.run_tests instead of
7773     unittest.main so we get memory leak information
7774     (TestLayer.test_arc_layer, TestLayer.test_polygon_layer)
7775     (TestLayer.test_point_layer, TestLayer.test_empty_layer)
7776     (TestLayerLegend.test_visibility): Call the layer's Destroy method
7777     to fix a memory leak.
7778    
7779     * test/test_classification.py: Use support.run_tests instead of
7780     unittest.main so we get memory leak information
7781     (TestClassification.test_classification): Call the layer's Destroy
7782     method to fix a memory leak.
7783    
7784 bh 591 2003-04-02 Bernhard Herzog <[email protected]>
7785    
7786 bh 595 * extensions/thuban/wxproj.cpp (check_version, check_version_gtk):
7787     Handle the reference counts of the return value and errors in
7788     PyArg_ParseTuple correctly.
7789    
7790 bh 593 * Thuban/UI/application.py (ThubanApplication.OpenSession): Make
7791     sure the filename is absolute to avoid problems when saving the
7792     session again
7793    
7794 bh 591 * Thuban/Model/table.py: Remove unnecessary import. Fix a typo.
7795    
7796 jonathan 587 2003-04-01 Jonathan Coles <[email protected]>
7797    
7798 jonathan 589 * Thuban/UI/renderer.py (MapRenderer.draw_point_shape): Check
7799 jonathan 587 that there actually are points in the returned list of points
7800     before trying to index into the list. The list may be empty if
7801     the shape is a Null Shape.
7802    
7803 bh 586 2003-04-01 Bernhard Herzog <[email protected]>
7804    
7805     * test/test_map.py: Don't use from <module> import *
7806    
7807 jonathan 581 2003-04-01 Jonathan Coles <[email protected]>
7808    
7809     * Thuban/Model/session.py: Use LAYER_CHANGED instead of
7810     LAYER_LEGEND_CHANGED
7811    
7812     * Thuban/UI/dock.py (DockableWindow._OnButtonClose): Call
7813     self.Destroy() to close the window after yesterday's changes.
7814    
7815     * test/test_map.py, test/test_session.py: Fix messages that
7816     are sent from maps and layers.
7817    
7818 jonathan 575 2003-03-31 Jonathan Coles <[email protected]>
7819    
7820     * Thuban/UI/classifier.py: Commented out some debugging statements.
7821     (ClassDataPreviewer.Draw): Draw rectangles for polygon layers per
7822     RTbug #1769.
7823    
7824     * Thuban/UI/dock.py (DockableWindow.UnDock): Restore size and
7825     position (although position doesn't work yet under GTK).
7826     (DockableWindow.Destroy): New. Called when the window must be
7827     closed. Namely needed when the DockFrame closes and must close
7828     its children.
7829     (DockFrame): Listen for EVT_CLOSE and destroy all children.
7830    
7831     * Thuban/UI/legend.py (LegendPanel.Destroy): New. Cleans up
7832     when then window is told to close.
7833     (LegendTree._OnMsgLayerChanged): Fixes a seg fault bug. See
7834     comment in source for more info.
7835    
7836     * Thuban/UI/main.py: Show the legend by default when Thuban starts.
7837    
7838     * Thuban/UI/mainwindow.py: Renamed OnClose to _OnClose for
7839     symmetry with other such methods.
7840     (MainWindow.ShowLegend): Show the legend docked by default.
7841    
7842 jonathan 569 2003-03-28 Jonathan Coles <[email protected]>
7843    
7844     * Thuban/UI/classifier.py: Support for highlighting a specific
7845     group within the grid when the classification dialog is opened.
7846     Also contains a lot of debugging printouts which will later
7847     be removed.
7848    
7849     * Thuban/UI/dock.py: Complete rework on the dock code so that
7850     that it is fairly removed from the rest of the Thuban application.
7851     It is easy to add new docks which the rest of the program having
7852     to be aware of them.
7853    
7854     * Thuban/UI/legend.py: Modifications to support selecting a
7855     specific group in the classification dialog. Changed how layers
7856     are drawn when the layer is visible/invisible.
7857    
7858     * Thuban/UI/mainwindow.py: Removed legend specific code and
7859     replaced it with calls to the new dock code.
7860    
7861     * Thuban/UI/renderer.py (MapRenderer.__init__): Added assert
7862     to check if scale > 0. Trying to track down a divide by zero.
7863    
7864 jonathan 557 2003-03-26 Jonathan Coles <[email protected]>
7865    
7866 jonathan 567 * Thuban/UI/legend.py: Removed unnecessary LegendDialog class.
7867     (LegendPanel): Removed _OnDock()/_OnUnDock() methods which are
7868     now part of DockableWindow.
7869     (LegendPanel.DoOnSelChanged): Select the current layer in the
7870     map.
7871     (LegendTree._OnSelChanged): Call LegendPanel.DoOnSelChanged()
7872     with the selected layer and/or group.
7873    
7874     2003-03-26 Jonathan Coles <[email protected]>
7875    
7876 jonathan 557 This putback contains the code for dockable windows. There is
7877     no support in wxWindows as of this date for windows that can
7878     attach themselves to other windows.
7879    
7880     The current model contains a DockableWindow which has a parent
7881     window for when it is detached and a dock window that it puts
7882     its contents in when it is docked. The contents of a DockableWindow
7883     must be a DockPanel. DockPanel itself derives from wxPanel.
7884    
7885     * Thuban/Model/layer.py (Layer.ClassChanged): Send a LAYER_CHANGED
7886     message, not a LAYER_LEGEND_CHANGED message.
7887    
7888     * Thuban/Model/map.py (Map): Forward LAYER_CHANGED messages.
7889    
7890     * Thuban/UI/classifier.py (Classifier.__init__): Use wxADJUST_MINSIZE
7891     as one of the style properties for the fieldTypeText item to
7892     be sure that its size is correct when the text changes.
7893    
7894     * Thuban/UI/dock.py: New. Classes for the DockPanel and
7895     DockableWindow.
7896    
7897     * Thuban/UI/legend.py: Added some more buttons and made the
7898     LegendPanel a DockPanel.
7899    
7900     * Thuban/UI/mainwindow.py: Added sash windows to the main window
7901     and supporting functions for manipulating the sashes.
7902     (MainWindow.ShowLegend): Create a DockableWindow with the
7903     LegendPanel as the contents.
7904    
7905     * Thuban/UI/messages.py: Added DOCKABLE_* messages
7906    
7907     * Thuban/UI/view.py (MapCanves.SetMap): Listen for LAYER_CHANGED,
7908     not LAYER_LEGEND_CHANGED, messages.
7909    
7910 jonathan 554 2003-03-25 Jonathan Coles <[email protected]>
7911    
7912     * setup.py: Added custom script bdist_rpm_build_script so that
7913     when the rpm is built the path to wx-config is correct.
7914    
7915     * setup.cfg: Added line saying to use the custom build script
7916    
7917 jonathan 552 2003-03-20 Jonathan Coles <[email protected]>
7918    
7919     Initial implementation of the Legend.
7920    
7921     * Thuban/UI/legend.py: New. Creates a window that shows the map's
7922     Legend information and allows the user to add/modify classifications
7923     and how the layers are drawn on the map.
7924    
7925     * setup.py: New command 'build_docs' which currently uses
7926     happydoc to generate html documentation for Thuban.
7927    
7928     * Thuban/Model/classification.py (ClassGroup.GetDisplayText): New.
7929     Returns a string which is appropriately describes the group.
7930    
7931     * Thuban/Model/layer.py (Layer.SetClassification): Generate a
7932     LAYER_CHANGED event instead of a LAYER_LEGEND_CHANGED event.
7933    
7934     * Thuban/Model/map.py (Map): Rename messages and use new, more
7935     specific, messages.
7936    
7937     * Thuban/Model/messages.py: New message to indicate that a layer's
7938     data has changed (LAYER_CHANGED). New map messages to indicate
7939     when layers have been added/removed/changed or if the stacking order
7940     of the layers has changed.
7941    
7942     * Thuban/Model/session.py: Rename and use new messages.
7943    
7944     * Thuban/UI/classifier.py: Remember if any changes have actually
7945     been applied so that if the dialog is cancelled without an application
7946     of changes we don't have to set a new classification.
7947     (ClassDataPreviewer): Pulled out the window specific code and put it
7948     ClassDataPreviewWindow. ClassDataPreviewer can then be used to draw
7949     symbols on any DC.
7950    
7951     * Thuban/UI/mainwindow.py: New code to open the legend.
7952    
7953     * Thuban/UI/view.py: Use new message names.
7954    
7955 jonathan 541 2003-03-19 Jonathan Coles <[email protected]>
7956    
7957     * Thuban/UI/main.py (verify_versions): New. Checks the versions
7958     of Python, wxPython, and some other libraries.
7959    
7960     * extensions/thuban/wxproj.cpp (check_version): Checks the given
7961     version against what wxproj was compiled with.
7962     (check_version_gtk): If wxproj was compiled with gtk then check
7963     the given version against the version of the gtk library
7964     currently being used.
7965    
7966 bh 538 2003-03-14 Bernhard Herzog <[email protected]>
7967    
7968     * test/test_command.py: Run the tests when the module is run as a
7969     script
7970    
7971     2003-03-14 Bernhard Herzog <[email protected]>
7972    
7973     Implement selection of multiple selected shapes in the same layer:
7974    
7975     - Introduce a new class to hold the selection. This basically
7976     replaces the interactor which was nothing more than the
7977     selection anyway. A major difference is of course that the new
7978     selection class supports multiple selected shapes in one layer
7979    
7980     - Move the object that represents the selection from the
7981     application to the canvas. The canvas is a better place than the
7982     application because the selection represents which shapes and
7983     layer of the map displayed by the canvas are selected and
7984     affects how the map is drawn.
7985    
7986     - Make the selection and its messages publicly available through
7987     the mainwindow.
7988    
7989     - The non-modal dialogs do not get a reference to the interactor
7990     anymore as they can simply refer to their parent, the
7991     mainwindow, for the what the interactor had to offer.
7992    
7993     * Thuban/UI/selection.py: New module with a class to represent the
7994     selection.
7995    
7996     * Thuban/UI/messages.py (SELECTED_TABLE, SELECTED_MAP): Remove
7997     these unused messages
7998    
7999     * Thuban/UI/application.py (ThubanApplication.OnInit)
8000     (ThubanApplication.OnExit, ThubanApplication.SetSession): The
8001     interactor is gone now.
8002     (ThubanApplication.CreateMainWindow): There is no interactor
8003     anymore so we pass None as the interactor argument for now for
8004     compatibility.
8005    
8006     * Thuban/UI/view.py (MapCanvas.delegated_messages)
8007     (MapCanvas.Subscribe, MapCanvas.Unsubscribe): In Subscribe and
8008     Unsubscribe, delegate messages according to the delegated_messages
8009     class variable.
8010     (MapCanvas.__getattr__, MapCanvas.delegated_methods): Get some
8011     attributes from instance variables as described with the
8012     delegated_methods class variable.
8013     (MapCanvas.__init__): New instance variable selection holding the
8014     current selection
8015     (MapCanvas.do_redraw): Deal with multiple selected shapes. Simply
8016     pass them on to the renderer
8017     (MapCanvas.SetMap): Clear the selection when a different map is
8018     selected.
8019     (MapCanvas.shape_selected): Simple force a complete redraw. The
8020     selection class now takes care of only issueing SHAPES_SELECTED
8021     messages when the set of selected shapes actually does change.
8022     (MapCanvas.SelectShapeAt): The selection is now managed in
8023     self.selection
8024    
8025     * Thuban/UI/mainwindow.py (MainWindow.delegated_messages)
8026     (MainWindow.Subscribe, MainWindow.Unsubscribe): In Subscribe and
8027     Unsubscribe, delegate messages according to the delegated_messages
8028     class variable.
8029     (MainWindow.delegated_methods, MainWindow.__getattr__): Get some
8030     attributes from instance variables as described with the
8031     delegated_methods class variable.
8032     (MainWindow.__init__): The interactor as ivar is gone. The
8033     parameter is still there for compatibility. The selection messages
8034     now come from the canvas.
8035     (MainWindow.current_layer, MainWindow.has_selected_layer):
8036     Delegate to the the canvas.
8037     (MainWindow.LayerShowTable, MainWindow.Classify)
8038     (MainWindow.identify_view_on_demand): The dialogs don't need the
8039     interactor parameter anymore.
8040    
8041     * Thuban/UI/tableview.py (TableFrame.__init__)
8042     (LayerTableFrame.__init__, LayerTableFrame.OnClose)
8043     (LayerTableFrame.row_selected): The interactor is gone. It's job
8044     from the dialog's point of view is now done by the mainwindow,
8045     i.e. the parent. Subscribe to SHAPES_SELECTED instead
8046     of SELECTED_SHAPE
8047    
8048     * Thuban/UI/dialogs.py (NonModalDialog.__init__): The interactor
8049     is gone. It's job from the dialog's point of view is now done by
8050     the mainwindow, i.e. the parent.
8051    
8052     * Thuban/UI/classifier.py (Classifier.__init__): The interactor is
8053     gone. It's job from the dialog's point of view is now done by the
8054     mainwindow, i.e. the parent.
8055    
8056     * Thuban/UI/tree.py (SessionTreeView.__init__): The interactor is
8057     gone. It's job from the dialog's point of view is now done by the
8058     mainwindow, i.e. the parent.
8059     (SessionTreeCtrl.__init__): New parameter mainwindow which is
8060     stored as self.mainwindow. The mainwindow is need so that the tree
8061     can still subscribe to the selection messages.
8062     (SessionTreeCtrl.__init__, SessionTreeCtrl.unsubscribe_all)
8063     (SessionTreeCtrl.update_tree, SessionTreeCtrl.OnSelChanged): The
8064     selection is now accessible through the mainwindow. Subscribe to
8065     SHAPES_SELECTED instead of SELECTED_SHAPE
8066    
8067     * Thuban/UI/identifyview.py (IdentifyView.__init__): Use the
8068     SHAPES_SELECTED message now.
8069     (IdentifyView.selected_shape): Now subscribed to SHAPES_SELECTED,
8070     so deal with multiple shapes
8071     (IdentifyView.__init__, IdentifyView.OnClose): The interactor is
8072     gone. It's job from the dialog's point of view is now done by the
8073     mainwindow, i.e. the parent.
8074    
8075     * Thuban/UI/controls.py (RecordListCtrl.fill_list): The second
8076     parameter is now a list of shape ids.
8077     (RecordTable.SetTable): The second parameter is now a list of
8078     indices.
8079    
8080     * Thuban/UI/renderer.py (ScreenRenderer.RenderMap): Rename the
8081     selected_shape parameter and ivar to selected_shapes. It's now a
8082     list of shape ids.
8083     (MapRenderer.draw_label_layer): Deal with multiple selected
8084     shapes. Rearrange the code a bit so that the setup and shape type
8085     distinctions are only executed once.
8086    
8087     * test/test_selection.py: Test cases for the selection class
8088    
8089 jonathan 527 2003-03-11 Jonathan Coles <[email protected]>
8090    
8091     * Thuban/Model/load.py: Temporary fix so that the xml reader
8092     doesn't cause Thuban to crash.
8093    
8094     * Thuban/Model/layer.py: Handle the cyclic references between
8095     a layer and its classification better, and be sure to disconnect
8096     the classification from the layer when the layer is destroyed
8097     so that we don't maintain a cyclic reference that may not be
8098     garbage collected.
8099    
8100     * Thuban/Model/classification.py: See comment for layer.py.
8101    
8102 jan 523 2003-03-12 Jan-Oliver Wagner <[email protected]>
8103    
8104     * HOWTO-Release: New. Information on the steps for releasing
8105     a new version of Thuban.
8106    
8107 jonathan 514 2003-03-11 Jonathan Coles <[email protected]>
8108    
8109     * Thuban/UI/classifier.py: Add normal border to SelectPropertiesDialog.
8110     Use True instead of true.
8111     (Classifier): Should have a single panel in which all the controls lie.
8112    
8113     * Thuban/UI/proj4dialog.py: Add normal border.
8114    
8115     * Thuban/UI/tree.py: Fixed problem with bad item images under Windows.
8116    
8117     * Thuban/UI/mainwindow.py: Use True instead of true.
8118    
8119     * setup.py: Update some definitions to use wxWindows2.4 files
8120    
8121     * Data/iceland_sample_class.thuban: Fixed file so that the
8122     field_type information is present.
8123    
8124 jonathan 490 2003-03-10 Jonathan Coles <[email protected]>
8125    
8126 jonathan 505 * Thuban/UI/classifier.py (Classifier.__init__): Make the
8127     field type label grow so that when the text changes the
8128     size is updated correctly. This may be a wxWindows bug.
8129    
8130     2003-03-10 Jonathan Coles <[email protected]>
8131    
8132 jonathan 499 * Thuban/UI/application.py: Changed SESSION_CHANGED to
8133     SESSION_REPLACED.
8134    
8135     * Thuban/UI/classifier.py: Wrap text with _().
8136     (ClassGrid.CreateTable): Set dimensions and size hints here,
8137     instead of in Reset, so we only set the size once.
8138    
8139     * Thuban/UI/dialogs.py: Don't need Shutdown(); just use Close()!
8140    
8141     * Thuban/UI/mainwindow.py (MainWindow.prepare_new_session):
8142     Call Close() instead of Shutdown().
8143    
8144     * Thuban/UI/messages.py: Changed SESSION_CHANGED to SESSION_REPLACED.
8145    
8146     * Thuban/UI/tree.py: Changed SESSION_CHANGED to SESSION_REPLACED.
8147     Go back to using OnClose() instead of Shutdown().
8148    
8149     2003-03-10 Jonathan Coles <[email protected]>
8150    
8151 jonathan 497 * Thuban/UI/classifier.py (Classifier): SelectField() needed
8152     to know the old field index as well as the new one.
8153    
8154     2003-03-10 Jonathan Coles <[email protected]>
8155    
8156 jonathan 495 * Thuban/UI/classifier.py (Classifier): Use __SelectField()
8157     to correctly set the table information and call this from
8158     __init__ and from _OnFieldSelect so that all the information
8159     is up to date when the dialog opens and when a field is changed.
8160    
8161     2003-03-10 Jonathan Coles <[email protected]>
8162    
8163 jonathan 490 * Thuban/Model/classification.py (Classification): Don't use
8164     layer's message function directly, use the ClassChanged() method
8165     when then classification changes. SetField/SetFieldType/SetLayer
8166     must keep the information about field name and field type in
8167     sync when an owning layer is set or removed.
8168    
8169     * Thuban/Model/layer.py: Added ClassChanged() so that the
8170     classification can tell the layer when its data has changed.
8171     (Layer.SetClassification): Accepts None as an arguement to
8172     remove the current classification and correctly handles
8173     adding a new classification.
8174    
8175     * Thuban/Model/load.py: Comment out print statement
8176    
8177     * test/test_classification.py, test/test_save.py: New and
8178     improved tests.
8179    
8180 jonathan 483 2003-03-07 Jonathan Coles <[email protected]>
8181    
8182     * Thuban/Model/classification.py: Implemented __copy__ and
8183     __deepcopy__ for ClassGroup* and ClassGroupProperites so
8184     they can easily be copied by the classifier dialog.
8185     (ClassGroupProperites.__init__): The default line color should
8186     have been Color.Black.
8187    
8188     * Thuban/UI/classifier.py: Setting and Getting table values now
8189     uses a consistent set of functions.
8190     (Classifier): Now non-modal. Has field type label which changes
8191     as the field changes. Keep track of buttons in a list so that
8192     we can enable/disable the buttons when the None field is selected.
8193     (SelectPropertiesDialog): Add buttons to make the colors transparent.
8194    
8195     * Thuban/UI/dialogs.py (NonModalDialog.Shutdown): New method which
8196     does what OnClose did, but can be called by the application to
8197     close a window. Needed when a session changes, and we have to
8198     close the classifier windows.
8199    
8200     * Thuban/UI/mainwindow.py (MainWindow.prepare_new_session):
8201     Shuts down open dialogs. Used when a new session is created
8202     or a session is opened.
8203     (MainWindow.SaveSession): Should only call application.SaveSession()
8204     if we don't call SaveSessionAs first.
8205     (MainWindow.Classify): Allow different classifier dialogs for
8206     different layers.
8207    
8208     * Thuban/UI/tree.py (SessionTreeView): Remove OnClose and let
8209     the parent class handle it. Add Shutdown() to unsubscibe from
8210     event notification and call the parent Shutdown(). This was
8211     necessary so the application can close the tree window.
8212    
8213 jonathan 478 2003-03-06 Jonathan Coles <[email protected]>
8214    
8215     * Thuban/Model/classification.py: Minor documentation changes,
8216     Addition of __eq__ and __ne__ methods.
8217     (Classification.SetLayer): prevent recursion between this method
8218     and Layer.SetClassification().
8219    
8220     * Thuban/Model/color.py: Addition of __eq__ and __ne__ methods.
8221    
8222     * Thuban/Model/layer.py (SetClassification): prevent recursion
8223     between this method and Classification.SetLayer().
8224    
8225     * test/test_classification.py, test/test_load.py,
8226     test/test_session.py: Fixed and added tests for the classification
8227     classes.
8228    
8229 bh 477 2003-03-06 Bernhard Herzog <[email protected]>
8230    
8231     * Thuban/UI/classifier.py (ClassGrid.__init__)
8232     (ClassGrid.CreateTable): Move the SetSelectionMode call to
8233     CreateTable because otherwise it triggers an assertion in
8234     wxPython/wxGTK 2.4.
8235    
8236 jonathan 459 2003-03-05 Jonathan Coles <[email protected]>
8237    
8238 jonathan 475 * Thuban/common.py: Move FIELDTYPE constants back to table.py.
8239 jonathan 471
8240 jonathan 475 * Thuban/Model/load.py: import FIELDTYPE constants from table.
8241 jonathan 471
8242 jonathan 475 * Thuban/UI/classifier.py: import FIELDTYPE constants from table.
8243 jonathan 471
8244 jonathan 475 * Thuban/Model/table.py: Put FIELDTYPE constants back.
8245 jonathan 471
8246     2003-03-05 Jonathan Coles <[email protected]>
8247    
8248 jonathan 459 * Thuban/UI/classifier.py: Added class documentation.
8249     Fixed RTbug #1713, #1714. Added Move[Up|Down] buttons.
8250     Store just the groups in the table and generate the other
8251     column information when it is requested. Add "None" field
8252     to pull-down to select no classification.
8253    
8254     * Thuban/common.py: Moved FIELDTYPE constants from table.py
8255     (Str2Num): Only catch ValueError exceptions.
8256    
8257     * Thuban/Model/classification.py: Class documentation. Renaming
8258     of methods with Stroke to Line. Groups are stored in a single
8259     list with the default as the first element. Groups are searched
8260     in the order they appear in the list.
8261    
8262     * Thuban/Model/color.py: Documentation.
8263    
8264     * Thuban/Model/layer.py (Layer): Add GetFieldType to retreive
8265     the kind of data represented by a field.
8266    
8267     * Thuban/Model/load.py (ProcessSession): Use proper string
8268     conversion function; fixes RTbug #1713.
8269    
8270     * Thuban/Model/save.py (Saver): Store field type information.
8271    
8272     * Thuban/Model/table.py: Put FIELDTYPE constants in common.py.
8273     (Table): Add field_info_by_name() to retrieve field information
8274     by specifying the field name, not the number.
8275    
8276     * Thuban/UI/mainwindow.py: Function name changes.
8277    
8278     * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Only
8279     get the layer classification once. Don't try to classify
8280     values when the field is None: just use the default properties.
8281    
8282     * Thuban/UI/view.py: Function name changes.
8283    
8284     * Doc/thuban.dtd: Add field_type attribute to a classification.
8285    
8286 bh 456 2003-03-04 Bernhard Herzog <[email protected]>
8287    
8288 bh 458 * Doc/thuban.dtd: Use correct syntax for optional attributes. Make
8289     the fill and stroke layer attributes optional with suitable
8290     default values. Add the stroke_width layer attribute. Use correct
8291     syntax for empty elements. Make the attribute list for labels
8292     refer to the label element.
8293    
8294     2003-03-04 Bernhard Herzog <[email protected]>
8295    
8296 bh 456 * setup.py (thuban_build_py.build): Add a comment about distutils in
8297     Python 2.3 containing some of the functionality we implement in
8298     setup.py ourselves.
8299    
8300     * Thuban/UI/classifier.py (ClassGrid.__init__): Set the table
8301     before the selection mode. Doing it the other way round triggers
8302     an assertion in wxWindows.
8303    
8304     * Thuban/Model/save.py (escape): Fix typo in doc-string
8305    
8306     * Thuban/Model/classification.py: Remove unnecessary wxPython
8307     import
8308    
8309 jonathan 448 2003-03-04 Jonathan Coles <[email protected]>
8310    
8311     * Thuban/Model/classification.py (ClassGroupRange.GetProperties):
8312     Parameter 'value' should default to None.
8313    
8314     * Thuban/UI/mainwindow.py: Use Layer.GetClassification() since
8315     the class attribute __classification is now private.
8316    
8317     * Thuban/UI/classifier.py (ClassGrid): Moved OnCellDClick() from
8318     Classifier to ClassGrid. Added support for removing selected rows,
8319     which including code for keeping track of when cells are selected,
8320     and deselected.
8321     (ClassTable): Support for added/removing rows. Fixed a problem
8322     with __ParseInput whereby it would not allow strings (only numbers)
8323     to be entered.
8324     (Classifier): Added button and supporting code for removing
8325     selected rows.
8326    
8327 jonathan 445 2003-02-27 Jonathan Coles <[email protected]>
8328 jonathan 434
8329     * Thuban/common.py: Moved color conversion functions into
8330     Thuban/UI/common.py.
8331     (Str2Num): Now converts the float (not the string) to a long/int
8332     so that an exception isn't thrown.
8333    
8334     * Thuban/UI/common.py: Common functions used in several UI modules
8335    
8336     * Thuban/Model/classification.py: Changed the class hierarchy
8337     so that a Classification consists of Groups which return
8338     Properties when a value matches a Group.
8339    
8340     * Thuban/Model/layer.py: Fixed name resolution problem.
8341    
8342     * Thuban/Model/load.py: Use new Classification and Group functions.
8343    
8344     * Thuban/Model/save.py (Saver.write_attribs): Fixes a test case
8345     failure.
8346     (Saver.write_classification): Use new Classification and Group
8347     functions.
8348    
8349     * Thuban/UI/classifier.py: Changes to use new Classification and Group
8350 jonathan 445 functions. Fix to create a tuple with a single value instead of
8351     simply returning the value.
8352 jonathan 434
8353     * Thuban/UI/renderer.py: Use new Classification and Group functions.
8354     Use common.py functions.
8355    
8356 jonathan 445 * Thuban/UI/tree.py: Use common.py functions.
8357 jonathan 447
8358     * test/test_classification.py: Use new Classification and Group
8359     classes.
8360 jonathan 434
8361 jonathan 426 2003-02-24 Jonathan Coles <[email protected]>
8362    
8363     * Thuban/common.py (Color2wxColour, wxColour2Color): Conversion
8364     functions from Thuban color objects to wxWindow colour objects.
8365    
8366     * Thuban/Model/classification.py (Classification): Renamed
8367     GetProperties() to GetClassData(). Used the new iterator
8368     in TreeInfo().
8369     (ClassIterator): Iterator implementation to iterate over the
8370     ClassData objects in a classification object.
8371    
8372     * Thuban/Model/save.py (Saver.write_classificaton): Uses
8373     the new iterator to save the classification information.
8374    
8375     * Thuban/UI/classifier.py (SelectPropertiesDialog): Support
8376     for changing the stroke and fill colors and previewing the
8377     changes.
8378    
8379     * Thuban/UI/mainwindow.py (MainWindow.OpenSession,
8380     MainWindow.SaveSessionAs): Text string changes so the dialogs
8381     have more meaningful titles.
8382    
8383     * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Change
8384     Classification method name from GetProperties to GetClassData.
8385    
8386     * Thuban/UI/view.py (MapCanvas.find_shape_at): Use method calls
8387     instead of accessing now non-existent class variables.
8388    
8389 bh 425 2003-02-24 Bernhard Herzog <[email protected]>
8390    
8391     * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Remove
8392     unneeded Shape() call. Rendering is substantially faster without
8393     it and it avoids some problems with broken shape files.
8394    
8395 frank 423 2003-02-20 Frank Koormann <[email protected]>
8396    
8397     Force minimal size of identify and label dialogs. The autosizing
8398     looked too ugly.
8399    
8400     * Thuban/UI/controls.py (RecordListCtrl): Set minimal width for columns.
8401     * Thuban/UI/labeldialog.py (LabelDialog.dialog_layout):
8402     Set size of listctrl.
8403     * Thuban/UI/identifyview.py (IdentifyView.__init__):
8404     Set size of dialog.
8405    
8406 jonathan 408 2003-02-19 Jonathan Coles <[email protected]>
8407    
8408     * test/test_classification.py, test/test_layer.py,
8409     test/test_load.py, test/test_map.py, test/test_session.py:
8410     Updated the tests to use the new functions that are in the
8411     respective classes.
8412    
8413     * Thuban/Model/classification.py (Classification):
8414     Uses the new ClassData* classes. Modification messages are
8415     passed up to the parent layer (if it exists).
8416     (ClassData): New class to encapsulate the common data in each
8417     classification property.
8418     (ClassDataDefault): Represents the Default class. data.
8419     (ClassDataPoint): Represents a single class. data point
8420     (ClassDataRange): Represents a class. range
8421     (ClassDataMap): Represents a class. map (unused).
8422    
8423     * Thuban/Model/color.py: Added Color.None to represent something
8424     with no color. Color.Black represents the color black.
8425     (NoColor): Helper class derived from Color to represent something
8426     with no color.
8427    
8428     * Thuban/Model/layer.py (Layer): Removed references to fill, stroke,
8429     stroke_width attributes. Made the 'classification' attribute private.
8430     New methods for setting/getting the classification.
8431    
8432     * Thuban/Model/load.py (ProcessSession): Use new methods on Layer
8433     to get the classifcation and use the new ClassData* classes to
8434     hold the classification data. Use Str2Num to convert numbers
8435     properly.
8436    
8437     * Thuban/Model/save.py (Saver): Use new Color and Classification
8438     methods
8439    
8440     * Thuban/UI/classifier.py (ClassGrid): New class to represent a
8441     custom grid.
8442     (ClassTable): Support for editing Values and Labels and for
8443     changing what type (point or range) of data is stored in each
8444     property based on how the user enters the data.
8445     (Classifier): Support for saving the new classifications and
8446     launching the dialog to edit a property.
8447     (SelectPropertiesDialog): New class for editing the visual
8448     properties of a classification (stroke color, width, and fill color)
8449     (ClassPreviewer): Took the Draw method from ClassRenderer and
8450     made most of it into this new class. Intend to use this class in
8451     the SelectPropertiesDialog for previewing changes.
8452    
8453     * Thuban/UI/renderer.py: Use new Color and Classification methods.
8454    
8455     * Thuban/UI/tree.py: Formatting changes.
8456    
8457     * Doc/thuban.dtd: Add 'label' element
8458    
8459     * Thuban/common.py: New. Contains common routines used throughout
8460     the code.
8461     (Str2Num): Takes a string and converts it to the "best" type of
8462     number.
8463    
8464 bh 405 2003-02-14 Bernhard Herzog <[email protected]>
8465    
8466     * Thuban/UI/view.py (MapCanvas.OnLeftUp): Make sure that the
8467     dragging flag is always set to 0 even when the tool implementation
8468     raises an exception
8469    
8470 bh 402 2003-02-11 Bernhard Herzog <[email protected]>
8471    
8472     * Thuban/UI/application.py (ThubanApplication.splash_screen): New
8473     method to create a splash screen.
8474     (ThubanApplication.ShowMainWindow): New. Show the main window.
8475     Needed so the splash screen can display the mainwindow
8476     (ThubanApplication.OnInit): Call the
8477     new splash_screen method to determine whether the application
8478     should display a splash screen. If it displays a splash screen do
8479     not immediately show the main window.
8480    
8481 jonathan 399 2003-02-11 Jonathan Coles <[email protected]>
8482    
8483     * Thuban/Model/classification.py: Added import line to fix
8484     feature conflicts between running on python2.2 and python2.1.
8485    
8486     * Thuban/UI/classifier.py (ClassTable): Didn't need to hang
8487     onto the clinfo parameter, so removed the deepcopy().
8488    
8489 jonathan 396 2003-02-10 Jonathan Coles <[email protected]>
8490    
8491 tkoester 403 * Thuban/Model/save.py (Saver.open_element, Saver.close_element):
8492 jonathan 396 Added element_open variable to track opening and closing of tags
8493     so that tags that don't span more than one line are closed with
8494     /> instead of </tag_name>. Use the GetDefault*() methods of
8495     the Classification class.
8496    
8497     * Thuban/Model/classification.py (Classificaton): Added set and
8498     get methods for the default data. The class also takes a layer
8499     reference so that modification messages can be sent. Fixed the
8500     methods to use the new ClassData class.
8501     (ClassData): New class to encapsulate the classification data
8502    
8503     * Thuban/Model/layer.py (Layer): Remove the
8504 tkoester 403 Set[Fill|Stroke|StrokeWidth]() methods. Code should call the
8505 jonathan 396 SetDefault*() methods on the layer's classification object.
8506 tkoester 403 (Layer.__init__): Use the new SetDefault*() methods in the
8507 jonathan 396 Classification class.
8508    
8509     * Thuban/Model/load.py (ProcessSession): Use the new ClassData
8510     object instead of a dictionary.
8511    
8512 tkoester 403 * Thuban/UI/classifier.py (ClassRenderer): New class to
8513 jonathan 396 draw the classifications in the dialog box's table.
8514     (Classifier): Modified to use the ClassRenderer class.
8515    
8516 tkoester 403 * Thuban/UI/mainwindow.py (MainWindow): Use the SetDefault*()
8517     methods of the Classification class.
8518 jonathan 396
8519     * Thuban/UI/renderer.py (MapRenderer): Use the Get*() methods
8520     of the ClassData class.
8521    
8522     * test/test_classification.py, test/test_layer.py,
8523     test/test_map.py, test/test_session.py: Fix the tests to work
8524     with the above code changes.
8525    
8526 jonathan 387 2003-02-03 Jonathan Coles <[email protected]>
8527    
8528     * Thuban/Model/classification.py (Classification): Added getNull()
8529     to return the NullData reference
8530    
8531     * Thuban/Model/layer.py (Layer.SetFill, Layer.SetStroke,
8532     Layer.SetStrokeWidth): Modified these functions to change the
8533     null data in the classification rather than keep these values
8534     directly in the Layer class. Menu options to change these values
8535     work again.
8536    
8537 jonathan 380 2003-01-28 Jonathan Coles <[email protected]>
8538    
8539 jonathan 384 * Thuban/UI/classifier.py (Classifier): Resolved merging conflicts.
8540 tkoester 403 Fixed crashing problem on some systems. Dialog box shows
8541 jonathan 380 classification data.
8542    
8543 jonathan 384 * Thuban/UI/tree.py (SessionTreeCtrl.add_items): Handle drawing
8544     Colors in the tree view.
8545    
8546     * Thuban/Model/layer.py (Layer.TreeInfo): Added a call to build
8547     the tree info for classifications. Commented out unnecessary lines.
8548    
8549     * Thuban/Model/classification.py (Classification.TreeInfo): New
8550     function to add information about the classification into the
8551     tree view.
8552    
8553 tkoester 403 2003-01-27 Jan-Oliver Wagner <[email protected]>
8554 jan 375
8555 tkoester 403 * Thuban/__init__.py (_): New.
8556 jan 375
8557     * Thuban/Model/classification.py, Thuban/Model/extension.py,
8558     Thuban/Model/layer.py, Thuban/Model/load.py, Thuban/Model/map.py,
8559 tkoester 403 Thuban/Model/session.py, Thuban/UI/application.py,
8560     Thuban/UI/classifier.py, Thuban/UI/context.py, Thuban/UI/controls.py,
8561     Thuban/UI/identifyview.py, Thuban/UI/labeldialog.py,
8562     Thuban/UI/mainwindow.py, Thuban/UI/menu.py, Thuban/UI/proj4dialog.py,
8563     Thuban/UI/renderer.py, Thuban/UI/tree.py, Thuban/Lib/connector.py,
8564     Thuban/Lib/fileutil.py: Replace user string by _() for i18n.
8565 jan 375
8566 jonathan 370 2003-01-27 Jonathan Coles <[email protected]>
8567    
8568 tkoester 403 * Thuban/Model/layer.py: Classification initialization calls.
8569 jonathan 370
8570 tkoester 403 * Thuban/Model/classification.py: Created class to encapsulate
8571     a layer classification. Supports specific data points and
8572     ranges.
8573 jonathan 370
8574 tkoester 403 * Thuban/Model/load.py: Added support for loading classification
8575     information.
8576 jonathan 370
8577 tkoester 403 * Thuban/Model/save.py: Added support for saving classification
8578     information.
8579 jonathan 370
8580 tkoester 403 * Thuban/UI/classifier.py: Initial class for a dialog box for
8581     specifying classification information.
8582 jonathan 370
8583 tkoester 403 * Thuban/UI/mainwindows.py: Support for opening the classifier
8584     dialog.
8585 jonathan 370
8586 tkoester 403 * Thuban/UI/renderer.py: Support for drawing a layer with the
8587     classification information.
8588 jonathan 370
8589 tkoester 403 * Data/iceland_sample_class.thuban: iceland_sample with
8590     classification data.
8591 jonathan 370
8592 tkoester 403 * test/test_classification: Tests for the Classification class.
8593 jonathan 370
8594 bh 359 2002-12-09 Bernhard Herzog <[email protected]>
8595    
8596 bh 361 * test/test_command.py: New. Tests for the command classes.
8597    
8598 bh 359 * Thuban/UI/command.py (ToolCommand): New class for tool commands.
8599     (Command.IsTool): New method to distinguish between command
8600     switching tools and other commands.
8601    
8602     * Thuban/UI/view.py (MapCanvas.SelectTool): New method to select
8603     the tool to avoid direct assignments to instance variables
8604     (MapCanvas.ZoomInTool, MapCanvas.ZoomOutTool, MapCanvas.PanTool)
8605     (MapCanvas.IdentifyTool, MapCanvas.LabelTool): Use SelectTool to
8606     change the tool
8607    
8608     * Thuban/UI/mainwindow.py (MainWindow.update_command_ui): If an
8609     active tool's command turns insensitive, disable the tool.
8610     (_tool_command): Use the new ToolCommand class
8611    
8612     * Examples/simple_extensions/simple_tool.py (simple_tool): Use the
8613     SelectTool method to change the tool
8614     (iconfile): Use the ToolCommand class
8615    
8616 bh 354 2002-12-03 Bernhard Herzog <[email protected]>
8617    
8618     * Thuban/UI/tree.py (SessionTreeCtrl.normalize_selection): Handle
8619     the case of selected items that are not children of Layers or Maps
8620     properly. Previously this bug would trigger an assertion in
8621     wxWindows.
8622    
8623 frank 352 2002-11-06 Frank Koormann <[email protected]>
8624    
8625 bh 354 * Thuban/UI/mainwindow.py: Altered the order of tools in the
8626     toolbar: First now are all navigation tools (Zoom In/Out, Pan,
8627     Full Extent).
8628 tkoester 403
8629 bh 349 2002-10-23 Bernhard Herzog <[email protected]>
8630    
8631     * setup.py (setup call): version now 0.1.3
8632    
8633     * MANIFEST.in: Add the files in test/
8634    
8635     * test/README: Add note about tests requiring the iceland data
8636    
8637     * Thuban/UI/mainwindow.py (MainWindow.About): Add 2002 to
8638     copyright notice.
8639    
8640 bh 344 2002-10-18 Bernhard Herzog <[email protected]>
8641    
8642     * test/test_map.py
8643     (TestMapWithContents.test_projected_bounding_box): Use an explicit
8644     epsilon.
8645    
8646     * test/support.py (FloatComparisonMixin.assertFloatEqual)
8647     (FloatComparisonMixin.assertFloatSeqEqual): give a more useful
8648     message if the assertion fails and don't return the return value
8649     of self.assert_. In assertFloatSeqEqual the return meant that not
8650     all items of the sequence were compared.
8651    
8652 bh 326 2002-09-20 Bernhard Herzog <[email protected]>
8653    
8654 bh 341 * test/test_fileutil.py: New. Test cases for Thuban.Lib.fileutil
8655    
8656     * Thuban/Lib/fileutil.py: Fixup some whitespace and typos
8657    
8658 bh 338 * test/test_map.py (TestMapWithContents.test_tree_info): Create
8659     the string with the bounding box on the fly because of platform
8660     differences in the way %g is handled.
8661    
8662     * test/test_layer.py (TestLayer.test_empty_layer): Create an empty
8663     DBFfile too because Thuban layers can't yet cope missing DBF
8664     files.
8665    
8666     2002-09-20 Bernhard Herzog <[email protected]>
8667    
8668 bh 326 * test/test_menu.py: Use initthuban instead of
8669     add_thuban_dir_to_path to initialize Thuban.
8670    
8671     * test/support.py (FloatComparisonMixin.assertFloatEqual): New.
8672     Mixin class for float comparisons
8673     (SubscriberMixin): New. Mixin class to test messages sent through
8674     the Connector class
8675    
8676     * test/README: Fix a typo and add the -v flag to the command for
8677     individual tests
8678    
8679 bh 335 * test/test_session.py: New. Test cases for Thuban.Model.session
8680    
8681     * test/test_proj.py: New. Test cases for Thuban.Model.proj
8682    
8683     * test/test_map.py: New. Test cases for Thuban.Model.map
8684    
8685     * test/test_layer.py: New. Test cases for Thuban.Model.layer
8686    
8687     * test/test_label.py: New. Test cases for Thuban.Model.label
8688    
8689     * test/test_connector.py: New. Test cases for Thuban.Lib.connector
8690    
8691     * test/test_color.py: New. Test cases for Thuban.Model.color
8692    
8693     * test/test_base.py: New. Test cases for Thuban.Model.base
8694    
8695 bh 322 2002-09-13 Bernhard Herzog <[email protected]>
8696    
8697     * Thuban/Model/session.py (Session.forwarded_channels): Forward
8698     the CHANGED channel too.
8699    
8700     * Thuban/Model/map.py (Map.forwarded_channels): Forward the
8701     CHANGED channel too.
8702     (Map.__init__): Call the Modifiable constructor as well.
8703    
8704     * Thuban/Model/base.py (Modifiable.UnsetModified): Issue a CHANGED
8705     event if the modified flag changes.
8706     (Modifiable.changed): Tweak the doc-string.
8707    
8708     * Thuban/UI/mainwindow.py (MainWindow.view_position_changed)
8709     (MainWindow.set_position_text): Put the code that puts the text
8710     with the mouse position into the status bar into the new method
8711     set_position_text so that it can overwritten in derived classes.
8712    
8713 bh 317 2002-09-12 Bernhard Herzog <[email protected]>
8714    
8715     * Thuban/UI/mainwindow.py (MainWindow.RunMessageBox): Center the
8716     message box on the main window.
8717    
8718 bh 313 2002-09-11 Bernhard Herzog <[email protected]>
8719    
8720     * Thuban/UI/mainwindow.py: Underline the 'x' in "Exit" instead of
8721     the 'E' because it's less likely to interfere with other menu
8722     entries.
8723 bh 315 (MainWindow.build_menu): remove an incorrect comment.
8724 bh 313
8725 bh 311 2002-09-10 Bernhard Herzog <[email protected]>
8726    
8727     * Thuban/UI/mainwindow.py (MainWindow.Map): New.
8728     (_tool_command): Add sensitive parameter
8729     (_has_visible_map): Sensitivity callback to tools and other
8730     commands that require a visible map. Use it in map_zoom_in_tool,
8731     map_zoom_out_tool, map_pan_tool, map_identify_tool, map_label_tool
8732     and map_full_extent
8733    
8734 bh 308 2002-09-06 Bernhard Herzog <[email protected]>
8735    
8736     * Thuban/UI/mainwindow.py (MainWindow.OnClose): Unsubscribe
8737     VIEW_POSITION
8738    
8739 tkoester 403 2002-09-04 Frank Koormann <[email protected]>
8740 frank 306
8741     * Resources/Bitmaps/fullextent.xpm: Updated Icon (removed "potatoe")
8742    
8743 bh 302 2002-09-02 Bernhard Herzog <[email protected]>
8744    
8745 bh 304 * Thuban/UI/view.py: Get rid of the idle redraw. This is done by
8746     wxWindows already and our implementation doesn't work correctly
8747     with wxGTK 2.3:
8748     (MapCanvas.__init__): Remove the instance variable
8749     (MapCanvas.OnPaint): Always call do_redraw when there's a map to
8750     be drawin
8751     (MapCanvas.OnIdle): Removed.
8752    
8753 bh 302 * Thuban/UI/view.py (MapCanvas.unprojected_rect_around_point): Add
8754     a parameter to determine the size of the rectangle.
8755     (MapCanvas.find_shape_at): Create the box around the point on a
8756     layer by layer basis and make the size depend on the shape type.
8757     This solves a problem with the selection of point shapes at the
8758     border of the layer's bounding box
8759    
8760 bh 292 2002-08-30 Bernhard Herzog <[email protected]>
8761    
8762 bh 300 * Thuban/UI/mainwindow.py (MainWindow.CanRemoveLayer): New method
8763     for the sensitivity of remove layer.
8764     (_can_remove_layer): New. Sensitivity callback for remove layer
8765     (Command layer_remove): Use _can_remove_layer
8766    
8767     * Thuban/Model/map.py (Map.CanRemoveLayer): New method to
8768     determine whether a given layer can be deleted.
8769    
8770 bh 297 * Thuban/UI/view.py (MapCanvas.__init__, MapCanvas.OnPaint)
8771     (MapCanvas.do_redraw): Get rid of the unused update_region
8772     instance variable
8773    
8774 bh 294 * Thuban/UI/view.py: Add/update some doc-strings.
8775    
8776 bh 292 * test/: new subdirectory with a bunch of unit tests.
8777    
8778     * test/README, test/test_table.py, test/test_save.py,
8779     test/test_menu.py, test/test_load.py: Initial set of tests and
8780     brief instructions on how to run them
8781    
8782 bh 287 2002-08-29 Bernhard Herzog <[email protected]>
8783    
8784 bh 291 * Thuban/UI/renderer.py (ScreenRenderer.draw_shape_layer): Handle
8785     arcs with multiple parts.
8786    
8787 bh 289 * Thuban/UI/view.py (ZoomInTool.MouseUp, ZoomOutTool.MouseUp):
8788     Handle degenrate rectangles.
8789    
8790 bh 287 * Thuban/Model/table.py: Make writing records work correctly:
8791     (Table.__init__): Keep track of whether the DBF is open for
8792     writing
8793     (Table.write_record): Open the DBF file for writing when necessary
8794    
8795 bh 285 2002-08-27 Bernhard Herzog <[email protected]>
8796    
8797     * Thuban/Model/table.py (Table.write_record, Table.__init__): Open
8798     dbf files only for reading by default. Use a new writable dbf
8799     object for writing.
8800    
8801 bh 278 2002-08-26 Bernhard Herzog <[email protected]>
8802    
8803 bh 282 * Thuban/UI/mainwindow.py: Refactor the context creation:
8804     (MainWindow.Context): New method to return a context
8805     (MainWindow.invoke_command, MainWindow.update_command_ui): Use the
8806     new method
8807    
8808 bh 278 * Thuban/UI/tableview.py (TableGrid, LayerTableGrid): Split the
8809     layer table specific code from TableGrid into LayerTableGrid
8810     (TableFrame, LayerTableFrame): Split the layer table specific code
8811     from TableFrame into LayerTableFrame
8812 bh 280 (LayerTableGrid.select_shape): Remove a debug print
8813 bh 278
8814     * Thuban/UI/mainwindow.py (MainWindow.LayerShowTable): Use the
8815     LayerTableFrame
8816    
8817 bh 277 2002-08-23 Bernhard Herzog <[email protected]>
8818    
8819     * Thuban/Model/layer.py (Layer.__init__): Make sure we have an
8820     absolute filename.
8821    
8822 bh 269 2002-08-22 Bernhard Herzog <[email protected]>
8823    
8824 bh 275 * Thuban/Model/table.py (Table.write_record): New method to write
8825     records.
8826 tkoester 403 (Table.__init__): Open the DBF file for writing too.
8827 bh 275
8828     * Thuban/UI/controls.py (RecordTable.SetValue): Write the value
8829     into the underlying table.
8830    
8831     * extensions/shapelib/shapefil.h (DBFCommit),
8832     extensions/shapelib/dbfopen.c (DBFCommit): New API function to
8833     commit any changes made to the DBF file.
8834    
8835 bh 271 * Thuban/UI/mainwindow.py (make_check_current_tool)
8836     (_tool_command): Put the code that generates the "checked"
8837     callback into a separate function so that we can reuse it
8838     elsewhere
8839    
8840 bh 269 * Thuban/Model/save.py (Saver): New class to handle serializing a
8841     session into an XML file. The main reason to introduce a class is
8842     that applications built on Thuban can derive from it so that they
8843     can save additional information in a session file.
8844     (save_session): Delegate almost all the work to the Saver class.
8845     Rename the filename argument to file because it may be a file like
8846     object now.
8847    
8848     * Thuban/Model/load.py: Get rid of the Python 1.5.2 compatibility
8849     code. Remove the little test code which would be executed when the
8850     module is run as a script which didn't work anymore since it can't
8851     import the other Thuban modules.
8852     (ProcessSession, load_session): Refactor the ProcessSession to
8853     have one method for each element start and end tag so that derived
8854     classes can easily override the processing of individual tags.
8855     Also, always parse with namespaces enabled because applications
8856     built on top of Thuban will likely use namespaces if they extend
8857     the session file format.
8858    
8859 bh 266 2002-08-21 Bernhard Herzog <[email protected]>
8860    
8861     * setup.py (ThubanInstall.run): Don't repr install_lib_orig
8862     because thubaninit_contents will do it for us.
8863    
8864 tkoester 403 2002-08-16 Jan-Oliver Wagner <[email protected]>
8865 jan 265
8866     * Thuban/UI/mainwindow.py: menu item 'show session tree' now disable if
8867     tree window already open
8868    
8869 bh 259 2002-08-15 Bernhard Herzog <[email protected]>
8870    
8871 bh 263 * Thuban/Model/layer.py (Layer.Destroy): Call the unboundd method
8872     with self.
8873    
8874     * Thuban/UI/view.py (MapCanvas.OnLeftUp): Only release the mouse
8875     when we have actually captured it.
8876    
8877 bh 259 * Thuban/Model/layer.py (Layer.Destroy): New. Explicitly close the
8878     shapefile and destroy the table.
8879    
8880     * Thuban/Model/table.py (Table.Destroy): New. Close the DBF file.
8881    
8882 bh 254 2002-08-14 Bernhard Herzog <[email protected]>
8883    
8884 bh 256 * Thuban/UI/controls.py (RecordTable.__init__): Remove the unused
8885     instance variable columns
8886     (RecordTable.GetTypeName): row and col may be negative in some
8887     cases.
8888    
8889 bh 254 * setup.py (InstallLocal.initialize_options)
8890     (InstallLocal.finalize_options, InstallLocal.user_options): New
8891     option create-init-file to build a thubaninit.py when running
8892     install_local
8893     (InstallLocal.run): Create the thubaninit.py module when requested
8894     (thubaninit_contents): Split the template into several parts and
8895     create a new function thubaninit_contents that creates the
8896     contents of a thubaninit module.
8897     (ThubanInstall.run): Use the new function to create the thubaninit
8898     module.
8899    
8900 bh 252 2002-07-30 Bernhard Herzog <[email protected]>
8901    
8902     * Thuban/UI/application.py (ThubanApplication.OnExit): Do some
8903     cleanup.
8904     (ThubanApplication.MainLoop): Extend to automatically call OnExit.
8905    
8906     * Thuban/Model/session.py (Session.Destroy): Don't bypass the
8907     direct base class' Destroy method.
8908    
8909     * Thuban/Model/map.py (Map.ClearLayers): New method to delete all
8910     layers.
8911     (Map.Destroy): Destroy the label_layer as well and call the
8912     inherited Desatroymethod first so that no more messages are
8913     issued.
8914     (Map.RaiseLayer, Map.LowerLayer): Only issue LAYERS_CHANGED
8915     message if the stacking order actually has changed. Add
8916     doc-strings.
8917     (Map.BoundingBox): Correct the doc-string.
8918     (Map.AddLayer, Map.RemoveLayer, Map.Layers, Map.HasLayers)
8919     (Map.ProjectedBoundingBox, Map.SetProjection): Add doc-strings.
8920    
8921     * Thuban/Model/label.py (LabelLayer.ClearLabels): New to delete
8922     all labels.
8923    
8924 bh 247 2002-07-29 Bernhard Herzog <[email protected]>
8925    
8926     * Thuban/Model/map.py (Map.subscribe_layer_channels)
8927     (Map.unsubscribe_layer_channels): Put the code that (un)subscribes
8928     to a layer's channels into separate methods.
8929     (Map.RemoveLayer, Map.AddLayer): Call the new methods
8930     (Map.Destroy): Unsubscribe from a layer's channels before
8931     destroying it.
8932    
8933     * Thuban/UI/view.py (MapCanvas.find_shape_at): Change the
8934     selected_layer parameter to searched_layer which is the layer to
8935     search in.
8936     (MapCanvas.SelectShapeAt): New parameter layer to restrict the
8937     search to that layer. Return the selected layer and shape.
8938    
8939     * Examples/simple_extensions/simple_tool.py (simple_tool): Fix a
8940     typo
8941    
8942 bh 238 2002-07-24 Bernhard Herzog <[email protected]>
8943    
8944 bh 243 * Thuban/UI/application.py (ThubanApplication.create_session):
8945     Extend the doc string.
8946     (ThubanApplication.subscribe_session)
8947     (ThubanApplication.unsubscribe_session): New methods to
8948     subscribe/unsubscribe to/from session channels.
8949     (ThubanApplication.SetSession): Call the new methods here.
8950     (ThubanApplication.maps_changed, ThubanApplication.set_map):
8951     Renamed set_map to maps_changed. Its now a subscriber for
8952     MAPS_CHANGED.
8953    
8954     * Thuban/UI/view.py (ZoomOutTool.MouseUp): Use the correct
8955     x-coordinate in case of simple clicks
8956    
8957     * Thuban/Model/base.py (Modifiable.changed): Apply the args tuple,
8958     don't pass it as a parameter
8959    
8960     * Thuban/Model/session.py (Session.RemoveMap): New
8961    
8962 bh 238 * Thuban/UI/mainwindow.py (MainWindow.__init__): Turn the initial
8963     window size into a parameter.
8964    
8965 bh 235 2002-07-23 Bernhard Herzog <[email protected]>
8966    
8967 bh 237 * Thuban/UI/menu.py (Menu.item_index): Also search for menus not
8968     just commands.
8969    
8970 bh 235 * Thuban/UI/mainwindow.py (MainWindow.__init__): Change the
8971     parameter list a bit to allow setting the window title and the
8972     initial message in the status bar. Update the callers.
8973    
8974     * Thuban/UI/application.py (ThubanApplication.OnInit)
8975     (ThubanApplication.CreateMainWindow): Put the mainwindow
8976     instantiation into a separate method so that it can be overridden
8977     by a subclass.
8978    
8979 bh 230 2002-07-19 Bernhard Herzog <[email protected]>
8980    
8981 bh 234 * Thuban/Model/session.py: Issue a CHANGED message every time
8982     another changed message is issued to make it easier to get
8983     notified of changes.
8984     (Session): Update the doc string
8985     (Session.forward): Issue changed-events as CHANGED as well.
8986     (Session.changed): Overwrite the inherited version to issue
8987     CHANGED events as well.
8988    
8989     * Thuban/UI/tree.py: We can now simply subscribe to the session's
8990     CHANGED channel to be informed of changes.
8991     (SessionTreeCtrl.session_channels): Not needed any longer.
8992 tkoester 403 (SessionTreeCtrl.unsubscribe_all, SessionTreeCtrl.session_changed):
8993 bh 234 Only have to (un)subscribe CHANGED
8994    
8995     * Thuban/Model/map.py (Map.TreeInfo): Deal better with empty maps.
8996    
8997 bh 230 * Thuban/UI/main.py, Thuban/UI/__init__.py: Move the work-around
8998     for the wxPython locale bug to __init__.py so that it's
8999     automatically executed by anybody using UI code from Thuban.
9000    
9001 bh 225 2002-07-18 Bernhard Herzog <[email protected]>
9002    
9003 bh 228 * Thuban/UI/main.py (main): app no longer needs to be global
9004    
9005     * Thuban/UI/mainwindow.py (MainWindow.__init__): Add application
9006     as parameter and store it in an instance variable
9007     (MainWindow.invoke_command, MainWindow.update_command_ui)
9008     (MainWindow.save_modified_session, MainWindow.NewSession)
9009     (MainWindow.OpenSession, MainWindow.SaveSession)
9010     (MainWindow.SaveSessionAs, MainWindow.ShowSessionTree): Use self's
9011     application object.
9012    
9013     * Thuban/UI/application.py (ThubanApplication.OnInit): Instantiate
9014     the main window with self.
9015    
9016 bh 225 * Thuban/UI/context.py: New module with the context class
9017    
9018     * Thuban/UI/command.py (Command): Update doc string.
9019    
9020     * Thuban/UI/mainwindow.py (MainWindow.invoke_command,
9021     MainWindow.update_command_ui): Pass an instance of the context
9022     class to the command's methods
9023     (check_current_tool, call_method): Handle the new context
9024     implementation
9025    
9026     * Examples/simple_extensions/simple_tool.py (simple_tool,
9027     check_simple_tool): Handle the new context implementation
9028    
9029     * Examples/simple_extensions/simple_command.py (simple_command):
9030     Handle the new context implementation. Update the comments about
9031     the context.
9032    
9033     * Thuban/UI/application.py (ThubanApplication.SetSession): Add
9034     doc-string
9035     (ThubanApplication.Session): New method to return the session
9036     object
9037    
9038     * Thuban/UI/tree.py (SessionTreeCtrl.update_tree): The
9039     interactor's selected_layer may not be a layer of the current
9040     session when the tree is updated while a new session is being set.
9041    
9042 bh 217 2002-07-17 Bernhard Herzog <[email protected]>
9043    
9044     * Thuban/UI/tree.py (color_string): Removed. No longer used.
9045     (SessionTreeCtrl.update_tree, SessionTreeCtrl.add_items): Split
9046     update_tree into update_tree and add_items. The tree now uses a
9047     more generic way to display the contents of the tree.
9048     (SessionTreeCtrl): Add a doc string explaining the TreeInfo method
9049    
9050     * Thuban/Model/layer.py (Layer.TreeInfo),
9051     Thuban/Model/extension.py (Extension.TreeInfo),
9052     Thuban/Model/map.py (Map.TreeInfo),
9053 tkoester 403 Thuban/Model/session.py (Session.TreeInfo):
9054 bh 217 Add TreeInfo methods to implement the new tree view update scheme
9055    
9056 bh 216 2002-07-16 Bernhard Herzog <[email protected]>
9057    
9058     * Thuban/UI/application.py: Don't use "import from" for the
9059     MainWindow. It can't always be resolved.
9060     (ThubanApplication.OnInit): change reference to MainWindow
9061     accordingly.
9062    
9063     * Thuban/UI/menu.py (Menu.SetItems): New method to replace a menu
9064     completely
9065    
9066 bh 213 2002-07-10 Bernhard Herzog <[email protected]>
9067    
9068     * setup.py (create_init_module): New configurable variable whose
9069     default depends on the platform we're running on.
9070     (ThubanInstall.initialize_options): Initialize
9071     self.create_init_module from the global create_init_module
9072     (ThubanInstall.user_options): indictate that the options
9073     create-init-module and init-module-dir have arguments.
9074    
9075     * setup.py: In the setup call change the version number to include
9076     cvs.
9077    
9078     * MANIFEST.in: Add the files in Examples
9079    
9080 bh 205 2002-07-09 Bernhard Herzog <[email protected]>
9081    
9082 bh 210 * setup.py: In the setup call, use the thuban homepage as the
9083     value of the url parameter.
9084    
9085 bh 208 * Examples: New subdirectory for examples.
9086    
9087     * Examples/simple_extensions/simple_tool.xpm,
9088     Examples/simple_extensions/simple_tool.py,
9089     Examples/simple_extensions/simple_command.py,
9090     Examples/simple_extensions/README: Simple examples showing how to
9091     add new commands and tools.
9092    
9093 bh 207 * setup.cfg (bdist_rpm): Add the default value for prefix and tell
9094     bdist_rpm that we also have an install script.
9095     (bdist_inno): Add 2002 to the copyright notice.
9096    
9097 bh 205 * setup.py: Create a file in python's site-packages directory to
9098     make installation of Thuban as a library easier.
9099     (ThubanInstall.user_options): Add two new options,
9100     create-init-module and init-module-dir
9101     (ThubanInstall.expand_with_pure_python_dirs): New method to expand
9102     filenames for installation in the default directories.
9103     (ThubanInstall.select_scheme, ThubanInstall.convert_paths): Extend
9104     the inherited methods to capture some filenames before they're
9105     transformed too much by distutils.
9106     (ThubanInstall.run): Create the init module if requested.
9107     (ThubanInstall.thuban_init_filename): New method to return the
9108     full name of the init module.
9109     (ThubanInstall.get_outputs): Append the filename of the init
9110     module.
9111    
9112 bh 202 2002-07-08 Bernhard Herzog <[email protected]>
9113    
9114 bh 205 * setup.py (thuban_bdist_rpm): Extend this version of bdist_rpm to
9115     handle the prefix properly which means that the default for the
9116     installation prefix should be /usr for RPMs and /usr/local when
9117     doing a normal source install.
9118     (bdist_rpm_install_script): Script to override the default install
9119     commands in the specfile generated by the bdist_rpm command.
9120     (thuban_bdist_rpm.user_options): Add a prefix option
9121     (thuban_bdist_rpm.initialize_options): Init the prefix option.
9122     Create the script files for the spec files as empty files here
9123     (thuban_bdist_rpm._make_spec_file): Override the inherited method
9124     to fill the script files with content.
9125    
9126 bh 202 * Thuban/Model/save.py (relative_filename): Wrapper around
9127     Thuban.Lib.fileutil.relative_filename that accepts an empty dir
9128     argument. save_session now automatically uses this version,
9129     solving a problem when saving to a relative filename.
9130    
9131     * setup.py: In the setup call, make sure that the library
9132     directories are under $prefix/lib not directly under $prefix.
9133    
9134 tkoester 403 2002-06-20 Jan-Oliver Wagner <[email protected]>
9135 jan 199
9136     * Thuban/Model/extension.py: new module to handle extension objects.
9137     * Thuban/Model/messages.py: new messages for extensions.
9138     * Thuban/Model/session.py (Session.Extensions, Session.HasExtensions,
9139     Session.AddExtension): new for handling extensions.
9140     Also some other minor changes to round up extension handling.
9141     * Thuban/UI/tree.py (SessionTreeCrtl:update_tree): Added visualization
9142     of Extension titles and title and names of its objects.
9143    
9144 bh 194 2002-05-29 Bernhard Herzog <[email protected]>
9145    
9146     * Thuban/UI/mainwindow.py (MainWindow.bind_command_events): Bind
9147 bh 202 the events for a command.
9148 bh 194 (MainWindow.add_toolbar_command, MainWindow.add_menu_command):
9149     Call bind_command_events to bind the events. add_toolbar_command
9150     can now bind events too so that it's possible to have commands
9151     that are only available through the toolbar.
9152     (MainWindow.init_ids): New instance variable events_bound to keep
9153     track of for which commands events have been bound.
9154    
9155 bh 190 2002-05-28 Bernhard Herzog <[email protected]>
9156    
9157     * Thuban/UI/menu.py: New module to build and manage menus.
9158    
9159     * Thuban/UI/mainwindow.py: Remove some unused imports.
9160     (MainWindow.__init__, main_menu): move the definition of the main
9161     menu from __init__ to the Menu instance main_menu.
9162     (MainWindow.build_menu_bar, MainWindow.build_menu): New methods to
9163     build the menu bar and sub-menus from a menu description.
9164    
9165     * Thuban/UI/application.py (ThubanApplication.OnInit): Read the
9166     startup file
9167     (ThubanApplication.read_startup_files): New method to run
9168     ~/.thuban/thubanstart.py
9169    
9170 bh 192 * Thuban/UI/mainwindow.py (MainWindow.__init__, main_toolbar):
9171     Move the toolbar definition to the Menu instance main_toolbar.
9172     (MainWindow.build_toolbar): New method to build the toolbar
9173     similar to the build_menu methods
9174    
9175 bh 184 2002-05-23 Bernhard Herzog <[email protected]>
9176    
9177 bh 186 * Thuban/UI/mainwindow.py (MainWindow.__init__): Fix spelling of
9178     layer_outline_color. Fix it in the definition of the command too.
9179    
9180 bh 184 * Thuban/UI/command.py (Command): Fix typo in doc string
9181    
9182 bh 182 2002-05-22 Bernhard Herzog <[email protected]>
9183    
9184     * Thuban/UI/mainwindow.py (MainWindow.RunMessageBox): Fix a typo
9185     in the docstring
9186    
9187 bh 175 2002-05-15 Bernhard Herzog <[email protected]>
9188    
9189 bh 180 * Thuban/Model/layer.py (Layer.open_shapefile): Set bbox to None
9190     when the shapefile is empty.
9191     (Layer.BoundingBox, Layer.LatLongBoundingBox): Both methods may
9192     now return None for empty shapefiles. Update doc-strings.
9193    
9194     * Thuban/Model/map.py (Map.BoundingBox): Add doc-string. Deal with
9195     the layer's bbox being None.
9196    
9197     * Thuban/UI/tree.py (SessionTreeCtrl.update_tree): Deal with the
9198     layer's bbox being None.
9199    
9200 bh 175 * Thuban/UI/view.py (MapCanvas.shape_selected): Only redraw when
9201     necessary.
9202     (MapCanvas.__init__): New instance variables, last_selected_layer
9203     and last_selected_shape to determine how the selection has
9204     changed.
9205    
9206     * Thuban/UI/tableview.py (TableGrid.__init__): Do not call
9207     AutoSizeColumns because it will cause a traversal of the entire
9208     table which for large .dbf files will take a very long time.
9209    
9210 bh 172 2002-05-14 Bernhard Herzog <[email protected]>
9211    
9212     * Thuban/Model/layer.py (Layer.open_shapefile): Choose a better
9213     maximum depth for the tree than shapelib does by default.
9214    
9215 bh 165 2002-05-10 Bernhard Herzog <[email protected]>
9216    
9217     * setup.py (py_modules): The shptree modules doesn't have a
9218     wrapper, so don't include it in the py_modules
9219    
9220 bh 163 2002-05-08 Bernhard Herzog <[email protected]>
9221    
9222     * extensions/shapelib/shptree.c (compare_ints): Make arguments
9223     const void * as in the qsort prototype
9224     (SHPTreeFindLikelyShapes): Remove some unused variables.
9225    
9226     * Thuban/UI/view.py (PanTool.MouseMove): Use the bitmap the view
9227     maintains to redraw the window during a drag.
9228     (MapCanvas.unprojected_rect_around_point): New method to determine
9229     a small region around a point for hit-testing.
9230     (MapCanvas.find_shape_at): Only test the shapes in a small region
9231     around the point.
9232    
9233     * setup.py: Increment the version to 0.1.2
9234    
9235     * Thuban/UI/tree.py (SessionTreeCtrl.unsubscribe_all): Remove a
9236     debug print and set session to None after unsubscribing
9237    
9238 bh 146 2002-05-07 Bernhard Herzog <[email protected]>
9239    
9240 bh 154 * Data/iceland_sample.session, Data/iceland_sample.thuban: Rename
9241     the file to have a .thuban extension.
9242    
9243 bh 152 * Thuban/UI/tree.py (session_channels): New class constant with
9244     all the session channels to subscribe to to update the tree
9245     (SessionTreeCtrl.session_changed): Remember the session so that we
9246     can unsubscribe properly. Use the new class constant to
9247     unsubscribe from the old session and subscribe to the new one.
9248     (SessionTreeCtrl.unsubscribe_all): New method to unsubscribe all
9249     subscriptions of the SessionTreeCtrl.
9250     (SessionTreeView.OnClose): Call the tree's unsubscribe_all method.
9251    
9252     * Thuban/UI/mainwindow.py (MainWindow.__init__): Add the "Show
9253     Session Tree" command to the file menu.
9254    
9255     * Thuban/UI/view.py (MapCanvas.do_redraw): Pass the entire bitmap
9256     as update_region to the renderer.
9257    
9258     * Thuban/UI/renderer.py
9259     (ScreenRenderer.layer_ids, ScreenRenderer.draw_shape_layer): The
9260     update box is now directly a tuple, not a wxRect anymore.
9261    
9262     * Thuban/Model/layer.py (Layer.ShapesInRegion): Remove some debug
9263     prints.
9264    
9265     2002-05-07 Bernhard Herzog <[email protected]>
9266    
9267 bh 146 * setup.py: Add the shptree extension module. See
9268     extensions/pyshapelib/ChangeLog for more details.
9269    
9270     * extensions/shapelib/shpopen.c, extensions/shapelib/shapefil.h,
9271     extensions/shapelib/dbfopen.c: Really update to the versions of
9272     shapelib 1.2.9. For some reason it wasn't really done on
9273     2002-04-11.
9274    
9275     * extensions/shapelib/shptree.c: Modified version of shptree.c of
9276     shapelib 1.2.9. The only real difference is the use of qsort
9277     instead of a bubble sort implementation
9278    
9279     * Thuban/Model/layer.py (Layer.__init__): New instance variable
9280     shapetree to hold the shapelib quadtree for the shapefile
9281     (Layer.open_shapefile): Create the quad tree.
9282     (Layer.ShapesInRegion): New method to return the ids of shapes in
9283     a given region using the quad tree.
9284    
9285     * extensions/thuban/wxproj.cpp (project_points): Fix some typos in
9286     comment
9287     (draw_polygon_shape): Accept both arcs and polygons.
9288     (initwxproj): Use the new PYSHAPELIB_IMPORT_API macro to import
9289     the api.
9290    
9291     * Thuban/UI/renderer.py (MapRenderer.layer_ids): New method to
9292     return the shape ids to be rendered in a given layer.
9293     (MapRenderer.draw_shape_layer): Call layer_ids to get the list of
9294     ids. Use draw_polygon_shape to draw arc shapes as well.
9295     (ScreenRenderer.RenderMap): New parameter for the rectangle that
9296     has to be updated
9297     (ScreenRenderer.layer_ids): Make use of the layer's quadtree by
9298     calling it's ShapesInRegion method.
9299    
9300     * Thuban/UI/view.py (MapCanvas.__init__): New instance variable
9301     update_region for the update region.
9302     (MapCanvas.OnPaint): Maintain the update region
9303     (MapCanvas.do_redraw): Pass the bounding box of the update_region
9304     to the renderer when drawing the bitmap. Reset the update_region.
9305    
9306 bh 129 2002-05-03 Bernhard Herzog <[email protected]>
9307    
9308 bh 131 * Thuban/UI/mainwindow.py (MainWindow.SaveSessionAs,
9309     MainWindow.OpenSession): Change the file extension of the session
9310     files to .thuban
9311    
9312 bh 129 * Thuban/Model/session.py (Session.AddMap, forwarded_channels):
9313     Move the map channels to be forwarded by the session into the
9314 bh 146 class constant with forwarded_channels. Also add
9315     LAYER_PROJECTION_CHANGED and LAYER_VISIBILITY_CHANGED to
9316     forwarded_channels
9317 bh 129
9318     * Thuban/Model/base.py (Modifiable.changed): Fix doc-string (a
9319     typo and some rewording).
9320    
9321 bh 126 2002-05-02 Bernhard Herzog <[email protected]>
9322    
9323     * Thuban/UI/view.py: Keep the temporary bitmap used during drawing
9324     around to speed up most redraws:
9325     (MapCanvas.__init__): New instance variable bitmap which holds the
9326     bitmap
9327     (MapCanvas.do_redraw): Redraw self.bitmap if necessary. Use
9328     self.bitmap to draw.
9329     (MapCanvas.full_redraw): New method to force a full redraw
9330     including the bitmap
9331     (MapCanvas.SetMap): Subscribe full_redraw instead of redraw to
9332     make sure the bitmap is redrawn.
9333     (MapCanvas.projection_changed, MapCanvas.set_view_transform,
9334     MapCanvas.shape_selected): Call full_redraw instead of readraw to
9335     make sure the bitmap is redrawn.
9336     (MapCanvas.OnSize): New method to handle size events so that the
9337     bitmap can be redrawn.
9338    
9339 bh 124 2002-04-29 Bernhard Herzog <[email protected]>
9340    
9341     * Thuban/UI/mainwindow.py (MainWindow.__init__): Subscribe to the
9342     canvas' VIEW_POSITION event
9343     (MainWindow.view_position_changed): Handler for VIEW_POSITION.
9344     Update the text in the status-bar accordingly.
9345    
9346     * Thuban/UI/view.py (MapCanvas): Derive from Publisher as well
9347     (MapCanvas.__del__): Implement because Publisher.__del__ has to be
9348     called.
9349     (MapCanvas.__init__): Bind EVT_LEAVE_WINDOW too. Initialize
9350     current_position
9351     (MapCanvas.set_current_position): New method to set
9352     current_position. Issue a VIEW_POSITION event
9353     (MapCanvas.CurrentPosition): New public method to return the value
9354     of current_position. Should be called when the VIEW_POSITION event
9355     is processed.
9356     (MapCanvas.OnLeftDown, MapCanvas.OnLeftUp, MapCanvas.OnMotion):
9357     Update the position.
9358     (MapCanvas.OnLeaveWindow): Set the position to None.
9359    
9360     * Thuban/UI/messages.py (VIEW_POSITION): New message for the
9361     position in the statusbar
9362    
9363 tkoester 403 2002-04-26 Frank Koormann <[email protected]>
9364 frank 120
9365     * Thuban/UI/mainwindow.py: AddLayer, Dialog title s/session/data
9366    
9367 tkoester 403 2002-04-24 Frank Koormann <[email protected]>
9368    
9369 frank 118 * Resources/Bitmaps/identify.xpm: shadow added
9370    
9371     * Resources/Bitmaps/fullextent.xpm: new
9372 jan 116
9373 tkoester 403 2002-04-22 Jan-Oliver Wagner <[email protected]>
9374 jan 116
9375 tkoester 403 * Thuban/UI/tree.py (update_tree): added test for None on map bounding
9376     box
9377 jan 114
9378 tkoester 403 2002-04-21 Jan-Oliver Wagner <[email protected]>
9379    
9380 jan 114 * Thuban/UI/proj4dialog.py (UTMProposeZoneDialog): new
9381    
9382     * Thuban/UI/tree.py (update_tree): added added map extent
9383    
9384     * Thuban/UI/mainwindow.py (_method_command): extended by parameter
9385 tkoester 403 icon; added map_full_extend as tool
9386 jan 114
9387 tkoester 403 2002-04-19 Jan-Oliver Wagner <[email protected]>
9388 jan 107
9389     * Thuban/UI/mainwindow.py (SaveSession): launch save as dialog for
9390     saving _new_ sessions
9391    
9392     * Thuban/Model/session.py (create_empty_session): new session
9393     don't have a filename (set to None)
9394    
9395     * Thuban/UI/tree.py (update_tree): added filename and modified flag
9396    
9397     * Thuban/Model/load.py (ProcessSession): convert projection
9398     parameters from unicode to regular string
9399    
9400     * Data/iceland_sample.session: Added UTM Zone 26 projection.
9401    
9402 bh 100 2002-04-11 Bernhard Herzog <[email protected]>
9403    
9404     * extensions/shapelib/shapefil.h, extensions/shapelib/shpopen.c,
9405     extensions/shapelib/dbfopen.c: Update to the versions of shapelib
9406     1.2.9
9407    
9408     * setup.py (Lib.wxproj extension): Don't link shpopen.c and put
9409     the pyshapelib directoy into the list of include dirs, so that
9410     pyshapelib_api.h can be found.
9411    
9412     * extensions/thuban/wxproj.cpp (pyshapelib_api): New variable that
9413     holds the pyshapelib C-API
9414     (draw_polygon_shape, point_in_polygon_shape, shape_centroid): Use
9415     pyshapelib_api to access the shapelib functions.
9416     (initwxproj): Import the c_api from the shapelib module and
9417     initialize pyshapelib_api.
9418    
9419 bh 89 2002-04-04 Bernhard Herzog <[email protected]>
9420    
9421 bh 91 * setup.py (thuban_bdist_rpm.initialize_options): Use
9422     initialize_options to create the scripts for the rpm.
9423    
9424 bh 89 * extensions/pyprojection/setup.py (PROJ4_PREFIX): Just use /
9425    
9426 bh 85 2002-04-03 Bernhard Herzog <[email protected]>
9427    
9428 bh 87 * setup.py: Increment version to 0.1.1
9429    
9430 bh 85 * Thuban/UI/mainwindow.py (MainWindow.__init__): Move the "Add
9431     Layer" and "Remove Layer" commands from the layer menu to the map
9432     menu
9433    
9434 bh 83 2002-02-15 Bernhard Herzog <[email protected]>
9435    
9436     * Thuban/Model/layer.py (Layer.Shape): list append only takes one
9437     argument (python <= 1.5.2 erroneously accepted multiuple
9438     arguments)
9439    
9440 bh 81 2002-02-04 Bernhard Herzog <[email protected]>
9441    
9442     * Thuban/UI/identifyview.py (IdentifyGridCtrl): New class to use a
9443     RecordGrid in the identifyview.
9444     (IdentifyView.__init__): Use IdentifyGridCtrl instead of
9445     IdentifyListCtrl. The grid allows editing of the values.
9446    
9447     * Thuban/UI/controls.py (RecordTable, RecordGridCtrl): New classes
9448     implementing a grid for a single row of a thuban table.
9449    
9450     * Thuban/UI/view.py (MapCanvas.SelectShapeAt): Search through all
9451     layers by default. Easier to use than the previous default of only
9452     searching through the select layer which meant that if no layer
9453     was selected, you couldn't select a shape.
9454    
9455     * Thuban/UI/tableview.py (TableGrid.__init__): Fix typo
9456    
9457     * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Honour the
9458     stroke_width attribute
9459    
9460     * Thuban/Model/save.py (save_session): Write the new stroke_width
9461     attribute
9462    
9463     * Thuban/Model/load.py (ProcessSession.startElement): Read the
9464     stroke_width attribute
9465    
9466     * Thuban/Model/layer.py (Layer.__init__): New parameter and
9467     instance variable stroke_width
9468     (Layer.SetStrokeWidth): Set the stroke_width.
9469    
9470 bh 72 2002-02-01 Bernhard Herzog <[email protected]>
9471    
9472     * extensions/thuban/wxproj.cpp (project_points): Fix two
9473     off-by-one errors in the last loop that joins the various parts
9474     together.
9475    
9476 bh 71 2002-01-14 Bernhard Herzog <[email protected]>
9477    
9478     * setup.py (data_dist.make_distribution): Fix some typos
9479    
9480 bh 70 2001-09-18 Bernhard Herzog <[email protected]>
9481    
9482     * README: Slight tweaking in preparation for the 0.1 release
9483    
9484     * setup.cfg: Add section for sdist to create both tgz and zip
9485     archives
9486    
9487     * setup.py: increase version number to 0.1
9488     (data_dist): New command class for data distribution
9489    
9490 bh 64 2001-09-14 Bernhard Herzog <[email protected]>
9491    
9492 bh 70 * Thuban/UI/identifyview.py (IdentifyListCtrl.selected_shape):
9493     Handle the case of no layer (i.e. layer is None) properly.
9494    
9495 tkoester 403 * Thuban/UI/proj4dialog.py (UTMDialog.__init__, Proj4Dialog.__init__):
9496 bh 70 Set the initial selection of the combo boxes to reflect the
9497     projection we're starting with in a way that works on windows,
9498     too.
9499    
9500 bh 64 * Thuban/Lib/connector.py (Connector.print_connections): Print the
9501     puiblisher's ids in hex to make it easier to compare them to the
9502     standard repr of python methods
9503    
9504     * Thuban/Model/map.py (Map.Destroy): Unsubscribe the label_layer
9505     messages
9506    
9507 bh 59 2001-09-13 Bernhard Herzog <[email protected]>
9508    
9509 bh 64 * Thuban/UI/tree.py (SessionTreeCtrl.OnSelChanged): Make sure to
9510     deselect the layer if no layer is selected
9511    
9512 bh 59 * Thuban/UI/view.py (MapCanvas.OnPaint): Only delay drawing to
9513     idle time when there actually is something to draw. If there's
9514     nothing to draw simply clear the window
9515     (MapCanvas.do_redraw): Call dc.EndDrawing and add some comments.
9516     (MapCanvas.SetMap): force a redraw in all cases because
9517     FitMapToWindow doesn't always do it.
9518     (MapCanvas.ZoomFactor): Add an optional parameter, center, to
9519     specify the point to move into the center of the window
9520     (ZoomOutTool.MouseUp, ZoomInTool.MouseUp): If the mouse wasn't
9521     dragged, zoon in/out by a factor of 2
9522 bh 64 (MapCanvas.find_shape_at): Iterate backwards (i.e. with decreasing
9523     index, i.e. reversed drawing order) so that objects appearing to
9524     be in from of others are selected first. This is probably mostly
9525     relevant for point shapes where the symbols used may overlap
9526 bh 59
9527     * Thuban/Model/session.py (create_empty_session): Unset the
9528     modified bit before returning it
9529    
9530     * Thuban/UI/mainwindow.py (MainWindow.NewSession): Use
9531     create_empty_session session to create the new, empty session.
9532    
9533     * Thuban/UI/mainwindow.py (MainWindow.__init__): Set the size of
9534     the tool bitmaps.
9535     (MainWindow.OnClose, MainWindow.save_modified_session): Separate
9536     the code that asks whether the session should be saved into the
9537     new method save_modified_session.
9538     (MainWindow.OpenSession, MainWindow.NewSession): Use the new
9539     method to save modified session here too.
9540    
9541 bh 55 2001-09-11 Bernhard Herzog <[email protected]>
9542    
9543     * setup.py (InnoIconItem): fix typo
9544    
9545     (thuban_bdist_inno.run):
9546     (bdist_inno.run): Move the decision not to create symlinks on
9547     non-nt platforms to thuban_bdist_inno and do it unconditinally
9548     since we never want to create the symlinks here
9549    
9550 bh 48 2001-09-10 Bernhard Herzog <[email protected]>
9551    
9552 bh 53 * Thuban/UI/mainwindow.py (MainWindow.IdentifyTool): Popup the
9553     identify view immediately
9554    
9555     * Thuban/UI/controls.py: New file with two classes RecordListCtrl
9556     and SelectableRecordListCtrl that implement the code shared by the
9557     identify view and the label dialog
9558    
9559     * Thuban/UI/identifyview.py (IdentifyListCtrl): Derive from the
9560     new class RecordListCtrl
9561    
9562     * Thuban/UI/labeldialog.py (LabelDialog.OnOK): Check whether the
9563     return value of GetValue is None instead of using it as a boolean
9564     directly so that Zero numbers are handled properly.
9565     (LabelListCtrl): Derive from the new class
9566     SelectableRecordListCtrl
9567    
9568 bh 48 * Thuban/UI/proj4dialog.py (Proj4Dialog.__init__):
9569     (Proj4Dialog.dialogLayout): Make the window resizable and set the
9570     size of the text control explicitly to make the sizers work on
9571     both Windows and X.
9572    
9573 bh 44 2001-09-07 Bernhard Herzog <[email protected]>
9574    
9575     * Thuban/UI/view.py (MapCanvas.find_shape_at):Add a new parameter
9576     that can limit the search to the currently selected layer.
9577     (MapCanvas.SelectShapeAt): Make sure that the currently selected
9578     layer stays selected even when no shape is found
9579 bh 46 (MapCanvas.FitRectToWindow): If the rect has zero with or zero
9580     height do nothing (avoids zero division errors)
9581 bh 44
9582 bh 32 2001-09-06 Bernhard Herzog <[email protected]>
9583    
9584 bh 42 * Thuban/UI/tree.py (SessionTreeCtrl, SessionTreeView.__init__):
9585     Correct the spelling of SessionTreeCtrl. dabbrev is too damn
9586     convenient :-)
9587     (SessionTreeCtrl.__init__, SessionTreeCtrl.update_tree): Introduce
9588     a new instvar layer_to_item to map layers to tree items
9589     (SessionTreeCtrl.layer_selected): Select the appropriate tree item
9590     to match the current selection in the interactor
9591    
9592 bh 40 * Thuban/UI/interactor.py (Interactor.SelectedLayer):
9593     (Interactor.HasSelectedLayer): New methods to query the current
9594     selection
9595    
9596     * Thuban/UI/mainwindow.py (MainWindow.current_layer):
9597     (MainWindow.has_selected_layer): Simply call the appropriate
9598     interactor method
9599    
9600     * Thuban/UI/mainwindow.py (MainWindow.__init__):
9601     (MainWindow.LayerShowTable):
9602     (MainWindow.identify_view_on_demand): Store the interactor in an
9603     instvar and use that reference instead of going through main.app
9604    
9605 tkoester 403 * Thuban/UI/mainwindow.py (MainWindow.ShowSessionTree):
9606     * Thuban/UI/application.py (ThubanApplication.OnInit):
9607 bh 40 * Thuban/UI/main.py (main): Create the session tree view in main
9608     with the new mainwindow method ShowSessionTree and not directly
9609     the application's OnInit method
9610    
9611     * Thuban/UI/tree.py (myTreeCtrlPanel):
9612     (SessioinTreeCtrl): Rename to SessioinTreeCtrl and turn it into a
9613     TreeCtrl isntead of a panel. This affects most method since we now
9614     refer to self instead of self.tree
9615     (SessionTreeView): New class implementing a non-modal dialog
9616     showing the session tree.
9617    
9618 bh 35 * Thuban/UI/mainwindow.py (MainWindow.LayerShowTable): Pass the
9619     layer to the tableview dialog.
9620    
9621     * Thuban/UI/tableview.py: Add some doc-strings
9622 tkoester 403 (TableGrid):
9623 bh 35 (TableGrid.OnRangeSelect):
9624     (TableGrid.OnSelectCell):
9625     (TableFrame.__init__):
9626     (TableFrame.row_selected):
9627     Selecting rows in the grid view now updates the selected shapes
9628     through the TableFrame. To achieve this we derive TableGrid from
9629     Publisher and introduce the message type ROW_SELECTED which the
9630     TableFrame subscribes to and which is issued by OnRangeSelect and
9631     OnSelectCell
9632    
9633     (DataTable.SelectRow): Removed because it's no longer needed in
9634     the row/shape selection scheme
9635    
9636 bh 32 * Thuban/UI/dialogs.py: New file implementing common classes for
9637     dialogs
9638    
9639     * Thuban/UI/tableview.py (TableGrid.__init__): Don't subscribe to
9640     the SELECTED_SHAPE message anymore. This is now handled by the
9641     parent.
9642     (TableGrid.select_shape): Only update the selection if the shape
9643     is not None.
9644     (TableFrame): Inherit from the new NonModalDialog class.
9645     (TableFrame.__init__, TableFrame.select_shape): Handle the
9646     SELECT_SHAPE message.
9647     (TableFrame.OnClose): Extend the inherited method to unsubscribe
9648     SELECT_SHAPE
9649    
9650     * Thuban/UI/mainwindow.py (MainWindow.init_dialogs):
9651     (MainWindow.add_dialog):
9652     (MainWindow.dialog_open):
9653     (MainWindow.remove_dialog):
9654     (MainWindow.get_open_dialog): New methods to maintain a dictionary
9655     of opened non-modal dialogs.
9656    
9657     (MainWindow.__init__): Initialize the new non-modal dictionary
9658     management code
9659     (MainWindow.LayerShowTable): maintain separate dialogs for each
9660     table using the non-modal dialog management code to only open a
9661     view once for each table.
9662    
9663     (MainWindow.IdentifyTool):
9664     (MainWindow.__init__):
9665     (MainWindow.identify_view_on_demand): Don't open the identify view
9666     in IdentifyTool anymore. This will be done automatically by the
9667     new method identify_view_on_demand which handles the
9668     SELECTED_SHAPE message so that the identify view will be opened on
9669     demand
9670    
9671     * Thuban/UI/identifyview.py (IdentifyListCtrl.__init__): Remove
9672     the interactor argument. The SELECTED_SHAPE message is now handled
9673     by the parent.
9674     (IdentifyView.__init__): Add the interactor argument so that we
9675     can handle the SELECTED_SHAPE message here
9676     (IdentifyView.selected_shape): New method to handle the
9677     SELECTED_SHAPE messages
9678    
9679     * Thuban/UI/identifyview.py (IdentifyView): Derive from the new
9680     NonModalDialog class
9681     (IdentifyView.OnClose): Extend the inherited version to
9682     unsubscribe SELECT_SHAPE
9683    
9684     * Thuban/Model/session.py (Session.UnsetModified): Remove debug prints
9685    
9686 bh 26 2001-09-05 Bernhard Herzog <[email protected]>
9687    
9688     * Thuban/UI/view.py (MapCanvas.__init__): New argument, interactor.
9689 tkoester 403
9690 bh 26 * Thuban/UI/mainwindow.py (MainWindow.__init__): New argument
9691     interactor to pass through to the MapCanvas
9692 tkoester 403
9693 bh 26 * Thuban/UI/application.py (ThubanApplication.OnInit): Use the new
9694     argument to the MainWindow constructor to get rid of the ugly hack
9695     that made main.app available early just so that the mapcanvas
9696     could access the interactor object.
9697    
9698 bh 19 2001-09-04 Bernhard Herzog <[email protected]>
9699    
9700 bh 22 * Thuban/UI/mainwindow.py (MainWindow.RunMessageBox): New method
9701     that runs a modal message box
9702     (MainWindow.OnClose): Use the new method
9703     (MainWindow.RemoveLayer): Just do nothing in case no layer is
9704     selected. The command should be grayed out anyway, so there's no
9705     need to pop up a message box.
9706     (MainWindow.AddLayer): Pop up a message box with an error message
9707     if the shape file can't be opened
9708    
9709     * Thuban/Model/layer.py (Layer.__init__): Open the shapefile
9710     immediately. This will cause an exception in case the file can't
9711     be opened and we can display an appropriate message.
9712    
9713 bh 19 * MANIFEST.in: Add extensions/pyprojection/LICENSE
9714    
9715     * setup.py (thuban_bdist_rpm): New class implementing a Thuban
9716     specific bdist_rpm command.
9717    
9718     * Thuban/UI/main.py: Catch ImportError exceptions when importing
9719     the locale module because it may not be available on some
9720     installations.
9721    
9722     * extensions/pyprojection/LICENSE: Copy of the license text in
9723     Projection.i. Having it in a separate file makes it easier to
9724     refer to license text in e.g. RPMs
9725    
9726 bh 18 2001-09-03 Bernhard Herzog <[email protected]>
9727    
9728 bh 19 * setup.py: use wx-config instead of wxgtk-config because it's
9729     more generic
9730    
9731     * setup.py (ThubanInstall.get_outputs): Add the symlink in
9732     <prefix>/bin to the outputs
9733     (ThubanInstall.link_file): New method to link files. We need this
9734     because the standard copy_files refuses to link non-existing
9735     files.
9736     (ThubanInstall.run): Remove the leading install root from the
9737     script filename if an install root was specified and use the new
9738     link_file method
9739 tkoester 403
9740 bh 18 * Thuban/UI/mainwindow.py (MainWindow.AddLayer): Fit the map to
9741     the window when the first layer is added to the map.
9742    
9743     * setup.py (ThubanInstall.run): Honor the build root (self.root)
9744     when linking thuban.py to <prefix>/bin
9745    
9746 bh 16 2001-08-31 Bernhard Herzog <[email protected]>
9747    
9748     * setup.py: In the setup call, the install parameters shouldn't
9749     have trailing slashes because distutils on non-posix platforms
9750     doesn't like that. The same applies to other directories like
9751     "Resources/Bitmaps"
9752    
9753     In the configuration section for nt, move the wxWindows directory
9754     optins into the part clearly marked as editable.
9755    
9756     (InstallLocal.initialize_options):
9757     (InstallLocal.user_options): remove the currently unused debug
9758     flag
9759     (thuban_build_py.find_all_modules): Add this method so that it
9760     works for our case of having packages and modules in one
9761     distribution as well.
9762     (ThubanInstall.initialize_options):
9763     (ThubanInstall.finalize_options):
9764     (ThubanInstall.user_options):
9765     (ThubanInstall.boolean_options): Add new options, do-symlink and
9766     extra files. Since these are the first ThubanInstall specific
9767     options, override user_options and boolean_options
9768     (ThubanInstall.run): Honor the new do-symlink and extra-files
9769     options.
9770     (ThubanInstall.get_outputs): Add to override the base-class's
9771     version and add the extra-files to the outputs
9772     (bdist_inno): New class for windows distributions with Inno Setup
9773     (InnoIconItem): Helper class for bdist_inno
9774     (thuban_bdist_inno): Thuban specific version of bdist_inno. Added
9775     this together with the appropriate parameters, to the setup call.
9776 tkoester 403
9777 bh 16 * setup.cfg (bdist_inno): added new section for the inno setup
9778     installer
9779    
9780     * Thuban/UI/tree.py (myTreeCtrlPanel.__init__): New inst var
9781     changing_selection to avoid recursive selection events when
9782     modifying the selection in response to a selection event.
9783     (myTreeCtrlPanel.normalize_selection): Set the new inst var when
9784     changing the tree's selection.
9785     (myTreeCtrlPanel.OnSelChanged): Only normalize the selection when
9786     we're not being called indirectly from normalize_selection.
9787    
9788     * Thuban/UI/mainwindow.py (MainWindow.update_command_ui): Call
9789     event.Check only if the command is actuall checkable.
9790     (MainWindow.__init__): Call the toolbar's Realize method to make
9791     sure that the items are actually shown
9792    
9793 bh 7 2001-08-28 Bernhard Herzog <[email protected]>
9794    
9795 bh 9 * setup.py: Fix some doc strings
9796    
9797 bh 7 * ChangeLog: started
9798    

Properties

Name Value
svn:eol-style native
svn:keywords Author Date Id Revision

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26