notebook tabs in an for loop set get text labels and set get values of a Simplelist





hi all 

in my programm i make the notebook tabs in an for loop 

code :

for ( $x=0;$x<=$searchoften1-1;$x++){
 
   my $simplelist_search = Gtk2::SimpleList->new (
                  'id'    => 'scalar',
                  'searchid'     => 'scalar',
                  'checksum'  => 'scalar',
                  'grösse'    => 'scalar',
                        'name'    => 'scalar',
                        'name'    => 'scalar',
                    );
            
   $simplelist_search->show();
   my $searchlabel= $search->[$x][1];
   my $vbox_search= new Gtk2::VBox( 0, 0 );
   my $search_id=$search->[$x][0];
   my $search_searchtext=$search->[$x][1];
   my $search_opensearches=$search->[$x][2];
   my $search_foundfiles=$search->[$x][3];
  my $search_sumsearches=$search->[$x][4];
   my $search_running=$search->[$x][5];


  my $hbox_search= new Gtk2::HBox(0,0);

   my $label_search_id= new Gtk2::Label("search id: ".$search_id);
  $label_search_id->show();
my $label_search_searchtext= new Gtk2::Label(" searchtext: ".$search_searchtext);
$label_search_searchtext->show();
my $label_search_opensearches= new Gtk2::Label(" opensearches:
".$search_opensearches);
$label_search_opensearches->show();
my $label_search_foundfiles= new Gtk2::Label(" foundfiles: ".$search_foundfiles);
$label_search_foundfiles->show();
my $label_search_sumsearches= new Gtk2::Label(" sumsearches: ".$search_sumsearches);
$label_search_sumsearches->show();
my $label_search_running= new Gtk2::Label(" running: ".$search_running);
$label_search_running->show();


$hbox_search->pack_start( $label_search_id, $false, $false, 0 );
$hbox_search->pack_start( $label_search_searchtext, $false, $false, 0 );
$hbox_search->pack_start( $label_search_opensearches, $false, $false, 0 );
$hbox_search->pack_start( $label_search_foundfiles, $false, $false, 0 );
$hbox_search->pack_start( $label_search_sumsearches, $false, $false, 0 );
$hbox_search->pack_start( $label_search_running, $false, $false, 0 );






$vbox_search->pack_end( $hbox_search, $false, $false, 0 );
 
my $scrolledsearch = Gtk2::ScrolledWindow->new;
 $scrolledsearch->set_shadow_type ('etched-in');
$scrolledsearch->set_policy ('automatic', 'automatic');

$scrolledsearch->add ($simplelist_search);
$scrolledsearch->show();
$vbox_search->pack_start( $scrolledsearch, $true, $true, 0 );
$vbox_search->show();
$hbox_search->show();



  my $hbox             = Gtk2::HBox->new;
        my $close            = Gtk2::Button->new("X");
   my $label_search_notebook=new Gtk2::Label($searchlabel);
  $label_search_notebook->show();
 $hbox->add($label_search_notebook);
        $hbox->add($close);
   $close->show();
   $hbox->show();
 $close->signal_connect(
                'clicked',
                sub {
                         $notebook_search->remove_page( $notebook_search->page_num($vbox_search));
                }
        );
 $notebook_search->append_page($vbox_search, $hbox);

 }
 
this is my for loop to generate my notebooktabs after this i would like have the
values from the  Simplelist (and set) and the labeles (get and set text) 
how can i do this ? 

thx Arnold

-------------------------------------------------
This mail sent through IMP: http://horde.org/imp/



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