/[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 988 by bh, Thu May 22 16:46:23 2003 UTC revision 1459 by bh, Fri Jul 18 15:09:32 2003 UTC
# Line 1  Line 1 
1    2003-07-18  Bernhard Herzog  <[email protected]>
2    
3            * test/runtests.py: The test suite can now be run without an X
4            connection. To make sure this remains true, remove the DISPLAY
5            environment variable so that an error occurs if the wxGTK is
6            imported accidentally
7    
8    2003-07-18  Bernhard Herzog  <[email protected]>
9    
10            * Thuban/UI/viewport.py: Remove unused imports
11    
12            * Thuban/UI/view.py: Remove unused imports
13    
14    2003-07-18  Bernhard Herzog  <[email protected]>
15    
16            * test/test_export.py Remove unused imports. The OutputTransform
17            function is now in viewport.py and is called output_transform
18            (TestScalebar.test_output_transform)
19            (TestScalebar.test_OutputTransform): Renamed to
20            test_output_transform and updated to use output_transform instead
21            of OutputTransform
22    
23            * Thuban/UI/view.py (OutputTransform): Moved to viewport.py and
24            renamed.
25            (MapCanvas.Export, MapPrintout.draw_on_dc): OutputTransform was
26            renamed to output_transform
27    
28            * Thuban/UI/viewport.py (OutputTransform, output_transform):
29            Rename to output_transform
30    
31    2003-07-18  Bernhard Herzog  <[email protected]>
32    
33            * Thuban/Model/layer.py (Layer.__init__): Rename
34            classificationField to classificatin_column and init it here so
35            that it can be used in SetClassificationColumn
36            (Layer.GetClassificationColumn, Layer.GetClassificationField):
37            Rename to GetClassificationColumn.
38            (Layer.SetClassificationColumn, Layer.SetClassificationField):
39            Rename to SetClassificationColumn and issue a LAYER_CHANGED
40            message if the column changes.
41            (Layer._classification_changed, Layer.ClassChanged): Rename to
42            _classification_changed. Update the callers.
43            (Layer.SetShapeStore): Further field->column renames.
44    
45            * Thuban/Model/load.py (SessionLoader.start_classification)
46            (SessionLoader.start_clpoint): Updates because of
47            field->column method name changes in the Layer class
48    
49            * Thuban/Model/save.py (SessionSaver.write_classification): Updates
50            because of field->column method name changes in the Layer class
51    
52            * Thuban/UI/classifier.py (Classifier.__init__)
53            (Classifier._OnTry, Classifier._OnRevert): Updates because of
54            field->column method name changes in the Layer class
55    
56            * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Updates
57            because of field->column method name changes in the Layer class
58    
59            * Thuban/UI/viewport.py (ViewPort.find_shape_at): Updates because
60            of field->column method name changes in the Layer class
61    
62            * test/test_save.py (SaveSessionTest.testClassifiedLayer)
63            (SaveSessionTest.testClassifiedLayer): Update because of
64            field->column method name changes in the Layer class
65    
66            * test/test_layer.py (SetShapeStoreTests.setUp)
67            (SetShapeStoreTests.test_sanity): Update because of field->column
68            method name changes in the Layer class
69            (TestLayerModification.setUp): Subscribe to LAYER_CHANGED as well
70            (TestLayerModification.test_sanity)
71            (TestLayerModification.test_initial_settings): remove unsued code
72            and rename to test_sanity.
73            (TestLayerModification.test_set_classification): New test for
74            SetClassification and SetClassificationField.
75    
76    2003-07-18  Bernhard Herzog  <[email protected]>
77    
78            * test/test_classgen.py (TestFixedRamp.test): Extend test to check
79            the non-fixed values as well. The old test would have accepted a
80            fixed ramp that only returnes the fixed properties
81    
82    2003-07-17  Jonathan Coles   <[email protected]>
83    
84            * Doc/manual/mainwindow.png, Doc/manual/mainwindow.xcf: Screen
85            shots for the manual. The XCF file is the source image and
86            has additional layers to support changes.
87    
88            * Doc/manual/thuban-manual.xml: Wrote an initial Introduction.
89    
90            * Thuban/UI/classifier.py (Classifier.__BuildClassification):
91            Return both the new class and the field name.
92    
93            * Thuban/UI/mainwindow.py (MainWindow.ToggleLegend): Don't
94            fit the map to the window as this changes any zoom level that
95            the user may have set.
96    
97    2003-07-16  Jonathan Coles   <[email protected]>
98    
99            * Thuban/Model/classgen.py (generate_singletons,
100            generate_uniform_distribution, generate_quantiles): Remove
101            fixes parameter, but maintain the same functionality by having
102            the calling function pass a FixedRamp object for the ramp.
103            (FixedRamp): New. Adapts a ramp to have fixed property values.
104    
105            * Thuban/Model/classification.py: Use new CLASS_CHANGED message.
106            (Classification): Inherit from Publisher.
107            (Classification.__init__): Remove the layer parameter.
108            Classifications no longer need to have a parent layer.
109            (Classification.GetField, Classification.GetFieldType,
110            Classification.SetFieldInfo): Removed. The field name is stored
111            in the layer, and the type can be retreived by calling
112            Layer.GetFieldType().
113            (Classification._set_layer, Classification.GetLayer): Removed.
114            Classifications no longer have a parent layer.
115    
116            * Thuban/Model/layer.py (Layer.Destroy): Unsubscribe from the
117            classification.
118            (Layer.SetShapeStore): Reset the classification first while
119            we still have the old shape store to work with.
120            (Layer.GetClassificationField, Layer.SetClassificationField):
121            New. Method for getting/setting the field to classify on.
122            (Layer.SetClassification): Simplified now that the layer
123            simply has to hold a reference to the classification and not
124            tell the classification who owns it.
125            Fixes RTbug #2023.
126    
127            * Thuban/Model/load.py (SessionLoader.start_classification):
128            Set the field name on the layer, not the classification.
129    
130            * Thuban/Model/messages.py: Add CLASS_CHANGED for when a
131            classification is modified.
132    
133            * Thuban/Model/save.py (SessionSaver.write_classification):
134            Get the field name and type from the layer.
135    
136            * Thuban/Model/table.py (table_to_dbf, table_to_csv): Renamed
137            parameter records to rows and add docstring. Fixes RTbug #1997.
138    
139            * Thuban/UI/classgen.py (ClassGenDialog.OnOK): Use a fixed
140            ramp when we need to fix certain values of a ramp rather than
141            using the old fixes parameter. Fixes RTbug #2024.
142    
143            * Thuban/UI/classifier.py (ClassGrid.CreateTable): Add fieldType
144            parameter.
145            (ClassTable.Reset): Add fieldType parameter and use it, rather
146            than asking the classification.
147            (Classifier.__init__): Remember the original class's field
148            and ask the layer for the field type, rather than the classification.
149            (Classifier.__SetGridTable): Retrieve the field and field type
150            for the table because they are not in the classification.
151            (Classifier._OnTry, Classifier._OnRevert): Set the classification
152            field on the layer in addition to the classification itself.
153    
154            * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Get the
155            classification field from layer.
156    
157            * Thuban/UI/viewport.py (ViewPort.find_shape_at): Get the
158            classification field from layer. Split up tests and remove
159            *-imports. Fixes RTbug #1992.
160    
161            * test/test_classgen.py (TestFixedRamp): Test for the FixedRamp class.
162    
163            * test/test_classification.py
164            (TestClassification.test_classification): Remove tests for methods
165            that no longer exist.
166    
167            * test/test_layer.py (SetShapeStoreTests.setUp): Classification
168            __init__ no longer has a field parameter, use SetClassificationField.
169            (SetShapeStoreTests.test_sanity): Use layer object to get class
170            field info.
171    
172            * test/test_save.py (SaveSessionTest.testClassifiedLayer): Use
173            SetClassificationField on layer to set class field info.
174    
175            * test/test_viewport.py: Renamed from test/test_view.py.
176    
177    2003-07-16  Jan-Oliver Wagner <[email protected]>
178    
179            * Doc/manual/thuban-manual.xml: Added authors and an initial
180            coarse structure.
181    
182    2003-07-15  Bernhard Herzog  <[email protected]>
183    
184            * test/support.py (FloatComparisonMixin): This is a mix-in class
185            and therefore should not be derived from any other class.
186    
187            * test/test_range.py (RangeTest): FloatComparisonMixin is a
188            mix-in, so derive from TestCase as well.
189    
190    2003-07-15  Bernhard Herzog  <[email protected]>
191    
192            * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Rework the
193            draw_func handling a bit to remove one layer of indirection. This
194            makes the renderer about 10% faster in the non-classifying case
195            and the code a bit cleaner
196            (MapRenderer.draw_point_shape): Add the pen and brush parameters
197            and set them in the dc. Now the draw_point_shape method and
198            wxproj's draw_polygon_shape function have basically the same
199            signature so that both can be directly used as draw_func
200    
201    2003-07-15  Bernhard Herzog  <[email protected]>
202    
203            * Thuban/Model/save.py (SessionSaver.write_classification): Encode
204            string values (in addition to the labels) as UTF 8
205    
206            * Thuban/Model/load.py (SessionLoader.start_clpoint): Decode the
207            values if the field type is string
208    
209            * test/test_save.py (SaveSessionTest.testClassifiedLayer): Test
210            saving a session with non-ascii string classification values.
211    
212            * test/test_load.py (TestClassification.file_contents)
213            (TestClassification.test): Check for non-ascii values in string
214            classifications
215    
216    2003-07-14  Jonathan Coles   <[email protected]>
217    
218            * test/test_view.py: New. Tests for ViewPort.
219    
220    2003-07-14  Frank Koormann   <[email protected]>
221    
222            * Thuban/Model/load.py (SessionLoader.start_map): Encode map
223            title to latin1.  Fixes https://intevation.de/rt/webrt?serial_num=2013
224    
225            * test/test_load_0_8.py (TestUnicodeStrings): New, test load of
226            unicode strings from session file: session title, map title and
227            projection name.
228            
229    2003-07-10  Jonathan Coles   <[email protected]>
230    
231            * Thuban/UI/viewport.py (Tool.MouseUp): Should have called
232            drag_stop, not drag_move when the mouse is released.
233    
234    2003-07-10  Jonathan Coles   <[email protected]>
235    
236            The most important part of this is the seperation of view.py into
237            two pieces. viewport.py now has a class called ViewPort which
238            contains all the non-wx parts of view.py and can therefore be
239            tested. view.py contains only the wx-specific parts and is fairly
240            simple.
241    
242            * Thuban/UI/view.py: Stripped out all non-wx functionality. Fixes
243            RTTbug #1992.
244            * Thuban/UI/viewport.py: New. Contains non-wx view functionality.
245            RTTbug #1992.
246    
247            * Thuban/Model/classgen.py (generate_singletons,
248            generate_uniform_distribution, generate_quantiles):
249            Added 'fixes' parameter so that property attributes can
250            be held constant over the generated classification groups.
251            (CustomRamp.GetProperties): Remove unused variables.
252    
253            * Thuban/Model/map.py (Map.SetProjection): Send the old
254            projection as an argument to listeners of the MAP_PROJECTION_CHANGED
255            event.
256    
257            * Thuban/Model/table.py (table_to_dbf, table_to_csv): Added 'records'
258            parameter which is a list of records that restricts which
259            records are saved. Fixes RTbug #1997.
260    
261            * Thuban/UI/application.py (ThubanApplication.ShowExceptionDialog):
262            Port exception dialog from GREAT-ER. Fixes RTbug #1993.
263    
264            * Thuban/UI/classgen.py (ClassGenDialog.__init__): Add controls
265            to allow the user to fix line color/width on generated groups.
266            (ClassGenDialog.OnOK): Use new 'fixes' parameter of the generate_*
267            functions to optionally fix group properties.
268    
269            * Thuban/UI/main.py (main): Set exception hook to the
270            ShowExceptionDialog. Fixes RTbug #1993.
271    
272            * Thuban/UI/mainwindow.py (MainWindow.ShowTableView): Raise
273            the table window when it is selectd to be shown.
274    
275            * Thuban/UI/tableview.py (QueryTableFrame.__init__): Add an
276            Export Selection button and move the export buttons underneath
277            the table.
278            (QueryTableFrame.UpdateStatusText): Added event argument so
279            that it can respond to grid selection events. The status text
280            is now updated even when the table is not associated with a
281            layer as was previously assumed.
282            (QueryTableFrame.OnGridSelectRange, OnGridSelectCell): Removed.
283            UpdateStatusText responds to these events.
284            (QueryTableFrame.OnSaveAs): Renamed to doExport.
285            (QueryTableFrame.doExport): Helper function that saves the
286            entire table, or selected rows, to a file.
287            (QueryTableFrame.OnExport, QueryTableFrame.OnExportSel): New.
288            Respond to export button events and call doExport.
289    
290            * extensions/thuban/gdalwarp.cpp (ProjectRasterFile): Make sure
291            the function doesn't return NULL without first setting a Python
292            Error.
293    
294            * test/runtests.py (main): Only print "Unknown option" for
295            unsupported options.
296    
297            * test/support.py (FloatComparisonMixin.assertFloatEqual): Take
298            optional epsilon argument to specify floating point accuracy.
299            (FloatComparisonMixin.assertFloatSeqEqual): Call assertFloatEqual
300            for each item test.
301    
302            * test/test_csv_table.py (TestCSVTable.test_table_to_cvs): Add
303            tests for saving selected records.
304    
305            * test/test_dbf_table.py (TestTableToDBF.test_table_to_dbf): Add
306            tests for saving selected records.
307    
308            * test/test_map.py (TestMapWithContents.test_set_projection):
309            MAP_PROJECTION_CHANGED events send the old projection.
310    
311            * test/test_session.py
312            (TestSessionWithContent.test_forward_map_projection):
313            MAP_PROJECTION_CHANGED events send the old projection.
314    
315            * test/test_table.py (TableTest): Update tests to use non-deprecated
316            functions.
317    
318    2003-07-08  Bernhard Herzog  <[email protected]>
319    
320            * Thuban/Model/transientdb.py (TransientTableBase.Width): The type
321            constants in the column objects are the standard ones defined in
322            the table module.
323    
324            * test/test_transientdb.py
325            (TestTransientTable.test_transienttable_to_dbf): New. Test whether
326            exporting transient tables as DBF works. This should catch the bug
327            just fixed in TransientTableBase.Width.
328    
329    2003-07-08  Bernhard Herzog  <[email protected]>
330    
331            * Thuban/Model/classgen.py (CustomRamp.GetProperties): Compute the
332            interpolated colors correctly.
333    
334            * test/test_classgen.py (TestCustomRamp.test_color_interpolation):
335            New. Test case for the fix in classgen.py
336    
337    2003-07-08  Bernhard Herzog  <[email protected]>
338    
339            * test/runtests.py (main): Make the default output less verbose
340            and add a verbosity option (-v) to get the old output
341    
342    2003-07-08  Bernhard Herzog  <[email protected]>
343    
344            * Resources/XML/thuban-0.9.dtd: New. This will become the DTD for
345            0.9.
346    
347            * Thuban/Model/transientdb.py (TransientJoinedTable.JoinType):
348            New. Return the join type
349    
350            * Thuban/Model/save.py (SessionSaver.write_session): Use new 0.9
351            DTD
352            (SessionSaver.write_data_containers): Save the join type for
353            joined tables
354    
355            * Thuban/Model/load.py (SessionLoader.__init__): Add the new 0.9
356            namespace
357            (SessionLoader.start_jointable): Handle the jointype attribute
358    
359            * test/test_load_0_8.py: New. Effectively a copy of test_load.py
360            as of Thuban 0.8. These are now tests to determine whether Thuban
361            can still read files generated by Thuban 0.8
362    
363            * test/test_load.py (LoadSessionTest.dtd)
364            (TestSingleLayer.file_contents)
365            (TestLayerVisibility.file_contents, TestLabels.file_contents)
366            (TestLayerProjection.file_contents)
367            (TestRasterLayer.file_contents, TestJoinedTable.file_contents)
368            (TestJoinedTable.file_contents)
369            (TestLoadError.file_contents): Update for new DTD
370            (TestJoinedTable.file_contents, TestJoinedTable.setUp): Add test
371            for new join type attribute
372    
373            * test/test_save.py (SaveSessionTest.dtd)
374            (SaveSessionTest.testEmptySession)
375            (SaveSessionTest.testSingleLayer)
376            (SaveSessionTest.testLayerProjection)
377            (SaveSessionTest.testRasterLayer)
378            (SaveSessionTest.testClassifiedLayer)
379            (SaveSessionTest.test_dbf_table)
380            (SaveSessionTest.test_joined_table): Update for new DTD
381            (SaveSessionTest.test_joined_table): Add test for new join type
382            attribute
383    
384    2003-07-04  Bernhard Herzog  <[email protected]>
385    
386            * Thuban/Model/table.py (_find_dbf_column_names): New. Helper
387            function for table_to_dbf
388            (table_to_dbf): Deal with names longer than the 10 character limit
389    
390            * test/test_dbf_table.py (TestTableToDBF.test_table_to_dbf): Add
391            doc-string
392            (TestTableToDBF.test_table_to_dbf_long_col_names): New test for
393            long column names
394    
395    2003-07-03  Bernhard Herzog  <[email protected]>
396    
397            * Doc/manual/thuban-manual.xml: Fix the CVS Revision Tag syntax
398    
399    2003-07-03  Bernhard Herzog  <[email protected]>
400    
401            * Doc/manual/thuban-manual.xml, Doc/manual/README: New. Skeleton
402            for the Thuban manual and README with some basic information about
403            the manual
404    
405    2003-07-03  Bernhard Herzog  <[email protected]>
406    
407            * Thuban/Model/transientdb.py (TransientJoinedTable.__init__):
408            Update doc-string
409            (TransientJoinedTable.create): Do not modify the column objects of
410            the input tables in place and copy all columns of the input tables
411            into the joined table after all.
412    
413            * test/test_transientdb.py
414            (TestTransientTable.test_transient_joined_table_same_column_name):
415            Update to reflect the new behavior
416            (TestTransientTable.test_transient_joined_table_with_equal_column_names):
417            Update to reflect the new behavior
418            (TestTransientTable.test_transient_joined_table_name_collisions_dont_modify_in_place):
419            New test case for a bug which modified the column objects in place
420    
421    2003-07-02  Jonathan Coles   <[email protected]>
422    
423            * Thuban/Model/classgen.py (generate_singletons,
424            generate_uniform_distribution, generate_quantiles,
425            GenQuantiles0): Make sure maxValue isn't less than
426            one, otherwise we could divide by zero.
427    
428            * test/test_classgen.py (ClassGenTest.doClassRangeTest,
429            ClassGenTest.doClassSingleTest): Call doBoundsTest to
430            check the end classification groups against the
431            proper property values.
432            (ClassGenTest.doBoundsTest): New. Checks the first and
433            last classification groups to make sure their properties
434            are the correct upper and lower bounds for a color ramp.
435    
436    2003-07-02  Jonathan Coles   <[email protected]>
437    
438            * Thuban/Model/classgen.py (generate_singletons,
439            generate_uniform_distribution, generate_quantiles,
440            GenQuantiles0): The denominator was one to high when
441            calculating the index for the ramp causing the index
442            to never to reach one.
443    
444    2003-07-02  Jonathan Coles   <[email protected]>
445    
446            Changed the singature of ClassGroupRange.__init__ and
447            ClassGroupRange.SetRange() so that the min/max values are
448            passed as a tuple. This makes a better calling scheme for
449            when a Range object is passed instead.
450    
451            * Thuban/Model/classgen.py: Fixed parameters to
452            ClassGroupRange constructor.
453    
454            * Thuban/Model/classification.py (ClassGroupRange.__init__):
455            Consolidate the min/max parameters into a single _range which
456            can either be a tuple or a Range object.
457            (ClassGroupRange.SetRange): Consolidate the min/max parameters
458            into a single _range which can either be a tuple or a Range object.
459    
460            * Thuban/Model/load.py (SessionLoader.start_clrange): Fix
461            call to ClassGroupRange constructor to use a tuple.
462    
463            * Thuban/Model/layer.py (Layer.SetClassification): Switch
464            the classification instance variable to the new class
465            before calling _set_layer otherwise subscribers to a
466            LAYER_CHANGED event will not see any difference.
467    
468            * test/test_classification.py: Fix tests of ClassGroupRange
469            so that they use the new signature.
470    
471            * test/test_load.py: Fix use of ClassGroupRange so that it
472            uses the new signature.
473    
474            * test/test_load_0_2.py: Fix use of ClassGroupRange so that it
475            uses the new signature.
476    
477            * test/test_save.py: Fix use of ClassGroupRange so that it
478            uses the new signature.
479    
480    
481    2003-07-01  Jonathan Coles   <[email protected]>
482    
483            * Thuban/Model/classgen.py: Fixes RTbug #1972, 1971.
484            Import used objects/class from color.
485            (generate_singletons): We don't
486            need the numGroups parameter anymore because we are using
487            the new ramps with GetProperties().
488            (generate_uniform_distribution): Use new ramp method
489            GetProperties().
490            (generate_quantiles, GenQuantiles0): Use new ramp method
491            GetProperties().
492            (CustomRamp.SetNumGroups): Removed. The ramps now map
493            a value from 0 to 1 to class properties so the number
494            of groups is not needed ahead of time.
495            (CustomRamp.next): Removed. CustomRamp does not support
496            interation anymore.
497            (CustomRamp.GetProperties): Returns a ClassGroupProperties
498            object based on the index value from 0 to 1 that is
499            passed to it.
500            (GreyRamp, RedRamp, GreenRamp, BlueRamp, GreenToRedRamp):
501            Made into instances of Monochromatic class instread of
502            deriving from it.
503            (HotToCold.SetNumGroups): Removed. See CustomRamp.
504            (HotToCold.next): Removed. See CustomRamp.
505    
506            * Thuban/Model/classification.py: Fixes RTbug #1973, 1971.
507            (Classification.SetField, Classification.SetFieldType):
508            Replaced with SetFieldInfo.
509            (Classification.SetFieldInfo): New. Does a better job of
510            what SetField and SetFieldType used to do by combining
511            their function since they should really always be done
512            at the same time.
513            (Classification.SetLayer): Renamed to _set_layer.
514            (Classification._set_layer): Should only be called from
515            Layer's SetClassification. This does not cause a recursive
516            call as SetLayer did because we know that Layer knows about
517            the classification.
518    
519            * Thuban/Model/color.py: Fixes RTbug #1971.
520            (_Transparent): Renamed from Transparent so it doesn't
521            conflict with the module variable.
522            (Transparent, Black): Renamed from Color.Transparent,
523            Color.Black so they are not class variables.
524    
525            * Thuban/Model/layer.py: Fixes RTbug #1971, 1973.
526            (Layer.Destroy): We don't need to call SetClassification
527            anymore to clear out the back reference in the classifcation
528            to the layer. It's better to set it to None using _set_layer,
529            and we won't be creating another clas object too.
530            (Layer.SetClassification): Classification._set_layer is not
531            recursive so remove all the locking variables. Also clean
532            up the code so that it remains unchanged if something fails.
533    
534            * Thuban/Model/load.py: Fixes RTbug #1971.
535            (SessionLoader.start_classification): Call
536            Classification.SetFieldInfo().
537    
538            * Thuban/Model/save.py: Removed import of Color which wasn't
539            being used.
540    
541            * Thuban/UI/classgen.py: Fixes RTbug #1972.
542            (ClassGenDialog.__init__): Color ramps are now instances
543            already so we don't need to create any new objects.
544            (ClassGenDialog.OnOK): Check for numGroups is no longer
545            necessary because we never use it.
546    
547            * Thuban/UI/classifier.py: Fixes RTbug #1971.
548            (Classifier.__BuildClassification, Classifier.__SetGridTable):
549            Call Classification.SetFieldInfo() instead of SetFieldType.
550    
551            * Thuban/UI/renderer.py: Fixes RTbug #1971.
552    
553            * Thuban/UI/view.py: Fixes RTbug #1974, 1971.
554            (MapCanvas.__init__): Subscribe to the idle time event. Set
555            background color to white.
556            (MapCanvas.OnPaint): Set a flag indicating that we should
557            render the map during idle time. If we already have a bitmap
558            just draw it now.
559            (MapCanvas.OnIdle): New. Render the map only during idle time.
560            This also fixes a problem with the busy cursor under gtk.
561    
562            * test/test_classgen.py (ClassGenTest.test_generate_singletons):
563            Fix calls to generate_singletons because the signature changed.
564    
565            * test/test_classification.py: Fix color references and
566            change calls to Classification.[SetField|SetFieldType] to
567            SetFieldInfo.
568    
569            * test/test_load.py: Fix color references.
570    
571            * test/test_load_0_2.py: Fix color references.
572    
573            * test/test_save.py (SaveSessionTest.testClassifiedLayer):
574            Change calls to Classification.[SetField|SetFieldType] to
575            SetFieldInfo.
576    
577    2003-07-01  Frank Koormann   <[email protected]>
578    
579            MERGE from the greater-ms3 branch.
580    
581            * test/test_transientdb.py
582            (TestTransientTable.test_transient_joined_table_with_equal_column_names):
583            New. Test join of two tables with partly equal column names.
584    
585            * Thuban/Model/transientdb.py (TransientJoinedTable.create):
586            If duplicates in left and right tables column names are found,
587            append '_' (underscores) to the name until it is unique.
588            Create always new internal names for the resulting table and reference
589            columns in the join statement with <table>.<column>
590    
591    2003-07-01  Bernhard Herzog  <[email protected]>
592    
593            * test/test_transientdb.py
594            (TestTransientTable.test_transient_joined_table_same_column_name):
595            New. Test whether joining on columns with the same names in both
596            tables works.
597            
598            * Thuban/Model/transientdb.py (TransientJoinedTable.create): Make
599            sure to use the right internal names even when joining on field
600            with the same names in both tables. Also, detect duplicate names
601            in the joined table correctly.
602    
603    2003-07-01  Frank Koormann   <[email protected]>
604    
605            * Thuban/UI/renderer.py (ExportRenderer.render_legend):
606            Reverse List of layers to render in same order as in desktop legend.
607    
608    2003-06-30  Jonathan Coles   <[email protected]>
609    
610            * Thuban/version.py (make_tuple): Takes a version string
611            and splits it into a tuple of at most three integers.
612            Used make_tuple() to make tuple versions of the version
613            numbers.
614    
615            * Thuban/UI/about.py: Add Thuban email addresses.
616    
617    2003-06-30  Jonathan Coles   <[email protected]>
618    
619            * Thuban/version.py: SQLite/PySQLite version dependencies
620            were too high.
621    
622    2003-06-30  Jonathan Coles   <[email protected]>
623    
624            * Thuban/version.py: Update version to 0.8.1
625            
626            * MANIFEST.in: Added Projections so that default.proj is
627            included.
628    
629    2003-06-26  Jonathan Coles   <[email protected]>
630    
631            New About box with lots more information including library
632            versions and credits. More/better version checking before
633            Thuban starts.
634    
635            * Thuban/UI/about.py: New. New About box that displays
636            library version information and credits.
637    
638            * Thuban/version.py: Added new 'versions' dictionary which
639            contains the verions of various libraries which are checked
640            when the module loads.
641            (verify_versions): Check all version numbers and returns
642            a list of errors.
643    
644            * Thuban/UI/classifier.py (Classifier.__EnableButtons):
645            Reset the status of the buttons as the situation warrants,
646            but in a better more reliable way by not relying on the
647            current status to determine what needs to change.
648    
649            * Thuban/UI/main.py (wxCHECK_VERSION): Removed. Not needed.
650            (verify_versions): Remove most of the code since it is
651            now in Thuban.version.verify_versions.o
652    
653            * Thuban/UI/mainwindow.py (MainWindow.About): Call new
654            About box in Thuban.UI.about.
655    
656            * extensions/thuban/gdalwarp.cpp (get_gdal_version): New.
657            Returns the version of gdal library being used as a string.
658    
659            * extensions/thuban/wxproj.cpp (check_version, check_version_gtk):
660            Removed.
661            (get_proj_version): Return the version of PROJ that the file
662            was compiled with.
663            (get_gtk_version): Return th version of GTK that the file
664            was compiled with.
665    
666    2003-06-25  Jonathan Coles   <[email protected]>
667    
668            * Thuban/UI/classifier.py (Classifier.EditSymbol): The parent
669            of the SelectPropertiesDialog should be self so the window
670            appears on top.
671            (ClassGroupPropertiesCtrl.DoEdit): The parent
672            of the SelectPropertiesDialog should be self so the window
673            appears on top.
674    
675            * Thuban/UI/resource.py: Cleaned up how we determine file
676            extensions.
677            (GetImageResource): Return an wxImage from our Resources.
678    
679    2003-06-24  Jonathan Coles   <[email protected]>
680    
681            * Thuban/UI/renderer.py (ExportRenderer.render_legend):
682            Check that a layer has a classification before trying
683            to get it. Raster layers don't have classifications.
684    
685    2003-06-23  Jonathan Coles   <[email protected]>
686            
687            * setup.py: Add Resources/XML to resource list.
688        
689    2003-06-23  Jonathan Coles   <[email protected]>
690    
691            * setup.cfg: Fix copyright dates
692        
693    2003-06-23  Jonathan Coles   <[email protected]>
694    
695            * MANIFEST.in: Update with Resources/XML
696    
697            * setup.py: Don't include Locale resources yet as we don't
698            have any and it causes problems building the distribution
699            for Windows. Update version to 0.8.0.
700    
701            * Doc/thuban.dtd: Removed since it is now in Resources/XML.
702    
703            * Thuban/UI/mainwindow.py: Add blank line at the end because
704            file was not being read correctly building the Windows
705            distribution.
706    
707    2003-06-23  Jonathan Coles   <[email protected]>
708    
709            * Thuban/UI/mainwindow.py (MainWindow.About): Fix text.
710    
711            * Thuban/version.py: Temporarily update longversion for
712            the 0.8 release so that it doesn't have the cvs revision.
713    
714    2003-06-23  Jonathan Coles   <[email protected]>
715    
716            * Thuban/UI/common.py (ThubanBeginBusyCursor): Call wxSafeYield
717            to make sure that we don't create reentrant possibilities with
718            wxYield.
719    
720            * Thuban/UI/view.py (MapCanvas.OnPaint): Call wxBeginBusyCursor()
721            directly to avoid the wxSafeYield() call which generates an
722            OnPaint event causing infinite recursion. Don't try to catch
723            exception anymore. This was for before there were limits on map
724            scaling.
725    
726    2003-06-23  Bernhard Herzog  <[email protected]>
727    
728            Bug fix for RT #1961:
729    
730            * Thuban/Model/load.py (SessionLoader.start_derivedshapesource):
731            Register DerivedShapestores with the session
732    
733            * Thuban/Model/session.py (Session.Tables): Make sure each table
734            is only listed once.
735    
736            * test/test_load.py (TestJoinedTable.test): Add check_format call.
737            Update file contents to match the one written out.
738    
739    2003-06-20  Bernhard Herzog  <[email protected]>
740    
741            * test/xmlsupport.py (SaxEventLister.startElementNS)
742            (SaxEventLister.endElementNS): Do not include the qname. Python
743            2.2.1 and 2.2.2 and 2.2.3 differ in this regard. In 2.2.1 qname it
744            is (presumably incorrectly) None, whereas it's a string with the
745            element name in the later versions.
746    
747            * test/test_xmlsupport.py (TestEventList.test_even_list_simple)
748            (TestEventList.test_even_list_namespace): Update tests to reflect
749            the new behaviour
750            (TestEventList.test_even_list_id_normalization): Fix doc-string
751    
752    2003-06-20  Jonathan Coles   <[email protected]>
753    
754            * Thuban/Model/layer.py (BaseLayer.HasShapes): New. Overridden
755            by deriving classes to determine if that layer supports shapes.
756            (Layer): Override HasShapes and return true.
757    
758            * Thuban/UI/classgen.py: Use Thuban[Begin|End]BusyCursor()
759            instead of a direct call to wx[Begin|End]CusyCursor().
760            (GenUniquePanel._OnRetrieve): Set busy cursor while retrieving
761            table data.
762    
763            * Thuban/UI/common.py (ThubanBeginBusyCursor, ThubanEndBusyCursor):
764            New. Wrappers around the wxWindows functions that allow us to
765            make additional calls such as wxYield which gives the native
766            system a chance to update the cursor correctly.
767    
768            * Thuban/UI/tableview.py: Use Thuban[Begin|End]BusyCursor()
769            instead of a direct call to wx[Begin|End]CusyCursor().
770    
771            * Thuban/UI/view.py: Use Thuban[Begin|End]BusyCursor()
772            instead of a direct call to wx[Begin|End]CusyCursor().
773            (MapCanvas.find_shape_at): Check if the current search layer
774            support shapes, otherwise go on to the next layer.
775    
776            * test/test_layer.py: Add tests in each type of layer for
777            HasClassification() and HasShapes()
778    
779    2003-06-20  Jonathan Coles   <[email protected]>
780    
781            * Thuban/UI/view.py (MapCanvas.OnPaint): Call wxYield after
782            turning on the busy cursor to allow the system to change the
783            cursor before we begin painting. This fixes a problem that
784            was occuring only under GTK. Fixes RTbug #1840.
785    
786    2003-06-20  Bernhard Herzog  <[email protected]>
787    
788            * Resources/XML/thuban-0.8.dtd: New DTD for the new file format
789            version.
790    
791            * Thuban/Model/save.py (sort_data_stores): New. Make topological
792            sort of the data sources so they can be written with sources that
793            data sources that depend on other data sources come after the
794            sources they depend on.
795            (SessionSaver.__init__): Add idmap instance variable to map from
796            objects to the ids used in the file.
797            (SessionSaver.get_id, SessionSaver.define_id)
798            (SessionSaver.has_id): New. Methods to manage the idmap
799            (SessionSaver.write): Use thuban-0.8.dtd
800            (SessionSaver.write_session): Add a namespace on the session and
801            write out the data sources before the maps.
802            (SessionSaver.write_data_containers): New. Write the data
803            containers.
804            (SessionSaver.write_layer): Layer elements now refer to a
805            shapestore and don't contain filenames anymore.
806    
807            * Thuban/Model/load.py (LoadError): Exception class to raise when
808            errors in the files are discovered
809            (SessionLoader.__init__): Define dispatchers for elements with a
810            thuban-0.8 namespace too.
811            (SessionLoader.check_attrs): New helper method to check and
812            convert attributes
813            (AttrDesc): New. Helper class for SessionLoader.check_attrs
814            (SessionLoader.start_fileshapesource)
815            (SessionLoader.start_derivedshapesource)
816            (SessionLoader.start_filetable, SessionLoader.start_jointable):
817            Handlers for the new elements in the new fileformat
818            (SessionLoader.start_layer): Handle the shapestore attribute in
819            addition to filename.
820            (SessionLoader.start_table, SessionLoader.end_table): Removed.
821            They were never used in the old formats and aren't needed for the
822            new.
823    
824            * Thuban/Model/session.py (Session.DataContainers): New method to
825            return all "data containers", i.e. shapestores and tables
826    
827            * test/xmlsupport.py (SaxEventLister.__init__)
828            (SaxEventLister.startElementNS, sax_eventlist): Add support to
829            normalize IDs.
830    
831            * test/test_xmlsupport.py
832            (TestEventList.test_even_list_id_normalization): New test case for
833            id normalization
834    
835            * test/test_load.py (LoadSessionTest.check_format): Use ID
836            normalization
837            (LoadSessionTest.thubanids, LoadSessionTest.thubanidrefs): New
838            class atrributes used for ID normalization
839            (TestSingleLayer, TestLayerVisibility, TestLabels.test)
840            (TestLayerProjection.test, TestRasterLayer.test): Adapt to new
841            file format
842            (TestJoinedTable): New test for loading sessions with joined
843            tables.
844            (TestLoadError): New. Test whether missing required attributes
845            cause a LoadError.
846    
847            * test/test_save.py (SaveSessionTest.thubanids)
848            (SaveSessionTest.thubanidrefs): New class attributes for ID
849            normalization in .thuban files.
850            (SaveSessionTest.compare_xml): Use id-normalization.
851            (SaveSessionTest.testEmptySession)
852            (SaveSessionTest.testLayerProjection)
853            (SaveSessionTest.testRasterLayer)
854            (SaveSessionTest.testClassifiedLayer): Adapt to new file format.
855            (SaveSessionTest.testLayerProjection): The filename used was the
856            same as for testSingleLayer. Use a different one.
857            (SaveSessionTest.test_dbf_table)
858            (SaveSessionTest.test_joined_table): New test cases for saving the
859            new data sources structures.
860            (TestStoreSort, MockDataStore): Classes to test the sorting of the
861            data stores for writing.
862    
863            * test/runtests.py: Add CVS keywords
864    
865    2003-06-20  Jonathan Coles   <[email protected]>
866    
867            * test/test_session.py
868            (UnreferencedTablesTests.test_unreferenced_tables_with_joins):
869            Use the cultural_landmark-point.dbf file for the store so that
870            the table rows and shape count match.
871    
872    2003-06-20  Jonathan Coles   <[email protected]>
873    
874            * Thuban/Model/data.py (DerivedShapeStore.__init__): Raise
875            an exception if the number of shapes is different from the
876            number of rows in the table. Address RTbug #1933.
877    
878            * test/test_layer.py (TestLayer.test_derived_store): Add
879            a test for the new exception in DerivedShapeStore.__init__.
880    
881            * test/support.py (FloatTestCase): Removed since there is
882            already FloatComparisonMixin. Fixes RTbug #1954.
883            (FloatComparisonMixin.assertFloatEqual): Include test for
884            infinity that was part of FloatTestCase.
885    
886            * test/test_range.py (RangeTest): Inherit from
887            support.FloatComparisonMixin now that we don't have
888            support.FloatTestCase.
889    
890    2003-06-20  Bernhard Herzog  <[email protected]>
891    
892            * test/test_save.py (SaxEventLister, sax_eventlist): Removed. Use
893            the implementation in xmlsupport instead.
894            (SaveSessionTest.compare_xml): sax_eventlist is now in xmlsupport
895    
896            * test/test_proj.py: Import sax_eventlist from xmlsupport instead
897            of test_save
898    
899    2003-06-20  Bernhard Herzog  <[email protected]>
900    
901            * test/test_load.py (LoadSessionTest.check_format): New helper
902            method to make sure the test files we load might have been written
903            by the current thuban version.
904            (ClassificationTest.TestLayers, TestSingleLayer.test)
905            (TestLayerVisibility.test, TestClassification.test)
906            (TestLabels.test, TestLayerProjection.test, TestRasterLayer.test):
907            Add check_format() calls and fix the thuban data to match the data
908            that would be written by saving the session loaded from it.
909    
910            * test/xmlsupport.py (SaxEventLister, sax_eventlist): Copies of
911            the same class and function in test_save.
912    
913            * test/test_xmlsupport.py (TestEventList): New. test cases for
914            sax_eventlist
915    
916    2003-06-20  Bernhard Herzog  <[email protected]>
917    
918            * Resources/XML/thuban.dtd: Add comment about which versions of
919            Thuban are covered by this DTD
920            (map): Fix content model for layers and raster layers. There can
921            be any number or layers and raster layers in any order.
922    
923    2003-06-20  Jonathan Coles   <[email protected]>
924    
925            This is mainly about fixing RTbug #1949.
926    
927            * Thuban/Model/classification.py: Remove "from __future__"
928            import statement since python 2.2 is the earliest supported
929            version.
930    
931            * Thuban/Model/proj.py (Projection.GetProjectedUnits): New.
932            Currently returns PROJ_UNITS_METERS or PROJ_UNITS_DEGREES
933            depending on the units this projection *forwards* into.
934    
935            * Thuban/Model/save.py (SessionSaver.write_classification):
936            Remove unnecessary use of lambdas and nested functions.
937    
938            * Thuban/UI/legend.py (ScaleBarBitmap.__SetScale): Do scale
939            adjustment here if the map projection uses degrees.
940    
941            * Thuban/UI/scalebar.py (ScaleBar.DrawScaleBar): Remove
942            scale adjust code since it is now done before calling
943            this method. Don't do anything if the map projection
944            is None.
945    
946    2003-06-19  Bernhard Herzog  <[email protected]>
947    
948            Move version specific load tests to their own file.
949    
950            * test/test_load.py: Expand the doc-string to explain a bit how to
951            handle file format changes.
952            (TestClassification.test): Update the docstring as this test is
953            not about Thuban 0.2 anymore.
954    
955            * test/test_load_0_2.py: New file with the load tests for thuban
956            files created with Thuban 0.2 and earlier.
957    
958    2003-06-19  Bernhard Herzog  <[email protected]>
959    
960            Add XML validation to some of the tests. Validation will only be
961            done if pyRXP is installed (http://reportlab.com/xml/pyrxp.html).
962            To make the DTD available to the test cases it's moved into
963            Resources/XML
964    
965            * Resources/XML/thuban.dtd: New. This is now the real Thuban DTD
966            for versions up to and including 0.2. Two slight changes: added an
967            encoding specification and fixed the comment which refered to
968            GRASS, not Thuban
969    
970            * test/xmlsupport.py: New support module for tests involving XML.
971            Currently there's a mix-in class for XML validation.
972    
973            * test/test_xmlsupport.py: New. Tests for the xmlsupport module
974    
975            * test/test_save.py (SaveSessionTest): Derive from ValidationTest
976            so that we can validate the
977            (SaveSessionTest.testEmptySession)
978            (SaveSessionTest.testSingleLayer)
979            (SaveSessionTest.testSingleLayer)
980            (SaveSessionTest.testLayerProjection)
981            (SaveSessionTest.testRasterLayer)
982            (SaveSessionTest.testClassifiedLayer): Validate the generated XML
983    
984            * test/runtests.py (main): Call print_additional_summary instead
985            of print_garbage_information
986    
987            * test/support.py (resource_dir): New function to return the
988            "Resource" subdirectory
989            (print_additional_summary): New function to combine several
990            summary functions
991            (run_tests): Use print_additional_summary instead of calling
992            print_garbage_information directly
993    
994    2003-06-19  Bernhard Herzog  <[email protected]>
995    
996            * Doc/thuban.dtd (classification): Correct the content model of
997            the classification element.
998            (projection): Add the "name" attribute
999    
1000    2003-06-19  Frank Koormann   <[email protected]>
1001    
1002            MERGE from the greater-ms3 branch.
1003    
1004            * Thuban/UI/scalebar.py (ScaleBar.DrawScaleBar): Apply conversion to
1005            scale if projection is latlong to get better estimate.
1006    
1007            Fix problem of hidden properties dialog under windows after double
1008            click on layer tree:
1009            The tree control always gets an Expanded / Collapsed event after
1010            the ItemActivated  on double click, which raises the main window again.         We add a second ItemActivated event to the queue, which simply
1011            raises the already displayed window.
1012    
1013            * Thuban/UI/legend.py (LegendTree.__init__): Instance variable
1014            raiseProperties initialized to prevent endless loops
1015            (LegendTree._OnItemActivated): Depending on self.raiseProperties
1016            simply raise the properties or open the dialog and issue a second
1017            event.
1018    
1019    2003-06-18  Jonathan Coles   <[email protected]>
1020    
1021            * setup.py: Fix a few problems that occured under Windows.
1022    
1023    2003-06-18  Jonathan Coles   <[email protected]>
1024    
1025            When Thuban loaded the map was redrawn twice because the
1026            legend was being opened after the mainwindow was created
1027            and not during its creation. This meant the map was drawn
1028            initially and then had to be redrawn when the legend
1029            caused the display to change. Now the legend is opened
1030            in the mainwindow constructor which resolves this issue.
1031    
1032            Also, although we were checking for the existence of
1033            gdal and gdalwarp modules, the gdalwarp extension was
1034            still being compiled (which may fail if the system doesn't
1035            have gdal installed). the build_ext command to setup.py
1036            now accepts the flags --with-gdal and --without-gdal.
1037            If --without-gdal is specified setup.py will try to
1038            use the gdal parameters specified by gdal-config. Under
1039            windows, those parameters have to be set in setup.py
1040            as with proj4 an wxWindows.
1041    
1042            * setup.py: Use a list instead of seperate variables for
1043            extension parameters so we can create a generic function
1044            that runs an appropriate *-config script.
1045            (run_cs_script): Renamed from run_wx_script and modified
1046            to accept a second argument which is a list of lists to
1047            be filled in by the values returned from running the command.
1048            (thuban_build_ext): New. Extends the build_ext command and
1049            provides the options --with-gdal/--without-gdal which then
1050            optionally includes the gdalwarp extension.
1051    
1052            * Thuban/Model/resource.py: First check if we can import
1053            the gdalwarp Thuban extension before checking for gdal.
1054            Also added some comments.
1055            
1056            * Thuban/UI/legend.py (ScaleBarBitmap.__SetScale): Check if
1057            the map is None which may be the case if none has been loaded
1058            yet.
1059    
1060            * Thuban/UI/main.py (main): Remove call to ShowLegend.
1061    
1062            * Thuban/UI/mainwindow.py (MainWindow.__init__): Call ShowLegend().
1063    
1064            * Thuban/UI/renderer.py: Check for gdal support before importing
1065            gdalwarp.
1066            (MapRenderer.render_map): Only try to optimize if we have gdal
1067            support otherwise nothing will get drawn.
1068    
1069            * Thuban/UI/view.py (MapCanvas.FitMapToWindow): This may be called
1070            during startup before a map has been created. Check if map is None
1071            before using it and do nothing if it is.
1072    
1073    2003-06-17  Jonathan Coles   <[email protected]>
1074    
1075            Fix the problem with raster layers under Windows that caused
1076            Thuban to crash. The view should respond to layer projection
1077            changed events to update the display. Changes to a projection
1078            should not cause the map to be set to full extent.
1079            
1080            * Thuban/UI/view.py (MapCanvas.__init__): New instance variable
1081            current_map_proj to remember the current map projection so that
1082            when the projection changes we know what the previous projection
1083            was.
1084            (MapCanvas.SetMap): Unsubscribe and subscribe to
1085            LAYER_PROJECTION_CHANGED events.
1086            (MapCanvas.projection_changed): Split into two methods that respond
1087            to map and layer projection changes.
1088            (MapCanvas.map_projection_changed): New. Takes the current view and
1089            projects it using the new projection. This does not cause the
1090            map to be redrawn at full extent.
1091            (MapCanvas.layer_projection_changed): New. Cause a redraw which
1092            will draw each layer in its new projection.
1093            
1094            * extensions/thuban/bmpdataset.cpp (BMPDataset::Open): Call
1095            VSIFClose() not VSIFCloseL() to close the file. Fixes a crash
1096            under Windows.
1097            
1098            * extensions/thuban/gdalwarp.cpp (MFILENAME): Padding should be
1099            to twice sizeof(void*) because there are two digits for each
1100            hex byte.
1101    
1102    2003-06-16  Bernhard Herzog  <[email protected]>
1103    
1104            Update to the layer interface: Direct access to the table,
1105            shapetable, shapefile and filename attributes is now actively
1106            deprecated by issuing deprecation warnings for all places where
1107            this happens.
1108    
1109            * Thuban/Model/layer.py (Layer.__getattr__): New. Implement access
1110            to the instance variables table, shapetable, shapefile and
1111            filename via __getattr__ so that we can issue a deprecation
1112            warning.
1113            (Layer.SetShapeStore): Don't set the deprecated instance variables
1114            any more
1115            (Layer.SetShapeStore): Don't use deprecated layer instance
1116            variables
1117            (Layer.Destroy): No need to explicitly remove the instance
1118            variables any more
1119            (Layer.GetFieldType, Layer.Shape): Don't use deprecated layer
1120            instance variables
1121    
1122            * Thuban/UI/classgen.py (ClassGenDialog.__init__)
1123            (GenUniformPanel._OnRetrieve, GenUniquePanel._OnRetrieve)
1124            (GenQuantilesPanel.GetList, GenQuantilesPanel.OnRetrieve): Don't
1125            use deprecated layer instance variables
1126    
1127            * Thuban/UI/classifier.py (Classifier.__init__): Don't use
1128            deprecated layer instance variables
1129    
1130            * Thuban/UI/identifyview.py (IdentifyListCtrl.selected_shape)
1131            (IdentifyGridCtrl.selected_shape): Don't set the deprecated layer
1132            instance variables
1133    
1134            * Thuban/UI/tableview.py (LayerTableGrid.select_shapes): Don't use
1135            deprecated layer instance variables
1136    
1137            * Thuban/UI/mainwindow.py (MainWindow.LayerShowTable): Don't use
1138            deprecated layer instance variables
1139    
1140            * Thuban/Model/save.py (SessionSaver.write_layer): Don't use
1141            deprecated layer instance variables
1142    
1143            * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer)
1144            (MapRenderer.polygon_render_param): Don't use deprecated layer instance
1145            variables
1146    
1147            * test/runtests.py (main): Turn Thuban's deprecation warnings into
1148            errors so that they're cought by the tests
1149    
1150            * test/test_load.py (TestSingleLayer.test): Don't use deprecated
1151            layer instance variables
1152    
1153    2003-06-16  Jonathan Coles   <[email protected]>
1154    
1155            Fix a problem under Windows whereby if the user double-clicks on a
1156            layer in the legend that tree item will expand or collapse as well
1157            as open the layer properties dialog. The state of the tree item
1158            should not be affected.
1159    
1160            * Thuban/UI/legend.py (LegendTree.__init__): Add instance variable
1161            preventExpandCollapse and subscribe to expanding and collapsing
1162            events.
1163            (LegendTree.OnItemExpandCollapse): New. Responds to expanding and
1164            collapsing events and will veto the event if it has been triggered
1165            by the user double clicking on a layer.
1166            (LegendTree._OnItemActivated): Set preventExpandCollapse to indicate
1167            that an expanding/collapsing event should be vetoed.
1168    
1169    2003-06-13  Bernhard Herzog  <[email protected]>
1170    
1171            * Thuban/UI/classifier.py (Classifier.OnClose)
1172            (Classifier.map_layers_removed)
1173            (Classifier.layer_shapestore_replaced): Unsubscribe the messages
1174            in OnClose and not in map_layers_removed or
1175            layer_shapestore_replaced to make sure it always happens when the
1176            dialog is closed
1177    
1178    2003-06-13  Jonathan Coles   <[email protected]>
1179    
1180            This puts back a fix for Windows where a panel is needed so that
1181            the background of the table view appears correctly.
1182    
1183            * Thuban/UI/tableview.py (TableFrame.__init__): Add a panel
1184            object that can be used by derived classes to place any
1185            controls (including the grid) onto.
1186            (QueryTableFrame.__init__): Use the panel as the parent window
1187            for all the controls. Reparent the grid so that the panel is
1188            the parent. Call UpdateStatusText() to correctly initialize
1189            the status bar.
1190    
1191    2003-06-13  Jonathan Coles   <[email protected]>
1192    
1193            * Thuban/UI/dialogs.py (ThubanFrame): New: a class that inherits
1194            from wxFrame (as opposed to wxDialog like the other classes)
1195            but otherwise behaves like the other classes. This is needed
1196            for the TableView which isn't really a dialog and needs to
1197            have a status bar and control buttons.
1198    
1199            * Thuban/UI/tableview.py (TableGrid.__init__): Create an
1200            instance variable to keep track of how many rows are selected.
1201            Subscribe once to the the events we are interested in.
1202            (ThubanGrid.OnRangeSelect): Only handle event if event handling
1203            hasn't been turned off.
1204            (ThubanGrid.OnSelectCell): Only handle event if event handling
1205            hasn't been turned off.
1206            (ThubanGrid.ToggleEventListeners): Rather than subscribe None
1207            as an event listener (which changes the event handler stack)
1208            simply set an instance variable to False. This is checked in
1209            the event handlers.
1210            (ThubanGrid.GetNumberSelected): Return the number of currently
1211            selected rows.
1212            (TableFrame): Inherit from ThubanFrame so we can have a
1213            status bar and control buttons.
1214            (QueryTableFrame.__init__): Create a status bar. Fixes RTbug #1942.
1215            Explicitly set which items are selected in the operator choice and
1216            action choice so there is always a valid selection. Fixes RTbug #1941.
1217            Subscribe to grid cell selection events so we can update the
1218            status bar.
1219            (QueryTableFrame.UpdateStatusText): Update the status bar with
1220            how many rows are in the grid, how many columns, and how many
1221            rows are selected.
1222            (QueryTableFrame.OnGridSelectRange, QueryTableFrame.OnGridSelectCell):
1223            Call UpdateStatusText when cells are (de)selected.
1224            (QueryTableFrame.OnQuery): Use the string value in the value
1225            combo if either the selected item index is 0 or if the string
1226            cannot be found in the predefined list (this happens if the
1227            user changes the text). Fixes RTbug #1940.
1228            Only turn off the grid event listeners if there a query comes
1229            back with a none empty list of ids. in the case that the list
1230            is empty this causes a grid.ClearSelection() call to actually
1231            clear the grid selection which causes the selected items in
1232            the map to be deselected. Fixes RTbug #1939.
1233    
1234            * test/test_save.py (XMLWriterTest.Encode): Check return values.
1235            Fixes RTbug #1851.
1236    
1237    2003-06-13  Bernhard Herzog  <[email protected]>
1238    
1239            * Thuban/UI/identifyview.py (IdentifyView.__init__): Call
1240            self.selected_shape with the current selection to make sure the
1241            contents of the dialog are up to date when it's shown for the
1242            first time.
1243            The dialog used to work without this by luck. The recent fix to
1244            the connector module 'broke' a 'feature' the identify view was
1245            relying on, i.e that subscribing to a message in response to
1246            receiving a message of that type would mean that the new
1247            subscriber would also be called for the same message.
1248            
1249    2003-06-12  Jonathan Coles   <[email protected]>
1250    
1251            * extensions/thuban/gdalwarp.cpp: Removed debug printing as
1252            the image is rendered. Fixes RTbug #1937.
1253    
1254    2003-06-12  Jonathan Coles   <[email protected]>
1255    
1256            * Thuban/Lib/fileutil.py: As is done under Windows, create the
1257            user directory if it doesn't exist on a posix system.
1258            Fixes RTbug #1815.
1259    
1260            * Thuban/Model/resource.py (get_user_proj_files): Moved the
1261            called to get_application_dir here, so that the directory
1262            will only be called if this method is invoked.
1263    
1264            * Thuban/UI/projdialog.py (ProjFrame.__DoOnProjAvail): Clear
1265            the projfilepath if no projection is selected.
1266    
1267    2003-06-12  Jonathan Coles   <[email protected]>
1268    
1269            * Thuban/UI/legend.py (ScaleBarBitmap.__SetScale): Don't draw
1270            the scalebar if the current map has no projection set.
1271    
1272            * Thuban/UI/projdialog.py (ProjFrame.__DoOnProjAvail): Set the
1273            projfilepath label to just the basename of the projection file
1274            rather than include the entire path.
1275    
1276            * Thuban/Model/resource.py: Fix missed proj functions that
1277            needed to be renamed.
1278    
1279    2003-06-12  Jonathan Coles   <[email protected]>
1280    
1281            * Thuban/Model/classification.py: Removed assert statements that
1282            tested if the variable was an instance of Color.
1283    
1284            * Thuban/Model/color.py (Color): Remove commented code that isn't
1285            used.
1286            (Transparent): Renamed from NoColor. Doesn't inherit from Color.
1287            Fixes RTbug #1835.
1288            (Transparent.__eq__, Transparent.__ne, Transparent.__repr): New.
1289            Needed now that the class doesn't inherit from Color.
1290    
1291    2003-06-12  Jonathan Coles   <[email protected]>
1292    
1293            * test/test_save.py (XMLWriterTest.testEncode): Explicitly
1294            check unicode strings.
1295    
1296            * test/test_layer.py: Check for existence of gdal.
1297    
1298    2003-06-12  Jonathan Coles   <[email protected]>
1299        
1300            * Thuban/Model/xmlreader.py: New. Contains the XMLReader class
1301            that was in load.py
1302    
1303            * Thuban/Model/xmlwriter.py: New. Contains the XMLWriter class
1304            that was in save.py
1305    
1306    2003-06-12  Jonathan Coles   <[email protected]>
1307    
1308            This is largely a collection of bug fixes. We also handle the
1309            case where gdal is not on the system. The XMLReader and XMLWriter
1310            classes were moved into there own files to resolve some circular
1311            import references and because they shouldn't really be in the
1312            file that is dediciated to reading/writing session files since
1313            they are also used elsewhere.
1314    
1315            * Thuban/Model/classgen.py: Renamed functions to follow the
1316            function_names_with_underscores style. Fixes RTbug #1903.
1317            (calculate_quantiles): Raise ValueError if 'percents' is invalid.
1318    
1319            * Thuban/Model/layer.py: Import gdal only if it available.
1320            (RasterLayer): Handle the case where the gdal library is unavailable.
1321            Addresses RTbug #1877.
1322    
1323            * Thuban/Model/load.py (XMLReader): Moved into seperate file
1324            xmlreader.py.
1325    
1326    2003-06-12  Jonathan Coles   <[email protected]>
1327    
1328            This is largely a collection of bug fixes. We also handle the
1329            case where gdal is not on the system. The XMLReader and XMLWriter
1330            classes were moved into there own files to resolve some circular
1331            import references and because they shouldn't really be in the
1332            file that is dediciated to reading/writing session files since
1333            they are also used elsewhere.
1334    
1335            * Thuban/Model/classgen.py: Renamed functions to follow the
1336            function_names_with_underscores style. Fixes RTbug #1903.
1337            (calculate_quantiles): Raise ValueError if 'percents' is invalid.
1338    
1339            * Thuban/Model/layer.py: Import gdal only if it available.
1340            (RasterLayer): Handle the case where the gdal library is unavailable.
1341            Addresses RTbug #1877.
1342    
1343            * Thuban/Model/load.py (XMLReader): Moved into seperate file
1344            xmlreader.py.
1345    
1346            * Thuban/Model/save.py (escape, XMLWriter): Moved into seperate
1347            file xmlwriter.py.
1348    
1349            * Thuban/Model/resource.py: Renamed functions to following the
1350            function_names_with_underscores style.
1351            (has_gdal_support): New function that returns true if the gdal
1352            library is available. Addresses RTbug #1877.
1353    
1354            * Thuban/UI/application.py (ThubanApplication.OpenSession):
1355            Display a message box if the gdal library is not available, but
1356            only if there are any layers that would use it. Addresses RTbug #1877.
1357    
1358            * Thuban/UI/classgen.py: Use renamed projection resource functions.
1359            (GenUniformPanel.__CalcStepping): Fix a slight discrepency
1360            when using integers versus floats.
1361    
1362            * Thuban/UI/mainwindow.py (_has_gdal_support): New. Used to
1363            determine if the "Add Image Layer" menu option should be
1364            greyed out or not. Addresses RTbug #1877.
1365    
1366            * Thuban/UI/projdialog.py: Use renamed projection resource functions.
1367    
1368            * Thuban/UI/renderer.py (MapRenderer.render_map): Only try to
1369            optimize if a raster layer is visible. Fixes RTbug #1931.
1370            Only draw the raster layer if the gdal library is available.
1371            Addresses RTbug #1877.
1372    
1373            * test/test_classgen.py: Add tests for generate_singletons,
1374            generate_uniform_distribution, generate_quantiles. Fixes RTbug #1903.
1375            (test_calculate_quantiles): Fix some tests to catch the new
1376            ValueError that is raised.
1377    
1378            * test/test_proj.py: Use renamed projection resource functions.
1379    
1380            * test/test_save.py (SaveSessionTest.testClassifiedLayer): New
1381            test for saving classified layers. Fixes RTbug #1902.
1382            (XMLWriterTest): New. Tests the XMLWriter class. Fixes RTbug #1851.
1383    
1384    2003-06-12  Jan-Oliver Wagner <[email protected]>
1385    
1386            Fix for http://intevation.de/rt/webrt?serial_num=1900.
1387    
1388            * Thuban/UI/multiplechoicedialog.py: New. A multiple choice dialog.
1389    
1390            * Thuban/UI/mainwindow.py: import wxMultipleChoiceDialog from
1391            multiplechoicedialog.py rather than from the wxPython library.
1392    
1393    2003-06-11  Frank Koormann  <[email protected]>
1394    
1395            * Thuban/Lib/fileutil.py (get_application_dir): Minor stability
1396            update.
1397    
1398    2003-06-11  Frank Koormann  <[email protected]>
1399    
1400            * Thuban/Lib/fileutil.py (get_application_dir): New function to
1401            determine the absolute .thuban/thuban directory under
1402            "posix" (os.expanduser) and "nt" (read AppData registry key).
1403    
1404            * Thuban/Model/resource.py: Use get_application_dir
1405    
1406            * Thuban/UI/application.py (ThubanApplication.read_startup_files):
1407            Use get_application_dir.
1408    
1409    2003-06-10  Bernhard Herzog  <[email protected]>
1410    
1411            * Thuban/UI/tableview.py (LayerTableFrame.__init__): Subscribe to
1412            the messages MAP_LAYERS_REMOVED messages
1413            (LayerTableFrame.OnClose): Unsubscribe from it.
1414            (LayerTableFrame.map_layers_removed): New. Receiver for
1415            MAP_LAYERS_REMOVED. Close the dialog when the layer whose the
1416            dialog is showing is removed.
1417    
1418    2003-06-10  Bernhard Herzog  <[email protected]>
1419    
1420            * Thuban/Lib/connector.py (Connector.Issue): Iterate over a copy
1421            of the receivers list so that unsubscribing in a receiver doesn't
1422            modify it while iterating over it.
1423    
1424            * test/test_connector.py
1425            (ConnectorTest.test_disconnect_in_receiver): New. Test whether
1426            unsubscribing in a receiver works correctly. See docstring for
1427            details
1428    
1429    2003-06-10  Bernhard Herzog  <[email protected]>
1430    
1431            * Thuban/Model/messages.py (LAYER_SHAPESTORE_REPLACED): New
1432            message.
1433    
1434            * Thuban/Model/layer.py (Layer.SetShapeStore): Send
1435            LAYER_SHAPESTORE_REPLACED when the shapestore changes. A
1436            LAYER_CHANGED will still be sent if the classification changes.
1437    
1438            * Thuban/UI/classifier.py (Classifier.__init__): Add the map as
1439            parameter so we can subscribe to some of its messages
1440            (Classifier.__init__): Subscribe to the map's MAP_LAYERS_REMOVED
1441            and the layer's LAYER_SHAPESTORE_REPLACED
1442            (Classifier.unsubscribe_messages): New. Unsubscribe from message
1443            subscribed to in __init__
1444            (Classifier.map_layers_removed)
1445            (Classifier.layer_shapestore_replaced): receivers for the messages
1446            subscribed to in __init__. Unsubscribe and close the dialog
1447    
1448            * Thuban/UI/mainwindow.py (MainWindow.OpenLayerProperties): Pass
1449            the map to the Classifier dialog
1450    
1451            * test/test_layer.py (SetShapeStoreTests): Derive from
1452            SubscriberMixin as well so we can test messages
1453            (SetShapeStoreTests.setUp): Subscribe to some of the layer's
1454            messages
1455            (SetShapeStoreTests.tearDown): Clear the messages again
1456            (SetShapeStoreTests.test_sanity): Expand the doc-string and check
1457            for the modified flag too
1458            (SetShapeStoreTests.test_set_shape_store_modified_flag): New test
1459            to check whether SetShapeStore sets the modified flag
1460            (SetShapeStoreTests.test_set_shape_store_different_field_name)
1461            (SetShapeStoreTests.test_set_shape_store_same_field)
1462            (SetShapeStoreTests.test_set_shape_store_same_field_different_type):
1463            Add tests for the messages. This checks both the new
1464            LAYER_SHAPESTORE_REPLACED and the older LAYER_CHANGED
1465    
1466    2003-06-06  Jan-Oliver Wagner <[email protected]>
1467    
1468            * Thuban/UI/mainwindow.py: Improved and partly added help texts for
1469            the menu items.
1470    
1471    2003-06-05  Frank Koormann  <[email protected]>
1472    
1473            * Thuban/UI/identifyview.py (IdentifyView.__init__):
1474            Layout reimplemented without panel. Make life easier to fit the list
1475            in the dialog.
1476    
1477    2003-06-05  Frank Koormann  <[email protected]>
1478    
1479            * Thuban/UI/projdialog.py (ProjFrame.__init__): Fill the projchoice
1480            once on initialisation (Former implementation resulted in multiple
1481            entries for each projection).
1482            (ProjFrame.__FillAvailList): selectProj as second optional parameter,
1483            if set, select the projection found under the specified name. This
1484            overwrites any other selection estimate.
1485            Removed projchoice filling from this method.
1486            (ProjFrame._OnSave, ProjFrame._OnAddToList):
1487            Updated call of ProjFrame.__FillAvailList
1488            (LCCPanel._DoLayout): Moved parameter controls in more common order.
1489    
1490            * Resources/Projections/defaults.proj: Extended defaults representing
1491            various common European projections.
1492    
1493    2003-06-05  Frank Koormann  <[email protected]>
1494    
1495            * Thuban/UI/identifyview.py (IdentifyView.__init__):
1496            Use ListCtrl instead of GridCtrl
1497    
1498            * Thuban/Model/resource.py:
1499            Guess location of .thuban directory from tempdir parent directory.
1500    
1501            * Thuban/UI/application.py (ThubanApplication.read_startup_files):
1502            Guess location of .thuban directory from tempdir parent directory.
1503    
1504    2003-06-04  Bernhard Herzog  <[email protected]>
1505    
1506            Do not cache the values returned by the tree widget's
1507            GetFirstChild and GetNextChild methods because it led to lots of
1508            segfaults. The new way requires more brute force but is more
1509            reliable.
1510    
1511            * Thuban/UI/legend.py (LegendTree.__init__): Remove instance
1512            variable layer2id
1513            (LegendTree.find_layer): New method to do with brute force what
1514            layer2id tried to accomplish
1515            (LegendTree._OnMsgLayerChanged)
1516            (LegendTree._OnMsgLayerTitleChanged, LegendTree.__ShowHideLayer):
1517            Use find_layer instead of layer2id
1518            (LegendTree.__RemoveLayer, LegendTree.__AddLayer): No need to
1519            update layer2id anymore
1520            (LegendTree._OnMsgMapLayersRemoved)
1521            (LegendTree._OnMsgMapLayersAdded): Get by without layer2id.
1522    
1523    2003-06-03  Thomas Koester  <[email protected]>
1524    
1525            * Thuban/Model/classgen.py (GenQuantiles0): New function.
1526    
1527    2003-06-02  Bernhard Herzog  <[email protected]>
1528    
1529            * Thuban/UI/mainwindow.py (layer_rename command, table_rename command):
1530            New commands.
1531            (main_menu): Add the new commands.
1532            (MainWindow.TableRename): New. Implementation of the table_rename
1533            command.
1534            (MainWindow.RenameLayer): New. Implementation of the layer_rename
1535            command.
1536    
1537            * Thuban/Model/session.py (Session.AddTable): call self.changed to
1538            set the modified flag
1539    
1540            * test/test_session.py (TestSessionSimple.test_add_table): Test
1541            whether the modified flag is set properly
1542    
1543            * Thuban/Model/base.py (TitledObject.SetTitle): Call changed
1544            instead of issue so that the modified flags get updated.
1545    
1546            * test/test_base.py (SomeTitledObject): Derive from Modifiable
1547            instead of Publisher to reflect reality better and to accomodate
1548            the fact that SetTitle now calls changed instead of issue
1549    
1550    2003-06-02  Bernhard Herzog  <[email protected]>
1551    
1552            * Thuban/UI/classgen.py (GenQuantilesPanel.GetList): Resource
1553            acquisition has to happen before the try in a try-finally.
1554    
1555    2003-06-02  Bernhard Herzog  <[email protected]>
1556    
1557            * Thuban/UI/legend.py (LegendTree._OnMsgMapLayersRemoved): It's
1558            possible that a layer is removed that is not currently selected in
1559            the legend so don't check for this.
1560    
1561    2003-05-30  Bernhard Herzog  <[email protected]>
1562    
1563            * Thuban/Model/layer.py (Layer.Destroy): Set all instance
1564            variables to None that have direct or indirect references to
1565            shapefiles or dbf files to make sure that they do go away and the
1566            files are closed.
1567    
1568    2003-05-30  Bernhard Herzog  <[email protected]>
1569    
1570            * Thuban/UI/legend.py (LegendTree.GetRootItem): Reset
1571            availImgListIndices when a new image list is created
1572            
1573    2003-05-30  Bernhard Herzog  <[email protected]>
1574    
1575            * Thuban/UI/legend.py (LegendTree.__init__): New instance variable
1576            changing_selection to indicate whether the LegendTree code itself
1577            is currently changing the selection
1578            (LegendTree.normalize_selection): New method to normalize the
1579            selection by selecting the layer item even if the user clicked on
1580            the classification.
1581            (LegendTree._OnSelChanged): normalize the selection. This works
1582            around a bug in wx which doesn't keep track of the selection
1583            properly when subtrees are deleted.
1584    
1585    2003-05-30  Bernhard Herzog  <[email protected]>
1586    
1587            * Thuban/UI/view.py (MapCanvas.set_view_transform): Limit the
1588            maximum and minimum scale factors.
1589    
1590            * test/test_classgen.py (ClassGenTest.test): Update to reflect the
1591            changes in classgen.py
1592    
1593    2003-05-30  Jonathan Coles   <[email protected]>
1594    
1595            * Thuban/Model/classgen.py: Remove ClassGenerator class but make
1596            all the methods functions. Fixes RTBug #1903.
1597    
1598            * Thuban/Model/map.py (Map.TopLayer, Map.BottomLayer): Renamed
1599            to MoveLayerToTop and MoveLayerToBottom respectively. Fixes
1600            RTBug #1907.
1601    
1602            * Thuban/UI/classgen.py: Use classgen functions that were part
1603            of the ClassGenerator class. Put try/finally blocks around
1604            code that uses wxBeginBusyCursor()/wxEndBusyCursor(). Fixes
1605            RTBug #1904.
1606    
1607            * Thuban/UI/classifier.py: Remove unused import of ClassGenerator.
1608    
1609            * Thuban/UI/legend.py: The legend was cleared and repopulated any
1610            time something changed which caused some state to be lost such
1611            as which children were expanded or collapsed. Fixes RTBug #1901.
1612            (LegendTree._OnMsgMapLayersAdded): Add only new layers.
1613            (LegendTree.__OnMsgMapLayersRemoved): Remove layers that exist in
1614            the legend but not in the map.
1615            (LegendTree.__FillTree): Move main functionality out into smaller
1616            methods that can be used by other methods.
1617            (LegendTree.__FillTreeLayer): Reuse old slots in the image list
1618            if they are available.
1619            (LegendTree.DeleteAllItems): Renamed from __DeleteAllItems so
1620            that we override the wxTreeCtrl method. Iterate over children
1621            and call __RemoveLayer.
1622            (LegendTree.__AddLayer): New. Add a new layer to the legend.
1623            (LegendTree.__RemoveLayer): Remove a layer from the legend.
1624            (LegendTree.DeleteChildren): New, overrides wxTreeCtrl method.
1625            Should only be called with the id of a layer branch.
1626            (LegendTree.GetRootItem): New, overrides wxTreeCtrl method.
1627            Returns the root item or creates one if necessary.
1628    
1629            * Thuban/UI/renderer.py (MapRenderer.draw_raster_layer): Call
1630            ProjectRasterFile with tuple arguments instead of strings.
1631    
1632            * Thuban/UI/tableview.py (QueryTableFrame.OnQuery): Wrap code
1633            with try/finally. Fixes RTBug #1904.
1634    
1635            * Thuban/UI/view.py (MapCanvas.OnPaint): Wrap code
1636            with try/finally. Fixes RTBug #1904.
1637            (MapCanvas.FitSelectedToWindow): If a single point is selected
1638            simply center it on the display. Fixes RTBug #1849.
1639    
1640            * extensions/thuban/gdalwarp.cpp: Removed code that allowed gdalwarp
1641            to be compiled as a standalone app. Now the code can only be
1642            called from Python which simplifies the parameter passing.
1643            (ProjectRasterFile): Handle Python arguments. Remove code that
1644            checks for a destination dataset. Add more clean up code.
1645    
1646            * test/test_map.py (TestMapWithContents.test_raise_layer_top,
1647            TestMapWithContents.test_lower_layer_bottom):
1648            Test Map.MoveLayerToTop() and Map.MoveLayerToBottom() respectively.
1649            Fixes RTBug #1907.
1650    
1651            * Thuban/UI/mainwindow.py (MainWindow.ToggleLegend): Apply a full
1652            extent to the map when the legend is toggled. Fixes RTBug #1881.
1653    
1654    2003-05-29  Jan-Oliver Wagner <[email protected]>
1655    
1656            * Thuban/UI/tableview.py (LayerTableFrame.OnClose): Bug-fix: Now
1657            unsubscribes all that is subcribed in __init__.
1658    
1659    2003-05-28  Bernhard Herzog  <[email protected]>
1660    
1661            * Thuban/UI/mainwindow.py (MainWindow.DuplicateLayer)
1662            (MainWindow.CanDuplicateLayer): New methods to implement the
1663            Layer/Duplicate command.
1664            (layer_duplicate command): New.
1665            (main_menu): Add layer_duplicate to the Layer menu.
1666    
1667    2003-05-28  Bernhard Herzog  <[email protected]>
1668    
1669            * Thuban/UI/tableview.py (NullRenderer.Draw): New. Our own
1670            renderer so that NULL/None values get displayed differently (by a
1671            gray rectangle).
1672            (TableGrid.__init__): Override the default renderers
1673    
1674    2003-05-28  Bernhard Herzog  <[email protected]>
1675    
1676            * Thuban/Model/layer.py (Layer.SetShapeStore): Set the
1677            classification to "None" if the type of the field has changed.
1678    
1679            * test/test_layer.py (SetShapeStoreTests): New. Class with a few
1680            test for the Layer.SetShapeStore method
1681    
1682    2003-05-28  Jan-Oliver Wagner <[email protected]>
1683    
1684            * Thuban/Model/layer.py (Layer.TreeInfo): Fixed a bug (a layer
1685            does not necessarily have a filename).
1686    
1687    2003-05-28  Jan-Oliver Wagner <[email protected]>
1688    
1689            * Thuban/UI/mainwindow.py (MainWindow.TableClose, MainWindow.TableShow):
1690            sort the selection list for the dialog.
1691    
1692    2003-05-28  Frank Koormann  <[email protected]>
1693    
1694            * extensions/thuban/wxproj.cpp
1695            (project_point): Removed cast to int for projected point coordinates.
1696            (shape_centroid): Return last point if all polygon vertices fall
1697            to one point.
1698    
1699    2003-05-28  Bernhard Herzog  <[email protected]>
1700    
1701            * Thuban/UI/mainwindow.py (_can_unjoin): Add doc-string and cope
1702            with layers that don't have shapestores, i.e. raster layers.
1703    
1704    2003-05-28  Bernhard Herzog  <[email protected]>
1705    
1706            * Thuban/Model/table.py (DBFTable.__init__): Omit the extension
1707            when determining the title from the filename.
1708    
1709            * test/test_dbf_table.py (TestDBFTable.test_title): Update to
1710            reflect changes in the way the title is derived from the filename
1711    
1712    2003-05-28  Frank Koormann  <[email protected]>
1713    
1714            * Thuban/UI/mainwindow.py (MainWindow.TableShow):
1715            Added wxDEFAULT_DIALOG_STYLE to show table dialog styles.
1716    
1717    2003-05-27  Bernhard Herzog  <[email protected]>
1718    
1719            * Thuban/UI/mainwindow.py (MainWindow.delegated_messages): Also
1720            delegate SelectedLayer.
1721            (MainWindow.LayerUnjoinTable): Implement.
1722            (_can_unjoin): New. Helper function for the sensitivity of the
1723            layer/unjoin command.
1724    
1725            * Thuban/Model/data.py (ShapefileStore.OrigShapeStore)
1726            (DerivedShapeStore.OrigShapeStore): New. Return the original
1727            shapestore. Used to figure out how to unjoin.
1728            (DerivedShapeStore.Shapefile): Fix a typo.
1729    
1730    2003-05-27  Bernhard Herzog  <[email protected]>
1731    
1732            * Thuban/UI/join.py (JoinDialog): Extend to handle layer joins as
1733            well
1734            (JoinDialog.__init__): Use the layer parameter and only build the
1735            left choice when a layer is given
1736            (JoinDialog.OnJoin): Handle layer joins as well
1737            (JoinDialog.OnLeftTable, JoinDialog.OnRightTable): Handle the case
1738            that the user selects the "Select..." item. The sensitivitly
1739            updating is now in update_sensitivity
1740            (JoinDialog.y): New method to refactor the sensitivity update of
1741            the join button into its own method.
1742    
1743            * Thuban/UI/mainwindow.py (MainWindow.LayerJoinTable): Implement.
1744    
1745    2003-05-27  Bernhard Herzog  <[email protected]>
1746    
1747            * Thuban/UI/mainwindow.py (table_close command): Make it sensitive
1748            iff there are unreferenced tables in the session
1749    
1750    2003-05-27  Bernhard Herzog  <[email protected]>
1751    
1752            * Thuban/Model/messages.py (TABLE_REMOVED): New message.
1753    
1754            * Thuban/Model/session.py (Session.UnreferencedTables): New method
1755            to return tables that are not referenced by other tables or shape
1756            stores and can be removed.
1757            (Session.RemoveTable): Issue a TABLE_REMOVED message after
1758            removing the table
1759    
1760            * Thuban/UI/mainwindow.py: Remove unused imports
1761            (MainWindow.TableClose): Implement.
1762    
1763            * Thuban/UI/tableview.py (TableFrame.__init__): Subscribe to some
1764            messages so that the frame will be automatically closed when a new
1765            session is opened or the table is removed.
1766            (TableFrame.OnClose): Unsubscribe the Subscriptions made in
1767            __init__
1768            (TableFrame.close_on_session_replaced)
1769            (TableFrame.close_on_table_removed): New. Subscribers that close
1770            the window
1771    
1772            * test/test_session.py (TestSessionMessages.test_remove_table)
1773            (TestSessionSimple.test_remove_table): Move the test to
1774            TestSessionSimple and add test for the TABLE_REMOVED message
1775            (TestSessionBase.setUp): Also subscribe to TABLE_REMOVED
1776            (TestSessionSimple.test_unreferenced_tables) New. Test for the
1777            UnreferencedTables method.
1778            (UnreferencedTablesTests): New. Class with some more sophisticated
1779            tests for UnreferencedTables.
1780    
1781    2003-05-27  Frank Koormann  <[email protected]>
1782    
1783            * Thuban/UI/tableview.py (QueryTableFrame.__init__): The "_S_election"
1784            display has some unwanted side effects. Removed again.
1785    
1786    2003-05-27  Frank Koormann  <[email protected]>
1787    
1788            * Resources/Bitmaps/legend_icon_layer.xpm: New, icon for legend.
1789    
1790            * Thuban/UI/legend.py (LegendTree.__FillTree): Use "legend_icon_layer"
1791    
1792    2003-05-27  Jan-Oliver Wagner <[email protected]>
1793    
1794            * test/test_menu.py (MenuTest.test): Added test for
1795            Menu.RemoveItem().
1796    
1797            * Thuban/UI/menu.py (Menu.RemoveItem): New. Remove an item from
1798            the menu.
1799    
1800    2003-05-27  Frank Koormann  <[email protected]>
1801            
1802            Nonmodal dialogs without parent (i.e. they can fall behind the main
1803            window)
1804    
1805            * Thuban/UI/mainwindow.py (MainWindow.OnClose): Explicitly destroy
1806            all dialogs in the dialogs dictionary and the canvas.
1807    
1808            * Thuban/UI/dialogs.py (NonModalNonParentDialog): New class, without
1809            parent, i.e. can fall behind other windows.
1810            (NonModalDialog.OnClose): Check is dialog is in mainwindow.dialog
1811            dictionary before removing it.
1812    
1813            * Thuban/UI/classifier.py: Dialog derived from NonModalNonParentDialog
1814    
1815            * Thuban/UI/projdialog.py: Dialog derived from NonModalNonParentDialog
1816            * Thuban/UI/tableview.py: Dialog derived from NonModalNonParentDialog
1817            * Thuban/UI/tree.py: Dialog derived from NonModalNonParentDialog
1818    
1819    2003-05-27  Bernhard Herzog  <[email protected]>
1820    
1821            * Thuban/UI/mainwindow.py (MainWindow.ShowTableView): New. Open a
1822            tableview dialog
1823            (MainWindow.TableShow): Use ShowTableView to open the dialogs.
1824            Also, don't use the table's titles as the dialog names. The titles
1825            aren't guaranteed to be unique.
1826            (MainWindow.TableOpen): Open a table view dialog after opening the
1827            table
1828    
1829    2003-05-27  Bernhard Herzog  <[email protected]>
1830    
1831            * Thuban/UI/mainwindow.py: Remove the Table/Hide menu item. Its
1832            effect can be achieved by simply closing the window showing the
1833            table.
1834            (MainWindow.TableHide): Removed.
1835            (main_menu): Removed "table_hide"
1836    
1837    2003-05-27  Frank Koormann  <[email protected]>
1838    
1839            Fix legend tree display problems under Win32
1840    
1841            * Thuban/UI/legend.py:  BMP_SIZE_W = 15
1842            (LegendTree.__FillTree): Display "legend_icon_map.xpm" with layer title.
1843            (LegendTree.__FillTreeLayer): Explicitely set SelectedImage.
1844    
1845            * Resources/Bitmaps/legend_icon_map.xpm: New icon for legend.
1846    
1847    2003-05-27  Jan-Oliver Wagner <[email protected]>
1848    
1849            * Thuban/UI/menu.py (Menu.InsertSeparator): Additional optional parameter
1850            'after' now allows to insert separators almost anywhere in the menu.
1851    
1852    2003-05-27  Frank Koormann  <[email protected]>
1853    
1854            * Thuban/UI/tableview.py (QueryTableFrame.__init__): Underline the
1855            "S" of selection box label to hint on hot key (Alt-S). Works under
1856            Win32 but is ignored under GTK.
1857    
1858    2003-05-26  Frank Koormann  <[email protected]>
1859    
1860            * Thuban/UI/projdialog.py (ProjFrame.__do_layout, ProjPanel._DoLayout):
1861            Center Choices.
1862    
1863    2003-05-26  Bernhard Herzog  <[email protected]>
1864    
1865            Remove the Precision methods again. They're too DBF specific to be
1866            part of the table interface and they're only used in table_to_dbf
1867            anyway.
1868            
1869            * Thuban/Model/transientdb.py (TransientTableBase.Width):Use a
1870            fixed precision of 12 for doubles.
1871            (TransientTableBase.Precision): Removed
1872            (AutoTransientTable.Width): Delegate to self.table.
1873    
1874            * Thuban/Model/table.py (DBFTable.Precision)
1875            (MemoryTable.Precision): Removed.
1876            (MemoryTable.Width): Use a fixed precision of 12 for doubles.
1877            (table_to_dbf): Use a fixed precision of 12 for floats unless the
1878            column object specifies something else.
1879    
1880            * test/test_dbf_table.py (TestTableToDBF.test_table_to_dbf): New.
1881            test for table_to_dbf
1882    
1883    2003-05-26  Bernhard Herzog  <[email protected]>
1884    
1885            * test/test_transientdb.py
1886            (TestTransientTable.run_iceland_political_tests): Fix a comment.
1887    
1888    2003-05-26  Bernhard Herzog  <[email protected]>
1889    
1890            * Thuban/UI/mainwindow.py (MainWindow.TableOpen): Real
1891            implementation. Mark parts of the file format strings for
1892            localization.
1893    
1894            * Thuban/Model/session.py (Session.OpenTableFile): New. Open a dbf
1895            file and add the table to the tables managed by the session
1896    
1897            * test/test_session.py (TestSessionSimple.test_open_table_file):
1898            New. test case for OpenTableFile
1899    
1900    2003-05-26  Jan-Oliver Wagner <[email protected]>
1901    
1902            * Thuban/UI/controls.py, Thuban/UI/identifyview.py, Thuban/UI/join.py,
1903            Thuban/UI/labeldialog.py, Thuban/UI/mainwindow.py,
1904            Thuban/UI/proj4dialog.py, Thuban/UI/tableview.py, Thuban/UI/view.py:
1905            Replace the true/false of wxWindows by True/False of Python 2.2.1.
1906    
1907    2003-05-26  Jan-Oliver Wagner <[email protected]>
1908    
1909            * Thuban/UI/tableview.py (LayerTableFrame.__init__): If there is
1910            already a selection present, update the grid accordingly.
1911    
1912            * Thuban/UI/mainwindow.py (MainWindow.TableShow): Make the dialog
1913            resizeable and increase its initial size.
1914    
1915    2003-05-26  Frank Koormann  <[email protected]>
1916    
1917            Table export functionality
1918    
1919            * Thuban/Model/table.py (DBFTable.Width, MemoryTable.Width):
1920            Return width (in characters) for a column.
1921            (DBFTable.Precision, MemoryTable.Precision): Return decimal precision.
1922            (table_to_dbf): Write table to dbf file.
1923            (table_to_csv): Write table to csv file.
1924    
1925            * Thuban/Model/transientdb.py (TransientTableBase.Width,
1926            TransientTableBase.Precision): Return column width and precision.
1927    
1928            * Thuban/UI/tableview.py (QueryTableFrame.OnSaveAs): Call table_to_dbf
1929            or table_to_csv depending on file selection.
1930    
1931            * test/test_dbf_table.py:
1932            Test table_to_dbf (extension of former part of test).
1933    
1934            * test/test_csv_table.py:
1935            Test table_to_csv.
1936    
1937    2003-05-23  Jan-Oliver Wagner <[email protected]>
1938    
1939            * Thuban/UI/join.py (JoinDialog.OnJoin): Use _() for strings.
1940            Use QueryTableFrame instead of TableFrame.
1941    
1942            * Thuban/UI/mainwindow.py (MainWindow.LayerShowTable): Prefix the
1943            table window with 'Layer Table:' instead of 'Table:'.
1944    
1945    2003-05-23  Jan-Oliver Wagner <[email protected]>
1946    
1947            Give all tables a title via mix-in TitledObject.LayerShowTable
1948    
1949            * Thuban/Model/base.py (TitledObject.SetTitle): Call method 'issue'
1950            only if it exists.
1951    
1952            * Thuban/Model/table.py (DBFTable, MemoryTable): mix-in TitledObject
1953            and call its init-method with a default title. Remove Title() method.
1954    
1955            * Thuban/Model/transientdb.py (TransientTable, TransientJoinedTable,
1956            AutoTransientTable): mix-in TitledObject and call its init-method with
1957            a default title. Remove Title() method.
1958    
1959    2003-05-23  Bernhard Herzog  <[email protected]>
1960    
1961            * Thuban/Model/session.py (Session.AddShapeStore): Define
1962            AddShapeStore analogously to AddTable.
1963    
1964            * test/test_session.py (TestSessionSimple.test_add_shapestore):
1965            New. Test for AddShapeStore
1966    
1967    2003-05-23  Jan-Oliver Wagner <[email protected]>
1968    
1969            Introducing QueryTableFrame and a very coarse ShowTable implementation.
1970    
1971            * Thuban/UI/tableview.py (LayerTableFrame, QueryTableFrame): Split the
1972            class LayerTableFrame into two classes, LayerTableFrame and QueryTableFrame.
1973            The latter implements the selection GUI without dependency on a layer.
1974            LayerTableFrame now is derived from QueryTableFrame and connects
1975            to a layer.
1976    
1977            * Thuban/UI/mainwindow.py (MainWindow.TableShow): A very coarse
1978            implementation that still needs work.
1979    
1980            * Thuban/Model/layer.py (Layer.TreeInfo): Added filename.
1981    
1982    2003-05-22  Frank Koormann  <[email protected]>
1983    
1984            * Thuban/Model/transientdb.py (TransientJoinedTable.__init__):
1985            Added "outer_join = False" as optional parameter.
1986            (TransientJoinedTable.create): If outer join is true, perform a
1987            "LEFT OUTER JOIN" instead of "JOIN", which preserves all records of
1988            the left table. Records not matching are filled with 0 / None.
1989    
1990            * Thuban/UI/join.py (JoinDialog.__init__): Checkbox for outer join.
1991            (JoinDialog.OnJoin): Consider outer join check box.
1992    
1993    2003-05-22  Bernhard Herzog  <[email protected]>
1994    
1995            * Thuban/UI/join.py (JoinDialog.OnJoin): Use exc_info in a
1996            somewhat safer way. Storing the traceback in a local variable can
1997            lead to memory leaks
1998    
1999    2003-05-22  Bernhard Herzog  <[email protected]>
2000    
2001            * Thuban/UI/join.py (JoinDialog.OnJoin): Make sure to really call
2002            the wxMessageDialog's Destroy() method.
2003    
2004    2003-05-22  Frank Koormann  <[email protected]>
2005    
2006            * Thuban/UI/join.py (JoinDialog.__init__): Make use of
2007            TransientTable.Title()
2008    
2009    2003-05-22  Frank Koormann  <[email protected]>
2010    
2011            Join Dialog, initial version.
2012    
2013            * Thuban/UI/mainwindow.py (MainWindow.TableJoin): Removed print.
2014    
2015            * Thuban/UI/join.py (JoinDialog): Functional implementation of
2016            former framework. Renamed Table1/Table2 to LeftTable/RightTable
2017            in all occurences.
2018    
2019            * Thuban/Model/transientdb.py (TransientJoinedTable.__doc__):
2020            Typo fixed.
2021    
2022    2003-05-22  Bernhard Herzog  <[email protected]>
2023    
2024            Give the tables titles so that the GUI can display more meaningful
2025            names. For now the titles are fixed but depend on e.g. filenames
2026            or the titles of the joined tables.
2027    
2028            * Thuban/Model/transientdb.py (TransientTable.Title)
2029            (TransientJoinedTable.Title, AutoTransientTable.Title): New.
2030    
2031            * Thuban/Model/table.py (DBFTable.Title, MemoryTable.Title): New.
2032    
2033            * test/test_transientdb.py
2034            (TestTransientTable.test_auto_transient_table_title): New. Test
2035            for the Title method
2036            (TestTransientTable.test_transient_joined_table)
2037            (TestTransientTable.test_transient_table): Add test for the Title
2038            methods
2039    
2040            * test/test_memory_table.py (TestMemoryTable.test_title): New.
2041            Test for the Title method
2042    
2043            * test/test_dbf_table.py (TestDBFTable.test_title): New. Test for
2044            the Title method
2045    
2046    2003-05-22  Bernhard Herzog  <[email protected]>
2047    
2048            * test/test_layer.py (TestLayer.setUp, TestLayer.tearDown):
2049            Provide a better way to destroy the layers
2050            (TestLayer.test_base_layer, TestLayer.test_arc_layer)
2051            (TestLayer.test_point_layer, TestLayer.test_empty_layer)
2052            (TestLayer.test_polygon_layer, TestLayer.test_get_field_type): Use
2053            the new way to destroy the layers.
2054            (TestLayer.test_derived_store): New. Test for using a layer with a
2055            DerivedShapeStore
2056    
2057            * Thuban/Model/layer.py (Layer.SetShapeStore): Only set the
2058            filename if the shape store actually has one.
2059    
2060    2003-05-22  Bernhard Herzog  <[email protected]>
2061    
2062            * Thuban/Model/table.py (DBFTable.FileName): New. Accessor method
2063            for the filename
2064    
2065            * test/test_dbf_table.py (TestDBFTable.test_filename): New. Test
2066            for the FileName method
2067            (TestDBFTableWriting.test_write): Fix spelling of filename
2068    
2069    2003-05-22  Thomas Koester  <[email protected]>
2070    
2071            * Thuban/Model/range.py, test/test_range.py: Brought over new Range
2072            from SciParam that now really is immutable.
2073    
2074    2003-05-22  Frank Koormann  <[email protected]>
2075    
2076            Layer Top/Bottom placement added to legend.
2077    
2078            * Thuban/UI/legend.py
2079            (LegendPanel._OnMoveTop(), LayerPanel._OnMoveBottom): New, methods
2080            bound to tool events.
2081            (LegendTree.MoveCurrentItemTop(), LegendTree.MoveCurrentItemBottom):
2082            New, methods binding the event methods with the map methods.
2083    
2084            * Thuban/Model/map.py (Map.TopLayer(), Map.BottomLayer()): New, place
2085            layer at top/bottom of layer stack.
2086    
2087            * Resources/Bitmaps/top_layer.xpm: New button icon.
2088    
2089            * Resources/Bitmaps/bottom_layer.xpm: New button icon.
2090    
2091  2003-05-22  Bernhard Herzog  <[email protected]>  2003-05-22  Bernhard Herzog  <[email protected]>
2092    
2093          * Thuban/Model/session.py (Session.RemoveTable): New method to          * Thuban/Model/session.py (Session.RemoveTable): New method to

Legend:
Removed from v.988  
changed lines
  Added in v.1459

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26