/[thuban]/trunk/thuban/Thuban/UI/classifier.py
ViewVC logotype

Log of /trunk/thuban/Thuban/UI/classifier.py

Parent Directory Parent Directory | Revision Log Revision Log


Links to HEAD: (view) (annotate)
Sticky Revision:

Revision 2560 - (view) (annotate) - [select for diffs]
Modified Tue Feb 8 20:25:22 2005 UTC (20 years, 1 month ago) by bh
File length: 49088 byte(s)
Diff to previous 2556 , to selected 2366
Compatibility with wxPython 2.5.  The changes should make it work
better with 2.5 while still keeping compatibility with 2.4.  There
are still problems with 2.5, though.

* Thuban/UI/dock.py (DockableWindow.__CreateBorder): Pass the size
of a spacer as a single item.

* Thuban/UI/classifier.py (ClassGroupPropertiesCtrl): Derive only
from wxControl

* Thuban/UI/legend.py (LegendTree): When running with wxPython <
2.5, add an implementation of the GetFirstChild method that does
not require the second parameter.
(LegendTree.find_layer, LegendTree._OnMsgMapLayersAdded)
(LegendTree._OnMsgMapLayersRemoved, LegendTree.DeleteAllItems)
(LegendTree.DeleteChildren, LegendTree.__ShowHideLayer): Do not
pass the second parameter to GetFirstChild


Revision 2556 - (view) (annotate) - [select for diffs]
Modified Mon Feb 7 13:46:53 2005 UTC (20 years, 1 month ago) by bernhard
File length: 49098 byte(s)
Diff to previous 2551 , to selected 2366
	* Thuban/UI/classifier.py (ClassGrid.DeleteSelectedRows):
	Enable translation for message string.


Revision 2551 - (view) (annotate) - [select for diffs]
Modified Thu Jan 27 14:19:41 2005 UTC (20 years, 1 month ago) by jonathan
File length: 49095 byte(s)
Diff to previous 2386 , to selected 2366
Add a new dialog box for raster layers. The dialog box allows
the user to toggle a mask that is generated by ProjectRasterFile
and is used to only draw the real parts of the projected image.


Revision 2386 - (view) (annotate) - [select for diffs]
Modified Thu Oct 7 14:43:45 2004 UTC (20 years, 5 months ago) by jan
File length: 52379 byte(s)
Diff to previous 2376 , to selected 2366
(ID_SELPROP_SPINCTRL): Renamed to ID_SELPROP_SPINCTRL_LINEWIDTH.
(ID_SELPROP_SPINCTRL_LINEWIDTH): New Id replaces ID_SELPROP_SPINCTRL.
(ID_SELPROP_SPINCTRL_SIZE): New Id.
(SelectPropertiesDialog.__init__): Added a second spin control
for the size in case the corresponding layer is of point type.
(SelectPropertiesDialog._OnSpin): Renamed to _OnSpinLineWidth.
(SelectPropertiesDialog._OnSpinLineWidth): New. Former _OnSpin.
(SelectPropertiesDialog._OnSpinSize): New. Set size of property
and refresh preview.


Revision 2376 - (view) (annotate) - [select for diffs]
Modified Sun Oct 3 21:23:25 2004 UTC (20 years, 5 months ago) by jan
File length: 51066 byte(s)
Diff to previous 2366
(ClassDataPreviewer.Draw): Added doc-string.
Also, now there is a return value that indicates whether the drawing
size exceeded the given rect extent and if so the new extent.
Finally, point objects are drawn depending on the size. If either
the width or height is exceeded, the new extent is returned.
(ClassRenderer.Draw): Now when calling the previewer drawing function,
evaluate the return value and, if not None, adapt the grid widget size
accordingly and redraw again.


Revision 2366 - (view) (annotate) - [selected]
Modified Fri Oct 1 18:24:10 2004 UTC (20 years, 5 months ago) by joey
File length: 49812 byte(s)
Diff to previous 2362
Register properties dialog classes for both provided layer classes/types


Revision 2362 - (view) (annotate) - [select for diffs]
Modified Fri Oct 1 18:00:42 2004 UTC (20 years, 5 months ago) by joey
File length: 49651 byte(s)
Diff to previous 2200 , to selected 2366
Unify arguments for general use through properties-dialog selector,
the map can be retrieved through the parent and doesn't require an
argument of its own.


Revision 2200 - (view) (annotate) - [select for diffs]
Modified Fri May 7 20:20:43 2004 UTC (20 years, 10 months ago) by jan
File length: 49647 byte(s)
Diff to previous 1539 , to selected 2366
(SelectPropertiesDialog.__GetColor): Now calls the abstract ColorDialog
instead of wxColourDialog.  This also removed the dependency to Color
class conversion from this function.


Revision 1539 - (view) (annotate) - [select for diffs]
Modified Fri Aug 1 14:27:57 2003 UTC (21 years, 7 months ago) by bh
File length: 49709 byte(s)
Diff to previous 1527 , to selected 2366
Import the SHAPETYPE_* constants from data
instead of layer.


