1 |
|
2003-03-14 Bernhard Herzog <[email protected]> |
2 |
|
|
3 |
|
* test/test_command.py: Run the tests when the module is run as a |
4 |
|
script |
5 |
|
|
6 |
|
2003-03-14 Bernhard Herzog <[email protected]> |
7 |
|
|
8 |
|
Implement selection of multiple selected shapes in the same layer: |
9 |
|
|
10 |
|
- Introduce a new class to hold the selection. This basically |
11 |
|
replaces the interactor which was nothing more than the |
12 |
|
selection anyway. A major difference is of course that the new |
13 |
|
selection class supports multiple selected shapes in one layer |
14 |
|
|
15 |
|
- Move the object that represents the selection from the |
16 |
|
application to the canvas. The canvas is a better place than the |
17 |
|
application because the selection represents which shapes and |
18 |
|
layer of the map displayed by the canvas are selected and |
19 |
|
affects how the map is drawn. |
20 |
|
|
21 |
|
- Make the selection and its messages publicly available through |
22 |
|
the mainwindow. |
23 |
|
|
24 |
|
- The non-modal dialogs do not get a reference to the interactor |
25 |
|
anymore as they can simply refer to their parent, the |
26 |
|
mainwindow, for the what the interactor had to offer. |
27 |
|
|
28 |
|
* Thuban/UI/selection.py: New module with a class to represent the |
29 |
|
selection. |
30 |
|
|
31 |
|
* Thuban/UI/messages.py (SELECTED_TABLE, SELECTED_MAP): Remove |
32 |
|
these unused messages |
33 |
|
|
34 |
|
* Thuban/UI/application.py (ThubanApplication.OnInit) |
35 |
|
(ThubanApplication.OnExit, ThubanApplication.SetSession): The |
36 |
|
interactor is gone now. |
37 |
|
(ThubanApplication.CreateMainWindow): There is no interactor |
38 |
|
anymore so we pass None as the interactor argument for now for |
39 |
|
compatibility. |
40 |
|
|
41 |
|
* Thuban/UI/view.py (MapCanvas.delegated_messages) |
42 |
|
(MapCanvas.Subscribe, MapCanvas.Unsubscribe): In Subscribe and |
43 |
|
Unsubscribe, delegate messages according to the delegated_messages |
44 |
|
class variable. |
45 |
|
(MapCanvas.__getattr__, MapCanvas.delegated_methods): Get some |
46 |
|
attributes from instance variables as described with the |
47 |
|
delegated_methods class variable. |
48 |
|
(MapCanvas.__init__): New instance variable selection holding the |
49 |
|
current selection |
50 |
|
(MapCanvas.do_redraw): Deal with multiple selected shapes. Simply |
51 |
|
pass them on to the renderer |
52 |
|
(MapCanvas.SetMap): Clear the selection when a different map is |
53 |
|
selected. |
54 |
|
(MapCanvas.shape_selected): Simple force a complete redraw. The |
55 |
|
selection class now takes care of only issueing SHAPES_SELECTED |
56 |
|
messages when the set of selected shapes actually does change. |
57 |
|
(MapCanvas.SelectShapeAt): The selection is now managed in |
58 |
|
self.selection |
59 |
|
|
60 |
|
* Thuban/UI/mainwindow.py (MainWindow.delegated_messages) |
61 |
|
(MainWindow.Subscribe, MainWindow.Unsubscribe): In Subscribe and |
62 |
|
Unsubscribe, delegate messages according to the delegated_messages |
63 |
|
class variable. |
64 |
|
(MainWindow.delegated_methods, MainWindow.__getattr__): Get some |
65 |
|
attributes from instance variables as described with the |
66 |
|
delegated_methods class variable. |
67 |
|
(MainWindow.__init__): The interactor as ivar is gone. The |
68 |
|
parameter is still there for compatibility. The selection messages |
69 |
|
now come from the canvas. |
70 |
|
(MainWindow.current_layer, MainWindow.has_selected_layer): |
71 |
|
Delegate to the the canvas. |
72 |
|
(MainWindow.LayerShowTable, MainWindow.Classify) |
73 |
|
(MainWindow.identify_view_on_demand): The dialogs don't need the |
74 |
|
interactor parameter anymore. |
75 |
|
|
76 |
|
* Thuban/UI/tableview.py (TableFrame.__init__) |
77 |
|
(LayerTableFrame.__init__, LayerTableFrame.OnClose) |
78 |
|
(LayerTableFrame.row_selected): The interactor is gone. It's job |
79 |
|
from the dialog's point of view is now done by the mainwindow, |
80 |
|
i.e. the parent. Subscribe to SHAPES_SELECTED instead |
81 |
|
of SELECTED_SHAPE |
82 |
|
|
83 |
|
* Thuban/UI/dialogs.py (NonModalDialog.__init__): The interactor |
84 |
|
is gone. It's job from the dialog's point of view is now done by |
85 |
|
the mainwindow, i.e. the parent. |
86 |
|
|
87 |
|
* Thuban/UI/classifier.py (Classifier.__init__): The interactor is |
88 |
|
gone. It's job from the dialog's point of view is now done by the |
89 |
|
mainwindow, i.e. the parent. |
90 |
|
|
91 |
|
* Thuban/UI/tree.py (SessionTreeView.__init__): The interactor is |
92 |
|
gone. It's job from the dialog's point of view is now done by the |
93 |
|
mainwindow, i.e. the parent. |
94 |
|
(SessionTreeCtrl.__init__): New parameter mainwindow which is |
95 |
|
stored as self.mainwindow. The mainwindow is need so that the tree |
96 |
|
can still subscribe to the selection messages. |
97 |
|
(SessionTreeCtrl.__init__, SessionTreeCtrl.unsubscribe_all) |
98 |
|
(SessionTreeCtrl.update_tree, SessionTreeCtrl.OnSelChanged): The |
99 |
|
selection is now accessible through the mainwindow. Subscribe to |
100 |
|
SHAPES_SELECTED instead of SELECTED_SHAPE |
101 |
|
|
102 |
|
* Thuban/UI/identifyview.py (IdentifyView.__init__): Use the |
103 |
|
SHAPES_SELECTED message now. |
104 |
|
(IdentifyView.selected_shape): Now subscribed to SHAPES_SELECTED, |
105 |
|
so deal with multiple shapes |
106 |
|
(IdentifyView.__init__, IdentifyView.OnClose): The interactor is |
107 |
|
gone. It's job from the dialog's point of view is now done by the |
108 |
|
mainwindow, i.e. the parent. |
109 |
|
|
110 |
|
* Thuban/UI/controls.py (RecordListCtrl.fill_list): The second |
111 |
|
parameter is now a list of shape ids. |
112 |
|
(RecordTable.SetTable): The second parameter is now a list of |
113 |
|
indices. |
114 |
|
|
115 |
|
* Thuban/UI/renderer.py (ScreenRenderer.RenderMap): Rename the |
116 |
|
selected_shape parameter and ivar to selected_shapes. It's now a |
117 |
|
list of shape ids. |
118 |
|
(MapRenderer.draw_label_layer): Deal with multiple selected |
119 |
|
shapes. Rearrange the code a bit so that the setup and shape type |
120 |
|
distinctions are only executed once. |
121 |
|
|
122 |
|
* test/test_selection.py: Test cases for the selection class |
123 |
|
|
124 |
|
2003-03-11 Jonathan Coles <[email protected]> |
125 |
|
|
126 |
|
* Thuban/Model/load.py: Temporary fix so that the xml reader |
127 |
|
doesn't cause Thuban to crash. |
128 |
|
|
129 |
|
* Thuban/Model/layer.py: Handle the cyclic references between |
130 |
|
a layer and its classification better, and be sure to disconnect |
131 |
|
the classification from the layer when the layer is destroyed |
132 |
|
so that we don't maintain a cyclic reference that may not be |
133 |
|
garbage collected. |
134 |
|
|
135 |
|
* Thuban/Model/classification.py: See comment for layer.py. |
136 |
|
|
137 |
|
2003-03-12 Jan-Oliver Wagner <[email protected]> |
138 |
|
|
139 |
|
* HOWTO-Release: New. Information on the steps for releasing |
140 |
|
a new version of Thuban. |
141 |
|
|
142 |
|
2003-03-11 Jonathan Coles <[email protected]> |
143 |
|
|
144 |
|
* Thuban/UI/classifier.py: Add normal border to SelectPropertiesDialog. |
145 |
|
Use True instead of true. |
146 |
|
(Classifier): Should have a single panel in which all the controls lie. |
147 |
|
|
148 |
|
* Thuban/UI/proj4dialog.py: Add normal border. |
149 |
|
|
150 |
|
* Thuban/UI/tree.py: Fixed problem with bad item images under Windows. |
151 |
|
|
152 |
|
* Thuban/UI/mainwindow.py: Use True instead of true. |
153 |
|
|
154 |
|
* setup.py: Update some definitions to use wxWindows2.4 files |
155 |
|
|
156 |
|
* Data/iceland_sample_class.thuban: Fixed file so that the |
157 |
|
field_type information is present. |
158 |
|
|
159 |
|
2003-03-10 Jonathan Coles <[email protected]> |
160 |
|
|
161 |
|
* Thuban/UI/classifier.py (Classifier.__init__): Make the |
162 |
|
field type label grow so that when the text changes the |
163 |
|
size is updated correctly. This may be a wxWindows bug. |
164 |
|
|
165 |
|
2003-03-10 Jonathan Coles <[email protected]> |
166 |
|
|
167 |
|
* Thuban/UI/application.py: Changed SESSION_CHANGED to |
168 |
|
SESSION_REPLACED. |
169 |
|
|
170 |
|
* Thuban/UI/classifier.py: Wrap text with _(). |
171 |
|
(ClassGrid.CreateTable): Set dimensions and size hints here, |
172 |
|
instead of in Reset, so we only set the size once. |
173 |
|
|
174 |
|
* Thuban/UI/dialogs.py: Don't need Shutdown(); just use Close()! |
175 |
|
|
176 |
|
* Thuban/UI/mainwindow.py (MainWindow.prepare_new_session): |
177 |
|
Call Close() instead of Shutdown(). |
178 |
|
|
179 |
|
* Thuban/UI/messages.py: Changed SESSION_CHANGED to SESSION_REPLACED. |
180 |
|
|
181 |
|
* Thuban/UI/tree.py: Changed SESSION_CHANGED to SESSION_REPLACED. |
182 |
|
Go back to using OnClose() instead of Shutdown(). |
183 |
|
|
184 |
|
2003-03-10 Jonathan Coles <[email protected]> |
185 |
|
|
186 |
|
* Thuban/UI/classifier.py (Classifier): SelectField() needed |
187 |
|
to know the old field index as well as the new one. |
188 |
|
|
189 |
|
2003-03-10 Jonathan Coles <[email protected]> |
190 |
|
|
191 |
|
* Thuban/UI/classifier.py (Classifier): Use __SelectField() |
192 |
|
to correctly set the table information and call this from |
193 |
|
__init__ and from _OnFieldSelect so that all the information |
194 |
|
is up to date when the dialog opens and when a field is changed. |
195 |
|
|
196 |
|
2003-03-10 Jonathan Coles <[email protected]> |
197 |
|
|
198 |
|
* Thuban/Model/classification.py (Classification): Don't use |
199 |
|
layer's message function directly, use the ClassChanged() method |
200 |
|
when then classification changes. SetField/SetFieldType/SetLayer |
201 |
|
must keep the information about field name and field type in |
202 |
|
sync when an owning layer is set or removed. |
203 |
|
|
204 |
|
* Thuban/Model/layer.py: Added ClassChanged() so that the |
205 |
|
classification can tell the layer when its data has changed. |
206 |
|
(Layer.SetClassification): Accepts None as an arguement to |
207 |
|
remove the current classification and correctly handles |
208 |
|
adding a new classification. |
209 |
|
|
210 |
|
* Thuban/Model/load.py: Comment out print statement |
211 |
|
|
212 |
|
* test/test_classification.py, test/test_save.py: New and |
213 |
|
improved tests. |
214 |
|
|
215 |
|
2003-03-07 Jonathan Coles <[email protected]> |
216 |
|
|
217 |
|
* Thuban/Model/classification.py: Implemented __copy__ and |
218 |
|
__deepcopy__ for ClassGroup* and ClassGroupProperites so |
219 |
|
they can easily be copied by the classifier dialog. |
220 |
|
(ClassGroupProperites.__init__): The default line color should |
221 |
|
have been Color.Black. |
222 |
|
|
223 |
|
* Thuban/UI/classifier.py: Setting and Getting table values now |
224 |
|
uses a consistent set of functions. |
225 |
|
(Classifier): Now non-modal. Has field type label which changes |
226 |
|
as the field changes. Keep track of buttons in a list so that |
227 |
|
we can enable/disable the buttons when the None field is selected. |
228 |
|
(SelectPropertiesDialog): Add buttons to make the colors transparent. |
229 |
|
|
230 |
|
* Thuban/UI/dialogs.py (NonModalDialog.Shutdown): New method which |
231 |
|
does what OnClose did, but can be called by the application to |
232 |
|
close a window. Needed when a session changes, and we have to |
233 |
|
close the classifier windows. |
234 |
|
|
235 |
|
* Thuban/UI/mainwindow.py (MainWindow.prepare_new_session): |
236 |
|
Shuts down open dialogs. Used when a new session is created |
237 |
|
or a session is opened. |
238 |
|
(MainWindow.SaveSession): Should only call application.SaveSession() |
239 |
|
if we don't call SaveSessionAs first. |
240 |
|
(MainWindow.Classify): Allow different classifier dialogs for |
241 |
|
different layers. |
242 |
|
|
243 |
|
* Thuban/UI/tree.py (SessionTreeView): Remove OnClose and let |
244 |
|
the parent class handle it. Add Shutdown() to unsubscibe from |
245 |
|
event notification and call the parent Shutdown(). This was |
246 |
|
necessary so the application can close the tree window. |
247 |
|
|
248 |
2003-03-06 Jonathan Coles <[email protected]> |
2003-03-06 Jonathan Coles <[email protected]> |
249 |
|
|
250 |
* Thuban/Model/classification.py: Minor documentation changes, |
* Thuban/Model/classification.py: Minor documentation changes, |