pub trait MarkAttributesExt: IsA<MarkAttributes> + Sealed + 'static {
Show 17 methods // Provided methods fn background(&self) -> Option<RGBA> { ... } fn gicon(&self) -> Option<Icon> { ... } fn icon_name(&self) -> Option<GString> { ... } fn pixbuf(&self) -> Option<Pixbuf> { ... } fn tooltip_markup(&self, mark: &impl IsA<Mark>) -> Option<GString> { ... } fn tooltip_text(&self, mark: &impl IsA<Mark>) -> Option<GString> { ... } fn render_icon( &self, widget: &impl IsA<Widget>, size: i32 ) -> Option<Pixbuf> { ... } fn set_background(&self, background: &RGBA) { ... } fn set_gicon(&self, gicon: &impl IsA<Icon>) { ... } fn set_icon_name(&self, icon_name: &str) { ... } fn set_pixbuf(&self, pixbuf: &Pixbuf) { ... } fn connect_query_tooltip_markup<F: Fn(&Self, &Mark) -> String + 'static>( &self, f: F ) -> SignalHandlerId { ... } fn connect_query_tooltip_text<F: Fn(&Self, &Mark) -> String + 'static>( &self, f: F ) -> SignalHandlerId { ... } fn connect_background_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId { ... } fn connect_gicon_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId { ... } fn connect_icon_name_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId { ... } fn connect_pixbuf_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId { ... }
}
Expand description

Trait containing all MarkAttributes methods.

Implementors

MarkAttributes

Provided Methods§

source

fn background(&self) -> Option<RGBA>

Stores background color in background.

Returns

whether background color for self was set.

background

a gdk::RGBA.

source

fn gicon(&self) -> Option<Icon>

Gets a gio::Icon to be used as a base for rendered icon. Note that the icon can be None if it wasn’t set earlier.

Returns

An icon. The icon belongs to self and should not be unreffed.

source

fn icon_name(&self) -> Option<GString>

Gets a name of an icon to be used as a base for rendered icon. Note that the icon name can be None if it wasn’t set earlier.

Returns

An icon name. The string belongs to self and should not be freed.

source

fn pixbuf(&self) -> Option<Pixbuf>

Gets a gdk_pixbuf::Pixbuf to be used as a base for rendered icon. Note that the pixbuf can be None if it wasn’t set earlier.

Returns

A pixbuf. The pixbuf belongs to self and should not be unreffed.

source

fn tooltip_markup(&self, mark: &impl IsA<Mark>) -> Option<GString>

Queries for a tooltip by emitting a query-tooltip-markup signal. The tooltip may contain a markup.

mark

a Mark.

Returns

A tooltip. The returned string should be freed by using g_free() when done with it.

source

fn tooltip_text(&self, mark: &impl IsA<Mark>) -> Option<GString>

Queries for a tooltip by emitting a query-tooltip-text signal. The tooltip is a plain text.

mark

a Mark.

Returns

A tooltip. The returned string should be freed by using g_free() when done with it.

source

fn render_icon(&self, widget: &impl IsA<Widget>, size: i32) -> Option<Pixbuf>

Renders an icon of given size. The base of the icon is set by the last call to one of: set_pixbuf(), set_gicon() or set_icon_name(). size cannot be lower than 1.

widget

widget of which style settings may be used.

size

size of the rendered icon.

Returns

A rendered pixbuf. The pixbuf belongs to self and should not be unreffed.

source

fn set_background(&self, background: &RGBA)

Sets background color to the one given in background.

background

a gdk::RGBA.

source

fn set_gicon(&self, gicon: &impl IsA<Icon>)

Sets an icon to be used as a base for rendered icon.

gicon

a gio::Icon to be used.

source

fn set_icon_name(&self, icon_name: &str)

Sets a name of an icon to be used as a base for rendered icon.

icon_name

name of an icon to be used.

source

fn set_pixbuf(&self, pixbuf: &Pixbuf)

Sets a pixbuf to be used as a base for rendered icon.

pixbuf

a gdk_pixbuf::Pixbuf to be used.

source

fn connect_query_tooltip_markup<F: Fn(&Self, &Mark) -> String + 'static>( &self, f: F ) -> SignalHandlerId

The code should connect to this signal to provide a tooltip for given mark. The tooltip can contain a markup.

mark

The Mark.

Returns

A tooltip. The string should be freed with g_free() when done with it.

source

fn connect_query_tooltip_text<F: Fn(&Self, &Mark) -> String + 'static>( &self, f: F ) -> SignalHandlerId

The code should connect to this signal to provide a tooltip for given mark. The tooltip should be just a plain text.

mark

The Mark.

Returns

A tooltip. The string should be freed with g_free() when done with it.

source

fn connect_background_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId

source

fn connect_gicon_notify<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId

source

fn connect_icon_name_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId

source

fn connect_pixbuf_notify<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId

Object Safety§

This trait is not object safe.

Implementors§