Revision 1527 - (view) (annotate) - [select for diffs]
Modified Wed Jul 30 15:43:28 2003 UTC (21 years, 7 months ago) by jonathan
File length: 49686 byte(s)
Diff to previous 1464 , to selected 2366
Add docstrings.


Revision 1464 - (view) (annotate) - [select for diffs]
Modified Fri Jul 18 18:20:40 2003 UTC (21 years, 7 months ago) by bh
File length: 46758 byte(s)
Diff to previous 1452 , to selected 2366
* Thuban/UI/messages.py (MAP_REPLACED): New message.

* Thuban/UI/viewport.py (ViewPort.SetMap): Issue MAP_REPLACED
after the new map has been assigned

* Thuban/UI/mainwindow.py (MainWindow.delegated_messages):
Delegate MAP_REPLACED to the canvas too
(MainWindow.prepare_new_session): Removed. Thanks to the new
MAP_REPLACED message it's no longer needed
(MainWindow.OpenSession, MainWindow.NewSession):
prepare_new_session has been removed.

* Thuban/UI/classifier.py (Classifier.__init__): Subscribe to
MAP_REPLACED so that we can close the dialog if a new map is set.
(Classifier.unsubscribe_messages): Unsubscribe from MAP_REPLACED
(Classifier.map_replaced): Handle MAP_REPLACED by closing the
dialog

* test/test_viewport.py (SimpleViewPortTest)
(SimpleViewPortTest.test_default_size): Add doc-strings
(ViewPortTest.setUp): Bind map to self.map so we can use it in
tests. Subscribe to MAP_REPLACED messages too.
(ViewPortTest.tearDown): No need to explicitly unsubscribe
(ViewPortTest.test_set_map): New test for the SetMap method.


Revision 1452 - (view) (annotate) - [select for diffs]
Modified Fri Jul 18 12:57:59 2003 UTC (21 years, 7 months ago) by bh
File length: 46357 byte(s)
Diff to previous 1447 , to selected 2366
* Thuban/Model/layer.py (Layer.__init__): Rename
classificationField to classificatin_column and init it here so
that it can be used in SetClassificationColumn
(Layer.GetClassificationColumn, Layer.GetClassificationField):
Rename to GetClassificationColumn.
(Layer.SetClassificationColumn, Layer.SetClassificationField):
Rename to SetClassificationColumn and issue a LAYER_CHANGED
message if the column changes.
(Layer._classification_changed, Layer.ClassChanged): Rename to
_classification_changed. Update the callers.
(Layer.SetShapeStore): Further field->column renames.

* Thuban/Model/load.py (SessionLoader.start_classification)
(SessionLoader.start_clpoint): Updates because of
field->column method name changes in the Layer class

* Thuban/Model/save.py (SessionSaver.write_classification): Updates
because of field->column method name changes in the Layer class

* Thuban/UI/classifier.py (Classifier.__init__)
(Classifier._OnTry, Classifier._OnRevert): Updates because of
field->column method name changes in the Layer class

* Thuban/UI/renderer.py (MapRenderer.draw_shape_layer): Updates
because of field->column method name changes in the Layer class

* Thuban/UI/viewport.py (ViewPort.find_shape_at): Updates because
of field->column method name changes in the Layer class

* test/test_save.py (SaveSessionTest.testClassifiedLayer)
(SaveSessionTest.testClassifiedLayer): Update because of
field->column method name changes in the Layer class

* test/test_layer.py (SetShapeStoreTests.setUp)
(SetShapeStoreTests.test_sanity): Update because of field->column
method name changes in the Layer class
(TestLayerModification.setUp): Subscribe to LAYER_CHANGED as well
(TestLayerModification.test_sanity)
(TestLayerModification.test_initial_settings): remove unsued code
and rename to test_sanity.
(TestLayerModification.test_set_classification): New test for
SetClassification and SetClassificationField.


Revision 1447 - (view) (annotate) - [select for diffs]
Modified Thu Jul 17 14:59:29 2003 UTC (21 years, 7 months ago) by jonathan
File length: 46354 byte(s)
Diff to previous 1433 , to selected 2366
(Classifier.__BuildClassification):
        Return both the new class and the field name.


Revision 1433 - (view) (annotate) - [select for diffs]
Modified Wed Jul 16 13:24:25 2003 UTC (21 years, 7 months ago) by jonathan
File length: 46292 byte(s)
Diff to previous 1342 , to selected 2366
(ClassGrid.CreateTable): Add fieldType parameter.
(ClassTable.Reset): Add fieldType parameter and use it, rather
        than asking the classification.
(Classifier.__init__): Remember the original class's field
        and ask the layer for the field type, rather than the classification.
(Classifier.__SetGridTable): Retrieve the field and field type
        for the table because they are not in the classification.
(Classifier._OnTry, Classifier._OnRevert): Set the classification
        field on the layer in addition to the classification itself.


