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

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

Parent Directory Parent Directory | Revision Log Revision Log


Revision 2733 - (hide annotations)
Mon Feb 26 23:05:09 2007 UTC (18 years ago) by bernhard
Original Path: trunk/thuban/ChangeLog
File size: 479969 byte(s)
MANIFEST.in: Added *.xmi to Doc so that ThubanModel.xmi is included
Improved ChangeLog.

1 bernhard 2731 007-02-26 Bernhard Reiter <[email protected]>
2    
3 bernhard 2733 * MANIFEST.in: Added *.xmi to Doc so that ThubanModel.xmi is included.
4    
5 bernhard 2732 * Extensions/svgexport/TODO: Added findings about how to write raster
6     in SVG.
7    
8     * Extensions/svgexport/svgmapwriter.py: untabified two lines.
9     Fixed a typo.
10    
11 bernhard 2731 * Doc/ThubanModel.xmi: Updated the format of the umbrello file.
12     Loaded and saved with umbrello 1.3.2, manually changed the
13     codegeneration tag to be empty again and change the XMI.model
14     to not contain a local path.
15     Now umbrello 1.5.5 also opens the file without crashing.
16     Thanks to Philippe LeGrand who discovered the problem and the
17     solution and filed report 141279 on bugs.kde.org for this umbrello
18     problem.
19    
20 dpinte 2730 2007-02-21 Didrik Pinte <[email protected]>
21    
22     * Extensions/umn_mapserver/__init__.py : UTF8 locales bugfix
23    
24 bernhard 2723 2007-02-20 Bernhard Reiter <[email protected]>
25    
26 bernhard 2729 * Thuban/version.py, setup.py: Getting ready for release 1.2.0.
27     Using this version number.
28    
29 bernhard 2728 * Doc/README: fixed a typo.
30    
31     * Doc/technotes/release_process.txt: Updated. Reference platform
32     is Debian Etch now. If windows, it should be window XP.
33     Marked a few entries in the instructions as "Old:".
34    
35     * README: Bumped requirements to wxWidgets 2.6.3.2 and gdal 1.3.2..
36     Added urls for homepage and infrastructure on wald. Fixed a typo.
37    
38 bernhard 2733 * MANIFEST.in: Added subdir "packaging" which should be in the tarball.
39 bernhard 2728
40     * NEWS: Completed changes from 1.1.0 until today as gathered from
41     the Changelog entries. Added small section about OGR known problems
42     because we do not have a release-notes file so far.
43    
44 bernhard 2727 * Doc/manual/thuban-manual.xml: Removed the installation instructions
45     as they are outdated and they should be only in one place.
46     Bumped version number of the document to 1.2.0. Marked it as Draft
47     in the title.
48    
49 bernhard 2726 * Extensions/svgexport/: Get ready for release. Bump version
50     number to 1.0.1. Adjusted numbers in TODO.
51    
52 bernhard 2725 * Thuban/UI/about.py: Reworked the about text. It shows now
53     when somebody was active on Thuban. Added a list of maintainers.
54     Bernhard Reiter is the current maintainer, following up on Bernhard
55     Herzog.
56    
57 bernhard 2724 * Extensions/export_shapefile/export_shapefile.py: untabify.
58 bernhard 2723
59 bernhard 2724 * test/README: Added example how to set the PATH for postgis on
60     Debian Etch.
61    
62 dpinte 2721 2007-01-13 Didrik Pinte <[email protected]>
63    
64     bboxdump, gns2shp, importAPR, mouseposition, ogr, profiling, svgexport
65     extensions migrated to wxPython 2.6
66    
67     * Extensions/bboxdump/bboxdump.py:
68     updated wx statements
69    
70     * Extensions/gns2shp/gns2shp.py:
71     updated wx statements
72    
73     * Extensions/importAPR/importAPR.py:
74     updated wx statements
75    
76     * Extensions/mouseposition/mouseposition.py:
77     updated wx statements
78    
79     * Extensions/ogr/
80     ogrdialog.py, ogrstart.py:
81     updated wx statements
82    
83     * Extensions/profiling/profiling.py:
84     updated wx statements
85    
86     * Extensions/svgexport/
87     maplegend.py, svgsaver.py:
88     updated wx statements
89    
90    
91 dpinte 2719 2007-01-08 Didrik Pinte <[email protected]>
92    
93 dpinte 2720 export_shapefile extension migrated to wxPython 2.6
94    
95     * Extensions/export_shapefile/export_shapefile.py:
96     updated wx statements, changed the FileDialog to wx.SAVE (was wx.OPEN)
97    
98     2007-01-08 Didrik Pinte <[email protected]>
99    
100 dpinte 2719 umn_mapserver extension migrated to wxPython 2.6
101    
102     * Extensions/umn_maserver/
103     mf_handle.py, mf_import.py, mf_export.py:
104     update wx imports to 2.6 policy
105    
106 dpinte 2718 2007-01-06 Didrik Pinte <[email protected]>
107    
108 bernhard 2722 UTF-8 locales support reading non utf-8 files.
109     This is a workaround and not a real bugfix. See
110     http://wald.intevation.org/tracker/index.php?func=detail&aid=118
111     for more details
112 dpinte 2718
113 bernhard 2722 * Thuban/UI/tableview.py, controls.py, baserenderer.py, view.py:
114     decode text from iso-8859-1 encoding.
115 dpinte 2718
116 bernhard 2717 2007-01-01 Bernhard Reiter <[email protected]>
117 bernhard 2722
118 bernhard 2717 * test/postgissupport.py, test/test_postgis_db.py: adding an
119     explicit WITH OIDS to the create table commands. This fixes tests
120     that rely on an oid column to be present for postgresql >=8.0.
121     Thanks for Frank Koormann for the hint.
122    
123 dpinte 2716 2006-11-06 Didrik Pinte <[email protected]>
124    
125     * libraries/thuban/wxproj.cpp: bugfix - allow compilation with
126     msvc++ toolkit 2003
127    
128 bernhard 2714 2006-11-06 Bernhard Reiter <[email protected]>
129    
130 bernhard 2715 Made it easier to run PostGIS test on Debian Etch. Improving
131     https://wald.intevation.org/tracker/index.php?func=detail&aid=173 .
132 bernhard 2714
133     * test/postgissupport.py: Taking pg_ctl and initdb commands
134     from internal variables now. Adding deactivated example values
135     for Debian Etch.
136     find_postgis_sql(): Added special line for Debian Etch postgresql-8.1.
137     Added copyright year 2006.
138    
139 bernhard 2713 2006-10-25 Bernhard Reiter <[email protected]>
140    
141     Moved ogr Extension to Extension menu.
142    
143     * Extensions/ogr/
144     __init__.py, ogrstart.py, ogrshapes.py, ogrdialog.py
145     test/test_OGRShapestore.py, test/__init__.py:
146     adding encoding information and made sure Autor's names
147     with an umlaut are actually written with an umlaut.
148    
149     * Extensions/ogr/ogrstrat.py: now registering in menu "Extensions",
150     having a "(testing)" string before the submenu to prepare for 1.2.0
151     release. Bumped copyright year to 2006.
152    
153 bernhard 2712 2006-10-15 Bernhard Reiter <[email protected]>
154    
155     * Thuban/UI/renderer.py: Added module variable verbose and
156     added verbose output before doing a raster projection.
157     Minor: Added (c) year 2006.
158    
159     * test/test_baserenderer.py: Added new function
160     test_projected_raster_decimalcommalocale()
161     Added new author Bernhard Reiter and new copyright year 2006.
162    
163     * libraries/thuban/gdalwarp.cpp(ProjectRasterFile): Adding
164     switching to LC_NUMERIC "C" and back before calling GDAL functions -
165     only #if python >=2.4 .
166    
167 dpinte 2710 2006-10-10 Didrik Pinte <[email protected]>
168 dpinte 2711
169     Win32 build updates
170    
171     * setup.py :
172     - update to the latest libs for win32 setup tasks
173     - added gdal and Lib content to the inno setup build task
174     - added stable and experimental extensions to setup packages
175    
176     * thuban.py :
177     - gdal support for win32 inno installation
178    
179     2006-10-10 Didrik Pinte <[email protected]>
180    
181 dpinte 2710 * Thuban/Model/layer.py (Layer.GetLabelPosFromShape): new method
182     extracted from Thuban/UI/viewport.py
183     * Thuban/UI/viewport.py (Viewport.LabelShapeAt): uses new method
184    
185 dpinte 2709 2006-09-28 Didrik Pinte <[email protected]>
186    
187     * Thuban/UI/classgen.py: bugfix due to wx2.6 update
188    
189     * Thuban/UI/view.py: removed non needed declaration
190    
191     * Thuban/UI/selection.py : typo correction
192    
193 bernhard 2705 2006-09-24 Bernhard Reiter <[email protected]>
194    
195 bernhard 2708 * Thuban/Model/proj.py(_do_we_have_to_work_around_broken_proj):
196     Making the test more robust for observed python 2.3 problems
197     with setlocale().
198    
199 bernhard 2705 * test/runtests.py: Added new option ---setdecimalcommalocale
200 bernhard 2712 to run all tests with an LC_NUMERIC that uses comma as decimal_point.
201 bernhard 2705 Minor: Added (c) year 2006. Fixed typo in a docstring.
202    
203     * test/test_transientdb.py: Minor: Added (c) year 2006. Fixed typo in
204     a docstring.
205    
206 bernhard 2702 2006-09-23 Bernhard Reiter <[email protected]>
207    
208     * Extensions/ogr/test/test_OGRShapestore.py: fixed skip_if_no_ogr()
209     and added it to TestOGRTable.setUp() so that all tests get skipped
210     if ogr cannot be imported. Added (c) year 2006.
211    
212 dpinte 2701 2006-09-18 Didrik Pinte <[email protected]>
213    
214     * wxPython 2.6 update : wx 2.4 syntax has been updated to 2.6
215    
216 bernhard 2696 2006-09-18 Bernhard Reiter <[email protected]>
217    
218 bernhard 2698 Fixed proj behaviour with python >=2.4 when decimal_point != '.'.
219    
220 bernhard 2697 * Thuban/UI/application.py: Fixed warning dialog when gdal is missing.
221    
222     * test/test_proj.py: new test_lc_numeric_robustness(). Added author
223     Bernhard Reiter and new copyright year 2006.
224    
225 bernhard 2698 * Thuban/Model/proj.py: New _do_we_have_to_work_around_broken_proj()
226     and Projection.assuregoodlocale(), Projection.assureinitlocale().
227     Added author Bernhard Reiter and (c) 2006.
228    
229 bernhard 2694 2006-09-15 Bernhard Reiter <[email protected]>
230 bernhard 2692
231     * README: added RXP and pyRXP as optional for tests.
232 bernhard 2697
233 bernhard 2694 * test/localessupport.py: New. Contains a helper function
234     to find a locale with comma used as decimal_point.
235 bernhard 2692
236 bernhard 2690 2006-08-31 Bernhard Reiter <[email protected]>
237 bernhard 2691
238 bernhard 2690 * README: fixed URLs to sqlite and pysqlite.
239 bernhard 2697
240 bernhard 2691 * Thuban/UI/about.py: Added Didrik Pinte as contributor. Extended
241     copyright range to include 2006.
242 bernhard 2690
243 dpinte 2689 2006-06-29 Didrik Pinte <[email protected]>
244    
245     * Thuban/UI/main.py: circular import fix.
246    
247 frank 2688 2006-06-27 Frank Koormann <[email protected]>
248    
249     New Classification "Pattern": Classify text attributes by regexp.
250    
251     * Thuban/Model/classification.py (class ClassGroupPattern):
252     New, group is associated with a regular expression.
253     (Classification._compile_classification): Store compiled regexp and
254     original group for pattern.
255     (Classification.FindGroup): Added pattern.
256    
257     * Thuban/UI/classifier.py
258     (ClassGrid._OnLabelRightClicked, ClassGrid.labelPopup):
259     New, add popup to select singleton/pattern.
260     (ClassTable.GetRowLabelValue, ClassTable.GetValueAsCustom,
261     ClassTable.SetValueAsCustom): Added pattern.
262     (ClassTable.__ParseInput): Autodetect singleton/pattern.
263    
264     * Thuban/Model/save.py (SessionSaver.write_classification):
265     Added pattern.
266    
267     * Thuban/Model/load.py (SessionLoader.start_clpattern,
268     SessionLoader.end_clpattern): New, process pattern elements.
269    
270     * test/test_classification.py (class TestClassGroupPattern): New.
271     (TestClassification.test_add_pattern,
272     TestClassification.test_multiple_groups_textual,
273     TestClassification.test_deepcopy_textual): New.
274     (TestClassification.test_multiple_groups_numerical):
275     Renamed test_multiple_groups.
276     (TestClassification.test_deepcopy_numerical): Renamed test_deepcopy.
277    
278     * test/test_save.py (SaveSessionTest.testClassifiedLayer):
279     Added pattern.
280    
281     * test/test_load.py (ClassificationTest.TestLayers, TestClassification):
282     Added pattern.
283    
284     * test/test_layer.py
285     (TestLayerModification.test_set_classification_textual): New
286     (TestLayerModification.test_set_classification_numerical):
287     Renamed test_set_classification.
288    
289     * Doc/manual/thuban-manual.xml: Added pattern to layer classification
290     description.
291    
292     * Resources/XML/thuban-1.1.dtd: Added clpattern element and attribs.
293    
294 dpinte 2687 2006-06-29 Didrik Pinte <[email protected]>
295    
296     * Thuban/version.py: Bugfix determination of SQLite, the wright one !
297    
298 dpinte 2685 2006-06-28 Didrik Pinte <[email protected]>
299    
300 dpinte 2686 * packaging/windows/thubanstart.py: sample file loading all the stable
301     extensions
302    
303     2006-06-28 Didrik Pinte <[email protected]>
304    
305 dpinte 2685 * Thuban/version.py: Bugfix determination of SQLite on old and recent
306     systems (support pysqlite1 and pysqlite2)
307    
308 frank 2684 2006-06-27 Frank Koormann <[email protected]>
309    
310     * Thuban/version.py: Bugfix determination of SQLite on old systems.
311    
312 dpinte 2683 2006-05-17 Didrik Pinte <[email protected]>
313     * Extensions/ogr/__init__.py : updated test for win32 and correct
314     imports
315    
316 dpinte 2680 2006-05-15 Didrik Pinte <[email protected]>
317 dpinte 2682 Ashamed ... still some tabs in the files
318    
319 bernhard 2722 * Thuban/version.py : tabs removed
320     * Thuban/Model/transientdb.py : tabs removed
321 dpinte 2682
322     2006-05-15 Didrik Pinte <[email protected]>
323    
324 bernhard 2722 * Thuban/version.py : coding style correction
325     * Thuban/Model/transientdb.py : coding style correction
326 dpinte 2681
327     2006-05-15 Didrik Pinte <[email protected]>
328 dpinte 2682
329 bernhard 2722 * Thuban/version.py : Updated imports to support pysqlite2
330 dpinte 2682
331 bernhard 2722 * Thuban/Model/transientdb.py : Updated imports to support pysqlite2
332 dpinte 2680 Patched the querying system to support the param style of pysqlite2
333    
334 dpinte 2679 2006-04-24 Didrik Pinte <[email protected]>
335 bernhard 2722
336     * Extensions/svgexport/__init__.py: The extension now works on win32
337 dpinte 2679 architecture. Bug #87 corrected.
338    
339 bernhard 2678 2006-04-20 Bernhard Reiter <[email protected]>
340 bernhard 2722
341 bernhard 2678 * Doc/technotes/coding_guidelines.txt: Changed text from CVS to SVN.
342     Removed emacs specific hint and replaced it with a general hint
343     that editors might support writing changelogs.
344    
345 bernhard 2677 2006-04-12 Bernhard Reiter <[email protected]>
346 bernhard 2678
347 bernhard 2677 * Thuban/version.py: Changed thuban_release mechanism to use "svn"
348     instead of "cvs".
349    
350 bernhard 2676 2006-03-31 Bernhard Reiter <[email protected]>
351    
352     * libraries/thuban/wxproj.cpp: including proj_api.h instead of
353     projects.h now. According the Frank Warmerdam and man pj_init
354     this is the public interface to proj. Thus I have changed PJ to projPJ.
355     And I could remove the hack to avoid clashes with typedef PVALUE
356     and #define LP in projects.h clashing with symbols when trying to
357     build on windows. The file is cleaner and nicer now.
358    
359 bernhard 2675 2006-03-29 Bernhard Reiter <[email protected]>
360 bernhard 2678
361 bernhard 2675 * libraries/thuban/wxproj.cpp: undef LP to avoid clash when
362     trying to build with mingw.
363    
364 bernhard 2673 2005-10-18 Bernhard Reiter <[email protected]>
365    
366 bernhard 2674 * Thuban/UI/about.py: remove unused import of getdefaultlocale.
367     Added display of internal encoding to the about dialog text.
368    
369     * Extensions/svgexport/__init__.py: changed version to "1.0.0+cvs".
370    
371     2005-10-18 Bernhard Reiter <[email protected]>
372    
373 bernhard 2673 Startup improved: We fail right away if the internal encoding could
374     not be determined.
375    
376     * Thuban/__init__.py (get_internal_encoding): new.
377    
378     * test/test_stringrepresentation.py (class TestInternalEncoding):
379     Preserve the internal encoding for the tests in this class.
380    
381 bernhard 2671 2005-10-17 Bernhard Reiter <[email protected]>
382    
383 bernhard 2672 * test/test_stringrepresentation.py: New file, for now testing
384     that set_internal_coding() is throwing an exception for bad exceptions.
385    
386     * Thuban/__init__.py (set_internal_encoding): added a forwards
387     and backward translation, so that we fail early if the
388     internal_encoding is bad.
389    
390     2005-10-17 Bernhard Reiter <[email protected]>
391    
392 bernhard 2671 svgexport 1.0.0cvs: Fixed ARC layer writing: No filling is done.
393     You could actually get polylines with filling in between,
394     when the classification for the lines had a fill color.
395     E.g. this happens when you generate a classification from a ramp.
396    
397     * Extensions/svgexport/test/test_svgmapwriter.py:
398     New test_export_arc_no_fill(). Extend copyright notice to 2005.
399    
400     * Extensions/svgexport/svgmapwriter.py
401     (SVGRenderer.draw_shape_layer_incrementally()):
402     Setting TRANSPARENT_BRUSH for shaptype ARC.
403     Extend copyright notice to 2005.
404    
405     * Extensions/svgexport/__init__.py: Extend copyright notice to 2005.
406    
407 frank 2670 2005-09-08 Frank Koormann <[email protected]>
408    
409     * Doc/manual/thuban-manual.xml (Map Management): Fixed typo reported
410     by Erik (sigra.at.home.se)
411    
412 jan 2669 2005-08-18 Jan-Oliver Wagner <[email protected]>
413    
414     * Thuban/UI/renderer.py (ScreenRenderer.draw_selection_incrementally):
415     Call the right method for the default size.
416    
417 jan 2667 2005-08-11 Jan-Oliver Wagner <[email protected]>
418    
419     * Extensions/export_shapefile: New.
420    
421     * Extensions/export_shapefile/__init__.py: New. Initialize
422     the export_shapefile extension.
423    
424     * Extensions/export_shapefile/export_shapefile.py: New.
425     Exports a layer as a Shapefile.
426    
427 jan 2664 2005-08-08 Jan-Oliver Wagner <[email protected]>
428    
429     * po/de.po: String fixes. This fixes Debian bug #313843.
430    
431 jan 2660 2005-07-27 Jan-Oliver Wagner <[email protected]>
432    
433     Remove the attributes from the layer element in
434     .thuban files for the save routine.
435     This also solves RT bug #3149,
436     https://intevation.de/rt/webrt?serial_num=3149
437    
438     * test/test_load.py: (TestSingleLayer, TestNonAsciiColumnName,
439     TestLayerVisibility, TestSymbolSize, TestClassification, TestLabels,
440     TestLayerProjection, TestJoinedTable, TestLabelLayer): Removed
441     attributes from layer element to classification clnull element.
442    
443     * test/test_save.py (SaveSessionTest.testSingleLayer,
444     SaveSessionTest.testLayerProjection,
445     SaveSessionTest.testClassifiedLayer,
446     SaveSessionTest.test_joined_table, SaveSessionTest.test_save_postgis):
447     Removed attributes from layer element to classification clnull element.
448     (test_save_postgis.NonConnectionStore._fetch_table_information):
449     added pretending to have a shape_type.
450    
451     * Resources/XML/thuban-1.1.dtd: Make the attributes field
452     and field_type of classification optional.
453    
454     * Thuban/Model/classification.py (Classification.TreeItem.build_info):
455     Added output of size.
456    
457     * Thuban/Model/load.py (SessionLoader.start_classification):
458     Change attribute 'field' and 'field_type' from obligatory to
459     optional to allow empty classes (ie. only with a default=clnull).
460    
461     * Thuban/Model/save.py (SessionSaver.write_layer): Don't write
462     any attributes anymore for the layer element.
463     (SessionSaver.write_classification): Even if there is no
464     classification field, still write the classification because
465     the clnull (default) symbol will not be defined anymore as
466     part of the layer element.
467    
468 bh 2643 2005-07-05 Bernhard Herzog <[email protected]>
469    
470 bh 2652 * setup.py (setup call): Version 1.1.0
471    
472     * NEWS: Update for 1.1.0
473    
474     * MANIFEST.in: Add *.txt to files taken from Doc. Otherwise the
475     technores won't be included
476    
477     * Thuban/UI/about.py (About.__init__): Extend copyright notice to
478     2005
479    
480     * po/de.po: Updated.
481    
482     2005-07-05 Bernhard Herzog <[email protected]>
483    
484 bh 2645 * README: gdal 1.1.8 is too old. 1.2.5 works.
485    
486     2005-07-05 Bernhard Herzog <[email protected]>
487    
488 bh 2650 * Resources/XML/thuban-1.1.dtd (rasterlayer): Add the opacity and
489     masktype attributes.
490    
491     2005-07-05 Bernhard Herzog <[email protected]>
492    
493 bh 2644 * Thuban/Model/layer.py (Layer.__mangle_bounding_box)
494     (Layer.ClipBoundingBox): Rename ClipBoundingBox to
495     __mangle_bounding_box. See the comments in the code and RT #2845
496    
497     * test/test_layer.py (TestLayer.test_arc_layer_with_projection):
498     Remove the explicit test of ClipBoundingBox. The method isn't
499     public anymore and the direct call in the test wasn't necessary in
500     the first place. If ClipBoundingBox (now __mangle_bounding_box)
501     isn't called, the return value of ShapesInRegion will be
502     different.
503    
504     2005-07-05 Bernhard Herzog <[email protected]>
505    
506 bh 2643 * Thuban/UI/viewport.py (ViewPort.set_view_transform): Handle
507     ZeroDivisionError exceptions. I don't know when they happen
508     exactly. It probably happens when the projections aren't set
509     properly.
510    
511 bh 2642 2005-07-01 Bernhard Herzog <[email protected]>
512    
513     First step towards unicode. With this roughly we're at step 1
514     string_representation.txt
515    
516     * Doc/technotes/string_representation.txt: New. Document how
517     strings are represented in Thuban and how to get to a Unicode
518     Thuban.
519    
520     * Thuban/__init__.py (set_internal_encoding)
521     (unicode_from_internal, internal_from_unicode): New. The first few
522     functions for the internal string representation
523    
524     * Thuban/UI/about.py (unicodeToLocale): Removed. Use
525     internal_from_unicode instead.
526    
527     * Thuban/UI/__init__.py (install_wx_translation): Determine the
528     encoding to use for the internal string representation. Also,
529     change the translation function to return strings in internal
530     representation even on unicode builds of wxPython
531    
532     * Thuban/Model/load.py (SessionLoader.check_attrs): Decode
533     filenames too.
534     (SessionLoader.start_clrange): Use check_attrs to decode and check
535     the attributes.
536    
537     * Thuban/Model/xmlreader.py (XMLReader.encode): Use
538     internal_from_unicode to convert unicode strings.
539    
540     * Thuban/Model/xmlwriter.py (XMLWriter.encode): Use
541     unicode_from_internal when applicable
542    
543     * test/runtests.py (main): New command line option:
544     internal-encoding to specify the internal string encoding to use
545     in the tests.
546    
547     * test/support.py (initthuban): Set the internal encoding to
548     latin-1
549    
550     * test/test_load.py (TestSingleLayer.test, TestClassification.test)
551     (TestLabelLayer.test): Use the internal string representation when
552     dealing with non-ascii characters
553    
554     * test/test_load_1_0.py (TestSingleLayer.test)
555     (TestClassification.test, TestLabelLayer.test): Use the internal
556     string representation when dealing with non-ascii characters
557    
558     * test/test_load_0_9.py (TestSingleLayer.test)
559     (TestClassification.test): Use the internal string representation
560     when dealing with non-ascii characters
561    
562     * test/test_load_0_8.py (TestUnicodeStrings.test): Use the
563     internal string representation when dealing with non-ascii
564     characters
565    
566     * test/test_save.py (XMLWriterTest.testEncode)
567     (SaveSessionTest.testClassifiedLayer): Use the internal string
568     representation when dealing with non-ascii characters where
569     applicable
570    
571 bh 2638 2005-06-30 Bernhard Herzog <[email protected]>
572    
573 bh 2641 * test/runtests.py: Untabify.
574    
575     2005-06-30 Bernhard Herzog <[email protected]>
576    
577 bh 2639 * Thuban/UI/renderer.py (ScreenRenderer.draw_selection_incrementally):
578     untabify.
579    
580     2005-06-30 Bernhard Herzog <[email protected]>
581    
582 bh 2638 * Extensions/ogr/test/__init__.py: Add missing coding directive
583    
584 jan 2631 2005-06-28 Jan-Oliver Wagner <[email protected]>
585    
586 jan 2636 * Thuban/UI/renderer.py (ScreenRenderer.draw_selection_incrementally):
587     Use the default size for rendering selected items of default type.
588     Fixes part 2 of https://intevation.de/rt/webrt?serial_num=3149
589    
590     2005-06-28 Jan-Oliver Wagner <[email protected]>
591    
592 jan 2631 * Extensions/importAPR/apr.py (APR_BShSym): Extend by 'Stripple'.
593     (APR_TClr.GetThubanColor): Fix bug in color interpretation.
594     Thanks to Frank Koormann who identified this problem.
595    
596     * Extensions/importAPR/importAPR.py (APR_VShSym): New. Just
597     another symbol identified.
598    
599 jan 2628 2005-06-27 Jan-Oliver Wagner <[email protected]>
600    
601     * Doc/manual/thuban-manual-de.xml: More translations.
602    
603 jonathan 2626 2005-05-12 Jonathan Coles <[email protected]>
604    
605     * Thuban/UI/projdialog.py: Add missing import, which led to an
606     exception when opening a layer's projection.
607    
608 bh 2623 2005-05-09 Bernhard Herzog <[email protected]>
609    
610 bh 2624 * test/support.py (FileLoadTestCase.filename): Fix doc-string.
611    
612     2005-05-09 Bernhard Herzog <[email protected]>
613    
614 bh 2623 * Thuban/Model/postgisdb.py (PostGISConnection.connect): Set the
615     connection to autoconnect. Fixes RT#3148.
616    
617     * test/test_postgis_db.py
618     (TestPostGISSpecialCases.test_simple_error_handling): New test
619     that attempts to reproduce RT#3148.
620    
621 jonathan 2622 2005-05-06 Jonathan Coles <[email protected]>
622    
623     Add support for saving and loading the opacity and mask type
624     properties of RasterLayers. Also add support for proper use
625     of alpha information while drawing images not in 'RAW' format.
626     If transparency in an image format (e.g, PNG) is supported by
627     wxWidgets then the image would previously have been draw with
628     transparent regions, but the opaque regions would have been
629     unaffected by a change in the layer's opacity. This patch
630     corrects the problem.
631    
632     * Thuban/Model/layer.py (RasterLayer): Added opacity and
633     masktype parameters to the constructor, and set the
634     appropriate variables to those values.
635    
636     * Thuban/Model/load.py (SessionLoader.start_rasterlayer): Added
637     code to read the opacity and mask type of the layer and construct
638     a new layer with the additional parameters.
639    
640     * Thuban/Model/save.py (SessionSaver.write_layer): Added code
641     to save the opacity and mask type of a layer.
642    
643     * Thuban/UI/baserenderer.py (BaseRenderer.draw_raster_layer): Pass
644     the opacity of the layer to draw_raster_data rather than the layer.
645     (BaseRenderer.draw_raster_data): Remove the layer parameter because
646     the function doesn't need to know about the layer. Add the optional
647     opacity parameter whose default is 1.0. Add 'PNG' as a supported
648     graphics format.
649    
650     * Thuban/UI/renderer.py (MapRenderer.draw_raster_data): Fixed
651     signature to match that in BaseRenderer. Use the new opacity argument
652     in place of calling layer.Opacity(). In the case where the
653     format is not 'RAW', alpha_data is None and the loaded image has
654     alpha information, use the file's alpha information. This is
655     still subject to the layer's opacity setting.
656    
657     * test/test_baserenderer.py (SimpleRenderer.draw_raster_data):
658     Fixed signature to match that in BaseRenderer.
659    
660     * test/test_load.py (TestRasterLayer): Change file_contents to
661     include opacity and masktype variables.
662     (TestRasterLayer.test): Include tests for opacity and masktype
663     changes.
664    
665     * test/test_save.py (SaveSessionTest.testRasterLayer): Restructure
666     test to cover a variety of combinations of masktype and opacity
667     settings.
668    
669 jan 2612 2005-05-02 Jan-Oliver Wagner <[email protected]>
670    
671     * debian/rules: add --use-wx-python-swig-hack
672     to the build command.
673     Thanks to Moritz Lennert for pointing this out.
674    
675 jan 2610 2005-04-28 Jan-Oliver Wagner <[email protected]>
676    
677     Introduce OGRFileShapeStore in ogr extension.
678     This allows at least that loaded shapefile shape stores
679     can be saved correctly in the thuban session file
680     and reloaded again (reload is via core shapefile
681     routine, not OGR). For other types, .thuban files
682     can not be reloaded for the time being.
683    
684     * Extensions/ogr/ogrshapes.py (OGRFileShapeStore): New. This
685     class ist to be used for any file-based shape stores
686     accessed through OGR.
687    
688     * Extensions/ogr/ogrstart.py (open_with_ogr): Added
689     forgotten _ for i18n. Adapted call OpenFileShapestore
690     regarding new parameter.
691     (OpenFileShapestore): Use OGRFileShapeStore instead of
692     OGRShapeStore. Fix return value (None instead of null).
693     Add new parameter "mainwindow" to avoid accessing global
694     context.
695    
696 jan 2607 2005-04-27 Jan-Oliver Wagner <[email protected]>
697    
698     Introduce FileShapeStore as generalization for
699     file-based shape stores. In a first instance
700     this allows additional modules to handle shapefile
701     format as well, namely the OGR extension.
702    
703     * Thuban/Model/data.py: Various small fixes in doc-strings.
704     (FileShapeStore): New class.
705     (ShapefileStore): Derive from FileShapeStore.
706     (ShapefileStore.__init__): Call __init__ of FileShapeStore,
707     rename self.table to self._table, initialize self._bbox
708     (ShapefileStore._open_shapefile): Use self._bbox instead of self.bbox
709     and self.FileName() instead of self.filename.
710     (ShapefileStore.Table): Use self._table instead of self.table.
711     (ShapefileStore.FileName): Removed (moved to FileShapeStore).
712     (ShapefileStore.BoundingBox): Use self._bbox instead of self.bbox.
713    
714     * Thuban/Model/save.py: Replace ShapefileStore by FileShapeStore.
715     (SessionSaver.write_data_containers): Only use methods of the
716     base class FileShapeStore.
717    
718 joey 2604 2005-04-26 Martin Schulze <[email protected]>
719    
720     * Extensions/wms/wms.py (render_wms_layer): Adjusted the render
721     function to the modified render engine
722    
723     2005-04-25 Martin Schulze <[email protected]>
724    
725     * Thuban/UI/renderer.py (MapRenderer.projected_raster_layer):
726     Added a description according to the CVS log message
727    
728     2005-04-23 Martin Schulze <[email protected]>
729    
730     * Thuban/UI/renderer.py: Added a missing import
731    
732 russell 2600 2005-04-23 Russell Nelson <[email protected]>
733    
734 russell 2613 * Thuban/UI/view.py (MapCanvas.OnMiddle{Up,Down}): Changed the
735     way the previous tool is remembered, so that middle-button
736     panning works even if you haven't selected a tool.
737 russell 2600
738 bh 2598 2005-04-11 Bernhard Herzog <[email protected]>
739    
740     * libraries/thuban/wxproj.cpp: Move the compatibility code that
741     deals with the wxPython 2.4 version of wxPython.h into the #ifdef
742     branch that includes wxPython.h because it's only needed when
743     wxPython.h is used. Also, it won't compile when
744     USE_WX_PYTHON_SWIG_HACK is set otherwise.
745    
746 bh 2597 2005-04-07 Bernhard Herzog <[email protected]>
747    
748     * Thuban/UI/classifier.py (ClassGrid.__init__): Use -1 as the ID.
749     (ID_CLASS_TABLE): Removed. It wasn't used anywhere except in
750     ClassGrid.__init__ and it's value is outside of the valid
751     range (must be < 32768). wxPython 2.5 complains about it with an
752     exception.
753    
754 jan 2596 2005-04-05 Jan-Oliver Wagner <[email protected]>
755    
756     * Doc/manual/thuban-manual-de.xml: More translations.
757    
758 bh 2590 2005-04-05 Bernhard Herzog <[email protected]>
759    
760 bh 2591 * libraries/thuban/wxproj.cpp: Make it work with a wxPython.h from
761     wxPython 2.4 as well. Also, remove a now obsolete comment.
762    
763     2005-04-05 Bernhard Herzog <[email protected]>
764    
765 bh 2590 Use wxPython.h by default but provide a workaround when it isn't
766     available.
767    
768     * setup.py (wxproj_extension): New variable. Assign the Extension
769     instance for Lib.wxproj to this variable instead of putting it
770     directly into the listso that it can be accessed by other code
771     later.
772     (thuban_build_ext.user_options): Added boolean option
773     --use-wx-python-swig-hack.
774     (thuban_build_ext.initialize_options): Initialize the new option
775     to False.
776     (thuban_build_ext.finalize_options): If the new option was given,
777     define the preprocesser macro USE_WX_PYTHON_SWIG_HACK.
778     (thuban_build_ext): Update the doc-string
779    
780     * libraries/thuban/wxproj.cpp: Normally we use
781     wx/wxPython/wxPython.h now. Only if USE_WX_PYTHON_SWIG_HACK is
782     defined, use swigPtrConvertHack.h instead.
783    
784     * libraries/thuban/swigPtrConvertHack.h: Remove the code that was
785     copied over from wxPython.h.
786     (decode_pointer_new): New. Equivalent of decode_pointer for
787     wxPython 2.5.
788     (wxPyConvertSwigPtr): Modified to cope with wxPython 2.5 as well.
789    
790     * README: Add section on potential build problems which explains
791     how the work-around for a missing wxPython.h is activated.
792    
793 bh 2588 2005-03-29 Bernhard Herzog <[email protected]>
794    
795 bh 2589 * test/postgissupport.py (find_postgis_sql): Added yet another
796     potential location for (lw)postgis.sql because the file has moved
797     again in postgis 1.0.0 rc4.
798    
799     2005-03-29 Bernhard Herzog <[email protected]>
800    
801 bh 2588 * Thuban/UI/legend.py (BMP_SIZE_W, BMP_SIZE_H): Set both to 16 to
802     match the site of the legend_icon_layer icon. Otherwise wxpython
803     2.5 complains when the legend is created with the error:
804    
805     PyAssertionError: C++ assertion "(bitmap.GetWidth() == m_width &&
806     bitmap.GetHeight() == m_height) || (m_width == 0 && m_height ==
807     0)" failed in ./src/generic/imaglist.cpp(81): invalid bitmap size
808     in wxImageList: this might work on this platform but definitely
809     won't under Windows.
810    
811 jonathan 2587 2005-03-23 Jonathan Coles <[email protected]>
812    
813     These changes add support for adjusting the opacity of a raster layer.
814    
815     * Thuban/Model/layer.py (RasterLayer.Opacity): Replaces AlphaOpacity.
816     (RasterLayer.SetOpacity): Replaces SetAlphaOpacity. Also triggers
817     a LAYER_CHANGED event if the opacity actually changes.
818    
819     * Thuban/UI/baserenderer.py (BaseRenderer.draw_raster_data): Added
820     layer parameter needed in the implementation of this method in
821     renderer.py.
822    
823     * Thuban/UI/layerproperties.py (LayerProperties.dialog_layout): Fixed
824     typo 00 -> 0.
825    
826     * Thuban/UI/rasterlayerproperties.py (RasterLayerProperties): Added
827     control to adjust opacity.
828    
829     * Thuban/UI/renderer.py (MapRenderer.draw_raster_data): Scale the
830     alpha data based on the opacity level of the layer.
831    
832     * test/test_baserenderer.py (SimpleRenderer.draw_raster_data): Now
833     accepts a layer parameter.
834    
835     * test/test_layer.py (TestLayerModification.test_raster_layer):
836     Rename opacity method calls and add test for LAYER_CHANGED.
837    
838 bh 2586 2005-03-16 Bernhard Herzog <[email protected]>
839    
840     * test/test_connector.py (DeletionTestMixin.check_deletions)
841     (DeletionTestMixin.check_deletetions): renamed to check_deletions.
842     update the callers.
843    
844 jan 2585 2005-03-14 Jan-Oliver Wagner <[email protected]>
845    
846     * Doc/manual/thuban-manual-de.xml: More translations.
847    
848 jan 2584 2005-03-10 Jan-Oliver Wagner <[email protected]>
849    
850     Introducing initialization callbacks for extensions.
851    
852     * Thuban/UI/extensionregistry.py (ExtensionDesc.__init__): Added
853     optional parameter init_callback.
854     (ExtensionDesc.init_ext): New. Executes the callback and sets
855     a status.
856    
857     * Thuban/UI/application.py (ThubanApplication.OnInit): Add the
858     initialization of the extensions.
859     (ThubanApplication.init_extensions): Init all extensions.
860    
861     * Thuban/UI/about.py (About.__init__): Added status of the extensions
862     to the about text.
863    
864     * Extensions/gns2shp/__init__.py: Added init method for Extension
865     description.
866     (init): New. Contains the initialization of the module.
867    
868 nhueffme 2577 2005-03-04 Nina Hüffmeyer <[email protected]>
869    
870     * Extensions/ogr/ogrdialog.py: Added a dialog, which asks for
871     OGRConnection to open a datasource. Removed dialog to display all
872     available drivers. Added some doc strings.
873    
874     * Extensions/ogr/ogrstart.py: Added menu entry for opening an
875     OGRDatasource with a string. Added two opening methods which return an
876     OGRDatasource (either data from file or from DB).
877    
878     * Extensions/ogr/ogrshapes.py: Added class OGRGeometry, which
879     represents a geometry reference of an OGRFeature. OGRShape now has a
880     list of referenced geometry objects (important for geometry
881     collections).
882     For OGRShapeStores loaded from a DB an ID column can be specified now.
883    
884 jan 2576 2005-02-22 Jan-Oliver Wagner <[email protected]>
885    
886     * test/test_map.py (TestMapWithContents.test_tree_info):
887     Added label layer for comparison.
888    
889 jonathan 2574 2005-02-18 Jonathan Coles <[email protected]>
890    
891     * libraries/thuban/gdalwarp.cpp (GetImageData): Optimize the loop
892     which builds a mask. Handle the majority of an image in a loop,
893     creating 8 bits at a time. Later, handle the edge case where less
894     than 8 bits are packed.
895    
896 bh 2573 2005-02-18 Bernhard Herzog <[email protected]>
897    
898     * test/test_baserenderer.py (TestBaseRenderer.setUp): Fix
899     doc-string
900    
901 jonathan 2571 2005-02-18 Jonathan Coles <[email protected]>
902    
903 jonathan 2572 * setup.py: Remove wx_cs_params from gdal compile options.
904    
905     2005-02-18 Jonathan Coles <[email protected]>
906    
907 jonathan 2571 Refactored baserenderer.py and renderer.py to remove baserenderer.py's
908     dependencies on wxPython. Added a new method projected_raster_layer()
909     that returns a raster layer image in projected space. This must be
910     implemented in classes derived from BaseRenderer. This also eliminates
911     the dependency on gdal in baserenderer.py.
912    
913     * Thuban/UI/baserenderer.py (BaseRenderer.draw_raster_layer): Call
914     new projected_raster_layer() to get projected raster image instead
915     of directly calling ProjectRasterFile().
916     (BaseRenderer.projected_raster_layer): New. This must be implemented
917     by derived classes. It takes almost the same arguments as ProjectRasterFile
918     did and returns a projected image with mask and alpha data (if requested).
919     (BaseRenderer.render_map_incrementally): Remove the check for gdal since
920     that check will be done in MapRenderer.projected_raster_layer(). This
921     also allows other implementations to use different projection code.
922    
923     * Thuban/UI/renderer.py (MapRenderer.projected_raster_layer):
924     Implementation of BaseRenderer.projected_raster_layer. Checks for
925     gdal support and wxPython version. Also handles exceptions from
926     ProjectRasterFile.
927    
928     * libraries/thuban/gdalwarp.cpp: Removed checks for wxPython versions
929     and added a variable which can be set through the options argument
930     of ProjectRasterFile.
931    
932     * test/test_baserenderer.py (SimpleRenderer.projected_raster_layer): New.
933     Calls ProjectRasterFile and returns the result.
934     (TestBaseRenderer.test_projected_raster_layer): New. Tests the results
935     of calling projected_raster_layer() with different options.
936     (TestBaseRenderer.test_raster_no_projection): Removed tests based on
937     wxPython version and all tests of masks and alpha channels. These are
938     now in test_projected_raster_layer().
939    
940 jan 2565 2005-02-17 Jan-Oliver Wagner <[email protected]>
941    
942 jan 2570 * Thuban/Model/map.py, Thuban/Model/label.py: Fixed
943     doc-strings to comply with coding_guidelines.
944    
945     2005-02-17 Jan-Oliver Wagner <[email protected]>
946    
947 jan 2565 Docstring improvements and minor fixes for labellayer.
948    
949     * Thuban/Model/map.py:
950     (Map, Map.Destroy, Map.RemoveLayer, Map.ClearLayers,
951     Map.Layers, Map.HasLayers, Map.MoveLayerToTop,
952     Map.RaiseLayer, Map.LowerLayer, Map.MoveLayerToBottom,
953     Map.ProjectedBoundingBox, Map.GetProjection): Improved/added
954     doc string.
955     (Map.BoundingBox): Removed superfluous test for label_layer
956     and improved doc string.
957     (Map.TreeInfo): Added label_layer and improved sdo string.
958    
959     * Thuban/Model/label.py: Added import of _.
960     (Label, Label.__init__): Improved/added doc string.
961     (LabelLayer, LabelLayer.__init__, LabelLayer.Labels,
962     LabelLayer.RemoveLabel, LabelLayer.ClearLabels):
963     Improved/added doc string.
964     (LabelLayer.AddLabel): Use already defined names for
965     align strings and improved doc string.
966     (LabelLayer.TreeInfo): New. Return the object data for
967     the tree view.
968    
969 jonathan 2562 2005-02-16 Jonathan Coles <[email protected]>
970    
971     Further wxPython 2.5 changes using patches from Daniel Calvelo Aros
972     so that that wxproj doesn't crash. Added GUI support for selecting
973     alpha channel (opacity can't be selected yet).
974    
975     NOTE: If wxPython.h is including in future distribution packages
976     then it will not be necessary to have the files swigPtrConvertHack.h
977     and wxPython_int.h included with Thuban. This is hopefully
978     a temporary workaround.
979    
980     * setup.py (thuban_build_ext.finalize_options): gdalwarp needs
981     access to the macro wxCHECK_VERSION so that it will properly
982     generate a bit mask. There was a problem between wx2.4 and wx2.5
983     that this works around.
984    
985     * Thuban/Model/layer.py (RasterLayer.UseMask): Removed in favor
986     of RasterLayer.MaskType.
987     (RasterLayer.SetUseMask): Removed in favor of RasterLayer.SetMaskType
988     (RasterLayer.MaskType): New. Returns the type of mask to use. Can
989     specify none, a bitmap, or an alpha channel.
990     (RasterLayer.SetMaskType): New. Set what kind of mask to use.
991    
992     * Thuban/UI/baserenderer.py (BaseRenderer.draw_raster_layer):
993     Set the raster warping options for the mask based on the value
994     of RasterLayer.MaskType.
995    
996     * Thuban/UI/legend.py (LegendTree.__FillTreeLayer): Remove
997     deprecated calls to SetItemSelectedImage in favor of SetItemImage
998     with wxTreeItemIcon_Selected.
999    
1000     * Thuban/UI/rasterlayerproperties.py: Support selecting to use
1001     an alpha channel for the mask.
1002    
1003     * Thuban/UI/renderer.py (MapRenderer.draw_raster_data): Use alpha
1004     data if it is available and an alpha channel is supported under
1005     the current version of wxPython.
1006    
1007     * libraries/thuban/gdalwarp.cpp (GetImageData): Added compiler define
1008     to select whether 1's or 0's select the desired portion of an image
1009     in the bit mask. wx2.4 has a bug where the documentation is the opposite
1010     from behavior.
1011     (ProjectRasterFile): Only generate an alpha channel if the version
1012     of wxPython is >= 2.5.3.
1013    
1014     * libraries/thuban/wxproj.cpp: Applied patches from Daniel Calvelo Aros.
1015     When wxPython >= 2.5.3 use the special swig functions to decode an
1016     object's address.
1017    
1018     * libraries/thuban/swigPtrConvertHack.h: Includes conditional code
1019     based on the version of wxPython. If >= 2.5.3 use the special swig
1020     functions from wxPython to decode wxPython objects, otherwise use
1021     the old method of retrieving the address from the object __repr__ string.
1022    
1023     * libraries/thuban/wxPython_int.h: Copied from wxPython source.
1024     Unnecessary code was removed to make it smaller.
1025    
1026     * test/test_baserenderer.py (TestBaseRenderer.test_raster_no_projection):
1027     Add tests for returning an alpha channel.
1028    
1029     * test/test_layer.py (TestLayerModification.test_raster_layer): Fix
1030     tests that used removed functions UseMask and SetUseMask
1031    
1032    
1033 bh 2560 2005-02-08 Bernhard Herzog <[email protected]>
1034    
1035 bh 2561 More wxPython 2.5 changes. This time taken from a patch from
1036     Daniel Calvelo Aros.
1037    
1038     * Thuban/UI/tableview.py (QueryTableFrame.__init__)
1039     (QueryTableFrame.__init__): Pass the size of a spacer as a single
1040     item.
1041    
1042     * Thuban/UI/projdialog.py (ProjFrame.build_dialog)
1043     (ProjFrame.build_dialog): Pass the size of a spacer as a single
1044     item.
1045    
1046     * Thuban/UI/dbdialog.py (ChooseDBTableDialog.__init__): Pass the
1047     size of a spacer as a single item.
1048    
1049     * Thuban/UI/classifier.py (Classifier.dialog_layout): Pass the
1050     size of a spacer as a single item.
1051    
1052     2005-02-08 Bernhard Herzog <[email protected]>
1053    
1054 bh 2560 Compatibility with wxPython 2.5. The changes should make it work
1055     better with 2.5 while still keeping compatibility with 2.4. There
1056     are still problems with 2.5, though.
1057    
1058     * Thuban/UI/dock.py (DockableWindow.__CreateBorder): Pass the size
1059     of a spacer as a single item.
1060    
1061     * Thuban/UI/classifier.py (ClassGroupPropertiesCtrl): Derive only
1062     from wxControl
1063    
1064     * Thuban/UI/legend.py (LegendTree): When running with wxPython <
1065     2.5, add an implementation of the GetFirstChild method that does
1066     not require the second parameter.
1067     (LegendTree.find_layer, LegendTree._OnMsgMapLayersAdded)
1068     (LegendTree._OnMsgMapLayersRemoved, LegendTree.DeleteAllItems)
1069     (LegendTree.DeleteChildren, LegendTree.__ShowHideLayer): Do not
1070     pass the second parameter to GetFirstChild
1071    
1072 nhueffme 2559 2005-02-08 Nina Hüffmeyer <[email protected]>
1073    
1074     * Extensions/ogr/ogrshapes.py: Removed some print commands.
1075    
1076     * Extensions/ogr/ogrstart.py: Changed the GUI. OGR is no longer an
1077     additional menu but appears as a possibility in the menu Map.
1078    
1079 jonathan 2558 2005-02-07 Jonathan Coles <[email protected]>
1080     * libraries/thuban/gdalwarp.cpp: Removed the macros PYTHON_ERR
1081     and PYTHON_ERRF since they were no longer necessary.
1082    
1083 bernhard 2556 2005-02-07 Bernhard Reiter <[email protected]>
1084     * Thuban/UI/classifier.py (ClassGrid.DeleteSelectedRows):
1085     Enable translation for message string.
1086    
1087 joey 2555 2005-02-06 Martin Schulze <[email protected]>
1088    
1089     * Extensions/wms/infodialog.py (wmsInfoDialog.__init__): Adjusted
1090     the arguments of the contstructor to fit the global scheme
1091    
1092 nhueffme 2554 2005-01-31 Nina Hüffmeyer <[email protected]>
1093    
1094     * Extensions/ogr/ogrdialog.py: Added class ogrdialog.py, which provides
1095     some dialogs needed to start ogr.
1096    
1097     * Extensions/ogr/__init__.py: Changed comments to avoid encoding
1098     warnings.
1099    
1100     * Extensions/ogr/test/test_OGRShapestore.py: Changed comments to avoid
1101     encoding warnings.
1102    
1103 jonathan 2552 2005-01-28 Jonathan Coles <[email protected]>
1104    
1105 jonathan 2553 * libraries/thuban/gdalwarp.cpp (GetImageData): Recode how the
1106     mask is packed into a bit array. It's now slightly faster.
1107    
1108     2005-01-28 Jonathan Coles <[email protected]>
1109    
1110 jonathan 2552 * Thuban/Model/layer.py (RasterLayer.__init__): Make use_mask
1111     default to true.
1112    
1113     * Thuban/Model/load.py (SessionLoader.start_rasterlayer): Remove
1114     code that loads the state of the layer's use_mask flag. Its
1115     usefulness is still being debated.
1116    
1117     * Thuban/Model/save.py (SessionSaver.write_layer): Remove
1118     code that saves the state of the layer's use_mask flag. Its
1119     usefulness is still being debated.
1120    
1121     * Thuban/UI/baserenderer.py (BaseRenderer.draw_raster_layer): Pass
1122     options to ProjectRasterFile based on the state of layer.UseMask().
1123     Catch more exceptions from ProjectRasterFile so that Thuban doesn't
1124     quit is there is a problem projecting.
1125     (BaseRenderer.draw_raster_data): Change the documentation to
1126     describe the new format (XBM) that the mask data will be in.
1127    
1128     * Thuban/UI/renderer.py (MapRenderer.draw_raster_data): The mask
1129     data is in XBM format when format='RAW' which means it doesn't
1130     need to be converted to a wxImage before being used as a mask
1131     for a wxBitmap. Assume that if format != 'RAW' that the image
1132     data and mask data are in the same format.
1133    
1134     * libraries/thuban/gdalwarp.cpp (GetImageData): If alpha is enabled
1135     and a mask is requested, convert the alpha band to a bit array in
1136     XBM format. if an alpha channel is requested, simply return the
1137     data in the alpha band. Provide better error handling by returning
1138     python error messages (also fixes RT #2947).
1139     (ProjectRasterFile): Support multiple mask options, rather than simply
1140     a flag indicating that a mask should or should not be used. Provide
1141     better error handling by returning python error messages.
1142    
1143     * test/test_baserenderer.py (TestBaseRenderer.test_raster_no_projection):
1144     Add mask data to test.
1145    
1146     * test/test_layer.py (TestLayer.test_raster_layer): Test that a layer
1147     should use the mask by default.
1148     (TestLayerModificaton.test_raster_layer): Test that a layer should use
1149     the mask by default.
1150    
1151     * test/test_load.py (TestRasterLayer.test): Remove testing for
1152     use_mask flag in file.
1153    
1154     * test/test_save.py (SaveSessionTest.testRasterLayer): Remove testing
1155     for use_mask in file.
1156    
1157     * test/test_load_1_0_1.py: Removed. Shouldn't have been checked in.
1158    
1159 jonathan 2551 2005-01-26 Jonathan Coles <[email protected]>
1160    
1161     Add a new dialog box for raster layers. The dialog box allows
1162     the user to toggle a mask that is generated by ProjectRasterFile
1163     and is used to only draw the real parts of the projected image.
1164    
1165     * Thuban/UI/baserenderer.py (BaseRenderer.draw_raster_layer):
1166     Instruct the warping code to generate a mask if the raster layer
1167     requests one.
1168     (BaseRenderer.draw_raster_data): Removed obsolete optional mask argument.
1169    
1170     * Thuban/UI/renderer.py (MapRenderer.draw_raster_data): Removed
1171     obsolete optional mask argument.
1172    
1173     * Thuban/UI/classifier.py (Classifier): Change the parent class
1174     to LayerProperties and rework the code to support layout calls
1175     from the parent.
1176     (Classifier.dialog_layout): New. Layout the dialog box.
1177     (Classifier.map_layers_removed): Removed. Moved to parent class.
1178     (Classifier.map_replaced): Removed. Moved to parent class.
1179     (Classifier._OnTry): Renamed to OnTry to support parent class.
1180     (Classifier.OnClose): Removed. Supplied in parent class.
1181     (Classifier._OnCloseBtn): Removed. Supplied in parent class as OnCloseBtn.
1182     (Classifier._OnOK): Renamed to OnOK to support parent class.
1183     (Classifier._OnRevert): Renamed to OnRevert to support parent class.
1184    
1185     * Thuban/UI/layerproperties.py: New. Base class for layer properties
1186     dialog boxes.
1187    
1188     * Thuban/UI/rasterlayerproperties.py: New. Class for displaying
1189     raster layer properties.
1190    
1191     * libraries/thuban/gdalwarp.cpp: Replace the old gdalwarp.cpp code
1192     with the non-simple version supplied with gdal. This allows added
1193     features such as creating an alpha band.
1194     (GetImageData): Generate a mask array from the alpha band that is
1195     generated by gdal if the user has selected it. Try to support images
1196     that have more than three bands, such as images with RGB plus an
1197     alpha band.
1198     (ProjectRasterFile): Convert python argument for mask and tell
1199     gdal to enable or disable an alpha band.
1200    
1201     * Thuban/Model/layer.py (BaseLayer.Type): New. Returns a string
1202     describing what kind of layer the class is. Defaults to "Unknown",
1203     but should be overridden by subclasses.
1204     (Layer.Type): New. Override base class method.
1205     (RasterLayer.__init__): Create a flag for using a mask. Record extra
1206     data from gdal for display in the properties dialog.
1207     (RasterLayer.Type): New. Override base class method.
1208     (RasterLayer.UseMask): New. Returns True if the mask should be used.
1209     (RasterLayer.SetUseMask): New. Set if the mask should be used.
1210     (RasterLayer.ImageInfo): New. Return extra information about the image.
1211    
1212     * Thuban/Model/load.py (SessionLoader.start_rasterlayer): Load
1213     the mask information.
1214    
1215     * Thuban/Model/save.py (SessionSaver.write_layer): Save mask information.
1216    
1217     * Thuban/UI/mainwindow.py: Register the RasterLayerProperties and
1218     Classifier classes as dialogs to use with the proper layer types.
1219    
1220     * test/test_baserenderer.py (TestBaseRenderer.test_raster_no_projection):
1221     Fix test.
1222    
1223     * test/test_layer.py (TestLayer.test_raster_layer): Test new methods.
1224     (TestLayerModification.build_path): New. Support function.
1225     (TestLayerModification.test_raster_layer): New. Test new methods.
1226    
1227     * test/test_save.py (SaveSessionTest.testRasterLayer): Add tests for mask.
1228    
1229     * test/test_load.py (TestRasterLayer): Add tests for mask.
1230    
1231     * test/test_load_1_0_1.py: New. Copied from test_load.py.
1232    
1233     * test/test_baserenderer.py (SimpleRenderer.draw_raster_data): Removed
1234     obsolete optional mask argument.
1235    
1236 nhueffme 2549 2005-01-26 Nina Hüffmeyer <[email protected]>
1237    
1238     * Extensions/ogr/ogrshapes.py: Added two dictionaries to ShapeStore
1239     which maps the ids and the ordinals. Fixed RowIdToOrdinal(),
1240     RowOrdinalToId() and ReadRowAsDict().
1241    
1242     * Extensions/ogr/ogrstart.py: Added menu item which opens database
1243     layers for existing database connections.
1244    
1245     * Extensions/ogr/test/test_OGRShapestore.py: Fixed a message string.
1246    
1247    
1248 jan 2548 2005-01-26 Jan-Oliver Wagner <[email protected]>
1249    
1250     * Doc/manual/thuban-manual-de.xml: More translations.
1251    
1252 bh 2544 2005-01-24 Bernhard Herzog <[email protected]>
1253    
1254     Rework the status bar updates a bit to make sure the message about
1255     the projections is produced at the right times.
1256    
1257     * Thuban/UI/mainwindow.py (MainWindow.update_status_bar_messages):
1258     New class variable with messages that may require a status bar
1259     update.
1260     (MainWindow.view_position_changed)
1261     (MainWindow.update_status_bar): Rename from view_position_changed
1262     to update_status_bar. It's meaning has changed now that it may
1263     also generate messages about problems with projection settings.
1264     (MainWindow.__init__): Use the new update_status_bar_messages
1265     class variable to subscribe update_status_bar
1266     (MainWindow.set_position_text): Update doc-string. This method
1267     has to be renamed at some point. See doc-string and comments.
1268     (MainWindow.OnClose): Unsubscribe update_status_bar from all
1269     messages in update_status_bar_messages
1270    
1271     * Thuban/UI/viewport.py (ViewPort.forwarded_map_messages): New
1272     class attribute. map messages to be forwarded by the viewport.
1273     (ViewPort._subscribe_map, ViewPort._unsubscribe_map): (un)subscribe
1274     the messages in forwarded_map_messages
1275    
1276 bh 2543 2005-01-21 Bernhard Herzog <[email protected]>
1277    
1278     * test/postgissupport.py (PostGISDatabase.__init__): Tweak
1279     doc-string
1280     (find_postgis_sql): Update for postgis-1.0.0-rc1, which uses a
1281     different name for the initialization SQL file.
1282    
1283 jonathan 2537 2005-01-21 Jonathan Coles <[email protected]>
1284 jan 2542
1285     * Thuban/UI/baserenderer.py (proj_params_to_str): New. Takes
1286     a projection and returns a formatted string representing the
1287     parameters to feed to gdalwarp. This function eliminates
1288     redundancy in draw_raster_layer().
1289     (BaseRenderer.render_map_incrementally): Removed the optimization which
1290     drew the top most raster layer first and then only those vector-
1291     based layers that are above it. With the support for transparency
1292     this optimization breaks correct behaviour.
1293     (BaseRenderer.draw_raster_layer): Reorganize code to support possible
1294     future enhancements to raster layer bounding box. The old behaviour has
1295     not changed. Also, change calling parameters to draw_raster_data()
1296     to specify new RAW data format and mask.
1297     (BaseRenderer.draw_raster_data): Change signature to include an optional
1298     parameter for mask information. Change documentation to mention
1299     support for new parameter and added option for RAW data format.
1300     The data argument is now a list of [width, height, data].
1301    
1302     * Thuban/UI/renderer.py (MapRenderer.draw_raster_data): Add new optional
1303     mask parameter. Add new condition for RAW format, which
1304     significantly reduces rendering time. Add condition for
1305     mask parameter.
1306    
1307     * libraries/thuban/gdalwarp.cpp (GetImageData): New. Creates a
1308 jonathan 2537 data array of RGB values from the projected image returned from
1309     the gdal warping functions. In the case of palette based images, it
1310 jan 2542 converts the NO_DATA index to the mask color.
1311     (ProjectRasterFile): Removed all custom memory driver references
1312     and replaced it with the standard in-memory dataset provided
1313     by gdal. The return data is no longer a BMP file, but an array
1314     of RGB values, one set triple per pixel.
1315 jonathan 2537
1316     * libraries/thuban/bmpdataset.cpp: Removed. Unnecessary.
1317     * libraries/thuban/cpl_mfile.h: Removed. Unnecessary.
1318     * libraries/thuban/cpl_mfile.cpp: Removed. Unnecessary.
1319    
1320 jan 2542 * setup.py (thuban_build_ext.finalize_options): Removed mention
1321     of cpl_mfile.cpp and bmpdataset.cpp files in the list of source
1322     files. These are obsolete with the new version of gdalwarp.cpp
1323    
1324     * test/test_baserenderer.py (SimpleRenderer.draw_raster_data):
1325     Updated signature.
1326     (TestBaseRenderer.test_raster_no_projection): Changed the test
1327     data to be data in the uncompressed RAW format returned from
1328     ProjectRasterFile.
1329    
1330 jan 2535 2005-01-21 Jan-Oliver Wagner <[email protected]>
1331    
1332 jan 2542 * Thuban/UI/mainwindow.py (MainWindow.view_position_changed): Made
1333     string available for i18n.
1334 jan 2535
1335 russell 2532 2005-01-20 Russell Nelson <[email protected]>
1336    
1337     * Resources/Projections/defaults.proj: Ruin the speling of the
1338 russell 2533 Lambert-93 projection so it doesn't run into the wx UTF-8 bug.
1339     It's the wrong thing to do in the long run, but it's necessary for
1340     those users until that bug is fixed. Otherwise the projection
1341     dialog segfaults. Better to annoy some Lambert-93 users with a
1342     spelling mistake than every Fedora Core 3 user of Thuban-CVS.
1343 russell 2532
1344 bernhard 2531 2005-01-20 Bernhard Reiter <[email protected]>
1345    
1346 jan 2542 * Thuban/UI/mainwindow.py (MainWindow.view_position_changed): Added
1347     docstring and comment that the warning code here is a hack.
1348 bernhard 2531
1349 russell 2529 2005-01-20 Russell Nelson <[email protected]>
1350    
1351 jan 2542 * Thuban/UI/mainwindow.py (MainWindow.view_position_changed): Warn
1352     user about misprojected layers when their lat/lon bounding
1353 russell 2529 box exceeds rational lat/lon values.
1354    
1355 bernhard 2525 2005-01-20 Bernhard Reiter <[email protected]>
1356    
1357 jan 2542 * Thuban/UI/about.py (unicodeToLocale): Improved:
1358 bernhard 2528 Use 'ascii' and then 'replace' for other characters
1359     when getdefaultlocale returns None. Thanks to Bernhard H. .
1360 jan 2542
1361 bernhard 2528 2005-01-20 Bernhard Reiter <[email protected]>
1362    
1363 jan 2542 * Thuban/UI/classgen.py (GenQuantilesPanel.OnRetrieve): Added a comment
1364 bernhard 2527 that OnRangeText might be called twice and using None as argument.
1365 jan 2542
1366 bernhard 2527 2005-01-20 Bernhard Reiter <[email protected]>
1367    
1368 jan 2542 * Thuban/UI/classgen.py (GenQuantilesPanel.OnRetrieve): Add a
1369     OnRangeText(0) to work around a different in wx Behaviour noticed
1370     on MacOSX, thanks to Lorenzo Moretti and Daniel Calvelo for the fix.
1371    
1372 bernhard 2526 2005-01-20 Bernhard Reiter <[email protected]>
1373    
1374     * Thuban/UI/about.py: take iso-8859-15 when getdefaultlocale returns
1375 bernhard 2525 None. (Fixes rt#2910.)
1376    
1377 frank 2524 2005-01-18 Frank Koormann <[email protected]>
1378    
1379     New Extension: mouseposition
1380     Tool to collect mouse click positions (map coordinates) in a dialog.
1381    
1382     * Extensions/mouseposition/__init__.py: New, extension registration
1383    
1384     * Extensions/mouseposition/mouseposition.py: New, implements the
1385     dialog and adds a tool to Thuban mainwindow.
1386    
1387     * Extensions/mouseposition/position.xpm: New, icon for tool.
1388    
1389 jan 2522 2005-01-14 Jan-Oliver Wagner <[email protected]>
1390    
1391     * Doc/manual/thuban-manual-de.xml: More translations.
1392    
1393 frank 2520 2005-01-11 Frank Koormann <[email protected]>
1394    
1395     * Thuban/UI/mainwindow.py (MainWindow.DuplicateLayer):
1396     Fix indention bug.
1397    
1398 frank 2517 2005-01-09 Frank Koormann <[email protected]>
1399    
1400     * Thuban/UI/mainwindow.py (MainWindow.DuplicateLayer):
1401 frank 2520 BugFix 2901: Explicitly copy layers ClassificationColumn since it
1402 frank 2517 is not part of the layers Classification.
1403    
1404 frank 2515 2005-01-03 Frank Koormann <[email protected]>
1405    
1406 frank 2517 * Thuban/UI/renderer.py (ScreenRendererdraw_selection_incrementally):
1407     BugFix 2883: Former implementation only worked on classified point
1408     layers: KeyError was raised, now use the default size if field is None.
1409 frank 2515
1410 bernhard 2513 2004-12-27 Bernhard Reiter <[email protected]>
1411    
1412     svgexport 1.0.0cvs: Fixed label export.
1413    
1414     * Extensions/svgexport/test/test_svgmapwriter.py:
1415     class TestSVGRenderer(): New class; new test test_label_font().
1416    
1417     * Extensions/svgexport/svgmapwriter.py
1418     (SVGRenderer.label_font()): initialised Font size with self.factor now,
1419     makes test_label_font happy.
1420    
1421     * Extensions/svgexport/TODO: crossed out fixed label export item.
1422     Added item for options.
1423    
1424     * Extensions/svgexport/__init__.py: Bumped version to 1.0.0cvs.
1425    
1426 russell 2511 2004-12-27 Russell Nelson <[email protected]>
1427    
1428 jan 2512 Middle mouse button pans.
1429 russell 2511
1430 jan 2512 * Thuban/UI/view.py (MapCanvas.__init__): Subscribe also
1431     OnMiddleDown and OnMiddleUp events.
1432     (MapCanvas.OnMiddleDown): New. Activate the pan tool and remember the
1433     previously used tool.
1434     (MapCanvas.OnMiddleUp): New. Reactivate the remebered tool used before
1435     pressing the middle mouse button.
1436    
1437 jan 2509 2004-12-27 Jan-Oliver Wagner <[email protected]>
1438    
1439     * Doc/manual/thuban-manual-de.xml: More translations.
1440    
1441 jan 2506 2004-12-23 Jan-Oliver Wagner <[email protected]>
1442    
1443     * Thuban/UI/projdialog.py (ProjFrame.load_user_proj): Added a
1444     \n to stderr after the warnings. Thanks to Russell Nelson.
1445    
1446 nhueffme 2493 2004-12-20 Nina Hueffmeyer <[email protected]>
1447    
1448     * Extensions/ogr/ogrshapes.py: Fixed some issues from
1449     Bernhard (coding guidelines etc.). Additionally it is now possible to
1450     display shapefiles containing feature collections (e.g.polygons
1451     with holes). Works with gdal 1.2.1 now.
1452    
1453     * Extensions/ogr/test/test_OGRShapestore.py: Fixed some issues
1454     from Bernhard (coding guidelines etc.). If ogr can't be imported,
1455     tests are skipped now.
1456    
1457     * Extensions/ogr/ogrstart.py: Fixed some typings.
1458    
1459 bernhard 2490 2004-12-20 Bernhard Reiter <[email protected]>
1460    
1461     * Extensions/svgexport/TODO: updated to add support for
1462     raster layers and labels for 1.0.1.
1463    
1464     * Extensions/svgexport/svgmapwriter.py (draw_raster_layer):
1465     Issue a warning now.
1466    
1467 bernhard 2488 2004-12-19 Bernhard Reiter <[email protected]>
1468    
1469 bernhard 2489 * Extensions/svgexport/TODO: Added idea to support triggering
1470     the application down the pipe.
1471    
1472     2004-12-19 Bernhard Reiter <[email protected]>
1473    
1474 bernhard 2488 svgexport: Improved code quality, mainly by better naming.
1475    
1476     * Extensions/svgexport/svgmapwriter.py:
1477     DrawPath() renamed to DrawPolygonPath(),
1478     added documentation, improved comments and variable names.
1479    
1480     * Extensions/svgexport/svgmapwriter.py,
1481     Extensions/svgexport/test/test_svgmapwriter.py:
1482     All using DrawPolygonPath() now, the default parameter closed=True
1483     omitted.
1484    
1485     * Extensions/svgexport/test/test_svgmapwriter.py:
1486     renamed test_polygon_opened() to test_polyline()
1487     renamed test_transparent_polygon() to test_transparent_polyline()
1488    
1489 jan 2487 2004-12-18 Jan-Oliver Wagner <[email protected]>
1490    
1491     Some fixes of gns2shp extension.
1492    
1493     * Extensions/gns2shp/test/__init__.py: New. Make this directory a
1494     package.
1495    
1496     * Extensions/gns2shp/test/test_gns2shp.py: Add some import paths
1497     dynamically.
1498    
1499     * Extensions/gns2shp/test/README: Simplified description how to test.
1500    
1501     * Extensions/gns2shp/gns2shp.py (gns2shp): Fixed doc-string,
1502     fixed some dimensions of fields according to the GNS documentation
1503     which seems to change undocumented.
1504     Now killing trailing \n and/or \r from MODIFY_DATE.
1505     This fixes RT#2453.
1506    
1507 bernhard 2479 2004-12-18 Bernhard Reiter <[email protected]>
1508 bernhard 2480
1509 bernhard 2482 svgexport 1.0.0: Treats holes and islands nicely. Documentation added.
1510    
1511     * Extensions/svgexport/test/test_svgmapwriter.py:
1512     Added new tests: test_export_polygon_with_hole()
1513     and test_polygon_with_hole().
1514    
1515     * Extensions/svgexport/svgmapwriter.py
1516     (draw_polygon_shape()): Uses DrawPath correctly now.
1517    
1518     * Doc/manual/thuban-manual.xml: Added documentation for stable
1519     extention svgexport.
1520     * Doc/manual/thuban-manual-de.xml: Copied English section about
1521     svexport over.
1522    
1523 jan 2509 * Extensions/svgexport/__init__.py: Bumped version number to 1.0.0.
1524 bernhard 2482
1525     * Extensions/svgexport/svgsaver.py,maplegend.py:
1526     Moved from experimental to stable extension menu.
1527    
1528     * Extensions/svgexport/TODO: updated.
1529    
1530    
1531     2004-12-18 Bernhard Reiter <[email protected]>
1532    
1533 bernhard 2481 Added Extensions/svgexport/TODO
1534    
1535     2004-12-18 Bernhard Reiter <[email protected]>
1536    
1537 bernhard 2480 Refactored in svgexport:
1538     DrawPath replaces DrawPolygon; added newline in front of "M" in paths.
1539    
1540     * Extensions/svgexport/svgmapwriter.py
1541     Added verbosity level 3 to print out polygon points.
1542     (class Point): added __repr__
1543     (class Brush, __str__()): Added space after ,.
1544     (DrawPolygon): Renamed to DrawPath()
1545     (DrawPath): Takes list of polygons as input now, adds \n before "M"s.
1546     (DrawLines): Using DrawPath now.
1547    
1548     * Extensions/svgexport/test/test_svgmapwriter.py:
1549     Replaced DrawPolygon() calls with DrawPath() and put the first argument
1550     inside another list. Adapted test data with a newline before "M".
1551    
1552     2004-12-18 Bernhard Reiter <[email protected]>
1553 bernhard 2479
1554     Refactored svgexport tests: 9 double tests runs eliminated;
1555     code size reduced by 8 lines.
1556    
1557     * Extensions/svgexport/test/test_svgmapwriter.py:
1558     (class TestWithDC): Renamed to BaseTestWithDC, moved to top.
1559     (class BaseWithDCtools): New, subclass from BaseTestWithDC.
1560     (class TestDrawSplines): now subclass from BaseTestWithDCtools,
1561     this fixed the double running of the nine tests of TestVirtualDC.
1562     (class TestVirtualDC): Using self.dc and self.file from setUp().
1563    
1564 bh 2478 2004-12-17 Bernhard Herzog <[email protected]>
1565    
1566     Two windows specific fixes ported from thuban-1­0-branch:
1567    
1568     * Thuban/UI/about.py (unicodeToLocale): Use getdefaultlocale
1569     instead of getlocale because getlocale doesn't return a usable
1570     encoding name on a german windows 2000
1571    
1572     * setup.py: windows build: Removed the absolute path names and
1573     made all prfixes relative to the directory containing setup.py.
1574     Makes it a little easier to adapt to a different system.
1575    
1576 bh 2470 2004-12-16 Bernhard Herzog <[email protected]>
1577    
1578 bernhard 2479 Add support for PostGIS tables with LINESTRING geometries.
1579 bh 2472 Fixes RT#2299
1580    
1581     * Thuban/Model/postgisdb.py (shapetype_map): Add LINESTRING
1582    
1583     * test/postgissupport.py
1584     (PostgreSQLServer.get_default_static_data_db): Rename the "roads"
1585     table to "roads-multi" because it now uses MULTILINESTRING
1586     geometries and introduce a new "roads" table that uses LINESTRING
1587     (coords_to_multilinestring): Make the doc string more precise
1588     (coords_to_linestring): New. Create a LINESTRING WKT
1589     representatin
1590     (wkt_converter): Add coords_to_linestring
1591     (upload_shapefile): Rephrase the doc-string a bit.
1592    
1593     * test/test_postgis_db.py (TestPostGISShapestoreArc)
1594     (LineStringTests)
1595     (TestPostGISShapestoreLineString)
1596     (TestPostGISShapestoreMultiLineString): Split
1597     TestPostGISShapestoreArc into a base class LineStringTests and two
1598     derived classes TestPostGISShapestoreLineString for LINESTRING
1599     geometries and TestPostGISShapestoreMultiLineString for
1600     MULTILINESTRING geometries. Most test methods are in the base
1601     class with the exception of tests that explicitly check the raw
1602     format.
1603    
1604     2004-12-16 Bernhard Herzog <[email protected]>
1605    
1606 bh 2471 Make the test suite work with PostGIS 0.8.2 and PostgreSQL 7.4
1607    
1608     * test/postgissupport.py (find_postgis_sql): Different postgis
1609     versions put the postgis.sql file into slightly different places
1610     so we have to look in both. The updated doc string describes this
1611     is more detail.
1612    
1613     * test/test_postgis_db.py
1614     (TestPostGISSpecialCases.test_column_name_quoting): The return
1615     value of UniqueValues is unsorted, so it has to be sorted for
1616     comparison.
1617    
1618     2004-12-16 Bernhard Herzog <[email protected]>
1619    
1620 bh 2470 Fix for RT#2237
1621    
1622     * Thuban/UI/projdialog.py (ProjFrame._show_proj_panel): If the
1623     panel to be shown is the UnknownProjPanel disable the OK and Try
1624     buttons. Otherwise enable them.
1625     (ProjFrame.__GetProjection): The UnknownProjPanel returns None for
1626     the parameters. In that case __GetProjection also returns None
1627     now.
1628    
1629 bh 2459 2004-12-15 Bernhard Herzog <[email protected]>
1630    
1631 bh 2462 * Thuban/UI/classgen.py (GenQuantilesPanel.__init__): Set the
1632     minimum number of classes to 2. The calculate_quantiles needs at
1633     least two and raises an exception otherwise.
1634     Fixes RT#2549
1635    
1636     2004-12-15 Bernhard Herzog <[email protected]>
1637    
1638 bh 2460 * test/postgissupport.py (PostgreSQLServer.execute_sql): Extend to
1639     so that it returns a result for select statements.
1640     (PostgreSQLServer.server_version): New. Return the version of the
1641     server software.
1642     (PostgreSQLServer.require_authentication): The format of
1643     pg_hba.conf has changed between PostgrSQL 7.2 and 7.3. Check the
1644     server version and generate the file in the correct format
1645    
1646     2004-12-15 Bernhard Herzog <[email protected]>
1647    
1648 bh 2459 * test/postgissupport.py (PostgreSQLServer.is_running): Fix typo
1649     in the doc string and rephrase it a little.
1650    
1651 frank 2457 2004-12-15 Frank Koormann <[email protected]>
1652    
1653     * test/test_load.py (TestAltPath.checkSession): New, extended checks if
1654     session has been loaded successfully. The check is called by the relevant
1655     tests after executing load_session().
1656    
1657 bh 2450 2004-12-13 Bernhard Herzog <[email protected]>
1658    
1659 bh 2454 Make sure the region used to determine which shapes are visible
1660     actually matches the region on the printed page. If this isn't
1661     done properly some shapes might not be printed.
1662     Fixes RT #2692
1663    
1664     * Thuban/UI/view.py (MapPrintout.draw_on_dc): The region for the
1665     renderer has to be at the same position as the mapregion
1666    
1667     * Thuban/UI/renderer.py (ExportRenderer.RenderMap): self.region
1668     has to be moved by (self.shiftx, self.shifty) too.
1669    
1670     2004-12-13 Bernhard Herzog <[email protected]>
1671    
1672 bh 2452 * libraries/pyprojection/Projection.i: Work around a bug in the
1673     generated python code which leads to exception in the __del__
1674     method when the constructor fails. See the comments in the code
1675     for more details.
1676    
1677     * libraries/pyprojection/Projection.py: Updated from Projection.i
1678     with SWIG.
1679    
1680     2004-12-13 Bernhard Herzog <[email protected]>
1681    
1682 bh 2451 * test/test_load.py (TestAltPath.test_01_single_path_error_fix)
1683     (TestAltPath.test_02_path_error_fix_from_list)
1684     (TestAltPath.test_05_path_error_fix_from_list_changed)
1685     (TestAltPath.test_06_path_error_fix_from_list_fails): self.session
1686     is destroyed in tearDown, so there's no need to do it in a test
1687     case.
1688    
1689     * Thuban/Model/load.py (SessionLoader.open_shapefile): Remove a
1690     debug print
1691    
1692     2004-12-13 Bernhard Herzog <[email protected]>
1693    
1694 bh 2450 * Extensions/svgexport/test/test_svgmapwriter.py
1695     (TestDrawSplines.setUp): Do not use super with the unittest
1696     classes because in Python 2.2 they're still old-style classes.
1697    
1698 frank 2448 2004-12-13 Frank Koormann <[email protected]>
1699    
1700     Alternative Path feature: When loading a (moved) session where
1701     shapefiles cannot be found, ask the user. Use the specified path
1702     if further shapefiles are missing. However, ask the usr for confirmation
1703     in such cases.
1704    
1705     * test/test_load.py (TestAltPath): New, tests for alternative path feature
1706     in load_session()
1707     (Shapefile_CallBack): Helper, implements controllable callback.
1708    
1709     * Thuban/UI/application.py (ThubanApplication.OnInit):
1710     Added "alt_path" to self.path
1711     (ThubanApplication.OpenSession): Added shapefile_callback as second
1712     callback similar to db_connection_callback.
1713     (ThubanApplication.run_alt_path_dialog): New, implementaion of
1714     shapefile_callback. In addition to raising the dialog the control of
1715     self.path('alt_path') is implemented here.
1716    
1717     * Thuban/Model/load.py (SessionLoader.__init__): Added shapefile_callback.
1718     (SessionLoader.open_shapefile): Open shapefile, eventually with
1719     alternative path. This wrapps the "theSession.OpenShapefile(filename)"
1720     formerly used in start_fileshapesource()/start_layer().
1721     (SessionLoader.start_fileshapesource): Call open_shapefile().
1722     (SessionLoader.start_layer): Call open_shapefile().
1723     (load_session): Added shapefile_callback.
1724    
1725     * Thuban/UI/altpathdialog.py: New, implements dialogs for alternative path
1726     feature (search / check).
1727    
1728     * Doc/manual/thuban-manual.xml: Added documentation of new feature.
1729    
1730 bernhard 2443 2004-12-11 Bernhard Reiter <[email protected]>
1731    
1732 bernhard 2445 svgexport 0.9.2: Point size supports for maps.
1733    
1734     * Extensions/svgexport/svgmapwriter.py: Added import of SHAPETYPE_POINT
1735     (def draw_point_shape): new parameter size defaults to 2 as before.
1736     (draw_shape_layer_incrementally): Moved draw_func log line higher.
1737     Added draw_func call with size when dealing with a point layer.
1738    
1739     * Extensions/svgexport/__init__.py: bumped version to 0.9.2.
1740    
1741     2004-12-11 Bernhard Reiter <[email protected]>
1742    
1743 bernhard 2444 Made sure that newlines are inserted in the svg path d attributes
1744     to raise the chance that the line length will be below 255 characters,
1745     as recommended by REC SVG 1.1 in section 8.3.1.
1746    
1747     * Extensions/svgexport/svgmapwriter.py(DrawPolygon):
1748     Adding \n before L's and changed whitespace handling.
1749    
1750     * Extensions/svgexport/test/test_svgmapwriter.py:
1751     Adapted tests to new whitespace handling of DrawPolygon.
1752    
1753     2004-12-11 Bernhard Reiter <[email protected]>
1754    
1755 bernhard 2443 * Doc/technotes/coding_guidelines.txt: easy typo fixed.
1756    
1757     * Extensions/svgexport/test/test_svgmapwriter.py:
1758     Removed test_drawbezier in favour of new test_drawspline3 and
1759     test_drawspline4 within new class TestDrawSplines(TestVirtualDC).
1760     All only to test DrawSpline.
1761    
1762     * Extensions/svgexport/svgmapwriter.py(DrawSpline):
1763     New implementation now really using the strange algorithm of
1764     xfig 3.1's approximated splines and its conversion to postscript
1765     with one twist: SVG can do quadratic beziers, so skipped translation
1766     to cubic beziers.
1767     (TestWithDC): Typo in comment fixed.
1768    
1769 joey 2442 2004-12-09 Martin Schulze <[email protected]>
1770    
1771     * Thuban/Model/classgen.py: Added missing character encoding
1772    
1773     * Extensions/wms/properties.py (OpenWMSProperties): removed
1774    
1775     * Extensions/wms/parser.py (WMSCapabilitiesParser.error): Dropped
1776     support for get_srs_discrepancies() since there are no
1777     discrepancies anymore (was a thinko)
1778    
1779     * Extensions/wms/layer.py (WMSLayer.GetMapImg): Improved graphic
1780     format priority now that more formats are supported globally by
1781     the render engine.
1782    
1783 silke 2437 2004-12-08 Silke Reimer <[email protected]>
1784     * Extensions/ogr/ogrshapes.py: Substituted ogr-method CloseRings
1785     because it is not available in all versions of ogr
1786    
1787 bernhard 2436 2004-12-08 Bernhard Reiter <[email protected]>
1788     * Extensions/ogr/__init__.py: Added empty __init__.py to heal
1789     global tests until a real one is commited.
1790    
1791 nhueffme 2435 2004-12-07 Nina Hüffmeyer <[email protected]>
1792    
1793     * /Extensions/ogr/: Adding a new extension to read shapefiles with
1794     ogr. It is planned to add other vector formats.
1795    
1796     * /test/runtests.py: Adding tests from /Extensions/ogr/test/.
1797    
1798 jan 2434 2004-12-07 Jan-Oliver Wagner <[email protected]>
1799    
1800     * /Extensions/svgexport/test/test_svgmapwriter.py: Reverting
1801     part of a (non-)fix to renable that the tests are always
1802     executed.
1803    
1804 bernhard 2432 2004-12-07 Bernhard Reiter <[email protected]>
1805    
1806     * Extensions/svgexport/test/test_svgmapwriter.py:
1807     Added test_drawbezier() to test DrawSpline().
1808    
1809     * Extensions/svgexport/svgmapwriter.py(DrawSpline):
1810     Really implemented bezier drawing.
1811    
1812     * Extensions/svgexport/__init__.py: Bumped version of svgexport
1813     to 0.9.1 because now the legend examples lines styles
1814     will be drawing with beziers.
1815    
1816 joey 2431 2004-12-05 Martin Schulze <[email protected]>
1817    
1818     * Thuban/UI/renderer.py (raster_format_map): Added PNG, TIFF and
1819     GIF as supported bitmap image formats (helpful for the WMS extension)
1820    
1821 joey 2430 2004-11-30 Martin Schulze <[email protected]>
1822    
1823     * Extensions/wms/test/test_ogclib.py (TestOGCLib.test_compareURLs):
1824     Improved the test for the internal compare method
1825    
1826 jan 2429 2004-11-27 Jan-Oliver Wagner <[email protected]>
1827    
1828     * Thuban/UI/about.py (About.__init__): Added
1829     Norbert Solymosi for hungarian translation and Ole Rahn
1830 bernhard 2722 as contributor. Moved Bernhard Reiter from Contributor
1831 jan 2429 to Developer.
1832    
1833 bernhard 2425 2004-11-27 Bernhard Reiter <[email protected]>
1834    
1835     * Extensions/svgexport/test/test_svgmapwriter.py:
1836     Removed Jan from author list as he did not change enough significant
1837     lines yet.
1838    
1839     * Extensions/svgexport/__init__.py: Added Bernhard as author
1840     of the Extension.
1841    
1842 jan 2422 2004-11-27 Jan-Oliver Wagner <[email protected]>
1843    
1844     * po/hu.po: New. Hungarian translation. Contributed
1845     by Norbert Solymosi.
1846    
1847 bh 2419 2004-11-26 Bernhard Herzog <[email protected]>
1848    
1849     * Extensions/svgexport/test/test_svgmapwriter.py
1850     (Testobjectexport.test_transparent_polygon): Commented out some
1851     debug prints
1852    
1853 jan 2418 2004-11-24 Jan-Oliver Wagner <[email protected]>
1854    
1855     Fix broken tests for svg extension and added svg legend
1856     to Experimental menu.
1857    
1858     * Extensions/svgexport/test/test_svgmapwriter.py: Fix to have
1859     the test run correctly even if the extension is a package.
1860     Also removed the "import Thuban" which makes no sense.
1861    
1862     * Extensions/svgexport/__init__.py: Fix to have the extensions'
1863     test module also be executed from the global test routine.
1864     This is done by looking for the absense of the DISPLAY variable.
1865    
1866     * Extensions/svgexport/maplegend.py: Moved the menu entry from Extensions
1867     to Experimental menu since this module has yet not reached a stable
1868     status (ie. 1.0).
1869    
1870 bernhard 2414 2004-11-22 Bernhard Reiter <[email protected]>
1871    
1872     * Extensions/svgexport/svgmapwriter.py:
1873     Added verbose variable and some logging depending on it.
1874     (class VirtualDC(XMLWriter)): Minor improvement in the polygon loop,
1875     because counting i is not necessary.
1876     (class Pen, class Brush): Added simple __str__ methods.
1877     (SVGRenderer.draw_polygone_shape): Fix #2698 (transparent polygons are
1878     not exported to svg file) Note: holes still unhandled.
1879    
1880     * Extensions/svgexport/test/test_svgmapwriter.py:
1881     Made a baseclass TestWithDC for test needed a DC.
1882     Added tests for bug #2698 (transparent polygons are not
1883     exported to svg file):
1884     Testobjectexport.test_transparent_polygon()
1885    
1886     * Thuban/Model/base.py (UnsetModified):
1887     Fixed some typos in docstring.
1888    
1889     * Thuban/UI/baserenderer.py (BaseRenderer.draw_polygon_shape()):
1890     Added hints on the used algorithm for handling holes.
1891    
1892 jan 2403 2004-11-20 Jan-Oliver Wagner <[email protected]>
1893    
1894 jan 2412 Some face lifting for the examples.
1895    
1896     * Examples/__init__.py: Make this directory a package.
1897    
1898     * Examples/simple_extensions/__init__.py: Make this directory a package.
1899    
1900     * Examples/simple_extensions/hello_world.py: Moved entry from Extensions
1901     menu to Examples menu.
1902    
1903     * Examples/simple_extensions/simple_command.py: Some more comments,
1904     minor changes.
1905    
1906     * Examples/simple_extensions/simple_tool.py: Minor changes.
1907    
1908     2004-11-20 Jan-Oliver Wagner <[email protected]>
1909    
1910 jan 2407 Changed way of extension registry for wms and added extension
1911     registry for umn_mapserver extension.
1912    
1913     * Extensions/wms/__init__.py: Added registry entry and the importing
1914     of the actual wms module. Included a test for the required PyOGCLib.
1915    
1916     * Extensions/wms/wms.py: Removed registry entry (moved to __init__.py).
1917    
1918     * Extensions/umn_mapserver/__init__.py: Added registry entry and the
1919     importing of the actual umn mapserver management modules.
1920     Included a test for the required Python MapScript.
1921    
1922     2004-11-20 Jan-Oliver Wagner <[email protected]>
1923    
1924 jan 2403 Changed way of extension registry for importAPR, bboxdump
1925     and added extension registry for svgexport.extension registry for
1926     svgexport.
1927    
1928     * Extensions/importAPR/__init__.py: Added registry entry and the importing
1929     of the actual importAPR module.
1930    
1931     * Extensions/importAPR/importAPR.py: Removed registry entry (moved to
1932     __init__.py).
1933    
1934     * Extensions/bboxdump/__init__.py: Added registry entry and the importing
1935     »···of the actual bboxdump module.
1936    
1937     * Extensions/bboxdump/bboxdump.py: Removed registry entry (moved to
1938     »···__init__.py).
1939    
1940     * Extensions/svgexport/__init__.py: Added registry entry and the importing
1941     of the svgsaver module.
1942    
1943     * Extensions/svgexport/svgsaver.py: Moved the menu entry from Extensions
1944     to Experimental menu since this module has yet not reached a stable
1945     status (ie. 1.0).
1946    
1947 jan 2397 2004-11-18 Jan-Oliver Wagner <[email protected]>
1948    
1949     Now the hit test considers the size of point symbols.
1950    
1951     * Thuban/UI/viewport.py (ViewPort._hit_point): Added optional parameter
1952     'size' defaulting to the previously fixed value 5.
1953     Extended doc-string.
1954     (Viewport._find_shape_in_layer): Resolved FIXME regarding flexibility
1955     for symbols.
1956     Now the size of the largest point symbol is determined to find out
1957     about whether the point has been hit.
1958     This fixes the problem that only clicks inside a fixed distance of
1959     5 where found.
1960    
1961 jan 2395 2004-11-17 Jan-Oliver Wagner <[email protected]>
1962    
1963 jan 2397 Another open issue fixed regarding sizeable symbols: correct rendering of
1964 jan 2395 selected symbols.
1965    
1966     * Thuban/UI/renderer.py (ScreenRenderer.draw_selection_incrementally):
1967     Added consideration of the specific size of point symbols.
1968     The property for each point symbol is retrieved and the size applied
1969     for the rendering method.
1970     Added doc-string.
1971    
1972 jan 2393 2004-11-16 Jan-Oliver Wagner <[email protected]>
1973    
1974     Changed way of Extension Registry for gns2shp and profiling.
1975    
1976     * Extensions/gns2shp/gns2shp.py: Removed registry entry (moved to
1977     __init__.py).
1978    
1979     * Extensions/gns2shp/__init__.py: Added registry entry and the importing
1980     of the actual gns2shp module.
1981    
1982     * Extensions/profiling/profiling.py: Removed registry entry (moved to
1983     __init__.py).
1984    
1985     * Extensions/profiling/__init__.py: Added registry entry and the importing
1986     of the actual profiling module.
1987    
1988 bernhard 2388 2004-10-28 Bernhard Reiter <[email protected]>
1989    
1990     * Extensions/svgexport/: Minor improvements to doc strings.
1991    
1992 jan 2387 2004-10-07 Jan-Oliver Wagner <[email protected]>
1993    
1994     Further elements for sizable point objects now
1995     making this feature usable though not yet complete.
1996    
1997     * Thuban/Model/save.py (SessionSaver.write_classification): Write
1998     attribute 'size' for cldata when the shape layer is of point type.
1999     This also now make the test_load.py tests happy.
2000    
2001     * Thuban/Model/classgen.py (CustomRamp.GetProperties): Added size
2002     gradient.
2003    
2004     * Thuban/UI/classifier.py (ID_SELPROP_SPINCTRL): Renamed to
2005     ID_SELPROP_SPINCTRL_LINEWIDTH.
2006     (ID_SELPROP_SPINCTRL_LINEWIDTH): New Id replaces ID_SELPROP_SPINCTRL.
2007     (ID_SELPROP_SPINCTRL_SIZE): New Id.
2008     (SelectPropertiesDialog.__init__): Added a second spin control
2009     for the size in case the corresponding layer is of point type.
2010     (SelectPropertiesDialog._OnSpin): Renamed to _OnSpinLineWidth.
2011     (SelectPropertiesDialog._OnSpinLineWidth): New. Former _OnSpin.
2012     (SelectPropertiesDialog._OnSpinSize): New. Set size of property
2013     and refresh preview.
2014    
2015    
2016    
2017 joey 2381 2004-10-04 Martin Schulze <[email protected]>
2018    
2019     * Extensions/wms/test/test_parser.py
2020     (TestWMSCapabilitiesParser.test_compareLists): Added missing
2021     self-test for compareLists()
2022     (TestWMSCapabilitiesParser.test_compareDicts): Added missing
2023     self-test for compareDicts()
2024 joey 2382 (TestWMSCapabilitiesParser.test_compareLists): Adding more tests
2025     to verify the test routine fails with non-equal arguments
2026     (TestWMSCapabilitiesParser.test_compareDicts): Adding more tests
2027     to verify the test routine fails with non-equal arguments
2028 joey 2381
2029 jan 2370 2004-10-03 Jan-Oliver Wagner <[email protected]>
2030    
2031 jan 2380 First elements for sizeable point objects.
2032    
2033     * Resources/XML/thuban-1.1.dtd: Added size attribute to cldata.
2034    
2035     * Data/iceland_sample_size.thuban: New. Sample for sized point objects.
2036    
2037     * test/test_load.py (ClassificationTest.TestLayers): Added SetSize in case
2038     of a corresponding argument is given.
2039     (TestSymbolSize): New. Test the size attribute of cldata.
2040    
2041     * Thuban/Model/classification.py: Removed some trailing whitespaces.
2042     (ClassGroupProperties.__init__): Set default size.
2043     (ClassGroupProperties.SetProperties): Set the size.
2044     (ClassGroupProperties.GetSize): New. Return the size.
2045     (ClassGroupProperties.SetSize): New. Set the size.
2046     (ClassGroupProperties__eq__): Compare also size.
2047     (ClassGroupProperties__repr__): Print also size.
2048    
2049     * Thuban/Model/load.py (SessionLoader.start_cldata): Also parse
2050     the size attribute.
2051    
2052     * Thuban/UI/classifier.py (ClassDataPreviewer.Draw): Added doc-string.
2053     Also, now there is a return value that indicates whether the drawing
2054     size exceeded the given rect extent and if so the new extent.
2055     Finally, point objects are drawn depending on the size. If either
2056     the width or height is exceeded, the new extent is returned.
2057     (ClassRenderer.Draw): Now when calling the previewer drawing function,
2058     evaluate the return value and, if not None, adapt the grid widget size
2059     accordingly and redraw again.
2060    
2061     * Thuban/UI/baserenderer.py (BaseRenderer.draw_shape_layer_incrementally):
2062     If the draw function is for points, call it with the size as additional
2063     parameter.
2064     (BaseRenderer.draw_point_shape): Added additional, optional parameter for
2065     the size. Compute the radius using the size.
2066    
2067     * Extensions/importAPR/apr.py (APR_BMkSym.GetThubanProp): Now
2068     that Thuban supports size, apply this correctly.
2069    
2070     * Extensions/importAPR/importAPR.py: Bumped version to 0.1.1.
2071    
2072     2004-10-03 Jan-Oliver Wagner <[email protected]>
2073    
2074 jan 2370 * Doc/manual/thuban-manual-de.xml: Started translation of
2075     Map chapter.
2076    
2077 joey 2368 2004-10-01 Martin Schulze <[email protected]>
2078    
2079     * Extensions/wms/properties.py (wmsProperties.__init__): Extended
2080     argument for general use through properties-dialog selector
2081    
2082     * Thuban/UI/classifier.py: Register properties dialog classes for
2083     both provided layer classes/types.
2084    
2085     * Thuban/UI/mainwindow.py (MainWindow.OpenLayerProperties): The
2086     map can be retrieved through the parent which is passed to the
2087     constructor anyway and doesn't require an argument of its own,
2088     required for the unification of arguments for general use through
2089     properties-dialog selector.
2090     (MainWindow.OpenOrRaiseDialog): Move the logic for checking
2091     whether a dialog is already opened (and raising it to the users
2092     attention) and creating a new dialog into a function of its own
2093     (MainWindow.OpenLayerProperties): Use the new OpenOrRaiseDialog()
2094     method
2095     (MainWindow.OpenLayerProperties): Utilise the new ClassMapper for
2096     global registration of properties dialog classes (which are indeed
2097     layer-specific).
2098    
2099     * Thuban/UI/classifier.py (Classifier.__init__): Unify arguments
2100     for general use through properties-dialog selector, the map can be
2101     retrieved through the parent and doesn't require an argument of
2102     its own.
2103    
2104     * Extensions/wms/wms.py: Register the properties dialog class for
2105     the provided WMS layer
2106    
2107 jan 2358 2004-09-28 Jan-Oliver Wagner <[email protected]>
2108    
2109     New feature: Registry for Extensions.
2110    
2111     * Thuban/UI/extensionregistry.py: This module defines a registry for
2112     Extensions.
2113    
2114     * Thuban/UI/about.py (About.__init__): Added description
2115     of the registered extensions with all of the information.
2116    
2117     * Thuban/Model/extension.py (Extension): Improved doc-string.
2118    
2119     * Extensions/gns2shp/gns2shp.py, Extensions/importAPR/importAPR.py,
2120     Extensions/bboxdump/bboxdump.py, Extensions/profiling/profiling.py,
2121     Extensions/wms/wms.py: Added registration of the extension.
2122    
2123 bernhard 2352 2004-09-27 Bernhard Reiter <[email protected]>
2124    
2125     More fixes to svgexport to make used ids unique and
2126     conforming to XML's Name production.
2127    
2128     * Extensions/svgexport/test/test_svgmapwriter.py: Added new tests
2129     test_xml_id_constraints(), test_make_ide_nosetbaseid() and
2130     test_make_id_nonintegersetid(). Switched SetID and SetBaseID.
2131     Added Bernhard R. as author.
2132     * Extensions/svgexport/svgmapwriter.py (make_id): Using "_" as
2133     concatenation char now (makes test_make_ide_nosetbaseid() valid).
2134     Also transform second id part with "%d" and catch the TypeError
2135     to raise SVGMapWriterError (making test_make_id_nonintegersetid() ok).
2136     Corrected typo inBernhard's author line.
2137     (SetBaseID): Return the transformed base id. Transform characters
2138     which are not alnum() or in ".-_" to binascii.b2a_hex(). Added
2139     import binascii. If to be set string starts with "xml" or so, add "t".
2140     (draw_shape_layer_incrementally): use the returned value of SetBaseID
2141     for used_baseids checks.
2142    
2143 bh 2351 2004-09-25 Bernhard Herzog <[email protected]>
2144    
2145     * test/test_layer.py (TestLayer.test_arc_layer_with_projection):
2146     Remove a debug print and some tab characters.
2147    
2148 bernhard 2350 2004-09-25 Bernhard Reiter <[email protected]>
2149    
2150     * Extensions/svgexport/svgmapwriter.py: Added Bernhard R. as Author.
2151     (SetBaseID, SetID, make_id): Improved docstring comments to explain
2152     the interaction of the three functions and the XML id contrains.
2153    
2154 bernhard 2352
2155 jan 2346 2004-09-23 Jan-Oliver Wagner <[email protected]>
2156    
2157 jan 2349 * Doc/ThubanModel.xmi: New. UML file for Thuban Model
2158     Module.
2159    
2160     * Doc/README: Added info on ThubanModel.xmi.
2161    
2162     2004-09-23 Jan-Oliver Wagner <[email protected]>
2163    
2164 jan 2346 * Doc/README: New. Some info about how to generate technical
2165     documentation from the source code.
2166     This text was send to the Thuban developer mailing list on
2167     September 21st 2004 by Bernhard Reiter.
2168    
2169 bernhard 2344 2004-09-21 Bernhard Reiter <[email protected]>
2170    
2171     Improved the svgexport to only use unique ids. Will issues
2172     an error message dialoge when two layer names are the same.
2173     ShapeIDs are now added with a dash within the svg ids.
2174    
2175     * Extensions/svgexport/svgmapwriter.py (SVGMapWriterError): New.
2176     * Extensions/svgexport/test/test_svgmapwriter.py: Added imports
2177     (TestSVGRenderer): New test class with test_make_in() and
2178     test_check_for_layer_name_clash()
2179     * Extensions/svgexport/svgmapwriter.py (SVGRenderer): Fixed __init__()
2180     and draw_shape_layer_incrementally() to not use a baseid twice,
2181     satisfying test_check_for_layer_name_clash()
2182     (VirtualDC.make_id): Use a dash between baseit and id, satisfies
2183     test_make_in().
2184     * Extensions/svexport/svgsaver.py: Import SVGMapWriterError, wxOK
2185     and wxICON_HAND.
2186     (write_to_svg): Put dc and rendering in a try statement and on
2187     catching SVGmapWriterError notify the user and delete the target file.
2188    
2189 bernhard 2343 2004-09-20 Bernhard Reiter <[email protected]>
2190    
2191     * Model/base.by, Model/layer.py: Fixed typos in docstrings.
2192    
2193 jschuengel 2342 2004-09-03 Jan Schüngel <[email protected]>
2194    
2195     * Extensions/umn_mapserver/mapfile(MF_Class.add_thubanstyle): Fix a
2196     small bug with the line color. Now the line color will now only set
2197     if it is set in Thuban an not Transparent.
2198    
2199     * Extensions/umn_mapserver/mf_export(tblayer_to_map): Fixed a bug with
2200     deleting the layers from mapfile. Now all layers will delete backwards
2201     from the last.
2202    
2203 silke 2339 2004-08-20 Silke Reimer <[email protected]>
2204 silke 2338
2205 silke 2339 * Thuban/Model/layer.py:
2206     Fixes bug in projection handling: Otherwise very large region might not
2207     have valid values in the layer's projection.
2208    
2209     2004-08-20 Silke Reimer <[email protected]>
2210    
2211 silke 2338 * Thuban/UI/about.py:
2212     small changes to be consistent with coding style.
2213    
2214 joey 2337 2004-08-13 Martin Schulze <[email protected]>
2215    
2216     * Extensions/wms/test/test_ogclib.py (TestOGCLib.compare_URLs):
2217     Adjusted a comment
2218    
2219 silke 2335 2004-08-11 Silke Reimer <[email protected]>
2220 silke 2334
2221 silke 2335 * Thuban/UI/about.py: Small changes to encoding related stuff to avoid
2222     too many and too enhanced imports of locale
2223    
2224 silke 2334 2004-08-10 Silke Reimer <[email protected]>
2225    
2226     * Thuban/UI/about.py: Fixed encoding problem of about dialog: Added
2227 silke 2339 function unicodeToLocale() to convert special characters to users
2228     locale encoding
2229 silke 2334
2230 jan 2333 2004-08-10 Jan-Oliver Wagner <[email protected]>
2231    
2232     * Doc/technotes/coding_guidelines.txt: Added rule 'Method names start with
2233     lower case letter'
2234    
2235 jschuengel 2331 2004-08-09 Jan Schüngel <[email protected]>
2236    
2237     * ChangeLog: Rewrite the last ChangeLog entry to follow
2238     the standard way.
2239    
2240     * Extensions/umn_mapserver/mapfile: Moved the import AnnotationLayer to
2241     the function where it is needed, because it don't works if it stands
2242     at the beginning.
2243     (MF_Layer.__init__): Removed the extra numclassed variable. Now
2244     numclasses from the mapscript will be used.
2245     (MF_Layer.get_index): New. Return the index of the layer in mapfile.
2246     (MF_Layer.set_classes): New. A Classlist will be set to the layer.
2247     (MF_Layer.set_metadata): New. A Metadata mapscript object will set.
2248     (MF_Layer.remove_allclasses): New. All class of the layer will remove.
2249     (MF_Map.create_new_layer): New. A new Layer is created and associated
2250     with the mapscript object.
2251     (MF_Map.set_layerorder): New. The Layer order like in thuban is set in
2252     the mapscript.
2253     (MF_Map.add_thubanlayer): Now a new layerobj is created if no one is
2254     linked to the layer in thuban, else the layerobject linked to the
2255     thubanlayer will be used.
2256     AnnotationLayer will now store the filename of the shapefile.
2257     (MF_Map.remove_layer): If a layer is removed the associated object
2258     must be set new.
2259    
2260     * Extensions/umn_mapserver/mf_export.py(tb_layer_to_map): Add all
2261     layers which are exists in thuban to the mapobj. All removed Layers
2262     will be removed from the mapobj.
2263     Added comments to all functions.
2264     (thuban_to_map): No layer will be removed here.
2265    
2266     * Extensions/umn_mapserver/mf_handle.py
2267     (_has_umn_mapobj_and_selectedlayer): Activating the layer menu. Now
2268     Layersettings for the mapserver kann be edited.
2269    
2270     * Extensions/umn_mapserver/mf_import.py: Now all layers which are
2271     imported, will be linked with the associated MF_Layer.
2272     (import_mapfile): All layers, which are not selected, will be removed.
2273     Disable the "import layer from mapfile" menu option.
2274    
2275     * Extensions/umn_mapserver/sample/iceland.map: Set the status of the
2276     Annotation Layer from DEFAULT to OFF. The DEFAULT setting turns the
2277     layer on permanently.
2278    
2279 jschuengel 2323 2004-08-03 Jan Schüngel <[email protected]>
2280    
2281 jschuengel 2331 * Extensions/umn_mapserver/mapfile.py(MF_Metadata.remove_allmetadata):
2282     New. This function removes all metadata
2283     (MF_Layer.set_group): New. Set the group setting.
2284     (MF_Layer.get_group): New. Get the group setting.
2285     (MF_Map): Removed the extra numlayers variable, used the mapscript
2286     parameter instead.
2287     (MF_Map.get_numlayers): New. This get numlayers.
2288     (MF_Map.remove_all_layers): New. Removes all layers from the mapobj.
2289 jschuengel 2323 (MF_Map.add_thubanlayer): Replaced the exception handling by a check
2290     if the object is an instance. Also added the annotation layer here to
2291     export, but only the layer is created in the mapfile.
2292    
2293 jschuengel 2331 * Extensions/umn_mapserver/mf_export.py(export_mapfile): Removed
2294     the check if a mapobj exist, because its not needed anymore. The
2295     export function is only available if a mapobj exist.
2296     Use the new function to remove all layers.
2297 jschuengel 2323
2298 jschuengel 2331 * Extensions/umn_mapserver/mf_handle.py(Layer_Dialog): Added a group
2299     option and the metadata button. The layer dialog is temporary disabled.
2300     (Metadata_CustomDataTable): Added some functions to show the grid
2301 jschuengel 2323 correct.
2302    
2303 jschuengel 2331 * Extensions/umn_mapserver/mf_import.py: Moved the code for showing
2304     the number of layer from import_mapfile to this function.
2305     (AnnotationLayer): New. This Class shows the Annotation layer in
2306     thuban. The layer don't do anything. It's only to show the layer
2307     and to save the layer order.
2308     (add_annotationlayer): New. Import an annotation layer to thuban.
2309     (select_layer2import): New. Import only layers to thuban and not
2310     the other settings like projection or scalebar.
2311     (create_new_mapfile): Moved the _has_umn_mapobj function and the
2312     create_new_mapfile functions from mf_handle.py to mf_import.py.
2313 jschuengel 2323
2314     * Extensions/umn_mapserver/sample/iceland.map: Added the group
2315     parameter to the roads and cultural layers. Also added a new
2316     Annotation Layer for the cultural points.
2317    
2318     * Extensions/umn_mapserver/sample/iceland.html: Added the select
2319     option for the annotation layer.
2320    
2321     * Extensions/umn_mapserver/sample/index.html: Added the start
2322     parameter for the annotation layer.
2323    
2324 jan 2315 2004-08-01 Jan-Oliver Wagner <[email protected]>
2325    
2326     * Doc/manual/thuban-manual-de.xml (Chapter Session Management):
2327     translation completed.
2328    
2329     * Doc/manual/thuban-manual.xml (Chapter Session Management):
2330     Fixed unprecise description for Save Session.
2331    
2332 jan 2312 2004-07-31 Jan-Oliver Wagner <[email protected]>
2333    
2334     Started translation of Users Manual into german.
2335    
2336     * Doc/manual/thuban-manual-de.xml: New. German Users Manual.
2337    
2338     * Doc/manual/Makefile: Added build instructions for german
2339     users manual.
2340    
2341     * Doc/manual/thuban-manual.xml: Minor corrections in Introduction.
2342    
2343 jschuengel 2308 2004-07-28 Jan Schüngel <[email protected]>
2344    
2345     * Extensions/umn_mapserver/mapfile.py(MF_Metadata): Changed all class
2346     functions. Now all metadata will handle by the function and its not
2347     needed to initialize it from outside. Therefor the associated mapobj
2348     will be stored in the Metadata Object. So we can use the special
2349     functions from the associated mapobj to get the Metadata.
2350     Therefor all initialization code for the metadata is removed from the
2351     other classes.
2352     (MF_Layer): Added a function to get the metadata object.
2353     (MF_Map): Added a function to set the mappath, the path where
2354     the mapfile ist stored.
2355    
2356     * Extensions/umn_mapserver/mf_export.py(thuban_to_map): Changed the code
2357     to set the extent in the mapfile. Now the code is set by the displayed
2358     data in the Thuban-view.
2359     (export_mapfile): The shapepath is now set empty, until relative
2360     pathnames are supported.
2361    
2362     * Extension/umn_mapserver/mf_handle.py: Added a dialog to handle
2363     metadata. Yet only mapfile metadata are supported. Layer and class
2364     supported are not implemented.
2365     Added a dialog to handle layer informations. The dialog only shows the
2366     selected layer at the moment.
2367    
2368     * Extensions/umn_mapserver/mf_import.py(import_mapfile): Changed the
2369     code for setting the extent in thuban. Now the extent is set to the
2370     given extent from the mapfile.
2371     Fixed a logical mistake. Now the extent is set when realy a layer is
2372     loaded, and not if one is selected to load.
2373    
2374     * Extensions/umn_mapserver/sample/iceland.html: Added code to zoom and
2375     move the shown map in the browser.
2376    
2377     * Extensions/umn_mapserver/sample/iceland.map: Added a new metadata
2378     line to the mapobj and added metadata to the political layer.
2379    
2380     * Extensions/umn_mapserver/test/test_mapserver.py: Changed the test
2381     for Metadata.
2382    
2383 joey 2300 2004-07-26 Martin Schulze <[email protected]>
2384    
2385     * Thuban/Lib/classmapper.py (ClassMapper.has): Added the new
2386     ClassMapper
2387    
2388     * test/test_classmapper.py (TestMapping.test_mapper): Added a Test
2389     case for the new ClassMapper
2390    
2391    
2392 bh 2296 2004-07-22 Bernhard Herzog <[email protected]>
2393    
2394 bh 2297 * Thuban/UI/viewport.py (ViewPort.VisibleExtent): New. Return the
2395     visible extent of the map in projected coordinates
2396    
2397     * test/test_viewport.py (SimpleViewPortTest.test_default_size)
2398     (SimpleViewPortTest.test_init_with_size): Add some VisibleExtent()
2399     tests.
2400     (SimpleViewPortTest.test_visible_extent): New. The real test for
2401     VisibleExtent()
2402    
2403     2004-07-22 Bernhard Herzog <[email protected]>
2404    
2405 bh 2296 * test/test_viewport.py: Use support.run_tests as the main
2406     function when running asa script.
2407    
2408 jschuengel 2295 2004-07-22 Jan Schüngel <[email protected]>
2409    
2410     * Extensions/umn_mapserver/mf_export.py: Added "import os"
2411     Removed the old "import Thuban.UI.mainwindow" code.
2412     (tbextent_to_map): Removed the extra function and at the code direct
2413     to "thuban_to_map" function.
2414     (write_creatorcomment): Added. Now a short comment is added to the
2415     beginning of an generated mapfile.
2416     (export_mapfile): Now the Path and filename are saved in to variables,
2417     and not together in one variable. This is needed for the new
2418     write_creatorcomment function.
2419    
2420     * Extensions/umn_mapserver/mf_import.py (import_mapfile): Added the
2421     import module "re". Also added Range and the ClassGroupRange import
2422     from Thuban. Both are needed for the new range expression import.
2423     (create_rangeexpression): Added. Creates a Range Expression in Thuban
2424     style from a given mapfile expression.
2425     (added_rasterlayer): Make some small code changes. The shapepath is
2426     now stored in an extra variable and the clazz_name is set empty if no
2427     class name set in the mapfile.
2428     Changed the Error message for Range Expressions, becaus the new
2429     function create a error string which will be shown in the dialog.
2430    
2431     * Extensions/umn_mapserver/test/test_mapserver.py: Added a test for the
2432     range expression import.
2433 jan 2312
2434 jan 2291 2004-07-21 Jan-Oliver Wagner <[email protected]>
2435    
2436     * Extensions/umn_mapserver/README: Added hint that
2437     installation as root can be avoided. Removed all tabs.
2438    
2439 bh 2289 2004-07-16 Bernhard Herzog <[email protected]>
2440    
2441     * test/test_viewport.py
2442     (ViewPortTest.test_changing_map_projection): Check that changing
2443     the projection of an empty map shown in a viewport doesn't lead to
2444     exceptions in the viewport's handler for the
2445     MAP_PROJECTION_CHANGED messages
2446    
2447     * Thuban/UI/viewport.py (ViewPort.map_projection_changed): Only
2448     try to keep the same region visible when the map actually contains
2449     something
2450    
2451 jschuengel 2288 2004-07-15 Jan Schüngel <[email protected]>
2452    
2453     * Extensions/umn_mapserver/mapfile.py: Added a function to get the
2454     mappath directly from the mapobj. Is needed because of the changes
2455     in mf_import.py.
2456     (MF_Layer.add_thubanclass): Added a new comment.
2457     (MF_Map.set_extent): Fixed a bug with exporting empty mapobj. If the
2458     mapobj is empty there is no extent get from thuban an so no one can
2459     set to th mapobj.
2460    
2461     * Extensions/umn_mapserver/mf_import.py (import_mapfile): Updated
2462     the discription.
2463     Split the funktion in to three smaller ones. The new functions are
2464     add_rasterlayer, add_polygonlayer and select_layer2import.
2465     Removed the mapfilepath and filepath initialisation, because its know
2466     include in the new functions.
2467     Now nothing will be imported if cancel is pressed in the
2468     layer choice dialog.
2469    
2470 jschuengel 2285 2004-07-14 Jan Schüngel <[email protected]>
2471    
2472     * Extensions/umn_mapserver/mapfile.py: Added ClassGroupDefault to
2473     import.
2474     (MF_Symbolset): Removed the extra variable for numsymbols.
2475     (MF_Class.__init__): Added a comment to the exception clause.
2476     Removed the extent init, because it was not needed anymore.
2477     (MF_Layer.add_thubanclass): Added the code to set the class name to
2478     the expression value from thuban if no label is defined.
2479     Added the code to export Range expressions from thuban to the mapfile.
2480     (MF_Map.set_extent): Removed the exception and replace it by some if
2481     code. If the size of a map is not defined the size will be set to 1,1.
2482     This is necessary because if the extent is set, mapscript checks if
2483     the size is greater than zero.
2484     (MF_Web): Added the get and set function for the template.
2485    
2486     * Extensions/umn_mapserver/mf_export.py: Added the function to check
2487     if a mapobject exists and used it to set the status of the menu items.
2488     If no mapfile exists the settings could not be edditied.
2489     Define after which menuitem the exportitem will include.
2490    
2491     * Extensions/umn_mapserver/mf_handle.py: Removed the import
2492     Thuban.UI.mainwindow clause, because it is not needed.
2493     Added the command Refresh() to all "OnChangeColor()" functions,
2494     because the color preview window was not updated on a color change.
2495     Added the function to check if a mapobject exists and used it to set the
2496     status of the menu items. If no mapobject exists the settings could not
2497     be edditied.
2498     (Map_Dialog): Moved the imagetype selector from the
2499     Outputformat_Dialog to Map_Dialog and removed Outputformat_Dialog.
2500     (Web_Dialog): Removed the name label and added the template textbox.
2501    
2502     * Extensions/umn_mapserver/mf_import.py (import_mapfile): Replace
2503     the exception handling on loading the layers by an if statement. It
2504     is not necessary to us the exception there.
2505     The Filepath creation now use os.path.join to build the path.
2506    
2507     * Extensions/umn_mapserver/test/test_mapserver.py: Moved the testMap
2508     definition from global to the setUp function. Now the testMap will
2509     initialize new on each test.
2510    
2511     * Extensions/umn_mapserver/sample/iceland.map: Include three new
2512     classes in the Line Layer, to test logical Expressions.
2513     Set the status of the class "Point9" in the Point Layer to off
2514    
2515 bh 2278 2004-07-13 Bernhard Herzog <[email protected]>
2516    
2517     * Thuban/UI/baserenderer.py
2518     (BaseRenderer.render_map_incrementally): Fix a logic bug in the
2519     optimization that tries not to draw layers under a raster layer.
2520     The bug was harmless. All it effectively did was to produce The a
2521     strange messages about not being able to draw Layer instances for
2522     all vector layers below a raster layer which would be invisible
2523     anyway because the raster layer currently always covers the entire
2524     window
2525    
2526 jschuengel 2277 2004-07-08 Jan Schüngel <[email protected]>
2527    
2528     * Extensions/umn_mapserver/mapfile.py: Added code to generade and get
2529     a list of supported outputformats. This formats are not alle supported
2530     because there is no possibility to get the outputformat without the
2531     name known. Make some formal changes to the code.
2532     (MF_Map.set_name()): Fixed a bug if the name is None.
2533    
2534     * Extensions/umn_mapserver/mf_handle.py: Removed the image_type import
2535     statement, because its not needed anymore. The Outputformat is now
2536     given as string from the object. Make some formal changes to the code.
2537    
2538     * Extensions/umn_mapserver/test/test_mapserver.py: Added new test for
2539     most of the new setting which were added during the last changes.
2540     Removed the MF_Size Test.
2541    
2542     * Extensions/umn_mapserver/test/test.map: Added a new class to the
2543     cultural Layer to test expressions and the the status of that layer
2544     from on to default.
2545     Changed the data path the the correct Thuban Data
2546     Added the Outputformat Object and Symbol Object
2547    
2548 jschuengel 2272 2004-07-07 Jan Schüngel <[email protected]>
2549    
2550     * Extensions/umn_mapserver/mapfile.py: Added some new
2551     settings to edit (outputformat, label, imagetype)
2552    
2553     * Extensions/umn_mapserver/mf_handle.py: Added some setting to
2554     the Label Dialog and add the OutputDialog.
2555     Make some changes to the code order.
2556    
2557 jschuengel 2269 2004-07-06 Jan Schüngel <[email protected]>
2558    
2559     * Extensions/umn_mapserver/mapfile.py: Added the symbolObj, pointObj
2560     and line Obj and add the scalebar_status_type, scalebar_style_type and
2561     scalebar_position_type.
2562     Added the symbol- and symbolsetObject (MF_Symbol,MF_Symbolset). The
2563     are only used to create a Symbol like the circle in Thuban.
2564     Added the scalebarObject (MF_Scalebar)
2565     (MF_Class): Added set_status and get_status.
2566     (MF_Layer.add_thubanclass): Added code to set the class status
2567     (MF_Map): Added code to handle the symbols and scalebar
2568     (MF_Label): Added the set_partials and get_partials functions
2569    
2570     * Extensions/umn_mapserver/mf_export.py: Added MF_Symbol to import
2571     from mapfile. Added a function to create a circle object like the one
2572     from thuban if no one exists.
2573    
2574     * Extensions/umn_mapserver/mf_handle.py: All colors are now set when
2575     press ok in the assosiated dialog and not at the end of the
2576     colordialog.
2577     Added the Dialog for the Scalebar.
2578     (Label_Dialog): Added the offset option
2579    
2580     * Extensions/umn_mapserver/mf_import.py: Added code to import the
2581     status of the Classes.
2582     Fixed a bug with the projection. Now the to_meter parameter will be
2583     added to the Projection only if it doesn't exists.
2584    
2585 jschuengel 2264 2004-07-01 Jan Schüngel <[email protected]>
2586    
2587     Added the functionality to handle the content thuban is not
2588     able to handle directly.
2589    
2590     * Extensions/umn_mapserver/mf_handle.py: New. This module extents
2591     Thuban with the possibility to edit the mapfile content.
2592    
2593     * Extensions/umn_mapserver/mf_import.py: Added the possibility
2594     to import mapfiles without any layer selected. So it is possible
2595     to edit the other settings in a mapfile.
2596     (import_mapfile): Added code to use the editing functions.
2597     Added the possibility to import the projection to a layer if one
2598     is defined.
2599     Status settings (On,Off) will now set in thuban (visible, invisible).
2600     fixed a bug with with classnames. If no classname is set in mapfile
2601     the value in Thuban will set to the expression.
2602    
2603     * Extensions/umn_mapserver/mf_export.py(export_mapfile): Added the
2604     possibility to save a new mapfile or use the old one which is
2605     imported or new created.
2606     Added code to use the editing functions.
2607     Remove some not needed import statements
2608    
2609     * Extensions/umn_mapserver/mapfile.py: Added new types which are
2610     need for the editing functions.
2611     Added needed set-functions for the editing functions.
2612     Added the possibility to export rasterimages.
2613     Added new classes (MF_Web, MF_Label, MF_Legend, MF_Symbol,
2614     MF_SymbolSet). MF_Symbol and MF_SymbolSet are not needed at the
2615     moment.
2616     (MF_Class.set_thubanstyle): Now point layers will set to a default
2617     symbol to show a circle in mapserver and not only a 1px dot.
2618     (MF_Style.__init__): Fixed a bug with the color. Color was not set
2619     correct before.
2620     (MF_Size): Removed, because it is not needed.
2621    
2622     * Extensions/umn_mapserver/README: Added the hints to use the
2623     export and editing functions, too.
2624    
2625     * Extensions/umn_mapserver/sample/iceland.map: Added the
2626     new parameter "UNITS METERS".
2627     Change the political layer to status OFF.
2628    
2629     * Extensions/umn_mapserver/sample/README: Added some
2630     more details to setup the sample in the MapServer.
2631    
2632 bernhard 2256 2004-06-26 Bernhard Reiter <[email protected]>
2633    
2634     * Extensions/svgexport/test/test_svgmapwriter.py:
2635     Removed class VFile and used standard StringIO instead.
2636    
2637 jschuengel 2255 2004-06-23 Jan Schüngel <[email protected]>
2638    
2639     Add the export function to the umn_mapserver extension.
2640    
2641     * Extension/umn_mapserver/mf_export.py: New. This module extents
2642     Thuban with the possibility to export the Thuban content.
2643    
2644     * Extensions/umn_mapserver/mapfile.py: Expand the classes to use
2645     with the export module. Especially added the possibility to
2646     add thuban objects directly to the map objects.
2647    
2648     * Extensions/umn_mapserver/mf_import.py: Removed the wxCHANGE_DIR,
2649     because of the hint from Bernhard Herzog.
2650     Corrected the handling of absolute pathnames.
2651     Changed the Text of the Menu-Item, now the beginning is upper case.
2652    
2653     * Extensions/umn_mapserver/README: Added the --with-tiff statement.
2654    
2655 jschuengel 2250 2004-06-16 Jan Schüngel <[email protected]>
2656 jschuengel 2242
2657 jschuengel 2250 Add a sample and make some changes.
2658    
2659     * Extension/umn_mapserver/mf_import.py: Changed the wxPython.wx
2660     import from * to explicit used statements. Changed the
2661     Thuban.UI.mainwindow import phrase, too.
2662     (import_mapfile):Corrected a clerical mistake.
2663     Added wxCHANGE_DIR in OpenFile Dialog.
2664     Added a MultipleChoiceDialog, to select the layers to load from
2665     mapfile into thuban. Thereby the projection is only set if one layer
2666     is selected.
2667     Added the possibility to handle relative pathnames which uses
2668     up-level references.
2669     Removed some doubled code.
2670     Corrected an error with integer values used as label in thuban
2671     ClassGroup.
2672    
2673     * Extensions/umn_mapserver/sample: New.
2674    
2675     * Extensions/umn_mapserver/sample/README: New. Describes the
2676     usage of the sample files.
2677    
2678     * Extensions/umn_mapserver/sample/iceland.map: New. This is
2679     a suitable .map-file for the iceland data.
2680    
2681     * Extensions/umn_mapserver/sample/index.html: New. The template
2682     for the mapfile.
2683    
2684     * Extensions/umn_mapserver/sample/iceland.html: New. Initialisation
2685     file for the Iceland Application on web.
2686    
2687     * Extensions/umn_mapserver/README: Corrected a inaccuracy and added
2688     some details.
2689    
2690     * Extensions/umn_mapserver/test/test_mapserver
2691     (mapserver_import_Test_generalClasses.test_MF_Color):
2692     Corrected the thubancolor test.
2693    
2694     2004-06-15 Jan Schüngel <[email protected]>
2695    
2696 jschuengel 2242 * Extensions/umn_mapserver/README: New. Install instruction.
2697    
2698 bernhard 2240 2004-06-14 Bernhard Reiter <[email protected]>
2699    
2700     * libraries/thuban/cpl_mfile.h: Added copyright header.
2701    
2702     * libraries/thuban/ cpl_mfile.cpp, cpl_mfile.h: Added non-protecting
2703     Free Software License so that it is most useful with gdalwarp
2704     and bmpdataset.
2705    
2706 bh 2239 2004-06-14 Bernhard Herzog <[email protected]>
2707    
2708     * Thuban/UI/multiplechoicedialog.py (__version__): Add missing
2709     import of wxPython.wx itself (as opposed to the contents of
2710     wxPython.wx). For some reason wxPython.wx is available as
2711     wxPython.wx.wx in at least some 2.4 releases. Fixes RT#2482
2712     wrt. wxPython 2.4.
2713    
2714 jschuengel 2238 2004-06-10 Jan Schüngel <[email protected]>
2715    
2716     Initial version of new extension "umn_mapserver". This extension aims
2717     to manage configuration for the UMN MapServer application. This
2718     inital version just imports the .map-files and displays all, Thuban is
2719     capable of.
2720    
2721     * Extensions/umn_mapserver, Extensions/umn_mapserver/test: New.
2722    
2723     * Extensions/umn_mapserver/test/README: New. Describes how to run the
2724     tests.
2725    
2726     * Extensions/umn_mapserver/test/test.map: New. This is a test
2727     .map-file for automated tests of the umn_mapserver extension of
2728     Thuban.
2729    
2730     * Extensions/umn_mapserver/test/test_mapserver.py: New. Tests for
2731     UMN Mapserver classes.
2732    
2733     * Extensions/umn_mapserver/__init__.py: New. Init to make this
2734     directory a package.
2735    
2736     * Extensions/umn_mapserver/mapfile.py: New. Classes to represent
2737     '.map'-file objects.
2738    
2739     * Extensions/umn_mapserver/mf_import.py: New. This module extends
2740     Thuban with the possibility to handle UMN MapServer mapfiles.
2741    
2742 bh 2230 2004-06-03 Bernhard Herzog <[email protected]>
2743    
2744     * Thuban/Model/layer.py (Layer.TreeInfo): Convert the bounding box
2745     to a tuple before using it as arguments to the % operator. This
2746     fixes the formatting issue filed in RT#2239 on 2004-01-13 and
2747     reported today on thuban-list by Jan Schüngel
2748    
2749     * test/test_layer.py (TestLayerModification.setUp): Save the
2750     filename as an instance variable so we can refer to it in tests
2751     (TestLayerModification.test_tree_info): Uncomment this method
2752     again and make it work. This tests for the formatting issue
2753     filed in RT#2239 on 2004-01-13
2754    
2755 bh 2224 2004-05-28 Bernhard Herzog <[email protected]>
2756    
2757     * Thuban/UI/baserenderer.py: Fix some typos.
2758    
2759 jan 2217 2004-05-18 Jan-Oliver Wagner <[email protected]>
2760    
2761     * Extensions/gns2shp/gns2shp.py (gns2shp): Fixed a bug
2762     by increasing a field size.
2763    
2764 bh 2213 2004-05-17 Bernhard Herzog <[email protected]>
2765    
2766     Update to newest shapelib and get rid of Thuban specific
2767     extensions, i.e. use the new DBFUpdateHeader instead of our
2768     DBFCommit kludge
2769    
2770     * libraries/shapelib/shpopen.c: Update to version from current
2771     shapelib CVS.
2772    
2773     * libraries/shapelib/shapefil.h: Update to version from current
2774     shapelib CVS.
2775    
2776     * libraries/shapelib/dbfopen.c: Update to version from current
2777     shapelib CVS.
2778     (DBFCommit): Effectively removed since shapelib itself has
2779     DBFUpdateHeader now which is better for what DBFCommit wanted to
2780     achieve.
2781     We're now using an unmodified version of dbfopen.
2782    
2783     * setup.py (extensions): Add the HAVE_UPDATE_HEADER macro with
2784     value '1' to the Lib.dbflibc extension. This simply reflects the
2785     shapelib and pyshapelib updates
2786    
2787 jan 2211 2004-05-16 Jan-Oliver Wagner <[email protected]>
2788    
2789     Finished introduction of Menu.FindOrInsertMenu.
2790    
2791     * Extensions/drawshape/drawshape.py: Add the command
2792     to the experimental menu additionally to the toolbar.
2793    
2794     * Extensions/svgexport/svgsaver.py: Use FindOrInsertMenu() instead of
2795     finding menu on its own.
2796    
2797     * Doc/manual/thuban-manual.xml: updated sample file
2798     to use FindOrInsertMenu().
2799    
2800     * Examples/simple_extensions/hello_world.py: Use FindOrInsertMenu()
2801     instead of finding menu on its own.
2802    
2803 jan 2206 2004-05-11 Jan-Oliver Wagner <[email protected]>
2804    
2805     * test/test_menu.py (MenuTest.test): Added testing
2806     of method Menu.FindOrInsertMenu.
2807    
2808 jan 2204 2004-05-10 Jan-Oliver Wagner <[email protected]>
2809    
2810     Introduce and use Menu.FindOrInsertMenu.
2811    
2812     * Thuban/UI/menu.py (Menu.FindOrInsertMenu): New. Find a
2813     given menu or, if not found, insert it.
2814    
2815     * Extensions/bboxdump/bboxdump.py, /Extensions/gns2shp/gns2shp.py,
2816     /Extensions/importAPR/importAPR.py, Extensions/profiling/profiling.py,
2817     /Extensions/wms/wms.py: Use FindOrInsertMenu() instead of finding
2818     menu on its own.
2819    
2820 jan 2201 2004-05-06 Jan-Oliver Wagner <[email protected]>
2821    
2822     Introduce a abstract ColorDialog class and remove
2823     and outdated file.
2824    
2825     * Thuban/UI/proj4dialog.py: Removed. It is has been
2826     replaced by projdialog for quite a while and is not used
2827     anymore.
2828    
2829     * Thuban/UI/colordialog.py: New. Abstraction for color selection
2830     dialog(s).
2831    
2832     * Thuban/UI/classifier.py (SelectPropertiesDialog.__GetColor):
2833     Now calls the abstract ColorDialog instead of wxColourDialog.
2834     This also removed the dependency to Color class conversion
2835     from this function.
2836    
2837 frank 2197 2004-05-04 Frank Koormann <[email protected]>
2838    
2839     * Extensions/bboxdump/__init__.py: Fixed string left over from
2840     copying.
2841    
2842     * Extensions/bboxdump/bboxdump.py (bboxdump):
2843     Use layer.ShapeStore().AllShapes() to loop over shapes instead of
2844     xrange(layer.NumShapes()). Compile the bboxmessage from a list
2845     of formatted outputs (string.join) instead of appending to the
2846     message. Two progress bar dialogs to report progress on the sometimes
2847     lenghty processing.
2848    
2849 frank 2196 2004-04-22 Frank Koormann <[email protected]>
2850    
2851     New Extension to dump bounding boxes of all shapes of the selected
2852     layer. An optional column can be specified to group the objects,
2853     in this case the bounding box is a union of the separate boxes.
2854     Dump can be displayed in a ScrolledMessageDialog or written to file.
2855     The Extension is simply a combination of available and well tested
2856     Thuban functionality.
2857    
2858     * Extensions/bboxdump/__init__.py: New: Init to make this
2859     directory a package.
2860    
2861     * Extensions/bboxdump/bboxdump.py: New: Dump bounding boxes of
2862     all shapes of the selected layer.
2863    
2864 jan 2192 2004-04-22 Jan-Oliver Wagner <[email protected]>
2865    
2866     * Thuban/UI/classgen.py (GenUniquePanel.__init__): Fixed two
2867     strings to be i18n now.
2868    
2869 jan 2188 2004-04-18 Jan-Oliver Wagner <[email protected]>
2870    
2871     Changing popup menu of legend from direct building
2872     to using the Menu construction as used for the mainwindow.
2873    
2874     * Thuban/UI/mainwindow.py: New method commands: layer_to_top,
2875     layer_to_bottom, layer_visibility
2876     (MainWindow.LayerToTop): New. Put current layer to the top.
2877     (MainWindow.LayerToBottom): New. Put current layer to bottom.
2878     (MainWindow.HideLayer, MainWindow.ShowLayer, _has_visible_map):
2879     Replace 1,0 by True, False.
2880     (MainWindow.ToggleLayerVisibility): New. Toggle visibility of
2881     current layer.
2882     (MainWindow.LayerShowTable): Removed raising of dialog.
2883     (_has_selected_layer_visible): New. Support function.
2884    
2885     * Thuban/UI/legend.py: ID_POP_xxx: removed.
2886     (LegendPanel.__init__): Removed EVT_MENU bindings.
2887     (LegendTree._OnRightClick): Replace direct creation of
2888     menu via wx Classes by applying the menu definition
2889     as of Menu class of menu.py.
2890    
2891 jan 2185 2004-04-16 Jan-Oliver Wagner <[email protected]>
2892    
2893     * Thuban/UI/exceptiondialog.py (ExceptionDialog.dialog_layout): Improved
2894     button string to stronger clearify that Thuban will be closed when hitting
2895     the button.
2896    
2897     * Thuban/UI/mainwindow.py (MainWindow.LayerShowTable): Added docstring.
2898     Now for layers without a ShapeStore a corresponding message is given
2899     to the user, that this layer has no table to show.
2900    
2901 joey 2182 2004-04-15 Martin Schulze <[email protected]>
2902    
2903     * Extensions/wms/layer.py (WMSLayer.setWMSFormat): Need to
2904     recalculate the format for the internal render engine as well.
2905    
2906     * Extensions/wms/properties.py (wmsProperties): First start for a
2907     properties dialog. It's functional for a first selection of
2908     layers, but still has some weired wxWidgets/GTK problems but
2909     beautification can be done later.
2910    
2911     * Extensions/wms/layer.py: Added more documentation
2912     (WMSLayer.getFormats): New: Return list of supported image formats
2913     by the WMS server
2914     (WMSLayer.getLayers): New: Return the list of layer names
2915     supported by the WMS server
2916     (WMSLayer.getLayerTitle): New: Return the title of the named layer
2917     (WMSLayer.getWMSFormat): New: Return the image format that is used
2918     for WMS GetMap requests
2919     (WMSLayer.setWMSFormat): New: Set the image format that is used
2920     for WMS GetMap requests
2921     (WMSLayer.__init__): Move away from using only one layer to using
2922     a list of layers (unsorted at the moment, though).
2923     (WMSLayer.getVisibleLayers): New: Return the list of names for all
2924     visible layers
2925     (WMSLayer.setVisibleLayers): New: Set the list of names for all
2926     visible layers
2927    
2928     * Extensions/wms/wms.py: Moved the WMS layer into layer.py in
2929     order to establish a clean structure.
2930    
2931     * Extensions/wms/layer.py: Moved the WMS layer into a file on its
2932     own in order to establish a clean structure.
2933    
2934 joey 2174 2004-04-13 Martin Schulze <[email protected]>
2935    
2936     * Extensions/wms/parser.py (WMSCapabilitiesParser.grok): Added
2937     support for oldstyle (WMS 1.0 apparently) image format
2938     specification.
2939    
2940     * Extensions/wms/wms.py (WMSLayer.calcFormat): Reduce the list of
2941     supported graphic formats back to JPEG and BMP, PNG and others are
2942     too *cough* experimental... Sorry, I meant to filter this out
2943     before I committed this part. This should make the WMS extension
2944     run from CVS again.
2945     (wms_dialog): Reset an empty URL to None so that the subsequent
2946     program can depend on this, since the dialog will indeed return an
2947     empty URL, causing another declaration of love by Python.
2948    
2949     * Extensions/wms/parser.py (WMSCapabilitiesParser.getLayerBBox):
2950     Whenever a native BoundingBox request cannot be fulfilled, check
2951     whether the requested SRS is EPSG:3426, in which case return the
2952     LatLonBoundingBox values.
2953    
2954     * Extensions/wms/test/test_parser.py
2955     (TestWMSCapabilitiesParser.test_LayerSRS): Added a test for
2956     ignoring AUTO:* SRS.
2957     (TestWMSCapabilitiesParser.test_LatLonBoundingBoxes_as_bboxes):
2958     Added another test method to test whether the LatLonBoundingBox
2959     values will be returned if BoundingBox values are requested with
2960     SRS set to EPSG:3426.
2961    
2962     * Extensions/wms/parser.py (WMSCapabilitiesParser.peekLayers):
2963     Added rudimentary support for non-EPSG SRS, i.e. ignore them for
2964     the moment by placing them into a variable which is currently
2965     unused. Also test whether the EPSG SRS is numerical as it should
2966     be and add an error message if it is not.
2967    
2968     * Extensions/wms/test/sample.xml: Added AUTO:* SRS since they
2969     appear in the real world as well. Since we cannot handle them yet
2970     (OGCLib can't either), we will ignore them for the moment.
2971    
2972     * Extensions/wms/parser.py: Use a variable for denoting the sample
2973     filename
2974     (WMSCapabilitiesParser.peekLayers): Added support for error
2975     messages during grok(). They will be aggregated in an array and
2976     may be displayed later. We may have to add a classification
2977     "Warning" and "Error" to this. That requires more experience,
2978     though, since not every error may be lethal.
2979    
2980     * Thuban/UI/mainwindow.py (MainWindow.LayerShowTable): Raise the
2981     ShowTable() dialog/frame when the user attempts to display it
2982     while it has been opened before already and not closed again.
2983    
2984 joey 2161 2004-04-11 Martin Schulze <[email protected]>
2985    
2986     * Extensions/wms/infodialog.py: Adjusted the class documentation
2987    
2988     * Extensions/wms/wms.py (WMSLayer.__init__, WMSLayer.GetMapImg):
2989     Switch to using Thuban{Begin,End}BusyCursor instead of the pure
2990     wxWidgets variants.
2991     (WMSLayer.__init__): The epsg_id variable is named top_srs now.
2992    
2993     * Extensions/wms/infodialog.py: Added an information dialog that
2994     will display various information about the WMS current resource,
2995     so that additional information such as the title, the abstract,
2996     fees and access constraints can be displayed for the user if they
2997     are documented in the WMS XML.
2998    
2999 joey 2156 2004-04-10 Martin Schulze <[email protected]>
3000    
3001     * Extensions/wms/parser.py (WMSCapabilitiesParser.grok): Adjusted
3002     string handling. It's "foo".lower() and not lower(foo) without
3003     lower imported from strings or something.
3004    
3005     * Extensions/wms/wms.py (WMSLayer): Incorporated WMSCapabilities
3006     from capabilities.py and parser.py. Implement priority list for
3007     supported graphics formats, take care of wbmp != bmp. PNG, TIFF
3008     and GIF are supported here, but not yet by main Thuban. Hence,
3009     support for them may be removed later. Special contribution to
3010     usability: get wxWidgets to change the cursor when we're waiting
3011     for data from the network so the user won't start to worry. This
3012     causes a redrawing error/warning, though.
3013    
3014     * Extensions/wms/parser.py (WMSCapabilitiesParser.grok): Unlink
3015     the DOM object.
3016    
3017     2004-04-01 Martin Schulze <[email protected]>
3018    
3019     * Extensions/wms/capabilities.py: Adjusted documentation
3020     (WMSCapabilities.__init__): Improved documentation, fixed syntax
3021     (WMSCapabilities.saveCapabilities): Only catch IOError when
3022     handling files
3023     (WMSCapabilities.loadCapabilities): Only catch IOError when
3024     handling files
3025     __main__: corrected variable naming
3026     (WMSCapabilities.fetchCapabilities,loadCapabilities): Make this
3027     class a specialisation of WMSCapabilitiesParser as well. Also
3028     execute grok() after loading or fetching capabilities, if that
3029     went well, so that subsequent calls can already access the data.
3030     (WMSCapabilities.getVersion): Export the used version of the
3031     GetCapabilities request, so we can use it for subsequent calls,
3032     i.e. for GetMap requests.
3033     (WMSCapabilities.fetchCapabilities): Added proper error handling
3034     when the GetCapabilities request failed, so that the surrounding
3035     program can act accordingly.
3036    
3037 joey 2146 2004-03-30 Martin Schulze <[email protected]>
3038    
3039     * Extensions/wms/parser.py (WMSCapabilitiesParser.getLayerSRS):
3040     Adjusted the getLayerSRS method to return the list of SRSes
3041     extracted from <SRS> elements instead of <BoundingBox> elements.
3042     Added a bit of documentation as well.
3043     (WMSCapabilitiesParser.checkLayerSRS): Removed integrity test
3044     since it was only implemented due to a misunderstanding.
3045    
3046     * Extensions/wms/test/test_parser.py
3047     (TestWMSCapabilitiesParser.test_LayerSRS): Adjust the tests to
3048     reflect the corrected interpretation of the standard: i.e. a layer
3049     does not have to define a BoundingBox for all SRSes it supports.
3050     Hence the <SRS></SRS> specification is authoritative, not the list
3051     of BoundingBoxes.
3052     (TestWMSCapabilitiesParser.test_BoundingBoxes): Added a new test
3053     to ensure None is returned for a non-existing SRS.
3054     (TestWMSCapabilitiesParser.test_grok): Removed test_grok method
3055     since it is not applicable anymore. Listing more SRSes in <SRS>
3056     elements is valid according to the specs.
3057    
3058 bernhard 2140 2004-03-26 Bernhard Reiter <[email protected]>
3059 joey 2146
3060 bernhard 2140 * README: Nicer formatting of text. Improved descriptions.
3061     Reflected wxWidgets name change.
3062    
3063     * Thuban/UI/about.py: Extended copyright to 2004 and added
3064     information about the thuban-devel mailinglist.
3065    
3066 joey 2138 2004-03-24 Martin Schulze <[email protected]>
3067 joey 2120
3068 joey 2138 * Extensions/wms/capabilities.py: Renamed the class to contain
3069     'WMS', also added a linebreak where required
3070    
3071     * Extensions/wms/parser.py: Finally added the XML parser for the
3072     GetCapabilities response.
3073    
3074     * Extensions/wms/test/sample.xml: Adjusted the sample file so that
3075     <SRS> elements match the <BoundingBox> elements, except for the
3076     layer 'beschriftung'.
3077    
3078     * Extensions/wms/test/test_parser.py: Encode non-ascii strings
3079     since Python uses unicode strings internally, otherwise
3080     comparisons will fail. Removed tests for getLayerBBoxSRS() since
3081     the SRS will be calculated anyway and this method is obsoleted by
3082     getLayerSRS(). Denote SRS as strings and not as cardinal numbers.
3083     Move loading the sample file into the setUp method. Added a test
3084     for finding the integrity problem in the sample response.
3085     Improved formatting.
3086    
3087     * Extensions/wms/domutils.py: Added convenience routines for
3088     handling of Document Object Model (DOM) nodes.
3089    
3090     * Extensions/wms/test/test_domutils.py: Added a test for the
3091     domutils module
3092    
3093     2004-03-19 Martin Schulze <[email protected]>
3094    
3095 joey 2120 * Extensions/wms/test/test_parser.py (TestWMSCapabilitiesParser):
3096     Moved path detection and adding into a module of its own,
3097     adjustpath, which exports thubandir as main Thuban directory.
3098    
3099     * Extensions/wms/test/test_ogclib.py (TestWMSLib): Moved path
3100     detection and adding into a module of its own, adjustpath, which
3101     exports thubandir as main Thuban directory. Reorganised the
3102     module in order to support the SkipTest feature for Thuban test
3103     cases.
3104    
3105     * Extensions/wms/test/adjustpath.py: Moved path detection and
3106     adding into a module of its own.
3107    
3108 joey 2115 2004-03-18 Martin Schulze <[email protected]>
3109    
3110     * Extensions/wms/test/test_parser.py: Added another test for
3111     checking whether the WMS XML parser (to be implemented) returns
3112     the information we expect. This requires a sample WMS WML file
3113     (sample.xml) which has been extracted from the frida server and
3114     "improved" manually.
3115    
3116     * Extensions/wms/test/test_ogclib.py: Added legacy code to add the
3117     main Thuban directory to the path in order to be able to import
3118     random modules. Adjusted the PyOGCLib detection to reuse the
3119     information gathered. Also added a note about the PYTHONPATH
3120     environment variable.
3121    
3122     * Extensions/wms/test/test_ogclib.py: The format specification is
3123     a mime-type, not a graphic format, hence image/jpeg wou ld be the
3124     proper format and not JPEG. We'll also have to take care of the
3125     encoding of / as %2F.
3126    
3127 joey 2111 2004-03-16 Martin Schulze <[email protected]>
3128    
3129     * Extensions/wms/test/test_ogclib.py: Added a (hopefully)
3130     comprehensive test for the getMapURL method, built compare URLs
3131     according to the documentation in OGC 01-068r3
3132    
3133     * Extensions/wms/capabilities.py (WMSCapabilities): Added the
3134     class WMSCapabilities to manage capabilites, will incorporate
3135     parsing the capabilities response and provide details for other
3136     classes.
3137    
3138 bh 2105 2004-03-12 Bernhard Herzog <[email protected]>
3139    
3140 bh 2107 Support views in addition to normal tables in the postgis
3141     shapestore
3142    
3143     * Thuban/Model/postgisdb.py
3144     (PostGISShapeStore._fetch_table_information): Add a fallback for
3145     the case where the table name is not in the geometry_columns
3146     table. This is usually the case for views. Also, set
3147     self.shapestore here.
3148     (PostGISShapeStore.ShapeType): No need to query the database all
3149     the time. The shape type is now determined in
3150     _fetch_table_information
3151    
3152     * test/postgissupport.py (PostgreSQLServer.new_postgis_db)
3153     (PostgreSQLServer.get_static_data_db, PostGISDatabase.__init__):
3154     New parameter to specify views.
3155     (PostGISDatabase.has_data): Also compare the views. New views
3156     parameter
3157     (PostGISDatabase.initdb): Create the views.
3158     (PostgreSQLServer.get_default_static_data_db): Add the v_landmarks
3159     view
3160    
3161     * test/test_postgis_db.py
3162     (TestPostGISShapestorePointFromViews): New. Test a
3163     PostGISShapeStore with a view
3164     (TestPostGISShapestorePointOIDAsGIDColumn.setUp): Pass the name of
3165     the geometry_column explicitly to test whether that works
3166    
3167     2004-03-12 Bernhard Herzog <[email protected]>
3168    
3169 bh 2105 Final step for explicit id/geometry columns: Loading and saving
3170    
3171     * Resources/XML/thuban-1.1.dtd: New. Derived from thuban-1.0.dtd
3172     with the following changes:
3173     (dbshapesource): Two new attributes id_column and geometry_column
3174    
3175     * Thuban/Model/save.py (SessionSaver.write): Use the new dtd
3176     (SessionSaver.write_session): Use the new namespace
3177     (SessionSaver.write_data_containers): Write the new dbshapesource
3178     parameters
3179    
3180     * Thuban/Model/load.py (SessionLoader.__init__): New namespace for
3181     the new file format version
3182     (SessionLoader.start_dbshapesource): Handle the new db parameters
3183    
3184     * test/test_save.py: Update to the new dtd and namespace
3185     (SaveSessionTest.test_save_postgis): Update the NonConnectionStore
3186     mock object to provide a working IDColumn method.
3187    
3188     * test/test_load_1_0.py: New. Copy of the test_load.py before
3189     today's changes but with the round-trip tests removed.
3190    
3191     * test/test_load_0_9.py: Update doc-string.
3192    
3193     * test/test_load.py: Update all .thuban files to the new dtd and
3194     namespace.
3195     (TestPostGISLayer.file_contents): Add the new dbshapesource
3196     paramters
3197    
3198 bh 2100 2004-03-11 Bernhard Herzog <[email protected]>
3199    
3200 bh 2103 Next step for explicit id/geometry columns: User interaction
3201    
3202     * Thuban/UI/dbdialog.py (ChooseDBTableDialog.__init__): Rework how
3203     the dialog is constructed. Add combo boxes to select id and
3204     geometry column. Rename some instance variables.
3205     (ChooseDBTableDialog.GetTable): Return id and geometry column
3206     names
3207     (ChooseDBTableDialog.OnTableSelect): New. Event handler for
3208     selections in the table list
3209    
3210     * Thuban/UI/mainwindow.py (MainWindow.AddDBLayer): Use id_column
3211     and geometry_column
3212    
3213     * Thuban/Model/session.py (Session.OpenDBShapeStore): Add the new
3214     parameters for id_column and geometry column of PostGISShapeStore
3215     here as well.
3216    
3217     * Thuban/Model/postgisdb.py (type_map): Add ROWID psycog type.
3218     (_raw_type_map): New. Map raw PostgreSQL type ints to thuban types
3219     (PostGISConnection.GeometryTables): Use a better query to
3220     determine which relations in the database might be usable for
3221     shapestores. Now supports views as well but is more PostgreSQL
3222     specific
3223     (PostGISConnection.table_columns): New. Somewhat experimental
3224     method to let the db dialogs provide lists of columns to users so
3225     that they can select id and geometry columns.
3226     (PostGISTable.__init__): The default value of the id_column
3227     parameter is now None it still means "gid" effectively, though.
3228     (PostGISTable.IDColumn): New introspection method to return a
3229     column object for the id column
3230     (PostGISShapeStore.GeometryColumn): New introspection method to
3231     return a column object for the geometry column
3232    
3233     * test/test_postgis_db.py
3234     (TestPostGISConnection.test_gis_tables_non_empty):
3235     Removed. Subsumed by the new:
3236     (TestPostGISConnection.test_gis_tables_with_views_and_tables):
3237     New. Tes the GeometryTables and table_columns methods with actual
3238     tables and views.
3239     (PointTests.test_id_column, PointTests.test_geometry_column):
3240     New. tests for the new methods.
3241     (TestPostGISShapestorePoint.setUp)
3242     (TestPostGISShapestorePointSRID.setUp)
3243     (TestPostGISShapestorePointExplicitGIDColumn.setUp): Fill the
3244     instance variables needed by the new tests
3245    
3246     2004-03-11 Bernhard Herzog <[email protected]>
3247    
3248 bh 2100 * Thuban/UI/classgen.py (GenQuantilesPanel.GetList): The row
3249     numbers given to ReadValue are ordinals.
3250    
3251     2004-03-11 Bernhard Herzog <[email protected]>
3252    
3253     Elimiate the requirement for PostGIS tables to have a column
3254     called "gid".
3255    
3256     * Thuban/Model/postgisdb.py (PostGISTable.__init__): New parameter
3257     id_column to specify which column to use to identify rows. Also
3258     new instance variables id_column and quoted_id_column
3259     (PostGISTable.RowIdToOrdinal, PostGISTable.RowOrdinalToId)
3260     (PostGISTable.ReadRowAsDict, PostGISTable.ReadValue)
3261     (PostGISTable.SimpleQuery): Use the id column name provided to the
3262     constructor instead of "gid"
3263     (PostGISShapeStore.__init__): New parameter id_column analogously
3264     to PostGISTable.__init__. This parameter is simply passed through
3265     to the base class constructor
3266     (PostGISShapeStore._create_col_from_description): Fix typo in
3267     doc-string
3268     (PostGISShapeStore.Shape, PostGISShapeStore.AllShapes)
3269     (PostGISShapeStore.ShapesInRegion): Use the id column name
3270     provided to the constructor instead of "gid"
3271    
3272     * test/postgissupport.py
3273     (PostgreSQLServer.get_default_static_data_db): New static table
3274     landmarks_point_id with an id column != "gid. Update the comments
3275     a bit.
3276     (skip_if_addgeometrycolumn_does_not_use_quote_ident): Fix typo in
3277     doc-
3278     (upload_shapefile): New parameter gid_column to use a name other
3279     than "gid" for the column to store the shape ids
3280    
3281     * test/test_postgis_db.py (TableTests): New. Mixin-class
3282     containing all tests previously in TestPostGISTable. The actual
3283     tests are the same but the code is a bit more configurable to
3284     allow for different id columns etc.
3285     (TestPostGISTable): Derive from TableTests now for the actual
3286     tests.
3287     (TestPostGISTableExplicitGIDColumn): New. Like TestPostGISTable
3288     except that it the landmarks_point_id table to test the id_column
3289     parameter
3290     (PointTests): Extend the doc-string
3291     (TestPostGISShapestorePointExplicitGIDColumn)
3292     (TestPostGISShapestorePointOIDAsGIDColumn): New classes derived
3293     from PointTests to test the explicit id_column parameter. One
3294     tests with the name of the column holding the shape ids, the other
3295     uses PostgreSQL's OID column. For the latter a number of methods
3296     have to be overwritten to make them independent of the actual id
3297     values.
3298    
3299 silke 2095 2004-03-08 Silke Reimer <[email protected]>
3300    
3301     Update debian directory:
3302    
3303     * debian/changelog: Added new version.
3304     * deiban/rules: Updated management of patches (with cbds)
3305     * debian/control: Added cbds to dependencies
3306     * debian/patches/*: New. Adds better support for patches of thuban in
3307     debian
3308     * debian/menu: Syntax of menu changed slightly
3309     * debian/setup.py.patch: removed because it has been moved to
3310     debian/patechs/setup.py.patch
3311    
3312    
3313 bh 2094 2004-02-26 Bernhard Herzog <[email protected]>
3314    
3315     Create the Doc/technotes directory for text files with information
3316     for developers
3317    
3318     * Doc/technotes/README: New. README for the technotes
3319    
3320     * Doc/technotes/coding_guidelines.txt: New. Coding guidelines for
3321     Thuban
3322    
3323     * Doc/technotes/release_process.txt: New. Used to be
3324     HOWTO-Release. Now slightly adapted to technote formatting style.
3325    
3326     * HOWTO-Release: Removed. It's contents are now in
3327     Doc/technotes/release_process.txt
3328    
3329 bh 2089 2004-02-25 Bernhard Herzog <[email protected]>
3330    
3331     * libraries/thuban/wxproj.cpp (get_wx_version): New. Return the
3332     version of wxWindows the module was compiled with so we can check
3333     that against the wxPython version.
3334    
3335     * Thuban/version.py (thuban_branch, thuban_release): New variables
3336     controlling which and how Thuban versions are shown. See the
3337     comments for details.
3338     (verify_versions): Also check that the wx version that wxproj is
3339     compiled against matches that of the wxPython we use at runtime
3340    
3341 bh 2080 2004-02-20 Bernhard Herzog <[email protected]>
3342    
3343 bh 2087 * Extensions/wms/wms.py (epsg_code_to_projection): Use
3344     get_system_proj_file to read the epsg projections. The old way
3345     depended on the current directory being the top Thuban directory.
3346    
3347     2004-02-20 Bernhard Herzog <[email protected]>
3348    
3349 bh 2085 * Extensions/svgexport/test/test_svgmapwriter.py
3350     (TestVirtualDC.test_clippath): Remove a debug print
3351    
3352     2004-02-20 Bernhard Herzog <[email protected]>
3353    
3354 bh 2083 * Extensions/svgexport/__init__.py: New. Turn
3355     Extensions/svgexport into a package.
3356    
3357     * Extensions/svgexport/svgmapwriter.py: Reorder the imports and
3358     doc-string a bit. The doc-string must come first, otherwise it's
3359     not a doc-string. The __future__ import must be the first thing
3360     after the doc-string. Use only double quotes in doc-strings.
3361     Single quotes trip up emacs syntax highlighting if the text
3362     contains apostrophes.
3363    
3364     2004-02-20 Bernhard Herzog <[email protected]>
3365    
3366 bh 2080 * Extensions/svgexport/test/__init__.py,
3367     Extensions/svgexport/test/test_svgmapwriter.py: New. Initial test
3368     suite for svgexport
3369    
3370     * test/runtests.py (find_test_modules): New. Function with the
3371     module finding code from main.
3372     (main): Use find_test_modules to figure out the default test
3373     modules and take modules from Extensions.svgexport.test too.
3374    
3375 bh 2075 2004-02-19 Bernhard Herzog <[email protected]>
3376    
3377 bh 2077 * Thuban/UI/application.py (ThubanApplication.OnInit): Make sure
3378     the mainwindow has a reference to the map of the initial session.
3379     This fixes a bug introduced with the fix for RT#2245
3380    
3381     2004-02-19 Bernhard Herzog <[email protected]>
3382    
3383 bh 2075 * Extensions/svgexport/svgsaver.py,
3384     Extensions/svgexport/svgmapwriter.py,
3385     Extensions/svgexport/maplegend.py: Added again. This time in the
3386     correct place.
3387    
3388 bh 2070 2004-02-17 Bernhard Herzog <[email protected]>
3389    
3390 bh 2073 Fix for RT#2245
3391    
3392     * Thuban/UI/application.py (ThubanApplication.OnInit): Initialize
3393     instance variables before trying to create any windows. Creating
3394     windows can start an event loop if e.g. message boxes are popped
3395     up for some reason, and event handlers, especially EVT_UPDATE_UI
3396     may want to access things from the application.
3397     (ThubanApplication.maps_changed): The mainwindow may not have been
3398     created yet, so check whether it has been created before calling
3399     its methods
3400    
3401     * Thuban/UI/view.py (MapCanvas.OnIdle): Only try to redraw if we
3402     have a map
3403    
3404     2004-02-17 Bernhard Herzog <[email protected]>
3405    
3406 bh 2070 * test/test_svgmapwriter.py, Extensions/svgsaver.py,
3407     Extensions/svgmapwriter.py, Extensions/maplegend.py,
3408     extensions/svgexport/svgsaver.py,
3409     extensions/svgexport/svgmapwriter.py,
3410     extensions/svgexport/maplegend.py: Removed. These files were in
3411     the wrong places or didn't work at all.
3412    
3413 bh 2067 2004-02-16 Bernhard Herzog <[email protected]>
3414    
3415 bh 2069 * Thuban/UI/view.py (MapCanvas.Export): Remove accidentally added
3416     line
3417    
3418     2004-02-16 Bernhard Herzog <[email protected]>
3419    
3420 bh 2067 * Thuban/UI/view.py (MapCanvas.Export): Avoid UnboundLocalError.
3421    
3422 mrechtie 2064 2004-02-15 Markus Rechtien <[email protected]>
3423    
3424     * Extensions/svgexport/svgmapwriter.py: New. Adds the capability
3425     to write a session to a file in SVG format.
3426     * Extensions/svgexport/svgsaver.py: New. Uses svgmapwriter.py
3427     to write a SVG map of a session.
3428     * Extensions/svgexport/maplegend: New. Writes a basic maplegend
3429     in SVG format for the current session.
3430    
3431 bh 2062 2004-02-13 Bernhard Herzog <[email protected]>
3432    
3433     * Thuban/UI/mainwindow.py (MainWindow.AddDBLayer): When the layer
3434     can't be created, return immediately after displaying the error
3435     message.
3436    
3437 bh 2060 2004-02-11 Bernhard Herzog <[email protected]>
3438    
3439     Handle postgis tables with more than one geometry column.
3440    
3441     * Thuban/Model/postgisdb.py
3442     (PostGISTable._fetch_table_information): Delegate the creation of
3443     column objects to a different method so that we can extend that in
3444     derived classes
3445     (PostGISTable._create_col_from_description): New. Column object
3446     creation part of _fetch_table_information
3447     (PostGISShapeStore._create_col_from_description): New. Extend
3448     inherited method to handle geometry columns
3449     (PostGISShapeStore.__init__): New parameter geometry_column to
3450     specify which geometry column to use. Optional but mandatory for
3451     tables with more than one geometry column
3452     (PostGISShapeStore._fetch_table_information): Also use the name of
3453     the geometry column when looking for the srid
3454     (PostGISShapeStore.ShapeType): Also use the name of the geometry
3455     column when looking for the shape type
3456    
3457     * test/test_save.py (SaveSessionTest.test_save_postgis): Adapt
3458     NonConnectionStore to changes in the PostGISShapeStore
3459    
3460     * test/test_postgis_db.py
3461     (TestPostGISSpecialCases.test_shapestore_two_geom_cols): Test
3462     PostGISShapeStore with tables having two geometry columns.
3463    
3464 bh 2058 2004-02-10 Bernhard Herzog <[email protected]>
3465    
3466     Fix some postgis problems. What remains to be done is real
3467     handling of SRIDs as they affect how reprojection is done
3468    
3469     * Thuban/Model/postgisdb.py (quote_identifier): Fix typo in
3470     doc-string
3471     (PostGISShapeStore._fetch_table_information): New. Extend
3472     inherited method to retrieve srid
3473     (PostGISShapeStore.BoundingBox): Handle tables without data.
3474     extent yields NULL for those
3475     (PostGISShapeStore.ShapesInRegion): Use the srid of the table.
3476    
3477     * test/test_postgis_db.py
3478     (TestPostGISSpecialCases.test_shapestore_empty_table): New test
3479     for the special case of a table without any data
3480     (TestPostGISShapestorePointSRID): New class with tests for a table
3481     that uses srids
3482     (PolygonTests): Fix a doc-string typo
3483    
3484     * test/postgissupport.py (PostGISDatabase.__init__): New parameter
3485     reference_systems with a specification of spacial reference
3486     systems to create in the new db.
3487     (PostgreSQLServer.new_postgis_db)
3488     (PostgreSQLServer.get_static_data_db): New parameter
3489     reference_systems to be passed through ultimately to
3490     PostGISDatabase. In new_postgis_db also check whether an existing
3491     db already has the right srids
3492     (PostgreSQLServer.get_default_static_data_db): Add srids and a
3493     table that uses srids
3494     (PostGISDatabase.initdb): Create the entries for the reference
3495     systems
3496     (PostGISDatabase.has_data): Add reference_systems parameter to
3497     check for those too
3498     (upload_shapefile): New parameter srid to create tables with a
3499     specific srid
3500    
3501 frank 2055 2004-02-06 Frank Koormann <[email protected]>
3502    
3503     * po/pt_BR.po: Fixed charset
3504    
3505 frank 2054 2004-02-05 Frank Koormann <[email protected]>
3506    
3507     * po/pt_BR.po: Fixed format string for error message, missing %s
3508     added (Thuban/UI/application.py:273)
3509    
3510 frank 2053 2004-02-03 Frank Koormann <[email protected]>
3511    
3512     First version of Portuguese (Brazilian) translation
3513    
3514     * po/pt_BR.po: New, translation of pot (2004-01-15 16:07+0300) for
3515     Brazilian Portuguese by Eduardo Patto Kanegae.
3516    
3517     * Thuban/UI/about.py (About.__init.py__): Added Eduardo to the list of
3518     translators.
3519    
3520    
3521 frank 2052 2004-01-22 Frank Koormann <[email protected]>
3522    
3523     * Doc/manual/thuban-manual.xml: Added section on installation of
3524     Thuban under Win32 systems. Fixed image path references in the postgis
3525     section. Some minor source formattings.
3526    
3527 frank 2051 2004-01-21 Frank Koormann <[email protected]>
3528    
3529     Make Thuban remember path selections (at least for one application run).
3530    
3531     * Thuban/UI/application.py (Application.OnInit): Initialize path as a
3532     attribute of application object. Path is a dictionary of
3533     strings, currently with the items "data" and "projection".
3534     (Application.SetPath): New, stores path for the specified item.
3535     (Application.Path): New, return path for the specified item.
3536    
3537     * Thuban/UI/mainwindow.py
3538     (MainWindow.OpenSession, MainWindow.SaveSessionAs,
3539     MainWindow.AddLayer, MainWindow.AddRasterLayer,
3540     MainWindow.TableOpen): Access "data" path information of the
3541     application.
3542    
3543     * Thuban/UI/projdialog.py (ProjFrame._OnImport, ProjFrame._OnExport):
3544     Access "projection" path information of the application.
3545    
3546 bh 2048 2004-01-05 Bernhard Herzog <[email protected]>
3547    
3548 bh 2050 * po/ru.po: Updated translations from Alex Shevlakov
3549    
3550     2004-01-05 Bernhard Herzog <[email protected]>
3551    
3552 bh 2048 * po/Makefile, po/README: Move the description of how to generate
3553     the translation statistics to the README.
3554    
3555 bh 2042 2003-12-23 Bernhard Herzog <[email protected]>
3556    
3557 bh 2045 * NEWS: Update for 1.0.0
3558    
3559     * po/it.po: Another update from Maurizio Napolitano
3560    
3561     2003-12-23 Bernhard Herzog <[email protected]>
3562    
3563 bh 2042 * po/it.po: Updated translation from Maurizio Napolitano
3564    
3565     2003-12-23 Bernhard Herzog <[email protected]>
3566    
3567     * Thuban/UI/join.py (JoinDialog.__init__): Mark one more string
3568     for translation
3569    
3570     * Thuban/UI/mainwindow.py (MainWindow.TableRename)
3571     (MainWindow.RenameMap, MainWindow.RenameLayer): Mark some more
3572     strings for translation
3573    
3574     * po/de.po: Update with the newly marked strings.
3575    
3576 bh 2033 2003-12-22 Bernhard Herzog <[email protected]>
3577    
3578 bh 2039 * HOWTO-Release: Fix the places where version numbers have to be
3579     updated
3580    
3581     2003-12-22 Bernhard Herzog <[email protected]>
3582    
3583 bh 2037 * setup.py (setup call): 1.0.0, yeah!
3584    
3585     * Thuban/version.py (longversion): 1.0.0, yeah!
3586    
3587     * Thuban/Model/load.py (SessionLoader.__init__): Accept the
3588     1.0.0 namespace too
3589    
3590     * Thuban/Model/save.py (SessionSaver.write_session): Save with
3591     1.0.0 namespace
3592    
3593     * test/test_load.py (LoadSessionTest.dtd)
3594     (TestSingleLayer.file_contents)
3595     (TestNonAsciiColumnName.file_contents)
3596     (TestLayerVisibility.file_contents)
3597     (TestClassification.file_contents, TestLabels.file_contents)
3598     (TestLayerProjection.file_contents)
3599     (TestRasterLayer.file_contents, TestJoinedTable.file_contents)
3600     (TestLabelLayer.file_contents, TestPostGISLayer.file_contents)
3601     (TestPostGISLayerPassword.file_contents)
3602     (TestLoadError.file_contents, TestLoadError.test): Update for
3603     1.0.0 namespace
3604    
3605     * test/test_save.py (SaveSessionTest.dtd)
3606     (SaveSessionTest.testEmptySession)
3607     (SaveSessionTest.testSingleLayer)
3608     (SaveSessionTest.testLayerProjection)
3609     (SaveSessionTest.testRasterLayer)
3610     (SaveSessionTest.testClassifiedLayer)
3611     (SaveSessionTest.test_dbf_table)
3612     (SaveSessionTest.test_joined_table)
3613     (SaveSessionTest.test_save_postgis): Update for 1.0.0 namespace
3614    
3615     2003-12-22 Bernhard Herzog <[email protected]>
3616    
3617 bh 2035 * Thuban/Model/load.py (SessionLoader.start_label): Make sure the
3618     alignment flags are byte strings not unicode and that they have
3619     valid values
3620    
3621     * test/test_load.py (TestLabelLayer): New. Test loading (and
3622     indirectly saving) of maps with labels.
3623    
3624     2003-12-22 Bernhard Herzog <[email protected]>
3625    
3626 bh 2033 * Thuban/UI/tableview.py (TableGrid.OnDestroy)
3627     (TableGrid.__init__): Handle EVT_WINDOW_DESTROY in the grid to
3628     unsubscribe all subscribers.
3629     (LayerTableFrame.OnDestroy): Do not unsubscribe any messages from
3630     self.grid since it may already have been destroyed.
3631     Fixes RT #2256
3632    
3633 bh 2031 2003-12-19 Bernhard Herzog <[email protected]>
3634    
3635     * po/fr.po, po/es.po: Updated translations from Daniel Calvelo
3636    
3637 bh 2028 2003-12-16 Bernhard Herzog <[email protected]>
3638 silke 2029
3639     * debian/bitmappath.patch, debian/setup.py.patch:
3640     added to ensure compliance with FHS for debian
3641     * debian/rules, debian/changelog:
3642     added patches in rules to ensure compliance with FHS for debian
3643 bh 2028
3644 silke 2029 2003-12-16 Bernhard Herzog <[email protected]>
3645    
3646 bh 2028 * po/Makefile (mo): Make the output a bit nicer so that it prints
3647     statistics about the translations. Add a comment how produce even
3648     nicer statistics with sed.
3649    
3650 frank 2026 2003-12-09 Frank Koormann <[email protected]>
3651    
3652     * Resources/Projections/defaults.proj:
3653     French projection sample with correct accents (UNICODE).
3654    
3655 bh 2025 2003-12-05 Bernhard Herzog <[email protected]>
3656    
3657     * MANIFEST.in: Add the devtools directory
3658    
3659     * setup.py (setup call): Use license instead of licence. This
3660     silences a deprecation warning on Python 2.3
3661    
3662 frank 2022 2003-12-05 Frank Koormann <[email protected]>
3663    
3664 frank 2023 Documentation synced with 1.0rc1
3665    
3666     * Doc/manual/thuban-manual.xml:
3667     Minor formatting changes and references to database layers .
3668     Introduction.Internationalization: New section on i18n.
3669     MapManagement.AddingandRemovingLayers: Added item on database layers.
3670     MapManagement.TheLegend: Added section and screenshot on popup menu.
3671     ProjectionManagement: Updated screenshot and sentence on EPSG.
3672     Appendix.SupportedDataSources: Added PostGIS.
3673     Appendix.WorkingwithPostGIS: New section.
3674    
3675     * Doc/manual/images/6_projection.png: Updated screenshot including
3676     EPSG checkboxes.
3677    
3678     * Doc/manual/images/3_5_popup_menu.png: New, popup menu screenshot.
3679    
3680     * Doc/manual/images/app_postgis_add_layer.png,
3681     Doc/manual/images/app_postgis_db_add.png,
3682     Doc/manual/images/app_postgis_db_management.png:
3683     New screenshots focussing on database layers
3684    
3685     2003-12-05 Frank Koormann <[email protected]>
3686    
3687 frank 2022 * Thuban/UI/projdialog.py (load_user_proj): If user.proj is missing
3688     write warning to stderr instead of rising a warning dialog
3689    
3690 bh 2016 2003-12-03 Bernhard Herzog <[email protected]>
3691    
3692 bh 2021 Fix for RT #2243
3693    
3694 bh 2020 * Thuban/UI/mainwindow.py (MainWindow.has_selected_shape_layer):
3695     New. Like has_selected_layer but for shape layers only
3696     (_has_selected_shape_layer): New. Like _has_selected_layer but for
3697     shape layers only
3698     (layer_show_table command, layer_jointable command): Use these
3699     commands should only be available for shape layers
3700    
3701     2003-12-03 Bernhard Herzog <[email protected]>
3702    
3703 bh 2018 * Thuban/UI/mainwindow.py (MainWindow.Unsubscribe): Deal with
3704     publishers that are wx objects and may have been destroyed by wx
3705     already. Fixes RT #2242.
3706    
3707     2003-12-03 Bernhard Herzog <[email protected]>
3708    
3709 bh 2016 * po/ru.po: Updates from Alex Shevlakov
3710    
3711 silke 2013 2003-12-03 Silke Reimer <silkeintevation.de>
3712    
3713     * debian/control, debian/changelog: Added gdal-support to
3714     debian package, updated to new thuban version
3715    
3716    
3717 bh 2012 2003-12-03 Bernhard Herzog <[email protected]>
3718    
3719     * Thuban/Lib/version.py: New. Module for version number
3720     manipulations. The version of make_tuple here also deals better
3721     with more unusual version number strings, such as e.g.
3722     "1.2+cvs20031111"
3723    
3724     * Thuban/version.py (make_tuple): Removed. It's now in
3725     Thuban.Lib.version. Use that implementation instead.
3726    
3727     * test/test_lib_version.py: New. Tests for Thuban/Lib/version.py
3728    
3729 bh 2005 2003-12-02 Bernhard Herzog <[email protected]>
3730    
3731 bh 2010 * MANIFEST.in: Add debian files
3732    
3733 bh 2008 * setup.py (setup call): Add packages for the Extensions so that
3734     they're installed too
3735     (data_files): Add READMEs and sample data from some Extensions
3736    
3737     * NEWS: Add note about the extensions in binary packages
3738    
3739     2003-12-02 Bernhard Herzog <[email protected]>
3740    
3741 bh 2005 * Thuban/Model/save.py (SessionSaver.write_session): Save files
3742     with the thuban-1.0rc1
3743    
3744     * Thuban/Model/load.py (SessionLoader.__init__): Recognize the
3745     thuban-1.0rc1 namespace too
3746    
3747     * test/test_save.py (SaveSessionTest.dtd)
3748     (SaveSessionTest.testEmptySession)
3749     (SaveSessionTest.testSingleLayer)
3750     (SaveSessionTest.testLayerProjection)
3751     (SaveSessionTest.testRasterLayer)
3752     (SaveSessionTest.testClassifiedLayer)
3753     (SaveSessionTest.test_dbf_table)
3754     (SaveSessionTest.test_joined_table)
3755     (SaveSessionTest.test_save_postgis): Update to thuban-1.0rc1
3756     namespace
3757    
3758     * test/test_load.py (LoadSessionTest.dtd): Update to thuban-1.0rc1
3759     namespace
3760     (TestSingleLayer.file_contents)
3761     (TestNonAsciiColumnName.file_contents)
3762     (TestLayerVisibility.file_contents)
3763     (TestClassification.file_contents, TestLabels.file_contents)
3764     (TestLayerProjection.file_contents)
3765     (TestRasterLayer.file_contents, TestJoinedTable.file_contents)
3766     (TestPostGISLayer.file_contents)
3767     (TestPostGISLayerPassword.file_contents)
3768     (TestLoadError.file_contents, TestLoadError.test): Update to
3769     thuban-1.0rc1 namespace
3770    
3771 bh 1996 2003-12-01 Bernhard Herzog <[email protected]>
3772    
3773 bh 2003 * setup.py (proj4_prefix, wx_prefix, gdal_prefix): Fix these for
3774     nt to better match Intevation's current w32 setup
3775    
3776 bh 2001 * HOWTO-Release: Add note about updating MANIFEST.in
3777    
3778     * MANIFEST.in: Add the Extensions
3779    
3780 bh 1998 * NEWS: Update for 1.0rc1
3781    
3782     2003-12-01 Bernhard Herzog <[email protected]>
3783    
3784 bh 1996 * Thuban/UI/mainwindow.py (MainWindow.AddLayer): Change the wild
3785     cards for the dialog so that shapefiles ending in all uppercase
3786     SHP are listed too
3787    
3788 bh 1988 2003-11-28 Bernhard Herzog <[email protected]>
3789    
3790 bh 1996 * Thuban/version.py (longversion): Update to 1.0rc1
3791    
3792     * setup.py (setup call): Update version to 1.0rc1. Use the
3793     [email protected] email address as author email instead of my
3794     personal one.
3795    
3796     2003-11-28 Bernhard Herzog <[email protected]>
3797    
3798 bh 1992 * po/de.po: Update german translation.
3799    
3800     2003-11-28 Bernhard Herzog <[email protected]>
3801    
3802 bh 1990 Unify the filenames stored in .thuban files so that the .thuban
3803     files are more platform independend
3804    
3805     * Thuban/Model/save.py (unify_filename): New. Unify filenames so
3806     that they can be used on both windows and unix
3807     (SessionSaver.prepare_filename): New. Handle all filename
3808     transformations for filenames stored in the thuban file
3809     (SessionSaver.write_data_containers, SessionSaver.write_layer):
3810     Use prepare_filename
3811    
3812     * test/test_save.py (SaveSessionTest.testSingleLayer)
3813     (SaveSessionTest.testLayerProjection)
3814     (SaveSessionTest.testRasterLayer)
3815     (SaveSessionTest.testClassifiedLayer)
3816     (SaveSessionTest.test_dbf_table)
3817     (SaveSessionTest.test_joined_table): Filenames are always stored
3818     with slashes on all currently supported platforms so adapt all
3819     tests to this
3820    
3821     * test/test_load.py (LoadSessionTest.filenames): With the new
3822     filename scheme the filenames in the tests should be
3823     understandable on all currently supported platforms so we turn
3824     this into an empty list because we don't have to normalize them
3825     anymore
3826    
3827     2003-11-28 Bernhard Herzog <[email protected]>
3828    
3829 bh 1988 * test/test_layer.py (TestLayer.test_arc_layer_with_projection):
3830     Add the ellipsoid to the projection since some Proj versions
3831     complain if it's missing.
3832    
3833 bh 1984 2003-11-27 Bernhard Herzog <[email protected]>
3834    
3835     Corect some bounding box projection problems
3836    
3837     * Thuban/Model/proj.py (Projection.InverseBBox): New. Inverse
3838     version of ForwardBBox
3839     (Projection._transform_bbox): New. common implementation of
3840     ForwardBBox and InverseBBox
3841     (Projection.ForwardBBox): Use _transform_bbox.
3842    
3843     * test/test_proj.py (TestProjection.test): Add test for
3844     InverseBBox
3845    
3846     * Thuban/Model/layer.py (Layer.LatLongBoundingBox)
3847     (Layer.ShapesBoundingBox, RasterLayer.LatLongBoundingBox): Use the
3848     new InverseBBox method to determine the unprojected bounding box
3849     (Layer.ShapesInRegion): Use the ForwardBBox method to project the
3850     bbox.
3851    
3852     * test/test_layer.py (TestLayer.test_point_layer_with_projection):
3853     Removed.
3854     (TestLayer.test_arc_layer_with_projection): New. This test is
3855     better able to test whether bounding boxes are projected correctly
3856     than test_point_layer_with_projection
3857    
3858 bh 1986 * Thuban/UI/viewport.py (ViewPort.map_projection_changed): Use
3859     InverseBBox to unproject bboxes
3860    
3861 bh 1975 2003-11-25 Bernhard Herzog <[email protected]>
3862    
3863 bh 1981 * Thuban/UI/about.py (About.__init__): Make sure we have ASCII
3864     source code.
3865    
3866     2003-11-25 Bernhard Herzog <[email protected]>
3867    
3868 bh 1979 * Thuban/Model/layer.py (Layer.__getattr__): Removed. It was only
3869     there for backwards compatibility and all code relying on that
3870     should have been updated by now.
3871    
3872     2003-11-25 Bernhard Herzog <[email protected]>
3873    
3874 bh 1977 * test/test_load.py (TestClassification.test): Add the missing
3875     round trip test.
3876     (TestClassification.file_contents): Update to the newest file
3877     format
3878    
3879     2003-11-25 Bernhard Herzog <[email protected]>
3880    
3881 bh 1975 Add very experimental (and possibly dangerous) extension to draw
3882     polygons:
3883    
3884     * Extensions/drawshape/README: New. Brief installation
3885     instructions
3886    
3887     * Extensions/drawshape/drawshape.py: New. Implementation of the
3888     drawshape extensions
3889    
3890     * Extensions/drawshape/patch.diff: Patch to apply before the
3891     extension can be used.
3892    
3893 bh 1971 2003-11-24 Bernhard Herzog <[email protected]>
3894    
3895 bh 1973 * Thuban/Model/data.py (ShapefileStore._open_shapefile)
3896     (ShapefileStore.__init__): Factor opening the shapefile into a
3897     separate method (the new _open_shapefile). This makes the code a
3898     bit more readable but the real reason is that it makes some evil
3899     hacks easier. :-)
3900    
3901     2003-11-24 Bernhard Herzog <[email protected]>
3902    
3903 bh 1971 * Thuban/Model/load.py (SessionLoader.check_attrs): If no
3904     converter is specified for an attribute assume it's a string
3905     containing only Latin1 characters. Update doc-string accordingly.
3906     This change should fix many places where unicode objects might
3907     accidentally enter Thuban.
3908    
3909     * test/test_load.py (TestNonAsciiColumnName): New test to check
3910     what happens with column names in DBF files that contain non-ascii
3911     characters
3912    
3913 bh 1969 2003-11-21 Bernhard Herzog <[email protected]>
3914    
3915     Enable the experimental attribute editing again and introduce a
3916     command line switch to actually activate it
3917    
3918     * Thuban/UI/main.py (options): New. Container for options set on
3919     the commmand line
3920     (main): Add the --enable-attribute-editing flag.
3921    
3922     * Thuban/UI/identifyview.py (IdentifyView.__init__): If attribute
3923     editing is enabled use the grid ctrl which allows editing of the
3924     values
3925    
3926     * Thuban/Model/transientdb.py (AutoTransientTable.write_record):
3927     New. Just delegate this to the underlying table.
3928    
3929 bh 1967 2003-11-20 Bernhard Herzog <[email protected]>
3930    
3931     * test/test_proj.py (ProjFileReadTests.test_read_unreadable_file):
3932     Skip this test if run under non-posix systems since it only works
3933     there
3934    
3935 bh 1960 2003-11-19 Bernhard Herzog <[email protected]>
3936    
3937 bh 1965 * Thuban/Model/resource.py: Rework the way gdal support is
3938     determined so that we can give a reason in the about why gdal is
3939     not supported.
3940     (gdal_support_status): New. Variable holding a string with the
3941     reason for no gdal support
3942    
3943     * Thuban/UI/about.py (About.__init__): Add the reason why gdal is
3944     not supported to the message
3945    
3946     2003-11-19 Bernhard Herzog <[email protected]>
3947    
3948 bh 1963 Remove the old table interface and its test cases
3949    
3950     * Thuban/Model/table.py (OldTableInterfaceMixin): Removed.
3951     (DBFTable, MemoryTable): Do not derive from OldTableInterfaceMixin
3952     anymore
3953    
3954     * Thuban/Model/transientdb.py (TransientTableBase)
3955     (AutoTransientTable): Do not derive from OldTableInterfaceMixin
3956     anymore
3957    
3958     * test/test_table.py: Removed since the old interface it tests is
3959     gone.
3960    
3961     * test/runtests.py (main): The old table interface is gone and
3962     with it the deprecation warnings so remove the code that turns
3963     these warnings into errors
3964    
3965     2003-11-19 Bernhard Herzog <[email protected]>
3966    
3967 bh 1960 * test/test_table.py: Revert to revision 1.5 again. Changing the
3968     tests to use the new table interface is completely wrong since the
3969     whole purpose of the tests in this module is to test the old
3970     interface.
3971    
3972 bh 1954 2003-11-18 Bernhard Herzog <[email protected]>
3973    
3974 bh 1958 * Thuban/Model/postgisdb.py (PostGISConnection.MatchesParameters):
3975     New. Test whether the connection matches a set of connection
3976     parameters
3977    
3978     * Thuban/UI/dbdialog.py (DBFrame.conns_changed): Fix doc-string
3979     (DBFrame.OnAdd): Use the new MatchesParameters method when looking
3980     for existing connections with the same parameters and break out of
3981     the loop correctly.
3982    
3983     * test/test_postgis_db.py (TestBriefDescription)
3984     (TestPostGISSimple.test_brief_description): Rename
3985     TestBriefDescription to TestPostGISSimple and the test method to
3986     test_brief_description so that we can add more test methods.
3987     (TestPostGISSimple.test_matches_parameters): New. Test the new
3988     MatchesParameters method
3989    
3990     2003-11-18 Bernhard Herzog <[email protected]>
3991    
3992 bh 1960 * Thuban/Lib/connector.py (Publisher): Introduce a new flag,
3993 bh 1954 _was_destroyed, to indicate whether an publisher instance has
3994     already been destroyed.
3995     (Publisher.Unsubscribe): Only disconnect if the publisher has not
3996     been destroyed yet.
3997     (Publisher.Destroy): Set the _was_destroyed flag to true.
3998    
3999     * test/test_connector.py
4000     (TestPublisher.test_unsubscribe_after_destroy): New. Test that
4001     calling Unsubscribe after Destroy doesn't raise an exception
4002    
4003 bh 1951 2003-11-14 Bernhard Herzog <[email protected]>
4004    
4005     * Thuban/UI/identifyview.py (IdentifyView.selected_shape): Fix
4006     typo in doc-string
4007    
4008 bh 1949 2003-11-13 Bernhard Herzog <[email protected]>
4009    
4010     Quote table and column names properly for postgis.
4011    
4012     * Thuban/Model/postgisdb.py (quote_identifier): New. Function to
4013     quote an identifier for use in an sql statement
4014     (PostGISColumn.__init__): Add the quoted_name attribute
4015     (PostGISTable.__init__): New instance variable quoted_tablename
4016     (PostGISTable._fetch_table_information): Use the quoted table
4017     name. New isntance variable quoted_geo_col with a quoted version
4018     of geometry_column
4019     (PostGISTable.NumRows, PostGISTable.RowIdToOrdinal)
4020     (PostGISTable.RowOrdinalToId): Use the quoted table name
4021     (PostGISTable.ReadValue, PostGISTable.ValueRange)
4022     (PostGISTable.UniqueValues, PostGISTable.SimpleQuery)
4023     (PostGISShapeStore.BoundingBox, PostGISShapeStore.Shape)
4024     (PostGISShapeStore.AllShapes, PostGISShapeStore.ShapesInRegion):
4025     Use quoted table and column names
4026    
4027     * test/test_postgis_db.py (TestPostGISSpecialCases)
4028     (TestPostGISIgnoredColumns): Rename the class to
4029     TestPostGISSpecialCases because that better describes the new
4030     cases
4031     (TestPostGISSpecialCases.test_unsupported_types)
4032     (TestPostGISSpecialCases.test): Rename the method to
4033     test_unsupported_types because we need a more descriptive name now
4034     that there are more methods
4035     (TestPostGISSpecialCases.test_table_name_quoting)
4036     (TestPostGISSpecialCases.test_column_name_quoting)
4037     (TestPostGISSpecialCases.test_shapestore_name_quoting): New test
4038     cases to test quoting of table and column names in PostGISTable
4039     and PostGISShapeStore
4040    
4041     * test/postgissupport.py
4042     (skip_if_addgeometrycolumn_does_not_use_quote_ident): New. Skip if
4043     AddGeometryColumn desn't support table or column names with sapces
4044     or double quotes
4045    
4046 jan 1945 2003-11-12 Jan-Oliver Wagner <[email protected]>
4047    
4048     * Extensions/wms/__init__.py: New: Init to make this
4049     directory a package.
4050    
4051     * Extensions/wms/wms.py: New: Provide layers via OGC WMS.
4052    
4053 bh 1932 2003-11-11 Bernhard Herzog <[email protected]>
4054    
4055 bh 1942 * Thuban/Model/resource.py (EPSG_DEPRECATED_PROJ_FILE): New.
4056     Constant for the file woth deprecated epsg projections
4057     (get_system_proj_file): Update doc-string
4058    
4059     * Thuban/UI/projdialog.py (ProjFrame.build_dialog): Add a space
4060     above the EPS widgets, introduce a check box for the deprecated
4061     eps projections and a label for the epsg widgets
4062     (ProjFrame._OnShowEPSG): Handle the deprecated EPSG projections
4063     too
4064    
4065     2003-11-11 Bernhard Herzog <[email protected]>
4066    
4067 bh 1939 Avoid warnings when run under Python 2.3
4068    
4069     * Thuban/UI/baserenderer.py (BaseRenderer.draw_point_shape)
4070     (BaseRenderer.draw_label_layer): Coordinates must be ints.
4071    
4072     * Thuban/UI/renderer.py (MapRenderer.make_point): Turn this into a
4073     real method so that we can convert to int.
4074     (MapRenderer.label_font): The font size mist be an int.
4075    
4076     * Thuban/UI/common.py (Color2wxColour): The color values must be
4077     ints. Also, remove the unnecessary asserts.
4078    
4079     * test/test_load_0_8.py (TestUnicodeStrings.file_contents)
4080     (TestUnicodeStrings.test): Python source code should not contain
4081     non-ascii characters unless an encoding is specified in the file.
4082     Therefore use \x escapes in the string literals for non-ascii
4083     characters.
4084    
4085     2003-11-11 Bernhard Herzog <[email protected]>
4086    
4087 bh 1934 * Thuban/Model/resource.py (get_system_proj_file): Add a filename
4088     parameter so that this function can be used for all proj files in
4089     Resource/Projections
4090     (DEFAULT_PROJ_FILE, EPSG_PROJ_FILE): New. Predefined filenames for
4091     get_system_proj_file
4092    
4093     * Thuban/UI/projdialog.py (ProjFrame.__init__): Instead of one
4094     ProjFile self.__sysProjFile use a dictionary of system ProjFile
4095     objects self._sys_proj_files
4096     (ProjFrame.build_dialog): Adapt to the new changes in the
4097     ProjectionList constructor. Add a check button to toggle whether
4098     EPSG projections are shown
4099     (ProjFrame._OnShowEPSG): New. Handler for the epsg check button
4100     events.
4101     (ProjFrame.load_user_proj, ProjFrame.load_system_proj): Only show
4102     the busy cursor if the files have not yet been loaded by the
4103     dialog.
4104     (ProjFrame.load_system_proj): Add a parameter for the name of the
4105     proj file. Maintain the dictionary of system projections
4106     self._sys_proj_files
4107    
4108     * Thuban/UI/projlist.py (ProjectionList): Merge the system_projs,
4109     user_projs parameters into one parameter proj_files which is a
4110     list of proj files.
4111     (ProjectionList._subscribe_proj_files)
4112     (ProjectionList._unsubscribe_proj_files): New. Move
4113     subscription/unsubscription of projfile messages to separate
4114     methods
4115     (ProjectionList.Destroy): The unsubscribe is now done in
4116     _unsubscribe_proj_files
4117     (ProjectionList.update_projections): We now have a list of proj
4118     file objects
4119     (ProjectionList.SetProjFiles): New method to set a new list of
4120     proj file objects
4121    
4122     * test/test_proj.py (ProjFileReadTests.test_get_system_proj_file):
4123     Specify explicitly which system proj file to load.
4124    
4125     2003-11-11 Bernhard Herzog <[email protected]>
4126    
4127 bh 1932 * Thuban/Model/load.py (SessionLoader.Destroy): New. Clear all
4128     instance variables to cut cyclic references. The GC would have
4129     collected the loader eventually but it can happen that it doesn't
4130     run at all until thuban is closed (2.3 but not 2.2 tries a bit
4131     harder and forces a collection when the interpreter terminates)
4132     (load_session): Call the handler's Destroy method to make sure
4133     that it gets garbage collected early. Otherwise it will be
4134     collected very late if at all and it holds some references to e.g.
4135     shapestores and the session which can lead to leaks (of e.g. the
4136     temporary files)
4137    
4138     * test/test_load.py (TestSingleLayer.test_leak): New. test for the
4139     resource leak in load_session
4140    
4141 bh 1929 2003-11-10 Bernhard Herzog <[email protected]>
4142    
4143     * Thuban/UI/baserenderer.py: Add a way to specify how layers in
4144     extensions are to be rendered.
4145     (_renderer_extensions): New. List with renderer for layers in
4146     extensions
4147     (add_renderer_extension): New. Add a renderer extension
4148     (init_renderer_extensions): New. Init the renderer extensions
4149     (BaseRenderer.render_map_incrementally): Search
4150     _renderer_extensions for how to draw unknown layer types
4151     (BaseRenderer.draw_raster_data): Add format parameter so that
4152     formats other than BMP can be drawn
4153     (BaseRenderer.draw_raster_layer): Pass an explicit format to
4154     draw_raster_data
4155    
4156     * Thuban/UI/renderer.py (raster_format_map): New. Mapping form the
4157     strings of the format parameter of draw_raster_data method to wx
4158     constants
4159     (MapRenderer.draw_raster_data): Add the format parameter and use
4160     raster_format_map to map it to the right wxwindows constant for
4161     wxImageFromStream
4162    
4163     * test/test_baserenderer.py (SimpleRenderer.draw_raster_data): Add
4164     the format parameter and record it
4165     (TestBaseRenderer.test_raster_no_projection): check the format
4166     paramter of the draw_raster_data method
4167     (TestBaseRenderer.test_renderer_extension): New. Test the renderer
4168     extension facility
4169    
4170 bh 1925 2003-11-07 Bernhard Herzog <[email protected]>
4171    
4172     Tweak the usage of the sqlite database to make common use cases
4173     more responsive. In most cases copying the data to the sqlite
4174     database takes so long that using sqlite doesn't have enough
4175     advantages.
4176    
4177     * Thuban/Model/transientdb.py (TransientTableBase.ValueRange): Add
4178     comments about performance and query the min and max in separate
4179     statements because only that way will indexes be used.
4180     (TransientTableBase.UniqueValues): Add some comments about
4181     performance.
4182     (AutoTransientTable.ValueRange, AutoTransientTable.UniqueValues):
4183     Do not copy the data to the transient DB but use the transient
4184     copy if it exists. See the new comments for the performance trade
4185     offs
4186    
4187     * test/test_transientdb.py
4188     (TestTransientTable.test_auto_transient_table): Make sure that the
4189     data is copied to the transient database at some point.
4190    
4191 bh 1913 2003-11-03 Bernhard Herzog <[email protected]>
4192    
4193 bh 1922 * Thuban/Model/data.py (ShapefileStore.ShapesInRegion): Bind some
4194     globals to locals so that it's a bit faster
4195    
4196     2003-11-03 Bernhard Herzog <[email protected]>
4197    
4198 bh 1920 * Thuban/UI/baserenderer.py
4199     (BaseRenderer.draw_shape_layer_incrementally): Use the ReadValue
4200     method. ReadValue is faster than ReadRowAsDict since it only reads
4201     one cell especially now that the dbf file objects actually
4202     implement it.
4203    
4204     * Thuban/Model/table.py (DBFTable.ReadValue): Use the new
4205     read_attribute method of the dbf objects
4206    
4207     2003-11-03 Bernhard Herzog <[email protected]>
4208    
4209 bh 1916 * Extensions/profiling/profiling.py (popup_dialog_box): New config
4210     variable to indicate whether the result should be shown in a
4211     dialog box
4212     (profile_screen_renderer, time_screen_renderer): Only show a
4213     dialog box if popup_dialog_box is true.
4214     (profile_screen_renderer): Flush stdout after the printing the
4215     first part of the "profiling..." message
4216    
4217     * Thuban/UI/baserenderer.py
4218     (BaseRenderer.draw_shape_layer_incrementally): Cache the pens and
4219     brushes for the groups so that they're not created over and over
4220     again
4221    
4222 bh 1913 * Thuban/Model/classification.py (Classification.__getattr__)
4223     (Classification._compile_classification)
4224     (Classification._clear_compiled_classification): New. Methods to
4225     manage a 'compiled' representation of the classification groups
4226     which is created on demand
4227     (Classification.InsertGroup, Classification.RemoveGroup)
4228     (Classification.ReplaceGroup): reset the compiled representation
4229     (Classification.FindGroup): Use the compiled representation to
4230     find the matching group
4231     (ClassGroupRange.GetRangeTuple): New. Return the range as a tuple
4232    
4233 bh 1904 2003-10-31 Bernhard Herzog <[email protected]>
4234    
4235 bh 1911 * Thuban/Model/classification.py (Classification.SetDefaultGroup):
4236     Send a CLASS_CHANGED message
4237     (Classification.RemoveGroup): Send a CLASS_CHANGED message and do
4238     not return the removed group since it wasn't used.
4239    
4240     * test/test_classification.py
4241     (TestClassification.test_set_default_group): New. Test the
4242     SetDefaultGroup method
4243     (TestClassification.test_insert_group): New. Test the InsertGroup
4244     method
4245     (TestClassification.test_remove_group): New. Test the RemoveGroup
4246     method
4247     (TestClassification.test_replace_group): New. Test the
4248     ReplaceGroup method
4249    
4250     2003-10-31 Bernhard Herzog <[email protected]>
4251    
4252 bh 1908 * test/test_classification.py (TestClassification.setUp):
4253     Subscribe to the CLASS_CHANGED messages
4254     (TestClassification.tearDown): New. Destroy the classification
4255     properly
4256     (TestClassification.test_defaults): Add tests for the default line
4257     width and whether no messages were sent yet
4258     (TestClassification.test_set_default_properties): Add tests for
4259     messages and setting the default line width
4260     (TestClassification.test_add_singleton)
4261     (TestClassification.test_add_range)
4262     (TestClassification.test_multiple_groups): Add tests for messages
4263    
4264     2003-10-31 Bernhard Herzog <[email protected]>
4265    
4266 bh 1906 Some more refactoring in preparation for new tests:
4267    
4268     * test/test_classification.py (TestClassification.setUp): New.
4269     Instantiate the classification here. Update the test methods
4270     accordingly.
4271     (TestClassification.test_multiple_groups): Make sure that the two
4272     singletons matching 1 are considered different.
4273    
4274     2003-10-31 Bernhard Herzog <[email protected]>
4275    
4276 bh 1904 * test/test_classification.py (red, green, blue): New. These
4277     constants were used in several cases. Update the relevant methods.
4278     (TestClassification.test_defaults)
4279     (TestClassification.test_set_default_properties)
4280     (TestClassification.test_add_singleton)
4281     (TestClassification.test_add_range)
4282     (TestClassification.test_multiple_groups)
4283     (TestClassification.test_deepcopy): New. These were formerly all
4284     part of the single method test.
4285     (TestClassification.test_deepcopy): Removed.
4286     (TestClassIterator): Removed. The test case is now a method of
4287     TestClassification since it tests part of the public interface of
4288     Classification
4289     (TestClassification.test_iterator): New. Used to be
4290     TestClassIterator effectively
4291    
4292 jan 1902 2003-10-31 Jan-Oliver Wagner <[email protected]>
4293    
4294     GUIfied the functions of the profiling extension.
4295    
4296     * /Extensions/profiling/__init__.py: New: Init to make this
4297     directory a package.
4298    
4299     * Extensions/profiling/profiling.py: Moved menu entries to
4300     the Extensions menu. Applied _() for strings.
4301     (profile_screen_renderer): Catch the detailed printout and present
4302     it in a dialog.
4303 bh 1904 (time_screen_renderer): Raise a dialog to present the result instead
4304 jan 1902 of printing it to stdout.
4305    
4306 bh 1897 2003-10-31 Bernhard Herzog <[email protected]>
4307    
4308 bh 1899 * test/test_classification.py (TestClassGroupProperties)
4309     (TestClassGroup, TestClassGroupDefault, TestClassGroupRange)
4310     (TestClassGroupSingleton, TestClassIterator, TestClassification):
4311     Split TestClassification into several classes, one for each class
4312     being tested. TestClassification itself now only tests
4313     Classification. This split makes changes to the tests a bit easier
4314    
4315     2003-10-31 Bernhard Herzog <[email protected]>
4316    
4317 bh 1897 * Extensions/profiling/profiling.py: New. Extension to measure
4318     Thuban performance
4319    
4320 frank 1895 2003-10-31 Frank Koormann <[email protected]>
4321    
4322     Added two items to legend popup menu: Remove Layer and Show Layer Table
4323    
4324     * Thuban/UI/legend.py (LegendPanel._OnRemoveLayer,
4325     LegendPanel._OnShowTable): New event handlers, call the corresponding
4326     mainwindow methods.
4327     (LegendTree._OnRightClick): Added items to popup menu.
4328    
4329 bh 1894 2003-10-30 Bernhard Herzog <[email protected]>
4330    
4331     * Thuban/UI/dialogs.py (ThubanFrame.__init__): Handle
4332     EVT_WINDOW_DESTROY
4333     (ThubanFrame.OnDestroy): New. Handler for EVT_WINDOW_DESTROY. Does
4334     nothing but is convenient for the derived classes.
4335    
4336     * Thuban/UI/tableview.py
4337     (TableFrame.OnDestroy, LayerTableFrame.OnDestroy): New.
4338     Unsubscribe the messages here not in OnClose because that might
4339     get called multiple times. Fixes RT #2196
4340     (TableFrame.OnClose, LayerTableFrame.OnClose): Removed. Not needed
4341     anymore.
4342    
4343     * README: Update the minimum requirement for wxPython. Since we
4344     now use the EVT_WINDOW_DESTROY event, we need at least 2.4.0.4,
4345     the version in which that was introduced for all platforms
4346    
4347 frank 1890 2003-10-30 Frank Koormann <[email protected]>
4348    
4349     * Thuban/UI/join.py (JoinDialog.OnJoin): Wrapped the major parts of
4350     the join process in a ThubanBeginBusyCursor, ThubanEndBusyCursor
4351     frame.
4352    
4353 jan 1889 2003-10-30 Jan-Oliver Wagner <[email protected]>
4354    
4355     Improved APR import extension, added further EPSG definitions
4356     and some cleanup regarding string class.
4357    
4358     * test/test_proj.py (TestProjection.test_get_projection_units_geo):
4359     Added test for alias 'longlat'.
4360    
4361     * Resources/Projections/epsg-deprecated.proj: New. Contains
4362     deprecated EPSG definitions.
4363    
4364     * Extensions/importAPR/odb.py (ODBBaseObject.TreeInfo): Added
4365     the variable names for objects.
4366    
4367     * Extensions/importAPR/apr.py (APR_BLnSym, APR_BMkSym, APR_BShSym): New.
4368     Copied from importAPR and provided with documentation.
4369    
4370     * Extensions/importAPR/importAPR.py (APR_BLnSym, APR_BMkSym, APR_BShSym):
4371     Moved to apr.py.
4372     (APR_View): Added object ref 'ITheme'.
4373    
4374     * Thuban/Lib/fileutil.py, Thuban/UI/proj4dialog.py: Replaced string
4375     split function by corresponding use of the string class method.
4376    
4377     * Thuban/Model/xmlwriter.py: Replaced string replace function by
4378     corresponding string method.
4379    
4380 bh 1880 2003-10-29 Bernhard Herzog <[email protected]>
4381    
4382     * Thuban/UI/baserenderer.py
4383     (BaseRenderer.draw_shape_layer_incrementally): Speed up the
4384     special case of a classification that only has the default group
4385    
4386 bh 1868 2003-10-27 Bernhard Herzog <[email protected]>
4387    
4388 bh 1878 * po/fr.po, po/es.po: Updated translations from Daniel Calvelo
4389    
4390 bh 1876 * po/de.po: Update.
4391    
4392     * Thuban/UI/application.py
4393     (ThubanApplication.ShowExceptionDialog): Handle translation of the
4394     dialog message properly
4395    
4396     2003-10-27 Bernhard Herzog <[email protected]>
4397    
4398 bh 1873 Rework how localization works so that we use wx's translation
4399     functions when running Thuban as a normal application but not when
4400     we don't need any UI, such as in the test suite. See the comment
4401     in Thuban/__init__.py for details
4402    
4403     * Thuban/__init__.py (_): Add one level of indirection to make the
4404     translation handling more flexible and to make it possible to use
4405     either wx's translation services or not.
4406     (gettext_identity, translation_function_installed)
4407     (install_translation_function): New function to help with this
4408    
4409     * Thuban/UI/__init__.py: Install the wx specific translation
4410     function if it's OK to do that
4411    
4412     * test/support.py (initthuban): Install a dummy translation
4413     function so that importing Thuban.UI doesn't install a wx specific
4414     one for which would need to import wxPython
4415    
4416     2003-10-27 Bernhard Herzog <[email protected]>
4417    
4418 bh 1870 * HOWTO-Release: Source archives should be created first and the
4419     binary packages should be created from the source archives.
4420     There's an official debian package now so there's no need to test
4421     the rpm on debian anymore
4422    
4423     2003-10-27 Bernhard Herzog <[email protected]>
4424    
4425 bh 1868 Several rendering changes:
4426    
4427     - Render the selection into a separate bitmap so that only that
4428     bitmap needs to be redrawn when the selection changes
4429    
4430     - Render incrementally showing previews and allowing interaction
4431     before rendering is complete
4432    
4433     - Update the renderer interface a bit. Most parameters of
4434     RenderMap are now parameters of the constructor
4435    
4436     * Thuban/UI/baserenderer.py (BaseRenderer.__init__): Add the map
4437     and the update region as parameters. Update the doc-string
4438     (BaseRenderer.render_map_incrementally): New. Generator function
4439     to renders the map incrementally
4440     (BaseRenderer.render_map): Remove the map argument (it's now in
4441     the constructor) and simply iterate over the
4442     render_map_incrementally generator to draw the map.
4443     (BaseRenderer.draw_shape_layer_incrementally)
4444     (BaseRenderer.draw_shape_layer): Renamed to
4445     draw_shape_layer_incrementally and changed into a generator that
4446     yields True every 500 shapes. Used by render_map_incrementally to
4447     render shape layers incrementally
4448    
4449     * Thuban/UI/renderer.py (ScreenRenderer.RenderMap): Removed the
4450     map and region parameters which are now in the constructor
4451     (ScreenRenderer.RenderMapIncrementally): New. Public frontend for
4452     the inherited render_map_incrementally.
4453     (BaseRenderer.draw_shape_layer): Removed.
4454     (ScreenRenderer.draw_selection_incrementally): New. The selection
4455     drawing part of the removed draw_shape_layer as a generator
4456     (ScreenRenderer.layer_shapes): Update because of the region
4457     parameter change
4458     (ExportRenderer.__init__): New. Extend the inherited constructor
4459     with the destination region for the drawing
4460     (ExportRenderer.RenderMap): Removed the map and region parameters
4461     which are now in the constructor
4462    
4463     * Thuban/UI/view.py (MapCanvas.PreviewBitmap): New. Return a
4464     bitmap suitable for a preview in a tool
4465     (CanvasPanTool.MouseMove): Use the PreviewBitmap method to get the
4466     bitmap
4467     (MapPrintout.draw_on_dc): Adapt to new renderer interface
4468     (MapCanvas.OnPaint): Handle drawing the selection bitmap if it
4469     exists
4470     (MapCanvas.OnIdle): Update the logic to deal with incremental
4471     rendering and the selection bitmap
4472     (MapCanvas._do_redraw): Handle the instantiation of the render
4473     iterator and the redraws during rendering
4474     (MapCanvas._render_iterator): New. Generator to incrementally
4475     redraw both bitmaps
4476     (MapCanvas.Export): Adapt to new renderer interface.
4477     (MapCanvas.full_redraw): Reset the selection bitmap and the
4478     renderer iterator too
4479     (MapCanvas.redraw_selection): New. Force a redraw of the selection
4480     bitmap
4481     (MapCanvas.shape_selected): Only redraw the selection bitmap
4482    
4483     * test/test_baserenderer.py
4484     (TestBaseRenderer.test_polygon_no_projection)
4485     (TestBaseRenderer.test_raster_no_projection)
4486     (TestBaseRenderer.test_point_map_projection)
4487     (TestBaseRenderer.test_point_layer_and_map_projection)
4488     (TestBaseRenderer.test_point_layer_projection)
4489     (TestBaseRenderer.test_point_with_classification): Adapt to new
4490     renderer interface
4491    
4492 bh 1865 2003-10-24 Bernhard Herzog <[email protected]>
4493    
4494     * libraries/thuban/wxproj.cpp (draw_polygon_shape)
4495     (point_in_polygon_shape, shape_centroid): Raise an exception if
4496     the shape can't be read. Previously invalid shape ids would lead
4497     to a segfault.
4498    
4499     * test/test_wxproj.py (TestShapeCentroid.test_invalid_shape_id):
4500     New. test whether an exception is raised for invalid shape ids
4501    
4502 jan 1857 2003-10-24 Jan-Oliver Wagner <[email protected]>
4503    
4504 jan 1862 * Thuban/Model/proj.py (Projection.GetProjectedUnits): Added 'longlat'
4505     as alias for 'latlong'.
4506    
4507     * Thuban/UI/projdialog.py (ProjFrame.__init__): Added 'longlat'
4508     as alias for 'latlong'.
4509    
4510     2003-10-24 Jan-Oliver Wagner <[email protected]>
4511    
4512 jan 1859 * Thuban/UI/projdialog.py (ProjFrame.proj_selection_changed): Set
4513     the projection even for the UnknownPanel.
4514     (UnknownProjPanel.__init__): Define the text and create the textctrl
4515     widget.
4516     (UnknownProjPanel._DoLayout): Replaced static text widget by the
4517     textctrl created in __init__.
4518     (UnknownProjPanel.SetProjection): Set the text for the text ctrl
4519     including the parameters of the projection.
4520    
4521     2003-10-24 Jan-Oliver Wagner <[email protected]>
4522    
4523 jan 1857 * Resources/Projections/epsg.proj: New. This is a list of
4524     EPSG codes with parameters for proj. The list has been
4525     generated using devtools/create_epsg.py based on the
4526     file nad/epsg of the proj 4.4.7 package. Four projection
4527     definitions have been deleted as they are not accepted by proj:
4528     "CH1903+ / LV95", "Bern 1898 (Bern) / LV03C", "CH1903 / LV03"
4529     and "HD72 / EOV".
4530    
4531 bh 1855 2003-10-22 Bernhard Herzog <[email protected]>
4532    
4533     Some more tweaks to the projection dialog which should fix RT
4534     #1886.
4535    
4536     * Thuban/UI/projlist.py (ProjectionList.Destroy): Unsubscribe from
4537     the ProjFile's messages and call the base class methods correctly
4538     (ProjectionList.SelectProjection): Set the wxLIST_STATE_FOCUSED
4539     flag on the newly selected item too. Otherwise some other item is
4540     focused and the first time the focus is moved with the keyboard
4541     the selection moves in unexpected ways.
4542    
4543     * Thuban/UI/projdialog.py (ProjFrame.__init__): Do not set the
4544     focus on the OK button, only on the projection list. That way the
4545     list really has the focus initially
4546     (ProjFrame.OnClose): Call the projection list's Destroy method to
4547     make it unsubscribe all messages
4548    
4549 bh 1840 2003-10-21 Bernhard Herzog <[email protected]>
4550    
4551 bh 1852 Rework the projection dialog to fix a few bugs, including RT 2166
4552     and most of 2168
4553    
4554     * Thuban/UI/projlist.py: New. The class ProjectionList is a
4555     special wxListCtrl to show a list of projections in a more MVC
4556     fashion
4557    
4558     * Thuban/UI/projdialog.py (ProjFrame): Substantial changes
4559     throughout the class. The main change is to use the ProjectionList
4560     class instead of a normal wxListBox. Also, add an explicit
4561     "Unknown" projection to the projection choice control.
4562     (ProjPanel.__init__): Add an "unknown" ellipsoid
4563     (TMPanel.__init__, LCCPanel.__init__): Tweak the order of
4564     instantiation of the panel's controls to make the tab-order more
4565     natural
4566    
4567     2003-10-21 Bernhard Herzog <[email protected]>
4568    
4569 bh 1849 * test/test_load.py (TestSingleLayer.file_contents)
4570     (TestSingleLayer.test): Add non-ascii characters to the titles of
4571     session, map and layer. This is effectively a port of the
4572     TestUnicodeStrings test in test_load_0_8.py which for some reason
4573     was only added there.
4574    
4575     * test/test_load_0_9.py (TestSingleLayer.file_contents)
4576     (TestSingleLayer.test): Same as in test_load.py: add non-ascii
4577     characters to the titles of session, map and layer,.
4578    
4579     2003-10-21 Bernhard Herzog <[email protected]>
4580    
4581 bh 1847 Add EPSG projection handling to .thuban files
4582    
4583     * test/test_save.py (SaveSessionTest.dtd)
4584     (SaveSessionTest.testEmptySession)
4585     (SaveSessionTest.testLayerProjection)
4586     (SaveSessionTest.testRasterLayer)
4587     (SaveSessionTest.testClassifiedLayer)
4588     (SaveSessionTest.test_dbf_table)
4589     (SaveSessionTest.test_joined_table)
4590     (SaveSessionTest.test_save_postgis): Update to 1.0-dev namespace
4591     (SaveSessionTest.testSingleLayer): Update to 1.0-dev namespace and
4592     use a and epsg projection to test saving them
4593    
4594     * test/test_load.py (LoadSessionTest.dtd): Update to 1.0-dev
4595     namespace
4596     (TestLayerVisibility.file_contents, TestLabels.file_contents)
4597     (TestLayerProjection.file_contents)
4598     (TestRasterLayer.file_contents, TestJoinedTable.file_contents)
4599     (TestPostGISLayer.file_contents)
4600     (TestPostGISLayerPassword.file_contents)
4601     (TestLoadError.file_contents, TestLoadError.test): Update to use
4602     1.0-dev namespace
4603     (TestSingleLayer.file_contents, TestSingleLayer.test): Update to
4604     use 1.0-dev namespace and use an EPSG projection to test whether
4605     loading it works
4606    
4607     * test/test_load_0_9.py: New. Effectively a copy of test_load.py
4608     as of Thuban 0.9. These are now tests to determine whether Thuban
4609     can still read files generated by Thuban 0.9
4610    
4611     * Thuban/Model/save.py (SessionSaver.write)
4612     (SessionSaver.write_session): Use the 1.0 dtd and 1.0-dev
4613     namespace
4614     (SessionSaver.write_projection): Write the projection's epsg
4615     attribute
4616    
4617     * Thuban/Model/load.py (SessionLoader.__init__): Also accept the
4618     thuban-1.0-dev.dtd namespace
4619     (SessionLoader.check_attrs): Allow a callable object as conversion
4620     too
4621     (SessionLoader.start_projection, SessionLoader.end_projection)
4622     (SessionLoader.start_parameter): Handle the epsg attribute and
4623     rename a few instance variables to lower case
4624    
4625     * Resources/XML/thuban-1.0.dtd: New. Only difference to
4626     thuban-0.9.dtd is the epsg attribute for projections.
4627    
4628     2003-10-21 Bernhard Herzog <[email protected]>
4629    
4630 bh 1840 * test/runtests.py (main): Let the user specify which tests to run
4631     on the command line
4632    
4633     * test/support.py (ThubanTestResult.getDescription): Override to
4634     give a better short description. The description can be used as a
4635     parameter to run_tests to run that particular test in isolation.
4636    
4637 frank 1837 2003-10-21 Frank Koormann <[email protected]>
4638    
4639     Popup menu for legend. Scheduled for the 1.2 release this was too
4640     simple to implement: The popup menu is bound to the legend tree, while
4641     the events are hanlded by its anchestor, the legend panel. This
4642     allows reuse of all the event handlers already implemented for the
4643     legend toolbar buttons.
4644    
4645     * Thuban/UI/legend.py (LegendPanel.__init__): EVT_MENU macros
4646     to add handlers for the events issued by the popup menu.
4647     (LegendPanel._OnToggleVisibility): Handler for toggling layer
4648     visibility event
4649     (LegendPanel._OnProjection): Handler for layer projection event.
4650     (LegendTree.__init__): Added EVT_TREE_ITEM_RIGHT_CLICK
4651     (LegendTree._OnRightClick): Event handler for right click, select item
4652     and pop up menu.
4653     (LegendTree.ToggleVisibility): Toggle layer visibility
4654     (LegendTree.LayerProjection): Raise layer projection dialog for
4655     current layer.
4656    
4657 bh 1836 2003-10-21 Bernhard Herzog <[email protected]>
4658    
4659     * Resources/Projections/defaults.proj: Use correct DOCTYPE
4660     declaration. The top-level element is projectionlist not projfile
4661    
4662 bh 1834 2003-10-20 Bernhard Herzog <[email protected]>
4663    
4664     * Thuban/UI/projdialog.py (ProjFrame.write_proj_file): New. helper
4665     method to write a projfile and display a busy cursor and error
4666     dialogs.
4667     (ProjFrame._OnSave, ProjFrame._OnAddToList, ProjFrame._OnImport)
4668     (ProjFrame._OnExport, ProjFrame._OnRemove): Use write_proj_file
4669     (ProjFrame.__FillAvailList): Translate "<None>" too and display a
4670     busy cursor while loading the user and system prj files.
4671    
4672 bh 1832 2003-10-16 Bernhard Herzog <[email protected]>
4673    
4674     * Thuban/Model/resource.py (projfile_cache): Introduce a cache for
4675     ProjFile objects
4676     (clear_proj_file_cache): New function to clear the cache. Mainly
4677     useful for use by the test suite
4678     (read_proj_file): Use the cache.
4679    
4680     * test/test_proj.py (TestProjFile): Clarify the doc-string
4681     (ProjFileReadTests): Update doc-string
4682     (ProjFileReadTests.test_get_system_proj_file): Check whether the
4683     system proj files is cached.
4684     (ProjFileLoadTestCase): New base class for the proj file tests
4685     derived from support.FileLoadTestCase to provide some common
4686     behavior.
4687     (TestLoadingProjFile)
4688     (TestLoadingProjFileWithEmptyProjectionlist.file_contents)
4689     (TestProjFileWithInvalidParameters.file_contents): Derive from
4690     ProjFileLoadTestCase
4691     (TestLoadingProjFile.test_caching): New. Test whether the cache
4692     works
4693    
4694 silke 1829 2003-10-16 Silke Reimer <[email protected]>
4695    
4696     * debian/*: New directory with configuration files for building a thuban
4697     deb-package.
4698    
4699 bh 1822 2003-10-14 Bernhard Herzog <[email protected]>
4700    
4701 bh 1828 * test/test_proj.py: Execute support.run_tests when run as
4702     __main__ so that missing unsubscribes are detected
4703     (TestProjFile.tearDown): Destroy the proj_file properly
4704    
4705     2003-10-14 Bernhard Herzog <[email protected]>
4706    
4707 bh 1826 * Thuban/Model/messages.py (PROJECTION_ADDED)
4708     (PROJECTION_REPLACED, PROJECTION_REMOVED): New message types for
4709     the ProjFile objects
4710    
4711     * Thuban/Model/proj.py (ProjFile): Derive from Publisher so we can
4712     easily send messages when the projections change
4713     (ProjFile.Add, ProjFile.Remove, ProjFile.Replace): Issue messages
4714     when the change was successful
4715    
4716     * test/test_proj.py (TestProjFile.setUp): Subscribe to some of the
4717     proj file messages
4718     (TestProjFile.test_add_remove)
4719     (TestProjFile.test_remove_non_existing)
4720     (TestProjFile.test_replace)
4721     (TestProjFile.test_replace_non_existing): Test whether the right
4722     messages are sent
4723    
4724     2003-10-14 Bernhard Herzog <[email protected]>
4725    
4726 bh 1822 * test/test_proj.py (TestProjFile.test): Refactor into several
4727     tests
4728     (TestProjFile.test_add_remove)
4729     (TestProjFile.test_remove_non_existing)
4730     (TestProjFile.test_replace)
4731     (TestProjFile.test_replace_non_existing): Some of the new
4732     individual test cases
4733     (TestProjFileSimple): New class for the rest of the test cases
4734     that came out of the refactoring
4735     (ProjFileTest): Derive from xmlsupport.ValidationTest so that the
4736     derived classes don't have to
4737    
4738 bh 1812 2003-10-13 Bernhard Herzog <[email protected]>
4739    
4740 bh 1820 Add an optional EPSG code to the projection objects and extend the
4741     .proj file format accordingly.
4742    
4743     * Resources/XML/projfile.dtd (element projection): Add epsg
4744     attribute
4745    
4746     * Thuban/Model/proj.py (Projection.__init__): New parameter and
4747     instance variable epsg. Update doc-string
4748     (Projection.EPSGCode, Projection.Label): New methods to provide
4749     access to EPSG code and a label for use in dialogs
4750    
4751     * Thuban/Model/resource.py (ProjFileReader.start_projection)
4752     (ProjFileReader.end_projection, ProjFileSaver.write_projfile):
4753     Handle the epsg code attribute when reading or writing proj files
4754    
4755     * Thuban/UI/projdialog.py (ProjFrame._OnSave)
4756     (ProjFrame._OnAddToList, ProjFrame.__DoOnProjAvail)
4757     (ProjFrame.__FillAvailList): Use the projection's Label method to
4758     get the string for the list box
4759    
4760     * test/test_proj.py (TestProjection.test_label)
4761     (TestProjection.test_label_epsg)
4762     (TestProjection.test_epsgcode_for_non_epsg_projection)
4763     (TestProjection.test_epsgcode_for_real_epsg_projection): New tests
4764     for the label and EPSGCode methods
4765     (WriteProjFileTests.doTestWrite, WriteProjFileTests.test_write)
4766     (WriteProjFileTests.test_write_empty_file): Create the ProjFile
4767     objects in the test cases and put the expected contents into the
4768     test case methods too. Update doTestWrite accordingly
4769     (TestLoadingProjFile)
4770     (TestLoadingProjFileWithEmptyProjectionlist): New classes with the
4771     read tests from TestProjFile.
4772     (TestProjFile.doTestRead, TestProjFile.testRead): Removed. These
4773     tests are now in the new classes.
4774     (sample_projfile, sample_projfile_data)
4775     (sample_projfile2, sample_projfile_data2): Removed. Not used
4776     anymore.
4777     (TestProjFile.test_read_unreadable_file): No need to reset the
4778     permissions at the end anymore since we use a unique filename
4779    
4780     2003-10-13 Bernhard Herzog <[email protected]>
4781    
4782 bh 1814 * test/test_proj.py: Some more refactoring of the test cases
4783     (ProjFileTest): New base class for the proj file tests.
4784     (TestProjFile): Derive from ProjFileTest
4785     (TestProjFile.test_read_unreadable_file)
4786     (TestProjFile.test_read_empty_file, TestProjFile.doTestRead): Use
4787     the new filename method to get a unique filename
4788     (TestProjFile.doTestWrite, TestProjFile.testWrite): Removed.
4789     (WriteProjFileTests): New class for proj file write tests.
4790     Contains the write test that were in TestProjFile originally.
4791    
4792     2003-10-13 Bernhard Herzog <[email protected]>
4793    
4794 bh 1812 * test/test_proj.py (TestProjFile.testRead)
4795     (TestProjFile.test_read_non_existing_file)
4796     (TestProjFile.test_read_unreadable_file)
4797     (TestProjFile.test_read_empty_file): Split into several methods.
4798    
4799 bh 1805 2003-10-10 Bernhard Herzog <[email protected]>
4800    
4801 bh 1810 * Thuban/UI/sizers.py: New file with custom sizers.
4802    
4803     * Thuban/UI/projdialog.py (ProjFrame.build_dialog): Instantiate
4804     all projection type specific panels and put them into a
4805     NotebookLikeSizer. This way the dialog doesn't change its size
4806     when a different projection is selected
4807     (ProjFrame.__init__): Rename projection_panels
4808     projection_panel_defs and reuse projection_panels for a list of
4809     the instantiated panels.
4810     (ProjFrame._show_proj_panel, ProjFrame.__DoOnProjAvail)
4811     (ProjFrame.__DoOnProjChoice): Changes due to the new handling of
4812     the panels
4813     (UnknownProjPanel._DoLayout): Place the newlines in the message
4814     differently to make the panel narrower.
4815     (TMPanel._DoLayout): Layout the parameters in one column.
4816    
4817     2003-10-10 Bernhard Herzog <[email protected]>
4818    
4819 bh 1807 * Thuban/UI/projdialog.py (ProjFrame.build_dialog): New method
4820     that contains all the setup for the dialog's widgets, layout and
4821     event handling.
4822     (__): Call build_dialog to build the dialog.
4823     (ProjFrame.__set_properties, ProjFrame.__do_layout): Removed.
4824     Their functionality is now in build_dialog
4825     (ProjFrame.__VerifyButtons, ProjFrame.__VerifyButtons)
4826     (ProjFrame.__DoOnProjAvail, ProjFrame.__DoOnProjAvail)
4827     (ProjFrame.__DoOnProjChoice): Small updates due to slightly
4828     different widget names and hierarchy introduced with build_dialog.
4829    
4830     2003-10-10 Bernhard Herzog <[email protected]>
4831    
4832 bh 1805 * README: Fix typo.
4833    
4834 bh 1803 2003-10-09 Bernhard Herzog <[email protected]>
4835    
4836     * Thuban/Model/proj.py (ProjFile.Add): Do not check whether the
4837     projection is already in the list. This is *a lot* faster when
4838     loading files with hundreds of projections since it saves a linear
4839     search. OTOH this will allow adding the same projection to the
4840     user.proj file multiple times in the projection dialog but we'll
4841     deal with that later
4842    
4843 jan 1801 2003-10-09 Jan-Oliver Wagner <[email protected]>
4844    
4845     * devtools: New. Directory for developer tools that are not intended
4846     for the regular user.
4847    
4848     * devtools/create_epsg.py: New. Convert the epsg file of proj into
4849     a python .proj file.
4850    
4851 bh 1799 2003-10-09 Bernhard Herzog <[email protected]>
4852    
4853     * test/test_proj.py
4854     (TestProjection.test_get_parameter_without_equals_sign): New. Test
4855     whether GetParameter handles parameters without "=" sign correctly
4856    
4857     * Thuban/Model/proj.py (Projection.GetParameter): Handle
4858     parameters that do not contain a "=". Update the doc-string
4859    
4860 bh 1794 2003-10-08 Bernhard Herzog <[email protected]>
4861    
4862 bh 1796 * Thuban/UI/projdialog.py (ProjFrame.__set_properties): Remove the
4863     length limit on the projname text control
4864    
4865     2003-10-08 Bernhard Herzog <[email protected]>
4866    
4867 bh 1794 * test/test_proj.py (TestProjection.test_get_projection_units_geo)
4868     (TestProjection.test_get_projection_units_normal): New. Tests for
4869     the Projection.GetProjectedUnits method
4870    
4871 jan 1792 2003-10-08 Jan-Oliver Wagner <[email protected]>
4872    
4873     * Thuban/Model/resource.py (get_user_proj_file): small bug-fix:
4874     Added missing 'val' parameter.
4875    
4876 bh 1788 2003-10-08 Bernhard Herzog <[email protected]>
4877    
4878 bh 1790 * Thuban/UI/projdialog.py (ProjFrame.__DoOnProjAvail): When the
4879     projection type of the currently selected projection is not known,
4880     i.e. there's no panel for it, use the UnknownProjPanel
4881     (ProjFrame.__DoOnProjChoice, ProjFrame._show_proj_panel): Split
4882     the actual replacing of the proj panel into the new method
4883     _show_proj_panel.
4884     (UnknownProjPanel): Add doc-string.
4885     (UnknownProjPanel._DoLayout): Insert a newline into the text so
4886     that the panel is not so wide.
4887    
4888     2003-10-08 Bernhard Herzog <[email protected]>
4889    
4890 bh 1788 * Thuban/Model/resource.py (read_proj_file): Return the warnings
4891     too. Update the doc-string
4892     (get_proj_files): Removed. It wasn't used anywhere
4893     (get_system_proj_files, get_system_proj_file): Rename to
4894     get_system_proj_file and return the ProjFile object and not a list
4895     of ProjFile objects. Update the callers.
4896     (get_user_proj_files, get_user_proj_file): Rename to
4897     get_user_proj_file return the ProjFile object and not a list of
4898     ProjFile objects. Update the callers.
4899     (ProjFileReader.__init__): New instance variable for the warnings.
4900     Rename the __pf ivar to projfile. Update the methods referring to
4901     __pf
4902     (ProjFileReader.end_projection): Catch any errors raised when
4903     instantiating the projection and record that as an error. The
4904     projection will not be in the final ProjFile object.
4905     (ProjFileReader.GetWarnings): New method to return the warnings.
4906    
4907     * Thuban/UI/projdialog.py (ProjFrame.show_warnings): New method to
4908     show the warnings from the projfile reader
4909     (ProjFrame._OnImport): Deal with any warnings returned by
4910     read_proj_file
4911     (ProjFrame.__FillAvailList): Deal with any warnings returned by
4912     get_system_proj_file or get_user_proj_file.
4913    
4914     * test/test_proj.py (TestProjFile.doTestRead): Check the warnings.
4915     (TestProjFileWithInvalidParameters.file_contents): New test cases
4916     to test whether read_proj_file handles invalid projection
4917     parameters correctly
4918     (TestProjFile.test_get_system_proj_file): New. Simple test for
4919     resource.get_system_proj_file
4920    
4921 bh 1785 2003-10-07 Bernhard Herzog <[email protected]>
4922    
4923     * test/test_derivedshapestore.py
4924     (TestDerivedShapeStoreExceptions.tearDown): Clear the session
4925     properly so that the temporary directories get deleted correctly
4926    
4927 bh 1773 2003-10-06 Bernhard Herzog <[email protected]>
4928    
4929 bh 1783 Handle the title changes in a proper MVC way.
4930    
4931     * Thuban/UI/mainwindow.py (MainWindow.__init__): Subscribe to the
4932     canvas' TITLE_CHANGED messages
4933     (MainWindow.update_title): New. Update the main window's title
4934     (MainWindow.__SetTitle): Removed. Use update_title instead.
4935     (MainWindow.SetMap): Use update_title instead of __SetTitle
4936     (MainWindow.RenameMap): Do change the window title explicitly
4937     here. That's handled in a proper MVC way now.
4938     (MainWindow.title_changed): New. Subscriber for the TITLE_CHANGED
4939     messages
4940    
4941     * Thuban/Lib/connector.py (Conduit): New class to help classes
4942     that forward messages
4943    
4944     * Thuban/UI/viewport.py: Forward the map's TITLE_CHANGED messages
4945     (ViewPort): Derive from Conduit instead of Publisher
4946     (ViewPort.Subscribe, ViewPort.Unsubscribe): Use the new base class
4947     when calling the inherited versions
4948     (ViewPort._subscribe_map, ViewPort._unsubscribe_map): New helper
4949     methods to subscribe and unsubscribe map messages
4950     (ViewPort.SetMap, ViewPort.Destroy): Use the new helper methods to
4951     handle the map subscriptions
4952     (ViewPort.Map, ViewPort.map_projection_changed)
4953     (ViewPort.layer_projection_changed): Add or update doc-strings
4954    
4955     * test/test_connector.py (TestPublisher.test_issue_simple): Fix
4956     typo
4957     (MyConduit): Helper class for the Conduit test.
4958     (TestConduit): Test cases for Conduit
4959    
4960     * test/test_connector.py: Use support.run_tests as main.
4961    
4962     * test/test_viewport.py (ViewPortTest.setUp): Also subscribe to
4963     the TITLE_CHANGED messages
4964     (ViewPortTest.test_forwarding_title_changed): New test to check
4965     whether the viewport forwards the map's TITLE_CHANGED messages
4966     (TestViewportWithPostGIS.tearDown): Call the map's Destroy method
4967     after the port's because the latter may require a still functional
4968     map.
4969    
4970     2003-10-06 Bernhard Herzog <[email protected]>
4971    
4972 bh 1777 * Thuban/UI/application.py (ThubanApplication.maps_changed): Add
4973     doc-string
4974    
4975     2003-10-06 Bernhard Herzog <[email protected]>
4976    
4977 bh 1775 * test/test_viewport.py (ViewPortTest.setUp)
4978     (SimpleViewPortTest.test_init_with_size): Move the test for the
4979     initial size as a constructor parameter from ViewPortTest.setUp
4980     method to a new separate test in SimpleViewPortTest.
4981    
4982     2003-10-06 Bernhard Herzog <[email protected]>
4983    
4984 bh 1773 * test/test_viewport.py (MockView): New class derived from
4985     ViewPort with a mock implementation of GetTextExtent to be used in
4986     the test cases
4987     (ViewPortTest.setUp): Use MockView instead of ViewPort
4988    
4989     * Thuban/UI/viewport.py (ViewPort.GetTextExtent): Turn this method
4990     into what would be a "pure virtual function" in C++: always raise
4991     NotImplementedError. Mock implementations for test cases don't
4992     belong into the real code
4993    
4994 bh 1770 2003-10-02 Bernhard Herzog <[email protected]>
4995    
4996     * test/test_layer.py (TestLayer.test_empty_layer): Explicitly
4997     close the dbf file we create so that it's contents have been
4998     written properly.
4999    
5000     * libraries/shapelib/shptree.c, libraries/shapelib/shpopen.c,
5001     libraries/shapelib/shapefil.h, libraries/shapelib/dbfopen.c:
5002     Update to shapelib 1.2.10
5003    
5004 jan 1767 2003-10-01 Jan-Oliver Wagner <[email protected]>
5005    
5006     * Thuban/UI/tree.py, Thuban/UI/main.py: Remove the #! line as
5007     it annoys lintian which warns about these files not being
5008     executable. The #! isn't necessary here since if you absolutely
5009     must execute them you can always say "python <filename>".
5010    
5011 bh 1757 2003-09-26 Bernhard Herzog <[email protected]>
5012    
5013 bh 1760 * Thuban/Model/classgen.py (GenQuantiles0): Removed since it's
5014     only used in GREAT-ER but not used in Thuban itself. When GREAT-ER
5015     is ported to a newer the import will fail, so it should be noticed
5016     immediately that this function is gone.
5017     Fixes RT#1919
5018    
5019     2003-09-26 Bernhard Herzog <[email protected]>
5020    
5021 bh 1757 Add a DTD for the projection files and make thuban write valid
5022     projection files
5023    
5024     * Resources/XML/projfile.dtd: New. DTD for thuban's projection
5025     files
5026    
5027     * Thuban/Model/resource.py (ProjFileSaver.write): Use
5028     'projectionlist' as the name in the document type declaration so
5029     that it matches the element type of the root element.
5030    
5031     * test/test_proj.py (sample_projfile, sample_projfile2): Use
5032     'projectionlist' as the name in the document type declaration just
5033     as it is done now in the files thuban would write
5034     (sample_projfile, sample_projfile_data): Fix spelling of
5035     "Mercator"
5036     (TestProjFile.doTestWrite): Validate the written and the expected
5037     XML data
5038     (TestProjFile): Derive from ValidationTest so that we can run xml
5039     validation tests
5040    
5041 bh 1751 2003-09-24 Bernhard Herzog <[email protected]>
5042    
5043     * Thuban/UI/renderer.py (ExportRenderer.render_legend): Do not
5044     modify the list returned by map.Layers() in place since it is the
5045     actual list of layers used by the map.
5046    
5047 jan 1745 2003-09-23 Jan-Oliver Wagner <[email protected]>
5048    
5049     * Doc/manual/thuban-manual.xml: Added subsection to chapter
5050     Extensions to describe the extensions coming with the Thuban
5051     standard package (gns2shp and importAPR).
5052    
5053 bh 1743 2003-09-23 Bernhard Herzog <[email protected]>
5054    
5055     * libraries/thuban/wxproj.cpp (project_point): if there's an
5056     inverse but no forward projection, convert to degrees after
5057     applying the inverse projection. Fixes RT#2096
5058    
5059     * test/test_wxproj.py: New. Test cases for wxproj.so. One test
5060     implicitly tests for the fix to RT#2096
5061    
5062     * test/support.py (FloatComparisonMixin.assertFloatSeqEqual):
5063     Check that the sequences have the same lengths
5064    
5065     * Resources/Projections/defaults.proj (Geographic projection): Use
5066     a much more precise value for the to_meter attribute.
5067    
5068 bh 1737 2003-09-22 Bernhard Herzog <[email protected]>
5069    
5070     * test/support.py (initthuban): Make sure to unset the LANG env.
5071     var. so that tests that compare translated strings work. Solves RT
5072     #2094
5073    
5074 jan 1730 2003-09-22 Jan-Oliver Wagner <[email protected]>
5075    
5076 jan 1735 Small improvement of APR import.
5077    
5078     * Extensions/importAPR/test/test_apr.py (aprTest.test_LClass):
5079     Added tests for text-ranges.
5080    
5081     * Extensions/importAPR/apr.py (APR_LClass.GetThubanRange): Now
5082     returns a string object if the range is based on text.
5083    
5084     * Extensions/importAPR/importAPR.py (import_apr_dialog): Unified
5085     range retrieval.
5086    
5087     2003-09-22 Jan-Oliver Wagner <[email protected]>
5088    
5089 jan 1730 Initial version of the importAPR extension which is in
5090     experimental state.
5091    
5092     * /Extensions/importAPR/, /Extensions/importAPR/samples/,
5093     /Extensions/importAPR/test/: New directories.
5094    
5095     * /Extensions/importAPR/samples/README: New: Howto load the samples.
5096    
5097     * /Extensions/importAPR/samples/iceland.apr: New: A sample APR
5098     file which refers to the Thuban Iceland demo data.
5099    
5100     * /Extensions/importAPR/test/README: New: Howto execute the tests.
5101    
5102     * /Extensions/importAPR/test/test_apr.py: New: Tests for APR classes.
5103    
5104     * /Extensions/importAPR/apr.py: New: Classes for ArcView Objects
5105     as in '.apr'-files.
5106    
5107     * /Extensions/importAPR/odb.py: New: Classes for generic ArcView
5108     ODB Objects as in '.apr', '.avl' and other files.
5109    
5110     * /Extensions/importAPR/__init__.py: New: Init to make this
5111     directory a package.
5112    
5113     * /Extensions/importAPR/importAPR.py: New: Import a ArcView
5114     project file (.apr) and convert it to Thuban.
5115    
5116     2003-09-22 Jan-Oliver Wagner <[email protected]>
5117    
5118     * Extensions/gns2shp.gns2shp.py: The main module of gns2shp.
5119    
5120 jan 1720 2003-09-19 Jan-Oliver Wagner <[email protected]>
5121    
5122     * Doc/manual/thuban-manual.xml: Extended section 'Installation'
5123     with description on RPM installation and RPM binary package
5124     creation.
5125    
5126 bh 1718 2003-09-18 Bernhard Herzog <[email protected]>
5127    
5128     * setup.py (data_files): Only add the mo files if the Locales
5129     directory actually exists, so that setup.py works with a fresh CVS
5130     checkout
5131    
5132 jan 1716 2003-09-12 Jan-Oliver Wagner <[email protected]>
5133    
5134     * Examples/simple_extensions/simple_tool.py: bugfix: Tool is now
5135     in viewport, not anymore in view
5136    
5137 jan 1714 2003-09-04 Jan-Oliver Wagner <[email protected]>
5138    
5139     Introducing first Extension (gns2shp).
5140    
5141     * Extensions, Extensions/gns2shp, Extensions/gns2shp/test: New.
5142    
5143     * Extensions/__init__.py: New. init to make this dir a package.
5144    
5145     * Extensions/gns2shp/__init__.py: New. init to make this dir a package.
5146    
5147     * Extensions/gns2shp/test/README: New. some info on this test directory.
5148    
5149     * Extensions/gns2shp/test/ls.txt: New. test data set (Liechtenstein).
5150    
5151     * Extensions/gns2shp/test/test_gns2shp.py: New. Test for correct creation
5152     of Shapefile from GNS text file format
5153    
5154 jan 1705 2003-09-03 Jan-Oliver Wagner <[email protected]>
5155    
5156 jan 1707 Fix/workaround for bug #2019:
5157     https://intevation.de/rt/webrt?serial_num=2019
5158    
5159     * Thuban/UI/identifyview.py (IdentifyView.ID_STOP): New.
5160     (IdentifyView.__init__): Added another button that allows to
5161     stop the identify mode.
5162     (IdentifyView.OnStop): New. Stops the identify mode.
5163    
5164     2003-09-03 Jan-Oliver Wagner <[email protected]>
5165    
5166 jan 1705 Introducing a new exception dialog that allows to exit the
5167     application immediately.
5168     This fixes bug #2060: https://intevation.de/rt/webrt?serial_num=2060
5169    
5170     * Thuban/UI/exceptiondialog.py: New. A special exception dialog.
5171    
5172     * Thuban/UI/application.py (ThubanApplication.ShowExceptionDialog):
5173     Made strings available to translations. Exchanged the simple
5174     ScrolledMessageDialog by the new ExceptionDialog.
5175    
5176 bh 1694 2003-09-01 Bernhard Herzog <[email protected]>
5177    
5178 bh 1701 * NEWS: New. Summary of changes and release notes.
5179    
5180     * MANIFEST.in: Add NEWS
5181    
5182     2003-09-01 Bernhard Herzog <[email protected]>
5183    
5184 bh 1699 * MANIFEST.in: Correct the include statement for the mo-files and
5185     include the documentation too.
5186    
5187     * setup.py (data_files): Add the .mo files
5188     (setup call): Up to version 0.9.0
5189    
5190     2003-09-01 Bernhard Herzog <[email protected]>
5191    
5192 bh 1696 * Thuban/UI/dbdialog.py (ChooseDBTableDialog.__init__): Change the
5193     parameter list to just parent and session
5194     (ChooseDBTableDialog.__set_properties): Removed. Setting the
5195     selection of empty list boxes is not allowed (and produces C++
5196     assertion errors) and the rest of the setup is better done in
5197     __init__ anyway.
5198     (ChooseDBTableDialog.OnCancel, ChooseDBTableDialog.OnOK)
5199     (ChooseDBTableDialog.OnLBDClick, DBDialog.OnOK): Use the Python
5200     builtins True/False for booleans to avoid warnings from wxPython
5201    
5202     * Thuban/UI/mainwindow.py (MainWindow.AddDBLayer): Adapt to new
5203     ChooseDBTableDialog constructor parameters.
5204    
5205     2003-09-01 Bernhard Herzog <[email protected]>
5206    
5207 bh 1694 * Thuban/Model/postgisdb.py
5208     (PostGISTable): Extend doc-string
5209     (PostGISTable._fetch_table_information): Set the column index
5210     correctly, pretending ignored columns don't exist.
5211    
5212     * test/test_postgis_db.py (TestPostGISIgnoredColumns): New tests
5213     for postgis tables with data types not yet supported by thuban.
5214    
5215 bh 1692 2003-08-29 Bernhard Herzog <[email protected]>
5216    
5217     * HOWTO-Release: Tweak item about running the tests.
5218    
5219 jan 1690 2003-08-29 Jan-Oliver Wagner <[email protected]>
5220    
5221     * /Doc/manual/thuban-manual.xml: updated to version 1.0pre2.
5222    
5223 bh 1688 2003-08-29 Bernhard Herzog <[email protected]>
5224    
5225     Add some missing parameters to projections. Proj complains about
5226     them on windows but for some reason not on Linux.
5227    
5228     * test/test_save.py (SaveSessionTest.testLayerProjection): Add
5229     missing required projection parameters
5230    
5231     * test/test_proj.py (TestProjFile.test): Add missing required
5232     projection parameters
5233    
5234     * test/test_load_0_8.py (TestLayerProjection.file_contents)
5235     (TestLayerProjection.test): Add missing required projection
5236     parameters and tests for them
5237    
5238     * test/test_load.py (TestLayerProjection.file_contents)
5239     (TestLayerProjection.test): Add missing required projection
5240     parameters and tests for them
5241    
5242     * test/test_layer.py (TestLayer.test_base_layer): Add missing
5243     required projection parameters
5244    
5245     2003-08-29 Bernhard Herzog <[email protected]>
5246    
5247     * libraries/pyprojection/Projection.i: Use pj_get_errno_ref to
5248     access the pj_errno because directly accessing pj_errno doesn't
5249     work on windows if the proj library is in a DLL
5250    
5251     * libraries/pyprojection/Projection_wrap.c: Update from Projection.i
5252    
5253 bh 1672 2003-08-28 Bernhard Herzog <[email protected]>
5254    
5255 bh 1685 * test/test_proj.py: Import things from Thuban after calling
5256     initthuban
5257    
5258     * test/test_load.py (LoadSessionTest.filenames): New class
5259     variable with the filename attributes to normalize
5260     (LoadSessionTest.check_format): Pass self.filenames to
5261     sax_eventlist to normalize the filename attributes
5262    
5263     * test/xmlsupport.py: Add cvs keywords
5264     (SaxEventLister.__init__): New parameter filenames which indicates
5265     attributes that contain filenames
5266     (SaxEventLister.startElementNS): Normalize the filename attributes
5267     with os.path.normpath
5268     (sax_eventlist): New parameter filenames to pass through to
5269     SaxEventLister
5270    
5271     * test/test_derivedshapestore.py: Make this file callable as a
5272     program to execute the tests
5273     (TestDerivedShapeStoreExceptions.test_table_with_wrong_size): Bind
5274     the session to self.session so that it gets destroyed properly
5275    
5276     * test/test_layer.py (TestLayer.tearDown): Call the session's
5277     Destroy method
5278    
5279     * test/test_map.py (TestMapBase.tearDown): Destroy self.session
5280     too if it exists
5281     (TestMapAddLayer.test_add_layer): Bind the session to self.session
5282     so that it gets destroyed properly
5283    
5284     * test/postgissupport.py (reason_for_not_running_tests): Add a
5285     test for the existence of popen2.Popen4.
5286    
5287     * test/test_save.py (SaveSessionTest.tearDown): New. Provide a
5288     reliable way to destroy the sessions created in the test cases
5289     (SaveSessionTest.test_dbf_table): Bind the session to self.session
5290     so that it gets destroyed properly
5291     (SaveSessionTest.testLayerProjection): Bind the session to
5292     self.session so that it gets destroyed properly
5293    
5294     * test/test_session.py (UnreferencedTablesTests.tearDown): Make
5295     sure that the session is destroyed properly
5296    
5297     * test/test_shapefilestore.py: Make this callable as a program to
5298     execute the tests
5299    
5300     * test/test_scalebar.py: Remove unnecessary import of _ from
5301     Thuban
5302    
5303     * test/support.py (print_garbage_information): Call initthuban
5304     here because it may be called indirectly from test cases that test
5305     test support modules which do not use anything from thuban itself
5306     (ThubanTestProgram.runTests): Remove unnecessary debug print
5307    
5308     2003-08-28 Bernhard Herzog <[email protected]>
5309    
5310 bh 1672 * Thuban/version.py (longversion): Update to 0.9
5311    
5312     * Thuban/UI/mainwindow.py: Remove some unused imports
5313    
5314     * README: Add section about required additional software. Add date
5315     and revision CVS keywords
5316    
5317     * HOWTO-Release: Add item about the translations. Add date and
5318     revision CVs keywords and change formatting to match README a bit
5319     better
5320    
5321     * po/de.po: Update for 0.9
5322    
5323     * test/README: Tweak the wording a little because many tests are
5324     not really unittest.
5325    
5326 bh 1663 2003-08-27 Bernhard Herzog <[email protected]>
5327    
5328 bh 1665 As preparation for the 0.9 release, switch thuban files to a
5329     non-dev namespace
5330    
5331     * Thuban/Model/save.py (SessionSaver.write_session): Write files
5332     with the http://thuban.intevation.org/dtds/thuban-0.9.dtd
5333     namespace
5334    
5335     * Thuban/Model/load.py (SessionLoader.__init__): Accept the
5336     http://thuban.intevation.org/dtds/thuban-0.9.dtd namespace too
5337    
5338     * test/test_save.py (SaveSessionTest.dtd)
5339     (SaveSessionTest.testEmptySession)
5340     (SaveSessionTest.testSingleLayer)
5341     (SaveSessionTest.testLayerProjection)
5342     (SaveSessionTest.testRasterLayer)
5343     (SaveSessionTest.testClassifiedLayer)
5344     (SaveSessionTest.test_dbf_table)
5345     (SaveSessionTest.test_joined_table)
5346     (SaveSessionTest.test_save_postgis): Update for new namespace
5347    
5348     * test/test_load.py (LoadSessionTest.dtd, TestSingleLayer)
5349     (TestLayerVisibility.file_contents, TestLabels.file_contents)
5350     (TestLayerProjection.file_contents)
5351     (TestRasterLayer.file_contents, TestJoinedTable.file_contents)
5352     (TestPostGISLayer.file_contents)
5353     (TestPostGISLayerPassword.file_contents)
5354     (TestLoadError.file_contents, TestLoadError.test): Update for new
5355     namespace
5356    
5357     2003-08-27 Bernhard Herzog <[email protected]>
5358    
5359 bh 1663 Make the table interface distinguish between row ids (an integer
5360     that uniquely identifies a row) and row ordinals (a simple row
5361     count from 0 to NumRows() - 1)
5362    
5363     * Thuban/Model/postgisdb.py (PostGISTable.RowIdToOrdinal)
5364     (PostGISTable.RowOrdinalToId): New methods to conver between row
5365     ids and row ordinals
5366     (PostGISTable.ReadRowAsDict, PostGISTable.ReadValue): New keyword
5367     parameter row_is_ordinal to indicate whether the row parameter is
5368     the row id or the ordinal
5369    
5370     * Thuban/Model/transientdb.py (TransientTableBase.RowIdToOrdinal)
5371     (TransientTableBase.RowOrdinalToId)
5372     (AutoTransientTable.RowIdToOrdinal)
5373     (AutoTransientTable.RowOrdinalToId): Same new methods as in
5374     PostGISTable.
5375     (TransientTableBase.ReadRowAsDict, TransientTableBase.ReadValue)
5376     (AutoTransientTable.ReadRowAsDict, AutoTransientTable.ReadValue):
5377     Same new parameter as in PostGISTable.
5378    
5379     * Thuban/Model/table.py (DBFTable.RowIdToOrdinal)
5380     (DBFTable.RowOrdinalToId, MemoryTable.RowIdToOrdinal)
5381     (MemoryTable.RowOrdinalToId): Same new methods as in PostGISTable.
5382     (DBFTable.ReadValue, DBFTable.ReadRowAsDict)
5383     (MemoryTable.ReadValue, MemoryTable.ReadRowAsDict): Same new
5384     parameter as in PostGISTable.
5385    
5386     * Thuban/UI/tableview.py (DataTable.RowIdToOrdinal)
5387     (DataTable.RowOrdinalToId): New methods to convert between row ids
5388     and row ordinals.
5389     (TableGrid.SelectRowById): New method to select a row based on its
5390     ID as opposed to its ordinal
5391     (DataTable.GetValue, TableGrid.OnRangeSelect)
5392     (TableGrid.OnSelectCell, LayerTableGrid.select_shapes)
5393     (QueryTableFrame.OnQuery, QueryTableFrame.get_selected)
5394     (LayerTableFrame.__init__): Convert between row ids and row
5395     ordinals as appropriate
5396    
5397     * test/postgissupport.py (PostGISDatabase.__init__): Add
5398     doc-string.
5399     (PostGISDatabase.initdb): The optional third item in a tuple in
5400     tables is now a (key, value) list with additional arguments to
5401     pass to upload_shapefile
5402     (upload_shapefile): New parameter gid_offset to allow gids that
5403     are not the same as the shapeids in the shapefile
5404     (PostgreSQLServer.get_default_static_data_db): Use the new
5405     gid_offset to make the gids in landmarks 1000 higher than the
5406     shapeids in the shapefile
5407    
5408     * test/test_viewport.py
5409     (TestViewportWithPostGIS.test_find_shape_at_point): Adapt to the
5410     new shapeids in the landmarks table
5411    
5412     * test/test_transientdb.py
5413     (TestTransientTable.run_iceland_political_tests)
5414     (TestTransientTable.test_transient_joined_table): Add tests for
5415     the new table methods and new keywords arguments.
5416    
5417     * test/test_postgis_db.py
5418     (TestPostGISTable.test_read_row_as_dict_row_count_mode)
5419     (TestPostGISTable.test_read_value_row_count_mode)
5420     (TestPostGISTable.test_row_id_to_ordinal)
5421     (TestPostGISTable.test_row_oridnal_to_id): New test for the new
5422     table methods and the new arguments
5423     (TestPostGISShapestorePoint.test_shapes_in_region)
5424     (TestPostGISShapestorePoint.test_shape_raw_data)
5425     (TestPostGISShapestorePoint.test_shape_points)
5426     (TestPostGISShapestorePoint.test_shape_shapeid)
5427     (TestPostGISShapestorePoint.test_all_shapes)
5428     (TestPostGISTable.test_simple_query)
5429     (TestPostGISTable.test_simple_query)
5430     (TestPostGISTable.test_simple_query)
5431     (TestPostGISTable.test_read_value)
5432     (TestPostGISTable.test_read_row_as_dict): Adapt to the new
5433     shapeids in the landmarks table
5434    
5435     * test/test_memory_table.py
5436     (TestMemoryTable.test_read_row_as_dict_row_count_mode)
5437     (TestMemoryTable.test_read_value_row_count_mode)
5438     (TestMemoryTable.test_row_id_to_ordinal)
5439     (TestMemoryTable.test_row_oridnal_to_id): New test for the new
5440     table methods and the new arguments
5441    
5442     * test/test_dbf_table.py
5443     (TestDBFTable.test_read_row_as_dict_row_count_mode)
5444     (TestDBFTable.test_read_value_row_count_mode)
5445     (TestDBFTable.test_row_id_to_ordinal)
5446     (TestDBFTable.test_row_oridnal_to_id): New test for the new table
5447     methods and the new arguments
5448    
5449 bh 1659 2003-08-26 Bernhard Herzog <[email protected]>
5450    
5451 bh 1661 * Thuban/Model/postgisdb.py (PostGISShapeStore.BoundingBox): Use a
5452     more postgis specific but much faster method to get the bounding
5453     box
5454    
5455     2003-08-26 Bernhard Herzog <[email protected]>
5456    
5457 bh 1659 * Thuban/Model/postgisdb.py (PostGISTable.Title)
5458     (PostGISShapeStore.AllShapes): Add these missing methods.
5459     (PostGISShapeStore.ShapesInRegion): No need to raise
5460     StopIteration. We can simply return
5461    
5462     * test/test_postgis_db.py (TestPostGISTable.test_title)
5463     (TestPostGISShapestorePoint.test_all_shapes): New tests for the
5464     new methods
5465    
5466 bh 1643 2003-08-25 Bernhard Herzog <[email protected]>
5467    
5468 bh 1657 * Thuban/Model/postgisdb.py (shapetype_map): Add MUTLIPOLYGON.
5469    
5470     * test/test_postgis_db.py (PolygonTests): New class containing
5471     those tests from TestPostGISShapestorePolygon that can also be
5472     used to test MUTLIPOLYGON tables
5473     (TestPostGISShapestorePolygon): Most tests are now in PolygonTests
5474     so derive from that
5475     (TestPostGISShapestoreMultiPolygon): New class with tests for
5476     MUTLIPOLYGON tables
5477    
5478     * test/postgissupport.py (PostGISDatabase.initdb): Allow the
5479     tables argument to have tuples with three items to override the
5480     WKT type used.
5481     (PostgreSQLServer.get_default_static_data_db): Use the above to
5482     create a polygon table with MUTLIPOLYGONs
5483     (point_to_wkt, coords_to_point, polygon_to_wkt, coords_to_polygon)
5484     (arc_to_wkt, coords_to_multilinestring): Rename from *_to_wkt to
5485     coords_to*
5486     (coords_to_multipolygon): New. Convert to MUTLIPOLYGON
5487     (wkt_converter): New. Map WKT types to converters
5488     (upload_shapefile): New parameter force_wkt_type to use a
5489     different WKT type than the default
5490    
5491     2003-08-25 Bernhard Herzog <[email protected]>
5492    
5493 bh 1655 * Thuban/UI/application.py
5494     (ThubanApplication.run_db_param_dialog): New. Suitable as a
5495     db_connection_callback. Main difference is that the dialog run
5496     from this method doesn't have a parent so it can be used even when
5497     there is no main window
5498     (ThubanApplication.OpenSession): Use self.run_db_param_dialog if
5499     no db_connection_callback was given. This way the dialog pops up
5500     even when the .thuban file was given as a command line parameter.
5501    
5502     2003-08-25 Bernhard Herzog <[email protected]>
5503    
5504 bh 1653 * Thuban/UI/view.py (MapCanvas.OnLeftUp): Release the the mouse
5505     before calling MouseLeftUp. MouseLeftUp may pop up modal dialogs
5506     which leads to an effectively frozen X session because the user
5507     can only interact with the dialog but the mouse is still grabbed
5508     by the canvas.
5509     Also, call the tool's Hide method before MouseLeftUp because
5510     MouseLeftUp may change the tool's coordinates.
5511    
5512     2003-08-25 Bernhard Herzog <[email protected]>
5513    
5514 bh 1651 * Thuban/UI/application.py (ThubanApplication.OpenSession): Catch
5515     LoadCancelled exceptions and handle them by returning immediately.
5516    
5517     2003-08-25 Bernhard Herzog <[email protected]>
5518    
5519 bh 1649 GUI part of loading sessions with postgis connections which may
5520     require user interaction to get passwords or updated parameters
5521    
5522     * Thuban/UI/dbdialog.py (DBDialog): Reimplement to make it look a
5523     bit nucer and be more generic.
5524     (DBFrame.OnAdd): Adapt to new DBDialog interface
5525    
5526     * Thuban/UI/application.py (ThubanApplication.OpenSession): New
5527     optional parameter db_connection_callback which is passed to
5528     load_session.
5529    
5530     * Thuban/UI/mainwindow.py (MainWindow.run_db_param_dialog): New.
5531     Suitable as a db_connection_callback
5532     (MainWindow.OpenSession): Use self.run_db_param_dialog as the
5533     db_connection_callback of the application's OpenSession method
5534    
5535    
5536     2003-08-25 Bernhard Herzog <[email protected]>
5537    
5538 bh 1647 Basic loading of sessions containing postgis connections:
5539    
5540     * Thuban/Model/load.py (LoadError): Add doc-string
5541     (LoadCancelled): New exception class to indicate a cancelled load
5542     (SessionLoader.__init__): Add the db_connection_callback parameter
5543     which will be used by the loader to get updated parameters and a
5544     password for a database connection
5545     (SessionLoader.__init__): Add the new XML elements to the
5546     dispatchers dictionary
5547     (SessionLoader.check_attrs): Two new conversions, ascii to convert
5548     to a byte-string object and idref as a generic id reference
5549     (SessionLoader.start_dbconnection)
5550     (SessionLoader.start_dbshapesource): New. Handlers for the new XML
5551     elements
5552     (load_session): Add the db_connection_callback to pass through the
5553     SessionLoader
5554    
5555     * test/test_load.py (TestPostGISLayer, TestPostGISLayerPassword):
5556     New classes to test loading of sessions with postgis database
5557     connections.
5558    
5559     2003-08-25 Bernhard Herzog <[email protected]>
5560    
5561 bh 1645 * Thuban/UI/mainwindow.py (__ThubanVersion__): Remove this and
5562     replace it and the comment with __BuildDate__ by the Source: and
5563     Id: cvs keywords as used in the other files.
5564    
5565     2003-08-25 Bernhard Herzog <[email protected]>
5566    
5567 bh 1643 * Thuban/Model/load.py (SessionLoader.check_attrs): Raise a
5568     LoadError when a required attribute is missing. The code used to
5569     be commented out for some reason, but probably should have been
5570     active.
5571    
5572     * test/test_load.py (TestLoadError.test): Test the message in the
5573     LoadError too to make sure it really is about the missing
5574     attribute
5575    
5576 bh 1632 2003-08-22 Bernhard Herzog <[email protected]>
5577 bh 1641
5578     * test/test_save.py (SaveSessionTest.test_dbf_table)
5579     (SaveSessionTest.test_joined_table): Add XML validation tests.
5580    
5581     2003-08-22 Bernhard Herzog <[email protected]>
5582    
5583 bh 1639 Implement saving a session with a postgis connection
5584 bh 1632
5585 bh 1639 * Resources/XML/thuban-0.9.dtd (dbconnection, dbshapesource) New
5586     elements for database connections and shapestores using db
5587     connections
5588     (session): Add the dbconnections to the content model
5589    
5590     * Thuban/Model/save.py (SessionSaver.write_db_connections): New.
5591     Write the db connections
5592     (SessionSaver.write_session): Call write_db_connections to write
5593     the connection before the data sources
5594     (SessionSaver.write_data_containers): Handle postgis shapestores
5595    
5596     * test/test_save.py (SaveSessionTest.thubanids)
5597     (SaveSessionTest.thubanidrefs): Update for new DTD
5598     (SaveSessionTest.test_save_postgis): New. Test saving a session
5599     with postgis connections
5600    
5601     * Thuban/Model/postgisdb.py (PostGISTable.DBConnection)
5602     (PostGISTable.TableName): New accessor methods for the connection
5603     and table name
5604    
5605     * test/test_postgis_db.py (TestPostGISTable.test_dbconn)
5606     (TestPostGISTable.test_dbname): New methods to test the new
5607     PostGISConnection methods
5608    
5609     2003-08-22 Bernhard Herzog <[email protected]>
5610    
5611 bh 1637 * Thuban/Model/postgisdb.py (ConnectionError): New exception class
5612     for exceptions occurring when establishing a Database connection
5613     (PostGISConnection.connect): Catch psycopg.OperationalError during
5614     connects and raise ConnectionError.
5615    
5616     * test/test_postgis_db.py (TestPostgisDBExceptions): New class for
5617     tests for database exceptions
5618    
5619     2003-08-22 Bernhard Herzog <[email protected]>
5620    
5621 bh 1635 Prepare the test suite for tests with required authentication
5622    
5623     * test/postgissupport.py (PostgreSQLServer.__init__): Add instance
5624     variables with two predefined users/passwords, one for the admin
5625     and one for a non-privileged user.
5626     (PostgreSQLServer.createdb): Pass the admin name to initdb and add
5627     the non-privileged user to the database and set the admin password
5628     (PostgreSQLServer.wait_for_postmaster): Use the admin user name.
5629     Better error reporting
5630     (PostgreSQLServer.connection_params)
5631     (PostgreSQLServer.connection_string): New methods to return
5632     information about how to connect to the server
5633     (PostgreSQLServer.execute_sql): New. Convenience method to execute
5634     SQL statements
5635     (PostgreSQLServer.require_authentication): Toggle whether the
5636     server requires authentication
5637     (PostgreSQLServer.create_user, PostgreSQLServer.alter_user): New.
5638     Add or alter users
5639     (PostGISDatabase.initdb): Pass the admin name one the
5640     subprocesses' command lines. Grant select rights on
5641     geometry_columns to everybody.
5642     (upload_shapefile): Use the admin name and password when
5643     connecting. Grant select rights on the new table to everybody.
5644    
5645     * test/test_viewport.py (TestViewportWithPostGIS.setUp): Use the
5646     server's new methods to get the connection parameters.
5647    
5648     * test/test_postgis_session.py (TestSessionWithPostGIS.setUp)
5649     (TestSessionWithPostGIS.test_remove_dbconn_exception): Use the
5650     server's new methods to get the connection parameters.
5651    
5652     * test/test_postgis_db.py
5653     (TestPostGISConnection.test_gis_tables_empty)
5654     (TestPostGISConnection.test_gis_tables_non_empty)
5655     (PostGISStaticTests.setUp): Use the server's new methods to get
5656     the connection parameters.
5657    
5658     2003-08-22 Bernhard Herzog <[email protected]>
5659    
5660 bh 1632 * Thuban/UI/about.py (About.__init__): Add the psycopg version.
5661    
5662     * Thuban/version.py: Add psycopg version
5663    
5664     * Thuban/Model/postgisdb.py (psycopg_version): New. Return the
5665     version of the psycopg module
5666    
5667     2003-08-22 Bernhard Herzog <[email protected]>
5668    
5669     * Thuban/UI/dbdialog.py (DBPwdDlg): Removed because it's not used.
5670     (DBFrame.OnEdit): Removed because it's not used and wouldn't work
5671     at the moment. The functionality should probably be implemented
5672     some time, though.
5673 bh 1633 (DBFrame.OnRemove): Display a message if the connection can't be
5674     removed because it's still in use.
5675 bh 1632
5676 jan 1629 2003-08-22 Jan-Oliver Wagner <[email protected]>
5677    
5678     * Thuban/UI/about.py (About.__init__): split up the huge about
5679     text into elements/lists for easier translation. This fixes bug
5680     https://intevation.de/rt/webrt?serial_num=2058
5681     Also, made some forgotten string available for the i18n.
5682    
5683 bh 1627 2003-08-21 Bernhard Herzog <[email protected]>
5684    
5685     Make postgis support really optional including insensitive menu
5686     items.
5687    
5688     * Thuban/Model/postgisdb.py (has_postgis_support): New. Return
5689     whether the postgis is supported.
5690    
5691     * Thuban/UI/dbdialog.py: Put the psycopg import into try..except
5692     to make postgis support optional
5693    
5694     * Thuban/UI/mainwindow.py (_has_postgis_support): New. Context
5695     version of Thuban.Model.postgisdb.has_postgis_support
5696     (database_management command): Make it only sensitive if postgis
5697     is supported.
5698    
5699 jan 1623 2003-08-21 Jan-Oliver Wagner <[email protected]>
5700    
5701 jan 1626 * Doc/manual/thuban-manual.xml: Added CVS revision for rev-history.
5702     (section Adding and Removing Layers): Added text and described
5703     multi-selection.
5704     (chapter Extensions): New.
5705    
5706     2003-08-21 Jan-Oliver Wagner <[email protected]>
5707    
5708 jan 1623 * Thuban/UI/mainwindow.py (MainWindow.AddLayer): Changed dialog
5709     settings to allow multiple files to load into the map.
5710     Also reduced selection to *.shp as a default.
5711    
5712 bh 1621 2003-08-20 Bernhard Herzog <[email protected]>
5713    
5714     Add dialogs and commands to open database connections and add
5715     database layers.
5716    
5717     * Thuban/UI/mainwindow.py (MainWindow.DatabaseManagement): New
5718     method to open the database connection management dialog
5719     (MainWindow.AddDBLayer): New method to add a layer from a database
5720     (_has_dbconnections): New helper function to use for sensitivity
5721     (database_management command, layer_add_db command): New commands
5722     that call the above new methods.
5723     (main_menu): Add the new commands to the menu.
5724    
5725     * Thuban/Model/postgisdb.py (PostGISConnection.__init__)
5726     (PostGISConnection.connect): Establish the actual connection in a
5727     separate method and call it in __init__. This makes it easier to
5728     override the behavior in test cases
5729     (PostGISConnection.BriefDescription): New method to return a brief
5730     description for use in dialogs.
5731    
5732     * test/test_postgis_db.py (NonConnection): DB connection that
5733     doesn't actually connect
5734     (TestBriefDescription): New class with tests for the new
5735     BriefDescription method
5736    
5737 jan 1619 2003-08-19 Jan-Oliver Wagner <[email protected]>
5738    
5739     Moved anything from extensions to libraries.
5740    
5741     * libraries: New.
5742    
5743     * libraries/ pyprojection, pyshapelib, shapelib, thuban: New.
5744    
5745     * libraries/pyprojection/ LICENSE, MANIFEST.in, Projection.i,
5746     Projection.py, Projection_wrap.c, setup.py, swighelp.txt: These files have
5747     been moved here from thuban/extensions/pyprojection/
5748     See there in the Attic for the older history.
5749    
5750     * libraries/pyshapelib/ COPYING, ChangeLog, NEWS, README, dbflib.i,
5751     dbflib.py, dbflib_wrap.c, pyshapelib_api.h, pytest.py, setup.py,
5752     shapelib.i, shapelib.py, shapelib_wrap.c, shptreemodule.c: These files
5753     have been moved here from thuban/extensions/pyshapelib/
5754     See there in the Attic for the older history.
5755    
5756     * libraries/shapelib/ dbfopen.c, shapefil.h, shpopen.c, shptree.c: These
5757     files have been moved here from thuban/extensions/shapelib/
5758     See there in the Attic for the older history.
5759    
5760     * libraries/thuban/ bmpdataset.cpp, cpl_mfile.cpp, cpl_mfile.h,
5761     gdalwarp.cpp, wxproj.cpp: These files have been moved here from
5762     thuban/extensions/thuban/
5763     See there in the Attic for the older history.
5764    
5765     * MANIFEST.in, setup.cfg, setup.py: renamed extensions to libraries.
5766    
5767     * extensions/thuban/ bmpdataset.cpp, cpl_mfile.cpp, cpl_mfile.h,
5768     gdalwarp.cpp, wxproj.cpp: Moved to libraries/thuban.
5769    
5770     * extensions/shapelib/ dbfopen.c, shapefil.h, shpopen.c, shptree.c:
5771     Moved to libraries/shapelib.
5772    
5773     * extensions/pyshapelib/ COPYING, NEWS, dbflib.py, pytest.py,
5774     shapelib.py, README, dbflib_wrap.c, setup.py, shapelib_wrap.c,
5775     ChangeLog, dbflib.i, pyshapelib_api.h, shapelib.i, shptreemodule.c:
5776     Moved to libraries/pyshapelib.
5777    
5778     * extensions/pyprojection/ MANIFEST.in, Projection.py, setup.py,
5779     LICENSE, Projection.i, Projection_wrap.c, swighelp.txt:
5780     Moved to libraries/pyprojection.
5781    
5782     * extensions/ pyprojection, pyshapelib, shapelib, thuban: Removed.
5783    
5784     * extensions: Removed.
5785    
5786 bh 1606 2003-08-19 Bernhard Herzog <[email protected]>
5787    
5788 bh 1609 * test/test_viewport.py (ViewPortTest): We don't use the
5789     facilities of FileTestMixin so don't derive from it.
5790     (TestViewportWithPostGIS): New class with tests for using a
5791     viewport on a map with postgis layers.
5792    
5793     2003-08-19 Bernhard Herzog <[email protected]>
5794    
5795     Add the db connection management to the session.
5796    
5797     * Thuban/Model/session.py (Session.__init__): New instance
5798     variable db_connections
5799     (Session.AddDBConnection, Session.DBConnections)
5800     (Session.HasDBConnections, Session.CanRemoveDBConnection)
5801     (Session.RemoveDBConnection): New methods to manage and query the
5802     db connections managed by the session
5803     (Session.OpenDBShapeStore): New method to open a shapestore from a
5804     db connection
5805    
5806     * Thuban/Model/messages.py (DBCONN_REMOVED, DBCONN_ADDED): New
5807     messages for the db connection handling in the session
5808    
5809     * test/test_postgis_session.py: New. test cases for the session's
5810     db connection handling with postgis connections
5811    
5812     2003-08-19 Bernhard Herzog <[email protected]>
5813    
5814 bh 1606 Add very basic postgis database support and the corresponding test
5815     cases. The test cases require a PostgreSQL + postgis installation
5816     but no existing database. The database will be created
5817     automatically by the test cases
5818    
5819     * test/README: Add note about skipped tests and the requirements
5820     of the postgis tests.
5821    
5822     * Thuban/Model/postgisdb.py: New. Basic postgis database support.
5823    
5824     * test/test_postgis_db.py: New. Test cases for the postgis
5825     support.
5826    
5827     * Thuban/Model/wellknowntext.py: New. Parser for well-known-text
5828     format
5829    
5830     * test/test_wellknowntext.py: New. Test cases for the
5831     wellknowntext parser
5832    
5833     * test/postgissupport.py: New. Support module for tests involving
5834     a postgis database.
5835    
5836     * test/support.py (execute_as_testsuite): Shut down the postmaster
5837     if it's still running after the tests
5838    
5839     * Thuban/Model/data.py (RAW_WKT): New constant for raw data in
5840     well known text format
5841    
5842 jan 1604 2003-08-19 Jan-Oliver Wagner <[email protected]>
5843    
5844     * Examples/simple_extensions/hello_world.py: New. Raises a Hello World
5845     message dialog.
5846    
5847 bh 1600 2003-08-18 Bernhard Herzog <[email protected]>
5848    
5849 bh 1602 * test/support.py (ThubanTestResult.printErrors): Indent the
5850     reason for the skips in the output to make it a bit more readable.
5851     (execute_as_testsuite): New helper function to run a test suite
5852     and print some more information.
5853     (run_tests): Use execute_as_testsuite to run the tests
5854    
5855     * test/runtests.py (main): Use execute_as_testsuite to run the
5856     tests
5857    
5858     2003-08-18 Bernhard Herzog <[email protected]>
5859    
5860 bh 1600 Fix some bugs in Thuban and the test suite that were uncovered by
5861     changes introduced in Python 2.3:
5862    
5863     * Thuban/Model/table.py (DBFTable.__init__): Make sure the
5864     filename is an absolute name
5865    
5866     * Thuban/Model/layer.py (RasterLayer.__init__): Make sure the
5867     filename is an absolute name
5868    
5869     * test/test_save.py (SaveSessionTest.testRasterLayer): Use a
5870     unique filename to save to and use the correct relative filename
5871     in the expected output.
5872     (SaveSessionTest.test_dbf_table): Use the correct relative
5873     filename in the expected output.
5874    
5875     * test/test_layer.py (TestLayer.test_raster_layer): Update the
5876     test to check whether the filename is absolute.
5877    
5878 jan 1596 2003-08-18 Jan-Oliver Wagner <[email protected]>
5879    
5880     * Thuban/UI/about.py (About.__init__): Added Silke Reimer.
5881    
5882 bh 1586 2003-08-15 Bernhard Herzog <[email protected]>
5883    
5884 bh 1594 Change the way shapes are returned by a shape store. The
5885     ShapesInRegion method returns an iterator over actual shape
5886     objects instead of a list of shape ids.
5887    
5888     * Thuban/Model/data.py (ShapefileShape.ShapeID): New. Return shape
5889     id.
5890     (ShapefileStore.ShapesInRegion): Return an iterator over the
5891     shapes which yields shape objects instead of returning a list of
5892     shape ids
5893     (ShapefileStore.AllShapes): New. Return an iterator over all
5894     shapes in the shape store
5895     (DerivedShapeStore.AllShapes): New. Like in ShapefileStore
5896    
5897     * Thuban/Model/layer.py (Layer.ShapesInRegion): Update
5898     doc-string.
5899    
5900     * Thuban/UI/baserenderer.py
5901     (BaseRenderer.layer_ids, BaseRenderer.layer_shapes): Rename to
5902     layer_shapes and make it return an iterator containg shapes
5903     instead of a list of ids.
5904     (BaseRenderer.draw_shape_layer): Update doc-string; Adapt to
5905     layer_shapes() change
5906    
5907     * Thuban/UI/renderer.py (ScreenRenderer.layer_ids)
5908     (ScreenRenderer.layer_shapes): Rename as in BaseRenderer
5909    
5910     * Thuban/UI/viewport.py (ViewPort._find_shape_in_layer): Adapt to
5911     changes in the ShapesInRegion return value.
5912     (ViewPort._get_hit_tester): Remove commented out code
5913    
5914     * test/mockgeo.py (SimpleShapeStore.ShapesInRegion): Adapt to the
5915     new return value.
5916     (SimpleShapeStore.AllShapes): New. Implement this method too.
5917    
5918     * test/test_layer.py (TestLayer.test_arc_layer)
5919     (TestLayer.test_polygon_layer, TestLayer.test_point_layer)
5920     (TestLayer.test_point_layer_with_projection)
5921     (TestLayer.test_derived_store): Adapt to changes in the
5922     ShapesInRegion return value.
5923    
5924     * test/test_shapefilestore.py
5925     (TestShapefileStoreArc.test_shapes_in_region)
5926     (TestShapefileStorePolygon.test_shapes_in_region)
5927     (TestShapefileStorePoint.test_shapes_in_region): Adapt to changes
5928     in the ShapesInRegion return value.
5929     (TestShapefileStorePoint.test_all_shapes)
5930     (TestShapefileStoreArc.test_shape_shapeid): New tests for the new
5931     methods
5932    
5933     * test/test_derivedshapestore.py
5934     (TestDerivedShapeStore.test_shapes_in_region): Adapt to changes in
5935     the ShapesInRegion return value.
5936     (TestDerivedShapeStore.test_all_shapes)
5937     (TestDerivedShapeStore.test_shape_shapeid): New tests for the new
5938     methods
5939    
5940     2003-08-15 Bernhard Herzog <[email protected]>
5941    
5942 bh 1592 Make the renderers deal correctly with raw vs. python level
5943     representation of shape geometries
5944    
5945     * Thuban/UI/baserenderer.py (BaseRenderer.low_level_renderer):
5946     Return a flag useraw in addition to the callable and the parameter
5947     to indicate whether the callable can deal with the raw shape data
5948     or uses the higher level python lists of coordinates. The callable
5949     now should accept either the raw data or the return value of the
5950     shape's Points() method.
5951     (BaseRenderer.draw_shape_layer): Adapt to the low_level_renderer
5952     change
5953     (BaseRenderer.projected_points): Instead of the shape id use the
5954     points list as parameter.
5955     (BaseRenderer.draw_polygon_shape, BaseRenderer.draw_arc_shape)
5956     (BaseRenderer.draw_point_shape): Adapt to projected_points()
5957     change and accept the points list as parameter instead of the
5958     shape id.
5959    
5960     * Thuban/UI/renderer.py (MapRenderer.low_level_renderer): Return
5961     the useraw flag as required by the BaseRenderer
5962     (ScreenRenderer.draw_shape_layer): Adapt to low-level renderer
5963     changes.
5964    
5965     * test/test_baserenderer.py
5966     (TestBaseRenderer.test_point_with_classification): New test for
5967     rendering a map with classifications.
5968    
5969     2003-08-15 Bernhard Herzog <[email protected]>
5970    
5971 bh 1590 * Thuban/UI/viewport.py (ViewPort.find_shape_at)
5972     (ViewPort._find_shape_in_layer, ViewPort._find_shape_in_layer)
5973     (ViewPort._get_hit_tester, ViewPort.projected_points)
5974     (ViewPort._hit_point, ViewPort._hit_arc, ViewPort._hit_polygon)
5975     (ViewPort._find_label_at): Split the find_shape_at method into
5976     several new methods and use the functions in the hit-test module.
5977    
5978     * Thuban/UI/hittest.py: New module with Python-level hit-testing
5979     functions
5980    
5981     * test/test_hittest.py: New. Test for the new hittest module
5982    
5983     2003-08-15 Bernhard Herzog <[email protected]>
5984    
5985 bh 1588 * Thuban/Model/layer.py (Layer.ShapesInRegion): Apply the layer
5986     projection to all corners of the bounding box to get a better
5987     approximation of the projected bounding box
5988    
5989     * test/test_layer.py (TestLayer.test_point_layer_with_projection):
5990     New. Test coordinate handling of a layer with a projection.
5991     Catches the bug fixed in Layer.ShapesInRegion
5992    
5993     2003-08-15 Bernhard Herzog <[email protected]>
5994    
5995 bh 1586 Move some of the mock objects in test_baserenderer into their own
5996     module so they can easily be used from other tests
5997    
5998     * test/mockgeo.py: New test helper module with some mock objects
5999     for geometry related things like shapes, shapestores and
6000     projections.
6001    
6002     * test/test_mockgeo.py: New. Tests for the new helper module
6003    
6004     * test/test_baserenderer.py: Some of the mock-objects are in
6005     mockgeo now.
6006    
6007 jan 1584 2003-08-12 Jan-Oliver Wagner <[email protected]>
6008    
6009     * Thuban/UI/about.py (About.__init__): Added Björn Broscheit.
6010    
6011 bh 1580 2003-08-12 Bernhard Herzog <[email protected]>
6012    
6013 bh 1582 * po/de.po: New. German translations by Bjoern Broscheit
6014    
6015     2003-08-12 Bernhard Herzog <[email protected]>
6016    
6017 bh 1580 * Thuban/UI/projdialog.py (UnknownProjPanel._DoLayout): Translated
6018     strings have to be one string literal.
6019    
6020 bh 1573 2003-08-11 Bernhard Herzog <[email protected]>
6021    
6022 bh 1578 * test/support.py (FloatComparisonMixin.assertPointListEquals):
6023     New. This method was used in various derived classes, but it's
6024     better to have it here.
6025    
6026     * test/test_shapefilestore.py
6027     (ShapefileStoreTests.assertPointListEquals): Removed. It's now in
6028     FloatComparisonMixin
6029    
6030     * test/test_layer.py (TestLayer.assertPointListEquals): Removed.
6031     It's now in FloatComparisonMixin
6032    
6033     * test/test_derivedshapestore.py
6034     (TestDerivedShapeStore.assertPointListEquals): Removed. It's now
6035     in FloatComparisonMixin
6036    
6037     2003-08-11 Bernhard Herzog <[email protected]>
6038    
6039 bh 1573 * Thuban/UI/join.py (JoinDialog.OnJoin): Add missing space to
6040     error message
6041    
6042 jan 1569 2003-08-08 Jan-Oliver Wagner <[email protected]>
6043    
6044 jan 1571 * Doc/manual/thuban-manual.xml: Now use authorgroup. Added revhistory
6045     with version number.
6046     Changed title to reflect version number of Thuban.
6047    
6048     2003-08-08 Jan-Oliver Wagner <[email protected]>
6049    
6050 jan 1569 * Thuban/UI/about.py (About.__init__): Reworked the hall of fame. Now
6051     the list corresponds to the "About" web page.
6052    
6053 bh 1567 2003-08-08 Bernhard Herzog <[email protected]>
6054    
6055     * Thuban/UI/projdialog.py (UTMProposeZoneDialog.dialogLayout):
6056     Make sure translated strings are recognized as one string literal.
6057    
6058     * Thuban/UI/proj4dialog.py (UTMProposeZoneDialog.dialogLayout):
6059     Make sure translated strings are recognized as one string literal.
6060    
6061     * Thuban/UI/classgen.py (ClassGenDialog.OnOK): Make sure
6062     translated strings are recognized as one string literal.
6063    
6064     * Thuban/UI/application.py (ThubanApplication.OpenSession): Make
6065     sure translated strings are recognized as one string literal.
6066    
6067 bh 1556 2003-08-07 Bernhard Herzog <[email protected]>
6068    
6069 bh 1565 * Thuban/Model/data.py (DerivedShapeStore.RawShapeFormat): New.
6070     Simply delegates to the original shapestore.
6071    
6072     * test/test_derivedshapestore.py
6073     (TestDerivedShapeStore.test_raw_format): New. Test case for
6074     DerivedShapeStore.RawShapeFormat
6075    
6076     2003-08-07 Bernhard Herzog <[email protected]>
6077    
6078 bh 1561 Add raw data interface to shape objects.
6079    
6080     * Thuban/Model/data.py (ShapefileShape, Shape): Rname the shape
6081     class to ShapefileShape which now holds shapefile specific
6082     information.
6083     (ShapefileShape.compute_bbox): Simplified to not cache any
6084     information. The way this method is used that shouldn't matter
6085     performance wise.
6086     (ShapefileShape.RawData): New. Return the shapeid which is the raw
6087     data format for shapes from shapefiles.
6088     (ShapefileStore.RawShapeFormat): New. Return the raw datatype used
6089     in the shape objects returned by a shapestore. For a
6090     ShapefileStore this is always RAW_SHAPEFILE.
6091     (RAW_PYTHON, RAW_SHAPEFILE): Constants for the RawShapeFormat
6092     method.
6093    
6094     * test/test_shapefilestore.py
6095     (TestShapefileStore.test_raw_format): New test to test the raw
6096     format feature of shapes.
6097    
6098 bh 1560 * Thuban/Model/layer.py: Remove the unused import of Shape from
6099     data. It was only there for interface compatibility but it's not
6100 bh 1561 used inside of Thuban and the generic Shape class has gone away.
6101 bh 1560
6102 bh 1563 * Thuban/UI/renderer.py (MapRenderer.low_level_renderer): Check
6103     the raw data format and only use an optimized version of its a
6104     shapefile.
6105    
6106 bh 1561 2003-08-07 Bernhard Herzog <[email protected]>
6107    
6108 bh 1559 * test/test_baserenderer.py (SimpleShape): Shape class for the
6109     tests.
6110     (SimpleShapeStore.Shape): Use SimpleShape instead of
6111     Thuban.Model.data.Shape to make the tests independed of the coming
6112     changes.
6113    
6114     2003-08-07 Bernhard Herzog <[email protected]>
6115    
6116 bh 1556 * test/support.py (SkipTest, ThubanTestResult, ThubanTestRunner)
6117     (ThubanTestProgram): New classes that extend the respective
6118     classes from unittest. These new version support skipping tests
6119     under certain expected conditions. In the Thuban test suite we
6120     uses this for tests that require the optional gdal support.
6121     (run_tests): Use ThubanTestProgram instead of the unittest.main()
6122    
6123     * test/runtests.py (main): Use the new ThubanTestRunner instead of
6124     the normal one from unittest
6125    
6126     * test/test_layer.py (TestLayer.test_raster_layer): If this test
6127     is not run because gdal support isn't available report this to the
6128     runner.
6129    
6130     * test/test_baserenderer.py
6131     (TestBaseRenderer.test_raster_no_projection): Do not run this test
6132     if gdal support isn't available and report this to the runner.
6133    
6134 bh 1553 2003-08-06 Bernhard Herzog <[email protected]>
6135    
6136     Rearrange the renderers a bit, partly in preparation for changes
6137     required for the postgis merge, partly to make it more testable.
6138     Also make the representation of coordinates in Shapes more
6139     consistent.
6140    
6141     * Thuban/UI/renderer.py (MapRenderer): Most of the code/methods in
6142     this class is now in BaseRenderer. This class is now practically
6143     only a specialization of BaseRenderer for rendering to an actual
6144     wx DC.
6145     (ScreenRenderer.draw_shape_layer): Use self.low_level_renderer()
6146     to get the shapetype specific rendering functions.
6147    
6148     * Thuban/UI/baserenderer.py: New file with the basic rendering
6149     logic. The code in this file is completely independend of wx.
6150     (BaseRenderer): Class with the basic rendering logic
6151    
6152     * test/test_baserenderer.py: New. Test cases for BaseRenderer
6153    
6154     * Thuban/UI/view.py (MapCanvas.__init__): New instance variable
6155     error_on_redraw to guard agains endless loops and stack overflows
6156     when there's a bug in the rendering code that raises exceptions.
6157     (MapCanvas.OnIdle, MapCanvas._do_redraw): Split the actual
6158     rendering into a separate method _do_redraw so that error handling
6159     is a bit easier. When an exception occurs, set error_on_redraw to
6160     true. When it's true on entry to OnIdle do nothing and return
6161     immediately.
6162    
6163     * Thuban/Model/data.py (ShapefileStore.Shape): For consistency, a
6164     Shape object will always have the coordinates as a list of list of
6165     coordinate pairs (tuples).
6166     (Shape.compute_bbox): Adapt to new representation.
6167    
6168     * Thuban/UI/viewport.py (ViewPort.find_shape_at)
6169     (ViewPort.LabelShapeAt): Adapt to new coordinate representation in
6170     Shape objects.
6171    
6172     * test/test_shapefilestore.py
6173     (ShapefileStoreTests.assertFloatTuplesEqual)
6174     (ShapefileStoreTests.assertPointListEquals): Rename to
6175     assertPointListEquals and change purpose to checking equality of
6176     the lists returned by Shape.Points().
6177     (TestShapefileStoreArc.test_shape)
6178     (TestShapefileStorePolygon.test_shape)
6179     (TestShapefileStorePoint.test_shape): Use the new
6180     assertPointListEquals instead of assertFloatTuplesEqual
6181    
6182     * test/test_layer.py (TestLayer.assertFloatTuplesEqual)
6183     (TestLayer.assertPointListEquals): Rename to assertPointListEquals
6184     and change purpose to checking equality of the lists returned by
6185     Shape.Points().
6186     (TestLayer.test_arc_layer, TestLayer.test_arc_layer)
6187     (TestLayer.test_polygon_layer, TestLayer.test_point_layer)
6188     (TestLayer.test_derived_store): Use the new assertPointListEquals
6189     instead of assertFloatTuplesEqual
6190    
6191     * test/test_derivedshapestore.py
6192     (TestDerivedShapeStore.assertFloatTuplesEqual)
6193     (TestDerivedShapeStore.assertPointListEquals): Rename to
6194     assertPointListEquals and change purpose to checking equality of
6195     the lists returned by Shape.Points().
6196     (TestDerivedShapeStore.test_shape): Use the new
6197     assertPointListEquals instead of assertFloatTuplesEqual
6198    
6199 jan 1550 2003-08-06 Jan-Oliver Wagner <[email protected]>
6200    
6201     * Thuban/UI/projdialog.py (UTMPanel._OnPropose): Added test for
6202     a bounding box. A dialog is raised in case, no bounding box
6203     is found. This fixes bug #2043:
6204     https://intevation.de/rt/webrt?serial_num=2043
6205    
6206 bh 1548 2003-08-05 Bernhard Herzog <[email protected]>
6207    
6208     * Thuban/Model/color.py (Color.__repr__): Make the repr of a color
6209     object look like a Color instantiation. Formerly it looked like a
6210     tuple.
6211    
6212     * test/test_color.py (TestColor.test_repr)
6213     (TestColor.test_equality, TestColor.test_inequality): New. test
6214     some more apects of the Color class
6215     (TestTransparent.test_repr, TestTransparent.test_hex)
6216     (TestTransparent.test_equality): New. Test cases for the
6217     Transparent object.
6218    
6219 jan 1545 2003-08-04 Jan-Oliver Wagner <[email protected]>
6220    
6221     * Doc/manual/thuban-manual.xml: a number of small improvements.
6222     The resulting file is the version submitted for GREAT-ER II.
6223    
6224 bh 1540 2003-08-01 Bernhard Herzog <[email protected]>
6225    
6226 bh 1543 * Thuban/UI/resource.py, Thuban/UI/projdialog.py,
6227     Thuban/UI/join.py, Thuban/UI/classgen.py, Thuban/UI/about.py,
6228     Thuban/Model/resource.py: Insert cvs keywords and doc-strings.
6229    
6230     * Thuban/UI/common.py: Insert cvs keywords and doc-strings.
6231     (Color2wxColour, wxColour2Color, ThubanBeginBusyCursor)
6232     (ThubanEndBusyCursor): Add doc-strings
6233    
6234     2003-08-01 Bernhard Herzog <[email protected]>
6235    
6236 bh 1540 First step towards PostGIS integration. More abstraction by movin
6237     more code from the layer to the shapestore. More methods of the
6238     layer are now simply delegated to the equivalent method of the
6239     shapestore. The SHAPETYPE_* constants are now in data not in
6240     layer.
6241    
6242     * Thuban/Model/data.py (SHAPETYPE_POLYGON, SHAPETYPE_ARC)
6243     (SHAPETYPE_POINT, Shape): Move these constants and classes from
6244     layer.py to data.py
6245     (ShapefileStore.__init__): More Initialization for the new methods
6246     and functionality.
6247     (ShapefileStore.ShapeType, ShapefileStore.NumShapes)
6248     (ShapefileStore.BoundingBox, ShapefileStore.ShapesInRegion)
6249     (ShapefileStore.Shape): New methods that were formerly implemented
6250     in the layer.
6251     (DerivedShapeStore.Shape, DerivedShapeStore.ShapesInRegion)
6252     (DerivedShapeStore.ShapeType, DerivedShapeStore.NumShapes)
6253     (DerivedShapeStore.BoundingBox): New. DerivedShapeStore
6254     equivalents of the new shape methods. These versions are simply
6255     delegated to the original shapstore.
6256    
6257     * Thuban/Model/layer.py (SHAPETYPE_POLYGON, SHAPETYPE_ARC)
6258     (SHAPETYPE_POINT, Shape): Removed. They're now in data.py
6259     (Layer.SetShapeStore): Removed the initializatin of instance
6260     variables that were needed for the stuff that's now in
6261     ShapefileStore
6262     (Layer.BoundingBox, Layer.NumShapes, Layer.ShapeType)
6263     (Layer.Shape, Layer.ShapesInRegion): Simply delegate to the
6264     shapestore.
6265    
6266     * Thuban/UI/classifier.py, Thuban/UI/renderer.py,
6267     Thuban/UI/viewport.py: Import the SHAPETYPE_* constants from data
6268     instead of layer.
6269    
6270     * test/test_shapefilestore.py: New. Tests for ShapefileStore.
6271    
6272     * test/test_derivedshapestore.py: New. Tests for DerivedShapeStore.
6273    
6274     * test/test_layer.py: Import the SHAPETYPE_* constants from data
6275     instead of layer.
6276     (TestLayer.test_derived_store): Remove the test for the exception
6277     when instantiating the DerivedShapeStore with an incompatible
6278     table which is now in test_derivedshapestore.py. Add some more
6279     tests of the layer methods to determine whether they work for a
6280     DerivedShapeStore as well.
6281    
6282 jonathan 1534 2003-07-31 Jonathan Coles <[email protected]>
6283    
6284     * Doc/manual/thuban-manual.xml: Fix the list of required packages
6285     by just listing the name and where they can be found.
6286    
6287 frank 1532 2003-07-31 Frank Koormann <[email protected]>
6288    
6289     * Doc/manual/thuban-manual.xml:
6290     Changed the screenshot elements to figure.
6291     Changed some variablelist elements to itemizedlist.
6292     Added section on GDAL formats.
6293    
6294 jonathan 1531 2003-07-31 Jonathan Coles <[email protected]>
6295    
6296     * Doc/manual/thuban-manual.xml: Added a few sentences about
6297     the Fix Border Color option when generating classes.
6298    
6299 jonathan 1529 2003-07-30 Jonathan Coles <[email protected]>
6300    
6301     * Thuban/Model/classgen.py: Add docstrings. Rename specific
6302     Ramp instances to use lower_case_style.
6303    
6304     * Thuban/UI/classgen.py: Use renamed Ramp instances.
6305    
6306     * Thuban/UI/classifier.py: Add docstrings.
6307    
6308     * Thuban/UI/dock.py: Add docstrings.
6309    
6310     * test/test_classgen.py: Use renamed Ramp instances.
6311    
6312 bh 1522 2003-07-30 Bernhard Herzog <[email protected]>
6313    
6314 bh 1524 * Thuban/Lib/connector.py (QueueingPublisher): Removed. This class
6315     was never used in Thuban.
6316    
6317     2003-07-30 Bernhard Herzog <[email protected]>
6318    
6319 bh 1522 * Thuban/UI/join.py (JoinDialog.__init__): Use the table's Title()
6320     method directly instead of going through the transient_table
6321     method. This faster because transient_table may force the copy of
6322     a DBF file into the transient database and setting a table's title
6323     doesnm't affect the title of the associated transient table, so
6324     this fixes RT #2042
6325    
6326     * Thuban/UI/main.py (__version__): Don't import the already
6327     removed show_exception_dialog.
6328    
6329 jonathan 1517 2003-07-29 Jonathan Coles <[email protected]>
6330    
6331 jonathan 1519 * Thuban/UI/application.py (ThubanApplication.ShowExceptionDialog):
6332     Put back this method and remove the equivalent function since we
6333     are setting the exception hook from within this class (OnInit).
6334    
6335     2003-07-29 Jonathan Coles <[email protected]>
6336    
6337 jonathan 1517 * Doc/manual/images/5_2_custom_ramp.png,
6338     Doc/manual/images/5_2_quantiles.png,
6339     Doc/manual/images/5_2_uniform_dist.png,
6340     Doc/manual/images/5_2_unique_values.png,
6341     Doc/manual/images/8_int_error.png: New screen shots.
6342    
6343     * Doc/manual/thuban-manual.xml: Fixed typos and wording, clarified
6344     some points, and added more screen shots.
6345    
6346 bh 1512 2003-07-29 Bernhard Herzog <[email protected]>
6347    
6348 bh 1516 * Thuban/Model/data.py: Remove the now unused import of warnings
6349    
6350     2003-07-29 Bernhard Herzog <[email protected]>
6351    
6352 bh 1514 * Thuban/Model/data.py (SimpleStore): Removed. This class has been
6353     deprecated since before the 0.8 release and isn't used in Thuban
6354     itself anymore.
6355    
6356 bh 1512 * Thuban/Model/transientdb.py: Remove some unnecessary imports
6357    
6358 jonathan 1503 2003-07-29 Jonathan Coles <[email protected]>
6359 jonathan 1506
6360     * Thuban/UI/application.py (ThubanApplication.OnInit): set the
6361     python exception hook here so that we are sure to catch any
6362     Thuban exception that happen during initialization.
6363    
6364     * Thuban/UI/main.py (main): Don't set the exception hook here,
6365     it will get set in ThubanApplication.OnInit.
6366    
6367     2003-07-29 Jonathan Coles <[email protected]>
6368 jonathan 1503
6369     * Thuban/UI/application.py (ThubanApplication.ShowExceptionDialog):
6370     Removed and called it show_exception_dialog() so that the exception
6371     handler can be set before the class is created.
6372    
6373     * Thuban/UI/main.py (main): Install the exception handler before
6374     a ThubanApplication is created.
6375    
6376 bh 1500 2003-07-29 Bernhard Herzog <[email protected]>
6377    
6378     * po/it.po: New. Italian translation by Maurizio Napolitano
6379    
6380     * po/ru.po: New. Russian translation by Alex Shevlakov
6381    
6382 frank 1497 2003-07-29 Frank Koormann <[email protected]>
6383    
6384 frank 1508 * Doc/manual/thuban-manual.xml: Extended section on supported
6385     projections.
6386    
6387     2003-07-29 Frank Koormann <[email protected]>
6388    
6389 frank 1497 * Doc/manual/thuban-manual.xml: gaspell-checked.
6390    
6391 jonathan 1493 2003-07-29 Jonathan Coles <[email protected]>
6392    
6393 jonathan 1495 * Doc/manual/images/3_5_legend.png: Added border to improve look
6394     on white background.
6395    
6396     2003-07-29 Jonathan Coles <[email protected]>
6397    
6398 jonathan 1493 * Doc/manual/thuban-manual.xml: Fixed grammar and typos. Added
6399     descriptions for the legend toolbar.
6400    
6401     * Doc/manual/images/4_2_raster_layer_properties.png: Removed
6402     cursor from dialog box.
6403    
6404     2003-07-28 Jonathan Coles <[email protected]>
6405    
6406     * Doc/manual/thuban-manual.xml: More screenshots and more chapters.
6407    
6408     * Doc/manual/images/2_4_session_tree.png,
6409     Doc/manual/images/3_5_legend.png, Doc/manual/images/3_rename_map.png,
6410     Doc/manual/images/4_2_layer_properties.png,
6411     Doc/manual/images/4_2_raster_layer_properties.png,
6412     Doc/manual/images/5_3_genclass.png,
6413     Doc/manual/images/5_classification.png,
6414     Doc/manual/images/6_projection.png,
6415     Doc/manual/images/7_1_table_view.png,
6416     Doc/manual/images/7_2_5_join.png: New screenshots.
6417    
6418     2003-07-24 Jonathan Coles <[email protected]>
6419    
6420     * Doc/manual/thuban-manual.xml: Chapter on Projection Management.
6421    
6422     2003-07-24 Jonathan Coles <[email protected]>
6423    
6424     * Doc/manual/thuban-manual.xml: Added EPS images and wrote
6425     chapter on Layer Management.
6426    
6427     * Doc/manual/Makefile: New. Makefile to generate all formats for the
6428     manual and images.
6429    
6430 bh 1483 2003-07-24 Bernhard Herzog <[email protected]>
6431    
6432     * Thuban/Model/range.py, Thuban/version.py: Remove the #! line as
6433     it annoys lintian which warns about these files not being
6434 jan 1767 executable. The #! isn't necessary here since if you absolutely
6435 bh 1483 must execute them you can always say "python <filename>".
6436    
6437     * Thuban/UI/renderer.py (ScreenRenderer.draw_shape_layer): Remove
6438     superfluous code to set brush and pen for point shapes
6439    
6440     * Thuban/UI/viewport.py: Remove commented out code that wouldn't
6441     belong in viewport anyway
6442    
6443 frank 1479 2003-07-24 Frank Koormann <[email protected]>
6444    
6445     * Doc/manual/thuban-manual.xml: Added section on table management.
6446    
6447 bh 1477 2003-07-24 Bernhard Herzog <[email protected]>
6448    
6449     * test/runtests.py (main): Recognize the long "verbose" option
6450     correctly.
6451    
6452 jonathan 1470 2003-07-22 Jonathan Coles <[email protected]>
6453    
6454     * Doc/manual/thuban-manual.xml: Continue to write first revision
6455     of the manual.
6456    
6457     * Thuban/UI/renderer.py (MapRenderer.render_map): Wrap method
6458     with Begin/EndDrawing() calls to ensure we aren't doing to
6459     many updates to the dc during rendering.
6460     (ScreenRenderer.draw_shape_layer): self.draw_point_shape takes
6461     a pen and brush argument so they need to be passed to the function.
6462    
6463     * Thuban/UI/viewport.py (ViewPort.calc_min_max_scales): New.
6464     Calculates the minimum and maximum scale values. Factored out
6465     of set_view_transform so that it could be used to zoom all the
6466     way into a single point.
6467     (ViewPort.set_view_transform): Call calc_min_max_scales().
6468     (ViewPort.FitSelectedToWindow): Zoom to the maximum scale
6469     if only a single point is selected.
6470    
6471     * Doc/manual/images/1_2_legend_close.png,
6472     Doc/manual/images/1_2_legend_dock.png,
6473     Doc/manual/images/1_2_mainwindow.png,
6474     Doc/manual/images/1_2_mainwindow.ps,
6475     Doc/manual/images/1_2_mainwindow.sk,
6476     Doc/manual/images/3_2_fullextent.png,
6477     Doc/manual/images/3_2_fulllayerextent.png,
6478     Doc/manual/images/3_2_fullshapeextent.png,
6479     Doc/manual/images/3_2_pan.png,
6480     Doc/manual/images/3_2_zoomin.png,
6481     Doc/manual/images/3_2_zoomout.png,
6482     Doc/manual/images/3_3_identify.png,
6483     Doc/manual/images/3_3_label.png,
6484     Doc/manual/images/3_5_invisible.png,
6485     Doc/manual/images/3_5_movedown.png,
6486     Doc/manual/images/3_5_moveup.png,
6487     Doc/manual/images/3_5_props.png,
6488     Doc/manual/images/3_5_tobottom.png,
6489     Doc/manual/images/3_5_totop.png,
6490     Doc/manual/images/3_5_visible.png: New. Images for the documentation.
6491    
6492 bh 1451 2003-07-18 Bernhard Herzog <[email protected]>
6493    
6494 bh 1465 * Thuban/UI/messages.py (MAP_REPLACED): New message.
6495    
6496     * Thuban/UI/viewport.py (ViewPort.SetMap): Issue MAP_REPLACED
6497     after the new map has been assigned
6498    
6499     * Thuban/UI/mainwindow.py (MainWindow.delegated_messages):
6500     Delegate MAP_REPLACED to the canvas too
6501     (MainWindow.prepare_new_session): Removed. Thanks to the new
6502     MAP_REPLACED message it's no longer needed
6503     (MainWindow.OpenSession, MainWindow.NewSession):
6504     prepare_new_session has been removed.
6505    
6506     * Thuban/UI/classifier.py (Classifier.__init__): Subscribe to
6507     MAP_REPLACED so that we can close the dialog if a new map is set.
6508     (Classifier.unsubscribe_messages): Unsubscribe from MAP_REPLACED
6509     (Classifier.map_replaced): Handle MAP_REPLACED by closing the
6510     dialog
6511    
6512     * test/test_viewport.py (SimpleViewPortTest)
6513     (SimpleViewPortTest.test_default_size): Add doc-strings
6514     (ViewPortTest.setUp): Bind map to self.map so we can use it in
6515     tests. Subscribe to MAP_REPLACED messages too.
6516     (ViewPortTest.tearDown): No need to explicitly unsubscribe
6517     (ViewPortTest.test_set_map): New test for the SetMap method.
6518    
6519     2003-07-18 Bernhard Herzog <[email protected]>
6520    
6521 bh 1463 * test/test_viewport.py (SimpleViewPortTest.test_default_size):
6522     Move this test from ViewPortTest.setUp to this new separate test
6523     case. setUp is not the place for the actual tests.
6524     (ViewPortTest.test_inital_settings, ViewPortTest.setUp): Move some
6525     more of the test from setUp to the new test test_inital_settings.
6526     (ViewPortTest.test_win_to_proj, ViewPortTest.test_proj_to_win)
6527     (ViewPortTest.test_proj_conv): Split test_proj_conv into
6528     test_win_to_proj and test_proj_to_win and make the tests easier to
6529     understand
6530     (ViewPortTest.testFitRectToWindow, ViewPortTest.testZoomFactor)
6531     (ViewPortTest.testZoomOutToRect, ViewPortTest.testTranslate)
6532     (ViewPortTest.test_unprojected_rect_around_point)
6533     (ViewPortTest.test_find_shape_at, ViewPortTest.testTools):
6534     Reformat to increase readability.
6535    
6536     2003-07-18 Bernhard Herzog <[email protected]>
6537    
6538 bh 1461 * Thuban/UI/view.py (MapCanvas.OnLeftDown): Capture the mouse.
6539    
6540     2003-07-18 Bernhard Herzog <[email protected]>
6541    
6542 bh 1459 * test/runtests.py: The test suite can now be run without an X
6543     connection. To make sure this remains true, remove the DISPLAY
6544     environment variable so that an error occurs if the wxGTK is
6545     imported accidentally
6546    
6547     2003-07-18 Bernhard Herzog <[email protected]>
6548    
6549 bh 1457 * Thuban/UI/viewport.py: Remove unused imports
6550    
6551     * Thuban/UI/view.py: Remove unused imports
6552    
6553     2003-07-18 Bernhard Herzog <[email protected]>
6554    
6555 bh 1455 * test/test_export.py Remove unused imports. The OutputTransform
6556     function is now in viewport.py and is called output_transform
6557     (TestScalebar.test_output_transform)
6558     (TestScalebar.test_OutputTransform): Renamed to
6559     test_output_transform and updated to use output_transform instead
6560     of OutputTransform
6561    
6562     * Thuban/UI/view.py (OutputTransform): Moved to viewport.py and
6563     renamed.
6564     (MapCanvas.Export, MapPrintout.draw_on_dc): OutputTransform was
6565     renamed to output_transform
6566    
6567     * Thuban/UI/viewport.py (OutputTransform, output_transform):
6568     Rename to output_transform
6569    
6570     2003-07-18 Bernhard Herzog <[email protected]>
6571    
6572 bh 1453 * Thuban/Model/layer.py (Layer.__init__): Rename
6573     classificationField to classificatin_column and init it here so
6574     that it can be used in SetClassificationColumn
6575     (Layer.GetClassificationColumn, Layer.GetClassificationField):
6576     Rename to GetClassificationColumn.
6577     (Layer.SetClassificationColumn, Layer.SetClassificationField):
6578     Rename to SetClassificationColumn and issue a LAYER_CHANGED
6579     message if the column changes.
6580     (Layer._classification_changed, Layer.ClassChanged): Rename to
6581     _classification_changed. Update the callers.
6582     (Layer.SetShapeStore): Further field->column renames.
6583    
6584     * Thuban/Model/load.py (SessionLoader.start_classification)
6585     (SessionLoader.start_clpoint): Updates because of
6586     field->column method name changes in the Layer class
6587    
6588     * Thuban/Model/save.py (SessionSaver.write_classification): Updates
6589     because of field->column method name changes in the Layer class
6590    
6591     * Thuban/UI/classifier.py (Classifier.__init__)
6592     (Classifier._OnTry, Classifier._OnRevert): Updates because of
6593     field->column method name changes in the Layer class
6594    
6595     * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Updates
6596     because of field->column method name changes in the Layer class
6597    
6598     * Thuban/UI/viewport.py (ViewPort.find_shape_at): Updates because
6599     of field->column method name changes in the Layer class
6600    
6601     * test/test_save.py (SaveSessionTest.testClassifiedLayer)
6602     (SaveSessionTest.testClassifiedLayer): Update because of
6603     field->column method name changes in the Layer class
6604    
6605     * test/test_layer.py (SetShapeStoreTests.setUp)
6606     (SetShapeStoreTests.test_sanity): Update because of field->column
6607     method name changes in the Layer class
6608     (TestLayerModification.setUp): Subscribe to LAYER_CHANGED as well
6609     (TestLayerModification.test_sanity)
6610     (TestLayerModification.test_initial_settings): remove unsued code
6611     and rename to test_sanity.
6612     (TestLayerModification.test_set_classification): New test for
6613     SetClassification and SetClassificationField.
6614    
6615     2003-07-18 Bernhard Herzog <[email protected]>
6616    
6617 bh 1451 * test/test_classgen.py (TestFixedRamp.test): Extend test to check
6618     the non-fixed values as well. The old test would have accepted a
6619     fixed ramp that only returnes the fixed properties
6620    
6621 jonathan 1449 2003-07-17 Jonathan Coles <[email protected]>
6622    
6623     * Doc/manual/mainwindow.png, Doc/manual/mainwindow.xcf: Screen
6624     shots for the manual. The XCF file is the source image and
6625     has additional layers to support changes.
6626    
6627     * Doc/manual/thuban-manual.xml: Wrote an initial Introduction.
6628    
6629     * Thuban/UI/classifier.py (Classifier.__BuildClassification):
6630     Return both the new class and the field name.
6631    
6632     * Thuban/UI/mainwindow.py (MainWindow.ToggleLegend): Don't
6633     fit the map to the window as this changes any zoom level that
6634     the user may have set.
6635    
6636 jonathan 1442 2003-07-16 Jonathan Coles <[email protected]>
6637    
6638     * Thuban/Model/classgen.py (generate_singletons,
6639     generate_uniform_distribution, generate_quantiles): Remove
6640     fixes parameter, but maintain the same functionality by having
6641     the calling function pass a FixedRamp object for the ramp.
6642     (FixedRamp): New. Adapts a ramp to have fixed property values.
6643    
6644     * Thuban/Model/classification.py: Use new CLASS_CHANGED message.
6645     (Classification): Inherit from Publisher.
6646     (Classification.__init__): Remove the layer parameter.
6647     Classifications no longer need to have a parent layer.
6648     (Classification.GetField, Classification.GetFieldType,
6649     Classification.SetFieldInfo): Removed. The field name is stored
6650     in the layer, and the type can be retreived by calling
6651     Layer.GetFieldType().
6652     (Classification._set_layer, Classification.GetLayer): Removed.
6653     Classifications no longer have a parent layer.
6654    
6655     * Thuban/Model/layer.py (Layer.Destroy): Unsubscribe from the
6656     classification.
6657     (Layer.SetShapeStore): Reset the classification first while
6658     we still have the old shape store to work with.
6659     (Layer.GetClassificationField, Layer.SetClassificationField):
6660     New. Method for getting/setting the field to classify on.
6661     (Layer.SetClassification): Simplified now that the layer
6662     simply has to hold a reference to the classification and not
6663     tell the classification who owns it.
6664     Fixes RTbug #2023.
6665    
6666     * Thuban/Model/load.py (SessionLoader.start_classification):
6667     Set the field name on the layer, not the classification.
6668    
6669     * Thuban/Model/messages.py: Add CLASS_CHANGED for when a
6670     classification is modified.
6671    
6672     * Thuban/Model/save.py (SessionSaver.write_classification):
6673     Get the field name and type from the layer.
6674    
6675     * Thuban/Model/table.py (table_to_dbf, table_to_csv): Renamed
6676     parameter records to rows and add docstring. Fixes RTbug #1997.
6677    
6678     * Thuban/UI/classgen.py (ClassGenDialog.OnOK): Use a fixed
6679     ramp when we need to fix certain values of a ramp rather than
6680     using the old fixes parameter. Fixes RTbug #2024.
6681    
6682     * Thuban/UI/classifier.py (ClassGrid.CreateTable): Add fieldType
6683     parameter.
6684     (ClassTable.Reset): Add fieldType parameter and use it, rather
6685     than asking the classification.
6686     (Classifier.__init__): Remember the original class's field
6687     and ask the layer for the field type, rather than the classification.
6688     (Classifier.__SetGridTable): Retrieve the field and field type
6689     for the table because they are not in the classification.
6690     (Classifier._OnTry, Classifier._OnRevert): Set the classification
6691     field on the layer in addition to the classification itself.
6692    
6693     * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Get the
6694     classification field from layer.
6695    
6696     * Thuban/UI/viewport.py (ViewPort.find_shape_at): Get the
6697     classification field from layer. Split up tests and remove
6698     *-imports. Fixes RTbug #1992.
6699    
6700     * test/test_classgen.py (TestFixedRamp): Test for the FixedRamp class.
6701    
6702     * test/test_classification.py
6703     (TestClassification.test_classification): Remove tests for methods
6704     that no longer exist.
6705    
6706     * test/test_layer.py (SetShapeStoreTests.setUp): Classification
6707     __init__ no longer has a field parameter, use SetClassificationField.
6708     (SetShapeStoreTests.test_sanity): Use layer object to get class
6709     field info.
6710    
6711     * test/test_save.py (SaveSessionTest.testClassifiedLayer): Use
6712     SetClassificationField on layer to set class field info.
6713    
6714     * test/test_viewport.py: Renamed from test/test_view.py.
6715    
6716 jan 1424 2003-07-16 Jan-Oliver Wagner <[email protected]>
6717    
6718     * Doc/manual/thuban-manual.xml: Added authors and an initial
6719     coarse structure.
6720    
6721 bh 1418 2003-07-15 Bernhard Herzog <[email protected]>
6722    
6723 bh 1422 * test/support.py (FloatComparisonMixin): This is a mix-in class
6724     and therefore should not be derived from any other class.
6725    
6726     * test/test_range.py (RangeTest): FloatComparisonMixin is a
6727     mix-in, so derive from TestCase as well.
6728    
6729     2003-07-15 Bernhard Herzog <[email protected]>
6730    
6731 bh 1420 * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Rework the
6732     draw_func handling a bit to remove one layer of indirection. This
6733     makes the renderer about 10% faster in the non-classifying case
6734     and the code a bit cleaner
6735     (MapRenderer.draw_point_shape): Add the pen and brush parameters
6736     and set them in the dc. Now the draw_point_shape method and
6737     wxproj's draw_polygon_shape function have basically the same
6738     signature so that both can be directly used as draw_func
6739    
6740     2003-07-15 Bernhard Herzog <[email protected]>
6741    
6742 bh 1418 * Thuban/Model/save.py (SessionSaver.write_classification): Encode
6743     string values (in addition to the labels) as UTF 8
6744    
6745     * Thuban/Model/load.py (SessionLoader.start_clpoint): Decode the
6746     values if the field type is string
6747    
6748     * test/test_save.py (SaveSessionTest.testClassifiedLayer): Test
6749     saving a session with non-ascii string classification values.
6750    
6751     * test/test_load.py (TestClassification.file_contents)
6752     (TestClassification.test): Check for non-ascii values in string
6753     classifications
6754    
6755 jonathan 1416 2003-07-14 Jonathan Coles <[email protected]>
6756    
6757     * test/test_view.py: New. Tests for ViewPort.
6758    
6759 frank 1409 2003-07-14 Frank Koormann <[email protected]>
6760    
6761     * Thuban/Model/load.py (SessionLoader.start_map): Encode map
6762     title to latin1. Fixes https://intevation.de/rt/webrt?serial_num=2013
6763    
6764 frank 1411 * test/test_load_0_8.py (TestUnicodeStrings): New, test load of
6765     unicode strings from session file: session title, map title and
6766     projection name.
6767    
6768 jonathan 1403 2003-07-10 Jonathan Coles <[email protected]>
6769    
6770 jonathan 1406 * Thuban/UI/viewport.py (Tool.MouseUp): Should have called
6771     drag_stop, not drag_move when the mouse is released.
6772    
6773     2003-07-10 Jonathan Coles <[email protected]>
6774    
6775 jonathan 1403 The most important part of this is the seperation of view.py into
6776     two pieces. viewport.py now has a class called ViewPort which
6777     contains all the non-wx parts of view.py and can therefore be
6778     tested. view.py contains only the wx-specific parts and is fairly
6779     simple.
6780    
6781     * Thuban/UI/view.py: Stripped out all non-wx functionality. Fixes
6782     RTTbug #1992.
6783     * Thuban/UI/viewport.py: New. Contains non-wx view functionality.
6784     RTTbug #1992.
6785    
6786     * Thuban/Model/classgen.py (generate_singletons,
6787     generate_uniform_distribution, generate_quantiles):
6788     Added 'fixes' parameter so that property attributes can
6789     be held constant over the generated classification groups.
6790     (CustomRamp.GetProperties): Remove unused variables.
6791    
6792     * Thuban/Model/map.py (Map.SetProjection): Send the old
6793     projection as an argument to listeners of the MAP_PROJECTION_CHANGED
6794     event.
6795    
6796     * Thuban/Model/table.py (table_to_dbf, table_to_csv): Added 'records'
6797     parameter which is a list of records that restricts which
6798     records are saved. Fixes RTbug #1997.
6799    
6800     * Thuban/UI/application.py (ThubanApplication.ShowExceptionDialog):
6801     Port exception dialog from GREAT-ER. Fixes RTbug #1993.
6802    
6803     * Thuban/UI/classgen.py (ClassGenDialog.__init__): Add controls
6804     to allow the user to fix line color/width on generated groups.
6805     (ClassGenDialog.OnOK): Use new 'fixes' parameter of the generate_*
6806     functions to optionally fix group properties.
6807    
6808     * Thuban/UI/main.py (main): Set exception hook to the
6809     ShowExceptionDialog. Fixes RTbug #1993.
6810    
6811     * Thuban/UI/mainwindow.py (MainWindow.ShowTableView): Raise
6812     the table window when it is selectd to be shown.
6813    
6814     * Thuban/UI/tableview.py (QueryTableFrame.__init__): Add an
6815     Export Selection button and move the export buttons underneath
6816     the table.
6817     (QueryTableFrame.UpdateStatusText): Added event argument so
6818     that it can respond to grid selection events. The status text
6819     is now updated even when the table is not associated with a
6820     layer as was previously assumed.
6821     (QueryTableFrame.OnGridSelectRange, OnGridSelectCell): Removed.
6822     UpdateStatusText responds to these events.
6823     (QueryTableFrame.OnSaveAs): Renamed to doExport.
6824     (QueryTableFrame.doExport): Helper function that saves the
6825     entire table, or selected rows, to a file.
6826     (QueryTableFrame.OnExport, QueryTableFrame.OnExportSel): New.
6827     Respond to export button events and call doExport.
6828    
6829     * extensions/thuban/gdalwarp.cpp (ProjectRasterFile): Make sure
6830     the function doesn't return NULL without first setting a Python
6831     Error.
6832    
6833     * test/runtests.py (main): Only print "Unknown option" for
6834     unsupported options.
6835    
6836     * test/support.py (FloatComparisonMixin.assertFloatEqual): Take
6837     optional epsilon argument to specify floating point accuracy.
6838     (FloatComparisonMixin.assertFloatSeqEqual): Call assertFloatEqual
6839     for each item test.
6840    
6841     * test/test_csv_table.py (TestCSVTable.test_table_to_cvs): Add
6842     tests for saving selected records.
6843    
6844     * test/test_dbf_table.py (TestTableToDBF.test_table_to_dbf): Add
6845     tests for saving selected records.
6846    
6847     * test/test_map.py (TestMapWithContents.test_set_projection):
6848     MAP_PROJECTION_CHANGED events send the old projection.
6849    
6850     * test/test_session.py
6851     (TestSessionWithContent.test_forward_map_projection):
6852     MAP_PROJECTION_CHANGED events send the old projection.
6853    
6854     * test/test_table.py (TableTest): Update tests to use non-deprecated
6855     functions.
6856    
6857 bh 1376 2003-07-08 Bernhard Herzog <[email protected]>
6858    
6859 bh 1382 * Thuban/Model/transientdb.py (TransientTableBase.Width): The type
6860     constants in the column objects are the standard ones defined in
6861     the table module.
6862    
6863     * test/test_transientdb.py
6864     (TestTransientTable.test_transienttable_to_dbf): New. Test whether
6865     exporting transient tables as DBF works. This should catch the bug
6866     just fixed in TransientTableBase.Width.
6867    
6868     2003-07-08 Bernhard Herzog <[email protected]>
6869    
6870 bh 1380 * Thuban/Model/classgen.py (CustomRamp.GetProperties): Compute the
6871     interpolated colors correctly.
6872    
6873     * test/test_classgen.py (TestCustomRamp.test_color_interpolation):
6874     New. Test case for the fix in classgen.py
6875    
6876     2003-07-08 Bernhard Herzog <[email protected]>
6877    
6878 bh 1378 * test/runtests.py (main): Make the default output less verbose
6879     and add a verbosity option (-v) to get the old output
6880    
6881     2003-07-08 Bernhard Herzog <[email protected]>
6882    
6883 bh 1376 * Resources/XML/thuban-0.9.dtd: New. This will become the DTD for
6884     0.9.
6885    
6886     * Thuban/Model/transientdb.py (TransientJoinedTable.JoinType):
6887     New. Return the join type
6888    
6889     * Thuban/Model/save.py (SessionSaver.write_session): Use new 0.9
6890     DTD
6891     (SessionSaver.write_data_containers): Save the join type for
6892     joined tables
6893    
6894     * Thuban/Model/load.py (SessionLoader.__init__): Add the new 0.9
6895     namespace
6896     (SessionLoader.start_jointable): Handle the jointype attribute
6897    
6898     * test/test_load_0_8.py: New. Effectively a copy of test_load.py
6899     as of Thuban 0.8. These are now tests to determine whether Thuban
6900     can still read files generated by Thuban 0.8
6901    
6902     * test/test_load.py (LoadSessionTest.dtd)
6903     (TestSingleLayer.file_contents)
6904     (TestLayerVisibility.file_contents, TestLabels.file_contents)
6905     (TestLayerProjection.file_contents)
6906     (TestRasterLayer.file_contents, TestJoinedTable.file_contents)
6907     (TestJoinedTable.file_contents)
6908     (TestLoadError.file_contents): Update for new DTD
6909     (TestJoinedTable.file_contents, TestJoinedTable.setUp): Add test
6910     for new join type attribute
6911    
6912     * test/test_save.py (SaveSessionTest.dtd)
6913     (SaveSessionTest.testEmptySession)
6914     (SaveSessionTest.testSingleLayer)
6915     (SaveSessionTest.testLayerProjection)
6916     (SaveSessionTest.testRasterLayer)
6917     (SaveSessionTest.testClassifiedLayer)
6918     (SaveSessionTest.test_dbf_table)
6919     (SaveSessionTest.test_joined_table): Update for new DTD
6920     (SaveSessionTest.test_joined_table): Add test for new join type
6921     attribute
6922    
6923 bh 1372 2003-07-04 Bernhard Herzog <[email protected]>
6924    
6925     * Thuban/Model/table.py (_find_dbf_column_names): New. Helper
6926     function for table_to_dbf
6927     (table_to_dbf): Deal with names longer than the 10 character limit
6928    
6929     * test/test_dbf_table.py (TestTableToDBF.test_table_to_dbf): Add
6930     doc-string
6931     (TestTableToDBF.test_table_to_dbf_long_col_names): New test for
6932     long column names
6933    
6934 bh 1365 2003-07-03 Bernhard Herzog <[email protected]>
6935    
6936 bh 1370 * Doc/manual/thuban-manual.xml: Fix the CVS Revision Tag syntax
6937    
6938     2003-07-03 Bernhard Herzog <[email protected]>
6939    
6940 bh 1368 * Doc/manual/thuban-manual.xml, Doc/manual/README: New. Skeleton
6941     for the Thuban manual and README with some basic information about
6942     the manual
6943    
6944     2003-07-03 Bernhard Herzog <[email protected]>
6945    
6946 bh 1365 * Thuban/Model/transientdb.py (TransientJoinedTable.__init__):
6947     Update doc-string
6948     (TransientJoinedTable.create): Do not modify the column objects of
6949     the input tables in place and copy all columns of the input tables
6950     into the joined table after all.
6951    
6952     * test/test_transientdb.py
6953     (TestTransientTable.test_transient_joined_table_same_column_name):
6954     Update to reflect the new behavior
6955     (TestTransientTable.test_transient_joined_table_with_equal_column_names):
6956     Update to reflect the new behavior
6957     (TestTransientTable.test_transient_joined_table_name_collisions_dont_modify_in_place):
6958     New test case for a bug which modified the column objects in place
6959    
6960 jonathan 1360 2003-07-02 Jonathan Coles <[email protected]>
6961 jonathan 1349
6962 jonathan 1360 * Thuban/Model/classgen.py (generate_singletons,
6963     generate_uniform_distribution, generate_quantiles,
6964 jonathan 1363 GenQuantiles0): Make sure maxValue isn't less than
6965     one, otherwise we could divide by zero.
6966    
6967     * test/test_classgen.py (ClassGenTest.doClassRangeTest,
6968     ClassGenTest.doClassSingleTest): Call doBoundsTest to
6969     check the end classification groups against the
6970     proper property values.
6971     (ClassGenTest.doBoundsTest): New. Checks the first and
6972     last classification groups to make sure their properties
6973     are the correct upper and lower bounds for a color ramp.
6974    
6975     2003-07-02 Jonathan Coles <[email protected]>
6976    
6977     * Thuban/Model/classgen.py (generate_singletons,
6978     generate_uniform_distribution, generate_quantiles,
6979 jonathan 1360 GenQuantiles0): The denominator was one to high when
6980     calculating the index for the ramp causing the index
6981     to never to reach one.
6982    
6983     2003-07-02 Jonathan Coles <[email protected]>
6984    
6985 jonathan 1358 Changed the singature of ClassGroupRange.__init__ and
6986     ClassGroupRange.SetRange() so that the min/max values are
6987     passed as a tuple. This makes a better calling scheme for
6988     when a Range object is passed instead.
6989    
6990     * Thuban/Model/classgen.py: Fixed parameters to
6991     ClassGroupRange constructor.
6992    
6993     * Thuban/Model/classification.py (ClassGroupRange.__init__):
6994     Consolidate the min/max parameters into a single _range which
6995     can either be a tuple or a Range object.
6996     (ClassGroupRange.SetRange): Consolidate the min/max parameters
6997     into a single _range which can either be a tuple or a Range object.
6998    
6999     * Thuban/Model/load.py (SessionLoader.start_clrange): Fix
7000     call to ClassGroupRange constructor to use a tuple.
7001    
7002     * Thuban/Model/layer.py (Layer.SetClassification): Switch
7003     the classification instance variable to the new class
7004     before calling _set_layer otherwise subscribers to a
7005     LAYER_CHANGED event will not see any difference.
7006    
7007     * test/test_classification.py: Fix tests of ClassGroupRange
7008     so that they use the new signature.
7009    
7010     * test/test_load.py: Fix use of ClassGroupRange so that it
7011     uses the new signature.
7012    
7013     * test/test_load_0_2.py: Fix use of ClassGroupRange so that it
7014     uses the new signature.
7015    
7016     * test/test_save.py: Fix use of ClassGroupRange so that it
7017     uses the new signature.
7018    
7019    
7020     2003-07-01 Jonathan Coles <[email protected]>
7021    
7022 jonathan 1349 * Thuban/Model/classgen.py: Fixes RTbug #1972, 1971.
7023     Import used objects/class from color.
7024     (generate_singletons): We don't
7025     need the numGroups parameter anymore because we are using
7026     the new ramps with GetProperties().
7027     (generate_uniform_distribution): Use new ramp method
7028     GetProperties().
7029     (generate_quantiles, GenQuantiles0): Use new ramp method
7030     GetProperties().
7031     (CustomRamp.SetNumGroups): Removed. The ramps now map
7032     a value from 0 to 1 to class properties so the number
7033     of groups is not needed ahead of time.
7034     (CustomRamp.next): Removed. CustomRamp does not support
7035     interation anymore.
7036     (CustomRamp.GetProperties): Returns a ClassGroupProperties
7037     object based on the index value from 0 to 1 that is
7038     passed to it.
7039     (GreyRamp, RedRamp, GreenRamp, BlueRamp, GreenToRedRamp):
7040     Made into instances of Monochromatic class instread of
7041     deriving from it.
7042     (HotToCold.SetNumGroups): Removed. See CustomRamp.
7043     (HotToCold.next): Removed. See CustomRamp.
7044    
7045     * Thuban/Model/classification.py: Fixes RTbug #1973, 1971.
7046     (Classification.SetField, Classification.SetFieldType):
7047     Replaced with SetFieldInfo.
7048     (Classification.SetFieldInfo): New. Does a better job of
7049     what SetField and SetFieldType used to do by combining
7050     their function since they should really always be done
7051     at the same time.
7052     (Classification.SetLayer): Renamed to _set_layer.
7053     (Classification._set_layer): Should only be called from
7054     Layer's SetClassification. This does not cause a recursive
7055     call as SetLayer did because we know that Layer knows about
7056     the classification.
7057    
7058     * Thuban/Model/color.py: Fixes RTbug #1971.
7059     (_Transparent): Renamed from Transparent so it doesn't
7060     conflict with the module variable.
7061     (Transparent, Black): Renamed from Color.Transparent,
7062     Color.Black so they are not class variables.
7063    
7064     * Thuban/Model/layer.py: Fixes RTbug #1971, 1973.
7065     (Layer.Destroy): We don't need to call SetClassification
7066     anymore to clear out the back reference in the classifcation
7067     to the layer. It's better to set it to None using _set_layer,
7068     and we won't be creating another clas object too.
7069     (Layer.SetClassification): Classification._set_layer is not
7070     recursive so remove all the locking variables. Also clean
7071     up the code so that it remains unchanged if something fails.
7072    
7073     * Thuban/Model/load.py: Fixes RTbug #1971.
7074     (SessionLoader.start_classification): Call
7075     Classification.SetFieldInfo().
7076    
7077     * Thuban/Model/save.py: Removed import of Color which wasn't
7078     being used.
7079    
7080     * Thuban/UI/classgen.py: Fixes RTbug #1972.
7081     (ClassGenDialog.__init__): Color ramps are now instances
7082     already so we don't need to create any new objects.
7083     (ClassGenDialog.OnOK): Check for numGroups is no longer
7084     necessary because we never use it.
7085    
7086     * Thuban/UI/classifier.py: Fixes RTbug #1971.
7087     (Classifier.__BuildClassification, Classifier.__SetGridTable):
7088     Call Classification.SetFieldInfo() instead of SetFieldType.
7089    
7090     * Thuban/UI/renderer.py: Fixes RTbug #1971.
7091    
7092     * Thuban/UI/view.py: Fixes RTbug #1974, 1971.
7093     (MapCanvas.__init__): Subscribe to the idle time event. Set
7094     background color to white.
7095     (MapCanvas.OnPaint): Set a flag indicating that we should
7096     render the map during idle time. If we already have a bitmap
7097     just draw it now.
7098     (MapCanvas.OnIdle): New. Render the map only during idle time.
7099     This also fixes a problem with the busy cursor under gtk.
7100    
7101     * test/test_classgen.py (ClassGenTest.test_generate_singletons):
7102     Fix calls to generate_singletons because the signature changed.
7103    
7104     * test/test_classification.py: Fix color references and
7105     change calls to Classification.[SetField|SetFieldType] to
7106     SetFieldInfo.
7107    
7108     * test/test_load.py: Fix color references.
7109    
7110     * test/test_load_0_2.py: Fix color references.
7111    
7112     * test/test_save.py (SaveSessionTest.testClassifiedLayer):
7113     Change calls to Classification.[SetField|SetFieldType] to
7114     SetFieldInfo.
7115    
7116 frank 1334 2003-07-01 Frank Koormann <[email protected]>
7117    
7118     MERGE from the greater-ms3 branch.
7119    
7120     * test/test_transientdb.py
7121     (TestTransientTable.test_transient_joined_table_with_equal_column_names):
7122     New. Test join of two tables with partly equal column names.
7123    
7124     * Thuban/Model/transientdb.py (TransientJoinedTable.create):
7125     If duplicates in left and right tables column names are found,
7126     append '_' (underscores) to the name until it is unique.
7127     Create always new internal names for the resulting table and reference
7128     columns in the join statement with <table>.<column>
7129    
7130 bh 1329 2003-07-01 Bernhard Herzog <[email protected]>
7131    
7132     * test/test_transientdb.py
7133     (TestTransientTable.test_transient_joined_table_same_column_name):
7134     New. Test whether joining on columns with the same names in both
7135     tables works.
7136 frank 1334
7137 bh 1329 * Thuban/Model/transientdb.py (TransientJoinedTable.create): Make
7138     sure to use the right internal names even when joining on field
7139     with the same names in both tables. Also, detect duplicate names
7140     in the joined table correctly.
7141    
7142 frank 1325 2003-07-01 Frank Koormann <[email protected]>
7143    
7144     * Thuban/UI/renderer.py (ExportRenderer.render_legend):
7145     Reverse List of layers to render in same order as in desktop legend.
7146    
7147 jonathan 1318 2003-06-30 Jonathan Coles <[email protected]>
7148    
7149 jonathan 1349 * Thuban/version.py (make_tuple): Takes a version string
7150     and splits it into a tuple of at most three integers.
7151     Used make_tuple() to make tuple versions of the version
7152     numbers.
7153    
7154     * Thuban/UI/about.py: Add Thuban email addresses.
7155    
7156     2003-06-30 Jonathan Coles <[email protected]>
7157    
7158 jonathan 1320 * Thuban/version.py: SQLite/PySQLite version dependencies
7159     were too high.
7160    
7161     2003-06-30 Jonathan Coles <[email protected]>
7162    
7163 jonathan 1318 * Thuban/version.py: Update version to 0.8.1
7164    
7165     * MANIFEST.in: Added Projections so that default.proj is
7166     included.
7167    
7168 jonathan 1312 2003-06-26 Jonathan Coles <[email protected]>
7169    
7170     New About box with lots more information including library
7171     versions and credits. More/better version checking before
7172     Thuban starts.
7173    
7174     * Thuban/UI/about.py: New. New About box that displays
7175     library version information and credits.
7176    
7177     * Thuban/version.py: Added new 'versions' dictionary which
7178     contains the verions of various libraries which are checked
7179     when the module loads.
7180     (verify_versions): Check all version numbers and returns
7181     a list of errors.
7182    
7183     * Thuban/UI/classifier.py (Classifier.__EnableButtons):
7184     Reset the status of the buttons as the situation warrants,
7185     but in a better more reliable way by not relying on the
7186     current status to determine what needs to change.
7187    
7188     * Thuban/UI/main.py (wxCHECK_VERSION): Removed. Not needed.
7189     (verify_versions): Remove most of the code since it is
7190     now in Thuban.version.verify_versions.o
7191    
7192     * Thuban/UI/mainwindow.py (MainWindow.About): Call new
7193     About box in Thuban.UI.about.
7194    
7195     * extensions/thuban/gdalwarp.cpp (get_gdal_version): New.
7196     Returns the version of gdal library being used as a string.
7197    
7198     * extensions/thuban/wxproj.cpp (check_version, check_version_gtk):
7199     Removed.
7200     (get_proj_version): Return the version of PROJ that the file
7201     was compiled with.
7202     (get_gtk_version): Return th version of GTK that the file
7203     was compiled with.
7204    
7205 jonathan 1304 2003-06-25 Jonathan Coles <[email protected]>
7206    
7207     * Thuban/UI/classifier.py (Classifier.EditSymbol): The parent
7208     of the SelectPropertiesDialog should be self so the window
7209     appears on top.
7210     (ClassGroupPropertiesCtrl.DoEdit): The parent
7211     of the SelectPropertiesDialog should be self so the window
7212     appears on top.
7213    
7214     * Thuban/UI/resource.py: Cleaned up how we determine file
7215     extensions.
7216     (GetImageResource): Return an wxImage from our Resources.
7217    
7218 jonathan 1299 2003-06-24 Jonathan Coles <[email protected]>
7219    
7220     * Thuban/UI/renderer.py (ExportRenderer.render_legend):
7221     Check that a layer has a classification before trying
7222     to get it. Raster layers don't have classifications.
7223    
7224 jonathan 1286 2003-06-23 Jonathan Coles <[email protected]>
7225 jonathan 1297
7226     * setup.py: Add Resources/XML to resource list.
7227    
7228     2003-06-23 Jonathan Coles <[email protected]>
7229 jonathan 1286
7230 jonathan 1297 * setup.cfg: Fix copyright dates
7231    
7232     2003-06-23 Jonathan Coles <[email protected]>
7233    
7234 jonathan 1294 * MANIFEST.in: Update with Resources/XML
7235    
7236     * setup.py: Don't include Locale resources yet as we don't
7237     have any and it causes problems building the distribution
7238     for Windows. Update version to 0.8.0.
7239    
7240     * Doc/thuban.dtd: Removed since it is now in Resources/XML.
7241    
7242     * Thuban/UI/mainwindow.py: Add blank line at the end because
7243     file was not being read correctly building the Windows
7244     distribution.
7245    
7246     2003-06-23 Jonathan Coles <[email protected]>
7247    
7248 jonathan 1289 * Thuban/UI/mainwindow.py (MainWindow.About): Fix text.
7249    
7250     * Thuban/version.py: Temporarily update longversion for
7251     the 0.8 release so that it doesn't have the cvs revision.
7252    
7253     2003-06-23 Jonathan Coles <[email protected]>
7254    
7255 jonathan 1286 * Thuban/UI/common.py (ThubanBeginBusyCursor): Call wxSafeYield
7256     to make sure that we don't create reentrant possibilities with
7257     wxYield.
7258    
7259     * Thuban/UI/view.py (MapCanvas.OnPaint): Call wxBeginBusyCursor()
7260     directly to avoid the wxSafeYield() call which generates an
7261     OnPaint event causing infinite recursion. Don't try to catch
7262     exception anymore. This was for before there were limits on map
7263     scaling.
7264    
7265 bh 1283 2003-06-23 Bernhard Herzog <[email protected]>
7266    
7267     Bug fix for RT #1961:
7268    
7269     * Thuban/Model/load.py (SessionLoader.start_derivedshapesource):
7270     Register DerivedShapestores with the session
7271    
7272     * Thuban/Model/session.py (Session.Tables): Make sure each table
7273     is only listed once.
7274    
7275     * test/test_load.py (TestJoinedTable.test): Add check_format call.
7276     Update file contents to match the one written out.
7277    
7278 bh 1281 2003-06-20 Bernhard Herzog <[email protected]>
7279    
7280     * test/xmlsupport.py (SaxEventLister.startElementNS)
7281     (SaxEventLister.endElementNS): Do not include the qname. Python
7282     2.2.1 and 2.2.2 and 2.2.3 differ in this regard. In 2.2.1 qname it
7283     is (presumably incorrectly) None, whereas it's a string with the
7284     element name in the later versions.
7285    
7286     * test/test_xmlsupport.py (TestEventList.test_even_list_simple)
7287     (TestEventList.test_even_list_namespace): Update tests to reflect
7288     the new behaviour
7289     (TestEventList.test_even_list_id_normalization): Fix doc-string
7290    
7291 jonathan 1272 2003-06-20 Jonathan Coles <[email protected]>
7292    
7293 jonathan 1279 * Thuban/Model/layer.py (BaseLayer.HasShapes): New. Overridden
7294     by deriving classes to determine if that layer supports shapes.
7295     (Layer): Override HasShapes and return true.
7296    
7297     * Thuban/UI/classgen.py: Use Thuban[Begin|End]BusyCursor()
7298     instead of a direct call to wx[Begin|End]CusyCursor().
7299     (GenUniquePanel._OnRetrieve): Set busy cursor while retrieving
7300     table data.
7301    
7302     * Thuban/UI/common.py (ThubanBeginBusyCursor, ThubanEndBusyCursor):
7303     New. Wrappers around the wxWindows functions that allow us to
7304     make additional calls such as wxYield which gives the native
7305     system a chance to update the cursor correctly.
7306    
7307     * Thuban/UI/tableview.py: Use Thuban[Begin|End]BusyCursor()
7308     instead of a direct call to wx[Begin|End]CusyCursor().
7309    
7310     * Thuban/UI/view.py: Use Thuban[Begin|End]BusyCursor()
7311     instead of a direct call to wx[Begin|End]CusyCursor().
7312     (MapCanvas.find_shape_at): Check if the current search layer
7313     support shapes, otherwise go on to the next layer.
7314    
7315     * test/test_layer.py: Add tests in each type of layer for
7316     HasClassification() and HasShapes()
7317    
7318     2003-06-20 Jonathan Coles <[email protected]>
7319    
7320 jonathan 1272 * Thuban/UI/view.py (MapCanvas.OnPaint): Call wxYield after
7321     turning on the busy cursor to allow the system to change the
7322     cursor before we begin painting. This fixes a problem that
7323     was occuring only under GTK. Fixes RTbug #1840.
7324    
7325 bh 1270 2003-06-20 Bernhard Herzog <[email protected]>
7326    
7327     * Resources/XML/thuban-0.8.dtd: New DTD for the new file format
7328     version.
7329    
7330     * Thuban/Model/save.py (sort_data_stores): New. Make topological
7331     sort of the data sources so they can be written with sources that
7332     data sources that depend on other data sources come after the
7333     sources they depend on.
7334     (SessionSaver.__init__): Add idmap instance variable to map from
7335     objects to the ids used in the file.
7336     (SessionSaver.get_id, SessionSaver.define_id)
7337     (SessionSaver.has_id): New. Methods to manage the idmap
7338     (SessionSaver.write): Use thuban-0.8.dtd
7339     (SessionSaver.write_session): Add a namespace on the session and
7340     write out the data sources before the maps.
7341     (SessionSaver.write_data_containers): New. Write the data
7342     containers.
7343     (SessionSaver.write_layer): Layer elements now refer to a
7344     shapestore and don't contain filenames anymore.
7345    
7346     * Thuban/Model/load.py (LoadError): Exception class to raise when
7347     errors in the files are discovered
7348     (SessionLoader.__init__): Define dispatchers for elements with a
7349     thuban-0.8 namespace too.
7350     (SessionLoader.check_attrs): New helper method to check and
7351     convert attributes
7352     (AttrDesc): New. Helper class for SessionLoader.check_attrs
7353     (SessionLoader.start_fileshapesource)
7354     (SessionLoader.start_derivedshapesource)
7355     (SessionLoader.start_filetable, SessionLoader.start_jointable):
7356     Handlers for the new elements in the new fileformat
7357     (SessionLoader.start_layer): Handle the shapestore attribute in
7358     addition to filename.
7359     (SessionLoader.start_table, SessionLoader.end_table): Removed.
7360     They were never used in the old formats and aren't needed for the
7361     new.
7362    
7363     * Thuban/Model/session.py (Session.DataContainers): New method to
7364     return all "data containers", i.e. shapestores and tables
7365    
7366     * test/xmlsupport.py (SaxEventLister.__init__)
7367     (SaxEventLister.startElementNS, sax_eventlist): Add support to
7368     normalize IDs.
7369    
7370     * test/test_xmlsupport.py
7371     (TestEventList.test_even_list_id_normalization): New test case for
7372     id normalization
7373    
7374     * test/test_load.py (LoadSessionTest.check_format): Use ID
7375     normalization
7376     (LoadSessionTest.thubanids, LoadSessionTest.thubanidrefs): New
7377     class atrributes used for ID normalization
7378     (TestSingleLayer, TestLayerVisibility, TestLabels.test)
7379     (TestLayerProjection.test, TestRasterLayer.test): Adapt to new
7380     file format
7381     (TestJoinedTable): New test for loading sessions with joined
7382     tables.
7383     (TestLoadError): New. Test whether missing required attributes
7384     cause a LoadError.
7385    
7386     * test/test_save.py (SaveSessionTest.thubanids)
7387     (SaveSessionTest.thubanidrefs): New class attributes for ID
7388     normalization in .thuban files.
7389     (SaveSessionTest.compare_xml): Use id-normalization.
7390     (SaveSessionTest.testEmptySession)
7391     (SaveSessionTest.testLayerProjection)
7392     (SaveSessionTest.testRasterLayer)
7393     (SaveSessionTest.testClassifiedLayer): Adapt to new file format.
7394     (SaveSessionTest.testLayerProjection): The filename used was the
7395     same as for testSingleLayer. Use a different one.
7396     (SaveSessionTest.test_dbf_table)
7397     (SaveSessionTest.test_joined_table): New test cases for saving the
7398     new data sources structures.
7399     (TestStoreSort, MockDataStore): Classes to test the sorting of the
7400     data stores for writing.
7401    
7402     * test/runtests.py: Add CVS keywords
7403    
7404 jonathan 1265 2003-06-20 Jonathan Coles <[email protected]>
7405    
7406 jonathan 1267 * test/test_session.py
7407     (UnreferencedTablesTests.test_unreferenced_tables_with_joins):
7408     Use the cultural_landmark-point.dbf file for the store so that
7409     the table rows and shape count match.
7410    
7411     2003-06-20 Jonathan Coles <[email protected]>
7412    
7413 jonathan 1265 * Thuban/Model/data.py (DerivedShapeStore.__init__): Raise
7414     an exception if the number of shapes is different from the
7415     number of rows in the table. Address RTbug #1933.
7416    
7417     * test/test_layer.py (TestLayer.test_derived_store): Add
7418     a test for the new exception in DerivedShapeStore.__init__.
7419    
7420     * test/support.py (FloatTestCase): Removed since there is
7421     already FloatComparisonMixin. Fixes RTbug #1954.
7422     (FloatComparisonMixin.assertFloatEqual): Include test for
7423     infinity that was part of FloatTestCase.
7424    
7425     * test/test_range.py (RangeTest): Inherit from
7426     support.FloatComparisonMixin now that we don't have
7427     support.FloatTestCase.
7428    
7429 bh 1256 2003-06-20 Bernhard Herzog <[email protected]>
7430    
7431 bh 1260 * test/test_save.py (SaxEventLister, sax_eventlist): Removed. Use
7432     the implementation in xmlsupport instead.
7433     (SaveSessionTest.compare_xml): sax_eventlist is now in xmlsupport
7434    
7435     * test/test_proj.py: Import sax_eventlist from xmlsupport instead
7436     of test_save
7437    
7438     2003-06-20 Bernhard Herzog <[email protected]>
7439    
7440 bh 1258 * test/test_load.py (LoadSessionTest.check_format): New helper
7441     method to make sure the test files we load might have been written
7442     by the current thuban version.
7443     (ClassificationTest.TestLayers, TestSingleLayer.test)
7444     (TestLayerVisibility.test, TestClassification.test)
7445     (TestLabels.test, TestLayerProjection.test, TestRasterLayer.test):
7446     Add check_format() calls and fix the thuban data to match the data
7447     that would be written by saving the session loaded from it.
7448    
7449     * test/xmlsupport.py (SaxEventLister, sax_eventlist): Copies of
7450     the same class and function in test_save.
7451    
7452     * test/test_xmlsupport.py (TestEventList): New. test cases for
7453     sax_eventlist
7454    
7455     2003-06-20 Bernhard Herzog <[email protected]>
7456    
7457 bh 1256 * Resources/XML/thuban.dtd: Add comment about which versions of
7458     Thuban are covered by this DTD
7459     (map): Fix content model for layers and raster layers. There can
7460     be any number or layers and raster layers in any order.
7461    
7462 jonathan 1254 2003-06-20 Jonathan Coles <[email protected]>
7463    
7464 jonathan 1265 This is mainly about fixing RTbug #1949.
7465    
7466 jonathan 1254 * Thuban/Model/classification.py: Remove "from __future__"
7467     import statement since python 2.2 is the earliest supported
7468     version.
7469    
7470     * Thuban/Model/proj.py (Projection.GetProjectedUnits): New.
7471     Currently returns PROJ_UNITS_METERS or PROJ_UNITS_DEGREES
7472     depending on the units this projection *forwards* into.
7473    
7474     * Thuban/Model/save.py (SessionSaver.write_classification):
7475     Remove unnecessary use of lambdas and nested functions.
7476    
7477     * Thuban/UI/legend.py (ScaleBarBitmap.__SetScale): Do scale
7478     adjustment here if the map projection uses degrees.
7479    
7480     * Thuban/UI/scalebar.py (ScaleBar.DrawScaleBar): Remove
7481     scale adjust code since it is now done before calling
7482     this method. Don't do anything if the map projection
7483     is None.
7484    
7485 bh 1244 2003-06-19 Bernhard Herzog <[email protected]>
7486    
7487 bh 1248 Move version specific load tests to their own file.
7488    
7489     * test/test_load.py: Expand the doc-string to explain a bit how to
7490     handle file format changes.
7491     (TestClassification.test): Update the docstring as this test is
7492     not about Thuban 0.2 anymore.
7493    
7494     * test/test_load_0_2.py: New file with the load tests for thuban
7495     files created with Thuban 0.2 and earlier.
7496    
7497     2003-06-19 Bernhard Herzog <[email protected]>
7498    
7499 bh 1246 Add XML validation to some of the tests. Validation will only be
7500     done if pyRXP is installed (http://reportlab.com/xml/pyrxp.html).
7501     To make the DTD available to the test cases it's moved into
7502     Resources/XML
7503    
7504     * Resources/XML/thuban.dtd: New. This is now the real Thuban DTD
7505     for versions up to and including 0.2. Two slight changes: added an
7506     encoding specification and fixed the comment which refered to
7507     GRASS, not Thuban
7508    
7509     * test/xmlsupport.py: New support module for tests involving XML.
7510     Currently there's a mix-in class for XML validation.
7511    
7512     * test/test_xmlsupport.py: New. Tests for the xmlsupport module
7513    
7514     * test/test_save.py (SaveSessionTest): Derive from ValidationTest
7515     so that we can validate the
7516     (SaveSessionTest.testEmptySession)
7517     (SaveSessionTest.testSingleLayer)
7518     (SaveSessionTest.testSingleLayer)
7519     (SaveSessionTest.testLayerProjection)
7520     (SaveSessionTest.testRasterLayer)
7521     (SaveSessionTest.testClassifiedLayer): Validate the generated XML
7522    
7523     * test/runtests.py (main): Call print_additional_summary instead
7524     of print_garbage_information
7525    
7526     * test/support.py (resource_dir): New function to return the
7527     "Resource" subdirectory
7528     (print_additional_summary): New function to combine several
7529     summary functions
7530     (run_tests): Use print_additional_summary instead of calling
7531     print_garbage_information directly
7532    
7533     2003-06-19 Bernhard Herzog <[email protected]>
7534    
7535 bh 1244 * Doc/thuban.dtd (classification): Correct the content model of
7536     the classification element.
7537     (projection): Add the "name" attribute
7538    
7539 frank 1242 2003-06-19 Frank Koormann <[email protected]>
7540    
7541     MERGE from the greater-ms3 branch.
7542    
7543     * Thuban/UI/scalebar.py (ScaleBar.DrawScaleBar): Apply conversion to
7544     scale if projection is latlong to get better estimate.
7545    
7546     Fix problem of hidden properties dialog under windows after double
7547     click on layer tree:
7548     The tree control always gets an Expanded / Collapsed event after
7549 joey 2162 the ItemActivated on double click, which raises the main window again.
7550     We add a second ItemActivated event to the queue, which simply
7551 frank 1242 raises the already displayed window.
7552    
7553     * Thuban/UI/legend.py (LegendTree.__init__): Instance variable
7554     raiseProperties initialized to prevent endless loops
7555     (LegendTree._OnItemActivated): Depending on self.raiseProperties
7556     simply raise the properties or open the dialog and issue a second
7557     event.
7558    
7559 jonathan 1235 2003-06-18 Jonathan Coles <[email protected]>
7560    
7561 jonathan 1239 * setup.py: Fix a few problems that occured under Windows.
7562    
7563     2003-06-18 Jonathan Coles <[email protected]>
7564    
7565 jonathan 1235 When Thuban loaded the map was redrawn twice because the
7566     legend was being opened after the mainwindow was created
7567     and not during its creation. This meant the map was drawn
7568     initially and then had to be redrawn when the legend
7569     caused the display to change. Now the legend is opened
7570     in the mainwindow constructor which resolves this issue.
7571    
7572     Also, although we were checking for the existence of
7573     gdal and gdalwarp modules, the gdalwarp extension was
7574     still being compiled (which may fail if the system doesn't
7575     have gdal installed). the build_ext command to setup.py
7576     now accepts the flags --with-gdal and --without-gdal.
7577     If --without-gdal is specified setup.py will try to
7578     use the gdal parameters specified by gdal-config. Under
7579     windows, those parameters have to be set in setup.py
7580     as with proj4 an wxWindows.
7581    
7582     * setup.py: Use a list instead of seperate variables for
7583     extension parameters so we can create a generic function
7584     that runs an appropriate *-config script.
7585     (run_cs_script): Renamed from run_wx_script and modified
7586     to accept a second argument which is a list of lists to
7587     be filled in by the values returned from running the command.
7588     (thuban_build_ext): New. Extends the build_ext command and
7589     provides the options --with-gdal/--without-gdal which then
7590     optionally includes the gdalwarp extension.
7591    
7592     * Thuban/Model/resource.py: First check if we can import
7593     the gdalwarp Thuban extension before checking for gdal.
7594     Also added some comments.
7595    
7596     * Thuban/UI/legend.py (ScaleBarBitmap.__SetScale): Check if
7597     the map is None which may be the case if none has been loaded
7598     yet.
7599    
7600     * Thuban/UI/main.py (main): Remove call to ShowLegend.
7601    
7602     * Thuban/UI/mainwindow.py (MainWindow.__init__): Call ShowLegend().
7603    
7604     * Thuban/UI/renderer.py: Check for gdal support before importing
7605     gdalwarp.
7606     (MapRenderer.render_map): Only try to optimize if we have gdal
7607     support otherwise nothing will get drawn.
7608    
7609 jonathan 1237 * Thuban/UI/view.py (MapCanvas.FitMapToWindow): This may be called
7610     during startup before a map has been created. Check if map is None
7611     before using it and do nothing if it is.
7612    
7613 jonathan 1224 2003-06-17 Jonathan Coles <[email protected]>
7614    
7615     Fix the problem with raster layers under Windows that caused
7616     Thuban to crash. The view should respond to layer projection
7617     changed events to update the display. Changes to a projection
7618     should not cause the map to be set to full extent.
7619    
7620     * Thuban/UI/view.py (MapCanvas.__init__): New instance variable
7621     current_map_proj to remember the current map projection so that
7622     when the projection changes we know what the previous projection
7623     was.
7624     (MapCanvas.SetMap): Unsubscribe and subscribe to
7625     LAYER_PROJECTION_CHANGED events.
7626     (MapCanvas.projection_changed): Split into two methods that respond
7627     to map and layer projection changes.
7628     (MapCanvas.map_projection_changed): New. Takes the current view and
7629     projects it using the new projection. This does not cause the
7630     map to be redrawn at full extent.
7631     (MapCanvas.layer_projection_changed): New. Cause a redraw which
7632     will draw each layer in its new projection.
7633    
7634     * extensions/thuban/bmpdataset.cpp (BMPDataset::Open): Call
7635     VSIFClose() not VSIFCloseL() to close the file. Fixes a crash
7636     under Windows.
7637    
7638     * extensions/thuban/gdalwarp.cpp (MFILENAME): Padding should be
7639     to twice sizeof(void*) because there are two digits for each
7640     hex byte.
7641    
7642 bh 1220 2003-06-16 Bernhard Herzog <[email protected]>
7643    
7644     Update to the layer interface: Direct access to the table,
7645     shapetable, shapefile and filename attributes is now actively
7646     deprecated by issuing deprecation warnings for all places where
7647     this happens.
7648    
7649     * Thuban/Model/layer.py (Layer.__getattr__): New. Implement access
7650     to the instance variables table, shapetable, shapefile and
7651     filename via __getattr__ so that we can issue a deprecation
7652     warning.
7653     (Layer.SetShapeStore): Don't set the deprecated instance variables
7654     any more
7655     (Layer.SetShapeStore): Don't use deprecated layer instance
7656     variables
7657     (Layer.Destroy): No need to explicitly remove the instance
7658     variables any more
7659     (Layer.GetFieldType, Layer.Shape): Don't use deprecated layer
7660     instance variables
7661    
7662     * Thuban/UI/classgen.py (ClassGenDialog.__init__)
7663     (GenUniformPanel._OnRetrieve, GenUniquePanel._OnRetrieve)
7664     (GenQuantilesPanel.GetList, GenQuantilesPanel.OnRetrieve): Don't
7665     use deprecated layer instance variables
7666    
7667     * Thuban/UI/classifier.py (Classifier.__init__): Don't use
7668     deprecated layer instance variables
7669    
7670     * Thuban/UI/identifyview.py (IdentifyListCtrl.selected_shape)
7671     (IdentifyGridCtrl.selected_shape): Don't set the deprecated layer
7672     instance variables
7673    
7674     * Thuban/UI/tableview.py (LayerTableGrid.select_shapes): Don't use
7675     deprecated layer instance variables
7676    
7677     * Thuban/UI/mainwindow.py (MainWindow.LayerShowTable): Don't use
7678     deprecated layer instance variables
7679    
7680     * Thuban/Model/save.py (SessionSaver.write_layer): Don't use
7681     deprecated layer instance variables
7682    
7683     * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer)
7684     (MapRenderer.polygon_render_param): Don't use deprecated layer instance
7685     variables
7686    
7687     * test/runtests.py (main): Turn Thuban's deprecation warnings into
7688     errors so that they're cought by the tests
7689    
7690     * test/test_load.py (TestSingleLayer.test): Don't use deprecated
7691     layer instance variables
7692    
7693 jonathan 1212 2003-06-16 Jonathan Coles <[email protected]>
7694    
7695     Fix a problem under Windows whereby if the user double-clicks on a
7696     layer in the legend that tree item will expand or collapse as well
7697     as open the layer properties dialog. The state of the tree item
7698     should not be affected.
7699    
7700     * Thuban/UI/legend.py (LegendTree.__init__): Add instance variable
7701     preventExpandCollapse and subscribe to expanding and collapsing
7702     events.
7703     (LegendTree.OnItemExpandCollapse): New. Responds to expanding and
7704     collapsing events and will veto the event if it has been triggered
7705     by the user double clicking on a layer.
7706     (LegendTree._OnItemActivated): Set preventExpandCollapse to indicate
7707     that an expanding/collapsing event should be vetoed.
7708    
7709 bh 1208 2003-06-13 Bernhard Herzog <[email protected]>
7710    
7711     * Thuban/UI/classifier.py (Classifier.OnClose)
7712     (Classifier.map_layers_removed)
7713     (Classifier.layer_shapestore_replaced): Unsubscribe the messages
7714     in OnClose and not in map_layers_removed or
7715     layer_shapestore_replaced to make sure it always happens when the
7716     dialog is closed
7717    
7718 jonathan 1201 2003-06-13 Jonathan Coles <[email protected]>
7719    
7720 jonathan 1203 This puts back a fix for Windows where a panel is needed so that
7721     the background of the table view appears correctly.
7722    
7723     * Thuban/UI/tableview.py (TableFrame.__init__): Add a panel
7724     object that can be used by derived classes to place any
7725     controls (including the grid) onto.
7726     (QueryTableFrame.__init__): Use the panel as the parent window
7727     for all the controls. Reparent the grid so that the panel is
7728     the parent. Call UpdateStatusText() to correctly initialize
7729     the status bar.
7730    
7731     2003-06-13 Jonathan Coles <[email protected]>
7732    
7733 jonathan 1201 * Thuban/UI/dialogs.py (ThubanFrame): New: a class that inherits
7734     from wxFrame (as opposed to wxDialog like the other classes)
7735     but otherwise behaves like the other classes. This is needed
7736     for the TableView which isn't really a dialog and needs to
7737     have a status bar and control buttons.
7738    
7739     * Thuban/UI/tableview.py (TableGrid.__init__): Create an
7740     instance variable to keep track of how many rows are selected.
7741     Subscribe once to the the events we are interested in.
7742     (ThubanGrid.OnRangeSelect): Only handle event if event handling
7743     hasn't been turned off.
7744     (ThubanGrid.OnSelectCell): Only handle event if event handling
7745     hasn't been turned off.
7746     (ThubanGrid.ToggleEventListeners): Rather than subscribe None
7747     as an event listener (which changes the event handler stack)
7748     simply set an instance variable to False. This is checked in
7749     the event handlers.
7750     (ThubanGrid.GetNumberSelected): Return the number of currently
7751     selected rows.
7752     (TableFrame): Inherit from ThubanFrame so we can have a
7753     status bar and control buttons.
7754     (QueryTableFrame.__init__): Create a status bar. Fixes RTbug #1942.
7755     Explicitly set which items are selected in the operator choice and
7756     action choice so there is always a valid selection. Fixes RTbug #1941.
7757     Subscribe to grid cell selection events so we can update the
7758     status bar.
7759     (QueryTableFrame.UpdateStatusText): Update the status bar with
7760     how many rows are in the grid, how many columns, and how many
7761     rows are selected.
7762     (QueryTableFrame.OnGridSelectRange, QueryTableFrame.OnGridSelectCell):
7763     Call UpdateStatusText when cells are (de)selected.
7764     (QueryTableFrame.OnQuery): Use the string value in the value
7765     combo if either the selected item index is 0 or if the string
7766     cannot be found in the predefined list (this happens if the
7767     user changes the text). Fixes RTbug #1940.
7768     Only turn off the grid event listeners if there a query comes
7769     back with a none empty list of ids. in the case that the list
7770     is empty this causes a grid.ClearSelection() call to actually
7771     clear the grid selection which causes the selected items in
7772     the map to be deselected. Fixes RTbug #1939.
7773    
7774     * test/test_save.py (XMLWriterTest.Encode): Check return values.
7775     Fixes RTbug #1851.
7776    
7777 bh 1195 2003-06-13 Bernhard Herzog <[email protected]>
7778    
7779     * Thuban/UI/identifyview.py (IdentifyView.__init__): Call
7780     self.selected_shape with the current selection to make sure the
7781     contents of the dialog are up to date when it's shown for the
7782     first time.
7783     The dialog used to work without this by luck. The recent fix to
7784     the connector module 'broke' a 'feature' the identify view was
7785     relying on, i.e that subscribing to a message in response to
7786     receiving a message of that type would mean that the new
7787     subscriber would also be called for the same message.
7788    
7789 jonathan 1169 2003-06-12 Jonathan Coles <[email protected]>
7790 jonathan 1175
7791 jonathan 1193 * extensions/thuban/gdalwarp.cpp: Removed debug printing as
7792     the image is rendered. Fixes RTbug #1937.
7793    
7794     2003-06-12 Jonathan Coles <[email protected]>
7795    
7796 jonathan 1191 * Thuban/Lib/fileutil.py: As is done under Windows, create the
7797 jonathan 1193 user directory if it doesn't exist on a posix system.
7798     Fixes RTbug #1815.
7799 jonathan 1191
7800     * Thuban/Model/resource.py (get_user_proj_files): Moved the
7801     called to get_application_dir here, so that the directory
7802     will only be called if this method is invoked.
7803    
7804     * Thuban/UI/projdialog.py (ProjFrame.__DoOnProjAvail): Clear
7805     the projfilepath if no projection is selected.
7806    
7807     2003-06-12 Jonathan Coles <[email protected]>
7808    
7809 jonathan 1182 * Thuban/UI/legend.py (ScaleBarBitmap.__SetScale): Don't draw
7810     the scalebar if the current map has no projection set.
7811    
7812     * Thuban/UI/projdialog.py (ProjFrame.__DoOnProjAvail): Set the
7813     projfilepath label to just the basename of the projection file
7814     rather than include the entire path.
7815    
7816     * Thuban/Model/resource.py: Fix missed proj functions that
7817     needed to be renamed.
7818    
7819     2003-06-12 Jonathan Coles <[email protected]>
7820    
7821 jonathan 1178 * Thuban/Model/classification.py: Removed assert statements that
7822     tested if the variable was an instance of Color.
7823    
7824     * Thuban/Model/color.py (Color): Remove commented code that isn't
7825     used.
7826     (Transparent): Renamed from NoColor. Doesn't inherit from Color.
7827     Fixes RTbug #1835.
7828     (Transparent.__eq__, Transparent.__ne, Transparent.__repr): New.
7829     Needed now that the class doesn't inherit from Color.
7830    
7831     2003-06-12 Jonathan Coles <[email protected]>
7832    
7833 jonathan 1175 * test/test_save.py (XMLWriterTest.testEncode): Explicitly
7834     check unicode strings.
7835    
7836     * test/test_layer.py: Check for existence of gdal.
7837    
7838     2003-06-12 Jonathan Coles <[email protected]>
7839 jonathan 1172
7840     * Thuban/Model/xmlreader.py: New. Contains the XMLReader class
7841     that was in load.py
7842 jonathan 1169
7843 jonathan 1172 * Thuban/Model/xmlwriter.py: New. Contains the XMLWriter class
7844     that was in save.py
7845    
7846     2003-06-12 Jonathan Coles <[email protected]>
7847    
7848 jonathan 1169 This is largely a collection of bug fixes. We also handle the
7849     case where gdal is not on the system. The XMLReader and XMLWriter
7850     classes were moved into there own files to resolve some circular
7851     import references and because they shouldn't really be in the
7852     file that is dediciated to reading/writing session files since
7853     they are also used elsewhere.
7854    
7855     * Thuban/Model/classgen.py: Renamed functions to follow the
7856     function_names_with_underscores style. Fixes RTbug #1903.
7857     (calculate_quantiles): Raise ValueError if 'percents' is invalid.
7858    
7859     * Thuban/Model/layer.py: Import gdal only if it available.
7860     (RasterLayer): Handle the case where the gdal library is unavailable.
7861     Addresses RTbug #1877.
7862    
7863     * Thuban/Model/load.py (XMLReader): Moved into seperate file
7864     xmlreader.py.
7865    
7866 jonathan 1172 2003-06-12 Jonathan Coles <[email protected]>
7867    
7868     This is largely a collection of bug fixes. We also handle the
7869     case where gdal is not on the system. The XMLReader and XMLWriter
7870     classes were moved into there own files to resolve some circular
7871     import references and because they shouldn't really be in the
7872     file that is dediciated to reading/writing session files since
7873     they are also used elsewhere.
7874    
7875     * Thuban/Model/classgen.py: Renamed functions to follow the
7876     function_names_with_underscores style. Fixes RTbug #1903.
7877     (calculate_quantiles): Raise ValueError if 'percents' is invalid.
7878    
7879     * Thuban/Model/layer.py: Import gdal only if it available.
7880     (RasterLayer): Handle the case where the gdal library is unavailable.
7881     Addresses RTbug #1877.
7882    
7883     * Thuban/Model/load.py (XMLReader): Moved into seperate file
7884     xmlreader.py.
7885    
7886 jonathan 1169 * Thuban/Model/save.py (escape, XMLWriter): Moved into seperate
7887     file xmlwriter.py.
7888    
7889     * Thuban/Model/resource.py: Renamed functions to following the
7890     function_names_with_underscores style.
7891     (has_gdal_support): New function that returns true if the gdal
7892     library is available. Addresses RTbug #1877.
7893    
7894     * Thuban/UI/application.py (ThubanApplication.OpenSession):
7895     Display a message box if the gdal library is not available, but
7896     only if there are any layers that would use it. Addresses RTbug #1877.
7897    
7898     * Thuban/UI/classgen.py: Use renamed projection resource functions.
7899     (GenUniformPanel.__CalcStepping): Fix a slight discrepency
7900     when using integers versus floats.
7901    
7902     * Thuban/UI/mainwindow.py (_has_gdal_support): New. Used to
7903     determine if the "Add Image Layer" menu option should be
7904     greyed out or not. Addresses RTbug #1877.
7905    
7906     * Thuban/UI/projdialog.py: Use renamed projection resource functions.
7907    
7908     * Thuban/UI/renderer.py (MapRenderer.render_map): Only try to
7909     optimize if a raster layer is visible. Fixes RTbug #1931.
7910     Only draw the raster layer if the gdal library is available.
7911     Addresses RTbug #1877.
7912    
7913     * test/test_classgen.py: Add tests for generate_singletons,
7914     generate_uniform_distribution, generate_quantiles. Fixes RTbug #1903.
7915     (test_calculate_quantiles): Fix some tests to catch the new
7916     ValueError that is raised.
7917    
7918     * test/test_proj.py: Use renamed projection resource functions.
7919    
7920     * test/test_save.py (SaveSessionTest.testClassifiedLayer): New
7921     test for saving classified layers. Fixes RTbug #1902.
7922     (XMLWriterTest): New. Tests the XMLWriter class. Fixes RTbug #1851.
7923    
7924 jan 1156 2003-06-12 Jan-Oliver Wagner <[email protected]>
7925    
7926     Fix for http://intevation.de/rt/webrt?serial_num=1900.
7927    
7928     * Thuban/UI/multiplechoicedialog.py: New. A multiple choice dialog.
7929    
7930     * Thuban/UI/mainwindow.py: import wxMultipleChoiceDialog from
7931     multiplechoicedialog.py rather than from the wxPython library.
7932    
7933 frank 1151 2003-06-11 Frank Koormann <[email protected]>
7934    
7935 frank 1152 * Thuban/Lib/fileutil.py (get_application_dir): Minor stability
7936     update.
7937    
7938     2003-06-11 Frank Koormann <[email protected]>
7939    
7940 frank 1151 * Thuban/Lib/fileutil.py (get_application_dir): New function to
7941     determine the absolute .thuban/thuban directory under
7942     "posix" (os.expanduser) and "nt" (read AppData registry key).
7943    
7944     * Thuban/Model/resource.py: Use get_application_dir
7945    
7946     * Thuban/UI/application.py (ThubanApplication.read_startup_files):
7947     Use get_application_dir.
7948    
7949 bh 1143 2003-06-10 Bernhard Herzog <[email protected]>
7950    
7951 bh 1147 * Thuban/UI/tableview.py (LayerTableFrame.__init__): Subscribe to
7952     the messages MAP_LAYERS_REMOVED messages
7953     (LayerTableFrame.OnClose): Unsubscribe from it.
7954     (LayerTableFrame.map_layers_removed): New. Receiver for
7955     MAP_LAYERS_REMOVED. Close the dialog when the layer whose the
7956     dialog is showing is removed.
7957    
7958     2003-06-10 Bernhard Herzog <[email protected]>
7959    
7960 bh 1145 * Thuban/Lib/connector.py (Connector.Issue): Iterate over a copy
7961     of the receivers list so that unsubscribing in a receiver doesn't
7962     modify it while iterating over it.
7963    
7964     * test/test_connector.py
7965     (ConnectorTest.test_disconnect_in_receiver): New. Test whether
7966     unsubscribing in a receiver works correctly. See docstring for
7967     details
7968    
7969     2003-06-10 Bernhard Herzog <[email protected]>
7970    
7971 bh 1143 * Thuban/Model/messages.py (LAYER_SHAPESTORE_REPLACED): New
7972     message.
7973    
7974     * Thuban/Model/layer.py (Layer.SetShapeStore): Send
7975     LAYER_SHAPESTORE_REPLACED when the shapestore changes. A
7976     LAYER_CHANGED will still be sent if the classification changes.
7977    
7978     * Thuban/UI/classifier.py (Classifier.__init__): Add the map as
7979     parameter so we can subscribe to some of its messages
7980     (Classifier.__init__): Subscribe to the map's MAP_LAYERS_REMOVED
7981     and the layer's LAYER_SHAPESTORE_REPLACED
7982     (Classifier.unsubscribe_messages): New. Unsubscribe from message
7983     subscribed to in __init__
7984     (Classifier.map_layers_removed)
7985     (Classifier.layer_shapestore_replaced): receivers for the messages
7986     subscribed to in __init__. Unsubscribe and close the dialog
7987    
7988     * Thuban/UI/mainwindow.py (MainWindow.OpenLayerProperties): Pass
7989     the map to the Classifier dialog
7990    
7991     * test/test_layer.py (SetShapeStoreTests): Derive from
7992     SubscriberMixin as well so we can test messages
7993     (SetShapeStoreTests.setUp): Subscribe to some of the layer's
7994     messages
7995     (SetShapeStoreTests.tearDown): Clear the messages again
7996     (SetShapeStoreTests.test_sanity): Expand the doc-string and check
7997     for the modified flag too
7998     (SetShapeStoreTests.test_set_shape_store_modified_flag): New test
7999     to check whether SetShapeStore sets the modified flag
8000     (SetShapeStoreTests.test_set_shape_store_different_field_name)
8001     (SetShapeStoreTests.test_set_shape_store_same_field)
8002     (SetShapeStoreTests.test_set_shape_store_same_field_different_type):
8003     Add tests for the messages. This checks both the new
8004     LAYER_SHAPESTORE_REPLACED and the older LAYER_CHANGED
8005    
8006 jan 1141 2003-06-06 Jan-Oliver Wagner <[email protected]>
8007    
8008     * Thuban/UI/mainwindow.py: Improved and partly added help texts for
8009     the menu items.
8010    
8011 frank 1134 2003-06-05 Frank Koormann <[email protected]>
8012    
8013 frank 1139 * Thuban/UI/identifyview.py (IdentifyView.__init__):
8014     Layout reimplemented without panel. Make life easier to fit the list
8015     in the dialog.
8016    
8017     2003-06-05 Frank Koormann <[email protected]>
8018    
8019 frank 1137 * Thuban/UI/projdialog.py (ProjFrame.__init__): Fill the projchoice
8020     once on initialisation (Former implementation resulted in multiple
8021     entries for each projection).
8022     (ProjFrame.__FillAvailList): selectProj as second optional parameter,
8023     if set, select the projection found under the specified name. This
8024     overwrites any other selection estimate.
8025     Removed projchoice filling from this method.
8026     (ProjFrame._OnSave, ProjFrame._OnAddToList):
8027     Updated call of ProjFrame.__FillAvailList
8028     (LCCPanel._DoLayout): Moved parameter controls in more common order.
8029    
8030     * Resources/Projections/defaults.proj: Extended defaults representing
8031     various common European projections.
8032    
8033     2003-06-05 Frank Koormann <[email protected]>
8034    
8035 frank 1134 * Thuban/UI/identifyview.py (IdentifyView.__init__):
8036     Use ListCtrl instead of GridCtrl
8037    
8038     * Thuban/Model/resource.py:
8039     Guess location of .thuban directory from tempdir parent directory.
8040    
8041     * Thuban/UI/application.py (ThubanApplication.read_startup_files):
8042     Guess location of .thuban directory from tempdir parent directory.
8043    
8044 bh 1130 2003-06-04 Bernhard Herzog <[email protected]>
8045    
8046     Do not cache the values returned by the tree widget's
8047     GetFirstChild and GetNextChild methods because it led to lots of
8048     segfaults. The new way requires more brute force but is more
8049     reliable.
8050    
8051     * Thuban/UI/legend.py (LegendTree.__init__): Remove instance
8052     variable layer2id
8053     (LegendTree.find_layer): New method to do with brute force what
8054     layer2id tried to accomplish
8055     (LegendTree._OnMsgLayerChanged)
8056     (LegendTree._OnMsgLayerTitleChanged, LegendTree.__ShowHideLayer):
8057     Use find_layer instead of layer2id
8058     (LegendTree.__RemoveLayer, LegendTree.__AddLayer): No need to
8059     update layer2id anymore
8060     (LegendTree._OnMsgMapLayersRemoved)
8061     (LegendTree._OnMsgMapLayersAdded): Get by without layer2id.
8062    
8063 tkoester 1128 2003-06-03 Thomas Koester <[email protected]>
8064    
8065     * Thuban/Model/classgen.py (GenQuantiles0): New function.
8066    
8067 bh 1120 2003-06-02 Bernhard Herzog <[email protected]>
8068    
8069 bh 1127 * Thuban/UI/mainwindow.py (layer_rename command, table_rename command):
8070     New commands.
8071     (main_menu): Add the new commands.
8072     (MainWindow.TableRename): New. Implementation of the table_rename
8073     command.
8074     (MainWindow.RenameLayer): New. Implementation of the layer_rename
8075     command.
8076    
8077     * Thuban/Model/session.py (Session.AddTable): call self.changed to
8078     set the modified flag
8079    
8080     * test/test_session.py (TestSessionSimple.test_add_table): Test
8081     whether the modified flag is set properly
8082    
8083     * Thuban/Model/base.py (TitledObject.SetTitle): Call changed
8084     instead of issue so that the modified flags get updated.
8085    
8086     * test/test_base.py (SomeTitledObject): Derive from Modifiable
8087     instead of Publisher to reflect reality better and to accomodate
8088     the fact that SetTitle now calls changed instead of issue
8089    
8090     2003-06-02 Bernhard Herzog <[email protected]>
8091    
8092     * Thuban/UI/classgen.py (GenQuantilesPanel.GetList): Resource
8093     acquisition has to happen before the try in a try-finally.
8094    
8095     2003-06-02 Bernhard Herzog <[email protected]>
8096    
8097 bh 1120 * Thuban/UI/legend.py (LegendTree._OnMsgMapLayersRemoved): It's
8098     possible that a layer is removed that is not currently selected in
8099     the legend so don't check for this.
8100    
8101 bh 1112 2003-05-30 Bernhard Herzog <[email protected]>
8102    
8103 bh 1118 * Thuban/Model/layer.py (Layer.Destroy): Set all instance
8104     variables to None that have direct or indirect references to
8105     shapefiles or dbf files to make sure that they do go away and the
8106     files are closed.
8107    
8108     2003-05-30 Bernhard Herzog <[email protected]>
8109    
8110 bh 1116 * Thuban/UI/legend.py (LegendTree.GetRootItem): Reset
8111     availImgListIndices when a new image list is created
8112    
8113     2003-05-30 Bernhard Herzog <[email protected]>
8114    
8115 bh 1114 * Thuban/UI/legend.py (LegendTree.__init__): New instance variable
8116     changing_selection to indicate whether the LegendTree code itself
8117     is currently changing the selection
8118     (LegendTree.normalize_selection): New method to normalize the
8119     selection by selecting the layer item even if the user clicked on
8120     the classification.
8121     (LegendTree._OnSelChanged): normalize the selection. This works
8122     around a bug in wx which doesn't keep track of the selection
8123     properly when subtrees are deleted.
8124    
8125     2003-05-30 Bernhard Herzog <[email protected]>
8126    
8127 bh 1112 * Thuban/UI/view.py (MapCanvas.set_view_transform): Limit the
8128     maximum and minimum scale factors.
8129    
8130     * test/test_classgen.py (ClassGenTest.test): Update to reflect the
8131     changes in classgen.py
8132    
8133 jonathan 1109 2003-05-30 Jonathan Coles <[email protected]>
8134    
8135     * Thuban/Model/classgen.py: Remove ClassGenerator class but make
8136     all the methods functions. Fixes RTBug #1903.
8137    
8138     * Thuban/Model/map.py (Map.TopLayer, Map.BottomLayer): Renamed
8139     to MoveLayerToTop and MoveLayerToBottom respectively. Fixes
8140     RTBug #1907.
8141    
8142     * Thuban/UI/classgen.py: Use classgen functions that were part
8143     of the ClassGenerator class. Put try/finally blocks around
8144     code that uses wxBeginBusyCursor()/wxEndBusyCursor(). Fixes
8145     RTBug #1904.
8146    
8147     * Thuban/UI/classifier.py: Remove unused import of ClassGenerator.
8148    
8149     * Thuban/UI/legend.py: The legend was cleared and repopulated any
8150     time something changed which caused some state to be lost such
8151     as which children were expanded or collapsed. Fixes RTBug #1901.
8152     (LegendTree._OnMsgMapLayersAdded): Add only new layers.
8153     (LegendTree.__OnMsgMapLayersRemoved): Remove layers that exist in
8154     the legend but not in the map.
8155     (LegendTree.__FillTree): Move main functionality out into smaller
8156     methods that can be used by other methods.
8157     (LegendTree.__FillTreeLayer): Reuse old slots in the image list
8158     if they are available.
8159     (LegendTree.DeleteAllItems): Renamed from __DeleteAllItems so
8160     that we override the wxTreeCtrl method. Iterate over children
8161     and call __RemoveLayer.
8162     (LegendTree.__AddLayer): New. Add a new layer to the legend.
8163     (LegendTree.__RemoveLayer): Remove a layer from the legend.
8164     (LegendTree.DeleteChildren): New, overrides wxTreeCtrl method.
8165     Should only be called with the id of a layer branch.
8166     (LegendTree.GetRootItem): New, overrides wxTreeCtrl method.
8167     Returns the root item or creates one if necessary.
8168    
8169     * Thuban/UI/renderer.py (MapRenderer.draw_raster_layer): Call
8170     ProjectRasterFile with tuple arguments instead of strings.
8171    
8172     * Thuban/UI/tableview.py (QueryTableFrame.OnQuery): Wrap code
8173     with try/finally. Fixes RTBug #1904.
8174    
8175     * Thuban/UI/view.py (MapCanvas.OnPaint): Wrap code
8176     with try/finally. Fixes RTBug #1904.
8177     (MapCanvas.FitSelectedToWindow): If a single point is selected
8178     simply center it on the display. Fixes RTBug #1849.
8179    
8180     * extensions/thuban/gdalwarp.cpp: Removed code that allowed gdalwarp
8181     to be compiled as a standalone app. Now the code can only be
8182     called from Python which simplifies the parameter passing.
8183     (ProjectRasterFile): Handle Python arguments. Remove code that
8184     checks for a destination dataset. Add more clean up code.
8185    
8186     * test/test_map.py (TestMapWithContents.test_raise_layer_top,
8187     TestMapWithContents.test_lower_layer_bottom):
8188     Test Map.MoveLayerToTop() and Map.MoveLayerToBottom() respectively.
8189     Fixes RTBug #1907.
8190    
8191     * Thuban/UI/mainwindow.py (MainWindow.ToggleLegend): Apply a full
8192     extent to the map when the legend is toggled. Fixes RTBug #1881.
8193    
8194 jan 1097 2003-05-29 Jan-Oliver Wagner <[email protected]>
8195    
8196     * Thuban/UI/tableview.py (LayerTableFrame.OnClose): Bug-fix: Now
8197     unsubscribes all that is subcribed in __init__.
8198    
8199 bh 1089 2003-05-28 Bernhard Herzog <[email protected]>
8200    
8201 bh 1095 * Thuban/UI/mainwindow.py (MainWindow.DuplicateLayer)
8202     (MainWindow.CanDuplicateLayer): New methods to implement the
8203     Layer/Duplicate command.
8204     (layer_duplicate command): New.
8205     (main_menu): Add layer_duplicate to the Layer menu.
8206    
8207     2003-05-28 Bernhard Herzog <[email protected]>
8208    
8209 bh 1093 * Thuban/UI/tableview.py (NullRenderer.Draw): New. Our own
8210     renderer so that NULL/None values get displayed differently (by a
8211     gray rectangle).
8212     (TableGrid.__init__): Override the default renderers
8213    
8214     2003-05-28 Bernhard Herzog <[email protected]>
8215    
8216 bh 1089 * Thuban/Model/layer.py (Layer.SetShapeStore): Set the
8217     classification to "None" if the type of the field has changed.
8218    
8219     * test/test_layer.py (SetShapeStoreTests): New. Class with a few
8220     test for the Layer.SetShapeStore method
8221    
8222 jan 1087 2003-05-28 Jan-Oliver Wagner <[email protected]>
8223 jan 1085
8224 jan 1087 * Thuban/Model/layer.py (Layer.TreeInfo): Fixed a bug (a layer
8225     does not necessarily have a filename).
8226    
8227     2003-05-28 Jan-Oliver Wagner <[email protected]>
8228    
8229 jan 1085 * Thuban/UI/mainwindow.py (MainWindow.TableClose, MainWindow.TableShow):
8230     sort the selection list for the dialog.
8231    
8232 frank 1083 2003-05-28 Frank Koormann <[email protected]>
8233    
8234     * extensions/thuban/wxproj.cpp
8235     (project_point): Removed cast to int for projected point coordinates.
8236     (shape_centroid): Return last point if all polygon vertices fall
8237     to one point.
8238    
8239 bh 1079 2003-05-28 Bernhard Herzog <[email protected]>
8240    
8241 bh 1081 * Thuban/UI/mainwindow.py (_can_unjoin): Add doc-string and cope
8242     with layers that don't have shapestores, i.e. raster layers.
8243    
8244     2003-05-28 Bernhard Herzog <[email protected]>
8245    
8246 bh 1079 * Thuban/Model/table.py (DBFTable.__init__): Omit the extension
8247     when determining the title from the filename.
8248    
8249     * test/test_dbf_table.py (TestDBFTable.test_title): Update to
8250     reflect changes in the way the title is derived from the filename
8251    
8252 frank 1077 2003-05-28 Frank Koormann <[email protected]>
8253    
8254     * Thuban/UI/mainwindow.py (MainWindow.TableShow):
8255     Added wxDEFAULT_DIALOG_STYLE to show table dialog styles.
8256    
8257 bh 1069 2003-05-27 Bernhard Herzog <[email protected]>
8258    
8259 bh 1075 * Thuban/UI/mainwindow.py (MainWindow.delegated_messages): Also
8260     delegate SelectedLayer.
8261     (MainWindow.LayerUnjoinTable): Implement.
8262     (_can_unjoin): New. Helper function for the sensitivity of the
8263     layer/unjoin command.
8264    
8265     * Thuban/Model/data.py (ShapefileStore.OrigShapeStore)
8266     (DerivedShapeStore.OrigShapeStore): New. Return the original
8267     shapestore. Used to figure out how to unjoin.
8268     (DerivedShapeStore.Shapefile): Fix a typo.
8269    
8270     2003-05-27 Bernhard Herzog <[email protected]>
8271    
8272 bh 1073 * Thuban/UI/join.py (JoinDialog): Extend to handle layer joins as
8273     well
8274     (JoinDialog.__init__): Use the layer parameter and only build the
8275     left choice when a layer is given
8276     (JoinDialog.OnJoin): Handle layer joins as well
8277     (JoinDialog.OnLeftTable, JoinDialog.OnRightTable): Handle the case
8278     that the user selects the "Select..." item. The sensitivitly
8279     updating is now in update_sensitivity
8280     (JoinDialog.y): New method to refactor the sensitivity update of
8281     the join button into its own method.
8282    
8283     * Thuban/UI/mainwindow.py (MainWindow.LayerJoinTable): Implement.
8284    
8285     2003-05-27 Bernhard Herzog <[email protected]>
8286    
8287 bh 1071 * Thuban/UI/mainwindow.py (table_close command): Make it sensitive
8288     iff there are unreferenced tables in the session
8289    
8290     2003-05-27 Bernhard Herzog <[email protected]>
8291    
8292 bh 1069 * Thuban/Model/messages.py (TABLE_REMOVED): New message.
8293    
8294     * Thuban/Model/session.py (Session.UnreferencedTables): New method
8295     to return tables that are not referenced by other tables or shape
8296     stores and can be removed.
8297     (Session.RemoveTable): Issue a TABLE_REMOVED message after
8298     removing the table
8299    
8300     * Thuban/UI/mainwindow.py: Remove unused imports
8301     (MainWindow.TableClose): Implement.
8302    
8303     * Thuban/UI/tableview.py (TableFrame.__init__): Subscribe to some
8304     messages so that the frame will be automatically closed when a new
8305     session is opened or the table is removed.
8306     (TableFrame.OnClose): Unsubscribe the Subscriptions made in
8307     __init__
8308     (TableFrame.close_on_session_replaced)
8309     (TableFrame.close_on_table_removed): New. Subscribers that close
8310     the window
8311    
8312     * test/test_session.py (TestSessionMessages.test_remove_table)
8313     (TestSessionSimple.test_remove_table): Move the test to
8314     TestSessionSimple and add test for the TABLE_REMOVED message
8315     (TestSessionBase.setUp): Also subscribe to TABLE_REMOVED
8316     (TestSessionSimple.test_unreferenced_tables) New. Test for the
8317     UnreferencedTables method.
8318     (UnreferencedTablesTests): New. Class with some more sophisticated
8319     tests for UnreferencedTables.
8320    
8321 frank 1065 2003-05-27 Frank Koormann <[email protected]>
8322    
8323 frank 1067 * Thuban/UI/tableview.py (QueryTableFrame.__init__): The "_S_election"
8324     display has some unwanted side effects. Removed again.
8325    
8326     2003-05-27 Frank Koormann <[email protected]>
8327    
8328 frank 1065 * Resources/Bitmaps/legend_icon_layer.xpm: New, icon for legend.
8329    
8330     * Thuban/UI/legend.py (LegendTree.__FillTree): Use "legend_icon_layer"
8331    
8332 jan 1062 2003-05-27 Jan-Oliver Wagner <[email protected]>
8333    
8334 bh 1069 * test/test_menu.py (MenuTest.test): Added test for
8335     Menu.RemoveItem().
8336 jan 1062
8337 bh 1069 * Thuban/UI/menu.py (Menu.RemoveItem): New. Remove an item from
8338     the menu.
8339 jan 1062
8340 frank 1059 2003-05-27 Frank Koormann <[email protected]>
8341    
8342     Nonmodal dialogs without parent (i.e. they can fall behind the main
8343     window)
8344    
8345     * Thuban/UI/mainwindow.py (MainWindow.OnClose): Explicitly destroy
8346     all dialogs in the dialogs dictionary and the canvas.
8347    
8348     * Thuban/UI/dialogs.py (NonModalNonParentDialog): New class, without
8349     parent, i.e. can fall behind other windows.
8350     (NonModalDialog.OnClose): Check is dialog is in mainwindow.dialog
8351     dictionary before removing it.
8352    
8353     * Thuban/UI/classifier.py: Dialog derived from NonModalNonParentDialog
8354    
8355     * Thuban/UI/projdialog.py: Dialog derived from NonModalNonParentDialog
8356     * Thuban/UI/tableview.py: Dialog derived from NonModalNonParentDialog
8357     * Thuban/UI/tree.py: Dialog derived from NonModalNonParentDialog
8358    
8359 bh 1053 2003-05-27 Bernhard Herzog <[email protected]>
8360    
8361 bh 1055 * Thuban/UI/mainwindow.py (MainWindow.ShowTableView): New. Open a
8362     tableview dialog
8363     (MainWindow.TableShow): Use ShowTableView to open the dialogs.
8364     Also, don't use the table's titles as the dialog names. The titles
8365     aren't guaranteed to be unique.
8366     (MainWindow.TableOpen): Open a table view dialog after opening the
8367     table
8368    
8369     2003-05-27 Bernhard Herzog <[email protected]>
8370    
8371 bh 1053 * Thuban/UI/mainwindow.py: Remove the Table/Hide menu item. Its
8372     effect can be achieved by simply closing the window showing the
8373     table.
8374     (MainWindow.TableHide): Removed.
8375     (main_menu): Removed "table_hide"
8376    
8377 frank 1051 2003-05-27 Frank Koormann <[email protected]>
8378    
8379     Fix legend tree display problems under Win32
8380    
8381     * Thuban/UI/legend.py: BMP_SIZE_W = 15
8382     (LegendTree.__FillTree): Display "legend_icon_map.xpm" with layer title.
8383     (LegendTree.__FillTreeLayer): Explicitely set SelectedImage.
8384    
8385     * Resources/Bitmaps/legend_icon_map.xpm: New icon for legend.
8386    
8387 jan 1048 2003-05-27 Jan-Oliver Wagner <[email protected]>
8388    
8389     * Thuban/UI/menu.py (Menu.InsertSeparator): Additional optional parameter
8390     'after' now allows to insert separators almost anywhere in the menu.
8391    
8392 frank 1046 2003-05-27 Frank Koormann <[email protected]>
8393    
8394     * Thuban/UI/tableview.py (QueryTableFrame.__init__): Underline the
8395     "S" of selection box label to hint on hot key (Alt-S). Works under
8396     Win32 but is ignored under GTK.
8397    
8398     2003-05-26 Frank Koormann <[email protected]>
8399    
8400     * Thuban/UI/projdialog.py (ProjFrame.__do_layout, ProjPanel._DoLayout):
8401     Center Choices.
8402    
8403 bh 1038 2003-05-26 Bernhard Herzog <[email protected]>
8404    
8405 bh 1044 Remove the Precision methods again. They're too DBF specific to be
8406     part of the table interface and they're only used in table_to_dbf
8407     anyway.
8408    
8409     * Thuban/Model/transientdb.py (TransientTableBase.Width):Use a
8410     fixed precision of 12 for doubles.
8411     (TransientTableBase.Precision): Removed
8412     (AutoTransientTable.Width): Delegate to self.table.
8413    
8414     * Thuban/Model/table.py (DBFTable.Precision)
8415     (MemoryTable.Precision): Removed.
8416     (MemoryTable.Width): Use a fixed precision of 12 for doubles.
8417     (table_to_dbf): Use a fixed precision of 12 for floats unless the
8418     column object specifies something else.
8419    
8420     * test/test_dbf_table.py (TestTableToDBF.test_table_to_dbf): New.
8421     test for table_to_dbf
8422    
8423     2003-05-26 Bernhard Herzog <[email protected]>
8424    
8425     * test/test_transientdb.py
8426     (TestTransientTable.run_iceland_political_tests): Fix a comment.
8427    
8428     2003-05-26 Bernhard Herzog <[email protected]>
8429    
8430 bh 1038 * Thuban/UI/mainwindow.py (MainWindow.TableOpen): Real
8431     implementation. Mark parts of the file format strings for
8432     localization.
8433    
8434     * Thuban/Model/session.py (Session.OpenTableFile): New. Open a dbf
8435     file and add the table to the tables managed by the session
8436    
8437 bh 1040 * test/test_session.py (TestSessionSimple.test_open_table_file):
8438     New. test case for OpenTableFile
8439    
8440 jan 1033 2003-05-26 Jan-Oliver Wagner <[email protected]>
8441    
8442 jan 1035 * Thuban/UI/controls.py, Thuban/UI/identifyview.py, Thuban/UI/join.py,
8443     Thuban/UI/labeldialog.py, Thuban/UI/mainwindow.py,
8444     Thuban/UI/proj4dialog.py, Thuban/UI/tableview.py, Thuban/UI/view.py:
8445     Replace the true/false of wxWindows by True/False of Python 2.2.1.
8446    
8447     2003-05-26 Jan-Oliver Wagner <[email protected]>
8448    
8449 bh 1038 * Thuban/UI/tableview.py (LayerTableFrame.__init__): If there is
8450     already a selection present, update the grid accordingly.
8451 jan 1033
8452     * Thuban/UI/mainwindow.py (MainWindow.TableShow): Make the dialog
8453     resizeable and increase its initial size.
8454    
8455 frank 1030 2003-05-26 Frank Koormann <[email protected]>
8456    
8457     Table export functionality
8458    
8459     * Thuban/Model/table.py (DBFTable.Width, MemoryTable.Width):
8460     Return width (in characters) for a column.
8461     (DBFTable.Precision, MemoryTable.Precision): Return decimal precision.
8462     (table_to_dbf): Write table to dbf file.
8463     (table_to_csv): Write table to csv file.
8464    
8465     * Thuban/Model/transientdb.py (TransientTableBase.Width,
8466     TransientTableBase.Precision): Return column width and precision.
8467    
8468     * Thuban/UI/tableview.py (QueryTableFrame.OnSaveAs): Call table_to_dbf
8469     or table_to_csv depending on file selection.
8470    
8471     * test/test_dbf_table.py:
8472     Test table_to_dbf (extension of former part of test).
8473    
8474     * test/test_csv_table.py:
8475     Test table_to_csv.
8476    
8477 jan 1021 2003-05-23 Jan-Oliver Wagner <[email protected]>
8478    
8479 jan 1024 * Thuban/UI/join.py (JoinDialog.OnJoin): Use _() for strings.
8480     Use QueryTableFrame instead of TableFrame.
8481 jan 1021
8482 jan 1024 * Thuban/UI/mainwindow.py (MainWindow.LayerShowTable): Prefix the
8483     table window with 'Layer Table:' instead of 'Table:'.
8484    
8485     2003-05-23 Jan-Oliver Wagner <[email protected]>
8486    
8487     Give all tables a title via mix-in TitledObject.LayerShowTable
8488    
8489 jan 1021 * Thuban/Model/base.py (TitledObject.SetTitle): Call method 'issue'
8490     only if it exists.
8491    
8492     * Thuban/Model/table.py (DBFTable, MemoryTable): mix-in TitledObject
8493     and call its init-method with a default title. Remove Title() method.
8494    
8495     * Thuban/Model/transientdb.py (TransientTable, TransientJoinedTable,
8496     AutoTransientTable): mix-in TitledObject and call its init-method with
8497     a default title. Remove Title() method.
8498    
8499 bh 1017 2003-05-23 Bernhard Herzog <[email protected]>
8500    
8501     * Thuban/Model/session.py (Session.AddShapeStore): Define
8502     AddShapeStore analogously to AddTable.
8503    
8504     * test/test_session.py (TestSessionSimple.test_add_shapestore):
8505     New. Test for AddShapeStore
8506    
8507 jan 1015 2003-05-23 Jan-Oliver Wagner <[email protected]>
8508    
8509     Introducing QueryTableFrame and a very coarse ShowTable implementation.
8510    
8511     * Thuban/UI/tableview.py (LayerTableFrame, QueryTableFrame): Split the
8512     class LayerTableFrame into two classes, LayerTableFrame and QueryTableFrame.
8513     The latter implements the selection GUI without dependency on a layer.
8514     LayerTableFrame now is derived from QueryTableFrame and connects
8515     to a layer.
8516    
8517     * Thuban/UI/mainwindow.py (MainWindow.TableShow): A very coarse
8518     implementation that still needs work.
8519    
8520     * Thuban/Model/layer.py (Layer.TreeInfo): Added filename.
8521    
8522 frank 1011 2003-05-22 Frank Koormann <[email protected]>
8523    
8524     * Thuban/Model/transientdb.py (TransientJoinedTable.__init__):
8525     Added "outer_join = False" as optional parameter.
8526     (TransientJoinedTable.create): If outer join is true, perform a
8527     "LEFT OUTER JOIN" instead of "JOIN", which preserves all records of
8528     the left table. Records not matching are filled with 0 / None.
8529    
8530     * Thuban/UI/join.py (JoinDialog.__init__): Checkbox for outer join.
8531     (JoinDialog.OnJoin): Consider outer join check box.
8532    
8533 bh 1006 2003-05-22 Bernhard Herzog <[email protected]>
8534    
8535 bh 1008 * Thuban/UI/join.py (JoinDialog.OnJoin): Use exc_info in a
8536     somewhat safer way. Storing the traceback in a local variable can
8537     lead to memory leaks
8538    
8539     2003-05-22 Bernhard Herzog <[email protected]>
8540    
8541 bh 1006 * Thuban/UI/join.py (JoinDialog.OnJoin): Make sure to really call
8542     the wxMessageDialog's Destroy() method.
8543    
8544 frank 1004 2003-05-22 Frank Koormann <[email protected]>
8545    
8546     * Thuban/UI/join.py (JoinDialog.__init__): Make use of
8547     TransientTable.Title()
8548    
8549     2003-05-22 Frank Koormann <[email protected]>
8550    
8551     Join Dialog, initial version.
8552    
8553     * Thuban/UI/mainwindow.py (MainWindow.TableJoin): Removed print.
8554    
8555     * Thuban/UI/join.py (JoinDialog): Functional implementation of
8556     former framework. Renamed Table1/Table2 to LeftTable/RightTable
8557     in all occurences.
8558    
8559     * Thuban/Model/transientdb.py (TransientJoinedTable.__doc__):
8560     Typo fixed.
8561    
8562 bh 995 2003-05-22 Bernhard Herzog <[email protected]>
8563    
8564 bh 999 Give the tables titles so that the GUI can display more meaningful
8565     names. For now the titles are fixed but depend on e.g. filenames
8566     or the titles of the joined tables.
8567    
8568     * Thuban/Model/transientdb.py (TransientTable.Title)
8569     (TransientJoinedTable.Title, AutoTransientTable.Title): New.
8570    
8571     * Thuban/Model/table.py (DBFTable.Title, MemoryTable.Title): New.
8572    
8573     * test/test_transientdb.py
8574     (TestTransientTable.test_auto_transient_table_title): New. Test
8575     for the Title method
8576     (TestTransientTable.test_transient_joined_table)
8577     (TestTransientTable.test_transient_table): Add test for the Title
8578     methods
8579    
8580     * test/test_memory_table.py (TestMemoryTable.test_title): New.
8581     Test for the Title method
8582    
8583     * test/test_dbf_table.py (TestDBFTable.test_title): New. Test for
8584     the Title method
8585    
8586     2003-05-22 Bernhard Herzog <[email protected]>
8587    
8588 bh 997 * test/test_layer.py (TestLayer.setUp, TestLayer.tearDown):
8589     Provide a better way to destroy the layers
8590     (TestLayer.test_base_layer, TestLayer.test_arc_layer)
8591     (TestLayer.test_point_layer, TestLayer.test_empty_layer)
8592     (TestLayer.test_polygon_layer, TestLayer.test_get_field_type): Use
8593     the new way to destroy the layers.
8594     (TestLayer.test_derived_store): New. Test for using a layer with a
8595     DerivedShapeStore
8596    
8597     * Thuban/Model/layer.py (Layer.SetShapeStore): Only set the
8598     filename if the shape store actually has one.
8599    
8600     2003-05-22 Bernhard Herzog <[email protected]>
8601    
8602 bh 995 * Thuban/Model/table.py (DBFTable.FileName): New. Accessor method
8603     for the filename
8604    
8605     * test/test_dbf_table.py (TestDBFTable.test_filename): New. Test
8606     for the FileName method
8607     (TestDBFTableWriting.test_write): Fix spelling of filename
8608    
8609 tkoester 993 2003-05-22 Thomas Koester <[email protected]>
8610    
8611     * Thuban/Model/range.py, test/test_range.py: Brought over new Range
8612     from SciParam that now really is immutable.
8613    
8614 frank 992 2003-05-22 Frank Koormann <[email protected]>
8615    
8616     Layer Top/Bottom placement added to legend.
8617    
8618     * Thuban/UI/legend.py
8619     (LegendPanel._OnMoveTop(), LayerPanel._OnMoveBottom): New, methods
8620     bound to tool events.
8621     (LegendTree.MoveCurrentItemTop(), LegendTree.MoveCurrentItemBottom):
8622     New, methods binding the event methods with the map methods.
8623    
8624     * Thuban/Model/map.py (Map.TopLayer(), Map.BottomLayer()): New, place
8625     layer at top/bottom of layer stack.
8626    
8627     * Resources/Bitmaps/top_layer.xpm: New button icon.
8628    
8629     * Resources/Bitmaps/bottom_layer.xpm: New button icon.
8630    
8631 bh 988 2003-05-22 Bernhard Herzog <[email protected]>
8632    
8633     * Thuban/Model/session.py (Session.RemoveTable): New method to
8634     remove tables
8635    
8636     * test/test_session.py (TestSessionSimple.test_remove_table): New.
8637     Test for RemoveTable
8638    
8639 tkoester 986 2003-05-22 Thomas Koester <[email protected]>
8640    
8641     * Thuban/Model/classgen.py: Added short module doc string and CVS id.
8642     (ClassGenerator.GenUniformDistribution): Use new Range __init__, too.
8643    
8644 bh 983 2003-05-22 Bernhard Herzog <[email protected]>
8645    
8646 bh 985 Implement a way to discover dependencies between tables and
8647     shapestores.
8648    
8649     * Thuban/Model/transientdb.py (TransientTableBase.Dependencies)
8650     (TransientJoinedTable.Dependencies)
8651     (AutoTransientTable.SimpleQuery): New. Implement the dependencies
8652     interface
8653     (TransientJoinedTable.__init__): Keep tack of the original table
8654     objects in addition to the corresponding transient tables.
8655    
8656     * Thuban/Model/table.py (DBFTable.Dependencies)
8657     (MemoryTable.Dependencies): New. Implement the dependencies
8658     interface
8659    
8660     * Thuban/Model/data.py (ShapeTable): New. Helper class for
8661     ShapefileStore
8662     (ShapefileStore.__init__): Use ShapeTable instead of
8663     AutoTransientTable
8664     (ShapefileStore.Table, ShapefileStore.Shapefile): Add doc-strings
8665     (ShapefileStore.FileName, ShapefileStore.FileType): New. Accessor
8666     methods for filename and type
8667     (ShapefileStore.Dependencies): New. Implement the dependencies
8668     interface
8669     (DerivedShapeStore): New class to replace SimpleStore. The main
8670     difference to SimpleStore is that it depends not on a shapefile
8671     but another shapestore which expresses the dependencies a bit
8672     better
8673     (SimpleStore.__init__): Add deprecation warning.
8674    
8675     * test/test_dbf_table.py (TestDBFTable.test_dependencies): New.
8676     Test for the Dependencies method.
8677    
8678     * test/test_memory_table.py (TestMemoryTable.test_dependencies):
8679     New. Test for the Dependencies method.
8680    
8681     * test/test_transientdb.py
8682     (TestTransientTable.test_auto_transient_table_dependencies): New.
8683     Test for the Dependencies method.
8684     (TestTransientTable.test_transient_joined_table): Add test for the
8685     Dependencies method.
8686    
8687     * test/test_session.py (TestSessionSimple.setUp)
8688     (TestSessionSimple.tearDown): New. Implement a better way to
8689     destroy the sessions.
8690     (TestSessionSimple.test_initial_state)
8691     (TestSessionSimple.test_add_table): Bind session to self.session
8692     so that it's destroyed by tearDown
8693     (TestSessionSimple.test_open_shapefile): New. Test for
8694     OpenShapefile and the object it returns
8695    
8696     2003-05-22 Bernhard Herzog <[email protected]>
8697    
8698 bh 983 * Thuban/Model/session.py (Session.AddTable): New method to
8699     register tables with the session.
8700     (Session.Tables): Return the tables registered with AddTable too.
8701    
8702     * test/test_session.py (TestSessionSimple.test_add_table): New.
8703     Test case for the AddTable method
8704    
8705 frank 981 2003-05-22 Frank Koormann <[email protected]>
8706    
8707     UI polishing updates: Place main buttons (OK, Cancel, etc) in the
8708     lower right corner, center labels for selections, initialize controls
8709     in reasonable order for keyboard navigation.
8710    
8711     * Thuban/UI/projdialog.py (ProjFrame.__init__, ProjFrame.__doLayout)
8712     (ProjFrame.__DoOnProjAvail): Determine position of current projection
8713     using the wxListBox.FindString() method. Still a problem (#1886)
8714    
8715     * Thuban/UI/classifier.py
8716     (Classifier.__init__, SelectPropertiesDialog.__init__)
8717    
8718     * Thuban/UI/classgen.py (ClassGenDialog.__init__,
8719     (ClassGenDialog.__DoOnGenTypeSelect): Moved initialization of the
8720     different classification types from here to __init__.
8721     (GenUniquePanel.__init__): Set the column width of the first field
8722     in the Field ListCtrl to the full width.
8723    
8724     * Thuban/UI/tableview.py (LayerTableFrame.__init__): Rename 'Save As'
8725     Button to 'Export'. Center Buttons in Selection Box, set Focus to
8726     Grid.
8727     (LayerTableFrame.OnKeyDown()): New, bound to the grid with EVT_KEY_DOWN,
8728     changes focus to the Selection when pressing "Alt-S".
8729    
8730     * Thuban/UI/legend.py (LegendTree.__SetVisibilityStyle): Only gray out
8731     the text if not visible. The italic font sometimes exceeds the
8732     rendering area.
8733    
8734 jonathan 972 2003-05-21 Jonathan Coles <[email protected]>
8735 jonathan 971
8736 jonathan 975 * Thuban/UI/dock.py (DockFrame): Rename references to _OnClose
8737     to OnClose so that Thuban closes correctly.
8738    
8739     * Thuban/UI/mainwindow.py (MainWindow.OnClose): Call
8740     DockFrame.OnClose, not DockFrame._OnClose.
8741    
8742     2003-05-21 Jonathan Coles <[email protected]>
8743    
8744 jonathan 971 * Thuban/Model/classgen.py (ClassGenerator.GenQuantiles): Remove
8745     references to 'inf' and use new Range __init__ to pass floats
8746     directly rather than converting them to strings first.
8747     Fixes RTBug #1876.
8748    
8749     * Thuban/Model/classification.py (ClassGroupRange.SetRange):
8750     Use new Range ___init__ to pass floats.
8751    
8752     * Thuban/Model/layer.py (RasterLayer.__init__): Test if the
8753     filename is a valid image file. Throw IOError otherwise.
8754    
8755     * Thuban/Model/range.py: Brought over new Range from SciParam that
8756     is immutable and has an __init__ which can accept floats.
8757    
8758     * Thuban/UI/mainwindow.py (MainWindow.AddLayer): Move OpenShapefile
8759     into try block. AddLayer doesn't throw any exceptions anymore.
8760     (MainWindow.AddRasterLayer): Move constructor of RasterLayer into
8761     try block.
8762    
8763     * Thuban/UI/projdialog.py (GeoPanel.__init__): Put Degrees as
8764     the first item in choices. Fixes RTBug #1882.
8765    
8766     * Thuban/UI/renderer.py (MapRenderer.render_map): Check if scale
8767     has gone to 0 which is a serious problem. abort.
8768     (MapRenderer.draw_raster_layer): Catch IOError seperately and
8769     print the error from GDAL.
8770    
8771     * Thuban/UI/tableview.py (TableGrid.__init__): Call
8772     ToggleEventListeners to turn on listening.
8773     (TableGrid.ToggleEventListeners): New. Turns event listening on
8774     and off so as to prevent excessive messages.
8775     (LayerTableFrame.OnQuery): Use TableGrid.ToggleEventListeners
8776     to suppress excessive messages when selecting many rows.
8777     Fixes RTBug #1880.
8778    
8779     * Thuban/UI/view.py: Added checks against if scale == 0. This
8780     is a serious problem that can occur when an image without
8781     geo data is loading and causes the map projection bounds to
8782     go to infinity. Right now, the solution is to simply try
8783     to recover.
8784    
8785     * extensions/thuban/cpl_mfile.cpp (MFILEClose): Make sure
8786     to set the MFILEReceiver attributes even if the data is NULL.
8787    
8788     * extensions/thuban/gdalwarp.cpp: Improved the error handling
8789     and passed GDAL messages back up to the Python layer. Also
8790     tried to fix some memory leaks that were present in the original
8791     utility but didn't matter because the program aborted.
8792    
8793     * test/test_range.py: Copied over tests from SciParam. Removed
8794     tests against importing. Fixes RTBug #1867.
8795    
8796 bh 958 2003-05-21 Bernhard Herzog <[email protected]>
8797    
8798     * test/test_load.py: Remove unused imports and restructure the
8799     test code
8800     (LoadSessionTest): Split into one class for each test and turn
8801     LoadSessionTest itself into the base class for all such session
8802     tests.
8803     (ClassificationTest): New base class for load tests that test
8804     classifications
8805     (TestSingleLayer, TestLayerVisibility, TestClassification)
8806     (TestLabels, TestLayerProjection, TestRasterLayer): New classes
8807     for the individual tests
8808    
8809     * test/support.py (FileLoadTestCase.filename): New base class for
8810     file loading tests
8811    
8812 jan 955 2003-05-21 Jan-Oliver Wagner <[email protected]>
8813    
8814     * Resources/Projections/defaults.proj: Renamed 'Universal Transverse
8815     Mercator' to 'UTM Zone 32' as a more convenient example.
8816     Added 'Gauss Krueger Zone 6'.
8817    
8818     * Data/iceland_sample_raster.thuban: political polygon now
8819     filled transparent to have the raster image visible at once.
8820    
8821 frank 952 2003-05-21 Frank Koormann <[email protected]>
8822    
8823     * Thuban/UI/mainwindow.py (MainWindow): Renamed _OnClose() back to
8824     OnClose() to keep in sync with extensions. Internally Thuban
8825     still uses "underscored" names.
8826    
8827 jonathan 949 2003-05-20 Jonathan Coles <[email protected]>
8828    
8829     This puts back Raster layer support. These layers support projections
8830     through the GDAL library. Currently, the CVS version is being used.
8831     There are no Debian packages available although this may change soon.
8832     A GDAL driver was extended to support writing to memory rather to
8833     files.
8834    
8835     There is still some work that needs to be done, such as some error
8836     handling when loading invalid images or when there is a problem
8837     projecting the image. This putback simply checks in the majority
8838     of the work.
8839    
8840     * setup.py: Add gdalwarp library extension.
8841    
8842     * Thuban/Model/layer.py (BaseLayer.HasClassification): New.
8843     Defaults to False, but can be overridden by subclasses if they
8844     support classification.
8845     (RasterLayer): New. Defines a new layer that represents an
8846     image.
8847    
8848     * Thuban/Model/load.py (SessionLoader.__init__): Add rasterlayer
8849     tag handler.
8850     (SessionLoader.start_layer): Encode the filename.
8851     (SessionLoader.start_rasterlayer, SessionLoader.end_rasterlayer):
8852     New. Supports reading a rasterlayer tag.
8853    
8854     * Thuban/Model/map.py (Map.BoundingBox): Fix typo in comment.
8855    
8856     * Thuban/Model/save.py (XMLWriter.encode): Don't assume that we
8857     get a string in Latin1. If we get such as string convert it to
8858     unicode first, otherwise leave if alone before encoding.
8859     (SessionSaver.write_layer): Add support for writing both Layers
8860     and RasterLayers.
8861    
8862     * Thuban/Model/transientdb.py (AutoTransientTable.SimpleQuery):
8863     The right argument may not be a string, it could also be a Column.
8864    
8865     * Thuban/UI/application.py (ThubanApplication.CreateMainWindow):
8866     Make initial window size 600x400. Fixes RTBug #1872.
8867    
8868     * Thuban/UI/classifier.py (Classifier.__init__): Rearrange how
8869     the dialog is constructed so that we can support layers that
8870     do not have classifications.
8871     (Classifier._OnTry): Only build a classification if the layer
8872     supports one.
8873    
8874     * Thuban/UI/legend.py: Change all checks that a layer is an
8875     instance of Layer into checks against BaseLayer.
8876     (LegendTree.__FillTreeLayer): Only add children to a branch if
8877     the layer supports classification.
8878    
8879     * Thuban/UI/mainwindow.py (MainWindow.NewSession,
8880     MainWindow.OpenSession): Don't proceed with an action if the
8881     user chooses Cancel when they are asked to save changes.
8882     (MainWindow.AddRasterLayer): New. Open a dialog to allow the
8883     user to select an image file. Create a new RasterLayer and add
8884     it to the map.
8885    
8886     * Thuban/UI/renderer.py (MapRenderer.render_map): Add support
8887     for rendering RasterLayer layers.
8888     (MapRenderer.draw_raster_layer): Actually method that calls
8889     the GDALWarp python wrapper and constructs an image from the
8890     data returned.
8891    
8892     * Thuban/UI/tableview.py (LayerTableFrame.__init__): Change the
8893     Choices symbols to match those used in the table query method.
8894     Replace deprecated method calls on table with new method names.
8895    
8896     * Thuban/UI/view.py (MapCanvas.set_view_transform): Try to limit
8897     how small the scale can get. This still needs more testing.
8898    
8899     * extensions/thuban/bmpdataset.cpp: New, but copied from GDAL.
8900     Provides a driver to output in .bmp format.
8901    
8902     * extensions/thuban/cpl_mfile.cpp, extensions/thuban/cpl_mfile.h:
8903     New. Provides IO routines which write to memory, rather than a file.
8904    
8905     * extensions/thuban/gdalwarp.cpp: New, but basically a direct copy
8906     of the gdalwarp utility provided in GDAL. Added function calls
8907     that can be accessed from python.
8908    
8909     * Data/iceland_sample_raster.thuban: New. Sample file that uses
8910     a raster layer.
8911    
8912     * Data/iceland/island.tfw, Data/iceland/island.tif: New. Raster
8913     layer image data.
8914    
8915     * Doc/thuban.dtd: Added rasterlayer attribute definition.
8916    
8917     * test/test_layer.py, test/test_load.py, test/test_save.py: Added
8918     tests associated with the raster layer code.
8919    
8920     * test/test_transientdb.py
8921     (TestTransientTable.test_auto_transient_table_query): Added a test
8922     for using a Column object as the "right" parameter to a query.
8923    
8924 frank 924 2003-05-19 Frank Koormann <[email protected]>
8925    
8926 frank 927 * Thuban/version.py (get_changelog_date):
8927     Catch exceptions if ChangeLog does not exist.
8928    
8929     * Thuban/UI/view.py (MapCanvas.Export): Bugfix
8930    
8931     2003-05-19 Frank Koormann <[email protected]>
8932    
8933 frank 924 Extended version information for Thuban
8934    
8935     * Thuban/version.py: New, version information for Thuban: Last
8936     modification date and last ChangeLog entry date.
8937    
8938     * Thuban/UI/mainwindow.py (MainWindow.About()): Extended version
8939     information: Display Thuban, wxPython and Python version.
8940    
8941 bh 919 2003-05-16 Bernhard Herzog <[email protected]>
8942    
8943 bh 921 * Thuban/Model/save.py: Remove some unused imports including the
8944     __future__ import for nested_scopes as Thuban relies on Python 2.2
8945     now.
8946     (XMLWriter.encode): Remove the special case for a None argument.
8947     In the saver encode is always called with a string argument.
8948    
8949     2003-05-16 Bernhard Herzog <[email protected]>
8950    
8951 bh 919 * Thuban/UI/__init__.py: Remove the work-around for the locale bug
8952     in wxPython (at least when usinvg wxGTK) prior to 2.4. The symptom
8953     of the bug was that e.g. float("1.2") would fail. Thuban now
8954     requires 2.4.x.
8955    
8956 frank 917 2003-05-16 Frank Koormann <[email protected]>
8957    
8958     Printing enhancement and WMF export (under Win32)
8959    
8960     * Thuban/UI/renderer.py (ExportRenderer): New, derived from
8961     ScreenRenderer. Renders Map, Legend and Scalebar for export.
8962     (PrinterRenderer): New, derived from ExportRenderer. Replaces the old
8963     PrintRender.
8964    
8965     * Thuban/UI/view.py (MapPrintout.__init__): Enhanced parameter set
8966     to fullfil information needed for PrinterRenderer.
8967     (MapCanvas.Export): New. Export Map (currently only to WMF on Win32).
8968     (MapCanvas.Print): Adapted to new MapPrintout.
8969     (OutputTransform): General calculations to transform from canvas
8970     coordinates to export/printing devices.
8971    
8972     * Thuban/UI/mainwindow.py (MainWindow.ExportMap()): New. Added also
8973     new method_command to call ExportMap, with platform dependency (only
8974     __WXMSW__)
8975    
8976     * Thuban/UI/scalebar.py (ScaleBar.DrawScaleBar): Position and Size
8977     of scalebar drawing area as new parameters.
8978    
8979     * Thuban/Model/scalebar.py (roundInterval): round long instead of int
8980    
8981     * Thuban/UI/legend.py (ScalebarBitmap.__SetScale):
8982     Update to extended scalebar.DrawScalebar header.
8983    
8984     * test/test_export.py: New, test Thuban.UI.view.OutputTransform()
8985    
8986     * test/test_scalebar.py: Made test executable as standalone.
8987    
8988 bh 908 2003-05-16 Bernhard Herzog <[email protected]>
8989    
8990     * Thuban/Model/table.py (Table): Remove this compatibility alias
8991     for DBFTable.
8992    
8993     * test/test_table.py: Import DBFTable as Table because that alias
8994     doesn't exist anymore.
8995    
8996     * Thuban/UI/classgen.py: Remove some unused imports
8997    
8998 jonathan 906 2003-05-14 Jonathan Coles <[email protected]>
8999    
9000     * Thuban/Model/classgen.py (ClassGenerator.GenSingletonsFromList):
9001     Fix docstring.
9002     (ClassGenerator.GenUniformDistribution): Fix spelling of method name.
9003     (ClassGenerator.GenQuantiles): Use the left/right brackets and min/max
9004     values of the supplied range to determine the beginning and end
9005     bounds of the generated classes.
9006    
9007     * Thuban/Model/range.py (Range.number_re): Now accepts floats that
9008     do not have a leading 0 (.5 is now accepted as well as 0.5).
9009    
9010     * Thuban/UI/classgen.py (ClassGenDialog.OnOK): Fix name of method
9011     call to ClassGenerator.GenUniformDistribution.
9012    
9013     * Thuban/UI/projdialog.py (ProjFrame.__do_layout): Fix Windows
9014     layout bug with the 'Projection' label.
9015    
9016     * test/support.py (FloatTestCase): New. Needed for the Range tests.
9017    
9018     * test/test_range.py: New. Imported from SciParam.
9019    
9020 jonathan 897 2003-05-12 Jonathan Coles <[email protected]>
9021    
9022 jonathan 899 * Thuban/UI/classgen.py (GenQuantilesPanel.GetList): Replace call
9023     to table.UniqueValues() with calls that retrieve all the values
9024     from the table. This will need to be replaced by a method on table
9025     which can simply return the list (perhaps more efficiently).
9026    
9027     2003-05-12 Jonathan Coles <[email protected]>
9028    
9029 jonathan 897 The return value of ClassGenerator.CalculateQuantiles has changed.
9030     Refer to the documentation for details.
9031    
9032     * test/test_classgen.py: Modified Quantile tests to use the
9033     new return values.
9034    
9035     * Thuban/Model/classgen.py
9036     (ClassGenerator.GenQuantiles): Add comments describing the parameters,
9037     use new return values from CalculateQuantiles to produce the correct
9038     range bounds in the Classification.
9039     (ClassGenerator.CalculateQuantiles): Add more comments describing
9040     the return values and parameters. Make minor adjustments to improve
9041     the legibility of the code. Fix problem with adjusted not being set
9042     in most cases.
9043    
9044 frank 893 2003-05-12 Frank Koormann <[email protected]>
9045    
9046     * Thuban/Model/save.py (XMLWriter.encode()): Explicite call to unicode
9047     and latin1. Fixes #1851 finally.
9048    
9049 jonathan 889 2003-05-09 Jonathan Coles <[email protected]>
9050    
9051 jonathan 897 * test/test_classgen.py: New. Tests the Quantile algorithm.
9052    
9053     * Thuban/Model/classgen.py (ClassGenerator.CalculateQuantiles):
9054     Clean up debugging statement, add comments, fix a small bug in the
9055     returned adjusted percentiles.
9056    
9057     2003-05-09 Jonathan Coles <[email protected]>
9058    
9059 jonathan 889 Introduces Range class from SciParam into the ClassGroupRange class,
9060     and such ranges can now be saved and loaded from disk.
9061    
9062     Quantiles are now available in the Classification Generator.
9063    
9064     Initial support for building Queries on a table. Doesn't do anything
9065     but run some tests.
9066    
9067     * Thuban/Model/classification.py: Explicit imports.
9068     (ClassGroupRange): Use the Range class to store the underlying
9069     range information. The interface remains the same, except for
9070     GetRange(), and you can also supply a Range object as the min
9071     parameter to SetRange or __init__.
9072    
9073     * Thuban/Model/load.py (XMLReader.encode): New. Encodes the given
9074     string appropriately for use in Thuban. Fixes RTbug #1851.
9075     (SessionLoader.end_projection): Handle the context of the
9076     projection tag a bit better by looking at what objects are not
9077     None. There was an assumption that a projection tag for a map
9078     could occur before any layers.
9079     (SessionLoader.start_clrange): Provide backward compatibility for
9080     reading min/max values as well as the new range parameter.
9081    
9082     * Thuban/Model/map.py: Explicit imports.
9083    
9084     * Thuban/Model/resource.py: Import _.
9085     (ProjFileSaver.write): write header using projfile.dtd.
9086    
9087     * Thuban/Model/save.py: Explicit imports.
9088     (XMLWriter.encode): New. Encode the given string from a format
9089     used by Thuban into UTF-8. Fixes RTbug #1851.
9090    
9091     * Thuban/UI/classgen.py: Explicit imports.
9092     (ClassGenDialog.__init__): Clean up the code and add support
9093     for Quantiles.
9094     (ClassGenDialog.OnOK): Add support for Quantiles.
9095     (GenQuantilesPanel): New. Input panel for Quantiles.
9096     (ClassGenerator, CustomRamp, MonochromaticRamp, GreyRamp, RedRamp,
9097     GreenRamp, BlueRamp, HotToColdRamp): Move to Thuban/Model/classgen.py
9098    
9099     * Thuban/Model/classgen.py: New. Contains all the classes named above.
9100    
9101     * Thuban/UI/classifier.py: Explicit imports.
9102     (ClassTable.GetValueAsCust, ClassTable.__ParseInput,
9103     ClassTable.SetValueAsCustom): Reworked to use new Range class.
9104    
9105     * Thuban/UI/legend.py: Explicit imports.
9106    
9107     * Thuban/UI/mainwindow.py: Add support for the Join Dialog. Added
9108     a Table menu and associated method calls.
9109     (MainWindow.choose_color): Removed. No longer needed.
9110    
9111     * Thuban/UI/projdialog.py (ProjFrame.__VerifyButtons): Save button
9112     should be disabled if no projection is selected in the available
9113     list.
9114    
9115     * Thuban/UI/renderer.py: Explicit imports.
9116    
9117     * Thuban/UI/tableview.py (TableGrid.OnRangeSelect): Fix some issues
9118     with correctly selecting the rows and issuing the right events.
9119     Be sure to call Skip() to allow the grid to do some of its own
9120     handling which allows the rows to actually be selected.
9121     (LayerTableGrid.select_shapes): Rename from select_shape. Supports
9122     selecting multiple shapes.
9123     (LayerTableFrame): Support for building Queries.
9124     (LayerTableFrame.select_shapes): Allow multiple shapes to be selected.
9125    
9126     * Thuban/UI/tree.py: Explicit imports.
9127    
9128     * Thuban/UI/view.py (MapCanvas): Delegate "SelectedShapes" so the
9129     table view can call it.
9130    
9131     * test/test_classification.py: Explicit imports.
9132     (TestClassification.test_ClassGroupRange): Fix test for new
9133     Range class.
9134    
9135     * Doc/thuban.dtd: Add range parameter for clrange.
9136    
9137     * Thuban/Model/range.py: Taken from SciParam. Used as the underlying
9138     object in ClassGroupRange, and also uesd for inputting ranges in
9139     the classifer table and elsewhere.
9140    
9141     * Thuban/UI/join.py: New. Initial Join dialog. No real functionality
9142     yet.
9143    
9144 frank 872 2003-05-09 Frank Koormann <[email protected]>
9145    
9146     * Thuban/UI/scalebar.py (DrawScaleBar): Draw only if interval > 0.0.
9147    
9148 frank 860 2003-05-08 Frank Koormann <[email protected]>
9149    
9150 frank 870 Coding style updates
9151    
9152     * test/test_scalebar.py: Replaced tab indentation by spaces.
9153    
9154     * Thuban/UI/scalebar.py: Explicit imports.
9155    
9156     2003-05-08 Frank Koormann <[email protected]>
9157    
9158 frank 867 * Thuban/UI/scalebar.py
9159     (ScaleBar.DrawScalebar): Format string bug fixed.
9160    
9161     2003-05-08 Frank Koormann <[email protected]>
9162    
9163 frank 865 Reorganization of scalebar component (no wx in Thuban/Model)
9164    
9165     * Thuban/Model/scalebar.py: Rendering moved to Thuban/UI/scalebar.py
9166     (deriveInterval):
9167     Calculate scalebar interval and unit which fits in width for scale.
9168     (roundInterval): Round float.
9169    
9170     * Thuban/UI/scalebar.py (ScaleBar): Scalebar rendering
9171    
9172     * test/test_scalebar.py: Test for Thuban/Model/scalebar.py methods.
9173    
9174     * Thuban/UI/legend.py: Import Thuban.UI.scalebar
9175    
9176     2003-05-08 Frank Koormann <[email protected]>
9177    
9178 frank 860 * Thuban/UI/legend.py (ScalebarBitmap.SetCanvas):
9179     Initialize ScaleBar with canvas.map
9180    
9181     * Thuban/Model/scalebar.py (ScaleBar.roundInterval()): New,
9182     round intervals to display smarter lengths
9183     (ScaleBar.DrawScalebar): Draw Scalebar only if the map contains a
9184     layer. If the maps has no projection applied grey the scalebar.
9185    
9186 frank 857 2003-05-07 Frank Koormann <[email protected]>
9187    
9188     Basic Scalebar features added.
9189    
9190     * Thuban/Model/scalebar.py (ScaleBar): New, scalebar rendering.
9191    
9192     * Thuban/UI/legend.py (LegendPanel): Added scalebar bitmap
9193     (ScaleBarBitmap): New, links the scalebar bitmap with view messages
9194     and the renderer.
9195    
9196     * Thuban/UI/view.py (MapCanvas.set_view_transform): Issue SCALE_CHANGED.
9197    
9198     * Thuban/UI/messages.py: SCALE_CHANGED added.
9199    
9200 bh 850 2003-05-07 Bernhard Herzog <[email protected]>
9201    
9202 bh 852 * Thuban/Model/session.py (Session.__init__): New instance
9203     variable shapestores to hold a list of all open shapestore objects
9204     (Session.ShapeStores): New. Accessor method for the shapestores
9205     list.
9206     (Session._add_shapestore, Session._clean_weak_store_refs): New.
9207     Internal methods to maintain the shapestores list.
9208     (Session.Tables): New. Return all tables open in the session.
9209     (Session.OpenShapefile): Insert the new ShapeStore into the
9210     shapestores list.
9211    
9212     * test/test_session.py (TestSessionSimple.test_initial_state): Add
9213     tests for ShapeStores and Tables
9214     (TestSessionWithContent.test_shape_stores)
9215     (TestSessionWithContent.test_tables): New. Test cases for
9216     ShapeStores and Tables
9217    
9218     2003-05-07 Bernhard Herzog <[email protected]>
9219    
9220 bh 850 * Thuban/Model/transientdb.py (TransientTableBase.ReadRowAsDict):
9221     Add comments about the optimizations used.
9222     (AutoTransientTable.ReadValue, TransientTableBase.ReadValue): New.
9223     Implement the ReadValue table interface method.
9224    
9225     * test/test_transientdb.py
9226     (TestTransientTable.run_iceland_political_tests)
9227     (TestTransientTable.test_transient_joined_table): Add tests for
9228     ReadValue
9229    
9230 frank 848 2003-05-07 Frank Koormann <[email protected]>
9231    
9232     * Resources/Bitmaps/fulllayerextent.xpm,
9233     Resources/Bitmaps/fullselextent.xpm: Replaced the place holders with
9234     new icons.
9235    
9236 bh 840 2003-05-06 Bernhard Herzog <[email protected]>
9237    
9238 bh 846 * Thuban/Model/transientdb.py (AutoTransientTable.SimpleQuery):
9239     New. Simply delegate to the transient table's version.
9240    
9241     * test/test_transientdb.py
9242     (TestTransientTable.test_auto_transient_table_query): New. Test
9243     case for AutoTransientTable's SimpleQuery
9244    
9245     2003-05-06 Bernhard Herzog <[email protected]>
9246    
9247 bh 843 * Thuban/Model/transientdb.py (TransientTableBase.SimpleQuery):
9248     Implement a simple query method for the query dialog
9249     (TransientTableBase.create): Add an INTEGER PRIMARY KEY that holds
9250     the row index or shapeid.
9251     (TransientTable.create): Insert the right value of the row index
9252     (TransientJoinedTable.create): Copy the row index of the left
9253     table to the joined result table
9254    
9255     * test/test_transientdb.py
9256     (TestTransientTable.test_transient_table_read_twice): Fix
9257     doc-string
9258     (TestTransientTable.test_transient_table_query): New. Test for the
9259     SimpleQuery method
9260    
9261     2003-05-06 Bernhard Herzog <[email protected]>
9262    
9263 bh 840 Convert all table users to use the new table interface. This only
9264     covers Thuban itself, not GREAT-ER or other applications built on
9265     Thuban yet, so the compatibility interface stays in place for the
9266     time being but it now issues DeprecationWarnings.
9267    
9268     Finally, the new Table interface has a new method, HasColumn.
9269    
9270     * Thuban/Model/table.py (OldTableInterfaceMixin): All methods
9271     issue deprecation warnings when they're. The warnings refer to the
9272     caller of the method.
9273     (OldTableInterfaceMixin.__deprecation_warning): New. Helper method
9274     for the deprecation warnings
9275    
9276     * test/test_table.py: Ignore the deprecation warnings for the old
9277     table in the tests in this module. The purpose of the tests is to
9278     test the old interface, after all.
9279    
9280     * test/test_transientdb.py
9281     (TestTransientTable.run_iceland_political_tests): Use the
9282     constants for the types. Add a test for HasColumn
9283     (TestTransientTable.test_transient_joined_table): Adapt to new
9284     table interface. Add a test for HasColumn
9285     (TestTransientTable.test_transient_table_read_twice): Adapt to new
9286     table interface
9287    
9288     * Thuban/UI/tableview.py (DataTable.SetTable, DataTable.GetValue):
9289     Adapt to new table interface
9290    
9291     * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Adapt to
9292     new table interface
9293    
9294     * Thuban/UI/controls.py (RecordListCtrl.fill_list)
9295     (RecordTable.SetTable): Adapt to new table interface
9296    
9297     * Thuban/UI/classifier.py (Classifier.__init__)
9298     (Classifier.__init__): Adapt to new table interface
9299    
9300     * Thuban/UI/classgen.py (ClassGenDialog.__init__)
9301     (GenUniformPanel._OnRetrieve, GenUniquePanel._OnRetrieve): Adapt
9302     to new table interface
9303    
9304     * Thuban/Model/transientdb.py (TransientTableBase.HasColumn)
9305     (AutoTransientTable.HasColumn): Implement the new table interface
9306     method
9307     (AutoTransientTable.ReadRowAsDict, AutoTransientTable.ValueRange)
9308     (AutoTransientTable.UniqueValues): Adapt to new table interface
9309    
9310     * Thuban/Model/layer.py (Layer.SetShapeStore, Layer.GetFieldType):
9311     Adapt to new table interface
9312    
9313     * test/test_layer.py (TestLayer.open_shapefile): Helper method to
9314     simplify opening shapefiles a bit easier.
9315     (TestLayer.test_arc_layer, TestLayer.test_polygon_layer)
9316     (TestLayer.test_point_layer): Use the new helper method
9317     (TestLayer.test_get_field_type): New. Test for the GetFieldType
9318     method
9319    
9320     * test/test_dbf_table.py (TestDBFTable.test_has_column): Test for
9321     the new table method
9322    
9323     * test/test_memory_table.py (TestMemoryTable.test_has_column):
9324     Test for the new table method HasColumn
9325    
9326 jonathan 833 2003-05-06 Jonathan Coles <[email protected]>
9327    
9328     Addresses the "Selection Extent" wish of RTbug #1787.
9329    
9330     * Resources/Bitmaps/fulllayerextent.xpm,
9331     Resources/Bitmaps/fullselextent.xpm: Bitmaps for layer and selection
9332     extent. These are just place holders for the real bitmaps.
9333    
9334     * Thuban/Model/layer.py (Shape): Since a Shape is immutable only
9335     calculate the bounding box once (the first time compute_bbox() is
9336     called).
9337     (Layer.ShapesBoundingBox): New. Given a list of shape ids, return
9338     the bounding box for the shapes in lat/long coordinates.
9339    
9340     * Thuban/UI/mainwindow.py: Added new "Full selection extent" menu
9341     option.
9342     (MainWindow.has_selected_shapes): New. Returns true if there are
9343     any selected shapes.
9344     (MainWindow.FullSelectionExtent): New. Calls
9345     MapCanvas.FitSelectedToWindow() when the user selects the menu option.
9346     (_has_selected_shapes): New. Returns true if there are any
9347     selected shapes.
9348    
9349     * Thuban/UI/selection.py (Selection.HasSelectedShapes): New. Returns
9350     true if there are any selected shapes.
9351    
9352     * Thuban/UI/view.py (MapCanvas): Added delegated method
9353     HasSelectedShapes.
9354     (MapCanvas.FitSelectedToWindow): New. Centers and scales any selected
9355     shapes on the canvas using the map projection (if any).
9356    
9357     * test/test_layer.py (TestLayer.test_arc_layer): Add some tests
9358     for Layer.ShapesBoundingBox().
9359    
9360 bh 826 2003-05-06 Bernhard Herzog <[email protected]>
9361    
9362     * Resources/Projections/defaults.proj: Fix spelling of Mercator
9363    
9364 jonathan 823 2003-05-05 Jonathan Coles <[email protected]>
9365    
9366     Addresses the "Full Layer Extent" wish of RTbug #1787.
9367    
9368     * Resources/Projections/defaults.proj: Added UK National Grid.
9369    
9370     * Thuban/UI/mainwindow.py: Added new "Full layer extent" menu option.
9371     (MainWindow.FullLayerExtent): New. Calls MapCanvas.FitLayerToWindow()
9372     when the user selects the menu option.
9373    
9374     * Thuban/UI/view.py (MapCanvas.FitLayerToWindow): New. Centers and
9375     scales the given layer on the canvas using the map projection.
9376    
9377 bh 819 2003-05-05 Bernhard Herzog <[email protected]>
9378    
9379     Convert the table implementations to a new table interface. All
9380     tables use a common mixin class to provide backwards compatibility
9381     until all table users have been updated.
9382    
9383     * Thuban/Model/table.py (OldTableInterfaceMixin): Mixin class to
9384     provide backwards compatibility for table classes implementing the
9385     new interface
9386     (DBFTable, MemoryTable): Implement the new table interface. Use
9387     OldTableInterfaceMixin as base for compatibility
9388     (DBFColumn, MemoryColumn): New. Column description for DBFTable
9389     and MemoryTable resp.
9390    
9391     * test/test_dbf_table.py: New. Test cases for the DBFTable with
9392     the new table interface.
9393    
9394     * test/test_memory_table.py: New. Test cases for the MemoryTable
9395     with the new table interface.
9396    
9397     * test/test_table.py: Document the all tests in this file as only
9398     for backwards compatibility. The equivalent tests for the new
9399     interface are in test_memory_table.py and test_dbf_table.py
9400     (MemoryTableTest.test_read): field_info should be returning tuples
9401     with four items
9402     (MemoryTableTest.test_write): Make doc-string a more precise.
9403    
9404     * Thuban/Model/transientdb.py (TransientTableBase): Convert to new
9405     table interface. Derive from from OldTableInterfaceMixin for
9406     compatibility.
9407     (TransientTableBase.create): New intance variable column_map to
9408     map from names and indices to column objects
9409     (TransientTable.create): Use the new table interface of the input
9410     table
9411     (AutoTransientTable): Convert to new table interface. Derive from
9412     from OldTableInterfaceMixin for compatibility.
9413     (AutoTransientTable.write_record): Removed. It's not implemented
9414     yet and we still have to decide how to handle writing with the new
9415     table and data framework.
9416    
9417     * test/test_transientdb.py
9418     (TestTransientTable.run_iceland_political_tests)
9419     (TestTransientTable.test_transient_joined_table): Use the new
9420     table interface
9421    
9422 jonathan 817 2003-05-05 Jonathan Coles <[email protected]>
9423    
9424     This is namely a collection of UI updates to improve user interactivity.
9425     Tabbing between controls now exists and you can use ESC to close dialog
9426     boxes; ENTER will active the default button.
9427    
9428     * Thuban/UI/classgen.py (ClassGenDialog.__init__): Rearrange the
9429     order that the controls are created so that tabbing works correctly.
9430     (ClassGenDialog.OnOK): Renamed from _OnGenerate() so that the
9431     wxDialog can handle the default button correctly.
9432     (ClassGenDialog.OnCancel): Renamed from _OnCloseBtn() for the
9433     same reasons as for OnOK.
9434     (GenUniformPanel._OnRetrieve): Call wxBeginBusyCursor/wxEndBusyCursor
9435     when we ask the table for the maximum/minimum values of a field
9436     which could take a very long time.
9437    
9438     * Thuban/UI/classifier.py (Classifier.__init__): Rearrange the
9439     order that the controls are created so that tabbing works correctly.
9440     (SelectPropertiesDialog.__init__): Rearrange the order that the
9441     controls are created so that tabbing works correctly.
9442    
9443     * Thuban/UI/dialogs.py: Copied NonModalDialog box and changed it
9444     to derive from a wxDialog but behave like the original implementation
9445     which was derived from a wxFrame. wxDialog provides useful key
9446     handling functionality like ESC calling OnCancel and ENTER calling
9447     OnOK which is lost with wxFrame.
9448    
9449     * Thuban/UI/mainwindow.py: Add "..." to menu items that will open
9450     new dialogs.
9451    
9452     * Thuban/UI/projdialog.py (ProjFrame.__init__): Rearrange the
9453     order that the controls are created so that tabbing works correctly.
9454     (ProjFrame.OnApply): Renamed from _OnTry() to use wxDialog behaviour.
9455     (ProjFrame.OnOK): Renamed from _OnOK() to use wxDialog behaviour.
9456     (ProjFrame.OnCancel): Renamed from _OnClose() to use wxDialog behaviour.
9457     (ProjPanel.__init__): Add "Airy" to the list of ellipsoids so we
9458     can provide the "UK National Grid" as a default projection.
9459     (UTMPanel.__init__): Rearrange the order that the controls are
9460     created so that tabbing works correctly.
9461    
9462 bh 809 2003-05-05 Bernhard Herzog <[email protected]>
9463    
9464 bh 811 * extensions/thuban/wxproj.cpp: Fix some of the comments.
9465     (project_point): If a map projection but no layer projection is
9466     given, convert degrees to radians before applying the map
9467     projection.
9468    
9469 bh 809 * Thuban/UI/tableview.py (TableGrid.disallow_messages)
9470     (TableGrid.allow_messages): New methods to make it possible to
9471     inhibit message sending.
9472     (TableGrid.issue): Only send the message if not inhibited.
9473     (LayerTableGrid.select_shape): Use the new methods to make sure
9474     that no ROW_SELECTED message is sent while we're updating the
9475     selected rows to match the selected shapes.
9476    
9477 jan 807 2003-05-02 Jan-Oliver Wagner <[email protected]>
9478    
9479     Implementation of MemoryTable.
9480    
9481     * Thuban/Model/table.py (MemoryTable): New. Quite simple table
9482     implementation that operates on a list of tuples. All of the data
9483     are kept in the memory.
9484    
9485     * test/test_table.py (MemoryTableTest): New.
9486    
9487     * test/test_transientdb.py (SimpleTable): Removed.
9488     (TestTransientTable.test_transient_joined_table,
9489     (TestTransientTable.test_transient_table_read_twice): Replaced
9490     SimpleTable by MemoryTable.
9491    
9492 jonathan 793 2003-04-30 Jonathan Coles <[email protected]>
9493    
9494 jonathan 803 * Data/iceland_sample.thuban: Now contains correct projections
9495     for each of the layers.
9496    
9497     * Resources/Projections/defaults.proj: Geographic projection
9498     contains unit conversion parameter.
9499    
9500     2003-04-30 Jonathan Coles <[email protected]>
9501    
9502 jonathan 793 The most important part of this putback is the projection changes.
9503     It should now be possible to specify the projection that a layer
9504     is in and then specify a different projection for the map. The
9505     projection dialog has an extra parameter for a geographic projection
9506     which lets the user select if the input is in degrees or radians.
9507    
9508     * Thuban/Model/layer.py (Layer.ShapesInRegion): Fix docstring
9509     to say that the parameter is a tuple of unprojected
9510     points (which is what the callers to this method were assuming).
9511     Also, since the points are unprojected we need to projected them.
9512    
9513     * Thuban/UI/legend.py (LegendTree.MoveCurrentItemUp,
9514     LegendTree.MoveCurrentItemDown): If the layer or any of the layer's
9515     groups are selected, move the layer up/down. Fixes RTbug #1833.
9516    
9517     * Thuban/UI/mainwindow.py: Move menu item map_rename up.
9518    
9519     * Thuban/UI/projdialog.py (ProjFrame._OnSave): Add missing
9520     parameter in call to SetClientData.
9521     (GeoPanel): Add support for selecting the units that the
9522     source data is in (Radians or Degrees).
9523    
9524     * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Optimize
9525     the rendering loop by reducing the number of if's, removing the
9526     unnecessary try/except block, and checking if the old group
9527     is the same as the new one (which happens a lot if there is
9528     no classification, or lots of shapes are in the same group).
9529    
9530     * Thuban/UI/view.py (MapCanvas.OnPaint): Add a try/except block
9531     around the redraw routine to try to catch problems that the user
9532     may create by selecting invalid projections for the data set and
9533     map. Clears the display if there are any problems and prints the
9534     error.
9535     (MapCanvas.do_redraw): Use DC.Clear() instead of drawing a filled
9536     rectangle.
9537    
9538     * extensions/thuban/wxproj.cpp (project_point): First invert the
9539     supplied point (which should be in projected coordinates) using
9540     the layer's projection and then project the point using the
9541     map's projection.
9542     (project_points): Use project_point() to project each point.
9543    
9544 jan 792 2003-04-30 Jan-Oliver Wagner <[email protected]>
9545    
9546     * Thuban/Model/layer.py (Layer.SetShapeStore): Fixed a bug:
9547     don't set the Classification to None if the classfication field
9548     is None (ie only a DEFAULT).
9549    
9550 bh 786 2003-04-30 Bernhard Herzog <[email protected]>
9551    
9552 bh 790 * Thuban/UI/view.py: Fix some typos.
9553    
9554 bh 788 * Thuban/UI/mainwindow.py (MainWindow.identify_view_on_demand): Do
9555     not pop up the dialog if the selection becomes empty (this could
9556     happen if e.g. a new selection is opened while the identify tool
9557     is active and dialog had been closed)
9558    
9559     2003-04-30 Bernhard Herzog <[email protected]>
9560    
9561 bh 786 * Thuban/Model/transientdb.py (TransientTableBase.__init__): New
9562     instance variable read_record_last_result
9563     (TransientTableBase.read_record): Make sure reading the same
9564     record twice works. The implementation uses the new instance
9565     variable read_record_last_result
9566    
9567     * test/test_transientdb.py
9568     (TestTransientTable.test_transient_table_read_twice): New test
9569     case for the above bug-fix.
9570    
9571 jonathan 793 2003-04-29 Jonathan Coles <[email protected]>
9572    
9573     * Thuban/common.py: Removed. No longer needed Str2Num. RTbug #1832.
9574    
9575     * Thuban/UI/classgen.py: Remove all uses of Str2Num.
9576    
9577     * Thuban/UI/classifier.py: Remove all uses of Str2Num.
9578     (ClassTable.SetValueAsCustom): Rename keyword argument in
9579     ClassGroup* constructors to match argument name.
9580    
9581 bh 779 2003-04-29 Bernhard Herzog <[email protected]>
9582    
9583     * Thuban/Model/session.py (Session.Destroy): Explicitly close the
9584     transient DB if it exists to make sure it doesn't leave a journal
9585     file in the temp directory.
9586    
9587     * Thuban/Model/transientdb.py (TransientDatabase.close): Set
9588     self.conn to None after closing the connection to make sure it's
9589     not closed twice
9590    
9591 jonathan 767 2003-04-29 Jonathan Coles <[email protected]>
9592    
9593 jonathan 769 Add a visible parameter in the layer XML tag. The default value is
9594     "true". If anything other than "false" is specified we also assume
9595 jonathan 776 "true". Addresses RTbug #1025.
9596 jonathan 769
9597     * Doc/thuban.dtd: Add visible parameter to a layer.
9598    
9599     * Thuban/Model/layer.py (BaseLayer.__init__): Change default value
9600     of visible from 1 to True.
9601     (Layer.__init__): Change default value of visible from 1 to True.
9602    
9603     * Thuban/Model/load.py (SessionLoader.start_layer): Read visible
9604     parameter.
9605    
9606     * Thuban/Model/save.py (SessionSaver.write_layer): Save visible
9607     parameter.
9608    
9609     * test/test_load.py: Add new test data contents_test_visible.
9610     (LoadSessionTest.setUp): save test data.
9611     (LoadSessionTest.testLayerVisibility): Test if the visible flag
9612     is loaded correctly.
9613    
9614     * test/test_save.py (SaveSessionTest.testSingleLayer): Add test
9615     for saving an invisible layer.
9616    
9617     2003-04-29 Jonathan Coles <[email protected]>
9618    
9619 jonathan 767 * Thuban/UI/mainwindow.py (MainWindow.SetMap): Look up the
9620     legend dialog box and tell it to change its map to the one
9621     supplied to SetMap(). Fixes RTbug #1770.
9622    
9623 bh 764 2003-04-29 Bernhard Herzog <[email protected]>
9624    
9625 bh 766 Next step of table implementation. Introduce a transient database
9626     using SQLite that some of the data is copied to on demand. This
9627     allows us to do joins and other operations that require an index
9628     for good performance with reasonable efficiency. Thuban now needs
9629     SQLite 2.8.0 and pysqlite 0.4.1. Older versions may work but I
9630     haven't tested that.
9631    
9632     * Thuban/Model/transientdb.py: New. Transient database
9633     implementation.
9634    
9635     * test/test_transientdb.py: New. Tests for the transient DB
9636     classes.
9637    
9638     * Thuban/Model/session.py (AutoRemoveFile, AutoRemoveDir): New
9639     classes to help automatically remove temporary files and
9640     directories.
9641     (Session.__init__): New instance variables temp_dir for the
9642     temporary directory and transient_db for the SQLite database
9643     (Session.temp_directory): New. Create a temporary directory if not
9644     yet done and return its name. Use AutoRemoveDir to have it
9645     automatically deleted
9646     (Session.TransientDB): Instantiate the transient database if not
9647     done yet and return it.
9648    
9649     * Thuban/Model/data.py (ShapefileStore.__init__): Use an
9650     AutoTransientTable so that data is copied to the transient DB on
9651     demand.
9652     (SimpleStore): New class that simply combines a table and a
9653     shapefile
9654    
9655     * Thuban/Model/table.py (Table, DBFTable): Rename Table into
9656     DBFTable and update its doc-string to reflect the fact that this
9657     is only the table interface to a DBF file. Table is now an alias
9658     for DBFTable for temporary backwards compatibility.
9659    
9660     * Thuban/UI/application.py (ThubanApplication.OnExit): Make sure
9661     the last reference to the session goes away so that the temporary
9662     files are removed properly.
9663    
9664     * test/test_load.py (LoadSessionTest.tearDown): Remove the
9665     reference to the session to make sure the temporary files are
9666     removed.
9667    
9668     2003-04-29 Bernhard Herzog <[email protected]>
9669    
9670 bh 764 * Thuban/Model/load.py (XMLReader.__init__, XMLReader.read): Turn
9671     the __parser instance variable into a normal local variable in
9672     read. It's only used there and read will never be called more than
9673     once. Plus it introduces a reference cycle that keeps can keep the
9674     session object alive for a long time.
9675    
9676 jonathan 767 2003-04-29 Jonathan Coles <[email protected]>
9677 jonathan 735
9678 jonathan 762 * Thuban/Model/proj.py (Projection): Removed Set*() methods to make
9679     Projection an immutable item. Fixes RTbug #1825.
9680     (Projection.__init__): Initialize instance variables here.
9681     (ProjFile.Replace): New. Replace the given projection object with
9682     the new projection object. This solves the problem of needing the
9683     mutator Projection.SetProjection() in the ProjFrame class and
9684     allows a projection to change parameters without changing its
9685     location in the file.
9686    
9687     * Thuban/UI/mainwindow.py (MainWindow.SaveSessionAs): Dialog should
9688     be of type wxSAVE and should verify overwriting a file.
9689    
9690     * Thuban/UI/projdialog.py (ProjFrame._OnSave): Use the new
9691     ProjFile.Replace() method instead of the mutator
9692     Projection.SetProjection(). Also requires that we reassign the
9693     client data to the new projection.
9694    
9695     * test/test_proj.py (TestProjection.test): Test GetName() and
9696     GetAllParameters()
9697     (TestProjFile.test): Remove tests for Set*() methods. Add tests
9698     for Replace().
9699    
9700     2003-04-25 Jonathan Coles <[email protected]>
9701    
9702 jonathan 756 * Thuban/Model/save.py (SessionSaver.write_projection): Make sure
9703     to save the name of the projection.
9704    
9705     * test/test_save.py (SaveSessionTest.testLayerProjection): New
9706     test to verify layer projections are saved correctly.
9707    
9708     2003-04-25 Jonathan Coles <[email protected]>
9709    
9710 jonathan 753 * Thuban/Model/proj.py (Projection.SetName): Set the name
9711     to "Unknown" if name is None.
9712     (Projection.SetAllParameters): New. Set the projection's
9713     parameter list to the one supplied.
9714     (Projection.SetProjection): New. Set the projection's
9715     properties to those of the supplied Projection.
9716    
9717     * Thuban/UI/mainwindow.py (MainWindow.MapProjection): Set
9718     the dialog title to include the map's title.
9719     (MainWindow.LayerProjection): Set the dialog title to include
9720     the layer's title.
9721    
9722     * Thuban/UI/projdialog.py (ProjFrame.__ShowError): Consolidate
9723     error dialogs into a single method call.
9724     (ProjFrame.__VerifyButtons): Add more states to check.
9725     (ProjFrame.__GetProjection): Return the current state of an
9726     edited projection or None.
9727     (ProjFrame.__FillAvailList): Remove checks for states that
9728     shouldn't exist.
9729     (ProjFrame._OnNew): Clear all selected items and supply
9730     a projection panel if necessary.
9731    
9732     * test/test_proj.py (TestProjFile.test): Add tests for
9733     ProjFile.SetAllParameters, ProjFile.SetProjection,
9734     ProjFile.SetName.
9735    
9736     2003-04-25 Jonathan Coles <[email protected]>
9737    
9738 jonathan 748 * Thuban/UI/projdialog.py (ProjFrame.__FillAvailList): Now
9739     takes an optional argument to select the current projection.
9740     This does not guarantee that the item is visible due to
9741     limited wxWindows functionality. Fixes RTBug #1821.
9742    
9743     2003-04-25 Jonathan Coles <[email protected]>
9744    
9745 jonathan 743 * Thuban/Model/load.py (SessionLoader.start_projection): Remember
9746     the projection name and use it when constructing the Projection
9747     object.
9748    
9749     * Thuban/Model/proj.py (Projection.__init__): Change the default
9750     value for 'name' to None and then test if name is equal to None
9751     in the body of the constructor. This way the caller doesn't have to
9752     know what the default value should be. Namely, useful in load.py
9753     where we have to pick a default value if the 'name' parameter
9754     doesn't exist in the XML file.
9755    
9756     * test/test_load.py (LoadSessionTest.testLayerProjection): New.
9757     Tests a file where a layer has a projection.
9758    
9759     2003-04-25 Jonathan Coles <[email protected]>
9760    
9761 jonathan 735 * Thuban/Model/layer.py (Layer.TreeInfo): Add an item to the
9762     tree for projection information.
9763    
9764     * Thuban/Model/load.py (XMLReader.GetFilename): Renamed from
9765     XMLReader.GetFileName.
9766     (SessionLoader): Added support for loading projection tags that
9767     appear inside a layer.
9768    
9769     * Thuban/Model/proj.py (ProjFile): Document the class. Move
9770     back to using a list because the order of the projections in
9771     the file is important to maintain. Fixes RTbug #1817.
9772    
9773     * Thuban/Model/resource.py: Rename calls to ProjFile.GetFileName
9774     to ProjFile.GetFilename.
9775    
9776     * Thuban/Model/save.py (SessionSaver.write_layer): Save projection
9777     information.
9778    
9779     * Thuban/UI/projdialog.py (ProjFrame._OnAddToList): Renamed from
9780     ProjFrame._OnSaveAs. Removed old dead code from previous
9781     implementation.
9782     (ProjFrame._OnExport): Add support for exporting more than one
9783     projection to a single file.
9784     (ProjFrame.__FillAvailList): use string formatting (% operator)
9785     to build strings that are (partly) translated. Fixes RTbug #1818.
9786    
9787     * test/test_proj.py (TestProjFile.test): New. Tests the base ProjFile
9788     class.
9789    
9790 bh 734 2003-04-24 Bernhard Herzog <[email protected]>
9791    
9792     * po/es.po: Updated Spanish translation by Daniel Calvelo Aros
9793    
9794     * po/fr.po: New. French translation by Daniel Calvelo Aros
9795    
9796     * Thuban/UI/projdialog.py (ProjFrame._OnSaveAs): Don't translate
9797     empty strings.
9798    
9799 jonathan 735 2003-04-24 Jonathan Coles <[email protected]>
9800 jonathan 724
9801     * Thuban/Model/layer.py (Layer.GetProjection): New. Needed to
9802     implement the interface that the ProjFrame dialog expects.
9803    
9804     * Thuban/Model/proj.py (Projection.SetName): New. Allows the
9805     name of the projection to be changed.
9806     (ProjFile): Use a dictionary instead of a list so that removing
9807     projections is easier and we are sure about uniqueness.
9808     (ProjFile.Remove): Remove the given projection object.
9809    
9810     * Thuban/Model/resource.py (GetSystemProjFiles, GetUserProjFiles):
9811     Return a list with only one projection file instead of searching for
9812     any projection file. This simplifies many things if the user can
9813     only have one system file and one user file.
9814    
9815     * Thuban/UI/classgen.py: Change all references to
9816     genCombo to genChoice.
9817    
9818     * Thuban/UI/mainwindow.py: Add a Projection option under the
9819     layer menu.
9820     (MainWindow.LayerProjection): New. Open up a projection window
9821     for a layer.
9822    
9823     * Thuban/UI/projdialog.py: Large changes to how the dialog is
9824     laid out. Use three panels instead of one. One for the list of
9825     projections, one for the edit controls, and one for the buttons.
9826     Fixed resizing problems so that the dialog resizes correctly
9827     when the projection panel changes. Added import/export, save, and
9828     new buttons/functionality.
9829    
9830 bh 723 2003-04-24 Bernhard Herzog <[email protected]>
9831    
9832     First step towards table management. Introduce a simple data
9833     abstraction so that we replace the data a layer uses more easily
9834     in the next step.
9835    
9836     * Thuban/Model/data.py: New file with a simple data abstraction
9837     that bundles shapefile and dbffile into one object.
9838    
9839     * Thuban/Model/session.py (Session.OpenShapefile): New method to
9840     open shapefiles and return a shape store object
9841    
9842     * Thuban/Model/layer.py (Layer.__init__): Pass the data as a store
9843     object instead of a shapefile filename. This introduces a new
9844     instance variable store holding the datastore. For intermediate
9845     backwards compatibility keep the old instance variables.
9846     (open_shapefile): Removed. No longer needed with the shape store.
9847     (Layer.SetShapeStore, Layer.ShapeStore): New methods to set and
9848     get the shape store used by a layer.
9849     (Layer.Destroy): No need to explicitly destroy the shapefile or
9850     table anymore.
9851    
9852     * Thuban/UI/mainwindow.py (MainWindow.AddLayer)
9853     (MainWindow.AddLayer): Use the session's OpenShapefile method to
9854     open shapefiles
9855    
9856     * Thuban/Model/load.py (ProcessSession.start_layer): Use the
9857     session's OpenShapefile method to open shapefiles
9858    
9859     * test/test_classification.py
9860     (TestClassification.test_classification): Use the session's
9861     OpenShapefile method to open shapefiles and build the filename in
9862     a more platform independed way
9863    
9864     * test/test_layer.py (TestLayer.setUp, TestLayer.tearDown):
9865     Implement to have a session to use in the tests
9866     (TestLayer.test_arc_layer, TestLayer.test_polygon_layer)
9867     (TestLayer.test_point_layer, TestLayer.test_empty_layer): Use the
9868     session's OpenShapefile method to open shapefiles
9869     (TestLayerLegend.setUp): Instantiate a session so that we can use
9870     it to open shapefiles.
9871     (TestLayerLegend.tearDown): Make sure that all references to
9872     layers and session are removed otherwise we may get a resource
9873     leak
9874    
9875     * test/test_map.py (TestMapAddLayer.test_add_layer)
9876     (TestMapWithContents.setUp): Instantiate a session so that we can
9877     use it to open shapefiles.
9878     (TestMapWithContents.tearDown): Make sure that all references to
9879     layers, maps and sessions are removed otherwise we may get a
9880     resource leak
9881     ("__main__"): use support.run_tests() so that more info about
9882     uncollected garbage is printed
9883    
9884     * test/test_save.py (SaveSessionTest.testSingleLayer): Use the
9885     session's OpenShapefile method to open shapefiles
9886     ("__main__"): use support.run_tests() so that more info about
9887     uncollected garbage is printed
9888    
9889     * test/test_selection.py (TestSelection.tearDown): Make sure that
9890     all references to the session and the selection are removed
9891     otherwise we may get a resource leak
9892     (TestSelection.get_layer): Instantiate a session so that we can
9893     use it to open shapefiles.
9894     ("__main__"): use support.run_tests() so that more info about
9895     uncollected garbage is printed
9896    
9897     * test/test_session.py (TestSessionBase.tearDown)
9898     (TestSessionWithContent.tearDown): Make sure that all references
9899     to the session and layers are removed otherwise we may get a
9900     resource leak
9901     (TestSessionWithContent.setUp): Use the session's OpenShapefile
9902     method to open shapefiles
9903    
9904 jonathan 721 2003-04-24 Jonathan Coles <[email protected]>
9905    
9906     * Thuban/Model/load.py (XMLReader.read): Should have been checking
9907     if the file_or_filename object had the 'read' attribute.
9908    
9909 jonathan 715 2003-04-23 Jonathan Coles <[email protected]>
9910    
9911 jonathan 720 * Thuban/Model/resource.py: Fixes RTbug #1813.
9912     (ReadProjFile): Add documentation about which exceptions are raised.
9913     Always pass the exceptions up to the caller.
9914     (GetProjFiles): If the directory can't be read return an empty list.
9915     If any of the proj files can't be read skip that file and go
9916     on to the next one.
9917    
9918     * test/test_proj.py: Added test cases to handle nonexistent files,
9919     unreadable files, and files that don't parse correctly.
9920    
9921     2003-04-23 Jonathan Coles <[email protected]>
9922    
9923 jonathan 716 Projection dialog. Allows the user to select from a list
9924     of projection templates and optionally edit them and save new ones.
9925    
9926     * Thuban/UI/projdialog.py (ProjFrame): New. Main dialog.
9927     (ProjPanel): Base class for projection specific panels.
9928     (TMPanel): Projection panel for Transverse Mercartor.
9929     (UTMPanel): Projection panel for Universal Transverse Mercartor.
9930     (LCCPanel): Projection panel for Lambert Conic Conformal.
9931     (GeoPanel): Projetion panel for Geographic Projection.
9932    
9933     2003-04-23 Jonathan Coles <[email protected]>
9934    
9935 jonathan 715 * Thuban/Model/load.py (XMLReader): Renamed from XMLProcessor to
9936     promote symmetry. There now exists XMLReader and XMLWriter.
9937     (XMLReader.read): New. Call to read the given file descriptor or
9938     filename.
9939     (XMLReader.close): New. Make sure the file is closed.
9940     (XMLReader.GetFileName): New. Return just the file name that is being
9941     read from.
9942     (XMLReader.GetDirectory): New. Return just the directory of the file
9943     that is being read.
9944     (XMLReader.AddDispatchers): New. Take a dictionary which contains
9945     the names of functions to call as the XML tree is parsed.
9946     (XMLReader.startElementNS): Updated to use new dispatcher dictionary.
9947     (XMLReader.endElementNS): Updated to use new dispatcher dictionary.
9948     (SessionLoader): Removed class variables start_dispatcher and
9949     end_dispatcher since this functionality is now part of a class
9950     instance. Fixes RTbug #1808.
9951     (SessionLoader.__init__): Add dispatcher functions.
9952     (load_xmlfile): Code was moved into the XMLReader.read().
9953     (load_session): Use modified SessionLoader.
9954    
9955     * Thuban/Model/map.py (Map.GetProjection): New. Returns the
9956     map's projection.
9957    
9958     * Thuban/Model/proj.py (Projection.GetParameters): Renamed to
9959     GetAllParameters.
9960     (Projection.GetParameter): Returns the value for the given parameter.
9961    
9962     * Thuban/Model/resource.py: Use XMLReader and XMLWriter.
9963     (GetProjFiles): Renamed from GetProjections. Now returns a list
9964     of ProjFile objects.
9965     (GetSystemProjFiles): Renamed from GetSuppliedProjections. Returns
9966     a list of ProjFile objects whose files are not user defined.
9967     (GetUserProjFiles): Renamed from GetUserProjections. Returns a
9968     list of ProjFile objects whose files are user defined.
9969     (ProjFileReader): Extend new XMLReader.
9970    
9971     * Thuban/Model/save.py (XMLWriter): Renamed from XMLSaver to
9972     promote symmetry.
9973    
9974     * Thuban/UI/classgen.py (ClassGenDialog.__init__): Use a wxChoice
9975     control instead of a wxComboBox. wxChoice controls do not generate
9976     events as the uses highlights possible choices which fixes problems
9977     with resizing the dialog when the use selects an option.
9978    
9979     * Thuban/UI/classifier.py (Classifier.__init__): Use a wxChoice
9980     control instead of a wxComboBox.
9981    
9982     * Thuban/UI/mainwindow.py (MainWindow.Projection): Use new projection
9983     dialog.
9984    
9985     * test/test_proj.py (TestProjection.test): New tests for GetParameter
9986     method.
9987    
9988 bh 703 2003-04-22 Bernhard Herzog <[email protected]>
9989    
9990 bh 705 * Thuban/UI/mainwindow.py: Remove some unused imports and global
9991     constants
9992    
9993 bh 703 * Thuban/UI/identifyview.py (IdentifyListCtrl.selected_shape)
9994     (IdentifyGridCtrl.selected_shape): Use table, not shapetable.
9995    
9996 bh 700 2003-04-17 Bernhard Herzog <[email protected]>
9997    
9998 bh 701 * Thuban/Model/layer.py: Don't import LAYER_LEGEND_CHANGED.
9999     (Layer): Update doc-string since LAYER_LEGEND_CHANGED is not used
10000     anymore.
10001     (Layer.BoundingBox, Layer.GetFieldType, Layer.NumShapes)
10002     (Layer.ShapeType, Layer.Shape): No need to call
10003     self.open_shapefile since it's always called in __init__
10004    
10005 bh 700 * Thuban/UI/application.py (ThubanApplication.MainLoop): Removed.
10006     In wxPython 2.4 there's no need to extend MainLoop anymore since
10007     wxPython itself makes sure OnExit is called.
10008    
10009 jonathan 688 2003-04-16 Jonathan Coles <[email protected]>
10010    
10011 jonathan 693 Initial putback of projection management code. Includes new
10012     classes to read and write projection files. The current load
10013     and save classes were abstracted a bit so they could be reused.
10014     The Projection class was extended to provide new methods and
10015     have a name.
10016    
10017     * Thuban/Model/load.py (XMLProcessor): New. Contains all the
10018     general XML reading methods that were part of ProcessSession.
10019    
10020     * Thuban/Model/proj.py (Projection.__init__): Accepts an optional
10021     name.
10022     (ProjFile): New. Represents a file that contains projection
10023     information.
10024    
10025     * Thuban/Model/resource.py: New. Contains general utilities
10026     for read and writing projection files.
10027    
10028     * Thuban/Model/save.py (XMLSaver): New. Contains all the
10029     general XML writing methods that were part of SessionSaver.
10030     (SessionSaver): Renamed from Saver.
10031    
10032     * test/test_proj.py: New test cases for the projection
10033     file read and write functions.
10034    
10035     2003-04-16 Jonathan Coles <[email protected]>
10036    
10037 jonathan 688 * Thuban/Model/classification.py: Use repr() around values
10038     in the ClassGroup*.__repr__() methods so it is clearer when
10039     a value is a string and when it is a number.
10040    
10041     * test/test_load.py: Rework the classification test to test
10042     that we can load old files.
10043     (testLabels): Test a file where the groups have labels.
10044    
10045 bh 687 2003-04-16 Bernhard Herzog <[email protected]>
10046    
10047     Safer implementation of the performance enhancements of the
10048     low-level renderer:
10049    
10050     * extensions/thuban/wxproj.cpp (extract_projection)
10051     (extract_pointer): Rename extract_projection to extract_pointer
10052     and redefine its purpose to return the pointer stored in a CObject
10053     returned by the object's cobject method. Update all callers.
10054     (s_draw_info, free_draw_info, draw_polygon_init): Implement the
10055     handling of these low-level parameters so that each s_draw_info
10056     instance is handled as a CObject at python level that also
10057     contains real references to the actual python objects which
10058     contain the values in the struct. Add free_draw_info as the
10059     destructor.
10060     (draw_polygon_shape): Add the py_draw_info parameter which must a
10061     cobject containing an s_draw_info pointer.
10062    
10063     * Thuban/UI/renderer.py (MapRenderer.polygon_render_param): New
10064     method to instantiat the low-level render parameter
10065     (MapRenderer.draw_shape_layer): Use the new method. Remove some
10066     commented out code.
10067     (MapRenderer.draw_polygon_shape): Make the first parameter not the
10068     layer but the low-level render parameter
10069     (ScreenRenderer.draw_shape_layer): Use the low-level render
10070     parameter.
10071    
10072 jonathan 673 2003-04-15 Jonathan Coles <[email protected]>
10073    
10074 jonathan 680 * Thuban/Model/classification.py: Implemented __repr__ for
10075     the ClassGroup* classes to make debugging a bit easier.
10076     (ClassGroup.SetLabel): Check that the string is an instance
10077     of StringTypes not StringType. Accounts for Unicode strings.
10078    
10079     * Thuban/Model/color.py: Implemented __repr__ to make
10080     debugging a bit easier.
10081    
10082     * Thuban/Model/save.py (Saver.write_classification): Need to
10083     save the group label.
10084    
10085     * test/test_load.py (testClassification): New. Loads the
10086     iceland_sample_test.thuban file and checks if it was loaded
10087     correctly.
10088    
10089     2003-04-15 Jonathan Coles <[email protected]>
10090    
10091 jonathan 673 * extensions/thuban/wxproj.cpp (draw_polygon_init): New. Used
10092     to improve rendering performance by initializing the variables
10093     that are not change each time draw_polygon_shape() is called.
10094     The values are stored in a global struct draw_info.
10095     (draw_polygon_shape): Removed initialization code that is
10096     now in draw_polygon_init().
10097    
10098     * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Make
10099 jonathan 674 drawing initialization call to draw_polygon_init()
10100     (MapRenderer.draw_polygon_shape): Use new signature of
10101     draw_polygon_shape.
10102 jonathan 673
10103 jonathan 674 * Thuban/UI/classgen.py (GenUniformPanel): Fix spin control
10104     weirdness by setting the range to (1, maxint).
10105 jonathan 673
10106 jonathan 674 * Thuban/Model/classification.py (ClassGroupProperties): Make
10107     instance variables private and optimize comparison operator
10108     by first checking if the color references are the same.
10109     (ClassGroupSingleton): Make instance variables private.
10110     (ClassGroupRange): Make instance variables private.
10111 jonathan 673
10112 jonathan 674 * HOWTO-Release: Filled in missing steps for releasing packages.
10113    
10114 bh 672 2003-04-15 Bernhard Herzog <[email protected]>
10115    
10116     First stab at internationalized messages:
10117    
10118     * Thuban/__init__.py (_): Implement the translation function for
10119     real using the python gettext module.
10120    
10121     * Thuban/UI/classifier.py (ClassTable.GetRowLabelValue): Don't
10122     translate empty strings.
10123    
10124     * Thuban/UI/application.py (ThubanApplication.read_startup_files):
10125     Add a missing space to a warning message
10126    
10127     * po/README: New. Notes about the management of the translation
10128     files.
10129    
10130     * po/Makefile: New. Makefile to help manage the translation files.
10131    
10132     * po/es.po: New. Spanish translation by Daniel Calvelo Aros
10133    
10134     * MANIFEST.in: Include the *.mo files in Resources/Locale and the
10135     translations and support files in po/
10136    
10137     * setup.py (data_files): Add the *.mo files to the data_files too
10138    
10139     * README: Add note about the translations when building from CVS
10140    
10141 jonathan 669 2003-04-14 Jonathan Coles <[email protected]>
10142    
10143     * Thuban/UI/dock.py: Fixes some window resizing problems most
10144     noticable under windows. Always assume the button bitmaps will
10145     be there. Code clean up.
10146     (DockabelWindow.Dock, DockableWindow.UnDock): Force all the
10147     images for the dock/undock button to the same images.
10148     Work around for RTbug #1801.
10149    
10150     * Thuban/UI/legend.py (LegendPanel.__init__): The toolbar should
10151     be allowed to grow within the sizer. Fixes a bug under Windows
10152     where the toolbar wasn't being drawn.
10153    
10154 frank 664 2003-04-14 Frank Koormann <[email protected]>
10155    
10156     * Resources/Bitmaps/dock_12.xpm, Resources/Bitmaps/undock_12.xpm:
10157     Updated design to try to make the button functionality more
10158     transparent.
10159    
10160 jonathan 662 2003-04-14 Jonathan Coles <[email protected]>
10161    
10162     * Thuban/UI/legend.py (LegendPanel.__init__): Call Create() to
10163     finalize the intialization of the panel.
10164    
10165     * Thuban/UI/dock.py (DockPanel.Create): New. Finalizes the
10166     creation of the panel. Should be the last thing called in the
10167     initializer of a subclass.
10168    
10169     * Thuban/UI/classgen.py (ClassGenDialog.__init__): Actively
10170     set the current selections in the combo boxes. This is needed
10171     under Windows.
10172    
10173     * Thuban/UI/classifier.py (Classifier.__init__): Add a top
10174     level panel to the dialog so that the background colors are
10175     consistent under Windows.
10176    
10177 jonathan 646 2003-04-11 Jonathan Coles <[email protected]>
10178    
10179 jonathan 662 * Thuban/UI/classgen.py: Change color ramps to start at white
10180     not black.
10181    
10182     * Thuban/UI/legend.py: Enable/disable the legend buttons when
10183     the legend changes. Fixes RTbug #1793.
10184    
10185     * test/test_classification.py: Added test for copying of
10186     classifications.
10187    
10188     2003-04-11 Jonathan Coles <[email protected]>
10189    
10190 jonathan 647 * Thuban/UI/resource.py: New. Centralize the loading of resources
10191     such as bitmaps.
10192    
10193     * Thuban/UI/classgen.py (GenUniquePanel.__init__): Reordered buttons,
10194     added images to the move buttons, added 'reverse' button.
10195     (CustomRampPanel.__init__): Added images to the move buttons.
10196     (GreyRamp): New. Generates a ramp from white to black.
10197     (HotToColdRamp): New. Generates a ramp from cold to hot colors.
10198    
10199     * Thuban/UI/classifier.py: Refactored ID's from ID_CLASSIFY_* to
10200     ID_PROPERTY_*.
10201     (Classifier.__init__): Minor changes to the layout.
10202     (Classifier._OnTitleChanged): Listen for when the user edits the
10203     title and update the dialog's title and the layer's title.
10204    
10205     * Thuban/UI/dock.py: Use new bitmaps for the control buttons.
10206    
10207     * Thuban/UI/legend.py: Use new bitmaps for the control buttons.
10208     (LegendTree._OnMsgLayerTitleChanged): Change the displayed title
10209     if the layer's title changes.
10210    
10211     * Thuban/UI/mainwindow.py: Added new menu item and associated code
10212     to open a dialog to rename the map.
10213     (MainWindow): Use new resource class to import bitmaps.
10214    
10215     2003-04-11 Jonathan Coles <[email protected]>
10216    
10217 jonathan 646 * Resources/Bitmaps/close_12.xpm, Resources/Bitmaps/dock_12.xpm,
10218 jonathan 647 Resources/Bitmaps/group_use.xpm, Resources/Bitmaps/group_use_all.xpm,
10219     Resources/Bitmaps/group_use_none.xpm,
10220     Resources/Bitmaps/group_use_not.xpm,
10221     Resources/Bitmaps/hide_layer.xpm,
10222     Resources/Bitmaps/layer_properties.xpm,
10223     Resources/Bitmaps/lower_layer.xpm, Resources/Bitmaps/raise_layer.xpm,
10224     Resources/Bitmaps/show_layer.xpm, Resources/Bitmaps/undock_12.xpm:
10225     New.
10226 jonathan 646
10227 jonathan 636 2003-04-10 Jonathan Coles <[email protected]>
10228    
10229 jonathan 644 * Thuban/Model/classification.py: (ClassGroupRange.__init__):
10230     Should pass group to ClassGroup constructor.
10231    
10232     2003-04-10 Jonathan Coles <[email protected]>
10233    
10234 jonathan 636 * Thuban/Model/classification.py: (ClassGroup): Move all the common
10235     methods of the derived classes ([Set|Get]Properties(), __eq__, __ne__)
10236     here. Implement SetVisible(), IsVisible().
10237     (ClassGroup.__init__): Add group parameter which acts as a copy
10238     constructor.
10239    
10240     * Thuban/UI/classifier.py (ClassTable): Add a new column for the
10241     "Visible" check boxes.
10242     (Classifier): Rename the buttons and refactor the code to match
10243     the new labels.
10244    
10245     * Thuban/UI/legend.py: Classify button is now called "Properties".
10246     Refactored the code to change variable names.
10247     (LegendTree.__FillTreeLayer): Only list a group if it is visible.
10248    
10249     * Thuban/UI/mainwindow.py: MainWindow.OpenClassifier renamed to
10250     MainWindow.OpenLayerProperties. MainWindow.LayerEditProperties
10251     renamed to MainWindow.LayerEditProperties.
10252     (MainWindow.ToggleLegend): Don't include map name in legend title.
10253     (MainWindow.SetMap): Added the map name to the window title.
10254     (MainWindow.LayerFillColor, MainWindow.LayerTransparentFill,
10255     MainWindow.LayerOutlineColor, MainWindow.LayerNoOutline): Removed.
10256     Functionality is found in the layer properties dialog.
10257    
10258     * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Only
10259     draw visible groups.
10260    
10261 jonathan 626 2003-04-09 Jonathan Coles <[email protected]>
10262    
10263 jonathan 634 * Thuban/UI/classgen.py: Modifications to allow simple
10264     addition and selection of new color schemes.
10265     (MonochromaticRamp): New. Generates a ramp between two colors.
10266     (RedRamp): New. Generates a ramp of all red.
10267     (GreenRamp): New. Generates a ramp of all green.
10268     (BlueRamp): New. Generates a ramp of all blue.
10269    
10270     2003-04-09 Jonathan Coles <[email protected]>
10271    
10272 jonathan 626 * Thuban/Model/classification.py (Classification.__deepcopy__):
10273     Need to copy over field and fieldType attributes.
10274    
10275     * Thuban/Model/table.py (Table.field_range): New. Retrive the
10276     maximum and minimum values over the entire table for a given
10277     field.
10278     (Table.GetUniqueValues): New. Retrieve all the unique values
10279     in the table for a given field.
10280    
10281     * Thuban/UI/classgen.py: Renamed GenRangePanel to GenUniformPanel.
10282     (GenUniquePanel): New. Controls to allow the user to select
10283     which unique field values they would like in the classification.
10284     (CustomRampPanel): Code that was in ClassGenDialog that allows
10285     the user to select the properties for a custom ramp.
10286     (ClassGenerator.GenUniformDistribution): Was called GenerateRanges.
10287    
10288     * Thuban/UI/classifier.py: Removed a lot of debugging code.
10289     (Classifier._SetClassification): Callback method so that the
10290     class generator can set the classification in the grid.
10291     (ClassGroupPropertiesCtrl): New. Encapsulates the drawing and
10292     editing of a group properties class into a wxWindows control.
10293    
10294     * Thuban/UI/dock.py: It was decided that if the user closes
10295     a dockable window the window should simply hide itself. That
10296     way if the user wants to show the dock again it appears in the
10297     same place as it was when it was closed.
10298     (DockableWindow.Destroy): Call renamed method OnDockDestroy().
10299     (DockableWindow._OnButtonClose): Hide the window instead of
10300     destroying it.
10301     (DockableWindow._OnClose): Hide the window instead of
10302     destroying it.
10303    
10304     * Thuban/UI/legend.py (LegendTree): Use a private method to
10305     consistently set the font and style of the text. Fixes RTbug #1786.
10306    
10307     * Thuban/UI/mainwindow.py: Import just the Classifier class.
10308    
10309 bh 623 2003-04-07 Bernhard Herzog <[email protected]>
10310    
10311 bh 625 * Thuban/UI/mainwindow.py (main_menu): Move the toggle_legend item
10312     to the map module
10313    
10314     2003-04-07 Bernhard Herzog <[email protected]>
10315    
10316 bh 623 * Thuban/UI/mainwindow.py (MainWindow.ShowSessionTree): Removed in
10317     favor of ToggleSessionTree
10318     (MainWindow.ToggleSessionTree): New method to toggle visibility of
10319     the session tree.
10320     (MainWindow.SessionTreeShown): New method to return whether the
10321     session tree is currently shown.
10322     (MainWindow.ToggleLegend): New method to toggle visibility of the
10323     legend
10324     (MainWindow.ShowLegend): Implement in terms of ToggleLegend and
10325     LegendShown
10326     (MainWindow.LegendShown): New method to return whether the legend
10327     is currently shown.
10328     (_method_command): Add checked parameter so we can define check
10329     menu items
10330     (_has_tree_window_shown, _has_legend_shown): Use the appropriate
10331     mainwindow methods.
10332     (show_session_tree, show_legend commands): Removed.
10333     (toggle_session_tree, toggle_legend commands): New commands to
10334     toggle the visibility of the dialogs
10335    
10336 jonathan 612 2003-04-07 Jonathan Coles <[email protected]>
10337    
10338 jonathan 619 * Thuban/UI/classgen.py: Fix Windows problem.
10339    
10340     * Thuban/UI/dock.py: Fix Windows problem.
10341    
10342     * Thuban/UI/mainwindow.py: Use False instead of false.
10343     (MainWindow.ShowLegend): Remove unnecessary switch parameter.
10344    
10345     2003-04-07 Jonathan Coles <[email protected]>
10346    
10347 jonathan 612 Since we now say that the order of the groups in a classification
10348     matters, it makes sense to be able to manipulate that order. Most
10349     of the changes to Thuban/Model/classification.py are to that end.
10350    
10351     * Thuban/Model/classification.py (Classification.AppendGroup,
10352     Classification.InsertGroup, Classification.ReplaceGroup,
10353     Classification.RemoveGroup, Classification.GetGroup): Do as the
10354     names imply.
10355     (Classification.FindGroup): This was called GetGroup, but GetGroup
10356     takes an index, while FindGroup takes a value.
10357     (Classification.__deepcopy__): Copy all the groups, BUT NOT THE LAYER
10358     REFERENCE. Currently there is a cyclic reference between the layer
10359     and its classification. If the classification doesn't need to know
10360     its owning layer we can change this, since it may make sense to be
10361     able to use the same classification with different layers.
10362    
10363     * Thuban/Model/load.py: Use Classification.AppendGroup(), not AddGroup()
10364    
10365     * Thuban/UI/classgen.py: Use Classification.AppendGroup(),
10366     not AddGroup()
10367    
10368     * Thuban/UI/classifier.py: Now that we can depend on the order in
10369     a Classification and have methods to manipulate that order we don't
10370     need to use our own data structures in the grid. We can simply make
10371     the grid/table access the information they need from a copy of
10372     the classification object.
10373     (Classifier._OnCloseBtn): Event handler for when the user clicks
10374     'Close'. This is needed so if the user applies changes and then
10375     continues to change the table the user has the option of discarding
10376     the most recent changes and keeping what they applied.
10377    
10378     * Thuban/UI/mainwindow.py: Put "Show Legend" and "Show Session Tree"
10379     into the same group.
10380    
10381     * extensions/thuban/wxproj.cpp (check_version): If Thuban is compiled
10382     with a really old version of proj, PJ_VERSION won't even be defined.
10383     If it isn't defined then just compile so that the function always
10384     returns Py_False.
10385    
10386     * test/test_classification.py: Fix tests to use the renamed methods.
10387     Still need to write tests for the new methods.
10388    
10389 jonathan 601 2003-04-04 Jonathan Coles <[email protected]>
10390 jonathan 608
10391 jonathan 612 * Thuban/UI/classifier.py (Classifier.__SelectField): Move the
10392     call to SetSelection out of the method and before the call
10393     to __SelectField in __init__. This prevents a recursion of events
10394     when _OnFieldSelect is triggered by the user.
10395    
10396     2003-04-04 Jonathan Coles <[email protected]>
10397    
10398 jonathan 608 * Thuban/Model/classification.py: Rename Color.None to
10399     Color.Transparent.
10400     (ClassGroupProperties.SetLineColori, ClassGroupProperties.SetFill):
10401     Don't bother copying the color, since Colors are immutable.
10402    
10403     * Thuban/Model/color.py, Thuban/Model/layer.py, Thuban/Model/load.py,
10404     Thuban/UI/classifier.py, Thuban/UI/mainwindow.py,
10405     Thuban/UI/renderer.py, Thuban/UI/view.py:
10406     Rename Color.None to Color.Transparent.
10407    
10408     * test/test_classification.py, test/test_load.py: Rename Color.None
10409     to Color.Transparent.
10410    
10411     2003-04-04 Jonathan Coles <[email protected]>
10412 jonathan 603
10413     * Thuban/Model/classification.py: Fix assert calls.
10414     (ClassGroupProperties.SetLineColor, ClassGroupProperties.SetFill):
10415     Copy the color parameter rather than hold onto a reference.
10416 jonathan 601
10417 jonathan 603 * Thuban/Model/color.py (Color.__copy__, Color.__deepcopy): Copy
10418     the color object.
10419     (NoColor.__copy__, NoColor.__deepcopy): Return 'self' so that we
10420     are sure there exists only one refernce to Color.None in the system.
10421     This allows us to use 'is' rather than the comparision functions.
10422    
10423     * Thuban/Model/save.py: Fix assert calls.
10424    
10425     * Thuban/UI/classifier.py: Fix assert calls.
10426     (ClassGrid._OnCellDClick): Call up to the classifier to open the
10427     dialog to edit the groups properties.
10428     (ClassGrid._OnCellResize): Make sure that the scollbars are drawn
10429     correctly if a cell is resized.
10430     (ClassTable.SetClassification): New. Changes the classification
10431     that is in the table.
10432     (ClassTable.__SetRow): Allow groups to be prepended.
10433     (Classifier): New code for opening the EditProperties and
10434     GenerateRanges dialogs.
10435     (SelectPropertiesDialog.__GetColor): Only set the color in the
10436     color dialog if the current color is not None.
10437    
10438     * Thuban/UI/dock.py: Fix assert calls.
10439    
10440     * Thuban/UI/legend.py: Fix assert calls.
10441    
10442     * Thuban/UI/renderer.py: Fix assert calls.
10443    
10444     * Thuban/UI/classgen.py (ClassGenDialog): Dialog for generating
10445     classifications.
10446     (GenRangePanel): Panel specific to range generation.
10447     (GenSingletonPanel): Panel specific to singleton generation.
10448     (ClassGenerator): Class responsible for actually generating
10449     the classification from the data gathered in the dialog box.
10450     (PropertyRamp): Generates properties whose values range from
10451     a starting property to an ending property.
10452 jonathan 601
10453 bh 600 2003-04-03 Bernhard Herzog <[email protected]>
10454    
10455     * test/support.py (print_garbage_information): New function that
10456     prints information about still connected messages and memory
10457     leaks.
10458     (run_suite): Removed.
10459     (run_tests): New function for use as a replacement of
10460     unittest.main in the test_* files. This one calls
10461     print_garbage_information at the end.
10462    
10463     * test/runtests.py (main): Use support.print_garbage_information
10464    
10465     * test/test_layer.py: Use support.run_tests instead of
10466     unittest.main so we get memory leak information
10467     (TestLayer.test_arc_layer, TestLayer.test_polygon_layer)
10468     (TestLayer.test_point_layer, TestLayer.test_empty_layer)
10469     (TestLayerLegend.test_visibility): Call the layer's Destroy method
10470     to fix a memory leak.
10471    
10472     * test/test_classification.py: Use support.run_tests instead of
10473     unittest.main so we get memory leak information
10474     (TestClassification.test_classification): Call the layer's Destroy
10475     method to fix a memory leak.
10476    
10477 bh 591 2003-04-02 Bernhard Herzog <[email protected]>
10478    
10479 bh 595 * extensions/thuban/wxproj.cpp (check_version, check_version_gtk):
10480     Handle the reference counts of the return value and errors in
10481     PyArg_ParseTuple correctly.
10482    
10483 bh 593 * Thuban/UI/application.py (ThubanApplication.OpenSession): Make
10484     sure the filename is absolute to avoid problems when saving the
10485     session again
10486    
10487 bh 591 * Thuban/Model/table.py: Remove unnecessary import. Fix a typo.
10488    
10489 jonathan 587 2003-04-01 Jonathan Coles <[email protected]>
10490    
10491 jonathan 589 * Thuban/UI/renderer.py (MapRenderer.draw_point_shape): Check
10492 jonathan 587 that there actually are points in the returned list of points
10493     before trying to index into the list. The list may be empty if
10494     the shape is a Null Shape.
10495    
10496 bh 586 2003-04-01 Bernhard Herzog <[email protected]>
10497    
10498     * test/test_map.py: Don't use from <module> import *
10499    
10500 jonathan 581 2003-04-01 Jonathan Coles <[email protected]>
10501    
10502     * Thuban/Model/session.py: Use LAYER_CHANGED instead of
10503     LAYER_LEGEND_CHANGED
10504    
10505     * Thuban/UI/dock.py (DockableWindow._OnButtonClose): Call
10506     self.Destroy() to close the window after yesterday's changes.
10507    
10508     * test/test_map.py, test/test_session.py: Fix messages that
10509     are sent from maps and layers.
10510    
10511 jonathan 575 2003-03-31 Jonathan Coles <[email protected]>
10512    
10513     * Thuban/UI/classifier.py: Commented out some debugging statements.
10514     (ClassDataPreviewer.Draw): Draw rectangles for polygon layers per
10515     RTbug #1769.
10516    
10517     * Thuban/UI/dock.py (DockableWindow.UnDock): Restore size and
10518     position (although position doesn't work yet under GTK).
10519     (DockableWindow.Destroy): New. Called when the window must be
10520     closed. Namely needed when the DockFrame closes and must close
10521     its children.
10522     (DockFrame): Listen for EVT_CLOSE and destroy all children.
10523    
10524     * Thuban/UI/legend.py (LegendPanel.Destroy): New. Cleans up
10525     when then window is told to close.
10526     (LegendTree._OnMsgLayerChanged): Fixes a seg fault bug. See
10527     comment in source for more info.
10528    
10529     * Thuban/UI/main.py: Show the legend by default when Thuban starts.
10530    
10531     * Thuban/UI/mainwindow.py: Renamed OnClose to _OnClose for
10532     symmetry with other such methods.
10533     (MainWindow.ShowLegend): Show the legend docked by default.
10534    
10535 jonathan 569 2003-03-28 Jonathan Coles <[email protected]>
10536    
10537     * Thuban/UI/classifier.py: Support for highlighting a specific
10538     group within the grid when the classification dialog is opened.
10539     Also contains a lot of debugging printouts which will later
10540     be removed.
10541    
10542     * Thuban/UI/dock.py: Complete rework on the dock code so that
10543     that it is fairly removed from the rest of the Thuban application.
10544     It is easy to add new docks which the rest of the program having
10545     to be aware of them.
10546    
10547     * Thuban/UI/legend.py: Modifications to support selecting a
10548     specific group in the classification dialog. Changed how layers
10549     are drawn when the layer is visible/invisible.
10550    
10551     * Thuban/UI/mainwindow.py: Removed legend specific code and
10552     replaced it with calls to the new dock code.
10553    
10554     * Thuban/UI/renderer.py (MapRenderer.__init__): Added assert
10555     to check if scale > 0. Trying to track down a divide by zero.
10556    
10557 jonathan 557 2003-03-26 Jonathan Coles <[email protected]>
10558    
10559 jonathan 567 * Thuban/UI/legend.py: Removed unnecessary LegendDialog class.
10560     (LegendPanel): Removed _OnDock()/_OnUnDock() methods which are
10561     now part of DockableWindow.
10562     (LegendPanel.DoOnSelChanged): Select the current layer in the
10563     map.
10564     (LegendTree._OnSelChanged): Call LegendPanel.DoOnSelChanged()
10565     with the selected layer and/or group.
10566    
10567     2003-03-26 Jonathan Coles <[email protected]>
10568    
10569 jonathan 557 This putback contains the code for dockable windows. There is
10570     no support in wxWindows as of this date for windows that can
10571     attach themselves to other windows.
10572    
10573     The current model contains a DockableWindow which has a parent
10574     window for when it is detached and a dock window that it puts
10575     its contents in when it is docked. The contents of a DockableWindow
10576     must be a DockPanel. DockPanel itself derives from wxPanel.
10577    
10578     * Thuban/Model/layer.py (Layer.ClassChanged): Send a LAYER_CHANGED
10579     message, not a LAYER_LEGEND_CHANGED message.
10580    
10581     * Thuban/Model/map.py (Map): Forward LAYER_CHANGED messages.
10582    
10583     * Thuban/UI/classifier.py (Classifier.__init__): Use wxADJUST_MINSIZE
10584     as one of the style properties for the fieldTypeText item to
10585     be sure that its size is correct when the text changes.
10586    
10587     * Thuban/UI/dock.py: New. Classes for the DockPanel and
10588     DockableWindow.
10589    
10590     * Thuban/UI/legend.py: Added some more buttons and made the
10591     LegendPanel a DockPanel.
10592    
10593     * Thuban/UI/mainwindow.py: Added sash windows to the main window
10594     and supporting functions for manipulating the sashes.
10595     (MainWindow.ShowLegend): Create a DockableWindow with the
10596     LegendPanel as the contents.
10597    
10598     * Thuban/UI/messages.py: Added DOCKABLE_* messages
10599    
10600     * Thuban/UI/view.py (MapCanves.SetMap): Listen for LAYER_CHANGED,
10601     not LAYER_LEGEND_CHANGED, messages.
10602    
10603 jonathan 554 2003-03-25 Jonathan Coles <[email protected]>
10604    
10605     * setup.py: Added custom script bdist_rpm_build_script so that
10606     when the rpm is built the path to wx-config is correct.
10607    
10608     * setup.cfg: Added line saying to use the custom build script
10609    
10610 jonathan 552 2003-03-20 Jonathan Coles <[email protected]>
10611    
10612     Initial implementation of the Legend.
10613    
10614     * Thuban/UI/legend.py: New. Creates a window that shows the map's
10615     Legend information and allows the user to add/modify classifications
10616     and how the layers are drawn on the map.
10617    
10618     * setup.py: New command 'build_docs' which currently uses
10619     happydoc to generate html documentation for Thuban.
10620    
10621     * Thuban/Model/classification.py (ClassGroup.GetDisplayText): New.
10622     Returns a string which is appropriately describes the group.
10623    
10624     * Thuban/Model/layer.py (Layer.SetClassification): Generate a
10625     LAYER_CHANGED event instead of a LAYER_LEGEND_CHANGED event.
10626    
10627     * Thuban/Model/map.py (Map): Rename messages and use new, more
10628     specific, messages.
10629    
10630     * Thuban/Model/messages.py: New message to indicate that a layer's
10631     data has changed (LAYER_CHANGED). New map messages to indicate
10632     when layers have been added/removed/changed or if the stacking order
10633     of the layers has changed.
10634    
10635     * Thuban/Model/session.py: Rename and use new messages.
10636    
10637     * Thuban/UI/classifier.py: Remember if any changes have actually
10638     been applied so that if the dialog is cancelled without an application
10639     of changes we don't have to set a new classification.
10640     (ClassDataPreviewer): Pulled out the window specific code and put it
10641     ClassDataPreviewWindow. ClassDataPreviewer can then be used to draw
10642     symbols on any DC.
10643    
10644     * Thuban/UI/mainwindow.py: New code to open the legend.
10645    
10646     * Thuban/UI/view.py: Use new message names.
10647    
10648 jonathan 541 2003-03-19 Jonathan Coles <[email protected]>
10649    
10650     * Thuban/UI/main.py (verify_versions): New. Checks the versions
10651     of Python, wxPython, and some other libraries.
10652    
10653     * extensions/thuban/wxproj.cpp (check_version): Checks the given
10654     version against what wxproj was compiled with.
10655     (check_version_gtk): If wxproj was compiled with gtk then check
10656     the given version against the version of the gtk library
10657     currently being used.
10658    
10659 bh 538 2003-03-14 Bernhard Herzog <[email protected]>
10660    
10661     * test/test_command.py: Run the tests when the module is run as a
10662     script
10663    
10664     2003-03-14 Bernhard Herzog <[email protected]>
10665    
10666     Implement selection of multiple selected shapes in the same layer:
10667    
10668     - Introduce a new class to hold the selection. This basically
10669     replaces the interactor which was nothing more than the
10670     selection anyway. A major difference is of course that the new
10671     selection class supports multiple selected shapes in one layer
10672    
10673     - Move the object that represents the selection from the
10674     application to the canvas. The canvas is a better place than the
10675     application because the selection represents which shapes and
10676     layer of the map displayed by the canvas are selected and
10677     affects how the map is drawn.
10678    
10679     - Make the selection and its messages publicly available through
10680     the mainwindow.
10681    
10682     - The non-modal dialogs do not get a reference to the interactor
10683     anymore as they can simply refer to their parent, the
10684     mainwindow, for the what the interactor had to offer.
10685    
10686     * Thuban/UI/selection.py: New module with a class to represent the
10687     selection.
10688    
10689     * Thuban/UI/messages.py (SELECTED_TABLE, SELECTED_MAP): Remove
10690     these unused messages
10691    
10692     * Thuban/UI/application.py (ThubanApplication.OnInit)
10693     (ThubanApplication.OnExit, ThubanApplication.SetSession): The
10694     interactor is gone now.
10695     (ThubanApplication.CreateMainWindow): There is no interactor
10696     anymore so we pass None as the interactor argument for now for
10697     compatibility.
10698    
10699     * Thuban/UI/view.py (MapCanvas.delegated_messages)
10700     (MapCanvas.Subscribe, MapCanvas.Unsubscribe): In Subscribe and
10701     Unsubscribe, delegate messages according to the delegated_messages
10702     class variable.
10703     (MapCanvas.__getattr__, MapCanvas.delegated_methods): Get some
10704     attributes from instance variables as described with the
10705     delegated_methods class variable.
10706     (MapCanvas.__init__): New instance variable selection holding the
10707     current selection
10708     (MapCanvas.do_redraw): Deal with multiple selected shapes. Simply
10709     pass them on to the renderer
10710     (MapCanvas.SetMap): Clear the selection when a different map is
10711     selected.
10712     (MapCanvas.shape_selected): Simple force a complete redraw. The
10713     selection class now takes care of only issueing SHAPES_SELECTED
10714     messages when the set of selected shapes actually does change.
10715     (MapCanvas.SelectShapeAt): The selection is now managed in
10716     self.selection
10717    
10718     * Thuban/UI/mainwindow.py (MainWindow.delegated_messages)
10719     (MainWindow.Subscribe, MainWindow.Unsubscribe): In Subscribe and
10720     Unsubscribe, delegate messages according to the delegated_messages
10721     class variable.
10722     (MainWindow.delegated_methods, MainWindow.__getattr__): Get some
10723     attributes from instance variables as described with the
10724     delegated_methods class variable.
10725     (MainWindow.__init__): The interactor as ivar is gone. The
10726     parameter is still there for compatibility. The selection messages
10727     now come from the canvas.
10728     (MainWindow.current_layer, MainWindow.has_selected_layer):
10729     Delegate to the the canvas.
10730     (MainWindow.LayerShowTable, MainWindow.Classify)
10731     (MainWindow.identify_view_on_demand): The dialogs don't need the
10732     interactor parameter anymore.
10733    
10734     * Thuban/UI/tableview.py (TableFrame.__init__)
10735     (LayerTableFrame.__init__, LayerTableFrame.OnClose)
10736     (LayerTableFrame.row_selected): The interactor is gone. It's job
10737     from the dialog's point of view is now done by the mainwindow,
10738     i.e. the parent. Subscribe to SHAPES_SELECTED instead
10739     of SELECTED_SHAPE
10740    
10741     * Thuban/UI/dialogs.py (NonModalDialog.__init__): The interactor
10742     is gone. It's job from the dialog's point of view is now done by
10743     the mainwindow, i.e. the parent.
10744    
10745     * Thuban/UI/classifier.py (Classifier.__init__): The interactor is
10746     gone. It's job from the dialog's point of view is now done by the
10747     mainwindow, i.e. the parent.
10748    
10749     * Thuban/UI/tree.py (SessionTreeView.__init__): The interactor is
10750     gone. It's job from the dialog's point of view is now done by the
10751     mainwindow, i.e. the parent.
10752     (SessionTreeCtrl.__init__): New parameter mainwindow which is
10753     stored as self.mainwindow. The mainwindow is need so that the tree
10754     can still subscribe to the selection messages.
10755     (SessionTreeCtrl.__init__, SessionTreeCtrl.unsubscribe_all)
10756     (SessionTreeCtrl.update_tree, SessionTreeCtrl.OnSelChanged): The
10757     selection is now accessible through the mainwindow. Subscribe to
10758     SHAPES_SELECTED instead of SELECTED_SHAPE
10759    
10760     * Thuban/UI/identifyview.py (IdentifyView.__init__): Use the
10761     SHAPES_SELECTED message now.
10762     (IdentifyView.selected_shape): Now subscribed to SHAPES_SELECTED,
10763     so deal with multiple shapes
10764     (IdentifyView.__init__, IdentifyView.OnClose): The interactor is
10765     gone. It's job from the dialog's point of view is now done by the
10766     mainwindow, i.e. the parent.
10767    
10768     * Thuban/UI/controls.py (RecordListCtrl.fill_list): The second
10769     parameter is now a list of shape ids.
10770     (RecordTable.SetTable): The second parameter is now a list of
10771     indices.
10772    
10773     * Thuban/UI/renderer.py (ScreenRenderer.RenderMap): Rename the
10774     selected_shape parameter and ivar to selected_shapes. It's now a
10775     list of shape ids.
10776     (MapRenderer.draw_label_layer): Deal with multiple selected
10777     shapes. Rearrange the code a bit so that the setup and shape type
10778     distinctions are only executed once.
10779    
10780     * test/test_selection.py: Test cases for the selection class
10781    
10782 jonathan 527 2003-03-11 Jonathan Coles <[email protected]>
10783    
10784     * Thuban/Model/load.py: Temporary fix so that the xml reader
10785     doesn't cause Thuban to crash.
10786    
10787     * Thuban/Model/layer.py: Handle the cyclic references between
10788     a layer and its classification better, and be sure to disconnect
10789     the classification from the layer when the layer is destroyed
10790     so that we don't maintain a cyclic reference that may not be
10791     garbage collected.
10792    
10793     * Thuban/Model/classification.py: See comment for layer.py.
10794    
10795 jan 523 2003-03-12 Jan-Oliver Wagner <[email protected]>
10796    
10797     * HOWTO-Release: New. Information on the steps for releasing
10798     a new version of Thuban.
10799    
10800 jonathan 514 2003-03-11 Jonathan Coles <[email protected]>
10801    
10802     * Thuban/UI/classifier.py: Add normal border to SelectPropertiesDialog.
10803     Use True instead of true.
10804     (Classifier): Should have a single panel in which all the controls lie.
10805    
10806     * Thuban/UI/proj4dialog.py: Add normal border.
10807    
10808     * Thuban/UI/tree.py: Fixed problem with bad item images under Windows.
10809    
10810     * Thuban/UI/mainwindow.py: Use True instead of true.
10811    
10812     * setup.py: Update some definitions to use wxWindows2.4 files
10813    
10814     * Data/iceland_sample_class.thuban: Fixed file so that the
10815     field_type information is present.
10816    
10817 jonathan 490 2003-03-10 Jonathan Coles <[email protected]>
10818    
10819 jonathan 505 * Thuban/UI/classifier.py (Classifier.__init__): Make the
10820     field type label grow so that when the text changes the
10821     size is updated correctly. This may be a wxWindows bug.
10822    
10823     2003-03-10 Jonathan Coles <[email protected]>
10824    
10825 jonathan 499 * Thuban/UI/application.py: Changed SESSION_CHANGED to
10826     SESSION_REPLACED.
10827    
10828     * Thuban/UI/classifier.py: Wrap text with _().
10829     (ClassGrid.CreateTable): Set dimensions and size hints here,
10830     instead of in Reset, so we only set the size once.
10831    
10832     * Thuban/UI/dialogs.py: Don't need Shutdown(); just use Close()!
10833    
10834     * Thuban/UI/mainwindow.py (MainWindow.prepare_new_session):
10835     Call Close() instead of Shutdown().
10836    
10837     * Thuban/UI/messages.py: Changed SESSION_CHANGED to SESSION_REPLACED.
10838    
10839     * Thuban/UI/tree.py: Changed SESSION_CHANGED to SESSION_REPLACED.
10840     Go back to using OnClose() instead of Shutdown().
10841    
10842     2003-03-10 Jonathan Coles <[email protected]>
10843    
10844 jonathan 497 * Thuban/UI/classifier.py (Classifier): SelectField() needed
10845     to know the old field index as well as the new one.
10846    
10847     2003-03-10 Jonathan Coles <[email protected]>
10848    
10849 jonathan 495 * Thuban/UI/classifier.py (Classifier): Use __SelectField()
10850     to correctly set the table information and call this from
10851     __init__ and from _OnFieldSelect so that all the information
10852     is up to date when the dialog opens and when a field is changed.
10853    
10854     2003-03-10 Jonathan Coles <[email protected]>
10855    
10856 jonathan 490 * Thuban/Model/classification.py (Classification): Don't use
10857     layer's message function directly, use the ClassChanged() method
10858     when then classification changes. SetField/SetFieldType/SetLayer
10859     must keep the information about field name and field type in
10860     sync when an owning layer is set or removed.
10861    
10862     * Thuban/Model/layer.py: Added ClassChanged() so that the
10863     classification can tell the layer when its data has changed.
10864     (Layer.SetClassification): Accepts None as an arguement to
10865     remove the current classification and correctly handles
10866     adding a new classification.
10867    
10868     * Thuban/Model/load.py: Comment out print statement
10869    
10870     * test/test_classification.py, test/test_save.py: New and
10871     improved tests.
10872    
10873 jonathan 483 2003-03-07 Jonathan Coles <[email protected]>
10874    
10875     * Thuban/Model/classification.py: Implemented __copy__ and
10876     __deepcopy__ for ClassGroup* and ClassGroupProperites so
10877     they can easily be copied by the classifier dialog.
10878     (ClassGroupProperites.__init__): The default line color should
10879     have been Color.Black.
10880    
10881     * Thuban/UI/classifier.py: Setting and Getting table values now
10882     uses a consistent set of functions.
10883     (Classifier): Now non-modal. Has field type label which changes
10884     as the field changes. Keep track of buttons in a list so that
10885     we can enable/disable the buttons when the None field is selected.
10886     (SelectPropertiesDialog): Add buttons to make the colors transparent.
10887    
10888     * Thuban/UI/dialogs.py (NonModalDialog.Shutdown): New method which
10889     does what OnClose did, but can be called by the application to
10890     close a window. Needed when a session changes, and we have to
10891     close the classifier windows.
10892    
10893     * Thuban/UI/mainwindow.py (MainWindow.prepare_new_session):
10894     Shuts down open dialogs. Used when a new session is created
10895     or a session is opened.
10896     (MainWindow.SaveSession): Should only call application.SaveSession()
10897     if we don't call SaveSessionAs first.
10898     (MainWindow.Classify): Allow different classifier dialogs for
10899     different layers.
10900    
10901     * Thuban/UI/tree.py (SessionTreeView): Remove OnClose and let
10902     the parent class handle it. Add Shutdown() to unsubscibe from
10903     event notification and call the parent Shutdown(). This was
10904     necessary so the application can close the tree window.
10905    
10906 jonathan 478 2003-03-06 Jonathan Coles <[email protected]>
10907    
10908     * Thuban/Model/classification.py: Minor documentation changes,
10909     Addition of __eq__ and __ne__ methods.
10910     (Classification.SetLayer): prevent recursion between this method
10911     and Layer.SetClassification().
10912    
10913     * Thuban/Model/color.py: Addition of __eq__ and __ne__ methods.
10914    
10915     * Thuban/Model/layer.py (SetClassification): prevent recursion
10916     between this method and Classification.SetLayer().
10917    
10918     * test/test_classification.py, test/test_load.py,
10919     test/test_session.py: Fixed and added tests for the classification
10920     classes.
10921    
10922 bh 477 2003-03-06 Bernhard Herzog <[email protected]>
10923    
10924     * Thuban/UI/classifier.py (ClassGrid.__init__)
10925     (ClassGrid.CreateTable): Move the SetSelectionMode call to
10926     CreateTable because otherwise it triggers an assertion in
10927     wxPython/wxGTK 2.4.
10928    
10929 jonathan 459 2003-03-05 Jonathan Coles <[email protected]>
10930    
10931 jonathan 475 * Thuban/common.py: Move FIELDTYPE constants back to table.py.
10932 jonathan 471
10933 jonathan 475 * Thuban/Model/load.py: import FIELDTYPE constants from table.
10934 jonathan 471
10935 jonathan 475 * Thuban/UI/classifier.py: import FIELDTYPE constants from table.
10936 jonathan 471
10937 jonathan 475 * Thuban/Model/table.py: Put FIELDTYPE constants back.
10938 jonathan 471
10939     2003-03-05 Jonathan Coles <[email protected]>
10940    
10941 jonathan 459 * Thuban/UI/classifier.py: Added class documentation.
10942     Fixed RTbug #1713, #1714. Added Move[Up|Down] buttons.
10943     Store just the groups in the table and generate the other
10944     column information when it is requested. Add "None" field
10945     to pull-down to select no classification.
10946    
10947     * Thuban/common.py: Moved FIELDTYPE constants from table.py
10948     (Str2Num): Only catch ValueError exceptions.
10949    
10950     * Thuban/Model/classification.py: Class documentation. Renaming
10951     of methods with Stroke to Line. Groups are stored in a single
10952     list with the default as the first element. Groups are searched
10953     in the order they appear in the list.
10954    
10955     * Thuban/Model/color.py: Documentation.
10956    
10957     * Thuban/Model/layer.py (Layer): Add GetFieldType to retreive
10958     the kind of data represented by a field.
10959    
10960     * Thuban/Model/load.py (ProcessSession): Use proper string
10961     conversion function; fixes RTbug #1713.
10962    
10963     * Thuban/Model/save.py (Saver): Store field type information.
10964    
10965     * Thuban/Model/table.py: Put FIELDTYPE constants in common.py.
10966     (Table): Add field_info_by_name() to retrieve field information
10967     by specifying the field name, not the number.
10968    
10969     * Thuban/UI/mainwindow.py: Function name changes.
10970    
10971     * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Only
10972     get the layer classification once. Don't try to classify
10973     values when the field is None: just use the default properties.
10974    
10975     * Thuban/UI/view.py: Function name changes.
10976    
10977     * Doc/thuban.dtd: Add field_type attribute to a classification.
10978    
10979 bh 456 2003-03-04 Bernhard Herzog <[email protected]>
10980    
10981 bh 458 * Doc/thuban.dtd: Use correct syntax for optional attributes. Make
10982     the fill and stroke layer attributes optional with suitable
10983     default values. Add the stroke_width layer attribute. Use correct
10984     syntax for empty elements. Make the attribute list for labels
10985     refer to the label element.
10986    
10987     2003-03-04 Bernhard Herzog <[email protected]>
10988    
10989 bh 456 * setup.py (thuban_build_py.build): Add a comment about distutils in
10990     Python 2.3 containing some of the functionality we implement in
10991     setup.py ourselves.
10992    
10993     * Thuban/UI/classifier.py (ClassGrid.__init__): Set the table
10994     before the selection mode. Doing it the other way round triggers
10995     an assertion in wxWindows.
10996    
10997     * Thuban/Model/save.py (escape): Fix typo in doc-string
10998    
10999     * Thuban/Model/classification.py: Remove unnecessary wxPython
11000     import
11001    
11002 jonathan 448 2003-03-04 Jonathan Coles <[email protected]>
11003    
11004     * Thuban/Model/classification.py (ClassGroupRange.GetProperties):
11005     Parameter 'value' should default to None.
11006    
11007     * Thuban/UI/mainwindow.py: Use Layer.GetClassification() since
11008     the class attribute __classification is now private.
11009    
11010     * Thuban/UI/classifier.py (ClassGrid): Moved OnCellDClick() from
11011     Classifier to ClassGrid. Added support for removing selected rows,
11012     which including code for keeping track of when cells are selected,
11013     and deselected.
11014     (ClassTable): Support for added/removing rows. Fixed a problem
11015     with __ParseInput whereby it would not allow strings (only numbers)
11016     to be entered.
11017     (Classifier): Added button and supporting code for removing
11018     selected rows.
11019    
11020 jonathan 445 2003-02-27 Jonathan Coles <[email protected]>
11021 jonathan 434
11022     * Thuban/common.py: Moved color conversion functions into
11023     Thuban/UI/common.py.
11024     (Str2Num): Now converts the float (not the string) to a long/int
11025     so that an exception isn't thrown.
11026    
11027     * Thuban/UI/common.py: Common functions used in several UI modules
11028    
11029     * Thuban/Model/classification.py: Changed the class hierarchy
11030     so that a Classification consists of Groups which return
11031     Properties when a value matches a Group.
11032    
11033     * Thuban/Model/layer.py: Fixed name resolution problem.
11034    
11035     * Thuban/Model/load.py: Use new Classification and Group functions.
11036    
11037     * Thuban/Model/save.py (Saver.write_attribs): Fixes a test case
11038     failure.
11039     (Saver.write_classification): Use new Classification and Group
11040     functions.
11041    
11042     * Thuban/UI/classifier.py: Changes to use new Classification and Group
11043 jonathan 445 functions. Fix to create a tuple with a single value instead of
11044     simply returning the value.
11045 jonathan 434
11046     * Thuban/UI/renderer.py: Use new Classification and Group functions.
11047     Use common.py functions.
11048    
11049 jonathan 445 * Thuban/UI/tree.py: Use common.py functions.
11050 jonathan 447
11051     * test/test_classification.py: Use new Classification and Group
11052     classes.
11053 jonathan 434
11054 jonathan 426 2003-02-24 Jonathan Coles <[email protected]>
11055    
11056     * Thuban/common.py (Color2wxColour, wxColour2Color): Conversion
11057     functions from Thuban color objects to wxWindow colour objects.
11058    
11059     * Thuban/Model/classification.py (Classification): Renamed
11060     GetProperties() to GetClassData(). Used the new iterator
11061     in TreeInfo().
11062     (ClassIterator): Iterator implementation to iterate over the
11063     ClassData objects in a classification object.
11064    
11065     * Thuban/Model/save.py (Saver.write_classificaton): Uses
11066     the new iterator to save the classification information.
11067    
11068     * Thuban/UI/classifier.py (SelectPropertiesDialog): Support
11069     for changing the stroke and fill colors and previewing the
11070     changes.
11071    
11072     * Thuban/UI/mainwindow.py (MainWindow.OpenSession,
11073     MainWindow.SaveSessionAs): Text string changes so the dialogs
11074     have more meaningful titles.
11075    
11076     * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Change
11077     Classification method name from GetProperties to GetClassData.
11078    
11079     * Thuban/UI/view.py (MapCanvas.find_shape_at): Use method calls
11080     instead of accessing now non-existent class variables.
11081    
11082 bh 425 2003-02-24 Bernhard Herzog <[email protected]>
11083    
11084     * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Remove
11085     unneeded Shape() call. Rendering is substantially faster without
11086     it and it avoids some problems with broken shape files.
11087    
11088 frank 423 2003-02-20 Frank Koormann <[email protected]>
11089    
11090     Force minimal size of identify and label dialogs. The autosizing
11091     looked too ugly.
11092    
11093     * Thuban/UI/controls.py (RecordListCtrl): Set minimal width for columns.
11094     * Thuban/UI/labeldialog.py (LabelDialog.dialog_layout):
11095     Set size of listctrl.
11096     * Thuban/UI/identifyview.py (IdentifyView.__init__):
11097     Set size of dialog.
11098    
11099 jonathan 408 2003-02-19 Jonathan Coles <[email protected]>
11100    
11101     * test/test_classification.py, test/test_layer.py,
11102     test/test_load.py, test/test_map.py, test/test_session.py:
11103     Updated the tests to use the new functions that are in the
11104     respective classes.
11105    
11106     * Thuban/Model/classification.py (Classification):
11107     Uses the new ClassData* classes. Modification messages are
11108     passed up to the parent layer (if it exists).
11109     (ClassData): New class to encapsulate the common data in each
11110     classification property.
11111     (ClassDataDefault): Represents the Default class. data.
11112     (ClassDataPoint): Represents a single class. data point
11113     (ClassDataRange): Represents a class. range
11114     (ClassDataMap): Represents a class. map (unused).
11115    
11116     * Thuban/Model/color.py: Added Color.None to represent something
11117     with no color. Color.Black represents the color black.
11118     (NoColor): Helper class derived from Color to represent something
11119     with no color.
11120    
11121     * Thuban/Model/layer.py (Layer): Removed references to fill, stroke,
11122     stroke_width attributes. Made the 'classification' attribute private.
11123     New methods for setting/getting the classification.
11124    
11125     * Thuban/Model/load.py (ProcessSession): Use new methods on Layer
11126     to get the classifcation and use the new ClassData* classes to
11127     hold the classification data. Use Str2Num to convert numbers
11128     properly.
11129    
11130     * Thuban/Model/save.py (Saver): Use new Color and Classification
11131     methods
11132    
11133     * Thuban/UI/classifier.py (ClassGrid): New class to represent a
11134     custom grid.
11135     (ClassTable): Support for editing Values and Labels and for
11136     changing what type (point or range) of data is stored in each
11137     property based on how the user enters the data.
11138     (Classifier): Support for saving the new classifications and
11139     launching the dialog to edit a property.
11140     (SelectPropertiesDialog): New class for editing the visual
11141     properties of a classification (stroke color, width, and fill color)
11142     (ClassPreviewer): Took the Draw method from ClassRenderer and
11143     made most of it into this new class. Intend to use this class in
11144     the SelectPropertiesDialog for previewing changes.
11145    
11146     * Thuban/UI/renderer.py: Use new Color and Classification methods.
11147    
11148     * Thuban/UI/tree.py: Formatting changes.
11149    
11150     * Doc/thuban.dtd: Add 'label' element
11151    
11152     * Thuban/common.py: New. Contains common routines used throughout
11153     the code.
11154     (Str2Num): Takes a string and converts it to the "best" type of
11155     number.
11156    
11157 bh 405 2003-02-14 Bernhard Herzog <[email protected]>
11158    
11159     * Thuban/UI/view.py (MapCanvas.OnLeftUp): Make sure that the
11160     dragging flag is always set to 0 even when the tool implementation
11161     raises an exception
11162    
11163 bh 402 2003-02-11 Bernhard Herzog <[email protected]>
11164    
11165     * Thuban/UI/application.py (ThubanApplication.splash_screen): New
11166     method to create a splash screen.
11167     (ThubanApplication.ShowMainWindow): New. Show the main window.
11168     Needed so the splash screen can display the mainwindow
11169     (ThubanApplication.OnInit): Call the
11170     new splash_screen method to determine whether the application
11171     should display a splash screen. If it displays a splash screen do
11172     not immediately show the main window.
11173    
11174 jonathan 399 2003-02-11 Jonathan Coles <[email protected]>
11175    
11176     * Thuban/Model/classification.py: Added import line to fix
11177     feature conflicts between running on python2.2 and python2.1.
11178    
11179     * Thuban/UI/classifier.py (ClassTable): Didn't need to hang
11180     onto the clinfo parameter, so removed the deepcopy().
11181    
11182 jonathan 396 2003-02-10 Jonathan Coles <[email protected]>
11183    
11184 tkoester 403 * Thuban/Model/save.py (Saver.open_element, Saver.close_element):
11185 jonathan 396 Added element_open variable to track opening and closing of tags
11186     so that tags that don't span more than one line are closed with
11187     /> instead of </tag_name>. Use the GetDefault*() methods of
11188     the Classification class.
11189    
11190     * Thuban/Model/classification.py (Classificaton): Added set and
11191     get methods for the default data. The class also takes a layer
11192     reference so that modification messages can be sent. Fixed the
11193     methods to use the new ClassData class.
11194     (ClassData): New class to encapsulate the classification data
11195    
11196     * Thuban/Model/layer.py (Layer): Remove the
11197 tkoester 403 Set[Fill|Stroke|StrokeWidth]() methods. Code should call the
11198 jonathan 396 SetDefault*() methods on the layer's classification object.
11199 tkoester 403 (Layer.__init__): Use the new SetDefault*() methods in the
11200 jonathan 396 Classification class.
11201    
11202     * Thuban/Model/load.py (ProcessSession): Use the new ClassData
11203     object instead of a dictionary.
11204    
11205 tkoester 403 * Thuban/UI/classifier.py (ClassRenderer): New class to
11206 jonathan 396 draw the classifications in the dialog box's table.
11207     (Classifier): Modified to use the ClassRenderer class.
11208    
11209 tkoester 403 * Thuban/UI/mainwindow.py (MainWindow): Use the SetDefault*()
11210     methods of the Classification class.
11211 jonathan 396
11212     * Thuban/UI/renderer.py (MapRenderer): Use the Get*() methods
11213     of the ClassData class.
11214    
11215     * test/test_classification.py, test/test_layer.py,
11216     test/test_map.py, test/test_session.py: Fix the tests to work
11217     with the above code changes.
11218    
11219 jonathan 387 2003-02-03 Jonathan Coles <[email protected]>
11220    
11221     * Thuban/Model/classification.py (Classification): Added getNull()
11222     to return the NullData reference
11223    
11224     * Thuban/Model/layer.py (Layer.SetFill, Layer.SetStroke,
11225     Layer.SetStrokeWidth): Modified these functions to change the
11226     null data in the classification rather than keep these values
11227     directly in the Layer class. Menu options to change these values
11228     work again.
11229    
11230 jonathan 380 2003-01-28 Jonathan Coles <[email protected]>
11231    
11232 jonathan 384 * Thuban/UI/classifier.py (Classifier): Resolved merging conflicts.
11233 tkoester 403 Fixed crashing problem on some systems. Dialog box shows
11234 jonathan 380 classification data.
11235    
11236 jonathan 384 * Thuban/UI/tree.py (SessionTreeCtrl.add_items): Handle drawing
11237     Colors in the tree view.
11238    
11239     * Thuban/Model/layer.py (Layer.TreeInfo): Added a call to build
11240     the tree info for classifications. Commented out unnecessary lines.
11241    
11242     * Thuban/Model/classification.py (Classification.TreeInfo): New
11243     function to add information about the classification into the
11244     tree view.
11245    
11246 tkoester 403 2003-01-27 Jan-Oliver Wagner <[email protected]>
11247 jan 375
11248 tkoester 403 * Thuban/__init__.py (_): New.
11249 jan 375
11250     * Thuban/Model/classification.py, Thuban/Model/extension.py,
11251     Thuban/Model/layer.py, Thuban/Model/load.py, Thuban/Model/map.py,
11252 tkoester 403 Thuban/Model/session.py, Thuban/UI/application.py,
11253     Thuban/UI/classifier.py, Thuban/UI/context.py, Thuban/UI/controls.py,
11254     Thuban/UI/identifyview.py, Thuban/UI/labeldialog.py,
11255     Thuban/UI/mainwindow.py, Thuban/UI/menu.py, Thuban/UI/proj4dialog.py,
11256     Thuban/UI/renderer.py, Thuban/UI/tree.py, Thuban/Lib/connector.py,
11257     Thuban/Lib/fileutil.py: Replace user string by _() for i18n.
11258 jan 375
11259 jonathan 370 2003-01-27 Jonathan Coles <[email protected]>
11260    
11261 tkoester 403 * Thuban/Model/layer.py: Classification initialization calls.
11262 jonathan 370
11263 tkoester 403 * Thuban/Model/classification.py: Created class to encapsulate
11264     a layer classification. Supports specific data points and
11265     ranges.
11266 jonathan 370
11267 tkoester 403 * Thuban/Model/load.py: Added support for loading classification
11268     information.
11269 jonathan 370
11270 tkoester 403 * Thuban/Model/save.py: Added support for saving classification
11271     information.
11272 jonathan 370
11273 tkoester 403 * Thuban/UI/classifier.py: Initial class for a dialog box for
11274     specifying classification information.
11275 jonathan 370
11276 tkoester 403 * Thuban/UI/mainwindows.py: Support for opening the classifier
11277     dialog.
11278 jonathan 370
11279 tkoester 403 * Thuban/UI/renderer.py: Support for drawing a layer with the
11280     classification information.
11281 jonathan 370
11282 tkoester 403 * Data/iceland_sample_class.thuban: iceland_sample with
11283     classification data.
11284 jonathan 370
11285 tkoester 403 * test/test_classification: Tests for the Classification class.
11286 jonathan 370
11287 bh 359 2002-12-09 Bernhard Herzog <[email protected]>
11288    
11289 bh 361 * test/test_command.py: New. Tests for the command classes.
11290    
11291 bh 359 * Thuban/UI/command.py (ToolCommand): New class for tool commands.
11292     (Command.IsTool): New method to distinguish between command
11293     switching tools and other commands.
11294    
11295     * Thuban/UI/view.py (MapCanvas.SelectTool): New method to select
11296     the tool to avoid direct assignments to instance variables
11297     (MapCanvas.ZoomInTool, MapCanvas.ZoomOutTool, MapCanvas.PanTool)
11298     (MapCanvas.IdentifyTool, MapCanvas.LabelTool): Use SelectTool to
11299     change the tool
11300    
11301     * Thuban/UI/mainwindow.py (MainWindow.update_command_ui): If an
11302     active tool's command turns insensitive, disable the tool.
11303     (_tool_command): Use the new ToolCommand class
11304    
11305     * Examples/simple_extensions/simple_tool.py (simple_tool): Use the
11306     SelectTool method to change the tool
11307     (iconfile): Use the ToolCommand class
11308    
11309 bh 354 2002-12-03 Bernhard Herzog <[email protected]>
11310    
11311     * Thuban/UI/tree.py (SessionTreeCtrl.normalize_selection): Handle
11312     the case of selected items that are not children of Layers or Maps
11313     properly. Previously this bug would trigger an assertion in
11314     wxWindows.
11315    
11316 frank 352 2002-11-06 Frank Koormann <[email protected]>
11317    
11318 bh 354 * Thuban/UI/mainwindow.py: Altered the order of tools in the
11319     toolbar: First now are all navigation tools (Zoom In/Out, Pan,
11320     Full Extent).
11321 tkoester 403
11322 bh 349 2002-10-23 Bernhard Herzog <[email protected]>
11323    
11324     * setup.py (setup call): version now 0.1.3
11325    
11326     * MANIFEST.in: Add the files in test/
11327    
11328     * test/README: Add note about tests requiring the iceland data
11329    
11330     * Thuban/UI/mainwindow.py (MainWindow.About): Add 2002 to
11331     copyright notice.
11332    
11333 bh 344 2002-10-18 Bernhard Herzog <[email protected]>
11334    
11335     * test/test_map.py
11336     (TestMapWithContents.test_projected_bounding_box): Use an explicit
11337     epsilon.
11338    
11339     * test/support.py (FloatComparisonMixin.assertFloatEqual)
11340     (FloatComparisonMixin.assertFloatSeqEqual): give a more useful
11341     message if the assertion fails and don't return the return value
11342     of self.assert_. In assertFloatSeqEqual the return meant that not
11343     all items of the sequence were compared.
11344    
11345 bh 326 2002-09-20 Bernhard Herzog <[email protected]>
11346    
11347 bh 341 * test/test_fileutil.py: New. Test cases for Thuban.Lib.fileutil
11348    
11349     * Thuban/Lib/fileutil.py: Fixup some whitespace and typos
11350    
11351 bh 338 * test/test_map.py (TestMapWithContents.test_tree_info): Create
11352     the string with the bounding box on the fly because of platform
11353     differences in the way %g is handled.
11354    
11355     * test/test_layer.py (TestLayer.test_empty_layer): Create an empty
11356     DBFfile too because Thuban layers can't yet cope missing DBF
11357     files.
11358    
11359     2002-09-20 Bernhard Herzog <[email protected]>
11360    
11361 bh 326 * test/test_menu.py: Use initthuban instead of
11362     add_thuban_dir_to_path to initialize Thuban.
11363    
11364     * test/support.py (FloatComparisonMixin.assertFloatEqual): New.
11365     Mixin class for float comparisons
11366     (SubscriberMixin): New. Mixin class to test messages sent through
11367     the Connector class
11368    
11369     * test/README: Fix a typo and add the -v flag to the command for
11370     individual tests
11371    
11372 bh 335 * test/test_session.py: New. Test cases for Thuban.Model.session
11373    
11374     * test/test_proj.py: New. Test cases for Thuban.Model.proj
11375    
11376     * test/test_map.py: New. Test cases for Thuban.Model.map
11377    
11378     * test/test_layer.py: New. Test cases for Thuban.Model.layer
11379    
11380     * test/test_label.py: New. Test cases for Thuban.Model.label
11381    
11382     * test/test_connector.py: New. Test cases for Thuban.Lib.connector
11383    
11384     * test/test_color.py: New. Test cases for Thuban.Model.color
11385    
11386     * test/test_base.py: New. Test cases for Thuban.Model.base
11387    
11388 bh 322 2002-09-13 Bernhard Herzog <[email protected]>
11389    
11390     * Thuban/Model/session.py (Session.forwarded_channels): Forward
11391     the CHANGED channel too.
11392    
11393     * Thuban/Model/map.py (Map.forwarded_channels): Forward the
11394     CHANGED channel too.
11395     (Map.__init__): Call the Modifiable constructor as well.
11396    
11397     * Thuban/Model/base.py (Modifiable.UnsetModified): Issue a CHANGED
11398     event if the modified flag changes.
11399     (Modifiable.changed): Tweak the doc-string.
11400    
11401     * Thuban/UI/mainwindow.py (MainWindow.view_position_changed)
11402     (MainWindow.set_position_text): Put the code that puts the text
11403     with the mouse position into the status bar into the new method
11404     set_position_text so that it can overwritten in derived classes.
11405    
11406 bh 317 2002-09-12 Bernhard Herzog <[email protected]>
11407    
11408     * Thuban/UI/mainwindow.py (MainWindow.RunMessageBox): Center the
11409     message box on the main window.
11410    
11411 bh 313 2002-09-11 Bernhard Herzog <[email protected]>
11412    
11413     * Thuban/UI/mainwindow.py: Underline the 'x' in "Exit" instead of
11414     the 'E' because it's less likely to interfere with other menu
11415     entries.
11416 bh 315 (MainWindow.build_menu): remove an incorrect comment.
11417 bh 313
11418 bh 311 2002-09-10 Bernhard Herzog <[email protected]>
11419    
11420     * Thuban/UI/mainwindow.py (MainWindow.Map): New.
11421     (_tool_command): Add sensitive parameter
11422     (_has_visible_map): Sensitivity callback to tools and other
11423     commands that require a visible map. Use it in map_zoom_in_tool,
11424     map_zoom_out_tool, map_pan_tool, map_identify_tool, map_label_tool
11425     and map_full_extent
11426    
11427 bh 308 2002-09-06 Bernhard Herzog <[email protected]>
11428    
11429     * Thuban/UI/mainwindow.py (MainWindow.OnClose): Unsubscribe
11430     VIEW_POSITION
11431    
11432 tkoester 403 2002-09-04 Frank Koormann <[email protected]>
11433 frank 306
11434     * Resources/Bitmaps/fullextent.xpm: Updated Icon (removed "potatoe")
11435    
11436 bh 302 2002-09-02 Bernhard Herzog <[email protected]>
11437    
11438 bh 304 * Thuban/UI/view.py: Get rid of the idle redraw. This is done by
11439     wxWindows already and our implementation doesn't work correctly
11440     with wxGTK 2.3:
11441     (MapCanvas.__init__): Remove the instance variable
11442     (MapCanvas.OnPaint): Always call do_redraw when there's a map to
11443     be drawin
11444     (MapCanvas.OnIdle): Removed.
11445    
11446 bh 302 * Thuban/UI/view.py (MapCanvas.unprojected_rect_around_point): Add
11447     a parameter to determine the size of the rectangle.
11448     (MapCanvas.find_shape_at): Create the box around the point on a
11449     layer by layer basis and make the size depend on the shape type.
11450     This solves a problem with the selection of point shapes at the
11451     border of the layer's bounding box
11452    
11453 bh 292 2002-08-30 Bernhard Herzog <[email protected]>
11454    
11455 bh 300 * Thuban/UI/mainwindow.py (MainWindow.CanRemoveLayer): New method
11456     for the sensitivity of remove layer.
11457     (_can_remove_layer): New. Sensitivity callback for remove layer
11458     (Command layer_remove): Use _can_remove_layer
11459    
11460     * Thuban/Model/map.py (Map.CanRemoveLayer): New method to
11461     determine whether a given layer can be deleted.
11462    
11463 bh 297 * Thuban/UI/view.py (MapCanvas.__init__, MapCanvas.OnPaint)
11464     (MapCanvas.do_redraw): Get rid of the unused update_region
11465     instance variable
11466    
11467 bh 294 * Thuban/UI/view.py: Add/update some doc-strings.
11468    
11469 bh 292 * test/: new subdirectory with a bunch of unit tests.
11470    
11471     * test/README, test/test_table.py, test/test_save.py,
11472     test/test_menu.py, test/test_load.py: Initial set of tests and
11473     brief instructions on how to run them
11474    
11475 bh 287 2002-08-29 Bernhard Herzog <[email protected]>
11476    
11477 bh 291 * Thuban/UI/renderer.py (ScreenRenderer.draw_shape_layer): Handle
11478     arcs with multiple parts.
11479    
11480 bh 289 * Thuban/UI/view.py (ZoomInTool.MouseUp, ZoomOutTool.MouseUp):
11481     Handle degenrate rectangles.
11482    
11483 bh 287 * Thuban/Model/table.py: Make writing records work correctly:
11484     (Table.__init__): Keep track of whether the DBF is open for
11485     writing
11486     (Table.write_record): Open the DBF file for writing when necessary
11487    
11488 bh 285 2002-08-27 Bernhard Herzog <[email protected]>
11489    
11490     * Thuban/Model/table.py (Table.write_record, Table.__init__): Open
11491     dbf files only for reading by default. Use a new writable dbf
11492     object for writing.
11493    
11494 bh 278 2002-08-26 Bernhard Herzog <[email protected]>
11495    
11496 bh 282 * Thuban/UI/mainwindow.py: Refactor the context creation:
11497     (MainWindow.Context): New method to return a context
11498     (MainWindow.invoke_command, MainWindow.update_command_ui): Use the
11499     new method
11500    
11501 bh 278 * Thuban/UI/tableview.py (TableGrid, LayerTableGrid): Split the
11502     layer table specific code from TableGrid into LayerTableGrid
11503     (TableFrame, LayerTableFrame): Split the layer table specific code
11504     from TableFrame into LayerTableFrame
11505 bh 280 (LayerTableGrid.select_shape): Remove a debug print
11506 bh 278
11507     * Thuban/UI/mainwindow.py (MainWindow.LayerShowTable): Use the
11508     LayerTableFrame
11509    
11510 bh 277 2002-08-23 Bernhard Herzog <[email protected]>
11511    
11512     * Thuban/Model/layer.py (Layer.__init__): Make sure we have an
11513     absolute filename.
11514    
11515 bh 269 2002-08-22 Bernhard Herzog <[email protected]>
11516    
11517 bh 275 * Thuban/Model/table.py (Table.write_record): New method to write
11518     records.
11519 tkoester 403 (Table.__init__): Open the DBF file for writing too.
11520 bh 275
11521     * Thuban/UI/controls.py (RecordTable.SetValue): Write the value
11522     into the underlying table.
11523    
11524     * extensions/shapelib/shapefil.h (DBFCommit),
11525     extensions/shapelib/dbfopen.c (DBFCommit): New API function to
11526     commit any changes made to the DBF file.
11527    
11528 bh 271 * Thuban/UI/mainwindow.py (make_check_current_tool)
11529     (_tool_command): Put the code that generates the "checked"
11530     callback into a separate function so that we can reuse it
11531     elsewhere
11532    
11533 bh 269 * Thuban/Model/save.py (Saver): New class to handle serializing a
11534     session into an XML file. The main reason to introduce a class is
11535     that applications built on Thuban can derive from it so that they
11536     can save additional information in a session file.
11537     (save_session): Delegate almost all the work to the Saver class.
11538     Rename the filename argument to file because it may be a file like
11539     object now.
11540    
11541     * Thuban/Model/load.py: Get rid of the Python 1.5.2 compatibility
11542     code. Remove the little test code which would be executed when the
11543     module is run as a script which didn't work anymore since it can't
11544     import the other Thuban modules.
11545     (ProcessSession, load_session): Refactor the ProcessSession to
11546     have one method for each element start and end tag so that derived
11547     classes can easily override the processing of individual tags.
11548     Also, always parse with namespaces enabled because applications
11549     built on top of Thuban will likely use namespaces if they extend
11550     the session file format.
11551    
11552 bh 266 2002-08-21 Bernhard Herzog <[email protected]>
11553    
11554     * setup.py (ThubanInstall.run): Don't repr install_lib_orig
11555     because thubaninit_contents will do it for us.
11556    
11557 tkoester 403 2002-08-16 Jan-Oliver Wagner <[email protected]>
11558 jan 265
11559     * Thuban/UI/mainwindow.py: menu item 'show session tree' now disable if
11560     tree window already open
11561    
11562 bh 259 2002-08-15 Bernhard Herzog <[email protected]>
11563    
11564 bh 263 * Thuban/Model/layer.py (Layer.Destroy): Call the unboundd method
11565     with self.
11566    
11567     * Thuban/UI/view.py (MapCanvas.OnLeftUp): Only release the mouse
11568     when we have actually captured it.
11569    
11570 bh 259 * Thuban/Model/layer.py (Layer.Destroy): New. Explicitly close the
11571     shapefile and destroy the table.
11572    
11573     * Thuban/Model/table.py (Table.Destroy): New. Close the DBF file.
11574    
11575 bh 254 2002-08-14 Bernhard Herzog <[email protected]>
11576    
11577 bh 256 * Thuban/UI/controls.py (RecordTable.__init__): Remove the unused
11578     instance variable columns
11579     (RecordTable.GetTypeName): row and col may be negative in some
11580     cases.
11581    
11582 bh 254 * setup.py (InstallLocal.initialize_options)
11583     (InstallLocal.finalize_options, InstallLocal.user_options): New
11584     option create-init-file to build a thubaninit.py when running
11585     install_local
11586     (InstallLocal.run): Create the thubaninit.py module when requested
11587     (thubaninit_contents): Split the template into several parts and
11588     create a new function thubaninit_contents that creates the
11589     contents of a thubaninit module.
11590     (ThubanInstall.run): Use the new function to create the thubaninit
11591     module.
11592    
11593 bh 252 2002-07-30 Bernhard Herzog <[email protected]>
11594    
11595     * Thuban/UI/application.py (ThubanApplication.OnExit): Do some
11596     cleanup.
11597     (ThubanApplication.MainLoop): Extend to automatically call OnExit.
11598    
11599     * Thuban/Model/session.py (Session.Destroy): Don't bypass the
11600     direct base class' Destroy method.
11601    
11602     * Thuban/Model/map.py (Map.ClearLayers): New method to delete all
11603     layers.
11604     (Map.Destroy): Destroy the label_layer as well and call the
11605     inherited Desatroymethod first so that no more messages are
11606     issued.
11607     (Map.RaiseLayer, Map.LowerLayer): Only issue LAYERS_CHANGED
11608     message if the stacking order actually has changed. Add
11609     doc-strings.
11610     (Map.BoundingBox): Correct the doc-string.
11611     (Map.AddLayer, Map.RemoveLayer, Map.Layers, Map.HasLayers)
11612     (Map.ProjectedBoundingBox, Map.SetProjection): Add doc-strings.
11613    
11614     * Thuban/Model/label.py (LabelLayer.ClearLabels): New to delete
11615     all labels.
11616    
11617 bh 247 2002-07-29 Bernhard Herzog <[email protected]>
11618    
11619     * Thuban/Model/map.py (Map.subscribe_layer_channels)
11620     (Map.unsubscribe_layer_channels): Put the code that (un)subscribes
11621     to a layer's channels into separate methods.
11622     (Map.RemoveLayer, Map.AddLayer): Call the new methods
11623     (Map.Destroy): Unsubscribe from a layer's channels before
11624     destroying it.
11625    
11626     * Thuban/UI/view.py (MapCanvas.find_shape_at): Change the
11627     selected_layer parameter to searched_layer which is the layer to
11628     search in.
11629     (MapCanvas.SelectShapeAt): New parameter layer to restrict the
11630     search to that layer. Return the selected layer and shape.
11631    
11632     * Examples/simple_extensions/simple_tool.py (simple_tool): Fix a
11633     typo
11634    
11635 bh 238 2002-07-24 Bernhard Herzog <[email protected]>
11636    
11637 bh 243 * Thuban/UI/application.py (ThubanApplication.create_session):
11638     Extend the doc string.
11639     (ThubanApplication.subscribe_session)
11640     (ThubanApplication.unsubscribe_session): New methods to
11641     subscribe/unsubscribe to/from session channels.
11642     (ThubanApplication.SetSession): Call the new methods here.
11643     (ThubanApplication.maps_changed, ThubanApplication.set_map):
11644     Renamed set_map to maps_changed. Its now a subscriber for
11645     MAPS_CHANGED.
11646    
11647     * Thuban/UI/view.py (ZoomOutTool.MouseUp): Use the correct
11648     x-coordinate in case of simple clicks
11649    
11650     * Thuban/Model/base.py (Modifiable.changed): Apply the args tuple,
11651     don't pass it as a parameter
11652    
11653     * Thuban/Model/session.py (Session.RemoveMap): New
11654    
11655 bh 238 * Thuban/UI/mainwindow.py (MainWindow.__init__): Turn the initial
11656     window size into a parameter.
11657    
11658 bh 235 2002-07-23 Bernhard Herzog <[email protected]>
11659    
11660 bh 237 * Thuban/UI/menu.py (Menu.item_index): Also search for menus not
11661     just commands.
11662    
11663 bh 235 * Thuban/UI/mainwindow.py (MainWindow.__init__): Change the
11664     parameter list a bit to allow setting the window title and the
11665     initial message in the status bar. Update the callers.
11666    
11667     * Thuban/UI/application.py (ThubanApplication.OnInit)
11668     (ThubanApplication.CreateMainWindow): Put the mainwindow
11669     instantiation into a separate method so that it can be overridden
11670     by a subclass.
11671    
11672 bh 230 2002-07-19 Bernhard Herzog <[email protected]>
11673    
11674 bh 234 * Thuban/Model/session.py: Issue a CHANGED message every time
11675     another changed message is issued to make it easier to get
11676     notified of changes.
11677     (Session): Update the doc string
11678     (Session.forward): Issue changed-events as CHANGED as well.
11679     (Session.changed): Overwrite the inherited version to issue
11680     CHANGED events as well.
11681    
11682     * Thuban/UI/tree.py: We can now simply subscribe to the session's
11683     CHANGED channel to be informed of changes.
11684     (SessionTreeCtrl.session_channels): Not needed any longer.
11685 tkoester 403 (SessionTreeCtrl.unsubscribe_all, SessionTreeCtrl.session_changed):
11686 bh 234 Only have to (un)subscribe CHANGED
11687    
11688     * Thuban/Model/map.py (Map.TreeInfo): Deal better with empty maps.
11689    
11690 bh 230 * Thuban/UI/main.py, Thuban/UI/__init__.py: Move the work-around
11691     for the wxPython locale bug to __init__.py so that it's
11692     automatically executed by anybody using UI code from Thuban.
11693    
11694 bh 225 2002-07-18 Bernhard Herzog <[email protected]>
11695    
11696 bh 228 * Thuban/UI/main.py (main): app no longer needs to be global
11697    
11698     * Thuban/UI/mainwindow.py (MainWindow.__init__): Add application
11699     as parameter and store it in an instance variable
11700     (MainWindow.invoke_command, MainWindow.update_command_ui)
11701     (MainWindow.save_modified_session, MainWindow.NewSession)
11702     (MainWindow.OpenSession, MainWindow.SaveSession)
11703     (MainWindow.SaveSessionAs, MainWindow.ShowSessionTree): Use self's
11704     application object.
11705    
11706     * Thuban/UI/application.py (ThubanApplication.OnInit): Instantiate
11707     the main window with self.
11708    
11709 bh 225 * Thuban/UI/context.py: New module with the context class
11710    
11711     * Thuban/UI/command.py (Command): Update doc string.
11712    
11713     * Thuban/UI/mainwindow.py (MainWindow.invoke_command,
11714     MainWindow.update_command_ui): Pass an instance of the context
11715     class to the command's methods
11716     (check_current_tool, call_method): Handle the new context
11717     implementation
11718    
11719     * Examples/simple_extensions/simple_tool.py (simple_tool,
11720     check_simple_tool): Handle the new context implementation
11721    
11722     * Examples/simple_extensions/simple_command.py (simple_command):
11723     Handle the new context implementation. Update the comments about
11724     the context.
11725    
11726     * Thuban/UI/application.py (ThubanApplication.SetSession): Add
11727     doc-string
11728     (ThubanApplication.Session): New method to return the session
11729     object
11730    
11731     * Thuban/UI/tree.py (SessionTreeCtrl.update_tree): The
11732     interactor's selected_layer may not be a layer of the current
11733     session when the tree is updated while a new session is being set.
11734    
11735 bh 217 2002-07-17 Bernhard Herzog <[email protected]>
11736    
11737     * Thuban/UI/tree.py (color_string): Removed. No longer used.
11738     (SessionTreeCtrl.update_tree, SessionTreeCtrl.add_items): Split
11739     update_tree into update_tree and add_items. The tree now uses a
11740     more generic way to display the contents of the tree.
11741     (SessionTreeCtrl): Add a doc string explaining the TreeInfo method
11742    
11743     * Thuban/Model/layer.py (Layer.TreeInfo),
11744     Thuban/Model/extension.py (Extension.TreeInfo),
11745     Thuban/Model/map.py (Map.TreeInfo),
11746 tkoester 403 Thuban/Model/session.py (Session.TreeInfo):
11747 bh 217 Add TreeInfo methods to implement the new tree view update scheme
11748    
11749 bh 216 2002-07-16 Bernhard Herzog <[email protected]>
11750    
11751     * Thuban/UI/application.py: Don't use "import from" for the
11752     MainWindow. It can't always be resolved.
11753     (ThubanApplication.OnInit): change reference to MainWindow
11754     accordingly.
11755    
11756     * Thuban/UI/menu.py (Menu.SetItems): New method to replace a menu
11757     completely
11758    
11759 bh 213 2002-07-10 Bernhard Herzog <[email protected]>
11760    
11761     * setup.py (create_init_module): New configurable variable whose
11762     default depends on the platform we're running on.
11763     (ThubanInstall.initialize_options): Initialize
11764     self.create_init_module from the global create_init_module
11765     (ThubanInstall.user_options): indictate that the options
11766     create-init-module and init-module-dir have arguments.
11767    
11768     * setup.py: In the setup call change the version number to include
11769     cvs.
11770    
11771     * MANIFEST.in: Add the files in Examples
11772    
11773 bh 205 2002-07-09 Bernhard Herzog <[email protected]>
11774    
11775 bh 210 * setup.py: In the setup call, use the thuban homepage as the
11776     value of the url parameter.
11777    
11778 bh 208 * Examples: New subdirectory for examples.
11779    
11780     * Examples/simple_extensions/simple_tool.xpm,
11781     Examples/simple_extensions/simple_tool.py,
11782     Examples/simple_extensions/simple_command.py,
11783     Examples/simple_extensions/README: Simple examples showing how to
11784     add new commands and tools.
11785    
11786 bh 207 * setup.cfg (bdist_rpm): Add the default value for prefix and tell
11787     bdist_rpm that we also have an install script.
11788     (bdist_inno): Add 2002 to the copyright notice.
11789    
11790 bh 205 * setup.py: Create a file in python's site-packages directory to
11791     make installation of Thuban as a library easier.
11792     (ThubanInstall.user_options): Add two new options,
11793     create-init-module and init-module-dir
11794     (ThubanInstall.expand_with_pure_python_dirs): New method to expand
11795     filenames for installation in the default directories.
11796     (ThubanInstall.select_scheme, ThubanInstall.convert_paths): Extend
11797     the inherited methods to capture some filenames before they're
11798     transformed too much by distutils.
11799     (ThubanInstall.run): Create the init module if requested.
11800     (ThubanInstall.thuban_init_filename): New method to return the
11801     full name of the init module.
11802     (ThubanInstall.get_outputs): Append the filename of the init
11803     module.
11804    
11805 bh 202 2002-07-08 Bernhard Herzog <[email protected]>
11806    
11807 bh 205 * setup.py (thuban_bdist_rpm): Extend this version of bdist_rpm to
11808     handle the prefix properly which means that the default for the
11809     installation prefix should be /usr for RPMs and /usr/local when
11810     doing a normal source install.
11811     (bdist_rpm_install_script): Script to override the default install
11812     commands in the specfile generated by the bdist_rpm command.
11813     (thuban_bdist_rpm.user_options): Add a prefix option
11814     (thuban_bdist_rpm.initialize_options): Init the prefix option.
11815     Create the script files for the spec files as empty files here
11816     (thuban_bdist_rpm._make_spec_file): Override the inherited method
11817     to fill the script files with content.
11818    
11819 bh 202 * Thuban/Model/save.py (relative_filename): Wrapper around
11820     Thuban.Lib.fileutil.relative_filename that accepts an empty dir
11821     argument. save_session now automatically uses this version,
11822     solving a problem when saving to a relative filename.
11823    
11824     * setup.py: In the setup call, make sure that the library
11825     directories are under $prefix/lib not directly under $prefix.
11826    
11827 tkoester 403 2002-06-20 Jan-Oliver Wagner <[email protected]>
11828 jan 199
11829     * Thuban/Model/extension.py: new module to handle extension objects.
11830     * Thuban/Model/messages.py: new messages for extensions.
11831     * Thuban/Model/session.py (Session.Extensions, Session.HasExtensions,
11832     Session.AddExtension): new for handling extensions.
11833     Also some other minor changes to round up extension handling.
11834     * Thuban/UI/tree.py (SessionTreeCrtl:update_tree): Added visualization
11835     of Extension titles and title and names of its objects.
11836    
11837 bh 194 2002-05-29 Bernhard Herzog <[email protected]>
11838    
11839     * Thuban/UI/mainwindow.py (MainWindow.bind_command_events): Bind
11840 bh 202 the events for a command.
11841 bh 194 (MainWindow.add_toolbar_command, MainWindow.add_menu_command):
11842     Call bind_command_events to bind the events. add_toolbar_command
11843     can now bind events too so that it's possible to have commands
11844     that are only available through the toolbar.
11845     (MainWindow.init_ids): New instance variable events_bound to keep
11846     track of for which commands events have been bound.
11847    
11848 bh 190 2002-05-28 Bernhard Herzog <[email protected]>
11849    
11850     * Thuban/UI/menu.py: New module to build and manage menus.
11851    
11852     * Thuban/UI/mainwindow.py: Remove some unused imports.
11853     (MainWindow.__init__, main_menu): move the definition of the main
11854     menu from __init__ to the Menu instance main_menu.
11855     (MainWindow.build_menu_bar, MainWindow.build_menu): New methods to
11856     build the menu bar and sub-menus from a menu description.
11857    
11858     * Thuban/UI/application.py (ThubanApplication.OnInit): Read the
11859     startup file
11860     (ThubanApplication.read_startup_files): New method to run
11861     ~/.thuban/thubanstart.py
11862    
11863 bh 192 * Thuban/UI/mainwindow.py (MainWindow.__init__, main_toolbar):
11864     Move the toolbar definition to the Menu instance main_toolbar.
11865     (MainWindow.build_toolbar): New method to build the toolbar
11866     similar to the build_menu methods
11867    
11868 bh 184 2002-05-23 Bernhard Herzog <[email protected]>
11869    
11870 bh 186 * Thuban/UI/mainwindow.py (MainWindow.__init__): Fix spelling of
11871     layer_outline_color. Fix it in the definition of the command too.
11872    
11873 bh 184 * Thuban/UI/command.py (Command): Fix typo in doc string
11874    
11875 bh 182 2002-05-22 Bernhard Herzog <[email protected]>
11876    
11877     * Thuban/UI/mainwindow.py (MainWindow.RunMessageBox): Fix a typo
11878     in the docstring
11879    
11880 bh 175 2002-05-15 Bernhard Herzog <[email protected]>
11881    
11882 bh 180 * Thuban/Model/layer.py (Layer.open_shapefile): Set bbox to None
11883     when the shapefile is empty.
11884     (Layer.BoundingBox, Layer.LatLongBoundingBox): Both methods may
11885     now return None for empty shapefiles. Update doc-strings.
11886    
11887     * Thuban/Model/map.py (Map.BoundingBox): Add doc-string. Deal with
11888     the layer's bbox being None.
11889    
11890     * Thuban/UI/tree.py (SessionTreeCtrl.update_tree): Deal with the
11891     layer's bbox being None.
11892    
11893 bh 175 * Thuban/UI/view.py (MapCanvas.shape_selected): Only redraw when
11894     necessary.
11895     (MapCanvas.__init__): New instance variables, last_selected_layer
11896     and last_selected_shape to determine how the selection has
11897     changed.
11898    
11899     * Thuban/UI/tableview.py (TableGrid.__init__): Do not call
11900     AutoSizeColumns because it will cause a traversal of the entire
11901     table which for large .dbf files will take a very long time.
11902    
11903 bh 172 2002-05-14 Bernhard Herzog <[email protected]>
11904    
11905     * Thuban/Model/layer.py (Layer.open_shapefile): Choose a better
11906     maximum depth for the tree than shapelib does by default.
11907    
11908 bh 165 2002-05-10 Bernhard Herzog <[email protected]>
11909    
11910     * setup.py (py_modules): The shptree modules doesn't have a
11911     wrapper, so don't include it in the py_modules
11912    
11913 bh 163 2002-05-08 Bernhard Herzog <[email protected]>
11914    
11915     * extensions/shapelib/shptree.c (compare_ints): Make arguments
11916     const void * as in the qsort prototype
11917     (SHPTreeFindLikelyShapes): Remove some unused variables.
11918    
11919     * Thuban/UI/view.py (PanTool.MouseMove): Use the bitmap the view
11920     maintains to redraw the window during a drag.
11921     (MapCanvas.unprojected_rect_around_point): New method to determine
11922     a small region around a point for hit-testing.
11923     (MapCanvas.find_shape_at): Only test the shapes in a small region
11924     around the point.
11925    
11926     * setup.py: Increment the version to 0.1.2
11927    
11928     * Thuban/UI/tree.py (SessionTreeCtrl.unsubscribe_all): Remove a
11929     debug print and set session to None after unsubscribing
11930    
11931 bh 146 2002-05-07 Bernhard Herzog <[email protected]>
11932    
11933 bh 154 * Data/iceland_sample.session, Data/iceland_sample.thuban: Rename
11934     the file to have a .thuban extension.
11935    
11936 bh 152 * Thuban/UI/tree.py (session_channels): New class constant with
11937     all the session channels to subscribe to to update the tree
11938     (SessionTreeCtrl.session_changed): Remember the session so that we
11939     can unsubscribe properly. Use the new class constant to
11940     unsubscribe from the old session and subscribe to the new one.
11941     (SessionTreeCtrl.unsubscribe_all): New method to unsubscribe all
11942     subscriptions of the SessionTreeCtrl.
11943     (SessionTreeView.OnClose): Call the tree's unsubscribe_all method.
11944    
11945     * Thuban/UI/mainwindow.py (MainWindow.__init__): Add the "Show
11946     Session Tree" command to the file menu.
11947    
11948     * Thuban/UI/view.py (MapCanvas.do_redraw): Pass the entire bitmap
11949     as update_region to the renderer.
11950    
11951     * Thuban/UI/renderer.py
11952     (ScreenRenderer.layer_ids, ScreenRenderer.draw_shape_layer): The
11953     update box is now directly a tuple, not a wxRect anymore.
11954    
11955     * Thuban/Model/layer.py (Layer.ShapesInRegion): Remove some debug
11956     prints.
11957    
11958     2002-05-07 Bernhard Herzog <[email protected]>
11959    
11960 bh 146 * setup.py: Add the shptree extension module. See
11961     extensions/pyshapelib/ChangeLog for more details.
11962    
11963     * extensions/shapelib/shpopen.c, extensions/shapelib/shapefil.h,
11964     extensions/shapelib/dbfopen.c: Really update to the versions of
11965     shapelib 1.2.9. For some reason it wasn't really done on
11966     2002-04-11.
11967    
11968     * extensions/shapelib/shptree.c: Modified version of shptree.c of
11969     shapelib 1.2.9. The only real difference is the use of qsort
11970     instead of a bubble sort implementation
11971    
11972     * Thuban/Model/layer.py (Layer.__init__): New instance variable
11973     shapetree to hold the shapelib quadtree for the shapefile
11974     (Layer.open_shapefile): Create the quad tree.
11975     (Layer.ShapesInRegion): New method to return the ids of shapes in
11976     a given region using the quad tree.
11977    
11978     * extensions/thuban/wxproj.cpp (project_points): Fix some typos in
11979     comment
11980     (draw_polygon_shape): Accept both arcs and polygons.
11981     (initwxproj): Use the new PYSHAPELIB_IMPORT_API macro to import
11982     the api.
11983    
11984     * Thuban/UI/renderer.py (MapRenderer.layer_ids): New method to
11985     return the shape ids to be rendered in a given layer.
11986     (MapRenderer.draw_shape_layer): Call layer_ids to get the list of
11987     ids. Use draw_polygon_shape to draw arc shapes as well.
11988     (ScreenRenderer.RenderMap): New parameter for the rectangle that
11989     has to be updated
11990     (ScreenRenderer.layer_ids): Make use of the layer's quadtree by
11991     calling it's ShapesInRegion method.
11992    
11993     * Thuban/UI/view.py (MapCanvas.__init__): New instance variable
11994     update_region for the update region.
11995     (MapCanvas.OnPaint): Maintain the update region
11996     (MapCanvas.do_redraw): Pass the bounding box of the update_region
11997     to the renderer when drawing the bitmap. Reset the update_region.
11998    
11999 bh 129 2002-05-03 Bernhard Herzog <[email protected]>
12000    
12001 bh 131 * Thuban/UI/mainwindow.py (MainWindow.SaveSessionAs,
12002     MainWindow.OpenSession): Change the file extension of the session
12003     files to .thuban
12004    
12005 bh 129 * Thuban/Model/session.py (Session.AddMap, forwarded_channels):
12006     Move the map channels to be forwarded by the session into the
12007 bh 146 class constant with forwarded_channels. Also add
12008     LAYER_PROJECTION_CHANGED and LAYER_VISIBILITY_CHANGED to
12009     forwarded_channels
12010 bh 129
12011     * Thuban/Model/base.py (Modifiable.changed): Fix doc-string (a
12012     typo and some rewording).
12013    
12014 bh 126 2002-05-02 Bernhard Herzog <[email protected]>
12015    
12016     * Thuban/UI/view.py: Keep the temporary bitmap used during drawing
12017     around to speed up most redraws:
12018     (MapCanvas.__init__): New instance variable bitmap which holds the
12019     bitmap
12020     (MapCanvas.do_redraw): Redraw self.bitmap if necessary. Use
12021     self.bitmap to draw.
12022     (MapCanvas.full_redraw): New method to force a full redraw
12023     including the bitmap
12024     (MapCanvas.SetMap): Subscribe full_redraw instead of redraw to
12025     make sure the bitmap is redrawn.
12026     (MapCanvas.projection_changed, MapCanvas.set_view_transform,
12027     MapCanvas.shape_selected): Call full_redraw instead of readraw to
12028     make sure the bitmap is redrawn.
12029     (MapCanvas.OnSize): New method to handle size events so that the
12030     bitmap can be redrawn.
12031    
12032 bh 124 2002-04-29 Bernhard Herzog <[email protected]>
12033    
12034     * Thuban/UI/mainwindow.py (MainWindow.__init__): Subscribe to the
12035     canvas' VIEW_POSITION event
12036     (MainWindow.view_position_changed): Handler for VIEW_POSITION.
12037     Update the text in the status-bar accordingly.
12038    
12039     * Thuban/UI/view.py (MapCanvas): Derive from Publisher as well
12040     (MapCanvas.__del__): Implement because Publisher.__del__ has to be
12041     called.
12042     (MapCanvas.__init__): Bind EVT_LEAVE_WINDOW too. Initialize
12043     current_position
12044     (MapCanvas.set_current_position): New method to set
12045     current_position. Issue a VIEW_POSITION event
12046     (MapCanvas.CurrentPosition): New public method to return the value
12047     of current_position. Should be called when the VIEW_POSITION event
12048     is processed.
12049     (MapCanvas.OnLeftDown, MapCanvas.OnLeftUp, MapCanvas.OnMotion):
12050     Update the position.
12051     (MapCanvas.OnLeaveWindow): Set the position to None.
12052    
12053     * Thuban/UI/messages.py (VIEW_POSITION): New message for the
12054     position in the statusbar
12055    
12056 tkoester 403 2002-04-26 Frank Koormann <[email protected]>
12057 frank 120
12058     * Thuban/UI/mainwindow.py: AddLayer, Dialog title s/session/data
12059    
12060 tkoester 403 2002-04-24 Frank Koormann <[email protected]>
12061    
12062 frank 118 * Resources/Bitmaps/identify.xpm: shadow added
12063    
12064     * Resources/Bitmaps/fullextent.xpm: new
12065 jan 116
12066 tkoester 403 2002-04-22 Jan-Oliver Wagner <[email protected]>
12067 jan 116
12068 tkoester 403 * Thuban/UI/tree.py (update_tree): added test for None on map bounding
12069     box
12070 jan 114
12071 tkoester 403 2002-04-21 Jan-Oliver Wagner <[email protected]>
12072    
12073 jan 114 * Thuban/UI/proj4dialog.py (UTMProposeZoneDialog): new
12074    
12075     * Thuban/UI/tree.py (update_tree): added added map extent
12076    
12077     * Thuban/UI/mainwindow.py (_method_command): extended by parameter
12078 tkoester 403 icon; added map_full_extend as tool
12079 jan 114
12080 tkoester 403 2002-04-19 Jan-Oliver Wagner <[email protected]>
12081 jan 107
12082     * Thuban/UI/mainwindow.py (SaveSession): launch save as dialog for
12083     saving _new_ sessions
12084    
12085     * Thuban/Model/session.py (create_empty_session): new session
12086     don't have a filename (set to None)
12087    
12088     * Thuban/UI/tree.py (update_tree): added filename and modified flag
12089    
12090     * Thuban/Model/load.py (ProcessSession): convert projection
12091     parameters from unicode to regular string
12092    
12093     * Data/iceland_sample.session: Added UTM Zone 26 projection.
12094    
12095 bh 100 2002-04-11 Bernhard Herzog <[email protected]>
12096    
12097     * extensions/shapelib/shapefil.h, extensions/shapelib/shpopen.c,
12098     extensions/shapelib/dbfopen.c: Update to the versions of shapelib
12099     1.2.9
12100    
12101     * setup.py (Lib.wxproj extension): Don't link shpopen.c and put
12102     the pyshapelib directoy into the list of include dirs, so that
12103     pyshapelib_api.h can be found.
12104    
12105     * extensions/thuban/wxproj.cpp (pyshapelib_api): New variable that
12106     holds the pyshapelib C-API
12107     (draw_polygon_shape, point_in_polygon_shape, shape_centroid): Use
12108     pyshapelib_api to access the shapelib functions.
12109     (initwxproj): Import the c_api from the shapelib module and
12110     initialize pyshapelib_api.
12111    
12112 bh 89 2002-04-04 Bernhard Herzog <[email protected]>
12113    
12114 bh 91 * setup.py (thuban_bdist_rpm.initialize_options): Use
12115     initialize_options to create the scripts for the rpm.
12116    
12117 bh 89 * extensions/pyprojection/setup.py (PROJ4_PREFIX): Just use /
12118    
12119 bh 85 2002-04-03 Bernhard Herzog <[email protected]>
12120    
12121 bh 87 * setup.py: Increment version to 0.1.1
12122    
12123 bh 85 * Thuban/UI/mainwindow.py (MainWindow.__init__): Move the "Add
12124     Layer" and "Remove Layer" commands from the layer menu to the map
12125     menu
12126    
12127 bh 83 2002-02-15 Bernhard Herzog <[email protected]>
12128    
12129     * Thuban/Model/layer.py (Layer.Shape): list append only takes one
12130     argument (python <= 1.5.2 erroneously accepted multiuple
12131     arguments)
12132    
12133 bh 81 2002-02-04 Bernhard Herzog <[email protected]>
12134    
12135     * Thuban/UI/identifyview.py (IdentifyGridCtrl): New class to use a
12136     RecordGrid in the identifyview.
12137     (IdentifyView.__init__): Use IdentifyGridCtrl instead of
12138     IdentifyListCtrl. The grid allows editing of the values.
12139    
12140     * Thuban/UI/controls.py (RecordTable, RecordGridCtrl): New classes
12141     implementing a grid for a single row of a thuban table.
12142    
12143     * Thuban/UI/view.py (MapCanvas.SelectShapeAt): Search through all
12144     layers by default. Easier to use than the previous default of only
12145     searching through the select layer which meant that if no layer
12146     was selected, you couldn't select a shape.
12147    
12148     * Thuban/UI/tableview.py (TableGrid.__init__): Fix typo
12149    
12150     * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Honour the
12151     stroke_width attribute
12152    
12153     * Thuban/Model/save.py (save_session): Write the new stroke_width
12154     attribute
12155    
12156     * Thuban/Model/load.py (ProcessSession.startElement): Read the
12157     stroke_width attribute
12158    
12159     * Thuban/Model/layer.py (Layer.__init__): New parameter and
12160     instance variable stroke_width
12161     (Layer.SetStrokeWidth): Set the stroke_width.
12162    
12163 bh 72 2002-02-01 Bernhard Herzog <[email protected]>
12164    
12165     * extensions/thuban/wxproj.cpp (project_points): Fix two
12166     off-by-one errors in the last loop that joins the various parts
12167     together.
12168    
12169 bh 71 2002-01-14 Bernhard Herzog <[email protected]>
12170    
12171     * setup.py (data_dist.make_distribution): Fix some typos
12172    
12173 bh 70 2001-09-18 Bernhard Herzog <[email protected]>
12174    
12175     * README: Slight tweaking in preparation for the 0.1 release
12176    
12177     * setup.cfg: Add section for sdist to create both tgz and zip
12178     archives
12179    
12180     * setup.py: increase version number to 0.1
12181     (data_dist): New command class for data distribution
12182    
12183 bh 64 2001-09-14 Bernhard Herzog <[email protected]>
12184    
12185 bh 70 * Thuban/UI/identifyview.py (IdentifyListCtrl.selected_shape):
12186     Handle the case of no layer (i.e. layer is None) properly.
12187    
12188 tkoester 403 * Thuban/UI/proj4dialog.py (UTMDialog.__init__, Proj4Dialog.__init__):
12189 bh 70 Set the initial selection of the combo boxes to reflect the
12190     projection we're starting with in a way that works on windows,
12191     too.
12192    
12193 bh 64 * Thuban/Lib/connector.py (Connector.print_connections): Print the
12194     puiblisher's ids in hex to make it easier to compare them to the
12195     standard repr of python methods
12196    
12197     * Thuban/Model/map.py (Map.Destroy): Unsubscribe the label_layer
12198     messages
12199    
12200 bh 59 2001-09-13 Bernhard Herzog <[email protected]>
12201    
12202 bh 64 * Thuban/UI/tree.py (SessionTreeCtrl.OnSelChanged): Make sure to
12203     deselect the layer if no layer is selected
12204    
12205 bh 59 * Thuban/UI/view.py (MapCanvas.OnPaint): Only delay drawing to
12206     idle time when there actually is something to draw. If there's
12207     nothing to draw simply clear the window
12208     (MapCanvas.do_redraw): Call dc.EndDrawing and add some comments.
12209     (MapCanvas.SetMap): force a redraw in all cases because
12210     FitMapToWindow doesn't always do it.
12211     (MapCanvas.ZoomFactor): Add an optional parameter, center, to
12212     specify the point to move into the center of the window
12213     (ZoomOutTool.MouseUp, ZoomInTool.MouseUp): If the mouse wasn't
12214     dragged, zoon in/out by a factor of 2
12215 bh 64 (MapCanvas.find_shape_at): Iterate backwards (i.e. with decreasing
12216     index, i.e. reversed drawing order) so that objects appearing to
12217     be in from of others are selected first. This is probably mostly
12218     relevant for point shapes where the symbols used may overlap
12219 bh 59
12220     * Thuban/Model/session.py (create_empty_session): Unset the
12221     modified bit before returning it
12222    
12223     * Thuban/UI/mainwindow.py (MainWindow.NewSession): Use
12224     create_empty_session session to create the new, empty session.
12225    
12226     * Thuban/UI/mainwindow.py (MainWindow.__init__): Set the size of
12227     the tool bitmaps.
12228     (MainWindow.OnClose, MainWindow.save_modified_session): Separate
12229     the code that asks whether the session should be saved into the
12230     new method save_modified_session.
12231     (MainWindow.OpenSession, MainWindow.NewSession): Use the new
12232     method to save modified session here too.
12233    
12234 bh 55 2001-09-11 Bernhard Herzog <[email protected]>
12235    
12236     * setup.py (InnoIconItem): fix typo
12237    
12238     (thuban_bdist_inno.run):
12239     (bdist_inno.run): Move the decision not to create symlinks on
12240     non-nt platforms to thuban_bdist_inno and do it unconditinally
12241     since we never want to create the symlinks here
12242    
12243 bh 48 2001-09-10 Bernhard Herzog <[email protected]>
12244    
12245 bh 53 * Thuban/UI/mainwindow.py (MainWindow.IdentifyTool): Popup the
12246     identify view immediately
12247    
12248     * Thuban/UI/controls.py: New file with two classes RecordListCtrl
12249     and SelectableRecordListCtrl that implement the code shared by the
12250     identify view and the label dialog
12251    
12252     * Thuban/UI/identifyview.py (IdentifyListCtrl): Derive from the
12253     new class RecordListCtrl
12254    
12255     * Thuban/UI/labeldialog.py (LabelDialog.OnOK): Check whether the
12256     return value of GetValue is None instead of using it as a boolean
12257     directly so that Zero numbers are handled properly.
12258     (LabelListCtrl): Derive from the new class
12259     SelectableRecordListCtrl
12260    
12261 bh 48 * Thuban/UI/proj4dialog.py (Proj4Dialog.__init__):
12262     (Proj4Dialog.dialogLayout): Make the window resizable and set the
12263     size of the text control explicitly to make the sizers work on
12264     both Windows and X.
12265    
12266 bh 44 2001-09-07 Bernhard Herzog <[email protected]>
12267    
12268     * Thuban/UI/view.py (MapCanvas.find_shape_at):Add a new parameter
12269     that can limit the search to the currently selected layer.
12270     (MapCanvas.SelectShapeAt): Make sure that the currently selected
12271     layer stays selected even when no shape is found
12272 bh 46 (MapCanvas.FitRectToWindow): If the rect has zero with or zero
12273     height do nothing (avoids zero division errors)
12274 bh 44
12275 bh 32 2001-09-06 Bernhard Herzog <[email protected]>
12276    
12277 bh 42 * Thuban/UI/tree.py (SessionTreeCtrl, SessionTreeView.__init__):
12278     Correct the spelling of SessionTreeCtrl. dabbrev is too damn
12279     convenient :-)
12280     (SessionTreeCtrl.__init__, SessionTreeCtrl.update_tree): Introduce
12281     a new instvar layer_to_item to map layers to tree items
12282     (SessionTreeCtrl.layer_selected): Select the appropriate tree item
12283     to match the current selection in the interactor
12284    
12285 bh 40 * Thuban/UI/interactor.py (Interactor.SelectedLayer):
12286     (Interactor.HasSelectedLayer): New methods to query the current
12287     selection
12288    
12289     * Thuban/UI/mainwindow.py (MainWindow.current_layer):
12290     (MainWindow.has_selected_layer): Simply call the appropriate
12291     interactor method
12292    
12293     * Thuban/UI/mainwindow.py (MainWindow.__init__):
12294     (MainWindow.LayerShowTable):
12295     (MainWindow.identify_view_on_demand): Store the interactor in an
12296     instvar and use that reference instead of going through main.app
12297    
12298 tkoester 403 * Thuban/UI/mainwindow.py (MainWindow.ShowSessionTree):
12299     * Thuban/UI/application.py (ThubanApplication.OnInit):
12300 bh 40 * Thuban/UI/main.py (main): Create the session tree view in main
12301     with the new mainwindow method ShowSessionTree and not directly
12302     the application's OnInit method
12303    
12304     * Thuban/UI/tree.py (myTreeCtrlPanel):
12305     (SessioinTreeCtrl): Rename to SessioinTreeCtrl and turn it into a
12306     TreeCtrl isntead of a panel. This affects most method since we now
12307     refer to self instead of self.tree
12308     (SessionTreeView): New class implementing a non-modal dialog
12309     showing the session tree.
12310    
12311 bh 35 * Thuban/UI/mainwindow.py (MainWindow.LayerShowTable): Pass the
12312     layer to the tableview dialog.
12313    
12314     * Thuban/UI/tableview.py: Add some doc-strings
12315 tkoester 403 (TableGrid):
12316 bh 35 (TableGrid.OnRangeSelect):
12317     (TableGrid.OnSelectCell):
12318     (TableFrame.__init__):
12319     (TableFrame.row_selected):
12320     Selecting rows in the grid view now updates the selected shapes
12321     through the TableFrame. To achieve this we derive TableGrid from
12322     Publisher and introduce the message type ROW_SELECTED which the
12323     TableFrame subscribes to and which is issued by OnRangeSelect and
12324     OnSelectCell
12325    
12326     (DataTable.SelectRow): Removed because it's no longer needed in
12327     the row/shape selection scheme
12328    
12329 bh 32 * Thuban/UI/dialogs.py: New file implementing common classes for
12330     dialogs
12331    
12332     * Thuban/UI/tableview.py (TableGrid.__init__): Don't subscribe to
12333     the SELECTED_SHAPE message anymore. This is now handled by the
12334     parent.
12335     (TableGrid.select_shape): Only update the selection if the shape
12336     is not None.
12337     (TableFrame): Inherit from the new NonModalDialog class.
12338     (TableFrame.__init__, TableFrame.select_shape): Handle the
12339     SELECT_SHAPE message.
12340     (TableFrame.OnClose): Extend the inherited method to unsubscribe
12341     SELECT_SHAPE
12342    
12343     * Thuban/UI/mainwindow.py (MainWindow.init_dialogs):
12344     (MainWindow.add_dialog):
12345     (MainWindow.dialog_open):
12346     (MainWindow.remove_dialog):
12347     (MainWindow.get_open_dialog): New methods to maintain a dictionary
12348     of opened non-modal dialogs.
12349    
12350     (MainWindow.__init__): Initialize the new non-modal dictionary
12351     management code
12352     (MainWindow.LayerShowTable): maintain separate dialogs for each
12353     table using the non-modal dialog management code to only open a
12354     view once for each table.
12355    
12356     (MainWindow.IdentifyTool):
12357     (MainWindow.__init__):
12358     (MainWindow.identify_view_on_demand): Don't open the identify view
12359     in IdentifyTool anymore. This will be done automatically by the
12360     new method identify_view_on_demand which handles the
12361     SELECTED_SHAPE message so that the identify view will be opened on
12362     demand
12363    
12364     * Thuban/UI/identifyview.py (IdentifyListCtrl.__init__): Remove
12365     the interactor argument. The SELECTED_SHAPE message is now handled
12366     by the parent.
12367     (IdentifyView.__init__): Add the interactor argument so that we
12368     can handle the SELECTED_SHAPE message here
12369     (IdentifyView.selected_shape): New method to handle the
12370     SELECTED_SHAPE messages
12371    
12372     * Thuban/UI/identifyview.py (IdentifyView): Derive from the new
12373     NonModalDialog class
12374     (IdentifyView.OnClose): Extend the inherited version to
12375     unsubscribe SELECT_SHAPE
12376    
12377     * Thuban/Model/session.py (Session.UnsetModified): Remove debug prints
12378    
12379 bh 26 2001-09-05 Bernhard Herzog <[email protected]>
12380    
12381     * Thuban/UI/view.py (MapCanvas.__init__): New argument, interactor.
12382 tkoester 403
12383 bh 26 * Thuban/UI/mainwindow.py (MainWindow.__init__): New argument
12384     interactor to pass through to the MapCanvas
12385 tkoester 403
12386 bh 26 * Thuban/UI/application.py (ThubanApplication.OnInit): Use the new
12387     argument to the MainWindow constructor to get rid of the ugly hack
12388     that made main.app available early just so that the mapcanvas
12389     could access the interactor object.
12390    
12391 bh 19 2001-09-04 Bernhard Herzog <[email protected]>
12392    
12393 bh 22 * Thuban/UI/mainwindow.py (MainWindow.RunMessageBox): New method
12394     that runs a modal message box
12395     (MainWindow.OnClose): Use the new method
12396     (MainWindow.RemoveLayer): Just do nothing in case no layer is
12397     selected. The command should be grayed out anyway, so there's no
12398     need to pop up a message box.
12399     (MainWindow.AddLayer): Pop up a message box with an error message
12400     if the shape file can't be opened
12401    
12402     * Thuban/Model/layer.py (Layer.__init__): Open the shapefile
12403     immediately. This will cause an exception in case the file can't
12404     be opened and we can display an appropriate message.
12405    
12406 bh 19 * MANIFEST.in: Add extensions/pyprojection/LICENSE
12407    
12408     * setup.py (thuban_bdist_rpm): New class implementing a Thuban
12409     specific bdist_rpm command.
12410    
12411     * Thuban/UI/main.py: Catch ImportError exceptions when importing
12412     the locale module because it may not be available on some
12413     installations.
12414    
12415     * extensions/pyprojection/LICENSE: Copy of the license text in
12416     Projection.i. Having it in a separate file makes it easier to
12417     refer to license text in e.g. RPMs
12418    
12419 bh 18 2001-09-03 Bernhard Herzog <[email protected]>
12420    
12421 bh 19 * setup.py: use wx-config instead of wxgtk-config because it's
12422     more generic
12423    
12424     * setup.py (ThubanInstall.get_outputs): Add the symlink in
12425     <prefix>/bin to the outputs
12426     (ThubanInstall.link_file): New method to link files. We need this
12427     because the standard copy_files refuses to link non-existing
12428     files.
12429     (ThubanInstall.run): Remove the leading install root from the
12430     script filename if an install root was specified and use the new
12431     link_file method
12432 tkoester 403
12433 bh 18 * Thuban/UI/mainwindow.py (MainWindow.AddLayer): Fit the map to
12434     the window when the first layer is added to the map.
12435    
12436     * setup.py (ThubanInstall.run): Honor the build root (self.root)
12437     when linking thuban.py to <prefix>/bin
12438    
12439 bh 16 2001-08-31 Bernhard Herzog <[email protected]>
12440    
12441     * setup.py: In the setup call, the install parameters shouldn't
12442     have trailing slashes because distutils on non-posix platforms
12443     doesn't like that. The same applies to other directories like
12444     "Resources/Bitmaps"
12445    
12446     In the configuration section for nt, move the wxWindows directory
12447     optins into the part clearly marked as editable.
12448    
12449     (InstallLocal.initialize_options):
12450     (InstallLocal.user_options): remove the currently unused debug
12451     flag
12452     (thuban_build_py.find_all_modules): Add this method so that it
12453     works for our case of having packages and modules in one
12454     distribution as well.
12455     (ThubanInstall.initialize_options):
12456     (ThubanInstall.finalize_options):
12457     (ThubanInstall.user_options):
12458     (ThubanInstall.boolean_options): Add new options, do-symlink and
12459     extra files. Since these are the first ThubanInstall specific
12460     options, override user_options and boolean_options
12461     (ThubanInstall.run): Honor the new do-symlink and extra-files
12462     options.
12463     (ThubanInstall.get_outputs): Add to override the base-class's
12464     version and add the extra-files to the outputs
12465     (bdist_inno): New class for windows distributions with Inno Setup
12466     (InnoIconItem): Helper class for bdist_inno
12467     (thuban_bdist_inno): Thuban specific version of bdist_inno. Added
12468     this together with the appropriate parameters, to the setup call.
12469 tkoester 403
12470 bh 16 * setup.cfg (bdist_inno): added new section for the inno setup
12471     installer
12472    
12473     * Thuban/UI/tree.py (myTreeCtrlPanel.__init__): New inst var
12474     changing_selection to avoid recursive selection events when
12475     modifying the selection in response to a selection event.
12476     (myTreeCtrlPanel.normalize_selection): Set the new inst var when
12477     changing the tree's selection.
12478     (myTreeCtrlPanel.OnSelChanged): Only normalize the selection when
12479     we're not being called indirectly from normalize_selection.
12480    
12481     * Thuban/UI/mainwindow.py (MainWindow.update_command_ui): Call
12482     event.Check only if the command is actuall checkable.
12483     (MainWindow.__init__): Call the toolbar's Realize method to make
12484     sure that the items are actually shown
12485    
12486 bh 7 2001-08-28 Bernhard Herzog <[email protected]>
12487    
12488 bh 9 * setup.py: Fix some doc strings
12489    
12490 bh 7 * ChangeLog: started
12491    

Properties

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

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26