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

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

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

revision 256 by bh, Wed Aug 14 15:08:14 2002 UTC revision 1272 by jonathan, Fri Jun 20 16:43:13 2003 UTC
# Line 1  Line 1 
1    2003-06-20  Jonathan Coles   <[email protected]>
2    
3            * Thuban/UI/view.py (MapCanvas.OnPaint): Call wxYield after
4            turning on the busy cursor to allow the system to change the
5            cursor before we begin painting. This fixes a problem that
6            was occuring only under GTK. Fixes RTbug #1840.
7    
8    2003-06-20  Bernhard Herzog  <[email protected]>
9    
10            * Resources/XML/thuban-0.8.dtd: New DTD for the new file format
11            version.
12    
13            * Thuban/Model/save.py (sort_data_stores): New. Make topological
14            sort of the data sources so they can be written with sources that
15            data sources that depend on other data sources come after the
16            sources they depend on.
17            (SessionSaver.__init__): Add idmap instance variable to map from
18            objects to the ids used in the file.
19            (SessionSaver.get_id, SessionSaver.define_id)
20            (SessionSaver.has_id): New. Methods to manage the idmap
21            (SessionSaver.write): Use thuban-0.8.dtd
22            (SessionSaver.write_session): Add a namespace on the session and
23            write out the data sources before the maps.
24            (SessionSaver.write_data_containers): New. Write the data
25            containers.
26            (SessionSaver.write_layer): Layer elements now refer to a
27            shapestore and don't contain filenames anymore.
28    
29            * Thuban/Model/load.py (LoadError): Exception class to raise when
30            errors in the files are discovered
31            (SessionLoader.__init__): Define dispatchers for elements with a
32            thuban-0.8 namespace too.
33            (SessionLoader.check_attrs): New helper method to check and
34            convert attributes
35            (AttrDesc): New. Helper class for SessionLoader.check_attrs
36            (SessionLoader.start_fileshapesource)
37            (SessionLoader.start_derivedshapesource)
38            (SessionLoader.start_filetable, SessionLoader.start_jointable):
39            Handlers for the new elements in the new fileformat
40            (SessionLoader.start_layer): Handle the shapestore attribute in
41            addition to filename.
42            (SessionLoader.start_table, SessionLoader.end_table): Removed.
43            They were never used in the old formats and aren't needed for the
44            new.
45    
46            * Thuban/Model/session.py (Session.DataContainers): New method to
47            return all "data containers", i.e. shapestores and tables
48    
49            * test/xmlsupport.py (SaxEventLister.__init__)
50            (SaxEventLister.startElementNS, sax_eventlist): Add support to
51            normalize IDs.
52    
53            * test/test_xmlsupport.py
54            (TestEventList.test_even_list_id_normalization): New test case for
55            id normalization
56    
57            * test/test_load.py (LoadSessionTest.check_format): Use ID
58            normalization
59            (LoadSessionTest.thubanids, LoadSessionTest.thubanidrefs): New
60            class atrributes used for ID normalization
61            (TestSingleLayer, TestLayerVisibility, TestLabels.test)
62            (TestLayerProjection.test, TestRasterLayer.test): Adapt to new
63            file format
64            (TestJoinedTable): New test for loading sessions with joined
65            tables.
66            (TestLoadError): New. Test whether missing required attributes
67            cause a LoadError.
68    
69            * test/test_save.py (SaveSessionTest.thubanids)
70            (SaveSessionTest.thubanidrefs): New class attributes for ID
71            normalization in .thuban files.
72            (SaveSessionTest.compare_xml): Use id-normalization.
73            (SaveSessionTest.testEmptySession)
74            (SaveSessionTest.testLayerProjection)
75            (SaveSessionTest.testRasterLayer)
76            (SaveSessionTest.testClassifiedLayer): Adapt to new file format.
77            (SaveSessionTest.testLayerProjection): The filename used was the
78            same as for testSingleLayer. Use a different one.
79            (SaveSessionTest.test_dbf_table)
80            (SaveSessionTest.test_joined_table): New test cases for saving the
81            new data sources structures.
82            (TestStoreSort, MockDataStore): Classes to test the sorting of the
83            data stores for writing.
84    
85            * test/runtests.py: Add CVS keywords
86    
87    2003-06-20  Jonathan Coles   <[email protected]>
88    
89            * test/test_session.py
90            (UnreferencedTablesTests.test_unreferenced_tables_with_joins):
91            Use the cultural_landmark-point.dbf file for the store so that
92            the table rows and shape count match.
93    
94    2003-06-20  Jonathan Coles   <[email protected]>
95    
96            * Thuban/Model/data.py (DerivedShapeStore.__init__): Raise
97            an exception if the number of shapes is different from the
98            number of rows in the table. Address RTbug #1933.
99    
100            * test/test_layer.py (TestLayer.test_derived_store): Add
101            a test for the new exception in DerivedShapeStore.__init__.
102    
103            * test/support.py (FloatTestCase): Removed since there is
104            already FloatComparisonMixin. Fixes RTbug #1954.
105            (FloatComparisonMixin.assertFloatEqual): Include test for
106            infinity that was part of FloatTestCase.
107    
108            * test/test_range.py (RangeTest): Inherit from
109            support.FloatComparisonMixin now that we don't have
110            support.FloatTestCase.
111    
112    2003-06-20  Bernhard Herzog  <[email protected]>
113    
114            * test/test_save.py (SaxEventLister, sax_eventlist): Removed. Use
115            the implementation in xmlsupport instead.
116            (SaveSessionTest.compare_xml): sax_eventlist is now in xmlsupport
117    
118            * test/test_proj.py: Import sax_eventlist from xmlsupport instead
119            of test_save
120    
121    2003-06-20  Bernhard Herzog  <[email protected]>
122    
123            * test/test_load.py (LoadSessionTest.check_format): New helper
124            method to make sure the test files we load might have been written
125            by the current thuban version.
126            (ClassificationTest.TestLayers, TestSingleLayer.test)
127            (TestLayerVisibility.test, TestClassification.test)
128            (TestLabels.test, TestLayerProjection.test, TestRasterLayer.test):
129            Add check_format() calls and fix the thuban data to match the data
130            that would be written by saving the session loaded from it.
131    
132            * test/xmlsupport.py (SaxEventLister, sax_eventlist): Copies of
133            the same class and function in test_save.
134    
135            * test/test_xmlsupport.py (TestEventList): New. test cases for
136            sax_eventlist
137    
138    2003-06-20  Bernhard Herzog  <[email protected]>
139    
140            * Resources/XML/thuban.dtd: Add comment about which versions of
141            Thuban are covered by this DTD
142            (map): Fix content model for layers and raster layers. There can
143            be any number or layers and raster layers in any order.
144    
145    2003-06-20  Jonathan Coles   <[email protected]>
146    
147            This is mainly about fixing RTbug #1949.
148    
149            * Thuban/Model/classification.py: Remove "from __future__"
150            import statement since python 2.2 is the earliest supported
151            version.
152    
153            * Thuban/Model/proj.py (Projection.GetProjectedUnits): New.
154            Currently returns PROJ_UNITS_METERS or PROJ_UNITS_DEGREES
155            depending on the units this projection *forwards* into.
156    
157            * Thuban/Model/save.py (SessionSaver.write_classification):
158            Remove unnecessary use of lambdas and nested functions.
159    
160            * Thuban/UI/legend.py (ScaleBarBitmap.__SetScale): Do scale
161            adjustment here if the map projection uses degrees.
162    
163            * Thuban/UI/scalebar.py (ScaleBar.DrawScaleBar): Remove
164            scale adjust code since it is now done before calling
165            this method. Don't do anything if the map projection
166            is None.
167    
168    2003-06-19  Bernhard Herzog  <[email protected]>
169    
170            Move version specific load tests to their own file.
171    
172            * test/test_load.py: Expand the doc-string to explain a bit how to
173            handle file format changes.
174            (TestClassification.test): Update the docstring as this test is
175            not about Thuban 0.2 anymore.
176    
177            * test/test_load_0_2.py: New file with the load tests for thuban
178            files created with Thuban 0.2 and earlier.
179    
180    2003-06-19  Bernhard Herzog  <[email protected]>
181    
182            Add XML validation to some of the tests. Validation will only be
183            done if pyRXP is installed (http://reportlab.com/xml/pyrxp.html).
184            To make the DTD available to the test cases it's moved into
185            Resources/XML
186    
187            * Resources/XML/thuban.dtd: New. This is now the real Thuban DTD
188            for versions up to and including 0.2. Two slight changes: added an
189            encoding specification and fixed the comment which refered to
190            GRASS, not Thuban
191    
192            * test/xmlsupport.py: New support module for tests involving XML.
193            Currently there's a mix-in class for XML validation.
194    
195            * test/test_xmlsupport.py: New. Tests for the xmlsupport module
196    
197            * test/test_save.py (SaveSessionTest): Derive from ValidationTest
198            so that we can validate the
199            (SaveSessionTest.testEmptySession)
200            (SaveSessionTest.testSingleLayer)
201            (SaveSessionTest.testSingleLayer)
202            (SaveSessionTest.testLayerProjection)
203            (SaveSessionTest.testRasterLayer)
204            (SaveSessionTest.testClassifiedLayer): Validate the generated XML
205    
206            * test/runtests.py (main): Call print_additional_summary instead
207            of print_garbage_information
208    
209            * test/support.py (resource_dir): New function to return the
210            "Resource" subdirectory
211            (print_additional_summary): New function to combine several
212            summary functions
213            (run_tests): Use print_additional_summary instead of calling
214            print_garbage_information directly
215    
216    2003-06-19  Bernhard Herzog  <[email protected]>
217    
218            * Doc/thuban.dtd (classification): Correct the content model of
219            the classification element.
220            (projection): Add the "name" attribute
221    
222    2003-06-19  Frank Koormann   <[email protected]>
223    
224            MERGE from the greater-ms3 branch.
225    
226            * Thuban/UI/scalebar.py (ScaleBar.DrawScaleBar): Apply conversion to
227            scale if projection is latlong to get better estimate.
228    
229            Fix problem of hidden properties dialog under windows after double
230            click on layer tree:
231            The tree control always gets an Expanded / Collapsed event after
232            the ItemActivated  on double click, which raises the main window again.         We add a second ItemActivated event to the queue, which simply
233            raises the already displayed window.
234    
235            * Thuban/UI/legend.py (LegendTree.__init__): Instance variable
236            raiseProperties initialized to prevent endless loops
237            (LegendTree._OnItemActivated): Depending on self.raiseProperties
238            simply raise the properties or open the dialog and issue a second
239            event.
240    
241    2003-06-18  Jonathan Coles   <[email protected]>
242    
243            * setup.py: Fix a few problems that occured under Windows.
244    
245    2003-06-18  Jonathan Coles   <[email protected]>
246    
247            When Thuban loaded the map was redrawn twice because the
248            legend was being opened after the mainwindow was created
249            and not during its creation. This meant the map was drawn
250            initially and then had to be redrawn when the legend
251            caused the display to change. Now the legend is opened
252            in the mainwindow constructor which resolves this issue.
253    
254            Also, although we were checking for the existence of
255            gdal and gdalwarp modules, the gdalwarp extension was
256            still being compiled (which may fail if the system doesn't
257            have gdal installed). the build_ext command to setup.py
258            now accepts the flags --with-gdal and --without-gdal.
259            If --without-gdal is specified setup.py will try to
260            use the gdal parameters specified by gdal-config. Under
261            windows, those parameters have to be set in setup.py
262            as with proj4 an wxWindows.
263    
264            * setup.py: Use a list instead of seperate variables for
265            extension parameters so we can create a generic function
266            that runs an appropriate *-config script.
267            (run_cs_script): Renamed from run_wx_script and modified
268            to accept a second argument which is a list of lists to
269            be filled in by the values returned from running the command.
270            (thuban_build_ext): New. Extends the build_ext command and
271            provides the options --with-gdal/--without-gdal which then
272            optionally includes the gdalwarp extension.
273    
274            * Thuban/Model/resource.py: First check if we can import
275            the gdalwarp Thuban extension before checking for gdal.
276            Also added some comments.
277            
278            * Thuban/UI/legend.py (ScaleBarBitmap.__SetScale): Check if
279            the map is None which may be the case if none has been loaded
280            yet.
281    
282            * Thuban/UI/main.py (main): Remove call to ShowLegend.
283    
284            * Thuban/UI/mainwindow.py (MainWindow.__init__): Call ShowLegend().
285    
286            * Thuban/UI/renderer.py: Check for gdal support before importing
287            gdalwarp.
288            (MapRenderer.render_map): Only try to optimize if we have gdal
289            support otherwise nothing will get drawn.
290    
291            * Thuban/UI/view.py (MapCanvas.FitMapToWindow): This may be called
292            during startup before a map has been created. Check if map is None
293            before using it and do nothing if it is.
294    
295    2003-06-17  Jonathan Coles   <[email protected]>
296    
297            Fix the problem with raster layers under Windows that caused
298            Thuban to crash. The view should respond to layer projection
299            changed events to update the display. Changes to a projection
300            should not cause the map to be set to full extent.
301            
302            * Thuban/UI/view.py (MapCanvas.__init__): New instance variable
303            current_map_proj to remember the current map projection so that
304            when the projection changes we know what the previous projection
305            was.
306            (MapCanvas.SetMap): Unsubscribe and subscribe to
307            LAYER_PROJECTION_CHANGED events.
308            (MapCanvas.projection_changed): Split into two methods that respond
309            to map and layer projection changes.
310            (MapCanvas.map_projection_changed): New. Takes the current view and
311            projects it using the new projection. This does not cause the
312            map to be redrawn at full extent.
313            (MapCanvas.layer_projection_changed): New. Cause a redraw which
314            will draw each layer in its new projection.
315            
316            * extensions/thuban/bmpdataset.cpp (BMPDataset::Open): Call
317            VSIFClose() not VSIFCloseL() to close the file. Fixes a crash
318            under Windows.
319            
320            * extensions/thuban/gdalwarp.cpp (MFILENAME): Padding should be
321            to twice sizeof(void*) because there are two digits for each
322            hex byte.
323    
324    2003-06-16  Bernhard Herzog  <[email protected]>
325    
326            Update to the layer interface: Direct access to the table,
327            shapetable, shapefile and filename attributes is now actively
328            deprecated by issuing deprecation warnings for all places where
329            this happens.
330    
331            * Thuban/Model/layer.py (Layer.__getattr__): New. Implement access
332            to the instance variables table, shapetable, shapefile and
333            filename via __getattr__ so that we can issue a deprecation
334            warning.
335            (Layer.SetShapeStore): Don't set the deprecated instance variables
336            any more
337            (Layer.SetShapeStore): Don't use deprecated layer instance
338            variables
339            (Layer.Destroy): No need to explicitly remove the instance
340            variables any more
341            (Layer.GetFieldType, Layer.Shape): Don't use deprecated layer
342            instance variables
343    
344            * Thuban/UI/classgen.py (ClassGenDialog.__init__)
345            (GenUniformPanel._OnRetrieve, GenUniquePanel._OnRetrieve)
346            (GenQuantilesPanel.GetList, GenQuantilesPanel.OnRetrieve): Don't
347            use deprecated layer instance variables
348    
349            * Thuban/UI/classifier.py (Classifier.__init__): Don't use
350            deprecated layer instance variables
351    
352            * Thuban/UI/identifyview.py (IdentifyListCtrl.selected_shape)
353            (IdentifyGridCtrl.selected_shape): Don't set the deprecated layer
354            instance variables
355    
356            * Thuban/UI/tableview.py (LayerTableGrid.select_shapes): Don't use
357            deprecated layer instance variables
358    
359            * Thuban/UI/mainwindow.py (MainWindow.LayerShowTable): Don't use
360            deprecated layer instance variables
361    
362            * Thuban/Model/save.py (SessionSaver.write_layer): Don't use
363            deprecated layer instance variables
364    
365            * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer)
366            (MapRenderer.polygon_render_param): Don't use deprecated layer instance
367            variables
368    
369            * test/runtests.py (main): Turn Thuban's deprecation warnings into
370            errors so that they're cought by the tests
371    
372            * test/test_load.py (TestSingleLayer.test): Don't use deprecated
373            layer instance variables
374    
375    2003-06-16  Jonathan Coles   <[email protected]>
376    
377            Fix a problem under Windows whereby if the user double-clicks on a
378            layer in the legend that tree item will expand or collapse as well
379            as open the layer properties dialog. The state of the tree item
380            should not be affected.
381    
382            * Thuban/UI/legend.py (LegendTree.__init__): Add instance variable
383            preventExpandCollapse and subscribe to expanding and collapsing
384            events.
385            (LegendTree.OnItemExpandCollapse): New. Responds to expanding and
386            collapsing events and will veto the event if it has been triggered
387            by the user double clicking on a layer.
388            (LegendTree._OnItemActivated): Set preventExpandCollapse to indicate
389            that an expanding/collapsing event should be vetoed.
390    
391    2003-06-13  Bernhard Herzog  <[email protected]>
392    
393            * Thuban/UI/classifier.py (Classifier.OnClose)
394            (Classifier.map_layers_removed)
395            (Classifier.layer_shapestore_replaced): Unsubscribe the messages
396            in OnClose and not in map_layers_removed or
397            layer_shapestore_replaced to make sure it always happens when the
398            dialog is closed
399    
400    2003-06-13  Jonathan Coles   <[email protected]>
401    
402            This puts back a fix for Windows where a panel is needed so that
403            the background of the table view appears correctly.
404    
405            * Thuban/UI/tableview.py (TableFrame.__init__): Add a panel
406            object that can be used by derived classes to place any
407            controls (including the grid) onto.
408            (QueryTableFrame.__init__): Use the panel as the parent window
409            for all the controls. Reparent the grid so that the panel is
410            the parent. Call UpdateStatusText() to correctly initialize
411            the status bar.
412    
413    2003-06-13  Jonathan Coles   <[email protected]>
414    
415            * Thuban/UI/dialogs.py (ThubanFrame): New: a class that inherits
416            from wxFrame (as opposed to wxDialog like the other classes)
417            but otherwise behaves like the other classes. This is needed
418            for the TableView which isn't really a dialog and needs to
419            have a status bar and control buttons.
420    
421            * Thuban/UI/tableview.py (TableGrid.__init__): Create an
422            instance variable to keep track of how many rows are selected.
423            Subscribe once to the the events we are interested in.
424            (ThubanGrid.OnRangeSelect): Only handle event if event handling
425            hasn't been turned off.
426            (ThubanGrid.OnSelectCell): Only handle event if event handling
427            hasn't been turned off.
428            (ThubanGrid.ToggleEventListeners): Rather than subscribe None
429            as an event listener (which changes the event handler stack)
430            simply set an instance variable to False. This is checked in
431            the event handlers.
432            (ThubanGrid.GetNumberSelected): Return the number of currently
433            selected rows.
434            (TableFrame): Inherit from ThubanFrame so we can have a
435            status bar and control buttons.
436            (QueryTableFrame.__init__): Create a status bar. Fixes RTbug #1942.
437            Explicitly set which items are selected in the operator choice and
438            action choice so there is always a valid selection. Fixes RTbug #1941.
439            Subscribe to grid cell selection events so we can update the
440            status bar.
441            (QueryTableFrame.UpdateStatusText): Update the status bar with
442            how many rows are in the grid, how many columns, and how many
443            rows are selected.
444            (QueryTableFrame.OnGridSelectRange, QueryTableFrame.OnGridSelectCell):
445            Call UpdateStatusText when cells are (de)selected.
446            (QueryTableFrame.OnQuery): Use the string value in the value
447            combo if either the selected item index is 0 or if the string
448            cannot be found in the predefined list (this happens if the
449            user changes the text). Fixes RTbug #1940.
450            Only turn off the grid event listeners if there a query comes
451            back with a none empty list of ids. in the case that the list
452            is empty this causes a grid.ClearSelection() call to actually
453            clear the grid selection which causes the selected items in
454            the map to be deselected. Fixes RTbug #1939.
455    
456            * test/test_save.py (XMLWriterTest.Encode): Check return values.
457            Fixes RTbug #1851.
458    
459    2003-06-13  Bernhard Herzog  <[email protected]>
460    
461            * Thuban/UI/identifyview.py (IdentifyView.__init__): Call
462            self.selected_shape with the current selection to make sure the
463            contents of the dialog are up to date when it's shown for the
464            first time.
465            The dialog used to work without this by luck. The recent fix to
466            the connector module 'broke' a 'feature' the identify view was
467            relying on, i.e that subscribing to a message in response to
468            receiving a message of that type would mean that the new
469            subscriber would also be called for the same message.
470            
471    2003-06-12  Jonathan Coles   <[email protected]>
472    
473            * extensions/thuban/gdalwarp.cpp: Removed debug printing as
474            the image is rendered. Fixes RTbug #1937.
475    
476    2003-06-12  Jonathan Coles   <[email protected]>
477    
478            * Thuban/Lib/fileutil.py: As is done under Windows, create the
479            user directory if it doesn't exist on a posix system.
480            Fixes RTbug #1815.
481    
482            * Thuban/Model/resource.py (get_user_proj_files): Moved the
483            called to get_application_dir here, so that the directory
484            will only be called if this method is invoked.
485    
486            * Thuban/UI/projdialog.py (ProjFrame.__DoOnProjAvail): Clear
487            the projfilepath if no projection is selected.
488    
489    2003-06-12  Jonathan Coles   <[email protected]>
490    
491            * Thuban/UI/legend.py (ScaleBarBitmap.__SetScale): Don't draw
492            the scalebar if the current map has no projection set.
493    
494            * Thuban/UI/projdialog.py (ProjFrame.__DoOnProjAvail): Set the
495            projfilepath label to just the basename of the projection file
496            rather than include the entire path.
497    
498            * Thuban/Model/resource.py: Fix missed proj functions that
499            needed to be renamed.
500    
501    2003-06-12  Jonathan Coles   <[email protected]>
502    
503            * Thuban/Model/classification.py: Removed assert statements that
504            tested if the variable was an instance of Color.
505    
506            * Thuban/Model/color.py (Color): Remove commented code that isn't
507            used.
508            (Transparent): Renamed from NoColor. Doesn't inherit from Color.
509            Fixes RTbug #1835.
510            (Transparent.__eq__, Transparent.__ne, Transparent.__repr): New.
511            Needed now that the class doesn't inherit from Color.
512    
513    2003-06-12  Jonathan Coles   <[email protected]>
514    
515            * test/test_save.py (XMLWriterTest.testEncode): Explicitly
516            check unicode strings.
517    
518            * test/test_layer.py: Check for existence of gdal.
519    
520    2003-06-12  Jonathan Coles   <[email protected]>
521        
522            * Thuban/Model/xmlreader.py: New. Contains the XMLReader class
523            that was in load.py
524    
525            * Thuban/Model/xmlwriter.py: New. Contains the XMLWriter class
526            that was in save.py
527    
528    2003-06-12  Jonathan Coles   <[email protected]>
529    
530            This is largely a collection of bug fixes. We also handle the
531            case where gdal is not on the system. The XMLReader and XMLWriter
532            classes were moved into there own files to resolve some circular
533            import references and because they shouldn't really be in the
534            file that is dediciated to reading/writing session files since
535            they are also used elsewhere.
536    
537            * Thuban/Model/classgen.py: Renamed functions to follow the
538            function_names_with_underscores style. Fixes RTbug #1903.
539            (calculate_quantiles): Raise ValueError if 'percents' is invalid.
540    
541            * Thuban/Model/layer.py: Import gdal only if it available.
542            (RasterLayer): Handle the case where the gdal library is unavailable.
543            Addresses RTbug #1877.
544    
545            * Thuban/Model/load.py (XMLReader): Moved into seperate file
546            xmlreader.py.
547    
548    2003-06-12  Jonathan Coles   <[email protected]>
549    
550            This is largely a collection of bug fixes. We also handle the
551            case where gdal is not on the system. The XMLReader and XMLWriter
552            classes were moved into there own files to resolve some circular
553            import references and because they shouldn't really be in the
554            file that is dediciated to reading/writing session files since
555            they are also used elsewhere.
556    
557            * Thuban/Model/classgen.py: Renamed functions to follow the
558            function_names_with_underscores style. Fixes RTbug #1903.
559            (calculate_quantiles): Raise ValueError if 'percents' is invalid.
560    
561            * Thuban/Model/layer.py: Import gdal only if it available.
562            (RasterLayer): Handle the case where the gdal library is unavailable.
563            Addresses RTbug #1877.
564    
565            * Thuban/Model/load.py (XMLReader): Moved into seperate file
566            xmlreader.py.
567    
568            * Thuban/Model/save.py (escape, XMLWriter): Moved into seperate
569            file xmlwriter.py.
570    
571            * Thuban/Model/resource.py: Renamed functions to following the
572            function_names_with_underscores style.
573            (has_gdal_support): New function that returns true if the gdal
574            library is available. Addresses RTbug #1877.
575    
576            * Thuban/UI/application.py (ThubanApplication.OpenSession):
577            Display a message box if the gdal library is not available, but
578            only if there are any layers that would use it. Addresses RTbug #1877.
579    
580            * Thuban/UI/classgen.py: Use renamed projection resource functions.
581            (GenUniformPanel.__CalcStepping): Fix a slight discrepency
582            when using integers versus floats.
583    
584            * Thuban/UI/mainwindow.py (_has_gdal_support): New. Used to
585            determine if the "Add Image Layer" menu option should be
586            greyed out or not. Addresses RTbug #1877.
587    
588            * Thuban/UI/projdialog.py: Use renamed projection resource functions.
589    
590            * Thuban/UI/renderer.py (MapRenderer.render_map): Only try to
591            optimize if a raster layer is visible. Fixes RTbug #1931.
592            Only draw the raster layer if the gdal library is available.
593            Addresses RTbug #1877.
594    
595            * test/test_classgen.py: Add tests for generate_singletons,
596            generate_uniform_distribution, generate_quantiles. Fixes RTbug #1903.
597            (test_calculate_quantiles): Fix some tests to catch the new
598            ValueError that is raised.
599    
600            * test/test_proj.py: Use renamed projection resource functions.
601    
602            * test/test_save.py (SaveSessionTest.testClassifiedLayer): New
603            test for saving classified layers. Fixes RTbug #1902.
604            (XMLWriterTest): New. Tests the XMLWriter class. Fixes RTbug #1851.
605    
606    2003-06-12  Jan-Oliver Wagner <[email protected]>
607    
608            Fix for http://intevation.de/rt/webrt?serial_num=1900.
609    
610            * Thuban/UI/multiplechoicedialog.py: New. A multiple choice dialog.
611    
612            * Thuban/UI/mainwindow.py: import wxMultipleChoiceDialog from
613            multiplechoicedialog.py rather than from the wxPython library.
614    
615    2003-06-11  Frank Koormann  <[email protected]>
616    
617            * Thuban/Lib/fileutil.py (get_application_dir): Minor stability
618            update.
619    
620    2003-06-11  Frank Koormann  <[email protected]>
621    
622            * Thuban/Lib/fileutil.py (get_application_dir): New function to
623            determine the absolute .thuban/thuban directory under
624            "posix" (os.expanduser) and "nt" (read AppData registry key).
625    
626            * Thuban/Model/resource.py: Use get_application_dir
627    
628            * Thuban/UI/application.py (ThubanApplication.read_startup_files):
629            Use get_application_dir.
630    
631    2003-06-10  Bernhard Herzog  <[email protected]>
632    
633            * Thuban/UI/tableview.py (LayerTableFrame.__init__): Subscribe to
634            the messages MAP_LAYERS_REMOVED messages
635            (LayerTableFrame.OnClose): Unsubscribe from it.
636            (LayerTableFrame.map_layers_removed): New. Receiver for
637            MAP_LAYERS_REMOVED. Close the dialog when the layer whose the
638            dialog is showing is removed.
639    
640    2003-06-10  Bernhard Herzog  <[email protected]>
641    
642            * Thuban/Lib/connector.py (Connector.Issue): Iterate over a copy
643            of the receivers list so that unsubscribing in a receiver doesn't
644            modify it while iterating over it.
645    
646            * test/test_connector.py
647            (ConnectorTest.test_disconnect_in_receiver): New. Test whether
648            unsubscribing in a receiver works correctly. See docstring for
649            details
650    
651    2003-06-10  Bernhard Herzog  <[email protected]>
652    
653            * Thuban/Model/messages.py (LAYER_SHAPESTORE_REPLACED): New
654            message.
655    
656            * Thuban/Model/layer.py (Layer.SetShapeStore): Send
657            LAYER_SHAPESTORE_REPLACED when the shapestore changes. A
658            LAYER_CHANGED will still be sent if the classification changes.
659    
660            * Thuban/UI/classifier.py (Classifier.__init__): Add the map as
661            parameter so we can subscribe to some of its messages
662            (Classifier.__init__): Subscribe to the map's MAP_LAYERS_REMOVED
663            and the layer's LAYER_SHAPESTORE_REPLACED
664            (Classifier.unsubscribe_messages): New. Unsubscribe from message
665            subscribed to in __init__
666            (Classifier.map_layers_removed)
667            (Classifier.layer_shapestore_replaced): receivers for the messages
668            subscribed to in __init__. Unsubscribe and close the dialog
669    
670            * Thuban/UI/mainwindow.py (MainWindow.OpenLayerProperties): Pass
671            the map to the Classifier dialog
672    
673            * test/test_layer.py (SetShapeStoreTests): Derive from
674            SubscriberMixin as well so we can test messages
675            (SetShapeStoreTests.setUp): Subscribe to some of the layer's
676            messages
677            (SetShapeStoreTests.tearDown): Clear the messages again
678            (SetShapeStoreTests.test_sanity): Expand the doc-string and check
679            for the modified flag too
680            (SetShapeStoreTests.test_set_shape_store_modified_flag): New test
681            to check whether SetShapeStore sets the modified flag
682            (SetShapeStoreTests.test_set_shape_store_different_field_name)
683            (SetShapeStoreTests.test_set_shape_store_same_field)
684            (SetShapeStoreTests.test_set_shape_store_same_field_different_type):
685            Add tests for the messages. This checks both the new
686            LAYER_SHAPESTORE_REPLACED and the older LAYER_CHANGED
687    
688    2003-06-06  Jan-Oliver Wagner <[email protected]>
689    
690            * Thuban/UI/mainwindow.py: Improved and partly added help texts for
691            the menu items.
692    
693    2003-06-05  Frank Koormann  <[email protected]>
694    
695            * Thuban/UI/identifyview.py (IdentifyView.__init__):
696            Layout reimplemented without panel. Make life easier to fit the list
697            in the dialog.
698    
699    2003-06-05  Frank Koormann  <[email protected]>
700    
701            * Thuban/UI/projdialog.py (ProjFrame.__init__): Fill the projchoice
702            once on initialisation (Former implementation resulted in multiple
703            entries for each projection).
704            (ProjFrame.__FillAvailList): selectProj as second optional parameter,
705            if set, select the projection found under the specified name. This
706            overwrites any other selection estimate.
707            Removed projchoice filling from this method.
708            (ProjFrame._OnSave, ProjFrame._OnAddToList):
709            Updated call of ProjFrame.__FillAvailList
710            (LCCPanel._DoLayout): Moved parameter controls in more common order.
711    
712            * Resources/Projections/defaults.proj: Extended defaults representing
713            various common European projections.
714    
715    2003-06-05  Frank Koormann  <[email protected]>
716    
717            * Thuban/UI/identifyview.py (IdentifyView.__init__):
718            Use ListCtrl instead of GridCtrl
719    
720            * Thuban/Model/resource.py:
721            Guess location of .thuban directory from tempdir parent directory.
722    
723            * Thuban/UI/application.py (ThubanApplication.read_startup_files):
724            Guess location of .thuban directory from tempdir parent directory.
725    
726    2003-06-04  Bernhard Herzog  <[email protected]>
727    
728            Do not cache the values returned by the tree widget's
729            GetFirstChild and GetNextChild methods because it led to lots of
730            segfaults. The new way requires more brute force but is more
731            reliable.
732    
733            * Thuban/UI/legend.py (LegendTree.__init__): Remove instance
734            variable layer2id
735            (LegendTree.find_layer): New method to do with brute force what
736            layer2id tried to accomplish
737            (LegendTree._OnMsgLayerChanged)
738            (LegendTree._OnMsgLayerTitleChanged, LegendTree.__ShowHideLayer):
739            Use find_layer instead of layer2id
740            (LegendTree.__RemoveLayer, LegendTree.__AddLayer): No need to
741            update layer2id anymore
742            (LegendTree._OnMsgMapLayersRemoved)
743            (LegendTree._OnMsgMapLayersAdded): Get by without layer2id.
744    
745    2003-06-03  Thomas Koester  <[email protected]>
746    
747            * Thuban/Model/classgen.py (GenQuantiles0): New function.
748    
749    2003-06-02  Bernhard Herzog  <[email protected]>
750    
751            * Thuban/UI/mainwindow.py (layer_rename command, table_rename command):
752            New commands.
753            (main_menu): Add the new commands.
754            (MainWindow.TableRename): New. Implementation of the table_rename
755            command.
756            (MainWindow.RenameLayer): New. Implementation of the layer_rename
757            command.
758    
759            * Thuban/Model/session.py (Session.AddTable): call self.changed to
760            set the modified flag
761    
762            * test/test_session.py (TestSessionSimple.test_add_table): Test
763            whether the modified flag is set properly
764    
765            * Thuban/Model/base.py (TitledObject.SetTitle): Call changed
766            instead of issue so that the modified flags get updated.
767    
768            * test/test_base.py (SomeTitledObject): Derive from Modifiable
769            instead of Publisher to reflect reality better and to accomodate
770            the fact that SetTitle now calls changed instead of issue
771    
772    2003-06-02  Bernhard Herzog  <[email protected]>
773    
774            * Thuban/UI/classgen.py (GenQuantilesPanel.GetList): Resource
775            acquisition has to happen before the try in a try-finally.
776    
777    2003-06-02  Bernhard Herzog  <[email protected]>
778    
779            * Thuban/UI/legend.py (LegendTree._OnMsgMapLayersRemoved): It's
780            possible that a layer is removed that is not currently selected in
781            the legend so don't check for this.
782    
783    2003-05-30  Bernhard Herzog  <[email protected]>
784    
785            * Thuban/Model/layer.py (Layer.Destroy): Set all instance
786            variables to None that have direct or indirect references to
787            shapefiles or dbf files to make sure that they do go away and the
788            files are closed.
789    
790    2003-05-30  Bernhard Herzog  <[email protected]>
791    
792            * Thuban/UI/legend.py (LegendTree.GetRootItem): Reset
793            availImgListIndices when a new image list is created
794            
795    2003-05-30  Bernhard Herzog  <[email protected]>
796    
797            * Thuban/UI/legend.py (LegendTree.__init__): New instance variable
798            changing_selection to indicate whether the LegendTree code itself
799            is currently changing the selection
800            (LegendTree.normalize_selection): New method to normalize the
801            selection by selecting the layer item even if the user clicked on
802            the classification.
803            (LegendTree._OnSelChanged): normalize the selection. This works
804            around a bug in wx which doesn't keep track of the selection
805            properly when subtrees are deleted.
806    
807    2003-05-30  Bernhard Herzog  <[email protected]>
808    
809            * Thuban/UI/view.py (MapCanvas.set_view_transform): Limit the
810            maximum and minimum scale factors.
811    
812            * test/test_classgen.py (ClassGenTest.test): Update to reflect the
813            changes in classgen.py
814    
815    2003-05-30  Jonathan Coles   <[email protected]>
816    
817            * Thuban/Model/classgen.py: Remove ClassGenerator class but make
818            all the methods functions. Fixes RTBug #1903.
819    
820            * Thuban/Model/map.py (Map.TopLayer, Map.BottomLayer): Renamed
821            to MoveLayerToTop and MoveLayerToBottom respectively. Fixes
822            RTBug #1907.
823    
824            * Thuban/UI/classgen.py: Use classgen functions that were part
825            of the ClassGenerator class. Put try/finally blocks around
826            code that uses wxBeginBusyCursor()/wxEndBusyCursor(). Fixes
827            RTBug #1904.
828    
829            * Thuban/UI/classifier.py: Remove unused import of ClassGenerator.
830    
831            * Thuban/UI/legend.py: The legend was cleared and repopulated any
832            time something changed which caused some state to be lost such
833            as which children were expanded or collapsed. Fixes RTBug #1901.
834            (LegendTree._OnMsgMapLayersAdded): Add only new layers.
835            (LegendTree.__OnMsgMapLayersRemoved): Remove layers that exist in
836            the legend but not in the map.
837            (LegendTree.__FillTree): Move main functionality out into smaller
838            methods that can be used by other methods.
839            (LegendTree.__FillTreeLayer): Reuse old slots in the image list
840            if they are available.
841            (LegendTree.DeleteAllItems): Renamed from __DeleteAllItems so
842            that we override the wxTreeCtrl method. Iterate over children
843            and call __RemoveLayer.
844            (LegendTree.__AddLayer): New. Add a new layer to the legend.
845            (LegendTree.__RemoveLayer): Remove a layer from the legend.
846            (LegendTree.DeleteChildren): New, overrides wxTreeCtrl method.
847            Should only be called with the id of a layer branch.
848            (LegendTree.GetRootItem): New, overrides wxTreeCtrl method.
849            Returns the root item or creates one if necessary.
850    
851            * Thuban/UI/renderer.py (MapRenderer.draw_raster_layer): Call
852            ProjectRasterFile with tuple arguments instead of strings.
853    
854            * Thuban/UI/tableview.py (QueryTableFrame.OnQuery): Wrap code
855            with try/finally. Fixes RTBug #1904.
856    
857            * Thuban/UI/view.py (MapCanvas.OnPaint): Wrap code
858            with try/finally. Fixes RTBug #1904.
859            (MapCanvas.FitSelectedToWindow): If a single point is selected
860            simply center it on the display. Fixes RTBug #1849.
861    
862            * extensions/thuban/gdalwarp.cpp: Removed code that allowed gdalwarp
863            to be compiled as a standalone app. Now the code can only be
864            called from Python which simplifies the parameter passing.
865            (ProjectRasterFile): Handle Python arguments. Remove code that
866            checks for a destination dataset. Add more clean up code.
867    
868            * test/test_map.py (TestMapWithContents.test_raise_layer_top,
869            TestMapWithContents.test_lower_layer_bottom):
870            Test Map.MoveLayerToTop() and Map.MoveLayerToBottom() respectively.
871            Fixes RTBug #1907.
872    
873            * Thuban/UI/mainwindow.py (MainWindow.ToggleLegend): Apply a full
874            extent to the map when the legend is toggled. Fixes RTBug #1881.
875    
876    2003-05-29  Jan-Oliver Wagner <[email protected]>
877    
878            * Thuban/UI/tableview.py (LayerTableFrame.OnClose): Bug-fix: Now
879            unsubscribes all that is subcribed in __init__.
880    
881    2003-05-28  Bernhard Herzog  <[email protected]>
882    
883            * Thuban/UI/mainwindow.py (MainWindow.DuplicateLayer)
884            (MainWindow.CanDuplicateLayer): New methods to implement the
885            Layer/Duplicate command.
886            (layer_duplicate command): New.
887            (main_menu): Add layer_duplicate to the Layer menu.
888    
889    2003-05-28  Bernhard Herzog  <[email protected]>
890    
891            * Thuban/UI/tableview.py (NullRenderer.Draw): New. Our own
892            renderer so that NULL/None values get displayed differently (by a
893            gray rectangle).
894            (TableGrid.__init__): Override the default renderers
895    
896    2003-05-28  Bernhard Herzog  <[email protected]>
897    
898            * Thuban/Model/layer.py (Layer.SetShapeStore): Set the
899            classification to "None" if the type of the field has changed.
900    
901            * test/test_layer.py (SetShapeStoreTests): New. Class with a few
902            test for the Layer.SetShapeStore method
903    
904    2003-05-28  Jan-Oliver Wagner <[email protected]>
905    
906            * Thuban/Model/layer.py (Layer.TreeInfo): Fixed a bug (a layer
907            does not necessarily have a filename).
908    
909    2003-05-28  Jan-Oliver Wagner <[email protected]>
910    
911            * Thuban/UI/mainwindow.py (MainWindow.TableClose, MainWindow.TableShow):
912            sort the selection list for the dialog.
913    
914    2003-05-28  Frank Koormann  <[email protected]>
915    
916            * extensions/thuban/wxproj.cpp
917            (project_point): Removed cast to int for projected point coordinates.
918            (shape_centroid): Return last point if all polygon vertices fall
919            to one point.
920    
921    2003-05-28  Bernhard Herzog  <[email protected]>
922    
923            * Thuban/UI/mainwindow.py (_can_unjoin): Add doc-string and cope
924            with layers that don't have shapestores, i.e. raster layers.
925    
926    2003-05-28  Bernhard Herzog  <[email protected]>
927    
928            * Thuban/Model/table.py (DBFTable.__init__): Omit the extension
929            when determining the title from the filename.
930    
931            * test/test_dbf_table.py (TestDBFTable.test_title): Update to
932            reflect changes in the way the title is derived from the filename
933    
934    2003-05-28  Frank Koormann  <[email protected]>
935    
936            * Thuban/UI/mainwindow.py (MainWindow.TableShow):
937            Added wxDEFAULT_DIALOG_STYLE to show table dialog styles.
938    
939    2003-05-27  Bernhard Herzog  <[email protected]>
940    
941            * Thuban/UI/mainwindow.py (MainWindow.delegated_messages): Also
942            delegate SelectedLayer.
943            (MainWindow.LayerUnjoinTable): Implement.
944            (_can_unjoin): New. Helper function for the sensitivity of the
945            layer/unjoin command.
946    
947            * Thuban/Model/data.py (ShapefileStore.OrigShapeStore)
948            (DerivedShapeStore.OrigShapeStore): New. Return the original
949            shapestore. Used to figure out how to unjoin.
950            (DerivedShapeStore.Shapefile): Fix a typo.
951    
952    2003-05-27  Bernhard Herzog  <[email protected]>
953    
954            * Thuban/UI/join.py (JoinDialog): Extend to handle layer joins as
955            well
956            (JoinDialog.__init__): Use the layer parameter and only build the
957            left choice when a layer is given
958            (JoinDialog.OnJoin): Handle layer joins as well
959            (JoinDialog.OnLeftTable, JoinDialog.OnRightTable): Handle the case
960            that the user selects the "Select..." item. The sensitivitly
961            updating is now in update_sensitivity
962            (JoinDialog.y): New method to refactor the sensitivity update of
963            the join button into its own method.
964    
965            * Thuban/UI/mainwindow.py (MainWindow.LayerJoinTable): Implement.
966    
967    2003-05-27  Bernhard Herzog  <[email protected]>
968    
969            * Thuban/UI/mainwindow.py (table_close command): Make it sensitive
970            iff there are unreferenced tables in the session
971    
972    2003-05-27  Bernhard Herzog  <[email protected]>
973    
974            * Thuban/Model/messages.py (TABLE_REMOVED): New message.
975    
976            * Thuban/Model/session.py (Session.UnreferencedTables): New method
977            to return tables that are not referenced by other tables or shape
978            stores and can be removed.
979            (Session.RemoveTable): Issue a TABLE_REMOVED message after
980            removing the table
981    
982            * Thuban/UI/mainwindow.py: Remove unused imports
983            (MainWindow.TableClose): Implement.
984    
985            * Thuban/UI/tableview.py (TableFrame.__init__): Subscribe to some
986            messages so that the frame will be automatically closed when a new
987            session is opened or the table is removed.
988            (TableFrame.OnClose): Unsubscribe the Subscriptions made in
989            __init__
990            (TableFrame.close_on_session_replaced)
991            (TableFrame.close_on_table_removed): New. Subscribers that close
992            the window
993    
994            * test/test_session.py (TestSessionMessages.test_remove_table)
995            (TestSessionSimple.test_remove_table): Move the test to
996            TestSessionSimple and add test for the TABLE_REMOVED message
997            (TestSessionBase.setUp): Also subscribe to TABLE_REMOVED
998            (TestSessionSimple.test_unreferenced_tables) New. Test for the
999            UnreferencedTables method.
1000            (UnreferencedTablesTests): New. Class with some more sophisticated
1001            tests for UnreferencedTables.
1002    
1003    2003-05-27  Frank Koormann  <[email protected]>
1004    
1005            * Thuban/UI/tableview.py (QueryTableFrame.__init__): The "_S_election"
1006            display has some unwanted side effects. Removed again.
1007    
1008    2003-05-27  Frank Koormann  <[email protected]>
1009    
1010            * Resources/Bitmaps/legend_icon_layer.xpm: New, icon for legend.
1011    
1012            * Thuban/UI/legend.py (LegendTree.__FillTree): Use "legend_icon_layer"
1013    
1014    2003-05-27  Jan-Oliver Wagner <[email protected]>
1015    
1016            * test/test_menu.py (MenuTest.test): Added test for
1017            Menu.RemoveItem().
1018    
1019            * Thuban/UI/menu.py (Menu.RemoveItem): New. Remove an item from
1020            the menu.
1021    
1022    2003-05-27  Frank Koormann  <[email protected]>
1023            
1024            Nonmodal dialogs without parent (i.e. they can fall behind the main
1025            window)
1026    
1027            * Thuban/UI/mainwindow.py (MainWindow.OnClose): Explicitly destroy
1028            all dialogs in the dialogs dictionary and the canvas.
1029    
1030            * Thuban/UI/dialogs.py (NonModalNonParentDialog): New class, without
1031            parent, i.e. can fall behind other windows.
1032            (NonModalDialog.OnClose): Check is dialog is in mainwindow.dialog
1033            dictionary before removing it.
1034    
1035            * Thuban/UI/classifier.py: Dialog derived from NonModalNonParentDialog
1036    
1037            * Thuban/UI/projdialog.py: Dialog derived from NonModalNonParentDialog
1038            * Thuban/UI/tableview.py: Dialog derived from NonModalNonParentDialog
1039            * Thuban/UI/tree.py: Dialog derived from NonModalNonParentDialog
1040    
1041    2003-05-27  Bernhard Herzog  <[email protected]>
1042    
1043            * Thuban/UI/mainwindow.py (MainWindow.ShowTableView): New. Open a
1044            tableview dialog
1045            (MainWindow.TableShow): Use ShowTableView to open the dialogs.
1046            Also, don't use the table's titles as the dialog names. The titles
1047            aren't guaranteed to be unique.
1048            (MainWindow.TableOpen): Open a table view dialog after opening the
1049            table
1050    
1051    2003-05-27  Bernhard Herzog  <[email protected]>
1052    
1053            * Thuban/UI/mainwindow.py: Remove the Table/Hide menu item. Its
1054            effect can be achieved by simply closing the window showing the
1055            table.
1056            (MainWindow.TableHide): Removed.
1057            (main_menu): Removed "table_hide"
1058    
1059    2003-05-27  Frank Koormann  <[email protected]>
1060    
1061            Fix legend tree display problems under Win32
1062    
1063            * Thuban/UI/legend.py:  BMP_SIZE_W = 15
1064            (LegendTree.__FillTree): Display "legend_icon_map.xpm" with layer title.
1065            (LegendTree.__FillTreeLayer): Explicitely set SelectedImage.
1066    
1067            * Resources/Bitmaps/legend_icon_map.xpm: New icon for legend.
1068    
1069    2003-05-27  Jan-Oliver Wagner <[email protected]>
1070    
1071            * Thuban/UI/menu.py (Menu.InsertSeparator): Additional optional parameter
1072            'after' now allows to insert separators almost anywhere in the menu.
1073    
1074    2003-05-27  Frank Koormann  <[email protected]>
1075    
1076            * Thuban/UI/tableview.py (QueryTableFrame.__init__): Underline the
1077            "S" of selection box label to hint on hot key (Alt-S). Works under
1078            Win32 but is ignored under GTK.
1079    
1080    2003-05-26  Frank Koormann  <[email protected]>
1081    
1082            * Thuban/UI/projdialog.py (ProjFrame.__do_layout, ProjPanel._DoLayout):
1083            Center Choices.
1084    
1085    2003-05-26  Bernhard Herzog  <[email protected]>
1086    
1087            Remove the Precision methods again. They're too DBF specific to be
1088            part of the table interface and they're only used in table_to_dbf
1089            anyway.
1090            
1091            * Thuban/Model/transientdb.py (TransientTableBase.Width):Use a
1092            fixed precision of 12 for doubles.
1093            (TransientTableBase.Precision): Removed
1094            (AutoTransientTable.Width): Delegate to self.table.
1095    
1096            * Thuban/Model/table.py (DBFTable.Precision)
1097            (MemoryTable.Precision): Removed.
1098            (MemoryTable.Width): Use a fixed precision of 12 for doubles.
1099            (table_to_dbf): Use a fixed precision of 12 for floats unless the
1100            column object specifies something else.
1101    
1102            * test/test_dbf_table.py (TestTableToDBF.test_table_to_dbf): New.
1103            test for table_to_dbf
1104    
1105    2003-05-26  Bernhard Herzog  <[email protected]>
1106    
1107            * test/test_transientdb.py
1108            (TestTransientTable.run_iceland_political_tests): Fix a comment.
1109    
1110    2003-05-26  Bernhard Herzog  <[email protected]>
1111    
1112            * Thuban/UI/mainwindow.py (MainWindow.TableOpen): Real
1113            implementation. Mark parts of the file format strings for
1114            localization.
1115    
1116            * Thuban/Model/session.py (Session.OpenTableFile): New. Open a dbf
1117            file and add the table to the tables managed by the session
1118    
1119            * test/test_session.py (TestSessionSimple.test_open_table_file):
1120            New. test case for OpenTableFile
1121    
1122    2003-05-26  Jan-Oliver Wagner <[email protected]>
1123    
1124            * Thuban/UI/controls.py, Thuban/UI/identifyview.py, Thuban/UI/join.py,
1125            Thuban/UI/labeldialog.py, Thuban/UI/mainwindow.py,
1126            Thuban/UI/proj4dialog.py, Thuban/UI/tableview.py, Thuban/UI/view.py:
1127            Replace the true/false of wxWindows by True/False of Python 2.2.1.
1128    
1129    2003-05-26  Jan-Oliver Wagner <[email protected]>
1130    
1131            * Thuban/UI/tableview.py (LayerTableFrame.__init__): If there is
1132            already a selection present, update the grid accordingly.
1133    
1134            * Thuban/UI/mainwindow.py (MainWindow.TableShow): Make the dialog
1135            resizeable and increase its initial size.
1136    
1137    2003-05-26  Frank Koormann  <[email protected]>
1138    
1139            Table export functionality
1140    
1141            * Thuban/Model/table.py (DBFTable.Width, MemoryTable.Width):
1142            Return width (in characters) for a column.
1143            (DBFTable.Precision, MemoryTable.Precision): Return decimal precision.
1144            (table_to_dbf): Write table to dbf file.
1145            (table_to_csv): Write table to csv file.
1146    
1147            * Thuban/Model/transientdb.py (TransientTableBase.Width,
1148            TransientTableBase.Precision): Return column width and precision.
1149    
1150            * Thuban/UI/tableview.py (QueryTableFrame.OnSaveAs): Call table_to_dbf
1151            or table_to_csv depending on file selection.
1152    
1153            * test/test_dbf_table.py:
1154            Test table_to_dbf (extension of former part of test).
1155    
1156            * test/test_csv_table.py:
1157            Test table_to_csv.
1158    
1159    2003-05-23  Jan-Oliver Wagner <[email protected]>
1160    
1161            * Thuban/UI/join.py (JoinDialog.OnJoin): Use _() for strings.
1162            Use QueryTableFrame instead of TableFrame.
1163    
1164            * Thuban/UI/mainwindow.py (MainWindow.LayerShowTable): Prefix the
1165            table window with 'Layer Table:' instead of 'Table:'.
1166    
1167    2003-05-23  Jan-Oliver Wagner <[email protected]>
1168    
1169            Give all tables a title via mix-in TitledObject.LayerShowTable
1170    
1171            * Thuban/Model/base.py (TitledObject.SetTitle): Call method 'issue'
1172            only if it exists.
1173    
1174            * Thuban/Model/table.py (DBFTable, MemoryTable): mix-in TitledObject
1175            and call its init-method with a default title. Remove Title() method.
1176    
1177            * Thuban/Model/transientdb.py (TransientTable, TransientJoinedTable,
1178            AutoTransientTable): mix-in TitledObject and call its init-method with
1179            a default title. Remove Title() method.
1180    
1181    2003-05-23  Bernhard Herzog  <[email protected]>
1182    
1183            * Thuban/Model/session.py (Session.AddShapeStore): Define
1184            AddShapeStore analogously to AddTable.
1185    
1186            * test/test_session.py (TestSessionSimple.test_add_shapestore):
1187            New. Test for AddShapeStore
1188    
1189    2003-05-23  Jan-Oliver Wagner <[email protected]>
1190    
1191            Introducing QueryTableFrame and a very coarse ShowTable implementation.
1192    
1193            * Thuban/UI/tableview.py (LayerTableFrame, QueryTableFrame): Split the
1194            class LayerTableFrame into two classes, LayerTableFrame and QueryTableFrame.
1195            The latter implements the selection GUI without dependency on a layer.
1196            LayerTableFrame now is derived from QueryTableFrame and connects
1197            to a layer.
1198    
1199            * Thuban/UI/mainwindow.py (MainWindow.TableShow): A very coarse
1200            implementation that still needs work.
1201    
1202            * Thuban/Model/layer.py (Layer.TreeInfo): Added filename.
1203    
1204    2003-05-22  Frank Koormann  <[email protected]>
1205    
1206            * Thuban/Model/transientdb.py (TransientJoinedTable.__init__):
1207            Added "outer_join = False" as optional parameter.
1208            (TransientJoinedTable.create): If outer join is true, perform a
1209            "LEFT OUTER JOIN" instead of "JOIN", which preserves all records of
1210            the left table. Records not matching are filled with 0 / None.
1211    
1212            * Thuban/UI/join.py (JoinDialog.__init__): Checkbox for outer join.
1213            (JoinDialog.OnJoin): Consider outer join check box.
1214    
1215    2003-05-22  Bernhard Herzog  <[email protected]>
1216    
1217            * Thuban/UI/join.py (JoinDialog.OnJoin): Use exc_info in a
1218            somewhat safer way. Storing the traceback in a local variable can
1219            lead to memory leaks
1220    
1221    2003-05-22  Bernhard Herzog  <[email protected]>
1222    
1223            * Thuban/UI/join.py (JoinDialog.OnJoin): Make sure to really call
1224            the wxMessageDialog's Destroy() method.
1225    
1226    2003-05-22  Frank Koormann  <[email protected]>
1227    
1228            * Thuban/UI/join.py (JoinDialog.__init__): Make use of
1229            TransientTable.Title()
1230    
1231    2003-05-22  Frank Koormann  <[email protected]>
1232    
1233            Join Dialog, initial version.
1234    
1235            * Thuban/UI/mainwindow.py (MainWindow.TableJoin): Removed print.
1236    
1237            * Thuban/UI/join.py (JoinDialog): Functional implementation of
1238            former framework. Renamed Table1/Table2 to LeftTable/RightTable
1239            in all occurences.
1240    
1241            * Thuban/Model/transientdb.py (TransientJoinedTable.__doc__):
1242            Typo fixed.
1243    
1244    2003-05-22  Bernhard Herzog  <[email protected]>
1245    
1246            Give the tables titles so that the GUI can display more meaningful
1247            names. For now the titles are fixed but depend on e.g. filenames
1248            or the titles of the joined tables.
1249    
1250            * Thuban/Model/transientdb.py (TransientTable.Title)
1251            (TransientJoinedTable.Title, AutoTransientTable.Title): New.
1252    
1253            * Thuban/Model/table.py (DBFTable.Title, MemoryTable.Title): New.
1254    
1255            * test/test_transientdb.py
1256            (TestTransientTable.test_auto_transient_table_title): New. Test
1257            for the Title method
1258            (TestTransientTable.test_transient_joined_table)
1259            (TestTransientTable.test_transient_table): Add test for the Title
1260            methods
1261    
1262            * test/test_memory_table.py (TestMemoryTable.test_title): New.
1263            Test for the Title method
1264    
1265            * test/test_dbf_table.py (TestDBFTable.test_title): New. Test for
1266            the Title method
1267    
1268    2003-05-22  Bernhard Herzog  <[email protected]>
1269    
1270            * test/test_layer.py (TestLayer.setUp, TestLayer.tearDown):
1271            Provide a better way to destroy the layers
1272            (TestLayer.test_base_layer, TestLayer.test_arc_layer)
1273            (TestLayer.test_point_layer, TestLayer.test_empty_layer)
1274            (TestLayer.test_polygon_layer, TestLayer.test_get_field_type): Use
1275            the new way to destroy the layers.
1276            (TestLayer.test_derived_store): New. Test for using a layer with a
1277            DerivedShapeStore
1278    
1279            * Thuban/Model/layer.py (Layer.SetShapeStore): Only set the
1280            filename if the shape store actually has one.
1281    
1282    2003-05-22  Bernhard Herzog  <[email protected]>
1283    
1284            * Thuban/Model/table.py (DBFTable.FileName): New. Accessor method
1285            for the filename
1286    
1287            * test/test_dbf_table.py (TestDBFTable.test_filename): New. Test
1288            for the FileName method
1289            (TestDBFTableWriting.test_write): Fix spelling of filename
1290    
1291    2003-05-22  Thomas Koester  <[email protected]>
1292    
1293            * Thuban/Model/range.py, test/test_range.py: Brought over new Range
1294            from SciParam that now really is immutable.
1295    
1296    2003-05-22  Frank Koormann  <[email protected]>
1297    
1298            Layer Top/Bottom placement added to legend.
1299    
1300            * Thuban/UI/legend.py
1301            (LegendPanel._OnMoveTop(), LayerPanel._OnMoveBottom): New, methods
1302            bound to tool events.
1303            (LegendTree.MoveCurrentItemTop(), LegendTree.MoveCurrentItemBottom):
1304            New, methods binding the event methods with the map methods.
1305    
1306            * Thuban/Model/map.py (Map.TopLayer(), Map.BottomLayer()): New, place
1307            layer at top/bottom of layer stack.
1308    
1309            * Resources/Bitmaps/top_layer.xpm: New button icon.
1310    
1311            * Resources/Bitmaps/bottom_layer.xpm: New button icon.
1312    
1313    2003-05-22  Bernhard Herzog  <[email protected]>
1314    
1315            * Thuban/Model/session.py (Session.RemoveTable): New method to
1316            remove tables
1317    
1318            * test/test_session.py (TestSessionSimple.test_remove_table): New.
1319            Test for RemoveTable
1320    
1321    2003-05-22  Thomas Koester  <[email protected]>
1322    
1323            * Thuban/Model/classgen.py: Added short module doc string and CVS id.
1324            (ClassGenerator.GenUniformDistribution): Use new Range __init__, too.
1325    
1326    2003-05-22  Bernhard Herzog  <[email protected]>
1327    
1328            Implement a way to discover dependencies between tables and
1329            shapestores.
1330    
1331            * Thuban/Model/transientdb.py (TransientTableBase.Dependencies)
1332            (TransientJoinedTable.Dependencies)
1333            (AutoTransientTable.SimpleQuery): New. Implement the dependencies
1334            interface
1335            (TransientJoinedTable.__init__): Keep tack of the original table
1336            objects in addition to the corresponding transient tables.
1337    
1338            * Thuban/Model/table.py (DBFTable.Dependencies)
1339            (MemoryTable.Dependencies): New. Implement the dependencies
1340            interface
1341    
1342            * Thuban/Model/data.py (ShapeTable): New. Helper class for
1343            ShapefileStore
1344            (ShapefileStore.__init__): Use ShapeTable instead of
1345            AutoTransientTable
1346            (ShapefileStore.Table, ShapefileStore.Shapefile): Add doc-strings
1347            (ShapefileStore.FileName, ShapefileStore.FileType): New. Accessor
1348            methods for filename and type
1349            (ShapefileStore.Dependencies): New. Implement the dependencies
1350            interface
1351            (DerivedShapeStore): New class to replace SimpleStore. The main
1352            difference to SimpleStore is that it depends not on a shapefile
1353            but another shapestore which expresses the dependencies a bit
1354            better
1355            (SimpleStore.__init__): Add deprecation warning.
1356    
1357            * test/test_dbf_table.py (TestDBFTable.test_dependencies): New.
1358            Test for the Dependencies method.
1359    
1360            * test/test_memory_table.py (TestMemoryTable.test_dependencies):
1361            New. Test for the Dependencies method.
1362    
1363            * test/test_transientdb.py
1364            (TestTransientTable.test_auto_transient_table_dependencies): New.
1365            Test for the Dependencies method.
1366            (TestTransientTable.test_transient_joined_table): Add test for the
1367            Dependencies method.
1368    
1369            * test/test_session.py (TestSessionSimple.setUp)
1370            (TestSessionSimple.tearDown): New. Implement a better way to
1371            destroy the sessions.
1372            (TestSessionSimple.test_initial_state)
1373            (TestSessionSimple.test_add_table): Bind session to self.session
1374            so that it's destroyed by tearDown
1375            (TestSessionSimple.test_open_shapefile): New. Test for
1376            OpenShapefile and the object it returns
1377    
1378    2003-05-22  Bernhard Herzog  <[email protected]>
1379    
1380            * Thuban/Model/session.py (Session.AddTable): New method to
1381            register tables with the session.
1382            (Session.Tables): Return the tables registered with AddTable too.
1383    
1384            * test/test_session.py (TestSessionSimple.test_add_table): New.
1385            Test case for the AddTable method
1386    
1387    2003-05-22  Frank Koormann  <[email protected]>
1388    
1389            UI polishing updates: Place main buttons (OK, Cancel, etc) in the
1390            lower right corner, center labels for selections, initialize controls
1391            in reasonable order for keyboard navigation.
1392    
1393            * Thuban/UI/projdialog.py (ProjFrame.__init__, ProjFrame.__doLayout)
1394            (ProjFrame.__DoOnProjAvail): Determine position of current projection
1395            using the wxListBox.FindString() method. Still a problem (#1886)
1396    
1397            * Thuban/UI/classifier.py
1398            (Classifier.__init__, SelectPropertiesDialog.__init__)
1399    
1400            * Thuban/UI/classgen.py (ClassGenDialog.__init__,
1401            (ClassGenDialog.__DoOnGenTypeSelect): Moved initialization of the
1402            different classification types from here to __init__.
1403            (GenUniquePanel.__init__): Set the column width of the first field
1404            in the Field ListCtrl to the full width.
1405    
1406            * Thuban/UI/tableview.py (LayerTableFrame.__init__): Rename 'Save As'
1407            Button to 'Export'. Center Buttons in Selection Box, set Focus to
1408            Grid.
1409            (LayerTableFrame.OnKeyDown()): New, bound to the grid with EVT_KEY_DOWN,
1410            changes focus to the Selection when pressing "Alt-S".
1411    
1412            * Thuban/UI/legend.py (LegendTree.__SetVisibilityStyle): Only gray out
1413            the text if not visible. The italic font sometimes exceeds the
1414            rendering area.
1415    
1416    2003-05-21  Jonathan Coles   <[email protected]>
1417    
1418            * Thuban/UI/dock.py (DockFrame): Rename references to _OnClose
1419            to OnClose so that Thuban closes correctly.
1420    
1421            * Thuban/UI/mainwindow.py (MainWindow.OnClose): Call
1422            DockFrame.OnClose, not DockFrame._OnClose.
1423    
1424    2003-05-21  Jonathan Coles   <[email protected]>
1425    
1426            * Thuban/Model/classgen.py (ClassGenerator.GenQuantiles): Remove
1427            references to 'inf' and use new Range __init__ to pass floats
1428            directly rather than converting them to strings first.
1429            Fixes RTBug #1876.
1430    
1431            * Thuban/Model/classification.py (ClassGroupRange.SetRange):
1432            Use new Range ___init__ to pass floats.
1433    
1434            * Thuban/Model/layer.py (RasterLayer.__init__): Test if the
1435            filename is a valid image file. Throw IOError otherwise.
1436    
1437            * Thuban/Model/range.py: Brought over new Range from SciParam that
1438            is immutable and has an __init__ which can accept floats.
1439    
1440            * Thuban/UI/mainwindow.py (MainWindow.AddLayer): Move OpenShapefile
1441            into try block. AddLayer doesn't throw any exceptions anymore.
1442            (MainWindow.AddRasterLayer): Move constructor of RasterLayer into
1443            try block.
1444    
1445            * Thuban/UI/projdialog.py (GeoPanel.__init__): Put Degrees as
1446            the first item in choices. Fixes RTBug #1882.
1447    
1448            * Thuban/UI/renderer.py (MapRenderer.render_map): Check if scale
1449            has gone to 0 which is a serious problem. abort.
1450            (MapRenderer.draw_raster_layer): Catch IOError seperately and
1451            print the error from GDAL.
1452    
1453            * Thuban/UI/tableview.py (TableGrid.__init__): Call
1454            ToggleEventListeners to turn on listening.
1455            (TableGrid.ToggleEventListeners): New. Turns event listening on
1456            and off so as to prevent excessive messages.
1457            (LayerTableFrame.OnQuery): Use TableGrid.ToggleEventListeners
1458            to suppress excessive messages when selecting many rows.
1459            Fixes RTBug #1880.
1460    
1461            * Thuban/UI/view.py: Added checks against if scale == 0. This
1462            is a serious problem that can occur when an image without
1463            geo data is loading and causes the map projection bounds to
1464            go to infinity. Right now, the solution is to simply try
1465            to recover.
1466    
1467            * extensions/thuban/cpl_mfile.cpp (MFILEClose): Make sure
1468            to set the MFILEReceiver attributes even if the data is NULL.
1469    
1470            * extensions/thuban/gdalwarp.cpp: Improved the error handling
1471            and passed GDAL messages back up to the Python layer. Also
1472            tried to fix some memory leaks that were present in the original
1473            utility but didn't matter because the program aborted.
1474    
1475            * test/test_range.py: Copied over tests from SciParam. Removed
1476            tests against importing. Fixes RTBug #1867.
1477    
1478    2003-05-21  Bernhard Herzog  <[email protected]>
1479    
1480            * test/test_load.py: Remove unused imports and restructure the
1481            test code
1482            (LoadSessionTest): Split into one class for each test and turn
1483            LoadSessionTest itself into the base class for all such session
1484            tests.
1485            (ClassificationTest): New base class for load tests that test
1486            classifications
1487            (TestSingleLayer, TestLayerVisibility, TestClassification)
1488            (TestLabels, TestLayerProjection, TestRasterLayer): New classes
1489            for the individual tests
1490    
1491            * test/support.py (FileLoadTestCase.filename): New base class for
1492            file loading tests
1493    
1494    2003-05-21  Jan-Oliver Wagner <[email protected]>
1495    
1496            * Resources/Projections/defaults.proj: Renamed 'Universal Transverse
1497            Mercator' to 'UTM Zone 32' as a more convenient example.
1498            Added 'Gauss Krueger Zone 6'.
1499    
1500            * Data/iceland_sample_raster.thuban: political polygon now
1501            filled transparent to have the raster image visible at once.
1502    
1503    2003-05-21  Frank Koormann  <[email protected]>
1504    
1505            * Thuban/UI/mainwindow.py (MainWindow): Renamed _OnClose() back to
1506            OnClose() to keep in sync with extensions. Internally Thuban
1507            still uses "underscored" names.
1508    
1509    2003-05-20  Jonathan Coles   <[email protected]>
1510    
1511            This puts back Raster layer support. These layers support projections
1512            through the GDAL library. Currently, the CVS version is being used.
1513            There are no Debian packages available although this may change soon.
1514            A GDAL driver was extended to support writing to memory rather to
1515            files.
1516    
1517            There is still some work that needs to be done, such as some error
1518            handling when loading invalid images or when there is a problem
1519            projecting the image. This putback simply checks in the majority
1520            of the work.
1521    
1522            * setup.py: Add gdalwarp library extension.
1523    
1524            * Thuban/Model/layer.py (BaseLayer.HasClassification): New.
1525            Defaults to False, but can be overridden by subclasses if they
1526            support classification.
1527            (RasterLayer): New. Defines a new layer that represents an
1528            image.
1529    
1530            * Thuban/Model/load.py (SessionLoader.__init__): Add rasterlayer
1531            tag handler.
1532            (SessionLoader.start_layer): Encode the filename.
1533            (SessionLoader.start_rasterlayer, SessionLoader.end_rasterlayer):
1534            New. Supports reading a rasterlayer tag.
1535    
1536            * Thuban/Model/map.py (Map.BoundingBox): Fix typo in comment.
1537    
1538            * Thuban/Model/save.py (XMLWriter.encode): Don't assume that we
1539            get a string in Latin1. If we get such as string convert it to
1540            unicode first, otherwise leave if alone before encoding.
1541            (SessionSaver.write_layer): Add support for writing both Layers
1542            and RasterLayers.
1543    
1544            * Thuban/Model/transientdb.py (AutoTransientTable.SimpleQuery):
1545            The right argument may not be a string, it could also be a Column.
1546    
1547            * Thuban/UI/application.py (ThubanApplication.CreateMainWindow):
1548            Make initial window size 600x400. Fixes RTBug #1872.
1549    
1550            * Thuban/UI/classifier.py (Classifier.__init__): Rearrange how
1551            the dialog is constructed so that we can support layers that
1552            do not have classifications.
1553            (Classifier._OnTry): Only build a classification if the layer
1554            supports one.
1555    
1556            * Thuban/UI/legend.py: Change all checks that a layer is an
1557            instance of Layer into checks against BaseLayer.
1558            (LegendTree.__FillTreeLayer): Only add children to a branch if
1559            the layer supports classification.
1560    
1561            * Thuban/UI/mainwindow.py (MainWindow.NewSession,
1562            MainWindow.OpenSession): Don't proceed with an action if the
1563            user chooses Cancel when they are asked to save changes.
1564            (MainWindow.AddRasterLayer): New. Open a dialog to allow the
1565            user to select an image file. Create a new RasterLayer and add
1566            it to the map.
1567    
1568            * Thuban/UI/renderer.py (MapRenderer.render_map): Add support
1569            for rendering RasterLayer layers.
1570            (MapRenderer.draw_raster_layer): Actually method that calls
1571            the GDALWarp python wrapper and constructs an image from the
1572            data returned.
1573    
1574            * Thuban/UI/tableview.py (LayerTableFrame.__init__): Change the
1575            Choices symbols to match those used in the table query method.
1576            Replace deprecated method calls on table with new method names.
1577    
1578            * Thuban/UI/view.py (MapCanvas.set_view_transform): Try to limit
1579            how small the scale can get. This still needs more testing.
1580    
1581            * extensions/thuban/bmpdataset.cpp: New, but copied from GDAL.
1582            Provides a driver to output in .bmp format.
1583    
1584            * extensions/thuban/cpl_mfile.cpp, extensions/thuban/cpl_mfile.h:
1585            New. Provides IO routines which write to memory, rather than a file.
1586    
1587            * extensions/thuban/gdalwarp.cpp: New, but basically a direct copy
1588            of the gdalwarp utility provided in GDAL. Added function calls
1589            that can be accessed from python.
1590    
1591            * Data/iceland_sample_raster.thuban: New. Sample file that uses
1592            a raster layer.
1593    
1594            * Data/iceland/island.tfw, Data/iceland/island.tif: New. Raster
1595            layer image data.
1596    
1597            * Doc/thuban.dtd: Added rasterlayer attribute definition.
1598    
1599            * test/test_layer.py, test/test_load.py, test/test_save.py: Added
1600            tests associated with the raster layer code.
1601    
1602            * test/test_transientdb.py
1603            (TestTransientTable.test_auto_transient_table_query): Added a test
1604            for using a Column object as the "right" parameter to a query.
1605    
1606    2003-05-19  Frank Koormann  <[email protected]>
1607    
1608            * Thuban/version.py (get_changelog_date):
1609            Catch exceptions if ChangeLog does not exist.
1610    
1611            * Thuban/UI/view.py (MapCanvas.Export): Bugfix
1612    
1613    2003-05-19  Frank Koormann  <[email protected]>
1614    
1615            Extended version information for Thuban
1616    
1617            * Thuban/version.py: New, version information for Thuban: Last
1618            modification date and last ChangeLog entry date.
1619    
1620            * Thuban/UI/mainwindow.py (MainWindow.About()): Extended version
1621            information: Display Thuban, wxPython and Python version.
1622    
1623    2003-05-16  Bernhard Herzog  <[email protected]>
1624    
1625            * Thuban/Model/save.py: Remove some unused imports including the
1626            __future__ import for nested_scopes as Thuban relies on Python 2.2
1627            now.
1628            (XMLWriter.encode): Remove the special case for a None argument.
1629            In the saver encode is always called with a string argument.
1630    
1631    2003-05-16  Bernhard Herzog  <[email protected]>
1632    
1633            * Thuban/UI/__init__.py: Remove the work-around for the locale bug
1634            in wxPython (at least when usinvg wxGTK) prior to 2.4. The symptom
1635            of the bug was that e.g. float("1.2") would fail. Thuban now
1636            requires 2.4.x.
1637            
1638    2003-05-16  Frank Koormann   <[email protected]>
1639    
1640            Printing enhancement and WMF export (under Win32)
1641    
1642            * Thuban/UI/renderer.py (ExportRenderer): New, derived from
1643            ScreenRenderer. Renders Map, Legend and Scalebar for export.
1644            (PrinterRenderer): New, derived from ExportRenderer. Replaces the old
1645            PrintRender.
1646    
1647            * Thuban/UI/view.py (MapPrintout.__init__): Enhanced parameter set
1648            to fullfil information needed for PrinterRenderer.
1649            (MapCanvas.Export): New. Export Map (currently only to WMF on Win32).
1650            (MapCanvas.Print): Adapted to new MapPrintout.
1651            (OutputTransform): General calculations to transform from canvas
1652            coordinates to export/printing devices.
1653    
1654            * Thuban/UI/mainwindow.py (MainWindow.ExportMap()): New. Added also
1655            new method_command to call ExportMap, with platform dependency (only
1656            __WXMSW__)
1657      
1658            * Thuban/UI/scalebar.py (ScaleBar.DrawScaleBar): Position and Size
1659            of scalebar drawing area as new parameters.
1660            
1661            * Thuban/Model/scalebar.py (roundInterval): round long instead of int
1662    
1663            * Thuban/UI/legend.py (ScalebarBitmap.__SetScale):
1664            Update to extended scalebar.DrawScalebar header.
1665    
1666            * test/test_export.py: New, test Thuban.UI.view.OutputTransform()
1667    
1668            * test/test_scalebar.py: Made test executable as standalone.
1669    
1670    2003-05-16  Bernhard Herzog  <[email protected]>
1671    
1672            * Thuban/Model/table.py (Table): Remove this compatibility alias
1673            for DBFTable.
1674    
1675            * test/test_table.py: Import DBFTable as Table because that alias
1676            doesn't exist anymore.
1677    
1678            * Thuban/UI/classgen.py: Remove some unused imports
1679    
1680    2003-05-14  Jonathan Coles   <[email protected]>
1681    
1682            * Thuban/Model/classgen.py (ClassGenerator.GenSingletonsFromList):
1683            Fix docstring.
1684            (ClassGenerator.GenUniformDistribution): Fix spelling of method name.
1685            (ClassGenerator.GenQuantiles): Use the left/right brackets and min/max
1686            values of the supplied range to determine the beginning and end
1687            bounds of the generated classes.
1688    
1689            * Thuban/Model/range.py (Range.number_re): Now accepts floats that
1690            do not have a leading 0 (.5 is now accepted as well as 0.5).
1691    
1692            * Thuban/UI/classgen.py (ClassGenDialog.OnOK): Fix name of method
1693            call to ClassGenerator.GenUniformDistribution.
1694    
1695            * Thuban/UI/projdialog.py (ProjFrame.__do_layout): Fix Windows
1696            layout bug with the 'Projection' label.
1697    
1698            * test/support.py (FloatTestCase): New. Needed for the Range tests.
1699    
1700            * test/test_range.py: New. Imported from SciParam.
1701    
1702    2003-05-12  Jonathan Coles   <[email protected]>
1703    
1704            * Thuban/UI/classgen.py (GenQuantilesPanel.GetList): Replace call
1705            to table.UniqueValues() with calls that retrieve all the values
1706            from the table. This will need to be replaced by a method on table
1707            which can simply return the list (perhaps more efficiently).
1708    
1709    2003-05-12  Jonathan Coles   <[email protected]>
1710    
1711            The return value of ClassGenerator.CalculateQuantiles has changed.
1712            Refer to the documentation for details.
1713    
1714            * test/test_classgen.py: Modified Quantile tests to use the
1715            new return values.
1716    
1717            * Thuban/Model/classgen.py
1718            (ClassGenerator.GenQuantiles): Add comments describing the parameters,
1719            use new return values from CalculateQuantiles to produce the correct
1720            range bounds in the Classification.
1721            (ClassGenerator.CalculateQuantiles): Add more comments describing
1722            the return values and parameters. Make minor adjustments to improve
1723            the legibility of the code. Fix problem with adjusted not being set
1724            in most cases.
1725    
1726    2003-05-12  Frank Koormann <[email protected]>
1727            
1728            * Thuban/Model/save.py (XMLWriter.encode()): Explicite call to unicode
1729            and latin1. Fixes #1851 finally.
1730    
1731    2003-05-09  Jonathan Coles   <[email protected]>
1732    
1733            * test/test_classgen.py: New. Tests the Quantile algorithm.
1734    
1735            * Thuban/Model/classgen.py (ClassGenerator.CalculateQuantiles):
1736            Clean up debugging statement, add comments, fix a small bug in the
1737            returned adjusted percentiles.
1738            
1739    2003-05-09  Jonathan Coles   <[email protected]>
1740    
1741            Introduces Range class from SciParam into the ClassGroupRange class,
1742            and such ranges can now be saved and loaded from disk.
1743    
1744            Quantiles are now available in the Classification Generator.
1745    
1746            Initial support for building Queries on a table. Doesn't do anything
1747            but run some tests.
1748    
1749            * Thuban/Model/classification.py: Explicit imports.
1750            (ClassGroupRange): Use the Range class to store the underlying
1751            range information. The interface remains the same, except for
1752            GetRange(), and you can also supply a Range object as the min
1753            parameter to SetRange or __init__.
1754    
1755            * Thuban/Model/load.py (XMLReader.encode): New. Encodes the given
1756            string appropriately for use in Thuban. Fixes RTbug #1851.
1757            (SessionLoader.end_projection): Handle the context of the
1758            projection tag a bit better by looking at what objects are not
1759            None. There was an assumption that a projection tag for a map
1760            could occur before any layers.
1761            (SessionLoader.start_clrange): Provide backward compatibility for
1762            reading min/max values as well as the new range parameter.
1763    
1764            * Thuban/Model/map.py: Explicit imports.
1765    
1766            * Thuban/Model/resource.py: Import _.
1767            (ProjFileSaver.write): write header using projfile.dtd.
1768    
1769            * Thuban/Model/save.py: Explicit imports.
1770            (XMLWriter.encode): New. Encode the given string from a format
1771            used by Thuban into UTF-8. Fixes RTbug #1851.
1772    
1773            * Thuban/UI/classgen.py: Explicit imports.
1774            (ClassGenDialog.__init__): Clean up the code and add support
1775            for Quantiles.
1776            (ClassGenDialog.OnOK): Add support for Quantiles.
1777            (GenQuantilesPanel): New. Input panel for Quantiles.
1778            (ClassGenerator, CustomRamp, MonochromaticRamp, GreyRamp, RedRamp,
1779            GreenRamp, BlueRamp, HotToColdRamp): Move to Thuban/Model/classgen.py
1780    
1781            * Thuban/Model/classgen.py: New. Contains all the classes named above.
1782    
1783            * Thuban/UI/classifier.py: Explicit imports.
1784            (ClassTable.GetValueAsCust, ClassTable.__ParseInput,
1785            ClassTable.SetValueAsCustom): Reworked to use new Range class.
1786    
1787            * Thuban/UI/legend.py: Explicit imports.
1788    
1789            * Thuban/UI/mainwindow.py: Add support for the Join Dialog. Added
1790            a Table menu and associated method calls.
1791            (MainWindow.choose_color): Removed. No longer needed.
1792    
1793            * Thuban/UI/projdialog.py (ProjFrame.__VerifyButtons): Save button
1794            should be disabled if no projection is selected in the available
1795            list.
1796    
1797            * Thuban/UI/renderer.py: Explicit imports.
1798    
1799            * Thuban/UI/tableview.py (TableGrid.OnRangeSelect): Fix some issues
1800            with correctly selecting the rows and issuing the right events.
1801            Be sure to call Skip() to allow the grid to do some of its own
1802            handling which allows the rows to actually be selected.
1803            (LayerTableGrid.select_shapes): Rename from select_shape. Supports
1804            selecting multiple shapes.
1805            (LayerTableFrame): Support for building Queries.
1806            (LayerTableFrame.select_shapes): Allow multiple shapes to be selected.
1807    
1808            * Thuban/UI/tree.py: Explicit imports.
1809    
1810            * Thuban/UI/view.py (MapCanvas): Delegate "SelectedShapes" so the
1811            table view can call it.
1812    
1813            * test/test_classification.py: Explicit imports.
1814            (TestClassification.test_ClassGroupRange): Fix test for new
1815            Range class.
1816    
1817            * Doc/thuban.dtd: Add range parameter for clrange.
1818    
1819            * Thuban/Model/range.py: Taken from SciParam. Used as the underlying
1820            object in ClassGroupRange, and also uesd for inputting ranges in
1821            the classifer table and elsewhere.
1822    
1823            * Thuban/UI/join.py: New. Initial Join dialog. No real functionality
1824            yet.
1825    
1826    2003-05-09  Frank Koormann <[email protected]>
1827    
1828            * Thuban/UI/scalebar.py (DrawScaleBar): Draw only if interval > 0.0.
1829    
1830    2003-05-08  Frank Koormann <[email protected]>
1831    
1832            Coding style updates
1833    
1834            * test/test_scalebar.py: Replaced tab indentation by spaces.
1835    
1836            * Thuban/UI/scalebar.py: Explicit imports.
1837    
1838    2003-05-08  Frank Koormann <[email protected]>
1839    
1840            * Thuban/UI/scalebar.py
1841            (ScaleBar.DrawScalebar): Format string bug fixed.
1842    
1843    2003-05-08  Frank Koormann <[email protected]>
1844    
1845            Reorganization of scalebar component (no wx in Thuban/Model)
1846    
1847            * Thuban/Model/scalebar.py: Rendering moved to Thuban/UI/scalebar.py
1848            (deriveInterval):
1849            Calculate scalebar interval and unit which fits in width for scale.
1850            (roundInterval): Round float.
1851    
1852            * Thuban/UI/scalebar.py (ScaleBar): Scalebar rendering
1853    
1854            * test/test_scalebar.py: Test for Thuban/Model/scalebar.py methods.
1855    
1856            * Thuban/UI/legend.py: Import Thuban.UI.scalebar
1857    
1858    2003-05-08  Frank Koormann <[email protected]>
1859    
1860            * Thuban/UI/legend.py (ScalebarBitmap.SetCanvas):
1861            Initialize ScaleBar with canvas.map
1862    
1863            * Thuban/Model/scalebar.py (ScaleBar.roundInterval()): New,
1864            round intervals to display smarter lengths
1865            (ScaleBar.DrawScalebar): Draw Scalebar only if the map contains a
1866            layer. If the maps has no projection applied grey the scalebar.
1867    
1868    2003-05-07  Frank Koormann <[email protected]>
1869            
1870            Basic Scalebar features added.
1871    
1872            * Thuban/Model/scalebar.py (ScaleBar): New, scalebar rendering.
1873    
1874            * Thuban/UI/legend.py (LegendPanel): Added scalebar bitmap
1875            (ScaleBarBitmap): New, links the scalebar bitmap with view messages
1876            and the renderer.
1877    
1878            * Thuban/UI/view.py (MapCanvas.set_view_transform): Issue SCALE_CHANGED.
1879    
1880            * Thuban/UI/messages.py: SCALE_CHANGED added.
1881    
1882    2003-05-07  Bernhard Herzog  <[email protected]>
1883    
1884            * Thuban/Model/session.py (Session.__init__): New instance
1885            variable shapestores to hold a list of all open shapestore objects
1886            (Session.ShapeStores): New. Accessor method for the shapestores
1887            list.
1888            (Session._add_shapestore, Session._clean_weak_store_refs): New.
1889            Internal methods to maintain the shapestores list.
1890            (Session.Tables): New. Return all tables open in the session.
1891            (Session.OpenShapefile): Insert the new ShapeStore into the
1892            shapestores list.
1893    
1894            * test/test_session.py (TestSessionSimple.test_initial_state): Add
1895            tests for ShapeStores and Tables
1896            (TestSessionWithContent.test_shape_stores)
1897            (TestSessionWithContent.test_tables): New. Test cases for
1898            ShapeStores and Tables
1899    
1900    2003-05-07  Bernhard Herzog  <[email protected]>
1901    
1902            * Thuban/Model/transientdb.py (TransientTableBase.ReadRowAsDict):
1903            Add comments about the optimizations used.
1904            (AutoTransientTable.ReadValue, TransientTableBase.ReadValue): New.
1905            Implement the ReadValue table interface method.
1906    
1907            * test/test_transientdb.py
1908            (TestTransientTable.run_iceland_political_tests)
1909            (TestTransientTable.test_transient_joined_table): Add tests for
1910            ReadValue
1911    
1912    2003-05-07  Frank Koormann <[email protected]>
1913    
1914            * Resources/Bitmaps/fulllayerextent.xpm,
1915            Resources/Bitmaps/fullselextent.xpm: Replaced the place holders with
1916            new icons.
1917    
1918    2003-05-06  Bernhard Herzog  <[email protected]>
1919    
1920            * Thuban/Model/transientdb.py (AutoTransientTable.SimpleQuery):
1921            New. Simply delegate to the transient table's version.
1922    
1923            * test/test_transientdb.py
1924            (TestTransientTable.test_auto_transient_table_query): New. Test
1925            case for AutoTransientTable's SimpleQuery
1926    
1927    2003-05-06  Bernhard Herzog  <[email protected]>
1928    
1929            * Thuban/Model/transientdb.py (TransientTableBase.SimpleQuery):
1930            Implement a simple query method for the query dialog
1931            (TransientTableBase.create): Add an INTEGER PRIMARY KEY that holds
1932            the row index or shapeid.
1933            (TransientTable.create): Insert the right value of the row index
1934            (TransientJoinedTable.create): Copy the row index of the left
1935            table to the joined result table
1936    
1937            * test/test_transientdb.py
1938            (TestTransientTable.test_transient_table_read_twice): Fix
1939            doc-string
1940            (TestTransientTable.test_transient_table_query): New. Test for the
1941            SimpleQuery method
1942    
1943    2003-05-06  Bernhard Herzog  <[email protected]>
1944    
1945            Convert all table users to use the new table interface. This only
1946            covers Thuban itself, not GREAT-ER or other applications built on
1947            Thuban yet, so the compatibility interface stays in place for the
1948            time being but it now issues DeprecationWarnings.
1949    
1950            Finally, the new Table interface has a new method, HasColumn.
1951    
1952            * Thuban/Model/table.py (OldTableInterfaceMixin): All methods
1953            issue deprecation warnings when they're. The warnings refer to the
1954            caller of the method.
1955            (OldTableInterfaceMixin.__deprecation_warning): New. Helper method
1956            for the deprecation warnings
1957    
1958            * test/test_table.py: Ignore the deprecation warnings for the old
1959            table in the tests in this module. The purpose of the tests is to
1960            test the old interface, after all.
1961    
1962            * test/test_transientdb.py
1963            (TestTransientTable.run_iceland_political_tests): Use the
1964            constants for the types. Add a test for HasColumn
1965            (TestTransientTable.test_transient_joined_table): Adapt to new
1966            table interface. Add a test for HasColumn
1967            (TestTransientTable.test_transient_table_read_twice): Adapt to new
1968            table interface
1969    
1970            * Thuban/UI/tableview.py (DataTable.SetTable, DataTable.GetValue):
1971            Adapt to new table interface
1972    
1973            * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Adapt to
1974            new table interface
1975    
1976            * Thuban/UI/controls.py (RecordListCtrl.fill_list)
1977            (RecordTable.SetTable): Adapt to new table interface
1978    
1979            * Thuban/UI/classifier.py (Classifier.__init__)
1980            (Classifier.__init__): Adapt to new table interface
1981    
1982            * Thuban/UI/classgen.py (ClassGenDialog.__init__)
1983            (GenUniformPanel._OnRetrieve, GenUniquePanel._OnRetrieve): Adapt
1984            to new table interface
1985    
1986            * Thuban/Model/transientdb.py (TransientTableBase.HasColumn)
1987            (AutoTransientTable.HasColumn): Implement the new table interface
1988            method
1989            (AutoTransientTable.ReadRowAsDict, AutoTransientTable.ValueRange)
1990            (AutoTransientTable.UniqueValues): Adapt to new table interface
1991    
1992            * Thuban/Model/layer.py (Layer.SetShapeStore, Layer.GetFieldType):
1993            Adapt to new table interface
1994    
1995            * test/test_layer.py (TestLayer.open_shapefile): Helper method to
1996            simplify opening shapefiles a bit easier.
1997            (TestLayer.test_arc_layer, TestLayer.test_polygon_layer)
1998            (TestLayer.test_point_layer): Use the new helper method
1999            (TestLayer.test_get_field_type): New. Test for the GetFieldType
2000            method
2001    
2002            * test/test_dbf_table.py (TestDBFTable.test_has_column): Test for
2003            the new table method
2004    
2005            * test/test_memory_table.py (TestMemoryTable.test_has_column):
2006            Test for the new table method HasColumn
2007    
2008    2003-05-06  Jonathan Coles   <[email protected]>
2009    
2010            Addresses the "Selection Extent" wish of RTbug #1787.
2011    
2012            * Resources/Bitmaps/fulllayerextent.xpm,
2013            Resources/Bitmaps/fullselextent.xpm: Bitmaps for layer and selection
2014            extent. These are just place holders for the real bitmaps.
2015    
2016            * Thuban/Model/layer.py (Shape): Since a Shape is immutable only
2017            calculate the bounding box once (the first time compute_bbox() is
2018            called).
2019            (Layer.ShapesBoundingBox): New. Given a list of shape ids, return
2020            the bounding box for the shapes in lat/long coordinates.
2021    
2022            * Thuban/UI/mainwindow.py: Added new "Full selection extent" menu
2023            option.
2024            (MainWindow.has_selected_shapes): New. Returns true if there are
2025            any selected shapes.
2026            (MainWindow.FullSelectionExtent): New. Calls
2027            MapCanvas.FitSelectedToWindow() when the user selects the menu option.
2028            (_has_selected_shapes): New. Returns true if there are any
2029            selected shapes.
2030    
2031            * Thuban/UI/selection.py (Selection.HasSelectedShapes): New. Returns
2032            true if there are any selected shapes.
2033    
2034            * Thuban/UI/view.py (MapCanvas): Added delegated method
2035            HasSelectedShapes.
2036            (MapCanvas.FitSelectedToWindow): New. Centers and scales any selected
2037            shapes on the canvas using the map projection (if any).
2038    
2039            * test/test_layer.py (TestLayer.test_arc_layer): Add some tests
2040            for Layer.ShapesBoundingBox().
2041    
2042    2003-05-06  Bernhard Herzog  <[email protected]>
2043    
2044            * Resources/Projections/defaults.proj: Fix spelling of Mercator
2045    
2046    2003-05-05  Jonathan Coles   <[email protected]>
2047    
2048            Addresses the "Full Layer Extent" wish of RTbug #1787.
2049    
2050            * Resources/Projections/defaults.proj: Added UK National Grid.
2051    
2052            * Thuban/UI/mainwindow.py: Added new "Full layer extent" menu option.
2053            (MainWindow.FullLayerExtent): New. Calls MapCanvas.FitLayerToWindow()
2054            when the user selects the menu option.
2055    
2056            * Thuban/UI/view.py (MapCanvas.FitLayerToWindow): New. Centers and
2057            scales the given layer on the canvas using the map projection.
2058    
2059    2003-05-05  Bernhard Herzog  <[email protected]>
2060    
2061            Convert the table implementations to a new table interface. All
2062            tables use a common mixin class to provide backwards compatibility
2063            until all table users have been updated.
2064    
2065            * Thuban/Model/table.py (OldTableInterfaceMixin): Mixin class to
2066            provide backwards compatibility for table classes implementing the
2067            new interface
2068            (DBFTable, MemoryTable): Implement the new table interface. Use
2069            OldTableInterfaceMixin as base for compatibility
2070            (DBFColumn, MemoryColumn): New. Column description for DBFTable
2071            and MemoryTable resp.
2072    
2073            * test/test_dbf_table.py: New. Test cases for the DBFTable with
2074            the new table interface.
2075    
2076            * test/test_memory_table.py: New. Test cases for the MemoryTable
2077            with the new table interface.
2078    
2079            * test/test_table.py: Document the all tests in this file as only
2080            for backwards compatibility. The equivalent tests for the new
2081            interface are in test_memory_table.py and test_dbf_table.py
2082            (MemoryTableTest.test_read): field_info should be returning tuples
2083            with four items
2084            (MemoryTableTest.test_write): Make doc-string a more precise.
2085    
2086            * Thuban/Model/transientdb.py (TransientTableBase): Convert to new
2087            table interface. Derive from from OldTableInterfaceMixin for
2088            compatibility.
2089            (TransientTableBase.create): New intance variable column_map to
2090            map from names and indices to column objects
2091            (TransientTable.create): Use the new table interface of the input
2092            table
2093            (AutoTransientTable): Convert to new table interface. Derive from
2094            from OldTableInterfaceMixin for compatibility.
2095            (AutoTransientTable.write_record): Removed. It's not implemented
2096            yet and we still have to decide how to handle writing with the new
2097            table and data framework.
2098    
2099            * test/test_transientdb.py
2100            (TestTransientTable.run_iceland_political_tests)
2101            (TestTransientTable.test_transient_joined_table): Use the new
2102            table interface
2103    
2104    2003-05-05  Jonathan Coles   <[email protected]>
2105    
2106            This is namely a collection of UI updates to improve user interactivity.
2107            Tabbing between controls now exists and you can use ESC to close dialog
2108            boxes; ENTER will active the default button.
2109    
2110            * Thuban/UI/classgen.py (ClassGenDialog.__init__): Rearrange the
2111            order that the controls are created so that tabbing works correctly.
2112            (ClassGenDialog.OnOK): Renamed from _OnGenerate() so that the
2113            wxDialog can handle the default button correctly.
2114            (ClassGenDialog.OnCancel): Renamed from _OnCloseBtn() for the
2115            same reasons as for OnOK.
2116            (GenUniformPanel._OnRetrieve): Call wxBeginBusyCursor/wxEndBusyCursor
2117            when we ask the table for the maximum/minimum values of a field
2118            which could take a very long time.
2119    
2120            * Thuban/UI/classifier.py (Classifier.__init__): Rearrange the
2121            order that the controls are created so that tabbing works correctly.
2122            (SelectPropertiesDialog.__init__): Rearrange the order that the
2123            controls are created so that tabbing works correctly.
2124    
2125            * Thuban/UI/dialogs.py: Copied NonModalDialog box and changed it
2126            to derive from a wxDialog but behave like the original implementation
2127            which was derived from a wxFrame. wxDialog provides useful key
2128            handling functionality like ESC calling OnCancel and ENTER calling
2129            OnOK which is lost with wxFrame.
2130    
2131            * Thuban/UI/mainwindow.py: Add "..." to menu items that will open
2132            new dialogs.
2133    
2134            * Thuban/UI/projdialog.py (ProjFrame.__init__): Rearrange the
2135            order that the controls are created so that tabbing works correctly.
2136            (ProjFrame.OnApply): Renamed from _OnTry() to use wxDialog behaviour.
2137            (ProjFrame.OnOK): Renamed from _OnOK() to use wxDialog behaviour.
2138            (ProjFrame.OnCancel): Renamed from _OnClose() to use wxDialog behaviour.
2139            (ProjPanel.__init__): Add "Airy" to the list of ellipsoids so we
2140            can provide the "UK National Grid" as a default projection.
2141            (UTMPanel.__init__): Rearrange the order that the controls are
2142            created so that tabbing works correctly.
2143    
2144    2003-05-05  Bernhard Herzog  <[email protected]>
2145    
2146            * extensions/thuban/wxproj.cpp: Fix some of the comments.
2147            (project_point): If a map projection but no layer projection is
2148            given, convert degrees to radians before applying the map
2149            projection.
2150    
2151            * Thuban/UI/tableview.py (TableGrid.disallow_messages)
2152            (TableGrid.allow_messages): New methods to make it possible to
2153            inhibit message sending.
2154            (TableGrid.issue): Only send the message if not inhibited.
2155            (LayerTableGrid.select_shape): Use the new methods to make sure
2156            that no ROW_SELECTED message is sent while we're updating the
2157            selected rows to match the selected shapes.
2158    
2159    2003-05-02  Jan-Oliver Wagner <[email protected]>
2160    
2161            Implementation of MemoryTable.
2162    
2163            * Thuban/Model/table.py (MemoryTable): New. Quite simple table
2164            implementation that operates on a list of tuples. All of the data
2165            are kept in the memory.
2166    
2167            * test/test_table.py (MemoryTableTest): New.
2168    
2169            * test/test_transientdb.py (SimpleTable): Removed.
2170            (TestTransientTable.test_transient_joined_table,
2171            (TestTransientTable.test_transient_table_read_twice): Replaced
2172            SimpleTable by MemoryTable.
2173    
2174    2003-04-30  Jonathan Coles   <[email protected]>
2175    
2176            * Data/iceland_sample.thuban: Now contains correct projections
2177            for each of the layers.
2178    
2179            * Resources/Projections/defaults.proj: Geographic projection
2180            contains unit conversion parameter.
2181    
2182    2003-04-30  Jonathan Coles   <[email protected]>
2183    
2184            The most important part of this putback is the projection changes.
2185            It should now be possible to specify the projection that a layer
2186            is in and then specify a different projection for the map. The
2187            projection dialog has an extra parameter for a geographic projection
2188            which lets the user select if the input is in degrees or radians.
2189    
2190            * Thuban/Model/layer.py (Layer.ShapesInRegion): Fix docstring
2191            to say that the parameter is a tuple of unprojected
2192            points (which is what the callers to this method were assuming).
2193            Also, since the points are unprojected we need to projected them.
2194    
2195            * Thuban/UI/legend.py (LegendTree.MoveCurrentItemUp,
2196            LegendTree.MoveCurrentItemDown): If the layer or any of the layer's
2197            groups are selected, move the layer up/down. Fixes RTbug #1833.
2198    
2199            * Thuban/UI/mainwindow.py: Move menu item map_rename up.
2200    
2201            * Thuban/UI/projdialog.py (ProjFrame._OnSave): Add missing
2202            parameter in call to SetClientData.
2203            (GeoPanel): Add support for selecting the units that the
2204            source data is in (Radians or Degrees).
2205    
2206            * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Optimize
2207            the rendering loop by reducing the number of if's, removing the
2208            unnecessary try/except block, and checking if the old group
2209            is the same as the new one (which happens a lot if there is
2210            no classification, or lots of shapes are in the same group).
2211    
2212            * Thuban/UI/view.py (MapCanvas.OnPaint): Add a try/except block
2213            around the redraw routine to try to catch problems that the user
2214            may create by selecting invalid projections for the data set and
2215            map. Clears the display if there are any problems and prints the
2216            error.
2217            (MapCanvas.do_redraw): Use DC.Clear() instead of drawing a filled
2218            rectangle.
2219    
2220            * extensions/thuban/wxproj.cpp (project_point): First invert the
2221            supplied point (which should be in projected coordinates) using
2222            the layer's projection and then project the point using the
2223            map's projection.
2224            (project_points): Use project_point() to project each point.
2225    
2226    2003-04-30  Jan-Oliver Wagner <[email protected]>
2227    
2228            * Thuban/Model/layer.py (Layer.SetShapeStore): Fixed a bug:
2229            don't set the Classification to None if the classfication field
2230            is None (ie only a DEFAULT).
2231    
2232    2003-04-30  Bernhard Herzog  <[email protected]>
2233    
2234            * Thuban/UI/view.py: Fix some typos.
2235    
2236            * Thuban/UI/mainwindow.py (MainWindow.identify_view_on_demand): Do
2237            not pop up the dialog if the selection becomes empty (this could
2238            happen if e.g. a new selection is opened while the identify tool
2239            is active and dialog had been closed)
2240    
2241    2003-04-30  Bernhard Herzog  <[email protected]>
2242    
2243            * Thuban/Model/transientdb.py (TransientTableBase.__init__): New
2244            instance variable read_record_last_result
2245            (TransientTableBase.read_record): Make sure reading the same
2246            record twice works. The implementation uses the new instance
2247            variable read_record_last_result
2248    
2249            * test/test_transientdb.py
2250            (TestTransientTable.test_transient_table_read_twice): New test
2251            case for the above bug-fix.
2252    
2253    2003-04-29  Jonathan Coles   <[email protected]>
2254    
2255            * Thuban/common.py: Removed. No longer needed Str2Num. RTbug #1832.
2256    
2257            * Thuban/UI/classgen.py: Remove all uses of Str2Num.
2258    
2259            * Thuban/UI/classifier.py: Remove all uses of Str2Num.
2260            (ClassTable.SetValueAsCustom): Rename keyword argument in
2261            ClassGroup* constructors to match argument name.
2262    
2263    2003-04-29  Bernhard Herzog  <[email protected]>
2264    
2265            * Thuban/Model/session.py (Session.Destroy): Explicitly close the
2266            transient DB if it exists to make sure it doesn't leave a journal
2267            file in the temp directory.
2268    
2269            * Thuban/Model/transientdb.py (TransientDatabase.close): Set
2270            self.conn to None after closing the connection to make sure it's
2271            not closed twice
2272    
2273    2003-04-29  Jonathan Coles   <[email protected]>
2274    
2275            Add a visible parameter in the layer XML tag. The default value is
2276            "true". If anything other than "false" is specified we also assume
2277            "true". Addresses RTbug #1025.
2278    
2279            * Doc/thuban.dtd: Add visible parameter to a layer.
2280    
2281            * Thuban/Model/layer.py (BaseLayer.__init__): Change default value
2282            of visible from 1 to True.
2283            (Layer.__init__): Change default value of visible from 1 to True.
2284    
2285            * Thuban/Model/load.py (SessionLoader.start_layer): Read visible
2286            parameter.
2287    
2288            * Thuban/Model/save.py (SessionSaver.write_layer): Save visible
2289            parameter.
2290    
2291            * test/test_load.py: Add new test data contents_test_visible.
2292            (LoadSessionTest.setUp): save test data.
2293            (LoadSessionTest.testLayerVisibility): Test if the visible flag
2294            is loaded correctly.
2295    
2296            * test/test_save.py (SaveSessionTest.testSingleLayer): Add test
2297            for saving an invisible layer.
2298    
2299    2003-04-29  Jonathan Coles   <[email protected]>
2300    
2301            * Thuban/UI/mainwindow.py (MainWindow.SetMap): Look up the
2302            legend dialog box and tell it to change its map to the one
2303            supplied to SetMap(). Fixes RTbug #1770.
2304    
2305    2003-04-29  Bernhard Herzog  <[email protected]>
2306    
2307            Next step of table implementation. Introduce a transient database
2308            using SQLite that some of the data is copied to on demand. This
2309            allows us to do joins and other operations that require an index
2310            for good performance with reasonable efficiency. Thuban now needs
2311            SQLite 2.8.0 and pysqlite 0.4.1. Older versions may work but I
2312            haven't tested that.
2313            
2314            * Thuban/Model/transientdb.py: New. Transient database
2315            implementation.
2316    
2317            * test/test_transientdb.py: New. Tests for the transient DB
2318            classes.
2319    
2320            * Thuban/Model/session.py (AutoRemoveFile, AutoRemoveDir): New
2321            classes to help automatically remove temporary files and
2322            directories.
2323            (Session.__init__): New instance variables temp_dir for the
2324            temporary directory and transient_db for the SQLite database
2325            (Session.temp_directory): New. Create a temporary directory if not
2326            yet done and return its name. Use AutoRemoveDir to have it
2327            automatically deleted
2328            (Session.TransientDB): Instantiate the transient database if not
2329            done yet and return it.
2330    
2331            * Thuban/Model/data.py (ShapefileStore.__init__): Use an
2332            AutoTransientTable so that data is copied to the transient DB on
2333            demand.
2334            (SimpleStore): New class that simply combines a table and a
2335            shapefile
2336    
2337            * Thuban/Model/table.py (Table, DBFTable): Rename Table into
2338            DBFTable and update its doc-string to reflect the fact that this
2339            is only the table interface to a DBF file. Table is now an alias
2340            for DBFTable for temporary backwards compatibility.
2341    
2342            * Thuban/UI/application.py (ThubanApplication.OnExit): Make sure
2343            the last reference to the session goes away so that the temporary
2344            files are removed properly.
2345    
2346            * test/test_load.py (LoadSessionTest.tearDown): Remove the
2347            reference to the session to make sure the temporary files are
2348            removed.
2349    
2350    2003-04-29  Bernhard Herzog  <[email protected]>
2351    
2352            * Thuban/Model/load.py (XMLReader.__init__, XMLReader.read): Turn
2353            the __parser instance variable into a normal local variable in
2354            read. It's only used there and read will never be called more than
2355            once. Plus it introduces a reference cycle that keeps can keep the
2356            session object alive for a long time.
2357    
2358    2003-04-29  Jonathan Coles   <[email protected]>
2359    
2360            * Thuban/Model/proj.py (Projection): Removed Set*() methods to make
2361            Projection an immutable item. Fixes RTbug #1825.
2362            (Projection.__init__): Initialize instance variables here.
2363            (ProjFile.Replace): New. Replace the given projection object with
2364            the new projection object. This solves the problem of needing the
2365            mutator Projection.SetProjection() in the ProjFrame class and
2366            allows a projection to change parameters without changing its
2367            location in the file.
2368    
2369            * Thuban/UI/mainwindow.py (MainWindow.SaveSessionAs): Dialog should
2370            be of type wxSAVE and should verify overwriting a file.
2371    
2372            * Thuban/UI/projdialog.py (ProjFrame._OnSave): Use the new
2373            ProjFile.Replace() method instead of the mutator
2374            Projection.SetProjection(). Also requires that we reassign the
2375            client data to the new projection.
2376    
2377            * test/test_proj.py (TestProjection.test): Test GetName() and
2378            GetAllParameters()
2379            (TestProjFile.test): Remove tests for Set*() methods. Add tests
2380            for Replace().
2381    
2382    2003-04-25  Jonathan Coles   <[email protected]>
2383    
2384            * Thuban/Model/save.py (SessionSaver.write_projection): Make sure
2385            to save the name of the projection.
2386    
2387            * test/test_save.py (SaveSessionTest.testLayerProjection): New
2388            test to verify layer projections are saved correctly.
2389    
2390    2003-04-25  Jonathan Coles   <[email protected]>
2391    
2392            * Thuban/Model/proj.py (Projection.SetName): Set the name
2393            to "Unknown" if name is None.
2394            (Projection.SetAllParameters): New. Set the projection's
2395            parameter list to the one supplied.
2396            (Projection.SetProjection): New. Set the projection's
2397            properties to those of the supplied Projection.
2398    
2399            * Thuban/UI/mainwindow.py (MainWindow.MapProjection): Set
2400            the dialog title to include the map's title.
2401            (MainWindow.LayerProjection): Set the dialog title to include
2402            the layer's title.
2403    
2404            * Thuban/UI/projdialog.py (ProjFrame.__ShowError): Consolidate
2405            error dialogs into a single method call.
2406            (ProjFrame.__VerifyButtons): Add more states to check.
2407            (ProjFrame.__GetProjection): Return the current state of an
2408            edited projection or None.
2409            (ProjFrame.__FillAvailList): Remove checks for states that
2410            shouldn't exist.
2411            (ProjFrame._OnNew): Clear all selected items and supply
2412            a projection panel if necessary.
2413    
2414            * test/test_proj.py (TestProjFile.test): Add tests for
2415            ProjFile.SetAllParameters, ProjFile.SetProjection,
2416            ProjFile.SetName.
2417    
2418    2003-04-25  Jonathan Coles   <[email protected]>
2419    
2420            * Thuban/UI/projdialog.py (ProjFrame.__FillAvailList): Now
2421            takes an optional argument to select the current projection.
2422            This does not guarantee that the item is visible due to
2423            limited wxWindows functionality. Fixes RTBug #1821.
2424    
2425    2003-04-25  Jonathan Coles   <[email protected]>
2426    
2427            * Thuban/Model/load.py (SessionLoader.start_projection): Remember
2428            the projection name and use it when constructing the Projection
2429            object.
2430    
2431            * Thuban/Model/proj.py (Projection.__init__): Change the default
2432            value for 'name' to None and then test if name is equal to None
2433            in the body of the constructor. This way the caller doesn't have to
2434            know what the default value should be. Namely, useful in load.py
2435            where we have to pick a default value if the 'name' parameter
2436            doesn't exist in the XML file.
2437    
2438            * test/test_load.py (LoadSessionTest.testLayerProjection): New.
2439            Tests a file where a layer has a projection.
2440    
2441    2003-04-25  Jonathan Coles   <[email protected]>
2442    
2443            * Thuban/Model/layer.py (Layer.TreeInfo): Add an item to the
2444            tree for projection information.
2445    
2446            * Thuban/Model/load.py (XMLReader.GetFilename): Renamed from
2447            XMLReader.GetFileName.
2448            (SessionLoader): Added support for loading projection tags that
2449            appear inside a layer.
2450    
2451            * Thuban/Model/proj.py (ProjFile): Document the class. Move
2452            back to using a list because the order of the projections in
2453            the file is important to maintain. Fixes RTbug #1817.
2454    
2455            * Thuban/Model/resource.py: Rename calls to ProjFile.GetFileName
2456            to ProjFile.GetFilename.
2457    
2458            * Thuban/Model/save.py (SessionSaver.write_layer): Save projection
2459            information.
2460    
2461            * Thuban/UI/projdialog.py (ProjFrame._OnAddToList): Renamed from
2462            ProjFrame._OnSaveAs. Removed old dead code from previous
2463            implementation.
2464            (ProjFrame._OnExport): Add support for exporting more than one
2465            projection to a single file.
2466            (ProjFrame.__FillAvailList): use string formatting (% operator)
2467            to build strings that are (partly) translated. Fixes RTbug #1818.
2468    
2469            * test/test_proj.py (TestProjFile.test): New. Tests the base ProjFile
2470            class.
2471    
2472    2003-04-24  Bernhard Herzog  <[email protected]>
2473    
2474            * po/es.po: Updated Spanish translation by Daniel Calvelo Aros
2475    
2476            * po/fr.po: New. French translation by Daniel Calvelo Aros
2477    
2478            * Thuban/UI/projdialog.py (ProjFrame._OnSaveAs): Don't translate
2479            empty strings.
2480    
2481    2003-04-24  Jonathan Coles   <[email protected]>
2482    
2483            * Thuban/Model/layer.py (Layer.GetProjection): New. Needed to
2484            implement the interface that the ProjFrame dialog expects.
2485    
2486            * Thuban/Model/proj.py (Projection.SetName): New. Allows the
2487            name of the projection to be changed.
2488            (ProjFile): Use a dictionary instead of a list so that removing
2489            projections is easier and we are sure about uniqueness.
2490            (ProjFile.Remove): Remove the given projection object.
2491    
2492            * Thuban/Model/resource.py (GetSystemProjFiles, GetUserProjFiles):
2493            Return a list with only one projection file instead of searching for
2494            any projection file. This simplifies many things if the user can
2495            only have one system file and one user file.
2496    
2497            * Thuban/UI/classgen.py: Change all references to
2498            genCombo to genChoice.
2499    
2500            * Thuban/UI/mainwindow.py: Add a Projection option under the
2501            layer menu.
2502            (MainWindow.LayerProjection): New. Open up a projection window
2503            for a layer.
2504    
2505            * Thuban/UI/projdialog.py: Large changes to how the dialog is
2506            laid out. Use three panels instead of one. One for the list of
2507            projections, one for the edit controls, and one for the buttons.
2508            Fixed resizing problems so that the dialog resizes correctly
2509            when the projection panel changes. Added import/export, save, and
2510            new buttons/functionality.
2511    
2512    2003-04-24  Bernhard Herzog  <[email protected]>
2513    
2514            First step towards table management. Introduce a simple data
2515            abstraction so that we replace the data a layer uses more easily
2516            in the next step.
2517    
2518            * Thuban/Model/data.py: New file with a simple data abstraction
2519            that bundles shapefile and dbffile into one object.
2520    
2521            * Thuban/Model/session.py (Session.OpenShapefile): New method to
2522            open shapefiles and return a shape store object
2523    
2524            * Thuban/Model/layer.py (Layer.__init__): Pass the data as a store
2525            object instead of a shapefile filename. This introduces a new
2526            instance variable store holding the datastore. For intermediate
2527            backwards compatibility keep the old instance variables.
2528            (open_shapefile): Removed. No longer needed with the shape store.
2529            (Layer.SetShapeStore, Layer.ShapeStore): New methods to set and
2530            get the shape store used by a layer.
2531            (Layer.Destroy): No need to explicitly destroy the shapefile or
2532            table anymore.
2533    
2534            * Thuban/UI/mainwindow.py (MainWindow.AddLayer)
2535            (MainWindow.AddLayer): Use the session's OpenShapefile method to
2536            open shapefiles
2537    
2538            * Thuban/Model/load.py (ProcessSession.start_layer): Use the
2539            session's OpenShapefile method to open shapefiles
2540    
2541            * test/test_classification.py
2542            (TestClassification.test_classification): Use the session's
2543            OpenShapefile method to open shapefiles and build the filename in
2544            a more platform independed way
2545    
2546            * test/test_layer.py (TestLayer.setUp, TestLayer.tearDown):
2547            Implement to have a session to use in the tests
2548            (TestLayer.test_arc_layer, TestLayer.test_polygon_layer)
2549            (TestLayer.test_point_layer, TestLayer.test_empty_layer): Use the
2550            session's OpenShapefile method to open shapefiles
2551            (TestLayerLegend.setUp): Instantiate a session so that we can use
2552            it to open shapefiles.
2553            (TestLayerLegend.tearDown): Make sure that all references to
2554            layers and session are removed otherwise we may get a resource
2555            leak
2556    
2557            * test/test_map.py (TestMapAddLayer.test_add_layer)
2558            (TestMapWithContents.setUp): Instantiate a session so that we can
2559            use it to open shapefiles.
2560            (TestMapWithContents.tearDown): Make sure that all references to
2561            layers, maps and sessions are removed otherwise we may get a
2562            resource leak
2563            ("__main__"): use support.run_tests() so that more info about
2564            uncollected garbage is printed
2565    
2566            * test/test_save.py (SaveSessionTest.testSingleLayer): Use the
2567            session's OpenShapefile method to open shapefiles
2568            ("__main__"): use support.run_tests() so that more info about
2569            uncollected garbage is printed
2570    
2571            * test/test_selection.py (TestSelection.tearDown): Make sure that
2572            all references to the session and the selection are removed
2573            otherwise we may get a resource leak
2574            (TestSelection.get_layer): Instantiate a session so that we can
2575            use it to open shapefiles.
2576            ("__main__"): use support.run_tests() so that more info about
2577            uncollected garbage is printed
2578    
2579            * test/test_session.py (TestSessionBase.tearDown)
2580            (TestSessionWithContent.tearDown): Make sure that all references
2581            to the session and layers are removed otherwise we may get a
2582            resource leak
2583            (TestSessionWithContent.setUp): Use the session's OpenShapefile
2584            method to open shapefiles
2585    
2586    2003-04-24  Jonathan Coles   <[email protected]>
2587    
2588            * Thuban/Model/load.py (XMLReader.read): Should have been checking
2589            if the file_or_filename object had the 'read' attribute.
2590    
2591    2003-04-23  Jonathan Coles   <[email protected]>
2592    
2593            * Thuban/Model/resource.py: Fixes RTbug #1813.
2594            (ReadProjFile): Add documentation about which exceptions are raised.
2595            Always pass the exceptions up to the caller.
2596            (GetProjFiles): If the directory can't be read return an empty list.
2597            If any of the proj files can't be read skip that file and go
2598            on to the next one.
2599    
2600            * test/test_proj.py: Added test cases to handle nonexistent files,
2601            unreadable files, and files that don't parse correctly.
2602    
2603    2003-04-23  Jonathan Coles   <[email protected]>
2604    
2605            Projection dialog. Allows the user to select from a list
2606            of projection templates and optionally edit them and save new ones.
2607    
2608            * Thuban/UI/projdialog.py (ProjFrame): New. Main dialog.
2609            (ProjPanel): Base class for projection specific panels.
2610            (TMPanel): Projection panel for Transverse Mercartor.
2611            (UTMPanel): Projection panel for Universal Transverse Mercartor.
2612            (LCCPanel): Projection panel for Lambert Conic Conformal.
2613            (GeoPanel): Projetion panel for Geographic Projection.
2614    
2615    2003-04-23  Jonathan Coles   <[email protected]>
2616    
2617            * Thuban/Model/load.py (XMLReader): Renamed from XMLProcessor to
2618            promote symmetry. There now exists XMLReader and XMLWriter.
2619            (XMLReader.read): New. Call to read the given file descriptor or
2620            filename.
2621            (XMLReader.close): New. Make sure the file is closed.
2622            (XMLReader.GetFileName): New. Return just the file name that is being
2623            read from.
2624            (XMLReader.GetDirectory): New. Return just the directory of the file
2625            that is being read.
2626            (XMLReader.AddDispatchers): New. Take a dictionary which contains
2627            the names of functions to call as the XML tree is parsed.
2628            (XMLReader.startElementNS): Updated to use new dispatcher dictionary.
2629            (XMLReader.endElementNS): Updated to use new dispatcher dictionary.
2630            (SessionLoader): Removed class variables start_dispatcher and
2631            end_dispatcher since this functionality is now part of a class
2632            instance. Fixes RTbug #1808.
2633            (SessionLoader.__init__): Add dispatcher functions.
2634            (load_xmlfile): Code was moved into the XMLReader.read().
2635            (load_session): Use modified SessionLoader.
2636    
2637            * Thuban/Model/map.py (Map.GetProjection): New. Returns the
2638            map's projection.
2639    
2640            * Thuban/Model/proj.py (Projection.GetParameters): Renamed to
2641            GetAllParameters.
2642            (Projection.GetParameter): Returns the value for the given parameter.
2643    
2644            * Thuban/Model/resource.py: Use XMLReader and XMLWriter.
2645            (GetProjFiles): Renamed from GetProjections. Now returns a list
2646            of ProjFile objects.
2647            (GetSystemProjFiles): Renamed from GetSuppliedProjections. Returns
2648            a list of ProjFile objects whose files are not user defined.
2649            (GetUserProjFiles): Renamed from GetUserProjections. Returns a
2650            list of ProjFile objects whose files are user defined.
2651            (ProjFileReader): Extend new XMLReader.
2652    
2653            * Thuban/Model/save.py (XMLWriter): Renamed from XMLSaver to
2654            promote symmetry.
2655    
2656            * Thuban/UI/classgen.py (ClassGenDialog.__init__): Use a wxChoice
2657            control instead of a wxComboBox. wxChoice controls do not generate
2658            events as the uses highlights possible choices which fixes problems
2659            with resizing the dialog when the use selects an option.
2660    
2661            * Thuban/UI/classifier.py (Classifier.__init__): Use a wxChoice
2662            control instead of a wxComboBox.
2663    
2664            * Thuban/UI/mainwindow.py (MainWindow.Projection): Use new projection
2665            dialog.
2666    
2667            * test/test_proj.py (TestProjection.test): New tests for GetParameter
2668            method.
2669    
2670    2003-04-22  Bernhard Herzog  <[email protected]>
2671    
2672            * Thuban/UI/mainwindow.py: Remove some unused imports and global
2673            constants
2674    
2675            * Thuban/UI/identifyview.py (IdentifyListCtrl.selected_shape)
2676            (IdentifyGridCtrl.selected_shape): Use table, not shapetable.
2677    
2678    2003-04-17  Bernhard Herzog  <[email protected]>
2679    
2680            * Thuban/Model/layer.py: Don't import LAYER_LEGEND_CHANGED.
2681            (Layer): Update doc-string since LAYER_LEGEND_CHANGED is not used
2682            anymore.
2683            (Layer.BoundingBox, Layer.GetFieldType, Layer.NumShapes)
2684            (Layer.ShapeType, Layer.Shape): No need to call
2685            self.open_shapefile since it's always called in __init__
2686    
2687            * Thuban/UI/application.py (ThubanApplication.MainLoop): Removed.
2688            In wxPython 2.4 there's no need to extend MainLoop anymore since
2689            wxPython itself makes sure OnExit is called.
2690    
2691    2003-04-16  Jonathan Coles   <[email protected]>
2692    
2693            Initial putback of projection management code. Includes new
2694            classes to read and write projection files. The current load
2695            and save classes were abstracted a bit so they could be reused.
2696            The Projection class was extended to provide new methods and
2697            have a name.
2698    
2699            * Thuban/Model/load.py (XMLProcessor): New. Contains all the
2700            general XML reading methods that were part of ProcessSession.
2701    
2702            * Thuban/Model/proj.py (Projection.__init__): Accepts an optional
2703            name.
2704            (ProjFile): New. Represents a file that contains projection
2705            information.
2706    
2707            * Thuban/Model/resource.py: New. Contains general utilities
2708            for read and writing projection files.
2709    
2710            * Thuban/Model/save.py (XMLSaver): New. Contains all the
2711            general XML writing methods that were part of SessionSaver.
2712            (SessionSaver): Renamed from Saver.
2713    
2714            * test/test_proj.py: New test cases for the projection
2715            file read and write functions.
2716    
2717    2003-04-16  Jonathan Coles   <[email protected]>
2718    
2719            * Thuban/Model/classification.py: Use repr() around values
2720            in the ClassGroup*.__repr__() methods so it is clearer when
2721            a value is a string and when it is a number.
2722    
2723            * test/test_load.py: Rework the classification test to test
2724            that we can load old files.
2725            (testLabels): Test a file where the groups have labels.
2726    
2727    2003-04-16  Bernhard Herzog  <[email protected]>
2728    
2729            Safer implementation of the performance enhancements of the
2730            low-level renderer:
2731            
2732            * extensions/thuban/wxproj.cpp (extract_projection)
2733            (extract_pointer): Rename extract_projection to extract_pointer
2734            and redefine its purpose to return the pointer stored in a CObject
2735            returned by the object's cobject method. Update all callers.
2736            (s_draw_info, free_draw_info, draw_polygon_init): Implement the
2737            handling of these low-level parameters so that each s_draw_info
2738            instance is handled as a CObject at python level that also
2739            contains real references to the actual python objects which
2740            contain the values in the struct. Add free_draw_info as the
2741            destructor.
2742            (draw_polygon_shape): Add the py_draw_info parameter which must a
2743            cobject containing an s_draw_info pointer.
2744    
2745            * Thuban/UI/renderer.py (MapRenderer.polygon_render_param): New
2746            method to instantiat the low-level render parameter
2747            (MapRenderer.draw_shape_layer): Use the new method. Remove some
2748            commented out code.
2749            (MapRenderer.draw_polygon_shape): Make the first parameter not the
2750            layer but the low-level render parameter
2751            (ScreenRenderer.draw_shape_layer): Use the low-level render
2752            parameter.
2753    
2754    2003-04-15  Jonathan Coles   <[email protected]>
2755    
2756            * Thuban/Model/classification.py: Implemented __repr__ for
2757            the ClassGroup* classes to make debugging a bit easier.
2758            (ClassGroup.SetLabel): Check that the string is an instance
2759            of StringTypes not StringType. Accounts for Unicode strings.
2760    
2761            * Thuban/Model/color.py: Implemented __repr__ to make
2762            debugging a bit easier.
2763    
2764            * Thuban/Model/save.py (Saver.write_classification): Need to
2765            save the group label.
2766    
2767            * test/test_load.py (testClassification): New. Loads the
2768            iceland_sample_test.thuban file and checks if it was loaded
2769            correctly.
2770    
2771    2003-04-15  Jonathan Coles   <[email protected]>
2772    
2773            * extensions/thuban/wxproj.cpp (draw_polygon_init): New. Used
2774            to improve rendering performance by initializing the variables
2775            that are not change each time draw_polygon_shape() is called.
2776            The values are stored in a global struct draw_info.
2777            (draw_polygon_shape): Removed initialization code that is
2778            now in draw_polygon_init().
2779    
2780            * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Make
2781            drawing initialization call to draw_polygon_init()
2782            (MapRenderer.draw_polygon_shape): Use new signature of
2783            draw_polygon_shape.
2784    
2785            * Thuban/UI/classgen.py (GenUniformPanel): Fix spin control
2786            weirdness by setting the range to (1, maxint).
2787    
2788            * Thuban/Model/classification.py (ClassGroupProperties): Make
2789            instance variables private and optimize comparison operator
2790            by first checking if the color references are the same.
2791            (ClassGroupSingleton): Make instance variables private.
2792            (ClassGroupRange): Make instance variables private.
2793    
2794            * HOWTO-Release: Filled in missing steps for releasing packages.
2795    
2796    2003-04-15  Bernhard Herzog  <[email protected]>
2797    
2798            First stab at internationalized messages:
2799    
2800            * Thuban/__init__.py (_): Implement the translation function for
2801            real using the python gettext module.
2802    
2803            * Thuban/UI/classifier.py (ClassTable.GetRowLabelValue): Don't
2804            translate empty strings.
2805    
2806            * Thuban/UI/application.py (ThubanApplication.read_startup_files):
2807            Add a missing space to a warning message
2808    
2809            * po/README: New. Notes about the management of the translation
2810            files.
2811    
2812            * po/Makefile: New. Makefile to help manage the translation files.
2813    
2814            * po/es.po: New. Spanish translation by Daniel Calvelo Aros
2815    
2816            * MANIFEST.in: Include the *.mo files in Resources/Locale and the
2817            translations and support files in po/
2818    
2819            * setup.py (data_files): Add the *.mo files to the data_files too
2820    
2821            * README: Add note about the translations when building from CVS
2822    
2823    2003-04-14  Jonathan Coles   <[email protected]>
2824    
2825            * Thuban/UI/dock.py: Fixes some window resizing problems most
2826            noticable under windows. Always assume the button bitmaps will
2827            be there. Code clean up.
2828            (DockabelWindow.Dock, DockableWindow.UnDock): Force all the
2829            images for the dock/undock button to the same images.
2830            Work around for RTbug #1801.
2831    
2832            * Thuban/UI/legend.py (LegendPanel.__init__): The toolbar should
2833            be allowed to grow within the sizer. Fixes a bug under Windows
2834            where the toolbar wasn't being drawn.
2835    
2836    2003-04-14  Frank Koormann   <[email protected]>
2837    
2838            * Resources/Bitmaps/dock_12.xpm, Resources/Bitmaps/undock_12.xpm:
2839            Updated design to try to make the button functionality more
2840            transparent.
2841    
2842    2003-04-14  Jonathan Coles   <[email protected]>
2843    
2844            * Thuban/UI/legend.py (LegendPanel.__init__): Call Create() to
2845            finalize the intialization of the panel.
2846    
2847            * Thuban/UI/dock.py (DockPanel.Create): New. Finalizes the
2848            creation of the panel. Should be the last thing called in the
2849            initializer of a subclass.
2850    
2851            * Thuban/UI/classgen.py (ClassGenDialog.__init__): Actively
2852            set the current selections in the combo boxes. This is needed
2853            under Windows.
2854    
2855            * Thuban/UI/classifier.py (Classifier.__init__): Add a top
2856            level panel to the dialog so that the background colors are
2857            consistent under Windows.
2858    
2859    2003-04-11  Jonathan Coles   <[email protected]>
2860    
2861            * Thuban/UI/classgen.py: Change color ramps to start at white
2862            not black.
2863    
2864            * Thuban/UI/legend.py: Enable/disable the legend buttons when
2865            the legend changes. Fixes RTbug #1793.
2866    
2867            * test/test_classification.py: Added test for copying of
2868            classifications.
2869    
2870    2003-04-11  Jonathan Coles   <[email protected]>
2871    
2872            * Thuban/UI/resource.py: New. Centralize the loading of resources
2873            such as bitmaps.
2874    
2875            * Thuban/UI/classgen.py (GenUniquePanel.__init__): Reordered buttons,
2876            added images to the move buttons, added 'reverse' button.
2877            (CustomRampPanel.__init__): Added images to the move buttons.
2878            (GreyRamp): New. Generates a ramp from white to black.
2879            (HotToColdRamp): New. Generates a ramp from cold to hot colors.
2880    
2881            * Thuban/UI/classifier.py: Refactored ID's from ID_CLASSIFY_* to
2882            ID_PROPERTY_*.
2883            (Classifier.__init__): Minor changes to the layout.
2884            (Classifier._OnTitleChanged): Listen for when the user edits the
2885            title and update the dialog's title and the layer's title.
2886    
2887            * Thuban/UI/dock.py: Use new bitmaps for the control buttons.
2888    
2889            * Thuban/UI/legend.py: Use new bitmaps for the control buttons.
2890            (LegendTree._OnMsgLayerTitleChanged): Change the displayed title
2891            if the layer's title changes.
2892    
2893            * Thuban/UI/mainwindow.py: Added new menu item and associated code
2894            to open a dialog to rename the map.
2895            (MainWindow): Use new resource class to import bitmaps.
2896    
2897    2003-04-11  Jonathan Coles   <[email protected]>
2898    
2899            * Resources/Bitmaps/close_12.xpm, Resources/Bitmaps/dock_12.xpm,
2900            Resources/Bitmaps/group_use.xpm, Resources/Bitmaps/group_use_all.xpm,
2901            Resources/Bitmaps/group_use_none.xpm,
2902            Resources/Bitmaps/group_use_not.xpm,
2903            Resources/Bitmaps/hide_layer.xpm,
2904            Resources/Bitmaps/layer_properties.xpm,
2905            Resources/Bitmaps/lower_layer.xpm, Resources/Bitmaps/raise_layer.xpm,
2906            Resources/Bitmaps/show_layer.xpm, Resources/Bitmaps/undock_12.xpm:
2907            New.
2908    
2909    2003-04-10  Jonathan Coles   <[email protected]>
2910    
2911            * Thuban/Model/classification.py: (ClassGroupRange.__init__):
2912            Should pass group to ClassGroup constructor.
2913    
2914    2003-04-10  Jonathan Coles   <[email protected]>
2915    
2916            * Thuban/Model/classification.py: (ClassGroup): Move all the common
2917            methods of the derived classes ([Set|Get]Properties(), __eq__, __ne__)
2918            here. Implement SetVisible(), IsVisible().
2919            (ClassGroup.__init__): Add group parameter which acts as a copy
2920            constructor.
2921    
2922            * Thuban/UI/classifier.py (ClassTable): Add a new column for the
2923            "Visible" check boxes.
2924            (Classifier): Rename the buttons and refactor the code to match
2925            the new labels.
2926    
2927            * Thuban/UI/legend.py: Classify button is now called "Properties".
2928            Refactored the code to change variable names.
2929            (LegendTree.__FillTreeLayer): Only list a group if it is visible.
2930    
2931            * Thuban/UI/mainwindow.py: MainWindow.OpenClassifier renamed to
2932            MainWindow.OpenLayerProperties. MainWindow.LayerEditProperties
2933            renamed to MainWindow.LayerEditProperties.
2934            (MainWindow.ToggleLegend): Don't include map name in legend title.
2935            (MainWindow.SetMap): Added the map name to the window title.
2936            (MainWindow.LayerFillColor, MainWindow.LayerTransparentFill,
2937            MainWindow.LayerOutlineColor, MainWindow.LayerNoOutline): Removed.
2938            Functionality is found in the layer properties dialog.
2939    
2940            * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Only
2941            draw visible groups.
2942    
2943    2003-04-09  Jonathan Coles   <[email protected]>
2944    
2945            * Thuban/UI/classgen.py: Modifications to allow simple
2946            addition and selection of new color schemes.
2947            (MonochromaticRamp): New. Generates a ramp between two colors.
2948            (RedRamp): New. Generates a ramp of all red.
2949            (GreenRamp): New. Generates a ramp of all green.
2950            (BlueRamp): New. Generates a ramp of all blue.
2951    
2952    2003-04-09  Jonathan Coles   <[email protected]>
2953    
2954            * Thuban/Model/classification.py (Classification.__deepcopy__):
2955            Need to copy over field and fieldType attributes.
2956    
2957            * Thuban/Model/table.py (Table.field_range): New. Retrive the
2958            maximum and minimum values over the entire table for a given
2959            field.
2960            (Table.GetUniqueValues): New. Retrieve all the unique values
2961            in the table for a given field.
2962    
2963            * Thuban/UI/classgen.py: Renamed GenRangePanel to GenUniformPanel.
2964            (GenUniquePanel): New. Controls to allow the user to select
2965            which unique field values they would like in the classification.
2966            (CustomRampPanel): Code that was in ClassGenDialog that allows
2967            the user to select the properties for a custom ramp.
2968            (ClassGenerator.GenUniformDistribution): Was called GenerateRanges.
2969    
2970            * Thuban/UI/classifier.py: Removed a lot of debugging code.
2971            (Classifier._SetClassification): Callback method so that the
2972            class generator can set the classification in the grid.
2973            (ClassGroupPropertiesCtrl): New. Encapsulates the drawing and
2974            editing of a group properties class into a wxWindows control.
2975    
2976            * Thuban/UI/dock.py: It was decided that if the user closes
2977            a dockable window the window should simply hide itself. That
2978            way if the user wants to show the dock again it appears in the
2979            same place as it was when it was closed.
2980            (DockableWindow.Destroy): Call renamed method OnDockDestroy().
2981            (DockableWindow._OnButtonClose): Hide the window instead of
2982            destroying it.
2983            (DockableWindow._OnClose): Hide the window instead of
2984            destroying it.
2985    
2986            * Thuban/UI/legend.py (LegendTree): Use a private method to
2987            consistently set the font and style of the text. Fixes RTbug #1786.
2988    
2989            * Thuban/UI/mainwindow.py: Import just the Classifier class.
2990    
2991    2003-04-07  Bernhard Herzog  <[email protected]>
2992    
2993            * Thuban/UI/mainwindow.py (main_menu): Move the toggle_legend item
2994            to the map module
2995    
2996    2003-04-07  Bernhard Herzog  <[email protected]>
2997    
2998            * Thuban/UI/mainwindow.py (MainWindow.ShowSessionTree): Removed in
2999            favor of ToggleSessionTree
3000            (MainWindow.ToggleSessionTree): New method to toggle visibility of
3001            the session tree.
3002            (MainWindow.SessionTreeShown): New method to return whether the
3003            session tree is currently shown.
3004            (MainWindow.ToggleLegend): New method to toggle visibility of the
3005            legend
3006            (MainWindow.ShowLegend): Implement in terms of ToggleLegend and
3007            LegendShown
3008            (MainWindow.LegendShown): New method to return whether the legend
3009            is currently shown.
3010            (_method_command): Add checked parameter so we can define check
3011            menu items
3012            (_has_tree_window_shown, _has_legend_shown): Use the appropriate
3013            mainwindow methods.
3014            (show_session_tree, show_legend commands): Removed.
3015            (toggle_session_tree, toggle_legend commands): New commands to
3016            toggle the visibility of the dialogs
3017    
3018    2003-04-07  Jonathan Coles   <[email protected]>
3019    
3020            * Thuban/UI/classgen.py: Fix Windows problem.
3021    
3022            * Thuban/UI/dock.py: Fix Windows problem.
3023    
3024            * Thuban/UI/mainwindow.py: Use False instead of false.
3025            (MainWindow.ShowLegend): Remove unnecessary switch parameter.
3026    
3027    2003-04-07  Jonathan Coles   <[email protected]>
3028    
3029            Since we now say that the order of the groups in a classification
3030            matters, it makes sense to be able to manipulate that order. Most
3031            of the changes to Thuban/Model/classification.py are to that end.
3032    
3033            * Thuban/Model/classification.py (Classification.AppendGroup,
3034            Classification.InsertGroup, Classification.ReplaceGroup,
3035            Classification.RemoveGroup, Classification.GetGroup): Do as the
3036            names imply.
3037            (Classification.FindGroup): This was called GetGroup, but GetGroup
3038            takes an index, while FindGroup takes a value.
3039            (Classification.__deepcopy__): Copy all the groups, BUT NOT THE LAYER
3040            REFERENCE. Currently there is a cyclic reference between the layer
3041            and its classification. If the classification doesn't need to know
3042            its owning layer we can change this, since it may make sense to be
3043            able to use the same classification with different layers.
3044    
3045            * Thuban/Model/load.py: Use Classification.AppendGroup(), not AddGroup()
3046    
3047            * Thuban/UI/classgen.py: Use Classification.AppendGroup(),
3048            not AddGroup()
3049    
3050            * Thuban/UI/classifier.py: Now that we can depend on the order in
3051            a Classification and have methods to manipulate that order we don't
3052            need to use our own data structures in the grid. We can simply make
3053            the grid/table access the information they need from a copy of
3054            the classification object.
3055            (Classifier._OnCloseBtn): Event handler for when the user clicks
3056            'Close'. This is needed so if the user applies changes and then
3057            continues to change the table the user has the option of discarding
3058            the most recent changes and keeping what they applied.
3059    
3060            * Thuban/UI/mainwindow.py: Put "Show Legend" and "Show Session Tree"
3061            into the same group.
3062    
3063            * extensions/thuban/wxproj.cpp (check_version): If Thuban is compiled
3064            with a really old version of proj, PJ_VERSION won't even be defined.
3065            If it isn't defined then just compile so that the function always
3066            returns Py_False.
3067    
3068            * test/test_classification.py: Fix tests to use the renamed methods.
3069            Still need to write tests for the new methods.
3070    
3071    2003-04-04  Jonathan Coles   <[email protected]>
3072    
3073            * Thuban/UI/classifier.py (Classifier.__SelectField): Move the
3074            call to SetSelection out of the method and before the call
3075            to __SelectField in __init__. This prevents a recursion of events
3076            when _OnFieldSelect is triggered by the user.
3077    
3078    2003-04-04  Jonathan Coles   <[email protected]>
3079    
3080            * Thuban/Model/classification.py: Rename Color.None to
3081            Color.Transparent.
3082            (ClassGroupProperties.SetLineColori, ClassGroupProperties.SetFill):
3083            Don't bother copying the color, since Colors are immutable.
3084    
3085            * Thuban/Model/color.py, Thuban/Model/layer.py, Thuban/Model/load.py,
3086            Thuban/UI/classifier.py, Thuban/UI/mainwindow.py,
3087            Thuban/UI/renderer.py, Thuban/UI/view.py:
3088            Rename Color.None to Color.Transparent.
3089        
3090            * test/test_classification.py, test/test_load.py: Rename Color.None
3091            to Color.Transparent.
3092    
3093    2003-04-04  Jonathan Coles   <[email protected]>
3094    
3095            * Thuban/Model/classification.py: Fix assert calls.
3096            (ClassGroupProperties.SetLineColor, ClassGroupProperties.SetFill):
3097            Copy the color parameter rather than hold onto a reference.
3098    
3099            * Thuban/Model/color.py (Color.__copy__, Color.__deepcopy): Copy
3100            the color object.
3101            (NoColor.__copy__, NoColor.__deepcopy): Return 'self' so that we
3102            are sure there exists only one refernce to Color.None in the system.
3103            This allows us to use 'is' rather than the comparision functions.
3104            
3105            * Thuban/Model/save.py: Fix assert calls.
3106            
3107            * Thuban/UI/classifier.py: Fix assert calls.
3108            (ClassGrid._OnCellDClick): Call up to the classifier to open the
3109            dialog to edit the groups properties.
3110            (ClassGrid._OnCellResize): Make sure that the scollbars are drawn
3111            correctly if a cell is resized.
3112            (ClassTable.SetClassification): New. Changes the classification
3113            that is in the table.
3114            (ClassTable.__SetRow): Allow groups to be prepended.
3115            (Classifier): New code for opening the EditProperties and
3116            GenerateRanges dialogs.
3117            (SelectPropertiesDialog.__GetColor): Only set the color in the
3118            color dialog if the current color is not None.
3119            
3120            * Thuban/UI/dock.py: Fix assert calls.
3121            
3122            * Thuban/UI/legend.py: Fix assert calls.
3123            
3124            * Thuban/UI/renderer.py: Fix assert calls.
3125            
3126            * Thuban/UI/classgen.py (ClassGenDialog): Dialog for generating
3127            classifications.
3128            (GenRangePanel): Panel specific to range generation.
3129            (GenSingletonPanel): Panel specific to singleton generation.
3130            (ClassGenerator): Class responsible for actually generating
3131            the classification from the data gathered in the dialog box.
3132            (PropertyRamp): Generates properties whose values range from
3133            a starting property to an ending property.
3134    
3135    2003-04-03  Bernhard Herzog  <[email protected]>
3136    
3137            * test/support.py (print_garbage_information): New function that
3138            prints information about still connected messages and memory
3139            leaks.
3140            (run_suite): Removed.
3141            (run_tests): New function for use as a replacement of
3142            unittest.main in the test_* files. This one calls
3143            print_garbage_information at the end.
3144    
3145            * test/runtests.py (main): Use support.print_garbage_information
3146    
3147            * test/test_layer.py: Use support.run_tests instead of
3148            unittest.main so we get memory leak information
3149            (TestLayer.test_arc_layer, TestLayer.test_polygon_layer)
3150            (TestLayer.test_point_layer, TestLayer.test_empty_layer)
3151            (TestLayerLegend.test_visibility): Call the layer's Destroy method
3152            to fix a memory leak.
3153    
3154            * test/test_classification.py: Use support.run_tests instead of
3155            unittest.main so we get memory leak information
3156            (TestClassification.test_classification): Call the layer's Destroy
3157            method to fix a memory leak.
3158    
3159    2003-04-02  Bernhard Herzog  <[email protected]>
3160    
3161            * extensions/thuban/wxproj.cpp (check_version, check_version_gtk):
3162            Handle the reference counts of the return value and errors in
3163            PyArg_ParseTuple correctly.
3164    
3165            * Thuban/UI/application.py (ThubanApplication.OpenSession): Make
3166            sure the filename is absolute to avoid problems when saving the
3167            session again
3168    
3169            * Thuban/Model/table.py: Remove unnecessary import. Fix a typo.
3170    
3171    2003-04-01  Jonathan Coles   <[email protected]>
3172    
3173            *  Thuban/UI/renderer.py (MapRenderer.draw_point_shape): Check
3174            that there actually are points in the returned list of points
3175            before trying to index into the list. The list may be empty if
3176            the shape is a Null Shape.
3177    
3178    2003-04-01  Bernhard Herzog  <[email protected]>
3179    
3180            * test/test_map.py: Don't use from <module> import *
3181    
3182    2003-04-01  Jonathan Coles   <[email protected]>
3183    
3184            * Thuban/Model/session.py: Use LAYER_CHANGED instead of
3185            LAYER_LEGEND_CHANGED
3186    
3187            * Thuban/UI/dock.py (DockableWindow._OnButtonClose): Call
3188            self.Destroy() to close the window after yesterday's changes.
3189    
3190            * test/test_map.py, test/test_session.py: Fix messages that
3191            are sent from maps and layers.
3192    
3193    2003-03-31  Jonathan Coles   <[email protected]>
3194    
3195            * Thuban/UI/classifier.py: Commented out some debugging statements.
3196            (ClassDataPreviewer.Draw): Draw rectangles for polygon layers per
3197            RTbug #1769.
3198    
3199            * Thuban/UI/dock.py (DockableWindow.UnDock): Restore size and
3200            position (although position doesn't work yet under GTK).
3201            (DockableWindow.Destroy): New. Called when the window must be
3202            closed. Namely needed when the DockFrame closes and must close
3203            its children.
3204            (DockFrame): Listen for EVT_CLOSE and destroy all children.
3205    
3206            * Thuban/UI/legend.py (LegendPanel.Destroy): New. Cleans up
3207            when then window is told to close.
3208            (LegendTree._OnMsgLayerChanged): Fixes a seg fault bug. See
3209            comment in source for more info.
3210    
3211            * Thuban/UI/main.py: Show the legend by default when Thuban starts.
3212    
3213            * Thuban/UI/mainwindow.py: Renamed OnClose to _OnClose for
3214            symmetry with other such methods.
3215            (MainWindow.ShowLegend): Show the legend docked by default.
3216    
3217    2003-03-28  Jonathan Coles   <[email protected]>
3218    
3219            * Thuban/UI/classifier.py: Support for highlighting a specific
3220            group within the grid when the classification dialog is opened.
3221            Also contains a lot of debugging printouts which will later
3222            be removed.
3223    
3224            * Thuban/UI/dock.py: Complete rework on the dock code so that
3225            that it is fairly removed from the rest of the Thuban application.
3226            It is easy to add new docks which the rest of the program having
3227            to be aware of them.
3228    
3229            * Thuban/UI/legend.py: Modifications to support selecting a
3230            specific group in the classification dialog. Changed how layers
3231            are drawn when the layer is visible/invisible.
3232    
3233            * Thuban/UI/mainwindow.py: Removed legend specific code and
3234            replaced it with calls to the new dock code.
3235    
3236            * Thuban/UI/renderer.py (MapRenderer.__init__): Added assert
3237            to check if scale > 0. Trying to track down a divide by zero.
3238    
3239    2003-03-26  Jonathan Coles   <[email protected]>
3240    
3241            * Thuban/UI/legend.py: Removed unnecessary LegendDialog class.
3242            (LegendPanel): Removed _OnDock()/_OnUnDock() methods which are
3243            now part of DockableWindow.
3244            (LegendPanel.DoOnSelChanged): Select the current layer in the
3245            map.
3246            (LegendTree._OnSelChanged): Call LegendPanel.DoOnSelChanged()
3247            with the selected layer and/or group.
3248    
3249    2003-03-26  Jonathan Coles   <[email protected]>
3250    
3251            This putback contains the code for dockable windows. There is
3252            no support in wxWindows as of this date for windows that can
3253            attach themselves to other windows.
3254    
3255            The current model contains a DockableWindow which has a parent
3256            window for when it is detached and a dock window that it puts
3257            its contents in when it is docked. The contents of a DockableWindow
3258            must be a DockPanel. DockPanel itself derives from wxPanel.
3259    
3260            * Thuban/Model/layer.py (Layer.ClassChanged): Send a LAYER_CHANGED
3261            message, not a LAYER_LEGEND_CHANGED message.
3262    
3263            * Thuban/Model/map.py (Map): Forward LAYER_CHANGED messages.
3264    
3265            * Thuban/UI/classifier.py (Classifier.__init__): Use wxADJUST_MINSIZE
3266            as one of the style properties for the fieldTypeText item to
3267            be sure that its size is correct when the text changes.
3268    
3269            * Thuban/UI/dock.py: New. Classes for the DockPanel and
3270            DockableWindow.
3271    
3272            * Thuban/UI/legend.py: Added some more buttons and made the
3273            LegendPanel a DockPanel.
3274    
3275            * Thuban/UI/mainwindow.py: Added sash windows to the main window
3276            and supporting functions for manipulating the sashes.
3277            (MainWindow.ShowLegend): Create a DockableWindow with the
3278            LegendPanel as the contents.
3279    
3280            * Thuban/UI/messages.py: Added DOCKABLE_* messages
3281    
3282            * Thuban/UI/view.py (MapCanves.SetMap): Listen for LAYER_CHANGED,
3283            not LAYER_LEGEND_CHANGED, messages.
3284    
3285    2003-03-25  Jonathan Coles   <[email protected]>
3286    
3287            * setup.py: Added custom script bdist_rpm_build_script so that
3288            when the rpm is built the path to wx-config is correct.
3289    
3290            * setup.cfg: Added line saying to use the custom build script
3291    
3292    2003-03-20  Jonathan Coles   <[email protected]>
3293    
3294            Initial implementation of the Legend.
3295    
3296            * Thuban/UI/legend.py: New. Creates a window that shows the map's
3297            Legend information and allows the user to add/modify classifications
3298            and how the layers are drawn on the map.
3299    
3300            * setup.py: New command 'build_docs' which currently uses
3301            happydoc to generate html documentation for Thuban.
3302    
3303            * Thuban/Model/classification.py (ClassGroup.GetDisplayText): New.
3304            Returns a string which is appropriately describes the group.
3305    
3306            * Thuban/Model/layer.py (Layer.SetClassification): Generate a
3307            LAYER_CHANGED event instead of a LAYER_LEGEND_CHANGED event.
3308    
3309            * Thuban/Model/map.py (Map): Rename messages and use new, more
3310            specific, messages.
3311    
3312            * Thuban/Model/messages.py: New message to indicate that a layer's
3313            data has changed (LAYER_CHANGED). New map messages to indicate
3314            when layers have been added/removed/changed or if the stacking order
3315            of the layers has changed.
3316    
3317            * Thuban/Model/session.py: Rename and use new messages.
3318    
3319            * Thuban/UI/classifier.py: Remember if any changes have actually
3320            been applied so that if the dialog is cancelled without an application
3321            of changes we don't have to set a new classification.
3322            (ClassDataPreviewer): Pulled out the window specific code and put it
3323            ClassDataPreviewWindow. ClassDataPreviewer can then be used to draw
3324            symbols on any DC.
3325            
3326            * Thuban/UI/mainwindow.py: New code to open the legend.
3327    
3328            * Thuban/UI/view.py: Use new message names.
3329    
3330    2003-03-19  Jonathan Coles   <[email protected]>
3331    
3332            * Thuban/UI/main.py (verify_versions): New. Checks the versions
3333            of Python, wxPython, and some other libraries.
3334    
3335            * extensions/thuban/wxproj.cpp (check_version): Checks the given
3336            version against what wxproj was compiled with.
3337            (check_version_gtk): If wxproj was compiled with gtk then check
3338            the given version against the version of the gtk library
3339            currently being used.
3340    
3341    2003-03-14  Bernhard Herzog  <[email protected]>
3342    
3343            * test/test_command.py: Run the tests when the module is run as a
3344            script
3345    
3346    2003-03-14  Bernhard Herzog  <[email protected]>
3347    
3348            Implement selection of multiple selected shapes in the same layer:
3349    
3350            - Introduce a new class to hold the selection. This basically
3351              replaces the interactor which was nothing more than the
3352              selection anyway. A major difference is of course that the new
3353              selection class supports multiple selected shapes in one layer
3354            
3355            - Move the object that represents the selection from the
3356              application to the canvas. The canvas is a better place than the
3357              application because the selection represents which shapes and
3358              layer of the map displayed by the canvas are selected and
3359              affects how the map is drawn.
3360    
3361            - Make the selection and its messages publicly available through
3362              the mainwindow.
3363    
3364            - The non-modal dialogs do not get a reference to the interactor
3365              anymore as they can simply refer to their parent, the
3366              mainwindow, for the what the interactor had to offer.
3367    
3368            * Thuban/UI/selection.py: New module with a class to represent the
3369            selection.
3370    
3371            * Thuban/UI/messages.py (SELECTED_TABLE, SELECTED_MAP): Remove
3372            these unused messages
3373    
3374            * Thuban/UI/application.py (ThubanApplication.OnInit)
3375            (ThubanApplication.OnExit, ThubanApplication.SetSession): The
3376            interactor is gone now.
3377            (ThubanApplication.CreateMainWindow): There is no interactor
3378            anymore so we pass None as the interactor argument for now for
3379            compatibility.
3380    
3381            * Thuban/UI/view.py (MapCanvas.delegated_messages)
3382            (MapCanvas.Subscribe, MapCanvas.Unsubscribe): In Subscribe and
3383            Unsubscribe, delegate messages according to the delegated_messages
3384            class variable.
3385            (MapCanvas.__getattr__, MapCanvas.delegated_methods): Get some
3386            attributes from instance variables as described with the
3387            delegated_methods class variable.
3388            (MapCanvas.__init__): New instance variable selection holding the
3389            current selection
3390            (MapCanvas.do_redraw): Deal with multiple selected shapes. Simply
3391            pass them on to the renderer
3392            (MapCanvas.SetMap): Clear the selection when a different map is
3393            selected.
3394            (MapCanvas.shape_selected): Simple force a complete redraw. The
3395            selection class now takes care of only issueing SHAPES_SELECTED
3396            messages when the set of selected shapes actually does change.
3397            (MapCanvas.SelectShapeAt): The selection is now managed in
3398            self.selection
3399    
3400            * Thuban/UI/mainwindow.py (MainWindow.delegated_messages)
3401            (MainWindow.Subscribe, MainWindow.Unsubscribe): In Subscribe and
3402            Unsubscribe, delegate messages according to the delegated_messages
3403            class variable.
3404            (MainWindow.delegated_methods, MainWindow.__getattr__): Get some
3405            attributes from instance variables as described with the
3406            delegated_methods class variable.
3407            (MainWindow.__init__): The interactor as ivar is gone. The
3408            parameter is still there for compatibility. The selection messages
3409            now come from the canvas.
3410            (MainWindow.current_layer, MainWindow.has_selected_layer):
3411            Delegate to the the canvas.
3412            (MainWindow.LayerShowTable, MainWindow.Classify)
3413            (MainWindow.identify_view_on_demand): The dialogs don't need the
3414            interactor parameter anymore.
3415    
3416            * Thuban/UI/tableview.py (TableFrame.__init__)
3417            (LayerTableFrame.__init__, LayerTableFrame.OnClose)
3418            (LayerTableFrame.row_selected): The interactor is gone. It's job
3419            from the dialog's point of view is now done by the mainwindow,
3420            i.e. the parent. Subscribe to SHAPES_SELECTED instead
3421            of SELECTED_SHAPE
3422            
3423            * Thuban/UI/dialogs.py (NonModalDialog.__init__): The interactor
3424            is gone. It's job from the dialog's point of view is now done by
3425            the mainwindow, i.e. the parent.
3426            
3427            * Thuban/UI/classifier.py (Classifier.__init__): The interactor is
3428            gone. It's job from the dialog's point of view is now done by the
3429            mainwindow, i.e. the parent.
3430    
3431            * Thuban/UI/tree.py (SessionTreeView.__init__): The interactor is
3432            gone. It's job from the dialog's point of view is now done by the
3433            mainwindow, i.e. the parent.
3434            (SessionTreeCtrl.__init__): New parameter mainwindow which is
3435            stored as self.mainwindow. The mainwindow is need so that the tree
3436            can still subscribe to the selection messages.
3437            (SessionTreeCtrl.__init__, SessionTreeCtrl.unsubscribe_all)
3438            (SessionTreeCtrl.update_tree, SessionTreeCtrl.OnSelChanged): The
3439            selection is now accessible through the mainwindow. Subscribe to
3440            SHAPES_SELECTED instead of SELECTED_SHAPE
3441    
3442            * Thuban/UI/identifyview.py (IdentifyView.__init__): Use the
3443            SHAPES_SELECTED message now.
3444            (IdentifyView.selected_shape): Now subscribed to SHAPES_SELECTED,
3445            so deal with multiple shapes
3446            (IdentifyView.__init__, IdentifyView.OnClose): The interactor is
3447            gone. It's job from the dialog's point of view is now done by the
3448            mainwindow, i.e. the parent.
3449    
3450            * Thuban/UI/controls.py (RecordListCtrl.fill_list): The second
3451            parameter is now a list of shape ids.
3452            (RecordTable.SetTable): The second parameter is now a list of
3453            indices.
3454    
3455            * Thuban/UI/renderer.py (ScreenRenderer.RenderMap): Rename the
3456            selected_shape parameter and ivar to selected_shapes. It's now a
3457            list of shape ids.
3458            (MapRenderer.draw_label_layer): Deal with multiple selected
3459            shapes. Rearrange the code a bit so that the setup and shape type
3460            distinctions are only executed once.
3461    
3462            * test/test_selection.py: Test cases for the selection class
3463    
3464    2003-03-11  Jonathan Coles   <[email protected]>
3465    
3466            * Thuban/Model/load.py: Temporary fix so that the xml reader
3467            doesn't cause Thuban to crash.
3468    
3469            * Thuban/Model/layer.py: Handle the cyclic references between
3470            a layer and its classification better, and be sure to disconnect
3471            the classification from the layer when the layer is destroyed
3472            so that we don't maintain a cyclic reference that may not be
3473            garbage collected.
3474    
3475            * Thuban/Model/classification.py: See comment for layer.py.
3476    
3477    2003-03-12  Jan-Oliver Wagner <[email protected]>
3478    
3479            * HOWTO-Release: New. Information on the steps for releasing
3480            a new version of Thuban.
3481    
3482    2003-03-11  Jonathan Coles   <[email protected]>
3483    
3484            * Thuban/UI/classifier.py: Add normal border to SelectPropertiesDialog.
3485            Use True instead of true.
3486            (Classifier): Should have a single panel in which all the controls lie.
3487    
3488            * Thuban/UI/proj4dialog.py: Add normal border.
3489    
3490            * Thuban/UI/tree.py: Fixed problem with bad item images under Windows.
3491    
3492            * Thuban/UI/mainwindow.py: Use True instead of true.
3493    
3494            * setup.py: Update some definitions to use wxWindows2.4 files
3495    
3496            * Data/iceland_sample_class.thuban: Fixed file so that the
3497            field_type information is present.
3498    
3499    2003-03-10  Jonathan Coles   <[email protected]>
3500    
3501            * Thuban/UI/classifier.py (Classifier.__init__): Make the
3502            field type label grow so that when the text changes the
3503            size is updated correctly. This may be a wxWindows bug.
3504    
3505    2003-03-10  Jonathan Coles   <[email protected]>
3506    
3507            * Thuban/UI/application.py: Changed SESSION_CHANGED to
3508            SESSION_REPLACED.
3509    
3510            * Thuban/UI/classifier.py: Wrap text with _().
3511            (ClassGrid.CreateTable): Set dimensions and size hints here,
3512            instead of in Reset, so we only set the size once.
3513    
3514            * Thuban/UI/dialogs.py: Don't need Shutdown(); just use Close()!
3515    
3516            * Thuban/UI/mainwindow.py (MainWindow.prepare_new_session):
3517            Call Close() instead of Shutdown().
3518    
3519            * Thuban/UI/messages.py: Changed SESSION_CHANGED to SESSION_REPLACED.
3520    
3521            * Thuban/UI/tree.py: Changed SESSION_CHANGED to SESSION_REPLACED.
3522            Go back to using OnClose() instead of Shutdown().
3523    
3524    2003-03-10  Jonathan Coles   <[email protected]>
3525    
3526            * Thuban/UI/classifier.py (Classifier): SelectField() needed
3527            to know the old field index as well as the new one.
3528    
3529    2003-03-10  Jonathan Coles   <[email protected]>
3530    
3531            * Thuban/UI/classifier.py (Classifier): Use __SelectField()
3532            to correctly set the table information and call this from
3533            __init__ and from _OnFieldSelect so that all the information
3534            is up to date when the dialog opens and when a field is changed.
3535    
3536    2003-03-10  Jonathan Coles   <[email protected]>
3537    
3538            * Thuban/Model/classification.py (Classification): Don't use
3539            layer's message function directly, use the ClassChanged() method
3540            when then classification changes. SetField/SetFieldType/SetLayer
3541            must keep the information about field name and field type in
3542            sync when an owning layer is set or removed.
3543    
3544            * Thuban/Model/layer.py: Added ClassChanged() so that the
3545            classification can tell the layer when its data has changed.
3546            (Layer.SetClassification): Accepts None as an arguement to
3547            remove the current classification and correctly handles
3548            adding a new classification.
3549    
3550            * Thuban/Model/load.py: Comment out print statement
3551    
3552            * test/test_classification.py, test/test_save.py: New and
3553            improved tests.
3554    
3555    2003-03-07  Jonathan Coles   <[email protected]>
3556    
3557            * Thuban/Model/classification.py: Implemented __copy__ and
3558            __deepcopy__ for ClassGroup* and ClassGroupProperites so
3559            they can easily be copied by the classifier dialog.
3560            (ClassGroupProperites.__init__): The default line color should
3561            have been Color.Black.
3562    
3563            * Thuban/UI/classifier.py: Setting and Getting table values now
3564            uses a consistent set of functions.
3565            (Classifier): Now non-modal. Has field type label which changes
3566            as the field changes. Keep track of buttons in a list so that
3567            we can enable/disable the buttons when the None field is selected.
3568            (SelectPropertiesDialog): Add buttons to make the colors transparent.
3569    
3570            * Thuban/UI/dialogs.py (NonModalDialog.Shutdown): New method which
3571            does what OnClose did, but can be called by the application to
3572            close a window. Needed when a session changes, and we have to
3573            close the classifier windows.
3574    
3575            * Thuban/UI/mainwindow.py (MainWindow.prepare_new_session):
3576            Shuts down open dialogs. Used when a new session is created
3577            or a session is opened.
3578            (MainWindow.SaveSession): Should only call application.SaveSession()
3579            if we don't call SaveSessionAs first.
3580            (MainWindow.Classify): Allow different classifier dialogs for
3581            different layers.
3582    
3583            * Thuban/UI/tree.py (SessionTreeView): Remove OnClose and let
3584            the parent class handle it. Add Shutdown() to unsubscibe from
3585            event notification and call the parent Shutdown(). This was
3586            necessary so the application can close the tree window.
3587    
3588    2003-03-06  Jonathan Coles   <[email protected]>
3589    
3590            * Thuban/Model/classification.py: Minor documentation changes,
3591            Addition of __eq__ and __ne__ methods.
3592            (Classification.SetLayer): prevent recursion between this method
3593            and Layer.SetClassification().
3594    
3595            * Thuban/Model/color.py: Addition of __eq__ and __ne__ methods.
3596    
3597            * Thuban/Model/layer.py (SetClassification): prevent recursion
3598            between this method and Classification.SetLayer().
3599    
3600            * test/test_classification.py, test/test_load.py,
3601            test/test_session.py: Fixed and added tests for the classification
3602            classes.
3603    
3604    2003-03-06  Bernhard Herzog  <[email protected]>
3605    
3606            * Thuban/UI/classifier.py (ClassGrid.__init__)
3607            (ClassGrid.CreateTable): Move the SetSelectionMode call to
3608            CreateTable because otherwise it triggers an assertion in
3609            wxPython/wxGTK 2.4.
3610    
3611    2003-03-05  Jonathan Coles   <[email protected]>
3612    
3613            * Thuban/common.py: Move FIELDTYPE constants back to table.py.
3614    
3615            * Thuban/Model/load.py: import FIELDTYPE constants from table.
3616    
3617            * Thuban/UI/classifier.py: import FIELDTYPE constants from table.
3618    
3619            * Thuban/Model/table.py: Put FIELDTYPE constants back.
3620    
3621    2003-03-05  Jonathan Coles   <[email protected]>
3622    
3623            * Thuban/UI/classifier.py: Added class documentation.
3624            Fixed RTbug #1713, #1714. Added Move[Up|Down] buttons.
3625            Store just the groups in the table and generate the other
3626            column information when it is requested. Add "None" field
3627            to pull-down to select no classification.
3628    
3629            * Thuban/common.py: Moved FIELDTYPE constants from table.py
3630            (Str2Num): Only catch ValueError exceptions.
3631    
3632            * Thuban/Model/classification.py: Class documentation. Renaming
3633            of methods with Stroke to Line. Groups are stored in a single
3634            list with the default as the first element. Groups are searched
3635            in the order they appear in the list.
3636    
3637            * Thuban/Model/color.py: Documentation.
3638    
3639            * Thuban/Model/layer.py (Layer): Add GetFieldType to retreive
3640            the kind of data represented by a field.
3641    
3642            * Thuban/Model/load.py (ProcessSession): Use proper string
3643            conversion function; fixes RTbug #1713.
3644    
3645            * Thuban/Model/save.py (Saver): Store field type information.
3646    
3647            * Thuban/Model/table.py: Put FIELDTYPE constants in common.py.
3648            (Table): Add field_info_by_name() to retrieve field information
3649            by specifying the field name, not the number.
3650    
3651            * Thuban/UI/mainwindow.py: Function name changes.
3652    
3653            * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Only
3654            get the layer classification once. Don't try to classify
3655            values when the field is None: just use the default properties.
3656    
3657            * Thuban/UI/view.py: Function name changes.
3658    
3659            * Doc/thuban.dtd: Add field_type attribute to a classification.
3660    
3661    2003-03-04  Bernhard Herzog  <[email protected]>
3662    
3663            * Doc/thuban.dtd: Use correct syntax for optional attributes. Make
3664            the fill and stroke layer attributes optional with suitable
3665            default values. Add the stroke_width layer attribute. Use correct
3666            syntax for empty elements. Make the attribute list for labels
3667            refer to the label element.
3668    
3669    2003-03-04  Bernhard Herzog  <[email protected]>
3670    
3671            * setup.py (thuban_build_py.build): Add a comment about distutils in
3672            Python 2.3 containing some of the functionality we implement in
3673            setup.py ourselves.
3674    
3675            * Thuban/UI/classifier.py (ClassGrid.__init__): Set the table
3676            before the selection mode. Doing it the other way round triggers
3677            an assertion in wxWindows.
3678    
3679            * Thuban/Model/save.py (escape): Fix typo in doc-string
3680    
3681            * Thuban/Model/classification.py: Remove unnecessary wxPython
3682            import
3683    
3684    2003-03-04  Jonathan Coles   <[email protected]>
3685    
3686            * Thuban/Model/classification.py (ClassGroupRange.GetProperties):
3687            Parameter 'value' should default to None.
3688    
3689            * Thuban/UI/mainwindow.py: Use Layer.GetClassification() since
3690            the class attribute __classification is now private.
3691    
3692            * Thuban/UI/classifier.py (ClassGrid): Moved OnCellDClick() from
3693            Classifier to ClassGrid. Added support for removing selected rows,
3694            which including code for keeping track of when cells are selected,
3695            and deselected.
3696            (ClassTable): Support for added/removing rows. Fixed a problem
3697            with __ParseInput whereby it would not allow strings (only numbers)
3698            to be entered.
3699            (Classifier): Added button and supporting code for removing
3700            selected rows.
3701    
3702    2003-02-27  Jonathan Coles   <[email protected]>
3703    
3704            * Thuban/common.py: Moved color conversion functions into
3705            Thuban/UI/common.py.
3706            (Str2Num): Now converts the float (not the string) to a long/int
3707            so that an exception isn't thrown.
3708    
3709            * Thuban/UI/common.py: Common functions used in several UI modules
3710    
3711            * Thuban/Model/classification.py: Changed the class hierarchy
3712            so that a Classification consists of Groups which return
3713            Properties when a value matches a Group.
3714    
3715            * Thuban/Model/layer.py: Fixed name resolution problem.
3716    
3717            * Thuban/Model/load.py: Use new Classification and Group functions.
3718    
3719            * Thuban/Model/save.py (Saver.write_attribs): Fixes a test case
3720            failure.
3721            (Saver.write_classification): Use new Classification and Group
3722            functions.
3723    
3724            * Thuban/UI/classifier.py: Changes to use new Classification and Group
3725            functions. Fix to create a tuple with a single value instead of
3726            simply returning the value.
3727    
3728            * Thuban/UI/renderer.py: Use new Classification and Group functions.
3729            Use common.py functions.
3730    
3731            * Thuban/UI/tree.py: Use common.py functions.
3732            
3733            * test/test_classification.py: Use new Classification and Group
3734            classes.
3735    
3736    2003-02-24  Jonathan Coles   <[email protected]>
3737    
3738            * Thuban/common.py (Color2wxColour, wxColour2Color): Conversion
3739            functions from Thuban color objects to wxWindow colour objects.
3740    
3741            * Thuban/Model/classification.py (Classification): Renamed
3742            GetProperties() to GetClassData(). Used the new iterator
3743            in TreeInfo().
3744            (ClassIterator): Iterator implementation to iterate over the
3745            ClassData objects in a classification object.
3746    
3747            * Thuban/Model/save.py (Saver.write_classificaton): Uses
3748            the new iterator to save the classification information.
3749    
3750            * Thuban/UI/classifier.py (SelectPropertiesDialog): Support
3751            for changing the stroke and fill colors and previewing the
3752            changes.
3753    
3754            * Thuban/UI/mainwindow.py (MainWindow.OpenSession,
3755            MainWindow.SaveSessionAs): Text string changes so the dialogs
3756            have more meaningful titles.
3757    
3758            * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Change
3759            Classification method name from GetProperties to GetClassData.
3760    
3761            * Thuban/UI/view.py (MapCanvas.find_shape_at): Use method calls
3762            instead of accessing now non-existent class variables.
3763    
3764    2003-02-24  Bernhard Herzog  <[email protected]>
3765    
3766            * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Remove
3767            unneeded Shape() call. Rendering is substantially faster without
3768            it and it avoids some problems with broken shape files.
3769    
3770    2003-02-20  Frank Koormann   <[email protected]>
3771    
3772            Force minimal size of identify and label dialogs. The autosizing
3773            looked too ugly.
3774    
3775            * Thuban/UI/controls.py (RecordListCtrl): Set minimal width for columns.
3776            * Thuban/UI/labeldialog.py (LabelDialog.dialog_layout):
3777            Set size of listctrl.
3778            * Thuban/UI/identifyview.py (IdentifyView.__init__):
3779            Set size of dialog.
3780    
3781    2003-02-19  Jonathan Coles   <[email protected]>
3782    
3783            * test/test_classification.py, test/test_layer.py,
3784            test/test_load.py, test/test_map.py, test/test_session.py:
3785            Updated the tests to use the new functions that are in the
3786            respective classes.
3787    
3788            * Thuban/Model/classification.py (Classification):
3789            Uses the new ClassData* classes. Modification messages are
3790            passed up to the parent layer (if it exists).
3791            (ClassData): New class to encapsulate the common data in each
3792            classification property.
3793            (ClassDataDefault): Represents the Default class. data.
3794            (ClassDataPoint): Represents a single class. data point
3795            (ClassDataRange): Represents a class. range
3796            (ClassDataMap): Represents a class. map (unused).
3797    
3798            * Thuban/Model/color.py: Added Color.None to represent something
3799            with no color. Color.Black represents the color black.
3800            (NoColor): Helper class derived from Color to represent something
3801            with no color.
3802    
3803            * Thuban/Model/layer.py (Layer): Removed references to fill, stroke,
3804            stroke_width attributes. Made the 'classification' attribute private.
3805            New methods for setting/getting the classification.
3806    
3807            * Thuban/Model/load.py (ProcessSession): Use new methods on Layer
3808            to get the classifcation and use the new ClassData* classes to
3809            hold the classification data. Use Str2Num to convert numbers
3810            properly.
3811    
3812            * Thuban/Model/save.py (Saver): Use new Color and Classification
3813            methods
3814    
3815            * Thuban/UI/classifier.py (ClassGrid): New class to represent a
3816            custom grid.
3817            (ClassTable): Support for editing Values and Labels and for
3818            changing what type (point or range) of data is stored in each
3819            property based on how the user enters the data.
3820            (Classifier): Support for saving the new classifications and
3821            launching the dialog to edit a property.
3822            (SelectPropertiesDialog): New class for editing the visual
3823            properties of a classification (stroke color, width, and fill color)
3824            (ClassPreviewer): Took the Draw method from ClassRenderer and
3825            made most of it into this new class. Intend to use this class in
3826            the SelectPropertiesDialog for previewing changes.
3827    
3828            * Thuban/UI/renderer.py: Use new Color and Classification methods.
3829    
3830            * Thuban/UI/tree.py: Formatting changes.
3831    
3832            * Doc/thuban.dtd: Add 'label' element
3833    
3834            * Thuban/common.py: New. Contains common routines used throughout
3835            the code.
3836            (Str2Num): Takes a string and converts it to the "best" type of
3837            number.
3838    
3839    2003-02-14  Bernhard Herzog  <[email protected]>
3840    
3841            * Thuban/UI/view.py (MapCanvas.OnLeftUp): Make sure that the
3842            dragging flag is always set to 0 even when the tool implementation
3843            raises an exception
3844    
3845    2003-02-11  Bernhard Herzog  <[email protected]>
3846    
3847            * Thuban/UI/application.py (ThubanApplication.splash_screen): New
3848            method to create a splash screen.
3849            (ThubanApplication.ShowMainWindow): New. Show the main window.
3850            Needed so the splash screen can display the mainwindow
3851            (ThubanApplication.OnInit): Call the
3852            new splash_screen method to determine whether the application
3853            should display a splash screen. If it displays a splash screen do
3854            not immediately show the main window.
3855    
3856    2003-02-11  Jonathan Coles  <[email protected]>
3857    
3858            * Thuban/Model/classification.py: Added import line to fix
3859            feature conflicts between running on python2.2 and python2.1.
3860    
3861            * Thuban/UI/classifier.py (ClassTable): Didn't need to hang
3862            onto the clinfo parameter, so removed the deepcopy().
3863    
3864    2003-02-10  Jonathan Coles  <[email protected]>
3865    
3866            * Thuban/Model/save.py (Saver.open_element, Saver.close_element):
3867            Added element_open variable to track opening and closing of tags
3868            so that tags that don't span more than one line are closed with
3869            /> instead of </tag_name>. Use the GetDefault*() methods of
3870            the Classification class.
3871    
3872            * Thuban/Model/classification.py (Classificaton): Added set and
3873            get methods for the default data. The class also takes a layer
3874            reference so that modification messages can be sent. Fixed the
3875            methods to use the new ClassData class.
3876            (ClassData): New class to encapsulate the classification data
3877    
3878            * Thuban/Model/layer.py (Layer): Remove the
3879            Set[Fill|Stroke|StrokeWidth]() methods. Code should call the
3880            SetDefault*() methods on the layer's classification object.
3881            (Layer.__init__): Use the new SetDefault*() methods in the
3882            Classification class.
3883    
3884            * Thuban/Model/load.py (ProcessSession): Use the new ClassData
3885            object instead of a dictionary.
3886    
3887            * Thuban/UI/classifier.py (ClassRenderer): New class to
3888            draw the classifications in the dialog box's table.
3889            (Classifier): Modified to use the ClassRenderer class.
3890    
3891            * Thuban/UI/mainwindow.py (MainWindow): Use the SetDefault*()
3892            methods of the Classification class.
3893    
3894            * Thuban/UI/renderer.py (MapRenderer): Use the Get*() methods
3895            of the ClassData class.
3896    
3897            * test/test_classification.py, test/test_layer.py,
3898            test/test_map.py, test/test_session.py: Fix the tests to work
3899            with the above code changes.
3900    
3901    2003-02-03  Jonathan Coles  <[email protected]>
3902    
3903            * Thuban/Model/classification.py (Classification): Added getNull()
3904            to return the NullData reference
3905    
3906            * Thuban/Model/layer.py (Layer.SetFill, Layer.SetStroke,
3907            Layer.SetStrokeWidth): Modified these functions to change the
3908            null data in the classification rather than keep these values
3909            directly in the Layer class. Menu options to change these values
3910            work again.
3911    
3912    2003-01-28  Jonathan Coles  <[email protected]>
3913    
3914            * Thuban/UI/classifier.py (Classifier): Resolved merging conflicts.
3915            Fixed crashing problem on some systems. Dialog box shows
3916            classification data.
3917    
3918            * Thuban/UI/tree.py (SessionTreeCtrl.add_items): Handle drawing
3919            Colors in the tree view.
3920    
3921            * Thuban/Model/layer.py (Layer.TreeInfo): Added a call to build
3922            the tree info for classifications. Commented out unnecessary lines.
3923    
3924            * Thuban/Model/classification.py (Classification.TreeInfo): New
3925            function to add information about the classification into the
3926            tree view.
3927    
3928    2003-01-27  Jan-Oliver Wagner <[email protected]>
3929    
3930            * Thuban/__init__.py (_): New.
3931    
3932            * Thuban/Model/classification.py, Thuban/Model/extension.py,
3933            Thuban/Model/layer.py, Thuban/Model/load.py, Thuban/Model/map.py,
3934            Thuban/Model/session.py, Thuban/UI/application.py,
3935            Thuban/UI/classifier.py, Thuban/UI/context.py, Thuban/UI/controls.py,
3936            Thuban/UI/identifyview.py, Thuban/UI/labeldialog.py,
3937            Thuban/UI/mainwindow.py, Thuban/UI/menu.py, Thuban/UI/proj4dialog.py,
3938            Thuban/UI/renderer.py, Thuban/UI/tree.py, Thuban/Lib/connector.py,
3939            Thuban/Lib/fileutil.py: Replace user string by _() for i18n.
3940    
3941    2003-01-27  Jonathan Coles  <[email protected]>
3942    
3943            * Thuban/Model/layer.py: Classification initialization calls.
3944    
3945            * Thuban/Model/classification.py: Created class to encapsulate
3946            a layer classification. Supports specific data points and
3947            ranges.
3948    
3949            * Thuban/Model/load.py: Added support for loading classification
3950            information.
3951    
3952            * Thuban/Model/save.py: Added support for saving classification
3953            information.
3954    
3955            * Thuban/UI/classifier.py: Initial class for a dialog box for
3956            specifying classification information.
3957    
3958            * Thuban/UI/mainwindows.py: Support for opening the classifier
3959            dialog.
3960    
3961            * Thuban/UI/renderer.py: Support for drawing a layer with the
3962            classification information.
3963    
3964            * Data/iceland_sample_class.thuban: iceland_sample with
3965            classification data.
3966    
3967            * test/test_classification: Tests for the Classification class.
3968    
3969    2002-12-09  Bernhard Herzog  <[email protected]>
3970    
3971            * test/test_command.py: New. Tests for the command classes.
3972    
3973            * Thuban/UI/command.py (ToolCommand): New class for tool commands.
3974            (Command.IsTool): New method to distinguish between command
3975            switching tools and other commands.
3976    
3977            * Thuban/UI/view.py (MapCanvas.SelectTool): New method to select
3978            the tool to avoid direct assignments to instance variables
3979            (MapCanvas.ZoomInTool, MapCanvas.ZoomOutTool, MapCanvas.PanTool)
3980            (MapCanvas.IdentifyTool, MapCanvas.LabelTool): Use SelectTool to
3981            change the tool
3982    
3983            * Thuban/UI/mainwindow.py (MainWindow.update_command_ui): If an
3984            active tool's command turns insensitive, disable the tool.
3985            (_tool_command): Use the new ToolCommand class
3986    
3987            * Examples/simple_extensions/simple_tool.py (simple_tool): Use the
3988            SelectTool method to change the tool
3989            (iconfile): Use the ToolCommand class
3990    
3991    2002-12-03  Bernhard Herzog  <[email protected]>
3992    
3993            * Thuban/UI/tree.py (SessionTreeCtrl.normalize_selection): Handle
3994            the case of selected items that are not children of Layers or Maps
3995            properly. Previously this bug would trigger an assertion in
3996            wxWindows.
3997    
3998    2002-11-06  Frank Koormann  <[email protected]>
3999    
4000            * Thuban/UI/mainwindow.py: Altered the order of tools in the
4001            toolbar: First now are all navigation tools (Zoom In/Out, Pan,
4002            Full Extent).
4003    
4004    2002-10-23  Bernhard Herzog  <[email protected]>
4005    
4006            * setup.py (setup call): version now 0.1.3
4007    
4008            * MANIFEST.in: Add the files in test/
4009    
4010            * test/README: Add note about tests requiring the iceland data
4011    
4012            * Thuban/UI/mainwindow.py (MainWindow.About): Add 2002 to
4013            copyright notice.
4014    
4015    2002-10-18  Bernhard Herzog  <[email protected]>
4016    
4017            * test/test_map.py
4018            (TestMapWithContents.test_projected_bounding_box): Use an explicit
4019            epsilon.
4020    
4021            * test/support.py (FloatComparisonMixin.assertFloatEqual)
4022            (FloatComparisonMixin.assertFloatSeqEqual): give a more useful
4023            message if the assertion fails and don't return the return value
4024            of self.assert_. In assertFloatSeqEqual the return meant that not
4025            all items of the sequence were compared.
4026    
4027    2002-09-20  Bernhard Herzog  <[email protected]>
4028    
4029            * test/test_fileutil.py: New. Test cases for Thuban.Lib.fileutil
4030    
4031            * Thuban/Lib/fileutil.py: Fixup some whitespace and typos
4032    
4033            * test/test_map.py (TestMapWithContents.test_tree_info): Create
4034            the string with the bounding box on the fly because of platform
4035            differences in the way %g is handled.
4036    
4037            * test/test_layer.py (TestLayer.test_empty_layer): Create an empty
4038            DBFfile too because Thuban layers can't yet cope missing DBF
4039            files.
4040    
4041    2002-09-20  Bernhard Herzog  <[email protected]>
4042    
4043            * test/test_menu.py: Use initthuban instead of
4044            add_thuban_dir_to_path to initialize Thuban.
4045    
4046            * test/support.py (FloatComparisonMixin.assertFloatEqual): New.
4047            Mixin class for float comparisons
4048            (SubscriberMixin): New. Mixin class to test messages sent through
4049            the Connector class
4050    
4051            * test/README: Fix a typo and add the -v flag to the command for
4052            individual tests
4053    
4054            * test/test_session.py: New. Test cases for Thuban.Model.session
4055    
4056            * test/test_proj.py: New. Test cases for Thuban.Model.proj
4057    
4058            * test/test_map.py: New. Test cases for Thuban.Model.map
4059    
4060            * test/test_layer.py: New. Test cases for Thuban.Model.layer
4061    
4062            * test/test_label.py: New. Test cases for Thuban.Model.label
4063    
4064            * test/test_connector.py: New. Test cases for Thuban.Lib.connector
4065    
4066            * test/test_color.py: New. Test cases for Thuban.Model.color
4067    
4068            * test/test_base.py: New. Test cases for Thuban.Model.base
4069    
4070    2002-09-13  Bernhard Herzog  <[email protected]>
4071    
4072            * Thuban/Model/session.py (Session.forwarded_channels): Forward
4073            the CHANGED channel too.
4074    
4075            * Thuban/Model/map.py (Map.forwarded_channels): Forward the
4076            CHANGED channel too.
4077            (Map.__init__): Call the Modifiable constructor as well.
4078    
4079            * Thuban/Model/base.py (Modifiable.UnsetModified): Issue a CHANGED
4080            event if the modified flag changes.
4081            (Modifiable.changed): Tweak the doc-string.
4082    
4083            * Thuban/UI/mainwindow.py (MainWindow.view_position_changed)
4084            (MainWindow.set_position_text): Put the code that puts the text
4085            with the mouse position into the status bar into the new method
4086            set_position_text so that it can overwritten in derived classes.
4087    
4088    2002-09-12  Bernhard Herzog  <[email protected]>
4089    
4090            * Thuban/UI/mainwindow.py (MainWindow.RunMessageBox): Center the
4091            message box on the main window.
4092    
4093    2002-09-11  Bernhard Herzog  <[email protected]>
4094    
4095            * Thuban/UI/mainwindow.py: Underline the 'x' in "Exit" instead of
4096            the 'E' because it's less likely to interfere with other menu
4097            entries.
4098            (MainWindow.build_menu): remove an incorrect comment.
4099    
4100    2002-09-10  Bernhard Herzog  <[email protected]>
4101    
4102            * Thuban/UI/mainwindow.py (MainWindow.Map): New.
4103            (_tool_command): Add sensitive parameter
4104            (_has_visible_map): Sensitivity callback to tools and other
4105            commands that require a visible map. Use it in map_zoom_in_tool,
4106            map_zoom_out_tool, map_pan_tool, map_identify_tool, map_label_tool
4107            and map_full_extent
4108    
4109    2002-09-06  Bernhard Herzog  <[email protected]>
4110    
4111            * Thuban/UI/mainwindow.py (MainWindow.OnClose): Unsubscribe
4112            VIEW_POSITION
4113    
4114    2002-09-04  Frank Koormann  <[email protected]>
4115    
4116            * Resources/Bitmaps/fullextent.xpm: Updated Icon (removed "potatoe")
4117    
4118    2002-09-02  Bernhard Herzog  <[email protected]>
4119    
4120            * Thuban/UI/view.py: Get rid of the idle redraw. This is done by
4121            wxWindows already and our implementation doesn't work correctly
4122            with wxGTK 2.3:
4123            (MapCanvas.__init__): Remove the instance variable
4124            (MapCanvas.OnPaint): Always call do_redraw when there's a map to
4125            be drawin
4126            (MapCanvas.OnIdle): Removed.
4127    
4128            * Thuban/UI/view.py (MapCanvas.unprojected_rect_around_point): Add
4129            a parameter to determine the size of the rectangle.
4130            (MapCanvas.find_shape_at): Create the box around the point on a
4131            layer by layer basis and make the size depend on the shape type.
4132            This solves a problem with the selection of point shapes at the
4133            border of the layer's bounding box
4134    
4135    2002-08-30  Bernhard Herzog  <[email protected]>
4136    
4137            * Thuban/UI/mainwindow.py (MainWindow.CanRemoveLayer): New method
4138            for the sensitivity  of remove layer.
4139            (_can_remove_layer): New. Sensitivity callback for remove layer
4140            (Command layer_remove): Use _can_remove_layer
4141    
4142            * Thuban/Model/map.py (Map.CanRemoveLayer): New method to
4143            determine whether a given layer can be deleted.
4144    
4145            * Thuban/UI/view.py (MapCanvas.__init__, MapCanvas.OnPaint)
4146            (MapCanvas.do_redraw): Get rid of the unused update_region
4147            instance variable
4148    
4149            * Thuban/UI/view.py: Add/update some doc-strings.
4150    
4151            * test/: new subdirectory with a bunch of unit tests.
4152    
4153            * test/README, test/test_table.py, test/test_save.py,
4154            test/test_menu.py, test/test_load.py: Initial set of tests and
4155            brief instructions on how to run them
4156    
4157    2002-08-29  Bernhard Herzog  <[email protected]>
4158    
4159            * Thuban/UI/renderer.py (ScreenRenderer.draw_shape_layer): Handle
4160            arcs with multiple parts.
4161    
4162            * Thuban/UI/view.py (ZoomInTool.MouseUp, ZoomOutTool.MouseUp):
4163            Handle degenrate rectangles.
4164    
4165            * Thuban/Model/table.py: Make writing records work correctly:
4166            (Table.__init__): Keep track of whether the DBF is open for
4167            writing
4168            (Table.write_record): Open the DBF file for writing when necessary
4169    
4170    2002-08-27  Bernhard Herzog  <[email protected]>
4171    
4172            * Thuban/Model/table.py (Table.write_record, Table.__init__): Open
4173            dbf files only for reading by default. Use a new writable dbf
4174            object for writing.
4175    
4176    2002-08-26  Bernhard Herzog  <[email protected]>
4177    
4178            * Thuban/UI/mainwindow.py: Refactor the context creation:
4179            (MainWindow.Context): New method to return a context
4180            (MainWindow.invoke_command, MainWindow.update_command_ui): Use the
4181            new method
4182    
4183            * Thuban/UI/tableview.py (TableGrid, LayerTableGrid): Split the
4184            layer table specific code from TableGrid into LayerTableGrid
4185            (TableFrame, LayerTableFrame): Split the layer table specific code
4186            from TableFrame into LayerTableFrame
4187            (LayerTableGrid.select_shape): Remove a debug print
4188    
4189            * Thuban/UI/mainwindow.py (MainWindow.LayerShowTable): Use the
4190            LayerTableFrame
4191    
4192    2002-08-23  Bernhard Herzog  <[email protected]>
4193    
4194            * Thuban/Model/layer.py (Layer.__init__): Make sure we have an
4195            absolute filename.
4196    
4197    2002-08-22  Bernhard Herzog  <[email protected]>
4198    
4199            * Thuban/Model/table.py (Table.write_record): New method to write
4200            records.
4201            (Table.__init__): Open the DBF file for writing too.
4202    
4203            * Thuban/UI/controls.py (RecordTable.SetValue): Write the value
4204            into the underlying table.
4205    
4206            * extensions/shapelib/shapefil.h (DBFCommit),
4207            extensions/shapelib/dbfopen.c (DBFCommit): New API function to
4208            commit any changes made to the DBF file.
4209    
4210            * Thuban/UI/mainwindow.py (make_check_current_tool)
4211            (_tool_command): Put the code that generates the "checked"
4212            callback into a separate function so that we can reuse it
4213            elsewhere
4214    
4215            * Thuban/Model/save.py (Saver): New class to handle serializing a
4216            session into an XML file. The main reason to introduce a class is
4217            that applications built on Thuban can derive from it so that they
4218            can save additional information in a session file.
4219            (save_session): Delegate almost all the work to the Saver class.
4220            Rename the filename argument to file because it may be a file like
4221            object now.
4222    
4223            * Thuban/Model/load.py: Get rid of the Python 1.5.2 compatibility
4224            code. Remove the little test code which would be executed when the
4225            module is run as a script which didn't work anymore since it can't
4226            import the other Thuban modules.
4227            (ProcessSession, load_session): Refactor the ProcessSession to
4228            have one method for each element start and end tag so that derived
4229            classes can easily override the processing of individual tags.
4230            Also, always parse with namespaces enabled because applications
4231            built on top of Thuban will likely use namespaces if they extend
4232            the session file format.
4233    
4234    2002-08-21  Bernhard Herzog  <[email protected]>
4235    
4236            * setup.py (ThubanInstall.run): Don't repr install_lib_orig
4237            because thubaninit_contents will do it for us.
4238    
4239    2002-08-16  Jan-Oliver Wagner <[email protected]>
4240    
4241            * Thuban/UI/mainwindow.py: menu item 'show session tree' now disable if
4242            tree window already open
4243    
4244    2002-08-15  Bernhard Herzog  <[email protected]>
4245    
4246            * Thuban/Model/layer.py (Layer.Destroy): Call the unboundd method
4247            with self.
4248    
4249            * Thuban/UI/view.py (MapCanvas.OnLeftUp): Only release the mouse
4250            when we have actually captured it.
4251    
4252            * Thuban/Model/layer.py (Layer.Destroy): New. Explicitly close the
4253            shapefile and destroy the table.
4254    
4255            * Thuban/Model/table.py (Table.Destroy): New. Close the DBF file.
4256    
4257  2002-08-14  Bernhard Herzog  <[email protected]>  2002-08-14  Bernhard Herzog  <[email protected]>
4258    
4259          * Thuban/UI/controls.py (RecordTable.__init__): Remove the unused          * Thuban/UI/controls.py (RecordTable.__init__): Remove the unused
# Line 108  Line 4364 
4364          * Thuban/UI/tree.py: We can now simply subscribe to the session's          * Thuban/UI/tree.py: We can now simply subscribe to the session's
4365          CHANGED channel to be informed of changes.          CHANGED channel to be informed of changes.
4366          (SessionTreeCtrl.session_channels): Not needed any longer.          (SessionTreeCtrl.session_channels): Not needed any longer.
4367          (SessionTreeCtrl.unsubscribe_all, SessionTreeCtrl.session_changed):          (SessionTreeCtrl.unsubscribe_all, SessionTreeCtrl.session_changed):
4368          Only have to (un)subscribe CHANGED          Only have to (un)subscribe CHANGED
4369    
4370          * Thuban/Model/map.py (Map.TreeInfo): Deal better with empty maps.          * Thuban/Model/map.py (Map.TreeInfo): Deal better with empty maps.
# Line 169  Line 4425 
4425          * Thuban/Model/layer.py (Layer.TreeInfo),          * Thuban/Model/layer.py (Layer.TreeInfo),
4426          Thuban/Model/extension.py (Extension.TreeInfo),          Thuban/Model/extension.py (Extension.TreeInfo),
4427          Thuban/Model/map.py (Map.TreeInfo),          Thuban/Model/map.py (Map.TreeInfo),
4428          Thuban/Model/session.py (Session.TreeInfo):          Thuban/Model/session.py (Session.TreeInfo):
4429          Add TreeInfo methods to implement the new tree view update scheme          Add TreeInfo methods to implement the new tree view update scheme
4430    
4431  2002-07-16  Bernhard Herzog  <[email protected]>  2002-07-16  Bernhard Herzog  <[email protected]>
# Line 250  Line 4506 
4506          * setup.py: In the setup call, make sure that the library          * setup.py: In the setup call, make sure that the library
4507          directories are under $prefix/lib not directly under $prefix.          directories are under $prefix/lib not directly under $prefix.
4508    
4509  2002-06-20      Jan-Oliver Wagner <[email protected]>  2002-06-20  Jan-Oliver Wagner <[email protected]>
4510    
4511          * Thuban/Model/extension.py: new module to handle extension objects.          * Thuban/Model/extension.py: new module to handle extension objects.
4512          * Thuban/Model/messages.py: new messages for extensions.          * Thuban/Model/messages.py: new messages for extensions.
# Line 479  Line 4735 
4735          * Thuban/UI/messages.py (VIEW_POSITION): New message for the          * Thuban/UI/messages.py (VIEW_POSITION): New message for the
4736          position in the statusbar          position in the statusbar
4737    
4738  2002-04-26      Frank Koormann <[email protected]>  2002-04-26  Frank Koormann <[email protected]>
4739    
4740          * Thuban/UI/mainwindow.py: AddLayer, Dialog title s/session/data          * Thuban/UI/mainwindow.py: AddLayer, Dialog title s/session/data
4741    
4742  2002-04-24      Frank Koormann <[email protected]>  2002-04-24  Frank Koormann <[email protected]>
4743            
4744          * Resources/Bitmaps/identify.xpm: shadow added          * Resources/Bitmaps/identify.xpm: shadow added
4745    
4746          * Resources/Bitmaps/fullextent.xpm: new          * Resources/Bitmaps/fullextent.xpm: new
           
 2002-04-22      Jan-Oliver Wagner <[email protected]>  
4747    
4748          * Thuban/UI/tree.py (update_tree): added test for None on map bounding box  2002-04-22  Jan-Oliver Wagner <[email protected]>
4749    
4750            * Thuban/UI/tree.py (update_tree): added test for None on map bounding
4751            box
4752    
4753  2002-04-21      Jan-Oliver Wagner <[email protected]>  2002-04-21  Jan-Oliver Wagner <[email protected]>
4754    
4755          * Thuban/UI/proj4dialog.py (UTMProposeZoneDialog): new          * Thuban/UI/proj4dialog.py (UTMProposeZoneDialog): new
4756    
4757          * Thuban/UI/tree.py (update_tree): added added map extent          * Thuban/UI/tree.py (update_tree): added added map extent
4758    
4759          * Thuban/UI/mainwindow.py (_method_command): extended by parameter          * Thuban/UI/mainwindow.py (_method_command): extended by parameter
4760          icon; added map_full_extend as tool          icon; added map_full_extend as tool
4761    
4762  2002-04-19      Jan-Oliver Wagner <[email protected]>  2002-04-19  Jan-Oliver Wagner <[email protected]>
4763    
4764          * Thuban/UI/mainwindow.py (SaveSession): launch save as dialog for          * Thuban/UI/mainwindow.py (SaveSession): launch save as dialog for
4765          saving _new_ sessions          saving _new_ sessions
# Line 604  Line 4861 
4861    
4862          * setup.py: increase version number to 0.1          * setup.py: increase version number to 0.1
4863          (data_dist): New command class for data distribution          (data_dist): New command class for data distribution
           
4864    
4865  2001-09-14  Bernhard Herzog  <[email protected]>  2001-09-14  Bernhard Herzog  <[email protected]>
4866    
4867          * Thuban/UI/identifyview.py (IdentifyListCtrl.selected_shape):          * Thuban/UI/identifyview.py (IdentifyListCtrl.selected_shape):
4868          Handle the case of no layer (i.e. layer is None) properly.          Handle the case of no layer (i.e. layer is None) properly.
4869    
4870          * Thuban/UI/proj4dialog.py (UTMDialog.__init__, Proj4Dialog.__init__):          * Thuban/UI/proj4dialog.py (UTMDialog.__init__, Proj4Dialog.__init__):
4871          Set the initial selection of the combo boxes to reflect the          Set the initial selection of the combo boxes to reflect the
4872          projection we're starting with in a way that works on windows,          projection we're starting with in a way that works on windows,
4873          too.          too.
# Line 721  Line 4977 
4977          (MainWindow.identify_view_on_demand): Store the interactor in an          (MainWindow.identify_view_on_demand): Store the interactor in an
4978          instvar and use that reference instead of going through main.app          instvar and use that reference instead of going through main.app
4979    
4980          * Thuban/UI/mainwindow.py (MainWindow.ShowSessionTree):          * Thuban/UI/mainwindow.py (MainWindow.ShowSessionTree):
4981          * Thuban/UI/application.py (ThubanApplication.OnInit):          * Thuban/UI/application.py (ThubanApplication.OnInit):
4982          * Thuban/UI/main.py (main): Create the session tree view in main          * Thuban/UI/main.py (main): Create the session tree view in main
4983          with the new mainwindow method ShowSessionTree and not directly          with the new mainwindow method ShowSessionTree and not directly
4984          the application's OnInit method          the application's OnInit method
# Line 738  Line 4994 
4994          layer to the tableview dialog.          layer to the tableview dialog.
4995    
4996          * Thuban/UI/tableview.py: Add some doc-strings          * Thuban/UI/tableview.py: Add some doc-strings
4997          (TableGrid):          (TableGrid):
4998          (TableGrid.OnRangeSelect):          (TableGrid.OnRangeSelect):
4999          (TableGrid.OnSelectCell):          (TableGrid.OnSelectCell):
5000          (TableFrame.__init__):          (TableFrame.__init__):
# Line 805  Line 5061 
5061  2001-09-05  Bernhard Herzog  <[email protected]>  2001-09-05  Bernhard Herzog  <[email protected]>
5062    
5063          * Thuban/UI/view.py (MapCanvas.__init__): New argument, interactor.          * Thuban/UI/view.py (MapCanvas.__init__): New argument, interactor.
5064            
5065          * Thuban/UI/mainwindow.py (MainWindow.__init__): New argument          * Thuban/UI/mainwindow.py (MainWindow.__init__): New argument
5066          interactor to pass through to the MapCanvas          interactor to pass through to the MapCanvas
5067            
5068          * Thuban/UI/application.py (ThubanApplication.OnInit): Use the new          * Thuban/UI/application.py (ThubanApplication.OnInit): Use the new
5069          argument to the MainWindow constructor to get rid of the ugly hack          argument to the MainWindow constructor to get rid of the ugly hack
5070          that made main.app available early just so that the mapcanvas          that made main.app available early just so that the mapcanvas
# Line 855  Line 5111 
5111          (ThubanInstall.run): Remove the leading install root from the          (ThubanInstall.run): Remove the leading install root from the
5112          script filename if an install root was specified and use the new          script filename if an install root was specified and use the new
5113          link_file method          link_file method
5114            
5115          * Thuban/UI/mainwindow.py (MainWindow.AddLayer): Fit the map to          * Thuban/UI/mainwindow.py (MainWindow.AddLayer): Fit the map to
5116          the window when the first layer is added to the map.          the window when the first layer is added to the map.
5117    
# Line 892  Line 5148 
5148          (InnoIconItem): Helper class for bdist_inno          (InnoIconItem): Helper class for bdist_inno
5149          (thuban_bdist_inno): Thuban specific version of bdist_inno. Added          (thuban_bdist_inno): Thuban specific version of bdist_inno. Added
5150          this together with the appropriate parameters, to the setup call.          this together with the appropriate parameters, to the setup call.
5151            
5152          * setup.cfg (bdist_inno): added new section for the inno setup          * setup.cfg (bdist_inno): added new section for the inno setup
5153          installer          installer
5154    

Legend:
Removed from v.256  
changed lines
  Added in v.1272

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26