gotk3extra

package module
v0.0.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 29, 2023 License: GPL-3.0 Imports: 8 Imported by: 1

README

gotk3extra

This adds some extra gtk3 functionality. For now, it's only GtkStatusIcon - and the code for it was created by the gotk3 project.

Build Status

API Documentation

GoDoc

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Cast

func Cast(c *C.GObject) (glib.IObject, error)

Cast takes a native GObject and casts it to the appropriate Go struct.

func CastInternal

func CastInternal(className string, obj *glib.Object) (interface{}, error)

CastInternal casts the given object to the appropriate Go struct, but returns it as interface for later type assertions. The className is the results of C.object_get_class_name(c) called on the native object. The obj is the result of glib.Take(unsafe.Pointer(c)), used as a parameter for the wrapper functions.

func CastWidget

func CastWidget(c *C.GtkWidget) (gtk.IWidget, error)

CastWidget takes a native GtkWidget and casts it to the appropriate Go struct.

func CastWidgetX

func CastWidgetX(c unsafe.Pointer) (gtk.IWidget, error)

CastWidgetX takes a native GtkWidget and casts it to the appropriate Go struct.

func CastX

func CastX(c unsafe.Pointer) (glib.IObject, error)

CastX takes a native GObject and casts it to the appropriate Go struct.

func GetAssistantButtonSizeGroup

func GetAssistantButtonSizeGroup(a *gtk.Assistant) (*gtk.SizeGroup, error)

func GetBuildableName

func GetBuildableName(obj *glib.Object) (string, error)

GetBuildableName is a wrapper around gtk_buildable_get_name().

func GetParent

func GetParent(v *gtk.Widget) (gtk.IWidget, error)

GetParent is a wrapper around gtk_widget_get_parent().

func GetWidgetBuildableName

func GetWidgetBuildableName(v *gtk.Widget) (string, error)

GetWidgetBuildableName is a wrapper around GetBuildableName(). It can be used to get the "buildable id" of any widget.

func GetWidgetTemplateChild

func GetWidgetTemplateChild(vv gtk.IWidget, name string) (*glib.Object, error)

GetWidgetTemplateChild is a wrapper around gtk_widget_get_template_child(). This will only report children which were previously declared with gtk_widget_class_bind_template_child_full() or one of its variants. In other case, it will return an error.

func InfoBarGetRevealed

func InfoBarGetRevealed(infobar *gtk.InfoBar) bool

InfoBarGetRevealed returns the current value of the infobar's revealed property.

func InfoBarSetRevealed

func InfoBarSetRevealed(infobar *gtk.InfoBar, setting bool)

InfoBarSetRevealed sets the revealed property to the infobar's revealer. This will cause infobar to show up with a slide-in transition. Note that this property does not automatically show infobar and thus won’t have any effect if it is invisible.

func WrapBox

func WrapBox(obj *glib.Object) *gtk.Box

WrapBox can be used to create a GTK box instance from the given object.

func WrapButton

func WrapButton(obj *glib.Object) *gtk.Button

WrapButton can be used to create a GTK button instance from the given object.

func WrapHeaderBar

func WrapHeaderBar(obj *glib.Object) *gtk.HeaderBar

WrapHeaderBar can be used to create a GTK header bar instance from the given object.

func WrapNotebook

func WrapNotebook(obj *glib.Object) *gtk.Notebook

WrapNotebook can be used to create a GTK notebook instance from the given object.

func WrapSizeGroup

func WrapSizeGroup(obj *glib.Object, e error) (*gtk.SizeGroup, error)

func WrapSizeGroupSimple

func WrapSizeGroupSimple(obj *glib.Object) *gtk.SizeGroup

func WrapWidget

func WrapWidget(obj *glib.Object) *gtk.Widget

WrapWidget can be used to create a GTK widget instance from the given object.

Types

type CSSClassCellRenderer

type CSSClassCellRenderer struct {
	gtk.CellRenderer
}

CSSClassCellRenderer is a representation of the native implementation.

func CSSClassCellRendererNew

func CSSClassCellRendererNew() (*CSSClassCellRenderer, error)

CSSClassCellRendererNew is a wrapper around css_class_cell_renderer_new().

func (*CSSClassCellRenderer) SetReal

func (v *CSSClassCellRenderer) SetReal(real *gtk.CellRenderer)

SetReal sets the real renderer for the CSS class renderer

type IconTheme

type IconTheme struct {
	*glib.Object
}

IconTheme is a representation of GTK's GtkIconTheme.

func IconThemeGetDefault

func IconThemeGetDefault() *IconTheme

IconThemeGetDefault is a wrapper around gtk_icon_theme_get_default()

func IconThemeGetForScreen

func IconThemeGetForScreen(screen *gdk.Screen) *IconTheme

IconThemeGetForScreen is a wrapper around gtk_icon_theme_get_for_screen()

func IconThemeNew

func IconThemeNew() (*IconTheme, error)

IconThemeNew is a wrapper around gtk_icon_theme_new()

func (*IconTheme) AddResourcePath

func (v *IconTheme) AddResourcePath(s string)

AddResourcePath is a wrapper around gtk_icon_theme_add_resource_path()

func (*IconTheme) AppendSearchPath

func (v *IconTheme) AppendSearchPath(s string)