Revision 1342 - (view) (annotate) - [select for diffs]
Modified Tue Jul 1 16:10:54 2003 UTC (21 years, 8 months ago) by jonathan
File length: 46394 byte(s)
Diff to previous 1307 , to selected 2366
Fixes RTbug #1971.
(Classifier.__BuildClassification, Classifier.__SetGridTable):
        Call Classification.SetFieldInfo() instead of SetFieldType.


Revision 1307 - (view) (annotate) - [select for diffs]
Modified Thu Jun 26 17:00:17 2003 UTC (21 years, 8 months ago) by jonathan
File length: 46429 byte(s)
Diff to previous 1302 , to selected 2366
(Classifier.__EnableButtons):
        Reset the status of the buttons as the situation warrants,
        but in a better more reliable way by not relying on the
        current status to determine what needs to change.


Revision 1302 - (view) (annotate) - [select for diffs]
Modified Wed Jun 25 09:39:33 2003 UTC (21 years, 8 months ago) by jonathan
File length: 45779 byte(s)
Diff to previous 1219 , to selected 2366
(Classifier.EditSymbol): The parent
        of the SelectPropertiesDialog should be self so the window
        appears on top.
(ClassGroupPropertiesCtrl.DoEdit): The parent
        of the SelectPropertiesDialog should be self so the window
        appears on top.


Revision 1219 - (view) (annotate) - [select for diffs]
Modified Mon Jun 16 17:42:54 2003 UTC (21 years, 8 months ago) by bh
File length: 45742 byte(s)
Diff to previous 1207 , to selected 2366
Update to the layer interface: Direct access to the table,
shapetable, shapefile and filename attributes is now actively
deprecated by issuing deprecation warnings for all places where
this happens.

* Thuban/Model/layer.py (Layer.__getattr__): New. Implement access
to the instance variables table, shapetable, shapefile and
filename via __getattr__ so that we can issue a deprecation
warning.
(Layer.SetShapeStore): Don't set the deprecated instance variables
any more
(Layer.SetShapeStore): Don't use deprecated layer instance
variables
(Layer.Destroy): No need to explicitly remove the instance
variables any more
(Layer.GetFieldType, Layer.Shape): Don't use deprecated layer
instance variables

* Thuban/UI/classgen.py (ClassGenDialog.__init__)
(GenUniformPanel._OnRetrieve, GenUniquePanel._OnRetrieve)
(GenQuantilesPanel.GetList, GenQuantilesPanel.OnRetrieve): Don't
use deprecated layer instance variables

* Thuban/UI/classifier.py (Classifier.__init__): Don't use
deprecated layer instance variables

* Thuban/UI/identifyview.py (IdentifyListCtrl.selected_shape)
(IdentifyGridCtrl.selected_shape): Don't set the deprecated layer
instance variables

* Thuban/UI/tableview.py (LayerTableGrid.select_shapes): Don't use
deprecated layer instance variables

* Thuban/UI/mainwindow.py (MainWindow.LayerShowTable): Don't use
deprecated layer instance variables

* Thuban/Model/save.py (SessionSaver.write_layer): Don't use
deprecated layer instance variables

* Thuban/UI/renderer.py (MapRenderer.draw_shape_layer)
(MapRenderer.polygon_render_param): Don't use deprecated layer instance
variables

* test/runtests.py (main): Turn Thuban's deprecation warnings into
errors so that they're cought by the tests

* test/test_load.py (TestSingleLayer.test): Don't use deprecated
layer instance variables


Revision 1207 - (view) (annotate) - [select for diffs]
Modified Fri Jun 13 18:16:10 2003 UTC (21 years, 8 months ago) by bh
File length: 45707 byte(s)
Diff to previous 1142 , to selected 2366
(Classifier.OnClose)
(Classifier.map_layers_removed)
(Classifier.layer_shapestore_replaced): Unsubscribe the messages
in OnClose and not in map_layers_removed or
layer_shapestore_replaced to make sure it always happens when the
dialog is closed


Revision 1142 - (view) (annotate) - [select for diffs]
Modified Tue Jun 10 09:41:57 2003 UTC (21 years, 9 months ago) by bh
File length: 45747 byte(s)
Diff to previous 1101 , to selected 2366
* Thuban/Model/messages.py (LAYER_SHAPESTORE_REPLACED): New
message.

* Thuban/Model/layer.py (Layer.SetShapeStore): Send
LAYER_SHAPESTORE_REPLACED when the shapestore changes. A
LAYER_CHANGED will still be sent if the classification changes.

* Thuban/UI/classifier.py (Classifier.__init__): Add the map as
parameter so we can subscribe to some of its messages
(Classifier.__init__): Subscribe to the map's MAP_LAYERS_REMOVED
and the layer's LAYER_SHAPESTORE_REPLACED
(Classifier.unsubscribe_messages): New. Unsubscribe from message
subscribed to in __init__
(Classifier.map_layers_removed)
(Classifier.layer_shapestore_replaced): receivers for the messages
subscribed to in __init__. Unsubscribe and close the dialog

* Thuban/UI/mainwindow.py (MainWindow.OpenLayerProperties): Pass
the map to the Classifier dialog

