#include <hk_dsgrid.h>
Public Member Functions | |
| hk_dsgrid (hk_form *form=NULL) | |
| hk_dsgridcolumn * | gridcolumn (unsigned int c) |
| hk_dsgridcolumn * | gridcolumn (const hk_string &identfier) |
| unsigned int | columnscount (void) |
| void | set_gridcolumnwidth (unsigned int col, int newwidth) |
| void | change_columnposition (unsigned int from, unsigned int to) |
| void | set_gridcolumns (vector< hk_dsgridcolumn > &c, bool registerchange=true) |
| void | set_gridcolumns (list< hk_string > &sl) |
| void | clear_gridcolumn (void) |
| void | set_hold_rowdefinition (bool h=true) |
| void | set_enablingbehaviour (bool add_col, bool del_col) |
| virtual void | savedata (ostream &s, bool saveall) |
| virtual void | savedata (ostream &s) |
| virtual void | loaddata (xmlNodePtr definition) |
| virtual void | set_datasource (hk_datasource *) |
| list< hk_string > * | visible_columns (void) |
| list< hk_string > * | nonvisible_columns (void) |
| bool | save_table (const hk_string &s="", bool ask=true) |
| bool | load_table (void) |
| bool | save_view (const hk_string &s="", bool ask=true) |
| bool | load_view (void) |
| void | set_rowheight (int, bool registerchange=true) |
| int | rowheight (void) |
Protected Member Functions | |
| bool | datasource_enable (void) |
| bool | datasource_disable (void) |
| bool | columns_new_created (void) |
| virtual void | before_store_changed_data (void) |
| virtual bool | table_structure_changes (void) |
| virtual void | widget_specific_columns_created (void) |
| virtual void | widget_specific_rowheight_changes (void) |
Friends | |
| class | hk_dsgridcolumn |
| hk_dsgridcolumn * hk_dsgrid::gridcolumn | ( | unsigned int | c | ) |
| unsigned int hk_dsgrid::columnscount | ( | void | ) |
returns the number of columns shown in the grid.
| void hk_dsgrid::set_gridcolumnwidth | ( | unsigned int | col, | |
| int | newwidth | |||
| ) |
sets the new width of a specific column.
| col | number of the column | |
| newsize | the new width of the column |
References hk_class::hkdebug().
| void hk_dsgrid::change_columnposition | ( | unsigned int | from, | |
| unsigned int | to | |||
| ) |
it's possible to change the order of the columns
| from | position where the column was originally | |
| to | target position |
References hk_class::hkdebug().
| void hk_dsgrid::set_gridcolumns | ( | vector< hk_dsgridcolumn > & | c, | |
| bool | registerchange = true | |||
| ) |
you can manually set the gridcolumn definition.
| c | the new defintion of the gridcolumns, all values in these definitions will be used |
References hk_class::hkdebug().
| void hk_dsgrid::set_gridcolumns | ( | list< hk_string > & | sl | ) |
you can manually set the gridcolumn definition.The new defintion of the gridcolumns, all columns get default values.
| sl | the strings contain the names of the columns. |
References hk_class::hkdebug().
| void hk_dsgrid::set_hold_rowdefinition | ( | bool | h = true |
) |
If true and you change the row definitions (i.e. column size) after disabling and reenabling your definitions still exist, if false the rows will be newly built. Default is true.
References hk_class::hkdebug().
| void hk_dsgrid::set_enablingbehaviour | ( | bool | add_col, | |
| bool | del_col | |||
| ) |
if set_hold_rowdefinition is true, this function defines what exactly to do during enabling
| add_col | if true, columns of the datasource will be added to the grid if no equivalent gridcolumn exists. Default is false. | |
| del_col | if true, gridcolumns will be removed if no equivalent columns in the datasource exist. Default is false. |
References hk_class::hkdebug().
| void hk_dsgrid::savedata | ( | ostream & | s | ) | [virtual] |
stores the object's values to stream s. Especially used to store queries, forms and reports
Reimplemented from hk_dsvisible.
References hk_class::hkdebug().
| void hk_dsgrid::loaddata | ( | xmlNodePtr | definition | ) | [virtual] |
loads the object's values out of the definition string. Especially used to load queries, forms and reports
Reimplemented from hk_dsvisible.
References hk_class::get_tagvalue(), hk_class::hkdebug(), and hk_dsvisible::loaddata().
| bool hk_dsgrid::datasource_enable | ( | void | ) | [protected, virtual] |
FOR WIDGET DEVELOPERS ONLY: will be automatically called when the datasources is enabling
Reimplemented from hk_dsvisible.
References hk_dsvisible::datasource_enable(), and hk_class::hkdebug().
| bool hk_dsgrid::datasource_disable | ( | void | ) | [protected, virtual] |
FOR WIDGET DEVELOPERS ONLY: will be automatically called when the datasources is disabling
Reimplemented from hk_dsvisible.
References hk_dsvisible::datasource_disable(), and hk_class::hkdebug().
| bool hk_dsgrid::table_structure_changes | ( | void | ) | [protected, virtual] |
FOR WIDGET DEVELOPERS ONLY: will be automatically called after the columnstructure of a table was successfully altered.
Reimplemented from hk_dsvisible.
1.5.6