AppendSearchPath is a wrapper around gtk_icon_theme_append_search_path()

func (*IconTheme) GetExampleIconName

func (v *IconTheme) GetExampleIconName() string

GetExampleIconName is a wrapper around gtk_icon_theme_get_example_icon_name()

func (*IconTheme) HasIcon

func (v *IconTheme) HasIcon(s string) bool

HasIcon is a wrapper around gtk_icon_theme_has_icon()

func (*IconTheme) PrependSearchPath

func (v *IconTheme) PrependSearchPath(s string)

PrependSearchPath is a wrapper around gtk_icon_theme_prepend_search_path()

type MenuToolButton struct {
	gtk.ToolButton
}

MenuToolButton is a representation of GTK's GtkMenuToolButton.

type StatusIcon

type StatusIcon struct {
	*glib.Object
}

StatusIcon is a representation of GTK's GtkStatusIcon. Deprecated since 3.14 in favor of notifications (no replacement, see https://stackoverflow.com/questions/41917903/gtk-3-statusicon-replacement)

func StatusIconNew

func StatusIconNew() (*StatusIcon, error)

StatusIconNew is a wrapper around gtk_status_icon_new()

func StatusIconNewFromFile

func StatusIconNewFromFile(filename string) (*StatusIcon, error)

StatusIconNewFromFile is a wrapper around gtk_status_icon_new_from_file()

func StatusIconNewFromIconName

func StatusIconNewFromIconName(iconName string) (*StatusIcon, error)

StatusIconNewFromIconName is a wrapper around gtk_status_icon_new_from_icon_name()

func StatusIconNewFromPixbuf

func StatusIconNewFromPixbuf(pixbuf *gdk.Pixbuf) (*StatusIcon, error)

StatusIconNewFromPixbuf is a wrapper around gtk_status_icon_new_from_pixbuf().

func (*StatusIcon) GetHasTooltip

func (v *StatusIcon) GetHasTooltip() bool

GetHasTooltip is a wrapper around gtk_status_icon_get_has_tooltip()

func (*StatusIcon) GetIconName

func (v *StatusIcon) GetIconName() string

GetIconName is a wrapper around gtk_status_icon_get_icon_name()

func (*StatusIcon) GetSize

func (v *StatusIcon) GetSize() int

GetSize is a wrapper around gtk_status_icon_get_size()

func (*StatusIcon) GetStorageType

func (v *StatusIcon) GetStorageType() gtk.ImageType

GetStorageType is a wrapper around gtk_status_icon_get_storage_type()

func (*StatusIcon) GetTitle

func (v *StatusIcon) GetTitle() string

GetTitle is a wrapper around gtk_status_icon_get_title()

func (*StatusIcon) GetTooltipMarkup

func (v *StatusIcon) GetTooltipMarkup() string

GetTooltipMarkup is a wrapper around gtk_status_icon_get_tooltip_markup()

func (*StatusIcon) GetTooltipText

func (v *StatusIcon) GetTooltipText() string

GetTooltipText is a wrapper around gtk_status_icon_get_tooltip_text()

func (*StatusIcon) GetVisible

func (v *StatusIcon) GetVisible() bool

GetVisible is a wrapper around gtk_status_icon_get_visible()

func (*StatusIcon) GetX11WindowID

func (v *StatusIcon) GetX11WindowID() uint32

GetX11WindowID is a wrapper around gtk_status_icon_get_x11_window_id()

func (*StatusIcon) IsEmbedded

func (v *StatusIcon) IsEmbedded() bool

IsEmbedded is a wrapper around gtk_status_icon_is_embedded()

func (*StatusIcon) SetFromFile

func (v *StatusIcon) SetFromFile(filename string)

SetFromFile is a wrapper around gtk_status_icon_set_from_file()

func (*StatusIcon) SetFromIconName

func (v *StatusIcon) SetFromIconName(iconName string)

SetFromIconName is a wrapper around gtk_status_icon_set_from_icon_name()

func (*StatusIcon) SetFromPixbuf

func (v *StatusIcon) SetFromPixbuf(pixbuf *gdk.Pixbuf)

SetFromPixbuf is a wrapper around gtk_status_icon_set_from_pixbuf()

func (*StatusIcon) SetHasTooltip

func (v *StatusIcon) SetHasTooltip(hasTooltip bool)

SetHasTooltip is a wrapper around gtk_status_icon_set_has_tooltip()

func (*StatusIcon) SetName

func (v *StatusIcon) SetName(name string)

SetName is a wrapper around gtk_status_icon_set_name()

func (*StatusIcon) SetTitle

func (v *StatusIcon) SetTitle(title string)

SetTitle is a wrapper around gtk_status_icon_set_title()

func (*StatusIcon) SetTooltipMarkup

func (v *StatusIcon) SetTooltipMarkup(markup string)

SetTooltipMarkup is a wrapper around gtk_status_icon_set_tooltip_markup()

func (*StatusIcon) SetTooltipText

func (v *StatusIcon) SetTooltipText(text string)

SetTooltipText is a wrapper around gtk_status_icon_set_tooltip_text()

func (*StatusIcon) SetVisible

func (v *StatusIcon) SetVisible(visible bool)

SetVisible is a wrapper around gtk_status_icon_set_visible()

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL