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

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

Parent Directory Parent Directory | Revision Log Revision Log


Revision 2712 - (hide annotations)
Sun Oct 15 23:27:05 2006 UTC (18 years, 4 months ago) by bernhard
Original Path: trunk/thuban/ChangeLog
File size: 475007 byte(s)
* Thuban/UI/renderer.py: Added module variable verbose and
added verbose output before doing a raster projection.
Minor: Added (c) year 2006.

* test/test_baserenderer.py: Added new function
test_projected_raster_decimalcommalocale()
Added new author Bernhard Reiter and new copyright year 2006.

* libraries/thuban/gdalwarp.cpp(ProjectRasterFile): Adding
switching to LC_NUMERIC "C" and back before calling GDAL functions -
only #if python >=2.4 .

1 bernhard 2712 2006-10-15 Bernhard Reiter <[email protected]>
2    
3     * Thuban/UI/renderer.py: Added module variable verbose and
4     added verbose output before doing a raster projection.
5     Minor: Added (c) year 2006.
6    
7     * test/test_baserenderer.py: Added new function
8     test_projected_raster_decimalcommalocale()
9     Added new author Bernhard Reiter and new copyright year 2006.
10    
11     * libraries/thuban/gdalwarp.cpp(ProjectRasterFile): Adding
12     switching to LC_NUMERIC "C" and back before calling GDAL functions -
13     only #if python >=2.4 .
14    
15 dpinte 2710 2006-10-10 Didrik Pinte <[email protected]>
16 dpinte 2711
17     Win32 build updates
18    
19     * setup.py :
20     - update to the latest libs for win32 setup tasks
21     - added gdal and Lib content to the inno setup build task
22     - added stable and experimental extensions to setup packages
23    
24     * thuban.py :
25     - gdal support for win32 inno installation
26    
27     2006-10-10 Didrik Pinte <[email protected]>
28    
29 dpinte 2710 * Thuban/Model/layer.py (Layer.GetLabelPosFromShape): new method
30     extracted from Thuban/UI/viewport.py
31     * Thuban/UI/viewport.py (Viewport.LabelShapeAt): uses new method
32    
33 dpinte 2709 2006-09-28 Didrik Pinte <[email protected]>
34    
35     * Thuban/UI/classgen.py: bugfix due to wx2.6 update
36    
37     * Thuban/UI/view.py: removed non needed declaration
38    
39     * Thuban/UI/selection.py : typo correction
40    
41 bernhard 2705 2006-09-24 Bernhard Reiter <[email protected]>
42    
43 bernhard 2708 * Thuban/Model/proj.py(_do_we_have_to_work_around_broken_proj):
44     Making the test more robust for observed python 2.3 problems
45     with setlocale().
46    
47 bernhard 2705 * test/runtests.py: Added new option ---setdecimalcommalocale
48 bernhard 2712 to run all tests with an LC_NUMERIC that uses comma as decimal_point.
49 bernhard 2705 Minor: Added (c) year 2006. Fixed typo in a docstring.
50    
51     * test/test_transientdb.py: Minor: Added (c) year 2006. Fixed typo in
52     a docstring.
53    
54 bernhard 2702 2006-09-23 Bernhard Reiter <[email protected]>
55    
56     * Extensions/ogr/test/test_OGRShapestore.py: fixed skip_if_no_ogr()
57     and added it to TestOGRTable.setUp() so that all tests get skipped
58     if ogr cannot be imported. Added (c) year 2006.
59    
60 dpinte 2701 2006-09-18 Didrik Pinte <[email protected]>
61    
62     * wxPython 2.6 update : wx 2.4 syntax has been updated to 2.6
63    
64 bernhard 2696 2006-09-18 Bernhard Reiter <[email protected]>
65    
66 bernhard 2698 Fixed proj behaviour with python >=2.4 when decimal_point != '.'.
67    
68 bernhard 2697 * Thuban/UI/application.py: Fixed warning dialog when gdal is missing.
69    
70     * test/test_proj.py: new test_lc_numeric_robustness(). Added author
71     Bernhard Reiter and new copyright year 2006.
72    
73 bernhard 2698 * Thuban/Model/proj.py: New _do_we_have_to_work_around_broken_proj()
74     and Projection.assuregoodlocale(), Projection.assureinitlocale().
75     Added author Bernhard Reiter and (c) 2006.
76    
77 bernhard 2694 2006-09-15 Bernhard Reiter <[email protected]>
78 bernhard 2692
79     * README: added RXP and pyRXP as optional for tests.
80 bernhard 2697
81 bernhard 2694 * test/localessupport.py: New. Contains a helper function
82     to find a locale with comma used as decimal_point.
83 bernhard 2692
84 bernhard 2690 2006-08-31 Bernhard Reiter <[email protected]>
85 bernhard 2691
86 bernhard 2690 * README: fixed URLs to sqlite and pysqlite.
87 bernhard 2697
88 bernhard 2691 * Thuban/UI/about.py: Added Didrik Pinte as contributor. Extended
89     copyright range to include 2006.
90 bernhard 2690
91 dpinte 2689 2006-06-29 Didrik Pinte <[email protected]>
92    
93     * Thuban/UI/main.py: circular import fix.
94    
95 frank 2688 2006-06-27 Frank Koormann <[email protected]>
96    
97     New Classification "Pattern": Classify text attributes by regexp.
98    
99     * Thuban/Model/classification.py (class ClassGroupPattern):
100     New, group is associated with a regular expression.
101     (Classification._compile_classification): Store compiled regexp and
102     original group for pattern.
103     (Classification.FindGroup): Added pattern.
104    
105     * Thuban/UI/classifier.py
106     (ClassGrid._OnLabelRightClicked, ClassGrid.labelPopup):
107     New, add popup to select singleton/pattern.
108     (ClassTable.GetRowLabelValue, ClassTable.GetValueAsCustom,
109     ClassTable.SetValueAsCustom): Added pattern.
110     (ClassTable.__ParseInput): Autodetect singleton/pattern.
111    
112     * Thuban/Model/save.py (SessionSaver.write_classification):
113     Added pattern.
114    
115     * Thuban/Model/load.py (SessionLoader.start_clpattern,
116     SessionLoader.end_clpattern): New, process pattern elements.
117    
118     * test/test_classification.py (class TestClassGroupPattern): New.
119     (TestClassification.test_add_pattern,
120     TestClassification.test_multiple_groups_textual,
121     TestClassification.test_deepcopy_textual): New.
122     (TestClassification.test_multiple_groups_numerical):
123     Renamed test_multiple_groups.
124     (TestClassification.test_deepcopy_numerical): Renamed test_deepcopy.
125    
126     * test/test_save.py (SaveSessionTest.testClassifiedLayer):
127     Added pattern.
128    
129     * test/test_load.py (ClassificationTest.TestLayers, TestClassification):
130     Added pattern.
131    
132     * test/test_layer.py
133     (TestLayerModification.test_set_classification_textual): New
134     (TestLayerModification.test_set_classification_numerical):
135     Renamed test_set_classification.
136    
137     * Doc/manual/thuban-manual.xml: Added pattern to layer classification
138     description.
139    
140     * Resources/XML/thuban-1.1.dtd: Added clpattern element and attribs.
141    
142 dpinte 2687 2006-06-29 Didrik Pinte <[email protected]>
143    
144     * Thuban/version.py: Bugfix determination of SQLite, the wright one !
145    
146 dpinte 2685 2006-06-28 Didrik Pinte <[email protected]>
147    
148 dpinte 2686 * packaging/windows/thubanstart.py: sample file loading all the stable
149     extensions
150    
151     2006-06-28 Didrik Pinte <[email protected]>
152    
153 dpinte 2685 * Thuban/version.py: Bugfix determination of SQLite on old and recent
154     systems (support pysqlite1 and pysqlite2)
155    
156 frank 2684 2006-06-27 Frank Koormann <[email protected]>
157    
158     * Thuban/version.py: Bugfix determination of SQLite on old systems.
159    
160 dpinte 2683 2006-05-17 Didrik Pinte <[email protected]>
161     * Extensions/ogr/__init__.py : updated test for win32 and correct
162     imports
163    
164 dpinte 2680 2006-05-15 Didrik Pinte <[email protected]>
165 dpinte 2682 Ashamed ... still some tabs in the files
166    
167     * Thuban/version.py : tabs removed
168     * Thuban/Model/transientdb.py : tabs removed
169    
170     2006-05-15 Didrik Pinte <[email protected]>
171    
172 dpinte 2681 * Thuban/version.py : coding style correction
173 dpinte 2682 * Thuban/Model/transientdb.py : coding style correction
174 dpinte 2681
175     2006-05-15 Didrik Pinte <[email protected]>
176 dpinte 2682
177 dpinte 2680 * Thuban/version.py : Updated imports to support pysqlite2
178 dpinte 2682
179     * Thuban/Model/transientdb.py : Updated imports to support pysqlite2
180 dpinte 2680 Patched the querying system to support the param style of pysqlite2
181    
182 dpinte 2679 2006-04-24 Didrik Pinte <[email protected]>
183 bernhard 2690 * Extensions/svgexport/__init__.py: The extension now works on win32
184 dpinte 2679 architecture. Bug #87 corrected.
185    
186 bernhard 2678 2006-04-20 Bernhard Reiter <[email protected]>
187     * Doc/technotes/coding_guidelines.txt: Changed text from CVS to SVN.
188     Removed emacs specific hint and replaced it with a general hint
189     that editors might support writing changelogs.
190    
191 bernhard 2677 2006-04-12 Bernhard Reiter <[email protected]>
192 bernhard 2678
193 bernhard 2677 * Thuban/version.py: Changed thuban_release mechanism to use "svn"
194     instead of "cvs".
195    
196 bernhard 2676 2006-03-31 Bernhard Reiter <[email protected]>
197    
198     * libraries/thuban/wxproj.cpp: including proj_api.h instead of
199     projects.h now. According the Frank Warmerdam and man pj_init
200     this is the public interface to proj. Thus I have changed PJ to projPJ.
201     And I could remove the hack to avoid clashes with typedef PVALUE
202     and #define LP in projects.h clashing with symbols when trying to
203     build on windows. The file is cleaner and nicer now.
204    
205 bernhard 2675 2006-03-29 Bernhard Reiter <[email protected]>
206 bernhard 2678
207 bernhard 2675 * libraries/thuban/wxproj.cpp: undef LP to avoid clash when
208     trying to build with mingw.
209    
210 bernhard 2673 2005-10-18 Bernhard Reiter <[email protected]>
211    
212 bernhard 2674 * Thuban/UI/about.py: remove unused import of getdefaultlocale.
213     Added display of internal encoding to the about dialog text.
214    
215     * Extensions/svgexport/__init__.py: changed version to "1.0.0+cvs".
216    
217     2005-10-18 Bernhard Reiter <[email protected]>
218    
219 bernhard 2673 Startup improved: We fail right away if the internal encoding could
220     not be determined.
221    
222     * Thuban/__init__.py (get_internal_encoding): new.
223    
224     * test/test_stringrepresentation.py (class TestInternalEncoding):
225     Preserve the internal encoding for the tests in this class.
226    
227 bernhard 2671 2005-10-17 Bernhard Reiter <[email protected]>
228    
229 bernhard 2672 * test/test_stringrepresentation.py: New file, for now testing
230     that set_internal_coding() is throwing an exception for bad exceptions.
231    
232     * Thuban/__init__.py (set_internal_encoding): added a forwards
233     and backward translation, so that we fail early if the
234     internal_encoding is bad.
235    
236     2005-10-17 Bernhard Reiter <[email protected]>
237    
238 bernhard 2671 svgexport 1.0.0cvs: Fixed ARC layer writing: No filling is done.
239     You could actually get polylines with filling in between,
240     when the classification for the lines had a fill color.
241     E.g. this happens when you generate a classification from a ramp.
242    
243     * Extensions/svgexport/test/test_svgmapwriter.py:
244     New test_export_arc_no_fill(). Extend copyright notice to 2005.
245    
246     * Extensions/svgexport/svgmapwriter.py
247     (SVGRenderer.draw_shape_layer_incrementally()):
248     Setting TRANSPARENT_BRUSH for shaptype ARC.
249     Extend copyright notice to 2005.
250    
251     * Extensions/svgexport/__init__.py: Extend copyright notice to 2005.
252    
253 frank 2670 2005-09-08 Frank Koormann <[email protected]>
254    
255     * Doc/manual/thuban-manual.xml (Map Management): Fixed typo reported
256     by Erik (sigra.at.home.se)
257    
258 jan 2669 2005-08-18 Jan-Oliver Wagner <[email protected]>
259    
260     * Thuban/UI/renderer.py (ScreenRenderer.draw_selection_incrementally):
261     Call the right method for the default size.
262    
263 jan 2667 2005-08-11 Jan-Oliver Wagner <[email protected]>
264    
265     * Extensions/export_shapefile: New.
266    
267     * Extensions/export_shapefile/__init__.py: New. Initialize
268     the export_shapefile extension.
269    
270     * Extensions/export_shapefile/export_shapefile.py: New.
271     Exports a layer as a Shapefile.
272    
273 jan 2664 2005-08-08 Jan-Oliver Wagner <[email protected]>
274    
275     * po/de.po: String fixes. This fixes Debian bug #313843.
276    
277 jan 2660 2005-07-27 Jan-Oliver Wagner <[email protected]>
278    
279     Remove the attributes from the layer element in
280     .thuban files for the save routine.
281     This also solves RT bug #3149,
282     https://intevation.de/rt/webrt?serial_num=3149
283    
284     * test/test_load.py: (TestSingleLayer, TestNonAsciiColumnName,
285     TestLayerVisibility, TestSymbolSize, TestClassification, TestLabels,
286     TestLayerProjection, TestJoinedTable, TestLabelLayer): Removed
287     attributes from layer element to classification clnull element.
288    
289     * test/test_save.py (SaveSessionTest.testSingleLayer,
290     SaveSessionTest.testLayerProjection,
291     SaveSessionTest.testClassifiedLayer,
292     SaveSessionTest.test_joined_table, SaveSessionTest.test_save_postgis):
293     Removed attributes from layer element to classification clnull element.
294     (test_save_postgis.NonConnectionStore._fetch_table_information):
295     added pretending to have a shape_type.
296    
297     * Resources/XML/thuban-1.1.dtd: Make the attributes field
298     and field_type of classification optional.
299    
300     * Thuban/Model/classification.py (Classification.TreeItem.build_info):
301     Added output of size.
302    
303     * Thuban/Model/load.py (SessionLoader.start_classification):
304     Change attribute 'field' and 'field_type' from obligatory to
305     optional to allow empty classes (ie. only with a default=clnull).
306    
307     * Thuban/Model/save.py (SessionSaver.write_layer): Don't write
308     any attributes anymore for the layer element.
309     (SessionSaver.write_classification): Even if there is no
310     classification field, still write the classification because
311     the clnull (default) symbol will not be defined anymore as
312     part of the layer element.
313    
314 bh 2643 2005-07-05 Bernhard Herzog <[email protected]>
315    
316 bh 2652 * setup.py (setup call): Version 1.1.0
317    
318     * NEWS: Update for 1.1.0
319    
320     * MANIFEST.in: Add *.txt to files taken from Doc. Otherwise the
321     technores won't be included
322    
323     * Thuban/UI/about.py (About.__init__): Extend copyright notice to
324     2005
325    
326     * po/de.po: Updated.
327    
328     2005-07-05 Bernhard Herzog <[email protected]>
329    
330 bh 2645 * README: gdal 1.1.8 is too old. 1.2.5 works.
331    
332     2005-07-05 Bernhard Herzog <[email protected]>
333    
334 bh 2650 * Resources/XML/thuban-1.1.dtd (rasterlayer): Add the opacity and
335     masktype attributes.
336    
337     2005-07-05 Bernhard Herzog <[email protected]>
338    
339 bh 2644 * Thuban/Model/layer.py (Layer.__mangle_bounding_box)
340     (Layer.ClipBoundingBox): Rename ClipBoundingBox to
341     __mangle_bounding_box. See the comments in the code and RT #2845
342    
343     * test/test_layer.py (TestLayer.test_arc_layer_with_projection):
344     Remove the explicit test of ClipBoundingBox. The method isn't
345     public anymore and the direct call in the test wasn't necessary in
346     the first place. If ClipBoundingBox (now __mangle_bounding_box)
347     isn't called, the return value of ShapesInRegion will be
348     different.
349    
350     2005-07-05 Bernhard Herzog <[email protected]>
351    
352 bh 2643 * Thuban/UI/viewport.py (ViewPort.set_view_transform): Handle
353     ZeroDivisionError exceptions. I don't know when they happen
354     exactly. It probably happens when the projections aren't set
355     properly.
356    
357 bh 2642 2005-07-01 Bernhard Herzog <[email protected]>
358    
359     First step towards unicode. With this roughly we're at step 1
360     string_representation.txt
361    
362     * Doc/technotes/string_representation.txt: New. Document how
363     strings are represented in Thuban and how to get to a Unicode
364     Thuban.
365    
366     * Thuban/__init__.py (set_internal_encoding)
367     (unicode_from_internal, internal_from_unicode): New. The first few
368     functions for the internal string representation
369    
370     * Thuban/UI/about.py (unicodeToLocale): Removed. Use
371     internal_from_unicode instead.
372    
373     * Thuban/UI/__init__.py (install_wx_translation): Determine the
374     encoding to use for the internal string representation. Also,
375     change the translation function to return strings in internal
376     representation even on unicode builds of wxPython
377    
378     * Thuban/Model/load.py (SessionLoader.check_attrs): Decode
379     filenames too.
380     (SessionLoader.start_clrange): Use check_attrs to decode and check
381     the attributes.
382    
383     * Thuban/Model/xmlreader.py (XMLReader.encode): Use
384     internal_from_unicode to convert unicode strings.
385    
386     * Thuban/Model/xmlwriter.py (XMLWriter.encode): Use
387     unicode_from_internal when applicable
388    
389     * test/runtests.py (main): New command line option:
390     internal-encoding to specify the internal string encoding to use
391     in the tests.
392    
393     * test/support.py (initthuban): Set the internal encoding to
394     latin-1
395    
396     * test/test_load.py (TestSingleLayer.test, TestClassification.test)
397     (TestLabelLayer.test): Use the internal string representation when
398     dealing with non-ascii characters
399    
400     * test/test_load_1_0.py (TestSingleLayer.test)
401     (TestClassification.test, TestLabelLayer.test): Use the internal
402     string representation when dealing with non-ascii characters
403    
404     * test/test_load_0_9.py (TestSingleLayer.test)
405     (TestClassification.test): Use the internal string representation
406     when dealing with non-ascii characters
407    
408     * test/test_load_0_8.py (TestUnicodeStrings.test): Use the
409     internal string representation when dealing with non-ascii
410     characters
411    
412     * test/test_save.py (XMLWriterTest.testEncode)
413     (SaveSessionTest.testClassifiedLayer): Use the internal string
414     representation when dealing with non-ascii characters where
415     applicable
416    
417 bh 2638 2005-06-30 Bernhard Herzog <[email protected]>
418    
419 bh 2641 * test/runtests.py: Untabify.
420    
421     2005-06-30 Bernhard Herzog <[email protected]>
422    
423 bh 2639 * Thuban/UI/renderer.py (ScreenRenderer.draw_selection_incrementally):
424     untabify.
425    
426     2005-06-30 Bernhard Herzog <[email protected]>
427    
428 bh 2638 * Extensions/ogr/test/__init__.py: Add missing coding directive
429    
430 jan 2631 2005-06-28 Jan-Oliver Wagner <[email protected]>
431    
432 jan 2636 * Thuban/UI/renderer.py (ScreenRenderer.draw_selection_incrementally):
433     Use the default size for rendering selected items of default type.
434     Fixes part 2 of https://intevation.de/rt/webrt?serial_num=3149
435    
436     2005-06-28 Jan-Oliver Wagner <[email protected]>
437    
438 jan 2631 * Extensions/importAPR/apr.py (APR_BShSym): Extend by 'Stripple'.
439     (APR_TClr.GetThubanColor): Fix bug in color interpretation.
440     Thanks to Frank Koormann who identified this problem.
441    
442     * Extensions/importAPR/importAPR.py (APR_VShSym): New. Just
443     another symbol identified.
444    
445 jan 2628 2005-06-27 Jan-Oliver Wagner <[email protected]>
446    
447     * Doc/manual/thuban-manual-de.xml: More translations.
448    
449 jonathan 2626 2005-05-12 Jonathan Coles <[email protected]>
450    
451     * Thuban/UI/projdialog.py: Add missing import, which led to an
452     exception when opening a layer's projection.
453    
454 bh 2623 2005-05-09 Bernhard Herzog <[email protected]>
455    
456 bh 2624 * test/support.py (FileLoadTestCase.filename): Fix doc-string.
457    
458     2005-05-09 Bernhard Herzog <[email protected]>
459    
460 bh 2623 * Thuban/Model/postgisdb.py (PostGISConnection.connect): Set the
461     connection to autoconnect. Fixes RT#3148.
462    
463     * test/test_postgis_db.py
464     (TestPostGISSpecialCases.test_simple_error_handling): New test
465     that attempts to reproduce RT#3148.
466    
467 jonathan 2622 2005-05-06 Jonathan Coles <[email protected]>
468    
469     Add support for saving and loading the opacity and mask type
470     properties of RasterLayers. Also add support for proper use
471     of alpha information while drawing images not in 'RAW' format.
472     If transparency in an image format (e.g, PNG) is supported by
473     wxWidgets then the image would previously have been draw with
474     transparent regions, but the opaque regions would have been
475     unaffected by a change in the layer's opacity. This patch
476     corrects the problem.
477    
478     * Thuban/Model/layer.py (RasterLayer): Added opacity and
479     masktype parameters to the constructor, and set the
480     appropriate variables to those values.
481    
482     * Thuban/Model/load.py (SessionLoader.start_rasterlayer): Added
483     code to read the opacity and mask type of the layer and construct
484     a new layer with the additional parameters.
485    
486     * Thuban/Model/save.py (SessionSaver.write_layer): Added code
487     to save the opacity and mask type of a layer.
488    
489     * Thuban/UI/baserenderer.py (BaseRenderer.draw_raster_layer): Pass
490     the opacity of the layer to draw_raster_data rather than the layer.
491     (BaseRenderer.draw_raster_data): Remove the layer parameter because
492     the function doesn't need to know about the layer. Add the optional
493     opacity parameter whose default is 1.0. Add 'PNG' as a supported
494     graphics format.
495    
496     * Thuban/UI/renderer.py (MapRenderer.draw_raster_data): Fixed
497     signature to match that in BaseRenderer. Use the new opacity argument
498     in place of calling layer.Opacity(). In the case where the
499     format is not 'RAW', alpha_data is None and the loaded image has
500     alpha information, use the file's alpha information. This is
501     still subject to the layer's opacity setting.
502    
503     * test/test_baserenderer.py (SimpleRenderer.draw_raster_data):
504     Fixed signature to match that in BaseRenderer.
505    
506     * test/test_load.py (TestRasterLayer): Change file_contents to
507     include opacity and masktype variables.
508     (TestRasterLayer.test): Include tests for opacity and masktype
509     changes.
510    
511     * test/test_save.py (SaveSessionTest.testRasterLayer): Restructure
512     test to cover a variety of combinations of masktype and opacity
513     settings.
514    
515 jan 2612 2005-05-02 Jan-Oliver Wagner <[email protected]>
516    
517     * debian/rules: add --use-wx-python-swig-hack
518     to the build command.
519     Thanks to Moritz Lennert for pointing this out.
520    
521 jan 2610 2005-04-28 Jan-Oliver Wagner <[email protected]>
522    
523     Introduce OGRFileShapeStore in ogr extension.
524     This allows at least that loaded shapefile shape stores
525     can be saved correctly in the thuban session file
526     and reloaded again (reload is via core shapefile
527     routine, not OGR). For other types, .thuban files
528     can not be reloaded for the time being.
529    
530     * Extensions/ogr/ogrshapes.py (OGRFileShapeStore): New. This
531     class ist to be used for any file-based shape stores
532     accessed through OGR.
533    
534     * Extensions/ogr/ogrstart.py (open_with_ogr): Added
535     forgotten _ for i18n. Adapted call OpenFileShapestore
536     regarding new parameter.
537     (OpenFileShapestore): Use OGRFileShapeStore instead of
538     OGRShapeStore. Fix return value (None instead of null).
539     Add new parameter "mainwindow" to avoid accessing global
540     context.
541    
542 jan 2607 2005-04-27 Jan-Oliver Wagner <[email protected]>
543    
544     Introduce FileShapeStore as generalization for
545     file-based shape stores. In a first instance
546     this allows additional modules to handle shapefile
547     format as well, namely the OGR extension.
548    
549     * Thuban/Model/data.py: Various small fixes in doc-strings.
550     (FileShapeStore): New class.
551     (ShapefileStore): Derive from FileShapeStore.
552     (ShapefileStore.__init__): Call __init__ of FileShapeStore,
553     rename self.table to self._table, initialize self._bbox
554     (ShapefileStore._open_shapefile): Use self._bbox instead of self.bbox
555     and self.FileName() instead of self.filename.
556     (ShapefileStore.Table): Use self._table instead of self.table.
557     (ShapefileStore.FileName): Removed (moved to FileShapeStore).
558     (ShapefileStore.BoundingBox): Use self._bbox instead of self.bbox.
559    
560     * Thuban/Model/save.py: Replace ShapefileStore by FileShapeStore.
561     (SessionSaver.write_data_containers): Only use methods of the
562     base class FileShapeStore.
563    
564 joey 2604 2005-04-26 Martin Schulze <[email protected]>
565    
566     * Extensions/wms/wms.py (render_wms_layer): Adjusted the render
567     function to the modified render engine
568    
569     2005-04-25 Martin Schulze <[email protected]>
570    
571     * Thuban/UI/renderer.py (MapRenderer.projected_raster_layer):
572     Added a description according to the CVS log message
573    
574     2005-04-23 Martin Schulze <[email protected]>
575    
576     * Thuban/UI/renderer.py: Added a missing import
577    
578 russell 2600 2005-04-23 Russell Nelson <[email protected]>
579    
580 russell 2613 * Thuban/UI/view.py (MapCanvas.OnMiddle{Up,Down}): Changed the
581     way the previous tool is remembered, so that middle-button
582     panning works even if you haven't selected a tool.
583 russell 2600
584 bh 2598 2005-04-11 Bernhard Herzog <[email protected]>
585    
586     * libraries/thuban/wxproj.cpp: Move the compatibility code that
587     deals with the wxPython 2.4 version of wxPython.h into the #ifdef
588     branch that includes wxPython.h because it's only needed when
589     wxPython.h is used. Also, it won't compile when
590     USE_WX_PYTHON_SWIG_HACK is set otherwise.
591    
592 bh 2597 2005-04-07 Bernhard Herzog <[email protected]>
593    
594     * Thuban/UI/classifier.py (ClassGrid.__init__): Use -1 as the ID.
595     (ID_CLASS_TABLE): Removed. It wasn't used anywhere except in
596     ClassGrid.__init__ and it's value is outside of the valid
597     range (must be < 32768). wxPython 2.5 complains about it with an
598     exception.
599    
600 jan 2596 2005-04-05 Jan-Oliver Wagner <[email protected]>
601    
602     * Doc/manual/thuban-manual-de.xml: More translations.
603    
604 bh 2590 2005-04-05 Bernhard Herzog <[email protected]>
605    
606 bh 2591 * libraries/thuban/wxproj.cpp: Make it work with a wxPython.h from
607     wxPython 2.4 as well. Also, remove a now obsolete comment.
608    
609     2005-04-05 Bernhard Herzog <[email protected]>
610    
611 bh 2590 Use wxPython.h by default but provide a workaround when it isn't
612     available.
613    
614     * setup.py (wxproj_extension): New variable. Assign the Extension
615     instance for Lib.wxproj to this variable instead of putting it
616     directly into the listso that it can be accessed by other code
617     later.
618     (thuban_build_ext.user_options): Added boolean option
619     --use-wx-python-swig-hack.
620     (thuban_build_ext.initialize_options): Initialize the new option
621     to False.
622     (thuban_build_ext.finalize_options): If the new option was given,
623     define the preprocesser macro USE_WX_PYTHON_SWIG_HACK.
624     (thuban_build_ext): Update the doc-string
625    
626     * libraries/thuban/wxproj.cpp: Normally we use
627     wx/wxPython/wxPython.h now. Only if USE_WX_PYTHON_SWIG_HACK is
628     defined, use swigPtrConvertHack.h instead.
629    
630     * libraries/thuban/swigPtrConvertHack.h: Remove the code that was
631     copied over from wxPython.h.
632     (decode_pointer_new): New. Equivalent of decode_pointer for
633     wxPython 2.5.
634     (wxPyConvertSwigPtr): Modified to cope with wxPython 2.5 as well.
635    
636     * README: Add section on potential build problems which explains
637     how the work-around for a missing wxPython.h is activated.
638    
639 bh 2588 2005-03-29 Bernhard Herzog <[email protected]>
640    
641 bh 2589 * test/postgissupport.py (find_postgis_sql): Added yet another
642     potential location for (lw)postgis.sql because the file has moved
643     again in postgis 1.0.0 rc4.
644    
645     2005-03-29 Bernhard Herzog <[email protected]>
646    
647 bh 2588 * Thuban/UI/legend.py (BMP_SIZE_W, BMP_SIZE_H): Set both to 16 to
648     match the site of the legend_icon_layer icon. Otherwise wxpython
649     2.5 complains when the legend is created with the error:
650    
651     PyAssertionError: C++ assertion "(bitmap.GetWidth() == m_width &&
652     bitmap.GetHeight() == m_height) || (m_width == 0 && m_height ==
653     0)" failed in ./src/generic/imaglist.cpp(81): invalid bitmap size
654     in wxImageList: this might work on this platform but definitely
655     won't under Windows.
656    
657 jonathan 2587 2005-03-23 Jonathan Coles <[email protected]>
658    
659     These changes add support for adjusting the opacity of a raster layer.
660    
661     * Thuban/Model/layer.py (RasterLayer.Opacity): Replaces AlphaOpacity.
662     (RasterLayer.SetOpacity): Replaces SetAlphaOpacity. Also triggers
663     a LAYER_CHANGED event if the opacity actually changes.
664    
665     * Thuban/UI/baserenderer.py (BaseRenderer.draw_raster_data): Added
666     layer parameter needed in the implementation of this method in
667     renderer.py.
668    
669     * Thuban/UI/layerproperties.py (LayerProperties.dialog_layout): Fixed
670     typo 00 -> 0.
671    
672     * Thuban/UI/rasterlayerproperties.py (RasterLayerProperties): Added
673     control to adjust opacity.
674    
675     * Thuban/UI/renderer.py (MapRenderer.draw_raster_data): Scale the
676     alpha data based on the opacity level of the layer.
677    
678     * test/test_baserenderer.py (SimpleRenderer.draw_raster_data): Now
679     accepts a layer parameter.
680    
681     * test/test_layer.py (TestLayerModification.test_raster_layer):
682     Rename opacity method calls and add test for LAYER_CHANGED.
683    
684 bh 2586 2005-03-16 Bernhard Herzog <[email protected]>
685    
686     * test/test_connector.py (DeletionTestMixin.check_deletions)
687     (DeletionTestMixin.check_deletetions): renamed to check_deletions.
688     update the callers.
689    
690 jan 2585 2005-03-14 Jan-Oliver Wagner <[email protected]>
691    
692     * Doc/manual/thuban-manual-de.xml: More translations.
693    
694 jan 2584 2005-03-10 Jan-Oliver Wagner <[email protected]>
695    
696     Introducing initialization callbacks for extensions.
697    
698     * Thuban/UI/extensionregistry.py (ExtensionDesc.__init__): Added
699     optional parameter init_callback.
700     (ExtensionDesc.init_ext): New. Executes the callback and sets
701     a status.
702    
703     * Thuban/UI/application.py (ThubanApplication.OnInit): Add the
704     initialization of the extensions.
705     (ThubanApplication.init_extensions): Init all extensions.
706    
707     * Thuban/UI/about.py (About.__init__): Added status of the extensions
708     to the about text.
709    
710     * Extensions/gns2shp/__init__.py: Added init method for Extension
711     description.
712     (init): New. Contains the initialization of the module.
713    
714 nhueffme 2577 2005-03-04 Nina Hüffmeyer <[email protected]>
715    
716     * Extensions/ogr/ogrdialog.py: Added a dialog, which asks for
717     OGRConnection to open a datasource. Removed dialog to display all
718     available drivers. Added some doc strings.
719    
720     * Extensions/ogr/ogrstart.py: Added menu entry for opening an
721     OGRDatasource with a string. Added two opening methods which return an
722     OGRDatasource (either data from file or from DB).
723    
724     * Extensions/ogr/ogrshapes.py: Added class OGRGeometry, which
725     represents a geometry reference of an OGRFeature. OGRShape now has a
726     list of referenced geometry objects (important for geometry
727     collections).
728     For OGRShapeStores loaded from a DB an ID column can be specified now.
729    
730 jan 2576 2005-02-22 Jan-Oliver Wagner <[email protected]>
731    
732     * test/test_map.py (TestMapWithContents.test_tree_info):
733     Added label layer for comparison.
734    
735 jonathan 2574 2005-02-18 Jonathan Coles <[email protected]>
736    
737     * libraries/thuban/gdalwarp.cpp (GetImageData): Optimize the loop
738     which builds a mask. Handle the majority of an image in a loop,
739     creating 8 bits at a time. Later, handle the edge case where less
740     than 8 bits are packed.
741    
742 bh 2573 2005-02-18 Bernhard Herzog <[email protected]>
743    
744     * test/test_baserenderer.py (TestBaseRenderer.setUp): Fix
745     doc-string
746    
747 jonathan 2571 2005-02-18 Jonathan Coles <[email protected]>
748    
749 jonathan 2572 * setup.py: Remove wx_cs_params from gdal compile options.
750    
751     2005-02-18 Jonathan Coles <[email protected]>
752    
753 jonathan 2571 Refactored baserenderer.py and renderer.py to remove baserenderer.py's
754     dependencies on wxPython. Added a new method projected_raster_layer()
755     that returns a raster layer image in projected space. This must be
756     implemented in classes derived from BaseRenderer. This also eliminates
757     the dependency on gdal in baserenderer.py.
758    
759     * Thuban/UI/baserenderer.py (BaseRenderer.draw_raster_layer): Call
760     new projected_raster_layer() to get projected raster image instead
761     of directly calling ProjectRasterFile().
762     (BaseRenderer.projected_raster_layer): New. This must be implemented
763     by derived classes. It takes almost the same arguments as ProjectRasterFile
764     did and returns a projected image with mask and alpha data (if requested).
765     (BaseRenderer.render_map_incrementally): Remove the check for gdal since
766     that check will be done in MapRenderer.projected_raster_layer(). This
767     also allows other implementations to use different projection code.
768    
769     * Thuban/UI/renderer.py (MapRenderer.projected_raster_layer):
770     Implementation of BaseRenderer.projected_raster_layer. Checks for
771     gdal support and wxPython version. Also handles exceptions from
772     ProjectRasterFile.
773    
774     * libraries/thuban/gdalwarp.cpp: Removed checks for wxPython versions
775     and added a variable which can be set through the options argument
776     of ProjectRasterFile.
777    
778     * test/test_baserenderer.py (SimpleRenderer.projected_raster_layer): New.
779     Calls ProjectRasterFile and returns the result.
780     (TestBaseRenderer.test_projected_raster_layer): New. Tests the results
781     of calling projected_raster_layer() with different options.
782     (TestBaseRenderer.test_raster_no_projection): Removed tests based on
783     wxPython version and all tests of masks and alpha channels. These are
784     now in test_projected_raster_layer().
785    
786 jan 2565 2005-02-17 Jan-Oliver Wagner <[email protected]>
787    
788 jan 2570 * Thuban/Model/map.py, Thuban/Model/label.py: Fixed
789     doc-strings to comply with coding_guidelines.
790    
791     2005-02-17 Jan-Oliver Wagner <[email protected]>
792    
793 jan 2565 Docstring improvements and minor fixes for labellayer.
794    
795     * Thuban/Model/map.py:
796     (Map, Map.Destroy, Map.RemoveLayer, Map.ClearLayers,
797     Map.Layers, Map.HasLayers, Map.MoveLayerToTop,
798     Map.RaiseLayer, Map.LowerLayer, Map.MoveLayerToBottom,
799     Map.ProjectedBoundingBox, Map.GetProjection): Improved/added
800     doc string.
801     (Map.BoundingBox): Removed superfluous test for label_layer
802     and improved doc string.
803     (Map.TreeInfo): Added label_layer and improved sdo string.
804    
805     * Thuban/Model/label.py: Added import of _.
806     (Label, Label.__init__): Improved/added doc string.
807     (LabelLayer, LabelLayer.__init__, LabelLayer.Labels,
808     LabelLayer.RemoveLabel, LabelLayer.ClearLabels):
809     Improved/added doc string.
810     (LabelLayer.AddLabel): Use already defined names for
811     align strings and improved doc string.
812     (LabelLayer.TreeInfo): New. Return the object data for
813     the tree view.
814    
815 jonathan 2562 2005-02-16 Jonathan Coles <[email protected]>
816    
817     Further wxPython 2.5 changes using patches from Daniel Calvelo Aros
818     so that that wxproj doesn't crash. Added GUI support for selecting
819     alpha channel (opacity can't be selected yet).
820    
821     NOTE: If wxPython.h is including in future distribution packages
822     then it will not be necessary to have the files swigPtrConvertHack.h
823     and wxPython_int.h included with Thuban. This is hopefully
824     a temporary workaround.
825    
826     * setup.py (thuban_build_ext.finalize_options): gdalwarp needs
827     access to the macro wxCHECK_VERSION so that it will properly
828     generate a bit mask. There was a problem between wx2.4 and wx2.5
829     that this works around.
830    
831     * Thuban/Model/layer.py (RasterLayer.UseMask): Removed in favor
832     of RasterLayer.MaskType.
833     (RasterLayer.SetUseMask): Removed in favor of RasterLayer.SetMaskType
834     (RasterLayer.MaskType): New. Returns the type of mask to use. Can
835     specify none, a bitmap, or an alpha channel.
836     (RasterLayer.SetMaskType): New. Set what kind of mask to use.
837    
838     * Thuban/UI/baserenderer.py (BaseRenderer.draw_raster_layer):
839     Set the raster warping options for the mask based on the value
840     of RasterLayer.MaskType.
841    
842     * Thuban/UI/legend.py (LegendTree.__FillTreeLayer): Remove
843     deprecated calls to SetItemSelectedImage in favor of SetItemImage
844     with wxTreeItemIcon_Selected.
845    
846     * Thuban/UI/rasterlayerproperties.py: Support selecting to use
847     an alpha channel for the mask.
848    
849     * Thuban/UI/renderer.py (MapRenderer.draw_raster_data): Use alpha
850     data if it is available and an alpha channel is supported under
851     the current version of wxPython.
852    
853     * libraries/thuban/gdalwarp.cpp (GetImageData): Added compiler define
854     to select whether 1's or 0's select the desired portion of an image
855     in the bit mask. wx2.4 has a bug where the documentation is the opposite
856     from behavior.
857     (ProjectRasterFile): Only generate an alpha channel if the version
858     of wxPython is >= 2.5.3.
859    
860     * libraries/thuban/wxproj.cpp: Applied patches from Daniel Calvelo Aros.
861     When wxPython >= 2.5.3 use the special swig functions to decode an
862     object's address.
863    
864     * libraries/thuban/swigPtrConvertHack.h: Includes conditional code
865     based on the version of wxPython. If >= 2.5.3 use the special swig
866     functions from wxPython to decode wxPython objects, otherwise use
867     the old method of retrieving the address from the object __repr__ string.
868    
869     * libraries/thuban/wxPython_int.h: Copied from wxPython source.
870     Unnecessary code was removed to make it smaller.
871    
872     * test/test_baserenderer.py (TestBaseRenderer.test_raster_no_projection):
873     Add tests for returning an alpha channel.
874    
875     * test/test_layer.py (TestLayerModification.test_raster_layer): Fix
876     tests that used removed functions UseMask and SetUseMask
877    
878    
879 bh 2560 2005-02-08 Bernhard Herzog <[email protected]>
880    
881 bh 2561 More wxPython 2.5 changes. This time taken from a patch from
882     Daniel Calvelo Aros.
883    
884     * Thuban/UI/tableview.py (QueryTableFrame.__init__)
885     (QueryTableFrame.__init__): Pass the size of a spacer as a single
886     item.
887    
888     * Thuban/UI/projdialog.py (ProjFrame.build_dialog)
889     (ProjFrame.build_dialog): Pass the size of a spacer as a single
890     item.
891    
892     * Thuban/UI/dbdialog.py (ChooseDBTableDialog.__init__): Pass the
893     size of a spacer as a single item.
894    
895     * Thuban/UI/classifier.py (Classifier.dialog_layout): Pass the
896     size of a spacer as a single item.
897    
898     2005-02-08 Bernhard Herzog <[email protected]>
899    
900 bh 2560 Compatibility with wxPython 2.5. The changes should make it work
901     better with 2.5 while still keeping compatibility with 2.4. There
902     are still problems with 2.5, though.
903    
904     * Thuban/UI/dock.py (DockableWindow.__CreateBorder): Pass the size
905     of a spacer as a single item.
906    
907     * Thuban/UI/classifier.py (ClassGroupPropertiesCtrl): Derive only
908     from wxControl
909    
910     * Thuban/UI/legend.py (LegendTree): When running with wxPython <
911     2.5, add an implementation of the GetFirstChild method that does
912     not require the second parameter.
913     (LegendTree.find_layer, LegendTree._OnMsgMapLayersAdded)
914     (LegendTree._OnMsgMapLayersRemoved, LegendTree.DeleteAllItems)
915     (LegendTree.DeleteChildren, LegendTree.__ShowHideLayer): Do not
916     pass the second parameter to GetFirstChild
917    
918 nhueffme 2559 2005-02-08 Nina Hüffmeyer <[email protected]>
919    
920     * Extensions/ogr/ogrshapes.py: Removed some print commands.
921    
922     * Extensions/ogr/ogrstart.py: Changed the GUI. OGR is no longer an
923     additional menu but appears as a possibility in the menu Map.
924    
925 jonathan 2558 2005-02-07 Jonathan Coles <[email protected]>
926     * libraries/thuban/gdalwarp.cpp: Removed the macros PYTHON_ERR
927     and PYTHON_ERRF since they were no longer necessary.
928    
929 bernhard 2556 2005-02-07 Bernhard Reiter <[email protected]>
930     * Thuban/UI/classifier.py (ClassGrid.DeleteSelectedRows):
931     Enable translation for message string.
932    
933 joey 2555 2005-02-06 Martin Schulze <[email protected]>
934    
935     * Extensions/wms/infodialog.py (wmsInfoDialog.__init__): Adjusted
936     the arguments of the contstructor to fit the global scheme
937    
938 nhueffme 2554 2005-01-31 Nina Hüffmeyer <[email protected]>
939    
940     * Extensions/ogr/ogrdialog.py: Added class ogrdialog.py, which provides
941     some dialogs needed to start ogr.
942    
943     * Extensions/ogr/__init__.py: Changed comments to avoid encoding
944     warnings.
945    
946     * Extensions/ogr/test/test_OGRShapestore.py: Changed comments to avoid
947     encoding warnings.
948    
949 jonathan 2552 2005-01-28 Jonathan Coles <[email protected]>
950    
951 jonathan 2553 * libraries/thuban/gdalwarp.cpp (GetImageData): Recode how the
952     mask is packed into a bit array. It's now slightly faster.
953    
954     2005-01-28 Jonathan Coles <[email protected]>
955    
956 jonathan 2552 * Thuban/Model/layer.py (RasterLayer.__init__): Make use_mask
957     default to true.
958    
959     * Thuban/Model/load.py (SessionLoader.start_rasterlayer): Remove
960     code that loads the state of the layer's use_mask flag. Its
961     usefulness is still being debated.
962    
963     * Thuban/Model/save.py (SessionSaver.write_layer): Remove
964     code that saves the state of the layer's use_mask flag. Its
965     usefulness is still being debated.
966    
967     * Thuban/UI/baserenderer.py (BaseRenderer.draw_raster_layer): Pass
968     options to ProjectRasterFile based on the state of layer.UseMask().
969     Catch more exceptions from ProjectRasterFile so that Thuban doesn't
970     quit is there is a problem projecting.
971     (BaseRenderer.draw_raster_data): Change the documentation to
972     describe the new format (XBM) that the mask data will be in.
973    
974     * Thuban/UI/renderer.py (MapRenderer.draw_raster_data): The mask
975     data is in XBM format when format='RAW' which means it doesn't
976     need to be converted to a wxImage before being used as a mask
977     for a wxBitmap. Assume that if format != 'RAW' that the image
978     data and mask data are in the same format.
979    
980     * libraries/thuban/gdalwarp.cpp (GetImageData): If alpha is enabled
981     and a mask is requested, convert the alpha band to a bit array in
982     XBM format. if an alpha channel is requested, simply return the
983     data in the alpha band. Provide better error handling by returning
984     python error messages (also fixes RT #2947).
985     (ProjectRasterFile): Support multiple mask options, rather than simply
986     a flag indicating that a mask should or should not be used. Provide
987     better error handling by returning python error messages.
988    
989     * test/test_baserenderer.py (TestBaseRenderer.test_raster_no_projection):
990     Add mask data to test.
991    
992     * test/test_layer.py (TestLayer.test_raster_layer): Test that a layer
993     should use the mask by default.
994     (TestLayerModificaton.test_raster_layer): Test that a layer should use
995     the mask by default.
996    
997     * test/test_load.py (TestRasterLayer.test): Remove testing for
998     use_mask flag in file.
999    
1000     * test/test_save.py (SaveSessionTest.testRasterLayer): Remove testing
1001     for use_mask in file.
1002    
1003     * test/test_load_1_0_1.py: Removed. Shouldn't have been checked in.
1004    
1005 jonathan 2551 2005-01-26 Jonathan Coles <[email protected]>
1006    
1007     Add a new dialog box for raster layers. The dialog box allows
1008     the user to toggle a mask that is generated by ProjectRasterFile
1009     and is used to only draw the real parts of the projected image.
1010    
1011     * Thuban/UI/baserenderer.py (BaseRenderer.draw_raster_layer):
1012     Instruct the warping code to generate a mask if the raster layer
1013     requests one.
1014     (BaseRenderer.draw_raster_data): Removed obsolete optional mask argument.
1015    
1016     * Thuban/UI/renderer.py (MapRenderer.draw_raster_data): Removed
1017     obsolete optional mask argument.
1018    
1019     * Thuban/UI/classifier.py (Classifier): Change the parent class
1020     to LayerProperties and rework the code to support layout calls
1021     from the parent.
1022     (Classifier.dialog_layout): New. Layout the dialog box.
1023     (Classifier.map_layers_removed): Removed. Moved to parent class.
1024     (Classifier.map_replaced): Removed. Moved to parent class.
1025     (Classifier._OnTry): Renamed to OnTry to support parent class.
1026     (Classifier.OnClose): Removed. Supplied in parent class.
1027     (Classifier._OnCloseBtn): Removed. Supplied in parent class as OnCloseBtn.
1028     (Classifier._OnOK): Renamed to OnOK to support parent class.
1029     (Classifier._OnRevert): Renamed to OnRevert to support parent class.
1030    
1031     * Thuban/UI/layerproperties.py: New. Base class for layer properties
1032     dialog boxes.
1033    
1034     * Thuban/UI/rasterlayerproperties.py: New. Class for displaying
1035     raster layer properties.
1036    
1037     * libraries/thuban/gdalwarp.cpp: Replace the old gdalwarp.cpp code
1038     with the non-simple version supplied with gdal. This allows added
1039     features such as creating an alpha band.
1040     (GetImageData): Generate a mask array from the alpha band that is
1041     generated by gdal if the user has selected it. Try to support images
1042     that have more than three bands, such as images with RGB plus an
1043     alpha band.
1044     (ProjectRasterFile): Convert python argument for mask and tell
1045     gdal to enable or disable an alpha band.
1046    
1047     * Thuban/Model/layer.py (BaseLayer.Type): New. Returns a string
1048     describing what kind of layer the class is. Defaults to "Unknown",
1049     but should be overridden by subclasses.
1050     (Layer.Type): New. Override base class method.
1051     (RasterLayer.__init__): Create a flag for using a mask. Record extra
1052     data from gdal for display in the properties dialog.
1053     (RasterLayer.Type): New. Override base class method.
1054     (RasterLayer.UseMask): New. Returns True if the mask should be used.
1055     (RasterLayer.SetUseMask): New. Set if the mask should be used.
1056     (RasterLayer.ImageInfo): New. Return extra information about the image.
1057    
1058     * Thuban/Model/load.py (SessionLoader.start_rasterlayer): Load
1059     the mask information.
1060    
1061     * Thuban/Model/save.py (SessionSaver.write_layer): Save mask information.
1062    
1063     * Thuban/UI/mainwindow.py: Register the RasterLayerProperties and
1064     Classifier classes as dialogs to use with the proper layer types.
1065    
1066     * test/test_baserenderer.py (TestBaseRenderer.test_raster_no_projection):
1067     Fix test.
1068    
1069     * test/test_layer.py (TestLayer.test_raster_layer): Test new methods.
1070     (TestLayerModification.build_path): New. Support function.
1071     (TestLayerModification.test_raster_layer): New. Test new methods.
1072    
1073     * test/test_save.py (SaveSessionTest.testRasterLayer): Add tests for mask.
1074    
1075     * test/test_load.py (TestRasterLayer): Add tests for mask.
1076    
1077     * test/test_load_1_0_1.py: New. Copied from test_load.py.
1078    
1079     * test/test_baserenderer.py (SimpleRenderer.draw_raster_data): Removed
1080     obsolete optional mask argument.
1081    
1082 nhueffme 2549 2005-01-26 Nina Hüffmeyer <[email protected]>
1083    
1084     * Extensions/ogr/ogrshapes.py: Added two dictionaries to ShapeStore
1085     which maps the ids and the ordinals. Fixed RowIdToOrdinal(),
1086     RowOrdinalToId() and ReadRowAsDict().
1087    
1088     * Extensions/ogr/ogrstart.py: Added menu item which opens database
1089     layers for existing database connections.
1090    
1091     * Extensions/ogr/test/test_OGRShapestore.py: Fixed a message string.
1092    
1093    
1094 jan 2548 2005-01-26 Jan-Oliver Wagner <[email protected]>
1095    
1096     * Doc/manual/thuban-manual-de.xml: More translations.
1097    
1098 bh 2544 2005-01-24 Bernhard Herzog <[email protected]>
1099    
1100     Rework the status bar updates a bit to make sure the message about
1101     the projections is produced at the right times.
1102    
1103     * Thuban/UI/mainwindow.py (MainWindow.update_status_bar_messages):
1104     New class variable with messages that may require a status bar
1105     update.
1106     (MainWindow.view_position_changed)
1107     (MainWindow.update_status_bar): Rename from view_position_changed
1108     to update_status_bar. It's meaning has changed now that it may
1109     also generate messages about problems with projection settings.
1110     (MainWindow.__init__): Use the new update_status_bar_messages
1111     class variable to subscribe update_status_bar
1112     (MainWindow.set_position_text): Update doc-string. This method
1113     has to be renamed at some point. See doc-string and comments.
1114     (MainWindow.OnClose): Unsubscribe update_status_bar from all
1115     messages in update_status_bar_messages
1116    
1117     * Thuban/UI/viewport.py (ViewPort.forwarded_map_messages): New
1118     class attribute. map messages to be forwarded by the viewport.
1119     (ViewPort._subscribe_map, ViewPort._unsubscribe_map): (un)subscribe
1120     the messages in forwarded_map_messages
1121    
1122 bh 2543 2005-01-21 Bernhard Herzog <[email protected]>
1123    
1124     * test/postgissupport.py (PostGISDatabase.__init__): Tweak
1125     doc-string
1126     (find_postgis_sql): Update for postgis-1.0.0-rc1, which uses a
1127     different name for the initialization SQL file.
1128    
1129 jonathan 2537 2005-01-21 Jonathan Coles <[email protected]>
1130 jan 2542
1131     * Thuban/UI/baserenderer.py (proj_params_to_str): New. Takes
1132     a projection and returns a formatted string representing the
1133     parameters to feed to gdalwarp. This function eliminates
1134     redundancy in draw_raster_layer().
1135     (BaseRenderer.render_map_incrementally): Removed the optimization which
1136     drew the top most raster layer first and then only those vector-
1137     based layers that are above it. With the support for transparency
1138     this optimization breaks correct behaviour.
1139     (BaseRenderer.draw_raster_layer): Reorganize code to support possible
1140     future enhancements to raster layer bounding box. The old behaviour has
1141     not changed. Also, change calling parameters to draw_raster_data()
1142     to specify new RAW data format and mask.
1143     (BaseRenderer.draw_raster_data): Change signature to include an optional
1144     parameter for mask information. Change documentation to mention
1145     support for new parameter and added option for RAW data format.
1146     The data argument is now a list of [width, height, data].
1147    
1148     * Thuban/UI/renderer.py (MapRenderer.draw_raster_data): Add new optional
1149     mask parameter. Add new condition for RAW format, which
1150     significantly reduces rendering time. Add condition for
1151     mask parameter.
1152    
1153     * libraries/thuban/gdalwarp.cpp (GetImageData): New. Creates a
1154 jonathan 2537 data array of RGB values from the projected image returned from
1155     the gdal warping functions. In the case of palette based images, it
1156 jan 2542 converts the NO_DATA index to the mask color.
1157     (ProjectRasterFile): Removed all custom memory driver references
1158     and replaced it with the standard in-memory dataset provided
1159     by gdal. The return data is no longer a BMP file, but an array
1160     of RGB values, one set triple per pixel.
1161 jonathan 2537
1162     * libraries/thuban/bmpdataset.cpp: Removed. Unnecessary.
1163     * libraries/thuban/cpl_mfile.h: Removed. Unnecessary.
1164     * libraries/thuban/cpl_mfile.cpp: Removed. Unnecessary.
1165    
1166 jan 2542 * setup.py (thuban_build_ext.finalize_options): Removed mention
1167     of cpl_mfile.cpp and bmpdataset.cpp files in the list of source
1168     files. These are obsolete with the new version of gdalwarp.cpp
1169    
1170     * test/test_baserenderer.py (SimpleRenderer.draw_raster_data):
1171     Updated signature.
1172     (TestBaseRenderer.test_raster_no_projection): Changed the test
1173     data to be data in the uncompressed RAW format returned from
1174     ProjectRasterFile.
1175    
1176 jan 2535 2005-01-21 Jan-Oliver Wagner <[email protected]>
1177    
1178 jan 2542 * Thuban/UI/mainwindow.py (MainWindow.view_position_changed): Made
1179     string available for i18n.
1180 jan 2535
1181 russell 2532 2005-01-20 Russell Nelson <[email protected]>
1182    
1183     * Resources/Projections/defaults.proj: Ruin the speling of the
1184 russell 2533 Lambert-93 projection so it doesn't run into the wx UTF-8 bug.
1185     It's the wrong thing to do in the long run, but it's necessary for
1186     those users until that bug is fixed. Otherwise the projection
1187     dialog segfaults. Better to annoy some Lambert-93 users with a
1188     spelling mistake than every Fedora Core 3 user of Thuban-CVS.
1189 russell 2532
1190 bernhard 2531 2005-01-20 Bernhard Reiter <[email protected]>
1191    
1192 jan 2542 * Thuban/UI/mainwindow.py (MainWindow.view_position_changed): Added
1193     docstring and comment that the warning code here is a hack.
1194 bernhard 2531
1195 russell 2529 2005-01-20 Russell Nelson <[email protected]>
1196    
1197 jan 2542 * Thuban/UI/mainwindow.py (MainWindow.view_position_changed): Warn
1198     user about misprojected layers when their lat/lon bounding
1199 russell 2529 box exceeds rational lat/lon values.
1200    
1201 bernhard 2525 2005-01-20 Bernhard Reiter <[email protected]>
1202    
1203 jan 2542 * Thuban/UI/about.py (unicodeToLocale): Improved:
1204 bernhard 2528 Use 'ascii' and then 'replace' for other characters
1205     when getdefaultlocale returns None. Thanks to Bernhard H. .
1206 jan 2542
1207 bernhard 2528 2005-01-20 Bernhard Reiter <[email protected]>
1208    
1209 jan 2542 * Thuban/UI/classgen.py (GenQuantilesPanel.OnRetrieve): Added a comment
1210 bernhard 2527 that OnRangeText might be called twice and using None as argument.
1211 jan 2542
1212 bernhard 2527 2005-01-20 Bernhard Reiter <[email protected]>
1213    
1214 jan 2542 * Thuban/UI/classgen.py (GenQuantilesPanel.OnRetrieve): Add a
1215     OnRangeText(0) to work around a different in wx Behaviour noticed
1216     on MacOSX, thanks to Lorenzo Moretti and Daniel Calvelo for the fix.
1217    
1218 bernhard 2526 2005-01-20 Bernhard Reiter <[email protected]>
1219    
1220     * Thuban/UI/about.py: take iso-8859-15 when getdefaultlocale returns
1221 bernhard 2525 None. (Fixes rt#2910.)
1222    
1223 frank 2524 2005-01-18 Frank Koormann <[email protected]>
1224    
1225     New Extension: mouseposition
1226     Tool to collect mouse click positions (map coordinates) in a dialog.
1227    
1228     * Extensions/mouseposition/__init__.py: New, extension registration
1229    
1230     * Extensions/mouseposition/mouseposition.py: New, implements the
1231     dialog and adds a tool to Thuban mainwindow.
1232    
1233     * Extensions/mouseposition/position.xpm: New, icon for tool.
1234    
1235 jan 2522 2005-01-14 Jan-Oliver Wagner <[email protected]>
1236    
1237     * Doc/manual/thuban-manual-de.xml: More translations.
1238    
1239 frank 2520 2005-01-11 Frank Koormann <[email protected]>
1240    
1241     * Thuban/UI/mainwindow.py (MainWindow.DuplicateLayer):
1242     Fix indention bug.
1243    
1244 frank 2517 2005-01-09 Frank Koormann <[email protected]>
1245    
1246     * Thuban/UI/mainwindow.py (MainWindow.DuplicateLayer):
1247 frank 2520 BugFix 2901: Explicitly copy layers ClassificationColumn since it
1248 frank 2517 is not part of the layers Classification.
1249    
1250 frank 2515 2005-01-03 Frank Koormann <[email protected]>
1251    
1252 frank 2517 * Thuban/UI/renderer.py (ScreenRendererdraw_selection_incrementally):
1253     BugFix 2883: Former implementation only worked on classified point
1254     layers: KeyError was raised, now use the default size if field is None.
1255 frank 2515
1256 bernhard 2513 2004-12-27 Bernhard Reiter <[email protected]>
1257    
1258     svgexport 1.0.0cvs: Fixed label export.
1259    
1260     * Extensions/svgexport/test/test_svgmapwriter.py:
1261     class TestSVGRenderer(): New class; new test test_label_font().
1262    
1263     * Extensions/svgexport/svgmapwriter.py
1264     (SVGRenderer.label_font()): initialised Font size with self.factor now,
1265     makes test_label_font happy.
1266    
1267     * Extensions/svgexport/TODO: crossed out fixed label export item.
1268     Added item for options.
1269    
1270     * Extensions/svgexport/__init__.py: Bumped version to 1.0.0cvs.
1271    
1272 russell 2511 2004-12-27 Russell Nelson <[email protected]>
1273    
1274 jan 2512 Middle mouse button pans.
1275 russell 2511
1276 jan 2512 * Thuban/UI/view.py (MapCanvas.__init__): Subscribe also
1277     OnMiddleDown and OnMiddleUp events.
1278     (MapCanvas.OnMiddleDown): New. Activate the pan tool and remember the
1279     previously used tool.
1280     (MapCanvas.OnMiddleUp): New. Reactivate the remebered tool used before
1281     pressing the middle mouse button.
1282    
1283 jan 2509 2004-12-27 Jan-Oliver Wagner <[email protected]>
1284    
1285     * Doc/manual/thuban-manual-de.xml: More translations.
1286    
1287 jan 2506 2004-12-23 Jan-Oliver Wagner <[email protected]>
1288    
1289     * Thuban/UI/projdialog.py (ProjFrame.load_user_proj): Added a
1290     \n to stderr after the warnings. Thanks to Russell Nelson.
1291    
1292 nhueffme 2493 2004-12-20 Nina Hueffmeyer <[email protected]>
1293    
1294     * Extensions/ogr/ogrshapes.py: Fixed some issues from
1295     Bernhard (coding guidelines etc.). Additionally it is now possible to
1296     display shapefiles containing feature collections (e.g.polygons
1297     with holes). Works with gdal 1.2.1 now.
1298    
1299     * Extensions/ogr/test/test_OGRShapestore.py: Fixed some issues
1300     from Bernhard (coding guidelines etc.). If ogr can't be imported,
1301     tests are skipped now.
1302    
1303     * Extensions/ogr/ogrstart.py: Fixed some typings.
1304    
1305 bernhard 2490 2004-12-20 Bernhard Reiter <[email protected]>
1306    
1307     * Extensions/svgexport/TODO: updated to add support for
1308     raster layers and labels for 1.0.1.
1309    
1310     * Extensions/svgexport/svgmapwriter.py (draw_raster_layer):
1311     Issue a warning now.
1312    
1313 bernhard 2488 2004-12-19 Bernhard Reiter <[email protected]>
1314    
1315 bernhard 2489 * Extensions/svgexport/TODO: Added idea to support triggering
1316     the application down the pipe.
1317    
1318     2004-12-19 Bernhard Reiter <[email protected]>
1319    
1320 bernhard 2488 svgexport: Improved code quality, mainly by better naming.
1321    
1322     * Extensions/svgexport/svgmapwriter.py:
1323     DrawPath() renamed to DrawPolygonPath(),
1324     added documentation, improved comments and variable names.
1325    
1326     * Extensions/svgexport/svgmapwriter.py,
1327     Extensions/svgexport/test/test_svgmapwriter.py:
1328     All using DrawPolygonPath() now, the default parameter closed=True
1329     omitted.
1330    
1331     * Extensions/svgexport/test/test_svgmapwriter.py:
1332     renamed test_polygon_opened() to test_polyline()
1333     renamed test_transparent_polygon() to test_transparent_polyline()
1334    
1335 jan 2487 2004-12-18 Jan-Oliver Wagner <[email protected]>
1336    
1337     Some fixes of gns2shp extension.
1338    
1339     * Extensions/gns2shp/test/__init__.py: New. Make this directory a
1340     package.
1341    
1342     * Extensions/gns2shp/test/test_gns2shp.py: Add some import paths
1343     dynamically.
1344    
1345     * Extensions/gns2shp/test/README: Simplified description how to test.
1346    
1347     * Extensions/gns2shp/gns2shp.py (gns2shp): Fixed doc-string,
1348     fixed some dimensions of fields according to the GNS documentation
1349     which seems to change undocumented.
1350     Now killing trailing \n and/or \r from MODIFY_DATE.
1351     This fixes RT#2453.
1352    
1353 bernhard 2479 2004-12-18 Bernhard Reiter <[email protected]>
1354 bernhard 2480
1355 bernhard 2482 svgexport 1.0.0: Treats holes and islands nicely. Documentation added.
1356    
1357     * Extensions/svgexport/test/test_svgmapwriter.py:
1358     Added new tests: test_export_polygon_with_hole()
1359     and test_polygon_with_hole().
1360    
1361     * Extensions/svgexport/svgmapwriter.py
1362     (draw_polygon_shape()): Uses DrawPath correctly now.
1363    
1364     * Doc/manual/thuban-manual.xml: Added documentation for stable
1365     extention svgexport.
1366     * Doc/manual/thuban-manual-de.xml: Copied English section about
1367     svexport over.
1368    
1369 jan 2509 * Extensions/svgexport/__init__.py: Bumped version number to 1.0.0.
1370 bernhard 2482
1371     * Extensions/svgexport/svgsaver.py,maplegend.py:
1372     Moved from experimental to stable extension menu.
1373    
1374     * Extensions/svgexport/TODO: updated.
1375    
1376    
1377     2004-12-18 Bernhard Reiter <[email protected]>
1378    
1379 bernhard 2481 Added Extensions/svgexport/TODO
1380    
1381     2004-12-18 Bernhard Reiter <[email protected]>
1382    
1383 bernhard 2480 Refactored in svgexport:
1384     DrawPath replaces DrawPolygon; added newline in front of "M" in paths.
1385    
1386     * Extensions/svgexport/svgmapwriter.py
1387     Added verbosity level 3 to print out polygon points.
1388     (class Point): added __repr__
1389     (class Brush, __str__()): Added space after ,.
1390     (DrawPolygon): Renamed to DrawPath()
1391     (DrawPath): Takes list of polygons as input now, adds \n before "M"s.
1392     (DrawLines): Using DrawPath now.
1393    
1394     * Extensions/svgexport/test/test_svgmapwriter.py:
1395     Replaced DrawPolygon() calls with DrawPath() and put the first argument
1396     inside another list. Adapted test data with a newline before "M".
1397    
1398     2004-12-18 Bernhard Reiter <[email protected]>
1399 bernhard 2479
1400     Refactored svgexport tests: 9 double tests runs eliminated;
1401     code size reduced by 8 lines.
1402    
1403     * Extensions/svgexport/test/test_svgmapwriter.py:
1404     (class TestWithDC): Renamed to BaseTestWithDC, moved to top.
1405     (class BaseWithDCtools): New, subclass from BaseTestWithDC.
1406     (class TestDrawSplines): now subclass from BaseTestWithDCtools,
1407     this fixed the double running of the nine tests of TestVirtualDC.
1408     (class TestVirtualDC): Using self.dc and self.file from setUp().
1409    
1410 bh 2478 2004-12-17 Bernhard Herzog <[email protected]>
1411    
1412     Two windows specific fixes ported from thuban-1­0-branch:
1413    
1414     * Thuban/UI/about.py (unicodeToLocale): Use getdefaultlocale
1415     instead of getlocale because getlocale doesn't return a usable
1416     encoding name on a german windows 2000
1417    
1418     * setup.py: windows build: Removed the absolute path names and
1419     made all prfixes relative to the directory containing setup.py.
1420     Makes it a little easier to adapt to a different system.
1421    
1422 bh 2470 2004-12-16 Bernhard Herzog <[email protected]>
1423    
1424 bernhard 2479 Add support for PostGIS tables with LINESTRING geometries.
1425 bh 2472 Fixes RT#2299
1426    
1427     * Thuban/Model/postgisdb.py (shapetype_map): Add LINESTRING
1428    
1429     * test/postgissupport.py
1430     (PostgreSQLServer.get_default_static_data_db): Rename the "roads"
1431     table to "roads-multi" because it now uses MULTILINESTRING
1432     geometries and introduce a new "roads" table that uses LINESTRING
1433     (coords_to_multilinestring): Make the doc string more precise
1434     (coords_to_linestring): New. Create a LINESTRING WKT
1435     representatin
1436     (wkt_converter): Add coords_to_linestring
1437     (upload_shapefile): Rephrase the doc-string a bit.
1438    
1439     * test/test_postgis_db.py (TestPostGISShapestoreArc)
1440     (LineStringTests)
1441     (TestPostGISShapestoreLineString)
1442     (TestPostGISShapestoreMultiLineString): Split
1443     TestPostGISShapestoreArc into a base class LineStringTests and two
1444     derived classes TestPostGISShapestoreLineString for LINESTRING
1445     geometries and TestPostGISShapestoreMultiLineString for
1446     MULTILINESTRING geometries. Most test methods are in the base
1447     class with the exception of tests that explicitly check the raw
1448     format.
1449    
1450     2004-12-16 Bernhard Herzog <[email protected]>
1451    
1452 bh 2471 Make the test suite work with PostGIS 0.8.2 and PostgreSQL 7.4
1453    
1454     * test/postgissupport.py (find_postgis_sql): Different postgis
1455     versions put the postgis.sql file into slightly different places
1456     so we have to look in both. The updated doc string describes this
1457     is more detail.
1458    
1459     * test/test_postgis_db.py
1460     (TestPostGISSpecialCases.test_column_name_quoting): The return
1461     value of UniqueValues is unsorted, so it has to be sorted for
1462     comparison.
1463    
1464     2004-12-16 Bernhard Herzog <[email protected]>
1465    
1466 bh 2470 Fix for RT#2237
1467    
1468     * Thuban/UI/projdialog.py (ProjFrame._show_proj_panel): If the
1469     panel to be shown is the UnknownProjPanel disable the OK and Try
1470     buttons. Otherwise enable them.
1471     (ProjFrame.__GetProjection): The UnknownProjPanel returns None for
1472     the parameters. In that case __GetProjection also returns None
1473     now.
1474    
1475 bh 2459 2004-12-15 Bernhard Herzog <[email protected]>
1476    
1477 bh 2462 * Thuban/UI/classgen.py (GenQuantilesPanel.__init__): Set the
1478     minimum number of classes to 2. The calculate_quantiles needs at
1479     least two and raises an exception otherwise.
1480     Fixes RT#2549
1481    
1482     2004-12-15 Bernhard Herzog <[email protected]>
1483    
1484 bh 2460 * test/postgissupport.py (PostgreSQLServer.execute_sql): Extend to
1485     so that it returns a result for select statements.
1486     (PostgreSQLServer.server_version): New. Return the version of the
1487     server software.
1488     (PostgreSQLServer.require_authentication): The format of
1489     pg_hba.conf has changed between PostgrSQL 7.2 and 7.3. Check the
1490     server version and generate the file in the correct format
1491    
1492     2004-12-15 Bernhard Herzog <[email protected]>
1493    
1494 bh 2459 * test/postgissupport.py (PostgreSQLServer.is_running): Fix typo
1495     in the doc string and rephrase it a little.
1496    
1497 frank 2457 2004-12-15 Frank Koormann <[email protected]>
1498    
1499     * test/test_load.py (TestAltPath.checkSession): New, extended checks if
1500     session has been loaded successfully. The check is called by the relevant
1501     tests after executing load_session().
1502    
1503 bh 2450 2004-12-13 Bernhard Herzog <[email protected]>
1504    
1505 bh 2454 Make sure the region used to determine which shapes are visible
1506     actually matches the region on the printed page. If this isn't
1507     done properly some shapes might not be printed.
1508     Fixes RT #2692
1509    
1510     * Thuban/UI/view.py (MapPrintout.draw_on_dc): The region for the
1511     renderer has to be at the same position as the mapregion
1512    
1513     * Thuban/UI/renderer.py (ExportRenderer.RenderMap): self.region
1514     has to be moved by (self.shiftx, self.shifty) too.
1515    
1516     2004-12-13 Bernhard Herzog <[email protected]>
1517    
1518 bh 2452 * libraries/pyprojection/Projection.i: Work around a bug in the
1519     generated python code which leads to exception in the __del__
1520     method when the constructor fails. See the comments in the code
1521     for more details.
1522    
1523     * libraries/pyprojection/Projection.py: Updated from Projection.i
1524     with SWIG.
1525    
1526     2004-12-13 Bernhard Herzog <[email protected]>
1527    
1528 bh 2451 * test/test_load.py (TestAltPath.test_01_single_path_error_fix)
1529     (TestAltPath.test_02_path_error_fix_from_list)
1530     (TestAltPath.test_05_path_error_fix_from_list_changed)
1531     (TestAltPath.test_06_path_error_fix_from_list_fails): self.session
1532     is destroyed in tearDown, so there's no need to do it in a test
1533     case.
1534    
1535     * Thuban/Model/load.py (SessionLoader.open_shapefile): Remove a
1536     debug print
1537    
1538     2004-12-13 Bernhard Herzog <[email protected]>
1539    
1540 bh 2450 * Extensions/svgexport/test/test_svgmapwriter.py
1541     (TestDrawSplines.setUp): Do not use super with the unittest
1542     classes because in Python 2.2 they're still old-style classes.
1543    
1544 frank 2448 2004-12-13 Frank Koormann <[email protected]>
1545    
1546     Alternative Path feature: When loading a (moved) session where
1547     shapefiles cannot be found, ask the user. Use the specified path
1548     if further shapefiles are missing. However, ask the usr for confirmation
1549     in such cases.
1550    
1551     * test/test_load.py (TestAltPath): New, tests for alternative path feature
1552     in load_session()
1553     (Shapefile_CallBack): Helper, implements controllable callback.
1554    
1555     * Thuban/UI/application.py (ThubanApplication.OnInit):
1556     Added "alt_path" to self.path
1557     (ThubanApplication.OpenSession): Added shapefile_callback as second
1558     callback similar to db_connection_callback.
1559     (ThubanApplication.run_alt_path_dialog): New, implementaion of
1560     shapefile_callback. In addition to raising the dialog the control of
1561     self.path('alt_path') is implemented here.
1562    
1563     * Thuban/Model/load.py (SessionLoader.__init__): Added shapefile_callback.
1564     (SessionLoader.open_shapefile): Open shapefile, eventually with
1565     alternative path. This wrapps the "theSession.OpenShapefile(filename)"
1566     formerly used in start_fileshapesource()/start_layer().
1567     (SessionLoader.start_fileshapesource): Call open_shapefile().
1568     (SessionLoader.start_layer): Call open_shapefile().
1569     (load_session): Added shapefile_callback.
1570    
1571     * Thuban/UI/altpathdialog.py: New, implements dialogs for alternative path
1572     feature (search / check).
1573    
1574     * Doc/manual/thuban-manual.xml: Added documentation of new feature.
1575    
1576 bernhard 2443 2004-12-11 Bernhard Reiter <[email protected]>
1577    
1578 bernhard 2445 svgexport 0.9.2: Point size supports for maps.
1579    
1580     * Extensions/svgexport/svgmapwriter.py: Added import of SHAPETYPE_POINT
1581     (def draw_point_shape): new parameter size defaults to 2 as before.
1582     (draw_shape_layer_incrementally): Moved draw_func log line higher.
1583     Added draw_func call with size when dealing with a point layer.
1584    
1585     * Extensions/svgexport/__init__.py: bumped version to 0.9.2.
1586    
1587     2004-12-11 Bernhard Reiter <[email protected]>
1588    
1589 bernhard 2444 Made sure that newlines are inserted in the svg path d attributes
1590     to raise the chance that the line length will be below 255 characters,
1591     as recommended by REC SVG 1.1 in section 8.3.1.
1592    
1593     * Extensions/svgexport/svgmapwriter.py(DrawPolygon):
1594     Adding \n before L's and changed whitespace handling.
1595    
1596     * Extensions/svgexport/test/test_svgmapwriter.py:
1597     Adapted tests to new whitespace handling of DrawPolygon.
1598    
1599     2004-12-11 Bernhard Reiter <[email protected]>
1600    
1601 bernhard 2443 * Doc/technotes/coding_guidelines.txt: easy typo fixed.
1602    
1603     * Extensions/svgexport/test/test_svgmapwriter.py:
1604     Removed test_drawbezier in favour of new test_drawspline3 and
1605     test_drawspline4 within new class TestDrawSplines(TestVirtualDC).
1606     All only to test DrawSpline.
1607    
1608     * Extensions/svgexport/svgmapwriter.py(DrawSpline):
1609     New implementation now really using the strange algorithm of
1610     xfig 3.1's approximated splines and its conversion to postscript
1611     with one twist: SVG can do quadratic beziers, so skipped translation
1612     to cubic beziers.
1613     (TestWithDC): Typo in comment fixed.
1614    
1615 joey 2442 2004-12-09 Martin Schulze <[email protected]>
1616    
1617     * Thuban/Model/classgen.py: Added missing character encoding
1618    
1619     * Extensions/wms/properties.py (OpenWMSProperties): removed
1620    
1621     * Extensions/wms/parser.py (WMSCapabilitiesParser.error): Dropped
1622     support for get_srs_discrepancies() since there are no
1623     discrepancies anymore (was a thinko)
1624    
1625     * Extensions/wms/layer.py (WMSLayer.GetMapImg): Improved graphic
1626     format priority now that more formats are supported globally by
1627     the render engine.
1628    
1629 silke 2437 2004-12-08 Silke Reimer <[email protected]>
1630     * Extensions/ogr/ogrshapes.py: Substituted ogr-method CloseRings
1631     because it is not available in all versions of ogr
1632    
1633 bernhard 2436 2004-12-08 Bernhard Reiter <[email protected]>
1634     * Extensions/ogr/__init__.py: Added empty __init__.py to heal
1635     global tests until a real one is commited.
1636    
1637 nhueffme 2435 2004-12-07 Nina Hüffmeyer <[email protected]>
1638    
1639     * /Extensions/ogr/: Adding a new extension to read shapefiles with
1640     ogr. It is planned to add other vector formats.
1641    
1642     * /test/runtests.py: Adding tests from /Extensions/ogr/test/.
1643    
1644 jan 2434 2004-12-07 Jan-Oliver Wagner <[email protected]>
1645    
1646     * /Extensions/svgexport/test/test_svgmapwriter.py: Reverting
1647     part of a (non-)fix to renable that the tests are always
1648     executed.
1649    
1650 bernhard 2432 2004-12-07 Bernhard Reiter <[email protected]>
1651    
1652     * Extensions/svgexport/test/test_svgmapwriter.py:
1653     Added test_drawbezier() to test DrawSpline().
1654    
1655     * Extensions/svgexport/svgmapwriter.py(DrawSpline):
1656     Really implemented bezier drawing.
1657    
1658     * Extensions/svgexport/__init__.py: Bumped version of svgexport
1659     to 0.9.1 because now the legend examples lines styles
1660     will be drawing with beziers.
1661    
1662 joey 2431 2004-12-05 Martin Schulze <[email protected]>
1663    
1664     * Thuban/UI/renderer.py (raster_format_map): Added PNG, TIFF and
1665     GIF as supported bitmap image formats (helpful for the WMS extension)
1666    
1667 joey 2430 2004-11-30 Martin Schulze <[email protected]>
1668    
1669     * Extensions/wms/test/test_ogclib.py (TestOGCLib.test_compareURLs):
1670     Improved the test for the internal compare method
1671    
1672 jan 2429 2004-11-27 Jan-Oliver Wagner <[email protected]>
1673    
1674     * Thuban/UI/about.py (About.__init__): Added
1675     Norbert Solymosi for hungarian translation and Ole Rahn
1676     as contrbutor. Moved Bernhard Reiter from Contributor
1677     to Developer.
1678    
1679 bernhard 2425 2004-11-27 Bernhard Reiter <[email protected]>
1680    
1681     * Extensions/svgexport/test/test_svgmapwriter.py:
1682     Removed Jan from author list as he did not change enough significant
1683     lines yet.
1684    
1685     * Extensions/svgexport/__init__.py: Added Bernhard as author
1686     of the Extension.
1687    
1688 jan 2422 2004-11-27 Jan-Oliver Wagner <[email protected]>
1689    
1690     * po/hu.po: New. Hungarian translation. Contributed
1691     by Norbert Solymosi.
1692    
1693 bh 2419 2004-11-26 Bernhard Herzog <[email protected]>
1694    
1695     * Extensions/svgexport/test/test_svgmapwriter.py
1696     (Testobjectexport.test_transparent_polygon): Commented out some
1697     debug prints
1698    
1699 jan 2418 2004-11-24 Jan-Oliver Wagner <[email protected]>
1700    
1701     Fix broken tests for svg extension and added svg legend
1702     to Experimental menu.
1703    
1704     * Extensions/svgexport/test/test_svgmapwriter.py: Fix to have
1705     the test run correctly even if the extension is a package.
1706     Also removed the "import Thuban" which makes no sense.
1707    
1708     * Extensions/svgexport/__init__.py: Fix to have the extensions'
1709     test module also be executed from the global test routine.
1710     This is done by looking for the absense of the DISPLAY variable.
1711    
1712     * Extensions/svgexport/maplegend.py: Moved the menu entry from Extensions
1713     to Experimental menu since this module has yet not reached a stable
1714     status (ie. 1.0).
1715    
1716 bernhard 2414 2004-11-22 Bernhard Reiter <[email protected]>
1717    
1718     * Extensions/svgexport/svgmapwriter.py:
1719     Added verbose variable and some logging depending on it.
1720     (class VirtualDC(XMLWriter)): Minor improvement in the polygon loop,
1721     because counting i is not necessary.
1722     (class Pen, class Brush): Added simple __str__ methods.
1723     (SVGRenderer.draw_polygone_shape): Fix #2698 (transparent polygons are
1724     not exported to svg file) Note: holes still unhandled.
1725    
1726     * Extensions/svgexport/test/test_svgmapwriter.py:
1727     Made a baseclass TestWithDC for test needed a DC.
1728     Added tests for bug #2698 (transparent polygons are not
1729     exported to svg file):
1730     Testobjectexport.test_transparent_polygon()
1731    
1732     * Thuban/Model/base.py (UnsetModified):
1733     Fixed some typos in docstring.
1734    
1735     * Thuban/UI/baserenderer.py (BaseRenderer.draw_polygon_shape()):
1736     Added hints on the used algorithm for handling holes.
1737    
1738 jan 2403 2004-11-20 Jan-Oliver Wagner <[email protected]>
1739    
1740 jan 2412 Some face lifting for the examples.
1741    
1742     * Examples/__init__.py: Make this directory a package.
1743    
1744     * Examples/simple_extensions/__init__.py: Make this directory a package.
1745    
1746     * Examples/simple_extensions/hello_world.py: Moved entry from Extensions
1747     menu to Examples menu.
1748    
1749     * Examples/simple_extensions/simple_command.py: Some more comments,
1750     minor changes.
1751    
1752     * Examples/simple_extensions/simple_tool.py: Minor changes.
1753    
1754     2004-11-20 Jan-Oliver Wagner <[email protected]>
1755    
1756 jan 2407 Changed way of extension registry for wms and added extension
1757     registry for umn_mapserver extension.
1758    
1759     * Extensions/wms/__init__.py: Added registry entry and the importing
1760     of the actual wms module. Included a test for the required PyOGCLib.
1761    
1762     * Extensions/wms/wms.py: Removed registry entry (moved to __init__.py).
1763    
1764     * Extensions/umn_mapserver/__init__.py: Added registry entry and the
1765     importing of the actual umn mapserver management modules.
1766     Included a test for the required Python MapScript.
1767    
1768     2004-11-20 Jan-Oliver Wagner <[email protected]>
1769    
1770 jan 2403 Changed way of extension registry for importAPR, bboxdump
1771     and added extension registry for svgexport.extension registry for
1772     svgexport.
1773    
1774     * Extensions/importAPR/__init__.py: Added registry entry and the importing
1775     of the actual importAPR module.
1776    
1777     * Extensions/importAPR/importAPR.py: Removed registry entry (moved to
1778     __init__.py).
1779    
1780     * Extensions/bboxdump/__init__.py: Added registry entry and the importing
1781     »···of the actual bboxdump module.
1782    
1783     * Extensions/bboxdump/bboxdump.py: Removed registry entry (moved to
1784     »···__init__.py).
1785    
1786     * Extensions/svgexport/__init__.py: Added registry entry and the importing
1787     of the svgsaver module.
1788    
1789     * Extensions/svgexport/svgsaver.py: Moved the menu entry from Extensions
1790     to Experimental menu since this module has yet not reached a stable
1791     status (ie. 1.0).
1792    
1793 jan 2397 2004-11-18 Jan-Oliver Wagner <[email protected]>
1794    
1795     Now the hit test considers the size of point symbols.
1796    
1797     * Thuban/UI/viewport.py (ViewPort._hit_point): Added optional parameter
1798     'size' defaulting to the previously fixed value 5.
1799     Extended doc-string.
1800     (Viewport._find_shape_in_layer): Resolved FIXME regarding flexibility
1801     for symbols.
1802     Now the size of the largest point symbol is determined to find out
1803     about whether the point has been hit.
1804     This fixes the problem that only clicks inside a fixed distance of
1805     5 where found.
1806    
1807 jan 2395 2004-11-17 Jan-Oliver Wagner <[email protected]>
1808    
1809 jan 2397 Another open issue fixed regarding sizeable symbols: correct rendering of
1810 jan 2395 selected symbols.
1811    
1812     * Thuban/UI/renderer.py (ScreenRenderer.draw_selection_incrementally):
1813     Added consideration of the specific size of point symbols.
1814     The property for each point symbol is retrieved and the size applied
1815     for the rendering method.
1816     Added doc-string.
1817    
1818 jan 2393 2004-11-16 Jan-Oliver Wagner <[email protected]>
1819    
1820     Changed way of Extension Registry for gns2shp and profiling.
1821    
1822     * Extensions/gns2shp/gns2shp.py: Removed registry entry (moved to
1823     __init__.py).
1824    
1825     * Extensions/gns2shp/__init__.py: Added registry entry and the importing
1826     of the actual gns2shp module.
1827    
1828     * Extensions/profiling/profiling.py: Removed registry entry (moved to
1829     __init__.py).
1830    
1831     * Extensions/profiling/__init__.py: Added registry entry and the importing
1832     of the actual profiling module.
1833    
1834 bernhard 2388 2004-10-28 Bernhard Reiter <[email protected]>
1835    
1836     * Extensions/svgexport/: Minor improvements to doc strings.
1837    
1838 jan 2387 2004-10-07 Jan-Oliver Wagner <[email protected]>
1839    
1840     Further elements for sizable point objects now
1841     making this feature usable though not yet complete.
1842    
1843     * Thuban/Model/save.py (SessionSaver.write_classification): Write
1844     attribute 'size' for cldata when the shape layer is of point type.
1845     This also now make the test_load.py tests happy.
1846    
1847     * Thuban/Model/classgen.py (CustomRamp.GetProperties): Added size
1848     gradient.
1849    
1850     * Thuban/UI/classifier.py (ID_SELPROP_SPINCTRL): Renamed to
1851     ID_SELPROP_SPINCTRL_LINEWIDTH.
1852     (ID_SELPROP_SPINCTRL_LINEWIDTH): New Id replaces ID_SELPROP_SPINCTRL.
1853     (ID_SELPROP_SPINCTRL_SIZE): New Id.
1854     (SelectPropertiesDialog.__init__): Added a second spin control
1855     for the size in case the corresponding layer is of point type.
1856     (SelectPropertiesDialog._OnSpin): Renamed to _OnSpinLineWidth.
1857     (SelectPropertiesDialog._OnSpinLineWidth): New. Former _OnSpin.
1858     (SelectPropertiesDialog._OnSpinSize): New. Set size of property
1859     and refresh preview.
1860    
1861    
1862    
1863 joey 2381 2004-10-04 Martin Schulze <[email protected]>
1864    
1865     * Extensions/wms/test/test_parser.py
1866     (TestWMSCapabilitiesParser.test_compareLists): Added missing
1867     self-test for compareLists()
1868     (TestWMSCapabilitiesParser.test_compareDicts): Added missing
1869     self-test for compareDicts()
1870 joey 2382 (TestWMSCapabilitiesParser.test_compareLists): Adding more tests
1871     to verify the test routine fails with non-equal arguments
1872     (TestWMSCapabilitiesParser.test_compareDicts): Adding more tests
1873     to verify the test routine fails with non-equal arguments
1874 joey 2381
1875 jan 2370 2004-10-03 Jan-Oliver Wagner <[email protected]>
1876    
1877 jan 2380 First elements for sizeable point objects.
1878    
1879     * Resources/XML/thuban-1.1.dtd: Added size attribute to cldata.
1880    
1881     * Data/iceland_sample_size.thuban: New. Sample for sized point objects.
1882    
1883     * test/test_load.py (ClassificationTest.TestLayers): Added SetSize in case
1884     of a corresponding argument is given.
1885     (TestSymbolSize): New. Test the size attribute of cldata.
1886    
1887     * Thuban/Model/classification.py: Removed some trailing whitespaces.
1888     (ClassGroupProperties.__init__): Set default size.
1889     (ClassGroupProperties.SetProperties): Set the size.
1890     (ClassGroupProperties.GetSize): New. Return the size.
1891     (ClassGroupProperties.SetSize): New. Set the size.
1892     (ClassGroupProperties__eq__): Compare also size.
1893     (ClassGroupProperties__repr__): Print also size.
1894    
1895     * Thuban/Model/load.py (SessionLoader.start_cldata): Also parse
1896     the size attribute.
1897    
1898     * Thuban/UI/classifier.py (ClassDataPreviewer.Draw): Added doc-string.
1899     Also, now there is a return value that indicates whether the drawing
1900     size exceeded the given rect extent and if so the new extent.
1901     Finally, point objects are drawn depending on the size. If either
1902     the width or height is exceeded, the new extent is returned.
1903     (ClassRenderer.Draw): Now when calling the previewer drawing function,
1904     evaluate the return value and, if not None, adapt the grid widget size
1905     accordingly and redraw again.
1906    
1907     * Thuban/UI/baserenderer.py (BaseRenderer.draw_shape_layer_incrementally):
1908     If the draw function is for points, call it with the size as additional
1909     parameter.
1910     (BaseRenderer.draw_point_shape): Added additional, optional parameter for
1911     the size. Compute the radius using the size.
1912    
1913     * Extensions/importAPR/apr.py (APR_BMkSym.GetThubanProp): Now
1914     that Thuban supports size, apply this correctly.
1915    
1916     * Extensions/importAPR/importAPR.py: Bumped version to 0.1.1.
1917    
1918     2004-10-03 Jan-Oliver Wagner <[email protected]>
1919    
1920 jan 2370 * Doc/manual/thuban-manual-de.xml: Started translation of
1921     Map chapter.
1922    
1923 joey 2368 2004-10-01 Martin Schulze <[email protected]>
1924    
1925     * Extensions/wms/properties.py (wmsProperties.__init__): Extended
1926     argument for general use through properties-dialog selector
1927    
1928     * Thuban/UI/classifier.py: Register properties dialog classes for
1929     both provided layer classes/types.
1930    
1931     * Thuban/UI/mainwindow.py (MainWindow.OpenLayerProperties): The
1932     map can be retrieved through the parent which is passed to the
1933     constructor anyway and doesn't require an argument of its own,
1934     required for the unification of arguments for general use through
1935     properties-dialog selector.
1936     (MainWindow.OpenOrRaiseDialog): Move the logic for checking
1937     whether a dialog is already opened (and raising it to the users
1938     attention) and creating a new dialog into a function of its own
1939     (MainWindow.OpenLayerProperties): Use the new OpenOrRaiseDialog()
1940     method
1941     (MainWindow.OpenLayerProperties): Utilise the new ClassMapper for
1942     global registration of properties dialog classes (which are indeed
1943     layer-specific).
1944    
1945     * Thuban/UI/classifier.py (Classifier.__init__): Unify arguments
1946     for general use through properties-dialog selector, the map can be
1947     retrieved through the parent and doesn't require an argument of
1948     its own.
1949    
1950     * Extensions/wms/wms.py: Register the properties dialog class for
1951     the provided WMS layer
1952    
1953 jan 2358 2004-09-28 Jan-Oliver Wagner <[email protected]>
1954    
1955     New feature: Registry for Extensions.
1956    
1957     * Thuban/UI/extensionregistry.py: This module defines a registry for
1958     Extensions.
1959    
1960     * Thuban/UI/about.py (About.__init__): Added description
1961     of the registered extensions with all of the information.
1962    
1963     * Thuban/Model/extension.py (Extension): Improved doc-string.
1964    
1965     * Extensions/gns2shp/gns2shp.py, Extensions/importAPR/importAPR.py,
1966     Extensions/bboxdump/bboxdump.py, Extensions/profiling/profiling.py,
1967     Extensions/wms/wms.py: Added registration of the extension.
1968    
1969 bernhard 2352 2004-09-27 Bernhard Reiter <[email protected]>
1970    
1971     More fixes to svgexport to make used ids unique and
1972     conforming to XML's Name production.
1973    
1974     * Extensions/svgexport/test/test_svgmapwriter.py: Added new tests
1975     test_xml_id_constraints(), test_make_ide_nosetbaseid() and
1976     test_make_id_nonintegersetid(). Switched SetID and SetBaseID.
1977     Added Bernhard R. as author.
1978     * Extensions/svgexport/svgmapwriter.py (make_id): Using "_" as
1979     concatenation char now (makes test_make_ide_nosetbaseid() valid).
1980     Also transform second id part with "%d" and catch the TypeError
1981     to raise SVGMapWriterError (making test_make_id_nonintegersetid() ok).
1982     Corrected typo inBernhard's author line.
1983     (SetBaseID): Return the transformed base id. Transform characters
1984     which are not alnum() or in ".-_" to binascii.b2a_hex(). Added
1985     import binascii. If to be set string starts with "xml" or so, add "t".
1986     (draw_shape_layer_incrementally): use the returned value of SetBaseID
1987     for used_baseids checks.
1988    
1989 bh 2351 2004-09-25 Bernhard Herzog <[email protected]>
1990    
1991     * test/test_layer.py (TestLayer.test_arc_layer_with_projection):
1992     Remove a debug print and some tab characters.
1993    
1994 bernhard 2350 2004-09-25 Bernhard Reiter <[email protected]>
1995    
1996     * Extensions/svgexport/svgmapwriter.py: Added Bernhard R. as Author.
1997     (SetBaseID, SetID, make_id): Improved docstring comments to explain
1998     the interaction of the three functions and the XML id contrains.
1999    
2000 bernhard 2352
2001 jan 2346 2004-09-23 Jan-Oliver Wagner <[email protected]>
2002    
2003 jan 2349 * Doc/ThubanModel.xmi: New. UML file for Thuban Model
2004     Module.
2005    
2006     * Doc/README: Added info on ThubanModel.xmi.
2007    
2008     2004-09-23 Jan-Oliver Wagner <[email protected]>
2009    
2010 jan 2346 * Doc/README: New. Some info about how to generate technical
2011     documentation from the source code.
2012     This text was send to the Thuban developer mailing list on
2013     September 21st 2004 by Bernhard Reiter.
2014    
2015 bernhard 2344 2004-09-21 Bernhard Reiter <[email protected]>
2016    
2017     Improved the svgexport to only use unique ids. Will issues
2018     an error message dialoge when two layer names are the same.
2019     ShapeIDs are now added with a dash within the svg ids.
2020    
2021     * Extensions/svgexport/svgmapwriter.py (SVGMapWriterError): New.
2022     * Extensions/svgexport/test/test_svgmapwriter.py: Added imports
2023     (TestSVGRenderer): New test class with test_make_in() and
2024     test_check_for_layer_name_clash()
2025     * Extensions/svgexport/svgmapwriter.py (SVGRenderer): Fixed __init__()
2026     and draw_shape_layer_incrementally() to not use a baseid twice,
2027     satisfying test_check_for_layer_name_clash()
2028     (VirtualDC.make_id): Use a dash between baseit and id, satisfies
2029     test_make_in().
2030     * Extensions/svexport/svgsaver.py: Import SVGMapWriterError, wxOK
2031     and wxICON_HAND.
2032     (write_to_svg): Put dc and rendering in a try statement and on
2033     catching SVGmapWriterError notify the user and delete the target file.
2034    
2035 bernhard 2343 2004-09-20 Bernhard Reiter <[email protected]>
2036    
2037     * Model/base.by, Model/layer.py: Fixed typos in docstrings.
2038    
2039 jschuengel 2342 2004-09-03 Jan Schüngel <[email protected]>
2040    
2041     * Extensions/umn_mapserver/mapfile(MF_Class.add_thubanstyle): Fix a
2042     small bug with the line color. Now the line color will now only set
2043     if it is set in Thuban an not Transparent.
2044    
2045     * Extensions/umn_mapserver/mf_export(tblayer_to_map): Fixed a bug with
2046     deleting the layers from mapfile. Now all layers will delete backwards
2047     from the last.
2048    
2049 silke 2339 2004-08-20 Silke Reimer <[email protected]>
2050 silke 2338
2051 silke 2339 * Thuban/Model/layer.py:
2052     Fixes bug in projection handling: Otherwise very large region might not
2053     have valid values in the layer's projection.
2054    
2055     2004-08-20 Silke Reimer <[email protected]>
2056    
2057 silke 2338 * Thuban/UI/about.py:
2058     small changes to be consistent with coding style.
2059    
2060 joey 2337 2004-08-13 Martin Schulze <[email protected]>
2061    
2062     * Extensions/wms/test/test_ogclib.py (TestOGCLib.compare_URLs):
2063     Adjusted a comment
2064    
2065 silke 2335 2004-08-11 Silke Reimer <[email protected]>
2066 silke 2334
2067 silke 2335 * Thuban/UI/about.py: Small changes to encoding related stuff to avoid
2068     too many and too enhanced imports of locale
2069    
2070 silke 2334 2004-08-10 Silke Reimer <[email protected]>
2071    
2072     * Thuban/UI/about.py: Fixed encoding problem of about dialog: Added
2073 silke 2339 function unicodeToLocale() to convert special characters to users
2074     locale encoding
2075 silke 2334
2076 jan 2333 2004-08-10 Jan-Oliver Wagner <[email protected]>
2077    
2078     * Doc/technotes/coding_guidelines.txt: Added rule 'Method names start with
2079     lower case letter'
2080    
2081 jschuengel 2331 2004-08-09 Jan Schüngel <[email protected]>
2082    
2083     * ChangeLog: Rewrite the last ChangeLog entry to follow
2084     the standard way.
2085    
2086     * Extensions/umn_mapserver/mapfile: Moved the import AnnotationLayer to
2087     the function where it is needed, because it don't works if it stands
2088     at the beginning.
2089     (MF_Layer.__init__): Removed the extra numclassed variable. Now
2090     numclasses from the mapscript will be used.
2091     (MF_Layer.get_index): New. Return the index of the layer in mapfile.
2092     (MF_Layer.set_classes): New. A Classlist will be set to the layer.
2093     (MF_Layer.set_metadata): New. A Metadata mapscript object will set.
2094     (MF_Layer.remove_allclasses): New. All class of the layer will remove.
2095     (MF_Map.create_new_layer): New. A new Layer is created and associated
2096     with the mapscript object.
2097     (MF_Map.set_layerorder): New. The Layer order like in thuban is set in
2098     the mapscript.
2099     (MF_Map.add_thubanlayer): Now a new layerobj is created if no one is
2100     linked to the layer in thuban, else the layerobject linked to the
2101     thubanlayer will be used.
2102     AnnotationLayer will now store the filename of the shapefile.
2103     (MF_Map.remove_layer): If a layer is removed the associated object
2104     must be set new.
2105    
2106     * Extensions/umn_mapserver/mf_export.py(tb_layer_to_map): Add all
2107     layers which are exists in thuban to the mapobj. All removed Layers
2108     will be removed from the mapobj.
2109     Added comments to all functions.
2110     (thuban_to_map): No layer will be removed here.
2111    
2112     * Extensions/umn_mapserver/mf_handle.py
2113     (_has_umn_mapobj_and_selectedlayer): Activating the layer menu. Now
2114     Layersettings for the mapserver kann be edited.
2115    
2116     * Extensions/umn_mapserver/mf_import.py: Now all layers which are
2117     imported, will be linked with the associated MF_Layer.
2118     (import_mapfile): All layers, which are not selected, will be removed.
2119     Disable the "import layer from mapfile" menu option.
2120    
2121     * Extensions/umn_mapserver/sample/iceland.map: Set the status of the
2122     Annotation Layer from DEFAULT to OFF. The DEFAULT setting turns the
2123     layer on permanently.
2124    
2125 jschuengel 2323 2004-08-03 Jan Schüngel <[email protected]>
2126    
2127 jschuengel 2331 * Extensions/umn_mapserver/mapfile.py(MF_Metadata.remove_allmetadata):
2128     New. This function removes all metadata
2129     (MF_Layer.set_group): New. Set the group setting.
2130     (MF_Layer.get_group): New. Get the group setting.
2131     (MF_Map): Removed the extra numlayers variable, used the mapscript
2132     parameter instead.
2133     (MF_Map.get_numlayers): New. This get numlayers.
2134     (MF_Map.remove_all_layers): New. Removes all layers from the mapobj.
2135 jschuengel 2323 (MF_Map.add_thubanlayer): Replaced the exception handling by a check
2136     if the object is an instance. Also added the annotation layer here to
2137     export, but only the layer is created in the mapfile.
2138    
2139 jschuengel 2331 * Extensions/umn_mapserver/mf_export.py(export_mapfile): Removed
2140     the check if a mapobj exist, because its not needed anymore. The
2141     export function is only available if a mapobj exist.
2142     Use the new function to remove all layers.
2143 jschuengel 2323
2144 jschuengel 2331 * Extensions/umn_mapserver/mf_handle.py(Layer_Dialog): Added a group
2145     option and the metadata button. The layer dialog is temporary disabled.
2146     (Metadata_CustomDataTable): Added some functions to show the grid
2147 jschuengel 2323 correct.
2148    
2149 jschuengel 2331 * Extensions/umn_mapserver/mf_import.py: Moved the code for showing
2150     the number of layer from import_mapfile to this function.
2151     (AnnotationLayer): New. This Class shows the Annotation layer in
2152     thuban. The layer don't do anything. It's only to show the layer
2153     and to save the layer order.
2154     (add_annotationlayer): New. Import an annotation layer to thuban.
2155     (select_layer2import): New. Import only layers to thuban and not
2156     the other settings like projection or scalebar.
2157     (create_new_mapfile): Moved the _has_umn_mapobj function and the
2158     create_new_mapfile functions from mf_handle.py to mf_import.py.
2159 jschuengel 2323
2160     * Extensions/umn_mapserver/sample/iceland.map: Added the group
2161     parameter to the roads and cultural layers. Also added a new
2162     Annotation Layer for the cultural points.
2163    
2164     * Extensions/umn_mapserver/sample/iceland.html: Added the select
2165     option for the annotation layer.
2166    
2167     * Extensions/umn_mapserver/sample/index.html: Added the start
2168     parameter for the annotation layer.
2169    
2170 jan 2315 2004-08-01 Jan-Oliver Wagner <[email protected]>
2171    
2172     * Doc/manual/thuban-manual-de.xml (Chapter Session Management):
2173     translation completed.
2174    
2175     * Doc/manual/thuban-manual.xml (Chapter Session Management):
2176     Fixed unprecise description for Save Session.
2177    
2178 jan 2312 2004-07-31 Jan-Oliver Wagner <[email protected]>
2179    
2180     Started translation of Users Manual into german.
2181    
2182     * Doc/manual/thuban-manual-de.xml: New. German Users Manual.
2183    
2184     * Doc/manual/Makefile: Added build instructions for german
2185     users manual.
2186    
2187     * Doc/manual/thuban-manual.xml: Minor corrections in Introduction.
2188    
2189 jschuengel 2308 2004-07-28 Jan Schüngel <[email protected]>
2190    
2191     * Extensions/umn_mapserver/mapfile.py(MF_Metadata): Changed all class
2192     functions. Now all metadata will handle by the function and its not
2193     needed to initialize it from outside. Therefor the associated mapobj
2194     will be stored in the Metadata Object. So we can use the special
2195     functions from the associated mapobj to get the Metadata.
2196     Therefor all initialization code for the metadata is removed from the
2197     other classes.
2198     (MF_Layer): Added a function to get the metadata object.
2199     (MF_Map): Added a function to set the mappath, the path where
2200     the mapfile ist stored.
2201    
2202     * Extensions/umn_mapserver/mf_export.py(thuban_to_map): Changed the code
2203     to set the extent in the mapfile. Now the code is set by the displayed
2204     data in the Thuban-view.
2205     (export_mapfile): The shapepath is now set empty, until relative
2206     pathnames are supported.
2207    
2208     * Extension/umn_mapserver/mf_handle.py: Added a dialog to handle
2209     metadata. Yet only mapfile metadata are supported. Layer and class
2210     supported are not implemented.
2211     Added a dialog to handle layer informations. The dialog only shows the
2212     selected layer at the moment.
2213    
2214     * Extensions/umn_mapserver/mf_import.py(import_mapfile): Changed the
2215     code for setting the extent in thuban. Now the extent is set to the
2216     given extent from the mapfile.
2217     Fixed a logical mistake. Now the extent is set when realy a layer is
2218     loaded, and not if one is selected to load.
2219    
2220     * Extensions/umn_mapserver/sample/iceland.html: Added code to zoom and
2221     move the shown map in the browser.
2222    
2223     * Extensions/umn_mapserver/sample/iceland.map: Added a new metadata
2224     line to the mapobj and added metadata to the political layer.
2225    
2226     * Extensions/umn_mapserver/test/test_mapserver.py: Changed the test
2227     for Metadata.
2228    
2229 joey 2300 2004-07-26 Martin Schulze <[email protected]>
2230    
2231     * Thuban/Lib/classmapper.py (ClassMapper.has): Added the new
2232     ClassMapper
2233    
2234     * test/test_classmapper.py (TestMapping.test_mapper): Added a Test
2235     case for the new ClassMapper
2236    
2237    
2238 bh 2296 2004-07-22 Bernhard Herzog <[email protected]>
2239    
2240 bh 2297 * Thuban/UI/viewport.py (ViewPort.VisibleExtent): New. Return the
2241     visible extent of the map in projected coordinates
2242    
2243     * test/test_viewport.py (SimpleViewPortTest.test_default_size)
2244     (SimpleViewPortTest.test_init_with_size): Add some VisibleExtent()
2245     tests.
2246     (SimpleViewPortTest.test_visible_extent): New. The real test for
2247     VisibleExtent()
2248    
2249     2004-07-22 Bernhard Herzog <[email protected]>
2250    
2251 bh 2296 * test/test_viewport.py: Use support.run_tests as the main
2252     function when running asa script.
2253    
2254 jschuengel 2295 2004-07-22 Jan Schüngel <[email protected]>
2255    
2256     * Extensions/umn_mapserver/mf_export.py: Added "import os"
2257     Removed the old "import Thuban.UI.mainwindow" code.
2258     (tbextent_to_map): Removed the extra function and at the code direct
2259     to "thuban_to_map" function.
2260     (write_creatorcomment): Added. Now a short comment is added to the
2261     beginning of an generated mapfile.
2262     (export_mapfile): Now the Path and filename are saved in to variables,
2263     and not together in one variable. This is needed for the new
2264     write_creatorcomment function.
2265    
2266     * Extensions/umn_mapserver/mf_import.py (import_mapfile): Added the
2267     import module "re". Also added Range and the ClassGroupRange import
2268     from Thuban. Both are needed for the new range expression import.
2269     (create_rangeexpression): Added. Creates a Range Expression in Thuban
2270     style from a given mapfile expression.
2271     (added_rasterlayer): Make some small code changes. The shapepath is
2272     now stored in an extra variable and the clazz_name is set empty if no
2273     class name set in the mapfile.
2274     Changed the Error message for Range Expressions, becaus the new
2275     function create a error string which will be shown in the dialog.
2276    
2277     * Extensions/umn_mapserver/test/test_mapserver.py: Added a test for the
2278     range expression import.
2279 jan 2312
2280 jan 2291 2004-07-21 Jan-Oliver Wagner <[email protected]>
2281    
2282     * Extensions/umn_mapserver/README: Added hint that
2283     installation as root can be avoided. Removed all tabs.
2284    
2285 bh 2289 2004-07-16 Bernhard Herzog <[email protected]>
2286    
2287     * test/test_viewport.py
2288     (ViewPortTest.test_changing_map_projection): Check that changing
2289     the projection of an empty map shown in a viewport doesn't lead to
2290     exceptions in the viewport's handler for the
2291     MAP_PROJECTION_CHANGED messages
2292    
2293     * Thuban/UI/viewport.py (ViewPort.map_projection_changed): Only
2294     try to keep the same region visible when the map actually contains
2295     something
2296    
2297 jschuengel 2288 2004-07-15 Jan Schüngel <[email protected]>
2298    
2299     * Extensions/umn_mapserver/mapfile.py: Added a function to get the
2300     mappath directly from the mapobj. Is needed because of the changes
2301     in mf_import.py.
2302     (MF_Layer.add_thubanclass): Added a new comment.
2303     (MF_Map.set_extent): Fixed a bug with exporting empty mapobj. If the
2304     mapobj is empty there is no extent get from thuban an so no one can
2305     set to th mapobj.
2306    
2307     * Extensions/umn_mapserver/mf_import.py (import_mapfile): Updated
2308     the discription.
2309     Split the funktion in to three smaller ones. The new functions are
2310     add_rasterlayer, add_polygonlayer and select_layer2import.
2311     Removed the mapfilepath and filepath initialisation, because its know
2312     include in the new functions.
2313     Now nothing will be imported if cancel is pressed in the
2314     layer choice dialog.
2315    
2316 jschuengel 2285 2004-07-14 Jan Schüngel <[email protected]>
2317    
2318     * Extensions/umn_mapserver/mapfile.py: Added ClassGroupDefault to
2319     import.
2320     (MF_Symbolset): Removed the extra variable for numsymbols.
2321     (MF_Class.__init__): Added a comment to the exception clause.
2322     Removed the extent init, because it was not needed anymore.
2323     (MF_Layer.add_thubanclass): Added the code to set the class name to
2324     the expression value from thuban if no label is defined.
2325     Added the code to export Range expressions from thuban to the mapfile.
2326     (MF_Map.set_extent): Removed the exception and replace it by some if
2327     code. If the size of a map is not defined the size will be set to 1,1.
2328     This is necessary because if the extent is set, mapscript checks if
2329     the size is greater than zero.
2330     (MF_Web): Added the get and set function for the template.
2331    
2332     * Extensions/umn_mapserver/mf_export.py: Added the function to check
2333     if a mapobject exists and used it to set the status of the menu items.
2334     If no mapfile exists the settings could not be edditied.
2335     Define after which menuitem the exportitem will include.
2336    
2337     * Extensions/umn_mapserver/mf_handle.py: Removed the import
2338     Thuban.UI.mainwindow clause, because it is not needed.
2339     Added the command Refresh() to all "OnChangeColor()" functions,
2340     because the color preview window was not updated on a color change.
2341     Added the function to check if a mapobject exists and used it to set the
2342     status of the menu items. If no mapobject exists the settings could not
2343     be edditied.
2344     (Map_Dialog): Moved the imagetype selector from the
2345     Outputformat_Dialog to Map_Dialog and removed Outputformat_Dialog.
2346     (Web_Dialog): Removed the name label and added the template textbox.
2347    
2348     * Extensions/umn_mapserver/mf_import.py (import_mapfile): Replace
2349     the exception handling on loading the layers by an if statement. It
2350     is not necessary to us the exception there.
2351     The Filepath creation now use os.path.join to build the path.
2352    
2353     * Extensions/umn_mapserver/test/test_mapserver.py: Moved the testMap
2354     definition from global to the setUp function. Now the testMap will
2355     initialize new on each test.
2356    
2357     * Extensions/umn_mapserver/sample/iceland.map: Include three new
2358     classes in the Line Layer, to test logical Expressions.
2359     Set the status of the class "Point9" in the Point Layer to off
2360    
2361 bh 2278 2004-07-13 Bernhard Herzog <[email protected]>
2362    
2363     * Thuban/UI/baserenderer.py
2364     (BaseRenderer.render_map_incrementally): Fix a logic bug in the
2365     optimization that tries not to draw layers under a raster layer.
2366     The bug was harmless. All it effectively did was to produce The a
2367     strange messages about not being able to draw Layer instances for
2368     all vector layers below a raster layer which would be invisible
2369     anyway because the raster layer currently always covers the entire
2370     window
2371    
2372 jschuengel 2277 2004-07-08 Jan Schüngel <[email protected]>
2373    
2374     * Extensions/umn_mapserver/mapfile.py: Added code to generade and get
2375     a list of supported outputformats. This formats are not alle supported
2376     because there is no possibility to get the outputformat without the
2377     name known. Make some formal changes to the code.
2378     (MF_Map.set_name()): Fixed a bug if the name is None.
2379    
2380     * Extensions/umn_mapserver/mf_handle.py: Removed the image_type import
2381     statement, because its not needed anymore. The Outputformat is now
2382     given as string from the object. Make some formal changes to the code.
2383    
2384     * Extensions/umn_mapserver/test/test_mapserver.py: Added new test for
2385     most of the new setting which were added during the last changes.
2386     Removed the MF_Size Test.
2387    
2388     * Extensions/umn_mapserver/test/test.map: Added a new class to the
2389     cultural Layer to test expressions and the the status of that layer
2390     from on to default.
2391     Changed the data path the the correct Thuban Data
2392     Added the Outputformat Object and Symbol Object
2393    
2394 jschuengel 2272 2004-07-07 Jan Schüngel <[email protected]>
2395    
2396     * Extensions/umn_mapserver/mapfile.py: Added some new
2397     settings to edit (outputformat, label, imagetype)
2398    
2399     * Extensions/umn_mapserver/mf_handle.py: Added some setting to
2400     the Label Dialog and add the OutputDialog.
2401     Make some changes to the code order.
2402    
2403 jschuengel 2269 2004-07-06 Jan Schüngel <[email protected]>
2404    
2405     * Extensions/umn_mapserver/mapfile.py: Added the symbolObj, pointObj
2406     and line Obj and add the scalebar_status_type, scalebar_style_type and
2407     scalebar_position_type.
2408     Added the symbol- and symbolsetObject (MF_Symbol,MF_Symbolset). The
2409     are only used to create a Symbol like the circle in Thuban.
2410     Added the scalebarObject (MF_Scalebar)
2411     (MF_Class): Added set_status and get_status.
2412     (MF_Layer.add_thubanclass): Added code to set the class status
2413     (MF_Map): Added code to handle the symbols and scalebar
2414     (MF_Label): Added the set_partials and get_partials functions
2415    
2416     * Extensions/umn_mapserver/mf_export.py: Added MF_Symbol to import
2417     from mapfile. Added a function to create a circle object like the one
2418     from thuban if no one exists.
2419    
2420     * Extensions/umn_mapserver/mf_handle.py: All colors are now set when
2421     press ok in the assosiated dialog and not at the end of the
2422     colordialog.
2423     Added the Dialog for the Scalebar.
2424     (Label_Dialog): Added the offset option
2425    
2426     * Extensions/umn_mapserver/mf_import.py: Added code to import the
2427     status of the Classes.
2428     Fixed a bug with the projection. Now the to_meter parameter will be
2429     added to the Projection only if it doesn't exists.
2430    
2431 jschuengel 2264 2004-07-01 Jan Schüngel <[email protected]>
2432    
2433     Added the functionality to handle the content thuban is not
2434     able to handle directly.
2435    
2436     * Extensions/umn_mapserver/mf_handle.py: New. This module extents
2437     Thuban with the possibility to edit the mapfile content.
2438    
2439     * Extensions/umn_mapserver/mf_import.py: Added the possibility
2440     to import mapfiles without any layer selected. So it is possible
2441     to edit the other settings in a mapfile.
2442     (import_mapfile): Added code to use the editing functions.
2443     Added the possibility to import the projection to a layer if one
2444     is defined.
2445     Status settings (On,Off) will now set in thuban (visible, invisible).
2446     fixed a bug with with classnames. If no classname is set in mapfile
2447     the value in Thuban will set to the expression.
2448    
2449     * Extensions/umn_mapserver/mf_export.py(export_mapfile): Added the
2450     possibility to save a new mapfile or use the old one which is
2451     imported or new created.
2452     Added code to use the editing functions.
2453     Remove some not needed import statements
2454    
2455     * Extensions/umn_mapserver/mapfile.py: Added new types which are
2456     need for the editing functions.
2457     Added needed set-functions for the editing functions.
2458     Added the possibility to export rasterimages.
2459     Added new classes (MF_Web, MF_Label, MF_Legend, MF_Symbol,
2460     MF_SymbolSet). MF_Symbol and MF_SymbolSet are not needed at the
2461     moment.
2462     (MF_Class.set_thubanstyle): Now point layers will set to a default
2463     symbol to show a circle in mapserver and not only a 1px dot.
2464     (MF_Style.__init__): Fixed a bug with the color. Color was not set
2465     correct before.
2466     (MF_Size): Removed, because it is not needed.
2467    
2468     * Extensions/umn_mapserver/README: Added the hints to use the
2469     export and editing functions, too.
2470    
2471     * Extensions/umn_mapserver/sample/iceland.map: Added the
2472     new parameter "UNITS METERS".
2473     Change the political layer to status OFF.
2474    
2475     * Extensions/umn_mapserver/sample/README: Added some
2476     more details to setup the sample in the MapServer.
2477    
2478 bernhard 2256 2004-06-26 Bernhard Reiter <[email protected]>
2479    
2480     * Extensions/svgexport/test/test_svgmapwriter.py:
2481     Removed class VFile and used standard StringIO instead.
2482    
2483 jschuengel 2255 2004-06-23 Jan Schüngel <[email protected]>
2484    
2485     Add the export function to the umn_mapserver extension.
2486    
2487     * Extension/umn_mapserver/mf_export.py: New. This module extents
2488     Thuban with the possibility to export the Thuban content.
2489    
2490     * Extensions/umn_mapserver/mapfile.py: Expand the classes to use
2491     with the export module. Especially added the possibility to
2492     add thuban objects directly to the map objects.
2493    
2494     * Extensions/umn_mapserver/mf_import.py: Removed the wxCHANGE_DIR,
2495     because of the hint from Bernhard Herzog.
2496     Corrected the handling of absolute pathnames.
2497     Changed the Text of the Menu-Item, now the beginning is upper case.
2498    
2499     * Extensions/umn_mapserver/README: Added the --with-tiff statement.
2500    
2501 jschuengel 2250 2004-06-16 Jan Schüngel <[email protected]>
2502 jschuengel 2242
2503 jschuengel 2250 Add a sample and make some changes.
2504    
2505     * Extension/umn_mapserver/mf_import.py: Changed the wxPython.wx
2506     import from * to explicit used statements. Changed the
2507     Thuban.UI.mainwindow import phrase, too.
2508     (import_mapfile):Corrected a clerical mistake.
2509     Added wxCHANGE_DIR in OpenFile Dialog.
2510     Added a MultipleChoiceDialog, to select the layers to load from
2511     mapfile into thuban. Thereby the projection is only set if one layer
2512     is selected.
2513     Added the possibility to handle relative pathnames which uses
2514     up-level references.
2515     Removed some doubled code.
2516     Corrected an error with integer values used as label in thuban
2517     ClassGroup.
2518    
2519     * Extensions/umn_mapserver/sample: New.
2520    
2521     * Extensions/umn_mapserver/sample/README: New. Describes the
2522     usage of the sample files.
2523    
2524     * Extensions/umn_mapserver/sample/iceland.map: New. This is
2525     a suitable .map-file for the iceland data.
2526    
2527     * Extensions/umn_mapserver/sample/index.html: New. The template
2528     for the mapfile.
2529    
2530     * Extensions/umn_mapserver/sample/iceland.html: New. Initialisation
2531     file for the Iceland Application on web.
2532    
2533     * Extensions/umn_mapserver/README: Corrected a inaccuracy and added
2534     some details.
2535    
2536     * Extensions/umn_mapserver/test/test_mapserver
2537     (mapserver_import_Test_generalClasses.test_MF_Color):
2538     Corrected the thubancolor test.
2539    
2540     2004-06-15 Jan Schüngel <[email protected]>
2541    
2542 jschuengel 2242 * Extensions/umn_mapserver/README: New. Install instruction.
2543    
2544 bernhard 2240 2004-06-14 Bernhard Reiter <[email protected]>
2545    
2546     * libraries/thuban/cpl_mfile.h: Added copyright header.
2547    
2548     * libraries/thuban/ cpl_mfile.cpp, cpl_mfile.h: Added non-protecting
2549     Free Software License so that it is most useful with gdalwarp
2550     and bmpdataset.
2551    
2552 bh 2239 2004-06-14 Bernhard Herzog <[email protected]>
2553    
2554     * Thuban/UI/multiplechoicedialog.py (__version__): Add missing
2555     import of wxPython.wx itself (as opposed to the contents of
2556     wxPython.wx). For some reason wxPython.wx is available as
2557     wxPython.wx.wx in at least some 2.4 releases. Fixes RT#2482
2558     wrt. wxPython 2.4.
2559    
2560 jschuengel 2238 2004-06-10 Jan Schüngel <[email protected]>
2561    
2562     Initial version of new extension "umn_mapserver". This extension aims
2563     to manage configuration for the UMN MapServer application. This
2564     inital version just imports the .map-files and displays all, Thuban is
2565     capable of.
2566    
2567     * Extensions/umn_mapserver, Extensions/umn_mapserver/test: New.
2568    
2569     * Extensions/umn_mapserver/test/README: New. Describes how to run the
2570     tests.
2571    
2572     * Extensions/umn_mapserver/test/test.map: New. This is a test
2573     .map-file for automated tests of the umn_mapserver extension of
2574     Thuban.
2575    
2576     * Extensions/umn_mapserver/test/test_mapserver.py: New. Tests for
2577     UMN Mapserver classes.
2578    
2579     * Extensions/umn_mapserver/__init__.py: New. Init to make this
2580     directory a package.
2581    
2582     * Extensions/umn_mapserver/mapfile.py: New. Classes to represent
2583     '.map'-file objects.
2584    
2585     * Extensions/umn_mapserver/mf_import.py: New. This module extends
2586     Thuban with the possibility to handle UMN MapServer mapfiles.
2587    
2588 bh 2230 2004-06-03 Bernhard Herzog <[email protected]>
2589    
2590     * Thuban/Model/layer.py (Layer.TreeInfo): Convert the bounding box
2591     to a tuple before using it as arguments to the % operator. This
2592     fixes the formatting issue filed in RT#2239 on 2004-01-13 and
2593     reported today on thuban-list by Jan Schüngel
2594    
2595     * test/test_layer.py (TestLayerModification.setUp): Save the
2596     filename as an instance variable so we can refer to it in tests
2597     (TestLayerModification.test_tree_info): Uncomment this method
2598     again and make it work. This tests for the formatting issue
2599     filed in RT#2239 on 2004-01-13
2600    
2601 bh 2224 2004-05-28 Bernhard Herzog <[email protected]>
2602    
2603     * Thuban/UI/baserenderer.py: Fix some typos.
2604    
2605 jan 2217 2004-05-18 Jan-Oliver Wagner <[email protected]>
2606    
2607     * Extensions/gns2shp/gns2shp.py (gns2shp): Fixed a bug
2608     by increasing a field size.
2609    
2610 bh 2213 2004-05-17 Bernhard Herzog <[email protected]>
2611    
2612     Update to newest shapelib and get rid of Thuban specific
2613     extensions, i.e. use the new DBFUpdateHeader instead of our
2614     DBFCommit kludge
2615    
2616     * libraries/shapelib/shpopen.c: Update to version from current
2617     shapelib CVS.
2618    
2619     * libraries/shapelib/shapefil.h: Update to version from current
2620     shapelib CVS.
2621    
2622     * libraries/shapelib/dbfopen.c: Update to version from current
2623     shapelib CVS.
2624     (DBFCommit): Effectively removed since shapelib itself has
2625     DBFUpdateHeader now which is better for what DBFCommit wanted to
2626     achieve.
2627     We're now using an unmodified version of dbfopen.
2628    
2629     * setup.py (extensions): Add the HAVE_UPDATE_HEADER macro with
2630     value '1' to the Lib.dbflibc extension. This simply reflects the
2631     shapelib and pyshapelib updates
2632    
2633 jan 2211 2004-05-16 Jan-Oliver Wagner <[email protected]>
2634    
2635     Finished introduction of Menu.FindOrInsertMenu.
2636    
2637     * Extensions/drawshape/drawshape.py: Add the command
2638     to the experimental menu additionally to the toolbar.
2639    
2640     * Extensions/svgexport/svgsaver.py: Use FindOrInsertMenu() instead of
2641     finding menu on its own.
2642    
2643     * Doc/manual/thuban-manual.xml: updated sample file
2644     to use FindOrInsertMenu().
2645    
2646     * Examples/simple_extensions/hello_world.py: Use FindOrInsertMenu()
2647     instead of finding menu on its own.
2648    
2649 jan 2206 2004-05-11 Jan-Oliver Wagner <[email protected]>
2650    
2651     * test/test_menu.py (MenuTest.test): Added testing
2652     of method Menu.FindOrInsertMenu.
2653    
2654 jan 2204 2004-05-10 Jan-Oliver Wagner <[email protected]>
2655    
2656     Introduce and use Menu.FindOrInsertMenu.
2657    
2658     * Thuban/UI/menu.py (Menu.FindOrInsertMenu): New. Find a
2659     given menu or, if not found, insert it.
2660    
2661     * Extensions/bboxdump/bboxdump.py, /Extensions/gns2shp/gns2shp.py,
2662     /Extensions/importAPR/importAPR.py, Extensions/profiling/profiling.py,
2663     /Extensions/wms/wms.py: Use FindOrInsertMenu() instead of finding
2664     menu on its own.
2665    
2666 jan 2201 2004-05-06 Jan-Oliver Wagner <[email protected]>
2667    
2668     Introduce a abstract ColorDialog class and remove
2669     and outdated file.
2670    
2671     * Thuban/UI/proj4dialog.py: Removed. It is has been
2672     replaced by projdialog for quite a while and is not used
2673     anymore.
2674    
2675     * Thuban/UI/colordialog.py: New. Abstraction for color selection
2676     dialog(s).
2677    
2678     * Thuban/UI/classifier.py (SelectPropertiesDialog.__GetColor):
2679     Now calls the abstract ColorDialog instead of wxColourDialog.
2680     This also removed the dependency to Color class conversion
2681     from this function.
2682    
2683 frank 2197 2004-05-04 Frank Koormann <[email protected]>
2684    
2685     * Extensions/bboxdump/__init__.py: Fixed string left over from
2686     copying.
2687    
2688     * Extensions/bboxdump/bboxdump.py (bboxdump):
2689     Use layer.ShapeStore().AllShapes() to loop over shapes instead of
2690     xrange(layer.NumShapes()). Compile the bboxmessage from a list
2691     of formatted outputs (string.join) instead of appending to the
2692     message. Two progress bar dialogs to report progress on the sometimes
2693     lenghty processing.
2694    
2695 frank 2196 2004-04-22 Frank Koormann <[email protected]>
2696    
2697     New Extension to dump bounding boxes of all shapes of the selected
2698     layer. An optional column can be specified to group the objects,
2699     in this case the bounding box is a union of the separate boxes.
2700     Dump can be displayed in a ScrolledMessageDialog or written to file.
2701     The Extension is simply a combination of available and well tested
2702     Thuban functionality.
2703    
2704     * Extensions/bboxdump/__init__.py: New: Init to make this
2705     directory a package.
2706    
2707     * Extensions/bboxdump/bboxdump.py: New: Dump bounding boxes of
2708     all shapes of the selected layer.
2709    
2710 jan 2192 2004-04-22 Jan-Oliver Wagner <[email protected]>
2711    
2712     * Thuban/UI/classgen.py (GenUniquePanel.__init__): Fixed two
2713     strings to be i18n now.
2714    
2715 jan 2188 2004-04-18 Jan-Oliver Wagner <[email protected]>
2716    
2717     Changing popup menu of legend from direct building
2718     to using the Menu construction as used for the mainwindow.
2719    
2720     * Thuban/UI/mainwindow.py: New method commands: layer_to_top,
2721     layer_to_bottom, layer_visibility
2722     (MainWindow.LayerToTop): New. Put current layer to the top.
2723     (MainWindow.LayerToBottom): New. Put current layer to bottom.
2724     (MainWindow.HideLayer, MainWindow.ShowLayer, _has_visible_map):
2725     Replace 1,0 by True, False.
2726     (MainWindow.ToggleLayerVisibility): New. Toggle visibility of
2727     current layer.
2728     (MainWindow.LayerShowTable): Removed raising of dialog.
2729     (_has_selected_layer_visible): New. Support function.
2730    
2731     * Thuban/UI/legend.py: ID_POP_xxx: removed.
2732     (LegendPanel.__init__): Removed EVT_MENU bindings.
2733     (LegendTree._OnRightClick): Replace direct creation of
2734     menu via wx Classes by applying the menu definition
2735     as of Menu class of menu.py.
2736    
2737 jan 2185 2004-04-16 Jan-Oliver Wagner <[email protected]>
2738    
2739     * Thuban/UI/exceptiondialog.py (ExceptionDialog.dialog_layout): Improved
2740     button string to stronger clearify that Thuban will be closed when hitting
2741     the button.
2742    
2743     * Thuban/UI/mainwindow.py (MainWindow.LayerShowTable): Added docstring.
2744     Now for layers without a ShapeStore a corresponding message is given
2745     to the user, that this layer has no table to show.
2746    
2747 joey 2182 2004-04-15 Martin Schulze <[email protected]>
2748    
2749     * Extensions/wms/layer.py (WMSLayer.setWMSFormat): Need to
2750     recalculate the format for the internal render engine as well.
2751    
2752     * Extensions/wms/properties.py (wmsProperties): First start for a
2753     properties dialog. It's functional for a first selection of
2754     layers, but still has some weired wxWidgets/GTK problems but
2755     beautification can be done later.
2756    
2757     * Extensions/wms/layer.py: Added more documentation
2758     (WMSLayer.getFormats): New: Return list of supported image formats
2759     by the WMS server
2760     (WMSLayer.getLayers): New: Return the list of layer names
2761     supported by the WMS server
2762     (WMSLayer.getLayerTitle): New: Return the title of the named layer
2763     (WMSLayer.getWMSFormat): New: Return the image format that is used
2764     for WMS GetMap requests
2765     (WMSLayer.setWMSFormat): New: Set the image format that is used
2766     for WMS GetMap requests
2767     (WMSLayer.__init__): Move away from using only one layer to using
2768     a list of layers (unsorted at the moment, though).
2769     (WMSLayer.getVisibleLayers): New: Return the list of names for all
2770     visible layers
2771     (WMSLayer.setVisibleLayers): New: Set the list of names for all
2772     visible layers
2773    
2774     * Extensions/wms/wms.py: Moved the WMS layer into layer.py in
2775     order to establish a clean structure.
2776    
2777     * Extensions/wms/layer.py: Moved the WMS layer into a file on its
2778     own in order to establish a clean structure.
2779    
2780 joey 2174 2004-04-13 Martin Schulze <[email protected]>
2781    
2782     * Extensions/wms/parser.py (WMSCapabilitiesParser.grok): Added
2783     support for oldstyle (WMS 1.0 apparently) image format
2784     specification.
2785    
2786     * Extensions/wms/wms.py (WMSLayer.calcFormat): Reduce the list of
2787     supported graphic formats back to JPEG and BMP, PNG and others are
2788     too *cough* experimental... Sorry, I meant to filter this out
2789     before I committed this part. This should make the WMS extension
2790     run from CVS again.
2791     (wms_dialog): Reset an empty URL to None so that the subsequent
2792     program can depend on this, since the dialog will indeed return an
2793     empty URL, causing another declaration of love by Python.
2794    
2795     * Extensions/wms/parser.py (WMSCapabilitiesParser.getLayerBBox):
2796     Whenever a native BoundingBox request cannot be fulfilled, check
2797     whether the requested SRS is EPSG:3426, in which case return the
2798     LatLonBoundingBox values.
2799    
2800     * Extensions/wms/test/test_parser.py
2801     (TestWMSCapabilitiesParser.test_LayerSRS): Added a test for
2802     ignoring AUTO:* SRS.
2803     (TestWMSCapabilitiesParser.test_LatLonBoundingBoxes_as_bboxes):
2804     Added another test method to test whether the LatLonBoundingBox
2805     values will be returned if BoundingBox values are requested with
2806     SRS set to EPSG:3426.
2807    
2808     * Extensions/wms/parser.py (WMSCapabilitiesParser.peekLayers):
2809     Added rudimentary support for non-EPSG SRS, i.e. ignore them for
2810     the moment by placing them into a variable which is currently
2811     unused. Also test whether the EPSG SRS is numerical as it should
2812     be and add an error message if it is not.
2813    
2814     * Extensions/wms/test/sample.xml: Added AUTO:* SRS since they
2815     appear in the real world as well. Since we cannot handle them yet
2816     (OGCLib can't either), we will ignore them for the moment.
2817    
2818     * Extensions/wms/parser.py: Use a variable for denoting the sample
2819     filename
2820     (WMSCapabilitiesParser.peekLayers): Added support for error
2821     messages during grok(). They will be aggregated in an array and
2822     may be displayed later. We may have to add a classification
2823     "Warning" and "Error" to this. That requires more experience,
2824     though, since not every error may be lethal.
2825    
2826     * Thuban/UI/mainwindow.py (MainWindow.LayerShowTable): Raise the
2827     ShowTable() dialog/frame when the user attempts to display it
2828     while it has been opened before already and not closed again.
2829    
2830 joey 2161 2004-04-11 Martin Schulze <[email protected]>
2831    
2832     * Extensions/wms/infodialog.py: Adjusted the class documentation
2833    
2834     * Extensions/wms/wms.py (WMSLayer.__init__, WMSLayer.GetMapImg):
2835     Switch to using Thuban{Begin,End}BusyCursor instead of the pure
2836     wxWidgets variants.
2837     (WMSLayer.__init__): The epsg_id variable is named top_srs now.
2838    
2839     * Extensions/wms/infodialog.py: Added an information dialog that
2840     will display various information about the WMS current resource,
2841     so that additional information such as the title, the abstract,
2842     fees and access constraints can be displayed for the user if they
2843     are documented in the WMS XML.
2844    
2845 joey 2156 2004-04-10 Martin Schulze <[email protected]>
2846    
2847     * Extensions/wms/parser.py (WMSCapabilitiesParser.grok): Adjusted
2848     string handling. It's "foo".lower() and not lower(foo) without
2849     lower imported from strings or something.
2850    
2851     * Extensions/wms/wms.py (WMSLayer): Incorporated WMSCapabilities
2852     from capabilities.py and parser.py. Implement priority list for
2853     supported graphics formats, take care of wbmp != bmp. PNG, TIFF
2854     and GIF are supported here, but not yet by main Thuban. Hence,
2855     support for them may be removed later. Special contribution to
2856     usability: get wxWidgets to change the cursor when we're waiting
2857     for data from the network so the user won't start to worry. This
2858     causes a redrawing error/warning, though.
2859    
2860     * Extensions/wms/parser.py (WMSCapabilitiesParser.grok): Unlink
2861     the DOM object.
2862    
2863     2004-04-01 Martin Schulze <[email protected]>
2864    
2865     * Extensions/wms/capabilities.py: Adjusted documentation
2866     (WMSCapabilities.__init__): Improved documentation, fixed syntax
2867     (WMSCapabilities.saveCapabilities): Only catch IOError when
2868     handling files
2869     (WMSCapabilities.loadCapabilities): Only catch IOError when
2870     handling files
2871     __main__: corrected variable naming
2872     (WMSCapabilities.fetchCapabilities,loadCapabilities): Make this
2873     class a specialisation of WMSCapabilitiesParser as well. Also
2874     execute grok() after loading or fetching capabilities, if that
2875     went well, so that subsequent calls can already access the data.
2876     (WMSCapabilities.getVersion): Export the used version of the
2877     GetCapabilities request, so we can use it for subsequent calls,
2878     i.e. for GetMap requests.
2879     (WMSCapabilities.fetchCapabilities): Added proper error handling
2880     when the GetCapabilities request failed, so that the surrounding
2881     program can act accordingly.
2882    
2883 joey 2146 2004-03-30 Martin Schulze <[email protected]>
2884    
2885     * Extensions/wms/parser.py (WMSCapabilitiesParser.getLayerSRS):
2886     Adjusted the getLayerSRS method to return the list of SRSes
2887     extracted from <SRS> elements instead of <BoundingBox> elements.
2888     Added a bit of documentation as well.
2889     (WMSCapabilitiesParser.checkLayerSRS): Removed integrity test
2890     since it was only implemented due to a misunderstanding.
2891    
2892     * Extensions/wms/test/test_parser.py
2893     (TestWMSCapabilitiesParser.test_LayerSRS): Adjust the tests to
2894     reflect the corrected interpretation of the standard: i.e. a layer
2895     does not have to define a BoundingBox for all SRSes it supports.
2896     Hence the <SRS></SRS> specification is authoritative, not the list
2897     of BoundingBoxes.
2898     (TestWMSCapabilitiesParser.test_BoundingBoxes): Added a new test
2899     to ensure None is returned for a non-existing SRS.
2900     (TestWMSCapabilitiesParser.test_grok): Removed test_grok method
2901     since it is not applicable anymore. Listing more SRSes in <SRS>
2902     elements is valid according to the specs.
2903    
2904 bernhard 2140 2004-03-26 Bernhard Reiter <[email protected]>
2905 joey 2146
2906 bernhard 2140 * README: Nicer formatting of text. Improved descriptions.
2907     Reflected wxWidgets name change.
2908    
2909     * Thuban/UI/about.py: Extended copyright to 2004 and added
2910     information about the thuban-devel mailinglist.
2911    
2912 joey 2138 2004-03-24 Martin Schulze <[email protected]>
2913 joey 2120
2914 joey 2138 * Extensions/wms/capabilities.py: Renamed the class to contain
2915     'WMS', also added a linebreak where required
2916    
2917     * Extensions/wms/parser.py: Finally added the XML parser for the
2918     GetCapabilities response.
2919    
2920     * Extensions/wms/test/sample.xml: Adjusted the sample file so that
2921     <SRS> elements match the <BoundingBox> elements, except for the
2922     layer 'beschriftung'.
2923    
2924     * Extensions/wms/test/test_parser.py: Encode non-ascii strings
2925     since Python uses unicode strings internally, otherwise
2926     comparisons will fail. Removed tests for getLayerBBoxSRS() since
2927     the SRS will be calculated anyway and this method is obsoleted by
2928     getLayerSRS(). Denote SRS as strings and not as cardinal numbers.
2929     Move loading the sample file into the setUp method. Added a test
2930     for finding the integrity problem in the sample response.
2931     Improved formatting.
2932    
2933     * Extensions/wms/domutils.py: Added convenience routines for
2934     handling of Document Object Model (DOM) nodes.
2935    
2936     * Extensions/wms/test/test_domutils.py: Added a test for the
2937     domutils module
2938    
2939     2004-03-19 Martin Schulze <[email protected]>
2940    
2941 joey 2120 * Extensions/wms/test/test_parser.py (TestWMSCapabilitiesParser):
2942     Moved path detection and adding into a module of its own,
2943     adjustpath, which exports thubandir as main Thuban directory.
2944    
2945     * Extensions/wms/test/test_ogclib.py (TestWMSLib): Moved path
2946     detection and adding into a module of its own, adjustpath, which
2947     exports thubandir as main Thuban directory. Reorganised the
2948     module in order to support the SkipTest feature for Thuban test
2949     cases.
2950    
2951     * Extensions/wms/test/adjustpath.py: Moved path detection and
2952     adding into a module of its own.
2953    
2954 joey 2115 2004-03-18 Martin Schulze <[email protected]>
2955    
2956     * Extensions/wms/test/test_parser.py: Added another test for
2957     checking whether the WMS XML parser (to be implemented) returns
2958     the information we expect. This requires a sample WMS WML file
2959     (sample.xml) which has been extracted from the frida server and
2960     "improved" manually.
2961    
2962     * Extensions/wms/test/test_ogclib.py: Added legacy code to add the
2963     main Thuban directory to the path in order to be able to import
2964     random modules. Adjusted the PyOGCLib detection to reuse the
2965     information gathered. Also added a note about the PYTHONPATH
2966     environment variable.
2967    
2968     * Extensions/wms/test/test_ogclib.py: The format specification is
2969     a mime-type, not a graphic format, hence image/jpeg wou ld be the
2970     proper format and not JPEG. We'll also have to take care of the
2971     encoding of / as %2F.
2972    
2973 joey 2111 2004-03-16 Martin Schulze <[email protected]>
2974    
2975     * Extensions/wms/test/test_ogclib.py: Added a (hopefully)
2976     comprehensive test for the getMapURL method, built compare URLs
2977     according to the documentation in OGC 01-068r3
2978    
2979     * Extensions/wms/capabilities.py (WMSCapabilities): Added the
2980     class WMSCapabilities to manage capabilites, will incorporate
2981     parsing the capabilities response and provide details for other
2982     classes.
2983    
2984 bh 2105 2004-03-12 Bernhard Herzog <[email protected]>
2985    
2986 bh 2107 Support views in addition to normal tables in the postgis
2987     shapestore
2988    
2989     * Thuban/Model/postgisdb.py
2990     (PostGISShapeStore._fetch_table_information): Add a fallback for
2991     the case where the table name is not in the geometry_columns
2992     table. This is usually the case for views. Also, set
2993     self.shapestore here.
2994     (PostGISShapeStore.ShapeType): No need to query the database all
2995     the time. The shape type is now determined in
2996     _fetch_table_information
2997    
2998     * test/postgissupport.py (PostgreSQLServer.new_postgis_db)
2999     (PostgreSQLServer.get_static_data_db, PostGISDatabase.__init__):
3000     New parameter to specify views.
3001     (PostGISDatabase.has_data): Also compare the views. New views
3002     parameter
3003     (PostGISDatabase.initdb): Create the views.
3004     (PostgreSQLServer.get_default_static_data_db): Add the v_landmarks
3005     view
3006    
3007     * test/test_postgis_db.py
3008     (TestPostGISShapestorePointFromViews): New. Test a
3009     PostGISShapeStore with a view
3010     (TestPostGISShapestorePointOIDAsGIDColumn.setUp): Pass the name of
3011     the geometry_column explicitly to test whether that works
3012    
3013     2004-03-12 Bernhard Herzog <[email protected]>
3014    
3015 bh 2105 Final step for explicit id/geometry columns: Loading and saving
3016    
3017     * Resources/XML/thuban-1.1.dtd: New. Derived from thuban-1.0.dtd
3018     with the following changes:
3019     (dbshapesource): Two new attributes id_column and geometry_column
3020    
3021     * Thuban/Model/save.py (SessionSaver.write): Use the new dtd
3022     (SessionSaver.write_session): Use the new namespace
3023     (SessionSaver.write_data_containers): Write the new dbshapesource
3024     parameters
3025    
3026     * Thuban/Model/load.py (SessionLoader.__init__): New namespace for
3027     the new file format version
3028     (SessionLoader.start_dbshapesource): Handle the new db parameters
3029    
3030     * test/test_save.py: Update to the new dtd and namespace
3031     (SaveSessionTest.test_save_postgis): Update the NonConnectionStore
3032     mock object to provide a working IDColumn method.
3033    
3034     * test/test_load_1_0.py: New. Copy of the test_load.py before
3035     today's changes but with the round-trip tests removed.
3036    
3037     * test/test_load_0_9.py: Update doc-string.
3038    
3039     * test/test_load.py: Update all .thuban files to the new dtd and
3040     namespace.
3041     (TestPostGISLayer.file_contents): Add the new dbshapesource
3042     paramters
3043    
3044 bh 2100 2004-03-11 Bernhard Herzog <[email protected]>
3045    
3046 bh 2103 Next step for explicit id/geometry columns: User interaction
3047    
3048     * Thuban/UI/dbdialog.py (ChooseDBTableDialog.__init__): Rework how
3049     the dialog is constructed. Add combo boxes to select id and
3050     geometry column. Rename some instance variables.
3051     (ChooseDBTableDialog.GetTable): Return id and geometry column
3052     names
3053     (ChooseDBTableDialog.OnTableSelect): New. Event handler for
3054     selections in the table list
3055    
3056     * Thuban/UI/mainwindow.py (MainWindow.AddDBLayer): Use id_column
3057     and geometry_column
3058    
3059     * Thuban/Model/session.py (Session.OpenDBShapeStore): Add the new
3060     parameters for id_column and geometry column of PostGISShapeStore
3061     here as well.
3062    
3063     * Thuban/Model/postgisdb.py (type_map): Add ROWID psycog type.
3064     (_raw_type_map): New. Map raw PostgreSQL type ints to thuban types
3065     (PostGISConnection.GeometryTables): Use a better query to
3066     determine which relations in the database might be usable for
3067     shapestores. Now supports views as well but is more PostgreSQL
3068     specific
3069     (PostGISConnection.table_columns): New. Somewhat experimental
3070     method to let the db dialogs provide lists of columns to users so
3071     that they can select id and geometry columns.
3072     (PostGISTable.__init__): The default value of the id_column
3073     parameter is now None it still means "gid" effectively, though.
3074     (PostGISTable.IDColumn): New introspection method to return a
3075     column object for the id column
3076     (PostGISShapeStore.GeometryColumn): New introspection method to
3077     return a column object for the geometry column
3078    
3079     * test/test_postgis_db.py
3080     (TestPostGISConnection.test_gis_tables_non_empty):
3081     Removed. Subsumed by the new:
3082     (TestPostGISConnection.test_gis_tables_with_views_and_tables):
3083     New. Tes the GeometryTables and table_columns methods with actual
3084     tables and views.
3085     (PointTests.test_id_column, PointTests.test_geometry_column):
3086     New. tests for the new methods.
3087     (TestPostGISShapestorePoint.setUp)
3088     (TestPostGISShapestorePointSRID.setUp)
3089     (TestPostGISShapestorePointExplicitGIDColumn.setUp): Fill the
3090     instance variables needed by the new tests
3091    
3092     2004-03-11 Bernhard Herzog <[email protected]>
3093    
3094 bh 2100 * Thuban/UI/classgen.py (GenQuantilesPanel.GetList): The row
3095     numbers given to ReadValue are ordinals.
3096    
3097     2004-03-11 Bernhard Herzog <[email protected]>
3098    
3099     Elimiate the requirement for PostGIS tables to have a column
3100     called "gid".
3101    
3102     * Thuban/Model/postgisdb.py (PostGISTable.__init__): New parameter
3103     id_column to specify which column to use to identify rows. Also
3104     new instance variables id_column and quoted_id_column
3105     (PostGISTable.RowIdToOrdinal, PostGISTable.RowOrdinalToId)
3106     (PostGISTable.ReadRowAsDict, PostGISTable.ReadValue)
3107     (PostGISTable.SimpleQuery): Use the id column name provided to the
3108     constructor instead of "gid"
3109     (PostGISShapeStore.__init__): New parameter id_column analogously
3110     to PostGISTable.__init__. This parameter is simply passed through
3111     to the base class constructor
3112     (PostGISShapeStore._create_col_from_description): Fix typo in
3113     doc-string
3114     (PostGISShapeStore.Shape, PostGISShapeStore.AllShapes)
3115     (PostGISShapeStore.ShapesInRegion): Use the id column name
3116     provided to the constructor instead of "gid"
3117    
3118     * test/postgissupport.py
3119     (PostgreSQLServer.get_default_static_data_db): New static table
3120     landmarks_point_id with an id column != "gid. Update the comments
3121     a bit.
3122     (skip_if_addgeometrycolumn_does_not_use_quote_ident): Fix typo in
3123     doc-
3124     (upload_shapefile): New parameter gid_column to use a name other
3125     than "gid" for the column to store the shape ids
3126    
3127     * test/test_postgis_db.py (TableTests): New. Mixin-class
3128     containing all tests previously in TestPostGISTable. The actual
3129     tests are the same but the code is a bit more configurable to
3130     allow for different id columns etc.
3131     (TestPostGISTable): Derive from TableTests now for the actual
3132     tests.
3133     (TestPostGISTableExplicitGIDColumn): New. Like TestPostGISTable
3134     except that it the landmarks_point_id table to test the id_column
3135     parameter
3136     (PointTests): Extend the doc-string
3137     (TestPostGISShapestorePointExplicitGIDColumn)
3138     (TestPostGISShapestorePointOIDAsGIDColumn): New classes derived
3139     from PointTests to test the explicit id_column parameter. One
3140     tests with the name of the column holding the shape ids, the other
3141     uses PostgreSQL's OID column. For the latter a number of methods
3142     have to be overwritten to make them independent of the actual id
3143     values.
3144    
3145 silke 2095 2004-03-08 Silke Reimer <[email protected]>
3146    
3147     Update debian directory:
3148    
3149     * debian/changelog: Added new version.
3150     * deiban/rules: Updated management of patches (with cbds)
3151     * debian/control: Added cbds to dependencies
3152     * debian/patches/*: New. Adds better support for patches of thuban in
3153     debian
3154     * debian/menu: Syntax of menu changed slightly
3155     * debian/setup.py.patch: removed because it has been moved to
3156     debian/patechs/setup.py.patch
3157    
3158    
3159 bh 2094 2004-02-26 Bernhard Herzog <[email protected]>
3160    
3161     Create the Doc/technotes directory for text files with information
3162     for developers
3163    
3164     * Doc/technotes/README: New. README for the technotes
3165    
3166     * Doc/technotes/coding_guidelines.txt: New. Coding guidelines for
3167     Thuban
3168    
3169     * Doc/technotes/release_process.txt: New. Used to be
3170     HOWTO-Release. Now slightly adapted to technote formatting style.
3171    
3172     * HOWTO-Release: Removed. It's contents are now in
3173     Doc/technotes/release_process.txt
3174    
3175 bh 2089 2004-02-25 Bernhard Herzog <[email protected]>
3176    
3177     * libraries/thuban/wxproj.cpp (get_wx_version): New. Return the
3178     version of wxWindows the module was compiled with so we can check
3179     that against the wxPython version.
3180    
3181     * Thuban/version.py (thuban_branch, thuban_release): New variables
3182     controlling which and how Thuban versions are shown. See the
3183     comments for details.
3184     (verify_versions): Also check that the wx version that wxproj is
3185     compiled against matches that of the wxPython we use at runtime
3186    
3187 bh 2080 2004-02-20 Bernhard Herzog <[email protected]>
3188    
3189 bh 2087 * Extensions/wms/wms.py (epsg_code_to_projection): Use
3190     get_system_proj_file to read the epsg projections. The old way
3191     depended on the current directory being the top Thuban directory.
3192    
3193     2004-02-20 Bernhard Herzog <[email protected]>
3194    
3195 bh 2085 * Extensions/svgexport/test/test_svgmapwriter.py
3196     (TestVirtualDC.test_clippath): Remove a debug print
3197    
3198     2004-02-20 Bernhard Herzog <[email protected]>
3199    
3200 bh 2083 * Extensions/svgexport/__init__.py: New. Turn
3201     Extensions/svgexport into a package.
3202    
3203     * Extensions/svgexport/svgmapwriter.py: Reorder the imports and
3204     doc-string a bit. The doc-string must come first, otherwise it's
3205     not a doc-string. The __future__ import must be the first thing
3206     after the doc-string. Use only double quotes in doc-strings.
3207     Single quotes trip up emacs syntax highlighting if the text
3208     contains apostrophes.
3209    
3210     2004-02-20 Bernhard Herzog <[email protected]>
3211    
3212 bh 2080 * Extensions/svgexport/test/__init__.py,
3213     Extensions/svgexport/test/test_svgmapwriter.py: New. Initial test
3214     suite for svgexport
3215    
3216     * test/runtests.py (find_test_modules): New. Function with the
3217     module finding code from main.
3218     (main): Use find_test_modules to figure out the default test
3219     modules and take modules from Extensions.svgexport.test too.
3220    
3221 bh 2075 2004-02-19 Bernhard Herzog <[email protected]>
3222    
3223 bh 2077 * Thuban/UI/application.py (ThubanApplication.OnInit): Make sure
3224     the mainwindow has a reference to the map of the initial session.
3225     This fixes a bug introduced with the fix for RT#2245
3226    
3227     2004-02-19 Bernhard Herzog <[email protected]>
3228    
3229 bh 2075 * Extensions/svgexport/svgsaver.py,
3230     Extensions/svgexport/svgmapwriter.py,
3231     Extensions/svgexport/maplegend.py: Added again. This time in the
3232     correct place.
3233    
3234 bh 2070 2004-02-17 Bernhard Herzog <[email protected]>
3235    
3236 bh 2073 Fix for RT#2245
3237    
3238     * Thuban/UI/application.py (ThubanApplication.OnInit): Initialize
3239     instance variables before trying to create any windows. Creating
3240     windows can start an event loop if e.g. message boxes are popped
3241     up for some reason, and event handlers, especially EVT_UPDATE_UI
3242     may want to access things from the application.
3243     (ThubanApplication.maps_changed): The mainwindow may not have been
3244     created yet, so check whether it has been created before calling
3245     its methods
3246    
3247     * Thuban/UI/view.py (MapCanvas.OnIdle): Only try to redraw if we
3248     have a map
3249    
3250     2004-02-17 Bernhard Herzog <[email protected]>
3251    
3252 bh 2070 * test/test_svgmapwriter.py, Extensions/svgsaver.py,
3253     Extensions/svgmapwriter.py, Extensions/maplegend.py,
3254     extensions/svgexport/svgsaver.py,
3255     extensions/svgexport/svgmapwriter.py,
3256     extensions/svgexport/maplegend.py: Removed. These files were in
3257     the wrong places or didn't work at all.
3258    
3259 bh 2067 2004-02-16 Bernhard Herzog <[email protected]>
3260    
3261 bh 2069 * Thuban/UI/view.py (MapCanvas.Export): Remove accidentally added
3262     line
3263    
3264     2004-02-16 Bernhard Herzog <[email protected]>
3265    
3266 bh 2067 * Thuban/UI/view.py (MapCanvas.Export): Avoid UnboundLocalError.
3267    
3268 mrechtie 2064 2004-02-15 Markus Rechtien <[email protected]>
3269    
3270     * Extensions/svgexport/svgmapwriter.py: New. Adds the capability
3271     to write a session to a file in SVG format.
3272     * Extensions/svgexport/svgsaver.py: New. Uses svgmapwriter.py
3273     to write a SVG map of a session.
3274     * Extensions/svgexport/maplegend: New. Writes a basic maplegend
3275     in SVG format for the current session.
3276    
3277 bh 2062 2004-02-13 Bernhard Herzog <[email protected]>
3278    
3279     * Thuban/UI/mainwindow.py (MainWindow.AddDBLayer): When the layer
3280     can't be created, return immediately after displaying the error
3281     message.
3282    
3283 bh 2060 2004-02-11 Bernhard Herzog <[email protected]>
3284    
3285     Handle postgis tables with more than one geometry column.
3286    
3287     * Thuban/Model/postgisdb.py
3288     (PostGISTable._fetch_table_information): Delegate the creation of
3289     column objects to a different method so that we can extend that in
3290     derived classes
3291     (PostGISTable._create_col_from_description): New. Column object
3292     creation part of _fetch_table_information
3293     (PostGISShapeStore._create_col_from_description): New. Extend
3294     inherited method to handle geometry columns
3295     (PostGISShapeStore.__init__): New parameter geometry_column to
3296     specify which geometry column to use. Optional but mandatory for
3297     tables with more than one geometry column
3298     (PostGISShapeStore._fetch_table_information): Also use the name of
3299     the geometry column when looking for the srid
3300     (PostGISShapeStore.ShapeType): Also use the name of the geometry
3301     column when looking for the shape type
3302    
3303     * test/test_save.py (SaveSessionTest.test_save_postgis): Adapt
3304     NonConnectionStore to changes in the PostGISShapeStore
3305    
3306     * test/test_postgis_db.py
3307     (TestPostGISSpecialCases.test_shapestore_two_geom_cols): Test
3308     PostGISShapeStore with tables having two geometry columns.
3309    
3310 bh 2058 2004-02-10 Bernhard Herzog <[email protected]>
3311    
3312     Fix some postgis problems. What remains to be done is real
3313     handling of SRIDs as they affect how reprojection is done
3314    
3315     * Thuban/Model/postgisdb.py (quote_identifier): Fix typo in
3316     doc-string
3317     (PostGISShapeStore._fetch_table_information): New. Extend
3318     inherited method to retrieve srid
3319     (PostGISShapeStore.BoundingBox): Handle tables without data.
3320     extent yields NULL for those
3321     (PostGISShapeStore.ShapesInRegion): Use the srid of the table.
3322    
3323     * test/test_postgis_db.py
3324     (TestPostGISSpecialCases.test_shapestore_empty_table): New test
3325     for the special case of a table without any data
3326     (TestPostGISShapestorePointSRID): New class with tests for a table
3327     that uses srids
3328     (PolygonTests): Fix a doc-string typo
3329    
3330     * test/postgissupport.py (PostGISDatabase.__init__): New parameter
3331     reference_systems with a specification of spacial reference
3332     systems to create in the new db.
3333     (PostgreSQLServer.new_postgis_db)
3334     (PostgreSQLServer.get_static_data_db): New parameter
3335     reference_systems to be passed through ultimately to
3336     PostGISDatabase. In new_postgis_db also check whether an existing
3337     db already has the right srids
3338     (PostgreSQLServer.get_default_static_data_db): Add srids and a
3339     table that uses srids
3340     (PostGISDatabase.initdb): Create the entries for the reference
3341     systems
3342     (PostGISDatabase.has_data): Add reference_systems parameter to
3343     check for those too
3344     (upload_shapefile): New parameter srid to create tables with a
3345     specific srid
3346    
3347 frank 2055 2004-02-06 Frank Koormann <[email protected]>
3348    
3349     * po/pt_BR.po: Fixed charset
3350    
3351 frank 2054 2004-02-05 Frank Koormann <[email protected]>
3352    
3353     * po/pt_BR.po: Fixed format string for error message, missing %s
3354     added (Thuban/UI/application.py:273)
3355    
3356 frank 2053 2004-02-03 Frank Koormann <[email protected]>
3357    
3358     First version of Portuguese (Brazilian) translation
3359    
3360     * po/pt_BR.po: New, translation of pot (2004-01-15 16:07+0300) for
3361     Brazilian Portuguese by Eduardo Patto Kanegae.
3362    
3363     * Thuban/UI/about.py (About.__init.py__): Added Eduardo to the list of
3364     translators.
3365    
3366    
3367 frank 2052 2004-01-22 Frank Koormann <[email protected]>
3368    
3369     * Doc/manual/thuban-manual.xml: Added section on installation of
3370     Thuban under Win32 systems. Fixed image path references in the postgis
3371     section. Some minor source formattings.
3372    
3373 frank 2051 2004-01-21 Frank Koormann <[email protected]>
3374    
3375     Make Thuban remember path selections (at least for one application run).
3376    
3377     * Thuban/UI/application.py (Application.OnInit): Initialize path as a
3378     attribute of application object. Path is a dictionary of
3379     strings, currently with the items "data" and "projection".
3380     (Application.SetPath): New, stores path for the specified item.
3381     (Application.Path): New, return path for the specified item.
3382    
3383     * Thuban/UI/mainwindow.py
3384     (MainWindow.OpenSession, MainWindow.SaveSessionAs,
3385     MainWindow.AddLayer, MainWindow.AddRasterLayer,
3386     MainWindow.TableOpen): Access "data" path information of the
3387     application.
3388    
3389     * Thuban/UI/projdialog.py (ProjFrame._OnImport, ProjFrame._OnExport):
3390     Access "projection" path information of the application.
3391    
3392 bh 2048 2004-01-05 Bernhard Herzog <[email protected]>
3393    
3394 bh 2050 * po/ru.po: Updated translations from Alex Shevlakov
3395    
3396     2004-01-05 Bernhard Herzog <[email protected]>
3397    
3398 bh 2048 * po/Makefile, po/README: Move the description of how to generate
3399     the translation statistics to the README.
3400    
3401 bh 2042 2003-12-23 Bernhard Herzog <[email protected]>
3402    
3403 bh 2045 * NEWS: Update for 1.0.0
3404    
3405     * po/it.po: Another update from Maurizio Napolitano
3406    
3407     2003-12-23 Bernhard Herzog <[email protected]>
3408    
3409 bh 2042 * po/it.po: Updated translation from Maurizio Napolitano
3410    
3411     2003-12-23 Bernhard Herzog <[email protected]>
3412    
3413     * Thuban/UI/join.py (JoinDialog.__init__): Mark one more string
3414     for translation
3415    
3416     * Thuban/UI/mainwindow.py (MainWindow.TableRename)
3417     (MainWindow.RenameMap, MainWindow.RenameLayer): Mark some more
3418     strings for translation
3419    
3420     * po/de.po: Update with the newly marked strings.
3421    
3422 bh 2033 2003-12-22 Bernhard Herzog <[email protected]>
3423    
3424 bh 2039 * HOWTO-Release: Fix the places where version numbers have to be
3425     updated
3426    
3427     2003-12-22 Bernhard Herzog <[email protected]>
3428    
3429 bh 2037 * setup.py (setup call): 1.0.0, yeah!
3430    
3431     * Thuban/version.py (longversion): 1.0.0, yeah!
3432    
3433     * Thuban/Model/load.py (SessionLoader.__init__): Accept the
3434     1.0.0 namespace too
3435    
3436     * Thuban/Model/save.py (SessionSaver.write_session): Save with
3437     1.0.0 namespace
3438    
3439     * test/test_load.py (LoadSessionTest.dtd)
3440     (TestSingleLayer.file_contents)
3441     (TestNonAsciiColumnName.file_contents)
3442     (TestLayerVisibility.file_contents)
3443     (TestClassification.file_contents, TestLabels.file_contents)
3444     (TestLayerProjection.file_contents)
3445     (TestRasterLayer.file_contents, TestJoinedTable.file_contents)
3446     (TestLabelLayer.file_contents, TestPostGISLayer.file_contents)
3447     (TestPostGISLayerPassword.file_contents)
3448     (TestLoadError.file_contents, TestLoadError.test): Update for
3449     1.0.0 namespace
3450    
3451     * test/test_save.py (SaveSessionTest.dtd)
3452     (SaveSessionTest.testEmptySession)
3453     (SaveSessionTest.testSingleLayer)
3454     (SaveSessionTest.testLayerProjection)
3455     (SaveSessionTest.testRasterLayer)
3456     (SaveSessionTest.testClassifiedLayer)
3457     (SaveSessionTest.test_dbf_table)
3458     (SaveSessionTest.test_joined_table)
3459     (SaveSessionTest.test_save_postgis): Update for 1.0.0 namespace
3460    
3461     2003-12-22 Bernhard Herzog <[email protected]>
3462    
3463 bh 2035 * Thuban/Model/load.py (SessionLoader.start_label): Make sure the
3464     alignment flags are byte strings not unicode and that they have
3465     valid values
3466    
3467     * test/test_load.py (TestLabelLayer): New. Test loading (and
3468     indirectly saving) of maps with labels.
3469    
3470     2003-12-22 Bernhard Herzog <[email protected]>
3471    
3472 bh 2033 * Thuban/UI/tableview.py (TableGrid.OnDestroy)
3473     (TableGrid.__init__): Handle EVT_WINDOW_DESTROY in the grid to
3474     unsubscribe all subscribers.
3475     (LayerTableFrame.OnDestroy): Do not unsubscribe any messages from
3476     self.grid since it may already have been destroyed.
3477     Fixes RT #2256
3478    
3479 bh 2031 2003-12-19 Bernhard Herzog <[email protected]>
3480    
3481     * po/fr.po, po/es.po: Updated translations from Daniel Calvelo
3482    
3483 bh 2028 2003-12-16 Bernhard Herzog <[email protected]>
3484 silke 2029
3485     * debian/bitmappath.patch, debian/setup.py.patch:
3486     added to ensure compliance with FHS for debian
3487     * debian/rules, debian/changelog:
3488     added patches in rules to ensure compliance with FHS for debian
3489 bh 2028
3490 silke 2029 2003-12-16 Bernhard Herzog <[email protected]>
3491    
3492 bh 2028 * po/Makefile (mo): Make the output a bit nicer so that it prints
3493     statistics about the translations. Add a comment how produce even
3494     nicer statistics with sed.
3495    
3496 frank 2026 2003-12-09 Frank Koormann <[email protected]>
3497    
3498     * Resources/Projections/defaults.proj:
3499     French projection sample with correct accents (UNICODE).
3500    
3501 bh 2025 2003-12-05 Bernhard Herzog <[email protected]>
3502    
3503     * MANIFEST.in: Add the devtools directory
3504    
3505     * setup.py (setup call): Use license instead of licence. This
3506     silences a deprecation warning on Python 2.3
3507    
3508 frank 2022 2003-12-05 Frank Koormann <[email protected]>
3509    
3510 frank 2023 Documentation synced with 1.0rc1
3511    
3512     * Doc/manual/thuban-manual.xml:
3513     Minor formatting changes and references to database layers .
3514     Introduction.Internationalization: New section on i18n.
3515     MapManagement.AddingandRemovingLayers: Added item on database layers.
3516     MapManagement.TheLegend: Added section and screenshot on popup menu.
3517     ProjectionManagement: Updated screenshot and sentence on EPSG.
3518     Appendix.SupportedDataSources: Added PostGIS.
3519     Appendix.WorkingwithPostGIS: New section.
3520    
3521     * Doc/manual/images/6_projection.png: Updated screenshot including
3522     EPSG checkboxes.
3523    
3524     * Doc/manual/images/3_5_popup_menu.png: New, popup menu screenshot.
3525    
3526     * Doc/manual/images/app_postgis_add_layer.png,
3527     Doc/manual/images/app_postgis_db_add.png,
3528     Doc/manual/images/app_postgis_db_management.png:
3529     New screenshots focussing on database layers
3530    
3531     2003-12-05 Frank Koormann <[email protected]>
3532    
3533 frank 2022 * Thuban/UI/projdialog.py (load_user_proj): If user.proj is missing
3534     write warning to stderr instead of rising a warning dialog
3535    
3536 bh 2016 2003-12-03 Bernhard Herzog <[email protected]>
3537    
3538 bh 2021 Fix for RT #2243
3539    
3540 bh 2020 * Thuban/UI/mainwindow.py (MainWindow.has_selected_shape_layer):
3541     New. Like has_selected_layer but for shape layers only
3542     (_has_selected_shape_layer): New. Like _has_selected_layer but for
3543     shape layers only
3544     (layer_show_table command, layer_jointable command): Use these
3545     commands should only be available for shape layers
3546    
3547     2003-12-03 Bernhard Herzog <[email protected]>
3548    
3549 bh 2018 * Thuban/UI/mainwindow.py (MainWindow.Unsubscribe): Deal with
3550     publishers that are wx objects and may have been destroyed by wx
3551     already. Fixes RT #2242.
3552    
3553     2003-12-03 Bernhard Herzog <[email protected]>
3554    
3555 bh 2016 * po/ru.po: Updates from Alex Shevlakov
3556    
3557 silke 2013 2003-12-03 Silke Reimer <silkeintevation.de>
3558    
3559     * debian/control, debian/changelog: Added gdal-support to
3560     debian package, updated to new thuban version
3561    
3562    
3563 bh 2012 2003-12-03 Bernhard Herzog <[email protected]>
3564    
3565     * Thuban/Lib/version.py: New. Module for version number
3566     manipulations. The version of make_tuple here also deals better
3567     with more unusual version number strings, such as e.g.
3568     "1.2+cvs20031111"
3569    
3570     * Thuban/version.py (make_tuple): Removed. It's now in
3571     Thuban.Lib.version. Use that implementation instead.
3572    
3573     * test/test_lib_version.py: New. Tests for Thuban/Lib/version.py
3574    
3575 bh 2005 2003-12-02 Bernhard Herzog <[email protected]>
3576    
3577 bh 2010 * MANIFEST.in: Add debian files
3578    
3579 bh 2008 * setup.py (setup call): Add packages for the Extensions so that
3580     they're installed too
3581     (data_files): Add READMEs and sample data from some Extensions
3582    
3583     * NEWS: Add note about the extensions in binary packages
3584    
3585     2003-12-02 Bernhard Herzog <[email protected]>
3586    
3587 bh 2005 * Thuban/Model/save.py (SessionSaver.write_session): Save files
3588     with the thuban-1.0rc1
3589    
3590     * Thuban/Model/load.py (SessionLoader.__init__): Recognize the
3591     thuban-1.0rc1 namespace too
3592    
3593     * test/test_save.py (SaveSessionTest.dtd)
3594     (SaveSessionTest.testEmptySession)
3595     (SaveSessionTest.testSingleLayer)
3596     (SaveSessionTest.testLayerProjection)
3597     (SaveSessionTest.testRasterLayer)
3598     (SaveSessionTest.testClassifiedLayer)
3599     (SaveSessionTest.test_dbf_table)
3600     (SaveSessionTest.test_joined_table)
3601     (SaveSessionTest.test_save_postgis): Update to thuban-1.0rc1
3602     namespace
3603    
3604     * test/test_load.py (LoadSessionTest.dtd): Update to thuban-1.0rc1
3605     namespace
3606     (TestSingleLayer.file_contents)
3607     (TestNonAsciiColumnName.file_contents)
3608     (TestLayerVisibility.file_contents)
3609     (TestClassification.file_contents, TestLabels.file_contents)
3610     (TestLayerProjection.file_contents)
3611     (TestRasterLayer.file_contents, TestJoinedTable.file_contents)
3612     (TestPostGISLayer.file_contents)
3613     (TestPostGISLayerPassword.file_contents)
3614     (TestLoadError.file_contents, TestLoadError.test): Update to
3615     thuban-1.0rc1 namespace
3616    
3617 bh 1996 2003-12-01 Bernhard Herzog <[email protected]>
3618    
3619 bh 2003 * setup.py (proj4_prefix, wx_prefix, gdal_prefix): Fix these for
3620     nt to better match Intevation's current w32 setup
3621    
3622 bh 2001 * HOWTO-Release: Add note about updating MANIFEST.in
3623    
3624     * MANIFEST.in: Add the Extensions
3625    
3626 bh 1998 * NEWS: Update for 1.0rc1
3627    
3628     2003-12-01 Bernhard Herzog <[email protected]>
3629    
3630 bh 1996 * Thuban/UI/mainwindow.py (MainWindow.AddLayer): Change the wild
3631     cards for the dialog so that shapefiles ending in all uppercase
3632     SHP are listed too
3633    
3634 bh 1988 2003-11-28 Bernhard Herzog <[email protected]>
3635    
3636 bh 1996 * Thuban/version.py (longversion): Update to 1.0rc1
3637    
3638     * setup.py (setup call): Update version to 1.0rc1. Use the
3639     [email protected] email address as author email instead of my
3640     personal one.
3641    
3642     2003-11-28 Bernhard Herzog <[email protected]>
3643    
3644 bh 1992 * po/de.po: Update german translation.
3645    
3646     2003-11-28 Bernhard Herzog <[email protected]>
3647    
3648 bh 1990 Unify the filenames stored in .thuban files so that the .thuban
3649     files are more platform independend
3650    
3651     * Thuban/Model/save.py (unify_filename): New. Unify filenames so
3652     that they can be used on both windows and unix
3653     (SessionSaver.prepare_filename): New. Handle all filename
3654     transformations for filenames stored in the thuban file
3655     (SessionSaver.write_data_containers, SessionSaver.write_layer):
3656     Use prepare_filename
3657    
3658     * test/test_save.py (SaveSessionTest.testSingleLayer)
3659     (SaveSessionTest.testLayerProjection)
3660     (SaveSessionTest.testRasterLayer)
3661     (SaveSessionTest.testClassifiedLayer)
3662     (SaveSessionTest.test_dbf_table)
3663     (SaveSessionTest.test_joined_table): Filenames are always stored
3664     with slashes on all currently supported platforms so adapt all
3665     tests to this
3666    
3667     * test/test_load.py (LoadSessionTest.filenames): With the new
3668     filename scheme the filenames in the tests should be
3669     understandable on all currently supported platforms so we turn
3670     this into an empty list because we don't have to normalize them
3671     anymore
3672    
3673     2003-11-28 Bernhard Herzog <[email protected]>
3674    
3675 bh 1988 * test/test_layer.py (TestLayer.test_arc_layer_with_projection):
3676     Add the ellipsoid to the projection since some Proj versions
3677     complain if it's missing.
3678    
3679 bh 1984 2003-11-27 Bernhard Herzog <[email protected]>
3680    
3681     Corect some bounding box projection problems
3682    
3683     * Thuban/Model/proj.py (Projection.InverseBBox): New. Inverse
3684     version of ForwardBBox
3685     (Projection._transform_bbox): New. common implementation of
3686     ForwardBBox and InverseBBox
3687     (Projection.ForwardBBox): Use _transform_bbox.
3688    
3689     * test/test_proj.py (TestProjection.test): Add test for
3690     InverseBBox
3691    
3692     * Thuban/Model/layer.py (Layer.LatLongBoundingBox)
3693     (Layer.ShapesBoundingBox, RasterLayer.LatLongBoundingBox): Use the
3694     new InverseBBox method to determine the unprojected bounding box
3695     (Layer.ShapesInRegion): Use the ForwardBBox method to project the
3696     bbox.
3697    
3698     * test/test_layer.py (TestLayer.test_point_layer_with_projection):
3699     Removed.
3700     (TestLayer.test_arc_layer_with_projection): New. This test is
3701     better able to test whether bounding boxes are projected correctly
3702     than test_point_layer_with_projection
3703    
3704 bh 1986 * Thuban/UI/viewport.py (ViewPort.map_projection_changed): Use
3705     InverseBBox to unproject bboxes
3706    
3707 bh 1975 2003-11-25 Bernhard Herzog <[email protected]>
3708    
3709 bh 1981 * Thuban/UI/about.py (About.__init__): Make sure we have ASCII
3710     source code.
3711    
3712     2003-11-25 Bernhard Herzog <[email protected]>
3713    
3714 bh 1979 * Thuban/Model/layer.py (Layer.__getattr__): Removed. It was only
3715     there for backwards compatibility and all code relying on that
3716     should have been updated by now.
3717    
3718     2003-11-25 Bernhard Herzog <[email protected]>
3719    
3720 bh 1977 * test/test_load.py (TestClassification.test): Add the missing
3721     round trip test.
3722     (TestClassification.file_contents): Update to the newest file
3723     format
3724    
3725     2003-11-25 Bernhard Herzog <[email protected]>
3726    
3727 bh 1975 Add very experimental (and possibly dangerous) extension to draw
3728     polygons:
3729    
3730     * Extensions/drawshape/README: New. Brief installation
3731     instructions
3732    
3733     * Extensions/drawshape/drawshape.py: New. Implementation of the
3734     drawshape extensions
3735    
3736     * Extensions/drawshape/patch.diff: Patch to apply before the
3737     extension can be used.
3738    
3739 bh 1971 2003-11-24 Bernhard Herzog <[email protected]>
3740    
3741 bh 1973 * Thuban/Model/data.py (ShapefileStore._open_shapefile)
3742     (ShapefileStore.__init__): Factor opening the shapefile into a
3743     separate method (the new _open_shapefile). This makes the code a
3744     bit more readable but the real reason is that it makes some evil
3745     hacks easier. :-)
3746    
3747     2003-11-24 Bernhard Herzog <[email protected]>
3748    
3749 bh 1971 * Thuban/Model/load.py (SessionLoader.check_attrs): If no
3750     converter is specified for an attribute assume it's a string
3751     containing only Latin1 characters. Update doc-string accordingly.
3752     This change should fix many places where unicode objects might
3753     accidentally enter Thuban.
3754    
3755     * test/test_load.py (TestNonAsciiColumnName): New test to check
3756     what happens with column names in DBF files that contain non-ascii
3757     characters
3758    
3759 bh 1969 2003-11-21 Bernhard Herzog <[email protected]>
3760    
3761     Enable the experimental attribute editing again and introduce a
3762     command line switch to actually activate it
3763    
3764     * Thuban/UI/main.py (options): New. Container for options set on
3765     the commmand line
3766     (main): Add the --enable-attribute-editing flag.
3767    
3768     * Thuban/UI/identifyview.py (IdentifyView.__init__): If attribute
3769     editing is enabled use the grid ctrl which allows editing of the
3770     values
3771    
3772     * Thuban/Model/transientdb.py (AutoTransientTable.write_record):
3773     New. Just delegate this to the underlying table.
3774    
3775 bh 1967 2003-11-20 Bernhard Herzog <[email protected]>
3776    
3777     * test/test_proj.py (ProjFileReadTests.test_read_unreadable_file):
3778     Skip this test if run under non-posix systems since it only works
3779     there
3780    
3781 bh 1960 2003-11-19 Bernhard Herzog <[email protected]>
3782    
3783 bh 1965 * Thuban/Model/resource.py: Rework the way gdal support is
3784     determined so that we can give a reason in the about why gdal is
3785     not supported.
3786     (gdal_support_status): New. Variable holding a string with the
3787     reason for no gdal support
3788    
3789     * Thuban/UI/about.py (About.__init__): Add the reason why gdal is
3790     not supported to the message
3791    
3792     2003-11-19 Bernhard Herzog <[email protected]>
3793    
3794 bh 1963 Remove the old table interface and its test cases
3795    
3796     * Thuban/Model/table.py (OldTableInterfaceMixin): Removed.
3797     (DBFTable, MemoryTable): Do not derive from OldTableInterfaceMixin
3798     anymore
3799    
3800     * Thuban/Model/transientdb.py (TransientTableBase)
3801     (AutoTransientTable): Do not derive from OldTableInterfaceMixin
3802     anymore
3803    
3804     * test/test_table.py: Removed since the old interface it tests is
3805     gone.
3806    
3807     * test/runtests.py (main): The old table interface is gone and
3808     with it the deprecation warnings so remove the code that turns
3809     these warnings into errors
3810    
3811     2003-11-19 Bernhard Herzog <[email protected]>
3812    
3813 bh 1960 * test/test_table.py: Revert to revision 1.5 again. Changing the
3814     tests to use the new table interface is completely wrong since the
3815     whole purpose of the tests in this module is to test the old
3816     interface.
3817    
3818 bh 1954 2003-11-18 Bernhard Herzog <[email protected]>
3819    
3820 bh 1958 * Thuban/Model/postgisdb.py (PostGISConnection.MatchesParameters):
3821     New. Test whether the connection matches a set of connection
3822     parameters
3823    
3824     * Thuban/UI/dbdialog.py (DBFrame.conns_changed): Fix doc-string
3825     (DBFrame.OnAdd): Use the new MatchesParameters method when looking
3826     for existing connections with the same parameters and break out of
3827     the loop correctly.
3828    
3829     * test/test_postgis_db.py (TestBriefDescription)
3830     (TestPostGISSimple.test_brief_description): Rename
3831     TestBriefDescription to TestPostGISSimple and the test method to
3832     test_brief_description so that we can add more test methods.
3833     (TestPostGISSimple.test_matches_parameters): New. Test the new
3834     MatchesParameters method
3835    
3836     2003-11-18 Bernhard Herzog <[email protected]>
3837    
3838 bh 1960 * Thuban/Lib/connector.py (Publisher): Introduce a new flag,
3839 bh 1954 _was_destroyed, to indicate whether an publisher instance has
3840     already been destroyed.
3841     (Publisher.Unsubscribe): Only disconnect if the publisher has not
3842     been destroyed yet.
3843     (Publisher.Destroy): Set the _was_destroyed flag to true.
3844    
3845     * test/test_connector.py
3846     (TestPublisher.test_unsubscribe_after_destroy): New. Test that
3847     calling Unsubscribe after Destroy doesn't raise an exception
3848    
3849 bh 1951 2003-11-14 Bernhard Herzog <[email protected]>
3850    
3851     * Thuban/UI/identifyview.py (IdentifyView.selected_shape): Fix
3852     typo in doc-string
3853    
3854 bh 1949 2003-11-13 Bernhard Herzog <[email protected]>
3855    
3856     Quote table and column names properly for postgis.
3857    
3858     * Thuban/Model/postgisdb.py (quote_identifier): New. Function to
3859     quote an identifier for use in an sql statement
3860     (PostGISColumn.__init__): Add the quoted_name attribute
3861     (PostGISTable.__init__): New instance variable quoted_tablename
3862     (PostGISTable._fetch_table_information): Use the quoted table
3863     name. New isntance variable quoted_geo_col with a quoted version
3864     of geometry_column
3865     (PostGISTable.NumRows, PostGISTable.RowIdToOrdinal)
3866     (PostGISTable.RowOrdinalToId): Use the quoted table name
3867     (PostGISTable.ReadValue, PostGISTable.ValueRange)
3868     (PostGISTable.UniqueValues, PostGISTable.SimpleQuery)
3869     (PostGISShapeStore.BoundingBox, PostGISShapeStore.Shape)
3870     (PostGISShapeStore.AllShapes, PostGISShapeStore.ShapesInRegion):
3871     Use quoted table and column names
3872    
3873     * test/test_postgis_db.py (TestPostGISSpecialCases)
3874     (TestPostGISIgnoredColumns): Rename the class to
3875     TestPostGISSpecialCases because that better describes the new
3876     cases
3877     (TestPostGISSpecialCases.test_unsupported_types)
3878     (TestPostGISSpecialCases.test): Rename the method to
3879     test_unsupported_types because we need a more descriptive name now
3880     that there are more methods
3881     (TestPostGISSpecialCases.test_table_name_quoting)
3882     (TestPostGISSpecialCases.test_column_name_quoting)
3883     (TestPostGISSpecialCases.test_shapestore_name_quoting): New test
3884     cases to test quoting of table and column names in PostGISTable
3885     and PostGISShapeStore
3886    
3887     * test/postgissupport.py
3888     (skip_if_addgeometrycolumn_does_not_use_quote_ident): New. Skip if
3889     AddGeometryColumn desn't support table or column names with sapces
3890     or double quotes
3891    
3892 jan 1945 2003-11-12 Jan-Oliver Wagner <[email protected]>
3893    
3894     * Extensions/wms/__init__.py: New: Init to make this
3895     directory a package.
3896    
3897     * Extensions/wms/wms.py: New: Provide layers via OGC WMS.
3898    
3899 bh 1932 2003-11-11 Bernhard Herzog <[email protected]>
3900    
3901 bh 1942 * Thuban/Model/resource.py (EPSG_DEPRECATED_PROJ_FILE): New.
3902     Constant for the file woth deprecated epsg projections
3903     (get_system_proj_file): Update doc-string
3904    
3905     * Thuban/UI/projdialog.py (ProjFrame.build_dialog): Add a space
3906     above the EPS widgets, introduce a check box for the deprecated
3907     eps projections and a label for the epsg widgets
3908     (ProjFrame._OnShowEPSG): Handle the deprecated EPSG projections
3909     too
3910    
3911     2003-11-11 Bernhard Herzog <[email protected]>
3912    
3913 bh 1939 Avoid warnings when run under Python 2.3
3914    
3915     * Thuban/UI/baserenderer.py (BaseRenderer.draw_point_shape)
3916     (BaseRenderer.draw_label_layer): Coordinates must be ints.
3917    
3918     * Thuban/UI/renderer.py (MapRenderer.make_point): Turn this into a
3919     real method so that we can convert to int.
3920     (MapRenderer.label_font): The font size mist be an int.
3921    
3922     * Thuban/UI/common.py (Color2wxColour): The color values must be
3923     ints. Also, remove the unnecessary asserts.
3924    
3925     * test/test_load_0_8.py (TestUnicodeStrings.file_contents)
3926     (TestUnicodeStrings.test): Python source code should not contain
3927     non-ascii characters unless an encoding is specified in the file.
3928     Therefore use \x escapes in the string literals for non-ascii
3929     characters.
3930    
3931     2003-11-11 Bernhard Herzog <[email protected]>
3932    
3933 bh 1934 * Thuban/Model/resource.py (get_system_proj_file): Add a filename
3934     parameter so that this function can be used for all proj files in
3935     Resource/Projections
3936     (DEFAULT_PROJ_FILE, EPSG_PROJ_FILE): New. Predefined filenames for
3937     get_system_proj_file
3938    
3939     * Thuban/UI/projdialog.py (ProjFrame.__init__): Instead of one
3940     ProjFile self.__sysProjFile use a dictionary of system ProjFile
3941     objects self._sys_proj_files
3942     (ProjFrame.build_dialog): Adapt to the new changes in the
3943     ProjectionList constructor. Add a check button to toggle whether
3944     EPSG projections are shown
3945     (ProjFrame._OnShowEPSG): New. Handler for the epsg check button
3946     events.
3947     (ProjFrame.load_user_proj, ProjFrame.load_system_proj): Only show
3948     the busy cursor if the files have not yet been loaded by the
3949     dialog.
3950     (ProjFrame.load_system_proj): Add a parameter for the name of the
3951     proj file. Maintain the dictionary of system projections
3952     self._sys_proj_files
3953    
3954     * Thuban/UI/projlist.py (ProjectionList): Merge the system_projs,
3955     user_projs parameters into one parameter proj_files which is a
3956     list of proj files.
3957     (ProjectionList._subscribe_proj_files)
3958     (ProjectionList._unsubscribe_proj_files): New. Move
3959     subscription/unsubscription of projfile messages to separate
3960     methods
3961     (ProjectionList.Destroy): The unsubscribe is now done in
3962     _unsubscribe_proj_files
3963     (ProjectionList.update_projections): We now have a list of proj
3964     file objects
3965     (ProjectionList.SetProjFiles): New method to set a new list of
3966     proj file objects
3967    
3968     * test/test_proj.py (ProjFileReadTests.test_get_system_proj_file):
3969     Specify explicitly which system proj file to load.
3970    
3971     2003-11-11 Bernhard Herzog <[email protected]>
3972    
3973 bh 1932 * Thuban/Model/load.py (SessionLoader.Destroy): New. Clear all
3974     instance variables to cut cyclic references. The GC would have
3975     collected the loader eventually but it can happen that it doesn't
3976     run at all until thuban is closed (2.3 but not 2.2 tries a bit
3977     harder and forces a collection when the interpreter terminates)
3978     (load_session): Call the handler's Destroy method to make sure
3979     that it gets garbage collected early. Otherwise it will be
3980     collected very late if at all and it holds some references to e.g.
3981     shapestores and the session which can lead to leaks (of e.g. the
3982     temporary files)
3983    
3984     * test/test_load.py (TestSingleLayer.test_leak): New. test for the
3985     resource leak in load_session
3986    
3987 bh 1929 2003-11-10 Bernhard Herzog <[email protected]>
3988    
3989     * Thuban/UI/baserenderer.py: Add a way to specify how layers in
3990     extensions are to be rendered.
3991     (_renderer_extensions): New. List with renderer for layers in
3992     extensions
3993     (add_renderer_extension): New. Add a renderer extension
3994     (init_renderer_extensions): New. Init the renderer extensions
3995     (BaseRenderer.render_map_incrementally): Search
3996     _renderer_extensions for how to draw unknown layer types
3997     (BaseRenderer.draw_raster_data): Add format parameter so that
3998     formats other than BMP can be drawn
3999     (BaseRenderer.draw_raster_layer): Pass an explicit format to
4000     draw_raster_data
4001    
4002     * Thuban/UI/renderer.py (raster_format_map): New. Mapping form the
4003     strings of the format parameter of draw_raster_data method to wx
4004     constants
4005     (MapRenderer.draw_raster_data): Add the format parameter and use
4006     raster_format_map to map it to the right wxwindows constant for
4007     wxImageFromStream
4008    
4009     * test/test_baserenderer.py (SimpleRenderer.draw_raster_data): Add
4010     the format parameter and record it
4011     (TestBaseRenderer.test_raster_no_projection): check the format
4012     paramter of the draw_raster_data method
4013     (TestBaseRenderer.test_renderer_extension): New. Test the renderer
4014     extension facility
4015    
4016 bh 1925 2003-11-07 Bernhard Herzog <[email protected]>
4017    
4018     Tweak the usage of the sqlite database to make common use cases
4019     more responsive. In most cases copying the data to the sqlite
4020     database takes so long that using sqlite doesn't have enough
4021     advantages.
4022    
4023     * Thuban/Model/transientdb.py (TransientTableBase.ValueRange): Add
4024     comments about performance and query the min and max in separate
4025     statements because only that way will indexes be used.
4026     (TransientTableBase.UniqueValues): Add some comments about
4027     performance.
4028     (AutoTransientTable.ValueRange, AutoTransientTable.UniqueValues):
4029     Do not copy the data to the transient DB but use the transient
4030     copy if it exists. See the new comments for the performance trade
4031     offs
4032    
4033     * test/test_transientdb.py
4034     (TestTransientTable.test_auto_transient_table): Make sure that the
4035     data is copied to the transient database at some point.
4036    
4037 bh 1913 2003-11-03 Bernhard Herzog <[email protected]>
4038    
4039 bh 1922 * Thuban/Model/data.py (ShapefileStore.ShapesInRegion): Bind some
4040     globals to locals so that it's a bit faster
4041    
4042     2003-11-03 Bernhard Herzog <[email protected]>
4043    
4044 bh 1920 * Thuban/UI/baserenderer.py
4045     (BaseRenderer.draw_shape_layer_incrementally): Use the ReadValue
4046     method. ReadValue is faster than ReadRowAsDict since it only reads
4047     one cell especially now that the dbf file objects actually
4048     implement it.
4049    
4050     * Thuban/Model/table.py (DBFTable.ReadValue): Use the new
4051     read_attribute method of the dbf objects
4052    
4053     2003-11-03 Bernhard Herzog <[email protected]>
4054    
4055 bh 1916 * Extensions/profiling/profiling.py (popup_dialog_box): New config
4056     variable to indicate whether the result should be shown in a
4057     dialog box
4058     (profile_screen_renderer, time_screen_renderer): Only show a
4059     dialog box if popup_dialog_box is true.
4060     (profile_screen_renderer): Flush stdout after the printing the
4061     first part of the "profiling..." message
4062    
4063     * Thuban/UI/baserenderer.py
4064     (BaseRenderer.draw_shape_layer_incrementally): Cache the pens and
4065     brushes for the groups so that they're not created over and over
4066     again
4067    
4068 bh 1913 * Thuban/Model/classification.py (Classification.__getattr__)
4069     (Classification._compile_classification)
4070     (Classification._clear_compiled_classification): New. Methods to
4071     manage a 'compiled' representation of the classification groups
4072     which is created on demand
4073     (Classification.InsertGroup, Classification.RemoveGroup)
4074     (Classification.ReplaceGroup): reset the compiled representation
4075     (Classification.FindGroup): Use the compiled representation to
4076     find the matching group
4077     (ClassGroupRange.GetRangeTuple): New. Return the range as a tuple
4078    
4079 bh 1904 2003-10-31 Bernhard Herzog <[email protected]>
4080    
4081 bh 1911 * Thuban/Model/classification.py (Classification.SetDefaultGroup):
4082     Send a CLASS_CHANGED message
4083     (Classification.RemoveGroup): Send a CLASS_CHANGED message and do
4084     not return the removed group since it wasn't used.
4085    
4086     * test/test_classification.py
4087     (TestClassification.test_set_default_group): New. Test the
4088     SetDefaultGroup method
4089     (TestClassification.test_insert_group): New. Test the InsertGroup
4090     method
4091     (TestClassification.test_remove_group): New. Test the RemoveGroup
4092     method
4093     (TestClassification.test_replace_group): New. Test the
4094     ReplaceGroup method
4095    
4096     2003-10-31 Bernhard Herzog <[email protected]>
4097    
4098 bh 1908 * test/test_classification.py (TestClassification.setUp):
4099     Subscribe to the CLASS_CHANGED messages
4100     (TestClassification.tearDown): New. Destroy the classification
4101     properly
4102     (TestClassification.test_defaults): Add tests for the default line
4103     width and whether no messages were sent yet
4104     (TestClassification.test_set_default_properties): Add tests for
4105     messages and setting the default line width
4106     (TestClassification.test_add_singleton)
4107     (TestClassification.test_add_range)
4108     (TestClassification.test_multiple_groups): Add tests for messages
4109    
4110     2003-10-31 Bernhard Herzog <[email protected]>
4111    
4112 bh 1906 Some more refactoring in preparation for new tests:
4113    
4114     * test/test_classification.py (TestClassification.setUp): New.
4115     Instantiate the classification here. Update the test methods
4116     accordingly.
4117     (TestClassification.test_multiple_groups): Make sure that the two
4118     singletons matching 1 are considered different.
4119    
4120     2003-10-31 Bernhard Herzog <[email protected]>
4121    
4122 bh 1904 * test/test_classification.py (red, green, blue): New. These
4123     constants were used in several cases. Update the relevant methods.
4124     (TestClassification.test_defaults)
4125     (TestClassification.test_set_default_properties)
4126     (TestClassification.test_add_singleton)
4127     (TestClassification.test_add_range)
4128     (TestClassification.test_multiple_groups)
4129     (TestClassification.test_deepcopy): New. These were formerly all
4130     part of the single method test.
4131     (TestClassification.test_deepcopy): Removed.
4132     (TestClassIterator): Removed. The test case is now a method of
4133     TestClassification since it tests part of the public interface of
4134     Classification
4135     (TestClassification.test_iterator): New. Used to be
4136     TestClassIterator effectively
4137    
4138 jan 1902 2003-10-31 Jan-Oliver Wagner <[email protected]>
4139    
4140     GUIfied the functions of the profiling extension.
4141    
4142     * /Extensions/profiling/__init__.py: New: Init to make this
4143     directory a package.
4144    
4145     * Extensions/profiling/profiling.py: Moved menu entries to
4146     the Extensions menu. Applied _() for strings.
4147     (profile_screen_renderer): Catch the detailed printout and present
4148     it in a dialog.
4149 bh 1904 (time_screen_renderer): Raise a dialog to present the result instead
4150 jan 1902 of printing it to stdout.
4151    
4152 bh 1897 2003-10-31 Bernhard Herzog <[email protected]>
4153    
4154 bh 1899 * test/test_classification.py (TestClassGroupProperties)
4155     (TestClassGroup, TestClassGroupDefault, TestClassGroupRange)
4156     (TestClassGroupSingleton, TestClassIterator, TestClassification):
4157     Split TestClassification into several classes, one for each class
4158     being tested. TestClassification itself now only tests
4159     Classification. This split makes changes to the tests a bit easier
4160    
4161     2003-10-31 Bernhard Herzog <[email protected]>
4162    
4163 bh 1897 * Extensions/profiling/profiling.py: New. Extension to measure
4164     Thuban performance
4165    
4166 frank 1895 2003-10-31 Frank Koormann <[email protected]>
4167    
4168     Added two items to legend popup menu: Remove Layer and Show Layer Table
4169    
4170     * Thuban/UI/legend.py (LegendPanel._OnRemoveLayer,
4171     LegendPanel._OnShowTable): New event handlers, call the corresponding
4172     mainwindow methods.
4173     (LegendTree._OnRightClick): Added items to popup menu.
4174    
4175 bh 1894 2003-10-30 Bernhard Herzog <[email protected]>
4176    
4177     * Thuban/UI/dialogs.py (ThubanFrame.__init__): Handle
4178     EVT_WINDOW_DESTROY
4179     (ThubanFrame.OnDestroy): New. Handler for EVT_WINDOW_DESTROY. Does
4180     nothing but is convenient for the derived classes.
4181    
4182     * Thuban/UI/tableview.py
4183     (TableFrame.OnDestroy, LayerTableFrame.OnDestroy): New.
4184     Unsubscribe the messages here not in OnClose because that might
4185     get called multiple times. Fixes RT #2196
4186     (TableFrame.OnClose, LayerTableFrame.OnClose): Removed. Not needed
4187     anymore.
4188    
4189     * README: Update the minimum requirement for wxPython. Since we
4190     now use the EVT_WINDOW_DESTROY event, we need at least 2.4.0.4,
4191     the version in which that was introduced for all platforms
4192    
4193 frank 1890 2003-10-30 Frank Koormann <[email protected]>
4194    
4195     * Thuban/UI/join.py (JoinDialog.OnJoin): Wrapped the major parts of
4196     the join process in a ThubanBeginBusyCursor, ThubanEndBusyCursor
4197     frame.
4198    
4199 jan 1889 2003-10-30 Jan-Oliver Wagner <[email protected]>
4200    
4201     Improved APR import extension, added further EPSG definitions
4202     and some cleanup regarding string class.
4203    
4204     * test/test_proj.py (TestProjection.test_get_projection_units_geo):
4205     Added test for alias 'longlat'.
4206    
4207     * Resources/Projections/epsg-deprecated.proj: New. Contains
4208     deprecated EPSG definitions.
4209    
4210     * Extensions/importAPR/odb.py (ODBBaseObject.TreeInfo): Added
4211     the variable names for objects.
4212    
4213     * Extensions/importAPR/apr.py (APR_BLnSym, APR_BMkSym, APR_BShSym): New.
4214     Copied from importAPR and provided with documentation.
4215    
4216     * Extensions/importAPR/importAPR.py (APR_BLnSym, APR_BMkSym, APR_BShSym):
4217     Moved to apr.py.
4218     (APR_View): Added object ref 'ITheme'.
4219    
4220     * Thuban/Lib/fileutil.py, Thuban/UI/proj4dialog.py: Replaced string
4221     split function by corresponding use of the string class method.
4222    
4223     * Thuban/Model/xmlwriter.py: Replaced string replace function by
4224     corresponding string method.
4225    
4226 bh 1880 2003-10-29 Bernhard Herzog <[email protected]>
4227    
4228     * Thuban/UI/baserenderer.py
4229     (BaseRenderer.draw_shape_layer_incrementally): Speed up the
4230     special case of a classification that only has the default group
4231    
4232 bh 1868 2003-10-27 Bernhard Herzog <[email protected]>
4233    
4234 bh 1878 * po/fr.po, po/es.po: Updated translations from Daniel Calvelo
4235    
4236 bh 1876 * po/de.po: Update.
4237    
4238     * Thuban/UI/application.py
4239     (ThubanApplication.ShowExceptionDialog): Handle translation of the
4240     dialog message properly
4241    
4242     2003-10-27 Bernhard Herzog <[email protected]>
4243    
4244 bh 1873 Rework how localization works so that we use wx's translation
4245     functions when running Thuban as a normal application but not when
4246     we don't need any UI, such as in the test suite. See the comment
4247     in Thuban/__init__.py for details
4248    
4249     * Thuban/__init__.py (_): Add one level of indirection to make the
4250     translation handling more flexible and to make it possible to use
4251     either wx's translation services or not.
4252     (gettext_identity, translation_function_installed)
4253     (install_translation_function): New function to help with this
4254    
4255     * Thuban/UI/__init__.py: Install the wx specific translation
4256     function if it's OK to do that
4257    
4258     * test/support.py (initthuban): Install a dummy translation
4259     function so that importing Thuban.UI doesn't install a wx specific
4260     one for which would need to import wxPython
4261    
4262     2003-10-27 Bernhard Herzog <[email protected]>
4263    
4264 bh 1870 * HOWTO-Release: Source archives should be created first and the
4265     binary packages should be created from the source archives.
4266     There's an official debian package now so there's no need to test
4267     the rpm on debian anymore
4268    
4269     2003-10-27 Bernhard Herzog <[email protected]>
4270    
4271 bh 1868 Several rendering changes:
4272    
4273     - Render the selection into a separate bitmap so that only that
4274     bitmap needs to be redrawn when the selection changes
4275    
4276     - Render incrementally showing previews and allowing interaction
4277     before rendering is complete
4278    
4279     - Update the renderer interface a bit. Most parameters of
4280     RenderMap are now parameters of the constructor
4281    
4282     * Thuban/UI/baserenderer.py (BaseRenderer.__init__): Add the map
4283     and the update region as parameters. Update the doc-string
4284     (BaseRenderer.render_map_incrementally): New. Generator function
4285     to renders the map incrementally
4286     (BaseRenderer.render_map): Remove the map argument (it's now in
4287     the constructor) and simply iterate over the
4288     render_map_incrementally generator to draw the map.
4289     (BaseRenderer.draw_shape_layer_incrementally)
4290     (BaseRenderer.draw_shape_layer): Renamed to
4291     draw_shape_layer_incrementally and changed into a generator that
4292     yields True every 500 shapes. Used by render_map_incrementally to
4293     render shape layers incrementally
4294    
4295     * Thuban/UI/renderer.py (ScreenRenderer.RenderMap): Removed the
4296     map and region parameters which are now in the constructor
4297     (ScreenRenderer.RenderMapIncrementally): New. Public frontend for
4298     the inherited render_map_incrementally.
4299     (BaseRenderer.draw_shape_layer): Removed.
4300     (ScreenRenderer.draw_selection_incrementally): New. The selection
4301     drawing part of the removed draw_shape_layer as a generator
4302     (ScreenRenderer.layer_shapes): Update because of the region
4303     parameter change
4304     (ExportRenderer.__init__): New. Extend the inherited constructor
4305     with the destination region for the drawing
4306     (ExportRenderer.RenderMap): Removed the map and region parameters
4307     which are now in the constructor
4308    
4309     * Thuban/UI/view.py (MapCanvas.PreviewBitmap): New. Return a
4310     bitmap suitable for a preview in a tool
4311     (CanvasPanTool.MouseMove): Use the PreviewBitmap method to get the
4312     bitmap
4313     (MapPrintout.draw_on_dc): Adapt to new renderer interface
4314     (MapCanvas.OnPaint): Handle drawing the selection bitmap if it
4315     exists
4316     (MapCanvas.OnIdle): Update the logic to deal with incremental
4317     rendering and the selection bitmap
4318     (MapCanvas._do_redraw): Handle the instantiation of the render
4319     iterator and the redraws during rendering
4320     (MapCanvas._render_iterator): New. Generator to incrementally
4321     redraw both bitmaps
4322     (MapCanvas.Export): Adapt to new renderer interface.
4323     (MapCanvas.full_redraw): Reset the selection bitmap and the
4324     renderer iterator too
4325     (MapCanvas.redraw_selection): New. Force a redraw of the selection
4326     bitmap
4327     (MapCanvas.shape_selected): Only redraw the selection bitmap
4328    
4329     * test/test_baserenderer.py
4330     (TestBaseRenderer.test_polygon_no_projection)
4331     (TestBaseRenderer.test_raster_no_projection)
4332     (TestBaseRenderer.test_point_map_projection)
4333     (TestBaseRenderer.test_point_layer_and_map_projection)
4334     (TestBaseRenderer.test_point_layer_projection)
4335     (TestBaseRenderer.test_point_with_classification): Adapt to new
4336     renderer interface
4337    
4338 bh 1865 2003-10-24 Bernhard Herzog <[email protected]>
4339    
4340     * libraries/thuban/wxproj.cpp (draw_polygon_shape)
4341     (point_in_polygon_shape, shape_centroid): Raise an exception if
4342     the shape can't be read. Previously invalid shape ids would lead
4343     to a segfault.
4344    
4345     * test/test_wxproj.py (TestShapeCentroid.test_invalid_shape_id):
4346     New. test whether an exception is raised for invalid shape ids
4347    
4348 jan 1857 2003-10-24 Jan-Oliver Wagner <[email protected]>
4349    
4350 jan 1862 * Thuban/Model/proj.py (Projection.GetProjectedUnits): Added 'longlat'
4351     as alias for 'latlong'.
4352    
4353     * Thuban/UI/projdialog.py (ProjFrame.__init__): Added 'longlat'
4354     as alias for 'latlong'.
4355    
4356     2003-10-24 Jan-Oliver Wagner <[email protected]>
4357    
4358 jan 1859 * Thuban/UI/projdialog.py (ProjFrame.proj_selection_changed): Set
4359     the projection even for the UnknownPanel.
4360     (UnknownProjPanel.__init__): Define the text and create the textctrl
4361     widget.
4362     (UnknownProjPanel._DoLayout): Replaced static text widget by the
4363     textctrl created in __init__.
4364     (UnknownProjPanel.SetProjection): Set the text for the text ctrl
4365     including the parameters of the projection.
4366    
4367     2003-10-24 Jan-Oliver Wagner <[email protected]>
4368    
4369 jan 1857 * Resources/Projections/epsg.proj: New. This is a list of
4370     EPSG codes with parameters for proj. The list has been
4371     generated using devtools/create_epsg.py based on the
4372     file nad/epsg of the proj 4.4.7 package. Four projection
4373     definitions have been deleted as they are not accepted by proj:
4374     "CH1903+ / LV95", "Bern 1898 (Bern) / LV03C", "CH1903 / LV03"
4375     and "HD72 / EOV".
4376    
4377 bh 1855 2003-10-22 Bernhard Herzog <[email protected]>
4378    
4379     Some more tweaks to the projection dialog which should fix RT
4380     #1886.
4381    
4382     * Thuban/UI/projlist.py (ProjectionList.Destroy): Unsubscribe from
4383     the ProjFile's messages and call the base class methods correctly
4384     (ProjectionList.SelectProjection): Set the wxLIST_STATE_FOCUSED
4385     flag on the newly selected item too. Otherwise some other item is
4386     focused and the first time the focus is moved with the keyboard
4387     the selection moves in unexpected ways.
4388    
4389     * Thuban/UI/projdialog.py (ProjFrame.__init__): Do not set the
4390     focus on the OK button, only on the projection list. That way the
4391     list really has the focus initially
4392     (ProjFrame.OnClose): Call the projection list's Destroy method to
4393     make it unsubscribe all messages
4394    
4395 bh 1840 2003-10-21 Bernhard Herzog <[email protected]>
4396    
4397 bh 1852 Rework the projection dialog to fix a few bugs, including RT 2166
4398     and most of 2168
4399    
4400     * Thuban/UI/projlist.py: New. The class ProjectionList is a
4401     special wxListCtrl to show a list of projections in a more MVC
4402     fashion
4403    
4404     * Thuban/UI/projdialog.py (ProjFrame): Substantial changes
4405     throughout the class. The main change is to use the ProjectionList
4406     class instead of a normal wxListBox. Also, add an explicit
4407     "Unknown" projection to the projection choice control.
4408     (ProjPanel.__init__): Add an "unknown" ellipsoid
4409     (TMPanel.__init__, LCCPanel.__init__): Tweak the order of
4410     instantiation of the panel's controls to make the tab-order more
4411     natural
4412    
4413     2003-10-21 Bernhard Herzog <[email protected]>
4414    
4415 bh 1849 * test/test_load.py (TestSingleLayer.file_contents)
4416     (TestSingleLayer.test): Add non-ascii characters to the titles of
4417     session, map and layer. This is effectively a port of the
4418     TestUnicodeStrings test in test_load_0_8.py which for some reason
4419     was only added there.
4420    
4421     * test/test_load_0_9.py (TestSingleLayer.file_contents)
4422     (TestSingleLayer.test): Same as in test_load.py: add non-ascii
4423     characters to the titles of session, map and layer,.
4424    
4425     2003-10-21 Bernhard Herzog <[email protected]>
4426    
4427 bh 1847 Add EPSG projection handling to .thuban files
4428    
4429     * test/test_save.py (SaveSessionTest.dtd)
4430     (SaveSessionTest.testEmptySession)
4431     (SaveSessionTest.testLayerProjection)
4432     (SaveSessionTest.testRasterLayer)
4433     (SaveSessionTest.testClassifiedLayer)
4434     (SaveSessionTest.test_dbf_table)
4435     (SaveSessionTest.test_joined_table)
4436     (SaveSessionTest.test_save_postgis): Update to 1.0-dev namespace
4437     (SaveSessionTest.testSingleLayer): Update to 1.0-dev namespace and
4438     use a and epsg projection to test saving them
4439    
4440     * test/test_load.py (LoadSessionTest.dtd): Update to 1.0-dev
4441     namespace
4442     (TestLayerVisibility.file_contents, TestLabels.file_contents)
4443     (TestLayerProjection.file_contents)
4444     (TestRasterLayer.file_contents, TestJoinedTable.file_contents)
4445     (TestPostGISLayer.file_contents)
4446     (TestPostGISLayerPassword.file_contents)
4447     (TestLoadError.file_contents, TestLoadError.test): Update to use
4448     1.0-dev namespace
4449     (TestSingleLayer.file_contents, TestSingleLayer.test): Update to
4450     use 1.0-dev namespace and use an EPSG projection to test whether
4451     loading it works
4452    
4453     * test/test_load_0_9.py: New. Effectively a copy of test_load.py
4454     as of Thuban 0.9. These are now tests to determine whether Thuban
4455     can still read files generated by Thuban 0.9
4456    
4457     * Thuban/Model/save.py (SessionSaver.write)
4458     (SessionSaver.write_session): Use the 1.0 dtd and 1.0-dev
4459     namespace
4460     (SessionSaver.write_projection): Write the projection's epsg
4461     attribute
4462    
4463     * Thuban/Model/load.py (SessionLoader.__init__): Also accept the
4464     thuban-1.0-dev.dtd namespace
4465     (SessionLoader.check_attrs): Allow a callable object as conversion
4466     too
4467     (SessionLoader.start_projection, SessionLoader.end_projection)
4468     (SessionLoader.start_parameter): Handle the epsg attribute and
4469     rename a few instance variables to lower case
4470    
4471     * Resources/XML/thuban-1.0.dtd: New. Only difference to
4472     thuban-0.9.dtd is the epsg attribute for projections.
4473    
4474     2003-10-21 Bernhard Herzog <[email protected]>
4475    
4476 bh 1840 * test/runtests.py (main): Let the user specify which tests to run
4477     on the command line
4478    
4479     * test/support.py (ThubanTestResult.getDescription): Override to
4480     give a better short description. The description can be used as a
4481     parameter to run_tests to run that particular test in isolation.
4482    
4483 frank 1837 2003-10-21 Frank Koormann <[email protected]>
4484    
4485     Popup menu for legend. Scheduled for the 1.2 release this was too
4486     simple to implement: The popup menu is bound to the legend tree, while
4487     the events are hanlded by its anchestor, the legend panel. This
4488     allows reuse of all the event handlers already implemented for the
4489     legend toolbar buttons.
4490    
4491     * Thuban/UI/legend.py (LegendPanel.__init__): EVT_MENU macros
4492     to add handlers for the events issued by the popup menu.
4493     (LegendPanel._OnToggleVisibility): Handler for toggling layer
4494     visibility event
4495     (LegendPanel._OnProjection): Handler for layer projection event.
4496     (LegendTree.__init__): Added EVT_TREE_ITEM_RIGHT_CLICK
4497     (LegendTree._OnRightClick): Event handler for right click, select item
4498     and pop up menu.
4499     (LegendTree.ToggleVisibility): Toggle layer visibility
4500     (LegendTree.LayerProjection): Raise layer projection dialog for
4501     current layer.
4502    
4503 bh 1836 2003-10-21 Bernhard Herzog <[email protected]>
4504    
4505     * Resources/Projections/defaults.proj: Use correct DOCTYPE
4506     declaration. The top-level element is projectionlist not projfile
4507    
4508 bh 1834 2003-10-20 Bernhard Herzog <[email protected]>
4509    
4510     * Thuban/UI/projdialog.py (ProjFrame.write_proj_file): New. helper
4511     method to write a projfile and display a busy cursor and error
4512     dialogs.
4513     (ProjFrame._OnSave, ProjFrame._OnAddToList, ProjFrame._OnImport)
4514     (ProjFrame._OnExport, ProjFrame._OnRemove): Use write_proj_file
4515     (ProjFrame.__FillAvailList): Translate "<None>" too and display a
4516     busy cursor while loading the user and system prj files.
4517    
4518 bh 1832 2003-10-16 Bernhard Herzog <[email protected]>
4519    
4520     * Thuban/Model/resource.py (projfile_cache): Introduce a cache for
4521     ProjFile objects
4522     (clear_proj_file_cache): New function to clear the cache. Mainly
4523     useful for use by the test suite
4524     (read_proj_file): Use the cache.
4525    
4526     * test/test_proj.py (TestProjFile): Clarify the doc-string
4527     (ProjFileReadTests): Update doc-string
4528     (ProjFileReadTests.test_get_system_proj_file): Check whether the
4529     system proj files is cached.
4530     (ProjFileLoadTestCase): New base class for the proj file tests
4531     derived from support.FileLoadTestCase to provide some common
4532     behavior.
4533     (TestLoadingProjFile)
4534     (TestLoadingProjFileWithEmptyProjectionlist.file_contents)
4535     (TestProjFileWithInvalidParameters.file_contents): Derive from
4536     ProjFileLoadTestCase
4537     (TestLoadingProjFile.test_caching): New. Test whether the cache
4538     works
4539    
4540 silke 1829 2003-10-16 Silke Reimer <[email protected]>
4541    
4542     * debian/*: New directory with configuration files for building a thuban
4543     deb-package.
4544    
4545 bh 1822 2003-10-14 Bernhard Herzog <[email protected]>
4546    
4547 bh 1828 * test/test_proj.py: Execute support.run_tests when run as
4548     __main__ so that missing unsubscribes are detected
4549     (TestProjFile.tearDown): Destroy the proj_file properly
4550    
4551     2003-10-14 Bernhard Herzog <[email protected]>
4552    
4553 bh 1826 * Thuban/Model/messages.py (PROJECTION_ADDED)
4554     (PROJECTION_REPLACED, PROJECTION_REMOVED): New message types for
4555     the ProjFile objects
4556    
4557     * Thuban/Model/proj.py (ProjFile): Derive from Publisher so we can
4558     easily send messages when the projections change
4559     (ProjFile.Add, ProjFile.Remove, ProjFile.Replace): Issue messages
4560     when the change was successful
4561    
4562     * test/test_proj.py (TestProjFile.setUp): Subscribe to some of the
4563     proj file messages
4564     (TestProjFile.test_add_remove)
4565     (TestProjFile.test_remove_non_existing)
4566     (TestProjFile.test_replace)
4567     (TestProjFile.test_replace_non_existing): Test whether the right
4568     messages are sent
4569    
4570     2003-10-14 Bernhard Herzog <[email protected]>
4571    
4572 bh 1822 * test/test_proj.py (TestProjFile.test): Refactor into several
4573     tests
4574     (TestProjFile.test_add_remove)
4575     (TestProjFile.test_remove_non_existing)
4576     (TestProjFile.test_replace)
4577     (TestProjFile.test_replace_non_existing): Some of the new
4578     individual test cases
4579     (TestProjFileSimple): New class for the rest of the test cases
4580     that came out of the refactoring
4581     (ProjFileTest): Derive from xmlsupport.ValidationTest so that the
4582     derived classes don't have to
4583    
4584 bh 1812 2003-10-13 Bernhard Herzog <[email protected]>
4585    
4586 bh 1820 Add an optional EPSG code to the projection objects and extend the
4587     .proj file format accordingly.
4588    
4589     * Resources/XML/projfile.dtd (element projection): Add epsg
4590     attribute
4591    
4592     * Thuban/Model/proj.py (Projection.__init__): New parameter and
4593     instance variable epsg. Update doc-string
4594     (Projection.EPSGCode, Projection.Label): New methods to provide
4595     access to EPSG code and a label for use in dialogs
4596    
4597     * Thuban/Model/resource.py (ProjFileReader.start_projection)
4598     (ProjFileReader.end_projection, ProjFileSaver.write_projfile):
4599     Handle the epsg code attribute when reading or writing proj files
4600    
4601     * Thuban/UI/projdialog.py (ProjFrame._OnSave)
4602     (ProjFrame._OnAddToList, ProjFrame.__DoOnProjAvail)
4603     (ProjFrame.__FillAvailList): Use the projection's Label method to
4604     get the string for the list box
4605    
4606     * test/test_proj.py (TestProjection.test_label)
4607     (TestProjection.test_label_epsg)
4608     (TestProjection.test_epsgcode_for_non_epsg_projection)
4609     (TestProjection.test_epsgcode_for_real_epsg_projection): New tests
4610     for the label and EPSGCode methods
4611     (WriteProjFileTests.doTestWrite, WriteProjFileTests.test_write)
4612     (WriteProjFileTests.test_write_empty_file): Create the ProjFile
4613     objects in the test cases and put the expected contents into the
4614     test case methods too. Update doTestWrite accordingly
4615     (TestLoadingProjFile)
4616     (TestLoadingProjFileWithEmptyProjectionlist): New classes with the
4617     read tests from TestProjFile.
4618     (TestProjFile.doTestRead, TestProjFile.testRead): Removed. These
4619     tests are now in the new classes.
4620     (sample_projfile, sample_projfile_data)
4621     (sample_projfile2, sample_projfile_data2): Removed. Not used
4622     anymore.
4623     (TestProjFile.test_read_unreadable_file): No need to reset the
4624     permissions at the end anymore since we use a unique filename
4625    
4626     2003-10-13 Bernhard Herzog <[email protected]>
4627    
4628 bh 1814 * test/test_proj.py: Some more refactoring of the test cases
4629     (ProjFileTest): New base class for the proj file tests.
4630     (TestProjFile): Derive from ProjFileTest
4631     (TestProjFile.test_read_unreadable_file)
4632     (TestProjFile.test_read_empty_file, TestProjFile.doTestRead): Use
4633     the new filename method to get a unique filename
4634     (TestProjFile.doTestWrite, TestProjFile.testWrite): Removed.
4635     (WriteProjFileTests): New class for proj file write tests.
4636     Contains the write test that were in TestProjFile originally.
4637    
4638     2003-10-13 Bernhard Herzog <[email protected]>
4639    
4640 bh 1812 * test/test_proj.py (TestProjFile.testRead)
4641     (TestProjFile.test_read_non_existing_file)
4642     (TestProjFile.test_read_unreadable_file)
4643     (TestProjFile.test_read_empty_file): Split into several methods.
4644    
4645 bh 1805 2003-10-10 Bernhard Herzog <[email protected]>
4646    
4647 bh 1810 * Thuban/UI/sizers.py: New file with custom sizers.
4648    
4649     * Thuban/UI/projdialog.py (ProjFrame.build_dialog): Instantiate
4650     all projection type specific panels and put them into a
4651     NotebookLikeSizer. This way the dialog doesn't change its size
4652     when a different projection is selected
4653     (ProjFrame.__init__): Rename projection_panels
4654     projection_panel_defs and reuse projection_panels for a list of
4655     the instantiated panels.
4656     (ProjFrame._show_proj_panel, ProjFrame.__DoOnProjAvail)
4657     (ProjFrame.__DoOnProjChoice): Changes due to the new handling of
4658     the panels
4659     (UnknownProjPanel._DoLayout): Place the newlines in the message
4660     differently to make the panel narrower.
4661     (TMPanel._DoLayout): Layout the parameters in one column.
4662    
4663     2003-10-10 Bernhard Herzog <[email protected]>
4664    
4665 bh 1807 * Thuban/UI/projdialog.py (ProjFrame.build_dialog): New method
4666     that contains all the setup for the dialog's widgets, layout and
4667     event handling.
4668     (__): Call build_dialog to build the dialog.
4669     (ProjFrame.__set_properties, ProjFrame.__do_layout): Removed.
4670     Their functionality is now in build_dialog
4671     (ProjFrame.__VerifyButtons, ProjFrame.__VerifyButtons)
4672     (ProjFrame.__DoOnProjAvail, ProjFrame.__DoOnProjAvail)
4673     (ProjFrame.__DoOnProjChoice): Small updates due to slightly
4674     different widget names and hierarchy introduced with build_dialog.
4675    
4676     2003-10-10 Bernhard Herzog <[email protected]>
4677    
4678 bh 1805 * README: Fix typo.
4679    
4680 bh 1803 2003-10-09 Bernhard Herzog <[email protected]>
4681    
4682     * Thuban/Model/proj.py (ProjFile.Add): Do not check whether the
4683     projection is already in the list. This is *a lot* faster when
4684     loading files with hundreds of projections since it saves a linear
4685     search. OTOH this will allow adding the same projection to the
4686     user.proj file multiple times in the projection dialog but we'll
4687     deal with that later
4688    
4689 jan 1801 2003-10-09 Jan-Oliver Wagner <[email protected]>
4690    
4691     * devtools: New. Directory for developer tools that are not intended
4692     for the regular user.
4693    
4694     * devtools/create_epsg.py: New. Convert the epsg file of proj into
4695     a python .proj file.
4696    
4697 bh 1799 2003-10-09 Bernhard Herzog <[email protected]>
4698    
4699     * test/test_proj.py
4700     (TestProjection.test_get_parameter_without_equals_sign): New. Test
4701     whether GetParameter handles parameters without "=" sign correctly
4702    
4703     * Thuban/Model/proj.py (Projection.GetParameter): Handle
4704     parameters that do not contain a "=". Update the doc-string
4705    
4706 bh 1794 2003-10-08 Bernhard Herzog <[email protected]>
4707    
4708 bh 1796 * Thuban/UI/projdialog.py (ProjFrame.__set_properties): Remove the
4709     length limit on the projname text control
4710    
4711     2003-10-08 Bernhard Herzog <[email protected]>
4712    
4713 bh 1794 * test/test_proj.py (TestProjection.test_get_projection_units_geo)
4714     (TestProjection.test_get_projection_units_normal): New. Tests for
4715     the Projection.GetProjectedUnits method
4716    
4717 jan 1792 2003-10-08 Jan-Oliver Wagner <[email protected]>
4718    
4719     * Thuban/Model/resource.py (get_user_proj_file): small bug-fix:
4720     Added missing 'val' parameter.
4721    
4722 bh 1788 2003-10-08 Bernhard Herzog <[email protected]>
4723    
4724 bh 1790 * Thuban/UI/projdialog.py (ProjFrame.__DoOnProjAvail): When the
4725     projection type of the currently selected projection is not known,
4726     i.e. there's no panel for it, use the UnknownProjPanel
4727     (ProjFrame.__DoOnProjChoice, ProjFrame._show_proj_panel): Split
4728     the actual replacing of the proj panel into the new method
4729     _show_proj_panel.
4730     (UnknownProjPanel): Add doc-string.
4731     (UnknownProjPanel._DoLayout): Insert a newline into the text so
4732     that the panel is not so wide.
4733    
4734     2003-10-08 Bernhard Herzog <[email protected]>
4735    
4736 bh 1788 * Thuban/Model/resource.py (read_proj_file): Return the warnings
4737     too. Update the doc-string
4738     (get_proj_files): Removed. It wasn't used anywhere
4739     (get_system_proj_files, get_system_proj_file): Rename to
4740     get_system_proj_file and return the ProjFile object and not a list
4741     of ProjFile objects. Update the callers.
4742     (get_user_proj_files, get_user_proj_file): Rename to
4743     get_user_proj_file return the ProjFile object and not a list of
4744     ProjFile objects. Update the callers.
4745     (ProjFileReader.__init__): New instance variable for the warnings.
4746     Rename the __pf ivar to projfile. Update the methods referring to
4747     __pf
4748     (ProjFileReader.end_projection): Catch any errors raised when
4749     instantiating the projection and record that as an error. The
4750     projection will not be in the final ProjFile object.
4751     (ProjFileReader.GetWarnings): New method to return the warnings.
4752    
4753     * Thuban/UI/projdialog.py (ProjFrame.show_warnings): New method to
4754     show the warnings from the projfile reader
4755     (ProjFrame._OnImport): Deal with any warnings returned by
4756     read_proj_file
4757     (ProjFrame.__FillAvailList): Deal with any warnings returned by
4758     get_system_proj_file or get_user_proj_file.
4759    
4760     * test/test_proj.py (TestProjFile.doTestRead): Check the warnings.
4761     (TestProjFileWithInvalidParameters.file_contents): New test cases
4762     to test whether read_proj_file handles invalid projection
4763     parameters correctly
4764     (TestProjFile.test_get_system_proj_file): New. Simple test for
4765     resource.get_system_proj_file
4766    
4767 bh 1785 2003-10-07 Bernhard Herzog <[email protected]>
4768    
4769     * test/test_derivedshapestore.py
4770     (TestDerivedShapeStoreExceptions.tearDown): Clear the session
4771     properly so that the temporary directories get deleted correctly
4772    
4773 bh 1773 2003-10-06 Bernhard Herzog <[email protected]>
4774    
4775 bh 1783 Handle the title changes in a proper MVC way.
4776    
4777     * Thuban/UI/mainwindow.py (MainWindow.__init__): Subscribe to the
4778     canvas' TITLE_CHANGED messages
4779     (MainWindow.update_title): New. Update the main window's title
4780     (MainWindow.__SetTitle): Removed. Use update_title instead.
4781     (MainWindow.SetMap): Use update_title instead of __SetTitle
4782     (MainWindow.RenameMap): Do change the window title explicitly
4783     here. That's handled in a proper MVC way now.
4784     (MainWindow.title_changed): New. Subscriber for the TITLE_CHANGED
4785     messages
4786    
4787     * Thuban/Lib/connector.py (Conduit): New class to help classes
4788     that forward messages
4789    
4790     * Thuban/UI/viewport.py: Forward the map's TITLE_CHANGED messages
4791     (ViewPort): Derive from Conduit instead of Publisher
4792     (ViewPort.Subscribe, ViewPort.Unsubscribe): Use the new base class
4793     when calling the inherited versions
4794     (ViewPort._subscribe_map, ViewPort._unsubscribe_map): New helper
4795     methods to subscribe and unsubscribe map messages
4796     (ViewPort.SetMap, ViewPort.Destroy): Use the new helper methods to
4797     handle the map subscriptions
4798     (ViewPort.Map, ViewPort.map_projection_changed)
4799     (ViewPort.layer_projection_changed): Add or update doc-strings
4800    
4801     * test/test_connector.py (TestPublisher.test_issue_simple): Fix
4802     typo
4803     (MyConduit): Helper class for the Conduit test.
4804     (TestConduit): Test cases for Conduit
4805    
4806     * test/test_connector.py: Use support.run_tests as main.
4807    
4808     * test/test_viewport.py (ViewPortTest.setUp): Also subscribe to
4809     the TITLE_CHANGED messages
4810     (ViewPortTest.test_forwarding_title_changed): New test to check
4811     whether the viewport forwards the map's TITLE_CHANGED messages
4812     (TestViewportWithPostGIS.tearDown): Call the map's Destroy method
4813     after the port's because the latter may require a still functional
4814     map.
4815    
4816     2003-10-06 Bernhard Herzog <[email protected]>
4817    
4818 bh 1777 * Thuban/UI/application.py (ThubanApplication.maps_changed): Add
4819     doc-string
4820    
4821     2003-10-06 Bernhard Herzog <[email protected]>
4822    
4823 bh 1775 * test/test_viewport.py (ViewPortTest.setUp)
4824     (SimpleViewPortTest.test_init_with_size): Move the test for the
4825     initial size as a constructor parameter from ViewPortTest.setUp
4826     method to a new separate test in SimpleViewPortTest.
4827    
4828     2003-10-06 Bernhard Herzog <[email protected]>
4829    
4830 bh 1773 * test/test_viewport.py (MockView): New class derived from
4831     ViewPort with a mock implementation of GetTextExtent to be used in
4832     the test cases
4833     (ViewPortTest.setUp): Use MockView instead of ViewPort
4834    
4835     * Thuban/UI/viewport.py (ViewPort.GetTextExtent): Turn this method
4836     into what would be a "pure virtual function" in C++: always raise
4837     NotImplementedError. Mock implementations for test cases don't
4838     belong into the real code
4839    
4840 bh 1770 2003-10-02 Bernhard Herzog <[email protected]>
4841    
4842     * test/test_layer.py (TestLayer.test_empty_layer): Explicitly
4843     close the dbf file we create so that it's contents have been
4844     written properly.
4845    
4846     * libraries/shapelib/shptree.c, libraries/shapelib/shpopen.c,
4847     libraries/shapelib/shapefil.h, libraries/shapelib/dbfopen.c:
4848     Update to shapelib 1.2.10
4849    
4850 jan 1767 2003-10-01 Jan-Oliver Wagner <[email protected]>
4851    
4852     * Thuban/UI/tree.py, Thuban/UI/main.py: Remove the #! line as
4853     it annoys lintian which warns about these files not being
4854     executable. The #! isn't necessary here since if you absolutely
4855     must execute them you can always say "python <filename>".
4856    
4857 bh 1757 2003-09-26 Bernhard Herzog <[email protected]>
4858    
4859 bh 1760 * Thuban/Model/classgen.py (GenQuantiles0): Removed since it's
4860     only used in GREAT-ER but not used in Thuban itself. When GREAT-ER
4861     is ported to a newer the import will fail, so it should be noticed
4862     immediately that this function is gone.
4863     Fixes RT#1919
4864    
4865     2003-09-26 Bernhard Herzog <[email protected]>
4866    
4867 bh 1757 Add a DTD for the projection files and make thuban write valid
4868     projection files
4869    
4870     * Resources/XML/projfile.dtd: New. DTD for thuban's projection
4871     files
4872    
4873     * Thuban/Model/resource.py (ProjFileSaver.write): Use
4874     'projectionlist' as the name in the document type declaration so
4875     that it matches the element type of the root element.
4876    
4877     * test/test_proj.py (sample_projfile, sample_projfile2): Use
4878     'projectionlist' as the name in the document type declaration just
4879     as it is done now in the files thuban would write
4880     (sample_projfile, sample_projfile_data): Fix spelling of
4881     "Mercator"
4882     (TestProjFile.doTestWrite): Validate the written and the expected
4883     XML data
4884     (TestProjFile): Derive from ValidationTest so that we can run xml
4885     validation tests
4886    
4887 bh 1751 2003-09-24 Bernhard Herzog <[email protected]>
4888    
4889     * Thuban/UI/renderer.py (ExportRenderer.render_legend): Do not
4890     modify the list returned by map.Layers() in place since it is the
4891     actual list of layers used by the map.
4892    
4893 jan 1745 2003-09-23 Jan-Oliver Wagner <[email protected]>
4894    
4895     * Doc/manual/thuban-manual.xml: Added subsection to chapter
4896     Extensions to describe the extensions coming with the Thuban
4897     standard package (gns2shp and importAPR).
4898    
4899 bh 1743 2003-09-23 Bernhard Herzog <[email protected]>
4900    
4901     * libraries/thuban/wxproj.cpp (project_point): if there's an
4902     inverse but no forward projection, convert to degrees after
4903     applying the inverse projection. Fixes RT#2096
4904    
4905     * test/test_wxproj.py: New. Test cases for wxproj.so. One test
4906     implicitly tests for the fix to RT#2096
4907    
4908     * test/support.py (FloatComparisonMixin.assertFloatSeqEqual):
4909     Check that the sequences have the same lengths
4910    
4911     * Resources/Projections/defaults.proj (Geographic projection): Use
4912     a much more precise value for the to_meter attribute.
4913    
4914 bh 1737 2003-09-22 Bernhard Herzog <[email protected]>
4915    
4916     * test/support.py (initthuban): Make sure to unset the LANG env.
4917     var. so that tests that compare translated strings work. Solves RT
4918     #2094
4919    
4920 jan 1730 2003-09-22 Jan-Oliver Wagner <[email protected]>
4921    
4922 jan 1735 Small improvement of APR import.
4923    
4924     * Extensions/importAPR/test/test_apr.py (aprTest.test_LClass):
4925     Added tests for text-ranges.
4926    
4927     * Extensions/importAPR/apr.py (APR_LClass.GetThubanRange): Now
4928     returns a string object if the range is based on text.
4929    
4930     * Extensions/importAPR/importAPR.py (import_apr_dialog): Unified
4931     range retrieval.
4932    
4933     2003-09-22 Jan-Oliver Wagner <[email protected]>
4934    
4935 jan 1730 Initial version of the importAPR extension which is in
4936     experimental state.
4937    
4938     * /Extensions/importAPR/, /Extensions/importAPR/samples/,
4939     /Extensions/importAPR/test/: New directories.
4940    
4941     * /Extensions/importAPR/samples/README: New: Howto load the samples.
4942    
4943     * /Extensions/importAPR/samples/iceland.apr: New: A sample APR
4944     file which refers to the Thuban Iceland demo data.
4945    
4946     * /Extensions/importAPR/test/README: New: Howto execute the tests.
4947    
4948     * /Extensions/importAPR/test/test_apr.py: New: Tests for APR classes.
4949    
4950     * /Extensions/importAPR/apr.py: New: Classes for ArcView Objects
4951     as in '.apr'-files.
4952    
4953     * /Extensions/importAPR/odb.py: New: Classes for generic ArcView
4954     ODB Objects as in '.apr', '.avl' and other files.
4955    
4956     * /Extensions/importAPR/__init__.py: New: Init to make this
4957     directory a package.
4958    
4959     * /Extensions/importAPR/importAPR.py: New: Import a ArcView
4960     project file (.apr) and convert it to Thuban.
4961    
4962     2003-09-22 Jan-Oliver Wagner <[email protected]>
4963    
4964     * Extensions/gns2shp.gns2shp.py: The main module of gns2shp.
4965    
4966 jan 1720 2003-09-19 Jan-Oliver Wagner <[email protected]>
4967    
4968     * Doc/manual/thuban-manual.xml: Extended section 'Installation'
4969     with description on RPM installation and RPM binary package
4970     creation.
4971    
4972 bh 1718 2003-09-18 Bernhard Herzog <[email protected]>
4973    
4974     * setup.py (data_files): Only add the mo files if the Locales
4975     directory actually exists, so that setup.py works with a fresh CVS
4976     checkout
4977    
4978 jan 1716 2003-09-12 Jan-Oliver Wagner <[email protected]>
4979    
4980     * Examples/simple_extensions/simple_tool.py: bugfix: Tool is now
4981     in viewport, not anymore in view
4982    
4983 jan 1714 2003-09-04 Jan-Oliver Wagner <[email protected]>
4984    
4985     Introducing first Extension (gns2shp).
4986    
4987     * Extensions, Extensions/gns2shp, Extensions/gns2shp/test: New.
4988    
4989     * Extensions/__init__.py: New. init to make this dir a package.
4990    
4991     * Extensions/gns2shp/__init__.py: New. init to make this dir a package.
4992    
4993     * Extensions/gns2shp/test/README: New. some info on this test directory.
4994    
4995     * Extensions/gns2shp/test/ls.txt: New. test data set (Liechtenstein).
4996    
4997     * Extensions/gns2shp/test/test_gns2shp.py: New. Test for correct creation
4998     of Shapefile from GNS text file format
4999    
5000 jan 1705 2003-09-03 Jan-Oliver Wagner <[email protected]>
5001    
5002 jan 1707 Fix/workaround for bug #2019:
5003     https://intevation.de/rt/webrt?serial_num=2019
5004    
5005     * Thuban/UI/identifyview.py (IdentifyView.ID_STOP): New.
5006     (IdentifyView.__init__): Added another button that allows to
5007     stop the identify mode.
5008     (IdentifyView.OnStop): New. Stops the identify mode.
5009    
5010     2003-09-03 Jan-Oliver Wagner <[email protected]>
5011    
5012 jan 1705 Introducing a new exception dialog that allows to exit the
5013     application immediately.
5014     This fixes bug #2060: https://intevation.de/rt/webrt?serial_num=2060
5015    
5016     * Thuban/UI/exceptiondialog.py: New. A special exception dialog.
5017    
5018     * Thuban/UI/application.py (ThubanApplication.ShowExceptionDialog):
5019     Made strings available to translations. Exchanged the simple
5020     ScrolledMessageDialog by the new ExceptionDialog.
5021    
5022 bh 1694 2003-09-01 Bernhard Herzog <[email protected]>
5023    
5024 bh 1701 * NEWS: New. Summary of changes and release notes.
5025    
5026     * MANIFEST.in: Add NEWS
5027    
5028     2003-09-01 Bernhard Herzog <[email protected]>
5029    
5030 bh 1699 * MANIFEST.in: Correct the include statement for the mo-files and
5031     include the documentation too.
5032    
5033     * setup.py (data_files): Add the .mo files
5034     (setup call): Up to version 0.9.0
5035    
5036     2003-09-01 Bernhard Herzog <[email protected]>
5037    
5038 bh 1696 * Thuban/UI/dbdialog.py (ChooseDBTableDialog.__init__): Change the
5039     parameter list to just parent and session
5040     (ChooseDBTableDialog.__set_properties): Removed. Setting the
5041     selection of empty list boxes is not allowed (and produces C++
5042     assertion errors) and the rest of the setup is better done in
5043     __init__ anyway.
5044     (ChooseDBTableDialog.OnCancel, ChooseDBTableDialog.OnOK)
5045     (ChooseDBTableDialog.OnLBDClick, DBDialog.OnOK): Use the Python
5046     builtins True/False for booleans to avoid warnings from wxPython
5047    
5048     * Thuban/UI/mainwindow.py (MainWindow.AddDBLayer): Adapt to new
5049     ChooseDBTableDialog constructor parameters.
5050    
5051     2003-09-01 Bernhard Herzog <[email protected]>
5052    
5053 bh 1694 * Thuban/Model/postgisdb.py
5054     (PostGISTable): Extend doc-string
5055     (PostGISTable._fetch_table_information): Set the column index
5056     correctly, pretending ignored columns don't exist.
5057    
5058     * test/test_postgis_db.py (TestPostGISIgnoredColumns): New tests
5059     for postgis tables with data types not yet supported by thuban.
5060    
5061 bh 1692 2003-08-29 Bernhard Herzog <[email protected]>
5062    
5063     * HOWTO-Release: Tweak item about running the tests.
5064    
5065 jan 1690 2003-08-29 Jan-Oliver Wagner <[email protected]>
5066    
5067     * /Doc/manual/thuban-manual.xml: updated to version 1.0pre2.
5068    
5069 bh 1688 2003-08-29 Bernhard Herzog <[email protected]>
5070    
5071     Add some missing parameters to projections. Proj complains about
5072     them on windows but for some reason not on Linux.
5073    
5074     * test/test_save.py (SaveSessionTest.testLayerProjection): Add
5075     missing required projection parameters
5076    
5077     * test/test_proj.py (TestProjFile.test): Add missing required
5078     projection parameters
5079    
5080     * test/test_load_0_8.py (TestLayerProjection.file_contents)
5081     (TestLayerProjection.test): Add missing required projection
5082     parameters and tests for them
5083    
5084     * test/test_load.py (TestLayerProjection.file_contents)
5085     (TestLayerProjection.test): Add missing required projection
5086     parameters and tests for them
5087    
5088     * test/test_layer.py (TestLayer.test_base_layer): Add missing
5089     required projection parameters
5090    
5091     2003-08-29 Bernhard Herzog <[email protected]>
5092    
5093     * libraries/pyprojection/Projection.i: Use pj_get_errno_ref to
5094     access the pj_errno because directly accessing pj_errno doesn't
5095     work on windows if the proj library is in a DLL
5096    
5097     * libraries/pyprojection/Projection_wrap.c: Update from Projection.i
5098    
5099 bh 1672 2003-08-28 Bernhard Herzog <[email protected]>
5100    
5101 bh 1685 * test/test_proj.py: Import things from Thuban after calling
5102     initthuban
5103    
5104     * test/test_load.py (LoadSessionTest.filenames): New class
5105     variable with the filename attributes to normalize
5106     (LoadSessionTest.check_format): Pass self.filenames to
5107     sax_eventlist to normalize the filename attributes
5108    
5109     * test/xmlsupport.py: Add cvs keywords
5110     (SaxEventLister.__init__): New parameter filenames which indicates
5111     attributes that contain filenames
5112     (SaxEventLister.startElementNS): Normalize the filename attributes
5113     with os.path.normpath
5114     (sax_eventlist): New parameter filenames to pass through to
5115     SaxEventLister
5116    
5117     * test/test_derivedshapestore.py: Make this file callable as a
5118     program to execute the tests
5119     (TestDerivedShapeStoreExceptions.test_table_with_wrong_size): Bind
5120     the session to self.session so that it gets destroyed properly
5121    
5122     * test/test_layer.py (TestLayer.tearDown): Call the session's
5123     Destroy method
5124    
5125     * test/test_map.py (TestMapBase.tearDown): Destroy self.session
5126     too if it exists
5127     (TestMapAddLayer.test_add_layer): Bind the session to self.session
5128     so that it gets destroyed properly
5129    
5130     * test/postgissupport.py (reason_for_not_running_tests): Add a
5131     test for the existence of popen2.Popen4.
5132    
5133     * test/test_save.py (SaveSessionTest.tearDown): New. Provide a
5134     reliable way to destroy the sessions created in the test cases
5135     (SaveSessionTest.test_dbf_table): Bind the session to self.session
5136     so that it gets destroyed properly
5137     (SaveSessionTest.testLayerProjection): Bind the session to
5138     self.session so that it gets destroyed properly
5139    
5140     * test/test_session.py (UnreferencedTablesTests.tearDown): Make
5141     sure that the session is destroyed properly
5142    
5143     * test/test_shapefilestore.py: Make this callable as a program to
5144     execute the tests
5145    
5146     * test/test_scalebar.py: Remove unnecessary import of _ from
5147     Thuban
5148    
5149     * test/support.py (print_garbage_information): Call initthuban
5150     here because it may be called indirectly from test cases that test
5151     test support modules which do not use anything from thuban itself
5152     (ThubanTestProgram.runTests): Remove unnecessary debug print
5153    
5154     2003-08-28 Bernhard Herzog <[email protected]>
5155    
5156 bh 1672 * Thuban/version.py (longversion): Update to 0.9
5157    
5158     * Thuban/UI/mainwindow.py: Remove some unused imports
5159    
5160     * README: Add section about required additional software. Add date
5161     and revision CVS keywords
5162    
5163     * HOWTO-Release: Add item about the translations. Add date and
5164     revision CVs keywords and change formatting to match README a bit
5165     better
5166    
5167     * po/de.po: Update for 0.9
5168    
5169     * test/README: Tweak the wording a little because many tests are
5170     not really unittest.
5171    
5172 bh 1663 2003-08-27 Bernhard Herzog <[email protected]>
5173    
5174 bh 1665 As preparation for the 0.9 release, switch thuban files to a
5175     non-dev namespace
5176    
5177     * Thuban/Model/save.py (SessionSaver.write_session): Write files
5178     with the http://thuban.intevation.org/dtds/thuban-0.9.dtd
5179     namespace
5180    
5181     * Thuban/Model/load.py (SessionLoader.__init__): Accept the
5182     http://thuban.intevation.org/dtds/thuban-0.9.dtd namespace too
5183    
5184     * test/test_save.py (SaveSessionTest.dtd)
5185     (SaveSessionTest.testEmptySession)
5186     (SaveSessionTest.testSingleLayer)
5187     (SaveSessionTest.testLayerProjection)
5188     (SaveSessionTest.testRasterLayer)
5189     (SaveSessionTest.testClassifiedLayer)
5190     (SaveSessionTest.test_dbf_table)
5191     (SaveSessionTest.test_joined_table)
5192     (SaveSessionTest.test_save_postgis): Update for new namespace
5193    
5194     * test/test_load.py (LoadSessionTest.dtd, TestSingleLayer)
5195     (TestLayerVisibility.file_contents, TestLabels.file_contents)
5196     (TestLayerProjection.file_contents)
5197     (TestRasterLayer.file_contents, TestJoinedTable.file_contents)
5198     (TestPostGISLayer.file_contents)
5199     (TestPostGISLayerPassword.file_contents)
5200     (TestLoadError.file_contents, TestLoadError.test): Update for new
5201     namespace
5202    
5203     2003-08-27 Bernhard Herzog <[email protected]>
5204    
5205 bh 1663 Make the table interface distinguish between row ids (an integer
5206     that uniquely identifies a row) and row ordinals (a simple row
5207     count from 0 to NumRows() - 1)
5208    
5209     * Thuban/Model/postgisdb.py (PostGISTable.RowIdToOrdinal)
5210     (PostGISTable.RowOrdinalToId): New methods to conver between row
5211     ids and row ordinals
5212     (PostGISTable.ReadRowAsDict, PostGISTable.ReadValue): New keyword
5213     parameter row_is_ordinal to indicate whether the row parameter is
5214     the row id or the ordinal
5215    
5216     * Thuban/Model/transientdb.py (TransientTableBase.RowIdToOrdinal)
5217     (TransientTableBase.RowOrdinalToId)
5218     (AutoTransientTable.RowIdToOrdinal)
5219     (AutoTransientTable.RowOrdinalToId): Same new methods as in
5220     PostGISTable.
5221     (TransientTableBase.ReadRowAsDict, TransientTableBase.ReadValue)
5222     (AutoTransientTable.ReadRowAsDict, AutoTransientTable.ReadValue):
5223     Same new parameter as in PostGISTable.
5224    
5225     * Thuban/Model/table.py (DBFTable.RowIdToOrdinal)
5226     (DBFTable.RowOrdinalToId, MemoryTable.RowIdToOrdinal)
5227     (MemoryTable.RowOrdinalToId): Same new methods as in PostGISTable.
5228     (DBFTable.ReadValue, DBFTable.ReadRowAsDict)
5229     (MemoryTable.ReadValue, MemoryTable.ReadRowAsDict): Same new
5230     parameter as in PostGISTable.
5231    
5232     * Thuban/UI/tableview.py (DataTable.RowIdToOrdinal)
5233     (DataTable.RowOrdinalToId): New methods to convert between row ids
5234     and row ordinals.
5235     (TableGrid.SelectRowById): New method to select a row based on its
5236     ID as opposed to its ordinal
5237     (DataTable.GetValue, TableGrid.OnRangeSelect)
5238     (TableGrid.OnSelectCell, LayerTableGrid.select_shapes)
5239     (QueryTableFrame.OnQuery, QueryTableFrame.get_selected)
5240     (LayerTableFrame.__init__): Convert between row ids and row
5241     ordinals as appropriate
5242    
5243     * test/postgissupport.py (PostGISDatabase.__init__): Add
5244     doc-string.
5245     (PostGISDatabase.initdb): The optional third item in a tuple in
5246     tables is now a (key, value) list with additional arguments to
5247     pass to upload_shapefile
5248     (upload_shapefile): New parameter gid_offset to allow gids that
5249     are not the same as the shapeids in the shapefile
5250     (PostgreSQLServer.get_default_static_data_db): Use the new
5251     gid_offset to make the gids in landmarks 1000 higher than the
5252     shapeids in the shapefile
5253    
5254     * test/test_viewport.py
5255     (TestViewportWithPostGIS.test_find_shape_at_point): Adapt to the
5256     new shapeids in the landmarks table
5257    
5258     * test/test_transientdb.py
5259     (TestTransientTable.run_iceland_political_tests)
5260     (TestTransientTable.test_transient_joined_table): Add tests for
5261     the new table methods and new keywords arguments.
5262    
5263     * test/test_postgis_db.py
5264     (TestPostGISTable.test_read_row_as_dict_row_count_mode)
5265     (TestPostGISTable.test_read_value_row_count_mode)
5266     (TestPostGISTable.test_row_id_to_ordinal)
5267     (TestPostGISTable.test_row_oridnal_to_id): New test for the new
5268     table methods and the new arguments
5269     (TestPostGISShapestorePoint.test_shapes_in_region)
5270     (TestPostGISShapestorePoint.test_shape_raw_data)
5271     (TestPostGISShapestorePoint.test_shape_points)
5272     (TestPostGISShapestorePoint.test_shape_shapeid)
5273     (TestPostGISShapestorePoint.test_all_shapes)
5274     (TestPostGISTable.test_simple_query)
5275     (TestPostGISTable.test_simple_query)
5276     (TestPostGISTable.test_simple_query)
5277     (TestPostGISTable.test_read_value)
5278     (TestPostGISTable.test_read_row_as_dict): Adapt to the new
5279     shapeids in the landmarks table
5280    
5281     * test/test_memory_table.py
5282     (TestMemoryTable.test_read_row_as_dict_row_count_mode)
5283     (TestMemoryTable.test_read_value_row_count_mode)
5284     (TestMemoryTable.test_row_id_to_ordinal)
5285     (TestMemoryTable.test_row_oridnal_to_id): New test for the new
5286     table methods and the new arguments
5287    
5288     * test/test_dbf_table.py
5289     (TestDBFTable.test_read_row_as_dict_row_count_mode)
5290     (TestDBFTable.test_read_value_row_count_mode)
5291     (TestDBFTable.test_row_id_to_ordinal)
5292     (TestDBFTable.test_row_oridnal_to_id): New test for the new table
5293     methods and the new arguments
5294    
5295 bh 1659 2003-08-26 Bernhard Herzog <[email protected]>
5296    
5297 bh 1661 * Thuban/Model/postgisdb.py (PostGISShapeStore.BoundingBox): Use a
5298     more postgis specific but much faster method to get the bounding
5299     box
5300    
5301     2003-08-26 Bernhard Herzog <[email protected]>
5302    
5303 bh 1659 * Thuban/Model/postgisdb.py (PostGISTable.Title)
5304     (PostGISShapeStore.AllShapes): Add these missing methods.
5305     (PostGISShapeStore.ShapesInRegion): No need to raise
5306     StopIteration. We can simply return
5307    
5308     * test/test_postgis_db.py (TestPostGISTable.test_title)
5309     (TestPostGISShapestorePoint.test_all_shapes): New tests for the
5310     new methods
5311    
5312 bh 1643 2003-08-25 Bernhard Herzog <[email protected]>
5313    
5314 bh 1657 * Thuban/Model/postgisdb.py (shapetype_map): Add MUTLIPOLYGON.
5315    
5316     * test/test_postgis_db.py (PolygonTests): New class containing
5317     those tests from TestPostGISShapestorePolygon that can also be
5318     used to test MUTLIPOLYGON tables
5319     (TestPostGISShapestorePolygon): Most tests are now in PolygonTests
5320     so derive from that
5321     (TestPostGISShapestoreMultiPolygon): New class with tests for
5322     MUTLIPOLYGON tables
5323    
5324     * test/postgissupport.py (PostGISDatabase.initdb): Allow the
5325     tables argument to have tuples with three items to override the
5326     WKT type used.
5327     (PostgreSQLServer.get_default_static_data_db): Use the above to
5328     create a polygon table with MUTLIPOLYGONs
5329     (point_to_wkt, coords_to_point, polygon_to_wkt, coords_to_polygon)
5330     (arc_to_wkt, coords_to_multilinestring): Rename from *_to_wkt to
5331     coords_to*
5332     (coords_to_multipolygon): New. Convert to MUTLIPOLYGON
5333     (wkt_converter): New. Map WKT types to converters
5334     (upload_shapefile): New parameter force_wkt_type to use a
5335     different WKT type than the default
5336    
5337     2003-08-25 Bernhard Herzog <[email protected]>
5338    
5339 bh 1655 * Thuban/UI/application.py
5340     (ThubanApplication.run_db_param_dialog): New. Suitable as a
5341     db_connection_callback. Main difference is that the dialog run
5342     from this method doesn't have a parent so it can be used even when
5343     there is no main window
5344     (ThubanApplication.OpenSession): Use self.run_db_param_dialog if
5345     no db_connection_callback was given. This way the dialog pops up
5346     even when the .thuban file was given as a command line parameter.
5347    
5348     2003-08-25 Bernhard Herzog <[email protected]>
5349    
5350 bh 1653 * Thuban/UI/view.py (MapCanvas.OnLeftUp): Release the the mouse
5351     before calling MouseLeftUp. MouseLeftUp may pop up modal dialogs
5352     which leads to an effectively frozen X session because the user
5353     can only interact with the dialog but the mouse is still grabbed
5354     by the canvas.
5355     Also, call the tool's Hide method before MouseLeftUp because
5356     MouseLeftUp may change the tool's coordinates.
5357    
5358     2003-08-25 Bernhard Herzog <[email protected]>
5359    
5360 bh 1651 * Thuban/UI/application.py (ThubanApplication.OpenSession): Catch
5361     LoadCancelled exceptions and handle them by returning immediately.
5362    
5363     2003-08-25 Bernhard Herzog <[email protected]>
5364    
5365 bh 1649 GUI part of loading sessions with postgis connections which may
5366     require user interaction to get passwords or updated parameters
5367    
5368     * Thuban/UI/dbdialog.py (DBDialog): Reimplement to make it look a
5369     bit nucer and be more generic.
5370     (DBFrame.OnAdd): Adapt to new DBDialog interface
5371    
5372     * Thuban/UI/application.py (ThubanApplication.OpenSession): New
5373     optional parameter db_connection_callback which is passed to
5374     load_session.
5375    
5376     * Thuban/UI/mainwindow.py (MainWindow.run_db_param_dialog): New.
5377     Suitable as a db_connection_callback
5378     (MainWindow.OpenSession): Use self.run_db_param_dialog as the
5379     db_connection_callback of the application's OpenSession method
5380    
5381    
5382     2003-08-25 Bernhard Herzog <[email protected]>
5383    
5384 bh 1647 Basic loading of sessions containing postgis connections:
5385    
5386     * Thuban/Model/load.py (LoadError): Add doc-string
5387     (LoadCancelled): New exception class to indicate a cancelled load
5388     (SessionLoader.__init__): Add the db_connection_callback parameter
5389     which will be used by the loader to get updated parameters and a
5390     password for a database connection
5391     (SessionLoader.__init__): Add the new XML elements to the
5392     dispatchers dictionary
5393     (SessionLoader.check_attrs): Two new conversions, ascii to convert
5394     to a byte-string object and idref as a generic id reference
5395     (SessionLoader.start_dbconnection)
5396     (SessionLoader.start_dbshapesource): New. Handlers for the new XML
5397     elements
5398     (load_session): Add the db_connection_callback to pass through the
5399     SessionLoader
5400    
5401     * test/test_load.py (TestPostGISLayer, TestPostGISLayerPassword):
5402     New classes to test loading of sessions with postgis database
5403     connections.
5404    
5405     2003-08-25 Bernhard Herzog <[email protected]>
5406    
5407 bh 1645 * Thuban/UI/mainwindow.py (__ThubanVersion__): Remove this and
5408     replace it and the comment with __BuildDate__ by the Source: and
5409     Id: cvs keywords as used in the other files.
5410    
5411     2003-08-25 Bernhard Herzog <[email protected]>
5412    
5413 bh 1643 * Thuban/Model/load.py (SessionLoader.check_attrs): Raise a
5414     LoadError when a required attribute is missing. The code used to
5415     be commented out for some reason, but probably should have been
5416     active.
5417    
5418     * test/test_load.py (TestLoadError.test): Test the message in the
5419     LoadError too to make sure it really is about the missing
5420     attribute
5421    
5422 bh 1632 2003-08-22 Bernhard Herzog <[email protected]>
5423 bh 1641
5424     * test/test_save.py (SaveSessionTest.test_dbf_table)
5425     (SaveSessionTest.test_joined_table): Add XML validation tests.
5426    
5427     2003-08-22 Bernhard Herzog <[email protected]>
5428    
5429 bh 1639 Implement saving a session with a postgis connection
5430 bh 1632
5431 bh 1639 * Resources/XML/thuban-0.9.dtd (dbconnection, dbshapesource) New
5432     elements for database connections and shapestores using db
5433     connections
5434     (session): Add the dbconnections to the content model
5435    
5436     * Thuban/Model/save.py (SessionSaver.write_db_connections): New.
5437     Write the db connections
5438     (SessionSaver.write_session): Call write_db_connections to write
5439     the connection before the data sources
5440     (SessionSaver.write_data_containers): Handle postgis shapestores
5441    
5442     * test/test_save.py (SaveSessionTest.thubanids)
5443     (SaveSessionTest.thubanidrefs): Update for new DTD
5444     (SaveSessionTest.test_save_postgis): New. Test saving a session
5445     with postgis connections
5446    
5447     * Thuban/Model/postgisdb.py (PostGISTable.DBConnection)
5448     (PostGISTable.TableName): New accessor methods for the connection
5449     and table name
5450    
5451     * test/test_postgis_db.py (TestPostGISTable.test_dbconn)
5452     (TestPostGISTable.test_dbname): New methods to test the new
5453     PostGISConnection methods
5454    
5455     2003-08-22 Bernhard Herzog <[email protected]>
5456    
5457 bh 1637 * Thuban/Model/postgisdb.py (ConnectionError): New exception class
5458     for exceptions occurring when establishing a Database connection
5459     (PostGISConnection.connect): Catch psycopg.OperationalError during
5460     connects and raise ConnectionError.
5461    
5462     * test/test_postgis_db.py (TestPostgisDBExceptions): New class for
5463     tests for database exceptions
5464    
5465     2003-08-22 Bernhard Herzog <[email protected]>
5466    
5467 bh 1635 Prepare the test suite for tests with required authentication
5468    
5469     * test/postgissupport.py (PostgreSQLServer.__init__): Add instance
5470     variables with two predefined users/passwords, one for the admin
5471     and one for a non-privileged user.
5472     (PostgreSQLServer.createdb): Pass the admin name to initdb and add
5473     the non-privileged user to the database and set the admin password
5474     (PostgreSQLServer.wait_for_postmaster): Use the admin user name.
5475     Better error reporting
5476     (PostgreSQLServer.connection_params)
5477     (PostgreSQLServer.connection_string): New methods to return
5478     information about how to connect to the server
5479     (PostgreSQLServer.execute_sql): New. Convenience method to execute
5480     SQL statements
5481     (PostgreSQLServer.require_authentication): Toggle whether the
5482     server requires authentication
5483     (PostgreSQLServer.create_user, PostgreSQLServer.alter_user): New.
5484     Add or alter users
5485     (PostGISDatabase.initdb): Pass the admin name one the
5486     subprocesses' command lines. Grant select rights on
5487     geometry_columns to everybody.
5488     (upload_shapefile): Use the admin name and password when
5489     connecting. Grant select rights on the new table to everybody.
5490    
5491     * test/test_viewport.py (TestViewportWithPostGIS.setUp): Use the
5492     server's new methods to get the connection parameters.
5493    
5494     * test/test_postgis_session.py (TestSessionWithPostGIS.setUp)
5495     (TestSessionWithPostGIS.test_remove_dbconn_exception): Use the
5496     server's new methods to get the connection parameters.
5497    
5498     * test/test_postgis_db.py
5499     (TestPostGISConnection.test_gis_tables_empty)
5500     (TestPostGISConnection.test_gis_tables_non_empty)
5501     (PostGISStaticTests.setUp): Use the server's new methods to get
5502     the connection parameters.
5503    
5504     2003-08-22 Bernhard Herzog <[email protected]>
5505    
5506 bh 1632 * Thuban/UI/about.py (About.__init__): Add the psycopg version.
5507    
5508     * Thuban/version.py: Add psycopg version
5509    
5510     * Thuban/Model/postgisdb.py (psycopg_version): New. Return the
5511     version of the psycopg module
5512    
5513     2003-08-22 Bernhard Herzog <[email protected]>
5514    
5515     * Thuban/UI/dbdialog.py (DBPwdDlg): Removed because it's not used.
5516     (DBFrame.OnEdit): Removed because it's not used and wouldn't work
5517     at the moment. The functionality should probably be implemented
5518     some time, though.
5519 bh 1633 (DBFrame.OnRemove): Display a message if the connection can't be
5520     removed because it's still in use.
5521 bh 1632
5522 jan 1629 2003-08-22 Jan-Oliver Wagner <[email protected]>
5523    
5524     * Thuban/UI/about.py (About.__init__): split up the huge about
5525     text into elements/lists for easier translation. This fixes bug
5526     https://intevation.de/rt/webrt?serial_num=2058
5527     Also, made some forgotten string available for the i18n.
5528    
5529 bh 1627 2003-08-21 Bernhard Herzog <[email protected]>
5530    
5531     Make postgis support really optional including insensitive menu
5532     items.
5533    
5534     * Thuban/Model/postgisdb.py (has_postgis_support): New. Return
5535     whether the postgis is supported.
5536    
5537     * Thuban/UI/dbdialog.py: Put the psycopg import into try..except
5538     to make postgis support optional
5539    
5540     * Thuban/UI/mainwindow.py (_has_postgis_support): New. Context
5541     version of Thuban.Model.postgisdb.has_postgis_support
5542     (database_management command): Make it only sensitive if postgis
5543     is supported.
5544    
5545 jan 1623 2003-08-21 Jan-Oliver Wagner <[email protected]>
5546    
5547 jan 1626 * Doc/manual/thuban-manual.xml: Added CVS revision for rev-history.
5548     (section Adding and Removing Layers): Added text and described
5549     multi-selection.
5550     (chapter Extensions): New.
5551    
5552     2003-08-21 Jan-Oliver Wagner <[email protected]>
5553    
5554 jan 1623 * Thuban/UI/mainwindow.py (MainWindow.AddLayer): Changed dialog
5555     settings to allow multiple files to load into the map.
5556     Also reduced selection to *.shp as a default.
5557    
5558 bh 1621 2003-08-20 Bernhard Herzog <[email protected]>
5559    
5560     Add dialogs and commands to open database connections and add
5561     database layers.
5562    
5563     * Thuban/UI/mainwindow.py (MainWindow.DatabaseManagement): New
5564     method to open the database connection management dialog
5565     (MainWindow.AddDBLayer): New method to add a layer from a database
5566     (_has_dbconnections): New helper function to use for sensitivity
5567     (database_management command, layer_add_db command): New commands
5568     that call the above new methods.
5569     (main_menu): Add the new commands to the menu.
5570    
5571     * Thuban/Model/postgisdb.py (PostGISConnection.__init__)
5572     (PostGISConnection.connect): Establish the actual connection in a
5573     separate method and call it in __init__. This makes it easier to
5574     override the behavior in test cases
5575     (PostGISConnection.BriefDescription): New method to return a brief
5576     description for use in dialogs.
5577    
5578     * test/test_postgis_db.py (NonConnection): DB connection that
5579     doesn't actually connect
5580     (TestBriefDescription): New class with tests for the new
5581     BriefDescription method
5582    
5583 jan 1619 2003-08-19 Jan-Oliver Wagner <[email protected]>
5584    
5585     Moved anything from extensions to libraries.
5586    
5587     * libraries: New.
5588    
5589     * libraries/ pyprojection, pyshapelib, shapelib, thuban: New.
5590    
5591     * libraries/pyprojection/ LICENSE, MANIFEST.in, Projection.i,
5592     Projection.py, Projection_wrap.c, setup.py, swighelp.txt: These files have
5593     been moved here from thuban/extensions/pyprojection/
5594     See there in the Attic for the older history.
5595    
5596     * libraries/pyshapelib/ COPYING, ChangeLog, NEWS, README, dbflib.i,
5597     dbflib.py, dbflib_wrap.c, pyshapelib_api.h, pytest.py, setup.py,
5598     shapelib.i, shapelib.py, shapelib_wrap.c, shptreemodule.c: These files
5599     have been moved here from thuban/extensions/pyshapelib/
5600     See there in the Attic for the older history.
5601    
5602     * libraries/shapelib/ dbfopen.c, shapefil.h, shpopen.c, shptree.c: These
5603     files have been moved here from thuban/extensions/shapelib/
5604     See there in the Attic for the older history.
5605    
5606     * libraries/thuban/ bmpdataset.cpp, cpl_mfile.cpp, cpl_mfile.h,
5607     gdalwarp.cpp, wxproj.cpp: These files have been moved here from
5608     thuban/extensions/thuban/
5609     See there in the Attic for the older history.
5610    
5611     * MANIFEST.in, setup.cfg, setup.py: renamed extensions to libraries.
5612    
5613     * extensions/thuban/ bmpdataset.cpp, cpl_mfile.cpp, cpl_mfile.h,
5614     gdalwarp.cpp, wxproj.cpp: Moved to libraries/thuban.
5615    
5616     * extensions/shapelib/ dbfopen.c, shapefil.h, shpopen.c, shptree.c:
5617     Moved to libraries/shapelib.
5618    
5619     * extensions/pyshapelib/ COPYING, NEWS, dbflib.py, pytest.py,
5620     shapelib.py, README, dbflib_wrap.c, setup.py, shapelib_wrap.c,
5621     ChangeLog, dbflib.i, pyshapelib_api.h, shapelib.i, shptreemodule.c:
5622     Moved to libraries/pyshapelib.
5623    
5624     * extensions/pyprojection/ MANIFEST.in, Projection.py, setup.py,
5625     LICENSE, Projection.i, Projection_wrap.c, swighelp.txt:
5626     Moved to libraries/pyprojection.
5627    
5628     * extensions/ pyprojection, pyshapelib, shapelib, thuban: Removed.
5629    
5630     * extensions: Removed.
5631    
5632 bh 1606 2003-08-19 Bernhard Herzog <[email protected]>
5633    
5634 bh 1609 * test/test_viewport.py (ViewPortTest): We don't use the
5635     facilities of FileTestMixin so don't derive from it.
5636     (TestViewportWithPostGIS): New class with tests for using a
5637     viewport on a map with postgis layers.
5638    
5639     2003-08-19 Bernhard Herzog <[email protected]>
5640    
5641     Add the db connection management to the session.
5642    
5643     * Thuban/Model/session.py (Session.__init__): New instance
5644     variable db_connections
5645     (Session.AddDBConnection, Session.DBConnections)
5646     (Session.HasDBConnections, Session.CanRemoveDBConnection)
5647     (Session.RemoveDBConnection): New methods to manage and query the
5648     db connections managed by the session
5649     (Session.OpenDBShapeStore): New method to open a shapestore from a
5650     db connection
5651    
5652     * Thuban/Model/messages.py (DBCONN_REMOVED, DBCONN_ADDED): New
5653     messages for the db connection handling in the session
5654    
5655     * test/test_postgis_session.py: New. test cases for the session's
5656     db connection handling with postgis connections
5657    
5658     2003-08-19 Bernhard Herzog <[email protected]>
5659    
5660 bh 1606 Add very basic postgis database support and the corresponding test
5661     cases. The test cases require a PostgreSQL + postgis installation
5662     but no existing database. The database will be created
5663     automatically by the test cases
5664    
5665     * test/README: Add note about skipped tests and the requirements
5666     of the postgis tests.
5667    
5668     * Thuban/Model/postgisdb.py: New. Basic postgis database support.
5669    
5670     * test/test_postgis_db.py: New. Test cases for the postgis
5671     support.
5672    
5673     * Thuban/Model/wellknowntext.py: New. Parser for well-known-text
5674     format
5675    
5676     * test/test_wellknowntext.py: New. Test cases for the
5677     wellknowntext parser
5678    
5679     * test/postgissupport.py: New. Support module for tests involving
5680     a postgis database.
5681    
5682     * test/support.py (execute_as_testsuite): Shut down the postmaster
5683     if it's still running after the tests
5684    
5685     * Thuban/Model/data.py (RAW_WKT): New constant for raw data in
5686     well known text format
5687    
5688 jan 1604 2003-08-19 Jan-Oliver Wagner <[email protected]>
5689    
5690     * Examples/simple_extensions/hello_world.py: New. Raises a Hello World
5691     message dialog.
5692    
5693 bh 1600 2003-08-18 Bernhard Herzog <[email protected]>
5694    
5695 bh 1602 * test/support.py (ThubanTestResult.printErrors): Indent the
5696     reason for the skips in the output to make it a bit more readable.
5697     (execute_as_testsuite): New helper function to run a test suite
5698     and print some more information.
5699     (run_tests): Use execute_as_testsuite to run the tests
5700    
5701     * test/runtests.py (main): Use execute_as_testsuite to run the
5702     tests
5703    
5704     2003-08-18 Bernhard Herzog <[email protected]>
5705    
5706 bh 1600 Fix some bugs in Thuban and the test suite that were uncovered by
5707     changes introduced in Python 2.3:
5708    
5709     * Thuban/Model/table.py (DBFTable.__init__): Make sure the
5710     filename is an absolute name
5711    
5712     * Thuban/Model/layer.py (RasterLayer.__init__): Make sure the
5713     filename is an absolute name
5714    
5715     * test/test_save.py (SaveSessionTest.testRasterLayer): Use a
5716     unique filename to save to and use the correct relative filename
5717     in the expected output.
5718     (SaveSessionTest.test_dbf_table): Use the correct relative
5719     filename in the expected output.
5720    
5721     * test/test_layer.py (TestLayer.test_raster_layer): Update the
5722     test to check whether the filename is absolute.
5723    
5724 jan 1596 2003-08-18 Jan-Oliver Wagner <[email protected]>
5725    
5726     * Thuban/UI/about.py (About.__init__): Added Silke Reimer.
5727    
5728 bh 1586 2003-08-15 Bernhard Herzog <[email protected]>
5729    
5730 bh 1594 Change the way shapes are returned by a shape store. The
5731     ShapesInRegion method returns an iterator over actual shape
5732     objects instead of a list of shape ids.
5733    
5734     * Thuban/Model/data.py (ShapefileShape.ShapeID): New. Return shape
5735     id.
5736     (ShapefileStore.ShapesInRegion): Return an iterator over the
5737     shapes which yields shape objects instead of returning a list of
5738     shape ids
5739     (ShapefileStore.AllShapes): New. Return an iterator over all
5740     shapes in the shape store
5741     (DerivedShapeStore.AllShapes): New. Like in ShapefileStore
5742    
5743     * Thuban/Model/layer.py (Layer.ShapesInRegion): Update
5744     doc-string.
5745    
5746     * Thuban/UI/baserenderer.py
5747     (BaseRenderer.layer_ids, BaseRenderer.layer_shapes): Rename to
5748     layer_shapes and make it return an iterator containg shapes
5749     instead of a list of ids.
5750     (BaseRenderer.draw_shape_layer): Update doc-string; Adapt to
5751     layer_shapes() change
5752    
5753     * Thuban/UI/renderer.py (ScreenRenderer.layer_ids)
5754     (ScreenRenderer.layer_shapes): Rename as in BaseRenderer
5755    
5756     * Thuban/UI/viewport.py (ViewPort._find_shape_in_layer): Adapt to
5757     changes in the ShapesInRegion return value.
5758     (ViewPort._get_hit_tester): Remove commented out code
5759    
5760     * test/mockgeo.py (SimpleShapeStore.ShapesInRegion): Adapt to the
5761     new return value.
5762     (SimpleShapeStore.AllShapes): New. Implement this method too.
5763    
5764     * test/test_layer.py (TestLayer.test_arc_layer)
5765     (TestLayer.test_polygon_layer, TestLayer.test_point_layer)
5766     (TestLayer.test_point_layer_with_projection)
5767     (TestLayer.test_derived_store): Adapt to changes in the
5768     ShapesInRegion return value.
5769    
5770     * test/test_shapefilestore.py
5771     (TestShapefileStoreArc.test_shapes_in_region)
5772     (TestShapefileStorePolygon.test_shapes_in_region)
5773     (TestShapefileStorePoint.test_shapes_in_region): Adapt to changes
5774     in the ShapesInRegion return value.
5775     (TestShapefileStorePoint.test_all_shapes)
5776     (TestShapefileStoreArc.test_shape_shapeid): New tests for the new
5777     methods
5778    
5779     * test/test_derivedshapestore.py
5780     (TestDerivedShapeStore.test_shapes_in_region): Adapt to changes in
5781     the ShapesInRegion return value.
5782     (TestDerivedShapeStore.test_all_shapes)
5783     (TestDerivedShapeStore.test_shape_shapeid): New tests for the new
5784     methods
5785    
5786     2003-08-15 Bernhard Herzog <[email protected]>
5787    
5788 bh 1592 Make the renderers deal correctly with raw vs. python level
5789     representation of shape geometries
5790    
5791     * Thuban/UI/baserenderer.py (BaseRenderer.low_level_renderer):
5792     Return a flag useraw in addition to the callable and the parameter
5793     to indicate whether the callable can deal with the raw shape data
5794     or uses the higher level python lists of coordinates. The callable
5795     now should accept either the raw data or the return value of the
5796     shape's Points() method.
5797     (BaseRenderer.draw_shape_layer): Adapt to the low_level_renderer
5798     change
5799     (BaseRenderer.projected_points): Instead of the shape id use the
5800     points list as parameter.
5801     (BaseRenderer.draw_polygon_shape, BaseRenderer.draw_arc_shape)
5802     (BaseRenderer.draw_point_shape): Adapt to projected_points()
5803     change and accept the points list as parameter instead of the
5804     shape id.
5805    
5806     * Thuban/UI/renderer.py (MapRenderer.low_level_renderer): Return
5807     the useraw flag as required by the BaseRenderer
5808     (ScreenRenderer.draw_shape_layer): Adapt to low-level renderer
5809     changes.
5810    
5811     * test/test_baserenderer.py
5812     (TestBaseRenderer.test_point_with_classification): New test for
5813     rendering a map with classifications.
5814    
5815     2003-08-15 Bernhard Herzog <[email protected]>
5816    
5817 bh 1590 * Thuban/UI/viewport.py (ViewPort.find_shape_at)
5818     (ViewPort._find_shape_in_layer, ViewPort._find_shape_in_layer)
5819     (ViewPort._get_hit_tester, ViewPort.projected_points)
5820     (ViewPort._hit_point, ViewPort._hit_arc, ViewPort._hit_polygon)
5821     (ViewPort._find_label_at): Split the find_shape_at method into
5822     several new methods and use the functions in the hit-test module.
5823    
5824     * Thuban/UI/hittest.py: New module with Python-level hit-testing
5825     functions
5826    
5827     * test/test_hittest.py: New. Test for the new hittest module
5828    
5829     2003-08-15 Bernhard Herzog <[email protected]>
5830    
5831 bh 1588 * Thuban/Model/layer.py (Layer.ShapesInRegion): Apply the layer
5832     projection to all corners of the bounding box to get a better
5833     approximation of the projected bounding box
5834    
5835     * test/test_layer.py (TestLayer.test_point_layer_with_projection):
5836     New. Test coordinate handling of a layer with a projection.
5837     Catches the bug fixed in Layer.ShapesInRegion
5838    
5839     2003-08-15 Bernhard Herzog <[email protected]>
5840    
5841 bh 1586 Move some of the mock objects in test_baserenderer into their own
5842     module so they can easily be used from other tests
5843    
5844     * test/mockgeo.py: New test helper module with some mock objects
5845     for geometry related things like shapes, shapestores and
5846     projections.
5847    
5848     * test/test_mockgeo.py: New. Tests for the new helper module
5849    
5850     * test/test_baserenderer.py: Some of the mock-objects are in
5851     mockgeo now.
5852    
5853 jan 1584 2003-08-12 Jan-Oliver Wagner <[email protected]>
5854    
5855     * Thuban/UI/about.py (About.__init__): Added Björn Broscheit.
5856    
5857 bh 1580 2003-08-12 Bernhard Herzog <[email protected]>
5858    
5859 bh 1582 * po/de.po: New. German translations by Bjoern Broscheit
5860    
5861     2003-08-12 Bernhard Herzog <[email protected]>
5862    
5863 bh 1580 * Thuban/UI/projdialog.py (UnknownProjPanel._DoLayout): Translated
5864     strings have to be one string literal.
5865    
5866 bh 1573 2003-08-11 Bernhard Herzog <[email protected]>
5867    
5868 bh 1578 * test/support.py (FloatComparisonMixin.assertPointListEquals):
5869     New. This method was used in various derived classes, but it's
5870     better to have it here.
5871    
5872     * test/test_shapefilestore.py
5873     (ShapefileStoreTests.assertPointListEquals): Removed. It's now in
5874     FloatComparisonMixin
5875    
5876     * test/test_layer.py (TestLayer.assertPointListEquals): Removed.
5877     It's now in FloatComparisonMixin
5878    
5879     * test/test_derivedshapestore.py
5880     (TestDerivedShapeStore.assertPointListEquals): Removed. It's now
5881     in FloatComparisonMixin
5882    
5883     2003-08-11 Bernhard Herzog <[email protected]>
5884    
5885 bh 1573 * Thuban/UI/join.py (JoinDialog.OnJoin): Add missing space to
5886     error message
5887    
5888 jan 1569 2003-08-08 Jan-Oliver Wagner <[email protected]>
5889    
5890 jan 1571 * Doc/manual/thuban-manual.xml: Now use authorgroup. Added revhistory
5891     with version number.
5892     Changed title to reflect version number of Thuban.
5893    
5894     2003-08-08 Jan-Oliver Wagner <[email protected]>
5895    
5896 jan 1569 * Thuban/UI/about.py (About.__init__): Reworked the hall of fame. Now
5897     the list corresponds to the "About" web page.
5898    
5899 bh 1567 2003-08-08 Bernhard Herzog <[email protected]>
5900    
5901     * Thuban/UI/projdialog.py (UTMProposeZoneDialog.dialogLayout):
5902     Make sure translated strings are recognized as one string literal.
5903    
5904     * Thuban/UI/proj4dialog.py (UTMProposeZoneDialog.dialogLayout):
5905     Make sure translated strings are recognized as one string literal.
5906    
5907     * Thuban/UI/classgen.py (ClassGenDialog.OnOK): Make sure
5908     translated strings are recognized as one string literal.
5909    
5910     * Thuban/UI/application.py (ThubanApplication.OpenSession): Make
5911     sure translated strings are recognized as one string literal.
5912    
5913 bh 1556 2003-08-07 Bernhard Herzog <[email protected]>
5914    
5915 bh 1565 * Thuban/Model/data.py (DerivedShapeStore.RawShapeFormat): New.
5916     Simply delegates to the original shapestore.
5917    
5918     * test/test_derivedshapestore.py
5919     (TestDerivedShapeStore.test_raw_format): New. Test case for
5920     DerivedShapeStore.RawShapeFormat
5921    
5922     2003-08-07 Bernhard Herzog <[email protected]>
5923    
5924 bh 1561 Add raw data interface to shape objects.
5925    
5926     * Thuban/Model/data.py (ShapefileShape, Shape): Rname the shape
5927     class to ShapefileShape which now holds shapefile specific
5928     information.
5929     (ShapefileShape.compute_bbox): Simplified to not cache any
5930     information. The way this method is used that shouldn't matter
5931     performance wise.
5932     (ShapefileShape.RawData): New. Return the shapeid which is the raw
5933     data format for shapes from shapefiles.
5934     (ShapefileStore.RawShapeFormat): New. Return the raw datatype used
5935     in the shape objects returned by a shapestore. For a
5936     ShapefileStore this is always RAW_SHAPEFILE.
5937     (RAW_PYTHON, RAW_SHAPEFILE): Constants for the RawShapeFormat
5938     method.
5939    
5940     * test/test_shapefilestore.py
5941     (TestShapefileStore.test_raw_format): New test to test the raw
5942     format feature of shapes.
5943    
5944 bh 1560 * Thuban/Model/layer.py: Remove the unused import of Shape from
5945     data. It was only there for interface compatibility but it's not
5946 bh 1561 used inside of Thuban and the generic Shape class has gone away.
5947 bh 1560
5948 bh 1563 * Thuban/UI/renderer.py (MapRenderer.low_level_renderer): Check
5949     the raw data format and only use an optimized version of its a
5950     shapefile.
5951    
5952 bh 1561 2003-08-07 Bernhard Herzog <[email protected]>
5953    
5954 bh 1559 * test/test_baserenderer.py (SimpleShape): Shape class for the
5955     tests.
5956     (SimpleShapeStore.Shape): Use SimpleShape instead of
5957     Thuban.Model.data.Shape to make the tests independed of the coming
5958     changes.
5959    
5960     2003-08-07 Bernhard Herzog <[email protected]>
5961    
5962 bh 1556 * test/support.py (SkipTest, ThubanTestResult, ThubanTestRunner)
5963     (ThubanTestProgram): New classes that extend the respective
5964     classes from unittest. These new version support skipping tests
5965     under certain expected conditions. In the Thuban test suite we
5966     uses this for tests that require the optional gdal support.
5967     (run_tests): Use ThubanTestProgram instead of the unittest.main()
5968    
5969     * test/runtests.py (main): Use the new ThubanTestRunner instead of
5970     the normal one from unittest
5971    
5972     * test/test_layer.py (TestLayer.test_raster_layer): If this test
5973     is not run because gdal support isn't available report this to the
5974     runner.
5975    
5976     * test/test_baserenderer.py
5977     (TestBaseRenderer.test_raster_no_projection): Do not run this test
5978     if gdal support isn't available and report this to the runner.
5979    
5980 bh 1553 2003-08-06 Bernhard Herzog <[email protected]>
5981    
5982     Rearrange the renderers a bit, partly in preparation for changes
5983     required for the postgis merge, partly to make it more testable.
5984     Also make the representation of coordinates in Shapes more
5985     consistent.
5986    
5987     * Thuban/UI/renderer.py (MapRenderer): Most of the code/methods in
5988     this class is now in BaseRenderer. This class is now practically
5989     only a specialization of BaseRenderer for rendering to an actual
5990     wx DC.
5991     (ScreenRenderer.draw_shape_layer): Use self.low_level_renderer()
5992     to get the shapetype specific rendering functions.
5993    
5994     * Thuban/UI/baserenderer.py: New file with the basic rendering
5995     logic. The code in this file is completely independend of wx.
5996     (BaseRenderer): Class with the basic rendering logic
5997    
5998     * test/test_baserenderer.py: New. Test cases for BaseRenderer
5999    
6000     * Thuban/UI/view.py (MapCanvas.__init__): New instance variable
6001     error_on_redraw to guard agains endless loops and stack overflows
6002     when there's a bug in the rendering code that raises exceptions.
6003     (MapCanvas.OnIdle, MapCanvas._do_redraw): Split the actual
6004     rendering into a separate method _do_redraw so that error handling
6005     is a bit easier. When an exception occurs, set error_on_redraw to
6006     true. When it's true on entry to OnIdle do nothing and return
6007     immediately.
6008    
6009     * Thuban/Model/data.py (ShapefileStore.Shape): For consistency, a
6010     Shape object will always have the coordinates as a list of list of
6011     coordinate pairs (tuples).
6012     (Shape.compute_bbox): Adapt to new representation.
6013    
6014     * Thuban/UI/viewport.py (ViewPort.find_shape_at)
6015     (ViewPort.LabelShapeAt): Adapt to new coordinate representation in
6016     Shape objects.
6017    
6018     * test/test_shapefilestore.py
6019     (ShapefileStoreTests.assertFloatTuplesEqual)
6020     (ShapefileStoreTests.assertPointListEquals): Rename to
6021     assertPointListEquals and change purpose to checking equality of
6022     the lists returned by Shape.Points().
6023     (TestShapefileStoreArc.test_shape)
6024     (TestShapefileStorePolygon.test_shape)
6025     (TestShapefileStorePoint.test_shape): Use the new
6026     assertPointListEquals instead of assertFloatTuplesEqual
6027    
6028     * test/test_layer.py (TestLayer.assertFloatTuplesEqual)
6029     (TestLayer.assertPointListEquals): Rename to assertPointListEquals
6030     and change purpose to checking equality of the lists returned by
6031     Shape.Points().
6032     (TestLayer.test_arc_layer, TestLayer.test_arc_layer)
6033     (TestLayer.test_polygon_layer, TestLayer.test_point_layer)
6034     (TestLayer.test_derived_store): Use the new assertPointListEquals
6035     instead of assertFloatTuplesEqual
6036    
6037     * test/test_derivedshapestore.py
6038     (TestDerivedShapeStore.assertFloatTuplesEqual)
6039     (TestDerivedShapeStore.assertPointListEquals): Rename to
6040     assertPointListEquals and change purpose to checking equality of
6041     the lists returned by Shape.Points().
6042     (TestDerivedShapeStore.test_shape): Use the new
6043     assertPointListEquals instead of assertFloatTuplesEqual
6044    
6045 jan 1550 2003-08-06 Jan-Oliver Wagner <[email protected]>
6046    
6047     * Thuban/UI/projdialog.py (UTMPanel._OnPropose): Added test for
6048     a bounding box. A dialog is raised in case, no bounding box
6049     is found. This fixes bug #2043:
6050     https://intevation.de/rt/webrt?serial_num=2043
6051    
6052 bh 1548 2003-08-05 Bernhard Herzog <[email protected]>
6053    
6054     * Thuban/Model/color.py (Color.__repr__): Make the repr of a color
6055     object look like a Color instantiation. Formerly it looked like a
6056     tuple.
6057    
6058     * test/test_color.py (TestColor.test_repr)
6059     (TestColor.test_equality, TestColor.test_inequality): New. test
6060     some more apects of the Color class
6061     (TestTransparent.test_repr, TestTransparent.test_hex)
6062     (TestTransparent.test_equality): New. Test cases for the
6063     Transparent object.
6064    
6065 jan 1545 2003-08-04 Jan-Oliver Wagner <[email protected]>
6066    
6067     * Doc/manual/thuban-manual.xml: a number of small improvements.
6068     The resulting file is the version submitted for GREAT-ER II.
6069    
6070 bh 1540 2003-08-01 Bernhard Herzog <[email protected]>
6071    
6072 bh 1543 * Thuban/UI/resource.py, Thuban/UI/projdialog.py,
6073     Thuban/UI/join.py, Thuban/UI/classgen.py, Thuban/UI/about.py,
6074     Thuban/Model/resource.py: Insert cvs keywords and doc-strings.
6075    
6076     * Thuban/UI/common.py: Insert cvs keywords and doc-strings.
6077     (Color2wxColour, wxColour2Color, ThubanBeginBusyCursor)
6078     (ThubanEndBusyCursor): Add doc-strings
6079    
6080     2003-08-01 Bernhard Herzog <[email protected]>
6081    
6082 bh 1540 First step towards PostGIS integration. More abstraction by movin
6083     more code from the layer to the shapestore. More methods of the
6084     layer are now simply delegated to the equivalent method of the
6085     shapestore. The SHAPETYPE_* constants are now in data not in
6086     layer.
6087    
6088     * Thuban/Model/data.py (SHAPETYPE_POLYGON, SHAPETYPE_ARC)
6089     (SHAPETYPE_POINT, Shape): Move these constants and classes from
6090     layer.py to data.py
6091     (ShapefileStore.__init__): More Initialization for the new methods
6092     and functionality.
6093     (ShapefileStore.ShapeType, ShapefileStore.NumShapes)
6094     (ShapefileStore.BoundingBox, ShapefileStore.ShapesInRegion)
6095     (ShapefileStore.Shape): New methods that were formerly implemented
6096     in the layer.
6097     (DerivedShapeStore.Shape, DerivedShapeStore.ShapesInRegion)
6098     (DerivedShapeStore.ShapeType, DerivedShapeStore.NumShapes)
6099     (DerivedShapeStore.BoundingBox): New. DerivedShapeStore
6100     equivalents of the new shape methods. These versions are simply
6101     delegated to the original shapstore.
6102    
6103     * Thuban/Model/layer.py (SHAPETYPE_POLYGON, SHAPETYPE_ARC)
6104     (SHAPETYPE_POINT, Shape): Removed. They're now in data.py
6105     (Layer.SetShapeStore): Removed the initializatin of instance
6106     variables that were needed for the stuff that's now in
6107     ShapefileStore
6108     (Layer.BoundingBox, Layer.NumShapes, Layer.ShapeType)
6109     (Layer.Shape, Layer.ShapesInRegion): Simply delegate to the
6110     shapestore.
6111    
6112     * Thuban/UI/classifier.py, Thuban/UI/renderer.py,
6113     Thuban/UI/viewport.py: Import the SHAPETYPE_* constants from data
6114     instead of layer.
6115    
6116     * test/test_shapefilestore.py: New. Tests for ShapefileStore.
6117    
6118     * test/test_derivedshapestore.py: New. Tests for DerivedShapeStore.
6119    
6120     * test/test_layer.py: Import the SHAPETYPE_* constants from data
6121     instead of layer.
6122     (TestLayer.test_derived_store): Remove the test for the exception
6123     when instantiating the DerivedShapeStore with an incompatible
6124     table which is now in test_derivedshapestore.py. Add some more
6125     tests of the layer methods to determine whether they work for a
6126     DerivedShapeStore as well.
6127    
6128 jonathan 1534 2003-07-31 Jonathan Coles <[email protected]>
6129    
6130     * Doc/manual/thuban-manual.xml: Fix the list of required packages
6131     by just listing the name and where they can be found.
6132    
6133 frank 1532 2003-07-31 Frank Koormann <[email protected]>
6134    
6135     * Doc/manual/thuban-manual.xml:
6136     Changed the screenshot elements to figure.
6137     Changed some variablelist elements to itemizedlist.
6138     Added section on GDAL formats.
6139    
6140 jonathan 1531 2003-07-31 Jonathan Coles <[email protected]>
6141    
6142     * Doc/manual/thuban-manual.xml: Added a few sentences about
6143     the Fix Border Color option when generating classes.
6144    
6145 jonathan 1529 2003-07-30 Jonathan Coles <[email protected]>
6146    
6147     * Thuban/Model/classgen.py: Add docstrings. Rename specific
6148     Ramp instances to use lower_case_style.
6149    
6150     * Thuban/UI/classgen.py: Use renamed Ramp instances.
6151    
6152     * Thuban/UI/classifier.py: Add docstrings.
6153    
6154     * Thuban/UI/dock.py: Add docstrings.
6155    
6156     * test/test_classgen.py: Use renamed Ramp instances.
6157    
6158 bh 1522 2003-07-30 Bernhard Herzog <[email protected]>
6159    
6160 bh 1524 * Thuban/Lib/connector.py (QueueingPublisher): Removed. This class
6161     was never used in Thuban.
6162    
6163     2003-07-30 Bernhard Herzog <[email protected]>
6164    
6165 bh 1522 * Thuban/UI/join.py (JoinDialog.__init__): Use the table's Title()
6166     method directly instead of going through the transient_table
6167     method. This faster because transient_table may force the copy of
6168     a DBF file into the transient database and setting a table's title
6169     doesnm't affect the title of the associated transient table, so
6170     this fixes RT #2042
6171    
6172     * Thuban/UI/main.py (__version__): Don't import the already
6173     removed show_exception_dialog.
6174    
6175 jonathan 1517 2003-07-29 Jonathan Coles <[email protected]>
6176    
6177 jonathan 1519 * Thuban/UI/application.py (ThubanApplication.ShowExceptionDialog):
6178     Put back this method and remove the equivalent function since we
6179     are setting the exception hook from within this class (OnInit).
6180    
6181     2003-07-29 Jonathan Coles <[email protected]>
6182    
6183 jonathan 1517 * Doc/manual/images/5_2_custom_ramp.png,
6184     Doc/manual/images/5_2_quantiles.png,
6185     Doc/manual/images/5_2_uniform_dist.png,
6186     Doc/manual/images/5_2_unique_values.png,
6187     Doc/manual/images/8_int_error.png: New screen shots.
6188    
6189     * Doc/manual/thuban-manual.xml: Fixed typos and wording, clarified
6190     some points, and added more screen shots.
6191    
6192 bh 1512 2003-07-29 Bernhard Herzog <[email protected]>
6193    
6194 bh 1516 * Thuban/Model/data.py: Remove the now unused import of warnings
6195    
6196     2003-07-29 Bernhard Herzog <[email protected]>
6197    
6198 bh 1514 * Thuban/Model/data.py (SimpleStore): Removed. This class has been
6199     deprecated since before the 0.8 release and isn't used in Thuban
6200     itself anymore.
6201    
6202 bh 1512 * Thuban/Model/transientdb.py: Remove some unnecessary imports
6203    
6204 jonathan 1503 2003-07-29 Jonathan Coles <[email protected]>
6205 jonathan 1506
6206     * Thuban/UI/application.py (ThubanApplication.OnInit): set the
6207     python exception hook here so that we are sure to catch any
6208     Thuban exception that happen during initialization.
6209    
6210     * Thuban/UI/main.py (main): Don't set the exception hook here,
6211     it will get set in ThubanApplication.OnInit.
6212    
6213     2003-07-29 Jonathan Coles <[email protected]>
6214 jonathan 1503
6215     * Thuban/UI/application.py (ThubanApplication.ShowExceptionDialog):
6216     Removed and called it show_exception_dialog() so that the exception
6217     handler can be set before the class is created.
6218    
6219     * Thuban/UI/main.py (main): Install the exception handler before
6220     a ThubanApplication is created.
6221    
6222 bh 1500 2003-07-29 Bernhard Herzog <[email protected]>
6223    
6224     * po/it.po: New. Italian translation by Maurizio Napolitano
6225    
6226     * po/ru.po: New. Russian translation by Alex Shevlakov
6227    
6228 frank 1497 2003-07-29 Frank Koormann <[email protected]>
6229    
6230 frank 1508 * Doc/manual/thuban-manual.xml: Extended section on supported
6231     projections.
6232    
6233     2003-07-29 Frank Koormann <[email protected]>
6234    
6235 frank 1497 * Doc/manual/thuban-manual.xml: gaspell-checked.
6236    
6237 jonathan 1493 2003-07-29 Jonathan Coles <[email protected]>
6238    
6239 jonathan 1495 * Doc/manual/images/3_5_legend.png: Added border to improve look
6240     on white background.
6241    
6242     2003-07-29 Jonathan Coles <[email protected]>
6243    
6244 jonathan 1493 * Doc/manual/thuban-manual.xml: Fixed grammar and typos. Added
6245     descriptions for the legend toolbar.
6246    
6247     * Doc/manual/images/4_2_raster_layer_properties.png: Removed
6248     cursor from dialog box.
6249    
6250     2003-07-28 Jonathan Coles <[email protected]>
6251    
6252     * Doc/manual/thuban-manual.xml: More screenshots and more chapters.
6253    
6254     * Doc/manual/images/2_4_session_tree.png,
6255     Doc/manual/images/3_5_legend.png, Doc/manual/images/3_rename_map.png,
6256     Doc/manual/images/4_2_layer_properties.png,
6257     Doc/manual/images/4_2_raster_layer_properties.png,
6258     Doc/manual/images/5_3_genclass.png,
6259     Doc/manual/images/5_classification.png,
6260     Doc/manual/images/6_projection.png,
6261     Doc/manual/images/7_1_table_view.png,
6262     Doc/manual/images/7_2_5_join.png: New screenshots.
6263    
6264     2003-07-24 Jonathan Coles <[email protected]>
6265    
6266     * Doc/manual/thuban-manual.xml: Chapter on Projection Management.
6267    
6268     2003-07-24 Jonathan Coles <[email protected]>
6269    
6270     * Doc/manual/thuban-manual.xml: Added EPS images and wrote
6271     chapter on Layer Management.
6272    
6273     * Doc/manual/Makefile: New. Makefile to generate all formats for the
6274     manual and images.
6275    
6276 bh 1483 2003-07-24 Bernhard Herzog <[email protected]>
6277    
6278     * Thuban/Model/range.py, Thuban/version.py: Remove the #! line as
6279     it annoys lintian which warns about these files not being
6280 jan 1767 executable. The #! isn't necessary here since if you absolutely
6281 bh 1483 must execute them you can always say "python <filename>".
6282    
6283     * Thuban/UI/renderer.py (ScreenRenderer.draw_shape_layer): Remove
6284     superfluous code to set brush and pen for point shapes
6285    
6286     * Thuban/UI/viewport.py: Remove commented out code that wouldn't
6287     belong in viewport anyway
6288    
6289 frank 1479 2003-07-24 Frank Koormann <[email protected]>
6290    
6291     * Doc/manual/thuban-manual.xml: Added section on table management.
6292    
6293 bh 1477 2003-07-24 Bernhard Herzog <[email protected]>
6294    
6295     * test/runtests.py (main): Recognize the long "verbose" option
6296     correctly.
6297    
6298 jonathan 1470 2003-07-22 Jonathan Coles <[email protected]>
6299    
6300     * Doc/manual/thuban-manual.xml: Continue to write first revision
6301     of the manual.
6302    
6303     * Thuban/UI/renderer.py (MapRenderer.render_map): Wrap method
6304     with Begin/EndDrawing() calls to ensure we aren't doing to
6305     many updates to the dc during rendering.
6306     (ScreenRenderer.draw_shape_layer): self.draw_point_shape takes
6307     a pen and brush argument so they need to be passed to the function.
6308    
6309     * Thuban/UI/viewport.py (ViewPort.calc_min_max_scales): New.
6310     Calculates the minimum and maximum scale values. Factored out
6311     of set_view_transform so that it could be used to zoom all the
6312     way into a single point.
6313     (ViewPort.set_view_transform): Call calc_min_max_scales().
6314     (ViewPort.FitSelectedToWindow): Zoom to the maximum scale
6315     if only a single point is selected.
6316    
6317     * Doc/manual/images/1_2_legend_close.png,
6318     Doc/manual/images/1_2_legend_dock.png,
6319     Doc/manual/images/1_2_mainwindow.png,
6320     Doc/manual/images/1_2_mainwindow.ps,
6321     Doc/manual/images/1_2_mainwindow.sk,
6322     Doc/manual/images/3_2_fullextent.png,
6323     Doc/manual/images/3_2_fulllayerextent.png,
6324     Doc/manual/images/3_2_fullshapeextent.png,
6325     Doc/manual/images/3_2_pan.png,
6326     Doc/manual/images/3_2_zoomin.png,
6327     Doc/manual/images/3_2_zoomout.png,
6328     Doc/manual/images/3_3_identify.png,
6329     Doc/manual/images/3_3_label.png,
6330     Doc/manual/images/3_5_invisible.png,
6331     Doc/manual/images/3_5_movedown.png,
6332     Doc/manual/images/3_5_moveup.png,
6333     Doc/manual/images/3_5_props.png,
6334     Doc/manual/images/3_5_tobottom.png,
6335     Doc/manual/images/3_5_totop.png,
6336     Doc/manual/images/3_5_visible.png: New. Images for the documentation.
6337    
6338 bh 1451 2003-07-18 Bernhard Herzog <[email protected]>
6339    
6340 bh 1465 * Thuban/UI/messages.py (MAP_REPLACED): New message.
6341    
6342     * Thuban/UI/viewport.py (ViewPort.SetMap): Issue MAP_REPLACED
6343     after the new map has been assigned
6344    
6345     * Thuban/UI/mainwindow.py (MainWindow.delegated_messages):
6346     Delegate MAP_REPLACED to the canvas too
6347     (MainWindow.prepare_new_session): Removed. Thanks to the new
6348     MAP_REPLACED message it's no longer needed
6349     (MainWindow.OpenSession, MainWindow.NewSession):
6350     prepare_new_session has been removed.
6351    
6352     * Thuban/UI/classifier.py (Classifier.__init__): Subscribe to
6353     MAP_REPLACED so that we can close the dialog if a new map is set.
6354     (Classifier.unsubscribe_messages): Unsubscribe from MAP_REPLACED
6355     (Classifier.map_replaced): Handle MAP_REPLACED by closing the
6356     dialog
6357    
6358     * test/test_viewport.py (SimpleViewPortTest)
6359     (SimpleViewPortTest.test_default_size): Add doc-strings
6360     (ViewPortTest.setUp): Bind map to self.map so we can use it in
6361     tests. Subscribe to MAP_REPLACED messages too.
6362     (ViewPortTest.tearDown): No need to explicitly unsubscribe
6363     (ViewPortTest.test_set_map): New test for the SetMap method.
6364    
6365     2003-07-18 Bernhard Herzog <[email protected]>
6366    
6367 bh 1463 * test/test_viewport.py (SimpleViewPortTest.test_default_size):
6368     Move this test from ViewPortTest.setUp to this new separate test
6369     case. setUp is not the place for the actual tests.
6370     (ViewPortTest.test_inital_settings, ViewPortTest.setUp): Move some
6371     more of the test from setUp to the new test test_inital_settings.
6372     (ViewPortTest.test_win_to_proj, ViewPortTest.test_proj_to_win)
6373     (ViewPortTest.test_proj_conv): Split test_proj_conv into
6374     test_win_to_proj and test_proj_to_win and make the tests easier to
6375     understand
6376     (ViewPortTest.testFitRectToWindow, ViewPortTest.testZoomFactor)
6377     (ViewPortTest.testZoomOutToRect, ViewPortTest.testTranslate)
6378     (ViewPortTest.test_unprojected_rect_around_point)
6379     (ViewPortTest.test_find_shape_at, ViewPortTest.testTools):
6380     Reformat to increase readability.
6381    
6382     2003-07-18 Bernhard Herzog <[email protected]>
6383    
6384 bh 1461 * Thuban/UI/view.py (MapCanvas.OnLeftDown): Capture the mouse.
6385    
6386     2003-07-18 Bernhard Herzog <[email protected]>
6387    
6388 bh 1459 * test/runtests.py: The test suite can now be run without an X
6389     connection. To make sure this remains true, remove the DISPLAY
6390     environment variable so that an error occurs if the wxGTK is
6391     imported accidentally
6392    
6393     2003-07-18 Bernhard Herzog <[email protected]>
6394    
6395 bh 1457 * Thuban/UI/viewport.py: Remove unused imports
6396    
6397     * Thuban/UI/view.py: Remove unused imports
6398    
6399     2003-07-18 Bernhard Herzog <[email protected]>
6400    
6401 bh 1455 * test/test_export.py Remove unused imports. The OutputTransform
6402     function is now in viewport.py and is called output_transform
6403     (TestScalebar.test_output_transform)
6404     (TestScalebar.test_OutputTransform): Renamed to
6405     test_output_transform and updated to use output_transform instead
6406     of OutputTransform
6407    
6408     * Thuban/UI/view.py (OutputTransform): Moved to viewport.py and
6409     renamed.
6410     (MapCanvas.Export, MapPrintout.draw_on_dc): OutputTransform was
6411     renamed to output_transform
6412    
6413     * Thuban/UI/viewport.py (OutputTransform, output_transform):
6414     Rename to output_transform
6415    
6416     2003-07-18 Bernhard Herzog <[email protected]>
6417    
6418 bh 1453 * Thuban/Model/layer.py (Layer.__init__): Rename
6419     classificationField to classificatin_column and init it here so
6420     that it can be used in SetClassificationColumn
6421     (Layer.GetClassificationColumn, Layer.GetClassificationField):
6422     Rename to GetClassificationColumn.
6423     (Layer.SetClassificationColumn, Layer.SetClassificationField):
6424     Rename to SetClassificationColumn and issue a LAYER_CHANGED
6425     message if the column changes.
6426     (Layer._classification_changed, Layer.ClassChanged): Rename to
6427     _classification_changed. Update the callers.
6428     (Layer.SetShapeStore): Further field->column renames.
6429    
6430     * Thuban/Model/load.py (SessionLoader.start_classification)
6431     (SessionLoader.start_clpoint): Updates because of
6432     field->column method name changes in the Layer class
6433    
6434     * Thuban/Model/save.py (SessionSaver.write_classification): Updates
6435     because of field->column method name changes in the Layer class
6436    
6437     * Thuban/UI/classifier.py (Classifier.__init__)
6438     (Classifier._OnTry, Classifier._OnRevert): Updates because of
6439     field->column method name changes in the Layer class
6440    
6441     * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Updates
6442     because of field->column method name changes in the Layer class
6443    
6444     * Thuban/UI/viewport.py (ViewPort.find_shape_at): Updates because
6445     of field->column method name changes in the Layer class
6446    
6447     * test/test_save.py (SaveSessionTest.testClassifiedLayer)
6448     (SaveSessionTest.testClassifiedLayer): Update because of
6449     field->column method name changes in the Layer class
6450    
6451     * test/test_layer.py (SetShapeStoreTests.setUp)
6452     (SetShapeStoreTests.test_sanity): Update because of field->column
6453     method name changes in the Layer class
6454     (TestLayerModification.setUp): Subscribe to LAYER_CHANGED as well
6455     (TestLayerModification.test_sanity)
6456     (TestLayerModification.test_initial_settings): remove unsued code
6457     and rename to test_sanity.
6458     (TestLayerModification.test_set_classification): New test for
6459     SetClassification and SetClassificationField.
6460    
6461     2003-07-18 Bernhard Herzog <[email protected]>
6462    
6463 bh 1451 * test/test_classgen.py (TestFixedRamp.test): Extend test to check
6464     the non-fixed values as well. The old test would have accepted a
6465     fixed ramp that only returnes the fixed properties
6466    
6467 jonathan 1449 2003-07-17 Jonathan Coles <[email protected]>
6468    
6469     * Doc/manual/mainwindow.png, Doc/manual/mainwindow.xcf: Screen
6470     shots for the manual. The XCF file is the source image and
6471     has additional layers to support changes.
6472    
6473     * Doc/manual/thuban-manual.xml: Wrote an initial Introduction.
6474    
6475     * Thuban/UI/classifier.py (Classifier.__BuildClassification):
6476     Return both the new class and the field name.
6477    
6478     * Thuban/UI/mainwindow.py (MainWindow.ToggleLegend): Don't
6479     fit the map to the window as this changes any zoom level that
6480     the user may have set.
6481    
6482 jonathan 1442 2003-07-16 Jonathan Coles <[email protected]>
6483    
6484     * Thuban/Model/classgen.py (generate_singletons,
6485     generate_uniform_distribution, generate_quantiles): Remove
6486     fixes parameter, but maintain the same functionality by having
6487     the calling function pass a FixedRamp object for the ramp.
6488     (FixedRamp): New. Adapts a ramp to have fixed property values.
6489    
6490     * Thuban/Model/classification.py: Use new CLASS_CHANGED message.
6491     (Classification): Inherit from Publisher.
6492     (Classification.__init__): Remove the layer parameter.
6493     Classifications no longer need to have a parent layer.
6494     (Classification.GetField, Classification.GetFieldType,
6495     Classification.SetFieldInfo): Removed. The field name is stored
6496     in the layer, and the type can be retreived by calling
6497     Layer.GetFieldType().
6498     (Classification._set_layer, Classification.GetLayer): Removed.
6499     Classifications no longer have a parent layer.
6500    
6501     * Thuban/Model/layer.py (Layer.Destroy): Unsubscribe from the
6502     classification.
6503     (Layer.SetShapeStore): Reset the classification first while
6504     we still have the old shape store to work with.
6505     (Layer.GetClassificationField, Layer.SetClassificationField):
6506     New. Method for getting/setting the field to classify on.
6507     (Layer.SetClassification): Simplified now that the layer
6508     simply has to hold a reference to the classification and not
6509     tell the classification who owns it.
6510     Fixes RTbug #2023.
6511    
6512     * Thuban/Model/load.py (SessionLoader.start_classification):
6513     Set the field name on the layer, not the classification.
6514    
6515     * Thuban/Model/messages.py: Add CLASS_CHANGED for when a
6516     classification is modified.
6517    
6518     * Thuban/Model/save.py (SessionSaver.write_classification):
6519     Get the field name and type from the layer.
6520    
6521     * Thuban/Model/table.py (table_to_dbf, table_to_csv): Renamed
6522     parameter records to rows and add docstring. Fixes RTbug #1997.
6523    
6524     * Thuban/UI/classgen.py (ClassGenDialog.OnOK): Use a fixed
6525     ramp when we need to fix certain values of a ramp rather than
6526     using the old fixes parameter. Fixes RTbug #2024.
6527    
6528     * Thuban/UI/classifier.py (ClassGrid.CreateTable): Add fieldType
6529     parameter.
6530     (ClassTable.Reset): Add fieldType parameter and use it, rather
6531     than asking the classification.
6532     (Classifier.__init__): Remember the original class's field
6533     and ask the layer for the field type, rather than the classification.
6534     (Classifier.__SetGridTable): Retrieve the field and field type
6535     for the table because they are not in the classification.
6536     (Classifier._OnTry, Classifier._OnRevert): Set the classification
6537     field on the layer in addition to the classification itself.
6538    
6539     * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Get the
6540     classification field from layer.
6541    
6542     * Thuban/UI/viewport.py (ViewPort.find_shape_at): Get the
6543     classification field from layer. Split up tests and remove
6544     *-imports. Fixes RTbug #1992.
6545    
6546     * test/test_classgen.py (TestFixedRamp): Test for the FixedRamp class.
6547    
6548     * test/test_classification.py
6549     (TestClassification.test_classification): Remove tests for methods
6550     that no longer exist.
6551    
6552     * test/test_layer.py (SetShapeStoreTests.setUp): Classification
6553     __init__ no longer has a field parameter, use SetClassificationField.
6554     (SetShapeStoreTests.test_sanity): Use layer object to get class
6555     field info.
6556    
6557     * test/test_save.py (SaveSessionTest.testClassifiedLayer): Use
6558     SetClassificationField on layer to set class field info.
6559    
6560     * test/test_viewport.py: Renamed from test/test_view.py.
6561    
6562 jan 1424 2003-07-16 Jan-Oliver Wagner <[email protected]>
6563    
6564     * Doc/manual/thuban-manual.xml: Added authors and an initial
6565     coarse structure.
6566    
6567 bh 1418 2003-07-15 Bernhard Herzog <[email protected]>
6568    
6569 bh 1422 * test/support.py (FloatComparisonMixin): This is a mix-in class
6570     and therefore should not be derived from any other class.
6571    
6572     * test/test_range.py (RangeTest): FloatComparisonMixin is a
6573     mix-in, so derive from TestCase as well.
6574    
6575     2003-07-15 Bernhard Herzog <[email protected]>
6576    
6577 bh 1420 * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Rework the
6578     draw_func handling a bit to remove one layer of indirection. This
6579     makes the renderer about 10% faster in the non-classifying case
6580     and the code a bit cleaner
6581     (MapRenderer.draw_point_shape): Add the pen and brush parameters
6582     and set them in the dc. Now the draw_point_shape method and
6583     wxproj's draw_polygon_shape function have basically the same
6584     signature so that both can be directly used as draw_func
6585    
6586     2003-07-15 Bernhard Herzog <[email protected]>
6587    
6588 bh 1418 * Thuban/Model/save.py (SessionSaver.write_classification): Encode
6589     string values (in addition to the labels) as UTF 8
6590    
6591     * Thuban/Model/load.py (SessionLoader.start_clpoint): Decode the
6592     values if the field type is string
6593    
6594     * test/test_save.py (SaveSessionTest.testClassifiedLayer): Test
6595     saving a session with non-ascii string classification values.
6596    
6597     * test/test_load.py (TestClassification.file_contents)
6598     (TestClassification.test): Check for non-ascii values in string
6599     classifications
6600    
6601 jonathan 1416 2003-07-14 Jonathan Coles <[email protected]>
6602    
6603     * test/test_view.py: New. Tests for ViewPort.
6604    
6605 frank 1409 2003-07-14 Frank Koormann <[email protected]>
6606    
6607     * Thuban/Model/load.py (SessionLoader.start_map): Encode map
6608     title to latin1. Fixes https://intevation.de/rt/webrt?serial_num=2013
6609    
6610 frank 1411 * test/test_load_0_8.py (TestUnicodeStrings): New, test load of
6611     unicode strings from session file: session title, map title and
6612     projection name.
6613    
6614 jonathan 1403 2003-07-10 Jonathan Coles <[email protected]>
6615    
6616 jonathan 1406 * Thuban/UI/viewport.py (Tool.MouseUp): Should have called
6617     drag_stop, not drag_move when the mouse is released.
6618    
6619     2003-07-10 Jonathan Coles <[email protected]>
6620    
6621 jonathan 1403 The most important part of this is the seperation of view.py into
6622     two pieces. viewport.py now has a class called ViewPort which
6623     contains all the non-wx parts of view.py and can therefore be
6624     tested. view.py contains only the wx-specific parts and is fairly
6625     simple.
6626    
6627     * Thuban/UI/view.py: Stripped out all non-wx functionality. Fixes
6628     RTTbug #1992.
6629     * Thuban/UI/viewport.py: New. Contains non-wx view functionality.
6630     RTTbug #1992.
6631    
6632     * Thuban/Model/classgen.py (generate_singletons,
6633     generate_uniform_distribution, generate_quantiles):
6634     Added 'fixes' parameter so that property attributes can
6635     be held constant over the generated classification groups.
6636     (CustomRamp.GetProperties): Remove unused variables.
6637    
6638     * Thuban/Model/map.py (Map.SetProjection): Send the old
6639     projection as an argument to listeners of the MAP_PROJECTION_CHANGED
6640     event.
6641    
6642     * Thuban/Model/table.py (table_to_dbf, table_to_csv): Added 'records'
6643     parameter which is a list of records that restricts which
6644     records are saved. Fixes RTbug #1997.
6645    
6646     * Thuban/UI/application.py (ThubanApplication.ShowExceptionDialog):
6647     Port exception dialog from GREAT-ER. Fixes RTbug #1993.
6648    
6649     * Thuban/UI/classgen.py (ClassGenDialog.__init__): Add controls
6650     to allow the user to fix line color/width on generated groups.
6651     (ClassGenDialog.OnOK): Use new 'fixes' parameter of the generate_*
6652     functions to optionally fix group properties.
6653    
6654     * Thuban/UI/main.py (main): Set exception hook to the
6655     ShowExceptionDialog. Fixes RTbug #1993.
6656    
6657     * Thuban/UI/mainwindow.py (MainWindow.ShowTableView): Raise
6658     the table window when it is selectd to be shown.
6659    
6660     * Thuban/UI/tableview.py (QueryTableFrame.__init__): Add an
6661     Export Selection button and move the export buttons underneath
6662     the table.
6663     (QueryTableFrame.UpdateStatusText): Added event argument so
6664     that it can respond to grid selection events. The status text
6665     is now updated even when the table is not associated with a
6666     layer as was previously assumed.
6667     (QueryTableFrame.OnGridSelectRange, OnGridSelectCell): Removed.
6668     UpdateStatusText responds to these events.
6669     (QueryTableFrame.OnSaveAs): Renamed to doExport.
6670     (QueryTableFrame.doExport): Helper function that saves the
6671     entire table, or selected rows, to a file.
6672     (QueryTableFrame.OnExport, QueryTableFrame.OnExportSel): New.
6673     Respond to export button events and call doExport.
6674    
6675     * extensions/thuban/gdalwarp.cpp (ProjectRasterFile): Make sure
6676     the function doesn't return NULL without first setting a Python
6677     Error.
6678    
6679     * test/runtests.py (main): Only print "Unknown option" for
6680     unsupported options.
6681    
6682     * test/support.py (FloatComparisonMixin.assertFloatEqual): Take
6683     optional epsilon argument to specify floating point accuracy.
6684     (FloatComparisonMixin.assertFloatSeqEqual): Call assertFloatEqual
6685     for each item test.
6686    
6687     * test/test_csv_table.py (TestCSVTable.test_table_to_cvs): Add
6688     tests for saving selected records.
6689    
6690     * test/test_dbf_table.py (TestTableToDBF.test_table_to_dbf): Add
6691     tests for saving selected records.
6692    
6693     * test/test_map.py (TestMapWithContents.test_set_projection):
6694     MAP_PROJECTION_CHANGED events send the old projection.
6695    
6696     * test/test_session.py
6697     (TestSessionWithContent.test_forward_map_projection):
6698     MAP_PROJECTION_CHANGED events send the old projection.
6699    
6700     * test/test_table.py (TableTest): Update tests to use non-deprecated
6701     functions.
6702    
6703 bh 1376 2003-07-08 Bernhard Herzog <[email protected]>
6704    
6705 bh 1382 * Thuban/Model/transientdb.py (TransientTableBase.Width): The type
6706     constants in the column objects are the standard ones defined in
6707     the table module.
6708    
6709     * test/test_transientdb.py
6710     (TestTransientTable.test_transienttable_to_dbf): New. Test whether
6711     exporting transient tables as DBF works. This should catch the bug
6712     just fixed in TransientTableBase.Width.
6713    
6714     2003-07-08 Bernhard Herzog <[email protected]>
6715    
6716 bh 1380 * Thuban/Model/classgen.py (CustomRamp.GetProperties): Compute the
6717     interpolated colors correctly.
6718    
6719     * test/test_classgen.py (TestCustomRamp.test_color_interpolation):
6720     New. Test case for the fix in classgen.py
6721    
6722     2003-07-08 Bernhard Herzog <[email protected]>
6723    
6724 bh 1378 * test/runtests.py (main): Make the default output less verbose
6725     and add a verbosity option (-v) to get the old output
6726    
6727     2003-07-08 Bernhard Herzog <[email protected]>
6728    
6729 bh 1376 * Resources/XML/thuban-0.9.dtd: New. This will become the DTD for
6730     0.9.
6731    
6732     * Thuban/Model/transientdb.py (TransientJoinedTable.JoinType):
6733     New. Return the join type
6734    
6735     * Thuban/Model/save.py (SessionSaver.write_session): Use new 0.9
6736     DTD
6737     (SessionSaver.write_data_containers): Save the join type for
6738     joined tables
6739    
6740     * Thuban/Model/load.py (SessionLoader.__init__): Add the new 0.9
6741     namespace
6742     (SessionLoader.start_jointable): Handle the jointype attribute
6743    
6744     * test/test_load_0_8.py: New. Effectively a copy of test_load.py
6745     as of Thuban 0.8. These are now tests to determine whether Thuban
6746     can still read files generated by Thuban 0.8
6747    
6748     * test/test_load.py (LoadSessionTest.dtd)
6749     (TestSingleLayer.file_contents)
6750     (TestLayerVisibility.file_contents, TestLabels.file_contents)
6751     (TestLayerProjection.file_contents)
6752     (TestRasterLayer.file_contents, TestJoinedTable.file_contents)
6753     (TestJoinedTable.file_contents)
6754     (TestLoadError.file_contents): Update for new DTD
6755     (TestJoinedTable.file_contents, TestJoinedTable.setUp): Add test
6756     for new join type attribute
6757    
6758     * test/test_save.py (SaveSessionTest.dtd)
6759     (SaveSessionTest.testEmptySession)
6760     (SaveSessionTest.testSingleLayer)
6761     (SaveSessionTest.testLayerProjection)
6762     (SaveSessionTest.testRasterLayer)
6763     (SaveSessionTest.testClassifiedLayer)
6764     (SaveSessionTest.test_dbf_table)
6765     (SaveSessionTest.test_joined_table): Update for new DTD
6766     (SaveSessionTest.test_joined_table): Add test for new join type
6767     attribute
6768    
6769 bh 1372 2003-07-04 Bernhard Herzog <[email protected]>
6770    
6771     * Thuban/Model/table.py (_find_dbf_column_names): New. Helper
6772     function for table_to_dbf
6773     (table_to_dbf): Deal with names longer than the 10 character limit
6774    
6775     * test/test_dbf_table.py (TestTableToDBF.test_table_to_dbf): Add
6776     doc-string
6777     (TestTableToDBF.test_table_to_dbf_long_col_names): New test for
6778     long column names
6779    
6780 bh 1365 2003-07-03 Bernhard Herzog <[email protected]>
6781    
6782 bh 1370 * Doc/manual/thuban-manual.xml: Fix the CVS Revision Tag syntax
6783    
6784     2003-07-03 Bernhard Herzog <[email protected]>
6785    
6786 bh 1368 * Doc/manual/thuban-manual.xml, Doc/manual/README: New. Skeleton
6787     for the Thuban manual and README with some basic information about
6788     the manual
6789    
6790     2003-07-03 Bernhard Herzog <[email protected]>
6791    
6792 bh 1365 * Thuban/Model/transientdb.py (TransientJoinedTable.__init__):
6793     Update doc-string
6794     (TransientJoinedTable.create): Do not modify the column objects of
6795     the input tables in place and copy all columns of the input tables
6796     into the joined table after all.
6797    
6798     * test/test_transientdb.py
6799     (TestTransientTable.test_transient_joined_table_same_column_name):
6800     Update to reflect the new behavior
6801     (TestTransientTable.test_transient_joined_table_with_equal_column_names):
6802     Update to reflect the new behavior
6803     (TestTransientTable.test_transient_joined_table_name_collisions_dont_modify_in_place):
6804     New test case for a bug which modified the column objects in place
6805    
6806 jonathan 1360 2003-07-02 Jonathan Coles <[email protected]>
6807 jonathan 1349
6808 jonathan 1360 * Thuban/Model/classgen.py (generate_singletons,
6809     generate_uniform_distribution, generate_quantiles,
6810 jonathan 1363 GenQuantiles0): Make sure maxValue isn't less than
6811     one, otherwise we could divide by zero.
6812    
6813     * test/test_classgen.py (ClassGenTest.doClassRangeTest,
6814     ClassGenTest.doClassSingleTest): Call doBoundsTest to
6815     check the end classification groups against the
6816     proper property values.
6817     (ClassGenTest.doBoundsTest): New. Checks the first and
6818     last classification groups to make sure their properties
6819     are the correct upper and lower bounds for a color ramp.
6820    
6821     2003-07-02 Jonathan Coles <[email protected]>
6822    
6823     * Thuban/Model/classgen.py (generate_singletons,
6824     generate_uniform_distribution, generate_quantiles,
6825 jonathan 1360 GenQuantiles0): The denominator was one to high when
6826     calculating the index for the ramp causing the index
6827     to never to reach one.
6828    
6829     2003-07-02 Jonathan Coles <[email protected]>
6830    
6831 jonathan 1358 Changed the singature of ClassGroupRange.__init__ and
6832     ClassGroupRange.SetRange() so that the min/max values are
6833     passed as a tuple. This makes a better calling scheme for
6834     when a Range object is passed instead.
6835    
6836     * Thuban/Model/classgen.py: Fixed parameters to
6837     ClassGroupRange constructor.
6838    
6839     * Thuban/Model/classification.py (ClassGroupRange.__init__):
6840     Consolidate the min/max parameters into a single _range which
6841     can either be a tuple or a Range object.
6842     (ClassGroupRange.SetRange): Consolidate the min/max parameters
6843     into a single _range which can either be a tuple or a Range object.
6844    
6845     * Thuban/Model/load.py (SessionLoader.start_clrange): Fix
6846     call to ClassGroupRange constructor to use a tuple.
6847    
6848     * Thuban/Model/layer.py (Layer.SetClassification): Switch
6849     the classification instance variable to the new class
6850     before calling _set_layer otherwise subscribers to a
6851     LAYER_CHANGED event will not see any difference.
6852    
6853     * test/test_classification.py: Fix tests of ClassGroupRange
6854     so that they use the new signature.
6855    
6856     * test/test_load.py: Fix use of ClassGroupRange so that it
6857     uses the new signature.
6858    
6859     * test/test_load_0_2.py: Fix use of ClassGroupRange so that it
6860     uses the new signature.
6861    
6862     * test/test_save.py: Fix use of ClassGroupRange so that it
6863     uses the new signature.
6864    
6865    
6866     2003-07-01 Jonathan Coles <[email protected]>
6867    
6868 jonathan 1349 * Thuban/Model/classgen.py: Fixes RTbug #1972, 1971.
6869     Import used objects/class from color.
6870     (generate_singletons): We don't
6871     need the numGroups parameter anymore because we are using
6872     the new ramps with GetProperties().
6873     (generate_uniform_distribution): Use new ramp method
6874     GetProperties().
6875     (generate_quantiles, GenQuantiles0): Use new ramp method
6876     GetProperties().
6877     (CustomRamp.SetNumGroups): Removed. The ramps now map
6878     a value from 0 to 1 to class properties so the number
6879     of groups is not needed ahead of time.
6880     (CustomRamp.next): Removed. CustomRamp does not support
6881     interation anymore.
6882     (CustomRamp.GetProperties): Returns a ClassGroupProperties
6883     object based on the index value from 0 to 1 that is
6884     passed to it.
6885     (GreyRamp, RedRamp, GreenRamp, BlueRamp, GreenToRedRamp):
6886     Made into instances of Monochromatic class instread of
6887     deriving from it.
6888     (HotToCold.SetNumGroups): Removed. See CustomRamp.
6889     (HotToCold.next): Removed. See CustomRamp.
6890    
6891     * Thuban/Model/classification.py: Fixes RTbug #1973, 1971.
6892     (Classification.SetField, Classification.SetFieldType):
6893     Replaced with SetFieldInfo.
6894     (Classification.SetFieldInfo): New. Does a better job of
6895     what SetField and SetFieldType used to do by combining
6896     their function since they should really always be done
6897     at the same time.
6898     (Classification.SetLayer): Renamed to _set_layer.
6899     (Classification._set_layer): Should only be called from
6900     Layer's SetClassification. This does not cause a recursive
6901     call as SetLayer did because we know that Layer knows about
6902     the classification.
6903    
6904     * Thuban/Model/color.py: Fixes RTbug #1971.
6905     (_Transparent): Renamed from Transparent so it doesn't
6906     conflict with the module variable.
6907     (Transparent, Black): Renamed from Color.Transparent,
6908     Color.Black so they are not class variables.
6909    
6910     * Thuban/Model/layer.py: Fixes RTbug #1971, 1973.
6911     (Layer.Destroy): We don't need to call SetClassification
6912     anymore to clear out the back reference in the classifcation
6913     to the layer. It's better to set it to None using _set_layer,
6914     and we won't be creating another clas object too.
6915     (Layer.SetClassification): Classification._set_layer is not
6916     recursive so remove all the locking variables. Also clean
6917     up the code so that it remains unchanged if something fails.
6918    
6919     * Thuban/Model/load.py: Fixes RTbug #1971.
6920     (SessionLoader.start_classification): Call
6921     Classification.SetFieldInfo().
6922    
6923     * Thuban/Model/save.py: Removed import of Color which wasn't
6924     being used.
6925    
6926     * Thuban/UI/classgen.py: Fixes RTbug #1972.
6927     (ClassGenDialog.__init__): Color ramps are now instances
6928     already so we don't need to create any new objects.
6929     (ClassGenDialog.OnOK): Check for numGroups is no longer
6930     necessary because we never use it.
6931    
6932     * Thuban/UI/classifier.py: Fixes RTbug #1971.
6933     (Classifier.__BuildClassification, Classifier.__SetGridTable):
6934     Call Classification.SetFieldInfo() instead of SetFieldType.
6935    
6936     * Thuban/UI/renderer.py: Fixes RTbug #1971.
6937    
6938     * Thuban/UI/view.py: Fixes RTbug #1974, 1971.
6939     (MapCanvas.__init__): Subscribe to the idle time event. Set
6940     background color to white.
6941     (MapCanvas.OnPaint): Set a flag indicating that we should
6942     render the map during idle time. If we already have a bitmap
6943     just draw it now.
6944     (MapCanvas.OnIdle): New. Render the map only during idle time.
6945     This also fixes a problem with the busy cursor under gtk.
6946    
6947     * test/test_classgen.py (ClassGenTest.test_generate_singletons):
6948     Fix calls to generate_singletons because the signature changed.
6949    
6950     * test/test_classification.py: Fix color references and
6951     change calls to Classification.[SetField|SetFieldType] to
6952     SetFieldInfo.
6953    
6954     * test/test_load.py: Fix color references.
6955    
6956     * test/test_load_0_2.py: Fix color references.
6957    
6958     * test/test_save.py (SaveSessionTest.testClassifiedLayer):
6959     Change calls to Classification.[SetField|SetFieldType] to
6960     SetFieldInfo.
6961    
6962 frank 1334 2003-07-01 Frank Koormann <[email protected]>
6963    
6964     MERGE from the greater-ms3 branch.
6965    
6966     * test/test_transientdb.py
6967     (TestTransientTable.test_transient_joined_table_with_equal_column_names):
6968     New. Test join of two tables with partly equal column names.
6969    
6970     * Thuban/Model/transientdb.py (TransientJoinedTable.create):
6971     If duplicates in left and right tables column names are found,
6972     append '_' (underscores) to the name until it is unique.
6973     Create always new internal names for the resulting table and reference
6974     columns in the join statement with <table>.<column>
6975    
6976 bh 1329 2003-07-01 Bernhard Herzog <[email protected]>
6977    
6978     * test/test_transientdb.py
6979     (TestTransientTable.test_transient_joined_table_same_column_name):
6980     New. Test whether joining on columns with the same names in both
6981     tables works.
6982 frank 1334
6983 bh 1329 * Thuban/Model/transientdb.py (TransientJoinedTable.create): Make
6984     sure to use the right internal names even when joining on field
6985     with the same names in both tables. Also, detect duplicate names
6986     in the joined table correctly.
6987    
6988 frank 1325 2003-07-01 Frank Koormann <[email protected]>
6989    
6990     * Thuban/UI/renderer.py (ExportRenderer.render_legend):
6991     Reverse List of layers to render in same order as in desktop legend.
6992    
6993 jonathan 1318 2003-06-30 Jonathan Coles <[email protected]>
6994    
6995 jonathan 1349 * Thuban/version.py (make_tuple): Takes a version string
6996     and splits it into a tuple of at most three integers.
6997     Used make_tuple() to make tuple versions of the version
6998     numbers.
6999    
7000     * Thuban/UI/about.py: Add Thuban email addresses.
7001    
7002     2003-06-30 Jonathan Coles <[email protected]>
7003    
7004 jonathan 1320 * Thuban/version.py: SQLite/PySQLite version dependencies
7005     were too high.
7006    
7007     2003-06-30 Jonathan Coles <[email protected]>
7008    
7009 jonathan 1318 * Thuban/version.py: Update version to 0.8.1
7010    
7011     * MANIFEST.in: Added Projections so that default.proj is
7012     included.
7013    
7014 jonathan 1312 2003-06-26 Jonathan Coles <[email protected]>
7015    
7016     New About box with lots more information including library
7017     versions and credits. More/better version checking before
7018     Thuban starts.
7019    
7020     * Thuban/UI/about.py: New. New About box that displays
7021     library version information and credits.
7022    
7023     * Thuban/version.py: Added new 'versions' dictionary which
7024     contains the verions of various libraries which are checked
7025     when the module loads.
7026     (verify_versions): Check all version numbers and returns
7027     a list of errors.
7028    
7029     * Thuban/UI/classifier.py (Classifier.__EnableButtons):
7030     Reset the status of the buttons as the situation warrants,
7031     but in a better more reliable way by not relying on the
7032     current status to determine what needs to change.
7033    
7034     * Thuban/UI/main.py (wxCHECK_VERSION): Removed. Not needed.
7035     (verify_versions): Remove most of the code since it is
7036     now in Thuban.version.verify_versions.o
7037    
7038     * Thuban/UI/mainwindow.py (MainWindow.About): Call new
7039     About box in Thuban.UI.about.
7040    
7041     * extensions/thuban/gdalwarp.cpp (get_gdal_version): New.
7042     Returns the version of gdal library being used as a string.
7043    
7044     * extensions/thuban/wxproj.cpp (check_version, check_version_gtk):
7045     Removed.
7046     (get_proj_version): Return the version of PROJ that the file
7047     was compiled with.
7048     (get_gtk_version): Return th version of GTK that the file
7049     was compiled with.
7050    
7051 jonathan 1304 2003-06-25 Jonathan Coles <[email protected]>
7052    
7053     * Thuban/UI/classifier.py (Classifier.EditSymbol): The parent
7054     of the SelectPropertiesDialog should be self so the window
7055     appears on top.
7056     (ClassGroupPropertiesCtrl.DoEdit): The parent
7057     of the SelectPropertiesDialog should be self so the window
7058     appears on top.
7059    
7060     * Thuban/UI/resource.py: Cleaned up how we determine file
7061     extensions.
7062     (GetImageResource): Return an wxImage from our Resources.
7063    
7064 jonathan 1299 2003-06-24 Jonathan Coles <[email protected]>
7065    
7066     * Thuban/UI/renderer.py (ExportRenderer.render_legend):
7067     Check that a layer has a classification before trying
7068     to get it. Raster layers don't have classifications.
7069    
7070 jonathan 1286 2003-06-23 Jonathan Coles <[email protected]>
7071 jonathan 1297
7072     * setup.py: Add Resources/XML to resource list.
7073    
7074     2003-06-23 Jonathan Coles <[email protected]>
7075 jonathan 1286
7076 jonathan 1297 * setup.cfg: Fix copyright dates
7077    
7078     2003-06-23 Jonathan Coles <[email protected]>
7079    
7080 jonathan 1294 * MANIFEST.in: Update with Resources/XML
7081    
7082     * setup.py: Don't include Locale resources yet as we don't
7083     have any and it causes problems building the distribution
7084     for Windows. Update version to 0.8.0.
7085    
7086     * Doc/thuban.dtd: Removed since it is now in Resources/XML.
7087    
7088     * Thuban/UI/mainwindow.py: Add blank line at the end because
7089     file was not being read correctly building the Windows
7090     distribution.
7091    
7092     2003-06-23 Jonathan Coles <[email protected]>
7093    
7094 jonathan 1289 * Thuban/UI/mainwindow.py (MainWindow.About): Fix text.
7095    
7096     * Thuban/version.py: Temporarily update longversion for
7097     the 0.8 release so that it doesn't have the cvs revision.
7098    
7099     2003-06-23 Jonathan Coles <[email protected]>
7100    
7101 jonathan 1286 * Thuban/UI/common.py (ThubanBeginBusyCursor): Call wxSafeYield
7102     to make sure that we don't create reentrant possibilities with
7103     wxYield.
7104    
7105     * Thuban/UI/view.py (MapCanvas.OnPaint): Call wxBeginBusyCursor()
7106     directly to avoid the wxSafeYield() call which generates an
7107     OnPaint event causing infinite recursion. Don't try to catch
7108     exception anymore. This was for before there were limits on map
7109     scaling.
7110    
7111 bh 1283 2003-06-23 Bernhard Herzog <[email protected]>
7112    
7113     Bug fix for RT #1961:
7114    
7115     * Thuban/Model/load.py (SessionLoader.start_derivedshapesource):
7116     Register DerivedShapestores with the session
7117    
7118     * Thuban/Model/session.py (Session.Tables): Make sure each table
7119     is only listed once.
7120    
7121     * test/test_load.py (TestJoinedTable.test): Add check_format call.
7122     Update file contents to match the one written out.
7123    
7124 bh 1281 2003-06-20 Bernhard Herzog <[email protected]>
7125    
7126     * test/xmlsupport.py (SaxEventLister.startElementNS)
7127     (SaxEventLister.endElementNS): Do not include the qname. Python
7128     2.2.1 and 2.2.2 and 2.2.3 differ in this regard. In 2.2.1 qname it
7129     is (presumably incorrectly) None, whereas it's a string with the
7130     element name in the later versions.
7131    
7132     * test/test_xmlsupport.py (TestEventList.test_even_list_simple)
7133     (TestEventList.test_even_list_namespace): Update tests to reflect
7134     the new behaviour
7135     (TestEventList.test_even_list_id_normalization): Fix doc-string
7136    
7137 jonathan 1272 2003-06-20 Jonathan Coles <[email protected]>
7138    
7139 jonathan 1279 * Thuban/Model/layer.py (BaseLayer.HasShapes): New. Overridden
7140     by deriving classes to determine if that layer supports shapes.
7141     (Layer): Override HasShapes and return true.
7142    
7143     * Thuban/UI/classgen.py: Use Thuban[Begin|End]BusyCursor()
7144     instead of a direct call to wx[Begin|End]CusyCursor().
7145     (GenUniquePanel._OnRetrieve): Set busy cursor while retrieving
7146     table data.
7147    
7148     * Thuban/UI/common.py (ThubanBeginBusyCursor, ThubanEndBusyCursor):
7149     New. Wrappers around the wxWindows functions that allow us to
7150     make additional calls such as wxYield which gives the native
7151     system a chance to update the cursor correctly.
7152    
7153     * Thuban/UI/tableview.py: Use Thuban[Begin|End]BusyCursor()
7154     instead of a direct call to wx[Begin|End]CusyCursor().
7155    
7156     * Thuban/UI/view.py: Use Thuban[Begin|End]BusyCursor()
7157     instead of a direct call to wx[Begin|End]CusyCursor().
7158     (MapCanvas.find_shape_at): Check if the current search layer
7159     support shapes, otherwise go on to the next layer.
7160    
7161     * test/test_layer.py: Add tests in each type of layer for
7162     HasClassification() and HasShapes()
7163    
7164     2003-06-20 Jonathan Coles <[email protected]>
7165    
7166 jonathan 1272 * Thuban/UI/view.py (MapCanvas.OnPaint): Call wxYield after
7167     turning on the busy cursor to allow the system to change the
7168     cursor before we begin painting. This fixes a problem that
7169     was occuring only under GTK. Fixes RTbug #1840.
7170    
7171 bh 1270 2003-06-20 Bernhard Herzog <[email protected]>
7172    
7173     * Resources/XML/thuban-0.8.dtd: New DTD for the new file format
7174     version.
7175    
7176     * Thuban/Model/save.py (sort_data_stores): New. Make topological
7177     sort of the data sources so they can be written with sources that
7178     data sources that depend on other data sources come after the
7179     sources they depend on.
7180     (SessionSaver.__init__): Add idmap instance variable to map from
7181     objects to the ids used in the file.
7182     (SessionSaver.get_id, SessionSaver.define_id)
7183     (SessionSaver.has_id): New. Methods to manage the idmap
7184     (SessionSaver.write): Use thuban-0.8.dtd
7185     (SessionSaver.write_session): Add a namespace on the session and
7186     write out the data sources before the maps.
7187     (SessionSaver.write_data_containers): New. Write the data
7188     containers.
7189     (SessionSaver.write_layer): Layer elements now refer to a
7190     shapestore and don't contain filenames anymore.
7191    
7192     * Thuban/Model/load.py (LoadError): Exception class to raise when
7193     errors in the files are discovered
7194     (SessionLoader.__init__): Define dispatchers for elements with a
7195     thuban-0.8 namespace too.
7196     (SessionLoader.check_attrs): New helper method to check and
7197     convert attributes
7198     (AttrDesc): New. Helper class for SessionLoader.check_attrs
7199     (SessionLoader.start_fileshapesource)
7200     (SessionLoader.start_derivedshapesource)
7201     (SessionLoader.start_filetable, SessionLoader.start_jointable):
7202     Handlers for the new elements in the new fileformat
7203     (SessionLoader.start_layer): Handle the shapestore attribute in
7204     addition to filename.
7205     (SessionLoader.start_table, SessionLoader.end_table): Removed.
7206     They were never used in the old formats and aren't needed for the
7207     new.
7208    
7209     * Thuban/Model/session.py (Session.DataContainers): New method to
7210     return all "data containers", i.e. shapestores and tables
7211    
7212     * test/xmlsupport.py (SaxEventLister.__init__)
7213     (SaxEventLister.startElementNS, sax_eventlist): Add support to
7214     normalize IDs.
7215    
7216     * test/test_xmlsupport.py
7217     (TestEventList.test_even_list_id_normalization): New test case for
7218     id normalization
7219    
7220     * test/test_load.py (LoadSessionTest.check_format): Use ID
7221     normalization
7222     (LoadSessionTest.thubanids, LoadSessionTest.thubanidrefs): New
7223     class atrributes used for ID normalization
7224     (TestSingleLayer, TestLayerVisibility, TestLabels.test)
7225     (TestLayerProjection.test, TestRasterLayer.test): Adapt to new
7226     file format
7227     (TestJoinedTable): New test for loading sessions with joined
7228     tables.
7229     (TestLoadError): New. Test whether missing required attributes
7230     cause a LoadError.
7231    
7232     * test/test_save.py (SaveSessionTest.thubanids)
7233     (SaveSessionTest.thubanidrefs): New class attributes for ID
7234     normalization in .thuban files.
7235     (SaveSessionTest.compare_xml): Use id-normalization.
7236     (SaveSessionTest.testEmptySession)
7237     (SaveSessionTest.testLayerProjection)
7238     (SaveSessionTest.testRasterLayer)
7239     (SaveSessionTest.testClassifiedLayer): Adapt to new file format.
7240     (SaveSessionTest.testLayerProjection): The filename used was the
7241     same as for testSingleLayer. Use a different one.
7242     (SaveSessionTest.test_dbf_table)
7243     (SaveSessionTest.test_joined_table): New test cases for saving the
7244     new data sources structures.
7245     (TestStoreSort, MockDataStore): Classes to test the sorting of the
7246     data stores for writing.
7247    
7248     * test/runtests.py: Add CVS keywords
7249    
7250 jonathan 1265 2003-06-20 Jonathan Coles <[email protected]>
7251    
7252 jonathan 1267 * test/test_session.py
7253     (UnreferencedTablesTests.test_unreferenced_tables_with_joins):
7254     Use the cultural_landmark-point.dbf file for the store so that
7255     the table rows and shape count match.
7256    
7257     2003-06-20 Jonathan Coles <[email protected]>
7258    
7259 jonathan 1265 * Thuban/Model/data.py (DerivedShapeStore.__init__): Raise
7260     an exception if the number of shapes is different from the
7261     number of rows in the table. Address RTbug #1933.
7262    
7263     * test/test_layer.py (TestLayer.test_derived_store): Add
7264     a test for the new exception in DerivedShapeStore.__init__.
7265    
7266     * test/support.py (FloatTestCase): Removed since there is
7267     already FloatComparisonMixin. Fixes RTbug #1954.
7268     (FloatComparisonMixin.assertFloatEqual): Include test for
7269     infinity that was part of FloatTestCase.
7270    
7271     * test/test_range.py (RangeTest): Inherit from
7272     support.FloatComparisonMixin now that we don't have
7273     support.FloatTestCase.
7274    
7275 bh 1256 2003-06-20 Bernhard Herzog <[email protected]>
7276    
7277 bh 1260 * test/test_save.py (SaxEventLister, sax_eventlist): Removed. Use
7278     the implementation in xmlsupport instead.
7279     (SaveSessionTest.compare_xml): sax_eventlist is now in xmlsupport
7280    
7281     * test/test_proj.py: Import sax_eventlist from xmlsupport instead
7282     of test_save
7283    
7284     2003-06-20 Bernhard Herzog <[email protected]>
7285    
7286 bh 1258 * test/test_load.py (LoadSessionTest.check_format): New helper
7287     method to make sure the test files we load might have been written
7288     by the current thuban version.
7289     (ClassificationTest.TestLayers, TestSingleLayer.test)
7290     (TestLayerVisibility.test, TestClassification.test)
7291     (TestLabels.test, TestLayerProjection.test, TestRasterLayer.test):
7292     Add check_format() calls and fix the thuban data to match the data
7293     that would be written by saving the session loaded from it.
7294    
7295     * test/xmlsupport.py (SaxEventLister, sax_eventlist): Copies of
7296     the same class and function in test_save.
7297    
7298     * test/test_xmlsupport.py (TestEventList): New. test cases for
7299     sax_eventlist
7300    
7301     2003-06-20 Bernhard Herzog <[email protected]>
7302    
7303 bh 1256 * Resources/XML/thuban.dtd: Add comment about which versions of
7304     Thuban are covered by this DTD
7305     (map): Fix content model for layers and raster layers. There can
7306     be any number or layers and raster layers in any order.
7307    
7308 jonathan 1254 2003-06-20 Jonathan Coles <[email protected]>
7309    
7310 jonathan 1265 This is mainly about fixing RTbug #1949.
7311    
7312 jonathan 1254 * Thuban/Model/classification.py: Remove "from __future__"
7313     import statement since python 2.2 is the earliest supported
7314     version.
7315    
7316     * Thuban/Model/proj.py (Projection.GetProjectedUnits): New.
7317     Currently returns PROJ_UNITS_METERS or PROJ_UNITS_DEGREES
7318     depending on the units this projection *forwards* into.
7319    
7320     * Thuban/Model/save.py (SessionSaver.write_classification):
7321     Remove unnecessary use of lambdas and nested functions.
7322    
7323     * Thuban/UI/legend.py (ScaleBarBitmap.__SetScale): Do scale
7324     adjustment here if the map projection uses degrees.
7325    
7326     * Thuban/UI/scalebar.py (ScaleBar.DrawScaleBar): Remove
7327     scale adjust code since it is now done before calling
7328     this method. Don't do anything if the map projection
7329     is None.
7330    
7331 bh 1244 2003-06-19 Bernhard Herzog <[email protected]>
7332    
7333 bh 1248 Move version specific load tests to their own file.
7334    
7335     * test/test_load.py: Expand the doc-string to explain a bit how to
7336     handle file format changes.
7337     (TestClassification.test): Update the docstring as this test is
7338     not about Thuban 0.2 anymore.
7339    
7340     * test/test_load_0_2.py: New file with the load tests for thuban
7341     files created with Thuban 0.2 and earlier.
7342    
7343     2003-06-19 Bernhard Herzog <[email protected]>
7344    
7345 bh 1246 Add XML validation to some of the tests. Validation will only be
7346     done if pyRXP is installed (http://reportlab.com/xml/pyrxp.html).
7347     To make the DTD available to the test cases it's moved into
7348     Resources/XML
7349    
7350     * Resources/XML/thuban.dtd: New. This is now the real Thuban DTD
7351     for versions up to and including 0.2. Two slight changes: added an
7352     encoding specification and fixed the comment which refered to
7353     GRASS, not Thuban
7354    
7355     * test/xmlsupport.py: New support module for tests involving XML.
7356     Currently there's a mix-in class for XML validation.
7357    
7358     * test/test_xmlsupport.py: New. Tests for the xmlsupport module
7359    
7360     * test/test_save.py (SaveSessionTest): Derive from ValidationTest
7361     so that we can validate the
7362     (SaveSessionTest.testEmptySession)
7363     (SaveSessionTest.testSingleLayer)
7364     (SaveSessionTest.testSingleLayer)
7365     (SaveSessionTest.testLayerProjection)
7366     (SaveSessionTest.testRasterLayer)
7367     (SaveSessionTest.testClassifiedLayer): Validate the generated XML
7368    
7369     * test/runtests.py (main): Call print_additional_summary instead
7370     of print_garbage_information
7371    
7372     * test/support.py (resource_dir): New function to return the
7373     "Resource" subdirectory
7374     (print_additional_summary): New function to combine several
7375     summary functions
7376     (run_tests): Use print_additional_summary instead of calling
7377     print_garbage_information directly
7378    
7379     2003-06-19 Bernhard Herzog <[email protected]>
7380    
7381 bh 1244 * Doc/thuban.dtd (classification): Correct the content model of
7382     the classification element.
7383     (projection): Add the "name" attribute
7384    
7385 frank 1242 2003-06-19 Frank Koormann <[email protected]>
7386    
7387     MERGE from the greater-ms3 branch.
7388    
7389     * Thuban/UI/scalebar.py (ScaleBar.DrawScaleBar): Apply conversion to
7390     scale if projection is latlong to get better estimate.
7391    
7392     Fix problem of hidden properties dialog under windows after double
7393     click on layer tree:
7394     The tree control always gets an Expanded / Collapsed event after
7395 joey 2162 the ItemActivated on double click, which raises the main window again.
7396     We add a second ItemActivated event to the queue, which simply
7397 frank 1242 raises the already displayed window.
7398    
7399     * Thuban/UI/legend.py (LegendTree.__init__): Instance variable
7400     raiseProperties initialized to prevent endless loops
7401     (LegendTree._OnItemActivated): Depending on self.raiseProperties
7402     simply raise the properties or open the dialog and issue a second
7403     event.
7404    
7405 jonathan 1235 2003-06-18 Jonathan Coles <[email protected]>
7406    
7407 jonathan 1239 * setup.py: Fix a few problems that occured under Windows.
7408    
7409     2003-06-18 Jonathan Coles <[email protected]>
7410    
7411 jonathan 1235 When Thuban loaded the map was redrawn twice because the
7412     legend was being opened after the mainwindow was created
7413     and not during its creation. This meant the map was drawn
7414     initially and then had to be redrawn when the legend
7415     caused the display to change. Now the legend is opened
7416     in the mainwindow constructor which resolves this issue.
7417    
7418     Also, although we were checking for the existence of
7419     gdal and gdalwarp modules, the gdalwarp extension was
7420     still being compiled (which may fail if the system doesn't
7421     have gdal installed). the build_ext command to setup.py
7422     now accepts the flags --with-gdal and --without-gdal.
7423     If --without-gdal is specified setup.py will try to
7424     use the gdal parameters specified by gdal-config. Under
7425     windows, those parameters have to be set in setup.py
7426     as with proj4 an wxWindows.
7427    
7428     * setup.py: Use a list instead of seperate variables for
7429     extension parameters so we can create a generic function
7430     that runs an appropriate *-config script.
7431     (run_cs_script): Renamed from run_wx_script and modified
7432     to accept a second argument which is a list of lists to
7433     be filled in by the values returned from running the command.
7434     (thuban_build_ext): New. Extends the build_ext command and
7435     provides the options --with-gdal/--without-gdal which then
7436     optionally includes the gdalwarp extension.
7437    
7438     * Thuban/Model/resource.py: First check if we can import
7439     the gdalwarp Thuban extension before checking for gdal.
7440     Also added some comments.
7441    
7442     * Thuban/UI/legend.py (ScaleBarBitmap.__SetScale): Check if
7443     the map is None which may be the case if none has been loaded
7444     yet.
7445    
7446     * Thuban/UI/main.py (main): Remove call to ShowLegend.
7447    
7448     * Thuban/UI/mainwindow.py (MainWindow.__init__): Call ShowLegend().
7449    
7450     * Thuban/UI/renderer.py: Check for gdal support before importing
7451     gdalwarp.
7452     (MapRenderer.render_map): Only try to optimize if we have gdal
7453     support otherwise nothing will get drawn.
7454    
7455 jonathan 1237 * Thuban/UI/view.py (MapCanvas.FitMapToWindow): This may be called
7456     during startup before a map has been created. Check if map is None
7457     before using it and do nothing if it is.
7458    
7459 jonathan 1224 2003-06-17 Jonathan Coles <[email protected]>
7460    
7461     Fix the problem with raster layers under Windows that caused
7462     Thuban to crash. The view should respond to layer projection
7463     changed events to update the display. Changes to a projection
7464     should not cause the map to be set to full extent.
7465    
7466     * Thuban/UI/view.py (MapCanvas.__init__): New instance variable
7467     current_map_proj to remember the current map projection so that
7468     when the projection changes we know what the previous projection
7469     was.
7470     (MapCanvas.SetMap): Unsubscribe and subscribe to
7471     LAYER_PROJECTION_CHANGED events.
7472     (MapCanvas.projection_changed): Split into two methods that respond
7473     to map and layer projection changes.
7474     (MapCanvas.map_projection_changed): New. Takes the current view and
7475     projects it using the new projection. This does not cause the
7476     map to be redrawn at full extent.
7477     (MapCanvas.layer_projection_changed): New. Cause a redraw which
7478     will draw each layer in its new projection.
7479    
7480     * extensions/thuban/bmpdataset.cpp (BMPDataset::Open): Call
7481     VSIFClose() not VSIFCloseL() to close the file. Fixes a crash
7482     under Windows.
7483    
7484     * extensions/thuban/gdalwarp.cpp (MFILENAME): Padding should be
7485     to twice sizeof(void*) because there are two digits for each
7486     hex byte.
7487    
7488 bh 1220 2003-06-16 Bernhard Herzog <[email protected]>
7489    
7490     Update to the layer interface: Direct access to the table,
7491     shapetable, shapefile and filename attributes is now actively
7492     deprecated by issuing deprecation warnings for all places where
7493     this happens.
7494    
7495     * Thuban/Model/layer.py (Layer.__getattr__): New. Implement access
7496     to the instance variables table, shapetable, shapefile and
7497     filename via __getattr__ so that we can issue a deprecation
7498     warning.
7499     (Layer.SetShapeStore): Don't set the deprecated instance variables
7500     any more
7501     (Layer.SetShapeStore): Don't use deprecated layer instance
7502     variables
7503     (Layer.Destroy): No need to explicitly remove the instance
7504     variables any more
7505     (Layer.GetFieldType, Layer.Shape): Don't use deprecated layer
7506     instance variables
7507    
7508     * Thuban/UI/classgen.py (ClassGenDialog.__init__)
7509     (GenUniformPanel._OnRetrieve, GenUniquePanel._OnRetrieve)
7510     (GenQuantilesPanel.GetList, GenQuantilesPanel.OnRetrieve): Don't
7511     use deprecated layer instance variables
7512    
7513     * Thuban/UI/classifier.py (Classifier.__init__): Don't use
7514     deprecated layer instance variables
7515    
7516     * Thuban/UI/identifyview.py (IdentifyListCtrl.selected_shape)
7517     (IdentifyGridCtrl.selected_shape): Don't set the deprecated layer
7518     instance variables
7519    
7520     * Thuban/UI/tableview.py (LayerTableGrid.select_shapes): Don't use
7521     deprecated layer instance variables
7522    
7523     * Thuban/UI/mainwindow.py (MainWindow.LayerShowTable): Don't use
7524     deprecated layer instance variables
7525    
7526     * Thuban/Model/save.py (SessionSaver.write_layer): Don't use
7527     deprecated layer instance variables
7528    
7529     * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer)
7530     (MapRenderer.polygon_render_param): Don't use deprecated layer instance
7531     variables
7532    
7533     * test/runtests.py (main): Turn Thuban's deprecation warnings into
7534     errors so that they're cought by the tests
7535    
7536     * test/test_load.py (TestSingleLayer.test): Don't use deprecated
7537     layer instance variables
7538    
7539 jonathan 1212 2003-06-16 Jonathan Coles <[email protected]>
7540    
7541     Fix a problem under Windows whereby if the user double-clicks on a
7542     layer in the legend that tree item will expand or collapse as well
7543     as open the layer properties dialog. The state of the tree item
7544     should not be affected.
7545    
7546     * Thuban/UI/legend.py (LegendTree.__init__): Add instance variable
7547     preventExpandCollapse and subscribe to expanding and collapsing
7548     events.
7549     (LegendTree.OnItemExpandCollapse): New. Responds to expanding and
7550     collapsing events and will veto the event if it has been triggered
7551     by the user double clicking on a layer.
7552     (LegendTree._OnItemActivated): Set preventExpandCollapse to indicate
7553     that an expanding/collapsing event should be vetoed.
7554    
7555 bh 1208 2003-06-13 Bernhard Herzog <[email protected]>
7556    
7557     * Thuban/UI/classifier.py (Classifier.OnClose)
7558     (Classifier.map_layers_removed)
7559     (Classifier.layer_shapestore_replaced): Unsubscribe the messages
7560     in OnClose and not in map_layers_removed or
7561     layer_shapestore_replaced to make sure it always happens when the
7562     dialog is closed
7563    
7564 jonathan 1201 2003-06-13 Jonathan Coles <[email protected]>
7565    
7566 jonathan 1203 This puts back a fix for Windows where a panel is needed so that
7567     the background of the table view appears correctly.
7568    
7569     * Thuban/UI/tableview.py (TableFrame.__init__): Add a panel
7570     object that can be used by derived classes to place any
7571     controls (including the grid) onto.
7572     (QueryTableFrame.__init__): Use the panel as the parent window
7573     for all the controls. Reparent the grid so that the panel is
7574     the parent. Call UpdateStatusText() to correctly initialize
7575     the status bar.
7576    
7577     2003-06-13 Jonathan Coles <[email protected]>
7578    
7579 jonathan 1201 * Thuban/UI/dialogs.py (ThubanFrame): New: a class that inherits
7580     from wxFrame (as opposed to wxDialog like the other classes)
7581     but otherwise behaves like the other classes. This is needed
7582     for the TableView which isn't really a dialog and needs to
7583     have a status bar and control buttons.
7584    
7585     * Thuban/UI/tableview.py (TableGrid.__init__): Create an
7586     instance variable to keep track of how many rows are selected.
7587     Subscribe once to the the events we are interested in.
7588     (ThubanGrid.OnRangeSelect): Only handle event if event handling
7589     hasn't been turned off.
7590     (ThubanGrid.OnSelectCell): Only handle event if event handling
7591     hasn't been turned off.
7592     (ThubanGrid.ToggleEventListeners): Rather than subscribe None
7593     as an event listener (which changes the event handler stack)
7594     simply set an instance variable to False. This is checked in
7595     the event handlers.
7596     (ThubanGrid.GetNumberSelected): Return the number of currently
7597     selected rows.
7598     (TableFrame): Inherit from ThubanFrame so we can have a
7599     status bar and control buttons.
7600     (QueryTableFrame.__init__): Create a status bar. Fixes RTbug #1942.
7601     Explicitly set which items are selected in the operator choice and
7602     action choice so there is always a valid selection. Fixes RTbug #1941.
7603     Subscribe to grid cell selection events so we can update the
7604     status bar.
7605     (QueryTableFrame.UpdateStatusText): Update the status bar with
7606     how many rows are in the grid, how many columns, and how many
7607     rows are selected.
7608     (QueryTableFrame.OnGridSelectRange, QueryTableFrame.OnGridSelectCell):
7609     Call UpdateStatusText when cells are (de)selected.
7610     (QueryTableFrame.OnQuery): Use the string value in the value
7611     combo if either the selected item index is 0 or if the string
7612     cannot be found in the predefined list (this happens if the
7613     user changes the text). Fixes RTbug #1940.
7614     Only turn off the grid event listeners if there a query comes
7615     back with a none empty list of ids. in the case that the list
7616     is empty this causes a grid.ClearSelection() call to actually
7617     clear the grid selection which causes the selected items in
7618     the map to be deselected. Fixes RTbug #1939.
7619    
7620     * test/test_save.py (XMLWriterTest.Encode): Check return values.
7621     Fixes RTbug #1851.
7622    
7623 bh 1195 2003-06-13 Bernhard Herzog <[email protected]>
7624    
7625     * Thuban/UI/identifyview.py (IdentifyView.__init__): Call
7626     self.selected_shape with the current selection to make sure the
7627     contents of the dialog are up to date when it's shown for the
7628     first time.
7629     The dialog used to work without this by luck. The recent fix to
7630     the connector module 'broke' a 'feature' the identify view was
7631     relying on, i.e that subscribing to a message in response to
7632     receiving a message of that type would mean that the new
7633     subscriber would also be called for the same message.
7634    
7635 jonathan 1169 2003-06-12 Jonathan Coles <[email protected]>
7636 jonathan 1175
7637 jonathan 1193 * extensions/thuban/gdalwarp.cpp: Removed debug printing as
7638     the image is rendered. Fixes RTbug #1937.
7639    
7640     2003-06-12 Jonathan Coles <[email protected]>
7641    
7642 jonathan 1191 * Thuban/Lib/fileutil.py: As is done under Windows, create the
7643 jonathan 1193 user directory if it doesn't exist on a posix system.
7644     Fixes RTbug #1815.
7645 jonathan 1191
7646     * Thuban/Model/resource.py (get_user_proj_files): Moved the
7647     called to get_application_dir here, so that the directory
7648     will only be called if this method is invoked.
7649    
7650     * Thuban/UI/projdialog.py (ProjFrame.__DoOnProjAvail): Clear
7651     the projfilepath if no projection is selected.
7652    
7653     2003-06-12 Jonathan Coles <[email protected]>
7654    
7655 jonathan 1182 * Thuban/UI/legend.py (ScaleBarBitmap.__SetScale): Don't draw
7656     the scalebar if the current map has no projection set.
7657    
7658     * Thuban/UI/projdialog.py (ProjFrame.__DoOnProjAvail): Set the
7659     projfilepath label to just the basename of the projection file
7660     rather than include the entire path.
7661    
7662     * Thuban/Model/resource.py: Fix missed proj functions that
7663     needed to be renamed.
7664    
7665     2003-06-12 Jonathan Coles <[email protected]>
7666    
7667 jonathan 1178 * Thuban/Model/classification.py: Removed assert statements that
7668     tested if the variable was an instance of Color.
7669    
7670     * Thuban/Model/color.py (Color): Remove commented code that isn't
7671     used.
7672     (Transparent): Renamed from NoColor. Doesn't inherit from Color.
7673     Fixes RTbug #1835.
7674     (Transparent.__eq__, Transparent.__ne, Transparent.__repr): New.
7675     Needed now that the class doesn't inherit from Color.
7676    
7677     2003-06-12 Jonathan Coles <[email protected]>
7678    
7679 jonathan 1175 * test/test_save.py (XMLWriterTest.testEncode): Explicitly
7680     check unicode strings.
7681    
7682     * test/test_layer.py: Check for existence of gdal.
7683    
7684     2003-06-12 Jonathan Coles <[email protected]>
7685 jonathan 1172
7686     * Thuban/Model/xmlreader.py: New. Contains the XMLReader class
7687     that was in load.py
7688 jonathan 1169
7689 jonathan 1172 * Thuban/Model/xmlwriter.py: New. Contains the XMLWriter class
7690     that was in save.py
7691    
7692     2003-06-12 Jonathan Coles <[email protected]>
7693    
7694 jonathan 1169 This is largely a collection of bug fixes. We also handle the
7695     case where gdal is not on the system. The XMLReader and XMLWriter
7696     classes were moved into there own files to resolve some circular
7697     import references and because they shouldn't really be in the
7698     file that is dediciated to reading/writing session files since
7699     they are also used elsewhere.
7700    
7701     * Thuban/Model/classgen.py: Renamed functions to follow the
7702     function_names_with_underscores style. Fixes RTbug #1903.
7703     (calculate_quantiles): Raise ValueError if 'percents' is invalid.
7704    
7705     * Thuban/Model/layer.py: Import gdal only if it available.
7706     (RasterLayer): Handle the case where the gdal library is unavailable.
7707     Addresses RTbug #1877.
7708    
7709     * Thuban/Model/load.py (XMLReader): Moved into seperate file
7710     xmlreader.py.
7711    
7712 jonathan 1172 2003-06-12 Jonathan Coles <[email protected]>
7713    
7714     This is largely a collection of bug fixes. We also handle the
7715     case where gdal is not on the system. The XMLReader and XMLWriter
7716     classes were moved into there own files to resolve some circular
7717     import references and because they shouldn't really be in the
7718     file that is dediciated to reading/writing session files since
7719     they are also used elsewhere.
7720    
7721     * Thuban/Model/classgen.py: Renamed functions to follow the
7722     function_names_with_underscores style. Fixes RTbug #1903.
7723     (calculate_quantiles): Raise ValueError if 'percents' is invalid.
7724    
7725     * Thuban/Model/layer.py: Import gdal only if it available.
7726     (RasterLayer): Handle the case where the gdal library is unavailable.
7727     Addresses RTbug #1877.
7728    
7729     * Thuban/Model/load.py (XMLReader): Moved into seperate file
7730     xmlreader.py.
7731    
7732 jonathan 1169 * Thuban/Model/save.py (escape, XMLWriter): Moved into seperate
7733     file xmlwriter.py.
7734    
7735     * Thuban/Model/resource.py: Renamed functions to following the
7736     function_names_with_underscores style.
7737     (has_gdal_support): New function that returns true if the gdal
7738     library is available. Addresses RTbug #1877.
7739    
7740     * Thuban/UI/application.py (ThubanApplication.OpenSession):
7741     Display a message box if the gdal library is not available, but
7742     only if there are any layers that would use it. Addresses RTbug #1877.
7743    
7744     * Thuban/UI/classgen.py: Use renamed projection resource functions.
7745     (GenUniformPanel.__CalcStepping): Fix a slight discrepency
7746     when using integers versus floats.
7747    
7748     * Thuban/UI/mainwindow.py (_has_gdal_support): New. Used to
7749     determine if the "Add Image Layer" menu option should be
7750     greyed out or not. Addresses RTbug #1877.
7751    
7752     * Thuban/UI/projdialog.py: Use renamed projection resource functions.
7753    
7754     * Thuban/UI/renderer.py (MapRenderer.render_map): Only try to
7755     optimize if a raster layer is visible. Fixes RTbug #1931.
7756     Only draw the raster layer if the gdal library is available.
7757     Addresses RTbug #1877.
7758    
7759     * test/test_classgen.py: Add tests for generate_singletons,
7760     generate_uniform_distribution, generate_quantiles. Fixes RTbug #1903.
7761     (test_calculate_quantiles): Fix some tests to catch the new
7762     ValueError that is raised.
7763    
7764     * test/test_proj.py: Use renamed projection resource functions.
7765    
7766     * test/test_save.py (SaveSessionTest.testClassifiedLayer): New
7767     test for saving classified layers. Fixes RTbug #1902.
7768     (XMLWriterTest): New. Tests the XMLWriter class. Fixes RTbug #1851.
7769    
7770 jan 1156 2003-06-12 Jan-Oliver Wagner <[email protected]>
7771    
7772     Fix for http://intevation.de/rt/webrt?serial_num=1900.
7773    
7774     * Thuban/UI/multiplechoicedialog.py: New. A multiple choice dialog.
7775    
7776     * Thuban/UI/mainwindow.py: import wxMultipleChoiceDialog from
7777     multiplechoicedialog.py rather than from the wxPython library.
7778    
7779 frank 1151 2003-06-11 Frank Koormann <[email protected]>
7780    
7781 frank 1152 * Thuban/Lib/fileutil.py (get_application_dir): Minor stability
7782     update.
7783    
7784     2003-06-11 Frank Koormann <[email protected]>
7785    
7786 frank 1151 * Thuban/Lib/fileutil.py (get_application_dir): New function to
7787     determine the absolute .thuban/thuban directory under
7788     "posix" (os.expanduser) and "nt" (read AppData registry key).
7789    
7790     * Thuban/Model/resource.py: Use get_application_dir
7791    
7792     * Thuban/UI/application.py (ThubanApplication.read_startup_files):
7793     Use get_application_dir.
7794    
7795 bh 1143 2003-06-10 Bernhard Herzog <[email protected]>
7796    
7797 bh 1147 * Thuban/UI/tableview.py (LayerTableFrame.__init__): Subscribe to
7798     the messages MAP_LAYERS_REMOVED messages
7799     (LayerTableFrame.OnClose): Unsubscribe from it.
7800     (LayerTableFrame.map_layers_removed): New. Receiver for
7801     MAP_LAYERS_REMOVED. Close the dialog when the layer whose the
7802     dialog is showing is removed.
7803    
7804     2003-06-10 Bernhard Herzog <[email protected]>
7805    
7806 bh 1145 * Thuban/Lib/connector.py (Connector.Issue): Iterate over a copy
7807     of the receivers list so that unsubscribing in a receiver doesn't
7808     modify it while iterating over it.
7809    
7810     * test/test_connector.py
7811     (ConnectorTest.test_disconnect_in_receiver): New. Test whether
7812     unsubscribing in a receiver works correctly. See docstring for
7813     details
7814    
7815     2003-06-10 Bernhard Herzog <[email protected]>
7816    
7817 bh 1143 * Thuban/Model/messages.py (LAYER_SHAPESTORE_REPLACED): New
7818     message.
7819    
7820     * Thuban/Model/layer.py (Layer.SetShapeStore): Send
7821     LAYER_SHAPESTORE_REPLACED when the shapestore changes. A
7822     LAYER_CHANGED will still be sent if the classification changes.
7823    
7824     * Thuban/UI/classifier.py (Classifier.__init__): Add the map as
7825     parameter so we can subscribe to some of its messages
7826     (Classifier.__init__): Subscribe to the map's MAP_LAYERS_REMOVED
7827     and the layer's LAYER_SHAPESTORE_REPLACED
7828     (Classifier.unsubscribe_messages): New. Unsubscribe from message
7829     subscribed to in __init__
7830     (Classifier.map_layers_removed)
7831     (Classifier.layer_shapestore_replaced): receivers for the messages
7832     subscribed to in __init__. Unsubscribe and close the dialog
7833    
7834     * Thuban/UI/mainwindow.py (MainWindow.OpenLayerProperties): Pass
7835     the map to the Classifier dialog
7836    
7837     * test/test_layer.py (SetShapeStoreTests): Derive from
7838     SubscriberMixin as well so we can test messages
7839     (SetShapeStoreTests.setUp): Subscribe to some of the layer's
7840     messages
7841     (SetShapeStoreTests.tearDown): Clear the messages again
7842     (SetShapeStoreTests.test_sanity): Expand the doc-string and check
7843     for the modified flag too
7844     (SetShapeStoreTests.test_set_shape_store_modified_flag): New test
7845     to check whether SetShapeStore sets the modified flag
7846     (SetShapeStoreTests.test_set_shape_store_different_field_name)
7847     (SetShapeStoreTests.test_set_shape_store_same_field)
7848     (SetShapeStoreTests.test_set_shape_store_same_field_different_type):
7849     Add tests for the messages. This checks both the new
7850     LAYER_SHAPESTORE_REPLACED and the older LAYER_CHANGED
7851    
7852 jan 1141 2003-06-06 Jan-Oliver Wagner <[email protected]>
7853    
7854     * Thuban/UI/mainwindow.py: Improved and partly added help texts for
7855     the menu items.
7856    
7857 frank 1134 2003-06-05 Frank Koormann <[email protected]>
7858    
7859 frank 1139 * Thuban/UI/identifyview.py (IdentifyView.__init__):
7860     Layout reimplemented without panel. Make life easier to fit the list
7861     in the dialog.
7862    
7863     2003-06-05 Frank Koormann <[email protected]>
7864    
7865 frank 1137 * Thuban/UI/projdialog.py (ProjFrame.__init__): Fill the projchoice
7866     once on initialisation (Former implementation resulted in multiple
7867     entries for each projection).
7868     (ProjFrame.__FillAvailList): selectProj as second optional parameter,
7869     if set, select the projection found under the specified name. This
7870     overwrites any other selection estimate.
7871     Removed projchoice filling from this method.
7872     (ProjFrame._OnSave, ProjFrame._OnAddToList):
7873     Updated call of ProjFrame.__FillAvailList
7874     (LCCPanel._DoLayout): Moved parameter controls in more common order.
7875    
7876     * Resources/Projections/defaults.proj: Extended defaults representing
7877     various common European projections.
7878    
7879     2003-06-05 Frank Koormann <[email protected]>
7880    
7881 frank 1134 * Thuban/UI/identifyview.py (IdentifyView.__init__):
7882     Use ListCtrl instead of GridCtrl
7883    
7884     * Thuban/Model/resource.py:
7885     Guess location of .thuban directory from tempdir parent directory.
7886    
7887     * Thuban/UI/application.py (ThubanApplication.read_startup_files):
7888     Guess location of .thuban directory from tempdir parent directory.
7889    
7890 bh 1130 2003-06-04 Bernhard Herzog <[email protected]>
7891    
7892     Do not cache the values returned by the tree widget's
7893     GetFirstChild and GetNextChild methods because it led to lots of
7894     segfaults. The new way requires more brute force but is more
7895     reliable.
7896    
7897     * Thuban/UI/legend.py (LegendTree.__init__): Remove instance
7898     variable layer2id
7899     (LegendTree.find_layer): New method to do with brute force what
7900     layer2id tried to accomplish
7901     (LegendTree._OnMsgLayerChanged)
7902     (LegendTree._OnMsgLayerTitleChanged, LegendTree.__ShowHideLayer):
7903     Use find_layer instead of layer2id
7904     (LegendTree.__RemoveLayer, LegendTree.__AddLayer): No need to
7905     update layer2id anymore
7906     (LegendTree._OnMsgMapLayersRemoved)
7907     (LegendTree._OnMsgMapLayersAdded): Get by without layer2id.
7908    
7909 tkoester 1128 2003-06-03 Thomas Koester <[email protected]>
7910    
7911     * Thuban/Model/classgen.py (GenQuantiles0): New function.
7912    
7913 bh 1120 2003-06-02 Bernhard Herzog <[email protected]>
7914    
7915 bh 1127 * Thuban/UI/mainwindow.py (layer_rename command, table_rename command):
7916     New commands.
7917     (main_menu): Add the new commands.
7918     (MainWindow.TableRename): New. Implementation of the table_rename
7919     command.
7920     (MainWindow.RenameLayer): New. Implementation of the layer_rename
7921     command.
7922    
7923     * Thuban/Model/session.py (Session.AddTable): call self.changed to
7924     set the modified flag
7925    
7926     * test/test_session.py (TestSessionSimple.test_add_table): Test
7927     whether the modified flag is set properly
7928    
7929     * Thuban/Model/base.py (TitledObject.SetTitle): Call changed
7930     instead of issue so that the modified flags get updated.
7931    
7932     * test/test_base.py (SomeTitledObject): Derive from Modifiable
7933     instead of Publisher to reflect reality better and to accomodate
7934     the fact that SetTitle now calls changed instead of issue
7935    
7936     2003-06-02 Bernhard Herzog <[email protected]>
7937    
7938     * Thuban/UI/classgen.py (GenQuantilesPanel.GetList): Resource
7939     acquisition has to happen before the try in a try-finally.
7940    
7941     2003-06-02 Bernhard Herzog <[email protected]>
7942    
7943 bh 1120 * Thuban/UI/legend.py (LegendTree._OnMsgMapLayersRemoved): It's
7944     possible that a layer is removed that is not currently selected in
7945     the legend so don't check for this.
7946    
7947 bh 1112 2003-05-30 Bernhard Herzog <[email protected]>
7948    
7949 bh 1118 * Thuban/Model/layer.py (Layer.Destroy): Set all instance
7950     variables to None that have direct or indirect references to
7951     shapefiles or dbf files to make sure that they do go away and the
7952     files are closed.
7953    
7954     2003-05-30 Bernhard Herzog <[email protected]>
7955    
7956 bh 1116 * Thuban/UI/legend.py (LegendTree.GetRootItem): Reset
7957     availImgListIndices when a new image list is created
7958    
7959     2003-05-30 Bernhard Herzog <[email protected]>
7960    
7961 bh 1114 * Thuban/UI/legend.py (LegendTree.__init__): New instance variable
7962     changing_selection to indicate whether the LegendTree code itself
7963     is currently changing the selection
7964     (LegendTree.normalize_selection): New method to normalize the
7965     selection by selecting the layer item even if the user clicked on
7966     the classification.
7967     (LegendTree._OnSelChanged): normalize the selection. This works
7968     around a bug in wx which doesn't keep track of the selection
7969     properly when subtrees are deleted.
7970    
7971     2003-05-30 Bernhard Herzog <[email protected]>
7972    
7973 bh 1112 * Thuban/UI/view.py (MapCanvas.set_view_transform): Limit the
7974     maximum and minimum scale factors.
7975    
7976     * test/test_classgen.py (ClassGenTest.test): Update to reflect the
7977     changes in classgen.py
7978    
7979 jonathan 1109 2003-05-30 Jonathan Coles <[email protected]>
7980    
7981     * Thuban/Model/classgen.py: Remove ClassGenerator class but make
7982     all the methods functions. Fixes RTBug #1903.
7983    
7984     * Thuban/Model/map.py (Map.TopLayer, Map.BottomLayer): Renamed
7985     to MoveLayerToTop and MoveLayerToBottom respectively. Fixes
7986     RTBug #1907.
7987    
7988     * Thuban/UI/classgen.py: Use classgen functions that were part
7989     of the ClassGenerator class. Put try/finally blocks around
7990     code that uses wxBeginBusyCursor()/wxEndBusyCursor(). Fixes
7991     RTBug #1904.
7992    
7993     * Thuban/UI/classifier.py: Remove unused import of ClassGenerator.
7994    
7995     * Thuban/UI/legend.py: The legend was cleared and repopulated any
7996     time something changed which caused some state to be lost such
7997     as which children were expanded or collapsed. Fixes RTBug #1901.
7998     (LegendTree._OnMsgMapLayersAdded): Add only new layers.
7999     (LegendTree.__OnMsgMapLayersRemoved): Remove layers that exist in
8000     the legend but not in the map.
8001     (LegendTree.__FillTree): Move main functionality out into smaller
8002     methods that can be used by other methods.
8003     (LegendTree.__FillTreeLayer): Reuse old slots in the image list
8004     if they are available.
8005     (LegendTree.DeleteAllItems): Renamed from __DeleteAllItems so
8006     that we override the wxTreeCtrl method. Iterate over children
8007     and call __RemoveLayer.
8008     (LegendTree.__AddLayer): New. Add a new layer to the legend.
8009     (LegendTree.__RemoveLayer): Remove a layer from the legend.
8010     (LegendTree.DeleteChildren): New, overrides wxTreeCtrl method.
8011     Should only be called with the id of a layer branch.
8012     (LegendTree.GetRootItem): New, overrides wxTreeCtrl method.
8013     Returns the root item or creates one if necessary.
8014    
8015     * Thuban/UI/renderer.py (MapRenderer.draw_raster_layer): Call
8016     ProjectRasterFile with tuple arguments instead of strings.
8017    
8018     * Thuban/UI/tableview.py (QueryTableFrame.OnQuery): Wrap code
8019     with try/finally. Fixes RTBug #1904.
8020    
8021     * Thuban/UI/view.py (MapCanvas.OnPaint): Wrap code
8022     with try/finally. Fixes RTBug #1904.
8023     (MapCanvas.FitSelectedToWindow): If a single point is selected
8024     simply center it on the display. Fixes RTBug #1849.
8025    
8026     * extensions/thuban/gdalwarp.cpp: Removed code that allowed gdalwarp
8027     to be compiled as a standalone app. Now the code can only be
8028     called from Python which simplifies the parameter passing.
8029     (ProjectRasterFile): Handle Python arguments. Remove code that
8030     checks for a destination dataset. Add more clean up code.
8031    
8032     * test/test_map.py (TestMapWithContents.test_raise_layer_top,
8033     TestMapWithContents.test_lower_layer_bottom):
8034     Test Map.MoveLayerToTop() and Map.MoveLayerToBottom() respectively.
8035     Fixes RTBug #1907.
8036    
8037     * Thuban/UI/mainwindow.py (MainWindow.ToggleLegend): Apply a full
8038     extent to the map when the legend is toggled. Fixes RTBug #1881.
8039    
8040 jan 1097 2003-05-29 Jan-Oliver Wagner <[email protected]>
8041    
8042     * Thuban/UI/tableview.py (LayerTableFrame.OnClose): Bug-fix: Now
8043     unsubscribes all that is subcribed in __init__.
8044    
8045 bh 1089 2003-05-28 Bernhard Herzog <[email protected]>
8046    
8047 bh 1095 * Thuban/UI/mainwindow.py (MainWindow.DuplicateLayer)
8048     (MainWindow.CanDuplicateLayer): New methods to implement the
8049     Layer/Duplicate command.
8050     (layer_duplicate command): New.
8051     (main_menu): Add layer_duplicate to the Layer menu.
8052    
8053     2003-05-28 Bernhard Herzog <[email protected]>
8054    
8055 bh 1093 * Thuban/UI/tableview.py (NullRenderer.Draw): New. Our own
8056     renderer so that NULL/None values get displayed differently (by a
8057     gray rectangle).
8058     (TableGrid.__init__): Override the default renderers
8059    
8060     2003-05-28 Bernhard Herzog <[email protected]>
8061    
8062 bh 1089 * Thuban/Model/layer.py (Layer.SetShapeStore): Set the
8063     classification to "None" if the type of the field has changed.
8064    
8065     * test/test_layer.py (SetShapeStoreTests): New. Class with a few
8066     test for the Layer.SetShapeStore method
8067    
8068 jan 1087 2003-05-28 Jan-Oliver Wagner <[email protected]>
8069 jan 1085
8070 jan 1087 * Thuban/Model/layer.py (Layer.TreeInfo): Fixed a bug (a layer
8071     does not necessarily have a filename).
8072    
8073     2003-05-28 Jan-Oliver Wagner <[email protected]>
8074    
8075 jan 1085 * Thuban/UI/mainwindow.py (MainWindow.TableClose, MainWindow.TableShow):
8076     sort the selection list for the dialog.
8077    
8078 frank 1083 2003-05-28 Frank Koormann <[email protected]>
8079    
8080     * extensions/thuban/wxproj.cpp
8081     (project_point): Removed cast to int for projected point coordinates.
8082     (shape_centroid): Return last point if all polygon vertices fall
8083     to one point.
8084    
8085 bh 1079 2003-05-28 Bernhard Herzog <[email protected]>
8086    
8087 bh 1081 * Thuban/UI/mainwindow.py (_can_unjoin): Add doc-string and cope
8088     with layers that don't have shapestores, i.e. raster layers.
8089    
8090     2003-05-28 Bernhard Herzog <[email protected]>
8091    
8092 bh 1079 * Thuban/Model/table.py (DBFTable.__init__): Omit the extension
8093     when determining the title from the filename.
8094    
8095     * test/test_dbf_table.py (TestDBFTable.test_title): Update to
8096     reflect changes in the way the title is derived from the filename
8097    
8098 frank 1077 2003-05-28 Frank Koormann <[email protected]>
8099    
8100     * Thuban/UI/mainwindow.py (MainWindow.TableShow):
8101     Added wxDEFAULT_DIALOG_STYLE to show table dialog styles.
8102    
8103 bh 1069 2003-05-27 Bernhard Herzog <[email protected]>
8104    
8105 bh 1075 * Thuban/UI/mainwindow.py (MainWindow.delegated_messages): Also
8106     delegate SelectedLayer.
8107     (MainWindow.LayerUnjoinTable): Implement.
8108     (_can_unjoin): New. Helper function for the sensitivity of the
8109     layer/unjoin command.
8110    
8111     * Thuban/Model/data.py (ShapefileStore.OrigShapeStore)
8112     (DerivedShapeStore.OrigShapeStore): New. Return the original
8113     shapestore. Used to figure out how to unjoin.
8114     (DerivedShapeStore.Shapefile): Fix a typo.
8115    
8116     2003-05-27 Bernhard Herzog <[email protected]>
8117    
8118 bh 1073 * Thuban/UI/join.py (JoinDialog): Extend to handle layer joins as
8119     well
8120     (JoinDialog.__init__): Use the layer parameter and only build the
8121     left choice when a layer is given
8122     (JoinDialog.OnJoin): Handle layer joins as well
8123     (JoinDialog.OnLeftTable, JoinDialog.OnRightTable): Handle the case
8124     that the user selects the "Select..." item. The sensitivitly
8125     updating is now in update_sensitivity
8126     (JoinDialog.y): New method to refactor the sensitivity update of
8127     the join button into its own method.
8128    
8129     * Thuban/UI/mainwindow.py (MainWindow.LayerJoinTable): Implement.
8130    
8131     2003-05-27 Bernhard Herzog <[email protected]>
8132    
8133 bh 1071 * Thuban/UI/mainwindow.py (table_close command): Make it sensitive
8134     iff there are unreferenced tables in the session
8135    
8136     2003-05-27 Bernhard Herzog <[email protected]>
8137    
8138 bh 1069 * Thuban/Model/messages.py (TABLE_REMOVED): New message.
8139    
8140     * Thuban/Model/session.py (Session.UnreferencedTables): New method
8141     to return tables that are not referenced by other tables or shape
8142     stores and can be removed.
8143     (Session.RemoveTable): Issue a TABLE_REMOVED message after
8144     removing the table
8145    
8146     * Thuban/UI/mainwindow.py: Remove unused imports
8147     (MainWindow.TableClose): Implement.
8148    
8149     * Thuban/UI/tableview.py (TableFrame.__init__): Subscribe to some
8150     messages so that the frame will be automatically closed when a new
8151     session is opened or the table is removed.
8152     (TableFrame.OnClose): Unsubscribe the Subscriptions made in
8153     __init__
8154     (TableFrame.close_on_session_replaced)
8155     (TableFrame.close_on_table_removed): New. Subscribers that close
8156     the window
8157    
8158     * test/test_session.py (TestSessionMessages.test_remove_table)
8159     (TestSessionSimple.test_remove_table): Move the test to
8160     TestSessionSimple and add test for the TABLE_REMOVED message
8161     (TestSessionBase.setUp): Also subscribe to TABLE_REMOVED
8162     (TestSessionSimple.test_unreferenced_tables) New. Test for the
8163     UnreferencedTables method.
8164     (UnreferencedTablesTests): New. Class with some more sophisticated
8165     tests for UnreferencedTables.
8166    
8167 frank 1065 2003-05-27 Frank Koormann <[email protected]>
8168    
8169 frank 1067 * Thuban/UI/tableview.py (QueryTableFrame.__init__): The "_S_election"
8170     display has some unwanted side effects. Removed again.
8171    
8172     2003-05-27 Frank Koormann <[email protected]>
8173    
8174 frank 1065 * Resources/Bitmaps/legend_icon_layer.xpm: New, icon for legend.
8175    
8176     * Thuban/UI/legend.py (LegendTree.__FillTree): Use "legend_icon_layer"
8177    
8178 jan 1062 2003-05-27 Jan-Oliver Wagner <[email protected]>
8179    
8180 bh 1069 * test/test_menu.py (MenuTest.test): Added test for
8181     Menu.RemoveItem().
8182 jan 1062
8183 bh 1069 * Thuban/UI/menu.py (Menu.RemoveItem): New. Remove an item from
8184     the menu.
8185 jan 1062
8186 frank 1059 2003-05-27 Frank Koormann <[email protected]>
8187    
8188     Nonmodal dialogs without parent (i.e. they can fall behind the main
8189     window)
8190    
8191     * Thuban/UI/mainwindow.py (MainWindow.OnClose): Explicitly destroy
8192     all dialogs in the dialogs dictionary and the canvas.
8193    
8194     * Thuban/UI/dialogs.py (NonModalNonParentDialog): New class, without
8195     parent, i.e. can fall behind other windows.
8196     (NonModalDialog.OnClose): Check is dialog is in mainwindow.dialog
8197     dictionary before removing it.
8198    
8199     * Thuban/UI/classifier.py: Dialog derived from NonModalNonParentDialog
8200    
8201     * Thuban/UI/projdialog.py: Dialog derived from NonModalNonParentDialog
8202     * Thuban/UI/tableview.py: Dialog derived from NonModalNonParentDialog
8203     * Thuban/UI/tree.py: Dialog derived from NonModalNonParentDialog
8204    
8205 bh 1053 2003-05-27 Bernhard Herzog <[email protected]>
8206    
8207 bh 1055 * Thuban/UI/mainwindow.py (MainWindow.ShowTableView): New. Open a
8208     tableview dialog
8209     (MainWindow.TableShow): Use ShowTableView to open the dialogs.
8210     Also, don't use the table's titles as the dialog names. The titles
8211     aren't guaranteed to be unique.
8212     (MainWindow.TableOpen): Open a table view dialog after opening the
8213     table
8214    
8215     2003-05-27 Bernhard Herzog <[email protected]>
8216    
8217 bh 1053 * Thuban/UI/mainwindow.py: Remove the Table/Hide menu item. Its
8218     effect can be achieved by simply closing the window showing the
8219     table.
8220     (MainWindow.TableHide): Removed.
8221     (main_menu): Removed "table_hide"
8222    
8223 frank 1051 2003-05-27 Frank Koormann <[email protected]>
8224    
8225     Fix legend tree display problems under Win32
8226    
8227     * Thuban/UI/legend.py: BMP_SIZE_W = 15
8228     (LegendTree.__FillTree): Display "legend_icon_map.xpm" with layer title.
8229     (LegendTree.__FillTreeLayer): Explicitely set SelectedImage.
8230    
8231     * Resources/Bitmaps/legend_icon_map.xpm: New icon for legend.
8232    
8233 jan 1048 2003-05-27 Jan-Oliver Wagner <[email protected]>
8234    
8235     * Thuban/UI/menu.py (Menu.InsertSeparator): Additional optional parameter
8236     'after' now allows to insert separators almost anywhere in the menu.
8237    
8238 frank 1046 2003-05-27 Frank Koormann <[email protected]>
8239    
8240     * Thuban/UI/tableview.py (QueryTableFrame.__init__): Underline the
8241     "S" of selection box label to hint on hot key (Alt-S). Works under
8242     Win32 but is ignored under GTK.
8243    
8244     2003-05-26 Frank Koormann <[email protected]>
8245    
8246     * Thuban/UI/projdialog.py (ProjFrame.__do_layout, ProjPanel._DoLayout):
8247     Center Choices.
8248    
8249 bh 1038 2003-05-26 Bernhard Herzog <[email protected]>
8250    
8251 bh 1044 Remove the Precision methods again. They're too DBF specific to be
8252     part of the table interface and they're only used in table_to_dbf
8253     anyway.
8254    
8255     * Thuban/Model/transientdb.py (TransientTableBase.Width):Use a
8256     fixed precision of 12 for doubles.
8257     (TransientTableBase.Precision): Removed
8258     (AutoTransientTable.Width): Delegate to self.table.
8259    
8260     * Thuban/Model/table.py (DBFTable.Precision)
8261     (MemoryTable.Precision): Removed.
8262     (MemoryTable.Width): Use a fixed precision of 12 for doubles.
8263     (table_to_dbf): Use a fixed precision of 12 for floats unless the
8264     column object specifies something else.
8265    
8266     * test/test_dbf_table.py (TestTableToDBF.test_table_to_dbf): New.
8267     test for table_to_dbf
8268    
8269     2003-05-26 Bernhard Herzog <[email protected]>
8270    
8271     * test/test_transientdb.py
8272     (TestTransientTable.run_iceland_political_tests): Fix a comment.
8273    
8274     2003-05-26 Bernhard Herzog <[email protected]>
8275    
8276 bh 1038 * Thuban/UI/mainwindow.py (MainWindow.TableOpen): Real
8277     implementation. Mark parts of the file format strings for
8278     localization.
8279    
8280     * Thuban/Model/session.py (Session.OpenTableFile): New. Open a dbf
8281     file and add the table to the tables managed by the session
8282    
8283 bh 1040 * test/test_session.py (TestSessionSimple.test_open_table_file):
8284     New. test case for OpenTableFile
8285    
8286 jan 1033 2003-05-26 Jan-Oliver Wagner <[email protected]>
8287    
8288 jan 1035 * Thuban/UI/controls.py, Thuban/UI/identifyview.py, Thuban/UI/join.py,
8289     Thuban/UI/labeldialog.py, Thuban/UI/mainwindow.py,
8290     Thuban/UI/proj4dialog.py, Thuban/UI/tableview.py, Thuban/UI/view.py:
8291     Replace the true/false of wxWindows by True/False of Python 2.2.1.
8292    
8293     2003-05-26 Jan-Oliver Wagner <[email protected]>
8294    
8295 bh 1038 * Thuban/UI/tableview.py (LayerTableFrame.__init__): If there is
8296     already a selection present, update the grid accordingly.
8297 jan 1033
8298     * Thuban/UI/mainwindow.py (MainWindow.TableShow): Make the dialog
8299     resizeable and increase its initial size.
8300    
8301 frank 1030 2003-05-26 Frank Koormann <[email protected]>
8302    
8303     Table export functionality
8304    
8305     * Thuban/Model/table.py (DBFTable.Width, MemoryTable.Width):
8306     Return width (in characters) for a column.
8307     (DBFTable.Precision, MemoryTable.Precision): Return decimal precision.
8308     (table_to_dbf): Write table to dbf file.
8309     (table_to_csv): Write table to csv file.
8310    
8311     * Thuban/Model/transientdb.py (TransientTableBase.Width,
8312     TransientTableBase.Precision): Return column width and precision.
8313    
8314     * Thuban/UI/tableview.py (QueryTableFrame.OnSaveAs): Call table_to_dbf
8315     or table_to_csv depending on file selection.
8316    
8317     * test/test_dbf_table.py:
8318     Test table_to_dbf (extension of former part of test).
8319    
8320     * test/test_csv_table.py:
8321     Test table_to_csv.
8322    
8323 jan 1021 2003-05-23 Jan-Oliver Wagner <[email protected]>
8324    
8325 jan 1024 * Thuban/UI/join.py (JoinDialog.OnJoin): Use _() for strings.
8326     Use QueryTableFrame instead of TableFrame.
8327 jan 1021
8328 jan 1024 * Thuban/UI/mainwindow.py (MainWindow.LayerShowTable): Prefix the
8329     table window with 'Layer Table:' instead of 'Table:'.
8330    
8331     2003-05-23 Jan-Oliver Wagner <[email protected]>
8332    
8333     Give all tables a title via mix-in TitledObject.LayerShowTable
8334    
8335 jan 1021 * Thuban/Model/base.py (TitledObject.SetTitle): Call method 'issue'
8336     only if it exists.
8337    
8338     * Thuban/Model/table.py (DBFTable, MemoryTable): mix-in TitledObject
8339     and call its init-method with a default title. Remove Title() method.
8340    
8341     * Thuban/Model/transientdb.py (TransientTable, TransientJoinedTable,
8342     AutoTransientTable): mix-in TitledObject and call its init-method with
8343     a default title. Remove Title() method.
8344    
8345 bh 1017 2003-05-23 Bernhard Herzog <[email protected]>
8346    
8347     * Thuban/Model/session.py (Session.AddShapeStore): Define
8348     AddShapeStore analogously to AddTable.
8349    
8350     * test/test_session.py (TestSessionSimple.test_add_shapestore):
8351     New. Test for AddShapeStore
8352    
8353 jan 1015 2003-05-23 Jan-Oliver Wagner <[email protected]>
8354    
8355     Introducing QueryTableFrame and a very coarse ShowTable implementation.
8356    
8357     * Thuban/UI/tableview.py (LayerTableFrame, QueryTableFrame): Split the
8358     class LayerTableFrame into two classes, LayerTableFrame and QueryTableFrame.
8359     The latter implements the selection GUI without dependency on a layer.
8360     LayerTableFrame now is derived from QueryTableFrame and connects
8361     to a layer.
8362    
8363     * Thuban/UI/mainwindow.py (MainWindow.TableShow): A very coarse
8364     implementation that still needs work.
8365    
8366     * Thuban/Model/layer.py (Layer.TreeInfo): Added filename.
8367    
8368 frank 1011 2003-05-22 Frank Koormann <[email protected]>
8369    
8370     * Thuban/Model/transientdb.py (TransientJoinedTable.__init__):
8371     Added "outer_join = False" as optional parameter.
8372     (TransientJoinedTable.create): If outer join is true, perform a
8373     "LEFT OUTER JOIN" instead of "JOIN", which preserves all records of
8374     the left table. Records not matching are filled with 0 / None.
8375    
8376     * Thuban/UI/join.py (JoinDialog.__init__): Checkbox for outer join.
8377     (JoinDialog.OnJoin): Consider outer join check box.
8378    
8379 bh 1006 2003-05-22 Bernhard Herzog <[email protected]>
8380    
8381 bh 1008 * Thuban/UI/join.py (JoinDialog.OnJoin): Use exc_info in a
8382     somewhat safer way. Storing the traceback in a local variable can
8383     lead to memory leaks
8384    
8385     2003-05-22 Bernhard Herzog <[email protected]>
8386    
8387 bh 1006 * Thuban/UI/join.py (JoinDialog.OnJoin): Make sure to really call
8388     the wxMessageDialog's Destroy() method.
8389    
8390 frank 1004 2003-05-22 Frank Koormann <[email protected]>
8391    
8392     * Thuban/UI/join.py (JoinDialog.__init__): Make use of
8393     TransientTable.Title()
8394    
8395     2003-05-22 Frank Koormann <[email protected]>
8396    
8397     Join Dialog, initial version.
8398    
8399     * Thuban/UI/mainwindow.py (MainWindow.TableJoin): Removed print.
8400    
8401     * Thuban/UI/join.py (JoinDialog): Functional implementation of
8402     former framework. Renamed Table1/Table2 to LeftTable/RightTable
8403     in all occurences.
8404    
8405     * Thuban/Model/transientdb.py (TransientJoinedTable.__doc__):
8406     Typo fixed.
8407    
8408 bh 995 2003-05-22 Bernhard Herzog <[email protected]>
8409    
8410 bh 999 Give the tables titles so that the GUI can display more meaningful
8411     names. For now the titles are fixed but depend on e.g. filenames
8412     or the titles of the joined tables.
8413    
8414     * Thuban/Model/transientdb.py (TransientTable.Title)
8415     (TransientJoinedTable.Title, AutoTransientTable.Title): New.
8416    
8417     * Thuban/Model/table.py (DBFTable.Title, MemoryTable.Title): New.
8418    
8419     * test/test_transientdb.py
8420     (TestTransientTable.test_auto_transient_table_title): New. Test
8421     for the Title method
8422     (TestTransientTable.test_transient_joined_table)
8423     (TestTransientTable.test_transient_table): Add test for the Title
8424     methods
8425    
8426     * test/test_memory_table.py (TestMemoryTable.test_title): New.
8427     Test for the Title method
8428    
8429     * test/test_dbf_table.py (TestDBFTable.test_title): New. Test for
8430     the Title method
8431    
8432     2003-05-22 Bernhard Herzog <[email protected]>
8433    
8434 bh 997 * test/test_layer.py (TestLayer.setUp, TestLayer.tearDown):
8435     Provide a better way to destroy the layers
8436     (TestLayer.test_base_layer, TestLayer.test_arc_layer)
8437     (TestLayer.test_point_layer, TestLayer.test_empty_layer)
8438     (TestLayer.test_polygon_layer, TestLayer.test_get_field_type): Use
8439     the new way to destroy the layers.
8440     (TestLayer.test_derived_store): New. Test for using a layer with a
8441     DerivedShapeStore
8442    
8443     * Thuban/Model/layer.py (Layer.SetShapeStore): Only set the
8444     filename if the shape store actually has one.
8445    
8446     2003-05-22 Bernhard Herzog <[email protected]>
8447    
8448 bh 995 * Thuban/Model/table.py (DBFTable.FileName): New. Accessor method
8449     for the filename
8450    
8451     * test/test_dbf_table.py (TestDBFTable.test_filename): New. Test
8452     for the FileName method
8453     (TestDBFTableWriting.test_write): Fix spelling of filename
8454    
8455 tkoester 993 2003-05-22 Thomas Koester <[email protected]>
8456    
8457     * Thuban/Model/range.py, test/test_range.py: Brought over new Range
8458     from SciParam that now really is immutable.
8459    
8460 frank 992 2003-05-22 Frank Koormann <[email protected]>
8461    
8462     Layer Top/Bottom placement added to legend.
8463    
8464     * Thuban/UI/legend.py
8465     (LegendPanel._OnMoveTop(), LayerPanel._OnMoveBottom): New, methods
8466     bound to tool events.
8467     (LegendTree.MoveCurrentItemTop(), LegendTree.MoveCurrentItemBottom):
8468     New, methods binding the event methods with the map methods.
8469    
8470     * Thuban/Model/map.py (Map.TopLayer(), Map.BottomLayer()): New, place
8471     layer at top/bottom of layer stack.
8472    
8473     * Resources/Bitmaps/top_layer.xpm: New button icon.
8474    
8475     * Resources/Bitmaps/bottom_layer.xpm: New button icon.
8476    
8477 bh 988 2003-05-22 Bernhard Herzog <[email protected]>
8478    
8479     * Thuban/Model/session.py (Session.RemoveTable): New method to
8480     remove tables
8481    
8482     * test/test_session.py (TestSessionSimple.test_remove_table): New.
8483     Test for RemoveTable
8484    
8485 tkoester 986 2003-05-22 Thomas Koester <[email protected]>
8486    
8487     * Thuban/Model/classgen.py: Added short module doc string and CVS id.
8488     (ClassGenerator.GenUniformDistribution): Use new Range __init__, too.
8489    
8490 bh 983 2003-05-22 Bernhard Herzog <[email protected]>
8491    
8492 bh 985 Implement a way to discover dependencies between tables and
8493     shapestores.
8494    
8495     * Thuban/Model/transientdb.py (TransientTableBase.Dependencies)
8496     (TransientJoinedTable.Dependencies)
8497     (AutoTransientTable.SimpleQuery): New. Implement the dependencies
8498     interface
8499     (TransientJoinedTable.__init__): Keep tack of the original table
8500     objects in addition to the corresponding transient tables.
8501    
8502     * Thuban/Model/table.py (DBFTable.Dependencies)
8503     (MemoryTable.Dependencies): New. Implement the dependencies
8504     interface
8505    
8506     * Thuban/Model/data.py (ShapeTable): New. Helper class for
8507     ShapefileStore
8508     (ShapefileStore.__init__): Use ShapeTable instead of
8509     AutoTransientTable
8510     (ShapefileStore.Table, ShapefileStore.Shapefile): Add doc-strings
8511     (ShapefileStore.FileName, ShapefileStore.FileType): New. Accessor
8512     methods for filename and type
8513     (ShapefileStore.Dependencies): New. Implement the dependencies
8514     interface
8515     (DerivedShapeStore): New class to replace SimpleStore. The main
8516     difference to SimpleStore is that it depends not on a shapefile
8517     but another shapestore which expresses the dependencies a bit
8518     better
8519     (SimpleStore.__init__): Add deprecation warning.
8520    
8521     * test/test_dbf_table.py (TestDBFTable.test_dependencies): New.
8522     Test for the Dependencies method.
8523    
8524     * test/test_memory_table.py (TestMemoryTable.test_dependencies):
8525     New. Test for the Dependencies method.
8526    
8527     * test/test_transientdb.py
8528     (TestTransientTable.test_auto_transient_table_dependencies): New.
8529     Test for the Dependencies method.
8530     (TestTransientTable.test_transient_joined_table): Add test for the
8531     Dependencies method.
8532    
8533     * test/test_session.py (TestSessionSimple.setUp)
8534     (TestSessionSimple.tearDown): New. Implement a better way to
8535     destroy the sessions.
8536     (TestSessionSimple.test_initial_state)
8537     (TestSessionSimple.test_add_table): Bind session to self.session
8538     so that it's destroyed by tearDown
8539     (TestSessionSimple.test_open_shapefile): New. Test for
8540     OpenShapefile and the object it returns
8541    
8542     2003-05-22 Bernhard Herzog <[email protected]>
8543    
8544 bh 983 * Thuban/Model/session.py (Session.AddTable): New method to
8545     register tables with the session.
8546     (Session.Tables): Return the tables registered with AddTable too.
8547    
8548     * test/test_session.py (TestSessionSimple.test_add_table): New.
8549     Test case for the AddTable method
8550    
8551 frank 981 2003-05-22 Frank Koormann <[email protected]>
8552    
8553     UI polishing updates: Place main buttons (OK, Cancel, etc) in the
8554     lower right corner, center labels for selections, initialize controls
8555     in reasonable order for keyboard navigation.
8556    
8557     * Thuban/UI/projdialog.py (ProjFrame.__init__, ProjFrame.__doLayout)
8558     (ProjFrame.__DoOnProjAvail): Determine position of current projection
8559     using the wxListBox.FindString() method. Still a problem (#1886)
8560    
8561     * Thuban/UI/classifier.py
8562     (Classifier.__init__, SelectPropertiesDialog.__init__)
8563    
8564     * Thuban/UI/classgen.py (ClassGenDialog.__init__,
8565     (ClassGenDialog.__DoOnGenTypeSelect): Moved initialization of the
8566     different classification types from here to __init__.
8567     (GenUniquePanel.__init__): Set the column width of the first field
8568     in the Field ListCtrl to the full width.
8569    
8570     * Thuban/UI/tableview.py (LayerTableFrame.__init__): Rename 'Save As'
8571     Button to 'Export'. Center Buttons in Selection Box, set Focus to
8572     Grid.
8573     (LayerTableFrame.OnKeyDown()): New, bound to the grid with EVT_KEY_DOWN,
8574     changes focus to the Selection when pressing "Alt-S".
8575    
8576     * Thuban/UI/legend.py (LegendTree.__SetVisibilityStyle): Only gray out
8577     the text if not visible. The italic font sometimes exceeds the
8578     rendering area.
8579    
8580 jonathan 972 2003-05-21 Jonathan Coles <[email protected]>
8581 jonathan 971
8582 jonathan 975 * Thuban/UI/dock.py (DockFrame): Rename references to _OnClose
8583     to OnClose so that Thuban closes correctly.
8584    
8585     * Thuban/UI/mainwindow.py (MainWindow.OnClose): Call
8586     DockFrame.OnClose, not DockFrame._OnClose.
8587    
8588     2003-05-21 Jonathan Coles <[email protected]>
8589    
8590 jonathan 971 * Thuban/Model/classgen.py (ClassGenerator.GenQuantiles): Remove
8591     references to 'inf' and use new Range __init__ to pass floats
8592     directly rather than converting them to strings first.
8593     Fixes RTBug #1876.
8594    
8595     * Thuban/Model/classification.py (ClassGroupRange.SetRange):
8596     Use new Range ___init__ to pass floats.
8597    
8598     * Thuban/Model/layer.py (RasterLayer.__init__): Test if the
8599     filename is a valid image file. Throw IOError otherwise.
8600    
8601     * Thuban/Model/range.py: Brought over new Range from SciParam that
8602     is immutable and has an __init__ which can accept floats.
8603    
8604     * Thuban/UI/mainwindow.py (MainWindow.AddLayer): Move OpenShapefile
8605     into try block. AddLayer doesn't throw any exceptions anymore.
8606     (MainWindow.AddRasterLayer): Move constructor of RasterLayer into
8607     try block.
8608    
8609     * Thuban/UI/projdialog.py (GeoPanel.__init__): Put Degrees as
8610     the first item in choices. Fixes RTBug #1882.
8611    
8612     * Thuban/UI/renderer.py (MapRenderer.render_map): Check if scale
8613     has gone to 0 which is a serious problem. abort.
8614     (MapRenderer.draw_raster_layer): Catch IOError seperately and
8615     print the error from GDAL.
8616    
8617     * Thuban/UI/tableview.py (TableGrid.__init__): Call
8618     ToggleEventListeners to turn on listening.
8619     (TableGrid.ToggleEventListeners): New. Turns event listening on
8620     and off so as to prevent excessive messages.
8621     (LayerTableFrame.OnQuery): Use TableGrid.ToggleEventListeners
8622     to suppress excessive messages when selecting many rows.
8623     Fixes RTBug #1880.
8624    
8625     * Thuban/UI/view.py: Added checks against if scale == 0. This
8626     is a serious problem that can occur when an image without
8627     geo data is loading and causes the map projection bounds to
8628     go to infinity. Right now, the solution is to simply try
8629     to recover.
8630    
8631     * extensions/thuban/cpl_mfile.cpp (MFILEClose): Make sure
8632     to set the MFILEReceiver attributes even if the data is NULL.
8633    
8634     * extensions/thuban/gdalwarp.cpp: Improved the error handling
8635     and passed GDAL messages back up to the Python layer. Also
8636     tried to fix some memory leaks that were present in the original
8637     utility but didn't matter because the program aborted.
8638    
8639     * test/test_range.py: Copied over tests from SciParam. Removed
8640     tests against importing. Fixes RTBug #1867.
8641    
8642 bh 958 2003-05-21 Bernhard Herzog <[email protected]>
8643    
8644     * test/test_load.py: Remove unused imports and restructure the
8645     test code
8646     (LoadSessionTest): Split into one class for each test and turn
8647     LoadSessionTest itself into the base class for all such session
8648     tests.
8649     (ClassificationTest): New base class for load tests that test
8650     classifications
8651     (TestSingleLayer, TestLayerVisibility, TestClassification)
8652     (TestLabels, TestLayerProjection, TestRasterLayer): New classes
8653     for the individual tests
8654    
8655     * test/support.py (FileLoadTestCase.filename): New base class for
8656     file loading tests
8657    
8658 jan 955 2003-05-21 Jan-Oliver Wagner <[email protected]>
8659    
8660     * Resources/Projections/defaults.proj: Renamed 'Universal Transverse
8661     Mercator' to 'UTM Zone 32' as a more convenient example.
8662     Added 'Gauss Krueger Zone 6'.
8663    
8664     * Data/iceland_sample_raster.thuban: political polygon now
8665     filled transparent to have the raster image visible at once.
8666    
8667 frank 952 2003-05-21 Frank Koormann <[email protected]>
8668    
8669     * Thuban/UI/mainwindow.py (MainWindow): Renamed _OnClose() back to
8670     OnClose() to keep in sync with extensions. Internally Thuban
8671     still uses "underscored" names.
8672    
8673 jonathan 949 2003-05-20 Jonathan Coles <[email protected]>
8674    
8675     This puts back Raster layer support. These layers support projections
8676     through the GDAL library. Currently, the CVS version is being used.
8677     There are no Debian packages available although this may change soon.
8678     A GDAL driver was extended to support writing to memory rather to
8679     files.
8680    
8681     There is still some work that needs to be done, such as some error
8682     handling when loading invalid images or when there is a problem
8683     projecting the image. This putback simply checks in the majority
8684     of the work.
8685    
8686     * setup.py: Add gdalwarp library extension.
8687    
8688     * Thuban/Model/layer.py (BaseLayer.HasClassification): New.
8689     Defaults to False, but can be overridden by subclasses if they
8690     support classification.
8691     (RasterLayer): New. Defines a new layer that represents an
8692     image.
8693    
8694     * Thuban/Model/load.py (SessionLoader.__init__): Add rasterlayer
8695     tag handler.
8696     (SessionLoader.start_layer): Encode the filename.
8697     (SessionLoader.start_rasterlayer, SessionLoader.end_rasterlayer):
8698     New. Supports reading a rasterlayer tag.
8699    
8700     * Thuban/Model/map.py (Map.BoundingBox): Fix typo in comment.
8701    
8702     * Thuban/Model/save.py (XMLWriter.encode): Don't assume that we
8703     get a string in Latin1. If we get such as string convert it to
8704     unicode first, otherwise leave if alone before encoding.
8705     (SessionSaver.write_layer): Add support for writing both Layers
8706     and RasterLayers.
8707    
8708     * Thuban/Model/transientdb.py (AutoTransientTable.SimpleQuery):
8709     The right argument may not be a string, it could also be a Column.
8710    
8711     * Thuban/UI/application.py (ThubanApplication.CreateMainWindow):
8712     Make initial window size 600x400. Fixes RTBug #1872.
8713    
8714     * Thuban/UI/classifier.py (Classifier.__init__): Rearrange how
8715     the dialog is constructed so that we can support layers that
8716     do not have classifications.
8717     (Classifier._OnTry): Only build a classification if the layer
8718     supports one.
8719    
8720     * Thuban/UI/legend.py: Change all checks that a layer is an
8721     instance of Layer into checks against BaseLayer.
8722     (LegendTree.__FillTreeLayer): Only add children to a branch if
8723     the layer supports classification.
8724    
8725     * Thuban/UI/mainwindow.py (MainWindow.NewSession,
8726     MainWindow.OpenSession): Don't proceed with an action if the
8727     user chooses Cancel when they are asked to save changes.
8728     (MainWindow.AddRasterLayer): New. Open a dialog to allow the
8729     user to select an image file. Create a new RasterLayer and add
8730     it to the map.
8731    
8732     * Thuban/UI/renderer.py (MapRenderer.render_map): Add support
8733     for rendering RasterLayer layers.
8734     (MapRenderer.draw_raster_layer): Actually method that calls
8735     the GDALWarp python wrapper and constructs an image from the
8736     data returned.
8737    
8738     * Thuban/UI/tableview.py (LayerTableFrame.__init__): Change the
8739     Choices symbols to match those used in the table query method.
8740     Replace deprecated method calls on table with new method names.
8741    
8742     * Thuban/UI/view.py (MapCanvas.set_view_transform): Try to limit
8743     how small the scale can get. This still needs more testing.
8744    
8745     * extensions/thuban/bmpdataset.cpp: New, but copied from GDAL.
8746     Provides a driver to output in .bmp format.
8747    
8748     * extensions/thuban/cpl_mfile.cpp, extensions/thuban/cpl_mfile.h:
8749     New. Provides IO routines which write to memory, rather than a file.
8750    
8751     * extensions/thuban/gdalwarp.cpp: New, but basically a direct copy
8752     of the gdalwarp utility provided in GDAL. Added function calls
8753     that can be accessed from python.
8754    
8755     * Data/iceland_sample_raster.thuban: New. Sample file that uses
8756     a raster layer.
8757    
8758     * Data/iceland/island.tfw, Data/iceland/island.tif: New. Raster
8759     layer image data.
8760    
8761     * Doc/thuban.dtd: Added rasterlayer attribute definition.
8762    
8763     * test/test_layer.py, test/test_load.py, test/test_save.py: Added
8764     tests associated with the raster layer code.
8765    
8766     * test/test_transientdb.py
8767     (TestTransientTable.test_auto_transient_table_query): Added a test
8768     for using a Column object as the "right" parameter to a query.
8769    
8770 frank 924 2003-05-19 Frank Koormann <[email protected]>
8771    
8772 frank 927 * Thuban/version.py (get_changelog_date):
8773     Catch exceptions if ChangeLog does not exist.
8774    
8775     * Thuban/UI/view.py (MapCanvas.Export): Bugfix
8776    
8777     2003-05-19 Frank Koormann <[email protected]>
8778    
8779 frank 924 Extended version information for Thuban
8780    
8781     * Thuban/version.py: New, version information for Thuban: Last
8782     modification date and last ChangeLog entry date.
8783    
8784     * Thuban/UI/mainwindow.py (MainWindow.About()): Extended version
8785     information: Display Thuban, wxPython and Python version.
8786    
8787 bh 919 2003-05-16 Bernhard Herzog <[email protected]>
8788    
8789 bh 921 * Thuban/Model/save.py: Remove some unused imports including the
8790     __future__ import for nested_scopes as Thuban relies on Python 2.2
8791     now.
8792     (XMLWriter.encode): Remove the special case for a None argument.
8793     In the saver encode is always called with a string argument.
8794    
8795     2003-05-16 Bernhard Herzog <[email protected]>
8796    
8797 bh 919 * Thuban/UI/__init__.py: Remove the work-around for the locale bug
8798     in wxPython (at least when usinvg wxGTK) prior to 2.4. The symptom
8799     of the bug was that e.g. float("1.2") would fail. Thuban now
8800     requires 2.4.x.
8801    
8802 frank 917 2003-05-16 Frank Koormann <[email protected]>
8803    
8804     Printing enhancement and WMF export (under Win32)
8805    
8806     * Thuban/UI/renderer.py (ExportRenderer): New, derived from
8807     ScreenRenderer. Renders Map, Legend and Scalebar for export.
8808     (PrinterRenderer): New, derived from ExportRenderer. Replaces the old
8809     PrintRender.
8810    
8811     * Thuban/UI/view.py (MapPrintout.__init__): Enhanced parameter set
8812     to fullfil information needed for PrinterRenderer.
8813     (MapCanvas.Export): New. Export Map (currently only to WMF on Win32).
8814     (MapCanvas.Print): Adapted to new MapPrintout.
8815     (OutputTransform): General calculations to transform from canvas
8816     coordinates to export/printing devices.
8817    
8818     * Thuban/UI/mainwindow.py (MainWindow.ExportMap()): New. Added also
8819     new method_command to call ExportMap, with platform dependency (only
8820     __WXMSW__)
8821    
8822     * Thuban/UI/scalebar.py (ScaleBar.DrawScaleBar): Position and Size
8823     of scalebar drawing area as new parameters.
8824    
8825     * Thuban/Model/scalebar.py (roundInterval): round long instead of int
8826    
8827     * Thuban/UI/legend.py (ScalebarBitmap.__SetScale):
8828     Update to extended scalebar.DrawScalebar header.
8829    
8830     * test/test_export.py: New, test Thuban.UI.view.OutputTransform()
8831    
8832     * test/test_scalebar.py: Made test executable as standalone.
8833    
8834 bh 908 2003-05-16 Bernhard Herzog <[email protected]>
8835    
8836     * Thuban/Model/table.py (Table): Remove this compatibility alias
8837     for DBFTable.
8838    
8839     * test/test_table.py: Import DBFTable as Table because that alias
8840     doesn't exist anymore.
8841    
8842     * Thuban/UI/classgen.py: Remove some unused imports
8843    
8844 jonathan 906 2003-05-14 Jonathan Coles <[email protected]>
8845    
8846     * Thuban/Model/classgen.py (ClassGenerator.GenSingletonsFromList):
8847     Fix docstring.
8848     (ClassGenerator.GenUniformDistribution): Fix spelling of method name.
8849     (ClassGenerator.GenQuantiles): Use the left/right brackets and min/max
8850     values of the supplied range to determine the beginning and end
8851     bounds of the generated classes.
8852    
8853     * Thuban/Model/range.py (Range.number_re): Now accepts floats that
8854     do not have a leading 0 (.5 is now accepted as well as 0.5).
8855    
8856     * Thuban/UI/classgen.py (ClassGenDialog.OnOK): Fix name of method
8857     call to ClassGenerator.GenUniformDistribution.
8858    
8859     * Thuban/UI/projdialog.py (ProjFrame.__do_layout): Fix Windows
8860     layout bug with the 'Projection' label.
8861    
8862     * test/support.py (FloatTestCase): New. Needed for the Range tests.
8863    
8864     * test/test_range.py: New. Imported from SciParam.
8865    
8866 jonathan 897 2003-05-12 Jonathan Coles <[email protected]>
8867    
8868 jonathan 899 * Thuban/UI/classgen.py (GenQuantilesPanel.GetList): Replace call
8869     to table.UniqueValues() with calls that retrieve all the values
8870     from the table. This will need to be replaced by a method on table
8871     which can simply return the list (perhaps more efficiently).
8872    
8873     2003-05-12 Jonathan Coles <[email protected]>
8874    
8875 jonathan 897 The return value of ClassGenerator.CalculateQuantiles has changed.
8876     Refer to the documentation for details.
8877    
8878     * test/test_classgen.py: Modified Quantile tests to use the
8879     new return values.
8880    
8881     * Thuban/Model/classgen.py
8882     (ClassGenerator.GenQuantiles): Add comments describing the parameters,
8883     use new return values from CalculateQuantiles to produce the correct
8884     range bounds in the Classification.
8885     (ClassGenerator.CalculateQuantiles): Add more comments describing
8886     the return values and parameters. Make minor adjustments to improve
8887     the legibility of the code. Fix problem with adjusted not being set
8888     in most cases.
8889    
8890 frank 893 2003-05-12 Frank Koormann <[email protected]>
8891    
8892     * Thuban/Model/save.py (XMLWriter.encode()): Explicite call to unicode
8893     and latin1. Fixes #1851 finally.
8894    
8895 jonathan 889 2003-05-09 Jonathan Coles <[email protected]>
8896    
8897 jonathan 897 * test/test_classgen.py: New. Tests the Quantile algorithm.
8898    
8899     * Thuban/Model/classgen.py (ClassGenerator.CalculateQuantiles):
8900     Clean up debugging statement, add comments, fix a small bug in the
8901     returned adjusted percentiles.
8902    
8903     2003-05-09 Jonathan Coles <[email protected]>
8904    
8905 jonathan 889 Introduces Range class from SciParam into the ClassGroupRange class,
8906     and such ranges can now be saved and loaded from disk.
8907    
8908     Quantiles are now available in the Classification Generator.
8909    
8910     Initial support for building Queries on a table. Doesn't do anything
8911     but run some tests.
8912    
8913     * Thuban/Model/classification.py: Explicit imports.
8914     (ClassGroupRange): Use the Range class to store the underlying
8915     range information. The interface remains the same, except for
8916     GetRange(), and you can also supply a Range object as the min
8917     parameter to SetRange or __init__.
8918    
8919     * Thuban/Model/load.py (XMLReader.encode): New. Encodes the given
8920     string appropriately for use in Thuban. Fixes RTbug #1851.
8921     (SessionLoader.end_projection): Handle the context of the
8922     projection tag a bit better by looking at what objects are not
8923     None. There was an assumption that a projection tag for a map
8924     could occur before any layers.
8925     (SessionLoader.start_clrange): Provide backward compatibility for
8926     reading min/max values as well as the new range parameter.
8927    
8928     * Thuban/Model/map.py: Explicit imports.
8929    
8930     * Thuban/Model/resource.py: Import _.
8931     (ProjFileSaver.write): write header using projfile.dtd.
8932    
8933     * Thuban/Model/save.py: Explicit imports.
8934     (XMLWriter.encode): New. Encode the given string from a format
8935     used by Thuban into UTF-8. Fixes RTbug #1851.
8936    
8937     * Thuban/UI/classgen.py: Explicit imports.
8938     (ClassGenDialog.__init__): Clean up the code and add support
8939     for Quantiles.
8940     (ClassGenDialog.OnOK): Add support for Quantiles.
8941     (GenQuantilesPanel): New. Input panel for Quantiles.
8942     (ClassGenerator, CustomRamp, MonochromaticRamp, GreyRamp, RedRamp,
8943     GreenRamp, BlueRamp, HotToColdRamp): Move to Thuban/Model/classgen.py
8944    
8945     * Thuban/Model/classgen.py: New. Contains all the classes named above.
8946    
8947     * Thuban/UI/classifier.py: Explicit imports.
8948     (ClassTable.GetValueAsCust, ClassTable.__ParseInput,
8949     ClassTable.SetValueAsCustom): Reworked to use new Range class.
8950    
8951     * Thuban/UI/legend.py: Explicit imports.
8952    
8953     * Thuban/UI/mainwindow.py: Add support for the Join Dialog. Added
8954     a Table menu and associated method calls.
8955     (MainWindow.choose_color): Removed. No longer needed.
8956    
8957     * Thuban/UI/projdialog.py (ProjFrame.__VerifyButtons): Save button
8958     should be disabled if no projection is selected in the available
8959     list.
8960    
8961     * Thuban/UI/renderer.py: Explicit imports.
8962    
8963     * Thuban/UI/tableview.py (TableGrid.OnRangeSelect): Fix some issues
8964     with correctly selecting the rows and issuing the right events.
8965     Be sure to call Skip() to allow the grid to do some of its own
8966     handling which allows the rows to actually be selected.
8967     (LayerTableGrid.select_shapes): Rename from select_shape. Supports
8968     selecting multiple shapes.
8969     (LayerTableFrame): Support for building Queries.
8970     (LayerTableFrame.select_shapes): Allow multiple shapes to be selected.
8971    
8972     * Thuban/UI/tree.py: Explicit imports.
8973    
8974     * Thuban/UI/view.py (MapCanvas): Delegate "SelectedShapes" so the
8975     table view can call it.
8976    
8977     * test/test_classification.py: Explicit imports.
8978     (TestClassification.test_ClassGroupRange): Fix test for new
8979     Range class.
8980    
8981     * Doc/thuban.dtd: Add range parameter for clrange.
8982    
8983     * Thuban/Model/range.py: Taken from SciParam. Used as the underlying
8984     object in ClassGroupRange, and also uesd for inputting ranges in
8985     the classifer table and elsewhere.
8986    
8987     * Thuban/UI/join.py: New. Initial Join dialog. No real functionality
8988     yet.
8989    
8990 frank 872 2003-05-09 Frank Koormann <[email protected]>
8991    
8992     * Thuban/UI/scalebar.py (DrawScaleBar): Draw only if interval > 0.0.
8993    
8994 frank 860 2003-05-08 Frank Koormann <[email protected]>
8995    
8996 frank 870 Coding style updates
8997    
8998     * test/test_scalebar.py: Replaced tab indentation by spaces.
8999    
9000     * Thuban/UI/scalebar.py: Explicit imports.
9001    
9002     2003-05-08 Frank Koormann <[email protected]>
9003    
9004 frank 867 * Thuban/UI/scalebar.py
9005     (ScaleBar.DrawScalebar): Format string bug fixed.
9006    
9007     2003-05-08 Frank Koormann <[email protected]>
9008    
9009 frank 865 Reorganization of scalebar component (no wx in Thuban/Model)
9010    
9011     * Thuban/Model/scalebar.py: Rendering moved to Thuban/UI/scalebar.py
9012     (deriveInterval):
9013     Calculate scalebar interval and unit which fits in width for scale.
9014     (roundInterval): Round float.
9015    
9016     * Thuban/UI/scalebar.py (ScaleBar): Scalebar rendering
9017    
9018     * test/test_scalebar.py: Test for Thuban/Model/scalebar.py methods.
9019    
9020     * Thuban/UI/legend.py: Import Thuban.UI.scalebar
9021    
9022     2003-05-08 Frank Koormann <[email protected]>
9023    
9024 frank 860 * Thuban/UI/legend.py (ScalebarBitmap.SetCanvas):
9025     Initialize ScaleBar with canvas.map
9026    
9027     * Thuban/Model/scalebar.py (ScaleBar.roundInterval()): New,
9028     round intervals to display smarter lengths
9029     (ScaleBar.DrawScalebar): Draw Scalebar only if the map contains a
9030     layer. If the maps has no projection applied grey the scalebar.
9031    
9032 frank 857 2003-05-07 Frank Koormann <[email protected]>
9033    
9034     Basic Scalebar features added.
9035    
9036     * Thuban/Model/scalebar.py (ScaleBar): New, scalebar rendering.
9037    
9038     * Thuban/UI/legend.py (LegendPanel): Added scalebar bitmap
9039     (ScaleBarBitmap): New, links the scalebar bitmap with view messages
9040     and the renderer.
9041    
9042     * Thuban/UI/view.py (MapCanvas.set_view_transform): Issue SCALE_CHANGED.
9043    
9044     * Thuban/UI/messages.py: SCALE_CHANGED added.
9045    
9046 bh 850 2003-05-07 Bernhard Herzog <[email protected]>
9047    
9048 bh 852 * Thuban/Model/session.py (Session.__init__): New instance
9049     variable shapestores to hold a list of all open shapestore objects
9050     (Session.ShapeStores): New. Accessor method for the shapestores
9051     list.
9052     (Session._add_shapestore, Session._clean_weak_store_refs): New.
9053     Internal methods to maintain the shapestores list.
9054     (Session.Tables): New. Return all tables open in the session.
9055     (Session.OpenShapefile): Insert the new ShapeStore into the
9056     shapestores list.
9057    
9058     * test/test_session.py (TestSessionSimple.test_initial_state): Add
9059     tests for ShapeStores and Tables
9060     (TestSessionWithContent.test_shape_stores)
9061     (TestSessionWithContent.test_tables): New. Test cases for
9062     ShapeStores and Tables
9063    
9064     2003-05-07 Bernhard Herzog <[email protected]>
9065    
9066 bh 850 * Thuban/Model/transientdb.py (TransientTableBase.ReadRowAsDict):
9067     Add comments about the optimizations used.
9068     (AutoTransientTable.ReadValue, TransientTableBase.ReadValue): New.
9069     Implement the ReadValue table interface method.
9070    
9071     * test/test_transientdb.py
9072     (TestTransientTable.run_iceland_political_tests)
9073     (TestTransientTable.test_transient_joined_table): Add tests for
9074     ReadValue
9075    
9076 frank 848 2003-05-07 Frank Koormann <[email protected]>
9077    
9078     * Resources/Bitmaps/fulllayerextent.xpm,
9079     Resources/Bitmaps/fullselextent.xpm: Replaced the place holders with
9080     new icons.
9081    
9082 bh 840 2003-05-06 Bernhard Herzog <[email protected]>
9083    
9084 bh 846 * Thuban/Model/transientdb.py (AutoTransientTable.SimpleQuery):
9085     New. Simply delegate to the transient table's version.
9086    
9087     * test/test_transientdb.py
9088     (TestTransientTable.test_auto_transient_table_query): New. Test
9089     case for AutoTransientTable's SimpleQuery
9090    
9091     2003-05-06 Bernhard Herzog <[email protected]>
9092    
9093 bh 843 * Thuban/Model/transientdb.py (TransientTableBase.SimpleQuery):
9094     Implement a simple query method for the query dialog
9095     (TransientTableBase.create): Add an INTEGER PRIMARY KEY that holds
9096     the row index or shapeid.
9097     (TransientTable.create): Insert the right value of the row index
9098     (TransientJoinedTable.create): Copy the row index of the left
9099     table to the joined result table
9100    
9101     * test/test_transientdb.py
9102     (TestTransientTable.test_transient_table_read_twice): Fix
9103     doc-string
9104     (TestTransientTable.test_transient_table_query): New. Test for the
9105     SimpleQuery method
9106    
9107     2003-05-06 Bernhard Herzog <[email protected]>
9108    
9109 bh 840 Convert all table users to use the new table interface. This only
9110     covers Thuban itself, not GREAT-ER or other applications built on
9111     Thuban yet, so the compatibility interface stays in place for the
9112     time being but it now issues DeprecationWarnings.
9113    
9114     Finally, the new Table interface has a new method, HasColumn.
9115    
9116     * Thuban/Model/table.py (OldTableInterfaceMixin): All methods
9117     issue deprecation warnings when they're. The warnings refer to the
9118     caller of the method.
9119     (OldTableInterfaceMixin.__deprecation_warning): New. Helper method
9120     for the deprecation warnings
9121    
9122     * test/test_table.py: Ignore the deprecation warnings for the old
9123     table in the tests in this module. The purpose of the tests is to
9124     test the old interface, after all.
9125    
9126     * test/test_transientdb.py
9127     (TestTransientTable.run_iceland_political_tests): Use the
9128     constants for the types. Add a test for HasColumn
9129     (TestTransientTable.test_transient_joined_table): Adapt to new
9130     table interface. Add a test for HasColumn
9131     (TestTransientTable.test_transient_table_read_twice): Adapt to new
9132     table interface
9133    
9134     * Thuban/UI/tableview.py (DataTable.SetTable, DataTable.GetValue):
9135     Adapt to new table interface
9136    
9137     * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Adapt to
9138     new table interface
9139    
9140     * Thuban/UI/controls.py (RecordListCtrl.fill_list)
9141     (RecordTable.SetTable): Adapt to new table interface
9142    
9143     * Thuban/UI/classifier.py (Classifier.__init__)
9144     (Classifier.__init__): Adapt to new table interface
9145    
9146     * Thuban/UI/classgen.py (ClassGenDialog.__init__)
9147     (GenUniformPanel._OnRetrieve, GenUniquePanel._OnRetrieve): Adapt
9148     to new table interface
9149    
9150     * Thuban/Model/transientdb.py (TransientTableBase.HasColumn)
9151     (AutoTransientTable.HasColumn): Implement the new table interface
9152     method
9153     (AutoTransientTable.ReadRowAsDict, AutoTransientTable.ValueRange)
9154     (AutoTransientTable.UniqueValues): Adapt to new table interface
9155    
9156     * Thuban/Model/layer.py (Layer.SetShapeStore, Layer.GetFieldType):
9157     Adapt to new table interface
9158    
9159     * test/test_layer.py (TestLayer.open_shapefile): Helper method to
9160     simplify opening shapefiles a bit easier.
9161     (TestLayer.test_arc_layer, TestLayer.test_polygon_layer)
9162     (TestLayer.test_point_layer): Use the new helper method
9163     (TestLayer.test_get_field_type): New. Test for the GetFieldType
9164     method
9165    
9166     * test/test_dbf_table.py (TestDBFTable.test_has_column): Test for
9167     the new table method
9168    
9169     * test/test_memory_table.py (TestMemoryTable.test_has_column):
9170     Test for the new table method HasColumn
9171    
9172 jonathan 833 2003-05-06 Jonathan Coles <[email protected]>
9173    
9174     Addresses the "Selection Extent" wish of RTbug #1787.
9175    
9176     * Resources/Bitmaps/fulllayerextent.xpm,
9177     Resources/Bitmaps/fullselextent.xpm: Bitmaps for layer and selection
9178     extent. These are just place holders for the real bitmaps.
9179    
9180     * Thuban/Model/layer.py (Shape): Since a Shape is immutable only
9181     calculate the bounding box once (the first time compute_bbox() is
9182     called).
9183     (Layer.ShapesBoundingBox): New. Given a list of shape ids, return
9184     the bounding box for the shapes in lat/long coordinates.
9185    
9186     * Thuban/UI/mainwindow.py: Added new "Full selection extent" menu
9187     option.
9188     (MainWindow.has_selected_shapes): New. Returns true if there are
9189     any selected shapes.
9190     (MainWindow.FullSelectionExtent): New. Calls
9191     MapCanvas.FitSelectedToWindow() when the user selects the menu option.
9192     (_has_selected_shapes): New. Returns true if there are any
9193     selected shapes.
9194    
9195     * Thuban/UI/selection.py (Selection.HasSelectedShapes): New. Returns
9196     true if there are any selected shapes.
9197    
9198     * Thuban/UI/view.py (MapCanvas): Added delegated method
9199     HasSelectedShapes.
9200     (MapCanvas.FitSelectedToWindow): New. Centers and scales any selected
9201     shapes on the canvas using the map projection (if any).
9202    
9203     * test/test_layer.py (TestLayer.test_arc_layer): Add some tests
9204     for Layer.ShapesBoundingBox().
9205    
9206 bh 826 2003-05-06 Bernhard Herzog <[email protected]>
9207    
9208     * Resources/Projections/defaults.proj: Fix spelling of Mercator
9209    
9210 jonathan 823 2003-05-05 Jonathan Coles <[email protected]>
9211    
9212     Addresses the "Full Layer Extent" wish of RTbug #1787.
9213    
9214     * Resources/Projections/defaults.proj: Added UK National Grid.
9215    
9216     * Thuban/UI/mainwindow.py: Added new "Full layer extent" menu option.
9217     (MainWindow.FullLayerExtent): New. Calls MapCanvas.FitLayerToWindow()
9218     when the user selects the menu option.
9219    
9220     * Thuban/UI/view.py (MapCanvas.FitLayerToWindow): New. Centers and
9221     scales the given layer on the canvas using the map projection.
9222    
9223 bh 819 2003-05-05 Bernhard Herzog <[email protected]>
9224    
9225     Convert the table implementations to a new table interface. All
9226     tables use a common mixin class to provide backwards compatibility
9227     until all table users have been updated.
9228    
9229     * Thuban/Model/table.py (OldTableInterfaceMixin): Mixin class to
9230     provide backwards compatibility for table classes implementing the
9231     new interface
9232     (DBFTable, MemoryTable): Implement the new table interface. Use
9233     OldTableInterfaceMixin as base for compatibility
9234     (DBFColumn, MemoryColumn): New. Column description for DBFTable
9235     and MemoryTable resp.
9236    
9237     * test/test_dbf_table.py: New. Test cases for the DBFTable with
9238     the new table interface.
9239    
9240     * test/test_memory_table.py: New. Test cases for the MemoryTable
9241     with the new table interface.
9242    
9243     * test/test_table.py: Document the all tests in this file as only
9244     for backwards compatibility. The equivalent tests for the new
9245     interface are in test_memory_table.py and test_dbf_table.py
9246     (MemoryTableTest.test_read): field_info should be returning tuples
9247     with four items
9248     (MemoryTableTest.test_write): Make doc-string a more precise.
9249    
9250     * Thuban/Model/transientdb.py (TransientTableBase): Convert to new
9251     table interface. Derive from from OldTableInterfaceMixin for
9252     compatibility.
9253     (TransientTableBase.create): New intance variable column_map to
9254     map from names and indices to column objects
9255     (TransientTable.create): Use the new table interface of the input
9256     table
9257     (AutoTransientTable): Convert to new table interface. Derive from
9258     from OldTableInterfaceMixin for compatibility.
9259     (AutoTransientTable.write_record): Removed. It's not implemented
9260     yet and we still have to decide how to handle writing with the new
9261     table and data framework.
9262    
9263     * test/test_transientdb.py
9264     (TestTransientTable.run_iceland_political_tests)
9265     (TestTransientTable.test_transient_joined_table): Use the new
9266     table interface
9267    
9268 jonathan 817 2003-05-05 Jonathan Coles <[email protected]>
9269    
9270     This is namely a collection of UI updates to improve user interactivity.
9271     Tabbing between controls now exists and you can use ESC to close dialog
9272     boxes; ENTER will active the default button.
9273    
9274     * Thuban/UI/classgen.py (ClassGenDialog.__init__): Rearrange the
9275     order that the controls are created so that tabbing works correctly.
9276     (ClassGenDialog.OnOK): Renamed from _OnGenerate() so that the
9277     wxDialog can handle the default button correctly.
9278     (ClassGenDialog.OnCancel): Renamed from _OnCloseBtn() for the
9279     same reasons as for OnOK.
9280     (GenUniformPanel._OnRetrieve): Call wxBeginBusyCursor/wxEndBusyCursor
9281     when we ask the table for the maximum/minimum values of a field
9282     which could take a very long time.
9283    
9284     * Thuban/UI/classifier.py (Classifier.__init__): Rearrange the
9285     order that the controls are created so that tabbing works correctly.
9286     (SelectPropertiesDialog.__init__): Rearrange the order that the
9287     controls are created so that tabbing works correctly.
9288    
9289     * Thuban/UI/dialogs.py: Copied NonModalDialog box and changed it
9290     to derive from a wxDialog but behave like the original implementation
9291     which was derived from a wxFrame. wxDialog provides useful key
9292     handling functionality like ESC calling OnCancel and ENTER calling
9293     OnOK which is lost with wxFrame.
9294    
9295     * Thuban/UI/mainwindow.py: Add "..." to menu items that will open
9296     new dialogs.
9297    
9298     * Thuban/UI/projdialog.py (ProjFrame.__init__): Rearrange the
9299     order that the controls are created so that tabbing works correctly.
9300     (ProjFrame.OnApply): Renamed from _OnTry() to use wxDialog behaviour.
9301     (ProjFrame.OnOK): Renamed from _OnOK() to use wxDialog behaviour.
9302     (ProjFrame.OnCancel): Renamed from _OnClose() to use wxDialog behaviour.
9303     (ProjPanel.__init__): Add "Airy" to the list of ellipsoids so we
9304     can provide the "UK National Grid" as a default projection.
9305     (UTMPanel.__init__): Rearrange the order that the controls are
9306     created so that tabbing works correctly.
9307    
9308 bh 809 2003-05-05 Bernhard Herzog <[email protected]>
9309    
9310 bh 811 * extensions/thuban/wxproj.cpp: Fix some of the comments.
9311     (project_point): If a map projection but no layer projection is
9312     given, convert degrees to radians before applying the map
9313     projection.
9314    
9315 bh 809 * Thuban/UI/tableview.py (TableGrid.disallow_messages)
9316     (TableGrid.allow_messages): New methods to make it possible to
9317     inhibit message sending.
9318     (TableGrid.issue): Only send the message if not inhibited.
9319     (LayerTableGrid.select_shape): Use the new methods to make sure
9320     that no ROW_SELECTED message is sent while we're updating the
9321     selected rows to match the selected shapes.
9322    
9323 jan 807 2003-05-02 Jan-Oliver Wagner <[email protected]>
9324    
9325     Implementation of MemoryTable.
9326    
9327     * Thuban/Model/table.py (MemoryTable): New. Quite simple table
9328     implementation that operates on a list of tuples. All of the data
9329     are kept in the memory.
9330    
9331     * test/test_table.py (MemoryTableTest): New.
9332    
9333     * test/test_transientdb.py (SimpleTable): Removed.
9334     (TestTransientTable.test_transient_joined_table,
9335     (TestTransientTable.test_transient_table_read_twice): Replaced
9336     SimpleTable by MemoryTable.
9337    
9338 jonathan 793 2003-04-30 Jonathan Coles <[email protected]>
9339    
9340 jonathan 803 * Data/iceland_sample.thuban: Now contains correct projections
9341     for each of the layers.
9342    
9343     * Resources/Projections/defaults.proj: Geographic projection
9344     contains unit conversion parameter.
9345    
9346     2003-04-30 Jonathan Coles <[email protected]>
9347    
9348 jonathan 793 The most important part of this putback is the projection changes.
9349     It should now be possible to specify the projection that a layer
9350     is in and then specify a different projection for the map. The
9351     projection dialog has an extra parameter for a geographic projection
9352     which lets the user select if the input is in degrees or radians.
9353    
9354     * Thuban/Model/layer.py (Layer.ShapesInRegion): Fix docstring
9355     to say that the parameter is a tuple of unprojected
9356     points (which is what the callers to this method were assuming).
9357     Also, since the points are unprojected we need to projected them.
9358    
9359     * Thuban/UI/legend.py (LegendTree.MoveCurrentItemUp,
9360     LegendTree.MoveCurrentItemDown): If the layer or any of the layer's
9361     groups are selected, move the layer up/down. Fixes RTbug #1833.
9362    
9363     * Thuban/UI/mainwindow.py: Move menu item map_rename up.
9364    
9365     * Thuban/UI/projdialog.py (ProjFrame._OnSave): Add missing
9366     parameter in call to SetClientData.
9367     (GeoPanel): Add support for selecting the units that the
9368     source data is in (Radians or Degrees).
9369    
9370     * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Optimize
9371     the rendering loop by reducing the number of if's, removing the
9372     unnecessary try/except block, and checking if the old group
9373     is the same as the new one (which happens a lot if there is
9374     no classification, or lots of shapes are in the same group).
9375    
9376     * Thuban/UI/view.py (MapCanvas.OnPaint): Add a try/except block
9377     around the redraw routine to try to catch problems that the user
9378     may create by selecting invalid projections for the data set and
9379     map. Clears the display if there are any problems and prints the
9380     error.
9381     (MapCanvas.do_redraw): Use DC.Clear() instead of drawing a filled
9382     rectangle.
9383    
9384     * extensions/thuban/wxproj.cpp (project_point): First invert the
9385     supplied point (which should be in projected coordinates) using
9386     the layer's projection and then project the point using the
9387     map's projection.
9388     (project_points): Use project_point() to project each point.
9389    
9390 jan 792 2003-04-30 Jan-Oliver Wagner <[email protected]>
9391    
9392     * Thuban/Model/layer.py (Layer.SetShapeStore): Fixed a bug:
9393     don't set the Classification to None if the classfication field
9394     is None (ie only a DEFAULT).
9395    
9396 bh 786 2003-04-30 Bernhard Herzog <[email protected]>
9397    
9398 bh 790 * Thuban/UI/view.py: Fix some typos.
9399    
9400 bh 788 * Thuban/UI/mainwindow.py (MainWindow.identify_view_on_demand): Do
9401     not pop up the dialog if the selection becomes empty (this could
9402     happen if e.g. a new selection is opened while the identify tool
9403     is active and dialog had been closed)
9404    
9405     2003-04-30 Bernhard Herzog <[email protected]>
9406    
9407 bh 786 * Thuban/Model/transientdb.py (TransientTableBase.__init__): New
9408     instance variable read_record_last_result
9409     (TransientTableBase.read_record): Make sure reading the same
9410     record twice works. The implementation uses the new instance
9411     variable read_record_last_result
9412    
9413     * test/test_transientdb.py
9414     (TestTransientTable.test_transient_table_read_twice): New test
9415     case for the above bug-fix.
9416    
9417 jonathan 793 2003-04-29 Jonathan Coles <[email protected]>
9418    
9419     * Thuban/common.py: Removed. No longer needed Str2Num. RTbug #1832.
9420    
9421     * Thuban/UI/classgen.py: Remove all uses of Str2Num.
9422    
9423     * Thuban/UI/classifier.py: Remove all uses of Str2Num.
9424     (ClassTable.SetValueAsCustom): Rename keyword argument in
9425     ClassGroup* constructors to match argument name.
9426    
9427 bh 779 2003-04-29 Bernhard Herzog <[email protected]>
9428    
9429     * Thuban/Model/session.py (Session.Destroy): Explicitly close the
9430     transient DB if it exists to make sure it doesn't leave a journal
9431     file in the temp directory.
9432    
9433     * Thuban/Model/transientdb.py (TransientDatabase.close): Set
9434     self.conn to None after closing the connection to make sure it's
9435     not closed twice
9436    
9437 jonathan 767 2003-04-29 Jonathan Coles <[email protected]>
9438    
9439 jonathan 769 Add a visible parameter in the layer XML tag. The default value is
9440     "true". If anything other than "false" is specified we also assume
9441 jonathan 776 "true". Addresses RTbug #1025.
9442 jonathan 769
9443     * Doc/thuban.dtd: Add visible parameter to a layer.
9444    
9445     * Thuban/Model/layer.py (BaseLayer.__init__): Change default value
9446     of visible from 1 to True.
9447     (Layer.__init__): Change default value of visible from 1 to True.
9448    
9449     * Thuban/Model/load.py (SessionLoader.start_layer): Read visible
9450     parameter.
9451    
9452     * Thuban/Model/save.py (SessionSaver.write_layer): Save visible
9453     parameter.
9454    
9455     * test/test_load.py: Add new test data contents_test_visible.
9456     (LoadSessionTest.setUp): save test data.
9457     (LoadSessionTest.testLayerVisibility): Test if the visible flag
9458     is loaded correctly.
9459    
9460     * test/test_save.py (SaveSessionTest.testSingleLayer): Add test
9461     for saving an invisible layer.
9462    
9463     2003-04-29 Jonathan Coles <[email protected]>
9464    
9465 jonathan 767 * Thuban/UI/mainwindow.py (MainWindow.SetMap): Look up the
9466     legend dialog box and tell it to change its map to the one
9467     supplied to SetMap(). Fixes RTbug #1770.
9468    
9469 bh 764 2003-04-29 Bernhard Herzog <[email protected]>
9470    
9471 bh 766 Next step of table implementation. Introduce a transient database
9472     using SQLite that some of the data is copied to on demand. This
9473     allows us to do joins and other operations that require an index
9474     for good performance with reasonable efficiency. Thuban now needs
9475     SQLite 2.8.0 and pysqlite 0.4.1. Older versions may work but I
9476     haven't tested that.
9477    
9478     * Thuban/Model/transientdb.py: New. Transient database
9479     implementation.
9480    
9481     * test/test_transientdb.py: New. Tests for the transient DB
9482     classes.
9483    
9484     * Thuban/Model/session.py (AutoRemoveFile, AutoRemoveDir): New
9485     classes to help automatically remove temporary files and
9486     directories.
9487     (Session.__init__): New instance variables temp_dir for the
9488     temporary directory and transient_db for the SQLite database
9489     (Session.temp_directory): New. Create a temporary directory if not
9490     yet done and return its name. Use AutoRemoveDir to have it
9491     automatically deleted
9492     (Session.TransientDB): Instantiate the transient database if not
9493     done yet and return it.
9494    
9495     * Thuban/Model/data.py (ShapefileStore.__init__): Use an
9496     AutoTransientTable so that data is copied to the transient DB on
9497     demand.
9498     (SimpleStore): New class that simply combines a table and a
9499     shapefile
9500    
9501     * Thuban/Model/table.py (Table, DBFTable): Rename Table into
9502     DBFTable and update its doc-string to reflect the fact that this
9503     is only the table interface to a DBF file. Table is now an alias
9504     for DBFTable for temporary backwards compatibility.
9505    
9506     * Thuban/UI/application.py (ThubanApplication.OnExit): Make sure
9507     the last reference to the session goes away so that the temporary
9508     files are removed properly.
9509    
9510     * test/test_load.py (LoadSessionTest.tearDown): Remove the
9511     reference to the session to make sure the temporary files are
9512     removed.
9513    
9514     2003-04-29 Bernhard Herzog <[email protected]>
9515    
9516 bh 764 * Thuban/Model/load.py (XMLReader.__init__, XMLReader.read): Turn
9517     the __parser instance variable into a normal local variable in
9518     read. It's only used there and read will never be called more than
9519     once. Plus it introduces a reference cycle that keeps can keep the
9520     session object alive for a long time.
9521    
9522 jonathan 767 2003-04-29 Jonathan Coles <[email protected]>
9523 jonathan 735
9524 jonathan 762 * Thuban/Model/proj.py (Projection): Removed Set*() methods to make
9525     Projection an immutable item. Fixes RTbug #1825.
9526     (Projection.__init__): Initialize instance variables here.
9527     (ProjFile.Replace): New. Replace the given projection object with
9528     the new projection object. This solves the problem of needing the
9529     mutator Projection.SetProjection() in the ProjFrame class and
9530     allows a projection to change parameters without changing its
9531     location in the file.
9532    
9533     * Thuban/UI/mainwindow.py (MainWindow.SaveSessionAs): Dialog should
9534     be of type wxSAVE and should verify overwriting a file.
9535    
9536     * Thuban/UI/projdialog.py (ProjFrame._OnSave): Use the new
9537     ProjFile.Replace() method instead of the mutator
9538     Projection.SetProjection(). Also requires that we reassign the
9539     client data to the new projection.
9540    
9541     * test/test_proj.py (TestProjection.test): Test GetName() and
9542     GetAllParameters()
9543     (TestProjFile.test): Remove tests for Set*() methods. Add tests
9544     for Replace().
9545    
9546     2003-04-25 Jonathan Coles <[email protected]>
9547    
9548 jonathan 756 * Thuban/Model/save.py (SessionSaver.write_projection): Make sure
9549     to save the name of the projection.
9550    
9551     * test/test_save.py (SaveSessionTest.testLayerProjection): New
9552     test to verify layer projections are saved correctly.
9553    
9554     2003-04-25 Jonathan Coles <[email protected]>
9555    
9556 jonathan 753 * Thuban/Model/proj.py (Projection.SetName): Set the name
9557     to "Unknown" if name is None.
9558     (Projection.SetAllParameters): New. Set the projection's
9559     parameter list to the one supplied.
9560     (Projection.SetProjection): New. Set the projection's
9561     properties to those of the supplied Projection.
9562    
9563     * Thuban/UI/mainwindow.py (MainWindow.MapProjection): Set
9564     the dialog title to include the map's title.
9565     (MainWindow.LayerProjection): Set the dialog title to include
9566     the layer's title.
9567    
9568     * Thuban/UI/projdialog.py (ProjFrame.__ShowError): Consolidate
9569     error dialogs into a single method call.
9570     (ProjFrame.__VerifyButtons): Add more states to check.
9571     (ProjFrame.__GetProjection): Return the current state of an
9572     edited projection or None.
9573     (ProjFrame.__FillAvailList): Remove checks for states that
9574     shouldn't exist.
9575     (ProjFrame._OnNew): Clear all selected items and supply
9576     a projection panel if necessary.
9577    
9578     * test/test_proj.py (TestProjFile.test): Add tests for
9579     ProjFile.SetAllParameters, ProjFile.SetProjection,
9580     ProjFile.SetName.
9581    
9582     2003-04-25 Jonathan Coles <[email protected]>
9583    
9584 jonathan 748 * Thuban/UI/projdialog.py (ProjFrame.__FillAvailList): Now
9585     takes an optional argument to select the current projection.
9586     This does not guarantee that the item is visible due to
9587     limited wxWindows functionality. Fixes RTBug #1821.
9588    
9589     2003-04-25 Jonathan Coles <[email protected]>
9590    
9591 jonathan 743 * Thuban/Model/load.py (SessionLoader.start_projection): Remember
9592     the projection name and use it when constructing the Projection
9593     object.
9594    
9595     * Thuban/Model/proj.py (Projection.__init__): Change the default
9596     value for 'name' to None and then test if name is equal to None
9597     in the body of the constructor. This way the caller doesn't have to
9598     know what the default value should be. Namely, useful in load.py
9599     where we have to pick a default value if the 'name' parameter
9600     doesn't exist in the XML file.
9601    
9602     * test/test_load.py (LoadSessionTest.testLayerProjection): New.
9603     Tests a file where a layer has a projection.
9604    
9605     2003-04-25 Jonathan Coles <[email protected]>
9606    
9607 jonathan 735 * Thuban/Model/layer.py (Layer.TreeInfo): Add an item to the
9608     tree for projection information.
9609    
9610     * Thuban/Model/load.py (XMLReader.GetFilename): Renamed from
9611     XMLReader.GetFileName.
9612     (SessionLoader): Added support for loading projection tags that
9613     appear inside a layer.
9614    
9615     * Thuban/Model/proj.py (ProjFile): Document the class. Move
9616     back to using a list because the order of the projections in
9617     the file is important to maintain. Fixes RTbug #1817.
9618    
9619     * Thuban/Model/resource.py: Rename calls to ProjFile.GetFileName
9620     to ProjFile.GetFilename.
9621    
9622     * Thuban/Model/save.py (SessionSaver.write_layer): Save projection
9623     information.
9624    
9625     * Thuban/UI/projdialog.py (ProjFrame._OnAddToList): Renamed from
9626     ProjFrame._OnSaveAs. Removed old dead code from previous
9627     implementation.
9628     (ProjFrame._OnExport): Add support for exporting more than one
9629     projection to a single file.
9630     (ProjFrame.__FillAvailList): use string formatting (% operator)
9631     to build strings that are (partly) translated. Fixes RTbug #1818.
9632    
9633     * test/test_proj.py (TestProjFile.test): New. Tests the base ProjFile
9634     class.
9635    
9636 bh 734 2003-04-24 Bernhard Herzog <[email protected]>
9637    
9638     * po/es.po: Updated Spanish translation by Daniel Calvelo Aros
9639    
9640     * po/fr.po: New. French translation by Daniel Calvelo Aros
9641    
9642     * Thuban/UI/projdialog.py (ProjFrame._OnSaveAs): Don't translate
9643     empty strings.
9644    
9645 jonathan 735 2003-04-24 Jonathan Coles <[email protected]>
9646 jonathan 724
9647     * Thuban/Model/layer.py (Layer.GetProjection): New. Needed to
9648     implement the interface that the ProjFrame dialog expects.
9649    
9650     * Thuban/Model/proj.py (Projection.SetName): New. Allows the
9651     name of the projection to be changed.
9652     (ProjFile): Use a dictionary instead of a list so that removing
9653     projections is easier and we are sure about uniqueness.
9654     (ProjFile.Remove): Remove the given projection object.
9655    
9656     * Thuban/Model/resource.py (GetSystemProjFiles, GetUserProjFiles):
9657     Return a list with only one projection file instead of searching for
9658     any projection file. This simplifies many things if the user can
9659     only have one system file and one user file.
9660    
9661     * Thuban/UI/classgen.py: Change all references to
9662     genCombo to genChoice.
9663    
9664     * Thuban/UI/mainwindow.py: Add a Projection option under the
9665     layer menu.
9666     (MainWindow.LayerProjection): New. Open up a projection window
9667     for a layer.
9668    
9669     * Thuban/UI/projdialog.py: Large changes to how the dialog is
9670     laid out. Use three panels instead of one. One for the list of
9671     projections, one for the edit controls, and one for the buttons.
9672     Fixed resizing problems so that the dialog resizes correctly
9673     when the projection panel changes. Added import/export, save, and
9674     new buttons/functionality.
9675    
9676 bh 723 2003-04-24 Bernhard Herzog <[email protected]>
9677    
9678     First step towards table management. Introduce a simple data
9679     abstraction so that we replace the data a layer uses more easily
9680     in the next step.
9681    
9682     * Thuban/Model/data.py: New file with a simple data abstraction
9683     that bundles shapefile and dbffile into one object.
9684    
9685     * Thuban/Model/session.py (Session.OpenShapefile): New method to
9686     open shapefiles and return a shape store object
9687    
9688     * Thuban/Model/layer.py (Layer.__init__): Pass the data as a store
9689     object instead of a shapefile filename. This introduces a new
9690     instance variable store holding the datastore. For intermediate
9691     backwards compatibility keep the old instance variables.
9692     (open_shapefile): Removed. No longer needed with the shape store.
9693     (Layer.SetShapeStore, Layer.ShapeStore): New methods to set and
9694     get the shape store used by a layer.
9695     (Layer.Destroy): No need to explicitly destroy the shapefile or
9696     table anymore.
9697    
9698     * Thuban/UI/mainwindow.py (MainWindow.AddLayer)
9699     (MainWindow.AddLayer): Use the session's OpenShapefile method to
9700     open shapefiles
9701    
9702     * Thuban/Model/load.py (ProcessSession.start_layer): Use the
9703     session's OpenShapefile method to open shapefiles
9704    
9705     * test/test_classification.py
9706     (TestClassification.test_classification): Use the session's
9707     OpenShapefile method to open shapefiles and build the filename in
9708     a more platform independed way
9709    
9710     * test/test_layer.py (TestLayer.setUp, TestLayer.tearDown):
9711     Implement to have a session to use in the tests
9712     (TestLayer.test_arc_layer, TestLayer.test_polygon_layer)
9713     (TestLayer.test_point_layer, TestLayer.test_empty_layer): Use the
9714     session's OpenShapefile method to open shapefiles
9715     (TestLayerLegend.setUp): Instantiate a session so that we can use
9716     it to open shapefiles.
9717     (TestLayerLegend.tearDown): Make sure that all references to
9718     layers and session are removed otherwise we may get a resource
9719     leak
9720    
9721     * test/test_map.py (TestMapAddLayer.test_add_layer)
9722     (TestMapWithContents.setUp): Instantiate a session so that we can
9723     use it to open shapefiles.
9724     (TestMapWithContents.tearDown): Make sure that all references to
9725     layers, maps and sessions are removed otherwise we may get a
9726     resource leak
9727     ("__main__"): use support.run_tests() so that more info about
9728     uncollected garbage is printed
9729    
9730     * test/test_save.py (SaveSessionTest.testSingleLayer): Use the
9731     session's OpenShapefile method to open shapefiles
9732     ("__main__"): use support.run_tests() so that more info about
9733     uncollected garbage is printed
9734    
9735     * test/test_selection.py (TestSelection.tearDown): Make sure that
9736     all references to the session and the selection are removed
9737     otherwise we may get a resource leak
9738     (TestSelection.get_layer): Instantiate a session so that we can
9739     use it to open shapefiles.
9740     ("__main__"): use support.run_tests() so that more info about
9741     uncollected garbage is printed
9742    
9743     * test/test_session.py (TestSessionBase.tearDown)
9744     (TestSessionWithContent.tearDown): Make sure that all references
9745     to the session and layers are removed otherwise we may get a
9746     resource leak
9747     (TestSessionWithContent.setUp): Use the session's OpenShapefile
9748     method to open shapefiles
9749    
9750 jonathan 721 2003-04-24 Jonathan Coles <[email protected]>
9751    
9752     * Thuban/Model/load.py (XMLReader.read): Should have been checking
9753     if the file_or_filename object had the 'read' attribute.
9754    
9755 jonathan 715 2003-04-23 Jonathan Coles <[email protected]>
9756    
9757 jonathan 720 * Thuban/Model/resource.py: Fixes RTbug #1813.
9758     (ReadProjFile): Add documentation about which exceptions are raised.
9759     Always pass the exceptions up to the caller.
9760     (GetProjFiles): If the directory can't be read return an empty list.
9761     If any of the proj files can't be read skip that file and go
9762     on to the next one.
9763    
9764     * test/test_proj.py: Added test cases to handle nonexistent files,
9765     unreadable files, and files that don't parse correctly.
9766    
9767     2003-04-23 Jonathan Coles <[email protected]>
9768    
9769 jonathan 716 Projection dialog. Allows the user to select from a list
9770     of projection templates and optionally edit them and save new ones.
9771    
9772     * Thuban/UI/projdialog.py (ProjFrame): New. Main dialog.
9773     (ProjPanel): Base class for projection specific panels.
9774     (TMPanel): Projection panel for Transverse Mercartor.
9775     (UTMPanel): Projection panel for Universal Transverse Mercartor.
9776     (LCCPanel): Projection panel for Lambert Conic Conformal.
9777     (GeoPanel): Projetion panel for Geographic Projection.
9778    
9779     2003-04-23 Jonathan Coles <[email protected]>
9780    
9781 jonathan 715 * Thuban/Model/load.py (XMLReader): Renamed from XMLProcessor to
9782     promote symmetry. There now exists XMLReader and XMLWriter.
9783     (XMLReader.read): New. Call to read the given file descriptor or
9784     filename.
9785     (XMLReader.close): New. Make sure the file is closed.
9786     (XMLReader.GetFileName): New. Return just the file name that is being
9787     read from.
9788     (XMLReader.GetDirectory): New. Return just the directory of the file
9789     that is being read.
9790     (XMLReader.AddDispatchers): New. Take a dictionary which contains
9791     the names of functions to call as the XML tree is parsed.
9792     (XMLReader.startElementNS): Updated to use new dispatcher dictionary.
9793     (XMLReader.endElementNS): Updated to use new dispatcher dictionary.
9794     (SessionLoader): Removed class variables start_dispatcher and
9795     end_dispatcher since this functionality is now part of a class
9796     instance. Fixes RTbug #1808.
9797     (SessionLoader.__init__): Add dispatcher functions.
9798     (load_xmlfile): Code was moved into the XMLReader.read().
9799     (load_session): Use modified SessionLoader.
9800    
9801     * Thuban/Model/map.py (Map.GetProjection): New. Returns the
9802     map's projection.
9803    
9804     * Thuban/Model/proj.py (Projection.GetParameters): Renamed to
9805     GetAllParameters.
9806     (Projection.GetParameter): Returns the value for the given parameter.
9807    
9808     * Thuban/Model/resource.py: Use XMLReader and XMLWriter.
9809     (GetProjFiles): Renamed from GetProjections. Now returns a list
9810     of ProjFile objects.
9811     (GetSystemProjFiles): Renamed from GetSuppliedProjections. Returns
9812     a list of ProjFile objects whose files are not user defined.
9813     (GetUserProjFiles): Renamed from GetUserProjections. Returns a
9814     list of ProjFile objects whose files are user defined.
9815     (ProjFileReader): Extend new XMLReader.
9816    
9817     * Thuban/Model/save.py (XMLWriter): Renamed from XMLSaver to
9818     promote symmetry.
9819    
9820     * Thuban/UI/classgen.py (ClassGenDialog.__init__): Use a wxChoice
9821     control instead of a wxComboBox. wxChoice controls do not generate
9822     events as the uses highlights possible choices which fixes problems
9823     with resizing the dialog when the use selects an option.
9824    
9825     * Thuban/UI/classifier.py (Classifier.__init__): Use a wxChoice
9826     control instead of a wxComboBox.
9827    
9828     * Thuban/UI/mainwindow.py (MainWindow.Projection): Use new projection
9829     dialog.
9830    
9831     * test/test_proj.py (TestProjection.test): New tests for GetParameter
9832     method.
9833    
9834 bh 703 2003-04-22 Bernhard Herzog <[email protected]>
9835    
9836 bh 705 * Thuban/UI/mainwindow.py: Remove some unused imports and global
9837     constants
9838    
9839 bh 703 * Thuban/UI/identifyview.py (IdentifyListCtrl.selected_shape)
9840     (IdentifyGridCtrl.selected_shape): Use table, not shapetable.
9841    
9842 bh 700 2003-04-17 Bernhard Herzog <[email protected]>
9843    
9844 bh 701 * Thuban/Model/layer.py: Don't import LAYER_LEGEND_CHANGED.
9845     (Layer): Update doc-string since LAYER_LEGEND_CHANGED is not used
9846     anymore.
9847     (Layer.BoundingBox, Layer.GetFieldType, Layer.NumShapes)
9848     (Layer.ShapeType, Layer.Shape): No need to call
9849     self.open_shapefile since it's always called in __init__
9850    
9851 bh 700 * Thuban/UI/application.py (ThubanApplication.MainLoop): Removed.
9852     In wxPython 2.4 there's no need to extend MainLoop anymore since
9853     wxPython itself makes sure OnExit is called.
9854    
9855 jonathan 688 2003-04-16 Jonathan Coles <[email protected]>
9856    
9857 jonathan 693 Initial putback of projection management code. Includes new
9858     classes to read and write projection files. The current load
9859     and save classes were abstracted a bit so they could be reused.
9860     The Projection class was extended to provide new methods and
9861     have a name.
9862    
9863     * Thuban/Model/load.py (XMLProcessor): New. Contains all the
9864     general XML reading methods that were part of ProcessSession.
9865    
9866     * Thuban/Model/proj.py (Projection.__init__): Accepts an optional
9867     name.
9868     (ProjFile): New. Represents a file that contains projection
9869     information.
9870    
9871     * Thuban/Model/resource.py: New. Contains general utilities
9872     for read and writing projection files.
9873    
9874     * Thuban/Model/save.py (XMLSaver): New. Contains all the
9875     general XML writing methods that were part of SessionSaver.
9876     (SessionSaver): Renamed from Saver.
9877    
9878     * test/test_proj.py: New test cases for the projection
9879     file read and write functions.
9880    
9881     2003-04-16 Jonathan Coles <[email protected]>
9882    
9883 jonathan 688 * Thuban/Model/classification.py: Use repr() around values
9884     in the ClassGroup*.__repr__() methods so it is clearer when
9885     a value is a string and when it is a number.
9886    
9887     * test/test_load.py: Rework the classification test to test
9888     that we can load old files.
9889     (testLabels): Test a file where the groups have labels.
9890    
9891 bh 687 2003-04-16 Bernhard Herzog <[email protected]>
9892    
9893     Safer implementation of the performance enhancements of the
9894     low-level renderer:
9895    
9896     * extensions/thuban/wxproj.cpp (extract_projection)
9897     (extract_pointer): Rename extract_projection to extract_pointer
9898     and redefine its purpose to return the pointer stored in a CObject
9899     returned by the object's cobject method. Update all callers.
9900     (s_draw_info, free_draw_info, draw_polygon_init): Implement the
9901     handling of these low-level parameters so that each s_draw_info
9902     instance is handled as a CObject at python level that also
9903     contains real references to the actual python objects which
9904     contain the values in the struct. Add free_draw_info as the
9905     destructor.
9906     (draw_polygon_shape): Add the py_draw_info parameter which must a
9907     cobject containing an s_draw_info pointer.
9908    
9909     * Thuban/UI/renderer.py (MapRenderer.polygon_render_param): New
9910     method to instantiat the low-level render parameter
9911     (MapRenderer.draw_shape_layer): Use the new method. Remove some
9912     commented out code.
9913     (MapRenderer.draw_polygon_shape): Make the first parameter not the
9914     layer but the low-level render parameter
9915     (ScreenRenderer.draw_shape_layer): Use the low-level render
9916     parameter.
9917    
9918 jonathan 673 2003-04-15 Jonathan Coles <[email protected]>
9919    
9920 jonathan 680 * Thuban/Model/classification.py: Implemented __repr__ for
9921     the ClassGroup* classes to make debugging a bit easier.
9922     (ClassGroup.SetLabel): Check that the string is an instance
9923     of StringTypes not StringType. Accounts for Unicode strings.
9924    
9925     * Thuban/Model/color.py: Implemented __repr__ to make
9926     debugging a bit easier.
9927    
9928     * Thuban/Model/save.py (Saver.write_classification): Need to
9929     save the group label.
9930    
9931     * test/test_load.py (testClassification): New. Loads the
9932     iceland_sample_test.thuban file and checks if it was loaded
9933     correctly.
9934    
9935     2003-04-15 Jonathan Coles <[email protected]>
9936    
9937 jonathan 673 * extensions/thuban/wxproj.cpp (draw_polygon_init): New. Used
9938     to improve rendering performance by initializing the variables
9939     that are not change each time draw_polygon_shape() is called.
9940     The values are stored in a global struct draw_info.
9941     (draw_polygon_shape): Removed initialization code that is
9942     now in draw_polygon_init().
9943    
9944     * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Make
9945 jonathan 674 drawing initialization call to draw_polygon_init()
9946     (MapRenderer.draw_polygon_shape): Use new signature of
9947     draw_polygon_shape.
9948 jonathan 673
9949 jonathan 674 * Thuban/UI/classgen.py (GenUniformPanel): Fix spin control
9950     weirdness by setting the range to (1, maxint).
9951 jonathan 673
9952 jonathan 674 * Thuban/Model/classification.py (ClassGroupProperties): Make
9953     instance variables private and optimize comparison operator
9954     by first checking if the color references are the same.
9955     (ClassGroupSingleton): Make instance variables private.
9956     (ClassGroupRange): Make instance variables private.
9957 jonathan 673
9958 jonathan 674 * HOWTO-Release: Filled in missing steps for releasing packages.
9959    
9960 bh 672 2003-04-15 Bernhard Herzog <[email protected]>
9961    
9962     First stab at internationalized messages:
9963    
9964     * Thuban/__init__.py (_): Implement the translation function for
9965     real using the python gettext module.
9966    
9967     * Thuban/UI/classifier.py (ClassTable.GetRowLabelValue): Don't
9968     translate empty strings.
9969    
9970     * Thuban/UI/application.py (ThubanApplication.read_startup_files):
9971     Add a missing space to a warning message
9972    
9973     * po/README: New. Notes about the management of the translation
9974     files.
9975    
9976     * po/Makefile: New. Makefile to help manage the translation files.
9977    
9978     * po/es.po: New. Spanish translation by Daniel Calvelo Aros
9979    
9980     * MANIFEST.in: Include the *.mo files in Resources/Locale and the
9981     translations and support files in po/
9982    
9983     * setup.py (data_files): Add the *.mo files to the data_files too
9984    
9985     * README: Add note about the translations when building from CVS
9986    
9987 jonathan 669 2003-04-14 Jonathan Coles <[email protected]>
9988    
9989     * Thuban/UI/dock.py: Fixes some window resizing problems most
9990     noticable under windows. Always assume the button bitmaps will
9991     be there. Code clean up.
9992     (DockabelWindow.Dock, DockableWindow.UnDock): Force all the
9993     images for the dock/undock button to the same images.
9994     Work around for RTbug #1801.
9995    
9996     * Thuban/UI/legend.py (LegendPanel.__init__): The toolbar should
9997     be allowed to grow within the sizer. Fixes a bug under Windows
9998     where the toolbar wasn't being drawn.
9999    
10000 frank 664 2003-04-14 Frank Koormann <[email protected]>
10001    
10002     * Resources/Bitmaps/dock_12.xpm, Resources/Bitmaps/undock_12.xpm:
10003     Updated design to try to make the button functionality more
10004     transparent.
10005    
10006 jonathan 662 2003-04-14 Jonathan Coles <[email protected]>
10007    
10008     * Thuban/UI/legend.py (LegendPanel.__init__): Call Create() to
10009     finalize the intialization of the panel.
10010    
10011     * Thuban/UI/dock.py (DockPanel.Create): New. Finalizes the
10012     creation of the panel. Should be the last thing called in the
10013     initializer of a subclass.
10014    
10015     * Thuban/UI/classgen.py (ClassGenDialog.__init__): Actively
10016     set the current selections in the combo boxes. This is needed
10017     under Windows.
10018    
10019     * Thuban/UI/classifier.py (Classifier.__init__): Add a top
10020     level panel to the dialog so that the background colors are
10021     consistent under Windows.
10022    
10023 jonathan 646 2003-04-11 Jonathan Coles <[email protected]>
10024    
10025 jonathan 662 * Thuban/UI/classgen.py: Change color ramps to start at white
10026     not black.
10027    
10028     * Thuban/UI/legend.py: Enable/disable the legend buttons when
10029     the legend changes. Fixes RTbug #1793.
10030    
10031     * test/test_classification.py: Added test for copying of
10032     classifications.
10033    
10034     2003-04-11 Jonathan Coles <[email protected]>
10035    
10036 jonathan 647 * Thuban/UI/resource.py: New. Centralize the loading of resources
10037     such as bitmaps.
10038    
10039     * Thuban/UI/classgen.py (GenUniquePanel.__init__): Reordered buttons,
10040     added images to the move buttons, added 'reverse' button.
10041     (CustomRampPanel.__init__): Added images to the move buttons.
10042     (GreyRamp): New. Generates a ramp from white to black.
10043     (HotToColdRamp): New. Generates a ramp from cold to hot colors.
10044    
10045     * Thuban/UI/classifier.py: Refactored ID's from ID_CLASSIFY_* to
10046     ID_PROPERTY_*.
10047     (Classifier.__init__): Minor changes to the layout.
10048     (Classifier._OnTitleChanged): Listen for when the user edits the
10049     title and update the dialog's title and the layer's title.
10050    
10051     * Thuban/UI/dock.py: Use new bitmaps for the control buttons.
10052    
10053     * Thuban/UI/legend.py: Use new bitmaps for the control buttons.
10054     (LegendTree._OnMsgLayerTitleChanged): Change the displayed title
10055     if the layer's title changes.
10056    
10057     * Thuban/UI/mainwindow.py: Added new menu item and associated code
10058     to open a dialog to rename the map.
10059     (MainWindow): Use new resource class to import bitmaps.
10060    
10061     2003-04-11 Jonathan Coles <[email protected]>
10062    
10063 jonathan 646 * Resources/Bitmaps/close_12.xpm, Resources/Bitmaps/dock_12.xpm,
10064 jonathan 647 Resources/Bitmaps/group_use.xpm, Resources/Bitmaps/group_use_all.xpm,
10065     Resources/Bitmaps/group_use_none.xpm,
10066     Resources/Bitmaps/group_use_not.xpm,
10067     Resources/Bitmaps/hide_layer.xpm,
10068     Resources/Bitmaps/layer_properties.xpm,
10069     Resources/Bitmaps/lower_layer.xpm, Resources/Bitmaps/raise_layer.xpm,
10070     Resources/Bitmaps/show_layer.xpm, Resources/Bitmaps/undock_12.xpm:
10071     New.
10072 jonathan 646
10073 jonathan 636 2003-04-10 Jonathan Coles <[email protected]>
10074    
10075 jonathan 644 * Thuban/Model/classification.py: (ClassGroupRange.__init__):
10076     Should pass group to ClassGroup constructor.
10077    
10078     2003-04-10 Jonathan Coles <[email protected]>
10079    
10080 jonathan 636 * Thuban/Model/classification.py: (ClassGroup): Move all the common
10081     methods of the derived classes ([Set|Get]Properties(), __eq__, __ne__)
10082     here. Implement SetVisible(), IsVisible().
10083     (ClassGroup.__init__): Add group parameter which acts as a copy
10084     constructor.
10085    
10086     * Thuban/UI/classifier.py (ClassTable): Add a new column for the
10087     "Visible" check boxes.
10088     (Classifier): Rename the buttons and refactor the code to match
10089     the new labels.
10090    
10091     * Thuban/UI/legend.py: Classify button is now called "Properties".
10092     Refactored the code to change variable names.
10093     (LegendTree.__FillTreeLayer): Only list a group if it is visible.
10094    
10095     * Thuban/UI/mainwindow.py: MainWindow.OpenClassifier renamed to
10096     MainWindow.OpenLayerProperties. MainWindow.LayerEditProperties
10097     renamed to MainWindow.LayerEditProperties.
10098     (MainWindow.ToggleLegend): Don't include map name in legend title.
10099     (MainWindow.SetMap): Added the map name to the window title.
10100     (MainWindow.LayerFillColor, MainWindow.LayerTransparentFill,
10101     MainWindow.LayerOutlineColor, MainWindow.LayerNoOutline): Removed.
10102     Functionality is found in the layer properties dialog.
10103    
10104     * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Only
10105     draw visible groups.
10106    
10107 jonathan 626 2003-04-09 Jonathan Coles <[email protected]>
10108    
10109 jonathan 634 * Thuban/UI/classgen.py: Modifications to allow simple
10110     addition and selection of new color schemes.
10111     (MonochromaticRamp): New. Generates a ramp between two colors.
10112     (RedRamp): New. Generates a ramp of all red.
10113     (GreenRamp): New. Generates a ramp of all green.
10114     (BlueRamp): New. Generates a ramp of all blue.
10115    
10116     2003-04-09 Jonathan Coles <[email protected]>
10117    
10118 jonathan 626 * Thuban/Model/classification.py (Classification.__deepcopy__):
10119     Need to copy over field and fieldType attributes.
10120    
10121     * Thuban/Model/table.py (Table.field_range): New. Retrive the
10122     maximum and minimum values over the entire table for a given
10123     field.
10124     (Table.GetUniqueValues): New. Retrieve all the unique values
10125     in the table for a given field.
10126    
10127     * Thuban/UI/classgen.py: Renamed GenRangePanel to GenUniformPanel.
10128     (GenUniquePanel): New. Controls to allow the user to select
10129     which unique field values they would like in the classification.
10130     (CustomRampPanel): Code that was in ClassGenDialog that allows
10131     the user to select the properties for a custom ramp.
10132     (ClassGenerator.GenUniformDistribution): Was called GenerateRanges.
10133    
10134     * Thuban/UI/classifier.py: Removed a lot of debugging code.
10135     (Classifier._SetClassification): Callback method so that the
10136     class generator can set the classification in the grid.
10137     (ClassGroupPropertiesCtrl): New. Encapsulates the drawing and
10138     editing of a group properties class into a wxWindows control.
10139    
10140     * Thuban/UI/dock.py: It was decided that if the user closes
10141     a dockable window the window should simply hide itself. That
10142     way if the user wants to show the dock again it appears in the
10143     same place as it was when it was closed.
10144     (DockableWindow.Destroy): Call renamed method OnDockDestroy().
10145     (DockableWindow._OnButtonClose): Hide the window instead of
10146     destroying it.
10147     (DockableWindow._OnClose): Hide the window instead of
10148     destroying it.
10149    
10150     * Thuban/UI/legend.py (LegendTree): Use a private method to
10151     consistently set the font and style of the text. Fixes RTbug #1786.
10152    
10153     * Thuban/UI/mainwindow.py: Import just the Classifier class.
10154    
10155 bh 623 2003-04-07 Bernhard Herzog <[email protected]>
10156    
10157 bh 625 * Thuban/UI/mainwindow.py (main_menu): Move the toggle_legend item
10158     to the map module
10159    
10160     2003-04-07 Bernhard Herzog <[email protected]>
10161    
10162 bh 623 * Thuban/UI/mainwindow.py (MainWindow.ShowSessionTree): Removed in
10163     favor of ToggleSessionTree
10164     (MainWindow.ToggleSessionTree): New method to toggle visibility of
10165     the session tree.
10166     (MainWindow.SessionTreeShown): New method to return whether the
10167     session tree is currently shown.
10168     (MainWindow.ToggleLegend): New method to toggle visibility of the
10169     legend
10170     (MainWindow.ShowLegend): Implement in terms of ToggleLegend and
10171     LegendShown
10172     (MainWindow.LegendShown): New method to return whether the legend
10173     is currently shown.
10174     (_method_command): Add checked parameter so we can define check
10175     menu items
10176     (_has_tree_window_shown, _has_legend_shown): Use the appropriate
10177     mainwindow methods.
10178     (show_session_tree, show_legend commands): Removed.
10179     (toggle_session_tree, toggle_legend commands): New commands to
10180     toggle the visibility of the dialogs
10181    
10182 jonathan 612 2003-04-07 Jonathan Coles <[email protected]>
10183    
10184 jonathan 619 * Thuban/UI/classgen.py: Fix Windows problem.
10185    
10186     * Thuban/UI/dock.py: Fix Windows problem.
10187    
10188     * Thuban/UI/mainwindow.py: Use False instead of false.
10189     (MainWindow.ShowLegend): Remove unnecessary switch parameter.
10190    
10191     2003-04-07 Jonathan Coles <[email protected]>
10192    
10193 jonathan 612 Since we now say that the order of the groups in a classification
10194     matters, it makes sense to be able to manipulate that order. Most
10195     of the changes to Thuban/Model/classification.py are to that end.
10196    
10197     * Thuban/Model/classification.py (Classification.AppendGroup,
10198     Classification.InsertGroup, Classification.ReplaceGroup,
10199     Classification.RemoveGroup, Classification.GetGroup): Do as the
10200     names imply.
10201     (Classification.FindGroup): This was called GetGroup, but GetGroup
10202     takes an index, while FindGroup takes a value.
10203     (Classification.__deepcopy__): Copy all the groups, BUT NOT THE LAYER
10204     REFERENCE. Currently there is a cyclic reference between the layer
10205     and its classification. If the classification doesn't need to know
10206     its owning layer we can change this, since it may make sense to be
10207     able to use the same classification with different layers.
10208    
10209     * Thuban/Model/load.py: Use Classification.AppendGroup(), not AddGroup()
10210    
10211     * Thuban/UI/classgen.py: Use Classification.AppendGroup(),
10212     not AddGroup()
10213    
10214     * Thuban/UI/classifier.py: Now that we can depend on the order in
10215     a Classification and have methods to manipulate that order we don't
10216     need to use our own data structures in the grid. We can simply make
10217     the grid/table access the information they need from a copy of
10218     the classification object.
10219     (Classifier._OnCloseBtn): Event handler for when the user clicks
10220     'Close'. This is needed so if the user applies changes and then
10221     continues to change the table the user has the option of discarding
10222     the most recent changes and keeping what they applied.
10223    
10224     * Thuban/UI/mainwindow.py: Put "Show Legend" and "Show Session Tree"
10225     into the same group.
10226    
10227     * extensions/thuban/wxproj.cpp (check_version): If Thuban is compiled
10228     with a really old version of proj, PJ_VERSION won't even be defined.
10229     If it isn't defined then just compile so that the function always
10230     returns Py_False.
10231    
10232     * test/test_classification.py: Fix tests to use the renamed methods.
10233     Still need to write tests for the new methods.
10234    
10235 jonathan 601 2003-04-04 Jonathan Coles <[email protected]>
10236 jonathan 608
10237 jonathan 612 * Thuban/UI/classifier.py (Classifier.__SelectField): Move the
10238     call to SetSelection out of the method and before the call
10239     to __SelectField in __init__. This prevents a recursion of events
10240     when _OnFieldSelect is triggered by the user.
10241    
10242     2003-04-04 Jonathan Coles <[email protected]>
10243    
10244 jonathan 608 * Thuban/Model/classification.py: Rename Color.None to
10245     Color.Transparent.
10246     (ClassGroupProperties.SetLineColori, ClassGroupProperties.SetFill):
10247     Don't bother copying the color, since Colors are immutable.
10248    
10249     * Thuban/Model/color.py, Thuban/Model/layer.py, Thuban/Model/load.py,
10250     Thuban/UI/classifier.py, Thuban/UI/mainwindow.py,
10251     Thuban/UI/renderer.py, Thuban/UI/view.py:
10252     Rename Color.None to Color.Transparent.
10253    
10254     * test/test_classification.py, test/test_load.py: Rename Color.None
10255     to Color.Transparent.
10256    
10257     2003-04-04 Jonathan Coles <[email protected]>
10258 jonathan 603
10259     * Thuban/Model/classification.py: Fix assert calls.
10260     (ClassGroupProperties.SetLineColor, ClassGroupProperties.SetFill):
10261     Copy the color parameter rather than hold onto a reference.
10262 jonathan 601
10263 jonathan 603 * Thuban/Model/color.py (Color.__copy__, Color.__deepcopy): Copy
10264     the color object.
10265     (NoColor.__copy__, NoColor.__deepcopy): Return 'self' so that we
10266     are sure there exists only one refernce to Color.None in the system.
10267     This allows us to use 'is' rather than the comparision functions.
10268    
10269     * Thuban/Model/save.py: Fix assert calls.
10270    
10271     * Thuban/UI/classifier.py: Fix assert calls.
10272     (ClassGrid._OnCellDClick): Call up to the classifier to open the
10273     dialog to edit the groups properties.
10274     (ClassGrid._OnCellResize): Make sure that the scollbars are drawn
10275     correctly if a cell is resized.
10276     (ClassTable.SetClassification): New. Changes the classification
10277     that is in the table.
10278     (ClassTable.__SetRow): Allow groups to be prepended.
10279     (Classifier): New code for opening the EditProperties and
10280     GenerateRanges dialogs.
10281     (SelectPropertiesDialog.__GetColor): Only set the color in the
10282     color dialog if the current color is not None.
10283    
10284     * Thuban/UI/dock.py: Fix assert calls.
10285    
10286     * Thuban/UI/legend.py: Fix assert calls.
10287    
10288     * Thuban/UI/renderer.py: Fix assert calls.
10289    
10290     * Thuban/UI/classgen.py (ClassGenDialog): Dialog for generating
10291     classifications.
10292     (GenRangePanel): Panel specific to range generation.
10293     (GenSingletonPanel): Panel specific to singleton generation.
10294     (ClassGenerator): Class responsible for actually generating
10295     the classification from the data gathered in the dialog box.
10296     (PropertyRamp): Generates properties whose values range from
10297     a starting property to an ending property.
10298 jonathan 601
10299 bh 600 2003-04-03 Bernhard Herzog <[email protected]>
10300    
10301     * test/support.py (print_garbage_information): New function that
10302     prints information about still connected messages and memory
10303     leaks.
10304     (run_suite): Removed.
10305     (run_tests): New function for use as a replacement of
10306     unittest.main in the test_* files. This one calls
10307     print_garbage_information at the end.
10308    
10309     * test/runtests.py (main): Use support.print_garbage_information
10310    
10311     * test/test_layer.py: Use support.run_tests instead of
10312     unittest.main so we get memory leak information
10313     (TestLayer.test_arc_layer, TestLayer.test_polygon_layer)
10314     (TestLayer.test_point_layer, TestLayer.test_empty_layer)
10315     (TestLayerLegend.test_visibility): Call the layer's Destroy method
10316     to fix a memory leak.
10317    
10318     * test/test_classification.py: Use support.run_tests instead of
10319     unittest.main so we get memory leak information
10320     (TestClassification.test_classification): Call the layer's Destroy
10321     method to fix a memory leak.
10322    
10323 bh 591 2003-04-02 Bernhard Herzog <[email protected]>
10324    
10325 bh 595 * extensions/thuban/wxproj.cpp (check_version, check_version_gtk):
10326     Handle the reference counts of the return value and errors in
10327     PyArg_ParseTuple correctly.
10328    
10329 bh 593 * Thuban/UI/application.py (ThubanApplication.OpenSession): Make
10330     sure the filename is absolute to avoid problems when saving the
10331     session again
10332    
10333 bh 591 * Thuban/Model/table.py: Remove unnecessary import. Fix a typo.
10334    
10335 jonathan 587 2003-04-01 Jonathan Coles <[email protected]>
10336    
10337 jonathan 589 * Thuban/UI/renderer.py (MapRenderer.draw_point_shape): Check
10338 jonathan 587 that there actually are points in the returned list of points
10339     before trying to index into the list. The list may be empty if
10340     the shape is a Null Shape.
10341    
10342 bh 586 2003-04-01 Bernhard Herzog <[email protected]>
10343    
10344     * test/test_map.py: Don't use from <module> import *
10345    
10346 jonathan 581 2003-04-01 Jonathan Coles <[email protected]>
10347    
10348     * Thuban/Model/session.py: Use LAYER_CHANGED instead of
10349     LAYER_LEGEND_CHANGED
10350    
10351     * Thuban/UI/dock.py (DockableWindow._OnButtonClose): Call
10352     self.Destroy() to close the window after yesterday's changes.
10353    
10354     * test/test_map.py, test/test_session.py: Fix messages that
10355     are sent from maps and layers.
10356    
10357 jonathan 575 2003-03-31 Jonathan Coles <[email protected]>
10358    
10359     * Thuban/UI/classifier.py: Commented out some debugging statements.
10360     (ClassDataPreviewer.Draw): Draw rectangles for polygon layers per
10361     RTbug #1769.
10362    
10363     * Thuban/UI/dock.py (DockableWindow.UnDock): Restore size and
10364     position (although position doesn't work yet under GTK).
10365     (DockableWindow.Destroy): New. Called when the window must be
10366     closed. Namely needed when the DockFrame closes and must close
10367     its children.
10368     (DockFrame): Listen for EVT_CLOSE and destroy all children.
10369    
10370     * Thuban/UI/legend.py (LegendPanel.Destroy): New. Cleans up
10371     when then window is told to close.
10372     (LegendTree._OnMsgLayerChanged): Fixes a seg fault bug. See
10373     comment in source for more info.
10374    
10375     * Thuban/UI/main.py: Show the legend by default when Thuban starts.
10376    
10377     * Thuban/UI/mainwindow.py: Renamed OnClose to _OnClose for
10378     symmetry with other such methods.
10379     (MainWindow.ShowLegend): Show the legend docked by default.
10380    
10381 jonathan 569 2003-03-28 Jonathan Coles <[email protected]>
10382    
10383     * Thuban/UI/classifier.py: Support for highlighting a specific
10384     group within the grid when the classification dialog is opened.
10385     Also contains a lot of debugging printouts which will later
10386     be removed.
10387    
10388     * Thuban/UI/dock.py: Complete rework on the dock code so that
10389     that it is fairly removed from the rest of the Thuban application.
10390     It is easy to add new docks which the rest of the program having
10391     to be aware of them.
10392    
10393     * Thuban/UI/legend.py: Modifications to support selecting a
10394     specific group in the classification dialog. Changed how layers
10395     are drawn when the layer is visible/invisible.
10396    
10397     * Thuban/UI/mainwindow.py: Removed legend specific code and
10398     replaced it with calls to the new dock code.
10399    
10400     * Thuban/UI/renderer.py (MapRenderer.__init__): Added assert
10401     to check if scale > 0. Trying to track down a divide by zero.
10402    
10403 jonathan 557 2003-03-26 Jonathan Coles <[email protected]>
10404    
10405 jonathan 567 * Thuban/UI/legend.py: Removed unnecessary LegendDialog class.
10406     (LegendPanel): Removed _OnDock()/_OnUnDock() methods which are
10407     now part of DockableWindow.
10408     (LegendPanel.DoOnSelChanged): Select the current layer in the
10409     map.
10410     (LegendTree._OnSelChanged): Call LegendPanel.DoOnSelChanged()
10411     with the selected layer and/or group.
10412    
10413     2003-03-26 Jonathan Coles <[email protected]>
10414    
10415 jonathan 557 This putback contains the code for dockable windows. There is
10416     no support in wxWindows as of this date for windows that can
10417     attach themselves to other windows.
10418    
10419     The current model contains a DockableWindow which has a parent
10420     window for when it is detached and a dock window that it puts
10421     its contents in when it is docked. The contents of a DockableWindow
10422     must be a DockPanel. DockPanel itself derives from wxPanel.
10423    
10424     * Thuban/Model/layer.py (Layer.ClassChanged): Send a LAYER_CHANGED
10425     message, not a LAYER_LEGEND_CHANGED message.
10426    
10427     * Thuban/Model/map.py (Map): Forward LAYER_CHANGED messages.
10428    
10429     * Thuban/UI/classifier.py (Classifier.__init__): Use wxADJUST_MINSIZE
10430     as one of the style properties for the fieldTypeText item to
10431     be sure that its size is correct when the text changes.
10432    
10433     * Thuban/UI/dock.py: New. Classes for the DockPanel and
10434     DockableWindow.
10435    
10436     * Thuban/UI/legend.py: Added some more buttons and made the
10437     LegendPanel a DockPanel.
10438    
10439     * Thuban/UI/mainwindow.py: Added sash windows to the main window
10440     and supporting functions for manipulating the sashes.
10441     (MainWindow.ShowLegend): Create a DockableWindow with the
10442     LegendPanel as the contents.
10443    
10444     * Thuban/UI/messages.py: Added DOCKABLE_* messages
10445    
10446     * Thuban/UI/view.py (MapCanves.SetMap): Listen for LAYER_CHANGED,
10447     not LAYER_LEGEND_CHANGED, messages.
10448    
10449 jonathan 554 2003-03-25 Jonathan Coles <[email protected]>
10450    
10451     * setup.py: Added custom script bdist_rpm_build_script so that
10452     when the rpm is built the path to wx-config is correct.
10453    
10454     * setup.cfg: Added line saying to use the custom build script
10455    
10456 jonathan 552 2003-03-20 Jonathan Coles <[email protected]>
10457    
10458     Initial implementation of the Legend.
10459    
10460     * Thuban/UI/legend.py: New. Creates a window that shows the map's
10461     Legend information and allows the user to add/modify classifications
10462     and how the layers are drawn on the map.
10463    
10464     * setup.py: New command 'build_docs' which currently uses
10465     happydoc to generate html documentation for Thuban.
10466    
10467     * Thuban/Model/classification.py (ClassGroup.GetDisplayText): New.
10468     Returns a string which is appropriately describes the group.
10469    
10470     * Thuban/Model/layer.py (Layer.SetClassification): Generate a
10471     LAYER_CHANGED event instead of a LAYER_LEGEND_CHANGED event.
10472    
10473     * Thuban/Model/map.py (Map): Rename messages and use new, more
10474     specific, messages.
10475    
10476     * Thuban/Model/messages.py: New message to indicate that a layer's
10477     data has changed (LAYER_CHANGED). New map messages to indicate
10478     when layers have been added/removed/changed or if the stacking order
10479     of the layers has changed.
10480    
10481     * Thuban/Model/session.py: Rename and use new messages.
10482    
10483     * Thuban/UI/classifier.py: Remember if any changes have actually
10484     been applied so that if the dialog is cancelled without an application
10485     of changes we don't have to set a new classification.
10486     (ClassDataPreviewer): Pulled out the window specific code and put it
10487     ClassDataPreviewWindow. ClassDataPreviewer can then be used to draw
10488     symbols on any DC.
10489    
10490     * Thuban/UI/mainwindow.py: New code to open the legend.
10491    
10492     * Thuban/UI/view.py: Use new message names.
10493    
10494 jonathan 541 2003-03-19 Jonathan Coles <[email protected]>
10495    
10496     * Thuban/UI/main.py (verify_versions): New. Checks the versions
10497     of Python, wxPython, and some other libraries.
10498    
10499     * extensions/thuban/wxproj.cpp (check_version): Checks the given
10500     version against what wxproj was compiled with.
10501     (check_version_gtk): If wxproj was compiled with gtk then check
10502     the given version against the version of the gtk library
10503     currently being used.
10504    
10505 bh 538 2003-03-14 Bernhard Herzog <[email protected]>
10506    
10507     * test/test_command.py: Run the tests when the module is run as a
10508     script
10509    
10510     2003-03-14 Bernhard Herzog <[email protected]>
10511    
10512     Implement selection of multiple selected shapes in the same layer:
10513    
10514     - Introduce a new class to hold the selection. This basically
10515     replaces the interactor which was nothing more than the
10516     selection anyway. A major difference is of course that the new
10517     selection class supports multiple selected shapes in one layer
10518    
10519     - Move the object that represents the selection from the
10520     application to the canvas. The canvas is a better place than the
10521     application because the selection represents which shapes and
10522     layer of the map displayed by the canvas are selected and
10523     affects how the map is drawn.
10524    
10525     - Make the selection and its messages publicly available through
10526     the mainwindow.
10527    
10528     - The non-modal dialogs do not get a reference to the interactor
10529     anymore as they can simply refer to their parent, the
10530     mainwindow, for the what the interactor had to offer.
10531    
10532     * Thuban/UI/selection.py: New module with a class to represent the
10533     selection.
10534    
10535     * Thuban/UI/messages.py (SELECTED_TABLE, SELECTED_MAP): Remove
10536     these unused messages
10537    
10538     * Thuban/UI/application.py (ThubanApplication.OnInit)
10539     (ThubanApplication.OnExit, ThubanApplication.SetSession): The
10540     interactor is gone now.
10541     (ThubanApplication.CreateMainWindow): There is no interactor
10542     anymore so we pass None as the interactor argument for now for
10543     compatibility.
10544    
10545     * Thuban/UI/view.py (MapCanvas.delegated_messages)
10546     (MapCanvas.Subscribe, MapCanvas.Unsubscribe): In Subscribe and
10547     Unsubscribe, delegate messages according to the delegated_messages
10548     class variable.
10549     (MapCanvas.__getattr__, MapCanvas.delegated_methods): Get some
10550     attributes from instance variables as described with the
10551     delegated_methods class variable.
10552     (MapCanvas.__init__): New instance variable selection holding the
10553     current selection
10554     (MapCanvas.do_redraw): Deal with multiple selected shapes. Simply
10555     pass them on to the renderer
10556     (MapCanvas.SetMap): Clear the selection when a different map is
10557     selected.
10558     (MapCanvas.shape_selected): Simple force a complete redraw. The
10559     selection class now takes care of only issueing SHAPES_SELECTED
10560     messages when the set of selected shapes actually does change.
10561     (MapCanvas.SelectShapeAt): The selection is now managed in
10562     self.selection
10563    
10564     * Thuban/UI/mainwindow.py (MainWindow.delegated_messages)
10565     (MainWindow.Subscribe, MainWindow.Unsubscribe): In Subscribe and
10566     Unsubscribe, delegate messages according to the delegated_messages
10567     class variable.
10568     (MainWindow.delegated_methods, MainWindow.__getattr__): Get some
10569     attributes from instance variables as described with the
10570     delegated_methods class variable.
10571     (MainWindow.__init__): The interactor as ivar is gone. The
10572     parameter is still there for compatibility. The selection messages
10573     now come from the canvas.
10574     (MainWindow.current_layer, MainWindow.has_selected_layer):
10575     Delegate to the the canvas.
10576     (MainWindow.LayerShowTable, MainWindow.Classify)
10577     (MainWindow.identify_view_on_demand): The dialogs don't need the
10578     interactor parameter anymore.
10579    
10580     * Thuban/UI/tableview.py (TableFrame.__init__)
10581     (LayerTableFrame.__init__, LayerTableFrame.OnClose)
10582     (LayerTableFrame.row_selected): The interactor is gone. It's job
10583     from the dialog's point of view is now done by the mainwindow,
10584     i.e. the parent. Subscribe to SHAPES_SELECTED instead
10585     of SELECTED_SHAPE
10586    
10587     * Thuban/UI/dialogs.py (NonModalDialog.__init__): The interactor
10588     is gone. It's job from the dialog's point of view is now done by
10589     the mainwindow, i.e. the parent.
10590    
10591     * Thuban/UI/classifier.py (Classifier.__init__): The interactor is
10592     gone. It's job from the dialog's point of view is now done by the
10593     mainwindow, i.e. the parent.
10594    
10595     * Thuban/UI/tree.py (SessionTreeView.__init__): The interactor is
10596     gone. It's job from the dialog's point of view is now done by the
10597     mainwindow, i.e. the parent.
10598     (SessionTreeCtrl.__init__): New parameter mainwindow which is
10599     stored as self.mainwindow. The mainwindow is need so that the tree
10600     can still subscribe to the selection messages.
10601     (SessionTreeCtrl.__init__, SessionTreeCtrl.unsubscribe_all)
10602     (SessionTreeCtrl.update_tree, SessionTreeCtrl.OnSelChanged): The
10603     selection is now accessible through the mainwindow. Subscribe to
10604     SHAPES_SELECTED instead of SELECTED_SHAPE
10605    
10606     * Thuban/UI/identifyview.py (IdentifyView.__init__): Use the
10607     SHAPES_SELECTED message now.
10608     (IdentifyView.selected_shape): Now subscribed to SHAPES_SELECTED,
10609     so deal with multiple shapes
10610     (IdentifyView.__init__, IdentifyView.OnClose): The interactor is
10611     gone. It's job from the dialog's point of view is now done by the
10612     mainwindow, i.e. the parent.
10613    
10614     * Thuban/UI/controls.py (RecordListCtrl.fill_list): The second
10615     parameter is now a list of shape ids.
10616     (RecordTable.SetTable): The second parameter is now a list of
10617     indices.
10618    
10619     * Thuban/UI/renderer.py (ScreenRenderer.RenderMap): Rename the
10620     selected_shape parameter and ivar to selected_shapes. It's now a
10621     list of shape ids.
10622     (MapRenderer.draw_label_layer): Deal with multiple selected
10623     shapes. Rearrange the code a bit so that the setup and shape type
10624     distinctions are only executed once.
10625    
10626     * test/test_selection.py: Test cases for the selection class
10627    
10628 jonathan 527 2003-03-11 Jonathan Coles <[email protected]>
10629    
10630     * Thuban/Model/load.py: Temporary fix so that the xml reader
10631     doesn't cause Thuban to crash.
10632    
10633     * Thuban/Model/layer.py: Handle the cyclic references between
10634     a layer and its classification better, and be sure to disconnect
10635     the classification from the layer when the layer is destroyed
10636     so that we don't maintain a cyclic reference that may not be
10637     garbage collected.
10638    
10639     * Thuban/Model/classification.py: See comment for layer.py.
10640    
10641 jan 523 2003-03-12 Jan-Oliver Wagner <[email protected]>
10642    
10643     * HOWTO-Release: New. Information on the steps for releasing
10644     a new version of Thuban.
10645    
10646 jonathan 514 2003-03-11 Jonathan Coles <[email protected]>
10647    
10648     * Thuban/UI/classifier.py: Add normal border to SelectPropertiesDialog.
10649     Use True instead of true.
10650     (Classifier): Should have a single panel in which all the controls lie.
10651    
10652     * Thuban/UI/proj4dialog.py: Add normal border.
10653    
10654     * Thuban/UI/tree.py: Fixed problem with bad item images under Windows.
10655    
10656     * Thuban/UI/mainwindow.py: Use True instead of true.
10657    
10658     * setup.py: Update some definitions to use wxWindows2.4 files
10659    
10660     * Data/iceland_sample_class.thuban: Fixed file so that the
10661     field_type information is present.
10662    
10663 jonathan 490 2003-03-10 Jonathan Coles <[email protected]>
10664    
10665 jonathan 505 * Thuban/UI/classifier.py (Classifier.__init__): Make the
10666     field type label grow so that when the text changes the
10667     size is updated correctly. This may be a wxWindows bug.
10668    
10669     2003-03-10 Jonathan Coles <[email protected]>
10670    
10671 jonathan 499 * Thuban/UI/application.py: Changed SESSION_CHANGED to
10672     SESSION_REPLACED.
10673    
10674     * Thuban/UI/classifier.py: Wrap text with _().
10675     (ClassGrid.CreateTable): Set dimensions and size hints here,
10676     instead of in Reset, so we only set the size once.
10677    
10678     * Thuban/UI/dialogs.py: Don't need Shutdown(); just use Close()!
10679    
10680     * Thuban/UI/mainwindow.py (MainWindow.prepare_new_session):
10681     Call Close() instead of Shutdown().
10682    
10683     * Thuban/UI/messages.py: Changed SESSION_CHANGED to SESSION_REPLACED.
10684    
10685     * Thuban/UI/tree.py: Changed SESSION_CHANGED to SESSION_REPLACED.
10686     Go back to using OnClose() instead of Shutdown().
10687    
10688     2003-03-10 Jonathan Coles <[email protected]>
10689    
10690 jonathan 497 * Thuban/UI/classifier.py (Classifier): SelectField() needed
10691     to know the old field index as well as the new one.
10692    
10693     2003-03-10 Jonathan Coles <[email protected]>
10694    
10695 jonathan 495 * Thuban/UI/classifier.py (Classifier): Use __SelectField()
10696     to correctly set the table information and call this from
10697     __init__ and from _OnFieldSelect so that all the information
10698     is up to date when the dialog opens and when a field is changed.
10699    
10700     2003-03-10 Jonathan Coles <[email protected]>
10701    
10702 jonathan 490 * Thuban/Model/classification.py (Classification): Don't use
10703     layer's message function directly, use the ClassChanged() method
10704     when then classification changes. SetField/SetFieldType/SetLayer
10705     must keep the information about field name and field type in
10706     sync when an owning layer is set or removed.
10707    
10708     * Thuban/Model/layer.py: Added ClassChanged() so that the
10709     classification can tell the layer when its data has changed.
10710     (Layer.SetClassification): Accepts None as an arguement to
10711     remove the current classification and correctly handles
10712     adding a new classification.
10713    
10714     * Thuban/Model/load.py: Comment out print statement
10715    
10716     * test/test_classification.py, test/test_save.py: New and
10717     improved tests.
10718    
10719 jonathan 483 2003-03-07 Jonathan Coles <[email protected]>
10720    
10721     * Thuban/Model/classification.py: Implemented __copy__ and
10722     __deepcopy__ for ClassGroup* and ClassGroupProperites so
10723     they can easily be copied by the classifier dialog.
10724     (ClassGroupProperites.__init__): The default line color should
10725     have been Color.Black.
10726    
10727     * Thuban/UI/classifier.py: Setting and Getting table values now
10728     uses a consistent set of functions.
10729     (Classifier): Now non-modal. Has field type label which changes
10730     as the field changes. Keep track of buttons in a list so that
10731     we can enable/disable the buttons when the None field is selected.
10732     (SelectPropertiesDialog): Add buttons to make the colors transparent.
10733    
10734     * Thuban/UI/dialogs.py (NonModalDialog.Shutdown): New method which
10735     does what OnClose did, but can be called by the application to
10736     close a window. Needed when a session changes, and we have to
10737     close the classifier windows.
10738    
10739     * Thuban/UI/mainwindow.py (MainWindow.prepare_new_session):
10740     Shuts down open dialogs. Used when a new session is created
10741     or a session is opened.
10742     (MainWindow.SaveSession): Should only call application.SaveSession()
10743     if we don't call SaveSessionAs first.
10744     (MainWindow.Classify): Allow different classifier dialogs for
10745     different layers.
10746    
10747     * Thuban/UI/tree.py (SessionTreeView): Remove OnClose and let
10748     the parent class handle it. Add Shutdown() to unsubscibe from
10749     event notification and call the parent Shutdown(). This was
10750     necessary so the application can close the tree window.
10751    
10752 jonathan 478 2003-03-06 Jonathan Coles <[email protected]>
10753    
10754     * Thuban/Model/classification.py: Minor documentation changes,
10755     Addition of __eq__ and __ne__ methods.
10756     (Classification.SetLayer): prevent recursion between this method
10757     and Layer.SetClassification().
10758    
10759     * Thuban/Model/color.py: Addition of __eq__ and __ne__ methods.
10760    
10761     * Thuban/Model/layer.py (SetClassification): prevent recursion
10762     between this method and Classification.SetLayer().
10763    
10764     * test/test_classification.py, test/test_load.py,
10765     test/test_session.py: Fixed and added tests for the classification
10766     classes.
10767    
10768 bh 477 2003-03-06 Bernhard Herzog <[email protected]>
10769    
10770     * Thuban/UI/classifier.py (ClassGrid.__init__)
10771     (ClassGrid.CreateTable): Move the SetSelectionMode call to
10772     CreateTable because otherwise it triggers an assertion in
10773     wxPython/wxGTK 2.4.
10774    
10775 jonathan 459 2003-03-05 Jonathan Coles <[email protected]>
10776    
10777 jonathan 475 * Thuban/common.py: Move FIELDTYPE constants back to table.py.
10778 jonathan 471
10779 jonathan 475 * Thuban/Model/load.py: import FIELDTYPE constants from table.
10780 jonathan 471
10781 jonathan 475 * Thuban/UI/classifier.py: import FIELDTYPE constants from table.
10782 jonathan 471
10783 jonathan 475 * Thuban/Model/table.py: Put FIELDTYPE constants back.
10784 jonathan 471
10785     2003-03-05 Jonathan Coles <[email protected]>
10786    
10787 jonathan 459 * Thuban/UI/classifier.py: Added class documentation.
10788     Fixed RTbug #1713, #1714. Added Move[Up|Down] buttons.
10789     Store just the groups in the table and generate the other
10790     column information when it is requested. Add "None" field
10791     to pull-down to select no classification.
10792    
10793     * Thuban/common.py: Moved FIELDTYPE constants from table.py
10794     (Str2Num): Only catch ValueError exceptions.
10795    
10796     * Thuban/Model/classification.py: Class documentation. Renaming
10797     of methods with Stroke to Line. Groups are stored in a single
10798     list with the default as the first element. Groups are searched
10799     in the order they appear in the list.
10800    
10801     * Thuban/Model/color.py: Documentation.
10802    
10803     * Thuban/Model/layer.py (Layer): Add GetFieldType to retreive
10804     the kind of data represented by a field.
10805    
10806     * Thuban/Model/load.py (ProcessSession): Use proper string
10807     conversion function; fixes RTbug #1713.
10808    
10809     * Thuban/Model/save.py (Saver): Store field type information.
10810    
10811     * Thuban/Model/table.py: Put FIELDTYPE constants in common.py.
10812     (Table): Add field_info_by_name() to retrieve field information
10813     by specifying the field name, not the number.
10814    
10815     * Thuban/UI/mainwindow.py: Function name changes.
10816    
10817     * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Only
10818     get the layer classification once. Don't try to classify
10819     values when the field is None: just use the default properties.
10820    
10821     * Thuban/UI/view.py: Function name changes.
10822    
10823     * Doc/thuban.dtd: Add field_type attribute to a classification.
10824    
10825 bh 456 2003-03-04 Bernhard Herzog <[email protected]>
10826    
10827 bh 458 * Doc/thuban.dtd: Use correct syntax for optional attributes. Make
10828     the fill and stroke layer attributes optional with suitable
10829     default values. Add the stroke_width layer attribute. Use correct
10830     syntax for empty elements. Make the attribute list for labels
10831     refer to the label element.
10832    
10833     2003-03-04 Bernhard Herzog <[email protected]>
10834    
10835 bh 456 * setup.py (thuban_build_py.build): Add a comment about distutils in
10836     Python 2.3 containing some of the functionality we implement in
10837     setup.py ourselves.
10838    
10839     * Thuban/UI/classifier.py (ClassGrid.__init__): Set the table
10840     before the selection mode. Doing it the other way round triggers
10841     an assertion in wxWindows.
10842    
10843     * Thuban/Model/save.py (escape): Fix typo in doc-string
10844    
10845     * Thuban/Model/classification.py: Remove unnecessary wxPython
10846     import
10847    
10848 jonathan 448 2003-03-04 Jonathan Coles <[email protected]>
10849    
10850     * Thuban/Model/classification.py (ClassGroupRange.GetProperties):
10851     Parameter 'value' should default to None.
10852    
10853     * Thuban/UI/mainwindow.py: Use Layer.GetClassification() since
10854     the class attribute __classification is now private.
10855    
10856     * Thuban/UI/classifier.py (ClassGrid): Moved OnCellDClick() from
10857     Classifier to ClassGrid. Added support for removing selected rows,
10858     which including code for keeping track of when cells are selected,
10859     and deselected.
10860     (ClassTable): Support for added/removing rows. Fixed a problem
10861     with __ParseInput whereby it would not allow strings (only numbers)
10862     to be entered.
10863     (Classifier): Added button and supporting code for removing
10864     selected rows.
10865    
10866 jonathan 445 2003-02-27 Jonathan Coles <[email protected]>
10867 jonathan 434
10868     * Thuban/common.py: Moved color conversion functions into
10869     Thuban/UI/common.py.
10870     (Str2Num): Now converts the float (not the string) to a long/int
10871     so that an exception isn't thrown.
10872    
10873     * Thuban/UI/common.py: Common functions used in several UI modules
10874    
10875     * Thuban/Model/classification.py: Changed the class hierarchy
10876     so that a Classification consists of Groups which return
10877     Properties when a value matches a Group.
10878    
10879     * Thuban/Model/layer.py: Fixed name resolution problem.
10880    
10881     * Thuban/Model/load.py: Use new Classification and Group functions.
10882    
10883     * Thuban/Model/save.py (Saver.write_attribs): Fixes a test case
10884     failure.
10885     (Saver.write_classification): Use new Classification and Group
10886     functions.
10887    
10888     * Thuban/UI/classifier.py: Changes to use new Classification and Group
10889 jonathan 445 functions. Fix to create a tuple with a single value instead of
10890     simply returning the value.
10891 jonathan 434
10892     * Thuban/UI/renderer.py: Use new Classification and Group functions.
10893     Use common.py functions.
10894    
10895 jonathan 445 * Thuban/UI/tree.py: Use common.py functions.
10896 jonathan 447
10897     * test/test_classification.py: Use new Classification and Group
10898     classes.
10899 jonathan 434
10900 jonathan 426 2003-02-24 Jonathan Coles <[email protected]>
10901    
10902     * Thuban/common.py (Color2wxColour, wxColour2Color): Conversion
10903     functions from Thuban color objects to wxWindow colour objects.
10904    
10905     * Thuban/Model/classification.py (Classification): Renamed
10906     GetProperties() to GetClassData(). Used the new iterator
10907     in TreeInfo().
10908     (ClassIterator): Iterator implementation to iterate over the
10909     ClassData objects in a classification object.
10910    
10911     * Thuban/Model/save.py (Saver.write_classificaton): Uses
10912     the new iterator to save the classification information.
10913    
10914     * Thuban/UI/classifier.py (SelectPropertiesDialog): Support
10915     for changing the stroke and fill colors and previewing the
10916     changes.
10917    
10918     * Thuban/UI/mainwindow.py (MainWindow.OpenSession,
10919     MainWindow.SaveSessionAs): Text string changes so the dialogs
10920     have more meaningful titles.
10921    
10922     * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Change
10923     Classification method name from GetProperties to GetClassData.
10924    
10925     * Thuban/UI/view.py (MapCanvas.find_shape_at): Use method calls
10926     instead of accessing now non-existent class variables.
10927    
10928 bh 425 2003-02-24 Bernhard Herzog <[email protected]>
10929    
10930     * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Remove
10931     unneeded Shape() call. Rendering is substantially faster without
10932     it and it avoids some problems with broken shape files.
10933    
10934 frank 423 2003-02-20 Frank Koormann <[email protected]>
10935    
10936     Force minimal size of identify and label dialogs. The autosizing
10937     looked too ugly.
10938    
10939     * Thuban/UI/controls.py (RecordListCtrl): Set minimal width for columns.
10940     * Thuban/UI/labeldialog.py (LabelDialog.dialog_layout):
10941     Set size of listctrl.
10942     * Thuban/UI/identifyview.py (IdentifyView.__init__):
10943     Set size of dialog.
10944    
10945 jonathan 408 2003-02-19 Jonathan Coles <[email protected]>
10946    
10947     * test/test_classification.py, test/test_layer.py,
10948     test/test_load.py, test/test_map.py, test/test_session.py:
10949     Updated the tests to use the new functions that are in the
10950     respective classes.
10951    
10952     * Thuban/Model/classification.py (Classification):
10953     Uses the new ClassData* classes. Modification messages are
10954     passed up to the parent layer (if it exists).
10955     (ClassData): New class to encapsulate the common data in each
10956     classification property.
10957     (ClassDataDefault): Represents the Default class. data.
10958     (ClassDataPoint): Represents a single class. data point
10959     (ClassDataRange): Represents a class. range
10960     (ClassDataMap): Represents a class. map (unused).
10961    
10962     * Thuban/Model/color.py: Added Color.None to represent something
10963     with no color. Color.Black represents the color black.
10964     (NoColor): Helper class derived from Color to represent something
10965     with no color.
10966    
10967     * Thuban/Model/layer.py (Layer): Removed references to fill, stroke,
10968     stroke_width attributes. Made the 'classification' attribute private.
10969     New methods for setting/getting the classification.
10970    
10971     * Thuban/Model/load.py (ProcessSession): Use new methods on Layer
10972     to get the classifcation and use the new ClassData* classes to
10973     hold the classification data. Use Str2Num to convert numbers
10974     properly.
10975    
10976     * Thuban/Model/save.py (Saver): Use new Color and Classification
10977     methods
10978    
10979     * Thuban/UI/classifier.py (ClassGrid): New class to represent a
10980     custom grid.
10981     (ClassTable): Support for editing Values and Labels and for
10982     changing what type (point or range) of data is stored in each
10983     property based on how the user enters the data.
10984     (Classifier): Support for saving the new classifications and
10985     launching the dialog to edit a property.
10986     (SelectPropertiesDialog): New class for editing the visual
10987     properties of a classification (stroke color, width, and fill color)
10988     (ClassPreviewer): Took the Draw method from ClassRenderer and
10989     made most of it into this new class. Intend to use this class in
10990     the SelectPropertiesDialog for previewing changes.
10991    
10992     * Thuban/UI/renderer.py: Use new Color and Classification methods.
10993    
10994     * Thuban/UI/tree.py: Formatting changes.
10995    
10996     * Doc/thuban.dtd: Add 'label' element
10997    
10998     * Thuban/common.py: New. Contains common routines used throughout
10999     the code.
11000     (Str2Num): Takes a string and converts it to the "best" type of
11001     number.
11002    
11003 bh 405 2003-02-14 Bernhard Herzog <[email protected]>
11004    
11005     * Thuban/UI/view.py (MapCanvas.OnLeftUp): Make sure that the
11006     dragging flag is always set to 0 even when the tool implementation
11007     raises an exception
11008    
11009 bh 402 2003-02-11 Bernhard Herzog <[email protected]>
11010    
11011     * Thuban/UI/application.py (ThubanApplication.splash_screen): New
11012     method to create a splash screen.
11013     (ThubanApplication.ShowMainWindow): New. Show the main window.
11014     Needed so the splash screen can display the mainwindow
11015     (ThubanApplication.OnInit): Call the
11016     new splash_screen method to determine whether the application
11017     should display a splash screen. If it displays a splash screen do
11018     not immediately show the main window.
11019    
11020 jonathan 399 2003-02-11 Jonathan Coles <[email protected]>
11021    
11022     * Thuban/Model/classification.py: Added import line to fix
11023     feature conflicts between running on python2.2 and python2.1.
11024    
11025     * Thuban/UI/classifier.py (ClassTable): Didn't need to hang
11026     onto the clinfo parameter, so removed the deepcopy().
11027    
11028 jonathan 396 2003-02-10 Jonathan Coles <[email protected]>
11029    
11030 tkoester 403 * Thuban/Model/save.py (Saver.open_element, Saver.close_element):
11031 jonathan 396 Added element_open variable to track opening and closing of tags
11032     so that tags that don't span more than one line are closed with
11033     /> instead of </tag_name>. Use the GetDefault*() methods of
11034     the Classification class.
11035    
11036     * Thuban/Model/classification.py (Classificaton): Added set and
11037     get methods for the default data. The class also takes a layer
11038     reference so that modification messages can be sent. Fixed the
11039     methods to use the new ClassData class.
11040     (ClassData): New class to encapsulate the classification data
11041    
11042     * Thuban/Model/layer.py (Layer): Remove the
11043 tkoester 403 Set[Fill|Stroke|StrokeWidth]() methods. Code should call the
11044 jonathan 396 SetDefault*() methods on the layer's classification object.
11045 tkoester 403 (Layer.__init__): Use the new SetDefault*() methods in the
11046 jonathan 396 Classification class.
11047    
11048     * Thuban/Model/load.py (ProcessSession): Use the new ClassData
11049     object instead of a dictionary.
11050    
11051 tkoester 403 * Thuban/UI/classifier.py (ClassRenderer): New class to
11052 jonathan 396 draw the classifications in the dialog box's table.
11053     (Classifier): Modified to use the ClassRenderer class.
11054    
11055 tkoester 403 * Thuban/UI/mainwindow.py (MainWindow): Use the SetDefault*()
11056     methods of the Classification class.
11057 jonathan 396
11058     * Thuban/UI/renderer.py (MapRenderer): Use the Get*() methods
11059     of the ClassData class.
11060    
11061     * test/test_classification.py, test/test_layer.py,
11062     test/test_map.py, test/test_session.py: Fix the tests to work
11063     with the above code changes.
11064    
11065 jonathan 387 2003-02-03 Jonathan Coles <[email protected]>
11066    
11067     * Thuban/Model/classification.py (Classification): Added getNull()
11068     to return the NullData reference
11069    
11070     * Thuban/Model/layer.py (Layer.SetFill, Layer.SetStroke,
11071     Layer.SetStrokeWidth): Modified these functions to change the
11072     null data in the classification rather than keep these values
11073     directly in the Layer class. Menu options to change these values
11074     work again.
11075    
11076 jonathan 380 2003-01-28 Jonathan Coles <[email protected]>
11077    
11078 jonathan 384 * Thuban/UI/classifier.py (Classifier): Resolved merging conflicts.
11079 tkoester 403 Fixed crashing problem on some systems. Dialog box shows
11080 jonathan 380 classification data.
11081    
11082 jonathan 384 * Thuban/UI/tree.py (SessionTreeCtrl.add_items): Handle drawing
11083     Colors in the tree view.
11084    
11085     * Thuban/Model/layer.py (Layer.TreeInfo): Added a call to build
11086     the tree info for classifications. Commented out unnecessary lines.
11087    
11088     * Thuban/Model/classification.py (Classification.TreeInfo): New
11089     function to add information about the classification into the
11090     tree view.
11091    
11092 tkoester 403 2003-01-27 Jan-Oliver Wagner <[email protected]>
11093 jan 375
11094 tkoester 403 * Thuban/__init__.py (_): New.
11095 jan 375
11096     * Thuban/Model/classification.py, Thuban/Model/extension.py,
11097     Thuban/Model/layer.py, Thuban/Model/load.py, Thuban/Model/map.py,
11098 tkoester 403 Thuban/Model/session.py, Thuban/UI/application.py,
11099     Thuban/UI/classifier.py, Thuban/UI/context.py, Thuban/UI/controls.py,
11100     Thuban/UI/identifyview.py, Thuban/UI/labeldialog.py,
11101     Thuban/UI/mainwindow.py, Thuban/UI/menu.py, Thuban/UI/proj4dialog.py,
11102     Thuban/UI/renderer.py, Thuban/UI/tree.py, Thuban/Lib/connector.py,
11103     Thuban/Lib/fileutil.py: Replace user string by _() for i18n.
11104 jan 375
11105 jonathan 370 2003-01-27 Jonathan Coles <[email protected]>
11106    
11107 tkoester 403 * Thuban/Model/layer.py: Classification initialization calls.
11108 jonathan 370
11109 tkoester 403 * Thuban/Model/classification.py: Created class to encapsulate
11110     a layer classification. Supports specific data points and
11111     ranges.
11112 jonathan 370
11113 tkoester 403 * Thuban/Model/load.py: Added support for loading classification
11114     information.
11115 jonathan 370
11116 tkoester 403 * Thuban/Model/save.py: Added support for saving classification
11117     information.
11118 jonathan 370
11119 tkoester 403 * Thuban/UI/classifier.py: Initial class for a dialog box for
11120     specifying classification information.
11121 jonathan 370
11122 tkoester 403 * Thuban/UI/mainwindows.py: Support for opening the classifier
11123     dialog.
11124 jonathan 370
11125 tkoester 403 * Thuban/UI/renderer.py: Support for drawing a layer with the
11126     classification information.
11127 jonathan 370
11128 tkoester 403 * Data/iceland_sample_class.thuban: iceland_sample with
11129     classification data.
11130 jonathan 370
11131 tkoester 403 * test/test_classification: Tests for the Classification class.
11132 jonathan 370
11133 bh 359 2002-12-09 Bernhard Herzog <[email protected]>
11134    
11135 bh 361 * test/test_command.py: New. Tests for the command classes.
11136    
11137 bh 359 * Thuban/UI/command.py (ToolCommand): New class for tool commands.
11138     (Command.IsTool): New method to distinguish between command
11139     switching tools and other commands.
11140    
11141     * Thuban/UI/view.py (MapCanvas.SelectTool): New method to select
11142     the tool to avoid direct assignments to instance variables
11143     (MapCanvas.ZoomInTool, MapCanvas.ZoomOutTool, MapCanvas.PanTool)
11144     (MapCanvas.IdentifyTool, MapCanvas.LabelTool): Use SelectTool to
11145     change the tool
11146    
11147     * Thuban/UI/mainwindow.py (MainWindow.update_command_ui): If an
11148     active tool's command turns insensitive, disable the tool.
11149     (_tool_command): Use the new ToolCommand class
11150    
11151     * Examples/simple_extensions/simple_tool.py (simple_tool): Use the
11152     SelectTool method to change the tool
11153     (iconfile): Use the ToolCommand class
11154    
11155 bh 354 2002-12-03 Bernhard Herzog <[email protected]>
11156    
11157     * Thuban/UI/tree.py (SessionTreeCtrl.normalize_selection): Handle
11158     the case of selected items that are not children of Layers or Maps
11159     properly. Previously this bug would trigger an assertion in
11160     wxWindows.
11161    
11162 frank 352 2002-11-06 Frank Koormann <[email protected]>
11163    
11164 bh 354 * Thuban/UI/mainwindow.py: Altered the order of tools in the
11165     toolbar: First now are all navigation tools (Zoom In/Out, Pan,
11166     Full Extent).
11167 tkoester 403
11168 bh 349 2002-10-23 Bernhard Herzog <[email protected]>
11169    
11170     * setup.py (setup call): version now 0.1.3
11171    
11172     * MANIFEST.in: Add the files in test/
11173    
11174     * test/README: Add note about tests requiring the iceland data
11175    
11176     * Thuban/UI/mainwindow.py (MainWindow.About): Add 2002 to
11177     copyright notice.
11178    
11179 bh 344 2002-10-18 Bernhard Herzog <[email protected]>
11180    
11181     * test/test_map.py
11182     (TestMapWithContents.test_projected_bounding_box): Use an explicit
11183     epsilon.
11184    
11185     * test/support.py (FloatComparisonMixin.assertFloatEqual)
11186     (FloatComparisonMixin.assertFloatSeqEqual): give a more useful
11187     message if the assertion fails and don't return the return value
11188     of self.assert_. In assertFloatSeqEqual the return meant that not
11189     all items of the sequence were compared.
11190    
11191 bh 326 2002-09-20 Bernhard Herzog <[email protected]>
11192    
11193 bh 341 * test/test_fileutil.py: New. Test cases for Thuban.Lib.fileutil
11194    
11195     * Thuban/Lib/fileutil.py: Fixup some whitespace and typos
11196    
11197 bh 338 * test/test_map.py (TestMapWithContents.test_tree_info): Create
11198     the string with the bounding box on the fly because of platform
11199     differences in the way %g is handled.
11200    
11201     * test/test_layer.py (TestLayer.test_empty_layer): Create an empty
11202     DBFfile too because Thuban layers can't yet cope missing DBF
11203     files.
11204    
11205     2002-09-20 Bernhard Herzog <[email protected]>
11206    
11207 bh 326 * test/test_menu.py: Use initthuban instead of
11208     add_thuban_dir_to_path to initialize Thuban.
11209    
11210     * test/support.py (FloatComparisonMixin.assertFloatEqual): New.
11211     Mixin class for float comparisons
11212     (SubscriberMixin): New. Mixin class to test messages sent through
11213     the Connector class
11214    
11215     * test/README: Fix a typo and add the -v flag to the command for
11216     individual tests
11217    
11218 bh 335 * test/test_session.py: New. Test cases for Thuban.Model.session
11219    
11220     * test/test_proj.py: New. Test cases for Thuban.Model.proj
11221    
11222     * test/test_map.py: New. Test cases for Thuban.Model.map
11223    
11224     * test/test_layer.py: New. Test cases for Thuban.Model.layer
11225    
11226     * test/test_label.py: New. Test cases for Thuban.Model.label
11227    
11228     * test/test_connector.py: New. Test cases for Thuban.Lib.connector
11229    
11230     * test/test_color.py: New. Test cases for Thuban.Model.color
11231    
11232     * test/test_base.py: New. Test cases for Thuban.Model.base
11233    
11234 bh 322 2002-09-13 Bernhard Herzog <[email protected]>
11235    
11236     * Thuban/Model/session.py (Session.forwarded_channels): Forward
11237     the CHANGED channel too.
11238    
11239     * Thuban/Model/map.py (Map.forwarded_channels): Forward the
11240     CHANGED channel too.
11241     (Map.__init__): Call the Modifiable constructor as well.
11242    
11243     * Thuban/Model/base.py (Modifiable.UnsetModified): Issue a CHANGED
11244     event if the modified flag changes.
11245     (Modifiable.changed): Tweak the doc-string.
11246    
11247     * Thuban/UI/mainwindow.py (MainWindow.view_position_changed)
11248     (MainWindow.set_position_text): Put the code that puts the text
11249     with the mouse position into the status bar into the new method
11250     set_position_text so that it can overwritten in derived classes.
11251    
11252 bh 317 2002-09-12 Bernhard Herzog <[email protected]>
11253    
11254     * Thuban/UI/mainwindow.py (MainWindow.RunMessageBox): Center the
11255     message box on the main window.
11256    
11257 bh 313 2002-09-11 Bernhard Herzog <[email protected]>
11258    
11259     * Thuban/UI/mainwindow.py: Underline the 'x' in "Exit" instead of
11260     the 'E' because it's less likely to interfere with other menu
11261     entries.
11262 bh 315 (MainWindow.build_menu): remove an incorrect comment.
11263 bh 313
11264 bh 311 2002-09-10 Bernhard Herzog <[email protected]>
11265    
11266     * Thuban/UI/mainwindow.py (MainWindow.Map): New.
11267     (_tool_command): Add sensitive parameter
11268     (_has_visible_map): Sensitivity callback to tools and other
11269     commands that require a visible map. Use it in map_zoom_in_tool,
11270     map_zoom_out_tool, map_pan_tool, map_identify_tool, map_label_tool
11271     and map_full_extent
11272    
11273 bh 308 2002-09-06 Bernhard Herzog <[email protected]>
11274    
11275     * Thuban/UI/mainwindow.py (MainWindow.OnClose): Unsubscribe
11276     VIEW_POSITION
11277    
11278 tkoester 403 2002-09-04 Frank Koormann <[email protected]>
11279 frank 306
11280     * Resources/Bitmaps/fullextent.xpm: Updated Icon (removed "potatoe")
11281    
11282 bh 302 2002-09-02 Bernhard Herzog <[email protected]>
11283    
11284 bh 304 * Thuban/UI/view.py: Get rid of the idle redraw. This is done by
11285     wxWindows already and our implementation doesn't work correctly
11286     with wxGTK 2.3:
11287     (MapCanvas.__init__): Remove the instance variable
11288     (MapCanvas.OnPaint): Always call do_redraw when there's a map to
11289     be drawin
11290     (MapCanvas.OnIdle): Removed.
11291    
11292 bh 302 * Thuban/UI/view.py (MapCanvas.unprojected_rect_around_point): Add
11293     a parameter to determine the size of the rectangle.
11294     (MapCanvas.find_shape_at): Create the box around the point on a
11295     layer by layer basis and make the size depend on the shape type.
11296     This solves a problem with the selection of point shapes at the
11297     border of the layer's bounding box
11298    
11299 bh 292 2002-08-30 Bernhard Herzog <[email protected]>
11300    
11301 bh 300 * Thuban/UI/mainwindow.py (MainWindow.CanRemoveLayer): New method
11302     for the sensitivity of remove layer.
11303     (_can_remove_layer): New. Sensitivity callback for remove layer
11304     (Command layer_remove): Use _can_remove_layer
11305    
11306     * Thuban/Model/map.py (Map.CanRemoveLayer): New method to
11307     determine whether a given layer can be deleted.
11308    
11309 bh 297 * Thuban/UI/view.py (MapCanvas.__init__, MapCanvas.OnPaint)
11310     (MapCanvas.do_redraw): Get rid of the unused update_region
11311     instance variable
11312    
11313 bh 294 * Thuban/UI/view.py: Add/update some doc-strings.
11314    
11315 bh 292 * test/: new subdirectory with a bunch of unit tests.
11316    
11317     * test/README, test/test_table.py, test/test_save.py,
11318     test/test_menu.py, test/test_load.py: Initial set of tests and
11319     brief instructions on how to run them
11320    
11321 bh 287 2002-08-29 Bernhard Herzog <[email protected]>
11322    
11323 bh 291 * Thuban/UI/renderer.py (ScreenRenderer.draw_shape_layer): Handle
11324     arcs with multiple parts.
11325    
11326 bh 289 * Thuban/UI/view.py (ZoomInTool.MouseUp, ZoomOutTool.MouseUp):
11327     Handle degenrate rectangles.
11328    
11329 bh 287 * Thuban/Model/table.py: Make writing records work correctly:
11330     (Table.__init__): Keep track of whether the DBF is open for
11331     writing
11332     (Table.write_record): Open the DBF file for writing when necessary
11333    
11334 bh 285 2002-08-27 Bernhard Herzog <[email protected]>
11335    
11336     * Thuban/Model/table.py (Table.write_record, Table.__init__): Open
11337     dbf files only for reading by default. Use a new writable dbf
11338     object for writing.
11339    
11340 bh 278 2002-08-26 Bernhard Herzog <[email protected]>
11341    
11342 bh 282 * Thuban/UI/mainwindow.py: Refactor the context creation:
11343     (MainWindow.Context): New method to return a context
11344     (MainWindow.invoke_command, MainWindow.update_command_ui): Use the
11345     new method
11346    
11347 bh 278 * Thuban/UI/tableview.py (TableGrid, LayerTableGrid): Split the
11348     layer table specific code from TableGrid into LayerTableGrid
11349     (TableFrame, LayerTableFrame): Split the layer table specific code
11350     from TableFrame into LayerTableFrame
11351 bh 280 (LayerTableGrid.select_shape): Remove a debug print
11352 bh 278
11353     * Thuban/UI/mainwindow.py (MainWindow.LayerShowTable): Use the
11354     LayerTableFrame
11355    
11356 bh 277 2002-08-23 Bernhard Herzog <[email protected]>
11357    
11358     * Thuban/Model/layer.py (Layer.__init__): Make sure we have an
11359     absolute filename.
11360    
11361 bh 269 2002-08-22 Bernhard Herzog <[email protected]>
11362    
11363 bh 275 * Thuban/Model/table.py (Table.write_record): New method to write
11364     records.
11365 tkoester 403 (Table.__init__): Open the DBF file for writing too.
11366 bh 275
11367     * Thuban/UI/controls.py (RecordTable.SetValue): Write the value
11368     into the underlying table.
11369    
11370     * extensions/shapelib/shapefil.h (DBFCommit),
11371     extensions/shapelib/dbfopen.c (DBFCommit): New API function to
11372     commit any changes made to the DBF file.
11373    
11374 bh 271 * Thuban/UI/mainwindow.py (make_check_current_tool)
11375     (_tool_command): Put the code that generates the "checked"
11376     callback into a separate function so that we can reuse it
11377     elsewhere
11378    
11379 bh 269 * Thuban/Model/save.py (Saver): New class to handle serializing a
11380     session into an XML file. The main reason to introduce a class is
11381     that applications built on Thuban can derive from it so that they
11382     can save additional information in a session file.
11383     (save_session): Delegate almost all the work to the Saver class.
11384     Rename the filename argument to file because it may be a file like
11385     object now.
11386    
11387     * Thuban/Model/load.py: Get rid of the Python 1.5.2 compatibility
11388     code. Remove the little test code which would be executed when the
11389     module is run as a script which didn't work anymore since it can't
11390     import the other Thuban modules.
11391     (ProcessSession, load_session): Refactor the ProcessSession to
11392     have one method for each element start and end tag so that derived
11393     classes can easily override the processing of individual tags.
11394     Also, always parse with namespaces enabled because applications
11395     built on top of Thuban will likely use namespaces if they extend
11396     the session file format.
11397    
11398 bh 266 2002-08-21 Bernhard Herzog <[email protected]>
11399    
11400     * setup.py (ThubanInstall.run): Don't repr install_lib_orig
11401     because thubaninit_contents will do it for us.
11402    
11403 tkoester 403 2002-08-16 Jan-Oliver Wagner <[email protected]>
11404 jan 265
11405     * Thuban/UI/mainwindow.py: menu item 'show session tree' now disable if
11406     tree window already open
11407    
11408 bh 259 2002-08-15 Bernhard Herzog <[email protected]>
11409    
11410 bh 263 * Thuban/Model/layer.py (Layer.Destroy): Call the unboundd method
11411     with self.
11412    
11413     * Thuban/UI/view.py (MapCanvas.OnLeftUp): Only release the mouse
11414     when we have actually captured it.
11415    
11416 bh 259 * Thuban/Model/layer.py (Layer.Destroy): New. Explicitly close the
11417     shapefile and destroy the table.
11418    
11419     * Thuban/Model/table.py (Table.Destroy): New. Close the DBF file.
11420    
11421 bh 254 2002-08-14 Bernhard Herzog <[email protected]>
11422    
11423 bh 256 * Thuban/UI/controls.py (RecordTable.__init__): Remove the unused
11424     instance variable columns
11425     (RecordTable.GetTypeName): row and col may be negative in some
11426     cases.
11427    
11428 bh 254 * setup.py (InstallLocal.initialize_options)
11429     (InstallLocal.finalize_options, InstallLocal.user_options): New
11430     option create-init-file to build a thubaninit.py when running
11431     install_local
11432     (InstallLocal.run): Create the thubaninit.py module when requested
11433     (thubaninit_contents): Split the template into several parts and
11434     create a new function thubaninit_contents that creates the
11435     contents of a thubaninit module.
11436     (ThubanInstall.run): Use the new function to create the thubaninit
11437     module.
11438    
11439 bh 252 2002-07-30 Bernhard Herzog <[email protected]>
11440    
11441     * Thuban/UI/application.py (ThubanApplication.OnExit): Do some
11442     cleanup.
11443     (ThubanApplication.MainLoop): Extend to automatically call OnExit.
11444    
11445     * Thuban/Model/session.py (Session.Destroy): Don't bypass the
11446     direct base class' Destroy method.
11447    
11448     * Thuban/Model/map.py (Map.ClearLayers): New method to delete all
11449     layers.
11450     (Map.Destroy): Destroy the label_layer as well and call the
11451     inherited Desatroymethod first so that no more messages are
11452     issued.
11453     (Map.RaiseLayer, Map.LowerLayer): Only issue LAYERS_CHANGED
11454     message if the stacking order actually has changed. Add
11455     doc-strings.
11456     (Map.BoundingBox): Correct the doc-string.
11457     (Map.AddLayer, Map.RemoveLayer, Map.Layers, Map.HasLayers)
11458     (Map.ProjectedBoundingBox, Map.SetProjection): Add doc-strings.
11459    
11460     * Thuban/Model/label.py (LabelLayer.ClearLabels): New to delete
11461     all labels.
11462    
11463 bh 247 2002-07-29 Bernhard Herzog <[email protected]>
11464    
11465     * Thuban/Model/map.py (Map.subscribe_layer_channels)
11466     (Map.unsubscribe_layer_channels): Put the code that (un)subscribes
11467     to a layer's channels into separate methods.
11468     (Map.RemoveLayer, Map.AddLayer): Call the new methods
11469     (Map.Destroy): Unsubscribe from a layer's channels before
11470     destroying it.
11471    
11472     * Thuban/UI/view.py (MapCanvas.find_shape_at): Change the
11473     selected_layer parameter to searched_layer which is the layer to
11474     search in.
11475     (MapCanvas.SelectShapeAt): New parameter layer to restrict the
11476     search to that layer. Return the selected layer and shape.
11477    
11478     * Examples/simple_extensions/simple_tool.py (simple_tool): Fix a
11479     typo
11480    
11481 bh 238 2002-07-24 Bernhard Herzog <[email protected]>
11482    
11483 bh 243 * Thuban/UI/application.py (ThubanApplication.create_session):
11484     Extend the doc string.
11485     (ThubanApplication.subscribe_session)
11486     (ThubanApplication.unsubscribe_session): New methods to
11487     subscribe/unsubscribe to/from session channels.
11488     (ThubanApplication.SetSession): Call the new methods here.
11489     (ThubanApplication.maps_changed, ThubanApplication.set_map):
11490     Renamed set_map to maps_changed. Its now a subscriber for
11491     MAPS_CHANGED.
11492    
11493     * Thuban/UI/view.py (ZoomOutTool.MouseUp): Use the correct
11494     x-coordinate in case of simple clicks
11495    
11496     * Thuban/Model/base.py (Modifiable.changed): Apply the args tuple,
11497     don't pass it as a parameter
11498    
11499     * Thuban/Model/session.py (Session.RemoveMap): New
11500    
11501 bh 238 * Thuban/UI/mainwindow.py (MainWindow.__init__): Turn the initial
11502     window size into a parameter.
11503    
11504 bh 235 2002-07-23 Bernhard Herzog <[email protected]>
11505    
11506 bh 237 * Thuban/UI/menu.py (Menu.item_index): Also search for menus not
11507     just commands.
11508    
11509 bh 235 * Thuban/UI/mainwindow.py (MainWindow.__init__): Change the
11510     parameter list a bit to allow setting the window title and the
11511     initial message in the status bar. Update the callers.
11512    
11513     * Thuban/UI/application.py (ThubanApplication.OnInit)
11514     (ThubanApplication.CreateMainWindow): Put the mainwindow
11515     instantiation into a separate method so that it can be overridden
11516     by a subclass.
11517    
11518 bh 230 2002-07-19 Bernhard Herzog <[email protected]>
11519    
11520 bh 234 * Thuban/Model/session.py: Issue a CHANGED message every time
11521     another changed message is issued to make it easier to get
11522     notified of changes.
11523     (Session): Update the doc string
11524     (Session.forward): Issue changed-events as CHANGED as well.
11525     (Session.changed): Overwrite the inherited version to issue
11526     CHANGED events as well.
11527    
11528     * Thuban/UI/tree.py: We can now simply subscribe to the session's
11529     CHANGED channel to be informed of changes.
11530     (SessionTreeCtrl.session_channels): Not needed any longer.
11531 tkoester 403 (SessionTreeCtrl.unsubscribe_all, SessionTreeCtrl.session_changed):
11532 bh 234 Only have to (un)subscribe CHANGED
11533    
11534     * Thuban/Model/map.py (Map.TreeInfo): Deal better with empty maps.
11535    
11536 bh 230 * Thuban/UI/main.py, Thuban/UI/__init__.py: Move the work-around
11537     for the wxPython locale bug to __init__.py so that it's
11538     automatically executed by anybody using UI code from Thuban.
11539    
11540 bh 225 2002-07-18 Bernhard Herzog <[email protected]>
11541    
11542 bh 228 * Thuban/UI/main.py (main): app no longer needs to be global
11543    
11544     * Thuban/UI/mainwindow.py (MainWindow.__init__): Add application
11545     as parameter and store it in an instance variable
11546     (MainWindow.invoke_command, MainWindow.update_command_ui)
11547     (MainWindow.save_modified_session, MainWindow.NewSession)
11548     (MainWindow.OpenSession, MainWindow.SaveSession)
11549     (MainWindow.SaveSessionAs, MainWindow.ShowSessionTree): Use self's
11550     application object.
11551    
11552     * Thuban/UI/application.py (ThubanApplication.OnInit): Instantiate
11553     the main window with self.
11554    
11555 bh 225 * Thuban/UI/context.py: New module with the context class
11556    
11557     * Thuban/UI/command.py (Command): Update doc string.
11558    
11559     * Thuban/UI/mainwindow.py (MainWindow.invoke_command,
11560     MainWindow.update_command_ui): Pass an instance of the context
11561     class to the command's methods
11562     (check_current_tool, call_method): Handle the new context
11563     implementation
11564    
11565     * Examples/simple_extensions/simple_tool.py (simple_tool,
11566     check_simple_tool): Handle the new context implementation
11567    
11568     * Examples/simple_extensions/simple_command.py (simple_command):
11569     Handle the new context implementation. Update the comments about
11570     the context.
11571    
11572     * Thuban/UI/application.py (ThubanApplication.SetSession): Add
11573     doc-string
11574     (ThubanApplication.Session): New method to return the session
11575     object
11576    
11577     * Thuban/UI/tree.py (SessionTreeCtrl.update_tree): The
11578     interactor's selected_layer may not be a layer of the current
11579     session when the tree is updated while a new session is being set.
11580    
11581 bh 217 2002-07-17 Bernhard Herzog <[email protected]>
11582    
11583     * Thuban/UI/tree.py (color_string): Removed. No longer used.
11584     (SessionTreeCtrl.update_tree, SessionTreeCtrl.add_items): Split
11585     update_tree into update_tree and add_items. The tree now uses a
11586     more generic way to display the contents of the tree.
11587     (SessionTreeCtrl): Add a doc string explaining the TreeInfo method
11588    
11589     * Thuban/Model/layer.py (Layer.TreeInfo),
11590     Thuban/Model/extension.py (Extension.TreeInfo),
11591     Thuban/Model/map.py (Map.TreeInfo),
11592 tkoester 403 Thuban/Model/session.py (Session.TreeInfo):
11593 bh 217 Add TreeInfo methods to implement the new tree view update scheme
11594    
11595 bh 216 2002-07-16 Bernhard Herzog <[email protected]>
11596    
11597     * Thuban/UI/application.py: Don't use "import from" for the
11598     MainWindow. It can't always be resolved.
11599     (ThubanApplication.OnInit): change reference to MainWindow
11600     accordingly.
11601    
11602     * Thuban/UI/menu.py (Menu.SetItems): New method to replace a menu
11603     completely
11604    
11605 bh 213 2002-07-10 Bernhard Herzog <[email protected]>
11606    
11607     * setup.py (create_init_module): New configurable variable whose
11608     default depends on the platform we're running on.
11609     (ThubanInstall.initialize_options): Initialize
11610     self.create_init_module from the global create_init_module
11611     (ThubanInstall.user_options): indictate that the options
11612     create-init-module and init-module-dir have arguments.
11613    
11614     * setup.py: In the setup call change the version number to include
11615     cvs.
11616    
11617     * MANIFEST.in: Add the files in Examples
11618    
11619 bh 205 2002-07-09 Bernhard Herzog <[email protected]>
11620    
11621 bh 210 * setup.py: In the setup call, use the thuban homepage as the
11622     value of the url parameter.
11623    
11624 bh 208 * Examples: New subdirectory for examples.
11625    
11626     * Examples/simple_extensions/simple_tool.xpm,
11627     Examples/simple_extensions/simple_tool.py,
11628     Examples/simple_extensions/simple_command.py,
11629     Examples/simple_extensions/README: Simple examples showing how to
11630     add new commands and tools.
11631    
11632 bh 207 * setup.cfg (bdist_rpm): Add the default value for prefix and tell
11633     bdist_rpm that we also have an install script.
11634     (bdist_inno): Add 2002 to the copyright notice.
11635    
11636 bh 205 * setup.py: Create a file in python's site-packages directory to
11637     make installation of Thuban as a library easier.
11638     (ThubanInstall.user_options): Add two new options,
11639     create-init-module and init-module-dir
11640     (ThubanInstall.expand_with_pure_python_dirs): New method to expand
11641     filenames for installation in the default directories.
11642     (ThubanInstall.select_scheme, ThubanInstall.convert_paths): Extend
11643     the inherited methods to capture some filenames before they're
11644     transformed too much by distutils.
11645     (ThubanInstall.run): Create the init module if requested.
11646     (ThubanInstall.thuban_init_filename): New method to return the
11647     full name of the init module.
11648     (ThubanInstall.get_outputs): Append the filename of the init
11649     module.
11650    
11651 bh 202 2002-07-08 Bernhard Herzog <[email protected]>
11652    
11653 bh 205 * setup.py (thuban_bdist_rpm): Extend this version of bdist_rpm to
11654     handle the prefix properly which means that the default for the
11655     installation prefix should be /usr for RPMs and /usr/local when
11656     doing a normal source install.
11657     (bdist_rpm_install_script): Script to override the default install
11658     commands in the specfile generated by the bdist_rpm command.
11659     (thuban_bdist_rpm.user_options): Add a prefix option
11660     (thuban_bdist_rpm.initialize_options): Init the prefix option.
11661     Create the script files for the spec files as empty files here
11662     (thuban_bdist_rpm._make_spec_file): Override the inherited method
11663     to fill the script files with content.
11664    
11665 bh 202 * Thuban/Model/save.py (relative_filename): Wrapper around
11666     Thuban.Lib.fileutil.relative_filename that accepts an empty dir
11667     argument. save_session now automatically uses this version,
11668     solving a problem when saving to a relative filename.
11669    
11670     * setup.py: In the setup call, make sure that the library
11671     directories are under $prefix/lib not directly under $prefix.
11672    
11673 tkoester 403 2002-06-20 Jan-Oliver Wagner <[email protected]>
11674 jan 199
11675     * Thuban/Model/extension.py: new module to handle extension objects.
11676     * Thuban/Model/messages.py: new messages for extensions.
11677     * Thuban/Model/session.py (Session.Extensions, Session.HasExtensions,
11678     Session.AddExtension): new for handling extensions.
11679     Also some other minor changes to round up extension handling.
11680     * Thuban/UI/tree.py (SessionTreeCrtl:update_tree): Added visualization
11681     of Extension titles and title and names of its objects.
11682    
11683 bh 194 2002-05-29 Bernhard Herzog <[email protected]>
11684    
11685     * Thuban/UI/mainwindow.py (MainWindow.bind_command_events): Bind
11686 bh 202 the events for a command.
11687 bh 194 (MainWindow.add_toolbar_command, MainWindow.add_menu_command):
11688     Call bind_command_events to bind the events. add_toolbar_command
11689     can now bind events too so that it's possible to have commands
11690     that are only available through the toolbar.
11691     (MainWindow.init_ids): New instance variable events_bound to keep
11692     track of for which commands events have been bound.
11693    
11694 bh 190 2002-05-28 Bernhard Herzog <[email protected]>
11695    
11696     * Thuban/UI/menu.py: New module to build and manage menus.
11697    
11698     * Thuban/UI/mainwindow.py: Remove some unused imports.
11699     (MainWindow.__init__, main_menu): move the definition of the main
11700     menu from __init__ to the Menu instance main_menu.
11701     (MainWindow.build_menu_bar, MainWindow.build_menu): New methods to
11702     build the menu bar and sub-menus from a menu description.
11703    
11704     * Thuban/UI/application.py (ThubanApplication.OnInit): Read the
11705     startup file
11706     (ThubanApplication.read_startup_files): New method to run
11707     ~/.thuban/thubanstart.py
11708    
11709 bh 192 * Thuban/UI/mainwindow.py (MainWindow.__init__, main_toolbar):
11710     Move the toolbar definition to the Menu instance main_toolbar.
11711     (MainWindow.build_toolbar): New method to build the toolbar
11712     similar to the build_menu methods
11713    
11714 bh 184 2002-05-23 Bernhard Herzog <[email protected]>
11715    
11716 bh 186 * Thuban/UI/mainwindow.py (MainWindow.__init__): Fix spelling of
11717     layer_outline_color. Fix it in the definition of the command too.
11718    
11719 bh 184 * Thuban/UI/command.py (Command): Fix typo in doc string
11720    
11721 bh 182 2002-05-22 Bernhard Herzog <[email protected]>
11722    
11723     * Thuban/UI/mainwindow.py (MainWindow.RunMessageBox): Fix a typo
11724     in the docstring
11725    
11726 bh 175 2002-05-15 Bernhard Herzog <[email protected]>
11727    
11728 bh 180 * Thuban/Model/layer.py (Layer.open_shapefile): Set bbox to None
11729     when the shapefile is empty.
11730     (Layer.BoundingBox, Layer.LatLongBoundingBox): Both methods may
11731     now return None for empty shapefiles. Update doc-strings.
11732    
11733     * Thuban/Model/map.py (Map.BoundingBox): Add doc-string. Deal with
11734     the layer's bbox being None.
11735    
11736     * Thuban/UI/tree.py (SessionTreeCtrl.update_tree): Deal with the
11737     layer's bbox being None.
11738    
11739 bh 175 * Thuban/UI/view.py (MapCanvas.shape_selected): Only redraw when
11740     necessary.
11741     (MapCanvas.__init__): New instance variables, last_selected_layer
11742     and last_selected_shape to determine how the selection has
11743     changed.
11744    
11745     * Thuban/UI/tableview.py (TableGrid.__init__): Do not call
11746     AutoSizeColumns because it will cause a traversal of the entire
11747     table which for large .dbf files will take a very long time.
11748    
11749 bh 172 2002-05-14 Bernhard Herzog <[email protected]>
11750    
11751     * Thuban/Model/layer.py (Layer.open_shapefile): Choose a better
11752     maximum depth for the tree than shapelib does by default.
11753    
11754 bh 165 2002-05-10 Bernhard Herzog <[email protected]>
11755    
11756     * setup.py (py_modules): The shptree modules doesn't have a
11757     wrapper, so don't include it in the py_modules
11758    
11759 bh 163 2002-05-08 Bernhard Herzog <[email protected]>
11760    
11761     * extensions/shapelib/shptree.c (compare_ints): Make arguments
11762     const void * as in the qsort prototype
11763     (SHPTreeFindLikelyShapes): Remove some unused variables.
11764    
11765     * Thuban/UI/view.py (PanTool.MouseMove): Use the bitmap the view
11766     maintains to redraw the window during a drag.
11767     (MapCanvas.unprojected_rect_around_point): New method to determine
11768     a small region around a point for hit-testing.
11769     (MapCanvas.find_shape_at): Only test the shapes in a small region
11770     around the point.
11771    
11772     * setup.py: Increment the version to 0.1.2
11773    
11774     * Thuban/UI/tree.py (SessionTreeCtrl.unsubscribe_all): Remove a
11775     debug print and set session to None after unsubscribing
11776    
11777 bh 146 2002-05-07 Bernhard Herzog <[email protected]>
11778    
11779 bh 154 * Data/iceland_sample.session, Data/iceland_sample.thuban: Rename
11780     the file to have a .thuban extension.
11781    
11782 bh 152 * Thuban/UI/tree.py (session_channels): New class constant with
11783     all the session channels to subscribe to to update the tree
11784     (SessionTreeCtrl.session_changed): Remember the session so that we
11785     can unsubscribe properly. Use the new class constant to
11786     unsubscribe from the old session and subscribe to the new one.
11787     (SessionTreeCtrl.unsubscribe_all): New method to unsubscribe all
11788     subscriptions of the SessionTreeCtrl.
11789     (SessionTreeView.OnClose): Call the tree's unsubscribe_all method.
11790    
11791     * Thuban/UI/mainwindow.py (MainWindow.__init__): Add the "Show
11792     Session Tree" command to the file menu.
11793    
11794     * Thuban/UI/view.py (MapCanvas.do_redraw): Pass the entire bitmap
11795     as update_region to the renderer.
11796    
11797     * Thuban/UI/renderer.py
11798     (ScreenRenderer.layer_ids, ScreenRenderer.draw_shape_layer): The
11799     update box is now directly a tuple, not a wxRect anymore.
11800    
11801     * Thuban/Model/layer.py (Layer.ShapesInRegion): Remove some debug
11802     prints.
11803    
11804     2002-05-07 Bernhard Herzog <[email protected]>
11805    
11806 bh 146 * setup.py: Add the shptree extension module. See
11807     extensions/pyshapelib/ChangeLog for more details.
11808    
11809     * extensions/shapelib/shpopen.c, extensions/shapelib/shapefil.h,
11810     extensions/shapelib/dbfopen.c: Really update to the versions of
11811     shapelib 1.2.9. For some reason it wasn't really done on
11812     2002-04-11.
11813    
11814     * extensions/shapelib/shptree.c: Modified version of shptree.c of
11815     shapelib 1.2.9. The only real difference is the use of qsort
11816     instead of a bubble sort implementation
11817    
11818     * Thuban/Model/layer.py (Layer.__init__): New instance variable
11819     shapetree to hold the shapelib quadtree for the shapefile
11820     (Layer.open_shapefile): Create the quad tree.
11821     (Layer.ShapesInRegion): New method to return the ids of shapes in
11822     a given region using the quad tree.
11823    
11824     * extensions/thuban/wxproj.cpp (project_points): Fix some typos in
11825     comment
11826     (draw_polygon_shape): Accept both arcs and polygons.
11827     (initwxproj): Use the new PYSHAPELIB_IMPORT_API macro to import
11828     the api.
11829    
11830     * Thuban/UI/renderer.py (MapRenderer.layer_ids): New method to
11831     return the shape ids to be rendered in a given layer.
11832     (MapRenderer.draw_shape_layer): Call layer_ids to get the list of
11833     ids. Use draw_polygon_shape to draw arc shapes as well.
11834     (ScreenRenderer.RenderMap): New parameter for the rectangle that
11835     has to be updated
11836     (ScreenRenderer.layer_ids): Make use of the layer's quadtree by
11837     calling it's ShapesInRegion method.
11838    
11839     * Thuban/UI/view.py (MapCanvas.__init__): New instance variable
11840     update_region for the update region.
11841     (MapCanvas.OnPaint): Maintain the update region
11842     (MapCanvas.do_redraw): Pass the bounding box of the update_region
11843     to the renderer when drawing the bitmap. Reset the update_region.
11844    
11845 bh 129 2002-05-03 Bernhard Herzog <[email protected]>
11846    
11847 bh 131 * Thuban/UI/mainwindow.py (MainWindow.SaveSessionAs,
11848     MainWindow.OpenSession): Change the file extension of the session
11849     files to .thuban
11850    
11851 bh 129 * Thuban/Model/session.py (Session.AddMap, forwarded_channels):
11852     Move the map channels to be forwarded by the session into the
11853 bh 146 class constant with forwarded_channels. Also add
11854     LAYER_PROJECTION_CHANGED and LAYER_VISIBILITY_CHANGED to
11855     forwarded_channels
11856 bh 129
11857     * Thuban/Model/base.py (Modifiable.changed): Fix doc-string (a
11858     typo and some rewording).
11859    
11860 bh 126 2002-05-02 Bernhard Herzog <[email protected]>
11861    
11862     * Thuban/UI/view.py: Keep the temporary bitmap used during drawing
11863     around to speed up most redraws:
11864     (MapCanvas.__init__): New instance variable bitmap which holds the
11865     bitmap
11866     (MapCanvas.do_redraw): Redraw self.bitmap if necessary. Use
11867     self.bitmap to draw.
11868     (MapCanvas.full_redraw): New method to force a full redraw
11869     including the bitmap
11870     (MapCanvas.SetMap): Subscribe full_redraw instead of redraw to
11871     make sure the bitmap is redrawn.
11872     (MapCanvas.projection_changed, MapCanvas.set_view_transform,
11873     MapCanvas.shape_selected): Call full_redraw instead of readraw to
11874     make sure the bitmap is redrawn.
11875     (MapCanvas.OnSize): New method to handle size events so that the
11876     bitmap can be redrawn.
11877    
11878 bh 124 2002-04-29 Bernhard Herzog <[email protected]>
11879    
11880     * Thuban/UI/mainwindow.py (MainWindow.__init__): Subscribe to the
11881     canvas' VIEW_POSITION event
11882     (MainWindow.view_position_changed): Handler for VIEW_POSITION.
11883     Update the text in the status-bar accordingly.
11884    
11885     * Thuban/UI/view.py (MapCanvas): Derive from Publisher as well
11886     (MapCanvas.__del__): Implement because Publisher.__del__ has to be
11887     called.
11888     (MapCanvas.__init__): Bind EVT_LEAVE_WINDOW too. Initialize
11889     current_position
11890     (MapCanvas.set_current_position): New method to set
11891     current_position. Issue a VIEW_POSITION event
11892     (MapCanvas.CurrentPosition): New public method to return the value
11893     of current_position. Should be called when the VIEW_POSITION event
11894     is processed.
11895     (MapCanvas.OnLeftDown, MapCanvas.OnLeftUp, MapCanvas.OnMotion):
11896     Update the position.
11897     (MapCanvas.OnLeaveWindow): Set the position to None.
11898    
11899     * Thuban/UI/messages.py (VIEW_POSITION): New message for the
11900     position in the statusbar
11901    
11902 tkoester 403 2002-04-26 Frank Koormann <[email protected]>
11903 frank 120
11904     * Thuban/UI/mainwindow.py: AddLayer, Dialog title s/session/data
11905    
11906 tkoester 403 2002-04-24 Frank Koormann <[email protected]>
11907    
11908 frank 118 * Resources/Bitmaps/identify.xpm: shadow added
11909    
11910     * Resources/Bitmaps/fullextent.xpm: new
11911 jan 116
11912 tkoester 403 2002-04-22 Jan-Oliver Wagner <[email protected]>
11913 jan 116
11914 tkoester 403 * Thuban/UI/tree.py (update_tree): added test for None on map bounding
11915     box
11916 jan 114
11917 tkoester 403 2002-04-21 Jan-Oliver Wagner <[email protected]>
11918    
11919 jan 114 * Thuban/UI/proj4dialog.py (UTMProposeZoneDialog): new
11920    
11921     * Thuban/UI/tree.py (update_tree): added added map extent
11922    
11923     * Thuban/UI/mainwindow.py (_method_command): extended by parameter
11924 tkoester 403 icon; added map_full_extend as tool
11925 jan 114
11926 tkoester 403 2002-04-19 Jan-Oliver Wagner <[email protected]>
11927 jan 107
11928     * Thuban/UI/mainwindow.py (SaveSession): launch save as dialog for
11929     saving _new_ sessions
11930    
11931     * Thuban/Model/session.py (create_empty_session): new session
11932     don't have a filename (set to None)
11933    
11934     * Thuban/UI/tree.py (update_tree): added filename and modified flag
11935    
11936     * Thuban/Model/load.py (ProcessSession): convert projection
11937     parameters from unicode to regular string
11938    
11939     * Data/iceland_sample.session: Added UTM Zone 26 projection.
11940    
11941 bh 100 2002-04-11 Bernhard Herzog <[email protected]>
11942    
11943     * extensions/shapelib/shapefil.h, extensions/shapelib/shpopen.c,
11944     extensions/shapelib/dbfopen.c: Update to the versions of shapelib
11945     1.2.9
11946    
11947     * setup.py (Lib.wxproj extension): Don't link shpopen.c and put
11948     the pyshapelib directoy into the list of include dirs, so that
11949     pyshapelib_api.h can be found.
11950    
11951     * extensions/thuban/wxproj.cpp (pyshapelib_api): New variable that
11952     holds the pyshapelib C-API
11953     (draw_polygon_shape, point_in_polygon_shape, shape_centroid): Use
11954     pyshapelib_api to access the shapelib functions.
11955     (initwxproj): Import the c_api from the shapelib module and
11956     initialize pyshapelib_api.
11957    
11958 bh 89 2002-04-04 Bernhard Herzog <[email protected]>
11959    
11960 bh 91 * setup.py (thuban_bdist_rpm.initialize_options): Use
11961     initialize_options to create the scripts for the rpm.
11962    
11963 bh 89 * extensions/pyprojection/setup.py (PROJ4_PREFIX): Just use /
11964    
11965 bh 85 2002-04-03 Bernhard Herzog <[email protected]>
11966    
11967 bh 87 * setup.py: Increment version to 0.1.1
11968    
11969 bh 85 * Thuban/UI/mainwindow.py (MainWindow.__init__): Move the "Add
11970     Layer" and "Remove Layer" commands from the layer menu to the map
11971     menu
11972    
11973 bh 83 2002-02-15 Bernhard Herzog <[email protected]>
11974    
11975     * Thuban/Model/layer.py (Layer.Shape): list append only takes one
11976     argument (python <= 1.5.2 erroneously accepted multiuple
11977     arguments)
11978    
11979 bh 81 2002-02-04 Bernhard Herzog <[email protected]>
11980    
11981     * Thuban/UI/identifyview.py (IdentifyGridCtrl): New class to use a
11982     RecordGrid in the identifyview.
11983     (IdentifyView.__init__): Use IdentifyGridCtrl instead of
11984     IdentifyListCtrl. The grid allows editing of the values.
11985    
11986     * Thuban/UI/controls.py (RecordTable, RecordGridCtrl): New classes
11987     implementing a grid for a single row of a thuban table.
11988    
11989     * Thuban/UI/view.py (MapCanvas.SelectShapeAt): Search through all
11990     layers by default. Easier to use than the previous default of only
11991     searching through the select layer which meant that if no layer
11992     was selected, you couldn't select a shape.
11993    
11994     * Thuban/UI/tableview.py (TableGrid.__init__): Fix typo
11995    
11996     * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Honour the
11997     stroke_width attribute
11998    
11999     * Thuban/Model/save.py (save_session): Write the new stroke_width
12000     attribute
12001    
12002     * Thuban/Model/load.py (ProcessSession.startElement): Read the
12003     stroke_width attribute
12004    
12005     * Thuban/Model/layer.py (Layer.__init__): New parameter and
12006     instance variable stroke_width
12007     (Layer.SetStrokeWidth): Set the stroke_width.
12008    
12009 bh 72 2002-02-01 Bernhard Herzog <[email protected]>
12010    
12011     * extensions/thuban/wxproj.cpp (project_points): Fix two
12012     off-by-one errors in the last loop that joins the various parts
12013     together.
12014    
12015 bh 71 2002-01-14 Bernhard Herzog <[email protected]>
12016    
12017     * setup.py (data_dist.make_distribution): Fix some typos
12018    
12019 bh 70 2001-09-18 Bernhard Herzog <[email protected]>
12020    
12021     * README: Slight tweaking in preparation for the 0.1 release
12022    
12023     * setup.cfg: Add section for sdist to create both tgz and zip
12024     archives
12025    
12026     * setup.py: increase version number to 0.1
12027     (data_dist): New command class for data distribution
12028    
12029 bh 64 2001-09-14 Bernhard Herzog <[email protected]>
12030    
12031 bh 70 * Thuban/UI/identifyview.py (IdentifyListCtrl.selected_shape):
12032     Handle the case of no layer (i.e. layer is None) properly.
12033    
12034 tkoester 403 * Thuban/UI/proj4dialog.py (UTMDialog.__init__, Proj4Dialog.__init__):
12035 bh 70 Set the initial selection of the combo boxes to reflect the
12036     projection we're starting with in a way that works on windows,
12037     too.
12038    
12039 bh 64 * Thuban/Lib/connector.py (Connector.print_connections): Print the
12040     puiblisher's ids in hex to make it easier to compare them to the
12041     standard repr of python methods
12042    
12043     * Thuban/Model/map.py (Map.Destroy): Unsubscribe the label_layer
12044     messages
12045    
12046 bh 59 2001-09-13 Bernhard Herzog <[email protected]>
12047    
12048 bh 64 * Thuban/UI/tree.py (SessionTreeCtrl.OnSelChanged): Make sure to
12049     deselect the layer if no layer is selected
12050    
12051 bh 59 * Thuban/UI/view.py (MapCanvas.OnPaint): Only delay drawing to
12052     idle time when there actually is something to draw. If there's
12053     nothing to draw simply clear the window
12054     (MapCanvas.do_redraw): Call dc.EndDrawing and add some comments.
12055     (MapCanvas.SetMap): force a redraw in all cases because
12056     FitMapToWindow doesn't always do it.
12057     (MapCanvas.ZoomFactor): Add an optional parameter, center, to
12058     specify the point to move into the center of the window
12059     (ZoomOutTool.MouseUp, ZoomInTool.MouseUp): If the mouse wasn't
12060     dragged, zoon in/out by a factor of 2
12061 bh 64 (MapCanvas.find_shape_at): Iterate backwards (i.e. with decreasing
12062     index, i.e. reversed drawing order) so that objects appearing to
12063     be in from of others are selected first. This is probably mostly
12064     relevant for point shapes where the symbols used may overlap
12065 bh 59
12066     * Thuban/Model/session.py (create_empty_session): Unset the
12067     modified bit before returning it
12068    
12069     * Thuban/UI/mainwindow.py (MainWindow.NewSession): Use
12070     create_empty_session session to create the new, empty session.
12071    
12072     * Thuban/UI/mainwindow.py (MainWindow.__init__): Set the size of
12073     the tool bitmaps.
12074     (MainWindow.OnClose, MainWindow.save_modified_session): Separate
12075     the code that asks whether the session should be saved into the
12076     new method save_modified_session.
12077     (MainWindow.OpenSession, MainWindow.NewSession): Use the new
12078     method to save modified session here too.
12079    
12080 bh 55 2001-09-11 Bernhard Herzog <[email protected]>
12081    
12082     * setup.py (InnoIconItem): fix typo
12083    
12084     (thuban_bdist_inno.run):
12085     (bdist_inno.run): Move the decision not to create symlinks on
12086     non-nt platforms to thuban_bdist_inno and do it unconditinally
12087     since we never want to create the symlinks here
12088    
12089 bh 48 2001-09-10 Bernhard Herzog <[email protected]>
12090    
12091 bh 53 * Thuban/UI/mainwindow.py (MainWindow.IdentifyTool): Popup the
12092     identify view immediately
12093    
12094     * Thuban/UI/controls.py: New file with two classes RecordListCtrl
12095     and SelectableRecordListCtrl that implement the code shared by the
12096     identify view and the label dialog
12097    
12098     * Thuban/UI/identifyview.py (IdentifyListCtrl): Derive from the
12099     new class RecordListCtrl
12100    
12101     * Thuban/UI/labeldialog.py (LabelDialog.OnOK): Check whether the
12102     return value of GetValue is None instead of using it as a boolean
12103     directly so that Zero numbers are handled properly.
12104     (LabelListCtrl): Derive from the new class
12105     SelectableRecordListCtrl
12106    
12107 bh 48 * Thuban/UI/proj4dialog.py (Proj4Dialog.__init__):
12108     (Proj4Dialog.dialogLayout): Make the window resizable and set the
12109     size of the text control explicitly to make the sizers work on
12110     both Windows and X.
12111    
12112 bh 44 2001-09-07 Bernhard Herzog <[email protected]>
12113    
12114     * Thuban/UI/view.py (MapCanvas.find_shape_at):Add a new parameter
12115     that can limit the search to the currently selected layer.
12116     (MapCanvas.SelectShapeAt): Make sure that the currently selected
12117     layer stays selected even when no shape is found
12118 bh 46 (MapCanvas.FitRectToWindow): If the rect has zero with or zero
12119     height do nothing (avoids zero division errors)
12120 bh 44
12121 bh 32 2001-09-06 Bernhard Herzog <[email protected]>
12122    
12123 bh 42 * Thuban/UI/tree.py (SessionTreeCtrl, SessionTreeView.__init__):
12124     Correct the spelling of SessionTreeCtrl. dabbrev is too damn
12125     convenient :-)
12126     (SessionTreeCtrl.__init__, SessionTreeCtrl.update_tree): Introduce
12127     a new instvar layer_to_item to map layers to tree items
12128     (SessionTreeCtrl.layer_selected): Select the appropriate tree item
12129     to match the current selection in the interactor
12130    
12131 bh 40 * Thuban/UI/interactor.py (Interactor.SelectedLayer):
12132     (Interactor.HasSelectedLayer): New methods to query the current
12133     selection
12134    
12135     * Thuban/UI/mainwindow.py (MainWindow.current_layer):
12136     (MainWindow.has_selected_layer): Simply call the appropriate
12137     interactor method
12138    
12139     * Thuban/UI/mainwindow.py (MainWindow.__init__):
12140     (MainWindow.LayerShowTable):
12141     (MainWindow.identify_view_on_demand): Store the interactor in an
12142     instvar and use that reference instead of going through main.app
12143    
12144 tkoester 403 * Thuban/UI/mainwindow.py (MainWindow.ShowSessionTree):
12145     * Thuban/UI/application.py (ThubanApplication.OnInit):
12146 bh 40 * Thuban/UI/main.py (main): Create the session tree view in main
12147     with the new mainwindow method ShowSessionTree and not directly
12148     the application's OnInit method
12149    
12150     * Thuban/UI/tree.py (myTreeCtrlPanel):
12151     (SessioinTreeCtrl): Rename to SessioinTreeCtrl and turn it into a
12152     TreeCtrl isntead of a panel. This affects most method since we now
12153     refer to self instead of self.tree
12154     (SessionTreeView): New class implementing a non-modal dialog
12155     showing the session tree.
12156    
12157 bh 35 * Thuban/UI/mainwindow.py (MainWindow.LayerShowTable): Pass the
12158     layer to the tableview dialog.
12159    
12160     * Thuban/UI/tableview.py: Add some doc-strings
12161 tkoester 403 (TableGrid):
12162 bh 35 (TableGrid.OnRangeSelect):
12163     (TableGrid.OnSelectCell):
12164     (TableFrame.__init__):
12165     (TableFrame.row_selected):
12166     Selecting rows in the grid view now updates the selected shapes
12167     through the TableFrame. To achieve this we derive TableGrid from
12168     Publisher and introduce the message type ROW_SELECTED which the
12169     TableFrame subscribes to and which is issued by OnRangeSelect and
12170     OnSelectCell
12171    
12172     (DataTable.SelectRow): Removed because it's no longer needed in
12173     the row/shape selection scheme
12174    
12175 bh 32 * Thuban/UI/dialogs.py: New file implementing common classes for
12176     dialogs
12177    
12178     * Thuban/UI/tableview.py (TableGrid.__init__): Don't subscribe to
12179     the SELECTED_SHAPE message anymore. This is now handled by the
12180     parent.
12181     (TableGrid.select_shape): Only update the selection if the shape
12182     is not None.
12183     (TableFrame): Inherit from the new NonModalDialog class.
12184     (TableFrame.__init__, TableFrame.select_shape): Handle the
12185     SELECT_SHAPE message.
12186     (TableFrame.OnClose): Extend the inherited method to unsubscribe
12187     SELECT_SHAPE
12188    
12189     * Thuban/UI/mainwindow.py (MainWindow.init_dialogs):
12190     (MainWindow.add_dialog):
12191     (MainWindow.dialog_open):
12192     (MainWindow.remove_dialog):
12193     (MainWindow.get_open_dialog): New methods to maintain a dictionary
12194     of opened non-modal dialogs.
12195    
12196     (MainWindow.__init__): Initialize the new non-modal dictionary
12197     management code
12198     (MainWindow.LayerShowTable): maintain separate dialogs for each
12199     table using the non-modal dialog management code to only open a
12200     view once for each table.
12201    
12202     (MainWindow.IdentifyTool):
12203     (MainWindow.__init__):
12204     (MainWindow.identify_view_on_demand): Don't open the identify view
12205     in IdentifyTool anymore. This will be done automatically by the
12206     new method identify_view_on_demand which handles the
12207     SELECTED_SHAPE message so that the identify view will be opened on
12208     demand
12209    
12210     * Thuban/UI/identifyview.py (IdentifyListCtrl.__init__): Remove
12211     the interactor argument. The SELECTED_SHAPE message is now handled
12212     by the parent.
12213     (IdentifyView.__init__): Add the interactor argument so that we
12214     can handle the SELECTED_SHAPE message here
12215     (IdentifyView.selected_shape): New method to handle the
12216     SELECTED_SHAPE messages
12217    
12218     * Thuban/UI/identifyview.py (IdentifyView): Derive from the new
12219     NonModalDialog class
12220     (IdentifyView.OnClose): Extend the inherited version to
12221     unsubscribe SELECT_SHAPE
12222    
12223     * Thuban/Model/session.py (Session.UnsetModified): Remove debug prints
12224    
12225 bh 26 2001-09-05 Bernhard Herzog <[email protected]>
12226    
12227     * Thuban/UI/view.py (MapCanvas.__init__): New argument, interactor.
12228 tkoester 403
12229 bh 26 * Thuban/UI/mainwindow.py (MainWindow.__init__): New argument
12230     interactor to pass through to the MapCanvas
12231 tkoester 403
12232 bh 26 * Thuban/UI/application.py (ThubanApplication.OnInit): Use the new
12233     argument to the MainWindow constructor to get rid of the ugly hack
12234     that made main.app available early just so that the mapcanvas
12235     could access the interactor object.
12236    
12237 bh 19 2001-09-04 Bernhard Herzog <[email protected]>
12238    
12239 bh 22 * Thuban/UI/mainwindow.py (MainWindow.RunMessageBox): New method
12240     that runs a modal message box
12241     (MainWindow.OnClose): Use the new method
12242     (MainWindow.RemoveLayer): Just do nothing in case no layer is
12243     selected. The command should be grayed out anyway, so there's no
12244     need to pop up a message box.
12245     (MainWindow.AddLayer): Pop up a message box with an error message
12246     if the shape file can't be opened
12247    
12248     * Thuban/Model/layer.py (Layer.__init__): Open the shapefile
12249     immediately. This will cause an exception in case the file can't
12250     be opened and we can display an appropriate message.
12251    
12252 bh 19 * MANIFEST.in: Add extensions/pyprojection/LICENSE
12253    
12254     * setup.py (thuban_bdist_rpm): New class implementing a Thuban
12255     specific bdist_rpm command.
12256    
12257     * Thuban/UI/main.py: Catch ImportError exceptions when importing
12258     the locale module because it may not be available on some
12259     installations.
12260    
12261     * extensions/pyprojection/LICENSE: Copy of the license text in
12262     Projection.i. Having it in a separate file makes it easier to
12263     refer to license text in e.g. RPMs
12264    
12265 bh 18 2001-09-03 Bernhard Herzog <[email protected]>
12266    
12267 bh 19 * setup.py: use wx-config instead of wxgtk-config because it's
12268     more generic
12269    
12270     * setup.py (ThubanInstall.get_outputs): Add the symlink in
12271     <prefix>/bin to the outputs
12272     (ThubanInstall.link_file): New method to link files. We need this
12273     because the standard copy_files refuses to link non-existing
12274     files.
12275     (ThubanInstall.run): Remove the leading install root from the
12276     script filename if an install root was specified and use the new
12277     link_file method
12278 tkoester 403
12279 bh 18 * Thuban/UI/mainwindow.py (MainWindow.AddLayer): Fit the map to
12280     the window when the first layer is added to the map.
12281    
12282     * setup.py (ThubanInstall.run): Honor the build root (self.root)
12283     when linking thuban.py to <prefix>/bin
12284    
12285 bh 16 2001-08-31 Bernhard Herzog <[email protected]>
12286    
12287     * setup.py: In the setup call, the install parameters shouldn't
12288     have trailing slashes because distutils on non-posix platforms
12289     doesn't like that. The same applies to other directories like
12290     "Resources/Bitmaps"
12291    
12292     In the configuration section for nt, move the wxWindows directory
12293     optins into the part clearly marked as editable.
12294    
12295     (InstallLocal.initialize_options):
12296     (InstallLocal.user_options): remove the currently unused debug
12297     flag
12298     (thuban_build_py.find_all_modules): Add this method so that it
12299     works for our case of having packages and modules in one
12300     distribution as well.
12301     (ThubanInstall.initialize_options):
12302     (ThubanInstall.finalize_options):
12303     (ThubanInstall.user_options):
12304     (ThubanInstall.boolean_options): Add new options, do-symlink and
12305     extra files. Since these are the first ThubanInstall specific
12306     options, override user_options and boolean_options
12307     (ThubanInstall.run): Honor the new do-symlink and extra-files
12308     options.
12309     (ThubanInstall.get_outputs): Add to override the base-class's
12310     version and add the extra-files to the outputs
12311     (bdist_inno): New class for windows distributions with Inno Setup
12312     (InnoIconItem): Helper class for bdist_inno
12313     (thuban_bdist_inno): Thuban specific version of bdist_inno. Added
12314     this together with the appropriate parameters, to the setup call.
12315 tkoester 403
12316 bh 16 * setup.cfg (bdist_inno): added new section for the inno setup
12317     installer
12318    
12319     * Thuban/UI/tree.py (myTreeCtrlPanel.__init__): New inst var
12320     changing_selection to avoid recursive selection events when
12321     modifying the selection in response to a selection event.
12322     (myTreeCtrlPanel.normalize_selection): Set the new inst var when
12323     changing the tree's selection.
12324     (myTreeCtrlPanel.OnSelChanged): Only normalize the selection when
12325     we're not being called indirectly from normalize_selection.
12326    
12327     * Thuban/UI/mainwindow.py (MainWindow.update_command_ui): Call
12328     event.Check only if the command is actuall checkable.
12329     (MainWindow.__init__): Call the toolbar's Realize method to make
12330     sure that the items are actually shown
12331    
12332 bh 7 2001-08-28 Bernhard Herzog <[email protected]>
12333    
12334 bh 9 * setup.py: Fix some doc strings
12335    
12336 bh 7 * ChangeLog: started
12337    

Properties

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

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26