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

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

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1442 - (hide annotations)
Wed Jul 16 13:31:05 2003 UTC (21 years, 7 months ago) by jonathan
Original Path: trunk/thuban/ChangeLog
File size: 226511 byte(s)
updated ChangeLog

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

Properties

Name Value
svn:eol-style native
svn:keywords Author Date Id Revision

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26