[gtkmm/gtkmm-3-24] Gtk::TreeView::append_column() doc: Modify the code exmaple



commit c96e1e1aab412d62d5815263849e82aaec9e64e1
Author: Kjell Ahlstedt <kjellahlstedt gmail com>
Date:   Sat Jan 18 10:19:00 2020 +0100

    Gtk::TreeView::append_column() doc: Modify the code exmaple

 gtk/src/treeview.hg | 11 ++++-------
 1 file changed, 4 insertions(+), 7 deletions(-)
---
diff --git a/gtk/src/treeview.hg b/gtk/src/treeview.hg
index ae085bf6..8d269b91 100644
--- a/gtk/src/treeview.hg
+++ b/gtk/src/treeview.hg
@@ -166,16 +166,13 @@ public:
    * manually and use TreeViewColumn::set_cell_data_func() to provide a callback
    * that converts the model value into a string representation with .
    *
-   * The returned value is useful, for example, for the connection the column renderer signal to a
+   * The returned value is useful, for example, for connecting the column renderer signal to
    * a slot:
-   *
    * @code
-   *
    *    int Ncolumns = mTreeView.append_column("Column Title", mColumns.mName);
-   *    auto renderer
-   *       = dynamic_cast<Gtk::CellRendererText*>(mTreeView.get_column_cell_renderer(Ncolumns-1));
-   *    renderer.signal_edited().connect(sigc::mem_fun(*this, &myFunc));
-   *
+   *    auto renderer =
+   *      dynamic_cast<Gtk::CellRendererText*>(mTreeView.get_column_cell_renderer(Ncolumns-1));
+   *    renderer->signal_edited().connect(sigc::mem_fun(*this, &MyWindow::on_name_edited));
    * @endcode
    *
    * @param title The text to be used in the title header of this column.


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]