* test/test_layer.py (SetShapeStoreTests): Derive from
SubscriberMixin as well so we can test messages
(SetShapeStoreTests.setUp): Subscribe to some of the layer's
messages
(SetShapeStoreTests.tearDown): Clear the messages again
(SetShapeStoreTests.test_sanity): Expand the doc-string and check
for the modified flag too
(SetShapeStoreTests.test_set_shape_store_modified_flag): New test
to check whether SetShapeStore sets the modified flag
(SetShapeStoreTests.test_set_shape_store_different_field_name)
(SetShapeStoreTests.test_set_shape_store_same_field)
(SetShapeStoreTests.test_set_shape_store_same_field_different_type):
Add tests for the messages. This checks both the new
LAYER_SHAPESTORE_REPLACED and the older LAYER_CHANGED


Revision 1101 - (view) (annotate) - [select for diffs]
Modified Fri May 30 06:28:39 2003 UTC (21 years, 9 months ago) by jonathan
File length: 44959 byte(s)
Diff to previous 1058 , to selected 2366
Remove unused import of ClassGenerator.


Revision 1058 - (view) (annotate) - [select for diffs]
Modified Tue May 27 11:30:29 2003 UTC (21 years, 9 months ago) by frank
File length: 44975 byte(s)
Diff to previous 977 , to selected 2366
Dialog derived from NonModalNonParentDialog


Revision 977 - (view) (annotate) - [select for diffs]
Modified Thu May 22 11:39:51 2003 UTC (21 years, 9 months ago) by frank
File length: 44939 byte(s)
Diff to previous 935 , to selected 2366
(Classifier.__init__, SelectPropertiesDialog.__init__)
	UI polishing updates: Place main buttons (OK, Cancel, etc) in the
	lower right corner, center labels for selections, initialize controls
	in reasonable order for keyboard navigation.


Revision 935 - (view) (annotate) - [select for diffs]
Modified Tue May 20 15:24:17 2003 UTC (21 years, 9 months ago) by jonathan
File length: 45044 byte(s)
Diff to previous 878 , to selected 2366
(Classifier.__init__): Rearrange how
        the dialog is constructed so that we can support layers that
        do not have classifications.
(Classifier._OnTry): Only build a classification if the layer supports one.


Revision 878 - (view) (annotate) - [select for diffs]
Modified Fri May 9 16:32:31 2003 UTC (21 years, 10 months ago) by jonathan
File length: 44437 byte(s)
Diff to previous 835 , to selected 2366
Explicit imports.
(ClassTable.GetValueAsCust, ClassTable.__ParseInput,
ClassTable.SetValueAsCustom): Reworked to use new Range class.


Revision 835 - (view) (annotate) - [select for diffs]
Modified Tue May 6 15:52:41 2003 UTC (21 years, 10 months ago) by bh
File length: 44533 byte(s)
Diff to previous 813 , to selected 2366
(Classifier.__init__)
(Classifier.__init__): Adapt to new table interface


Revision 813 - (view) (annotate) - [select for diffs]
Modified Mon May 5 15:04:21 2003 UTC (21 years, 10 months ago) by jonathan
File length: 44550 byte(s)
Diff to previous 783 , to selected 2366
(Classifier.__init__): Rearrange the
        order that the controls are created so that tabbing works correctly.
(SelectPropertiesDialog.__init__): Rearrange the order that the
        controls are created so that tabbing works correctly.


Revision 783 - (view) (annotate) - [select for diffs]
Modified Tue Apr 29 17:29:32 2003 UTC (21 years, 10 months ago) by jonathan
File length: 44688 byte(s)
Diff to previous 782 , to selected 2366
Remove Thuban.common import.


Revision 782 - (view) (annotate) - [select for diffs]
Modified Tue Apr 29 16:53:55 2003 UTC (21 years, 10 months ago) by jonathan
File length: 44716 byte(s)
Diff to previous 712 , to selected 2366
Remove all uses of Str2Num.
(ClassTable.SetValueAsCustom): Rename keyword argument in
        ClassGroup* constructors to match argument name.


Revision 712 - (view) (annotate) - [select for diffs]
Modified Wed Apr 23 08:46:40 2003 UTC (21 years, 10 months ago) by jonathan
File length: 44673 byte(s)
Diff to previous 671 , to selected 2366
(Classifier.__init__): Use a wxChoice control instead of a wxComboBox.


Revision 671 - (view) (annotate) - [select for diffs]
Modified Tue Apr 15 18:09:47 2003 UTC (21 years, 10 months ago) by bh
File length: 44544 byte(s)
Diff to previous 661 , to selected 2366
* Thuban/__init__.py (_): Implement the translation function for
real using the python gettext module.

* Thuban/UI/classifier.py (ClassTable.GetRowLabelValue): Don't
translate empty strings.

* Thuban/UI/application.py (ThubanApplication.read_startup_files):
Add a missing space to a warning message

* po/README: New. Notes about the management of the translation
files.

