1
  
2
  
3
  
4
  
5
  
6
  
7
  
8
  
9
  
10
  
11
  
12
  
13
  
14
  
15
  
16
  
17
  
18
  
19
  
20
  
21
  
22
  
23
  
24
  
25
  
26
  
27
  
28
  
29
  
30
  
31
  
32
  
33
  
34
  
35
  
36
  
37
  
38
  
39
  
40
  
41
  
42
  
43
  
44
  
45
  
46
  
/* -*- C -*- */ 
class GTK2.Vscale; 
inherit GTK2.Scale; 
 
//! The GTK2.HScale widget is used to allow the user to select a value 
//! using a horizontal slider. A GTK2.Adjustment is used to set the 
//! initial value, the lower and upper bounds, and the step and page 
//! increments. 
//! <p> 
//! See W(Scale) for details 
//! </p><p> 
//! The position to show the current value, and the number of decimal 
//! places shown can be set using the parent W(Scale) class's 
//! functions. 
//! </p> 
//! IMG: GTK2.Vscale(GTK2.Adjustment())->set_size_request(300,30) 
 
void create(GTK2.Adjustment|float|mapping(string:mixed) settings_or_min_props, 
            ?float max, ?float step) 
//! Used to create a new hscale widget. 
//! Either pass an W(Adjustment), or three floats representing min, max, and 
//! step values. 
{ 
  pgtk2_verify_not_inited(); 
  pgtk2_verify_setup(); 
  if (args==1) { 
    if (TYPEOF(Pike_sp[-args]) == PIKE_T_OBJECT) { 
      struct object *o1; 
      GtkWidget *gv; 
      get_all_args(NULL,args,"%o",&o1); 
      gv=gtk_vscale_new(GTK_ADJUSTMENT(get_gobject(o1))); 
      THIS->obj=G_OBJECT(gv); 
    } else { 
      INIT_WITH_PROPS(GTK_TYPE_VSCALE); 
    } 
  } else { 
    FLOAT_TYPE min,max,step; 
    GtkWidget *gv; 
    get_all_args(NULL,args,"%f%f%f",&min,&max,&step); 
    gv=gtk_vscale_new_with_range(min,max,step); 
    THIS->obj=G_OBJECT(gv); 
  } 
  pgtk2_pop_n_elems(args); 
  pgtk2__init_this_object(); 
}