PHP-GTK
Tuesday, October 21, 2014 
download | documentation | applications | faq | changelog | resources 


search for in the  


previousGtkTreeStore::iter_is_valid
GtkTreeStore::move_beforenext

Last updated: Sun, 12 May 2013
view this page in English

GtkTreeStore::move_after

Moves the row given by iter directly after position.

That method works only with unsorted stores and requires both iters to be at the same level. If position is null, the row will be moved to the start of the level.

Example 137. Moving rows

<?php
//Create the store
$store = new GtkTreeStore(Gtk::TYPE_STRING);
 
//Create first row
$row1 = $store->append(null, array('row 1'));
//Create second row
$row2 = $store->append(null, array('row 2'));
 
//move $row1 after $row2
$store->move_after($row1, $row2);
 
 
//Display the store
$wnd  = new GtkWindow();
$view = new GtkTreeView($store);
$view->append_column(
    new GtkTreeViewColumn('String column', new GtkCellRendererText(), 'text', 0)
);
$wnd->add($view);
$wnd->connect_simple('destroy', array('gtk', 'main_quit'));
$wnd->show_all();
Gtk::main();
?>

See also: move_before()


User Contributed Notes
gtk.gtktreestore.method.move_after.php
add a note about notes
There are no user contributed notes for this page.


previousGtkTreeStore::iter_is_valid
GtkTreeStore::move_beforenext

Last updated: Sun, 12 May 2013
view this page in English


credits 

PHP  Copyright © 2001-2014 The PHP Group
 All rights reserved.
Last updated: Sun May 12 20:51:01 2013 CEST