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

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

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

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

Legend:
Removed from v.59  
changed lines
  Added in v.1422

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26