libgui 3.00
libgui is a GUI library for the GameCube, Wii, and Wii U
 
Loading...
Searching...
No Matches
GuiPopover::Anchor Struct Reference

The control a popover opens beside, in canvas pixels. More...

#include <GuiPopover.h>

Public Types

enum  Edge { AUTO , LEFT_MARGIN , RIGHT_MARGIN , BESIDE }
 Which way the panel lines up: with the anchor's nearer edge (AUTO), or against a side margin to leave the other side of the screen clear. More...
 

Public Member Functions

 Anchor ()
 No anchor: the popover is centered.
 
 Anchor (int ax, int ay, int aw, int ah, Edge e=AUTO)
 The popover opens beside the rectangle ax,ay,aw,ah
 
 Anchor (GuiElement &control, Edge e=AUTO)
 The popover opens beside control, where it is now.
 

Public Attributes

int x
 
int y
 
int w
 
int h
 
bool valid
 false for a popover with no anchor: it is centered
 
Edge edge
 

Detailed Description

The control a popover opens beside, in canvas pixels.

Definition at line 39 of file GuiPopover.h.

Member Enumeration Documentation

◆ Edge

Which way the panel lines up: with the anchor's nearer edge (AUTO), or against a side margin to leave the other side of the screen clear.

BESIDE puts it level with the anchor, to its right (or its left when there is no room), so the anchor itself stays visible; for a card in a list

Definition at line 43 of file GuiPopover.h.

Constructor & Destructor Documentation

◆ Anchor() [1/3]

GuiPopover::Anchor::Anchor ( )
inline

No anchor: the popover is centered.

Definition at line 48 of file GuiPopover.h.

◆ Anchor() [2/3]

GuiPopover::Anchor::Anchor ( int ax,
int ay,
int aw,
int ah,
Edge e = AUTO )
inline

The popover opens beside the rectangle ax,ay,aw,ah

Definition at line 50 of file GuiPopover.h.

◆ Anchor() [3/3]

GuiPopover::Anchor::Anchor ( GuiElement & control,
Edge e = AUTO )
inlineexplicit

The popover opens beside control, where it is now.

Definition at line 52 of file GuiPopover.h.

Member Data Documentation

◆ edge

Edge GuiPopover::Anchor::edge

Definition at line 46 of file GuiPopover.h.

◆ h

int GuiPopover::Anchor::h

Definition at line 44 of file GuiPopover.h.

◆ valid

bool GuiPopover::Anchor::valid

false for a popover with no anchor: it is centered

Definition at line 45 of file GuiPopover.h.

◆ w

int GuiPopover::Anchor::w

Definition at line 44 of file GuiPopover.h.

◆ x

int GuiPopover::Anchor::x

Definition at line 44 of file GuiPopover.h.

◆ y

int GuiPopover::Anchor::y

Definition at line 44 of file GuiPopover.h.


The documentation for this struct was generated from the following file: