Example #1
0
// TextViewNew is a wrapper around gtk_text_view_new().
func TextViewNew() (*TextView, error) {
	c := C.gtk_text_view_new()
	if c == nil {
		return nil, nilPtrErr
	}
	return wrapTextView(wrapObject(unsafe.Pointer(c))), nil
}
Example #2
0
func newTextbox() Textbox {
	widget := C.gtk_text_view_new()
	t := &textbox{
		scroller: newScroller(widget, true, true, false), // natively scrollable, has a border, no overlay
		textview: (*C.GtkTextView)(unsafe.Pointer(widget)),
	}
	return t
}