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

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

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1134 by frank, Thu Jun 5 13:28:04 2003 UTC revision 1224 by jonathan, Tue Jun 17 15:26:11 2003 UTC
# Line 1  Line 1 
1    2003-06-17  Jonathan Coles   <[email protected]>
2    
3            Fix the problem with raster layers under Windows that caused
4            Thuban to crash. The view should respond to layer projection
5            changed events to update the display. Changes to a projection
6            should not cause the map to be set to full extent.
7            
8            * Thuban/UI/view.py (MapCanvas.__init__): New instance variable
9            current_map_proj to remember the current map projection so that
10            when the projection changes we know what the previous projection
11            was.
12            (MapCanvas.SetMap): Unsubscribe and subscribe to
13            LAYER_PROJECTION_CHANGED events.
14            (MapCanvas.projection_changed): Split into two methods that respond
15            to map and layer projection changes.
16            (MapCanvas.map_projection_changed): New. Takes the current view and
17            projects it using the new projection. This does not cause the
18            map to be redrawn at full extent.
19            (MapCanvas.layer_projection_changed): New. Cause a redraw which
20            will draw each layer in its new projection.
21            
22            * extensions/thuban/bmpdataset.cpp (BMPDataset::Open): Call
23            VSIFClose() not VSIFCloseL() to close the file. Fixes a crash
24            under Windows.
25            
26            * extensions/thuban/gdalwarp.cpp (MFILENAME): Padding should be
27            to twice sizeof(void*) because there are two digits for each
28            hex byte.
29    
30    2003-06-16  Bernhard Herzog  <[email protected]>
31    
32            Update to the layer interface: Direct access to the table,
33            shapetable, shapefile and filename attributes is now actively
34            deprecated by issuing deprecation warnings for all places where
35            this happens.
36    
37            * Thuban/Model/layer.py (Layer.__getattr__): New. Implement access
38            to the instance variables table, shapetable, shapefile and
39            filename via __getattr__ so that we can issue a deprecation
40            warning.
41            (Layer.SetShapeStore): Don't set the deprecated instance variables
42            any more
43            (Layer.SetShapeStore): Don't use deprecated layer instance
44            variables
45            (Layer.Destroy): No need to explicitly remove the instance
46            variables any more
47            (Layer.GetFieldType, Layer.Shape): Don't use deprecated layer
48            instance variables
49    
50            * Thuban/UI/classgen.py (ClassGenDialog.__init__)
51            (GenUniformPanel._OnRetrieve, GenUniquePanel._OnRetrieve)
52            (GenQuantilesPanel.GetList, GenQuantilesPanel.OnRetrieve): Don't
53            use deprecated layer instance variables
54    
55            * Thuban/UI/classifier.py (Classifier.__init__): Don't use
56            deprecated layer instance variables
57    
58            * Thuban/UI/identifyview.py (IdentifyListCtrl.selected_shape)
59            (IdentifyGridCtrl.selected_shape): Don't set the deprecated layer
60            instance variables
61    
62            * Thuban/UI/tableview.py (LayerTableGrid.select_shapes): Don't use
63            deprecated layer instance variables
64    
65            * Thuban/UI/mainwindow.py (MainWindow.LayerShowTable): Don't use
66            deprecated layer instance variables
67    
68            * Thuban/Model/save.py (SessionSaver.write_layer): Don't use
69            deprecated layer instance variables
70    
71            * Thuban/UI/renderer.py (MapRenderer.draw_shape_layer)
72            (MapRenderer.polygon_render_param): Don't use deprecated layer instance
73            variables
74    
75            * test/runtests.py (main): Turn Thuban's deprecation warnings into
76            errors so that they're cought by the tests
77    
78            * test/test_load.py (TestSingleLayer.test): Don't use deprecated
79            layer instance variables
80    
81    2003-06-16  Jonathan Coles   <[email protected]>
82    
83            Fix a problem under Windows whereby if the user double-clicks on a
84            layer in the legend that tree item will expand or collapse as well
85            as open the layer properties dialog. The state of the tree item
86            should not be affected.
87    
88            * Thuban/UI/legend.py (LegendTree.__init__): Add instance variable
89            preventExpandCollapse and subscribe to expanding and collapsing
90            events.
91            (LegendTree.OnItemExpandCollapse): New. Responds to expanding and
92            collapsing events and will veto the event if it has been triggered
93            by the user double clicking on a layer.
94            (LegendTree._OnItemActivated): Set preventExpandCollapse to indicate
95            that an expanding/collapsing event should be vetoed.
96    
97    2003-06-13  Bernhard Herzog  <[email protected]>
98    
99            * Thuban/UI/classifier.py (Classifier.OnClose)
100            (Classifier.map_layers_removed)
101            (Classifier.layer_shapestore_replaced): Unsubscribe the messages
102            in OnClose and not in map_layers_removed or
103            layer_shapestore_replaced to make sure it always happens when the
104            dialog is closed
105    
106    2003-06-13  Jonathan Coles   <[email protected]>
107    
108            This puts back a fix for Windows where a panel is needed so that
109            the background of the table view appears correctly.
110    
111            * Thuban/UI/tableview.py (TableFrame.__init__): Add a panel
112            object that can be used by derived classes to place any
113            controls (including the grid) onto.
114            (QueryTableFrame.__init__): Use the panel as the parent window
115            for all the controls. Reparent the grid so that the panel is
116            the parent. Call UpdateStatusText() to correctly initialize
117            the status bar.
118    
119    2003-06-13  Jonathan Coles   <[email protected]>
120    
121            * Thuban/UI/dialogs.py (ThubanFrame): New: a class that inherits
122            from wxFrame (as opposed to wxDialog like the other classes)
123            but otherwise behaves like the other classes. This is needed
124            for the TableView which isn't really a dialog and needs to
125            have a status bar and control buttons.
126    
127            * Thuban/UI/tableview.py (TableGrid.__init__): Create an
128            instance variable to keep track of how many rows are selected.
129            Subscribe once to the the events we are interested in.
130            (ThubanGrid.OnRangeSelect): Only handle event if event handling
131            hasn't been turned off.
132            (ThubanGrid.OnSelectCell): Only handle event if event handling
133            hasn't been turned off.
134            (ThubanGrid.ToggleEventListeners): Rather than subscribe None
135            as an event listener (which changes the event handler stack)
136            simply set an instance variable to False. This is checked in
137            the event handlers.
138            (ThubanGrid.GetNumberSelected): Return the number of currently
139            selected rows.
140            (TableFrame): Inherit from ThubanFrame so we can have a
141            status bar and control buttons.
142            (QueryTableFrame.__init__): Create a status bar. Fixes RTbug #1942.
143            Explicitly set which items are selected in the operator choice and
144            action choice so there is always a valid selection. Fixes RTbug #1941.
145            Subscribe to grid cell selection events so we can update the
146            status bar.
147            (QueryTableFrame.UpdateStatusText): Update the status bar with
148            how many rows are in the grid, how many columns, and how many
149            rows are selected.
150            (QueryTableFrame.OnGridSelectRange, QueryTableFrame.OnGridSelectCell):
151            Call UpdateStatusText when cells are (de)selected.
152            (QueryTableFrame.OnQuery): Use the string value in the value
153            combo if either the selected item index is 0 or if the string
154            cannot be found in the predefined list (this happens if the
155            user changes the text). Fixes RTbug #1940.
156            Only turn off the grid event listeners if there a query comes
157            back with a none empty list of ids. in the case that the list
158            is empty this causes a grid.ClearSelection() call to actually
159            clear the grid selection which causes the selected items in
160            the map to be deselected. Fixes RTbug #1939.
161    
162            * test/test_save.py (XMLWriterTest.Encode): Check return values.
163            Fixes RTbug #1851.
164    
165    2003-06-13  Bernhard Herzog  <[email protected]>
166    
167            * Thuban/UI/identifyview.py (IdentifyView.__init__): Call
168            self.selected_shape with the current selection to make sure the
169            contents of the dialog are up to date when it's shown for the
170            first time.
171            The dialog used to work without this by luck. The recent fix to
172            the connector module 'broke' a 'feature' the identify view was
173            relying on, i.e that subscribing to a message in response to
174            receiving a message of that type would mean that the new
175            subscriber would also be called for the same message.
176            
177    2003-06-12  Jonathan Coles   <[email protected]>
178    
179            * extensions/thuban/gdalwarp.cpp: Removed debug printing as
180            the image is rendered. Fixes RTbug #1937.
181    
182    2003-06-12  Jonathan Coles   <[email protected]>
183    
184            * Thuban/Lib/fileutil.py: As is done under Windows, create the
185            user directory if it doesn't exist on a posix system.
186            Fixes RTbug #1815.
187    
188            * Thuban/Model/resource.py (get_user_proj_files): Moved the
189            called to get_application_dir here, so that the directory
190            will only be called if this method is invoked.
191    
192            * Thuban/UI/projdialog.py (ProjFrame.__DoOnProjAvail): Clear
193            the projfilepath if no projection is selected.
194    
195    2003-06-12  Jonathan Coles   <[email protected]>
196    
197            * Thuban/UI/legend.py (ScaleBarBitmap.__SetScale): Don't draw
198            the scalebar if the current map has no projection set.
199    
200            * Thuban/UI/projdialog.py (ProjFrame.__DoOnProjAvail): Set the
201            projfilepath label to just the basename of the projection file
202            rather than include the entire path.
203    
204            * Thuban/Model/resource.py: Fix missed proj functions that
205            needed to be renamed.
206    
207    2003-06-12  Jonathan Coles   <[email protected]>
208    
209            * Thuban/Model/classification.py: Removed assert statements that
210            tested if the variable was an instance of Color.
211    
212            * Thuban/Model/color.py (Color): Remove commented code that isn't
213            used.
214            (Transparent): Renamed from NoColor. Doesn't inherit from Color.
215            Fixes RTbug #1835.
216            (Transparent.__eq__, Transparent.__ne, Transparent.__repr): New.
217            Needed now that the class doesn't inherit from Color.
218    
219    2003-06-12  Jonathan Coles   <[email protected]>
220    
221            * test/test_save.py (XMLWriterTest.testEncode): Explicitly
222            check unicode strings.
223    
224            * test/test_layer.py: Check for existence of gdal.
225    
226    2003-06-12  Jonathan Coles   <[email protected]>
227        
228            * Thuban/Model/xmlreader.py: New. Contains the XMLReader class
229            that was in load.py
230    
231            * Thuban/Model/xmlwriter.py: New. Contains the XMLWriter class
232            that was in save.py
233    
234    2003-06-12  Jonathan Coles   <[email protected]>
235    
236            This is largely a collection of bug fixes. We also handle the
237            case where gdal is not on the system. The XMLReader and XMLWriter
238            classes were moved into there own files to resolve some circular
239            import references and because they shouldn't really be in the
240            file that is dediciated to reading/writing session files since
241            they are also used elsewhere.
242    
243            * Thuban/Model/classgen.py: Renamed functions to follow the
244            function_names_with_underscores style. Fixes RTbug #1903.
245            (calculate_quantiles): Raise ValueError if 'percents' is invalid.
246    
247            * Thuban/Model/layer.py: Import gdal only if it available.
248            (RasterLayer): Handle the case where the gdal library is unavailable.
249            Addresses RTbug #1877.
250    
251            * Thuban/Model/load.py (XMLReader): Moved into seperate file
252            xmlreader.py.
253    
254    2003-06-12  Jonathan Coles   <[email protected]>
255    
256            This is largely a collection of bug fixes. We also handle the
257            case where gdal is not on the system. The XMLReader and XMLWriter
258            classes were moved into there own files to resolve some circular
259            import references and because they shouldn't really be in the
260            file that is dediciated to reading/writing session files since
261            they are also used elsewhere.
262    
263            * Thuban/Model/classgen.py: Renamed functions to follow the
264            function_names_with_underscores style. Fixes RTbug #1903.
265            (calculate_quantiles): Raise ValueError if 'percents' is invalid.
266    
267            * Thuban/Model/layer.py: Import gdal only if it available.
268            (RasterLayer): Handle the case where the gdal library is unavailable.
269            Addresses RTbug #1877.
270    
271            * Thuban/Model/load.py (XMLReader): Moved into seperate file
272            xmlreader.py.
273    
274            * Thuban/Model/save.py (escape, XMLWriter): Moved into seperate
275            file xmlwriter.py.
276    
277            * Thuban/Model/resource.py: Renamed functions to following the
278            function_names_with_underscores style.
279            (has_gdal_support): New function that returns true if the gdal
280            library is available. Addresses RTbug #1877.
281    
282            * Thuban/UI/application.py (ThubanApplication.OpenSession):
283            Display a message box if the gdal library is not available, but
284            only if there are any layers that would use it. Addresses RTbug #1877.
285    
286            * Thuban/UI/classgen.py: Use renamed projection resource functions.
287            (GenUniformPanel.__CalcStepping): Fix a slight discrepency
288            when using integers versus floats.
289    
290            * Thuban/UI/mainwindow.py (_has_gdal_support): New. Used to
291            determine if the "Add Image Layer" menu option should be
292            greyed out or not. Addresses RTbug #1877.
293    
294            * Thuban/UI/projdialog.py: Use renamed projection resource functions.
295    
296            * Thuban/UI/renderer.py (MapRenderer.render_map): Only try to
297            optimize if a raster layer is visible. Fixes RTbug #1931.
298            Only draw the raster layer if the gdal library is available.
299            Addresses RTbug #1877.
300    
301            * test/test_classgen.py: Add tests for generate_singletons,
302            generate_uniform_distribution, generate_quantiles. Fixes RTbug #1903.
303            (test_calculate_quantiles): Fix some tests to catch the new
304            ValueError that is raised.
305    
306            * test/test_proj.py: Use renamed projection resource functions.
307    
308            * test/test_save.py (SaveSessionTest.testClassifiedLayer): New
309            test for saving classified layers. Fixes RTbug #1902.
310            (XMLWriterTest): New. Tests the XMLWriter class. Fixes RTbug #1851.
311    
312    2003-06-12  Jan-Oliver Wagner <[email protected]>
313    
314            Fix for http://intevation.de/rt/webrt?serial_num=1900.
315    
316            * Thuban/UI/multiplechoicedialog.py: New. A multiple choice dialog.
317    
318            * Thuban/UI/mainwindow.py: import wxMultipleChoiceDialog from
319            multiplechoicedialog.py rather than from the wxPython library.
320    
321    2003-06-11  Frank Koormann  <[email protected]>
322    
323            * Thuban/Lib/fileutil.py (get_application_dir): Minor stability
324            update.
325    
326    2003-06-11  Frank Koormann  <[email protected]>
327    
328            * Thuban/Lib/fileutil.py (get_application_dir): New function to
329            determine the absolute .thuban/thuban directory under
330            "posix" (os.expanduser) and "nt" (read AppData registry key).
331    
332            * Thuban/Model/resource.py: Use get_application_dir
333    
334            * Thuban/UI/application.py (ThubanApplication.read_startup_files):
335            Use get_application_dir.
336    
337    2003-06-10  Bernhard Herzog  <[email protected]>
338    
339            * Thuban/UI/tableview.py (LayerTableFrame.__init__): Subscribe to
340            the messages MAP_LAYERS_REMOVED messages
341            (LayerTableFrame.OnClose): Unsubscribe from it.
342            (LayerTableFrame.map_layers_removed): New. Receiver for
343            MAP_LAYERS_REMOVED. Close the dialog when the layer whose the
344            dialog is showing is removed.
345    
346    2003-06-10  Bernhard Herzog  <[email protected]>
347    
348            * Thuban/Lib/connector.py (Connector.Issue): Iterate over a copy
349            of the receivers list so that unsubscribing in a receiver doesn't
350            modify it while iterating over it.
351    
352            * test/test_connector.py
353            (ConnectorTest.test_disconnect_in_receiver): New. Test whether
354            unsubscribing in a receiver works correctly. See docstring for
355            details
356    
357    2003-06-10  Bernhard Herzog  <[email protected]>
358    
359            * Thuban/Model/messages.py (LAYER_SHAPESTORE_REPLACED): New
360            message.
361    
362            * Thuban/Model/layer.py (Layer.SetShapeStore): Send
363            LAYER_SHAPESTORE_REPLACED when the shapestore changes. A
364            LAYER_CHANGED will still be sent if the classification changes.
365    
366            * Thuban/UI/classifier.py (Classifier.__init__): Add the map as
367            parameter so we can subscribe to some of its messages
368            (Classifier.__init__): Subscribe to the map's MAP_LAYERS_REMOVED
369            and the layer's LAYER_SHAPESTORE_REPLACED
370            (Classifier.unsubscribe_messages): New. Unsubscribe from message
371            subscribed to in __init__
372            (Classifier.map_layers_removed)
373            (Classifier.layer_shapestore_replaced): receivers for the messages
374            subscribed to in __init__. Unsubscribe and close the dialog
375    
376            * Thuban/UI/mainwindow.py (MainWindow.OpenLayerProperties): Pass
377            the map to the Classifier dialog
378    
379            * test/test_layer.py (SetShapeStoreTests): Derive from
380            SubscriberMixin as well so we can test messages
381            (SetShapeStoreTests.setUp): Subscribe to some of the layer's
382            messages
383            (SetShapeStoreTests.tearDown): Clear the messages again
384            (SetShapeStoreTests.test_sanity): Expand the doc-string and check
385            for the modified flag too
386            (SetShapeStoreTests.test_set_shape_store_modified_flag): New test
387            to check whether SetShapeStore sets the modified flag
388            (SetShapeStoreTests.test_set_shape_store_different_field_name)
389            (SetShapeStoreTests.test_set_shape_store_same_field)
390            (SetShapeStoreTests.test_set_shape_store_same_field_different_type):
391            Add tests for the messages. This checks both the new
392            LAYER_SHAPESTORE_REPLACED and the older LAYER_CHANGED
393    
394    2003-06-06  Jan-Oliver Wagner <[email protected]>
395    
396            * Thuban/UI/mainwindow.py: Improved and partly added help texts for
397            the menu items.
398    
399    2003-06-05  Frank Koormann  <[email protected]>
400    
401            * Thuban/UI/identifyview.py (IdentifyView.__init__):
402            Layout reimplemented without panel. Make life easier to fit the list
403            in the dialog.
404    
405    2003-06-05  Frank Koormann  <[email protected]>
406    
407            * Thuban/UI/projdialog.py (ProjFrame.__init__): Fill the projchoice
408            once on initialisation (Former implementation resulted in multiple
409            entries for each projection).
410            (ProjFrame.__FillAvailList): selectProj as second optional parameter,
411            if set, select the projection found under the specified name. This
412            overwrites any other selection estimate.
413            Removed projchoice filling from this method.
414            (ProjFrame._OnSave, ProjFrame._OnAddToList):
415            Updated call of ProjFrame.__FillAvailList
416            (LCCPanel._DoLayout): Moved parameter controls in more common order.
417    
418            * Resources/Projections/defaults.proj: Extended defaults representing
419            various common European projections.
420    
421  2003-06-05  Frank Koormann  <[email protected]>  2003-06-05  Frank Koormann  <[email protected]>
422    
423          * Thuban/UI/identifyview.py (IdentifyView.__init__):          * Thuban/UI/identifyview.py (IdentifyView.__init__):

Legend:
Removed from v.1134  
changed lines
  Added in v.1224

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26