Exemplo n.º 1
0
func NewField(height int, width int, top int, left int, offscreen int, nbuf int) (*Field, error) {
	field := (*Field)(C.new_field(C.int(height), C.int(width), C.int(top), C.int(left), C.int(offscreen), C.int(nbuf)))
	if field == nil {
		return nil, FormsError{"NewField failed"}
	}
	return field, nil
}
Exemplo n.º 2
0
func NewField(h, w, tr, lc, oscr, nbuf int) (*Field, error) {
	var new_field Field
	var err error
	new_field.field, err = C.new_field(C.int(h), C.int(w), C.int(tr), C.int(lc),
		C.int(oscr), C.int(nbuf))
	return &new_field, ncursesError(err)
}
Exemplo n.º 3
0
func NewField(height int, width int, top int, left int, offscreen int, nbuf int) (*Field, error) {
	field := C.new_field(C.int(height), C.int(width), C.int(top), C.int(left), C.int(offscreen), C.int(nbuf))
	if field == nil {
		return nil, errors.New("NewField failed")
	}
	return &Field{field}, nil
}
Exemplo n.º 4
0
func NewField(h, w, tr, lc, oscr, nbuf int32) (*Field, error) {
	f, err := C.new_field(C.int(h), C.int(w), C.int(tr), C.int(lc),
		C.int(oscr), C.int(nbuf))
	return (*Field)(f), ncursesError(err)
}