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

Legend:
Removed from v.311  
changed lines
  Added in v.1260

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26