v0.2.1 c0399be

gtkoverlaylayout.go RawHistoryFolder

1// Package gtk was automatically generated by github.com/bnema/puregotk DO NOT EDIT
2package gtk
3
4import (
5	"structs"
6	"unsafe"
7
8	"github.com/ebitengine/purego"
9
10	"github.com/bnema/puregotk/pkg/core"
11	"github.com/bnema/puregotk/v4/gobject"
12	"github.com/bnema/puregotk/v4/gobject/types"
13)
14
15type OverlayLayoutChildClass struct {
16	_ structs.HostLayout
17
18	ParentClass LayoutChildClass
19}
20
21func (x *OverlayLayoutChildClass) GoPointer() uintptr {
22	return uintptr(unsafe.Pointer(x))
23}
24
25type OverlayLayoutClass struct {
26	_ structs.HostLayout
27
28	ParentClass LayoutManagerClass
29}
30
31func (x *OverlayLayoutClass) GoPointer() uintptr {
32	return uintptr(unsafe.Pointer(x))
33}
34
35// The layout manager used by [class@Gtk.Overlay].
36//
37// It places widgets as overlays on top of the main child.
38//
39// This is not a reusable layout manager, since it expects its widget
40// to be a `GtkOverlay`. It is only listed here so that its layout
41// properties get documented.
42type OverlayLayout struct {
43	LayoutManager
44}
45
46var xOverlayLayoutGLibType func() types.GType
47
48func OverlayLayoutGLibType() types.GType {
49	return xOverlayLayoutGLibType()
50}
51
52func OverlayLayoutNewFromInternalPtr(ptr uintptr) *OverlayLayout {
53	cls := &OverlayLayout{}
54	cls.Ptr = ptr
55	return cls
56}
57
58var xNewOverlayLayout func() uintptr
59
60// Creates a new `GtkOverlayLayout` instance.
61func NewOverlayLayout() *OverlayLayout {
62	var cls *OverlayLayout
63
64	cret := xNewOverlayLayout()
65
66	if cret == 0 {
67		return nil
68	}
69	cls = &OverlayLayout{}
70	cls.Ptr = cret
71	return cls
72}
73
74func (c *OverlayLayout) GoPointer() uintptr {
75	if c == nil {
76		return 0
77	}
78	return c.Ptr
79}
80
81func (c *OverlayLayout) SetGoPointer(ptr uintptr) {
82	c.Ptr = ptr
83}
84
85// `GtkLayoutChild` subclass for children in a `GtkOverlayLayout`.
86type OverlayLayoutChild struct {
87	LayoutChild
88}
89
90var xOverlayLayoutChildGLibType func() types.GType
91
92func OverlayLayoutChildGLibType() types.GType {
93	return xOverlayLayoutChildGLibType()
94}
95
96func OverlayLayoutChildNewFromInternalPtr(ptr uintptr) *OverlayLayoutChild {
97	cls := &OverlayLayoutChild{}
98	cls.Ptr = ptr
99	return cls
100}
101
102var xOverlayLayoutChildGetClipOverlay func(uintptr) bool
103
104// Retrieves whether the child is clipped.
105func (x *OverlayLayoutChild) GetClipOverlay() bool {
106
107	cret := xOverlayLayoutChildGetClipOverlay(x.GoPointer())
108	return cret
109}
110
111var xOverlayLayoutChildGetMeasure func(uintptr) bool
112
113// Retrieves whether the child is measured.
114func (x *OverlayLayoutChild) GetMeasure() bool {
115
116	cret := xOverlayLayoutChildGetMeasure(x.GoPointer())
117	return cret
118}
119
120var xOverlayLayoutChildSetClipOverlay func(uintptr, bool)
121
122// Sets whether to clip this child.
123func (x *OverlayLayoutChild) SetClipOverlay(ClipOverlayVar bool) {
124
125	xOverlayLayoutChildSetClipOverlay(x.GoPointer(), ClipOverlayVar)
126
127}
128
129var xOverlayLayoutChildSetMeasure func(uintptr, bool)
130
131// Sets whether to measure this child.
132func (x *OverlayLayoutChild) SetMeasure(MeasureVar bool) {
133
134	xOverlayLayoutChildSetMeasure(x.GoPointer(), MeasureVar)
135
136}
137
138func (c *OverlayLayoutChild) GoPointer() uintptr {
139	if c == nil {
140		return 0
141	}
142	return c.Ptr
143}
144
145func (c *OverlayLayoutChild) SetGoPointer(ptr uintptr) {
146	c.Ptr = ptr
147}
148
149// SetPropertyClipOverlay sets the "clip-overlay" property.
150// Whether the child should be clipped to fit the parent's size.
151func (x *OverlayLayoutChild) SetPropertyClipOverlay(value bool) {
152	var v gobject.Value
153	v.Init(gobject.TypeBooleanVal)
154	v.SetBoolean(value)
155	x.SetProperty("clip-overlay", &v)
156}
157
158// GetPropertyClipOverlay gets the "clip-overlay" property.
159// Whether the child should be clipped to fit the parent's size.
160func (x *OverlayLayoutChild) GetPropertyClipOverlay() bool {
161	var v gobject.Value
162	x.GetProperty("clip-overlay", &v)
163	return v.GetBoolean()
164}
165
166// SetPropertyMeasure sets the "measure" property.
167// Whether the child size should contribute to the `GtkOverlayLayout`'s
168// measurement.
169func (x *OverlayLayoutChild) SetPropertyMeasure(value bool) {
170	var v gobject.Value
171	v.Init(gobject.TypeBooleanVal)
172	v.SetBoolean(value)
173	x.SetProperty("measure", &v)
174}
175
176// GetPropertyMeasure gets the "measure" property.
177// Whether the child size should contribute to the `GtkOverlayLayout`'s
178// measurement.
179func (x *OverlayLayoutChild) GetPropertyMeasure() bool {
180	var v gobject.Value
181	x.GetProperty("measure", &v)
182	return v.GetBoolean()
183}
184
185func init() {
186	core.SetPackageName("GTK", "gtk4")
187	core.SetSharedLibraries("GTK", []string{"libgtk-4.so.1"})
188	var libs []uintptr
189	for _, libPath := range core.GetPaths("GTK") {
190		lib, err := purego.Dlopen(libPath, purego.RTLD_NOW|purego.RTLD_GLOBAL)
191		if err != nil {
192			panic(err)
193		}
194		libs = append(libs, lib)
195	}
196
197	core.PuregoSafeRegister(&xOverlayLayoutGLibType, libs, "gtk_overlay_layout_get_type")
198
199	core.PuregoSafeRegister(&xNewOverlayLayout, libs, "gtk_overlay_layout_new")
200
201	core.PuregoSafeRegister(&xOverlayLayoutChildGLibType, libs, "gtk_overlay_layout_child_get_type")
202
203	core.PuregoSafeRegister(&xOverlayLayoutChildGetClipOverlay, libs, "gtk_overlay_layout_child_get_clip_overlay")
204	core.PuregoSafeRegister(&xOverlayLayoutChildGetMeasure, libs, "gtk_overlay_layout_child_get_measure")
205	core.PuregoSafeRegister(&xOverlayLayoutChildSetClipOverlay, libs, "gtk_overlay_layout_child_set_clip_overlay")
206	core.PuregoSafeRegister(&xOverlayLayoutChildSetMeasure, libs, "gtk_overlay_layout_child_set_measure")
207
208}

Keyboard shortcuts

Single-key shortcuts are on. ctrl k and esc work whatever this says.

ctrl k :
go to a section, branch, tag, file or repository
?
this list
j k
move the row cursor down / up
enter
open the row under the cursor; on Files, a directory opens or closes in place
↑ ↓ ← → home end
in the file tree (focus on a row): previous / next row, close / open a directory or go to its parent / first entry, first / last row. They never open a file
l h
on Files: open a directory or a file / close a directory or go up to its parent, then to the parent page. Elsewhere: into the side panel (on a merge request, its files) / back to the content; there j k move between its controls
g g G
first / last row
/
filter the list; on Files, find a file anywhere in the repository (esc clears, enter opens the best match)
b
switch branch or tag
g s g f g c g b g m g i g r g a
tabs: summary, files, commits, branches & tags, merge requests, issues, releases, actions (when available)
g h
home
w
wide mode: use the whole width of the screen, or not (remembered)
y
copy a permalink pinned to the commit
d u x
diff: split / unified / collapse or expand all
e E
diff: the whole file in view / every file, with the lines the hunks hide
n
merge request: next note in the diff
esc
close a dialog, leave a field

Branches 1

Tags 102

↑↓ moveenter openesc close