Documentation
¶
Overview ¶
Package testclient is a scripted Wayland client for integration tests: it maps toplevels, paints shm frames and keeps animating while frame callbacks arrive.
Index ¶
- func UDMABUF(size image.Point, paint Painter) (gpu.DMABUF, func() error, error)
- type Answer
- type Band
- type Client
- func (c *Client) Bind(r wire.Resource)
- func (c *Client) Buffer(size image.Point, frame int, paint Painter) *cw.WlBuffer
- func (c *Client) Clipboard(seat *cw.WlSeat) *Clipboard
- func (c *Client) DMABUF(size image.Point, paint Painter) *DMABUF
- func (c *Client) DMABUFIn(format fourcc.Format, size image.Point, paint Painter) *DMABUF
- func (c *Client) DMABUFOutside(size image.Point, excluded []fourcc.Modifier) (*DMABUF, bool)
- func (c *Client) DataSource(content map[string]string) *Source
- func (c *Client) Dialog(parent *Window, title string, paint Painter) *Window
- func (c *Client) DispatchUntil(what string, cond func() bool)
- func (c *Client) ExpectProtocolError(code uint32) *wire.ProtocolError
- func (c *Client) FormatBuffer(size image.Point, format cw.WlShmFormat, frame int, paint Painter) *cw.WlBuffer
- func (c *Client) HasDMABUFFeedback() bool
- func (c *Client) HasGlobal(iface string) bool
- func (c *Client) Layer(spec LayerSpec, paint Painter) *Window
- func (c *Client) PartialWindow(title string, paint Painter, damage Damager) *Window
- func (c *Client) Popup(parent *Window, p Placement, grab *Grab, paint Painter) *Window
- func (c *Client) Positioner(p Placement) *cxdg.XdgPositioner
- func (c *Client) PrimarySource(content map[string]string) *Source
- func (c *Client) Receive(request func(fd int) error, source *Client) string
- func (c *Client) RenderTarget(size image.Point, modifiers []fourcc.Modifier) *DMABUF
- func (c *Client) ScaledWindow(title string, scaling Scaling, paint Painter) *Window
- func (c *Client) Seat() (*cw.WlSeat, *Input)
- func (c *Client) Surface() *cw.WlSurface
- func (c *Client) Sync()
- func (c *Client) Target(size image.Point) (*cw.WlBuffer, []byte)
- func (c *Client) Window(title string, paint Painter) *Window
- func (c *Client) WindowWith(title string, paint Painter, setup func(*Window) error) *Window
- type Clipboard
- type DMABUF
- type Damager
- type Grab
- type Input
- type LayerSpec
- type Log
- type Offer
- type Painter
- type Placement
- type Scaling
- type Source
- type Window
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Client ¶
type Client struct {
Display *wlclient.Display
Compositor *cw.WlCompositor
Subcompositor *cw.WlSubcompositor
Shm *cw.WlShm
WM *cxdg.XdgWmBase
Viewporter *cvp.WpViewporter
Fractional *cfs.WpFractionalScaleManagerV1
CursorShape *ccs.WpCursorShapeManagerV1
LayerShell *cwlr.ZwlrLayerShellV1
DataDevices *cw.WlDataDeviceManager
PrimarySelection *cps.ZwpPrimarySelectionDeviceManagerV1
Outputs []*cw.WlOutput
// contains filtered or unexported fields
}
func (*Client) DMABUFOutside ¶
func (*Client) DispatchUntil ¶
func (*Client) ExpectProtocolError ¶
func (c *Client) ExpectProtocolError(code uint32) *wire.ProtocolError
func (*Client) FormatBuffer ¶
func (*Client) HasDMABUFFeedback ¶
func (*Client) PartialWindow ¶
func (*Client) Positioner ¶
func (c *Client) Positioner(p Placement) *cxdg.XdgPositioner
func (*Client) RenderTarget ¶
func (*Client) ScaledWindow ¶
type Clipboard ¶
type Clipboard struct {
Device *cw.WlDataDevice
Primaries *cps.ZwpPrimarySelectionDeviceV1
Log Log
Selection *Offer
Primary *Offer
Drag *Offer
Serial uint32
// contains filtered or unexported fields
}
type Input ¶
type LayerSpec ¶
type LayerSpec struct {
Output *cw.WlOutput
Layer cwlr.ZwlrLayerShellV1Layer
Anchor cwlr.ZwlrLayerSurfaceV1Anchor
Size image.Point
ExclusiveZone int32
Interactivity cwlr.ZwlrLayerSurfaceV1KeyboardInteractivity
Namespace string
}
type Offer ¶
type Offer struct {
Data *cw.WlDataOffer
Primary *cps.ZwpPrimarySelectionOfferV1
Mimes []string
SourceActions cw.WlDataDeviceManagerDndAction
Action cw.WlDataDeviceManagerDndAction
}
type Placement ¶
type Placement struct {
Size image.Point
Anchor image.Rectangle
Edge cxdg.XdgPositionerAnchor
Gravity cxdg.XdgPositionerGravity
Adjustment cxdg.XdgPositionerConstraintAdjustment
}
type Source ¶
type Source struct {
Data *cw.WlDataSource
Primary *cps.ZwpPrimarySelectionSourceV1
Log Log
Send func(mime string, f *os.File)
// contains filtered or unexported fields
}
type Window ¶
type Window struct {
Surface *cw.WlSurface
XdgSurface *cxdg.XdgSurface
Toplevel *cxdg.XdgToplevel
Popup *cxdg.XdgPopup
Layer *cwlr.ZwlrLayerSurfaceV1
Placed image.Rectangle
Dismissed bool
Logical image.Point
Size image.Point
BufferScale int32
Preferred120 uint32
Entered int
Frames int
Closed bool
States []cxdg.XdgToplevelState
Translucent bool
Answer Answer
Configures int
// contains filtered or unexported fields
}
Click to show internal directories.
Click to hide internal directories.