/[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 1191 by jonathan, Thu Jun 12 17:01:45 2003 UTC revision 1420 by bh, Tue Jul 15 09:29:39 2003 UTC
# Line 1  Line 1 
1    2003-07-15  Bernhard Herzog  <[email protected]>
2    
3            * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Rework the
4            draw_func handling a bit to remove one layer of indirection. This
5            makes the renderer about 10% faster in the non-classifying case
6            and the code a bit cleaner
7            (MapRenderer.draw_point_shape): Add the pen and brush parameters
8            and set them in the dc. Now the draw_point_shape method and
9            wxproj's draw_polygon_shape function have basically the same
10            signature so that both can be directly used as draw_func
11    
12    2003-07-15  Bernhard Herzog  <[email protected]>
13    
14            * Thuban/Model/save.py (SessionSaver.write_classification): Encode
15            string values (in addition to the labels) as UTF 8
16    
17            * Thuban/Model/load.py (SessionLoader.start_clpoint): Decode the
18            values if the field type is string
19    
20            * test/test_save.py (SaveSessionTest.testClassifiedLayer): Test
21            saving a session with non-ascii string classification values.
22    
23            * test/test_load.py (TestClassification.file_contents)
24            (TestClassification.test): Check for non-ascii values in string
25            classifications
26    
27    2003-07-14  Jonathan Coles   <[email protected]>
28    
29            * test/test_view.py: New. Tests for ViewPort.
30    
31    2003-07-14  Frank Koormann   <[email protected]>
32    
33            * Thuban/Model/load.py (SessionLoader.start_map): Encode map
34            title to latin1.  Fixes https://intevation.de/rt/webrt?serial_num=2013
35    
36            * test/test_load_0_8.py (TestUnicodeStrings): New, test load of
37            unicode strings from session file: session title, map title and
38            projection name.
39            
40    2003-07-10  Jonathan Coles   <[email protected]>
41    
42            * Thuban/UI/viewport.py (Tool.MouseUp): Should have called
43            drag_stop, not drag_move when the mouse is released.
44    
45    2003-07-10  Jonathan Coles   <[email protected]>
46    
47            The most important part of this is the seperation of view.py into
48            two pieces. viewport.py now has a class called ViewPort which
49            contains all the non-wx parts of view.py and can therefore be
50            tested. view.py contains only the wx-specific parts and is fairly
51            simple.
52    
53            * Thuban/UI/view.py: Stripped out all non-wx functionality. Fixes
54            RTTbug #1992.
55            * Thuban/UI/viewport.py: New. Contains non-wx view functionality.
56            RTTbug #1992.
57    
58            * Thuban/Model/classgen.py (generate_singletons,
59            generate_uniform_distribution, generate_quantiles):
60            Added 'fixes' parameter so that property attributes can
61            be held constant over the generated classification groups.
62            (CustomRamp.GetProperties): Remove unused variables.
63    
64            * Thuban/Model/map.py (Map.SetProjection): Send the old
65            projection as an argument to listeners of the MAP_PROJECTION_CHANGED
66            event.
67    
68            * Thuban/Model/table.py (table_to_dbf, table_to_csv): Added 'records'
69            parameter which is a list of records that restricts which
70            records are saved. Fixes RTbug #1997.
71    
72            * Thuban/UI/application.py (ThubanApplication.ShowExceptionDialog):
73            Port exception dialog from GREAT-ER. Fixes RTbug #1993.
74    
75            * Thuban/UI/classgen.py (ClassGenDialog.__init__): Add controls
76            to allow the user to fix line color/width on generated groups.
77            (ClassGenDialog.OnOK): Use new 'fixes' parameter of the generate_*
78            functions to optionally fix group properties.
79    
80            * Thuban/UI/main.py (main): Set exception hook to the
81            ShowExceptionDialog. Fixes RTbug #1993.
82    
83            * Thuban/UI/mainwindow.py (MainWindow.ShowTableView): Raise
84            the table window when it is selectd to be shown.
85    
86            * Thuban/UI/tableview.py (QueryTableFrame.__init__): Add an
87            Export Selection button and move the export buttons underneath
88            the table.
89            (QueryTableFrame.UpdateStatusText): Added event argument so
90            that it can respond to grid selection events. The status text
91            is now updated even when the table is not associated with a
92            layer as was previously assumed.
93            (QueryTableFrame.OnGridSelectRange, OnGridSelectCell): Removed.
94            UpdateStatusText responds to these events.
95            (QueryTableFrame.OnSaveAs): Renamed to doExport.
96            (QueryTableFrame.doExport): Helper function that saves the
97            entire table, or selected rows, to a file.
98            (QueryTableFrame.OnExport, QueryTableFrame.OnExportSel): New.
99            Respond to export button events and call doExport.
100    
101            * extensions/thuban/gdalwarp.cpp (ProjectRasterFile): Make sure
102            the function doesn't return NULL without first setting a Python
103            Error.
104    
105            * test/runtests.py (main): Only print "Unknown option" for
106            unsupported options.
107    
108            * test/support.py (FloatComparisonMixin.assertFloatEqual): Take
109            optional epsilon argument to specify floating point accuracy.
110            (FloatComparisonMixin.assertFloatSeqEqual): Call assertFloatEqual
111            for each item test.
112    
113            * test/test_csv_table.py (TestCSVTable.test_table_to_cvs): Add
114            tests for saving selected records.
115    
116            * test/test_dbf_table.py (TestTableToDBF.test_table_to_dbf): Add
117            tests for saving selected records.
118    
119            * test/test_map.py (TestMapWithContents.test_set_projection):
120            MAP_PROJECTION_CHANGED events send the old projection.
121    
122            * test/test_session.py
123            (TestSessionWithContent.test_forward_map_projection):
124            MAP_PROJECTION_CHANGED events send the old projection.
125    
126            * test/test_table.py (TableTest): Update tests to use non-deprecated
127            functions.
128    
129    2003-07-08  Bernhard Herzog  <[email protected]>
130    
131            * Thuban/Model/transientdb.py (TransientTableBase.Width): The type
132            constants in the column objects are the standard ones defined in
133            the table module.
134    
135            * test/test_transientdb.py
136            (TestTransientTable.test_transienttable_to_dbf): New. Test whether
137            exporting transient tables as DBF works. This should catch the bug
138            just fixed in TransientTableBase.Width.
139    
140    2003-07-08  Bernhard Herzog  <[email protected]>
141    
142            * Thuban/Model/classgen.py (CustomRamp.GetProperties): Compute the
143            interpolated colors correctly.
144    
145            * test/test_classgen.py (TestCustomRamp.test_color_interpolation):
146            New. Test case for the fix in classgen.py
147    
148    2003-07-08  Bernhard Herzog  <[email protected]>
149    
150            * test/runtests.py (main): Make the default output less verbose
151            and add a verbosity option (-v) to get the old output
152    
153    2003-07-08  Bernhard Herzog  <[email protected]>
154    
155            * Resources/XML/thuban-0.9.dtd: New. This will become the DTD for
156            0.9.
157    
158            * Thuban/Model/transientdb.py (TransientJoinedTable.JoinType):
159            New. Return the join type
160    
161            * Thuban/Model/save.py (SessionSaver.write_session): Use new 0.9
162            DTD
163            (SessionSaver.write_data_containers): Save the join type for
164            joined tables
165    
166            * Thuban/Model/load.py (SessionLoader.__init__): Add the new 0.9
167            namespace
168            (SessionLoader.start_jointable): Handle the jointype attribute
169    
170            * test/test_load_0_8.py: New. Effectively a copy of test_load.py
171            as of Thuban 0.8. These are now tests to determine whether Thuban
172            can still read files generated by Thuban 0.8
173    
174            * test/test_load.py (LoadSessionTest.dtd)
175            (TestSingleLayer.file_contents)
176            (TestLayerVisibility.file_contents, TestLabels.file_contents)
177            (TestLayerProjection.file_contents)
178            (TestRasterLayer.file_contents, TestJoinedTable.file_contents)
179            (TestJoinedTable.file_contents)
180            (TestLoadError.file_contents): Update for new DTD
181            (TestJoinedTable.file_contents, TestJoinedTable.setUp): Add test
182            for new join type attribute
183    
184            * test/test_save.py (SaveSessionTest.dtd)
185            (SaveSessionTest.testEmptySession)
186            (SaveSessionTest.testSingleLayer)
187            (SaveSessionTest.testLayerProjection)
188            (SaveSessionTest.testRasterLayer)
189            (SaveSessionTest.testClassifiedLayer)
190            (SaveSessionTest.test_dbf_table)
191            (SaveSessionTest.test_joined_table): Update for new DTD
192            (SaveSessionTest.test_joined_table): Add test for new join type
193            attribute
194    
195    2003-07-04  Bernhard Herzog  <[email protected]>
196    
197            * Thuban/Model/table.py (_find_dbf_column_names): New. Helper
198            function for table_to_dbf
199            (table_to_dbf): Deal with names longer than the 10 character limit
200    
201            * test/test_dbf_table.py (TestTableToDBF.test_table_to_dbf): Add
202            doc-string
203            (TestTableToDBF.test_table_to_dbf_long_col_names): New test for
204            long column names
205    
206    2003-07-03  Bernhard Herzog  <[email protected]>
207    
208            * Doc/manual/thuban-manual.xml: Fix the CVS Revision Tag syntax
209    
210    2003-07-03  Bernhard Herzog  <[email protected]>
211    
212            * Doc/manual/thuban-manual.xml, Doc/manual/README: New. Skeleton
213            for the Thuban manual and README with some basic information about
214            the manual
215    
216    2003-07-03  Bernhard Herzog  <[email protected]>
217    
218            * Thuban/Model/transientdb.py (TransientJoinedTable.__init__):
219            Update doc-string
220            (TransientJoinedTable.create): Do not modify the column objects of
221            the input tables in place and copy all columns of the input tables
222            into the joined table after all.
223    
224            * test/test_transientdb.py
225            (TestTransientTable.test_transient_joined_table_same_column_name):
226            Update to reflect the new behavior
227            (TestTransientTable.test_transient_joined_table_with_equal_column_names):
228            Update to reflect the new behavior
229            (TestTransientTable.test_transient_joined_table_name_collisions_dont_modify_in_place):
230            New test case for a bug which modified the column objects in place
231    
232    2003-07-02  Jonathan Coles   <[email protected]>
233    
234            * Thuban/Model/classgen.py (generate_singletons,
235            generate_uniform_distribution, generate_quantiles,
236            GenQuantiles0): Make sure maxValue isn't less than
237            one, otherwise we could divide by zero.
238    
239            * test/test_classgen.py (ClassGenTest.doClassRangeTest,
240            ClassGenTest.doClassSingleTest): Call doBoundsTest to
241            check the end classification groups against the
242            proper property values.
243            (ClassGenTest.doBoundsTest): New. Checks the first and
244            last classification groups to make sure their properties
245            are the correct upper and lower bounds for a color ramp.
246    
247    2003-07-02  Jonathan Coles   <[email protected]>
248    
249            * Thuban/Model/classgen.py (generate_singletons,
250            generate_uniform_distribution, generate_quantiles,
251            GenQuantiles0): The denominator was one to high when
252            calculating the index for the ramp causing the index
253            to never to reach one.
254    
255    2003-07-02  Jonathan Coles   <[email protected]>
256    
257            Changed the singature of ClassGroupRange.__init__ and
258            ClassGroupRange.SetRange() so that the min/max values are
259            passed as a tuple. This makes a better calling scheme for
260            when a Range object is passed instead.
261    
262            * Thuban/Model/classgen.py: Fixed parameters to
263            ClassGroupRange constructor.
264    
265            * Thuban/Model/classification.py (ClassGroupRange.__init__):
266            Consolidate the min/max parameters into a single _range which
267            can either be a tuple or a Range object.
268            (ClassGroupRange.SetRange): Consolidate the min/max parameters
269            into a single _range which can either be a tuple or a Range object.
270    
271            * Thuban/Model/load.py (SessionLoader.start_clrange): Fix
272            call to ClassGroupRange constructor to use a tuple.
273    
274            * Thuban/Model/layer.py (Layer.SetClassification): Switch
275            the classification instance variable to the new class
276            before calling _set_layer otherwise subscribers to a
277            LAYER_CHANGED event will not see any difference.
278    
279            * test/test_classification.py: Fix tests of ClassGroupRange
280            so that they use the new signature.
281    
282            * test/test_load.py: Fix use of ClassGroupRange so that it
283            uses the new signature.
284    
285            * test/test_load_0_2.py: Fix use of ClassGroupRange so that it
286            uses the new signature.
287    
288            * test/test_save.py: Fix use of ClassGroupRange so that it
289            uses the new signature.
290    
291    
292    2003-07-01  Jonathan Coles   <[email protected]>
293    
294            * Thuban/Model/classgen.py: Fixes RTbug #1972, 1971.
295            Import used objects/class from color.
296            (generate_singletons): We don't
297            need the numGroups parameter anymore because we are using
298            the new ramps with GetProperties().
299            (generate_uniform_distribution): Use new ramp method
300            GetProperties().
301            (generate_quantiles, GenQuantiles0): Use new ramp method
302            GetProperties().
303            (CustomRamp.SetNumGroups): Removed. The ramps now map
304            a value from 0 to 1 to class properties so the number
305            of groups is not needed ahead of time.
306            (CustomRamp.next): Removed. CustomRamp does not support
307            interation anymore.
308            (CustomRamp.GetProperties): Returns a ClassGroupProperties
309            object based on the index value from 0 to 1 that is
310            passed to it.
311            (GreyRamp, RedRamp, GreenRamp, BlueRamp, GreenToRedRamp):
312            Made into instances of Monochromatic class instread of
313            deriving from it.
314            (HotToCold.SetNumGroups): Removed. See CustomRamp.
315            (HotToCold.next): Removed. See CustomRamp.
316    
317            * Thuban/Model/classification.py: Fixes RTbug #1973, 1971.
318            (Classification.SetField, Classification.SetFieldType):
319            Replaced with SetFieldInfo.
320            (Classification.SetFieldInfo): New. Does a better job of
321            what SetField and SetFieldType used to do by combining
322            their function since they should really always be done
323            at the same time.
324            (Classification.SetLayer): Renamed to _set_layer.
325            (Classification._set_layer): Should only be called from
326            Layer's SetClassification. This does not cause a recursive
327            call as SetLayer did because we know that Layer knows about
328            the classification.
329    
330            * Thuban/Model/color.py: Fixes RTbug #1971.
331            (_Transparent): Renamed from Transparent so it doesn't
332            conflict with the module variable.
333            (Transparent, Black): Renamed from Color.Transparent,
334            Color.Black so they are not class variables.
335    
336            * Thuban/Model/layer.py: Fixes RTbug #1971, 1973.
337            (Layer.Destroy): We don't need to call SetClassification
338            anymore to clear out the back reference in the classifcation
339            to the layer. It's better to set it to None using _set_layer,
340            and we won't be creating another clas object too.
341            (Layer.SetClassification): Classification._set_layer is not
342            recursive so remove all the locking variables. Also clean
343            up the code so that it remains unchanged if something fails.
344    
345            * Thuban/Model/load.py: Fixes RTbug #1971.
346            (SessionLoader.start_classification): Call
347            Classification.SetFieldInfo().
348    
349            * Thuban/Model/save.py: Removed import of Color which wasn't
350            being used.
351    
352            * Thuban/UI/classgen.py: Fixes RTbug #1972.
353            (ClassGenDialog.__init__): Color ramps are now instances
354            already so we don't need to create any new objects.
355            (ClassGenDialog.OnOK): Check for numGroups is no longer
356            necessary because we never use it.
357    
358            * Thuban/UI/classifier.py: Fixes RTbug #1971.
359            (Classifier.__BuildClassification, Classifier.__SetGridTable):
360            Call Classification.SetFieldInfo() instead of SetFieldType.
361    
362            * Thuban/UI/renderer.py: Fixes RTbug #1971.
363    
364            * Thuban/UI/view.py: Fixes RTbug #1974, 1971.
365            (MapCanvas.__init__): Subscribe to the idle time event. Set
366            background color to white.
367            (MapCanvas.OnPaint): Set a flag indicating that we should
368            render the map during idle time. If we already have a bitmap
369            just draw it now.
370            (MapCanvas.OnIdle): New. Render the map only during idle time.
371            This also fixes a problem with the busy cursor under gtk.
372    
373            * test/test_classgen.py (ClassGenTest.test_generate_singletons):
374            Fix calls to generate_singletons because the signature changed.
375    
376            * test/test_classification.py: Fix color references and
377            change calls to Classification.[SetField|SetFieldType] to
378            SetFieldInfo.
379    
380            * test/test_load.py: Fix color references.
381    
382            * test/test_load_0_2.py: Fix color references.
383    
384            * test/test_save.py (SaveSessionTest.testClassifiedLayer):
385            Change calls to Classification.[SetField|SetFieldType] to
386            SetFieldInfo.
387    
388    2003-07-01  Frank Koormann   <[email protected]>
389    
390            MERGE from the greater-ms3 branch.
391    
392            * test/test_transientdb.py
393            (TestTransientTable.test_transient_joined_table_with_equal_column_names):
394            New. Test join of two tables with partly equal column names.
395    
396            * Thuban/Model/transientdb.py (TransientJoinedTable.create):
397            If duplicates in left and right tables column names are found,
398            append '_' (underscores) to the name until it is unique.
399            Create always new internal names for the resulting table and reference
400            columns in the join statement with <table>.<column>
401    
402    2003-07-01  Bernhard Herzog  <[email protected]>
403    
404            * test/test_transientdb.py
405            (TestTransientTable.test_transient_joined_table_same_column_name):
406            New. Test whether joining on columns with the same names in both
407            tables works.
408            
409            * Thuban/Model/transientdb.py (TransientJoinedTable.create): Make
410            sure to use the right internal names even when joining on field
411            with the same names in both tables. Also, detect duplicate names
412            in the joined table correctly.
413    
414    2003-07-01  Frank Koormann   <[email protected]>
415    
416            * Thuban/UI/renderer.py (ExportRenderer.render_legend):
417            Reverse List of layers to render in same order as in desktop legend.
418    
419    2003-06-30  Jonathan Coles   <[email protected]>
420    
421            * Thuban/version.py (make_tuple): Takes a version string
422            and splits it into a tuple of at most three integers.
423            Used make_tuple() to make tuple versions of the version
424            numbers.
425    
426            * Thuban/UI/about.py: Add Thuban email addresses.
427    
428    2003-06-30  Jonathan Coles   <[email protected]>
429    
430            * Thuban/version.py: SQLite/PySQLite version dependencies
431            were too high.
432    
433    2003-06-30  Jonathan Coles   <[email protected]>
434    
435            * Thuban/version.py: Update version to 0.8.1
436            
437            * MANIFEST.in: Added Projections so that default.proj is
438            included.
439    
440    2003-06-26  Jonathan Coles   <[email protected]>
441    
442            New About box with lots more information including library
443            versions and credits. More/better version checking before
444            Thuban starts.
445    
446            * Thuban/UI/about.py: New. New About box that displays
447            library version information and credits.
448    
449            * Thuban/version.py: Added new 'versions' dictionary which
450            contains the verions of various libraries which are checked
451            when the module loads.
452            (verify_versions): Check all version numbers and returns
453            a list of errors.
454    
455            * Thuban/UI/classifier.py (Classifier.__EnableButtons):
456            Reset the status of the buttons as the situation warrants,
457            but in a better more reliable way by not relying on the
458            current status to determine what needs to change.
459    
460            * Thuban/UI/main.py (wxCHECK_VERSION): Removed. Not needed.
461            (verify_versions): Remove most of the code since it is
462            now in Thuban.version.verify_versions.o
463    
464            * Thuban/UI/mainwindow.py (MainWindow.About): Call new
465            About box in Thuban.UI.about.
466    
467            * extensions/thuban/gdalwarp.cpp (get_gdal_version): New.
468            Returns the version of gdal library being used as a string.
469    
470            * extensions/thuban/wxproj.cpp (check_version, check_version_gtk):
471            Removed.
472            (get_proj_version): Return the version of PROJ that the file
473            was compiled with.
474            (get_gtk_version): Return th version of GTK that the file
475            was compiled with.
476    
477    2003-06-25  Jonathan Coles   <[email protected]>
478    
479            * Thuban/UI/classifier.py (Classifier.EditSymbol): The parent
480            of the SelectPropertiesDialog should be self so the window
481            appears on top.
482            (ClassGroupPropertiesCtrl.DoEdit): The parent
483            of the SelectPropertiesDialog should be self so the window
484            appears on top.
485    
486            * Thuban/UI/resource.py: Cleaned up how we determine file
487            extensions.
488            (GetImageResource): Return an wxImage from our Resources.
489    
490    2003-06-24  Jonathan Coles   <[email protected]>
491    
492            * Thuban/UI/renderer.py (ExportRenderer.render_legend):
493            Check that a layer has a classification before trying
494            to get it. Raster layers don't have classifications.
495    
496    2003-06-23  Jonathan Coles   <[email protected]>
497            
498            * setup.py: Add Resources/XML to resource list.
499        
500    2003-06-23  Jonathan Coles   <[email protected]>
501    
502            * setup.cfg: Fix copyright dates
503        
504    2003-06-23  Jonathan Coles   <[email protected]>
505    
506            * MANIFEST.in: Update with Resources/XML
507    
508            * setup.py: Don't include Locale resources yet as we don't
509            have any and it causes problems building the distribution
510            for Windows. Update version to 0.8.0.
511    
512            * Doc/thuban.dtd: Removed since it is now in Resources/XML.
513    
514            * Thuban/UI/mainwindow.py: Add blank line at the end because
515            file was not being read correctly building the Windows
516            distribution.
517    
518    2003-06-23  Jonathan Coles   <[email protected]>
519    
520            * Thuban/UI/mainwindow.py (MainWindow.About): Fix text.
521    
522            * Thuban/version.py: Temporarily update longversion for
523            the 0.8 release so that it doesn't have the cvs revision.
524    
525    2003-06-23  Jonathan Coles   <[email protected]>
526    
527            * Thuban/UI/common.py (ThubanBeginBusyCursor): Call wxSafeYield
528            to make sure that we don't create reentrant possibilities with
529            wxYield.
530    
531            * Thuban/UI/view.py (MapCanvas.OnPaint): Call wxBeginBusyCursor()
532            directly to avoid the wxSafeYield() call which generates an
533            OnPaint event causing infinite recursion. Don't try to catch
534            exception anymore. This was for before there were limits on map
535            scaling.
536    
537    2003-06-23  Bernhard Herzog  <[email protected]>
538    
539            Bug fix for RT #1961:
540    
541            * Thuban/Model/load.py (SessionLoader.start_derivedshapesource):
542            Register DerivedShapestores with the session
543    
544            * Thuban/Model/session.py (Session.Tables): Make sure each table
545            is only listed once.
546    
547            * test/test_load.py (TestJoinedTable.test): Add check_format call.
548            Update file contents to match the one written out.
549    
550    2003-06-20  Bernhard Herzog  <[email protected]>
551    
552            * test/xmlsupport.py (SaxEventLister.startElementNS)
553            (SaxEventLister.endElementNS): Do not include the qname. Python
554            2.2.1 and 2.2.2 and 2.2.3 differ in this regard. In 2.2.1 qname it
555            is (presumably incorrectly) None, whereas it's a string with the
556            element name in the later versions.
557    
558            * test/test_xmlsupport.py (TestEventList.test_even_list_simple)
559            (TestEventList.test_even_list_namespace): Update tests to reflect
560            the new behaviour
561            (TestEventList.test_even_list_id_normalization): Fix doc-string
562    
563    2003-06-20  Jonathan Coles   <[email protected]>
564    
565            * Thuban/Model/layer.py (BaseLayer.HasShapes): New. Overridden
566            by deriving classes to determine if that layer supports shapes.
567            (Layer): Override HasShapes and return true.
568    
569            * Thuban/UI/classgen.py: Use Thuban[Begin|End]BusyCursor()
570            instead of a direct call to wx[Begin|End]CusyCursor().
571            (GenUniquePanel._OnRetrieve): Set busy cursor while retrieving
572            table data.
573    
574            * Thuban/UI/common.py (ThubanBeginBusyCursor, ThubanEndBusyCursor):
575            New. Wrappers around the wxWindows functions that allow us to
576            make additional calls such as wxYield which gives the native
577            system a chance to update the cursor correctly.
578    
579            * Thuban/UI/tableview.py: Use Thuban[Begin|End]BusyCursor()
580            instead of a direct call to wx[Begin|End]CusyCursor().
581    
582            * Thuban/UI/view.py: Use Thuban[Begin|End]BusyCursor()
583            instead of a direct call to wx[Begin|End]CusyCursor().
584            (MapCanvas.find_shape_at): Check if the current search layer
585            support shapes, otherwise go on to the next layer.
586    
587            * test/test_layer.py: Add tests in each type of layer for
588            HasClassification() and HasShapes()
589    
590    2003-06-20  Jonathan Coles   <[email protected]>
591    
592            * Thuban/UI/view.py (MapCanvas.OnPaint): Call wxYield after
593            turning on the busy cursor to allow the system to change the
594            cursor before we begin painting. This fixes a problem that
595            was occuring only under GTK. Fixes RTbug #1840.
596    
597    2003-06-20  Bernhard Herzog  <[email protected]>
598    
599            * Resources/XML/thuban-0.8.dtd: New DTD for the new file format
600            version.
601    
602            * Thuban/Model/save.py (sort_data_stores): New. Make topological
603            sort of the data sources so they can be written with sources that
604            data sources that depend on other data sources come after the
605            sources they depend on.
606            (SessionSaver.__init__): Add idmap instance variable to map from
607            objects to the ids used in the file.
608            (SessionSaver.get_id, SessionSaver.define_id)
609            (SessionSaver.has_id): New. Methods to manage the idmap
610            (SessionSaver.write): Use thuban-0.8.dtd
611            (SessionSaver.write_session): Add a namespace on the session and
612            write out the data sources before the maps.
613            (SessionSaver.write_data_containers): New. Write the data
614            containers.
615            (SessionSaver.write_layer): Layer elements now refer to a
616            shapestore and don't contain filenames anymore.
617    
618            * Thuban/Model/load.py (LoadError): Exception class to raise when
619            errors in the files are discovered
620            (SessionLoader.__init__): Define dispatchers for elements with a
621            thuban-0.8 namespace too.
622            (SessionLoader.check_attrs): New helper method to check and
623            convert attributes
624            (AttrDesc): New. Helper class for SessionLoader.check_attrs
625            (SessionLoader.start_fileshapesource)
626            (SessionLoader.start_derivedshapesource)
627            (SessionLoader.start_filetable, SessionLoader.start_jointable):
628            Handlers for the new elements in the new fileformat
629            (SessionLoader.start_layer): Handle the shapestore attribute in
630            addition to filename.
631            (SessionLoader.start_table, SessionLoader.end_table): Removed.
632            They were never used in the old formats and aren't needed for the
633            new.
634    
635            * Thuban/Model/session.py (Session.DataContainers): New method to
636            return all "data containers", i.e. shapestores and tables
637    
638            * test/xmlsupport.py (SaxEventLister.__init__)
639            (SaxEventLister.startElementNS, sax_eventlist): Add support to
640            normalize IDs.
641    
642            * test/test_xmlsupport.py
643            (TestEventList.test_even_list_id_normalization): New test case for
644            id normalization
645    
646            * test/test_load.py (LoadSessionTest.check_format): Use ID
647            normalization
648            (LoadSessionTest.thubanids, LoadSessionTest.thubanidrefs): New
649            class atrributes used for ID normalization
650            (TestSingleLayer, TestLayerVisibility, TestLabels.test)
651            (TestLayerProjection.test, TestRasterLayer.test): Adapt to new
652            file format
653            (TestJoinedTable): New test for loading sessions with joined
654            tables.
655            (TestLoadError): New. Test whether missing required attributes
656            cause a LoadError.
657    
658            * test/test_save.py (SaveSessionTest.thubanids)
659            (SaveSessionTest.thubanidrefs): New class attributes for ID
660            normalization in .thuban files.
661            (SaveSessionTest.compare_xml): Use id-normalization.
662            (SaveSessionTest.testEmptySession)
663            (SaveSessionTest.testLayerProjection)
664            (SaveSessionTest.testRasterLayer)
665            (SaveSessionTest.testClassifiedLayer): Adapt to new file format.
666            (SaveSessionTest.testLayerProjection): The filename used was the
667            same as for testSingleLayer. Use a different one.
668            (SaveSessionTest.test_dbf_table)
669            (SaveSessionTest.test_joined_table): New test cases for saving the
670            new data sources structures.
671            (TestStoreSort, MockDataStore): Classes to test the sorting of the
672            data stores for writing.
673    
674            * test/runtests.py: Add CVS keywords
675    
676    2003-06-20  Jonathan Coles   <[email protected]>
677    
678            * test/test_session.py
679            (UnreferencedTablesTests.test_unreferenced_tables_with_joins):
680            Use the cultural_landmark-point.dbf file for the store so that
681            the table rows and shape count match.
682    
683    2003-06-20  Jonathan Coles   <[email protected]>
684    
685            * Thuban/Model/data.py (DerivedShapeStore.__init__): Raise
686            an exception if the number of shapes is different from the
687            number of rows in the table. Address RTbug #1933.
688    
689            * test/test_layer.py (TestLayer.test_derived_store): Add
690            a test for the new exception in DerivedShapeStore.__init__.
691    
692            * test/support.py (FloatTestCase): Removed since there is
693            already FloatComparisonMixin. Fixes RTbug #1954.
694            (FloatComparisonMixin.assertFloatEqual): Include test for
695            infinity that was part of FloatTestCase.
696    
697            * test/test_range.py (RangeTest): Inherit from
698            support.FloatComparisonMixin now that we don't have
699            support.FloatTestCase.
700    
701    2003-06-20  Bernhard Herzog  <[email protected]>
702    
703            * test/test_save.py (SaxEventLister, sax_eventlist): Removed. Use
704            the implementation in xmlsupport instead.
705            (SaveSessionTest.compare_xml): sax_eventlist is now in xmlsupport
706    
707            * test/test_proj.py: Import sax_eventlist from xmlsupport instead
708            of test_save
709    
710    2003-06-20  Bernhard Herzog  <[email protected]>
711    
712            * test/test_load.py (LoadSessionTest.check_format): New helper
713            method to make sure the test files we load might have been written
714            by the current thuban version.
715            (ClassificationTest.TestLayers, TestSingleLayer.test)
716            (TestLayerVisibility.test, TestClassification.test)
717            (TestLabels.test, TestLayerProjection.test, TestRasterLayer.test):
718            Add check_format() calls and fix the thuban data to match the data
719            that would be written by saving the session loaded from it.
720    
721            * test/xmlsupport.py (SaxEventLister, sax_eventlist): Copies of
722            the same class and function in test_save.
723    
724            * test/test_xmlsupport.py (TestEventList): New. test cases for
725            sax_eventlist
726    
727    2003-06-20  Bernhard Herzog  <[email protected]>
728    
729            * Resources/XML/thuban.dtd: Add comment about which versions of
730            Thuban are covered by this DTD
731            (map): Fix content model for layers and raster layers. There can
732            be any number or layers and raster layers in any order.
733    
734    2003-06-20  Jonathan Coles   <[email protected]>
735    
736            This is mainly about fixing RTbug #1949.
737    
738            * Thuban/Model/classification.py: Remove "from __future__"
739            import statement since python 2.2 is the earliest supported
740            version.
741    
742            * Thuban/Model/proj.py (Projection.GetProjectedUnits): New.
743            Currently returns PROJ_UNITS_METERS or PROJ_UNITS_DEGREES
744            depending on the units this projection *forwards* into.
745    
746            * Thuban/Model/save.py (SessionSaver.write_classification):
747            Remove unnecessary use of lambdas and nested functions.
748    
749            * Thuban/UI/legend.py (ScaleBarBitmap.__SetScale): Do scale
750            adjustment here if the map projection uses degrees.
751    
752            * Thuban/UI/scalebar.py (ScaleBar.DrawScaleBar): Remove
753            scale adjust code since it is now done before calling
754            this method. Don't do anything if the map projection
755            is None.
756    
757    2003-06-19  Bernhard Herzog  <[email protected]>
758    
759            Move version specific load tests to their own file.
760    
761            * test/test_load.py: Expand the doc-string to explain a bit how to
762            handle file format changes.
763            (TestClassification.test): Update the docstring as this test is
764            not about Thuban 0.2 anymore.
765    
766            * test/test_load_0_2.py: New file with the load tests for thuban
767            files created with Thuban 0.2 and earlier.
768    
769    2003-06-19  Bernhard Herzog  <[email protected]>
770    
771            Add XML validation to some of the tests. Validation will only be
772            done if pyRXP is installed (http://reportlab.com/xml/pyrxp.html).
773            To make the DTD available to the test cases it's moved into
774            Resources/XML
775    
776            * Resources/XML/thuban.dtd: New. This is now the real Thuban DTD
777            for versions up to and including 0.2. Two slight changes: added an
778            encoding specification and fixed the comment which refered to
779            GRASS, not Thuban
780    
781            * test/xmlsupport.py: New support module for tests involving XML.
782            Currently there's a mix-in class for XML validation.
783    
784            * test/test_xmlsupport.py: New. Tests for the xmlsupport module
785    
786            * test/test_save.py (SaveSessionTest): Derive from ValidationTest
787            so that we can validate the
788            (SaveSessionTest.testEmptySession)
789            (SaveSessionTest.testSingleLayer)
790            (SaveSessionTest.testSingleLayer)
791            (SaveSessionTest.testLayerProjection)
792            (SaveSessionTest.testRasterLayer)
793            (SaveSessionTest.testClassifiedLayer): Validate the generated XML
794    
795            * test/runtests.py (main): Call print_additional_summary instead
796            of print_garbage_information
797    
798            * test/support.py (resource_dir): New function to return the
799            "Resource" subdirectory
800            (print_additional_summary): New function to combine several
801            summary functions
802            (run_tests): Use print_additional_summary instead of calling
803            print_garbage_information directly
804    
805    2003-06-19  Bernhard Herzog  <[email protected]>
806    
807            * Doc/thuban.dtd (classification): Correct the content model of
808            the classification element.
809            (projection): Add the "name" attribute
810    
811    2003-06-19  Frank Koormann   <[email protected]>
812    
813            MERGE from the greater-ms3 branch.
814    
815            * Thuban/UI/scalebar.py (ScaleBar.DrawScaleBar): Apply conversion to
816            scale if projection is latlong to get better estimate.
817    
818            Fix problem of hidden properties dialog under windows after double
819            click on layer tree:
820            The tree control always gets an Expanded / Collapsed event after
821            the ItemActivated  on double click, which raises the main window again.         We add a second ItemActivated event to the queue, which simply
822            raises the already displayed window.
823    
824            * Thuban/UI/legend.py (LegendTree.__init__): Instance variable
825            raiseProperties initialized to prevent endless loops
826            (LegendTree._OnItemActivated): Depending on self.raiseProperties
827            simply raise the properties or open the dialog and issue a second
828            event.
829    
830    2003-06-18  Jonathan Coles   <[email protected]>
831    
832            * setup.py: Fix a few problems that occured under Windows.
833    
834    2003-06-18  Jonathan Coles   <[email protected]>
835    
836            When Thuban loaded the map was redrawn twice because the
837            legend was being opened after the mainwindow was created
838            and not during its creation. This meant the map was drawn
839            initially and then had to be redrawn when the legend
840            caused the display to change. Now the legend is opened
841            in the mainwindow constructor which resolves this issue.
842    
843            Also, although we were checking for the existence of
844            gdal and gdalwarp modules, the gdalwarp extension was
845            still being compiled (which may fail if the system doesn't
846            have gdal installed). the build_ext command to setup.py
847            now accepts the flags --with-gdal and --without-gdal.
848            If --without-gdal is specified setup.py will try to
849            use the gdal parameters specified by gdal-config. Under
850            windows, those parameters have to be set in setup.py
851            as with proj4 an wxWindows.
852    
853            * setup.py: Use a list instead of seperate variables for
854            extension parameters so we can create a generic function
855            that runs an appropriate *-config script.
856            (run_cs_script): Renamed from run_wx_script and modified
857            to accept a second argument which is a list of lists to
858            be filled in by the values returned from running the command.
859            (thuban_build_ext): New. Extends the build_ext command and
860            provides the options --with-gdal/--without-gdal which then
861            optionally includes the gdalwarp extension.
862    
863            * Thuban/Model/resource.py: First check if we can import
864            the gdalwarp Thuban extension before checking for gdal.
865            Also added some comments.
866            
867            * Thuban/UI/legend.py (ScaleBarBitmap.__SetScale): Check if
868            the map is None which may be the case if none has been loaded
869            yet.
870    
871            * Thuban/UI/main.py (main): Remove call to ShowLegend.
872    
873            * Thuban/UI/mainwindow.py (MainWindow.__init__): Call ShowLegend().
874    
875            * Thuban/UI/renderer.py: Check for gdal support before importing
876            gdalwarp.
877            (MapRenderer.render_map): Only try to optimize if we have gdal
878            support otherwise nothing will get drawn.
879    
880            * Thuban/UI/view.py (MapCanvas.FitMapToWindow): This may be called
881            during startup before a map has been created. Check if map is None
882            before using it and do nothing if it is.
883    
884    2003-06-17  Jonathan Coles   <[email protected]>
885    
886            Fix the problem with raster layers under Windows that caused
887            Thuban to crash. The view should respond to layer projection
888            changed events to update the display. Changes to a projection
889            should not cause the map to be set to full extent.
890            
891            * Thuban/UI/view.py (MapCanvas.__init__): New instance variable
892            current_map_proj to remember the current map projection so that
893            when the projection changes we know what the previous projection
894            was.
895            (MapCanvas.SetMap): Unsubscribe and subscribe to
896            LAYER_PROJECTION_CHANGED events.
897            (MapCanvas.projection_changed): Split into two methods that respond
898            to map and layer projection changes.
899            (MapCanvas.map_projection_changed): New. Takes the current view and
900            projects it using the new projection. This does not cause the
901            map to be redrawn at full extent.
902            (MapCanvas.layer_projection_changed): New. Cause a redraw which
903            will draw each layer in its new projection.
904            
905            * extensions/thuban/bmpdataset.cpp (BMPDataset::Open): Call
906            VSIFClose() not VSIFCloseL() to close the file. Fixes a crash
907            under Windows.
908            
909            * extensions/thuban/gdalwarp.cpp (MFILENAME): Padding should be
910            to twice sizeof(void*) because there are two digits for each
911            hex byte.
912    
913    2003-06-16  Bernhard Herzog  <[email protected]>
914    
915            Update to the layer interface: Direct access to the table,
916            shapetable, shapefile and filename attributes is now actively
917            deprecated by issuing deprecation warnings for all places where
918            this happens.
919    
920            * Thuban/Model/layer.py (Layer.__getattr__): New. Implement access
921            to the instance variables table, shapetable, shapefile and
922            filename via __getattr__ so that we can issue a deprecation
923            warning.
924            (Layer.SetShapeStore): Don't set the deprecated instance variables
925            any more
926            (Layer.SetShapeStore): Don't use deprecated layer instance
927            variables
928            (Layer.Destroy): No need to explicitly remove the instance
929            variables any more
930            (Layer.GetFieldType, Layer.Shape): Don't use deprecated layer
931            instance variables
932    
933            * Thuban/UI/classgen.py (ClassGenDialog.__init__)
934            (GenUniformPanel._OnRetrieve, GenUniquePanel._OnRetrieve)
935            (GenQuantilesPanel.GetList, GenQuantilesPanel.OnRetrieve): Don't
936            use deprecated layer instance variables
937    
938            * Thuban/UI/classifier.py (Classifier.__init__): Don't use
939            deprecated layer instance variables
940    
941            * Thuban/UI/identifyview.py (IdentifyListCtrl.selected_shape)
942            (IdentifyGridCtrl.selected_shape): Don't set the deprecated layer
943            instance variables
944    
945            * Thuban/UI/tableview.py (LayerTableGrid.select_shapes): Don't use
946            deprecated layer instance variables
947    
948            * Thuban/UI/mainwindow.py (MainWindow.LayerShowTable): Don't use
949            deprecated layer instance variables
950    
951            * Thuban/Model/save.py (SessionSaver.write_layer): Don't use
952            deprecated layer instance variables
953    
954            * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer)
955            (MapRenderer.polygon_render_param): Don't use deprecated layer instance
956            variables
957    
958            * test/runtests.py (main): Turn Thuban's deprecation warnings into
959            errors so that they're cought by the tests
960    
961            * test/test_load.py (TestSingleLayer.test): Don't use deprecated
962            layer instance variables
963    
964    2003-06-16  Jonathan Coles   <[email protected]>
965    
966            Fix a problem under Windows whereby if the user double-clicks on a
967            layer in the legend that tree item will expand or collapse as well
968            as open the layer properties dialog. The state of the tree item
969            should not be affected.
970    
971            * Thuban/UI/legend.py (LegendTree.__init__): Add instance variable
972            preventExpandCollapse and subscribe to expanding and collapsing
973            events.
974            (LegendTree.OnItemExpandCollapse): New. Responds to expanding and
975            collapsing events and will veto the event if it has been triggered
976            by the user double clicking on a layer.
977            (LegendTree._OnItemActivated): Set preventExpandCollapse to indicate
978            that an expanding/collapsing event should be vetoed.
979    
980    2003-06-13  Bernhard Herzog  <[email protected]>
981    
982            * Thuban/UI/classifier.py (Classifier.OnClose)
983            (Classifier.map_layers_removed)
984            (Classifier.layer_shapestore_replaced): Unsubscribe the messages
985            in OnClose and not in map_layers_removed or
986            layer_shapestore_replaced to make sure it always happens when the
987            dialog is closed
988    
989    2003-06-13  Jonathan Coles   <[email protected]>
990    
991            This puts back a fix for Windows where a panel is needed so that
992            the background of the table view appears correctly.
993    
994            * Thuban/UI/tableview.py (TableFrame.__init__): Add a panel
995            object that can be used by derived classes to place any
996            controls (including the grid) onto.
997            (QueryTableFrame.__init__): Use the panel as the parent window
998            for all the controls. Reparent the grid so that the panel is
999            the parent. Call UpdateStatusText() to correctly initialize
1000            the status bar.
1001    
1002    2003-06-13  Jonathan Coles   <[email protected]>
1003    
1004            * Thuban/UI/dialogs.py (ThubanFrame): New: a class that inherits
1005            from wxFrame (as opposed to wxDialog like the other classes)
1006            but otherwise behaves like the other classes. This is needed
1007            for the TableView which isn't really a dialog and needs to
1008            have a status bar and control buttons.
1009    
1010            * Thuban/UI/tableview.py (TableGrid.__init__): Create an
1011            instance variable to keep track of how many rows are selected.
1012            Subscribe once to the the events we are interested in.
1013            (ThubanGrid.OnRangeSelect): Only handle event if event handling
1014            hasn't been turned off.
1015            (ThubanGrid.OnSelectCell): Only handle event if event handling
1016            hasn't been turned off.
1017            (ThubanGrid.ToggleEventListeners): Rather than subscribe None
1018            as an event listener (which changes the event handler stack)
1019            simply set an instance variable to False. This is checked in
1020            the event handlers.
1021            (ThubanGrid.GetNumberSelected): Return the number of currently
1022            selected rows.
1023            (TableFrame): Inherit from ThubanFrame so we can have a
1024            status bar and control buttons.
1025            (QueryTableFrame.__init__): Create a status bar. Fixes RTbug #1942.
1026            Explicitly set which items are selected in the operator choice and
1027            action choice so there is always a valid selection. Fixes RTbug #1941.
1028            Subscribe to grid cell selection events so we can update the
1029            status bar.
1030            (QueryTableFrame.UpdateStatusText): Update the status bar with
1031            how many rows are in the grid, how many columns, and how many
1032            rows are selected.
1033            (QueryTableFrame.OnGridSelectRange, QueryTableFrame.OnGridSelectCell):
1034            Call UpdateStatusText when cells are (de)selected.
1035            (QueryTableFrame.OnQuery): Use the string value in the value
1036            combo if either the selected item index is 0 or if the string
1037            cannot be found in the predefined list (this happens if the
1038            user changes the text). Fixes RTbug #1940.
1039            Only turn off the grid event listeners if there a query comes
1040            back with a none empty list of ids. in the case that the list
1041            is empty this causes a grid.ClearSelection() call to actually
1042            clear the grid selection which causes the selected items in
1043            the map to be deselected. Fixes RTbug #1939.
1044    
1045            * test/test_save.py (XMLWriterTest.Encode): Check return values.
1046            Fixes RTbug #1851.
1047    
1048    2003-06-13  Bernhard Herzog  <[email protected]>
1049    
1050            * Thuban/UI/identifyview.py (IdentifyView.__init__): Call
1051            self.selected_shape with the current selection to make sure the
1052            contents of the dialog are up to date when it's shown for the
1053            first time.
1054            The dialog used to work without this by luck. The recent fix to
1055            the connector module 'broke' a 'feature' the identify view was
1056            relying on, i.e that subscribing to a message in response to
1057            receiving a message of that type would mean that the new
1058            subscriber would also be called for the same message.
1059            
1060    2003-06-12  Jonathan Coles   <[email protected]>
1061    
1062            * extensions/thuban/gdalwarp.cpp: Removed debug printing as
1063            the image is rendered. Fixes RTbug #1937.
1064    
1065  2003-06-12  Jonathan Coles   <[email protected]>  2003-06-12  Jonathan Coles   <[email protected]>
1066    
1067          * Thuban/Lib/fileutil.py: As is done under Windows, create the          * Thuban/Lib/fileutil.py: As is done under Windows, create the
1068          user directory if it doesn't exist on a posix system.          user directory if it doesn't exist on a posix system.
1069            Fixes RTbug #1815.
1070    
1071          * Thuban/Model/resource.py (get_user_proj_files): Moved the          * Thuban/Model/resource.py (get_user_proj_files): Moved the
1072          called to get_application_dir here, so that the directory          called to get_application_dir here, so that the directory

Legend:
Removed from v.1191  
changed lines
  Added in v.1420

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26