Esempio n. 1
0
func NewButtonWithMnemonic(label string) *Button {
	b := &Button{}
	l := gobject.GString(label)
	o := C.gtk_button_new_with_mnemonic((*C.gchar)(l.GetPtr()))
	b.Container = NewContainer(unsafe.Pointer(o))
	b.object = C.to_GtkButton(unsafe.Pointer(o))
	return b
}
Esempio n. 2
0
// GtkWidget*     gtk_button_new_with_mnemonic (const gchar    *label);
func NewButtonWithMnemonic(label string) *Button {
	s := _GString(label)
	defer _GFree(unsafe.Pointer(s))

	ret := C.gtk_button_new_with_mnemonic(s)
	if ret != nil {
		return ToButton(unsafe.Pointer(ret))
	}

	return nil
}