]> git.saurik.com Git - wxWidgets.git/blobdiff - interface/wx/dataview.h
implement * and / operators for wxPoint, not only wxSize.
[wxWidgets.git] / interface / wx / dataview.h
index f678bb7f23e65e41eb549753aa4eec7a4f93affe..13df37997be37d4d0a6581ea52191487e40b787a 100644 (file)
@@ -1114,6 +1114,7 @@ enum wxDataViewCellRenderState
     - wxDataViewBitmapRenderer,
     - wxDataViewDateRenderer,
     - wxDataViewSpinRenderer.
+    - wxDataViewChoiceRenderer.
 
     Additionally, the user can write own renderers by deriving from
     wxDataViewCustomRenderer.
@@ -1353,6 +1354,38 @@ public:
 };
 
 
+/**
+    @class wxDataViewChoiceRenderer
+
+    This class is used by wxDataViewCtrl to render choice controls.
+    It stores a string so that SetValue() and GetValue() operate
+    on a variant holding a string.
+
+    @library{wxadv}
+    @category{dvc}
+*/
+
+class wxDataViewChoiceRenderer: public wxDataViewRenderer
+{
+public:
+    /**
+        The ctor.
+    */
+    wxDataViewChoiceRenderer( const wxArrayString &choices,
+                              wxDataViewCellMode mode = wxDATAVIEW_CELL_EDITABLE,
+                              int alignment = wxDVR_DEFAULT_ALIGNMENT );
+
+    /**
+        Returns the choice referred to by index.
+    */
+    wxString GetChoice(size_t index) const;
+    
+    /**
+        Returns all choices.
+    */
+    const wxArrayString& GetChoices() const;
+};
+
 
 /**
     @class wxDataViewDateRenderer