* po/Makefile: New. Makefile to help manage the translation files.

* po/es.po: New. Spanish translation by Daniel Calvelo Aros

* MANIFEST.in: Include the *.mo files in Resources/Locale and the
translations and support files in po/

* setup.py (data_files): Add the *.mo files to the data_files too

* README: Add note about the translations when building from CVS


Revision 661 - (view) (annotate) - [select for diffs]
Modified Mon Apr 14 14:16:00 2003 UTC (21 years, 10 months ago) by jonathan
File length: 44547 byte(s)
Diff to previous 650 , to selected 2366
(Classifier.__init__): Add a top level panel to the dialog so that the
background colors are consistent under Windows.


Revision 650 - (view) (annotate) - [select for diffs]
Modified Fri Apr 11 14:27:41 2003 UTC (21 years, 11 months ago) by jonathan
File length: 44450 byte(s)
Diff to previous 638 , to selected 2366
Refactored ID's from ID_CLASSIFY_* to ID_PROPERTY_*.
(Classifier.__init__): Minor changes to the layout.
(Classifier._OnTitleChanged): Listen for when the user edits the
        title and update the dialog's title and the layer's title.


Revision 638 - (view) (annotate) - [select for diffs]
Modified Thu Apr 10 14:35:20 2003 UTC (21 years, 11 months ago) by jonathan
File length: 44305 byte(s)
Diff to previous 630 , to selected 2366
(ClassTable): Add a new column for the "Visible" check boxes.
(Classifier): Rename the buttons and refactor the code to match the new labels.


Revision 630 - (view) (annotate) - [select for diffs]
Modified Wed Apr 9 10:10:06 2003 UTC (21 years, 11 months ago) by jonathan
File length: 43670 byte(s)
Diff to previous 615 , to selected 2366
Removed a lot of debugging code.
(Classifier._SetClassification): Callback method so that the
        class generator can set the classification in the grid.
(ClassGroupPropertiesCtrl): New. Encapsulates the drawing and
        editing of a group properties class into a wxWindows control.


Revision 615 - (view) (annotate) - [select for diffs]
Modified Mon Apr 7 08:57:20 2003 UTC (21 years, 11 months ago) by jonathan
File length: 42348 byte(s)
Diff to previous 611 , to selected 2366
Now that we can depend on the order in
        a Classification and have methods to manipulate that order we don't
        need to use our own data structures in the grid. We can simply make
        the grid/table access the information they need from a copy of
        the classification object.
(Classifier._OnCloseBtn): Event handler for when the user clicks
        'Close'. This is needed so if the user applies changes and then
        continues to change the table the user has the option of discarding
        the most recent changes and keeping what they applied.


Revision 611 - (view) (annotate) - [select for diffs]
Modified Fri Apr 4 16:34:46 2003 UTC (21 years, 11 months ago) by jonathan
File length: 40941 byte(s)
Diff to previous 610 , to selected 2366
(Classifier.__SelectField): Move the
    call to SetSelection out of the method and before the call
    to __SelectField in __init__. This prevents a recursion of events
    when _OnFieldSelect is triggered by the user.


Revision 610 - (view) (annotate) - [select for diffs]
Modified Fri Apr 4 13:56:59 2003 UTC (21 years, 11 months ago) by jonathan
File length: 40792 byte(s)
Diff to previous 606 , to selected 2366
Rename Color.None to Color.Transparent.


Revision 606 - (view) (annotate) - [select for diffs]
Modified Fri Apr 4 12:16:39 2003 UTC (21 years, 11 months ago) by jonathan
File length: 40757 byte(s)
Diff to previous 576 , to selected 2366
Fix assert calls.
(ClassGrid._OnCellDClick): Call up to the classifier to open the
        dialog to edit the groups properties.
(ClassGrid._OnCellResize): Make sure that the scollbars are drawn
        correctly if a cell is resized.
(ClassTable.SetClassification): New. Changes the classification
        that is in the table.
(ClassTable.__SetRow): Allow groups to be prepended.
(Classifier): New code for opening the EditProperties and
        GenerateRanges dialogs.
(SelectPropertiesDialog.__GetColor): Only set the color in the
        color dialog if the current color is not None.


Revision 576 - (view) (annotate) - [select for diffs]
Modified Mon Mar 31 18:31:17 2003 UTC (21 years, 11 months ago) by jonathan
File length: 39193 byte(s)
Diff to previous 570 , to selected 2366
Commented out some debugging statements.
(ClassDataPreviewer.Draw): Draw rectangles for polygon layers per
        RTbug #1769.


Revision 570 - (view) (annotate) - [select for diffs]
Modified Fri Mar 28 17:06:26 2003 UTC (21 years, 11 months ago) by jonathan
File length: 39125 byte(s)
Diff to previous 560 , to selected 2366
Support for highlighting a specific
        group within the grid when the classification dialog is opened.
        Also contains a lot of debugging printouts which will later
        be removed.


