propertygrid
A specialized grid for editing properties.

author: besh81
nana::propertygrid

Public Member Functions

 propertygrid (window, bool visible)
 Constructor.
 
 propertygrid (window, const rectangle &={}, bool visible=true)
 Constructor.
 
cat_proxy append (std::string str)
 Appends a new category to the end.
 
cat_proxy at (std::size_t pos) const
 Returns the category at the specified position.
 
item_proxy at (const index_pair &idx) const
 Returns an item by the specified absolute position.
 
void auto_draw (bool)
 Enables/disables automatic drawing.
 
void clear (std::size_t cat)
 Removes all the items from the specified category.
 
void clear ()
 Removes all the items from all categories.
 
bool enabled ()
 Get the enables state of the control.
 
void enabled (bool state)
 Enables/disables the control.
 
void erase (std::size_t cat)
 Erases specified category.
 
void erase ()
 Erases all categories.
 
void erase (item_proxy ip)
 Erases specified item.
 
std::size_t find (std::string) const
 Finds category with given name. Returns the category position if found or npos otherwise.
 
cat_proxy insert (cat_proxy cat, ::std::string str)
 Inser a new category before the specified one.
 
unsigned labels_min_width () const
 Gets the label column min width.
 
propertygridlabels_min_width (unsigned pixels)
 Sets the label column min width.
 
void scroll (const index_pair &pos, bool as_first=false)
 Scrolls the view to the selected item.
 
std::size_t size_categ () const
 Get the number of categories.
 
std::size_t size_item (std::size_t cat) const
 Get the number of items in the specified category.
 
unsigned values_min_width () const
 Gets the value column min width.
 
propertygridvalues_min_width (unsigned pixels)
 Sets the value column min width.
 

nana::drawerbase::propertygrid::cat_proxy

Public Member Functions

 cat_proxy (essence_t *, std::size_t pos)
 Constructor.
 
 cat_proxy (essence_t *, category_t *)
 Constructor.
 
item_proxy append (pgitem_ptr p)
 Appends passed item at the end of this category.
 
item_proxy at (std::size_t pos) const
 Returns the item at the specified position.
 
item_proxy back () const
 Returns the last item of this category.
 
item_proxy begin () const
 
item_proxy cbegin () const
 
item_proxy cend () const
 
item_proxy end () const
 
cat_proxyoperator * ()
 
const cat_proxyoperator * () const
 
bool operator!= (const cat_proxy &) const
 
cat_proxyoperator++ ()
 
cat_proxy operator++ (int)
 
cat_proxyoperator-> ()
 
const cat_proxyoperator-> () const
 
cat_proxyoperator= (const cat_proxy &)
 
bool operator== (const cat_proxy &) const
 
std::size_t position () const
 Returns the position of this category.
 
std::size_t size () const
 Returns the number of items.
 
cat_proxytext (std::string)
 Sets category text.
 
std::string text () const
 Gets category text.
 
nana::drawerbase::propertygrid::item_proxy

Public Member Functions

 item_proxy (essence_t *)
 Constructor.
 
 item_proxy (essence_t *, const index_pair &)
 Constructor.
 
item_proxydefvalue (const std::string &value)
 Sets item's default value.
 
std::string defvalue () const
 Gets item's default value.
 
bool empty () const
 Returns true if item is empty.
 
bool enabled ()
 Get the enables state of the item.
 
void enabled (bool state)
 Enables/disables the item.
 
item_proxylabel (const std::string &label)
 Sets item's label.
 
std::string label () const
 Gets item's label.
 
item_proxyoperator * ()
 
const item_proxyoperator * () const
 
bool operator!= (const item_proxy &) const
 
item_proxyoperator++ ()
 
item_proxy operator++ (int)
 
item_proxyoperator-> ()
 
const item_proxyoperator-> () const
 
item_proxyoperator= (const item_proxy &)
 
bool operator== (const char *s) const
 
bool operator== (const ::std::string &s) const
 
bool operator== (const item_proxy &) const
 
index_pair pos () const
 Returns the position of this item.
 
item_proxyvalue (const std::string &value, bool emit=false)
 Sets item's value. If emit is set to true then a property_changed event is generated.
 
std::string value () const
 Gets item's value.