3 #ifndef _GTKMM_TREEITER_H
4 #define _GTKMM_TREEITER_H
6 #include <gtkmmconfig.h>
9 #include <glibmm/ustring.h>
10 #include <sigc++/sigc++.h>
41 class TreeNodeChildren;
49 #ifndef DOXYGEN_SHOULD_SKIP_THIS
158 operator bool()
const;
175 #ifndef DOXYGEN_SHOULD_SKIP_THIS
180 void set_model_refptr(
const Glib::RefPtr<TreeModel>& model);
184 void setup_end_iterator(
const TreeIter& last_valid);
187 {
return (!is_end_) ? &
gobject_ : 0; }
189 const GtkTreeIter* get_parent_gobject_if_end()
const
219 {
return lhs.
equal(rhs); }
223 {
return !lhs.
equal(rhs); }
226 template <
class ColumnType>
230 #ifndef DOXYGEN_SHOULD_SKIP_THIS
235 inline operator ColumnType()
const;
269 template <
class ColumnType>
inline
281 template <
class ColumnType>
290 template <
class ColumnType>
291 void set_value(
int column,
const ColumnType& data)
const;
302 template <
class ColumnType>
314 template <
class ColumnType>
329 operator bool()
const;
358 #ifndef GLIBMM_HAVE_SUN_REVERSE_ITERATOR
361 typedef std::reverse_iterator<
iterator, std::random_access_iterator_tag,
367 #ifndef GLIBMM_HAVE_SUN_REVERSE_ITERATOR
370 typedef std::reverse_iterator<
const_iterator, std::random_access_iterator_tag,
390 operator bool()
const {
return !
empty(); }
392 #ifndef DOXYGEN_SHOULD_SKIP_THIS
404 #ifndef DOXYGEN_SHOULD_SKIP_THIS
411 return static_cast<const TreeRow&
>(*this);
417 return static_cast<const TreeRow*
>(
this);
423 template <
class ColumnType>
inline
424 TreeValueProxy<ColumnType>::TreeValueProxy(
const TreeRow& row,
const TreeModelColumn<ColumnType>& column)
430 template <
class ColumnType>
inline
433 row_.set_value(column_, data);
437 template <
class ColumnType>
inline
438 TreeValueProxy<ColumnType>::operator ColumnType()
const
440 return row_.get_value(column_);
446 template <
class ColumnType>
inline
447 TreeValueProxy<ColumnType>
TreeRow::operator[](
const TreeModelColumn<ColumnType>& column)
const
449 return TreeValueProxy<ColumnType>(*
this, column);
452 template <
class ColumnType>
453 void TreeRow::set_value(
const TreeModelColumn<ColumnType>& column,
const ColumnType& data)
const
458 value.init(column.type());
464 template <
class ColumnType>
471 typedef typename type_cppcolumn::ValueType ValueType;
474 value.init(ValueType::value_type());
480 template <
class ColumnType>
491 template <
class ColumnType>
513 #ifndef DOXYGEN_SHOULD_SKIP_THIS
515 class Value<
Gtk::TreeIterBase> :
public Glib::Value_Boxed<Gtk::TreeIterBase>
GtkTreeIter * gobj()
Provides access to the underlying C instance.
const GtkTreeIter * gobj() const
Provides access to the underlying C instance.
static GType get_type() G_GNUC_CONST
bool operator==(const TreeIter &lhs, const TreeIter &rhs)
const TreeIter operator++(int)
const Gtk::TreeRow & reference
const Gtk::TreeRow * pointer
bool equal(const TreeIter &other) const
bool operator!=(const TreeIter &lhs, const TreeIter &rhs)
pointer operator->() const
const TreeIter operator--(int)
reference operator*() const
std::bidirectional_iterator_tag iterator_category
void set_stamp(int stamp)
Glib::Value< T > ValueType
std::reverse_iterator< iterator > reverse_iterator
Gtk::TreeIter const_iterator
const_reverse_iterator rbegin() const
const_iterator begin() const
const_reverse_iterator rend() const
value_type operator[](size_type index) const
const_iterator end() const
std::reverse_iterator< const_iterator > const_reverse_iterator
reverse_iterator rbegin()
const GtkTreeIter * gobj() const
Provides access to the underlying C GObject.
const TreeNodeChildren & children() const
GtkTreeIter * gobj()
Provides access to the underlying C GObject.
ColumnType get_value(const TreeModelColumn< ColumnType > &column) const
void set_value(const TreeModelColumn< ColumnType > &column, const ColumnType &data) const
void get_value_impl(int column, Glib::ValueBase &value) const
void set_value(int column, const ColumnType &data) const
TreeValueProxy< ColumnType > operator[](const TreeModelColumn< ColumnType > &column) const
void get_value(int column, ColumnType &data) const
void set_value_impl(int column, const Glib::ValueBase &value) const
TreeValueProxy< ColumnType > & operator=(const ColumnType &data)
const TreeModelColumn< ColumnType > & column_
TreeValueProxy< ColumnType > & operator=(const TreeValueProxy< ColumnType > &)
struct _GtkTreeModel GtkTreeModel