Revision 560 - (view) (annotate) - [select for diffs]
Modified Wed Mar 26 11:05:47 2003 UTC (21 years, 11 months ago) by jonathan
File length: 36558 byte(s)
Diff to previous 549 , to selected 2366
(Classifier.__init__): Use wxADJUST_MINSIZE
        as one of the style properties for the fieldTypeText item to
        be sure that its size is correct when the text changes.


Revision 549 - (view) (annotate) - [select for diffs]
Modified Thu Mar 20 09:45:07 2003 UTC (21 years, 11 months ago) by jonathan
File length: 36517 byte(s)
Diff to previous 535 , to selected 2366
 Remember if any changes have actually
        been applied so that if the dialog is cancelled without an application
        of changes we don't have to set a new classification.
(ClassDataPreviewer): Pulled out the window specific code and put it
        ClassDataPreviewWindow. ClassDataPreviewer can then be used to draw
        symbols on any DC.


Revision 535 - (view) (annotate) - [select for diffs]
Modified Fri Mar 14 20:42:18 2003 UTC (21 years, 11 months ago) by bh
File length: 36105 byte(s)
Diff to previous 519 , to selected 2366
Implement multiple selected shapes

* Thuban/UI/selection.py: New module with a class to represent the
selection.

* Thuban/UI/messages.py (SELECTED_TABLE, SELECTED_MAP): Remove
these unused messages

* Thuban/UI/application.py (ThubanApplication.OnInit)
(ThubanApplication.OnExit, ThubanApplication.SetSession): The
interactor is gone now.
(ThubanApplication.CreateMainWindow): There is no interactor
anymore so we pass None as the interactor argument for now for
compatibility.

* Thuban/UI/view.py (MapCanvas.delegated_messages)
(MapCanvas.Subscribe, MapCanvas.Unsubscribe): In Subscribe and
Unsubscribe, delegate messages according to the delegated_messages
class variable.
(MapCanvas.__getattr__, MapCanvas.delegated_methods): Get some
attributes from instance variables as described with the
delegated_methods class variable.
(MapCanvas.__init__): New instance variable selection holding the
current selection
(MapCanvas.do_redraw): Deal with multiple selected shapes. Simply
pass them on to the renderer
(MapCanvas.SetMap): Clear the selection when a different map is
selected.
(MapCanvas.shape_selected): Simple force a complete redraw. The
selection class now takes care of only issueing SHAPES_SELECTED
messages when the set of selected shapes actually does change.
(MapCanvas.SelectShapeAt): The selection is now managed in
self.selection

* Thuban/UI/mainwindow.py (MainWindow.delegated_messages)
(MainWindow.Subscribe, MainWindow.Unsubscribe): In Subscribe and
Unsubscribe, delegate messages according to the delegated_messages
class variable.
(MainWindow.delegated_methods, MainWindow.__getattr__): Get some
attributes from instance variables as described with the
delegated_methods class variable.
(MainWindow.__init__): The interactor as ivar is gone. The
parameter is still there for compatibility. The selection messages
now come from the canvas.
(MainWindow.current_layer, MainWindow.has_selected_layer):
Delegate to the the canvas.
(MainWindow.LayerShowTable, MainWindow.Classify)
(MainWindow.identify_view_on_demand): The dialogs don't need the
interactor parameter anymore.

* Thuban/UI/tableview.py (TableFrame.__init__)
(LayerTableFrame.__init__, LayerTableFrame.OnClose)
(LayerTableFrame.row_selected): The interactor is gone. It's job
from the dialog's point of view is now done by the mainwindow,
i.e. the parent. Subscribe to SHAPES_SELECTED instead
of SELECTED_SHAPE

* Thuban/UI/dialogs.py (NonModalDialog.__init__): The interactor
is gone. It's job from the dialog's point of view is now done by
the mainwindow, i.e. the parent.

* Thuban/UI/classifier.py (Classifier.__init__): The interactor is
gone. It's job from the dialog's point of view is now done by the
mainwindow, i.e. the parent.

* Thuban/UI/tree.py (SessionTreeView.__init__): The interactor is
gone. It's job from the dialog's point of view is now done by the
mainwindow, i.e. the parent.
(SessionTreeCtrl.__init__): New parameter mainwindow which is
stored as self.mainwindow. The mainwindow is need so that the tree
can still subscribe to the selection messages.
(SessionTreeCtrl.__init__, SessionTreeCtrl.unsubscribe_all)
(SessionTreeCtrl.update_tree, SessionTreeCtrl.OnSelChanged): The
selection is now accessible through the mainwindow. Subscribe to
SHAPES_SELECTED instead of SELECTED_SHAPE

* Thuban/UI/identifyview.py (IdentifyView.__init__): Use the
SHAPES_SELECTED message now.
(IdentifyView.selected_shape): Now subscribed to SHAPES_SELECTED,
so deal with multiple shapes
(IdentifyView.__init__, IdentifyView.OnClose): The interactor is
gone. It's job from the dialog's point of view is now done by the
mainwindow, i.e. the parent.

