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

Legend:
Removed from v.252  
changed lines
  Added in v.846

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26