Top | ![]() |
![]() |
![]() |
![]() |
GtkWidget * | budgie_popover_new () |
void | budgie_popover_set_position_policy () |
BudgiePopoverPositionPolicy | budgie_popover_get_position_policy () |
BudgiePopoverPositionPolicy | position-policy | Read / Write |
GtkWidget * | relative-to | Read / Write |
GEnum ╰── BudgiePopoverPositionPolicy GObject ╰── GInitiallyUnowned ╰── GtkWidget ╰── GtkContainer ╰── GtkBin ╰── GtkWindow ╰── BudgiePopover
The BudgiePopover is a specialised top level window with a tail pointer, providing a decorative approach to panel windows. These windows point at the source of an event, such as a button, and allow rich user interfaces to be built with a focus on Budgie Panel usage.
The BudgiePopover should be used in conjunction with the BudgiePopoverManager. Simply add your content to the popover, and ensure that you call “show_all” to display the contents.
Your popover may be dismissed from screen in response to an event, such as the user pressing the button again, or automatically, as the user clicked outside of the window, or even because the BudgiePopoverManager switched to a new active popover. You may connect to the “closed” signal to check for this event.
GtkWidget *
budgie_popover_new (GtkWidget *relative_to
);
Construct a new BudgiePopover object
void budgie_popover_set_position_policy (BudgiePopover *popover
,BudgiePopoverPositionPolicy policy
);
Set the positioning policy employed by the popover
BudgiePopoverPositionPolicy
budgie_popover_get_position_policy (BudgiePopover *popover
);
Retrieve the currently active positioning policy for this popover
struct BudgiePopoverClass { GtkWindowClass parent_class; /* Marked for gtk-doc syntax */ void (*closed)(BudgiePopover* popover); gpointer padding[12]; };
The BudgiePopoverPositionPolicy determines how the BudgiePopover will be placed on screen. The default policy (AUTOMATIC) will try to place the popover at a sensible location relative to the parent widget, and point the tail accordingly.
The TOPLEVEL_HINT policy is designed for use with panels + docks, where the top level window owning the relative-to widget sets a CSS class on itself in accordance with the screen edge, i.e. top, left, bottom, right.
“position-policy”
property“position-policy” BudgiePopoverPositionPolicy
Control the behavior used to place the popover on screen.
Owner: BudgiePopover
Flags: Read / Write
Default value: BUDGIE_POPOVER_POSITION_AUTOMATIC
“closed”
signalvoid user_function (BudgiePopover *popover, gpointer user_data)
This signal is emitted when the popover has been dismissed, whether it was deliberately from the user's perspective, or implicitly through a toggling action, such as being rolled past in a BudgiePopoverManager set of popovers.
popover |
The popover that has been closed |
|
user_data |
user data set when the signal handler was connected. |
Flags: Action