/[thuban]/branches/greater-ms3/thuban/ChangeLog
ViewVC logotype

Diff of /branches/greater-ms3/thuban/ChangeLog

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

revision 152 by bh, Tue May 7 17:01:49 2002 UTC revision 906 by jonathan, Wed May 14 11:16:59 2003 UTC
# Line 1  Line 1 
1    2003-05-14  Jonathan Coles   <[email protected]>
2    
3            * Thuban/Model/classgen.py (ClassGenerator.GenSingletonsFromList):
4            Fix docstring.
5            (ClassGenerator.GenUniformDistribution): Fix spelling of method name.
6            (ClassGenerator.GenQuantiles): Use the left/right brackets and min/max
7            values of the supplied range to determine the beginning and end
8            bounds of the generated classes.
9    
10            * Thuban/Model/range.py (Range.number_re): Now accepts floats that
11            do not have a leading 0 (.5 is now accepted as well as 0.5).
12    
13            * Thuban/UI/classgen.py (ClassGenDialog.OnOK): Fix name of method
14            call to ClassGenerator.GenUniformDistribution.
15    
16            * Thuban/UI/projdialog.py (ProjFrame.__do_layout): Fix Windows
17            layout bug with the 'Projection' label.
18    
19            * test/support.py (FloatTestCase): New. Needed for the Range tests.
20    
21            * test/test_range.py: New. Imported from SciParam.
22    
23    2003-05-12  Jonathan Coles   <[email protected]>
24    
25            * Thuban/UI/classgen.py (GenQuantilesPanel.GetList): Replace call
26            to table.UniqueValues() with calls that retrieve all the values
27            from the table. This will need to be replaced by a method on table
28            which can simply return the list (perhaps more efficiently).
29    
30    2003-05-12  Jonathan Coles   <[email protected]>
31    
32            The return value of ClassGenerator.CalculateQuantiles has changed.
33            Refer to the documentation for details.
34    
35            * test/test_classgen.py: Modified Quantile tests to use the
36            new return values.
37    
38            * Thuban/Model/classgen.py
39            (ClassGenerator.GenQuantiles): Add comments describing the parameters,
40            use new return values from CalculateQuantiles to produce the correct
41            range bounds in the Classification.
42            (ClassGenerator.CalculateQuantiles): Add more comments describing
43            the return values and parameters. Make minor adjustments to improve
44            the legibility of the code. Fix problem with adjusted not being set
45            in most cases.
46    
47    2003-05-12  Frank Koormann <[email protected]>
48            
49            * Thuban/Model/save.py (XMLWriter.encode()): Explicite call to unicode
50            and latin1. Fixes #1851 finally.
51    
52    2003-05-09  Jonathan Coles   <[email protected]>
53    
54            * test/test_classgen.py: New. Tests the Quantile algorithm.
55    
56            * Thuban/Model/classgen.py (ClassGenerator.CalculateQuantiles):
57            Clean up debugging statement, add comments, fix a small bug in the
58            returned adjusted percentiles.
59            
60    2003-05-09  Jonathan Coles   <[email protected]>
61    
62            Introduces Range class from SciParam into the ClassGroupRange class,
63            and such ranges can now be saved and loaded from disk.
64    
65            Quantiles are now available in the Classification Generator.
66    
67            Initial support for building Queries on a table. Doesn't do anything
68            but run some tests.
69    
70            * Thuban/Model/classification.py: Explicit imports.
71            (ClassGroupRange): Use the Range class to store the underlying
72            range information. The interface remains the same, except for
73            GetRange(), and you can also supply a Range object as the min
74            parameter to SetRange or __init__.
75    
76            * Thuban/Model/load.py (XMLReader.encode): New. Encodes the given
77            string appropriately for use in Thuban. Fixes RTbug #1851.
78            (SessionLoader.end_projection): Handle the context of the
79            projection tag a bit better by looking at what objects are not
80            None. There was an assumption that a projection tag for a map
81            could occur before any layers.
82            (SessionLoader.start_clrange): Provide backward compatibility for
83            reading min/max values as well as the new range parameter.
84    
85            * Thuban/Model/map.py: Explicit imports.
86    
87            * Thuban/Model/resource.py: Import _.
88            (ProjFileSaver.write): write header using projfile.dtd.
89    
90            * Thuban/Model/save.py: Explicit imports.
91            (XMLWriter.encode): New. Encode the given string from a format
92            used by Thuban into UTF-8. Fixes RTbug #1851.
93    
94            * Thuban/UI/classgen.py: Explicit imports.
95            (ClassGenDialog.__init__): Clean up the code and add support
96            for Quantiles.
97            (ClassGenDialog.OnOK): Add support for Quantiles.
98            (GenQuantilesPanel): New. Input panel for Quantiles.
99            (ClassGenerator, CustomRamp, MonochromaticRamp, GreyRamp, RedRamp,
100            GreenRamp, BlueRamp, HotToColdRamp): Move to Thuban/Model/classgen.py
101    
102            * Thuban/Model/classgen.py: New. Contains all the classes named above.
103    
104            * Thuban/UI/classifier.py: Explicit imports.
105            (ClassTable.GetValueAsCust, ClassTable.__ParseInput,
106            ClassTable.SetValueAsCustom): Reworked to use new Range class.
107    
108            * Thuban/UI/legend.py: Explicit imports.
109    
110            * Thuban/UI/mainwindow.py: Add support for the Join Dialog. Added
111            a Table menu and associated method calls.
112            (MainWindow.choose_color): Removed. No longer needed.
113    
114            * Thuban/UI/projdialog.py (ProjFrame.__VerifyButtons): Save button
115            should be disabled if no projection is selected in the available
116            list.
117    
118            * Thuban/UI/renderer.py: Explicit imports.
119    
120            * Thuban/UI/tableview.py (TableGrid.OnRangeSelect): Fix some issues
121            with correctly selecting the rows and issuing the right events.
122            Be sure to call Skip() to allow the grid to do some of its own
123            handling which allows the rows to actually be selected.
124            (LayerTableGrid.select_shapes): Rename from select_shape. Supports
125            selecting multiple shapes.
126            (LayerTableFrame): Support for building Queries.
127            (LayerTableFrame.select_shapes): Allow multiple shapes to be selected.
128    
129            * Thuban/UI/tree.py: Explicit imports.
130    
131            * Thuban/UI/view.py (MapCanvas): Delegate "SelectedShapes" so the
132            table view can call it.
133    
134            * test/test_classification.py: Explicit imports.
135            (TestClassification.test_ClassGroupRange): Fix test for new
136            Range class.
137    
138            * Doc/thuban.dtd: Add range parameter for clrange.
139    
140            * Thuban/Model/range.py: Taken from SciParam. Used as the underlying
141            object in ClassGroupRange, and also uesd for inputting ranges in
142            the classifer table and elsewhere.
143    
144            * Thuban/UI/join.py: New. Initial Join dialog. No real functionality
145            yet.
146    
147    2003-05-09  Frank Koormann <[email protected]>
148    
149            * Thuban/UI/scalebar.py (DrawScaleBar): Draw only if interval > 0.0.
150    
151    2003-05-08  Frank Koormann <[email protected]>
152    
153            Coding style updates
154    
155            * test/test_scalebar.py: Replaced tab indentation by spaces.
156    
157            * Thuban/UI/scalebar.py: Explicit imports.
158    
159    2003-05-08  Frank Koormann <[email protected]>
160    
161            * Thuban/UI/scalebar.py
162            (ScaleBar.DrawScalebar): Format string bug fixed.
163    
164    2003-05-08  Frank Koormann <[email protected]>
165    
166            Reorganization of scalebar component (no wx in Thuban/Model)
167    
168            * Thuban/Model/scalebar.py: Rendering moved to Thuban/UI/scalebar.py
169            (deriveInterval):
170            Calculate scalebar interval and unit which fits in width for scale.
171            (roundInterval): Round float.
172    
173            * Thuban/UI/scalebar.py (ScaleBar): Scalebar rendering
174    
175            * test/test_scalebar.py: Test for Thuban/Model/scalebar.py methods.
176    
177            * Thuban/UI/legend.py: Import Thuban.UI.scalebar
178    
179    2003-05-08  Frank Koormann <[email protected]>
180    
181            * Thuban/UI/legend.py (ScalebarBitmap.SetCanvas):
182            Initialize ScaleBar with canvas.map
183    
184            * Thuban/Model/scalebar.py (ScaleBar.roundInterval()): New,
185            round intervals to display smarter lengths
186            (ScaleBar.DrawScalebar): Draw Scalebar only if the map contains a
187            layer. If the maps has no projection applied grey the scalebar.
188    
189    2003-05-07  Frank Koormann <[email protected]>
190            
191            Basic Scalebar features added.
192    
193            * Thuban/Model/scalebar.py (ScaleBar): New, scalebar rendering.
194    
195            * Thuban/UI/legend.py (LegendPanel): Added scalebar bitmap
196            (ScaleBarBitmap): New, links the scalebar bitmap with view messages
197            and the renderer.
198    
199            * Thuban/UI/view.py (MapCanvas.set_view_transform): Issue SCALE_CHANGED.
200    
201            * Thuban/UI/messages.py: SCALE_CHANGED added.
202    
203    2003-05-07  Bernhard Herzog  <[email protected]>
204    
205            * Thuban/Model/session.py (Session.__init__): New instance
206            variable shapestores to hold a list of all open shapestore objects
207            (Session.ShapeStores): New. Accessor method for the shapestores
208            list.
209            (Session._add_shapestore, Session._clean_weak_store_refs): New.
210            Internal methods to maintain the shapestores list.
211            (Session.Tables): New. Return all tables open in the session.
212            (Session.OpenShapefile): Insert the new ShapeStore into the
213            shapestores list.
214    
215            * test/test_session.py (TestSessionSimple.test_initial_state): Add
216            tests for ShapeStores and Tables
217            (TestSessionWithContent.test_shape_stores)
218            (TestSessionWithContent.test_tables): New. Test cases for
219            ShapeStores and Tables
220    
221    2003-05-07  Bernhard Herzog  <[email protected]>
222    
223            * Thuban/Model/transientdb.py (TransientTableBase.ReadRowAsDict):
224            Add comments about the optimizations used.
225            (AutoTransientTable.ReadValue, TransientTableBase.ReadValue): New.
226            Implement the ReadValue table interface method.
227    
228            * test/test_transientdb.py
229            (TestTransientTable.run_iceland_political_tests)
230            (TestTransientTable.test_transient_joined_table): Add tests for
231            ReadValue
232    
233    2003-05-07  Frank Koormann <[email protected]>
234    
235            * Resources/Bitmaps/fulllayerextent.xpm,
236            Resources/Bitmaps/fullselextent.xpm: Replaced the place holders with
237            new icons.
238    
239    2003-05-06  Bernhard Herzog  <[email protected]>
240    
241            * Thuban/Model/transientdb.py (AutoTransientTable.SimpleQuery):
242            New. Simply delegate to the transient table's version.
243    
244            * test/test_transientdb.py
245            (TestTransientTable.test_auto_transient_table_query): New. Test
246            case for AutoTransientTable's SimpleQuery
247    
248    2003-05-06  Bernhard Herzog  <[email protected]>
249    
250            * Thuban/Model/transientdb.py (TransientTableBase.SimpleQuery):
251            Implement a simple query method for the query dialog
252            (TransientTableBase.create): Add an INTEGER PRIMARY KEY that holds
253            the row index or shapeid.
254            (TransientTable.create): Insert the right value of the row index
255            (TransientJoinedTable.create): Copy the row index of the left
256            table to the joined result table
257    
258            * test/test_transientdb.py
259            (TestTransientTable.test_transient_table_read_twice): Fix
260            doc-string
261            (TestTransientTable.test_transient_table_query): New. Test for the
262            SimpleQuery method
263    
264    2003-05-06  Bernhard Herzog  <[email protected]>
265    
266            Convert all table users to use the new table interface. This only
267            covers Thuban itself, not GREAT-ER or other applications built on
268            Thuban yet, so the compatibility interface stays in place for the
269            time being but it now issues DeprecationWarnings.
270    
271            Finally, the new Table interface has a new method, HasColumn.
272    
273            * Thuban/Model/table.py (OldTableInterfaceMixin): All methods
274            issue deprecation warnings when they're. The warnings refer to the
275            caller of the method.
276            (OldTableInterfaceMixin.__deprecation_warning): New. Helper method
277            for the deprecation warnings
278    
279            * test/test_table.py: Ignore the deprecation warnings for the old
280            table in the tests in this module. The purpose of the tests is to
281            test the old interface, after all.
282    
283            * test/test_transientdb.py
284            (TestTransientTable.run_iceland_political_tests): Use the
285            constants for the types. Add a test for HasColumn
286            (TestTransientTable.test_transient_joined_table): Adapt to new
287            table interface. Add a test for HasColumn
288            (TestTransientTable.test_transient_table_read_twice): Adapt to new
289            table interface
290    
291            * Thuban/UI/tableview.py (DataTable.SetTable, DataTable.GetValue):
292            Adapt to new table interface
293    
294            * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Adapt to
295            new table interface
296    
297            * Thuban/UI/controls.py (RecordListCtrl.fill_list)
298            (RecordTable.SetTable): Adapt to new table interface
299    
300            * Thuban/UI/classifier.py (Classifier.__init__)
301            (Classifier.__init__): Adapt to new table interface
302    
303            * Thuban/UI/classgen.py (ClassGenDialog.__init__)
304            (GenUniformPanel._OnRetrieve, GenUniquePanel._OnRetrieve): Adapt
305            to new table interface
306    
307            * Thuban/Model/transientdb.py (TransientTableBase.HasColumn)
308            (AutoTransientTable.HasColumn): Implement the new table interface
309            method
310            (AutoTransientTable.ReadRowAsDict, AutoTransientTable.ValueRange)
311            (AutoTransientTable.UniqueValues): Adapt to new table interface
312    
313            * Thuban/Model/layer.py (Layer.SetShapeStore, Layer.GetFieldType):
314            Adapt to new table interface
315    
316            * test/test_layer.py (TestLayer.open_shapefile): Helper method to
317            simplify opening shapefiles a bit easier.
318            (TestLayer.test_arc_layer, TestLayer.test_polygon_layer)
319            (TestLayer.test_point_layer): Use the new helper method
320            (TestLayer.test_get_field_type): New. Test for the GetFieldType
321            method
322    
323            * test/test_dbf_table.py (TestDBFTable.test_has_column): Test for
324            the new table method
325    
326            * test/test_memory_table.py (TestMemoryTable.test_has_column):
327            Test for the new table method HasColumn
328    
329    2003-05-06  Jonathan Coles   <[email protected]>
330    
331            Addresses the "Selection Extent" wish of RTbug #1787.
332    
333            * Resources/Bitmaps/fulllayerextent.xpm,
334            Resources/Bitmaps/fullselextent.xpm: Bitmaps for layer and selection
335            extent. These are just place holders for the real bitmaps.
336    
337            * Thuban/Model/layer.py (Shape): Since a Shape is immutable only
338            calculate the bounding box once (the first time compute_bbox() is
339            called).
340            (Layer.ShapesBoundingBox): New. Given a list of shape ids, return
341            the bounding box for the shapes in lat/long coordinates.
342    
343            * Thuban/UI/mainwindow.py: Added new "Full selection extent" menu
344            option.
345            (MainWindow.has_selected_shapes): New. Returns true if there are
346            any selected shapes.
347            (MainWindow.FullSelectionExtent): New. Calls
348            MapCanvas.FitSelectedToWindow() when the user selects the menu option.
349            (_has_selected_shapes): New. Returns true if there are any
350            selected shapes.
351    
352            * Thuban/UI/selection.py (Selection.HasSelectedShapes): New. Returns
353            true if there are any selected shapes.
354    
355            * Thuban/UI/view.py (MapCanvas): Added delegated method
356            HasSelectedShapes.
357            (MapCanvas.FitSelectedToWindow): New. Centers and scales any selected
358            shapes on the canvas using the map projection (if any).
359    
360            * test/test_layer.py (TestLayer.test_arc_layer): Add some tests
361            for Layer.ShapesBoundingBox().
362    
363    2003-05-06  Bernhard Herzog  <[email protected]>
364    
365            * Resources/Projections/defaults.proj: Fix spelling of Mercator
366    
367    2003-05-05  Jonathan Coles   <[email protected]>
368    
369            Addresses the "Full Layer Extent" wish of RTbug #1787.
370    
371            * Resources/Projections/defaults.proj: Added UK National Grid.
372    
373            * Thuban/UI/mainwindow.py: Added new "Full layer extent" menu option.
374            (MainWindow.FullLayerExtent): New. Calls MapCanvas.FitLayerToWindow()
375            when the user selects the menu option.
376    
377            * Thuban/UI/view.py (MapCanvas.FitLayerToWindow): New. Centers and
378            scales the given layer on the canvas using the map projection.
379    
380    2003-05-05  Bernhard Herzog  <[email protected]>
381    
382            Convert the table implementations to a new table interface. All
383            tables use a common mixin class to provide backwards compatibility
384            until all table users have been updated.
385    
386            * Thuban/Model/table.py (OldTableInterfaceMixin): Mixin class to
387            provide backwards compatibility for table classes implementing the
388            new interface
389            (DBFTable, MemoryTable): Implement the new table interface. Use
390            OldTableInterfaceMixin as base for compatibility
391            (DBFColumn, MemoryColumn): New. Column description for DBFTable
392            and MemoryTable resp.
393    
394            * test/test_dbf_table.py: New. Test cases for the DBFTable with
395            the new table interface.
396    
397            * test/test_memory_table.py: New. Test cases for the MemoryTable
398            with the new table interface.
399    
400            * test/test_table.py: Document the all tests in this file as only
401            for backwards compatibility. The equivalent tests for the new
402            interface are in test_memory_table.py and test_dbf_table.py
403            (MemoryTableTest.test_read): field_info should be returning tuples
404            with four items
405            (MemoryTableTest.test_write): Make doc-string a more precise.
406    
407            * Thuban/Model/transientdb.py (TransientTableBase): Convert to new
408            table interface. Derive from from OldTableInterfaceMixin for
409            compatibility.
410            (TransientTableBase.create): New intance variable column_map to
411            map from names and indices to column objects
412            (TransientTable.create): Use the new table interface of the input
413            table
414            (AutoTransientTable): Convert to new table interface. Derive from
415            from OldTableInterfaceMixin for compatibility.
416            (AutoTransientTable.write_record): Removed. It's not implemented
417            yet and we still have to decide how to handle writing with the new
418            table and data framework.
419    
420            * test/test_transientdb.py
421            (TestTransientTable.run_iceland_political_tests)
422            (TestTransientTable.test_transient_joined_table): Use the new
423            table interface
424    
425    2003-05-05  Jonathan Coles   <[email protected]>
426    
427            This is namely a collection of UI updates to improve user interactivity.
428            Tabbing between controls now exists and you can use ESC to close dialog
429            boxes; ENTER will active the default button.
430    
431            * Thuban/UI/classgen.py (ClassGenDialog.__init__): Rearrange the
432            order that the controls are created so that tabbing works correctly.
433            (ClassGenDialog.OnOK): Renamed from _OnGenerate() so that the
434            wxDialog can handle the default button correctly.
435            (ClassGenDialog.OnCancel): Renamed from _OnCloseBtn() for the
436            same reasons as for OnOK.
437            (GenUniformPanel._OnRetrieve): Call wxBeginBusyCursor/wxEndBusyCursor
438            when we ask the table for the maximum/minimum values of a field
439            which could take a very long time.
440    
441            * Thuban/UI/classifier.py (Classifier.__init__): Rearrange the
442            order that the controls are created so that tabbing works correctly.
443            (SelectPropertiesDialog.__init__): Rearrange the order that the
444            controls are created so that tabbing works correctly.
445    
446            * Thuban/UI/dialogs.py: Copied NonModalDialog box and changed it
447            to derive from a wxDialog but behave like the original implementation
448            which was derived from a wxFrame. wxDialog provides useful key
449            handling functionality like ESC calling OnCancel and ENTER calling
450            OnOK which is lost with wxFrame.
451    
452            * Thuban/UI/mainwindow.py: Add "..." to menu items that will open
453            new dialogs.
454    
455            * Thuban/UI/projdialog.py (ProjFrame.__init__): Rearrange the
456            order that the controls are created so that tabbing works correctly.
457            (ProjFrame.OnApply): Renamed from _OnTry() to use wxDialog behaviour.
458            (ProjFrame.OnOK): Renamed from _OnOK() to use wxDialog behaviour.
459            (ProjFrame.OnCancel): Renamed from _OnClose() to use wxDialog behaviour.
460            (ProjPanel.__init__): Add "Airy" to the list of ellipsoids so we
461            can provide the "UK National Grid" as a default projection.
462            (UTMPanel.__init__): Rearrange the order that the controls are
463            created so that tabbing works correctly.
464    
465    2003-05-05  Bernhard Herzog  <[email protected]>
466    
467            * extensions/thuban/wxproj.cpp: Fix some of the comments.
468            (project_point): If a map projection but no layer projection is
469            given, convert degrees to radians before applying the map
470            projection.
471    
472            * Thuban/UI/tableview.py (TableGrid.disallow_messages)
473            (TableGrid.allow_messages): New methods to make it possible to
474            inhibit message sending.
475            (TableGrid.issue): Only send the message if not inhibited.
476            (LayerTableGrid.select_shape): Use the new methods to make sure
477            that no ROW_SELECTED message is sent while we're updating the
478            selected rows to match the selected shapes.
479    
480    2003-05-02  Jan-Oliver Wagner <[email protected]>
481    
482            Implementation of MemoryTable.
483    
484            * Thuban/Model/table.py (MemoryTable): New. Quite simple table
485            implementation that operates on a list of tuples. All of the data
486            are kept in the memory.
487    
488            * test/test_table.py (MemoryTableTest): New.
489    
490            * test/test_transientdb.py (SimpleTable): Removed.
491            (TestTransientTable.test_transient_joined_table,
492            (TestTransientTable.test_transient_table_read_twice): Replaced
493            SimpleTable by MemoryTable.
494    
495    2003-04-30  Jonathan Coles   <[email protected]>
496    
497            * Data/iceland_sample.thuban: Now contains correct projections
498            for each of the layers.
499    
500            * Resources/Projections/defaults.proj: Geographic projection
501            contains unit conversion parameter.
502    
503    2003-04-30  Jonathan Coles   <[email protected]>
504    
505            The most important part of this putback is the projection changes.
506            It should now be possible to specify the projection that a layer
507            is in and then specify a different projection for the map. The
508            projection dialog has an extra parameter for a geographic projection
509            which lets the user select if the input is in degrees or radians.
510    
511            * Thuban/Model/layer.py (Layer.ShapesInRegion): Fix docstring
512            to say that the parameter is a tuple of unprojected
513            points (which is what the callers to this method were assuming).
514            Also, since the points are unprojected we need to projected them.
515    
516            * Thuban/UI/legend.py (LegendTree.MoveCurrentItemUp,
517            LegendTree.MoveCurrentItemDown): If the layer or any of the layer's
518            groups are selected, move the layer up/down. Fixes RTbug #1833.
519    
520            * Thuban/UI/mainwindow.py: Move menu item map_rename up.
521    
522            * Thuban/UI/projdialog.py (ProjFrame._OnSave): Add missing
523            parameter in call to SetClientData.
524            (GeoPanel): Add support for selecting the units that the
525            source data is in (Radians or Degrees).
526    
527            * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Optimize
528            the rendering loop by reducing the number of if's, removing the
529            unnecessary try/except block, and checking if the old group
530            is the same as the new one (which happens a lot if there is
531            no classification, or lots of shapes are in the same group).
532    
533            * Thuban/UI/view.py (MapCanvas.OnPaint): Add a try/except block
534            around the redraw routine to try to catch problems that the user
535            may create by selecting invalid projections for the data set and
536            map. Clears the display if there are any problems and prints the
537            error.
538            (MapCanvas.do_redraw): Use DC.Clear() instead of drawing a filled
539            rectangle.
540    
541            * extensions/thuban/wxproj.cpp (project_point): First invert the
542            supplied point (which should be in projected coordinates) using
543            the layer's projection and then project the point using the
544            map's projection.
545            (project_points): Use project_point() to project each point.
546    
547    2003-04-30  Jan-Oliver Wagner <[email protected]>
548    
549            * Thuban/Model/layer.py (Layer.SetShapeStore): Fixed a bug:
550            don't set the Classification to None if the classfication field
551            is None (ie only a DEFAULT).
552    
553    2003-04-30  Bernhard Herzog  <[email protected]>
554    
555            * Thuban/UI/view.py: Fix some typos.
556    
557            * Thuban/UI/mainwindow.py (MainWindow.identify_view_on_demand): Do
558            not pop up the dialog if the selection becomes empty (this could
559            happen if e.g. a new selection is opened while the identify tool
560            is active and dialog had been closed)
561    
562    2003-04-30  Bernhard Herzog  <[email protected]>
563    
564            * Thuban/Model/transientdb.py (TransientTableBase.__init__): New
565            instance variable read_record_last_result
566            (TransientTableBase.read_record): Make sure reading the same
567            record twice works. The implementation uses the new instance
568            variable read_record_last_result
569    
570            * test/test_transientdb.py
571            (TestTransientTable.test_transient_table_read_twice): New test
572            case for the above bug-fix.
573    
574    2003-04-29  Jonathan Coles   <[email protected]>
575    
576            * Thuban/common.py: Removed. No longer needed Str2Num. RTbug #1832.
577    
578            * Thuban/UI/classgen.py: Remove all uses of Str2Num.
579    
580            * Thuban/UI/classifier.py: Remove all uses of Str2Num.
581            (ClassTable.SetValueAsCustom): Rename keyword argument in
582            ClassGroup* constructors to match argument name.
583    
584    2003-04-29  Bernhard Herzog  <[email protected]>
585    
586            * Thuban/Model/session.py (Session.Destroy): Explicitly close the
587            transient DB if it exists to make sure it doesn't leave a journal
588            file in the temp directory.
589    
590            * Thuban/Model/transientdb.py (TransientDatabase.close): Set
591            self.conn to None after closing the connection to make sure it's
592            not closed twice
593    
594    2003-04-29  Jonathan Coles   <[email protected]>
595    
596            Add a visible parameter in the layer XML tag. The default value is
597            "true". If anything other than "false" is specified we also assume
598            "true". Addresses RTbug #1025.
599    
600            * Doc/thuban.dtd: Add visible parameter to a layer.
601    
602            * Thuban/Model/layer.py (BaseLayer.__init__): Change default value
603            of visible from 1 to True.
604            (Layer.__init__): Change default value of visible from 1 to True.
605    
606            * Thuban/Model/load.py (SessionLoader.start_layer): Read visible
607            parameter.
608    
609            * Thuban/Model/save.py (SessionSaver.write_layer): Save visible
610            parameter.
611    
612            * test/test_load.py: Add new test data contents_test_visible.
613            (LoadSessionTest.setUp): save test data.
614            (LoadSessionTest.testLayerVisibility): Test if the visible flag
615            is loaded correctly.
616    
617            * test/test_save.py (SaveSessionTest.testSingleLayer): Add test
618            for saving an invisible layer.
619    
620    2003-04-29  Jonathan Coles   <[email protected]>
621    
622            * Thuban/UI/mainwindow.py (MainWindow.SetMap): Look up the
623            legend dialog box and tell it to change its map to the one
624            supplied to SetMap(). Fixes RTbug #1770.
625    
626    2003-04-29  Bernhard Herzog  <[email protected]>
627    
628            Next step of table implementation. Introduce a transient database
629            using SQLite that some of the data is copied to on demand. This
630            allows us to do joins and other operations that require an index
631            for good performance with reasonable efficiency. Thuban now needs
632            SQLite 2.8.0 and pysqlite 0.4.1. Older versions may work but I
633            haven't tested that.
634            
635            * Thuban/Model/transientdb.py: New. Transient database
636            implementation.
637    
638            * test/test_transientdb.py: New. Tests for the transient DB
639            classes.
640    
641            * Thuban/Model/session.py (AutoRemoveFile, AutoRemoveDir): New
642            classes to help automatically remove temporary files and
643            directories.
644            (Session.__init__): New instance variables temp_dir for the
645            temporary directory and transient_db for the SQLite database
646            (Session.temp_directory): New. Create a temporary directory if not
647            yet done and return its name. Use AutoRemoveDir to have it
648            automatically deleted
649            (Session.TransientDB): Instantiate the transient database if not
650            done yet and return it.
651    
652            * Thuban/Model/data.py (ShapefileStore.__init__): Use an
653            AutoTransientTable so that data is copied to the transient DB on
654            demand.
655            (SimpleStore): New class that simply combines a table and a
656            shapefile
657    
658            * Thuban/Model/table.py (Table, DBFTable): Rename Table into
659            DBFTable and update its doc-string to reflect the fact that this
660            is only the table interface to a DBF file. Table is now an alias
661            for DBFTable for temporary backwards compatibility.
662    
663            * Thuban/UI/application.py (ThubanApplication.OnExit): Make sure
664            the last reference to the session goes away so that the temporary
665            files are removed properly.
666    
667            * test/test_load.py (LoadSessionTest.tearDown): Remove the
668            reference to the session to make sure the temporary files are
669            removed.
670    
671    2003-04-29  Bernhard Herzog  <[email protected]>
672    
673            * Thuban/Model/load.py (XMLReader.__init__, XMLReader.read): Turn
674            the __parser instance variable into a normal local variable in
675            read. It's only used there and read will never be called more than
676            once. Plus it introduces a reference cycle that keeps can keep the
677            session object alive for a long time.
678    
679    2003-04-29  Jonathan Coles   <[email protected]>
680    
681            * Thuban/Model/proj.py (Projection): Removed Set*() methods to make
682            Projection an immutable item. Fixes RTbug #1825.
683            (Projection.__init__): Initialize instance variables here.
684            (ProjFile.Replace): New. Replace the given projection object with
685            the new projection object. This solves the problem of needing the
686            mutator Projection.SetProjection() in the ProjFrame class and
687            allows a projection to change parameters without changing its
688            location in the file.
689    
690            * Thuban/UI/mainwindow.py (MainWindow.SaveSessionAs): Dialog should
691            be of type wxSAVE and should verify overwriting a file.
692    
693            * Thuban/UI/projdialog.py (ProjFrame._OnSave): Use the new
694            ProjFile.Replace() method instead of the mutator
695            Projection.SetProjection(). Also requires that we reassign the
696            client data to the new projection.
697    
698            * test/test_proj.py (TestProjection.test): Test GetName() and
699            GetAllParameters()
700            (TestProjFile.test): Remove tests for Set*() methods. Add tests
701            for Replace().
702    
703    2003-04-25  Jonathan Coles   <[email protected]>
704    
705            * Thuban/Model/save.py (SessionSaver.write_projection): Make sure
706            to save the name of the projection.
707    
708            * test/test_save.py (SaveSessionTest.testLayerProjection): New
709            test to verify layer projections are saved correctly.
710    
711    2003-04-25  Jonathan Coles   <[email protected]>
712    
713            * Thuban/Model/proj.py (Projection.SetName): Set the name
714            to "Unknown" if name is None.
715            (Projection.SetAllParameters): New. Set the projection's
716            parameter list to the one supplied.
717            (Projection.SetProjection): New. Set the projection's
718            properties to those of the supplied Projection.
719    
720            * Thuban/UI/mainwindow.py (MainWindow.MapProjection): Set
721            the dialog title to include the map's title.
722            (MainWindow.LayerProjection): Set the dialog title to include
723            the layer's title.
724    
725            * Thuban/UI/projdialog.py (ProjFrame.__ShowError): Consolidate
726            error dialogs into a single method call.
727            (ProjFrame.__VerifyButtons): Add more states to check.
728            (ProjFrame.__GetProjection): Return the current state of an
729            edited projection or None.
730            (ProjFrame.__FillAvailList): Remove checks for states that
731            shouldn't exist.
732            (ProjFrame._OnNew): Clear all selected items and supply
733            a projection panel if necessary.
734    
735            * test/test_proj.py (TestProjFile.test): Add tests for
736            ProjFile.SetAllParameters, ProjFile.SetProjection,
737            ProjFile.SetName.
738    
739    2003-04-25  Jonathan Coles   <[email protected]>
740    
741            * Thuban/UI/projdialog.py (ProjFrame.__FillAvailList): Now
742            takes an optional argument to select the current projection.
743            This does not guarantee that the item is visible due to
744            limited wxWindows functionality. Fixes RTBug #1821.
745    
746    2003-04-25  Jonathan Coles   <[email protected]>
747    
748            * Thuban/Model/load.py (SessionLoader.start_projection): Remember
749            the projection name and use it when constructing the Projection
750            object.
751    
752            * Thuban/Model/proj.py (Projection.__init__): Change the default
753            value for 'name' to None and then test if name is equal to None
754            in the body of the constructor. This way the caller doesn't have to
755            know what the default value should be. Namely, useful in load.py
756            where we have to pick a default value if the 'name' parameter
757            doesn't exist in the XML file.
758    
759            * test/test_load.py (LoadSessionTest.testLayerProjection): New.
760            Tests a file where a layer has a projection.
761    
762    2003-04-25  Jonathan Coles   <[email protected]>
763    
764            * Thuban/Model/layer.py (Layer.TreeInfo): Add an item to the
765            tree for projection information.
766    
767            * Thuban/Model/load.py (XMLReader.GetFilename): Renamed from
768            XMLReader.GetFileName.
769            (SessionLoader): Added support for loading projection tags that
770            appear inside a layer.
771    
772            * Thuban/Model/proj.py (ProjFile): Document the class. Move
773            back to using a list because the order of the projections in
774            the file is important to maintain. Fixes RTbug #1817.
775    
776            * Thuban/Model/resource.py: Rename calls to ProjFile.GetFileName
777            to ProjFile.GetFilename.
778    
779            * Thuban/Model/save.py (SessionSaver.write_layer): Save projection
780            information.
781    
782            * Thuban/UI/projdialog.py (ProjFrame._OnAddToList): Renamed from
783            ProjFrame._OnSaveAs. Removed old dead code from previous
784            implementation.
785            (ProjFrame._OnExport): Add support for exporting more than one
786            projection to a single file.
787            (ProjFrame.__FillAvailList): use string formatting (% operator)
788            to build strings that are (partly) translated. Fixes RTbug #1818.
789    
790            * test/test_proj.py (TestProjFile.test): New. Tests the base ProjFile
791            class.
792    
793    2003-04-24  Bernhard Herzog  <[email protected]>
794    
795            * po/es.po: Updated Spanish translation by Daniel Calvelo Aros
796    
797            * po/fr.po: New. French translation by Daniel Calvelo Aros
798    
799            * Thuban/UI/projdialog.py (ProjFrame._OnSaveAs): Don't translate
800            empty strings.
801    
802    2003-04-24  Jonathan Coles   <[email protected]>
803    
804            * Thuban/Model/layer.py (Layer.GetProjection): New. Needed to
805            implement the interface that the ProjFrame dialog expects.
806    
807            * Thuban/Model/proj.py (Projection.SetName): New. Allows the
808            name of the projection to be changed.
809            (ProjFile): Use a dictionary instead of a list so that removing
810            projections is easier and we are sure about uniqueness.
811            (ProjFile.Remove): Remove the given projection object.
812    
813            * Thuban/Model/resource.py (GetSystemProjFiles, GetUserProjFiles):
814            Return a list with only one projection file instead of searching for
815            any projection file. This simplifies many things if the user can
816            only have one system file and one user file.
817    
818            * Thuban/UI/classgen.py: Change all references to
819            genCombo to genChoice.
820    
821            * Thuban/UI/mainwindow.py: Add a Projection option under the
822            layer menu.
823            (MainWindow.LayerProjection): New. Open up a projection window
824            for a layer.
825    
826            * Thuban/UI/projdialog.py: Large changes to how the dialog is
827            laid out. Use three panels instead of one. One for the list of
828            projections, one for the edit controls, and one for the buttons.
829            Fixed resizing problems so that the dialog resizes correctly
830            when the projection panel changes. Added import/export, save, and
831            new buttons/functionality.
832    
833    2003-04-24  Bernhard Herzog  <[email protected]>
834    
835            First step towards table management. Introduce a simple data
836            abstraction so that we replace the data a layer uses more easily
837            in the next step.
838    
839            * Thuban/Model/data.py: New file with a simple data abstraction
840            that bundles shapefile and dbffile into one object.
841    
842            * Thuban/Model/session.py (Session.OpenShapefile): New method to
843            open shapefiles and return a shape store object
844    
845            * Thuban/Model/layer.py (Layer.__init__): Pass the data as a store
846            object instead of a shapefile filename. This introduces a new
847            instance variable store holding the datastore. For intermediate
848            backwards compatibility keep the old instance variables.
849            (open_shapefile): Removed. No longer needed with the shape store.
850            (Layer.SetShapeStore, Layer.ShapeStore): New methods to set and
851            get the shape store used by a layer.
852            (Layer.Destroy): No need to explicitly destroy the shapefile or
853            table anymore.
854    
855            * Thuban/UI/mainwindow.py (MainWindow.AddLayer)
856            (MainWindow.AddLayer): Use the session's OpenShapefile method to
857            open shapefiles
858    
859            * Thuban/Model/load.py (ProcessSession.start_layer): Use the
860            session's OpenShapefile method to open shapefiles
861    
862            * test/test_classification.py
863            (TestClassification.test_classification): Use the session's
864            OpenShapefile method to open shapefiles and build the filename in
865            a more platform independed way
866    
867            * test/test_layer.py (TestLayer.setUp, TestLayer.tearDown):
868            Implement to have a session to use in the tests
869            (TestLayer.test_arc_layer, TestLayer.test_polygon_layer)
870            (TestLayer.test_point_layer, TestLayer.test_empty_layer): Use the
871            session's OpenShapefile method to open shapefiles
872            (TestLayerLegend.setUp): Instantiate a session so that we can use
873            it to open shapefiles.
874            (TestLayerLegend.tearDown): Make sure that all references to
875            layers and session are removed otherwise we may get a resource
876            leak
877    
878            * test/test_map.py (TestMapAddLayer.test_add_layer)
879            (TestMapWithContents.setUp): Instantiate a session so that we can
880            use it to open shapefiles.
881            (TestMapWithContents.tearDown): Make sure that all references to
882            layers, maps and sessions are removed otherwise we may get a
883            resource leak
884            ("__main__"): use support.run_tests() so that more info about
885            uncollected garbage is printed
886    
887            * test/test_save.py (SaveSessionTest.testSingleLayer): Use the
888            session's OpenShapefile method to open shapefiles
889            ("__main__"): use support.run_tests() so that more info about
890            uncollected garbage is printed
891    
892            * test/test_selection.py (TestSelection.tearDown): Make sure that
893            all references to the session and the selection are removed
894            otherwise we may get a resource leak
895            (TestSelection.get_layer): Instantiate a session so that we can
896            use it to open shapefiles.
897            ("__main__"): use support.run_tests() so that more info about
898            uncollected garbage is printed
899    
900            * test/test_session.py (TestSessionBase.tearDown)
901            (TestSessionWithContent.tearDown): Make sure that all references
902            to the session and layers are removed otherwise we may get a
903            resource leak
904            (TestSessionWithContent.setUp): Use the session's OpenShapefile
905            method to open shapefiles
906    
907    2003-04-24  Jonathan Coles   <[email protected]>
908    
909            * Thuban/Model/load.py (XMLReader.read): Should have been checking
910            if the file_or_filename object had the 'read' attribute.
911    
912    2003-04-23  Jonathan Coles   <[email protected]>
913    
914            * Thuban/Model/resource.py: Fixes RTbug #1813.
915            (ReadProjFile): Add documentation about which exceptions are raised.
916            Always pass the exceptions up to the caller.
917            (GetProjFiles): If the directory can't be read return an empty list.
918            If any of the proj files can't be read skip that file and go
919            on to the next one.
920    
921            * test/test_proj.py: Added test cases to handle nonexistent files,
922            unreadable files, and files that don't parse correctly.
923    
924    2003-04-23  Jonathan Coles   <[email protected]>
925    
926            Projection dialog. Allows the user to select from a list
927            of projection templates and optionally edit them and save new ones.
928    
929            * Thuban/UI/projdialog.py (ProjFrame): New. Main dialog.
930            (ProjPanel): Base class for projection specific panels.
931            (TMPanel): Projection panel for Transverse Mercartor.
932            (UTMPanel): Projection panel for Universal Transverse Mercartor.
933            (LCCPanel): Projection panel for Lambert Conic Conformal.
934            (GeoPanel): Projetion panel for Geographic Projection.
935    
936    2003-04-23  Jonathan Coles   <[email protected]>
937    
938            * Thuban/Model/load.py (XMLReader): Renamed from XMLProcessor to
939            promote symmetry. There now exists XMLReader and XMLWriter.
940            (XMLReader.read): New. Call to read the given file descriptor or
941            filename.
942            (XMLReader.close): New. Make sure the file is closed.
943            (XMLReader.GetFileName): New. Return just the file name that is being
944            read from.
945            (XMLReader.GetDirectory): New. Return just the directory of the file
946            that is being read.
947            (XMLReader.AddDispatchers): New. Take a dictionary which contains
948            the names of functions to call as the XML tree is parsed.
949            (XMLReader.startElementNS): Updated to use new dispatcher dictionary.
950            (XMLReader.endElementNS): Updated to use new dispatcher dictionary.
951            (SessionLoader): Removed class variables start_dispatcher and
952            end_dispatcher since this functionality is now part of a class
953            instance. Fixes RTbug #1808.
954            (SessionLoader.__init__): Add dispatcher functions.
955            (load_xmlfile): Code was moved into the XMLReader.read().
956            (load_session): Use modified SessionLoader.
957    
958            * Thuban/Model/map.py (Map.GetProjection): New. Returns the
959            map's projection.
960    
961            * Thuban/Model/proj.py (Projection.GetParameters): Renamed to
962            GetAllParameters.
963            (Projection.GetParameter): Returns the value for the given parameter.
964    
965            * Thuban/Model/resource.py: Use XMLReader and XMLWriter.
966            (GetProjFiles): Renamed from GetProjections. Now returns a list
967            of ProjFile objects.
968            (GetSystemProjFiles): Renamed from GetSuppliedProjections. Returns
969            a list of ProjFile objects whose files are not user defined.
970            (GetUserProjFiles): Renamed from GetUserProjections. Returns a
971            list of ProjFile objects whose files are user defined.
972            (ProjFileReader): Extend new XMLReader.
973    
974            * Thuban/Model/save.py (XMLWriter): Renamed from XMLSaver to
975            promote symmetry.
976    
977            * Thuban/UI/classgen.py (ClassGenDialog.__init__): Use a wxChoice
978            control instead of a wxComboBox. wxChoice controls do not generate
979            events as the uses highlights possible choices which fixes problems
980            with resizing the dialog when the use selects an option.
981    
982            * Thuban/UI/classifier.py (Classifier.__init__): Use a wxChoice
983            control instead of a wxComboBox.
984    
985            * Thuban/UI/mainwindow.py (MainWindow.Projection): Use new projection
986            dialog.
987    
988            * test/test_proj.py (TestProjection.test): New tests for GetParameter
989            method.
990    
991    2003-04-22  Bernhard Herzog  <[email protected]>
992    
993            * Thuban/UI/mainwindow.py: Remove some unused imports and global
994            constants
995    
996            * Thuban/UI/identifyview.py (IdentifyListCtrl.selected_shape)
997            (IdentifyGridCtrl.selected_shape): Use table, not shapetable.
998    
999    2003-04-17  Bernhard Herzog  <[email protected]>
1000    
1001            * Thuban/Model/layer.py: Don't import LAYER_LEGEND_CHANGED.
1002            (Layer): Update doc-string since LAYER_LEGEND_CHANGED is not used
1003            anymore.
1004            (Layer.BoundingBox, Layer.GetFieldType, Layer.NumShapes)
1005            (Layer.ShapeType, Layer.Shape): No need to call
1006            self.open_shapefile since it's always called in __init__
1007    
1008            * Thuban/UI/application.py (ThubanApplication.MainLoop): Removed.
1009            In wxPython 2.4 there's no need to extend MainLoop anymore since
1010            wxPython itself makes sure OnExit is called.
1011    
1012    2003-04-16  Jonathan Coles   <[email protected]>
1013    
1014            Initial putback of projection management code. Includes new
1015            classes to read and write projection files. The current load
1016            and save classes were abstracted a bit so they could be reused.
1017            The Projection class was extended to provide new methods and
1018            have a name.
1019    
1020            * Thuban/Model/load.py (XMLProcessor): New. Contains all the
1021            general XML reading methods that were part of ProcessSession.
1022    
1023            * Thuban/Model/proj.py (Projection.__init__): Accepts an optional
1024            name.
1025            (ProjFile): New. Represents a file that contains projection
1026            information.
1027    
1028            * Thuban/Model/resource.py: New. Contains general utilities
1029            for read and writing projection files.
1030    
1031            * Thuban/Model/save.py (XMLSaver): New. Contains all the
1032            general XML writing methods that were part of SessionSaver.
1033            (SessionSaver): Renamed from Saver.
1034    
1035            * test/test_proj.py: New test cases for the projection
1036            file read and write functions.
1037    
1038    2003-04-16  Jonathan Coles   <[email protected]>
1039    
1040            * Thuban/Model/classification.py: Use repr() around values
1041            in the ClassGroup*.__repr__() methods so it is clearer when
1042            a value is a string and when it is a number.
1043    
1044            * test/test_load.py: Rework the classification test to test
1045            that we can load old files.
1046            (testLabels): Test a file where the groups have labels.
1047    
1048    2003-04-16  Bernhard Herzog  <[email protected]>
1049    
1050            Safer implementation of the performance enhancements of the
1051            low-level renderer:
1052            
1053            * extensions/thuban/wxproj.cpp (extract_projection)
1054            (extract_pointer): Rename extract_projection to extract_pointer
1055            and redefine its purpose to return the pointer stored in a CObject
1056            returned by the object's cobject method. Update all callers.
1057            (s_draw_info, free_draw_info, draw_polygon_init): Implement the
1058            handling of these low-level parameters so that each s_draw_info
1059            instance is handled as a CObject at python level that also
1060            contains real references to the actual python objects which
1061            contain the values in the struct. Add free_draw_info as the
1062            destructor.
1063            (draw_polygon_shape): Add the py_draw_info parameter which must a
1064            cobject containing an s_draw_info pointer.
1065    
1066            * Thuban/UI/renderer.py (MapRenderer.polygon_render_param): New
1067            method to instantiat the low-level render parameter
1068            (MapRenderer.draw_shape_layer): Use the new method. Remove some
1069            commented out code.
1070            (MapRenderer.draw_polygon_shape): Make the first parameter not the
1071            layer but the low-level render parameter
1072            (ScreenRenderer.draw_shape_layer): Use the low-level render
1073            parameter.
1074    
1075    2003-04-15  Jonathan Coles   <[email protected]>
1076    
1077            * Thuban/Model/classification.py: Implemented __repr__ for
1078            the ClassGroup* classes to make debugging a bit easier.
1079            (ClassGroup.SetLabel): Check that the string is an instance
1080            of StringTypes not StringType. Accounts for Unicode strings.
1081    
1082            * Thuban/Model/color.py: Implemented __repr__ to make
1083            debugging a bit easier.
1084    
1085            * Thuban/Model/save.py (Saver.write_classification): Need to
1086            save the group label.
1087    
1088            * test/test_load.py (testClassification): New. Loads the
1089            iceland_sample_test.thuban file and checks if it was loaded
1090            correctly.
1091    
1092    2003-04-15  Jonathan Coles   <[email protected]>
1093    
1094            * extensions/thuban/wxproj.cpp (draw_polygon_init): New. Used
1095            to improve rendering performance by initializing the variables
1096            that are not change each time draw_polygon_shape() is called.
1097            The values are stored in a global struct draw_info.
1098            (draw_polygon_shape): Removed initialization code that is
1099            now in draw_polygon_init().
1100    
1101            * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Make
1102            drawing initialization call to draw_polygon_init()
1103            (MapRenderer.draw_polygon_shape): Use new signature of
1104            draw_polygon_shape.
1105    
1106            * Thuban/UI/classgen.py (GenUniformPanel): Fix spin control
1107            weirdness by setting the range to (1, maxint).
1108    
1109            * Thuban/Model/classification.py (ClassGroupProperties): Make
1110            instance variables private and optimize comparison operator
1111            by first checking if the color references are the same.
1112            (ClassGroupSingleton): Make instance variables private.
1113            (ClassGroupRange): Make instance variables private.
1114    
1115            * HOWTO-Release: Filled in missing steps for releasing packages.
1116    
1117    2003-04-15  Bernhard Herzog  <[email protected]>
1118    
1119            First stab at internationalized messages:
1120    
1121            * Thuban/__init__.py (_): Implement the translation function for
1122            real using the python gettext module.
1123    
1124            * Thuban/UI/classifier.py (ClassTable.GetRowLabelValue): Don't
1125            translate empty strings.
1126    
1127            * Thuban/UI/application.py (ThubanApplication.read_startup_files):
1128            Add a missing space to a warning message
1129    
1130            * po/README: New. Notes about the management of the translation
1131            files.
1132    
1133            * po/Makefile: New. Makefile to help manage the translation files.
1134    
1135            * po/es.po: New. Spanish translation by Daniel Calvelo Aros
1136    
1137            * MANIFEST.in: Include the *.mo files in Resources/Locale and the
1138            translations and support files in po/
1139    
1140            * setup.py (data_files): Add the *.mo files to the data_files too
1141    
1142            * README: Add note about the translations when building from CVS
1143    
1144    2003-04-14  Jonathan Coles   <[email protected]>
1145    
1146            * Thuban/UI/dock.py: Fixes some window resizing problems most
1147            noticable under windows. Always assume the button bitmaps will
1148            be there. Code clean up.
1149            (DockabelWindow.Dock, DockableWindow.UnDock): Force all the
1150            images for the dock/undock button to the same images.
1151            Work around for RTbug #1801.
1152    
1153            * Thuban/UI/legend.py (LegendPanel.__init__): The toolbar should
1154            be allowed to grow within the sizer. Fixes a bug under Windows
1155            where the toolbar wasn't being drawn.
1156    
1157    2003-04-14  Frank Koormann   <[email protected]>
1158    
1159            * Resources/Bitmaps/dock_12.xpm, Resources/Bitmaps/undock_12.xpm:
1160            Updated design to try to make the button functionality more
1161            transparent.
1162    
1163    2003-04-14  Jonathan Coles   <[email protected]>
1164    
1165            * Thuban/UI/legend.py (LegendPanel.__init__): Call Create() to
1166            finalize the intialization of the panel.
1167    
1168            * Thuban/UI/dock.py (DockPanel.Create): New. Finalizes the
1169            creation of the panel. Should be the last thing called in the
1170            initializer of a subclass.
1171    
1172            * Thuban/UI/classgen.py (ClassGenDialog.__init__): Actively
1173            set the current selections in the combo boxes. This is needed
1174            under Windows.
1175    
1176            * Thuban/UI/classifier.py (Classifier.__init__): Add a top
1177            level panel to the dialog so that the background colors are
1178            consistent under Windows.
1179    
1180    2003-04-11  Jonathan Coles   <[email protected]>
1181    
1182            * Thuban/UI/classgen.py: Change color ramps to start at white
1183            not black.
1184    
1185            * Thuban/UI/legend.py: Enable/disable the legend buttons when
1186            the legend changes. Fixes RTbug #1793.
1187    
1188            * test/test_classification.py: Added test for copying of
1189            classifications.
1190    
1191    2003-04-11  Jonathan Coles   <[email protected]>
1192    
1193            * Thuban/UI/resource.py: New. Centralize the loading of resources
1194            such as bitmaps.
1195    
1196            * Thuban/UI/classgen.py (GenUniquePanel.__init__): Reordered buttons,
1197            added images to the move buttons, added 'reverse' button.
1198            (CustomRampPanel.__init__): Added images to the move buttons.
1199            (GreyRamp): New. Generates a ramp from white to black.
1200            (HotToColdRamp): New. Generates a ramp from cold to hot colors.
1201    
1202            * Thuban/UI/classifier.py: Refactored ID's from ID_CLASSIFY_* to
1203            ID_PROPERTY_*.
1204            (Classifier.__init__): Minor changes to the layout.
1205            (Classifier._OnTitleChanged): Listen for when the user edits the
1206            title and update the dialog's title and the layer's title.
1207    
1208            * Thuban/UI/dock.py: Use new bitmaps for the control buttons.
1209    
1210            * Thuban/UI/legend.py: Use new bitmaps for the control buttons.
1211            (LegendTree._OnMsgLayerTitleChanged): Change the displayed title
1212            if the layer's title changes.
1213    
1214            * Thuban/UI/mainwindow.py: Added new menu item and associated code
1215            to open a dialog to rename the map.
1216            (MainWindow): Use new resource class to import bitmaps.
1217    
1218    2003-04-11  Jonathan Coles   <[email protected]>
1219    
1220            * Resources/Bitmaps/close_12.xpm, Resources/Bitmaps/dock_12.xpm,
1221            Resources/Bitmaps/group_use.xpm, Resources/Bitmaps/group_use_all.xpm,
1222            Resources/Bitmaps/group_use_none.xpm,
1223            Resources/Bitmaps/group_use_not.xpm,
1224            Resources/Bitmaps/hide_layer.xpm,
1225            Resources/Bitmaps/layer_properties.xpm,
1226            Resources/Bitmaps/lower_layer.xpm, Resources/Bitmaps/raise_layer.xpm,
1227            Resources/Bitmaps/show_layer.xpm, Resources/Bitmaps/undock_12.xpm:
1228            New.
1229    
1230    2003-04-10  Jonathan Coles   <[email protected]>
1231    
1232            * Thuban/Model/classification.py: (ClassGroupRange.__init__):
1233            Should pass group to ClassGroup constructor.
1234    
1235    2003-04-10  Jonathan Coles   <[email protected]>
1236    
1237            * Thuban/Model/classification.py: (ClassGroup): Move all the common
1238            methods of the derived classes ([Set|Get]Properties(), __eq__, __ne__)
1239            here. Implement SetVisible(), IsVisible().
1240            (ClassGroup.__init__): Add group parameter which acts as a copy
1241            constructor.
1242    
1243            * Thuban/UI/classifier.py (ClassTable): Add a new column for the
1244            "Visible" check boxes.
1245            (Classifier): Rename the buttons and refactor the code to match
1246            the new labels.
1247    
1248            * Thuban/UI/legend.py: Classify button is now called "Properties".
1249            Refactored the code to change variable names.
1250            (LegendTree.__FillTreeLayer): Only list a group if it is visible.
1251    
1252            * Thuban/UI/mainwindow.py: MainWindow.OpenClassifier renamed to
1253            MainWindow.OpenLayerProperties. MainWindow.LayerEditProperties
1254            renamed to MainWindow.LayerEditProperties.
1255            (MainWindow.ToggleLegend): Don't include map name in legend title.
1256            (MainWindow.SetMap): Added the map name to the window title.
1257            (MainWindow.LayerFillColor, MainWindow.LayerTransparentFill,
1258            MainWindow.LayerOutlineColor, MainWindow.LayerNoOutline): Removed.
1259            Functionality is found in the layer properties dialog.
1260    
1261            * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Only
1262            draw visible groups.
1263    
1264    2003-04-09  Jonathan Coles   <[email protected]>
1265    
1266            * Thuban/UI/classgen.py: Modifications to allow simple
1267            addition and selection of new color schemes.
1268            (MonochromaticRamp): New. Generates a ramp between two colors.
1269            (RedRamp): New. Generates a ramp of all red.
1270            (GreenRamp): New. Generates a ramp of all green.
1271            (BlueRamp): New. Generates a ramp of all blue.
1272    
1273    2003-04-09  Jonathan Coles   <[email protected]>
1274    
1275            * Thuban/Model/classification.py (Classification.__deepcopy__):
1276            Need to copy over field and fieldType attributes.
1277    
1278            * Thuban/Model/table.py (Table.field_range): New. Retrive the
1279            maximum and minimum values over the entire table for a given
1280            field.
1281            (Table.GetUniqueValues): New. Retrieve all the unique values
1282            in the table for a given field.
1283    
1284            * Thuban/UI/classgen.py: Renamed GenRangePanel to GenUniformPanel.
1285            (GenUniquePanel): New. Controls to allow the user to select
1286            which unique field values they would like in the classification.
1287            (CustomRampPanel): Code that was in ClassGenDialog that allows
1288            the user to select the properties for a custom ramp.
1289            (ClassGenerator.GenUniformDistribution): Was called GenerateRanges.
1290    
1291            * Thuban/UI/classifier.py: Removed a lot of debugging code.
1292            (Classifier._SetClassification): Callback method so that the
1293            class generator can set the classification in the grid.
1294            (ClassGroupPropertiesCtrl): New. Encapsulates the drawing and
1295            editing of a group properties class into a wxWindows control.
1296    
1297            * Thuban/UI/dock.py: It was decided that if the user closes
1298            a dockable window the window should simply hide itself. That
1299            way if the user wants to show the dock again it appears in the
1300            same place as it was when it was closed.
1301            (DockableWindow.Destroy): Call renamed method OnDockDestroy().
1302            (DockableWindow._OnButtonClose): Hide the window instead of
1303            destroying it.
1304            (DockableWindow._OnClose): Hide the window instead of
1305            destroying it.
1306    
1307            * Thuban/UI/legend.py (LegendTree): Use a private method to
1308            consistently set the font and style of the text. Fixes RTbug #1786.
1309    
1310            * Thuban/UI/mainwindow.py: Import just the Classifier class.
1311    
1312    2003-04-07  Bernhard Herzog  <[email protected]>
1313    
1314            * Thuban/UI/mainwindow.py (main_menu): Move the toggle_legend item
1315            to the map module
1316    
1317    2003-04-07  Bernhard Herzog  <[email protected]>
1318    
1319            * Thuban/UI/mainwindow.py (MainWindow.ShowSessionTree): Removed in
1320            favor of ToggleSessionTree
1321            (MainWindow.ToggleSessionTree): New method to toggle visibility of
1322            the session tree.
1323            (MainWindow.SessionTreeShown): New method to return whether the
1324            session tree is currently shown.
1325            (MainWindow.ToggleLegend): New method to toggle visibility of the
1326            legend
1327            (MainWindow.ShowLegend): Implement in terms of ToggleLegend and
1328            LegendShown
1329            (MainWindow.LegendShown): New method to return whether the legend
1330            is currently shown.
1331            (_method_command): Add checked parameter so we can define check
1332            menu items
1333            (_has_tree_window_shown, _has_legend_shown): Use the appropriate
1334            mainwindow methods.
1335            (show_session_tree, show_legend commands): Removed.
1336            (toggle_session_tree, toggle_legend commands): New commands to
1337            toggle the visibility of the dialogs
1338    
1339    2003-04-07  Jonathan Coles   <[email protected]>
1340    
1341            * Thuban/UI/classgen.py: Fix Windows problem.
1342    
1343            * Thuban/UI/dock.py: Fix Windows problem.
1344    
1345            * Thuban/UI/mainwindow.py: Use False instead of false.
1346            (MainWindow.ShowLegend): Remove unnecessary switch parameter.
1347    
1348    2003-04-07  Jonathan Coles   <[email protected]>
1349    
1350            Since we now say that the order of the groups in a classification
1351            matters, it makes sense to be able to manipulate that order. Most
1352            of the changes to Thuban/Model/classification.py are to that end.
1353    
1354            * Thuban/Model/classification.py (Classification.AppendGroup,
1355            Classification.InsertGroup, Classification.ReplaceGroup,
1356            Classification.RemoveGroup, Classification.GetGroup): Do as the
1357            names imply.
1358            (Classification.FindGroup): This was called GetGroup, but GetGroup
1359            takes an index, while FindGroup takes a value.
1360            (Classification.__deepcopy__): Copy all the groups, BUT NOT THE LAYER
1361            REFERENCE. Currently there is a cyclic reference between the layer
1362            and its classification. If the classification doesn't need to know
1363            its owning layer we can change this, since it may make sense to be
1364            able to use the same classification with different layers.
1365    
1366            * Thuban/Model/load.py: Use Classification.AppendGroup(), not AddGroup()
1367    
1368            * Thuban/UI/classgen.py: Use Classification.AppendGroup(),
1369            not AddGroup()
1370    
1371            * Thuban/UI/classifier.py: Now that we can depend on the order in
1372            a Classification and have methods to manipulate that order we don't
1373            need to use our own data structures in the grid. We can simply make
1374            the grid/table access the information they need from a copy of
1375            the classification object.
1376            (Classifier._OnCloseBtn): Event handler for when the user clicks
1377            'Close'. This is needed so if the user applies changes and then
1378            continues to change the table the user has the option of discarding
1379            the most recent changes and keeping what they applied.
1380    
1381            * Thuban/UI/mainwindow.py: Put "Show Legend" and "Show Session Tree"
1382            into the same group.
1383    
1384            * extensions/thuban/wxproj.cpp (check_version): If Thuban is compiled
1385            with a really old version of proj, PJ_VERSION won't even be defined.
1386            If it isn't defined then just compile so that the function always
1387            returns Py_False.
1388    
1389            * test/test_classification.py: Fix tests to use the renamed methods.
1390            Still need to write tests for the new methods.
1391    
1392    2003-04-04  Jonathan Coles   <[email protected]>
1393    
1394            * Thuban/UI/classifier.py (Classifier.__SelectField): Move the
1395            call to SetSelection out of the method and before the call
1396            to __SelectField in __init__. This prevents a recursion of events
1397            when _OnFieldSelect is triggered by the user.
1398    
1399    2003-04-04  Jonathan Coles   <[email protected]>
1400    
1401            * Thuban/Model/classification.py: Rename Color.None to
1402            Color.Transparent.
1403            (ClassGroupProperties.SetLineColori, ClassGroupProperties.SetFill):
1404            Don't bother copying the color, since Colors are immutable.
1405    
1406            * Thuban/Model/color.py, Thuban/Model/layer.py, Thuban/Model/load.py,
1407            Thuban/UI/classifier.py, Thuban/UI/mainwindow.py,
1408            Thuban/UI/renderer.py, Thuban/UI/view.py:
1409            Rename Color.None to Color.Transparent.
1410        
1411            * test/test_classification.py, test/test_load.py: Rename Color.None
1412            to Color.Transparent.
1413    
1414    2003-04-04  Jonathan Coles   <[email protected]>
1415    
1416            * Thuban/Model/classification.py: Fix assert calls.
1417            (ClassGroupProperties.SetLineColor, ClassGroupProperties.SetFill):
1418            Copy the color parameter rather than hold onto a reference.
1419    
1420            * Thuban/Model/color.py (Color.__copy__, Color.__deepcopy): Copy
1421            the color object.
1422            (NoColor.__copy__, NoColor.__deepcopy): Return 'self' so that we
1423            are sure there exists only one refernce to Color.None in the system.
1424            This allows us to use 'is' rather than the comparision functions.
1425            
1426            * Thuban/Model/save.py: Fix assert calls.
1427            
1428            * Thuban/UI/classifier.py: Fix assert calls.
1429            (ClassGrid._OnCellDClick): Call up to the classifier to open the
1430            dialog to edit the groups properties.
1431            (ClassGrid._OnCellResize): Make sure that the scollbars are drawn
1432            correctly if a cell is resized.
1433            (ClassTable.SetClassification): New. Changes the classification
1434            that is in the table.
1435            (ClassTable.__SetRow): Allow groups to be prepended.
1436            (Classifier): New code for opening the EditProperties and
1437            GenerateRanges dialogs.
1438            (SelectPropertiesDialog.__GetColor): Only set the color in the
1439            color dialog if the current color is not None.
1440            
1441            * Thuban/UI/dock.py: Fix assert calls.
1442            
1443            * Thuban/UI/legend.py: Fix assert calls.
1444            
1445            * Thuban/UI/renderer.py: Fix assert calls.
1446            
1447            * Thuban/UI/classgen.py (ClassGenDialog): Dialog for generating
1448            classifications.
1449            (GenRangePanel): Panel specific to range generation.
1450            (GenSingletonPanel): Panel specific to singleton generation.
1451            (ClassGenerator): Class responsible for actually generating
1452            the classification from the data gathered in the dialog box.
1453            (PropertyRamp): Generates properties whose values range from
1454            a starting property to an ending property.
1455    
1456    2003-04-03  Bernhard Herzog  <[email protected]>
1457    
1458            * test/support.py (print_garbage_information): New function that
1459            prints information about still connected messages and memory
1460            leaks.
1461            (run_suite): Removed.
1462            (run_tests): New function for use as a replacement of
1463            unittest.main in the test_* files. This one calls
1464            print_garbage_information at the end.
1465    
1466            * test/runtests.py (main): Use support.print_garbage_information
1467    
1468            * test/test_layer.py: Use support.run_tests instead of
1469            unittest.main so we get memory leak information
1470            (TestLayer.test_arc_layer, TestLayer.test_polygon_layer)
1471            (TestLayer.test_point_layer, TestLayer.test_empty_layer)
1472            (TestLayerLegend.test_visibility): Call the layer's Destroy method
1473            to fix a memory leak.
1474    
1475            * test/test_classification.py: Use support.run_tests instead of
1476            unittest.main so we get memory leak information
1477            (TestClassification.test_classification): Call the layer's Destroy
1478            method to fix a memory leak.
1479    
1480    2003-04-02  Bernhard Herzog  <[email protected]>
1481    
1482            * extensions/thuban/wxproj.cpp (check_version, check_version_gtk):
1483            Handle the reference counts of the return value and errors in
1484            PyArg_ParseTuple correctly.
1485    
1486            * Thuban/UI/application.py (ThubanApplication.OpenSession): Make
1487            sure the filename is absolute to avoid problems when saving the
1488            session again
1489    
1490            * Thuban/Model/table.py: Remove unnecessary import. Fix a typo.
1491    
1492    2003-04-01  Jonathan Coles   <[email protected]>
1493    
1494            *  Thuban/UI/renderer.py (MapRenderer.draw_point_shape): Check
1495            that there actually are points in the returned list of points
1496            before trying to index into the list. The list may be empty if
1497            the shape is a Null Shape.
1498    
1499    2003-04-01  Bernhard Herzog  <[email protected]>
1500    
1501            * test/test_map.py: Don't use from <module> import *
1502    
1503    2003-04-01  Jonathan Coles   <[email protected]>
1504    
1505            * Thuban/Model/session.py: Use LAYER_CHANGED instead of
1506            LAYER_LEGEND_CHANGED
1507    
1508            * Thuban/UI/dock.py (DockableWindow._OnButtonClose): Call
1509            self.Destroy() to close the window after yesterday's changes.
1510    
1511            * test/test_map.py, test/test_session.py: Fix messages that
1512            are sent from maps and layers.
1513    
1514    2003-03-31  Jonathan Coles   <[email protected]>
1515    
1516            * Thuban/UI/classifier.py: Commented out some debugging statements.
1517            (ClassDataPreviewer.Draw): Draw rectangles for polygon layers per
1518            RTbug #1769.
1519    
1520            * Thuban/UI/dock.py (DockableWindow.UnDock): Restore size and
1521            position (although position doesn't work yet under GTK).
1522            (DockableWindow.Destroy): New. Called when the window must be
1523            closed. Namely needed when the DockFrame closes and must close
1524            its children.
1525            (DockFrame): Listen for EVT_CLOSE and destroy all children.
1526    
1527            * Thuban/UI/legend.py (LegendPanel.Destroy): New. Cleans up
1528            when then window is told to close.
1529            (LegendTree._OnMsgLayerChanged): Fixes a seg fault bug. See
1530            comment in source for more info.
1531    
1532            * Thuban/UI/main.py: Show the legend by default when Thuban starts.
1533    
1534            * Thuban/UI/mainwindow.py: Renamed OnClose to _OnClose for
1535            symmetry with other such methods.
1536            (MainWindow.ShowLegend): Show the legend docked by default.
1537    
1538    2003-03-28  Jonathan Coles   <[email protected]>
1539    
1540            * Thuban/UI/classifier.py: Support for highlighting a specific
1541            group within the grid when the classification dialog is opened.
1542            Also contains a lot of debugging printouts which will later
1543            be removed.
1544    
1545            * Thuban/UI/dock.py: Complete rework on the dock code so that
1546            that it is fairly removed from the rest of the Thuban application.
1547            It is easy to add new docks which the rest of the program having
1548            to be aware of them.
1549    
1550            * Thuban/UI/legend.py: Modifications to support selecting a
1551            specific group in the classification dialog. Changed how layers
1552            are drawn when the layer is visible/invisible.
1553    
1554            * Thuban/UI/mainwindow.py: Removed legend specific code and
1555            replaced it with calls to the new dock code.
1556    
1557            * Thuban/UI/renderer.py (MapRenderer.__init__): Added assert
1558            to check if scale > 0. Trying to track down a divide by zero.
1559    
1560    2003-03-26  Jonathan Coles   <[email protected]>
1561    
1562            * Thuban/UI/legend.py: Removed unnecessary LegendDialog class.
1563            (LegendPanel): Removed _OnDock()/_OnUnDock() methods which are
1564            now part of DockableWindow.
1565            (LegendPanel.DoOnSelChanged): Select the current layer in the
1566            map.
1567            (LegendTree._OnSelChanged): Call LegendPanel.DoOnSelChanged()
1568            with the selected layer and/or group.
1569    
1570    2003-03-26  Jonathan Coles   <[email protected]>
1571    
1572            This putback contains the code for dockable windows. There is
1573            no support in wxWindows as of this date for windows that can
1574            attach themselves to other windows.
1575    
1576            The current model contains a DockableWindow which has a parent
1577            window for when it is detached and a dock window that it puts
1578            its contents in when it is docked. The contents of a DockableWindow
1579            must be a DockPanel. DockPanel itself derives from wxPanel.
1580    
1581            * Thuban/Model/layer.py (Layer.ClassChanged): Send a LAYER_CHANGED
1582            message, not a LAYER_LEGEND_CHANGED message.
1583    
1584            * Thuban/Model/map.py (Map): Forward LAYER_CHANGED messages.
1585    
1586            * Thuban/UI/classifier.py (Classifier.__init__): Use wxADJUST_MINSIZE
1587            as one of the style properties for the fieldTypeText item to
1588            be sure that its size is correct when the text changes.
1589    
1590            * Thuban/UI/dock.py: New. Classes for the DockPanel and
1591            DockableWindow.
1592    
1593            * Thuban/UI/legend.py: Added some more buttons and made the
1594            LegendPanel a DockPanel.
1595    
1596            * Thuban/UI/mainwindow.py: Added sash windows to the main window
1597            and supporting functions for manipulating the sashes.
1598            (MainWindow.ShowLegend): Create a DockableWindow with the
1599            LegendPanel as the contents.
1600    
1601            * Thuban/UI/messages.py: Added DOCKABLE_* messages
1602    
1603            * Thuban/UI/view.py (MapCanves.SetMap): Listen for LAYER_CHANGED,
1604            not LAYER_LEGEND_CHANGED, messages.
1605    
1606    2003-03-25  Jonathan Coles   <[email protected]>
1607    
1608            * setup.py: Added custom script bdist_rpm_build_script so that
1609            when the rpm is built the path to wx-config is correct.
1610    
1611            * setup.cfg: Added line saying to use the custom build script
1612    
1613    2003-03-20  Jonathan Coles   <[email protected]>
1614    
1615            Initial implementation of the Legend.
1616    
1617            * Thuban/UI/legend.py: New. Creates a window that shows the map's
1618            Legend information and allows the user to add/modify classifications
1619            and how the layers are drawn on the map.
1620    
1621            * setup.py: New command 'build_docs' which currently uses
1622            happydoc to generate html documentation for Thuban.
1623    
1624            * Thuban/Model/classification.py (ClassGroup.GetDisplayText): New.
1625            Returns a string which is appropriately describes the group.
1626    
1627            * Thuban/Model/layer.py (Layer.SetClassification): Generate a
1628            LAYER_CHANGED event instead of a LAYER_LEGEND_CHANGED event.
1629    
1630            * Thuban/Model/map.py (Map): Rename messages and use new, more
1631            specific, messages.
1632    
1633            * Thuban/Model/messages.py: New message to indicate that a layer's
1634            data has changed (LAYER_CHANGED). New map messages to indicate
1635            when layers have been added/removed/changed or if the stacking order
1636            of the layers has changed.
1637    
1638            * Thuban/Model/session.py: Rename and use new messages.
1639    
1640            * Thuban/UI/classifier.py: Remember if any changes have actually
1641            been applied so that if the dialog is cancelled without an application
1642            of changes we don't have to set a new classification.
1643            (ClassDataPreviewer): Pulled out the window specific code and put it
1644            ClassDataPreviewWindow. ClassDataPreviewer can then be used to draw
1645            symbols on any DC.
1646            
1647            * Thuban/UI/mainwindow.py: New code to open the legend.
1648    
1649            * Thuban/UI/view.py: Use new message names.
1650    
1651    2003-03-19  Jonathan Coles   <[email protected]>
1652    
1653            * Thuban/UI/main.py (verify_versions): New. Checks the versions
1654            of Python, wxPython, and some other libraries.
1655    
1656            * extensions/thuban/wxproj.cpp (check_version): Checks the given
1657            version against what wxproj was compiled with.
1658            (check_version_gtk): If wxproj was compiled with gtk then check
1659            the given version against the version of the gtk library
1660            currently being used.
1661    
1662    2003-03-14  Bernhard Herzog  <[email protected]>
1663    
1664            * test/test_command.py: Run the tests when the module is run as a
1665            script
1666    
1667    2003-03-14  Bernhard Herzog  <[email protected]>
1668    
1669            Implement selection of multiple selected shapes in the same layer:
1670    
1671            - Introduce a new class to hold the selection. This basically
1672              replaces the interactor which was nothing more than the
1673              selection anyway. A major difference is of course that the new
1674              selection class supports multiple selected shapes in one layer
1675            
1676            - Move the object that represents the selection from the
1677              application to the canvas. The canvas is a better place than the
1678              application because the selection represents which shapes and
1679              layer of the map displayed by the canvas are selected and
1680              affects how the map is drawn.
1681    
1682            - Make the selection and its messages publicly available through
1683              the mainwindow.
1684    
1685            - The non-modal dialogs do not get a reference to the interactor
1686              anymore as they can simply refer to their parent, the
1687              mainwindow, for the what the interactor had to offer.
1688    
1689            * Thuban/UI/selection.py: New module with a class to represent the
1690            selection.
1691    
1692            * Thuban/UI/messages.py (SELECTED_TABLE, SELECTED_MAP): Remove
1693            these unused messages
1694    
1695            * Thuban/UI/application.py (ThubanApplication.OnInit)
1696            (ThubanApplication.OnExit, ThubanApplication.SetSession): The
1697            interactor is gone now.
1698            (ThubanApplication.CreateMainWindow): There is no interactor
1699            anymore so we pass None as the interactor argument for now for
1700            compatibility.
1701    
1702            * Thuban/UI/view.py (MapCanvas.delegated_messages)
1703            (MapCanvas.Subscribe, MapCanvas.Unsubscribe): In Subscribe and
1704            Unsubscribe, delegate messages according to the delegated_messages
1705            class variable.
1706            (MapCanvas.__getattr__, MapCanvas.delegated_methods): Get some
1707            attributes from instance variables as described with the
1708            delegated_methods class variable.
1709            (MapCanvas.__init__): New instance variable selection holding the
1710            current selection
1711            (MapCanvas.do_redraw): Deal with multiple selected shapes. Simply
1712            pass them on to the renderer
1713            (MapCanvas.SetMap): Clear the selection when a different map is
1714            selected.
1715            (MapCanvas.shape_selected): Simple force a complete redraw. The
1716            selection class now takes care of only issueing SHAPES_SELECTED
1717            messages when the set of selected shapes actually does change.
1718            (MapCanvas.SelectShapeAt): The selection is now managed in
1719            self.selection
1720    
1721            * Thuban/UI/mainwindow.py (MainWindow.delegated_messages)
1722            (MainWindow.Subscribe, MainWindow.Unsubscribe): In Subscribe and
1723            Unsubscribe, delegate messages according to the delegated_messages
1724            class variable.
1725            (MainWindow.delegated_methods, MainWindow.__getattr__): Get some
1726            attributes from instance variables as described with the
1727            delegated_methods class variable.
1728            (MainWindow.__init__): The interactor as ivar is gone. The
1729            parameter is still there for compatibility. The selection messages
1730            now come from the canvas.
1731            (MainWindow.current_layer, MainWindow.has_selected_layer):
1732            Delegate to the the canvas.
1733            (MainWindow.LayerShowTable, MainWindow.Classify)
1734            (MainWindow.identify_view_on_demand): The dialogs don't need the
1735            interactor parameter anymore.
1736    
1737            * Thuban/UI/tableview.py (TableFrame.__init__)
1738            (LayerTableFrame.__init__, LayerTableFrame.OnClose)
1739            (LayerTableFrame.row_selected): The interactor is gone. It's job
1740            from the dialog's point of view is now done by the mainwindow,
1741            i.e. the parent. Subscribe to SHAPES_SELECTED instead
1742            of SELECTED_SHAPE
1743            
1744            * Thuban/UI/dialogs.py (NonModalDialog.__init__): The interactor
1745            is gone. It's job from the dialog's point of view is now done by
1746            the mainwindow, i.e. the parent.
1747            
1748            * Thuban/UI/classifier.py (Classifier.__init__): The interactor is
1749            gone. It's job from the dialog's point of view is now done by the
1750            mainwindow, i.e. the parent.
1751    
1752            * Thuban/UI/tree.py (SessionTreeView.__init__): The interactor is
1753            gone. It's job from the dialog's point of view is now done by the
1754            mainwindow, i.e. the parent.
1755            (SessionTreeCtrl.__init__): New parameter mainwindow which is
1756            stored as self.mainwindow. The mainwindow is need so that the tree
1757            can still subscribe to the selection messages.
1758            (SessionTreeCtrl.__init__, SessionTreeCtrl.unsubscribe_all)
1759            (SessionTreeCtrl.update_tree, SessionTreeCtrl.OnSelChanged): The
1760            selection is now accessible through the mainwindow. Subscribe to
1761            SHAPES_SELECTED instead of SELECTED_SHAPE
1762    
1763            * Thuban/UI/identifyview.py (IdentifyView.__init__): Use the
1764            SHAPES_SELECTED message now.
1765            (IdentifyView.selected_shape): Now subscribed to SHAPES_SELECTED,
1766            so deal with multiple shapes
1767            (IdentifyView.__init__, IdentifyView.OnClose): The interactor is
1768            gone. It's job from the dialog's point of view is now done by the
1769            mainwindow, i.e. the parent.
1770    
1771            * Thuban/UI/controls.py (RecordListCtrl.fill_list): The second
1772            parameter is now a list of shape ids.
1773            (RecordTable.SetTable): The second parameter is now a list of
1774            indices.
1775    
1776            * Thuban/UI/renderer.py (ScreenRenderer.RenderMap): Rename the
1777            selected_shape parameter and ivar to selected_shapes. It's now a
1778            list of shape ids.
1779            (MapRenderer.draw_label_layer): Deal with multiple selected
1780            shapes. Rearrange the code a bit so that the setup and shape type
1781            distinctions are only executed once.
1782    
1783            * test/test_selection.py: Test cases for the selection class
1784    
1785    2003-03-11  Jonathan Coles   <[email protected]>
1786    
1787            * Thuban/Model/load.py: Temporary fix so that the xml reader
1788            doesn't cause Thuban to crash.
1789    
1790            * Thuban/Model/layer.py: Handle the cyclic references between
1791            a layer and its classification better, and be sure to disconnect
1792            the classification from the layer when the layer is destroyed
1793            so that we don't maintain a cyclic reference that may not be
1794            garbage collected.
1795    
1796            * Thuban/Model/classification.py: See comment for layer.py.
1797    
1798    2003-03-12  Jan-Oliver Wagner <[email protected]>
1799    
1800            * HOWTO-Release: New. Information on the steps for releasing
1801            a new version of Thuban.
1802    
1803    2003-03-11  Jonathan Coles   <[email protected]>
1804    
1805            * Thuban/UI/classifier.py: Add normal border to SelectPropertiesDialog.
1806            Use True instead of true.
1807            (Classifier): Should have a single panel in which all the controls lie.
1808    
1809            * Thuban/UI/proj4dialog.py: Add normal border.
1810    
1811            * Thuban/UI/tree.py: Fixed problem with bad item images under Windows.
1812    
1813            * Thuban/UI/mainwindow.py: Use True instead of true.
1814    
1815            * setup.py: Update some definitions to use wxWindows2.4 files
1816    
1817            * Data/iceland_sample_class.thuban: Fixed file so that the
1818            field_type information is present.
1819    
1820    2003-03-10  Jonathan Coles   <[email protected]>
1821    
1822            * Thuban/UI/classifier.py (Classifier.__init__): Make the
1823            field type label grow so that when the text changes the
1824            size is updated correctly. This may be a wxWindows bug.
1825    
1826    2003-03-10  Jonathan Coles   <[email protected]>
1827    
1828            * Thuban/UI/application.py: Changed SESSION_CHANGED to
1829            SESSION_REPLACED.
1830    
1831            * Thuban/UI/classifier.py: Wrap text with _().
1832            (ClassGrid.CreateTable): Set dimensions and size hints here,
1833            instead of in Reset, so we only set the size once.
1834    
1835            * Thuban/UI/dialogs.py: Don't need Shutdown(); just use Close()!
1836    
1837            * Thuban/UI/mainwindow.py (MainWindow.prepare_new_session):
1838            Call Close() instead of Shutdown().
1839    
1840            * Thuban/UI/messages.py: Changed SESSION_CHANGED to SESSION_REPLACED.
1841    
1842            * Thuban/UI/tree.py: Changed SESSION_CHANGED to SESSION_REPLACED.
1843            Go back to using OnClose() instead of Shutdown().
1844    
1845    2003-03-10  Jonathan Coles   <[email protected]>
1846    
1847            * Thuban/UI/classifier.py (Classifier): SelectField() needed
1848            to know the old field index as well as the new one.
1849    
1850    2003-03-10  Jonathan Coles   <[email protected]>
1851    
1852            * Thuban/UI/classifier.py (Classifier): Use __SelectField()
1853            to correctly set the table information and call this from
1854            __init__ and from _OnFieldSelect so that all the information
1855            is up to date when the dialog opens and when a field is changed.
1856    
1857    2003-03-10  Jonathan Coles   <[email protected]>
1858    
1859            * Thuban/Model/classification.py (Classification): Don't use
1860            layer's message function directly, use the ClassChanged() method
1861            when then classification changes. SetField/SetFieldType/SetLayer
1862            must keep the information about field name and field type in
1863            sync when an owning layer is set or removed.
1864    
1865            * Thuban/Model/layer.py: Added ClassChanged() so that the
1866            classification can tell the layer when its data has changed.
1867            (Layer.SetClassification): Accepts None as an arguement to
1868            remove the current classification and correctly handles
1869            adding a new classification.
1870    
1871            * Thuban/Model/load.py: Comment out print statement
1872    
1873            * test/test_classification.py, test/test_save.py: New and
1874            improved tests.
1875    
1876    2003-03-07  Jonathan Coles   <[email protected]>
1877    
1878            * Thuban/Model/classification.py: Implemented __copy__ and
1879            __deepcopy__ for ClassGroup* and ClassGroupProperites so
1880            they can easily be copied by the classifier dialog.
1881            (ClassGroupProperites.__init__): The default line color should
1882            have been Color.Black.
1883    
1884            * Thuban/UI/classifier.py: Setting and Getting table values now
1885            uses a consistent set of functions.
1886            (Classifier): Now non-modal. Has field type label which changes
1887            as the field changes. Keep track of buttons in a list so that
1888            we can enable/disable the buttons when the None field is selected.
1889            (SelectPropertiesDialog): Add buttons to make the colors transparent.
1890    
1891            * Thuban/UI/dialogs.py (NonModalDialog.Shutdown): New method which
1892            does what OnClose did, but can be called by the application to
1893            close a window. Needed when a session changes, and we have to
1894            close the classifier windows.
1895    
1896            * Thuban/UI/mainwindow.py (MainWindow.prepare_new_session):
1897            Shuts down open dialogs. Used when a new session is created
1898            or a session is opened.
1899            (MainWindow.SaveSession): Should only call application.SaveSession()
1900            if we don't call SaveSessionAs first.
1901            (MainWindow.Classify): Allow different classifier dialogs for
1902            different layers.
1903    
1904            * Thuban/UI/tree.py (SessionTreeView): Remove OnClose and let
1905            the parent class handle it. Add Shutdown() to unsubscibe from
1906            event notification and call the parent Shutdown(). This was
1907            necessary so the application can close the tree window.
1908    
1909    2003-03-06  Jonathan Coles   <[email protected]>
1910    
1911            * Thuban/Model/classification.py: Minor documentation changes,
1912            Addition of __eq__ and __ne__ methods.
1913            (Classification.SetLayer): prevent recursion between this method
1914            and Layer.SetClassification().
1915    
1916            * Thuban/Model/color.py: Addition of __eq__ and __ne__ methods.
1917    
1918            * Thuban/Model/layer.py (SetClassification): prevent recursion
1919            between this method and Classification.SetLayer().
1920    
1921            * test/test_classification.py, test/test_load.py,
1922            test/test_session.py: Fixed and added tests for the classification
1923            classes.
1924    
1925    2003-03-06  Bernhard Herzog  <[email protected]>
1926    
1927            * Thuban/UI/classifier.py (ClassGrid.__init__)
1928            (ClassGrid.CreateTable): Move the SetSelectionMode call to
1929            CreateTable because otherwise it triggers an assertion in
1930            wxPython/wxGTK 2.4.
1931    
1932    2003-03-05  Jonathan Coles   <[email protected]>
1933    
1934            * Thuban/common.py: Move FIELDTYPE constants back to table.py.
1935    
1936            * Thuban/Model/load.py: import FIELDTYPE constants from table.
1937    
1938            * Thuban/UI/classifier.py: import FIELDTYPE constants from table.
1939    
1940            * Thuban/Model/table.py: Put FIELDTYPE constants back.
1941    
1942    2003-03-05  Jonathan Coles   <[email protected]>
1943    
1944            * Thuban/UI/classifier.py: Added class documentation.
1945            Fixed RTbug #1713, #1714. Added Move[Up|Down] buttons.
1946            Store just the groups in the table and generate the other
1947            column information when it is requested. Add "None" field
1948            to pull-down to select no classification.
1949    
1950            * Thuban/common.py: Moved FIELDTYPE constants from table.py
1951            (Str2Num): Only catch ValueError exceptions.
1952    
1953            * Thuban/Model/classification.py: Class documentation. Renaming
1954            of methods with Stroke to Line. Groups are stored in a single
1955            list with the default as the first element. Groups are searched
1956            in the order they appear in the list.
1957    
1958            * Thuban/Model/color.py: Documentation.
1959    
1960            * Thuban/Model/layer.py (Layer): Add GetFieldType to retreive
1961            the kind of data represented by a field.
1962    
1963            * Thuban/Model/load.py (ProcessSession): Use proper string
1964            conversion function; fixes RTbug #1713.
1965    
1966            * Thuban/Model/save.py (Saver): Store field type information.
1967    
1968            * Thuban/Model/table.py: Put FIELDTYPE constants in common.py.
1969            (Table): Add field_info_by_name() to retrieve field information
1970            by specifying the field name, not the number.
1971    
1972            * Thuban/UI/mainwindow.py: Function name changes.
1973    
1974            * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Only
1975            get the layer classification once. Don't try to classify
1976            values when the field is None: just use the default properties.
1977    
1978            * Thuban/UI/view.py: Function name changes.
1979    
1980            * Doc/thuban.dtd: Add field_type attribute to a classification.
1981    
1982    2003-03-04  Bernhard Herzog  <[email protected]>
1983    
1984            * Doc/thuban.dtd: Use correct syntax for optional attributes. Make
1985            the fill and stroke layer attributes optional with suitable
1986            default values. Add the stroke_width layer attribute. Use correct
1987            syntax for empty elements. Make the attribute list for labels
1988            refer to the label element.
1989    
1990    2003-03-04  Bernhard Herzog  <[email protected]>
1991    
1992            * setup.py (thuban_build_py.build): Add a comment about distutils in
1993            Python 2.3 containing some of the functionality we implement in
1994            setup.py ourselves.
1995    
1996            * Thuban/UI/classifier.py (ClassGrid.__init__): Set the table
1997            before the selection mode. Doing it the other way round triggers
1998            an assertion in wxWindows.
1999    
2000            * Thuban/Model/save.py (escape): Fix typo in doc-string
2001    
2002            * Thuban/Model/classification.py: Remove unnecessary wxPython
2003            import
2004    
2005    2003-03-04  Jonathan Coles   <[email protected]>
2006    
2007            * Thuban/Model/classification.py (ClassGroupRange.GetProperties):
2008            Parameter 'value' should default to None.
2009    
2010            * Thuban/UI/mainwindow.py: Use Layer.GetClassification() since
2011            the class attribute __classification is now private.
2012    
2013            * Thuban/UI/classifier.py (ClassGrid): Moved OnCellDClick() from
2014            Classifier to ClassGrid. Added support for removing selected rows,
2015            which including code for keeping track of when cells are selected,
2016            and deselected.
2017            (ClassTable): Support for added/removing rows. Fixed a problem
2018            with __ParseInput whereby it would not allow strings (only numbers)
2019            to be entered.
2020            (Classifier): Added button and supporting code for removing
2021            selected rows.
2022    
2023    2003-02-27  Jonathan Coles   <[email protected]>
2024    
2025            * Thuban/common.py: Moved color conversion functions into
2026            Thuban/UI/common.py.
2027            (Str2Num): Now converts the float (not the string) to a long/int
2028            so that an exception isn't thrown.
2029    
2030            * Thuban/UI/common.py: Common functions used in several UI modules
2031    
2032            * Thuban/Model/classification.py: Changed the class hierarchy
2033            so that a Classification consists of Groups which return
2034            Properties when a value matches a Group.
2035    
2036            * Thuban/Model/layer.py: Fixed name resolution problem.
2037    
2038            * Thuban/Model/load.py: Use new Classification and Group functions.
2039    
2040            * Thuban/Model/save.py (Saver.write_attribs): Fixes a test case
2041            failure.
2042            (Saver.write_classification): Use new Classification and Group
2043            functions.
2044    
2045            * Thuban/UI/classifier.py: Changes to use new Classification and Group
2046            functions. Fix to create a tuple with a single value instead of
2047            simply returning the value.
2048    
2049            * Thuban/UI/renderer.py: Use new Classification and Group functions.
2050            Use common.py functions.
2051    
2052            * Thuban/UI/tree.py: Use common.py functions.
2053            
2054            * test/test_classification.py: Use new Classification and Group
2055            classes.
2056    
2057    2003-02-24  Jonathan Coles   <[email protected]>
2058    
2059            * Thuban/common.py (Color2wxColour, wxColour2Color): Conversion
2060            functions from Thuban color objects to wxWindow colour objects.
2061    
2062            * Thuban/Model/classification.py (Classification): Renamed
2063            GetProperties() to GetClassData(). Used the new iterator
2064            in TreeInfo().
2065            (ClassIterator): Iterator implementation to iterate over the
2066            ClassData objects in a classification object.
2067    
2068            * Thuban/Model/save.py (Saver.write_classificaton): Uses
2069            the new iterator to save the classification information.
2070    
2071            * Thuban/UI/classifier.py (SelectPropertiesDialog): Support
2072            for changing the stroke and fill colors and previewing the
2073            changes.
2074    
2075            * Thuban/UI/mainwindow.py (MainWindow.OpenSession,
2076            MainWindow.SaveSessionAs): Text string changes so the dialogs
2077            have more meaningful titles.
2078    
2079            * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Change
2080            Classification method name from GetProperties to GetClassData.
2081    
2082            * Thuban/UI/view.py (MapCanvas.find_shape_at): Use method calls
2083            instead of accessing now non-existent class variables.
2084    
2085    2003-02-24  Bernhard Herzog  <[email protected]>
2086    
2087            * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Remove
2088            unneeded Shape() call. Rendering is substantially faster without
2089            it and it avoids some problems with broken shape files.
2090    
2091    2003-02-20  Frank Koormann   <[email protected]>
2092    
2093            Force minimal size of identify and label dialogs. The autosizing
2094            looked too ugly.
2095    
2096            * Thuban/UI/controls.py (RecordListCtrl): Set minimal width for columns.
2097            * Thuban/UI/labeldialog.py (LabelDialog.dialog_layout):
2098            Set size of listctrl.
2099            * Thuban/UI/identifyview.py (IdentifyView.__init__):
2100            Set size of dialog.
2101    
2102    2003-02-19  Jonathan Coles   <[email protected]>
2103    
2104            * test/test_classification.py, test/test_layer.py,
2105            test/test_load.py, test/test_map.py, test/test_session.py:
2106            Updated the tests to use the new functions that are in the
2107            respective classes.
2108    
2109            * Thuban/Model/classification.py (Classification):
2110            Uses the new ClassData* classes. Modification messages are
2111            passed up to the parent layer (if it exists).
2112            (ClassData): New class to encapsulate the common data in each
2113            classification property.
2114            (ClassDataDefault): Represents the Default class. data.
2115            (ClassDataPoint): Represents a single class. data point
2116            (ClassDataRange): Represents a class. range
2117            (ClassDataMap): Represents a class. map (unused).
2118    
2119            * Thuban/Model/color.py: Added Color.None to represent something
2120            with no color. Color.Black represents the color black.
2121            (NoColor): Helper class derived from Color to represent something
2122            with no color.
2123    
2124            * Thuban/Model/layer.py (Layer): Removed references to fill, stroke,
2125            stroke_width attributes. Made the 'classification' attribute private.
2126            New methods for setting/getting the classification.
2127    
2128            * Thuban/Model/load.py (ProcessSession): Use new methods on Layer
2129            to get the classifcation and use the new ClassData* classes to
2130            hold the classification data. Use Str2Num to convert numbers
2131            properly.
2132    
2133            * Thuban/Model/save.py (Saver): Use new Color and Classification
2134            methods
2135    
2136            * Thuban/UI/classifier.py (ClassGrid): New class to represent a
2137            custom grid.
2138            (ClassTable): Support for editing Values and Labels and for
2139            changing what type (point or range) of data is stored in each
2140            property based on how the user enters the data.
2141            (Classifier): Support for saving the new classifications and
2142            launching the dialog to edit a property.
2143            (SelectPropertiesDialog): New class for editing the visual
2144            properties of a classification (stroke color, width, and fill color)
2145            (ClassPreviewer): Took the Draw method from ClassRenderer and
2146            made most of it into this new class. Intend to use this class in
2147            the SelectPropertiesDialog for previewing changes.
2148    
2149            * Thuban/UI/renderer.py: Use new Color and Classification methods.
2150    
2151            * Thuban/UI/tree.py: Formatting changes.
2152    
2153            * Doc/thuban.dtd: Add 'label' element
2154    
2155            * Thuban/common.py: New. Contains common routines used throughout
2156            the code.
2157            (Str2Num): Takes a string and converts it to the "best" type of
2158            number.
2159    
2160    2003-02-14  Bernhard Herzog  <[email protected]>
2161    
2162            * Thuban/UI/view.py (MapCanvas.OnLeftUp): Make sure that the
2163            dragging flag is always set to 0 even when the tool implementation
2164            raises an exception
2165    
2166    2003-02-11  Bernhard Herzog  <[email protected]>
2167    
2168            * Thuban/UI/application.py (ThubanApplication.splash_screen): New
2169            method to create a splash screen.
2170            (ThubanApplication.ShowMainWindow): New. Show the main window.
2171            Needed so the splash screen can display the mainwindow
2172            (ThubanApplication.OnInit): Call the
2173            new splash_screen method to determine whether the application
2174            should display a splash screen. If it displays a splash screen do
2175            not immediately show the main window.
2176    
2177    2003-02-11  Jonathan Coles  <[email protected]>
2178    
2179            * Thuban/Model/classification.py: Added import line to fix
2180            feature conflicts between running on python2.2 and python2.1.
2181    
2182            * Thuban/UI/classifier.py (ClassTable): Didn't need to hang
2183            onto the clinfo parameter, so removed the deepcopy().
2184    
2185    2003-02-10  Jonathan Coles  <[email protected]>
2186    
2187            * Thuban/Model/save.py (Saver.open_element, Saver.close_element):
2188            Added element_open variable to track opening and closing of tags
2189            so that tags that don't span more than one line are closed with
2190            /> instead of </tag_name>. Use the GetDefault*() methods of
2191            the Classification class.
2192    
2193            * Thuban/Model/classification.py (Classificaton): Added set and
2194            get methods for the default data. The class also takes a layer
2195            reference so that modification messages can be sent. Fixed the
2196            methods to use the new ClassData class.
2197            (ClassData): New class to encapsulate the classification data
2198    
2199            * Thuban/Model/layer.py (Layer): Remove the
2200            Set[Fill|Stroke|StrokeWidth]() methods. Code should call the
2201            SetDefault*() methods on the layer's classification object.
2202            (Layer.__init__): Use the new SetDefault*() methods in the
2203            Classification class.
2204    
2205            * Thuban/Model/load.py (ProcessSession): Use the new ClassData
2206            object instead of a dictionary.
2207    
2208            * Thuban/UI/classifier.py (ClassRenderer): New class to
2209            draw the classifications in the dialog box's table.
2210            (Classifier): Modified to use the ClassRenderer class.
2211    
2212            * Thuban/UI/mainwindow.py (MainWindow): Use the SetDefault*()
2213            methods of the Classification class.
2214    
2215            * Thuban/UI/renderer.py (MapRenderer): Use the Get*() methods
2216            of the ClassData class.
2217    
2218            * test/test_classification.py, test/test_layer.py,
2219            test/test_map.py, test/test_session.py: Fix the tests to work
2220            with the above code changes.
2221    
2222    2003-02-03  Jonathan Coles  <[email protected]>
2223    
2224            * Thuban/Model/classification.py (Classification): Added getNull()
2225            to return the NullData reference
2226    
2227            * Thuban/Model/layer.py (Layer.SetFill, Layer.SetStroke,
2228            Layer.SetStrokeWidth): Modified these functions to change the
2229            null data in the classification rather than keep these values
2230            directly in the Layer class. Menu options to change these values
2231            work again.
2232    
2233    2003-01-28  Jonathan Coles  <[email protected]>
2234    
2235            * Thuban/UI/classifier.py (Classifier): Resolved merging conflicts.
2236            Fixed crashing problem on some systems. Dialog box shows
2237            classification data.
2238    
2239            * Thuban/UI/tree.py (SessionTreeCtrl.add_items): Handle drawing
2240            Colors in the tree view.
2241    
2242            * Thuban/Model/layer.py (Layer.TreeInfo): Added a call to build
2243            the tree info for classifications. Commented out unnecessary lines.
2244    
2245            * Thuban/Model/classification.py (Classification.TreeInfo): New
2246            function to add information about the classification into the
2247            tree view.
2248    
2249    2003-01-27  Jan-Oliver Wagner <[email protected]>
2250    
2251            * Thuban/__init__.py (_): New.
2252    
2253            * Thuban/Model/classification.py, Thuban/Model/extension.py,
2254            Thuban/Model/layer.py, Thuban/Model/load.py, Thuban/Model/map.py,
2255            Thuban/Model/session.py, Thuban/UI/application.py,
2256            Thuban/UI/classifier.py, Thuban/UI/context.py, Thuban/UI/controls.py,
2257            Thuban/UI/identifyview.py, Thuban/UI/labeldialog.py,
2258            Thuban/UI/mainwindow.py, Thuban/UI/menu.py, Thuban/UI/proj4dialog.py,
2259            Thuban/UI/renderer.py, Thuban/UI/tree.py, Thuban/Lib/connector.py,
2260            Thuban/Lib/fileutil.py: Replace user string by _() for i18n.
2261    
2262    2003-01-27  Jonathan Coles  <[email protected]>
2263    
2264            * Thuban/Model/layer.py: Classification initialization calls.
2265    
2266            * Thuban/Model/classification.py: Created class to encapsulate
2267            a layer classification. Supports specific data points and
2268            ranges.
2269    
2270            * Thuban/Model/load.py: Added support for loading classification
2271            information.
2272    
2273            * Thuban/Model/save.py: Added support for saving classification
2274            information.
2275    
2276            * Thuban/UI/classifier.py: Initial class for a dialog box for
2277            specifying classification information.
2278    
2279            * Thuban/UI/mainwindows.py: Support for opening the classifier
2280            dialog.
2281    
2282            * Thuban/UI/renderer.py: Support for drawing a layer with the
2283            classification information.
2284    
2285            * Data/iceland_sample_class.thuban: iceland_sample with
2286            classification data.
2287    
2288            * test/test_classification: Tests for the Classification class.
2289    
2290    2002-12-09  Bernhard Herzog  <[email protected]>
2291    
2292            * test/test_command.py: New. Tests for the command classes.
2293    
2294            * Thuban/UI/command.py (ToolCommand): New class for tool commands.
2295            (Command.IsTool): New method to distinguish between command
2296            switching tools and other commands.
2297    
2298            * Thuban/UI/view.py (MapCanvas.SelectTool): New method to select
2299            the tool to avoid direct assignments to instance variables
2300            (MapCanvas.ZoomInTool, MapCanvas.ZoomOutTool, MapCanvas.PanTool)
2301            (MapCanvas.IdentifyTool, MapCanvas.LabelTool): Use SelectTool to
2302            change the tool
2303    
2304            * Thuban/UI/mainwindow.py (MainWindow.update_command_ui): If an
2305            active tool's command turns insensitive, disable the tool.
2306            (_tool_command): Use the new ToolCommand class
2307    
2308            * Examples/simple_extensions/simple_tool.py (simple_tool): Use the
2309            SelectTool method to change the tool
2310            (iconfile): Use the ToolCommand class
2311    
2312    2002-12-03  Bernhard Herzog  <[email protected]>
2313    
2314            * Thuban/UI/tree.py (SessionTreeCtrl.normalize_selection): Handle
2315            the case of selected items that are not children of Layers or Maps
2316            properly. Previously this bug would trigger an assertion in
2317            wxWindows.
2318    
2319    2002-11-06  Frank Koormann  <[email protected]>
2320    
2321            * Thuban/UI/mainwindow.py: Altered the order of tools in the
2322            toolbar: First now are all navigation tools (Zoom In/Out, Pan,
2323            Full Extent).
2324    
2325    2002-10-23  Bernhard Herzog  <[email protected]>
2326    
2327            * setup.py (setup call): version now 0.1.3
2328    
2329            * MANIFEST.in: Add the files in test/
2330    
2331            * test/README: Add note about tests requiring the iceland data
2332    
2333            * Thuban/UI/mainwindow.py (MainWindow.About): Add 2002 to
2334            copyright notice.
2335    
2336    2002-10-18  Bernhard Herzog  <[email protected]>
2337    
2338            * test/test_map.py
2339            (TestMapWithContents.test_projected_bounding_box): Use an explicit
2340            epsilon.
2341    
2342            * test/support.py (FloatComparisonMixin.assertFloatEqual)
2343            (FloatComparisonMixin.assertFloatSeqEqual): give a more useful
2344            message if the assertion fails and don't return the return value
2345            of self.assert_. In assertFloatSeqEqual the return meant that not
2346            all items of the sequence were compared.
2347    
2348    2002-09-20  Bernhard Herzog  <[email protected]>
2349    
2350            * test/test_fileutil.py: New. Test cases for Thuban.Lib.fileutil
2351    
2352            * Thuban/Lib/fileutil.py: Fixup some whitespace and typos
2353    
2354            * test/test_map.py (TestMapWithContents.test_tree_info): Create
2355            the string with the bounding box on the fly because of platform
2356            differences in the way %g is handled.
2357    
2358            * test/test_layer.py (TestLayer.test_empty_layer): Create an empty
2359            DBFfile too because Thuban layers can't yet cope missing DBF
2360            files.
2361    
2362    2002-09-20  Bernhard Herzog  <[email protected]>
2363    
2364            * test/test_menu.py: Use initthuban instead of
2365            add_thuban_dir_to_path to initialize Thuban.
2366    
2367            * test/support.py (FloatComparisonMixin.assertFloatEqual): New.
2368            Mixin class for float comparisons
2369            (SubscriberMixin): New. Mixin class to test messages sent through
2370            the Connector class
2371    
2372            * test/README: Fix a typo and add the -v flag to the command for
2373            individual tests
2374    
2375            * test/test_session.py: New. Test cases for Thuban.Model.session
2376    
2377            * test/test_proj.py: New. Test cases for Thuban.Model.proj
2378    
2379            * test/test_map.py: New. Test cases for Thuban.Model.map
2380    
2381            * test/test_layer.py: New. Test cases for Thuban.Model.layer
2382    
2383            * test/test_label.py: New. Test cases for Thuban.Model.label
2384    
2385            * test/test_connector.py: New. Test cases for Thuban.Lib.connector
2386    
2387            * test/test_color.py: New. Test cases for Thuban.Model.color
2388    
2389            * test/test_base.py: New. Test cases for Thuban.Model.base
2390    
2391    2002-09-13  Bernhard Herzog  <[email protected]>
2392    
2393            * Thuban/Model/session.py (Session.forwarded_channels): Forward
2394            the CHANGED channel too.
2395    
2396            * Thuban/Model/map.py (Map.forwarded_channels): Forward the
2397            CHANGED channel too.
2398            (Map.__init__): Call the Modifiable constructor as well.
2399    
2400            * Thuban/Model/base.py (Modifiable.UnsetModified): Issue a CHANGED
2401            event if the modified flag changes.
2402            (Modifiable.changed): Tweak the doc-string.
2403    
2404            * Thuban/UI/mainwindow.py (MainWindow.view_position_changed)
2405            (MainWindow.set_position_text): Put the code that puts the text
2406            with the mouse position into the status bar into the new method
2407            set_position_text so that it can overwritten in derived classes.
2408    
2409    2002-09-12  Bernhard Herzog  <[email protected]>
2410    
2411            * Thuban/UI/mainwindow.py (MainWindow.RunMessageBox): Center the
2412            message box on the main window.
2413    
2414    2002-09-11  Bernhard Herzog  <[email protected]>
2415    
2416            * Thuban/UI/mainwindow.py: Underline the 'x' in "Exit" instead of
2417            the 'E' because it's less likely to interfere with other menu
2418            entries.
2419            (MainWindow.build_menu): remove an incorrect comment.
2420    
2421    2002-09-10  Bernhard Herzog  <[email protected]>
2422    
2423            * Thuban/UI/mainwindow.py (MainWindow.Map): New.
2424            (_tool_command): Add sensitive parameter
2425            (_has_visible_map): Sensitivity callback to tools and other
2426            commands that require a visible map. Use it in map_zoom_in_tool,
2427            map_zoom_out_tool, map_pan_tool, map_identify_tool, map_label_tool
2428            and map_full_extent
2429    
2430    2002-09-06  Bernhard Herzog  <[email protected]>
2431    
2432            * Thuban/UI/mainwindow.py (MainWindow.OnClose): Unsubscribe
2433            VIEW_POSITION
2434    
2435    2002-09-04  Frank Koormann  <[email protected]>
2436    
2437            * Resources/Bitmaps/fullextent.xpm: Updated Icon (removed "potatoe")
2438    
2439    2002-09-02  Bernhard Herzog  <[email protected]>
2440    
2441            * Thuban/UI/view.py: Get rid of the idle redraw. This is done by
2442            wxWindows already and our implementation doesn't work correctly
2443            with wxGTK 2.3:
2444            (MapCanvas.__init__): Remove the instance variable
2445            (MapCanvas.OnPaint): Always call do_redraw when there's a map to
2446            be drawin
2447            (MapCanvas.OnIdle): Removed.
2448    
2449            * Thuban/UI/view.py (MapCanvas.unprojected_rect_around_point): Add
2450            a parameter to determine the size of the rectangle.
2451            (MapCanvas.find_shape_at): Create the box around the point on a
2452            layer by layer basis and make the size depend on the shape type.
2453            This solves a problem with the selection of point shapes at the
2454            border of the layer's bounding box
2455    
2456    2002-08-30  Bernhard Herzog  <[email protected]>
2457    
2458            * Thuban/UI/mainwindow.py (MainWindow.CanRemoveLayer): New method
2459            for the sensitivity  of remove layer.
2460            (_can_remove_layer): New. Sensitivity callback for remove layer
2461            (Command layer_remove): Use _can_remove_layer
2462    
2463            * Thuban/Model/map.py (Map.CanRemoveLayer): New method to
2464            determine whether a given layer can be deleted.
2465    
2466            * Thuban/UI/view.py (MapCanvas.__init__, MapCanvas.OnPaint)
2467            (MapCanvas.do_redraw): Get rid of the unused update_region
2468            instance variable
2469    
2470            * Thuban/UI/view.py: Add/update some doc-strings.
2471    
2472            * test/: new subdirectory with a bunch of unit tests.
2473    
2474            * test/README, test/test_table.py, test/test_save.py,
2475            test/test_menu.py, test/test_load.py: Initial set of tests and
2476            brief instructions on how to run them
2477    
2478    2002-08-29  Bernhard Herzog  <[email protected]>
2479    
2480            * Thuban/UI/renderer.py (ScreenRenderer.draw_shape_layer): Handle
2481            arcs with multiple parts.
2482    
2483            * Thuban/UI/view.py (ZoomInTool.MouseUp, ZoomOutTool.MouseUp):
2484            Handle degenrate rectangles.
2485    
2486            * Thuban/Model/table.py: Make writing records work correctly:
2487            (Table.__init__): Keep track of whether the DBF is open for
2488            writing
2489            (Table.write_record): Open the DBF file for writing when necessary
2490    
2491    2002-08-27  Bernhard Herzog  <[email protected]>
2492    
2493            * Thuban/Model/table.py (Table.write_record, Table.__init__): Open
2494            dbf files only for reading by default. Use a new writable dbf
2495            object for writing.
2496    
2497    2002-08-26  Bernhard Herzog  <[email protected]>
2498    
2499            * Thuban/UI/mainwindow.py: Refactor the context creation:
2500            (MainWindow.Context): New method to return a context
2501            (MainWindow.invoke_command, MainWindow.update_command_ui): Use the
2502            new method
2503    
2504            * Thuban/UI/tableview.py (TableGrid, LayerTableGrid): Split the
2505            layer table specific code from TableGrid into LayerTableGrid
2506            (TableFrame, LayerTableFrame): Split the layer table specific code
2507            from TableFrame into LayerTableFrame
2508            (LayerTableGrid.select_shape): Remove a debug print
2509    
2510            * Thuban/UI/mainwindow.py (MainWindow.LayerShowTable): Use the
2511            LayerTableFrame
2512    
2513    2002-08-23  Bernhard Herzog  <[email protected]>
2514    
2515            * Thuban/Model/layer.py (Layer.__init__): Make sure we have an
2516            absolute filename.
2517    
2518    2002-08-22  Bernhard Herzog  <[email protected]>
2519    
2520            * Thuban/Model/table.py (Table.write_record): New method to write
2521            records.
2522            (Table.__init__): Open the DBF file for writing too.
2523    
2524            * Thuban/UI/controls.py (RecordTable.SetValue): Write the value
2525            into the underlying table.
2526    
2527            * extensions/shapelib/shapefil.h (DBFCommit),
2528            extensions/shapelib/dbfopen.c (DBFCommit): New API function to
2529            commit any changes made to the DBF file.
2530    
2531            * Thuban/UI/mainwindow.py (make_check_current_tool)
2532            (_tool_command): Put the code that generates the "checked"
2533            callback into a separate function so that we can reuse it
2534            elsewhere
2535    
2536            * Thuban/Model/save.py (Saver): New class to handle serializing a
2537            session into an XML file. The main reason to introduce a class is
2538            that applications built on Thuban can derive from it so that they
2539            can save additional information in a session file.
2540            (save_session): Delegate almost all the work to the Saver class.
2541            Rename the filename argument to file because it may be a file like
2542            object now.
2543    
2544            * Thuban/Model/load.py: Get rid of the Python 1.5.2 compatibility
2545            code. Remove the little test code which would be executed when the
2546            module is run as a script which didn't work anymore since it can't
2547            import the other Thuban modules.
2548            (ProcessSession, load_session): Refactor the ProcessSession to
2549            have one method for each element start and end tag so that derived
2550            classes can easily override the processing of individual tags.
2551            Also, always parse with namespaces enabled because applications
2552            built on top of Thuban will likely use namespaces if they extend
2553            the session file format.
2554    
2555    2002-08-21  Bernhard Herzog  <[email protected]>
2556    
2557            * setup.py (ThubanInstall.run): Don't repr install_lib_orig
2558            because thubaninit_contents will do it for us.
2559    
2560    2002-08-16  Jan-Oliver Wagner <[email protected]>
2561    
2562            * Thuban/UI/mainwindow.py: menu item 'show session tree' now disable if
2563            tree window already open
2564    
2565    2002-08-15  Bernhard Herzog  <[email protected]>
2566    
2567            * Thuban/Model/layer.py (Layer.Destroy): Call the unboundd method
2568            with self.
2569    
2570            * Thuban/UI/view.py (MapCanvas.OnLeftUp): Only release the mouse
2571            when we have actually captured it.
2572    
2573            * Thuban/Model/layer.py (Layer.Destroy): New. Explicitly close the
2574            shapefile and destroy the table.
2575    
2576            * Thuban/Model/table.py (Table.Destroy): New. Close the DBF file.
2577    
2578    2002-08-14  Bernhard Herzog  <[email protected]>
2579    
2580            * Thuban/UI/controls.py (RecordTable.__init__): Remove the unused
2581            instance variable columns
2582            (RecordTable.GetTypeName): row and col may be negative in some
2583            cases.
2584    
2585            * setup.py (InstallLocal.initialize_options)
2586            (InstallLocal.finalize_options, InstallLocal.user_options): New
2587            option create-init-file to build a thubaninit.py when running
2588            install_local
2589            (InstallLocal.run): Create the thubaninit.py module when requested
2590            (thubaninit_contents): Split the template into several parts and
2591            create a new function thubaninit_contents that creates the
2592            contents of a thubaninit module.
2593            (ThubanInstall.run): Use the new function to create the thubaninit
2594            module.
2595    
2596    2002-07-30  Bernhard Herzog  <[email protected]>
2597    
2598            * Thuban/UI/application.py (ThubanApplication.OnExit): Do some
2599            cleanup.
2600            (ThubanApplication.MainLoop): Extend to automatically call OnExit.
2601    
2602            * Thuban/Model/session.py (Session.Destroy): Don't bypass the
2603            direct base class' Destroy method.
2604    
2605            * Thuban/Model/map.py (Map.ClearLayers): New method to delete all
2606            layers.
2607            (Map.Destroy): Destroy the label_layer as well and call the
2608            inherited Desatroymethod first so that no more messages are
2609            issued.
2610            (Map.RaiseLayer, Map.LowerLayer): Only issue LAYERS_CHANGED
2611            message if the stacking order actually has changed. Add
2612            doc-strings.
2613            (Map.BoundingBox): Correct the doc-string.
2614            (Map.AddLayer, Map.RemoveLayer, Map.Layers, Map.HasLayers)
2615            (Map.ProjectedBoundingBox, Map.SetProjection): Add doc-strings.
2616    
2617            * Thuban/Model/label.py (LabelLayer.ClearLabels): New to delete
2618            all labels.
2619    
2620    2002-07-29  Bernhard Herzog  <[email protected]>
2621    
2622            * Thuban/Model/map.py (Map.subscribe_layer_channels)
2623            (Map.unsubscribe_layer_channels): Put the code that (un)subscribes
2624            to a layer's channels into separate methods.
2625            (Map.RemoveLayer, Map.AddLayer): Call the new methods
2626            (Map.Destroy): Unsubscribe from a layer's channels before
2627            destroying it.
2628    
2629            * Thuban/UI/view.py (MapCanvas.find_shape_at): Change the
2630            selected_layer parameter to searched_layer which is the layer to
2631            search in.
2632            (MapCanvas.SelectShapeAt): New parameter layer to restrict the
2633            search to that layer. Return the selected layer and shape.
2634    
2635            * Examples/simple_extensions/simple_tool.py (simple_tool): Fix a
2636            typo
2637    
2638    2002-07-24  Bernhard Herzog  <[email protected]>
2639    
2640            * Thuban/UI/application.py (ThubanApplication.create_session):
2641            Extend the doc string.
2642            (ThubanApplication.subscribe_session)
2643            (ThubanApplication.unsubscribe_session): New methods to
2644            subscribe/unsubscribe to/from session channels.
2645            (ThubanApplication.SetSession): Call the new methods here.
2646            (ThubanApplication.maps_changed, ThubanApplication.set_map):
2647            Renamed set_map to maps_changed. Its now a subscriber for
2648            MAPS_CHANGED.
2649    
2650            * Thuban/UI/view.py (ZoomOutTool.MouseUp): Use the correct
2651            x-coordinate in case of simple clicks
2652    
2653            * Thuban/Model/base.py (Modifiable.changed): Apply the args tuple,
2654            don't pass it as a parameter
2655    
2656            * Thuban/Model/session.py (Session.RemoveMap): New
2657    
2658            * Thuban/UI/mainwindow.py (MainWindow.__init__): Turn the initial
2659            window size into a parameter.
2660    
2661    2002-07-23  Bernhard Herzog  <[email protected]>
2662    
2663            * Thuban/UI/menu.py (Menu.item_index): Also search for menus not
2664            just commands.
2665    
2666            * Thuban/UI/mainwindow.py (MainWindow.__init__): Change the
2667            parameter list a bit to allow setting the window title and the
2668            initial message in the status bar. Update the callers.
2669    
2670            * Thuban/UI/application.py (ThubanApplication.OnInit)
2671            (ThubanApplication.CreateMainWindow): Put the mainwindow
2672            instantiation into a separate method so that it can be overridden
2673            by a subclass.
2674    
2675    2002-07-19  Bernhard Herzog  <[email protected]>
2676    
2677            * Thuban/Model/session.py: Issue a CHANGED message every time
2678            another changed message is issued to make it easier to get
2679            notified of changes.
2680            (Session): Update the doc string
2681            (Session.forward): Issue changed-events as CHANGED as well.
2682            (Session.changed): Overwrite the inherited version to issue
2683            CHANGED events as well.
2684    
2685            * Thuban/UI/tree.py: We can now simply subscribe to the session's
2686            CHANGED channel to be informed of changes.
2687            (SessionTreeCtrl.session_channels): Not needed any longer.
2688            (SessionTreeCtrl.unsubscribe_all, SessionTreeCtrl.session_changed):
2689            Only have to (un)subscribe CHANGED
2690    
2691            * Thuban/Model/map.py (Map.TreeInfo): Deal better with empty maps.
2692    
2693            * Thuban/UI/main.py, Thuban/UI/__init__.py: Move the work-around
2694            for the wxPython locale bug to __init__.py so that it's
2695            automatically executed by anybody using UI code from Thuban.
2696    
2697    2002-07-18  Bernhard Herzog  <[email protected]>
2698    
2699            * Thuban/UI/main.py (main): app no longer needs to be global
2700    
2701            * Thuban/UI/mainwindow.py (MainWindow.__init__): Add application
2702            as parameter and store it in an instance variable
2703            (MainWindow.invoke_command, MainWindow.update_command_ui)
2704            (MainWindow.save_modified_session, MainWindow.NewSession)
2705            (MainWindow.OpenSession, MainWindow.SaveSession)
2706            (MainWindow.SaveSessionAs, MainWindow.ShowSessionTree): Use self's
2707            application object.
2708    
2709            * Thuban/UI/application.py (ThubanApplication.OnInit): Instantiate
2710            the main window with self.
2711    
2712            * Thuban/UI/context.py: New module with the context class
2713    
2714            * Thuban/UI/command.py (Command): Update doc string.
2715    
2716            * Thuban/UI/mainwindow.py (MainWindow.invoke_command,
2717            MainWindow.update_command_ui): Pass an instance of the context
2718            class to the command's methods
2719            (check_current_tool, call_method): Handle the new context
2720            implementation
2721    
2722            * Examples/simple_extensions/simple_tool.py (simple_tool,
2723            check_simple_tool): Handle the new context implementation
2724    
2725            * Examples/simple_extensions/simple_command.py (simple_command):
2726            Handle the new context implementation. Update the comments about
2727            the context.
2728    
2729            * Thuban/UI/application.py (ThubanApplication.SetSession): Add
2730            doc-string
2731            (ThubanApplication.Session): New method to return the session
2732            object
2733    
2734            * Thuban/UI/tree.py (SessionTreeCtrl.update_tree): The
2735            interactor's selected_layer may not be a layer of the current
2736            session when the tree is updated while a new session is being set.
2737    
2738    2002-07-17  Bernhard Herzog  <[email protected]>
2739    
2740            * Thuban/UI/tree.py (color_string): Removed. No longer used.
2741            (SessionTreeCtrl.update_tree, SessionTreeCtrl.add_items): Split
2742            update_tree into update_tree and add_items. The tree now uses a
2743            more generic way to display the contents of the tree.
2744            (SessionTreeCtrl): Add a doc string explaining the TreeInfo method
2745    
2746            * Thuban/Model/layer.py (Layer.TreeInfo),
2747            Thuban/Model/extension.py (Extension.TreeInfo),
2748            Thuban/Model/map.py (Map.TreeInfo),
2749            Thuban/Model/session.py (Session.TreeInfo):
2750            Add TreeInfo methods to implement the new tree view update scheme
2751    
2752    2002-07-16  Bernhard Herzog  <[email protected]>
2753    
2754            * Thuban/UI/application.py: Don't use "import from" for the
2755            MainWindow. It can't always be resolved.
2756            (ThubanApplication.OnInit): change reference to MainWindow
2757            accordingly.
2758    
2759            * Thuban/UI/menu.py (Menu.SetItems): New method to replace a menu
2760            completely
2761    
2762    2002-07-10  Bernhard Herzog  <[email protected]>
2763    
2764            * setup.py (create_init_module): New configurable variable whose
2765            default depends on the platform we're running on.
2766            (ThubanInstall.initialize_options): Initialize
2767            self.create_init_module from the global create_init_module
2768            (ThubanInstall.user_options): indictate that the options
2769            create-init-module and init-module-dir have arguments.
2770    
2771            * setup.py: In the setup call change the version number to include
2772            cvs.
2773    
2774            * MANIFEST.in: Add the files in Examples
2775    
2776    2002-07-09  Bernhard Herzog  <[email protected]>
2777    
2778            * setup.py: In the setup call, use the thuban homepage as the
2779            value of the url parameter.
2780    
2781            * Examples: New subdirectory for examples.
2782    
2783            * Examples/simple_extensions/simple_tool.xpm,
2784            Examples/simple_extensions/simple_tool.py,
2785            Examples/simple_extensions/simple_command.py,
2786            Examples/simple_extensions/README: Simple examples showing how to
2787            add new commands and tools.
2788    
2789            * setup.cfg (bdist_rpm): Add the default value for prefix and tell
2790            bdist_rpm that we also have an install script.
2791            (bdist_inno): Add 2002 to the copyright notice.
2792    
2793            * setup.py: Create a file in python's site-packages directory to
2794            make installation of Thuban as a library easier.
2795            (ThubanInstall.user_options): Add two new options,
2796            create-init-module and init-module-dir
2797            (ThubanInstall.expand_with_pure_python_dirs): New method to expand
2798            filenames for installation in the default directories.
2799            (ThubanInstall.select_scheme, ThubanInstall.convert_paths): Extend
2800            the inherited methods to capture some filenames before they're
2801            transformed too much by distutils.
2802            (ThubanInstall.run): Create the init module if requested.
2803            (ThubanInstall.thuban_init_filename): New method to return the
2804            full name of the init module.
2805            (ThubanInstall.get_outputs): Append the filename of the init
2806            module.
2807    
2808    2002-07-08  Bernhard Herzog  <[email protected]>
2809    
2810            * setup.py (thuban_bdist_rpm): Extend this version of bdist_rpm to
2811            handle the prefix properly which means that the default for the
2812            installation prefix should be /usr for RPMs and /usr/local when
2813            doing a normal source install.
2814            (bdist_rpm_install_script): Script to override the default install
2815            commands in the specfile generated by the bdist_rpm command.
2816            (thuban_bdist_rpm.user_options): Add a prefix option
2817            (thuban_bdist_rpm.initialize_options): Init the prefix option.
2818            Create the script files for the spec files as empty files here
2819            (thuban_bdist_rpm._make_spec_file): Override the inherited method
2820            to fill the script files with content.
2821    
2822            * Thuban/Model/save.py (relative_filename): Wrapper around
2823            Thuban.Lib.fileutil.relative_filename that accepts an empty dir
2824            argument. save_session now automatically uses this version,
2825            solving a problem when saving to a relative filename.
2826    
2827            * setup.py: In the setup call, make sure that the library
2828            directories are under $prefix/lib not directly under $prefix.
2829    
2830    2002-06-20  Jan-Oliver Wagner <[email protected]>
2831    
2832            * Thuban/Model/extension.py: new module to handle extension objects.
2833            * Thuban/Model/messages.py: new messages for extensions.
2834            * Thuban/Model/session.py (Session.Extensions, Session.HasExtensions,
2835            Session.AddExtension): new for handling extensions.
2836            Also some other minor changes to round up extension handling.
2837            * Thuban/UI/tree.py (SessionTreeCrtl:update_tree): Added visualization
2838            of Extension titles and title and names of its objects.
2839    
2840    2002-05-29  Bernhard Herzog  <[email protected]>
2841    
2842            * Thuban/UI/mainwindow.py (MainWindow.bind_command_events): Bind
2843            the events for a command.
2844            (MainWindow.add_toolbar_command, MainWindow.add_menu_command):
2845            Call bind_command_events to bind the events. add_toolbar_command
2846            can now bind events too so that it's possible to have commands
2847            that are only available through the toolbar.
2848            (MainWindow.init_ids): New instance variable events_bound to keep
2849            track of for which commands events have been bound.
2850    
2851    2002-05-28  Bernhard Herzog  <[email protected]>
2852    
2853            * Thuban/UI/menu.py: New module to build and manage menus.
2854    
2855            * Thuban/UI/mainwindow.py: Remove some unused imports.
2856            (MainWindow.__init__, main_menu): move the definition of the main
2857            menu from __init__ to the Menu instance main_menu.
2858            (MainWindow.build_menu_bar, MainWindow.build_menu): New methods to
2859            build the menu bar and sub-menus from a menu description.
2860    
2861            * Thuban/UI/application.py (ThubanApplication.OnInit): Read the
2862            startup file
2863            (ThubanApplication.read_startup_files): New method to run
2864            ~/.thuban/thubanstart.py
2865    
2866            * Thuban/UI/mainwindow.py (MainWindow.__init__, main_toolbar):
2867            Move the toolbar definition to the Menu instance main_toolbar.
2868            (MainWindow.build_toolbar): New method to build the toolbar
2869            similar to the build_menu methods
2870    
2871    2002-05-23  Bernhard Herzog  <[email protected]>
2872    
2873            * Thuban/UI/mainwindow.py (MainWindow.__init__): Fix spelling of
2874            layer_outline_color. Fix it in the definition of the command too.
2875    
2876            * Thuban/UI/command.py (Command): Fix typo in doc string
2877    
2878    2002-05-22  Bernhard Herzog  <[email protected]>
2879    
2880            * Thuban/UI/mainwindow.py (MainWindow.RunMessageBox): Fix a typo
2881            in the docstring
2882    
2883    2002-05-15  Bernhard Herzog  <[email protected]>
2884    
2885            * Thuban/Model/layer.py (Layer.open_shapefile): Set bbox to None
2886            when the shapefile is empty.
2887            (Layer.BoundingBox, Layer.LatLongBoundingBox): Both methods may
2888            now return None for empty shapefiles. Update doc-strings.
2889    
2890            * Thuban/Model/map.py (Map.BoundingBox): Add doc-string. Deal with
2891            the layer's bbox being None.
2892    
2893            * Thuban/UI/tree.py (SessionTreeCtrl.update_tree): Deal with the
2894            layer's bbox being None.
2895    
2896            * Thuban/UI/view.py (MapCanvas.shape_selected): Only redraw when
2897            necessary.
2898            (MapCanvas.__init__): New instance variables, last_selected_layer
2899            and last_selected_shape to determine how the selection has
2900            changed.
2901    
2902            * Thuban/UI/tableview.py (TableGrid.__init__): Do not call
2903            AutoSizeColumns because it will cause a traversal of the entire
2904            table which for large .dbf files will take a very long time.
2905    
2906    2002-05-14  Bernhard Herzog  <[email protected]>
2907    
2908            * Thuban/Model/layer.py (Layer.open_shapefile): Choose a better
2909            maximum depth for the tree than shapelib does by default.
2910    
2911    2002-05-10  Bernhard Herzog  <[email protected]>
2912    
2913            * setup.py (py_modules): The shptree modules doesn't have a
2914            wrapper, so don't include it in the py_modules
2915    
2916    2002-05-08  Bernhard Herzog  <[email protected]>
2917    
2918            * extensions/shapelib/shptree.c (compare_ints): Make arguments
2919            const void * as in the qsort prototype
2920            (SHPTreeFindLikelyShapes): Remove some unused variables.
2921    
2922            * Thuban/UI/view.py (PanTool.MouseMove): Use the bitmap the view
2923            maintains to redraw the window during a drag.
2924            (MapCanvas.unprojected_rect_around_point): New method to determine
2925            a small region around a point for hit-testing.
2926            (MapCanvas.find_shape_at): Only test the shapes in a small region
2927            around the point.
2928    
2929            * setup.py: Increment the version to 0.1.2
2930    
2931            * Thuban/UI/tree.py (SessionTreeCtrl.unsubscribe_all): Remove a
2932            debug print and set session to None after unsubscribing
2933    
2934  2002-05-07  Bernhard Herzog  <[email protected]>  2002-05-07  Bernhard Herzog  <[email protected]>
2935    
2936            * Data/iceland_sample.session, Data/iceland_sample.thuban: Rename
2937            the file to have a .thuban extension.
2938    
2939          * Thuban/UI/tree.py (session_channels): New class constant with          * Thuban/UI/tree.py (session_channels): New class constant with
2940          all the session channels to subscribe to to update the tree          all the session channels to subscribe to to update the tree
2941          (SessionTreeCtrl.session_changed): Remember the session so that we          (SessionTreeCtrl.session_changed): Remember the session so that we
# Line 120  Line 3056 
3056          * Thuban/UI/messages.py (VIEW_POSITION): New message for the          * Thuban/UI/messages.py (VIEW_POSITION): New message for the
3057          position in the statusbar          position in the statusbar
3058    
3059  2002-04-26      Frank Koormann <[email protected]>  2002-04-26  Frank Koormann <[email protected]>
3060    
3061          * Thuban/UI/mainwindow.py: AddLayer, Dialog title s/session/data          * Thuban/UI/mainwindow.py: AddLayer, Dialog title s/session/data
3062    
3063  2002-04-24      Frank Koormann <[email protected]>  2002-04-24  Frank Koormann <[email protected]>
3064            
3065          * Resources/Bitmaps/identify.xpm: shadow added          * Resources/Bitmaps/identify.xpm: shadow added
3066    
3067          * Resources/Bitmaps/fullextent.xpm: new          * Resources/Bitmaps/fullextent.xpm: new
           
 2002-04-22      Jan-Oliver Wagner <[email protected]>  
3068    
3069          * Thuban/UI/tree.py (update_tree): added test for None on map bounding box  2002-04-22  Jan-Oliver Wagner <[email protected]>
3070    
3071            * Thuban/UI/tree.py (update_tree): added test for None on map bounding
3072            box
3073    
3074  2002-04-21      Jan-Oliver Wagner <[email protected]>  2002-04-21  Jan-Oliver Wagner <[email protected]>
3075    
3076          * Thuban/UI/proj4dialog.py (UTMProposeZoneDialog): new          * Thuban/UI/proj4dialog.py (UTMProposeZoneDialog): new
3077    
3078          * Thuban/UI/tree.py (update_tree): added added map extent          * Thuban/UI/tree.py (update_tree): added added map extent
3079    
3080          * Thuban/UI/mainwindow.py (_method_command): extended by parameter          * Thuban/UI/mainwindow.py (_method_command): extended by parameter
3081          icon; added map_full_extend as tool          icon; added map_full_extend as tool
3082    
3083  2002-04-19      Jan-Oliver Wagner <[email protected]>  2002-04-19  Jan-Oliver Wagner <[email protected]>
3084    
3085          * Thuban/UI/mainwindow.py (SaveSession): launch save as dialog for          * Thuban/UI/mainwindow.py (SaveSession): launch save as dialog for
3086          saving _new_ sessions          saving _new_ sessions
# Line 245  Line 3182 
3182    
3183          * setup.py: increase version number to 0.1          * setup.py: increase version number to 0.1
3184          (data_dist): New command class for data distribution          (data_dist): New command class for data distribution
           
3185    
3186  2001-09-14  Bernhard Herzog  <[email protected]>  2001-09-14  Bernhard Herzog  <[email protected]>
3187    
3188          * Thuban/UI/identifyview.py (IdentifyListCtrl.selected_shape):          * Thuban/UI/identifyview.py (IdentifyListCtrl.selected_shape):
3189          Handle the case of no layer (i.e. layer is None) properly.          Handle the case of no layer (i.e. layer is None) properly.
3190    
3191          * Thuban/UI/proj4dialog.py (UTMDialog.__init__, Proj4Dialog.__init__):          * Thuban/UI/proj4dialog.py (UTMDialog.__init__, Proj4Dialog.__init__):
3192          Set the initial selection of the combo boxes to reflect the          Set the initial selection of the combo boxes to reflect the
3193          projection we're starting with in a way that works on windows,          projection we're starting with in a way that works on windows,
3194          too.          too.
# Line 362  Line 3298 
3298          (MainWindow.identify_view_on_demand): Store the interactor in an          (MainWindow.identify_view_on_demand): Store the interactor in an
3299          instvar and use that reference instead of going through main.app          instvar and use that reference instead of going through main.app
3300    
3301          * Thuban/UI/mainwindow.py (MainWindow.ShowSessionTree):          * Thuban/UI/mainwindow.py (MainWindow.ShowSessionTree):
3302          * Thuban/UI/application.py (ThubanApplication.OnInit):          * Thuban/UI/application.py (ThubanApplication.OnInit):
3303          * Thuban/UI/main.py (main): Create the session tree view in main          * Thuban/UI/main.py (main): Create the session tree view in main
3304          with the new mainwindow method ShowSessionTree and not directly          with the new mainwindow method ShowSessionTree and not directly
3305          the application's OnInit method          the application's OnInit method
# Line 379  Line 3315 
3315          layer to the tableview dialog.          layer to the tableview dialog.
3316    
3317          * Thuban/UI/tableview.py: Add some doc-strings          * Thuban/UI/tableview.py: Add some doc-strings
3318          (TableGrid):          (TableGrid):
3319          (TableGrid.OnRangeSelect):          (TableGrid.OnRangeSelect):
3320          (TableGrid.OnSelectCell):          (TableGrid.OnSelectCell):
3321          (TableFrame.__init__):          (TableFrame.__init__):
# Line 446  Line 3382 
3382  2001-09-05  Bernhard Herzog  <[email protected]>  2001-09-05  Bernhard Herzog  <[email protected]>
3383    
3384          * Thuban/UI/view.py (MapCanvas.__init__): New argument, interactor.          * Thuban/UI/view.py (MapCanvas.__init__): New argument, interactor.
3385            
3386          * Thuban/UI/mainwindow.py (MainWindow.__init__): New argument          * Thuban/UI/mainwindow.py (MainWindow.__init__): New argument
3387          interactor to pass through to the MapCanvas          interactor to pass through to the MapCanvas
3388            
3389          * Thuban/UI/application.py (ThubanApplication.OnInit): Use the new          * Thuban/UI/application.py (ThubanApplication.OnInit): Use the new
3390          argument to the MainWindow constructor to get rid of the ugly hack          argument to the MainWindow constructor to get rid of the ugly hack
3391          that made main.app available early just so that the mapcanvas          that made main.app available early just so that the mapcanvas
# Line 496  Line 3432 
3432          (ThubanInstall.run): Remove the leading install root from the          (ThubanInstall.run): Remove the leading install root from the
3433          script filename if an install root was specified and use the new          script filename if an install root was specified and use the new
3434          link_file method          link_file method
3435            
3436          * Thuban/UI/mainwindow.py (MainWindow.AddLayer): Fit the map to          * Thuban/UI/mainwindow.py (MainWindow.AddLayer): Fit the map to
3437          the window when the first layer is added to the map.          the window when the first layer is added to the map.
3438    
# Line 533  Line 3469 
3469          (InnoIconItem): Helper class for bdist_inno          (InnoIconItem): Helper class for bdist_inno
3470          (thuban_bdist_inno): Thuban specific version of bdist_inno. Added          (thuban_bdist_inno): Thuban specific version of bdist_inno. Added
3471          this together with the appropriate parameters, to the setup call.          this together with the appropriate parameters, to the setup call.
3472            
3473          * setup.cfg (bdist_inno): added new section for the inno setup          * setup.cfg (bdist_inno): added new section for the inno setup
3474          installer          installer
3475    

Legend:
Removed from v.152  
changed lines
  Added in v.906

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26