Ejemplo n.º 1
0
func (h *Handle) SetAttribute(name string, value string) {
	cname := NewCS(name)
	defer FreeCS(cname)
	cvalue := NewCS(value)
	defer FreeCS(cvalue)
	C.IupStoreAttribute(h.p, cname, cvalue)
}
Ejemplo n.º 2
0
func StoreAttribute(ih *Ihandle, name, value string) {
	cName := C.CString(name)
	defer C.free(unsafe.Pointer(cName))

	cValue := C.CString(value)
	defer C.free(unsafe.Pointer(cValue))

	C.IupStoreAttribute((*C.Ihandle)(ih), cName, cValue)
}