]> git.saurik.com Git - wxWidgets.git/blobdiff - interface/wx/dataview.h
Suppress warnings about double to int truncation in wxHTML code.
[wxWidgets.git] / interface / wx / dataview.h
index 551e09607b40455d30358b1e4558b46cbed74563..7e4029aaf2bcd65a472243fc2dc8865a4d8706c3 100644 (file)
@@ -3,7 +3,7 @@
 // Purpose:     interface of wxDataView* classes
 // Author:      wxWidgets team
 // RCS-ID:      $Id$
-// Licence:     wxWindows license
+// Licence:     wxWindows licence
 /////////////////////////////////////////////////////////////////////////////
 
 
@@ -100,7 +100,7 @@ public:
 
         @since 2.9.1
 
-        @param variable
+        @param variant
             The new value.
         @param item
             The item (row) to update.
@@ -514,7 +514,7 @@ public:
     @class wxDataViewItem
 
     wxDataViewItem is a small opaque class that represents an item in a wxDataViewCtrl
-    in a persistent way, i.e. indepent of the position of the item in the control
+    in a persistent way, i.e. independent of the position of the item in the control
     or changes to its contents.
 
     It must hold a unique ID of type @e void* in its only field and can be converted
@@ -596,6 +596,8 @@ public:
     @style{wxDV_VARIABLE_LINE_HEIGHT}
            Allow variable line heights.
            This can be inefficient when displaying large number of items.
+    @style{wxDV_NO_HEADER}
+           Do not show column headers (which are shown by default).
     @endStyleTable
 
     @beginEventEmissionTable{wxDataViewEvent}
@@ -1112,6 +1114,7 @@ enum wxDataViewCellRenderState
     - wxDataViewBitmapRenderer,
     - wxDataViewDateRenderer,
     - wxDataViewSpinRenderer.
+    - wxDataViewChoiceRenderer.
 
     Additionally, the user can write own renderers by deriving from
     wxDataViewCustomRenderer.
@@ -1266,8 +1269,8 @@ public:
     a small icon next to it as it is typically done in a file manager.
 
     This classes uses the wxDataViewIconText helper class to store its data.
-    wxDataViewIonText can be converted to and from a wxVariant using the left shift
-    operator.
+    wxDataViewIconText can be converted to and from a wxVariant using the left
+    shift operator.
 
     @library{wxadv}
     @category{dvc}
@@ -1351,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