1 |
|
2003-06-23 Bernhard Herzog <[email protected]> |
2 |
|
|
3 |
|
Bug fix for RT #1961: |
4 |
|
|
5 |
|
* Thuban/Model/load.py (SessionLoader.start_derivedshapesource): |
6 |
|
Register DerivedShapestores with the session |
7 |
|
|
8 |
|
* Thuban/Model/session.py (Session.Tables): Make sure each table |
9 |
|
is only listed once. |
10 |
|
|
11 |
|
* test/test_load.py (TestJoinedTable.test): Add check_format call. |
12 |
|
Update file contents to match the one written out. |
13 |
|
|
14 |
|
2003-06-20 Bernhard Herzog <[email protected]> |
15 |
|
|
16 |
|
* test/xmlsupport.py (SaxEventLister.startElementNS) |
17 |
|
(SaxEventLister.endElementNS): Do not include the qname. Python |
18 |
|
2.2.1 and 2.2.2 and 2.2.3 differ in this regard. In 2.2.1 qname it |
19 |
|
is (presumably incorrectly) None, whereas it's a string with the |
20 |
|
element name in the later versions. |
21 |
|
|
22 |
|
* test/test_xmlsupport.py (TestEventList.test_even_list_simple) |
23 |
|
(TestEventList.test_even_list_namespace): Update tests to reflect |
24 |
|
the new behaviour |
25 |
|
(TestEventList.test_even_list_id_normalization): Fix doc-string |
26 |
|
|
27 |
|
2003-06-20 Jonathan Coles <[email protected]> |
28 |
|
|
29 |
|
* Thuban/Model/layer.py (BaseLayer.HasShapes): New. Overridden |
30 |
|
by deriving classes to determine if that layer supports shapes. |
31 |
|
(Layer): Override HasShapes and return true. |
32 |
|
|
33 |
|
* Thuban/UI/classgen.py: Use Thuban[Begin|End]BusyCursor() |
34 |
|
instead of a direct call to wx[Begin|End]CusyCursor(). |
35 |
|
(GenUniquePanel._OnRetrieve): Set busy cursor while retrieving |
36 |
|
table data. |
37 |
|
|
38 |
|
* Thuban/UI/common.py (ThubanBeginBusyCursor, ThubanEndBusyCursor): |
39 |
|
New. Wrappers around the wxWindows functions that allow us to |
40 |
|
make additional calls such as wxYield which gives the native |
41 |
|
system a chance to update the cursor correctly. |
42 |
|
|
43 |
|
* Thuban/UI/tableview.py: Use Thuban[Begin|End]BusyCursor() |
44 |
|
instead of a direct call to wx[Begin|End]CusyCursor(). |
45 |
|
|
46 |
|
* Thuban/UI/view.py: Use Thuban[Begin|End]BusyCursor() |
47 |
|
instead of a direct call to wx[Begin|End]CusyCursor(). |
48 |
|
(MapCanvas.find_shape_at): Check if the current search layer |
49 |
|
support shapes, otherwise go on to the next layer. |
50 |
|
|
51 |
|
* test/test_layer.py: Add tests in each type of layer for |
52 |
|
HasClassification() and HasShapes() |
53 |
|
|
54 |
|
2003-06-20 Jonathan Coles <[email protected]> |
55 |
|
|
56 |
|
* Thuban/UI/view.py (MapCanvas.OnPaint): Call wxYield after |
57 |
|
turning on the busy cursor to allow the system to change the |
58 |
|
cursor before we begin painting. This fixes a problem that |
59 |
|
was occuring only under GTK. Fixes RTbug #1840. |
60 |
|
|
61 |
|
2003-06-20 Bernhard Herzog <[email protected]> |
62 |
|
|
63 |
|
* Resources/XML/thuban-0.8.dtd: New DTD for the new file format |
64 |
|
version. |
65 |
|
|
66 |
|
* Thuban/Model/save.py (sort_data_stores): New. Make topological |
67 |
|
sort of the data sources so they can be written with sources that |
68 |
|
data sources that depend on other data sources come after the |
69 |
|
sources they depend on. |
70 |
|
(SessionSaver.__init__): Add idmap instance variable to map from |
71 |
|
objects to the ids used in the file. |
72 |
|
(SessionSaver.get_id, SessionSaver.define_id) |
73 |
|
(SessionSaver.has_id): New. Methods to manage the idmap |
74 |
|
(SessionSaver.write): Use thuban-0.8.dtd |
75 |
|
(SessionSaver.write_session): Add a namespace on the session and |
76 |
|
write out the data sources before the maps. |
77 |
|
(SessionSaver.write_data_containers): New. Write the data |
78 |
|
containers. |
79 |
|
(SessionSaver.write_layer): Layer elements now refer to a |
80 |
|
shapestore and don't contain filenames anymore. |
81 |
|
|
82 |
|
* Thuban/Model/load.py (LoadError): Exception class to raise when |
83 |
|
errors in the files are discovered |
84 |
|
(SessionLoader.__init__): Define dispatchers for elements with a |
85 |
|
thuban-0.8 namespace too. |
86 |
|
(SessionLoader.check_attrs): New helper method to check and |
87 |
|
convert attributes |
88 |
|
(AttrDesc): New. Helper class for SessionLoader.check_attrs |
89 |
|
(SessionLoader.start_fileshapesource) |
90 |
|
(SessionLoader.start_derivedshapesource) |
91 |
|
(SessionLoader.start_filetable, SessionLoader.start_jointable): |
92 |
|
Handlers for the new elements in the new fileformat |
93 |
|
(SessionLoader.start_layer): Handle the shapestore attribute in |
94 |
|
addition to filename. |
95 |
|
(SessionLoader.start_table, SessionLoader.end_table): Removed. |
96 |
|
They were never used in the old formats and aren't needed for the |
97 |
|
new. |
98 |
|
|
99 |
|
* Thuban/Model/session.py (Session.DataContainers): New method to |
100 |
|
return all "data containers", i.e. shapestores and tables |
101 |
|
|
102 |
|
* test/xmlsupport.py (SaxEventLister.__init__) |
103 |
|
(SaxEventLister.startElementNS, sax_eventlist): Add support to |
104 |
|
normalize IDs. |
105 |
|
|
106 |
|
* test/test_xmlsupport.py |
107 |
|
(TestEventList.test_even_list_id_normalization): New test case for |
108 |
|
id normalization |
109 |
|
|
110 |
|
* test/test_load.py (LoadSessionTest.check_format): Use ID |
111 |
|
normalization |
112 |
|
(LoadSessionTest.thubanids, LoadSessionTest.thubanidrefs): New |
113 |
|
class atrributes used for ID normalization |
114 |
|
(TestSingleLayer, TestLayerVisibility, TestLabels.test) |
115 |
|
(TestLayerProjection.test, TestRasterLayer.test): Adapt to new |
116 |
|
file format |
117 |
|
(TestJoinedTable): New test for loading sessions with joined |
118 |
|
tables. |
119 |
|
(TestLoadError): New. Test whether missing required attributes |
120 |
|
cause a LoadError. |
121 |
|
|
122 |
|
* test/test_save.py (SaveSessionTest.thubanids) |
123 |
|
(SaveSessionTest.thubanidrefs): New class attributes for ID |
124 |
|
normalization in .thuban files. |
125 |
|
(SaveSessionTest.compare_xml): Use id-normalization. |
126 |
|
(SaveSessionTest.testEmptySession) |
127 |
|
(SaveSessionTest.testLayerProjection) |
128 |
|
(SaveSessionTest.testRasterLayer) |
129 |
|
(SaveSessionTest.testClassifiedLayer): Adapt to new file format. |
130 |
|
(SaveSessionTest.testLayerProjection): The filename used was the |
131 |
|
same as for testSingleLayer. Use a different one. |
132 |
|
(SaveSessionTest.test_dbf_table) |
133 |
|
(SaveSessionTest.test_joined_table): New test cases for saving the |
134 |
|
new data sources structures. |
135 |
|
(TestStoreSort, MockDataStore): Classes to test the sorting of the |
136 |
|
data stores for writing. |
137 |
|
|
138 |
|
* test/runtests.py: Add CVS keywords |
139 |
|
|
140 |
|
2003-06-20 Jonathan Coles <[email protected]> |
141 |
|
|
142 |
|
* test/test_session.py |
143 |
|
(UnreferencedTablesTests.test_unreferenced_tables_with_joins): |
144 |
|
Use the cultural_landmark-point.dbf file for the store so that |
145 |
|
the table rows and shape count match. |
146 |
|
|
147 |
|
2003-06-20 Jonathan Coles <[email protected]> |
148 |
|
|
149 |
|
* Thuban/Model/data.py (DerivedShapeStore.__init__): Raise |
150 |
|
an exception if the number of shapes is different from the |
151 |
|
number of rows in the table. Address RTbug #1933. |
152 |
|
|
153 |
|
* test/test_layer.py (TestLayer.test_derived_store): Add |
154 |
|
a test for the new exception in DerivedShapeStore.__init__. |
155 |
|
|
156 |
|
* test/support.py (FloatTestCase): Removed since there is |
157 |
|
already FloatComparisonMixin. Fixes RTbug #1954. |
158 |
|
(FloatComparisonMixin.assertFloatEqual): Include test for |
159 |
|
infinity that was part of FloatTestCase. |
160 |
|
|
161 |
|
* test/test_range.py (RangeTest): Inherit from |
162 |
|
support.FloatComparisonMixin now that we don't have |
163 |
|
support.FloatTestCase. |
164 |
|
|
165 |
|
2003-06-20 Bernhard Herzog <[email protected]> |
166 |
|
|
167 |
|
* test/test_save.py (SaxEventLister, sax_eventlist): Removed. Use |
168 |
|
the implementation in xmlsupport instead. |
169 |
|
(SaveSessionTest.compare_xml): sax_eventlist is now in xmlsupport |
170 |
|
|
171 |
|
* test/test_proj.py: Import sax_eventlist from xmlsupport instead |
172 |
|
of test_save |
173 |
|
|
174 |
|
2003-06-20 Bernhard Herzog <[email protected]> |
175 |
|
|
176 |
|
* test/test_load.py (LoadSessionTest.check_format): New helper |
177 |
|
method to make sure the test files we load might have been written |
178 |
|
by the current thuban version. |
179 |
|
(ClassificationTest.TestLayers, TestSingleLayer.test) |
180 |
|
(TestLayerVisibility.test, TestClassification.test) |
181 |
|
(TestLabels.test, TestLayerProjection.test, TestRasterLayer.test): |
182 |
|
Add check_format() calls and fix the thuban data to match the data |
183 |
|
that would be written by saving the session loaded from it. |
184 |
|
|
185 |
|
* test/xmlsupport.py (SaxEventLister, sax_eventlist): Copies of |
186 |
|
the same class and function in test_save. |
187 |
|
|
188 |
|
* test/test_xmlsupport.py (TestEventList): New. test cases for |
189 |
|
sax_eventlist |
190 |
|
|
191 |
|
2003-06-20 Bernhard Herzog <[email protected]> |
192 |
|
|
193 |
|
* Resources/XML/thuban.dtd: Add comment about which versions of |
194 |
|
Thuban are covered by this DTD |
195 |
|
(map): Fix content model for layers and raster layers. There can |
196 |
|
be any number or layers and raster layers in any order. |
197 |
|
|
198 |
|
2003-06-20 Jonathan Coles <[email protected]> |
199 |
|
|
200 |
|
This is mainly about fixing RTbug #1949. |
201 |
|
|
202 |
|
* Thuban/Model/classification.py: Remove "from __future__" |
203 |
|
import statement since python 2.2 is the earliest supported |
204 |
|
version. |
205 |
|
|
206 |
|
* Thuban/Model/proj.py (Projection.GetProjectedUnits): New. |
207 |
|
Currently returns PROJ_UNITS_METERS or PROJ_UNITS_DEGREES |
208 |
|
depending on the units this projection *forwards* into. |
209 |
|
|
210 |
|
* Thuban/Model/save.py (SessionSaver.write_classification): |
211 |
|
Remove unnecessary use of lambdas and nested functions. |
212 |
|
|
213 |
|
* Thuban/UI/legend.py (ScaleBarBitmap.__SetScale): Do scale |
214 |
|
adjustment here if the map projection uses degrees. |
215 |
|
|
216 |
|
* Thuban/UI/scalebar.py (ScaleBar.DrawScaleBar): Remove |
217 |
|
scale adjust code since it is now done before calling |
218 |
|
this method. Don't do anything if the map projection |
219 |
|
is None. |
220 |
|
|
221 |
|
2003-06-19 Bernhard Herzog <[email protected]> |
222 |
|
|
223 |
|
Move version specific load tests to their own file. |
224 |
|
|
225 |
|
* test/test_load.py: Expand the doc-string to explain a bit how to |
226 |
|
handle file format changes. |
227 |
|
(TestClassification.test): Update the docstring as this test is |
228 |
|
not about Thuban 0.2 anymore. |
229 |
|
|
230 |
|
* test/test_load_0_2.py: New file with the load tests for thuban |
231 |
|
files created with Thuban 0.2 and earlier. |
232 |
|
|
233 |
|
2003-06-19 Bernhard Herzog <[email protected]> |
234 |
|
|
235 |
|
Add XML validation to some of the tests. Validation will only be |
236 |
|
done if pyRXP is installed (http://reportlab.com/xml/pyrxp.html). |
237 |
|
To make the DTD available to the test cases it's moved into |
238 |
|
Resources/XML |
239 |
|
|
240 |
|
* Resources/XML/thuban.dtd: New. This is now the real Thuban DTD |
241 |
|
for versions up to and including 0.2. Two slight changes: added an |
242 |
|
encoding specification and fixed the comment which refered to |
243 |
|
GRASS, not Thuban |
244 |
|
|
245 |
|
* test/xmlsupport.py: New support module for tests involving XML. |
246 |
|
Currently there's a mix-in class for XML validation. |
247 |
|
|
248 |
|
* test/test_xmlsupport.py: New. Tests for the xmlsupport module |
249 |
|
|
250 |
|
* test/test_save.py (SaveSessionTest): Derive from ValidationTest |
251 |
|
so that we can validate the |
252 |
|
(SaveSessionTest.testEmptySession) |
253 |
|
(SaveSessionTest.testSingleLayer) |
254 |
|
(SaveSessionTest.testSingleLayer) |
255 |
|
(SaveSessionTest.testLayerProjection) |
256 |
|
(SaveSessionTest.testRasterLayer) |
257 |
|
(SaveSessionTest.testClassifiedLayer): Validate the generated XML |
258 |
|
|
259 |
|
* test/runtests.py (main): Call print_additional_summary instead |
260 |
|
of print_garbage_information |
261 |
|
|
262 |
|
* test/support.py (resource_dir): New function to return the |
263 |
|
"Resource" subdirectory |
264 |
|
(print_additional_summary): New function to combine several |
265 |
|
summary functions |
266 |
|
(run_tests): Use print_additional_summary instead of calling |
267 |
|
print_garbage_information directly |
268 |
|
|
269 |
|
2003-06-19 Bernhard Herzog <[email protected]> |
270 |
|
|
271 |
|
* Doc/thuban.dtd (classification): Correct the content model of |
272 |
|
the classification element. |
273 |
|
(projection): Add the "name" attribute |
274 |
|
|
275 |
|
2003-06-19 Frank Koormann <[email protected]> |
276 |
|
|
277 |
|
MERGE from the greater-ms3 branch. |
278 |
|
|
279 |
|
* Thuban/UI/scalebar.py (ScaleBar.DrawScaleBar): Apply conversion to |
280 |
|
scale if projection is latlong to get better estimate. |
281 |
|
|
282 |
|
Fix problem of hidden properties dialog under windows after double |
283 |
|
click on layer tree: |
284 |
|
The tree control always gets an Expanded / Collapsed event after |
285 |
|
the ItemActivated on double click, which raises the main window again. We add a second ItemActivated event to the queue, which simply |
286 |
|
raises the already displayed window. |
287 |
|
|
288 |
|
* Thuban/UI/legend.py (LegendTree.__init__): Instance variable |
289 |
|
raiseProperties initialized to prevent endless loops |
290 |
|
(LegendTree._OnItemActivated): Depending on self.raiseProperties |
291 |
|
simply raise the properties or open the dialog and issue a second |
292 |
|
event. |
293 |
|
|
294 |
|
2003-06-18 Jonathan Coles <[email protected]> |
295 |
|
|
296 |
|
* setup.py: Fix a few problems that occured under Windows. |
297 |
|
|
298 |
|
2003-06-18 Jonathan Coles <[email protected]> |
299 |
|
|
300 |
|
When Thuban loaded the map was redrawn twice because the |
301 |
|
legend was being opened after the mainwindow was created |
302 |
|
and not during its creation. This meant the map was drawn |
303 |
|
initially and then had to be redrawn when the legend |
304 |
|
caused the display to change. Now the legend is opened |
305 |
|
in the mainwindow constructor which resolves this issue. |
306 |
|
|
307 |
|
Also, although we were checking for the existence of |
308 |
|
gdal and gdalwarp modules, the gdalwarp extension was |
309 |
|
still being compiled (which may fail if the system doesn't |
310 |
|
have gdal installed). the build_ext command to setup.py |
311 |
|
now accepts the flags --with-gdal and --without-gdal. |
312 |
|
If --without-gdal is specified setup.py will try to |
313 |
|
use the gdal parameters specified by gdal-config. Under |
314 |
|
windows, those parameters have to be set in setup.py |
315 |
|
as with proj4 an wxWindows. |
316 |
|
|
317 |
|
* setup.py: Use a list instead of seperate variables for |
318 |
|
extension parameters so we can create a generic function |
319 |
|
that runs an appropriate *-config script. |
320 |
|
(run_cs_script): Renamed from run_wx_script and modified |
321 |
|
to accept a second argument which is a list of lists to |
322 |
|
be filled in by the values returned from running the command. |
323 |
|
(thuban_build_ext): New. Extends the build_ext command and |
324 |
|
provides the options --with-gdal/--without-gdal which then |
325 |
|
optionally includes the gdalwarp extension. |
326 |
|
|
327 |
|
* Thuban/Model/resource.py: First check if we can import |
328 |
|
the gdalwarp Thuban extension before checking for gdal. |
329 |
|
Also added some comments. |
330 |
|
|
331 |
|
* Thuban/UI/legend.py (ScaleBarBitmap.__SetScale): Check if |
332 |
|
the map is None which may be the case if none has been loaded |
333 |
|
yet. |
334 |
|
|
335 |
|
* Thuban/UI/main.py (main): Remove call to ShowLegend. |
336 |
|
|
337 |
|
* Thuban/UI/mainwindow.py (MainWindow.__init__): Call ShowLegend(). |
338 |
|
|
339 |
|
* Thuban/UI/renderer.py: Check for gdal support before importing |
340 |
|
gdalwarp. |
341 |
|
(MapRenderer.render_map): Only try to optimize if we have gdal |
342 |
|
support otherwise nothing will get drawn. |
343 |
|
|
344 |
|
* Thuban/UI/view.py (MapCanvas.FitMapToWindow): This may be called |
345 |
|
during startup before a map has been created. Check if map is None |
346 |
|
before using it and do nothing if it is. |
347 |
|
|
348 |
|
2003-06-17 Jonathan Coles <[email protected]> |
349 |
|
|
350 |
|
Fix the problem with raster layers under Windows that caused |
351 |
|
Thuban to crash. The view should respond to layer projection |
352 |
|
changed events to update the display. Changes to a projection |
353 |
|
should not cause the map to be set to full extent. |
354 |
|
|
355 |
|
* Thuban/UI/view.py (MapCanvas.__init__): New instance variable |
356 |
|
current_map_proj to remember the current map projection so that |
357 |
|
when the projection changes we know what the previous projection |
358 |
|
was. |
359 |
|
(MapCanvas.SetMap): Unsubscribe and subscribe to |
360 |
|
LAYER_PROJECTION_CHANGED events. |
361 |
|
(MapCanvas.projection_changed): Split into two methods that respond |
362 |
|
to map and layer projection changes. |
363 |
|
(MapCanvas.map_projection_changed): New. Takes the current view and |
364 |
|
projects it using the new projection. This does not cause the |
365 |
|
map to be redrawn at full extent. |
366 |
|
(MapCanvas.layer_projection_changed): New. Cause a redraw which |
367 |
|
will draw each layer in its new projection. |
368 |
|
|
369 |
|
* extensions/thuban/bmpdataset.cpp (BMPDataset::Open): Call |
370 |
|
VSIFClose() not VSIFCloseL() to close the file. Fixes a crash |
371 |
|
under Windows. |
372 |
|
|
373 |
|
* extensions/thuban/gdalwarp.cpp (MFILENAME): Padding should be |
374 |
|
to twice sizeof(void*) because there are two digits for each |
375 |
|
hex byte. |
376 |
|
|
377 |
|
2003-06-16 Bernhard Herzog <[email protected]> |
378 |
|
|
379 |
|
Update to the layer interface: Direct access to the table, |
380 |
|
shapetable, shapefile and filename attributes is now actively |
381 |
|
deprecated by issuing deprecation warnings for all places where |
382 |
|
this happens. |
383 |
|
|
384 |
|
* Thuban/Model/layer.py (Layer.__getattr__): New. Implement access |
385 |
|
to the instance variables table, shapetable, shapefile and |
386 |
|
filename via __getattr__ so that we can issue a deprecation |
387 |
|
warning. |
388 |
|
(Layer.SetShapeStore): Don't set the deprecated instance variables |
389 |
|
any more |
390 |
|
(Layer.SetShapeStore): Don't use deprecated layer instance |
391 |
|
variables |
392 |
|
(Layer.Destroy): No need to explicitly remove the instance |
393 |
|
variables any more |
394 |
|
(Layer.GetFieldType, Layer.Shape): Don't use deprecated layer |
395 |
|
instance variables |
396 |
|
|
397 |
|
* Thuban/UI/classgen.py (ClassGenDialog.__init__) |
398 |
|
(GenUniformPanel._OnRetrieve, GenUniquePanel._OnRetrieve) |
399 |
|
(GenQuantilesPanel.GetList, GenQuantilesPanel.OnRetrieve): Don't |
400 |
|
use deprecated layer instance variables |
401 |
|
|
402 |
|
* Thuban/UI/classifier.py (Classifier.__init__): Don't use |
403 |
|
deprecated layer instance variables |
404 |
|
|
405 |
|
* Thuban/UI/identifyview.py (IdentifyListCtrl.selected_shape) |
406 |
|
(IdentifyGridCtrl.selected_shape): Don't set the deprecated layer |
407 |
|
instance variables |
408 |
|
|
409 |
|
* Thuban/UI/tableview.py (LayerTableGrid.select_shapes): Don't use |
410 |
|
deprecated layer instance variables |
411 |
|
|
412 |
|
* Thuban/UI/mainwindow.py (MainWindow.LayerShowTable): Don't use |
413 |
|
deprecated layer instance variables |
414 |
|
|
415 |
|
* Thuban/Model/save.py (SessionSaver.write_layer): Don't use |
416 |
|
deprecated layer instance variables |
417 |
|
|
418 |
|
* Thuban/UI/renderer.py (MapRenderer.draw_shape_layer) |
419 |
|
(MapRenderer.polygon_render_param): Don't use deprecated layer instance |
420 |
|
variables |
421 |
|
|
422 |
|
* test/runtests.py (main): Turn Thuban's deprecation warnings into |
423 |
|
errors so that they're cought by the tests |
424 |
|
|
425 |
|
* test/test_load.py (TestSingleLayer.test): Don't use deprecated |
426 |
|
layer instance variables |
427 |
|
|
428 |
|
2003-06-16 Jonathan Coles <[email protected]> |
429 |
|
|
430 |
|
Fix a problem under Windows whereby if the user double-clicks on a |
431 |
|
layer in the legend that tree item will expand or collapse as well |
432 |
|
as open the layer properties dialog. The state of the tree item |
433 |
|
should not be affected. |
434 |
|
|
435 |
|
* Thuban/UI/legend.py (LegendTree.__init__): Add instance variable |
436 |
|
preventExpandCollapse and subscribe to expanding and collapsing |
437 |
|
events. |
438 |
|
(LegendTree.OnItemExpandCollapse): New. Responds to expanding and |
439 |
|
collapsing events and will veto the event if it has been triggered |
440 |
|
by the user double clicking on a layer. |
441 |
|
(LegendTree._OnItemActivated): Set preventExpandCollapse to indicate |
442 |
|
that an expanding/collapsing event should be vetoed. |
443 |
|
|
444 |
|
2003-06-13 Bernhard Herzog <[email protected]> |
445 |
|
|
446 |
|
* Thuban/UI/classifier.py (Classifier.OnClose) |
447 |
|
(Classifier.map_layers_removed) |
448 |
|
(Classifier.layer_shapestore_replaced): Unsubscribe the messages |
449 |
|
in OnClose and not in map_layers_removed or |
450 |
|
layer_shapestore_replaced to make sure it always happens when the |
451 |
|
dialog is closed |
452 |
|
|
453 |
|
2003-06-13 Jonathan Coles <[email protected]> |
454 |
|
|
455 |
|
This puts back a fix for Windows where a panel is needed so that |
456 |
|
the background of the table view appears correctly. |
457 |
|
|
458 |
|
* Thuban/UI/tableview.py (TableFrame.__init__): Add a panel |
459 |
|
object that can be used by derived classes to place any |
460 |
|
controls (including the grid) onto. |
461 |
|
(QueryTableFrame.__init__): Use the panel as the parent window |
462 |
|
for all the controls. Reparent the grid so that the panel is |
463 |
|
the parent. Call UpdateStatusText() to correctly initialize |
464 |
|
the status bar. |
465 |
|
|
466 |
|
2003-06-13 Jonathan Coles <[email protected]> |
467 |
|
|
468 |
|
* Thuban/UI/dialogs.py (ThubanFrame): New: a class that inherits |
469 |
|
from wxFrame (as opposed to wxDialog like the other classes) |
470 |
|
but otherwise behaves like the other classes. This is needed |
471 |
|
for the TableView which isn't really a dialog and needs to |
472 |
|
have a status bar and control buttons. |
473 |
|
|
474 |
|
* Thuban/UI/tableview.py (TableGrid.__init__): Create an |
475 |
|
instance variable to keep track of how many rows are selected. |
476 |
|
Subscribe once to the the events we are interested in. |
477 |
|
(ThubanGrid.OnRangeSelect): Only handle event if event handling |
478 |
|
hasn't been turned off. |
479 |
|
(ThubanGrid.OnSelectCell): Only handle event if event handling |
480 |
|
hasn't been turned off. |
481 |
|
(ThubanGrid.ToggleEventListeners): Rather than subscribe None |
482 |
|
as an event listener (which changes the event handler stack) |
483 |
|
simply set an instance variable to False. This is checked in |
484 |
|
the event handlers. |
485 |
|
(ThubanGrid.GetNumberSelected): Return the number of currently |
486 |
|
selected rows. |
487 |
|
(TableFrame): Inherit from ThubanFrame so we can have a |
488 |
|
status bar and control buttons. |
489 |
|
(QueryTableFrame.__init__): Create a status bar. Fixes RTbug #1942. |
490 |
|
Explicitly set which items are selected in the operator choice and |
491 |
|
action choice so there is always a valid selection. Fixes RTbug #1941. |
492 |
|
Subscribe to grid cell selection events so we can update the |
493 |
|
status bar. |
494 |
|
(QueryTableFrame.UpdateStatusText): Update the status bar with |
495 |
|
how many rows are in the grid, how many columns, and how many |
496 |
|
rows are selected. |
497 |
|
(QueryTableFrame.OnGridSelectRange, QueryTableFrame.OnGridSelectCell): |
498 |
|
Call UpdateStatusText when cells are (de)selected. |
499 |
|
(QueryTableFrame.OnQuery): Use the string value in the value |
500 |
|
combo if either the selected item index is 0 or if the string |
501 |
|
cannot be found in the predefined list (this happens if the |
502 |
|
user changes the text). Fixes RTbug #1940. |
503 |
|
Only turn off the grid event listeners if there a query comes |
504 |
|
back with a none empty list of ids. in the case that the list |
505 |
|
is empty this causes a grid.ClearSelection() call to actually |
506 |
|
clear the grid selection which causes the selected items in |
507 |
|
the map to be deselected. Fixes RTbug #1939. |
508 |
|
|
509 |
|
* test/test_save.py (XMLWriterTest.Encode): Check return values. |
510 |
|
Fixes RTbug #1851. |
511 |
|
|
512 |
|
2003-06-13 Bernhard Herzog <[email protected]> |
513 |
|
|
514 |
|
* Thuban/UI/identifyview.py (IdentifyView.__init__): Call |
515 |
|
self.selected_shape with the current selection to make sure the |
516 |
|
contents of the dialog are up to date when it's shown for the |
517 |
|
first time. |
518 |
|
The dialog used to work without this by luck. The recent fix to |
519 |
|
the connector module 'broke' a 'feature' the identify view was |
520 |
|
relying on, i.e that subscribing to a message in response to |
521 |
|
receiving a message of that type would mean that the new |
522 |
|
subscriber would also be called for the same message. |
523 |
|
|
524 |
|
2003-06-12 Jonathan Coles <[email protected]> |
525 |
|
|
526 |
|
* extensions/thuban/gdalwarp.cpp: Removed debug printing as |
527 |
|
the image is rendered. Fixes RTbug #1937. |
528 |
|
|
529 |
|
2003-06-12 Jonathan Coles <[email protected]> |
530 |
|
|
531 |
|
* Thuban/Lib/fileutil.py: As is done under Windows, create the |
532 |
|
user directory if it doesn't exist on a posix system. |
533 |
|
Fixes RTbug #1815. |
534 |
|
|
535 |
|
* Thuban/Model/resource.py (get_user_proj_files): Moved the |
536 |
|
called to get_application_dir here, so that the directory |
537 |
|
will only be called if this method is invoked. |
538 |
|
|
539 |
|
* Thuban/UI/projdialog.py (ProjFrame.__DoOnProjAvail): Clear |
540 |
|
the projfilepath if no projection is selected. |
541 |
|
|
542 |
|
2003-06-12 Jonathan Coles <[email protected]> |
543 |
|
|
544 |
|
* Thuban/UI/legend.py (ScaleBarBitmap.__SetScale): Don't draw |
545 |
|
the scalebar if the current map has no projection set. |
546 |
|
|
547 |
|
* Thuban/UI/projdialog.py (ProjFrame.__DoOnProjAvail): Set the |
548 |
|
projfilepath label to just the basename of the projection file |
549 |
|
rather than include the entire path. |
550 |
|
|
551 |
|
* Thuban/Model/resource.py: Fix missed proj functions that |
552 |
|
needed to be renamed. |
553 |
|
|
554 |
|
2003-06-12 Jonathan Coles <[email protected]> |
555 |
|
|
556 |
|
* Thuban/Model/classification.py: Removed assert statements that |
557 |
|
tested if the variable was an instance of Color. |
558 |
|
|
559 |
|
* Thuban/Model/color.py (Color): Remove commented code that isn't |
560 |
|
used. |
561 |
|
(Transparent): Renamed from NoColor. Doesn't inherit from Color. |
562 |
|
Fixes RTbug #1835. |
563 |
|
(Transparent.__eq__, Transparent.__ne, Transparent.__repr): New. |
564 |
|
Needed now that the class doesn't inherit from Color. |
565 |
|
|
566 |
|
2003-06-12 Jonathan Coles <[email protected]> |
567 |
|
|
568 |
|
* test/test_save.py (XMLWriterTest.testEncode): Explicitly |
569 |
|
check unicode strings. |
570 |
|
|
571 |
|
* test/test_layer.py: Check for existence of gdal. |
572 |
|
|
573 |
|
2003-06-12 Jonathan Coles <[email protected]> |
574 |
|
|
575 |
|
* Thuban/Model/xmlreader.py: New. Contains the XMLReader class |
576 |
|
that was in load.py |
577 |
|
|
578 |
|
* Thuban/Model/xmlwriter.py: New. Contains the XMLWriter class |
579 |
|
that was in save.py |
580 |
|
|
581 |
|
2003-06-12 Jonathan Coles <[email protected]> |
582 |
|
|
583 |
|
This is largely a collection of bug fixes. We also handle the |
584 |
|
case where gdal is not on the system. The XMLReader and XMLWriter |
585 |
|
classes were moved into there own files to resolve some circular |
586 |
|
import references and because they shouldn't really be in the |
587 |
|
file that is dediciated to reading/writing session files since |
588 |
|
they are also used elsewhere. |
589 |
|
|
590 |
|
* Thuban/Model/classgen.py: Renamed functions to follow the |
591 |
|
function_names_with_underscores style. Fixes RTbug #1903. |
592 |
|
(calculate_quantiles): Raise ValueError if 'percents' is invalid. |
593 |
|
|
594 |
|
* Thuban/Model/layer.py: Import gdal only if it available. |
595 |
|
(RasterLayer): Handle the case where the gdal library is unavailable. |
596 |
|
Addresses RTbug #1877. |
597 |
|
|
598 |
|
* Thuban/Model/load.py (XMLReader): Moved into seperate file |
599 |
|
xmlreader.py. |
600 |
|
|
601 |
|
2003-06-12 Jonathan Coles <[email protected]> |
602 |
|
|
603 |
|
This is largely a collection of bug fixes. We also handle the |
604 |
|
case where gdal is not on the system. The XMLReader and XMLWriter |
605 |
|
classes were moved into there own files to resolve some circular |
606 |
|
import references and because they shouldn't really be in the |
607 |
|
file that is dediciated to reading/writing session files since |
608 |
|
they are also used elsewhere. |
609 |
|
|
610 |
|
* Thuban/Model/classgen.py: Renamed functions to follow the |
611 |
|
function_names_with_underscores style. Fixes RTbug #1903. |
612 |
|
(calculate_quantiles): Raise ValueError if 'percents' is invalid. |
613 |
|
|
614 |
|
* Thuban/Model/layer.py: Import gdal only if it available. |
615 |
|
(RasterLayer): Handle the case where the gdal library is unavailable. |
616 |
|
Addresses RTbug #1877. |
617 |
|
|
618 |
|
* Thuban/Model/load.py (XMLReader): Moved into seperate file |
619 |
|
xmlreader.py. |
620 |
|
|
621 |
|
* Thuban/Model/save.py (escape, XMLWriter): Moved into seperate |
622 |
|
file xmlwriter.py. |
623 |
|
|
624 |
|
* Thuban/Model/resource.py: Renamed functions to following the |
625 |
|
function_names_with_underscores style. |
626 |
|
(has_gdal_support): New function that returns true if the gdal |
627 |
|
library is available. Addresses RTbug #1877. |
628 |
|
|
629 |
|
* Thuban/UI/application.py (ThubanApplication.OpenSession): |
630 |
|
Display a message box if the gdal library is not available, but |
631 |
|
only if there are any layers that would use it. Addresses RTbug #1877. |
632 |
|
|
633 |
|
* Thuban/UI/classgen.py: Use renamed projection resource functions. |
634 |
|
(GenUniformPanel.__CalcStepping): Fix a slight discrepency |
635 |
|
when using integers versus floats. |
636 |
|
|
637 |
|
* Thuban/UI/mainwindow.py (_has_gdal_support): New. Used to |
638 |
|
determine if the "Add Image Layer" menu option should be |
639 |
|
greyed out or not. Addresses RTbug #1877. |
640 |
|
|
641 |
|
* Thuban/UI/projdialog.py: Use renamed projection resource functions. |
642 |
|
|
643 |
|
* Thuban/UI/renderer.py (MapRenderer.render_map): Only try to |
644 |
|
optimize if a raster layer is visible. Fixes RTbug #1931. |
645 |
|
Only draw the raster layer if the gdal library is available. |
646 |
|
Addresses RTbug #1877. |
647 |
|
|
648 |
|
* test/test_classgen.py: Add tests for generate_singletons, |
649 |
|
generate_uniform_distribution, generate_quantiles. Fixes RTbug #1903. |
650 |
|
(test_calculate_quantiles): Fix some tests to catch the new |
651 |
|
ValueError that is raised. |
652 |
|
|
653 |
|
* test/test_proj.py: Use renamed projection resource functions. |
654 |
|
|
655 |
|
* test/test_save.py (SaveSessionTest.testClassifiedLayer): New |
656 |
|
test for saving classified layers. Fixes RTbug #1902. |
657 |
|
(XMLWriterTest): New. Tests the XMLWriter class. Fixes RTbug #1851. |
658 |
|
|
659 |
|
2003-06-12 Jan-Oliver Wagner <[email protected]> |
660 |
|
|
661 |
|
Fix for http://intevation.de/rt/webrt?serial_num=1900. |
662 |
|
|
663 |
|
* Thuban/UI/multiplechoicedialog.py: New. A multiple choice dialog. |
664 |
|
|
665 |
|
* Thuban/UI/mainwindow.py: import wxMultipleChoiceDialog from |
666 |
|
multiplechoicedialog.py rather than from the wxPython library. |
667 |
|
|
668 |
|
2003-06-11 Frank Koormann <[email protected]> |
669 |
|
|
670 |
|
* Thuban/Lib/fileutil.py (get_application_dir): Minor stability |
671 |
|
update. |
672 |
|
|
673 |
|
2003-06-11 Frank Koormann <[email protected]> |
674 |
|
|
675 |
|
* Thuban/Lib/fileutil.py (get_application_dir): New function to |
676 |
|
determine the absolute .thuban/thuban directory under |
677 |
|
"posix" (os.expanduser) and "nt" (read AppData registry key). |
678 |
|
|
679 |
|
* Thuban/Model/resource.py: Use get_application_dir |
680 |
|
|
681 |
|
* Thuban/UI/application.py (ThubanApplication.read_startup_files): |
682 |
|
Use get_application_dir. |
683 |
|
|
684 |
|
2003-06-10 Bernhard Herzog <[email protected]> |
685 |
|
|
686 |
|
* Thuban/UI/tableview.py (LayerTableFrame.__init__): Subscribe to |
687 |
|
the messages MAP_LAYERS_REMOVED messages |
688 |
|
(LayerTableFrame.OnClose): Unsubscribe from it. |
689 |
|
(LayerTableFrame.map_layers_removed): New. Receiver for |
690 |
|
MAP_LAYERS_REMOVED. Close the dialog when the layer whose the |
691 |
|
dialog is showing is removed. |
692 |
|
|
693 |
|
2003-06-10 Bernhard Herzog <[email protected]> |
694 |
|
|
695 |
|
* Thuban/Lib/connector.py (Connector.Issue): Iterate over a copy |
696 |
|
of the receivers list so that unsubscribing in a receiver doesn't |
697 |
|
modify it while iterating over it. |
698 |
|
|
699 |
|
* test/test_connector.py |
700 |
|
(ConnectorTest.test_disconnect_in_receiver): New. Test whether |
701 |
|
unsubscribing in a receiver works correctly. See docstring for |
702 |
|
details |
703 |
|
|
704 |
|
2003-06-10 Bernhard Herzog <[email protected]> |
705 |
|
|
706 |
|
* Thuban/Model/messages.py (LAYER_SHAPESTORE_REPLACED): New |
707 |
|
message. |
708 |
|
|
709 |
|
* Thuban/Model/layer.py (Layer.SetShapeStore): Send |
710 |
|
LAYER_SHAPESTORE_REPLACED when the shapestore changes. A |
711 |
|
LAYER_CHANGED will still be sent if the classification changes. |
712 |
|
|
713 |
|
* Thuban/UI/classifier.py (Classifier.__init__): Add the map as |
714 |
|
parameter so we can subscribe to some of its messages |
715 |
|
(Classifier.__init__): Subscribe to the map's MAP_LAYERS_REMOVED |
716 |
|
and the layer's LAYER_SHAPESTORE_REPLACED |
717 |
|
(Classifier.unsubscribe_messages): New. Unsubscribe from message |
718 |
|
subscribed to in __init__ |
719 |
|
(Classifier.map_layers_removed) |
720 |
|
(Classifier.layer_shapestore_replaced): receivers for the messages |
721 |
|
subscribed to in __init__. Unsubscribe and close the dialog |
722 |
|
|
723 |
|
* Thuban/UI/mainwindow.py (MainWindow.OpenLayerProperties): Pass |
724 |
|
the map to the Classifier dialog |
725 |
|
|
726 |
|
* test/test_layer.py (SetShapeStoreTests): Derive from |
727 |
|
SubscriberMixin as well so we can test messages |
728 |
|
(SetShapeStoreTests.setUp): Subscribe to some of the layer's |
729 |
|
messages |
730 |
|
(SetShapeStoreTests.tearDown): Clear the messages again |
731 |
|
(SetShapeStoreTests.test_sanity): Expand the doc-string and check |
732 |
|
for the modified flag too |
733 |
|
(SetShapeStoreTests.test_set_shape_store_modified_flag): New test |
734 |
|
to check whether SetShapeStore sets the modified flag |
735 |
|
(SetShapeStoreTests.test_set_shape_store_different_field_name) |
736 |
|
(SetShapeStoreTests.test_set_shape_store_same_field) |
737 |
|
(SetShapeStoreTests.test_set_shape_store_same_field_different_type): |
738 |
|
Add tests for the messages. This checks both the new |
739 |
|
LAYER_SHAPESTORE_REPLACED and the older LAYER_CHANGED |
740 |
|
|
741 |
|
2003-06-06 Jan-Oliver Wagner <[email protected]> |
742 |
|
|
743 |
|
* Thuban/UI/mainwindow.py: Improved and partly added help texts for |
744 |
|
the menu items. |
745 |
|
|
746 |
|
2003-06-05 Frank Koormann <[email protected]> |
747 |
|
|
748 |
|
* Thuban/UI/identifyview.py (IdentifyView.__init__): |
749 |
|
Layout reimplemented without panel. Make life easier to fit the list |
750 |
|
in the dialog. |
751 |
|
|
752 |
|
2003-06-05 Frank Koormann <[email protected]> |
753 |
|
|
754 |
|
* Thuban/UI/projdialog.py (ProjFrame.__init__): Fill the projchoice |
755 |
|
once on initialisation (Former implementation resulted in multiple |
756 |
|
entries for each projection). |
757 |
|
(ProjFrame.__FillAvailList): selectProj as second optional parameter, |
758 |
|
if set, select the projection found under the specified name. This |
759 |
|
overwrites any other selection estimate. |
760 |
|
Removed projchoice filling from this method. |
761 |
|
(ProjFrame._OnSave, ProjFrame._OnAddToList): |
762 |
|
Updated call of ProjFrame.__FillAvailList |
763 |
|
(LCCPanel._DoLayout): Moved parameter controls in more common order. |
764 |
|
|
765 |
|
* Resources/Projections/defaults.proj: Extended defaults representing |
766 |
|
various common European projections. |
767 |
|
|
768 |
|
2003-06-05 Frank Koormann <[email protected]> |
769 |
|
|
770 |
|
* Thuban/UI/identifyview.py (IdentifyView.__init__): |
771 |
|
Use ListCtrl instead of GridCtrl |
772 |
|
|
773 |
|
* Thuban/Model/resource.py: |
774 |
|
Guess location of .thuban directory from tempdir parent directory. |
775 |
|
|
776 |
|
* Thuban/UI/application.py (ThubanApplication.read_startup_files): |
777 |
|
Guess location of .thuban directory from tempdir parent directory. |
778 |
|
|
779 |
|
2003-06-04 Bernhard Herzog <[email protected]> |
780 |
|
|
781 |
|
Do not cache the values returned by the tree widget's |
782 |
|
GetFirstChild and GetNextChild methods because it led to lots of |
783 |
|
segfaults. The new way requires more brute force but is more |
784 |
|
reliable. |
785 |
|
|
786 |
|
* Thuban/UI/legend.py (LegendTree.__init__): Remove instance |
787 |
|
variable layer2id |
788 |
|
(LegendTree.find_layer): New method to do with brute force what |
789 |
|
layer2id tried to accomplish |
790 |
|
(LegendTree._OnMsgLayerChanged) |
791 |
|
(LegendTree._OnMsgLayerTitleChanged, LegendTree.__ShowHideLayer): |
792 |
|
Use find_layer instead of layer2id |
793 |
|
(LegendTree.__RemoveLayer, LegendTree.__AddLayer): No need to |
794 |
|
update layer2id anymore |
795 |
|
(LegendTree._OnMsgMapLayersRemoved) |
796 |
|
(LegendTree._OnMsgMapLayersAdded): Get by without layer2id. |
797 |
|
|
798 |
|
2003-06-03 Thomas Koester <[email protected]> |
799 |
|
|
800 |
|
* Thuban/Model/classgen.py (GenQuantiles0): New function. |
801 |
|
|
802 |
|
2003-06-02 Bernhard Herzog <[email protected]> |
803 |
|
|
804 |
|
* Thuban/UI/mainwindow.py (layer_rename command, table_rename command): |
805 |
|
New commands. |
806 |
|
(main_menu): Add the new commands. |
807 |
|
(MainWindow.TableRename): New. Implementation of the table_rename |
808 |
|
command. |
809 |
|
(MainWindow.RenameLayer): New. Implementation of the layer_rename |
810 |
|
command. |
811 |
|
|
812 |
|
* Thuban/Model/session.py (Session.AddTable): call self.changed to |
813 |
|
set the modified flag |
814 |
|
|
815 |
|
* test/test_session.py (TestSessionSimple.test_add_table): Test |
816 |
|
whether the modified flag is set properly |
817 |
|
|
818 |
|
* Thuban/Model/base.py (TitledObject.SetTitle): Call changed |
819 |
|
instead of issue so that the modified flags get updated. |
820 |
|
|
821 |
|
* test/test_base.py (SomeTitledObject): Derive from Modifiable |
822 |
|
instead of Publisher to reflect reality better and to accomodate |
823 |
|
the fact that SetTitle now calls changed instead of issue |
824 |
|
|
825 |
|
2003-06-02 Bernhard Herzog <[email protected]> |
826 |
|
|
827 |
|
* Thuban/UI/classgen.py (GenQuantilesPanel.GetList): Resource |
828 |
|
acquisition has to happen before the try in a try-finally. |
829 |
|
|
830 |
|
2003-06-02 Bernhard Herzog <[email protected]> |
831 |
|
|
832 |
|
* Thuban/UI/legend.py (LegendTree._OnMsgMapLayersRemoved): It's |
833 |
|
possible that a layer is removed that is not currently selected in |
834 |
|
the legend so don't check for this. |
835 |
|
|
836 |
|
2003-05-30 Bernhard Herzog <[email protected]> |
837 |
|
|
838 |
|
* Thuban/Model/layer.py (Layer.Destroy): Set all instance |
839 |
|
variables to None that have direct or indirect references to |
840 |
|
shapefiles or dbf files to make sure that they do go away and the |
841 |
|
files are closed. |
842 |
|
|
843 |
|
2003-05-30 Bernhard Herzog <[email protected]> |
844 |
|
|
845 |
|
* Thuban/UI/legend.py (LegendTree.GetRootItem): Reset |
846 |
|
availImgListIndices when a new image list is created |
847 |
|
|
848 |
|
2003-05-30 Bernhard Herzog <[email protected]> |
849 |
|
|
850 |
|
* Thuban/UI/legend.py (LegendTree.__init__): New instance variable |
851 |
|
changing_selection to indicate whether the LegendTree code itself |
852 |
|
is currently changing the selection |
853 |
|
(LegendTree.normalize_selection): New method to normalize the |
854 |
|
selection by selecting the layer item even if the user clicked on |
855 |
|
the classification. |
856 |
|
(LegendTree._OnSelChanged): normalize the selection. This works |
857 |
|
around a bug in wx which doesn't keep track of the selection |
858 |
|
properly when subtrees are deleted. |
859 |
|
|
860 |
|
2003-05-30 Bernhard Herzog <[email protected]> |
861 |
|
|
862 |
|
* Thuban/UI/view.py (MapCanvas.set_view_transform): Limit the |
863 |
|
maximum and minimum scale factors. |
864 |
|
|
865 |
|
* test/test_classgen.py (ClassGenTest.test): Update to reflect the |
866 |
|
changes in classgen.py |
867 |
|
|
868 |
|
2003-05-30 Jonathan Coles <[email protected]> |
869 |
|
|
870 |
|
* Thuban/Model/classgen.py: Remove ClassGenerator class but make |
871 |
|
all the methods functions. Fixes RTBug #1903. |
872 |
|
|
873 |
|
* Thuban/Model/map.py (Map.TopLayer, Map.BottomLayer): Renamed |
874 |
|
to MoveLayerToTop and MoveLayerToBottom respectively. Fixes |
875 |
|
RTBug #1907. |
876 |
|
|
877 |
|
* Thuban/UI/classgen.py: Use classgen functions that were part |
878 |
|
of the ClassGenerator class. Put try/finally blocks around |
879 |
|
code that uses wxBeginBusyCursor()/wxEndBusyCursor(). Fixes |
880 |
|
RTBug #1904. |
881 |
|
|
882 |
|
* Thuban/UI/classifier.py: Remove unused import of ClassGenerator. |
883 |
|
|
884 |
|
* Thuban/UI/legend.py: The legend was cleared and repopulated any |
885 |
|
time something changed which caused some state to be lost such |
886 |
|
as which children were expanded or collapsed. Fixes RTBug #1901. |
887 |
|
(LegendTree._OnMsgMapLayersAdded): Add only new layers. |
888 |
|
(LegendTree.__OnMsgMapLayersRemoved): Remove layers that exist in |
889 |
|
the legend but not in the map. |
890 |
|
(LegendTree.__FillTree): Move main functionality out into smaller |
891 |
|
methods that can be used by other methods. |
892 |
|
(LegendTree.__FillTreeLayer): Reuse old slots in the image list |
893 |
|
if they are available. |
894 |
|
(LegendTree.DeleteAllItems): Renamed from __DeleteAllItems so |
895 |
|
that we override the wxTreeCtrl method. Iterate over children |
896 |
|
and call __RemoveLayer. |
897 |
|
(LegendTree.__AddLayer): New. Add a new layer to the legend. |
898 |
|
(LegendTree.__RemoveLayer): Remove a layer from the legend. |
899 |
|
(LegendTree.DeleteChildren): New, overrides wxTreeCtrl method. |
900 |
|
Should only be called with the id of a layer branch. |
901 |
|
(LegendTree.GetRootItem): New, overrides wxTreeCtrl method. |
902 |
|
Returns the root item or creates one if necessary. |
903 |
|
|
904 |
|
* Thuban/UI/renderer.py (MapRenderer.draw_raster_layer): Call |
905 |
|
ProjectRasterFile with tuple arguments instead of strings. |
906 |
|
|
907 |
|
* Thuban/UI/tableview.py (QueryTableFrame.OnQuery): Wrap code |
908 |
|
with try/finally. Fixes RTBug #1904. |
909 |
|
|
910 |
|
* Thuban/UI/view.py (MapCanvas.OnPaint): Wrap code |
911 |
|
with try/finally. Fixes RTBug #1904. |
912 |
|
(MapCanvas.FitSelectedToWindow): If a single point is selected |
913 |
|
simply center it on the display. Fixes RTBug #1849. |
914 |
|
|
915 |
|
* extensions/thuban/gdalwarp.cpp: Removed code that allowed gdalwarp |
916 |
|
to be compiled as a standalone app. Now the code can only be |
917 |
|
called from Python which simplifies the parameter passing. |
918 |
|
(ProjectRasterFile): Handle Python arguments. Remove code that |
919 |
|
checks for a destination dataset. Add more clean up code. |
920 |
|
|
921 |
|
* test/test_map.py (TestMapWithContents.test_raise_layer_top, |
922 |
|
TestMapWithContents.test_lower_layer_bottom): |
923 |
|
Test Map.MoveLayerToTop() and Map.MoveLayerToBottom() respectively. |
924 |
|
Fixes RTBug #1907. |
925 |
|
|
926 |
|
* Thuban/UI/mainwindow.py (MainWindow.ToggleLegend): Apply a full |
927 |
|
extent to the map when the legend is toggled. Fixes RTBug #1881. |
928 |
|
|
929 |
|
2003-05-29 Jan-Oliver Wagner <[email protected]> |
930 |
|
|
931 |
|
* Thuban/UI/tableview.py (LayerTableFrame.OnClose): Bug-fix: Now |
932 |
|
unsubscribes all that is subcribed in __init__. |
933 |
|
|
934 |
|
2003-05-28 Bernhard Herzog <[email protected]> |
935 |
|
|
936 |
|
* Thuban/UI/mainwindow.py (MainWindow.DuplicateLayer) |
937 |
|
(MainWindow.CanDuplicateLayer): New methods to implement the |
938 |
|
Layer/Duplicate command. |
939 |
|
(layer_duplicate command): New. |
940 |
|
(main_menu): Add layer_duplicate to the Layer menu. |
941 |
|
|
942 |
|
2003-05-28 Bernhard Herzog <[email protected]> |
943 |
|
|
944 |
|
* Thuban/UI/tableview.py (NullRenderer.Draw): New. Our own |
945 |
|
renderer so that NULL/None values get displayed differently (by a |
946 |
|
gray rectangle). |
947 |
|
(TableGrid.__init__): Override the default renderers |
948 |
|
|
949 |
|
2003-05-28 Bernhard Herzog <[email protected]> |
950 |
|
|
951 |
|
* Thuban/Model/layer.py (Layer.SetShapeStore): Set the |
952 |
|
classification to "None" if the type of the field has changed. |
953 |
|
|
954 |
|
* test/test_layer.py (SetShapeStoreTests): New. Class with a few |
955 |
|
test for the Layer.SetShapeStore method |
956 |
|
|
957 |
|
2003-05-28 Jan-Oliver Wagner <[email protected]> |
958 |
|
|
959 |
|
* Thuban/Model/layer.py (Layer.TreeInfo): Fixed a bug (a layer |
960 |
|
does not necessarily have a filename). |
961 |
|
|
962 |
|
2003-05-28 Jan-Oliver Wagner <[email protected]> |
963 |
|
|
964 |
|
* Thuban/UI/mainwindow.py (MainWindow.TableClose, MainWindow.TableShow): |
965 |
|
sort the selection list for the dialog. |
966 |
|
|
967 |
|
2003-05-28 Frank Koormann <[email protected]> |
968 |
|
|
969 |
|
* extensions/thuban/wxproj.cpp |
970 |
|
(project_point): Removed cast to int for projected point coordinates. |
971 |
|
(shape_centroid): Return last point if all polygon vertices fall |
972 |
|
to one point. |
973 |
|
|
974 |
|
2003-05-28 Bernhard Herzog <[email protected]> |
975 |
|
|
976 |
|
* Thuban/UI/mainwindow.py (_can_unjoin): Add doc-string and cope |
977 |
|
with layers that don't have shapestores, i.e. raster layers. |
978 |
|
|
979 |
|
2003-05-28 Bernhard Herzog <[email protected]> |
980 |
|
|
981 |
|
* Thuban/Model/table.py (DBFTable.__init__): Omit the extension |
982 |
|
when determining the title from the filename. |
983 |
|
|
984 |
|
* test/test_dbf_table.py (TestDBFTable.test_title): Update to |
985 |
|
reflect changes in the way the title is derived from the filename |
986 |
|
|
987 |
|
2003-05-28 Frank Koormann <[email protected]> |
988 |
|
|
989 |
|
* Thuban/UI/mainwindow.py (MainWindow.TableShow): |
990 |
|
Added wxDEFAULT_DIALOG_STYLE to show table dialog styles. |
991 |
|
|
992 |
|
2003-05-27 Bernhard Herzog <[email protected]> |
993 |
|
|
994 |
|
* Thuban/UI/mainwindow.py (MainWindow.delegated_messages): Also |
995 |
|
delegate SelectedLayer. |
996 |
|
(MainWindow.LayerUnjoinTable): Implement. |
997 |
|
(_can_unjoin): New. Helper function for the sensitivity of the |
998 |
|
layer/unjoin command. |
999 |
|
|
1000 |
|
* Thuban/Model/data.py (ShapefileStore.OrigShapeStore) |
1001 |
|
(DerivedShapeStore.OrigShapeStore): New. Return the original |
1002 |
|
shapestore. Used to figure out how to unjoin. |
1003 |
|
(DerivedShapeStore.Shapefile): Fix a typo. |
1004 |
|
|
1005 |
|
2003-05-27 Bernhard Herzog <[email protected]> |
1006 |
|
|
1007 |
|
* Thuban/UI/join.py (JoinDialog): Extend to handle layer joins as |
1008 |
|
well |
1009 |
|
(JoinDialog.__init__): Use the layer parameter and only build the |
1010 |
|
left choice when a layer is given |
1011 |
|
(JoinDialog.OnJoin): Handle layer joins as well |
1012 |
|
(JoinDialog.OnLeftTable, JoinDialog.OnRightTable): Handle the case |
1013 |
|
that the user selects the "Select..." item. The sensitivitly |
1014 |
|
updating is now in update_sensitivity |
1015 |
|
(JoinDialog.y): New method to refactor the sensitivity update of |
1016 |
|
the join button into its own method. |
1017 |
|
|
1018 |
|
* Thuban/UI/mainwindow.py (MainWindow.LayerJoinTable): Implement. |
1019 |
|
|
1020 |
|
2003-05-27 Bernhard Herzog <[email protected]> |
1021 |
|
|
1022 |
|
* Thuban/UI/mainwindow.py (table_close command): Make it sensitive |
1023 |
|
iff there are unreferenced tables in the session |
1024 |
|
|
1025 |
|
2003-05-27 Bernhard Herzog <[email protected]> |
1026 |
|
|
1027 |
|
* Thuban/Model/messages.py (TABLE_REMOVED): New message. |
1028 |
|
|
1029 |
|
* Thuban/Model/session.py (Session.UnreferencedTables): New method |
1030 |
|
to return tables that are not referenced by other tables or shape |
1031 |
|
stores and can be removed. |
1032 |
|
(Session.RemoveTable): Issue a TABLE_REMOVED message after |
1033 |
|
removing the table |
1034 |
|
|
1035 |
|
* Thuban/UI/mainwindow.py: Remove unused imports |
1036 |
|
(MainWindow.TableClose): Implement. |
1037 |
|
|
1038 |
|
* Thuban/UI/tableview.py (TableFrame.__init__): Subscribe to some |
1039 |
|
messages so that the frame will be automatically closed when a new |
1040 |
|
session is opened or the table is removed. |
1041 |
|
(TableFrame.OnClose): Unsubscribe the Subscriptions made in |
1042 |
|
__init__ |
1043 |
|
(TableFrame.close_on_session_replaced) |
1044 |
|
(TableFrame.close_on_table_removed): New. Subscribers that close |
1045 |
|
the window |
1046 |
|
|
1047 |
|
* test/test_session.py (TestSessionMessages.test_remove_table) |
1048 |
|
(TestSessionSimple.test_remove_table): Move the test to |
1049 |
|
TestSessionSimple and add test for the TABLE_REMOVED message |
1050 |
|
(TestSessionBase.setUp): Also subscribe to TABLE_REMOVED |
1051 |
|
(TestSessionSimple.test_unreferenced_tables) New. Test for the |
1052 |
|
UnreferencedTables method. |
1053 |
|
(UnreferencedTablesTests): New. Class with some more sophisticated |
1054 |
|
tests for UnreferencedTables. |
1055 |
|
|
1056 |
|
2003-05-27 Frank Koormann <[email protected]> |
1057 |
|
|
1058 |
|
* Thuban/UI/tableview.py (QueryTableFrame.__init__): The "_S_election" |
1059 |
|
display has some unwanted side effects. Removed again. |
1060 |
|
|
1061 |
|
2003-05-27 Frank Koormann <[email protected]> |
1062 |
|
|
1063 |
|
* Resources/Bitmaps/legend_icon_layer.xpm: New, icon for legend. |
1064 |
|
|
1065 |
|
* Thuban/UI/legend.py (LegendTree.__FillTree): Use "legend_icon_layer" |
1066 |
|
|
1067 |
|
2003-05-27 Jan-Oliver Wagner <[email protected]> |
1068 |
|
|
1069 |
|
* test/test_menu.py (MenuTest.test): Added test for |
1070 |
|
Menu.RemoveItem(). |
1071 |
|
|
1072 |
|
* Thuban/UI/menu.py (Menu.RemoveItem): New. Remove an item from |
1073 |
|
the menu. |
1074 |
|
|
1075 |
|
2003-05-27 Frank Koormann <[email protected]> |
1076 |
|
|
1077 |
|
Nonmodal dialogs without parent (i.e. they can fall behind the main |
1078 |
|
window) |
1079 |
|
|
1080 |
|
* Thuban/UI/mainwindow.py (MainWindow.OnClose): Explicitly destroy |
1081 |
|
all dialogs in the dialogs dictionary and the canvas. |
1082 |
|
|
1083 |
|
* Thuban/UI/dialogs.py (NonModalNonParentDialog): New class, without |
1084 |
|
parent, i.e. can fall behind other windows. |
1085 |
|
(NonModalDialog.OnClose): Check is dialog is in mainwindow.dialog |
1086 |
|
dictionary before removing it. |
1087 |
|
|
1088 |
|
* Thuban/UI/classifier.py: Dialog derived from NonModalNonParentDialog |
1089 |
|
|
1090 |
|
* Thuban/UI/projdialog.py: Dialog derived from NonModalNonParentDialog |
1091 |
|
* Thuban/UI/tableview.py: Dialog derived from NonModalNonParentDialog |
1092 |
|
* Thuban/UI/tree.py: Dialog derived from NonModalNonParentDialog |
1093 |
|
|
1094 |
|
2003-05-27 Bernhard Herzog <[email protected]> |
1095 |
|
|
1096 |
|
* Thuban/UI/mainwindow.py (MainWindow.ShowTableView): New. Open a |
1097 |
|
tableview dialog |
1098 |
|
(MainWindow.TableShow): Use ShowTableView to open the dialogs. |
1099 |
|
Also, don't use the table's titles as the dialog names. The titles |
1100 |
|
aren't guaranteed to be unique. |
1101 |
|
(MainWindow.TableOpen): Open a table view dialog after opening the |
1102 |
|
table |
1103 |
|
|
1104 |
|
2003-05-27 Bernhard Herzog <[email protected]> |
1105 |
|
|
1106 |
|
* Thuban/UI/mainwindow.py: Remove the Table/Hide menu item. Its |
1107 |
|
effect can be achieved by simply closing the window showing the |
1108 |
|
table. |
1109 |
|
(MainWindow.TableHide): Removed. |
1110 |
|
(main_menu): Removed "table_hide" |
1111 |
|
|
1112 |
|
2003-05-27 Frank Koormann <[email protected]> |
1113 |
|
|
1114 |
|
Fix legend tree display problems under Win32 |
1115 |
|
|
1116 |
|
* Thuban/UI/legend.py: BMP_SIZE_W = 15 |
1117 |
|
(LegendTree.__FillTree): Display "legend_icon_map.xpm" with layer title. |
1118 |
|
(LegendTree.__FillTreeLayer): Explicitely set SelectedImage. |
1119 |
|
|
1120 |
|
* Resources/Bitmaps/legend_icon_map.xpm: New icon for legend. |
1121 |
|
|
1122 |
|
2003-05-27 Jan-Oliver Wagner <[email protected]> |
1123 |
|
|
1124 |
|
* Thuban/UI/menu.py (Menu.InsertSeparator): Additional optional parameter |
1125 |
|
'after' now allows to insert separators almost anywhere in the menu. |
1126 |
|
|
1127 |
|
2003-05-27 Frank Koormann <[email protected]> |
1128 |
|
|
1129 |
|
* Thuban/UI/tableview.py (QueryTableFrame.__init__): Underline the |
1130 |
|
"S" of selection box label to hint on hot key (Alt-S). Works under |
1131 |
|
Win32 but is ignored under GTK. |
1132 |
|
|
1133 |
|
2003-05-26 Frank Koormann <[email protected]> |
1134 |
|
|
1135 |
|
* Thuban/UI/projdialog.py (ProjFrame.__do_layout, ProjPanel._DoLayout): |
1136 |
|
Center Choices. |
1137 |
|
|
1138 |
|
2003-05-26 Bernhard Herzog <[email protected]> |
1139 |
|
|
1140 |
|
Remove the Precision methods again. They're too DBF specific to be |
1141 |
|
part of the table interface and they're only used in table_to_dbf |
1142 |
|
anyway. |
1143 |
|
|
1144 |
|
* Thuban/Model/transientdb.py (TransientTableBase.Width):Use a |
1145 |
|
fixed precision of 12 for doubles. |
1146 |
|
(TransientTableBase.Precision): Removed |
1147 |
|
(AutoTransientTable.Width): Delegate to self.table. |
1148 |
|
|
1149 |
|
* Thuban/Model/table.py (DBFTable.Precision) |
1150 |
|
(MemoryTable.Precision): Removed. |
1151 |
|
(MemoryTable.Width): Use a fixed precision of 12 for doubles. |
1152 |
|
(table_to_dbf): Use a fixed precision of 12 for floats unless the |
1153 |
|
column object specifies something else. |
1154 |
|
|
1155 |
|
* test/test_dbf_table.py (TestTableToDBF.test_table_to_dbf): New. |
1156 |
|
test for table_to_dbf |
1157 |
|
|
1158 |
|
2003-05-26 Bernhard Herzog <[email protected]> |
1159 |
|
|
1160 |
|
* test/test_transientdb.py |
1161 |
|
(TestTransientTable.run_iceland_political_tests): Fix a comment. |
1162 |
|
|
1163 |
|
2003-05-26 Bernhard Herzog <[email protected]> |
1164 |
|
|
1165 |
|
* Thuban/UI/mainwindow.py (MainWindow.TableOpen): Real |
1166 |
|
implementation. Mark parts of the file format strings for |
1167 |
|
localization. |
1168 |
|
|
1169 |
|
* Thuban/Model/session.py (Session.OpenTableFile): New. Open a dbf |
1170 |
|
file and add the table to the tables managed by the session |
1171 |
|
|
1172 |
|
* test/test_session.py (TestSessionSimple.test_open_table_file): |
1173 |
|
New. test case for OpenTableFile |
1174 |
|
|
1175 |
|
2003-05-26 Jan-Oliver Wagner <[email protected]> |
1176 |
|
|
1177 |
|
* Thuban/UI/controls.py, Thuban/UI/identifyview.py, Thuban/UI/join.py, |
1178 |
|
Thuban/UI/labeldialog.py, Thuban/UI/mainwindow.py, |
1179 |
|
Thuban/UI/proj4dialog.py, Thuban/UI/tableview.py, Thuban/UI/view.py: |
1180 |
|
Replace the true/false of wxWindows by True/False of Python 2.2.1. |
1181 |
|
|
1182 |
|
2003-05-26 Jan-Oliver Wagner <[email protected]> |
1183 |
|
|
1184 |
|
* Thuban/UI/tableview.py (LayerTableFrame.__init__): If there is |
1185 |
|
already a selection present, update the grid accordingly. |
1186 |
|
|
1187 |
|
* Thuban/UI/mainwindow.py (MainWindow.TableShow): Make the dialog |
1188 |
|
resizeable and increase its initial size. |
1189 |
|
|
1190 |
|
2003-05-26 Frank Koormann <[email protected]> |
1191 |
|
|
1192 |
|
Table export functionality |
1193 |
|
|
1194 |
|
* Thuban/Model/table.py (DBFTable.Width, MemoryTable.Width): |
1195 |
|
Return width (in characters) for a column. |
1196 |
|
(DBFTable.Precision, MemoryTable.Precision): Return decimal precision. |
1197 |
|
(table_to_dbf): Write table to dbf file. |
1198 |
|
(table_to_csv): Write table to csv file. |
1199 |
|
|
1200 |
|
* Thuban/Model/transientdb.py (TransientTableBase.Width, |
1201 |
|
TransientTableBase.Precision): Return column width and precision. |
1202 |
|
|
1203 |
|
* Thuban/UI/tableview.py (QueryTableFrame.OnSaveAs): Call table_to_dbf |
1204 |
|
or table_to_csv depending on file selection. |
1205 |
|
|
1206 |
|
* test/test_dbf_table.py: |
1207 |
|
Test table_to_dbf (extension of former part of test). |
1208 |
|
|
1209 |
|
* test/test_csv_table.py: |
1210 |
|
Test table_to_csv. |
1211 |
|
|
1212 |
|
2003-05-23 Jan-Oliver Wagner <[email protected]> |
1213 |
|
|
1214 |
|
* Thuban/UI/join.py (JoinDialog.OnJoin): Use _() for strings. |
1215 |
|
Use QueryTableFrame instead of TableFrame. |
1216 |
|
|
1217 |
|
* Thuban/UI/mainwindow.py (MainWindow.LayerShowTable): Prefix the |
1218 |
|
table window with 'Layer Table:' instead of 'Table:'. |
1219 |
|
|
1220 |
|
2003-05-23 Jan-Oliver Wagner <[email protected]> |
1221 |
|
|
1222 |
|
Give all tables a title via mix-in TitledObject.LayerShowTable |
1223 |
|
|
1224 |
|
* Thuban/Model/base.py (TitledObject.SetTitle): Call method 'issue' |
1225 |
|
only if it exists. |
1226 |
|
|
1227 |
|
* Thuban/Model/table.py (DBFTable, MemoryTable): mix-in TitledObject |
1228 |
|
and call its init-method with a default title. Remove Title() method. |
1229 |
|
|
1230 |
|
* Thuban/Model/transientdb.py (TransientTable, TransientJoinedTable, |
1231 |
|
AutoTransientTable): mix-in TitledObject and call its init-method with |
1232 |
|
a default title. Remove Title() method. |
1233 |
|
|
1234 |
|
2003-05-23 Bernhard Herzog <[email protected]> |
1235 |
|
|
1236 |
|
* Thuban/Model/session.py (Session.AddShapeStore): Define |
1237 |
|
AddShapeStore analogously to AddTable. |
1238 |
|
|
1239 |
|
* test/test_session.py (TestSessionSimple.test_add_shapestore): |
1240 |
|
New. Test for AddShapeStore |
1241 |
|
|
1242 |
|
2003-05-23 Jan-Oliver Wagner <[email protected]> |
1243 |
|
|
1244 |
|
Introducing QueryTableFrame and a very coarse ShowTable implementation. |
1245 |
|
|
1246 |
|
* Thuban/UI/tableview.py (LayerTableFrame, QueryTableFrame): Split the |
1247 |
|
class LayerTableFrame into two classes, LayerTableFrame and QueryTableFrame. |
1248 |
|
The latter implements the selection GUI without dependency on a layer. |
1249 |
|
LayerTableFrame now is derived from QueryTableFrame and connects |
1250 |
|
to a layer. |
1251 |
|
|
1252 |
|
* Thuban/UI/mainwindow.py (MainWindow.TableShow): A very coarse |
1253 |
|
implementation that still needs work. |
1254 |
|
|
1255 |
|
* Thuban/Model/layer.py (Layer.TreeInfo): Added filename. |
1256 |
|
|
1257 |
|
2003-05-22 Frank Koormann <[email protected]> |
1258 |
|
|
1259 |
|
* Thuban/Model/transientdb.py (TransientJoinedTable.__init__): |
1260 |
|
Added "outer_join = False" as optional parameter. |
1261 |
|
(TransientJoinedTable.create): If outer join is true, perform a |
1262 |
|
"LEFT OUTER JOIN" instead of "JOIN", which preserves all records of |
1263 |
|
the left table. Records not matching are filled with 0 / None. |
1264 |
|
|
1265 |
|
* Thuban/UI/join.py (JoinDialog.__init__): Checkbox for outer join. |
1266 |
|
(JoinDialog.OnJoin): Consider outer join check box. |
1267 |
|
|
1268 |
|
2003-05-22 Bernhard Herzog <[email protected]> |
1269 |
|
|
1270 |
|
* Thuban/UI/join.py (JoinDialog.OnJoin): Use exc_info in a |
1271 |
|
somewhat safer way. Storing the traceback in a local variable can |
1272 |
|
lead to memory leaks |
1273 |
|
|
1274 |
|
2003-05-22 Bernhard Herzog <[email protected]> |
1275 |
|
|
1276 |
|
* Thuban/UI/join.py (JoinDialog.OnJoin): Make sure to really call |
1277 |
|
the wxMessageDialog's Destroy() method. |
1278 |
|
|
1279 |
|
2003-05-22 Frank Koormann <[email protected]> |
1280 |
|
|
1281 |
|
* Thuban/UI/join.py (JoinDialog.__init__): Make use of |
1282 |
|
TransientTable.Title() |
1283 |
|
|
1284 |
|
2003-05-22 Frank Koormann <[email protected]> |
1285 |
|
|
1286 |
|
Join Dialog, initial version. |
1287 |
|
|
1288 |
|
* Thuban/UI/mainwindow.py (MainWindow.TableJoin): Removed print. |
1289 |
|
|
1290 |
|
* Thuban/UI/join.py (JoinDialog): Functional implementation of |
1291 |
|
former framework. Renamed Table1/Table2 to LeftTable/RightTable |
1292 |
|
in all occurences. |
1293 |
|
|
1294 |
|
* Thuban/Model/transientdb.py (TransientJoinedTable.__doc__): |
1295 |
|
Typo fixed. |
1296 |
|
|
1297 |
|
2003-05-22 Bernhard Herzog <[email protected]> |
1298 |
|
|
1299 |
|
Give the tables titles so that the GUI can display more meaningful |
1300 |
|
names. For now the titles are fixed but depend on e.g. filenames |
1301 |
|
or the titles of the joined tables. |
1302 |
|
|
1303 |
|
* Thuban/Model/transientdb.py (TransientTable.Title) |
1304 |
|
(TransientJoinedTable.Title, AutoTransientTable.Title): New. |
1305 |
|
|
1306 |
|
* Thuban/Model/table.py (DBFTable.Title, MemoryTable.Title): New. |
1307 |
|
|
1308 |
|
* test/test_transientdb.py |
1309 |
|
(TestTransientTable.test_auto_transient_table_title): New. Test |
1310 |
|
for the Title method |
1311 |
|
(TestTransientTable.test_transient_joined_table) |
1312 |
|
(TestTransientTable.test_transient_table): Add test for the Title |
1313 |
|
methods |
1314 |
|
|
1315 |
|
* test/test_memory_table.py (TestMemoryTable.test_title): New. |
1316 |
|
Test for the Title method |
1317 |
|
|
1318 |
|
* test/test_dbf_table.py (TestDBFTable.test_title): New. Test for |
1319 |
|
the Title method |
1320 |
|
|
1321 |
|
2003-05-22 Bernhard Herzog <[email protected]> |
1322 |
|
|
1323 |
|
* test/test_layer.py (TestLayer.setUp, TestLayer.tearDown): |
1324 |
|
Provide a better way to destroy the layers |
1325 |
|
(TestLayer.test_base_layer, TestLayer.test_arc_layer) |
1326 |
|
(TestLayer.test_point_layer, TestLayer.test_empty_layer) |
1327 |
|
(TestLayer.test_polygon_layer, TestLayer.test_get_field_type): Use |
1328 |
|
the new way to destroy the layers. |
1329 |
|
(TestLayer.test_derived_store): New. Test for using a layer with a |
1330 |
|
DerivedShapeStore |
1331 |
|
|
1332 |
|
* Thuban/Model/layer.py (Layer.SetShapeStore): Only set the |
1333 |
|
filename if the shape store actually has one. |
1334 |
|
|
1335 |
|
2003-05-22 Bernhard Herzog <[email protected]> |
1336 |
|
|
1337 |
|
* Thuban/Model/table.py (DBFTable.FileName): New. Accessor method |
1338 |
|
for the filename |
1339 |
|
|
1340 |
|
* test/test_dbf_table.py (TestDBFTable.test_filename): New. Test |
1341 |
|
for the FileName method |
1342 |
|
(TestDBFTableWriting.test_write): Fix spelling of filename |
1343 |
|
|
1344 |
|
2003-05-22 Thomas Koester <[email protected]> |
1345 |
|
|
1346 |
|
* Thuban/Model/range.py, test/test_range.py: Brought over new Range |
1347 |
|
from SciParam that now really is immutable. |
1348 |
|
|
1349 |
|
2003-05-22 Frank Koormann <[email protected]> |
1350 |
|
|
1351 |
|
Layer Top/Bottom placement added to legend. |
1352 |
|
|
1353 |
|
* Thuban/UI/legend.py |
1354 |
|
(LegendPanel._OnMoveTop(), LayerPanel._OnMoveBottom): New, methods |
1355 |
|
bound to tool events. |
1356 |
|
(LegendTree.MoveCurrentItemTop(), LegendTree.MoveCurrentItemBottom): |
1357 |
|
New, methods binding the event methods with the map methods. |
1358 |
|
|
1359 |
|
* Thuban/Model/map.py (Map.TopLayer(), Map.BottomLayer()): New, place |
1360 |
|
layer at top/bottom of layer stack. |
1361 |
|
|
1362 |
|
* Resources/Bitmaps/top_layer.xpm: New button icon. |
1363 |
|
|
1364 |
|
* Resources/Bitmaps/bottom_layer.xpm: New button icon. |
1365 |
|
|
1366 |
|
2003-05-22 Bernhard Herzog <[email protected]> |
1367 |
|
|
1368 |
|
* Thuban/Model/session.py (Session.RemoveTable): New method to |
1369 |
|
remove tables |
1370 |
|
|
1371 |
|
* test/test_session.py (TestSessionSimple.test_remove_table): New. |
1372 |
|
Test for RemoveTable |
1373 |
|
|
1374 |
|
2003-05-22 Thomas Koester <[email protected]> |
1375 |
|
|
1376 |
|
* Thuban/Model/classgen.py: Added short module doc string and CVS id. |
1377 |
|
(ClassGenerator.GenUniformDistribution): Use new Range __init__, too. |
1378 |
|
|
1379 |
|
2003-05-22 Bernhard Herzog <[email protected]> |
1380 |
|
|
1381 |
|
Implement a way to discover dependencies between tables and |
1382 |
|
shapestores. |
1383 |
|
|
1384 |
|
* Thuban/Model/transientdb.py (TransientTableBase.Dependencies) |
1385 |
|
(TransientJoinedTable.Dependencies) |
1386 |
|
(AutoTransientTable.SimpleQuery): New. Implement the dependencies |
1387 |
|
interface |
1388 |
|
(TransientJoinedTable.__init__): Keep tack of the original table |
1389 |
|
objects in addition to the corresponding transient tables. |
1390 |
|
|
1391 |
|
* Thuban/Model/table.py (DBFTable.Dependencies) |
1392 |
|
(MemoryTable.Dependencies): New. Implement the dependencies |
1393 |
|
interface |
1394 |
|
|
1395 |
|
* Thuban/Model/data.py (ShapeTable): New. Helper class for |
1396 |
|
ShapefileStore |
1397 |
|
(ShapefileStore.__init__): Use ShapeTable instead of |
1398 |
|
AutoTransientTable |
1399 |
|
(ShapefileStore.Table, ShapefileStore.Shapefile): Add doc-strings |
1400 |
|
(ShapefileStore.FileName, ShapefileStore.FileType): New. Accessor |
1401 |
|
methods for filename and type |
1402 |
|
(ShapefileStore.Dependencies): New. Implement the dependencies |
1403 |
|
interface |
1404 |
|
(DerivedShapeStore): New class to replace SimpleStore. The main |
1405 |
|
difference to SimpleStore is that it depends not on a shapefile |
1406 |
|
but another shapestore which expresses the dependencies a bit |
1407 |
|
better |
1408 |
|
(SimpleStore.__init__): Add deprecation warning. |
1409 |
|
|
1410 |
|
* test/test_dbf_table.py (TestDBFTable.test_dependencies): New. |
1411 |
|
Test for the Dependencies method. |
1412 |
|
|
1413 |
|
* test/test_memory_table.py (TestMemoryTable.test_dependencies): |
1414 |
|
New. Test for the Dependencies method. |
1415 |
|
|
1416 |
|
* test/test_transientdb.py |
1417 |
|
(TestTransientTable.test_auto_transient_table_dependencies): New. |
1418 |
|
Test for the Dependencies method. |
1419 |
|
(TestTransientTable.test_transient_joined_table): Add test for the |
1420 |
|
Dependencies method. |
1421 |
|
|
1422 |
|
* test/test_session.py (TestSessionSimple.setUp) |
1423 |
|
(TestSessionSimple.tearDown): New. Implement a better way to |
1424 |
|
destroy the sessions. |
1425 |
|
(TestSessionSimple.test_initial_state) |
1426 |
|
(TestSessionSimple.test_add_table): Bind session to self.session |
1427 |
|
so that it's destroyed by tearDown |
1428 |
|
(TestSessionSimple.test_open_shapefile): New. Test for |
1429 |
|
OpenShapefile and the object it returns |
1430 |
|
|
1431 |
|
2003-05-22 Bernhard Herzog <[email protected]> |
1432 |
|
|
1433 |
|
* Thuban/Model/session.py (Session.AddTable): New method to |
1434 |
|
register tables with the session. |
1435 |
|
(Session.Tables): Return the tables registered with AddTable too. |
1436 |
|
|
1437 |
|
* test/test_session.py (TestSessionSimple.test_add_table): New. |
1438 |
|
Test case for the AddTable method |
1439 |
|
|
1440 |
|
2003-05-22 Frank Koormann <[email protected]> |
1441 |
|
|
1442 |
|
UI polishing updates: Place main buttons (OK, Cancel, etc) in the |
1443 |
|
lower right corner, center labels for selections, initialize controls |
1444 |
|
in reasonable order for keyboard navigation. |
1445 |
|
|
1446 |
|
* Thuban/UI/projdialog.py (ProjFrame.__init__, ProjFrame.__doLayout) |
1447 |
|
(ProjFrame.__DoOnProjAvail): Determine position of current projection |
1448 |
|
using the wxListBox.FindString() method. Still a problem (#1886) |
1449 |
|
|
1450 |
|
* Thuban/UI/classifier.py |
1451 |
|
(Classifier.__init__, SelectPropertiesDialog.__init__) |
1452 |
|
|
1453 |
|
* Thuban/UI/classgen.py (ClassGenDialog.__init__, |
1454 |
|
(ClassGenDialog.__DoOnGenTypeSelect): Moved initialization of the |
1455 |
|
different classification types from here to __init__. |
1456 |
|
(GenUniquePanel.__init__): Set the column width of the first field |
1457 |
|
in the Field ListCtrl to the full width. |
1458 |
|
|
1459 |
|
* Thuban/UI/tableview.py (LayerTableFrame.__init__): Rename 'Save As' |
1460 |
|
Button to 'Export'. Center Buttons in Selection Box, set Focus to |
1461 |
|
Grid. |
1462 |
|
(LayerTableFrame.OnKeyDown()): New, bound to the grid with EVT_KEY_DOWN, |
1463 |
|
changes focus to the Selection when pressing "Alt-S". |
1464 |
|
|
1465 |
|
* Thuban/UI/legend.py (LegendTree.__SetVisibilityStyle): Only gray out |
1466 |
|
the text if not visible. The italic font sometimes exceeds the |
1467 |
|
rendering area. |
1468 |
|
|
1469 |
|
2003-05-21 Jonathan Coles <[email protected]> |
1470 |
|
|
1471 |
|
* Thuban/UI/dock.py (DockFrame): Rename references to _OnClose |
1472 |
|
to OnClose so that Thuban closes correctly. |
1473 |
|
|
1474 |
|
* Thuban/UI/mainwindow.py (MainWindow.OnClose): Call |
1475 |
|
DockFrame.OnClose, not DockFrame._OnClose. |
1476 |
|
|
1477 |
|
2003-05-21 Jonathan Coles <[email protected]> |
1478 |
|
|
1479 |
|
* Thuban/Model/classgen.py (ClassGenerator.GenQuantiles): Remove |
1480 |
|
references to 'inf' and use new Range __init__ to pass floats |
1481 |
|
directly rather than converting them to strings first. |
1482 |
|
Fixes RTBug #1876. |
1483 |
|
|
1484 |
|
* Thuban/Model/classification.py (ClassGroupRange.SetRange): |
1485 |
|
Use new Range ___init__ to pass floats. |
1486 |
|
|
1487 |
|
* Thuban/Model/layer.py (RasterLayer.__init__): Test if the |
1488 |
|
filename is a valid image file. Throw IOError otherwise. |
1489 |
|
|
1490 |
|
* Thuban/Model/range.py: Brought over new Range from SciParam that |
1491 |
|
is immutable and has an __init__ which can accept floats. |
1492 |
|
|
1493 |
|
* Thuban/UI/mainwindow.py (MainWindow.AddLayer): Move OpenShapefile |
1494 |
|
into try block. AddLayer doesn't throw any exceptions anymore. |
1495 |
|
(MainWindow.AddRasterLayer): Move constructor of RasterLayer into |
1496 |
|
try block. |
1497 |
|
|
1498 |
|
* Thuban/UI/projdialog.py (GeoPanel.__init__): Put Degrees as |
1499 |
|
the first item in choices. Fixes RTBug #1882. |
1500 |
|
|
1501 |
|
* Thuban/UI/renderer.py (MapRenderer.render_map): Check if scale |
1502 |
|
has gone to 0 which is a serious problem. abort. |
1503 |
|
(MapRenderer.draw_raster_layer): Catch IOError seperately and |
1504 |
|
print the error from GDAL. |
1505 |
|
|
1506 |
|
* Thuban/UI/tableview.py (TableGrid.__init__): Call |
1507 |
|
ToggleEventListeners to turn on listening. |
1508 |
|
(TableGrid.ToggleEventListeners): New. Turns event listening on |
1509 |
|
and off so as to prevent excessive messages. |
1510 |
|
(LayerTableFrame.OnQuery): Use TableGrid.ToggleEventListeners |
1511 |
|
to suppress excessive messages when selecting many rows. |
1512 |
|
Fixes RTBug #1880. |
1513 |
|
|
1514 |
|
* Thuban/UI/view.py: Added checks against if scale == 0. This |
1515 |
|
is a serious problem that can occur when an image without |
1516 |
|
geo data is loading and causes the map projection bounds to |
1517 |
|
go to infinity. Right now, the solution is to simply try |
1518 |
|
to recover. |
1519 |
|
|
1520 |
|
* extensions/thuban/cpl_mfile.cpp (MFILEClose): Make sure |
1521 |
|
to set the MFILEReceiver attributes even if the data is NULL. |
1522 |
|
|
1523 |
|
* extensions/thuban/gdalwarp.cpp: Improved the error handling |
1524 |
|
and passed GDAL messages back up to the Python layer. Also |
1525 |
|
tried to fix some memory leaks that were present in the original |
1526 |
|
utility but didn't matter because the program aborted. |
1527 |
|
|
1528 |
|
* test/test_range.py: Copied over tests from SciParam. Removed |
1529 |
|
tests against importing. Fixes RTBug #1867. |
1530 |
|
|
1531 |
|
2003-05-21 Bernhard Herzog <[email protected]> |
1532 |
|
|
1533 |
|
* test/test_load.py: Remove unused imports and restructure the |
1534 |
|
test code |
1535 |
|
(LoadSessionTest): Split into one class for each test and turn |
1536 |
|
LoadSessionTest itself into the base class for all such session |
1537 |
|
tests. |
1538 |
|
(ClassificationTest): New base class for load tests that test |
1539 |
|
classifications |
1540 |
|
(TestSingleLayer, TestLayerVisibility, TestClassification) |
1541 |
|
(TestLabels, TestLayerProjection, TestRasterLayer): New classes |
1542 |
|
for the individual tests |
1543 |
|
|
1544 |
|
* test/support.py (FileLoadTestCase.filename): New base class for |
1545 |
|
file loading tests |
1546 |
|
|
1547 |
|
2003-05-21 Jan-Oliver Wagner <[email protected]> |
1548 |
|
|
1549 |
|
* Resources/Projections/defaults.proj: Renamed 'Universal Transverse |
1550 |
|
Mercator' to 'UTM Zone 32' as a more convenient example. |
1551 |
|
Added 'Gauss Krueger Zone 6'. |
1552 |
|
|
1553 |
|
* Data/iceland_sample_raster.thuban: political polygon now |
1554 |
|
filled transparent to have the raster image visible at once. |
1555 |
|
|
1556 |
|
2003-05-21 Frank Koormann <[email protected]> |
1557 |
|
|
1558 |
|
* Thuban/UI/mainwindow.py (MainWindow): Renamed _OnClose() back to |
1559 |
|
OnClose() to keep in sync with extensions. Internally Thuban |
1560 |
|
still uses "underscored" names. |
1561 |
|
|
1562 |
|
2003-05-20 Jonathan Coles <[email protected]> |
1563 |
|
|
1564 |
|
This puts back Raster layer support. These layers support projections |
1565 |
|
through the GDAL library. Currently, the CVS version is being used. |
1566 |
|
There are no Debian packages available although this may change soon. |
1567 |
|
A GDAL driver was extended to support writing to memory rather to |
1568 |
|
files. |
1569 |
|
|
1570 |
|
There is still some work that needs to be done, such as some error |
1571 |
|
handling when loading invalid images or when there is a problem |
1572 |
|
projecting the image. This putback simply checks in the majority |
1573 |
|
of the work. |
1574 |
|
|
1575 |
|
* setup.py: Add gdalwarp library extension. |
1576 |
|
|
1577 |
|
* Thuban/Model/layer.py (BaseLayer.HasClassification): New. |
1578 |
|
Defaults to False, but can be overridden by subclasses if they |
1579 |
|
support classification. |
1580 |
|
(RasterLayer): New. Defines a new layer that represents an |
1581 |
|
image. |
1582 |
|
|
1583 |
|
* Thuban/Model/load.py (SessionLoader.__init__): Add rasterlayer |
1584 |
|
tag handler. |
1585 |
|
(SessionLoader.start_layer): Encode the filename. |
1586 |
|
(SessionLoader.start_rasterlayer, SessionLoader.end_rasterlayer): |
1587 |
|
New. Supports reading a rasterlayer tag. |
1588 |
|
|
1589 |
|
* Thuban/Model/map.py (Map.BoundingBox): Fix typo in comment. |
1590 |
|
|
1591 |
|
* Thuban/Model/save.py (XMLWriter.encode): Don't assume that we |
1592 |
|
get a string in Latin1. If we get such as string convert it to |
1593 |
|
unicode first, otherwise leave if alone before encoding. |
1594 |
|
(SessionSaver.write_layer): Add support for writing both Layers |
1595 |
|
and RasterLayers. |
1596 |
|
|
1597 |
|
* Thuban/Model/transientdb.py (AutoTransientTable.SimpleQuery): |
1598 |
|
The right argument may not be a string, it could also be a Column. |
1599 |
|
|
1600 |
|
* Thuban/UI/application.py (ThubanApplication.CreateMainWindow): |
1601 |
|
Make initial window size 600x400. Fixes RTBug #1872. |
1602 |
|
|
1603 |
|
* Thuban/UI/classifier.py (Classifier.__init__): Rearrange how |
1604 |
|
the dialog is constructed so that we can support layers that |
1605 |
|
do not have classifications. |
1606 |
|
(Classifier._OnTry): Only build a classification if the layer |
1607 |
|
supports one. |
1608 |
|
|
1609 |
|
* Thuban/UI/legend.py: Change all checks that a layer is an |
1610 |
|
instance of Layer into checks against BaseLayer. |
1611 |
|
(LegendTree.__FillTreeLayer): Only add children to a branch if |
1612 |
|
the layer supports classification. |
1613 |
|
|
1614 |
|
* Thuban/UI/mainwindow.py (MainWindow.NewSession, |
1615 |
|
MainWindow.OpenSession): Don't proceed with an action if the |
1616 |
|
user chooses Cancel when they are asked to save changes. |
1617 |
|
(MainWindow.AddRasterLayer): New. Open a dialog to allow the |
1618 |
|
user to select an image file. Create a new RasterLayer and add |
1619 |
|
it to the map. |
1620 |
|
|
1621 |
|
* Thuban/UI/renderer.py (MapRenderer.render_map): Add support |
1622 |
|
for rendering RasterLayer layers. |
1623 |
|
(MapRenderer.draw_raster_layer): Actually method that calls |
1624 |
|
the GDALWarp python wrapper and constructs an image from the |
1625 |
|
data returned. |
1626 |
|
|
1627 |
|
* Thuban/UI/tableview.py (LayerTableFrame.__init__): Change the |
1628 |
|
Choices symbols to match those used in the table query method. |
1629 |
|
Replace deprecated method calls on table with new method names. |
1630 |
|
|
1631 |
|
* Thuban/UI/view.py (MapCanvas.set_view_transform): Try to limit |
1632 |
|
how small the scale can get. This still needs more testing. |
1633 |
|
|
1634 |
|
* extensions/thuban/bmpdataset.cpp: New, but copied from GDAL. |
1635 |
|
Provides a driver to output in .bmp format. |
1636 |
|
|
1637 |
|
* extensions/thuban/cpl_mfile.cpp, extensions/thuban/cpl_mfile.h: |
1638 |
|
New. Provides IO routines which write to memory, rather than a file. |
1639 |
|
|
1640 |
|
* extensions/thuban/gdalwarp.cpp: New, but basically a direct copy |
1641 |
|
of the gdalwarp utility provided in GDAL. Added function calls |
1642 |
|
that can be accessed from python. |
1643 |
|
|
1644 |
|
* Data/iceland_sample_raster.thuban: New. Sample file that uses |
1645 |
|
a raster layer. |
1646 |
|
|
1647 |
|
* Data/iceland/island.tfw, Data/iceland/island.tif: New. Raster |
1648 |
|
layer image data. |
1649 |
|
|
1650 |
|
* Doc/thuban.dtd: Added rasterlayer attribute definition. |
1651 |
|
|
1652 |
|
* test/test_layer.py, test/test_load.py, test/test_save.py: Added |
1653 |
|
tests associated with the raster layer code. |
1654 |
|
|
1655 |
|
* test/test_transientdb.py |
1656 |
|
(TestTransientTable.test_auto_transient_table_query): Added a test |
1657 |
|
for using a Column object as the "right" parameter to a query. |
1658 |
|
|
1659 |
|
2003-05-19 Frank Koormann <[email protected]> |
1660 |
|
|
1661 |
|
* Thuban/version.py (get_changelog_date): |
1662 |
|
Catch exceptions if ChangeLog does not exist. |
1663 |
|
|
1664 |
|
* Thuban/UI/view.py (MapCanvas.Export): Bugfix |
1665 |
|
|
1666 |
2003-05-19 Frank Koormann <[email protected]> |
2003-05-19 Frank Koormann <[email protected]> |
1667 |
|
|
1668 |
Extended version information for Thuban |
Extended version information for Thuban |