1 |
|
2003-06-10 Bernhard Herzog <[email protected]> |
2 |
|
|
3 |
|
* Thuban/Lib/connector.py (Connector.Issue): Iterate over a copy |
4 |
|
of the receivers list so that unsubscribing in a receiver doesn't |
5 |
|
modify it while iterating over it. |
6 |
|
|
7 |
|
* test/test_connector.py |
8 |
|
(ConnectorTest.test_disconnect_in_receiver): New. Test whether |
9 |
|
unsubscribing in a receiver works correctly. See docstring for |
10 |
|
details |
11 |
|
|
12 |
|
2003-06-10 Bernhard Herzog <[email protected]> |
13 |
|
|
14 |
|
* Thuban/Model/messages.py (LAYER_SHAPESTORE_REPLACED): New |
15 |
|
message. |
16 |
|
|
17 |
|
* Thuban/Model/layer.py (Layer.SetShapeStore): Send |
18 |
|
LAYER_SHAPESTORE_REPLACED when the shapestore changes. A |
19 |
|
LAYER_CHANGED will still be sent if the classification changes. |
20 |
|
|
21 |
|
* Thuban/UI/classifier.py (Classifier.__init__): Add the map as |
22 |
|
parameter so we can subscribe to some of its messages |
23 |
|
(Classifier.__init__): Subscribe to the map's MAP_LAYERS_REMOVED |
24 |
|
and the layer's LAYER_SHAPESTORE_REPLACED |
25 |
|
(Classifier.unsubscribe_messages): New. Unsubscribe from message |
26 |
|
subscribed to in __init__ |
27 |
|
(Classifier.map_layers_removed) |
28 |
|
(Classifier.layer_shapestore_replaced): receivers for the messages |
29 |
|
subscribed to in __init__. Unsubscribe and close the dialog |
30 |
|
|
31 |
|
* Thuban/UI/mainwindow.py (MainWindow.OpenLayerProperties): Pass |
32 |
|
the map to the Classifier dialog |
33 |
|
|
34 |
|
* test/test_layer.py (SetShapeStoreTests): Derive from |
35 |
|
SubscriberMixin as well so we can test messages |
36 |
|
(SetShapeStoreTests.setUp): Subscribe to some of the layer's |
37 |
|
messages |
38 |
|
(SetShapeStoreTests.tearDown): Clear the messages again |
39 |
|
(SetShapeStoreTests.test_sanity): Expand the doc-string and check |
40 |
|
for the modified flag too |
41 |
|
(SetShapeStoreTests.test_set_shape_store_modified_flag): New test |
42 |
|
to check whether SetShapeStore sets the modified flag |
43 |
|
(SetShapeStoreTests.test_set_shape_store_different_field_name) |
44 |
|
(SetShapeStoreTests.test_set_shape_store_same_field) |
45 |
|
(SetShapeStoreTests.test_set_shape_store_same_field_different_type): |
46 |
|
Add tests for the messages. This checks both the new |
47 |
|
LAYER_SHAPESTORE_REPLACED and the older LAYER_CHANGED |
48 |
|
|
49 |
|
2003-06-06 Jan-Oliver Wagner <[email protected]> |
50 |
|
|
51 |
|
* Thuban/UI/mainwindow.py: Improved and partly added help texts for |
52 |
|
the menu items. |
53 |
|
|
54 |
|
2003-06-05 Frank Koormann <[email protected]> |
55 |
|
|
56 |
|
* Thuban/UI/identifyview.py (IdentifyView.__init__): |
57 |
|
Layout reimplemented without panel. Make life easier to fit the list |
58 |
|
in the dialog. |
59 |
|
|
60 |
|
2003-06-05 Frank Koormann <[email protected]> |
61 |
|
|
62 |
|
* Thuban/UI/projdialog.py (ProjFrame.__init__): Fill the projchoice |
63 |
|
once on initialisation (Former implementation resulted in multiple |
64 |
|
entries for each projection). |
65 |
|
(ProjFrame.__FillAvailList): selectProj as second optional parameter, |
66 |
|
if set, select the projection found under the specified name. This |
67 |
|
overwrites any other selection estimate. |
68 |
|
Removed projchoice filling from this method. |
69 |
|
(ProjFrame._OnSave, ProjFrame._OnAddToList): |
70 |
|
Updated call of ProjFrame.__FillAvailList |
71 |
|
(LCCPanel._DoLayout): Moved parameter controls in more common order. |
72 |
|
|
73 |
|
* Resources/Projections/defaults.proj: Extended defaults representing |
74 |
|
various common European projections. |
75 |
|
|
76 |
|
2003-06-05 Frank Koormann <[email protected]> |
77 |
|
|
78 |
|
* Thuban/UI/identifyview.py (IdentifyView.__init__): |
79 |
|
Use ListCtrl instead of GridCtrl |
80 |
|
|
81 |
|
* Thuban/Model/resource.py: |
82 |
|
Guess location of .thuban directory from tempdir parent directory. |
83 |
|
|
84 |
|
* Thuban/UI/application.py (ThubanApplication.read_startup_files): |
85 |
|
Guess location of .thuban directory from tempdir parent directory. |
86 |
|
|
87 |
|
2003-06-04 Bernhard Herzog <[email protected]> |
88 |
|
|
89 |
|
Do not cache the values returned by the tree widget's |
90 |
|
GetFirstChild and GetNextChild methods because it led to lots of |
91 |
|
segfaults. The new way requires more brute force but is more |
92 |
|
reliable. |
93 |
|
|
94 |
|
* Thuban/UI/legend.py (LegendTree.__init__): Remove instance |
95 |
|
variable layer2id |
96 |
|
(LegendTree.find_layer): New method to do with brute force what |
97 |
|
layer2id tried to accomplish |
98 |
|
(LegendTree._OnMsgLayerChanged) |
99 |
|
(LegendTree._OnMsgLayerTitleChanged, LegendTree.__ShowHideLayer): |
100 |
|
Use find_layer instead of layer2id |
101 |
|
(LegendTree.__RemoveLayer, LegendTree.__AddLayer): No need to |
102 |
|
update layer2id anymore |
103 |
|
(LegendTree._OnMsgMapLayersRemoved) |
104 |
|
(LegendTree._OnMsgMapLayersAdded): Get by without layer2id. |
105 |
|
|
106 |
|
2003-06-03 Thomas Koester <[email protected]> |
107 |
|
|
108 |
|
* Thuban/Model/classgen.py (GenQuantiles0): New function. |
109 |
|
|
110 |
|
2003-06-02 Bernhard Herzog <[email protected]> |
111 |
|
|
112 |
|
* Thuban/UI/mainwindow.py (layer_rename command, table_rename command): |
113 |
|
New commands. |
114 |
|
(main_menu): Add the new commands. |
115 |
|
(MainWindow.TableRename): New. Implementation of the table_rename |
116 |
|
command. |
117 |
|
(MainWindow.RenameLayer): New. Implementation of the layer_rename |
118 |
|
command. |
119 |
|
|
120 |
|
* Thuban/Model/session.py (Session.AddTable): call self.changed to |
121 |
|
set the modified flag |
122 |
|
|
123 |
|
* test/test_session.py (TestSessionSimple.test_add_table): Test |
124 |
|
whether the modified flag is set properly |
125 |
|
|
126 |
|
* Thuban/Model/base.py (TitledObject.SetTitle): Call changed |
127 |
|
instead of issue so that the modified flags get updated. |
128 |
|
|
129 |
|
* test/test_base.py (SomeTitledObject): Derive from Modifiable |
130 |
|
instead of Publisher to reflect reality better and to accomodate |
131 |
|
the fact that SetTitle now calls changed instead of issue |
132 |
|
|
133 |
|
2003-06-02 Bernhard Herzog <[email protected]> |
134 |
|
|
135 |
|
* Thuban/UI/classgen.py (GenQuantilesPanel.GetList): Resource |
136 |
|
acquisition has to happen before the try in a try-finally. |
137 |
|
|
138 |
|
2003-06-02 Bernhard Herzog <[email protected]> |
139 |
|
|
140 |
|
* Thuban/UI/legend.py (LegendTree._OnMsgMapLayersRemoved): It's |
141 |
|
possible that a layer is removed that is not currently selected in |
142 |
|
the legend so don't check for this. |
143 |
|
|
144 |
|
2003-05-30 Bernhard Herzog <[email protected]> |
145 |
|
|
146 |
|
* Thuban/Model/layer.py (Layer.Destroy): Set all instance |
147 |
|
variables to None that have direct or indirect references to |
148 |
|
shapefiles or dbf files to make sure that they do go away and the |
149 |
|
files are closed. |
150 |
|
|
151 |
|
2003-05-30 Bernhard Herzog <[email protected]> |
152 |
|
|
153 |
|
* Thuban/UI/legend.py (LegendTree.GetRootItem): Reset |
154 |
|
availImgListIndices when a new image list is created |
155 |
|
|
156 |
|
2003-05-30 Bernhard Herzog <[email protected]> |
157 |
|
|
158 |
|
* Thuban/UI/legend.py (LegendTree.__init__): New instance variable |
159 |
|
changing_selection to indicate whether the LegendTree code itself |
160 |
|
is currently changing the selection |
161 |
|
(LegendTree.normalize_selection): New method to normalize the |
162 |
|
selection by selecting the layer item even if the user clicked on |
163 |
|
the classification. |
164 |
|
(LegendTree._OnSelChanged): normalize the selection. This works |
165 |
|
around a bug in wx which doesn't keep track of the selection |
166 |
|
properly when subtrees are deleted. |
167 |
|
|
168 |
|
2003-05-30 Bernhard Herzog <[email protected]> |
169 |
|
|
170 |
|
* Thuban/UI/view.py (MapCanvas.set_view_transform): Limit the |
171 |
|
maximum and minimum scale factors. |
172 |
|
|
173 |
|
* test/test_classgen.py (ClassGenTest.test): Update to reflect the |
174 |
|
changes in classgen.py |
175 |
|
|
176 |
|
2003-05-30 Jonathan Coles <[email protected]> |
177 |
|
|
178 |
|
* Thuban/Model/classgen.py: Remove ClassGenerator class but make |
179 |
|
all the methods functions. Fixes RTBug #1903. |
180 |
|
|
181 |
|
* Thuban/Model/map.py (Map.TopLayer, Map.BottomLayer): Renamed |
182 |
|
to MoveLayerToTop and MoveLayerToBottom respectively. Fixes |
183 |
|
RTBug #1907. |
184 |
|
|
185 |
|
* Thuban/UI/classgen.py: Use classgen functions that were part |
186 |
|
of the ClassGenerator class. Put try/finally blocks around |
187 |
|
code that uses wxBeginBusyCursor()/wxEndBusyCursor(). Fixes |
188 |
|
RTBug #1904. |
189 |
|
|
190 |
|
* Thuban/UI/classifier.py: Remove unused import of ClassGenerator. |
191 |
|
|
192 |
|
* Thuban/UI/legend.py: The legend was cleared and repopulated any |
193 |
|
time something changed which caused some state to be lost such |
194 |
|
as which children were expanded or collapsed. Fixes RTBug #1901. |
195 |
|
(LegendTree._OnMsgMapLayersAdded): Add only new layers. |
196 |
|
(LegendTree.__OnMsgMapLayersRemoved): Remove layers that exist in |
197 |
|
the legend but not in the map. |
198 |
|
(LegendTree.__FillTree): Move main functionality out into smaller |
199 |
|
methods that can be used by other methods. |
200 |
|
(LegendTree.__FillTreeLayer): Reuse old slots in the image list |
201 |
|
if they are available. |
202 |
|
(LegendTree.DeleteAllItems): Renamed from __DeleteAllItems so |
203 |
|
that we override the wxTreeCtrl method. Iterate over children |
204 |
|
and call __RemoveLayer. |
205 |
|
(LegendTree.__AddLayer): New. Add a new layer to the legend. |
206 |
|
(LegendTree.__RemoveLayer): Remove a layer from the legend. |
207 |
|
(LegendTree.DeleteChildren): New, overrides wxTreeCtrl method. |
208 |
|
Should only be called with the id of a layer branch. |
209 |
|
(LegendTree.GetRootItem): New, overrides wxTreeCtrl method. |
210 |
|
Returns the root item or creates one if necessary. |
211 |
|
|
212 |
|
* Thuban/UI/renderer.py (MapRenderer.draw_raster_layer): Call |
213 |
|
ProjectRasterFile with tuple arguments instead of strings. |
214 |
|
|
215 |
|
* Thuban/UI/tableview.py (QueryTableFrame.OnQuery): Wrap code |
216 |
|
with try/finally. Fixes RTBug #1904. |
217 |
|
|
218 |
|
* Thuban/UI/view.py (MapCanvas.OnPaint): Wrap code |
219 |
|
with try/finally. Fixes RTBug #1904. |
220 |
|
(MapCanvas.FitSelectedToWindow): If a single point is selected |
221 |
|
simply center it on the display. Fixes RTBug #1849. |
222 |
|
|
223 |
|
* extensions/thuban/gdalwarp.cpp: Removed code that allowed gdalwarp |
224 |
|
to be compiled as a standalone app. Now the code can only be |
225 |
|
called from Python which simplifies the parameter passing. |
226 |
|
(ProjectRasterFile): Handle Python arguments. Remove code that |
227 |
|
checks for a destination dataset. Add more clean up code. |
228 |
|
|
229 |
|
* test/test_map.py (TestMapWithContents.test_raise_layer_top, |
230 |
|
TestMapWithContents.test_lower_layer_bottom): |
231 |
|
Test Map.MoveLayerToTop() and Map.MoveLayerToBottom() respectively. |
232 |
|
Fixes RTBug #1907. |
233 |
|
|
234 |
|
* Thuban/UI/mainwindow.py (MainWindow.ToggleLegend): Apply a full |
235 |
|
extent to the map when the legend is toggled. Fixes RTBug #1881. |
236 |
|
|
237 |
|
2003-05-29 Jan-Oliver Wagner <[email protected]> |
238 |
|
|
239 |
|
* Thuban/UI/tableview.py (LayerTableFrame.OnClose): Bug-fix: Now |
240 |
|
unsubscribes all that is subcribed in __init__. |
241 |
|
|
242 |
|
2003-05-28 Bernhard Herzog <[email protected]> |
243 |
|
|
244 |
|
* Thuban/UI/mainwindow.py (MainWindow.DuplicateLayer) |
245 |
|
(MainWindow.CanDuplicateLayer): New methods to implement the |
246 |
|
Layer/Duplicate command. |
247 |
|
(layer_duplicate command): New. |
248 |
|
(main_menu): Add layer_duplicate to the Layer menu. |
249 |
|
|
250 |
|
2003-05-28 Bernhard Herzog <[email protected]> |
251 |
|
|
252 |
|
* Thuban/UI/tableview.py (NullRenderer.Draw): New. Our own |
253 |
|
renderer so that NULL/None values get displayed differently (by a |
254 |
|
gray rectangle). |
255 |
|
(TableGrid.__init__): Override the default renderers |
256 |
|
|
257 |
|
2003-05-28 Bernhard Herzog <[email protected]> |
258 |
|
|
259 |
|
* Thuban/Model/layer.py (Layer.SetShapeStore): Set the |
260 |
|
classification to "None" if the type of the field has changed. |
261 |
|
|
262 |
|
* test/test_layer.py (SetShapeStoreTests): New. Class with a few |
263 |
|
test for the Layer.SetShapeStore method |
264 |
|
|
265 |
|
2003-05-28 Jan-Oliver Wagner <[email protected]> |
266 |
|
|
267 |
|
* Thuban/Model/layer.py (Layer.TreeInfo): Fixed a bug (a layer |
268 |
|
does not necessarily have a filename). |
269 |
|
|
270 |
|
2003-05-28 Jan-Oliver Wagner <[email protected]> |
271 |
|
|
272 |
|
* Thuban/UI/mainwindow.py (MainWindow.TableClose, MainWindow.TableShow): |
273 |
|
sort the selection list for the dialog. |
274 |
|
|
275 |
|
2003-05-28 Frank Koormann <[email protected]> |
276 |
|
|
277 |
|
* extensions/thuban/wxproj.cpp |
278 |
|
(project_point): Removed cast to int for projected point coordinates. |
279 |
|
(shape_centroid): Return last point if all polygon vertices fall |
280 |
|
to one point. |
281 |
|
|
282 |
|
2003-05-28 Bernhard Herzog <[email protected]> |
283 |
|
|
284 |
|
* Thuban/UI/mainwindow.py (_can_unjoin): Add doc-string and cope |
285 |
|
with layers that don't have shapestores, i.e. raster layers. |
286 |
|
|
287 |
|
2003-05-28 Bernhard Herzog <[email protected]> |
288 |
|
|
289 |
|
* Thuban/Model/table.py (DBFTable.__init__): Omit the extension |
290 |
|
when determining the title from the filename. |
291 |
|
|
292 |
|
* test/test_dbf_table.py (TestDBFTable.test_title): Update to |
293 |
|
reflect changes in the way the title is derived from the filename |
294 |
|
|
295 |
|
2003-05-28 Frank Koormann <[email protected]> |
296 |
|
|
297 |
|
* Thuban/UI/mainwindow.py (MainWindow.TableShow): |
298 |
|
Added wxDEFAULT_DIALOG_STYLE to show table dialog styles. |
299 |
|
|
300 |
|
2003-05-27 Bernhard Herzog <[email protected]> |
301 |
|
|
302 |
|
* Thuban/UI/mainwindow.py (MainWindow.delegated_messages): Also |
303 |
|
delegate SelectedLayer. |
304 |
|
(MainWindow.LayerUnjoinTable): Implement. |
305 |
|
(_can_unjoin): New. Helper function for the sensitivity of the |
306 |
|
layer/unjoin command. |
307 |
|
|
308 |
|
* Thuban/Model/data.py (ShapefileStore.OrigShapeStore) |
309 |
|
(DerivedShapeStore.OrigShapeStore): New. Return the original |
310 |
|
shapestore. Used to figure out how to unjoin. |
311 |
|
(DerivedShapeStore.Shapefile): Fix a typo. |
312 |
|
|
313 |
|
2003-05-27 Bernhard Herzog <[email protected]> |
314 |
|
|
315 |
|
* Thuban/UI/join.py (JoinDialog): Extend to handle layer joins as |
316 |
|
well |
317 |
|
(JoinDialog.__init__): Use the layer parameter and only build the |
318 |
|
left choice when a layer is given |
319 |
|
(JoinDialog.OnJoin): Handle layer joins as well |
320 |
|
(JoinDialog.OnLeftTable, JoinDialog.OnRightTable): Handle the case |
321 |
|
that the user selects the "Select..." item. The sensitivitly |
322 |
|
updating is now in update_sensitivity |
323 |
|
(JoinDialog.y): New method to refactor the sensitivity update of |
324 |
|
the join button into its own method. |
325 |
|
|
326 |
|
* Thuban/UI/mainwindow.py (MainWindow.LayerJoinTable): Implement. |
327 |
|
|
328 |
|
2003-05-27 Bernhard Herzog <[email protected]> |
329 |
|
|
330 |
|
* Thuban/UI/mainwindow.py (table_close command): Make it sensitive |
331 |
|
iff there are unreferenced tables in the session |
332 |
|
|
333 |
|
2003-05-27 Bernhard Herzog <[email protected]> |
334 |
|
|
335 |
|
* Thuban/Model/messages.py (TABLE_REMOVED): New message. |
336 |
|
|
337 |
|
* Thuban/Model/session.py (Session.UnreferencedTables): New method |
338 |
|
to return tables that are not referenced by other tables or shape |
339 |
|
stores and can be removed. |
340 |
|
(Session.RemoveTable): Issue a TABLE_REMOVED message after |
341 |
|
removing the table |
342 |
|
|
343 |
|
* Thuban/UI/mainwindow.py: Remove unused imports |
344 |
|
(MainWindow.TableClose): Implement. |
345 |
|
|
346 |
|
* Thuban/UI/tableview.py (TableFrame.__init__): Subscribe to some |
347 |
|
messages so that the frame will be automatically closed when a new |
348 |
|
session is opened or the table is removed. |
349 |
|
(TableFrame.OnClose): Unsubscribe the Subscriptions made in |
350 |
|
__init__ |
351 |
|
(TableFrame.close_on_session_replaced) |
352 |
|
(TableFrame.close_on_table_removed): New. Subscribers that close |
353 |
|
the window |
354 |
|
|
355 |
|
* test/test_session.py (TestSessionMessages.test_remove_table) |
356 |
|
(TestSessionSimple.test_remove_table): Move the test to |
357 |
|
TestSessionSimple and add test for the TABLE_REMOVED message |
358 |
|
(TestSessionBase.setUp): Also subscribe to TABLE_REMOVED |
359 |
|
(TestSessionSimple.test_unreferenced_tables) New. Test for the |
360 |
|
UnreferencedTables method. |
361 |
|
(UnreferencedTablesTests): New. Class with some more sophisticated |
362 |
|
tests for UnreferencedTables. |
363 |
|
|
364 |
|
2003-05-27 Frank Koormann <[email protected]> |
365 |
|
|
366 |
|
* Thuban/UI/tableview.py (QueryTableFrame.__init__): The "_S_election" |
367 |
|
display has some unwanted side effects. Removed again. |
368 |
|
|
369 |
|
2003-05-27 Frank Koormann <[email protected]> |
370 |
|
|
371 |
|
* Resources/Bitmaps/legend_icon_layer.xpm: New, icon for legend. |
372 |
|
|
373 |
|
* Thuban/UI/legend.py (LegendTree.__FillTree): Use "legend_icon_layer" |
374 |
|
|
375 |
2003-05-27 Jan-Oliver Wagner <[email protected]> |
2003-05-27 Jan-Oliver Wagner <[email protected]> |
376 |
|
|
377 |
* test/test_menu.py (MenuTest.test): Added test for Menu.RemoveItem(). |
* test/test_menu.py (MenuTest.test): Added test for |
378 |
|
Menu.RemoveItem(). |
379 |
|
|
380 |
* Thuban/UI/menu.py (Menu.RemoveItem): New. Remove an item from the menu. |
* Thuban/UI/menu.py (Menu.RemoveItem): New. Remove an item from |
381 |
|
the menu. |
382 |
|
|
|
* |
|
383 |
2003-05-27 Frank Koormann <[email protected]> |
2003-05-27 Frank Koormann <[email protected]> |
384 |
|
|
385 |
Nonmodal dialogs without parent (i.e. they can fall behind the main |
Nonmodal dialogs without parent (i.e. they can fall behind the main |