* Thuban/UI/renderer.py (ScreenRenderer.RenderMap): Rename the
selected_shape parameter and ivar to selected_shapes. It's now a
list of shape ids.
(MapRenderer.draw_label_layer): Deal with multiple selected
shapes. Rearrange the code a bit so that the setup and shape type
distinctions are only executed once.


Revision 519 - (view) (annotate) - [select for diffs]
Modified Tue Mar 11 22:27:35 2003 UTC (22 years ago) by jonathan
File length: 36134 byte(s)
Diff to previous 513 , to selected 2366
Undo last changes so that we now need wxWindows2.4


Revision 513 - (view) (annotate) - [select for diffs]
Modified Tue Mar 11 16:42:38 2003 UTC (22 years ago) by jonathan
File length: 36196 byte(s)
Diff to previous 511 , to selected 2366
Quick fix so that the ClassGrid works on wxWindows 2.3.


Revision 511 - (view) (annotate) - [select for diffs]
Modified Tue Mar 11 16:27:52 2003 UTC (22 years ago) by jonathan
File length: 36134 byte(s)
Diff to previous 509 , to selected 2366
More work with the classifier panel.


Revision 509 - (view) (annotate) - [select for diffs]
Modified Tue Mar 11 09:45:59 2003 UTC (22 years ago) by jonathan
File length: 35928 byte(s)
Diff to previous 507 , to selected 2366
Working to get wxPanel to behave correctly.


Revision 507 - (view) (annotate) - [select for diffs]
Modified Mon Mar 10 17:36:42 2003 UTC (22 years ago) by jonathan
File length: 35751 byte(s)
Diff to previous 506 , to selected 2366
Add normal border to SelectPropertiesDialog.


Revision 506 - (view) (annotate) - [select for diffs]
Modified Mon Mar 10 15:49:22 2003 UTC (22 years ago) by jonathan
File length: 35726 byte(s)
Diff to previous 500 , to selected 2366
(Classifier.__init__): Make the
        field type label grow so that when the text changes the
        size is updated correctly. This may be a wxWindows bug.


Revision 500 - (view) (annotate) - [select for diffs]
Modified Mon Mar 10 15:11:24 2003 UTC (22 years ago) by jonathan
File length: 35820 byte(s)
Diff to previous 498 , to selected 2366
Wrap text with _().
(ClassGrid.CreateTable): Set dimensions and size hints here,
        instead of in Reset, so we only set the size once.


Revision 498 - (view) (annotate) - [select for diffs]
Modified Mon Mar 10 11:03:22 2003 UTC (22 years ago) by jonathan
File length: 35810 byte(s)
Diff to previous 496 , to selected 2366
(Classifier): SelectField() needed
        to know the old field index as well as the new one.


Revision 496 - (view) (annotate) - [select for diffs]
Modified Mon Mar 10 10:54:50 2003 UTC (22 years ago) by jonathan
File length: 35710 byte(s)
Diff to previous 489 , to selected 2366
(Classifier): Use __SelectField()
        to correctly set the table information and call this from
        __init__ and from _OnFieldSelect so that all the information
        is up to date when the dialog opens and when a field is changed.


Revision 489 - (view) (annotate) - [select for diffs]
Modified Fri Mar 7 18:22:47 2003 UTC (22 years ago) by jonathan
File length: 35552 byte(s)
Diff to previous 485 , to selected 2366
removed print statement


Revision 485 - (view) (annotate) - [select for diffs]
Modified Fri Mar 7 18:20:31 2003 UTC (22 years ago) by jonathan
File length: 35596 byte(s)
Diff to previous 476 , to selected 2366
Setting and Getting table values now
        uses a consistent set of functions.
(Classifier): Now non-modal. Has field type label which changes
        as the field changes. Keep track of buttons in a list so that
        we can enable/disable the buttons when the None field is selected.
(SelectPropertiesDialog): Add buttons to make the colors transparent.


Revision 476 - (view) (annotate) - [select for diffs]
Modified Thu Mar 6 15:03:37 2003 UTC (22 years ago) by bh
File length: 31261 byte(s)
Diff to previous 473 , to selected 2366
(ClassGrid.__init__)
(ClassGrid.CreateTable): Move the SetSelectionMode call to
CreateTable because otherwise it triggers an assertion in
wxPython/wxGTK 2.4.


Revision 473 - (view) (annotate) - [select for diffs]
Modified Wed Mar 5 18:39:45 2003 UTC (22 years ago) by jonathan
File length: 31255 byte(s)
Diff to previous 460 , to selected 2366
import FIELDTYPE constants from table


Revision 460 - (view) (annotate) - [select for diffs]
Modified Wed Mar 5 18:16:28 2003 UTC (22 years ago) by jonathan
File length: 31165 byte(s)
Diff to previous 455 , to selected 2366
Added class documentation.
        Fixed RTbug #1713, #1714. Added Move[Up|Down] buttons.
        Store just the groups in the table and generate the other
        column information when it is requested. Add "None" field
        to pull-down to select no classification.


