/[thuban]/branches/greater-ms3/thuban/ChangeLog
ViewVC logotype

Contents of /branches/greater-ms3/thuban/ChangeLog

Parent Directory Parent Directory | Revision Log Revision Log


Revision 514 - (show annotations)
Tue Mar 11 16:44:44 2003 UTC (21 years, 11 months ago) by jonathan
Original Path: trunk/thuban/ChangeLog
File size: 64130 byte(s)
updated ChangeLog

1 2003-03-11 Jonathan Coles <[email protected]>
2
3 * Thuban/UI/classifier.py: Add normal border to SelectPropertiesDialog.
4 Use True instead of true.
5 (Classifier): Should have a single panel in which all the controls lie.
6
7 * Thuban/UI/proj4dialog.py: Add normal border.
8
9 * Thuban/UI/tree.py: Fixed problem with bad item images under Windows.
10
11 * Thuban/UI/mainwindow.py: Use True instead of true.
12
13 * setup.py: Update some definitions to use wxWindows2.4 files
14
15 * Data/iceland_sample_class.thuban: Fixed file so that the
16 field_type information is present.
17
18 2003-03-10 Jonathan Coles <[email protected]>
19
20 * Thuban/UI/classifier.py (Classifier.__init__): Make the
21 field type label grow so that when the text changes the
22 size is updated correctly. This may be a wxWindows bug.
23
24 2003-03-10 Jonathan Coles <[email protected]>
25
26 * Thuban/UI/application.py: Changed SESSION_CHANGED to
27 SESSION_REPLACED.
28
29 * Thuban/UI/classifier.py: Wrap text with _().
30 (ClassGrid.CreateTable): Set dimensions and size hints here,
31 instead of in Reset, so we only set the size once.
32
33 * Thuban/UI/dialogs.py: Don't need Shutdown(); just use Close()!
34
35 * Thuban/UI/mainwindow.py (MainWindow.prepare_new_session):
36 Call Close() instead of Shutdown().
37
38 * Thuban/UI/messages.py: Changed SESSION_CHANGED to SESSION_REPLACED.
39
40 * Thuban/UI/tree.py: Changed SESSION_CHANGED to SESSION_REPLACED.
41 Go back to using OnClose() instead of Shutdown().
42
43 2003-03-10 Jonathan Coles <[email protected]>
44
45 * Thuban/UI/classifier.py (Classifier): SelectField() needed
46 to know the old field index as well as the new one.
47
48 2003-03-10 Jonathan Coles <[email protected]>
49
50 * Thuban/UI/classifier.py (Classifier): Use __SelectField()
51 to correctly set the table information and call this from
52 __init__ and from _OnFieldSelect so that all the information
53 is up to date when the dialog opens and when a field is changed.
54
55 2003-03-10 Jonathan Coles <[email protected]>
56
57 * Thuban/Model/classification.py (Classification): Don't use
58 layer's message function directly, use the ClassChanged() method
59 when then classification changes. SetField/SetFieldType/SetLayer
60 must keep the information about field name and field type in
61 sync when an owning layer is set or removed.
62
63 * Thuban/Model/layer.py: Added ClassChanged() so that the
64 classification can tell the layer when its data has changed.
65 (Layer.SetClassification): Accepts None as an arguement to
66 remove the current classification and correctly handles
67 adding a new classification.
68
69 * Thuban/Model/load.py: Comment out print statement
70
71 * test/test_classification.py, test/test_save.py: New and
72 improved tests.
73
74 2003-03-07 Jonathan Coles <[email protected]>
75
76 * Thuban/Model/classification.py: Implemented __copy__ and
77 __deepcopy__ for ClassGroup* and ClassGroupProperites so
78 they can easily be copied by the classifier dialog.
79 (ClassGroupProperites.__init__): The default line color should
80 have been Color.Black.
81
82 * Thuban/UI/classifier.py: Setting and Getting table values now
83 uses a consistent set of functions.
84 (Classifier): Now non-modal. Has field type label which changes
85 as the field changes. Keep track of buttons in a list so that
86 we can enable/disable the buttons when the None field is selected.
87 (SelectPropertiesDialog): Add buttons to make the colors transparent.
88
89 * Thuban/UI/dialogs.py (NonModalDialog.Shutdown): New method which
90 does what OnClose did, but can be called by the application to
91 close a window. Needed when a session changes, and we have to
92 close the classifier windows.
93
94 * Thuban/UI/mainwindow.py (MainWindow.prepare_new_session):
95 Shuts down open dialogs. Used when a new session is created
96 or a session is opened.
97 (MainWindow.SaveSession): Should only call application.SaveSession()
98 if we don't call SaveSessionAs first.
99 (MainWindow.Classify): Allow different classifier dialogs for
100 different layers.
101
102 * Thuban/UI/tree.py (SessionTreeView): Remove OnClose and let
103 the parent class handle it. Add Shutdown() to unsubscibe from
104 event notification and call the parent Shutdown(). This was
105 necessary so the application can close the tree window.
106
107 2003-03-06 Jonathan Coles <[email protected]>
108
109 * Thuban/Model/classification.py: Minor documentation changes,
110 Addition of __eq__ and __ne__ methods.
111 (Classification.SetLayer): prevent recursion between this method
112 and Layer.SetClassification().
113
114 * Thuban/Model/color.py: Addition of __eq__ and __ne__ methods.
115
116 * Thuban/Model/layer.py (SetClassification): prevent recursion
117 between this method and Classification.SetLayer().
118
119 * test/test_classification.py, test/test_load.py,
120 test/test_session.py: Fixed and added tests for the classification
121 classes.
122
123 2003-03-06 Bernhard Herzog <[email protected]>
124
125 * Thuban/UI/classifier.py (ClassGrid.__init__)
126 (ClassGrid.CreateTable): Move the SetSelectionMode call to
127 CreateTable because otherwise it triggers an assertion in
128 wxPython/wxGTK 2.4.
129
130 2003-03-05 Jonathan Coles <[email protected]>
131
132 * Thuban/common.py: Move FIELDTYPE constants back to table.py.
133
134 * Thuban/Model/load.py: import FIELDTYPE constants from table.
135
136 * Thuban/UI/classifier.py: import FIELDTYPE constants from table.
137
138 * Thuban/Model/table.py: Put FIELDTYPE constants back.
139
140 2003-03-05 Jonathan Coles <[email protected]>
141
142 * Thuban/UI/classifier.py: Added class documentation.
143 Fixed RTbug #1713, #1714. Added Move[Up|Down] buttons.
144 Store just the groups in the table and generate the other
145 column information when it is requested. Add "None" field
146 to pull-down to select no classification.
147
148 * Thuban/common.py: Moved FIELDTYPE constants from table.py
149 (Str2Num): Only catch ValueError exceptions.
150
151 * Thuban/Model/classification.py: Class documentation. Renaming
152 of methods with Stroke to Line. Groups are stored in a single
153 list with the default as the first element. Groups are searched
154 in the order they appear in the list.
155
156 * Thuban/Model/color.py: Documentation.
157
158 * Thuban/Model/layer.py (Layer): Add GetFieldType to retreive
159 the kind of data represented by a field.
160
161 * Thuban/Model/load.py (ProcessSession): Use proper string
162 conversion function; fixes RTbug #1713.
163
164 * Thuban/Model/save.py (Saver): Store field type information.
165
166 * Thuban/Model/table.py: Put FIELDTYPE constants in common.py.
167 (Table): Add field_info_by_name() to retrieve field information
168 by specifying the field name, not the number.
169
170 * Thuban/UI/mainwindow.py: Function name changes.
171
172 * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Only
173 get the layer classification once. Don't try to classify
174 values when the field is None: just use the default properties.
175
176 * Thuban/UI/view.py: Function name changes.
177
178 * Doc/thuban.dtd: Add field_type attribute to a classification.
179
180 2003-03-04 Bernhard Herzog <[email protected]>
181
182 * Doc/thuban.dtd: Use correct syntax for optional attributes. Make
183 the fill and stroke layer attributes optional with suitable
184 default values. Add the stroke_width layer attribute. Use correct
185 syntax for empty elements. Make the attribute list for labels
186 refer to the label element.
187
188 2003-03-04 Bernhard Herzog <[email protected]>
189
190 * setup.py (thuban_build_py.build): Add a comment about distutils in
191 Python 2.3 containing some of the functionality we implement in
192 setup.py ourselves.
193
194 * Thuban/UI/classifier.py (ClassGrid.__init__): Set the table
195 before the selection mode. Doing it the other way round triggers
196 an assertion in wxWindows.
197
198 * Thuban/Model/save.py (escape): Fix typo in doc-string
199
200 * Thuban/Model/classification.py: Remove unnecessary wxPython
201 import
202
203 2003-03-04 Jonathan Coles <[email protected]>
204
205 * Thuban/Model/classification.py (ClassGroupRange.GetProperties):
206 Parameter 'value' should default to None.
207
208 * Thuban/UI/mainwindow.py: Use Layer.GetClassification() since
209 the class attribute __classification is now private.
210
211 * Thuban/UI/classifier.py (ClassGrid): Moved OnCellDClick() from
212 Classifier to ClassGrid. Added support for removing selected rows,
213 which including code for keeping track of when cells are selected,
214 and deselected.
215 (ClassTable): Support for added/removing rows. Fixed a problem
216 with __ParseInput whereby it would not allow strings (only numbers)
217 to be entered.
218 (Classifier): Added button and supporting code for removing
219 selected rows.
220
221 2003-02-27 Jonathan Coles <[email protected]>
222
223 * Thuban/common.py: Moved color conversion functions into
224 Thuban/UI/common.py.
225 (Str2Num): Now converts the float (not the string) to a long/int
226 so that an exception isn't thrown.
227
228 * Thuban/UI/common.py: Common functions used in several UI modules
229
230 * Thuban/Model/classification.py: Changed the class hierarchy
231 so that a Classification consists of Groups which return
232 Properties when a value matches a Group.
233
234 * Thuban/Model/layer.py: Fixed name resolution problem.
235
236 * Thuban/Model/load.py: Use new Classification and Group functions.
237
238 * Thuban/Model/save.py (Saver.write_attribs): Fixes a test case
239 failure.
240 (Saver.write_classification): Use new Classification and Group
241 functions.
242
243 * Thuban/UI/classifier.py: Changes to use new Classification and Group
244 functions. Fix to create a tuple with a single value instead of
245 simply returning the value.
246
247 * Thuban/UI/renderer.py: Use new Classification and Group functions.
248 Use common.py functions.
249
250 * Thuban/UI/tree.py: Use common.py functions.
251
252 * test/test_classification.py: Use new Classification and Group
253 classes.
254
255 2003-02-24 Jonathan Coles <[email protected]>
256
257 * Thuban/common.py (Color2wxColour, wxColour2Color): Conversion
258 functions from Thuban color objects to wxWindow colour objects.
259
260 * Thuban/Model/classification.py (Classification): Renamed
261 GetProperties() to GetClassData(). Used the new iterator
262 in TreeInfo().
263 (ClassIterator): Iterator implementation to iterate over the
264 ClassData objects in a classification object.
265
266 * Thuban/Model/save.py (Saver.write_classificaton): Uses
267 the new iterator to save the classification information.
268
269 * Thuban/UI/classifier.py (SelectPropertiesDialog): Support
270 for changing the stroke and fill colors and previewing the
271 changes.
272
273 * Thuban/UI/mainwindow.py (MainWindow.OpenSession,
274 MainWindow.SaveSessionAs): Text string changes so the dialogs
275 have more meaningful titles.
276
277 * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Change
278 Classification method name from GetProperties to GetClassData.
279
280 * Thuban/UI/view.py (MapCanvas.find_shape_at): Use method calls
281 instead of accessing now non-existent class variables.
282
283 2003-02-24 Bernhard Herzog <[email protected]>
284
285 * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Remove
286 unneeded Shape() call. Rendering is substantially faster without
287 it and it avoids some problems with broken shape files.
288
289 2003-02-20 Frank Koormann <[email protected]>
290
291 Force minimal size of identify and label dialogs. The autosizing
292 looked too ugly.
293
294 * Thuban/UI/controls.py (RecordListCtrl): Set minimal width for columns.
295 * Thuban/UI/labeldialog.py (LabelDialog.dialog_layout):
296 Set size of listctrl.
297 * Thuban/UI/identifyview.py (IdentifyView.__init__):
298 Set size of dialog.
299
300 2003-02-19 Jonathan Coles <[email protected]>
301
302 * test/test_classification.py, test/test_layer.py,
303 test/test_load.py, test/test_map.py, test/test_session.py:
304 Updated the tests to use the new functions that are in the
305 respective classes.
306
307 * Thuban/Model/classification.py (Classification):
308 Uses the new ClassData* classes. Modification messages are
309 passed up to the parent layer (if it exists).
310 (ClassData): New class to encapsulate the common data in each
311 classification property.
312 (ClassDataDefault): Represents the Default class. data.
313 (ClassDataPoint): Represents a single class. data point
314 (ClassDataRange): Represents a class. range
315 (ClassDataMap): Represents a class. map (unused).
316
317 * Thuban/Model/color.py: Added Color.None to represent something
318 with no color. Color.Black represents the color black.
319 (NoColor): Helper class derived from Color to represent something
320 with no color.
321
322 * Thuban/Model/layer.py (Layer): Removed references to fill, stroke,
323 stroke_width attributes. Made the 'classification' attribute private.
324 New methods for setting/getting the classification.
325
326 * Thuban/Model/load.py (ProcessSession): Use new methods on Layer
327 to get the classifcation and use the new ClassData* classes to
328 hold the classification data. Use Str2Num to convert numbers
329 properly.
330
331 * Thuban/Model/save.py (Saver): Use new Color and Classification
332 methods
333
334 * Thuban/UI/classifier.py (ClassGrid): New class to represent a
335 custom grid.
336 (ClassTable): Support for editing Values and Labels and for
337 changing what type (point or range) of data is stored in each
338 property based on how the user enters the data.
339 (Classifier): Support for saving the new classifications and
340 launching the dialog to edit a property.
341 (SelectPropertiesDialog): New class for editing the visual
342 properties of a classification (stroke color, width, and fill color)
343 (ClassPreviewer): Took the Draw method from ClassRenderer and
344 made most of it into this new class. Intend to use this class in
345 the SelectPropertiesDialog for previewing changes.
346
347 * Thuban/UI/renderer.py: Use new Color and Classification methods.
348
349 * Thuban/UI/tree.py: Formatting changes.
350
351 * Doc/thuban.dtd: Add 'label' element
352
353 * Thuban/common.py: New. Contains common routines used throughout
354 the code.
355 (Str2Num): Takes a string and converts it to the "best" type of
356 number.
357
358 2003-02-14 Bernhard Herzog <[email protected]>
359
360 * Thuban/UI/view.py (MapCanvas.OnLeftUp): Make sure that the
361 dragging flag is always set to 0 even when the tool implementation
362 raises an exception
363
364 2003-02-11 Bernhard Herzog <[email protected]>
365
366 * Thuban/UI/application.py (ThubanApplication.splash_screen): New
367 method to create a splash screen.
368 (ThubanApplication.ShowMainWindow): New. Show the main window.
369 Needed so the splash screen can display the mainwindow
370 (ThubanApplication.OnInit): Call the
371 new splash_screen method to determine whether the application
372 should display a splash screen. If it displays a splash screen do
373 not immediately show the main window.
374
375 2003-02-11 Jonathan Coles <[email protected]>
376
377 * Thuban/Model/classification.py: Added import line to fix
378 feature conflicts between running on python2.2 and python2.1.
379
380 * Thuban/UI/classifier.py (ClassTable): Didn't need to hang
381 onto the clinfo parameter, so removed the deepcopy().
382
383 2003-02-10 Jonathan Coles <[email protected]>
384
385 * Thuban/Model/save.py (Saver.open_element, Saver.close_element):
386 Added element_open variable to track opening and closing of tags
387 so that tags that don't span more than one line are closed with
388 /> instead of </tag_name>. Use the GetDefault*() methods of
389 the Classification class.
390
391 * Thuban/Model/classification.py (Classificaton): Added set and
392 get methods for the default data. The class also takes a layer
393 reference so that modification messages can be sent. Fixed the
394 methods to use the new ClassData class.
395 (ClassData): New class to encapsulate the classification data
396
397 * Thuban/Model/layer.py (Layer): Remove the
398 Set[Fill|Stroke|StrokeWidth]() methods. Code should call the
399 SetDefault*() methods on the layer's classification object.
400 (Layer.__init__): Use the new SetDefault*() methods in the
401 Classification class.
402
403 * Thuban/Model/load.py (ProcessSession): Use the new ClassData
404 object instead of a dictionary.
405
406 * Thuban/UI/classifier.py (ClassRenderer): New class to
407 draw the classifications in the dialog box's table.
408 (Classifier): Modified to use the ClassRenderer class.
409
410 * Thuban/UI/mainwindow.py (MainWindow): Use the SetDefault*()
411 methods of the Classification class.
412
413 * Thuban/UI/renderer.py (MapRenderer): Use the Get*() methods
414 of the ClassData class.
415
416 * test/test_classification.py, test/test_layer.py,
417 test/test_map.py, test/test_session.py: Fix the tests to work
418 with the above code changes.
419
420 2003-02-03 Jonathan Coles <[email protected]>
421
422 * Thuban/Model/classification.py (Classification): Added getNull()
423 to return the NullData reference
424
425 * Thuban/Model/layer.py (Layer.SetFill, Layer.SetStroke,
426 Layer.SetStrokeWidth): Modified these functions to change the
427 null data in the classification rather than keep these values
428 directly in the Layer class. Menu options to change these values
429 work again.
430
431 2003-01-28 Jonathan Coles <[email protected]>
432
433 * Thuban/UI/classifier.py (Classifier): Resolved merging conflicts.
434 Fixed crashing problem on some systems. Dialog box shows
435 classification data.
436
437 * Thuban/UI/tree.py (SessionTreeCtrl.add_items): Handle drawing
438 Colors in the tree view.
439
440 * Thuban/Model/layer.py (Layer.TreeInfo): Added a call to build
441 the tree info for classifications. Commented out unnecessary lines.
442
443 * Thuban/Model/classification.py (Classification.TreeInfo): New
444 function to add information about the classification into the
445 tree view.
446
447 2003-01-27 Jan-Oliver Wagner <[email protected]>
448
449 * Thuban/__init__.py (_): New.
450
451 * Thuban/Model/classification.py, Thuban/Model/extension.py,
452 Thuban/Model/layer.py, Thuban/Model/load.py, Thuban/Model/map.py,
453 Thuban/Model/session.py, Thuban/UI/application.py,
454 Thuban/UI/classifier.py, Thuban/UI/context.py, Thuban/UI/controls.py,
455 Thuban/UI/identifyview.py, Thuban/UI/labeldialog.py,
456 Thuban/UI/mainwindow.py, Thuban/UI/menu.py, Thuban/UI/proj4dialog.py,
457 Thuban/UI/renderer.py, Thuban/UI/tree.py, Thuban/Lib/connector.py,
458 Thuban/Lib/fileutil.py: Replace user string by _() for i18n.
459
460 2003-01-27 Jonathan Coles <[email protected]>
461
462 * Thuban/Model/layer.py: Classification initialization calls.
463
464 * Thuban/Model/classification.py: Created class to encapsulate
465 a layer classification. Supports specific data points and
466 ranges.
467
468 * Thuban/Model/load.py: Added support for loading classification
469 information.
470
471 * Thuban/Model/save.py: Added support for saving classification
472 information.
473
474 * Thuban/UI/classifier.py: Initial class for a dialog box for
475 specifying classification information.
476
477 * Thuban/UI/mainwindows.py: Support for opening the classifier
478 dialog.
479
480 * Thuban/UI/renderer.py: Support for drawing a layer with the
481 classification information.
482
483 * Data/iceland_sample_class.thuban: iceland_sample with
484 classification data.
485
486 * test/test_classification: Tests for the Classification class.
487
488 2002-12-09 Bernhard Herzog <[email protected]>
489
490 * test/test_command.py: New. Tests for the command classes.
491
492 * Thuban/UI/command.py (ToolCommand): New class for tool commands.
493 (Command.IsTool): New method to distinguish between command
494 switching tools and other commands.
495
496 * Thuban/UI/view.py (MapCanvas.SelectTool): New method to select
497 the tool to avoid direct assignments to instance variables
498 (MapCanvas.ZoomInTool, MapCanvas.ZoomOutTool, MapCanvas.PanTool)
499 (MapCanvas.IdentifyTool, MapCanvas.LabelTool): Use SelectTool to
500 change the tool
501
502 * Thuban/UI/mainwindow.py (MainWindow.update_command_ui): If an
503 active tool's command turns insensitive, disable the tool.
504 (_tool_command): Use the new ToolCommand class
505
506 * Examples/simple_extensions/simple_tool.py (simple_tool): Use the
507 SelectTool method to change the tool
508 (iconfile): Use the ToolCommand class
509
510 2002-12-03 Bernhard Herzog <[email protected]>
511
512 * Thuban/UI/tree.py (SessionTreeCtrl.normalize_selection): Handle
513 the case of selected items that are not children of Layers or Maps
514 properly. Previously this bug would trigger an assertion in
515 wxWindows.
516
517 2002-11-06 Frank Koormann <[email protected]>
518
519 * Thuban/UI/mainwindow.py: Altered the order of tools in the
520 toolbar: First now are all navigation tools (Zoom In/Out, Pan,
521 Full Extent).
522
523 2002-10-23 Bernhard Herzog <[email protected]>
524
525 * setup.py (setup call): version now 0.1.3
526
527 * MANIFEST.in: Add the files in test/
528
529 * test/README: Add note about tests requiring the iceland data
530
531 * Thuban/UI/mainwindow.py (MainWindow.About): Add 2002 to
532 copyright notice.
533
534 2002-10-18 Bernhard Herzog <[email protected]>
535
536 * test/test_map.py
537 (TestMapWithContents.test_projected_bounding_box): Use an explicit
538 epsilon.
539
540 * test/support.py (FloatComparisonMixin.assertFloatEqual)
541 (FloatComparisonMixin.assertFloatSeqEqual): give a more useful
542 message if the assertion fails and don't return the return value
543 of self.assert_. In assertFloatSeqEqual the return meant that not
544 all items of the sequence were compared.
545
546 2002-09-20 Bernhard Herzog <[email protected]>
547
548 * test/test_fileutil.py: New. Test cases for Thuban.Lib.fileutil
549
550 * Thuban/Lib/fileutil.py: Fixup some whitespace and typos
551
552 * test/test_map.py (TestMapWithContents.test_tree_info): Create
553 the string with the bounding box on the fly because of platform
554 differences in the way %g is handled.
555
556 * test/test_layer.py (TestLayer.test_empty_layer): Create an empty
557 DBFfile too because Thuban layers can't yet cope missing DBF
558 files.
559
560 2002-09-20 Bernhard Herzog <[email protected]>
561
562 * test/test_menu.py: Use initthuban instead of
563 add_thuban_dir_to_path to initialize Thuban.
564
565 * test/support.py (FloatComparisonMixin.assertFloatEqual): New.
566 Mixin class for float comparisons
567 (SubscriberMixin): New. Mixin class to test messages sent through
568 the Connector class
569
570 * test/README: Fix a typo and add the -v flag to the command for
571 individual tests
572
573 * test/test_session.py: New. Test cases for Thuban.Model.session
574
575 * test/test_proj.py: New. Test cases for Thuban.Model.proj
576
577 * test/test_map.py: New. Test cases for Thuban.Model.map
578
579 * test/test_layer.py: New. Test cases for Thuban.Model.layer
580
581 * test/test_label.py: New. Test cases for Thuban.Model.label
582
583 * test/test_connector.py: New. Test cases for Thuban.Lib.connector
584
585 * test/test_color.py: New. Test cases for Thuban.Model.color
586
587 * test/test_base.py: New. Test cases for Thuban.Model.base
588
589 2002-09-13 Bernhard Herzog <[email protected]>
590
591 * Thuban/Model/session.py (Session.forwarded_channels): Forward
592 the CHANGED channel too.
593
594 * Thuban/Model/map.py (Map.forwarded_channels): Forward the
595 CHANGED channel too.
596 (Map.__init__): Call the Modifiable constructor as well.
597
598 * Thuban/Model/base.py (Modifiable.UnsetModified): Issue a CHANGED
599 event if the modified flag changes.
600 (Modifiable.changed): Tweak the doc-string.
601
602 * Thuban/UI/mainwindow.py (MainWindow.view_position_changed)
603 (MainWindow.set_position_text): Put the code that puts the text
604 with the mouse position into the status bar into the new method
605 set_position_text so that it can overwritten in derived classes.
606
607 2002-09-12 Bernhard Herzog <[email protected]>
608
609 * Thuban/UI/mainwindow.py (MainWindow.RunMessageBox): Center the
610 message box on the main window.
611
612 2002-09-11 Bernhard Herzog <[email protected]>
613
614 * Thuban/UI/mainwindow.py: Underline the 'x' in "Exit" instead of
615 the 'E' because it's less likely to interfere with other menu
616 entries.
617 (MainWindow.build_menu): remove an incorrect comment.
618
619 2002-09-10 Bernhard Herzog <[email protected]>
620
621 * Thuban/UI/mainwindow.py (MainWindow.Map): New.
622 (_tool_command): Add sensitive parameter
623 (_has_visible_map): Sensitivity callback to tools and other
624 commands that require a visible map. Use it in map_zoom_in_tool,
625 map_zoom_out_tool, map_pan_tool, map_identify_tool, map_label_tool
626 and map_full_extent
627
628 2002-09-06 Bernhard Herzog <[email protected]>
629
630 * Thuban/UI/mainwindow.py (MainWindow.OnClose): Unsubscribe
631 VIEW_POSITION
632
633 2002-09-04 Frank Koormann <[email protected]>
634
635 * Resources/Bitmaps/fullextent.xpm: Updated Icon (removed "potatoe")
636
637 2002-09-02 Bernhard Herzog <[email protected]>
638
639 * Thuban/UI/view.py: Get rid of the idle redraw. This is done by
640 wxWindows already and our implementation doesn't work correctly
641 with wxGTK 2.3:
642 (MapCanvas.__init__): Remove the instance variable
643 (MapCanvas.OnPaint): Always call do_redraw when there's a map to
644 be drawin
645 (MapCanvas.OnIdle): Removed.
646
647 * Thuban/UI/view.py (MapCanvas.unprojected_rect_around_point): Add
648 a parameter to determine the size of the rectangle.
649 (MapCanvas.find_shape_at): Create the box around the point on a
650 layer by layer basis and make the size depend on the shape type.
651 This solves a problem with the selection of point shapes at the
652 border of the layer's bounding box
653
654 2002-08-30 Bernhard Herzog <[email protected]>
655
656 * Thuban/UI/mainwindow.py (MainWindow.CanRemoveLayer): New method
657 for the sensitivity of remove layer.
658 (_can_remove_layer): New. Sensitivity callback for remove layer
659 (Command layer_remove): Use _can_remove_layer
660
661 * Thuban/Model/map.py (Map.CanRemoveLayer): New method to
662 determine whether a given layer can be deleted.
663
664 * Thuban/UI/view.py (MapCanvas.__init__, MapCanvas.OnPaint)
665 (MapCanvas.do_redraw): Get rid of the unused update_region
666 instance variable
667
668 * Thuban/UI/view.py: Add/update some doc-strings.
669
670 * test/: new subdirectory with a bunch of unit tests.
671
672 * test/README, test/test_table.py, test/test_save.py,
673 test/test_menu.py, test/test_load.py: Initial set of tests and
674 brief instructions on how to run them
675
676 2002-08-29 Bernhard Herzog <[email protected]>
677
678 * Thuban/UI/renderer.py (ScreenRenderer.draw_shape_layer): Handle
679 arcs with multiple parts.
680
681 * Thuban/UI/view.py (ZoomInTool.MouseUp, ZoomOutTool.MouseUp):
682 Handle degenrate rectangles.
683
684 * Thuban/Model/table.py: Make writing records work correctly:
685 (Table.__init__): Keep track of whether the DBF is open for
686 writing
687 (Table.write_record): Open the DBF file for writing when necessary
688
689 2002-08-27 Bernhard Herzog <[email protected]>
690
691 * Thuban/Model/table.py (Table.write_record, Table.__init__): Open
692 dbf files only for reading by default. Use a new writable dbf
693 object for writing.
694
695 2002-08-26 Bernhard Herzog <[email protected]>
696
697 * Thuban/UI/mainwindow.py: Refactor the context creation:
698 (MainWindow.Context): New method to return a context
699 (MainWindow.invoke_command, MainWindow.update_command_ui): Use the
700 new method
701
702 * Thuban/UI/tableview.py (TableGrid, LayerTableGrid): Split the
703 layer table specific code from TableGrid into LayerTableGrid
704 (TableFrame, LayerTableFrame): Split the layer table specific code
705 from TableFrame into LayerTableFrame
706 (LayerTableGrid.select_shape): Remove a debug print
707
708 * Thuban/UI/mainwindow.py (MainWindow.LayerShowTable): Use the
709 LayerTableFrame
710
711 2002-08-23 Bernhard Herzog <[email protected]>
712
713 * Thuban/Model/layer.py (Layer.__init__): Make sure we have an
714 absolute filename.
715
716 2002-08-22 Bernhard Herzog <[email protected]>
717
718 * Thuban/Model/table.py (Table.write_record): New method to write
719 records.
720 (Table.__init__): Open the DBF file for writing too.
721
722 * Thuban/UI/controls.py (RecordTable.SetValue): Write the value
723 into the underlying table.
724
725 * extensions/shapelib/shapefil.h (DBFCommit),
726 extensions/shapelib/dbfopen.c (DBFCommit): New API function to
727 commit any changes made to the DBF file.
728
729 * Thuban/UI/mainwindow.py (make_check_current_tool)
730 (_tool_command): Put the code that generates the "checked"
731 callback into a separate function so that we can reuse it
732 elsewhere
733
734 * Thuban/Model/save.py (Saver): New class to handle serializing a
735 session into an XML file. The main reason to introduce a class is
736 that applications built on Thuban can derive from it so that they
737 can save additional information in a session file.
738 (save_session): Delegate almost all the work to the Saver class.
739 Rename the filename argument to file because it may be a file like
740 object now.
741
742 * Thuban/Model/load.py: Get rid of the Python 1.5.2 compatibility
743 code. Remove the little test code which would be executed when the
744 module is run as a script which didn't work anymore since it can't
745 import the other Thuban modules.
746 (ProcessSession, load_session): Refactor the ProcessSession to
747 have one method for each element start and end tag so that derived
748 classes can easily override the processing of individual tags.
749 Also, always parse with namespaces enabled because applications
750 built on top of Thuban will likely use namespaces if they extend
751 the session file format.
752
753 2002-08-21 Bernhard Herzog <[email protected]>
754
755 * setup.py (ThubanInstall.run): Don't repr install_lib_orig
756 because thubaninit_contents will do it for us.
757
758 2002-08-16 Jan-Oliver Wagner <[email protected]>
759
760 * Thuban/UI/mainwindow.py: menu item 'show session tree' now disable if
761 tree window already open
762
763 2002-08-15 Bernhard Herzog <[email protected]>
764
765 * Thuban/Model/layer.py (Layer.Destroy): Call the unboundd method
766 with self.
767
768 * Thuban/UI/view.py (MapCanvas.OnLeftUp): Only release the mouse
769 when we have actually captured it.
770
771 * Thuban/Model/layer.py (Layer.Destroy): New. Explicitly close the
772 shapefile and destroy the table.
773
774 * Thuban/Model/table.py (Table.Destroy): New. Close the DBF file.
775
776 2002-08-14 Bernhard Herzog <[email protected]>
777
778 * Thuban/UI/controls.py (RecordTable.__init__): Remove the unused
779 instance variable columns
780 (RecordTable.GetTypeName): row and col may be negative in some
781 cases.
782
783 * setup.py (InstallLocal.initialize_options)
784 (InstallLocal.finalize_options, InstallLocal.user_options): New
785 option create-init-file to build a thubaninit.py when running
786 install_local
787 (InstallLocal.run): Create the thubaninit.py module when requested
788 (thubaninit_contents): Split the template into several parts and
789 create a new function thubaninit_contents that creates the
790 contents of a thubaninit module.
791 (ThubanInstall.run): Use the new function to create the thubaninit
792 module.
793
794 2002-07-30 Bernhard Herzog <[email protected]>
795
796 * Thuban/UI/application.py (ThubanApplication.OnExit): Do some
797 cleanup.
798 (ThubanApplication.MainLoop): Extend to automatically call OnExit.
799
800 * Thuban/Model/session.py (Session.Destroy): Don't bypass the
801 direct base class' Destroy method.
802
803 * Thuban/Model/map.py (Map.ClearLayers): New method to delete all
804 layers.
805 (Map.Destroy): Destroy the label_layer as well and call the
806 inherited Desatroymethod first so that no more messages are
807 issued.
808 (Map.RaiseLayer, Map.LowerLayer): Only issue LAYERS_CHANGED
809 message if the stacking order actually has changed. Add
810 doc-strings.
811 (Map.BoundingBox): Correct the doc-string.
812 (Map.AddLayer, Map.RemoveLayer, Map.Layers, Map.HasLayers)
813 (Map.ProjectedBoundingBox, Map.SetProjection): Add doc-strings.
814
815 * Thuban/Model/label.py (LabelLayer.ClearLabels): New to delete
816 all labels.
817
818 2002-07-29 Bernhard Herzog <[email protected]>
819
820 * Thuban/Model/map.py (Map.subscribe_layer_channels)
821 (Map.unsubscribe_layer_channels): Put the code that (un)subscribes
822 to a layer's channels into separate methods.
823 (Map.RemoveLayer, Map.AddLayer): Call the new methods
824 (Map.Destroy): Unsubscribe from a layer's channels before
825 destroying it.
826
827 * Thuban/UI/view.py (MapCanvas.find_shape_at): Change the
828 selected_layer parameter to searched_layer which is the layer to
829 search in.
830 (MapCanvas.SelectShapeAt): New parameter layer to restrict the
831 search to that layer. Return the selected layer and shape.
832
833 * Examples/simple_extensions/simple_tool.py (simple_tool): Fix a
834 typo
835
836 2002-07-24 Bernhard Herzog <[email protected]>
837
838 * Thuban/UI/application.py (ThubanApplication.create_session):
839 Extend the doc string.
840 (ThubanApplication.subscribe_session)
841 (ThubanApplication.unsubscribe_session): New methods to
842 subscribe/unsubscribe to/from session channels.
843 (ThubanApplication.SetSession): Call the new methods here.
844 (ThubanApplication.maps_changed, ThubanApplication.set_map):
845 Renamed set_map to maps_changed. Its now a subscriber for
846 MAPS_CHANGED.
847
848 * Thuban/UI/view.py (ZoomOutTool.MouseUp): Use the correct
849 x-coordinate in case of simple clicks
850
851 * Thuban/Model/base.py (Modifiable.changed): Apply the args tuple,
852 don't pass it as a parameter
853
854 * Thuban/Model/session.py (Session.RemoveMap): New
855
856 * Thuban/UI/mainwindow.py (MainWindow.__init__): Turn the initial
857 window size into a parameter.
858
859 2002-07-23 Bernhard Herzog <[email protected]>
860
861 * Thuban/UI/menu.py (Menu.item_index): Also search for menus not
862 just commands.
863
864 * Thuban/UI/mainwindow.py (MainWindow.__init__): Change the
865 parameter list a bit to allow setting the window title and the
866 initial message in the status bar. Update the callers.
867
868 * Thuban/UI/application.py (ThubanApplication.OnInit)
869 (ThubanApplication.CreateMainWindow): Put the mainwindow
870 instantiation into a separate method so that it can be overridden
871 by a subclass.
872
873 2002-07-19 Bernhard Herzog <[email protected]>
874
875 * Thuban/Model/session.py: Issue a CHANGED message every time
876 another changed message is issued to make it easier to get
877 notified of changes.
878 (Session): Update the doc string
879 (Session.forward): Issue changed-events as CHANGED as well.
880 (Session.changed): Overwrite the inherited version to issue
881 CHANGED events as well.
882
883 * Thuban/UI/tree.py: We can now simply subscribe to the session's
884 CHANGED channel to be informed of changes.
885 (SessionTreeCtrl.session_channels): Not needed any longer.
886 (SessionTreeCtrl.unsubscribe_all, SessionTreeCtrl.session_changed):
887 Only have to (un)subscribe CHANGED
888
889 * Thuban/Model/map.py (Map.TreeInfo): Deal better with empty maps.
890
891 * Thuban/UI/main.py, Thuban/UI/__init__.py: Move the work-around
892 for the wxPython locale bug to __init__.py so that it's
893 automatically executed by anybody using UI code from Thuban.
894
895 2002-07-18 Bernhard Herzog <[email protected]>
896
897 * Thuban/UI/main.py (main): app no longer needs to be global
898
899 * Thuban/UI/mainwindow.py (MainWindow.__init__): Add application
900 as parameter and store it in an instance variable
901 (MainWindow.invoke_command, MainWindow.update_command_ui)
902 (MainWindow.save_modified_session, MainWindow.NewSession)
903 (MainWindow.OpenSession, MainWindow.SaveSession)
904 (MainWindow.SaveSessionAs, MainWindow.ShowSessionTree): Use self's
905 application object.
906
907 * Thuban/UI/application.py (ThubanApplication.OnInit): Instantiate
908 the main window with self.
909
910 * Thuban/UI/context.py: New module with the context class
911
912 * Thuban/UI/command.py (Command): Update doc string.
913
914 * Thuban/UI/mainwindow.py (MainWindow.invoke_command,
915 MainWindow.update_command_ui): Pass an instance of the context
916 class to the command's methods
917 (check_current_tool, call_method): Handle the new context
918 implementation
919
920 * Examples/simple_extensions/simple_tool.py (simple_tool,
921 check_simple_tool): Handle the new context implementation
922
923 * Examples/simple_extensions/simple_command.py (simple_command):
924 Handle the new context implementation. Update the comments about
925 the context.
926
927 * Thuban/UI/application.py (ThubanApplication.SetSession): Add
928 doc-string
929 (ThubanApplication.Session): New method to return the session
930 object
931
932 * Thuban/UI/tree.py (SessionTreeCtrl.update_tree): The
933 interactor's selected_layer may not be a layer of the current
934 session when the tree is updated while a new session is being set.
935
936 2002-07-17 Bernhard Herzog <[email protected]>
937
938 * Thuban/UI/tree.py (color_string): Removed. No longer used.
939 (SessionTreeCtrl.update_tree, SessionTreeCtrl.add_items): Split
940 update_tree into update_tree and add_items. The tree now uses a
941 more generic way to display the contents of the tree.
942 (SessionTreeCtrl): Add a doc string explaining the TreeInfo method
943
944 * Thuban/Model/layer.py (Layer.TreeInfo),
945 Thuban/Model/extension.py (Extension.TreeInfo),
946 Thuban/Model/map.py (Map.TreeInfo),
947 Thuban/Model/session.py (Session.TreeInfo):
948 Add TreeInfo methods to implement the new tree view update scheme
949
950 2002-07-16 Bernhard Herzog <[email protected]>
951
952 * Thuban/UI/application.py: Don't use "import from" for the
953 MainWindow. It can't always be resolved.
954 (ThubanApplication.OnInit): change reference to MainWindow
955 accordingly.
956
957 * Thuban/UI/menu.py (Menu.SetItems): New method to replace a menu
958 completely
959
960 2002-07-10 Bernhard Herzog <[email protected]>
961
962 * setup.py (create_init_module): New configurable variable whose
963 default depends on the platform we're running on.
964 (ThubanInstall.initialize_options): Initialize
965 self.create_init_module from the global create_init_module
966 (ThubanInstall.user_options): indictate that the options
967 create-init-module and init-module-dir have arguments.
968
969 * setup.py: In the setup call change the version number to include
970 cvs.
971
972 * MANIFEST.in: Add the files in Examples
973
974 2002-07-09 Bernhard Herzog <[email protected]>
975
976 * setup.py: In the setup call, use the thuban homepage as the
977 value of the url parameter.
978
979 * Examples: New subdirectory for examples.
980
981 * Examples/simple_extensions/simple_tool.xpm,
982 Examples/simple_extensions/simple_tool.py,
983 Examples/simple_extensions/simple_command.py,
984 Examples/simple_extensions/README: Simple examples showing how to
985 add new commands and tools.
986
987 * setup.cfg (bdist_rpm): Add the default value for prefix and tell
988 bdist_rpm that we also have an install script.
989 (bdist_inno): Add 2002 to the copyright notice.
990
991 * setup.py: Create a file in python's site-packages directory to
992 make installation of Thuban as a library easier.
993 (ThubanInstall.user_options): Add two new options,
994 create-init-module and init-module-dir
995 (ThubanInstall.expand_with_pure_python_dirs): New method to expand
996 filenames for installation in the default directories.
997 (ThubanInstall.select_scheme, ThubanInstall.convert_paths): Extend
998 the inherited methods to capture some filenames before they're
999 transformed too much by distutils.
1000 (ThubanInstall.run): Create the init module if requested.
1001 (ThubanInstall.thuban_init_filename): New method to return the
1002 full name of the init module.
1003 (ThubanInstall.get_outputs): Append the filename of the init
1004 module.
1005
1006 2002-07-08 Bernhard Herzog <[email protected]>
1007
1008 * setup.py (thuban_bdist_rpm): Extend this version of bdist_rpm to
1009 handle the prefix properly which means that the default for the
1010 installation prefix should be /usr for RPMs and /usr/local when
1011 doing a normal source install.
1012 (bdist_rpm_install_script): Script to override the default install
1013 commands in the specfile generated by the bdist_rpm command.
1014 (thuban_bdist_rpm.user_options): Add a prefix option
1015 (thuban_bdist_rpm.initialize_options): Init the prefix option.
1016 Create the script files for the spec files as empty files here
1017 (thuban_bdist_rpm._make_spec_file): Override the inherited method
1018 to fill the script files with content.
1019
1020 * Thuban/Model/save.py (relative_filename): Wrapper around
1021 Thuban.Lib.fileutil.relative_filename that accepts an empty dir
1022 argument. save_session now automatically uses this version,
1023 solving a problem when saving to a relative filename.
1024
1025 * setup.py: In the setup call, make sure that the library
1026 directories are under $prefix/lib not directly under $prefix.
1027
1028 2002-06-20 Jan-Oliver Wagner <[email protected]>
1029
1030 * Thuban/Model/extension.py: new module to handle extension objects.
1031 * Thuban/Model/messages.py: new messages for extensions.
1032 * Thuban/Model/session.py (Session.Extensions, Session.HasExtensions,
1033 Session.AddExtension): new for handling extensions.
1034 Also some other minor changes to round up extension handling.
1035 * Thuban/UI/tree.py (SessionTreeCrtl:update_tree): Added visualization
1036 of Extension titles and title and names of its objects.
1037
1038 2002-05-29 Bernhard Herzog <[email protected]>
1039
1040 * Thuban/UI/mainwindow.py (MainWindow.bind_command_events): Bind
1041 the events for a command.
1042 (MainWindow.add_toolbar_command, MainWindow.add_menu_command):
1043 Call bind_command_events to bind the events. add_toolbar_command
1044 can now bind events too so that it's possible to have commands
1045 that are only available through the toolbar.
1046 (MainWindow.init_ids): New instance variable events_bound to keep
1047 track of for which commands events have been bound.
1048
1049 2002-05-28 Bernhard Herzog <[email protected]>
1050
1051 * Thuban/UI/menu.py: New module to build and manage menus.
1052
1053 * Thuban/UI/mainwindow.py: Remove some unused imports.
1054 (MainWindow.__init__, main_menu): move the definition of the main
1055 menu from __init__ to the Menu instance main_menu.
1056 (MainWindow.build_menu_bar, MainWindow.build_menu): New methods to
1057 build the menu bar and sub-menus from a menu description.
1058
1059 * Thuban/UI/application.py (ThubanApplication.OnInit): Read the
1060 startup file
1061 (ThubanApplication.read_startup_files): New method to run
1062 ~/.thuban/thubanstart.py
1063
1064 * Thuban/UI/mainwindow.py (MainWindow.__init__, main_toolbar):
1065 Move the toolbar definition to the Menu instance main_toolbar.
1066 (MainWindow.build_toolbar): New method to build the toolbar
1067 similar to the build_menu methods
1068
1069 2002-05-23 Bernhard Herzog <[email protected]>
1070
1071 * Thuban/UI/mainwindow.py (MainWindow.__init__): Fix spelling of
1072 layer_outline_color. Fix it in the definition of the command too.
1073
1074 * Thuban/UI/command.py (Command): Fix typo in doc string
1075
1076 2002-05-22 Bernhard Herzog <[email protected]>
1077
1078 * Thuban/UI/mainwindow.py (MainWindow.RunMessageBox): Fix a typo
1079 in the docstring
1080
1081 2002-05-15 Bernhard Herzog <[email protected]>
1082
1083 * Thuban/Model/layer.py (Layer.open_shapefile): Set bbox to None
1084 when the shapefile is empty.
1085 (Layer.BoundingBox, Layer.LatLongBoundingBox): Both methods may
1086 now return None for empty shapefiles. Update doc-strings.
1087
1088 * Thuban/Model/map.py (Map.BoundingBox): Add doc-string. Deal with
1089 the layer's bbox being None.
1090
1091 * Thuban/UI/tree.py (SessionTreeCtrl.update_tree): Deal with the
1092 layer's bbox being None.
1093
1094 * Thuban/UI/view.py (MapCanvas.shape_selected): Only redraw when
1095 necessary.
1096 (MapCanvas.__init__): New instance variables, last_selected_layer
1097 and last_selected_shape to determine how the selection has
1098 changed.
1099
1100 * Thuban/UI/tableview.py (TableGrid.__init__): Do not call
1101 AutoSizeColumns because it will cause a traversal of the entire
1102 table which for large .dbf files will take a very long time.
1103
1104 2002-05-14 Bernhard Herzog <[email protected]>
1105
1106 * Thuban/Model/layer.py (Layer.open_shapefile): Choose a better
1107 maximum depth for the tree than shapelib does by default.
1108
1109 2002-05-10 Bernhard Herzog <[email protected]>
1110
1111 * setup.py (py_modules): The shptree modules doesn't have a
1112 wrapper, so don't include it in the py_modules
1113
1114 2002-05-08 Bernhard Herzog <[email protected]>
1115
1116 * extensions/shapelib/shptree.c (compare_ints): Make arguments
1117 const void * as in the qsort prototype
1118 (SHPTreeFindLikelyShapes): Remove some unused variables.
1119
1120 * Thuban/UI/view.py (PanTool.MouseMove): Use the bitmap the view
1121 maintains to redraw the window during a drag.
1122 (MapCanvas.unprojected_rect_around_point): New method to determine
1123 a small region around a point for hit-testing.
1124 (MapCanvas.find_shape_at): Only test the shapes in a small region
1125 around the point.
1126
1127 * setup.py: Increment the version to 0.1.2
1128
1129 * Thuban/UI/tree.py (SessionTreeCtrl.unsubscribe_all): Remove a
1130 debug print and set session to None after unsubscribing
1131
1132 2002-05-07 Bernhard Herzog <[email protected]>
1133
1134 * Data/iceland_sample.session, Data/iceland_sample.thuban: Rename
1135 the file to have a .thuban extension.
1136
1137 * Thuban/UI/tree.py (session_channels): New class constant with
1138 all the session channels to subscribe to to update the tree
1139 (SessionTreeCtrl.session_changed): Remember the session so that we
1140 can unsubscribe properly. Use the new class constant to
1141 unsubscribe from the old session and subscribe to the new one.
1142 (SessionTreeCtrl.unsubscribe_all): New method to unsubscribe all
1143 subscriptions of the SessionTreeCtrl.
1144 (SessionTreeView.OnClose): Call the tree's unsubscribe_all method.
1145
1146 * Thuban/UI/mainwindow.py (MainWindow.__init__): Add the "Show
1147 Session Tree" command to the file menu.
1148
1149 * Thuban/UI/view.py (MapCanvas.do_redraw): Pass the entire bitmap
1150 as update_region to the renderer.
1151
1152 * Thuban/UI/renderer.py
1153 (ScreenRenderer.layer_ids, ScreenRenderer.draw_shape_layer): The
1154 update box is now directly a tuple, not a wxRect anymore.
1155
1156 * Thuban/Model/layer.py (Layer.ShapesInRegion): Remove some debug
1157 prints.
1158
1159 2002-05-07 Bernhard Herzog <[email protected]>
1160
1161 * setup.py: Add the shptree extension module. See
1162 extensions/pyshapelib/ChangeLog for more details.
1163
1164 * extensions/shapelib/shpopen.c, extensions/shapelib/shapefil.h,
1165 extensions/shapelib/dbfopen.c: Really update to the versions of
1166 shapelib 1.2.9. For some reason it wasn't really done on
1167 2002-04-11.
1168
1169 * extensions/shapelib/shptree.c: Modified version of shptree.c of
1170 shapelib 1.2.9. The only real difference is the use of qsort
1171 instead of a bubble sort implementation
1172
1173 * Thuban/Model/layer.py (Layer.__init__): New instance variable
1174 shapetree to hold the shapelib quadtree for the shapefile
1175 (Layer.open_shapefile): Create the quad tree.
1176 (Layer.ShapesInRegion): New method to return the ids of shapes in
1177 a given region using the quad tree.
1178
1179 * extensions/thuban/wxproj.cpp (project_points): Fix some typos in
1180 comment
1181 (draw_polygon_shape): Accept both arcs and polygons.
1182 (initwxproj): Use the new PYSHAPELIB_IMPORT_API macro to import
1183 the api.
1184
1185 * Thuban/UI/renderer.py (MapRenderer.layer_ids): New method to
1186 return the shape ids to be rendered in a given layer.
1187 (MapRenderer.draw_shape_layer): Call layer_ids to get the list of
1188 ids. Use draw_polygon_shape to draw arc shapes as well.
1189 (ScreenRenderer.RenderMap): New parameter for the rectangle that
1190 has to be updated
1191 (ScreenRenderer.layer_ids): Make use of the layer's quadtree by
1192 calling it's ShapesInRegion method.
1193
1194 * Thuban/UI/view.py (MapCanvas.__init__): New instance variable
1195 update_region for the update region.
1196 (MapCanvas.OnPaint): Maintain the update region
1197 (MapCanvas.do_redraw): Pass the bounding box of the update_region
1198 to the renderer when drawing the bitmap. Reset the update_region.
1199
1200 2002-05-03 Bernhard Herzog <[email protected]>
1201
1202 * Thuban/UI/mainwindow.py (MainWindow.SaveSessionAs,
1203 MainWindow.OpenSession): Change the file extension of the session
1204 files to .thuban
1205
1206 * Thuban/Model/session.py (Session.AddMap, forwarded_channels):
1207 Move the map channels to be forwarded by the session into the
1208 class constant with forwarded_channels. Also add
1209 LAYER_PROJECTION_CHANGED and LAYER_VISIBILITY_CHANGED to
1210 forwarded_channels
1211
1212 * Thuban/Model/base.py (Modifiable.changed): Fix doc-string (a
1213 typo and some rewording).
1214
1215 2002-05-02 Bernhard Herzog <[email protected]>
1216
1217 * Thuban/UI/view.py: Keep the temporary bitmap used during drawing
1218 around to speed up most redraws:
1219 (MapCanvas.__init__): New instance variable bitmap which holds the
1220 bitmap
1221 (MapCanvas.do_redraw): Redraw self.bitmap if necessary. Use
1222 self.bitmap to draw.
1223 (MapCanvas.full_redraw): New method to force a full redraw
1224 including the bitmap
1225 (MapCanvas.SetMap): Subscribe full_redraw instead of redraw to
1226 make sure the bitmap is redrawn.
1227 (MapCanvas.projection_changed, MapCanvas.set_view_transform,
1228 MapCanvas.shape_selected): Call full_redraw instead of readraw to
1229 make sure the bitmap is redrawn.
1230 (MapCanvas.OnSize): New method to handle size events so that the
1231 bitmap can be redrawn.
1232
1233 2002-04-29 Bernhard Herzog <[email protected]>
1234
1235 * Thuban/UI/mainwindow.py (MainWindow.__init__): Subscribe to the
1236 canvas' VIEW_POSITION event
1237 (MainWindow.view_position_changed): Handler for VIEW_POSITION.
1238 Update the text in the status-bar accordingly.
1239
1240 * Thuban/UI/view.py (MapCanvas): Derive from Publisher as well
1241 (MapCanvas.__del__): Implement because Publisher.__del__ has to be
1242 called.
1243 (MapCanvas.__init__): Bind EVT_LEAVE_WINDOW too. Initialize
1244 current_position
1245 (MapCanvas.set_current_position): New method to set
1246 current_position. Issue a VIEW_POSITION event
1247 (MapCanvas.CurrentPosition): New public method to return the value
1248 of current_position. Should be called when the VIEW_POSITION event
1249 is processed.
1250 (MapCanvas.OnLeftDown, MapCanvas.OnLeftUp, MapCanvas.OnMotion):
1251 Update the position.
1252 (MapCanvas.OnLeaveWindow): Set the position to None.
1253
1254 * Thuban/UI/messages.py (VIEW_POSITION): New message for the
1255 position in the statusbar
1256
1257 2002-04-26 Frank Koormann <[email protected]>
1258
1259 * Thuban/UI/mainwindow.py: AddLayer, Dialog title s/session/data
1260
1261 2002-04-24 Frank Koormann <[email protected]>
1262
1263 * Resources/Bitmaps/identify.xpm: shadow added
1264
1265 * Resources/Bitmaps/fullextent.xpm: new
1266
1267 2002-04-22 Jan-Oliver Wagner <[email protected]>
1268
1269 * Thuban/UI/tree.py (update_tree): added test for None on map bounding
1270 box
1271
1272 2002-04-21 Jan-Oliver Wagner <[email protected]>
1273
1274 * Thuban/UI/proj4dialog.py (UTMProposeZoneDialog): new
1275
1276 * Thuban/UI/tree.py (update_tree): added added map extent
1277
1278 * Thuban/UI/mainwindow.py (_method_command): extended by parameter
1279 icon; added map_full_extend as tool
1280
1281 2002-04-19 Jan-Oliver Wagner <[email protected]>
1282
1283 * Thuban/UI/mainwindow.py (SaveSession): launch save as dialog for
1284 saving _new_ sessions
1285
1286 * Thuban/Model/session.py (create_empty_session): new session
1287 don't have a filename (set to None)
1288
1289 * Thuban/UI/tree.py (update_tree): added filename and modified flag
1290
1291 * Thuban/Model/load.py (ProcessSession): convert projection
1292 parameters from unicode to regular string
1293
1294 * Data/iceland_sample.session: Added UTM Zone 26 projection.
1295
1296 2002-04-11 Bernhard Herzog <[email protected]>
1297
1298 * extensions/shapelib/shapefil.h, extensions/shapelib/shpopen.c,
1299 extensions/shapelib/dbfopen.c: Update to the versions of shapelib
1300 1.2.9
1301
1302 * setup.py (Lib.wxproj extension): Don't link shpopen.c and put
1303 the pyshapelib directoy into the list of include dirs, so that
1304 pyshapelib_api.h can be found.
1305
1306 * extensions/thuban/wxproj.cpp (pyshapelib_api): New variable that
1307 holds the pyshapelib C-API
1308 (draw_polygon_shape, point_in_polygon_shape, shape_centroid): Use
1309 pyshapelib_api to access the shapelib functions.
1310 (initwxproj): Import the c_api from the shapelib module and
1311 initialize pyshapelib_api.
1312
1313 2002-04-04 Bernhard Herzog <[email protected]>
1314
1315 * setup.py (thuban_bdist_rpm.initialize_options): Use
1316 initialize_options to create the scripts for the rpm.
1317
1318 * extensions/pyprojection/setup.py (PROJ4_PREFIX): Just use /
1319
1320 2002-04-03 Bernhard Herzog <[email protected]>
1321
1322 * setup.py: Increment version to 0.1.1
1323
1324 * Thuban/UI/mainwindow.py (MainWindow.__init__): Move the "Add
1325 Layer" and "Remove Layer" commands from the layer menu to the map
1326 menu
1327
1328 2002-02-15 Bernhard Herzog <[email protected]>
1329
1330 * Thuban/Model/layer.py (Layer.Shape): list append only takes one
1331 argument (python <= 1.5.2 erroneously accepted multiuple
1332 arguments)
1333
1334 2002-02-04 Bernhard Herzog <[email protected]>
1335
1336 * Thuban/UI/identifyview.py (IdentifyGridCtrl): New class to use a
1337 RecordGrid in the identifyview.
1338 (IdentifyView.__init__): Use IdentifyGridCtrl instead of
1339 IdentifyListCtrl. The grid allows editing of the values.
1340
1341 * Thuban/UI/controls.py (RecordTable, RecordGridCtrl): New classes
1342 implementing a grid for a single row of a thuban table.
1343
1344 * Thuban/UI/view.py (MapCanvas.SelectShapeAt): Search through all
1345 layers by default. Easier to use than the previous default of only
1346 searching through the select layer which meant that if no layer
1347 was selected, you couldn't select a shape.
1348
1349 * Thuban/UI/tableview.py (TableGrid.__init__): Fix typo
1350
1351 * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Honour the
1352 stroke_width attribute
1353
1354 * Thuban/Model/save.py (save_session): Write the new stroke_width
1355 attribute
1356
1357 * Thuban/Model/load.py (ProcessSession.startElement): Read the
1358 stroke_width attribute
1359
1360 * Thuban/Model/layer.py (Layer.__init__): New parameter and
1361 instance variable stroke_width
1362 (Layer.SetStrokeWidth): Set the stroke_width.
1363
1364 2002-02-01 Bernhard Herzog <[email protected]>
1365
1366 * extensions/thuban/wxproj.cpp (project_points): Fix two
1367 off-by-one errors in the last loop that joins the various parts
1368 together.
1369
1370 2002-01-14 Bernhard Herzog <[email protected]>
1371
1372 * setup.py (data_dist.make_distribution): Fix some typos
1373
1374 2001-09-18 Bernhard Herzog <[email protected]>
1375
1376 * README: Slight tweaking in preparation for the 0.1 release
1377
1378 * setup.cfg: Add section for sdist to create both tgz and zip
1379 archives
1380
1381 * setup.py: increase version number to 0.1
1382 (data_dist): New command class for data distribution
1383
1384 2001-09-14 Bernhard Herzog <[email protected]>
1385
1386 * Thuban/UI/identifyview.py (IdentifyListCtrl.selected_shape):
1387 Handle the case of no layer (i.e. layer is None) properly.
1388
1389 * Thuban/UI/proj4dialog.py (UTMDialog.__init__, Proj4Dialog.__init__):
1390 Set the initial selection of the combo boxes to reflect the
1391 projection we're starting with in a way that works on windows,
1392 too.
1393
1394 * Thuban/Lib/connector.py (Connector.print_connections): Print the
1395 puiblisher's ids in hex to make it easier to compare them to the
1396 standard repr of python methods
1397
1398 * Thuban/Model/map.py (Map.Destroy): Unsubscribe the label_layer
1399 messages
1400
1401 2001-09-13 Bernhard Herzog <[email protected]>
1402
1403 * Thuban/UI/tree.py (SessionTreeCtrl.OnSelChanged): Make sure to
1404 deselect the layer if no layer is selected
1405
1406 * Thuban/UI/view.py (MapCanvas.OnPaint): Only delay drawing to
1407 idle time when there actually is something to draw. If there's
1408 nothing to draw simply clear the window
1409 (MapCanvas.do_redraw): Call dc.EndDrawing and add some comments.
1410 (MapCanvas.SetMap): force a redraw in all cases because
1411 FitMapToWindow doesn't always do it.
1412 (MapCanvas.ZoomFactor): Add an optional parameter, center, to
1413 specify the point to move into the center of the window
1414 (ZoomOutTool.MouseUp, ZoomInTool.MouseUp): If the mouse wasn't
1415 dragged, zoon in/out by a factor of 2
1416 (MapCanvas.find_shape_at): Iterate backwards (i.e. with decreasing
1417 index, i.e. reversed drawing order) so that objects appearing to
1418 be in from of others are selected first. This is probably mostly
1419 relevant for point shapes where the symbols used may overlap
1420
1421 * Thuban/Model/session.py (create_empty_session): Unset the
1422 modified bit before returning it
1423
1424 * Thuban/UI/mainwindow.py (MainWindow.NewSession): Use
1425 create_empty_session session to create the new, empty session.
1426
1427 * Thuban/UI/mainwindow.py (MainWindow.__init__): Set the size of
1428 the tool bitmaps.
1429 (MainWindow.OnClose, MainWindow.save_modified_session): Separate
1430 the code that asks whether the session should be saved into the
1431 new method save_modified_session.
1432 (MainWindow.OpenSession, MainWindow.NewSession): Use the new
1433 method to save modified session here too.
1434
1435 2001-09-11 Bernhard Herzog <[email protected]>
1436
1437 * setup.py (InnoIconItem): fix typo
1438
1439 (thuban_bdist_inno.run):
1440 (bdist_inno.run): Move the decision not to create symlinks on
1441 non-nt platforms to thuban_bdist_inno and do it unconditinally
1442 since we never want to create the symlinks here
1443
1444 2001-09-10 Bernhard Herzog <[email protected]>
1445
1446 * Thuban/UI/mainwindow.py (MainWindow.IdentifyTool): Popup the
1447 identify view immediately
1448
1449 * Thuban/UI/controls.py: New file with two classes RecordListCtrl
1450 and SelectableRecordListCtrl that implement the code shared by the
1451 identify view and the label dialog
1452
1453 * Thuban/UI/identifyview.py (IdentifyListCtrl): Derive from the
1454 new class RecordListCtrl
1455
1456 * Thuban/UI/labeldialog.py (LabelDialog.OnOK): Check whether the
1457 return value of GetValue is None instead of using it as a boolean
1458 directly so that Zero numbers are handled properly.
1459 (LabelListCtrl): Derive from the new class
1460 SelectableRecordListCtrl
1461
1462 * Thuban/UI/proj4dialog.py (Proj4Dialog.__init__):
1463 (Proj4Dialog.dialogLayout): Make the window resizable and set the
1464 size of the text control explicitly to make the sizers work on
1465 both Windows and X.
1466
1467 2001-09-07 Bernhard Herzog <[email protected]>
1468
1469 * Thuban/UI/view.py (MapCanvas.find_shape_at):Add a new parameter
1470 that can limit the search to the currently selected layer.
1471 (MapCanvas.SelectShapeAt): Make sure that the currently selected
1472 layer stays selected even when no shape is found
1473 (MapCanvas.FitRectToWindow): If the rect has zero with or zero
1474 height do nothing (avoids zero division errors)
1475
1476 2001-09-06 Bernhard Herzog <[email protected]>
1477
1478 * Thuban/UI/tree.py (SessionTreeCtrl, SessionTreeView.__init__):
1479 Correct the spelling of SessionTreeCtrl. dabbrev is too damn
1480 convenient :-)
1481 (SessionTreeCtrl.__init__, SessionTreeCtrl.update_tree): Introduce
1482 a new instvar layer_to_item to map layers to tree items
1483 (SessionTreeCtrl.layer_selected): Select the appropriate tree item
1484 to match the current selection in the interactor
1485
1486 * Thuban/UI/interactor.py (Interactor.SelectedLayer):
1487 (Interactor.HasSelectedLayer): New methods to query the current
1488 selection
1489
1490 * Thuban/UI/mainwindow.py (MainWindow.current_layer):
1491 (MainWindow.has_selected_layer): Simply call the appropriate
1492 interactor method
1493
1494 * Thuban/UI/mainwindow.py (MainWindow.__init__):
1495 (MainWindow.LayerShowTable):
1496 (MainWindow.identify_view_on_demand): Store the interactor in an
1497 instvar and use that reference instead of going through main.app
1498
1499 * Thuban/UI/mainwindow.py (MainWindow.ShowSessionTree):
1500 * Thuban/UI/application.py (ThubanApplication.OnInit):
1501 * Thuban/UI/main.py (main): Create the session tree view in main
1502 with the new mainwindow method ShowSessionTree and not directly
1503 the application's OnInit method
1504
1505 * Thuban/UI/tree.py (myTreeCtrlPanel):
1506 (SessioinTreeCtrl): Rename to SessioinTreeCtrl and turn it into a
1507 TreeCtrl isntead of a panel. This affects most method since we now
1508 refer to self instead of self.tree
1509 (SessionTreeView): New class implementing a non-modal dialog
1510 showing the session tree.
1511
1512 * Thuban/UI/mainwindow.py (MainWindow.LayerShowTable): Pass the
1513 layer to the tableview dialog.
1514
1515 * Thuban/UI/tableview.py: Add some doc-strings
1516 (TableGrid):
1517 (TableGrid.OnRangeSelect):
1518 (TableGrid.OnSelectCell):
1519 (TableFrame.__init__):
1520 (TableFrame.row_selected):
1521 Selecting rows in the grid view now updates the selected shapes
1522 through the TableFrame. To achieve this we derive TableGrid from
1523 Publisher and introduce the message type ROW_SELECTED which the
1524 TableFrame subscribes to and which is issued by OnRangeSelect and
1525 OnSelectCell
1526
1527 (DataTable.SelectRow): Removed because it's no longer needed in
1528 the row/shape selection scheme
1529
1530 * Thuban/UI/dialogs.py: New file implementing common classes for
1531 dialogs
1532
1533 * Thuban/UI/tableview.py (TableGrid.__init__): Don't subscribe to
1534 the SELECTED_SHAPE message anymore. This is now handled by the
1535 parent.
1536 (TableGrid.select_shape): Only update the selection if the shape
1537 is not None.
1538 (TableFrame): Inherit from the new NonModalDialog class.
1539 (TableFrame.__init__, TableFrame.select_shape): Handle the
1540 SELECT_SHAPE message.
1541 (TableFrame.OnClose): Extend the inherited method to unsubscribe
1542 SELECT_SHAPE
1543
1544 * Thuban/UI/mainwindow.py (MainWindow.init_dialogs):
1545 (MainWindow.add_dialog):
1546 (MainWindow.dialog_open):
1547 (MainWindow.remove_dialog):
1548 (MainWindow.get_open_dialog): New methods to maintain a dictionary
1549 of opened non-modal dialogs.
1550
1551 (MainWindow.__init__): Initialize the new non-modal dictionary
1552 management code
1553 (MainWindow.LayerShowTable): maintain separate dialogs for each
1554 table using the non-modal dialog management code to only open a
1555 view once for each table.
1556
1557 (MainWindow.IdentifyTool):
1558 (MainWindow.__init__):
1559 (MainWindow.identify_view_on_demand): Don't open the identify view
1560 in IdentifyTool anymore. This will be done automatically by the
1561 new method identify_view_on_demand which handles the
1562 SELECTED_SHAPE message so that the identify view will be opened on
1563 demand
1564
1565 * Thuban/UI/identifyview.py (IdentifyListCtrl.__init__): Remove
1566 the interactor argument. The SELECTED_SHAPE message is now handled
1567 by the parent.
1568 (IdentifyView.__init__): Add the interactor argument so that we
1569 can handle the SELECTED_SHAPE message here
1570 (IdentifyView.selected_shape): New method to handle the
1571 SELECTED_SHAPE messages
1572
1573 * Thuban/UI/identifyview.py (IdentifyView): Derive from the new
1574 NonModalDialog class
1575 (IdentifyView.OnClose): Extend the inherited version to
1576 unsubscribe SELECT_SHAPE
1577
1578 * Thuban/Model/session.py (Session.UnsetModified): Remove debug prints
1579
1580 2001-09-05 Bernhard Herzog <[email protected]>
1581
1582 * Thuban/UI/view.py (MapCanvas.__init__): New argument, interactor.
1583
1584 * Thuban/UI/mainwindow.py (MainWindow.__init__): New argument
1585 interactor to pass through to the MapCanvas
1586
1587 * Thuban/UI/application.py (ThubanApplication.OnInit): Use the new
1588 argument to the MainWindow constructor to get rid of the ugly hack
1589 that made main.app available early just so that the mapcanvas
1590 could access the interactor object.
1591
1592 2001-09-04 Bernhard Herzog <[email protected]>
1593
1594 * Thuban/UI/mainwindow.py (MainWindow.RunMessageBox): New method
1595 that runs a modal message box
1596 (MainWindow.OnClose): Use the new method
1597 (MainWindow.RemoveLayer): Just do nothing in case no layer is
1598 selected. The command should be grayed out anyway, so there's no
1599 need to pop up a message box.
1600 (MainWindow.AddLayer): Pop up a message box with an error message
1601 if the shape file can't be opened
1602
1603 * Thuban/Model/layer.py (Layer.__init__): Open the shapefile
1604 immediately. This will cause an exception in case the file can't
1605 be opened and we can display an appropriate message.
1606
1607 * MANIFEST.in: Add extensions/pyprojection/LICENSE
1608
1609 * setup.py (thuban_bdist_rpm): New class implementing a Thuban
1610 specific bdist_rpm command.
1611
1612 * Thuban/UI/main.py: Catch ImportError exceptions when importing
1613 the locale module because it may not be available on some
1614 installations.
1615
1616 * extensions/pyprojection/LICENSE: Copy of the license text in
1617 Projection.i. Having it in a separate file makes it easier to
1618 refer to license text in e.g. RPMs
1619
1620 2001-09-03 Bernhard Herzog <[email protected]>
1621
1622 * setup.py: use wx-config instead of wxgtk-config because it's
1623 more generic
1624
1625 * setup.py (ThubanInstall.get_outputs): Add the symlink in
1626 <prefix>/bin to the outputs
1627 (ThubanInstall.link_file): New method to link files. We need this
1628 because the standard copy_files refuses to link non-existing
1629 files.
1630 (ThubanInstall.run): Remove the leading install root from the
1631 script filename if an install root was specified and use the new
1632 link_file method
1633
1634 * Thuban/UI/mainwindow.py (MainWindow.AddLayer): Fit the map to
1635 the window when the first layer is added to the map.
1636
1637 * setup.py (ThubanInstall.run): Honor the build root (self.root)
1638 when linking thuban.py to <prefix>/bin
1639
1640 2001-08-31 Bernhard Herzog <[email protected]>
1641
1642 * setup.py: In the setup call, the install parameters shouldn't
1643 have trailing slashes because distutils on non-posix platforms
1644 doesn't like that. The same applies to other directories like
1645 "Resources/Bitmaps"
1646
1647 In the configuration section for nt, move the wxWindows directory
1648 optins into the part clearly marked as editable.
1649
1650 (InstallLocal.initialize_options):
1651 (InstallLocal.user_options): remove the currently unused debug
1652 flag
1653 (thuban_build_py.find_all_modules): Add this method so that it
1654 works for our case of having packages and modules in one
1655 distribution as well.
1656 (ThubanInstall.initialize_options):
1657 (ThubanInstall.finalize_options):
1658 (ThubanInstall.user_options):
1659 (ThubanInstall.boolean_options): Add new options, do-symlink and
1660 extra files. Since these are the first ThubanInstall specific
1661 options, override user_options and boolean_options
1662 (ThubanInstall.run): Honor the new do-symlink and extra-files
1663 options.
1664 (ThubanInstall.get_outputs): Add to override the base-class's
1665 version and add the extra-files to the outputs
1666 (bdist_inno): New class for windows distributions with Inno Setup
1667 (InnoIconItem): Helper class for bdist_inno
1668 (thuban_bdist_inno): Thuban specific version of bdist_inno. Added
1669 this together with the appropriate parameters, to the setup call.
1670
1671 * setup.cfg (bdist_inno): added new section for the inno setup
1672 installer
1673
1674 * Thuban/UI/tree.py (myTreeCtrlPanel.__init__): New inst var
1675 changing_selection to avoid recursive selection events when
1676 modifying the selection in response to a selection event.
1677 (myTreeCtrlPanel.normalize_selection): Set the new inst var when
1678 changing the tree's selection.
1679 (myTreeCtrlPanel.OnSelChanged): Only normalize the selection when
1680 we're not being called indirectly from normalize_selection.
1681
1682 * Thuban/UI/mainwindow.py (MainWindow.update_command_ui): Call
1683 event.Check only if the command is actuall checkable.
1684 (MainWindow.__init__): Call the toolbar's Realize method to make
1685 sure that the items are actually shown
1686
1687 2001-08-28 Bernhard Herzog <[email protected]>
1688
1689 * setup.py: Fix some doc strings
1690
1691 * ChangeLog: started
1692

Properties

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

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26