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

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

Parent Directory Parent Directory | Revision Log Revision Log


Revision 447 - (show annotations)
Thu Feb 27 16:05:51 2003 UTC (22 years ago) by jonathan
Original Path: trunk/thuban/ChangeLog
File size: 55756 byte(s)
updated ChangeLog

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

Properties

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

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26