Logo Search packages:      
Sourcecode: pan version File versions

PanTreeStore * PanTreeStore::new_tree ( int  n_cols,
  ... 
) [static]

This is how you instantiate. Arguments are equivalent to gtk_tree_store_new().

Definition at line 724 of file pan-tree.cc.

References column_types, and n_columns.

{
  g_return_val_if_fail (n_columns>0, 0);
  PanTreeStore* tree = (PanTreeStore*) g_object_new (PAN_TREE_STORE_TYPE, NULL);

  va_list args;
  va_start (args, n_columns);
  for (int i=0; i<n_columns; ++i) {
    const GType type (va_arg (args, GType));
    tree->column_types->push_back (type);
  }
  va_end (args);
  tree->n_columns = tree->column_types->size();

  return tree;
}


Generated by  Doxygen 1.6.0   Back to index