Branch: Tag:

2006-02-02

2006-02-02 18:00:27 by Lance Dillon <riffraff169@yahoo.com>

Added ability to create a mnemonic button.
Changed radio buttons to add to same group as other radio button using _from_widget() functions.

Rev: src/post_modules/GTK2/source/gtkcheckbutton.pre:1.6
Rev: src/post_modules/GTK2/source/gtkradiobutton.pre:1.7

13:   //! int indicator-size   //! int indicator-spacing    - void create(string|mapping|void label_or_props) + void create(string|mapping|void label_or_props, ?int mnemonic)   //! The argument, if specified, is the label of the item.   //! If no label is specified, use object->add() to add some   //! other widget (such as an pixmap or image widget)
24:    if (Pike_sp[-args].type==PIKE_T_STRING) {    struct pike_string *t;    GtkWidget *gcb; -  get_all_args("create",args,"%T",&t); +  INT_TYPE nem=0; +  +  get_all_args("create",args,"%T.%i",&t,&nem);    if (t) {    ref_push_string(t);    f_string_to_utf8(1); -  gcb=gtk_check_button_new_with_mnemonic((char *)STR0(Pike_sp[-1].u.string)); +  if (nem) +  gcb=gtk_check_button_new_with_mnemonic(CGSTR0(Pike_sp[-1].u.string)); +  else +  gcb=gtk_check_button_new_with_label(CGSTR0(Pike_sp[-1].u.string));    pop_stack();    } else    gcb=gtk_check_button_new();