Revision 455 - (view) (annotate) - [select for diffs]
Modified Tue Mar 4 11:32:20 2003 UTC (22 years ago) by bh
File length: 24703 byte(s)
Diff to previous 451 , to selected 2366
(ClassGrid.__init__): Set the table
before the selection mode. Doing it the other way round triggers
an assertion in wxWindows.


Revision 451 - (view) (annotate) - [select for diffs]
Modified Tue Mar 4 10:33:56 2003 UTC (22 years ago) by jonathan
File length: 24703 byte(s)
Diff to previous 444 , to selected 2366
(ClassGrid): Moved OnCellDClick() from
        Classifier to ClassGrid. Added support for removing selected rows,
        which including code for keeping track of when cells are selected,
        and deselected.
(ClassTable): Support for added/removing rows. Fixed a problem
        with __ParseInput whereby it would not allow strings (only numbers)
        to be entered.
(Classifier): Added button and supporting code for removing selected rows.


Revision 444 - (view) (annotate) - [select for diffs]
Modified Thu Feb 27 16:02:59 2003 UTC (22 years ago) by jonathan
File length: 20635 byte(s)
Diff to previous 441 , to selected 2366
Fix to create a tuple with a single value instead of simply returning the value.


Revision 441 - (view) (annotate) - [select for diffs]
Modified Thu Feb 27 15:55:00 2003 UTC (22 years ago) by jonathan
File length: 20597 byte(s)
Diff to previous 430 , to selected 2366
Changes to use new Classification and Group functions.


Revision 430 - (view) (annotate) - [select for diffs]
Modified Mon Feb 24 18:47:06 2003 UTC (22 years ago) by jonathan
File length: 19705 byte(s)
Diff to previous 415 , to selected 2366
(SelectPropertiesDialog): Support
        for changing the stroke and fill colors and previewing the
        changes.


Revision 415 - (view) (annotate) - [select for diffs]
Modified Wed Feb 19 16:52:51 2003 UTC (22 years ago) by jonathan
File length: 17811 byte(s)
Diff to previous 400 , to selected 2366
(ClassGrid): New class to represent a
        custom grid.
(ClassTable): Support for editing Values and Labels and for
        changing what type (point or range) of data is stored in each
        property based on how the user enters the data.
(Classifier): Support for saving the new classifications and
        launching the dialog to edit a property.
(SelectPropertiesDialog): New class for editing the visual
        properties of a classification (stroke color, width, and fill color)
(ClassPreviewer): Took the Draw method from ClassRenderer and
        made most of it into this new class. Intend to use this class in
        the SelectPropertiesDialog for previewing changes.


Revision 400 - (view) (annotate) - [select for diffs]
Modified Tue Feb 11 14:29:09 2003 UTC (22 years ago) by jonathan
File length: 5974 byte(s)
Diff to previous 398 , to selected 2366
typo fix


Revision 398 - (view) (annotate) - [select for diffs]
Modified Tue Feb 11 14:23:45 2003 UTC (22 years ago) by jonathan
File length: 5979 byte(s)
Diff to previous 392 , to selected 2366
* Thuban/UI/classifier.py (ClassTable): Didn't need to hang
        onto the clinfo parameter, so removed the deepcopy().


Revision 392 - (view) (annotate) - [select for diffs]
Modified Mon Feb 10 15:26:30 2003 UTC (22 years ago) by jonathan
File length: 6033 byte(s)
Diff to previous 379 , to selected 2366
* Thuban/UI/classifier.py (ClassRenderer): New class to
        draw the classifications in the dialog box's table.
        (Classifier): Modified to use the ClassRenderer class.


Revision 379 - (view) (annotate) - [select for diffs]
Modified Tue Jan 28 12:54:01 2003 UTC (22 years, 1 month ago) by jonathan
File length: 3315 byte(s)
Diff to previous 377 , to selected 2366
added i18n wrapper _() to text


Revision 377 - (view) (annotate) - [select for diffs]
Modified Tue Jan 28 12:09:56 2003 UTC (22 years, 1 month ago) by jonathan
File length: 3312 byte(s)
Diff to previous 376 , to selected 2366
fixed a missed conflict


Revision 376 - (view) (annotate) - [select for diffs]
Modified Tue Jan 28 12:01:38 2003 UTC (22 years, 1 month ago) by jonathan
File length: 3784 byte(s)
Diff to previous 374 , to selected 2366
fix i18n merge conflict


Revision 374 - (view) (annotate) - [select for diffs]
Modified Mon Jan 27 14:20:02 2003 UTC (22 years, 1 month ago) by jan
File length: 2813 byte(s)
Diff to previous 372 , to selected 2366
Replace user string by _() for i18n.


Revision 372 - (view) (annotate) - [select for diffs]
Added Mon Jan 27 13:50:58 2003 UTC (22 years, 1 month ago) by jonathan
File length: 2764 byte(s)
Diff to selected 2366
Dialog box for modifying classification information


This form allows you to request diffs between any two revisions of this file. For each of the two "sides" of the diff, enter a numeric revision.

  Diffs between and
  Type of Diff should be a

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26