const ( SkBounding = 0 SkClip = 1 SkInput = 2 )
const ( SoSet = 0 SoUnion = 1 SoIntersect = 2 SoSubtract = 3 SoInvert = 4 )
Notify is the event number for a NotifyEvent.
const Notify = 0
func Init(c *xgb.Conn) error
Init must be called before using the SHAPE extension.
func NotifyEventNew(buf []byte) xgb.Event
NotifyEventNew constructs a NotifyEvent value that implements xgb.Event from a byte slice.
CombineCookie is a cookie used only for Combine requests.
type CombineCookie struct { *xgb.Cookie }
func Combine(c *xgb.Conn, Operation Op, DestinationKind Kind, SourceKind Kind, DestinationWindow xproto.Window, XOffset int16, YOffset int16, SourceWindow xproto.Window) CombineCookie
Combine sends an unchecked request. If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.
func CombineChecked(c *xgb.Conn, Operation Op, DestinationKind Kind, SourceKind Kind, DestinationWindow xproto.Window, XOffset int16, YOffset int16, SourceWindow xproto.Window) CombineCookie
CombineChecked sends a checked request. If an error occurs, it can be retrieved using CombineCookie.Check()
func (cook CombineCookie) Check() error
Check returns an error if one occurred for checked requests that are not expecting a reply. This cannot be called for requests expecting a reply, nor for unchecked requests.
GetRectanglesCookie is a cookie used only for GetRectangles requests.
type GetRectanglesCookie struct { *xgb.Cookie }
func GetRectangles(c *xgb.Conn, Window xproto.Window, SourceKind Kind) GetRectanglesCookie
GetRectangles sends a checked request. If an error occurs, it will be returned with the reply by calling GetRectanglesCookie.Reply()
func GetRectanglesUnchecked(c *xgb.Conn, Window xproto.Window, SourceKind Kind) GetRectanglesCookie
GetRectanglesUnchecked sends an unchecked request. If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.
func (cook GetRectanglesCookie) Reply() (*GetRectanglesReply, error)
Reply blocks and returns the reply data for a GetRectangles request.
GetRectanglesReply represents the data returned from a GetRectangles request.
type GetRectanglesReply struct { Sequence uint16 // sequence number of the request for this reply Length uint32 // number of bytes in this reply Ordering byte RectanglesLen uint32 // padding: 20 bytes Rectangles []xproto.Rectangle // size: xgb.Pad((int(RectanglesLen) * 8)) }
InputSelectedCookie is a cookie used only for InputSelected requests.
type InputSelectedCookie struct { *xgb.Cookie }
func InputSelected(c *xgb.Conn, DestinationWindow xproto.Window) InputSelectedCookie
InputSelected sends a checked request. If an error occurs, it will be returned with the reply by calling InputSelectedCookie.Reply()
func InputSelectedUnchecked(c *xgb.Conn, DestinationWindow xproto.Window) InputSelectedCookie
InputSelectedUnchecked sends an unchecked request. If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.
func (cook InputSelectedCookie) Reply() (*InputSelectedReply, error)
Reply blocks and returns the reply data for a InputSelected request.
InputSelectedReply represents the data returned from a InputSelected request.
type InputSelectedReply struct { Sequence uint16 // sequence number of the request for this reply Length uint32 // number of bytes in this reply Enabled bool }
type Kind byte
MaskCookie is a cookie used only for Mask requests.
type MaskCookie struct { *xgb.Cookie }
func Mask(c *xgb.Conn, Operation Op, DestinationKind Kind, DestinationWindow xproto.Window, XOffset int16, YOffset int16, SourceBitmap xproto.Pixmap) MaskCookie
Mask sends an unchecked request. If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.
func MaskChecked(c *xgb.Conn, Operation Op, DestinationKind Kind, DestinationWindow xproto.Window, XOffset int16, YOffset int16, SourceBitmap xproto.Pixmap) MaskCookie
MaskChecked sends a checked request. If an error occurs, it can be retrieved using MaskCookie.Check()
func (cook MaskCookie) Check() error
Check returns an error if one occurred for checked requests that are not expecting a reply. This cannot be called for requests expecting a reply, nor for unchecked requests.
type NotifyEvent struct { Sequence uint16 ShapeKind Kind AffectedWindow xproto.Window ExtentsX int16 ExtentsY int16 ExtentsWidth uint16 ExtentsHeight uint16 ServerTime xproto.Timestamp Shaped bool }
func (v NotifyEvent) Bytes() []byte
Bytes writes a NotifyEvent value to a byte slice.
func (v NotifyEvent) SequenceId() uint16
SequenceId returns the sequence id attached to the Notify event. Events without a sequence number (KeymapNotify) return 0. This is mostly used internally.
func (v NotifyEvent) String() string
String is a rudimentary string representation of NotifyEvent.
OffsetCookie is a cookie used only for Offset requests.
type OffsetCookie struct { *xgb.Cookie }
func Offset(c *xgb.Conn, DestinationKind Kind, DestinationWindow xproto.Window, XOffset int16, YOffset int16) OffsetCookie
Offset sends an unchecked request. If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.
func OffsetChecked(c *xgb.Conn, DestinationKind Kind, DestinationWindow xproto.Window, XOffset int16, YOffset int16) OffsetCookie
OffsetChecked sends a checked request. If an error occurs, it can be retrieved using OffsetCookie.Check()
func (cook OffsetCookie) Check() error
Check returns an error if one occurred for checked requests that are not expecting a reply. This cannot be called for requests expecting a reply, nor for unchecked requests.
type Op byte
QueryExtentsCookie is a cookie used only for QueryExtents requests.
type QueryExtentsCookie struct { *xgb.Cookie }
func QueryExtents(c *xgb.Conn, DestinationWindow xproto.Window) QueryExtentsCookie
QueryExtents sends a checked request. If an error occurs, it will be returned with the reply by calling QueryExtentsCookie.Reply()
func QueryExtentsUnchecked(c *xgb.Conn, DestinationWindow xproto.Window) QueryExtentsCookie
QueryExtentsUnchecked sends an unchecked request. If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.
func (cook QueryExtentsCookie) Reply() (*QueryExtentsReply, error)
Reply blocks and returns the reply data for a QueryExtents request.
QueryExtentsReply represents the data returned from a QueryExtents request.
type QueryExtentsReply struct { Sequence uint16 // sequence number of the request for this reply Length uint32 // number of bytes in this reply // padding: 1 bytes BoundingShaped bool ClipShaped bool // padding: 2 bytes BoundingShapeExtentsX int16 BoundingShapeExtentsY int16 BoundingShapeExtentsWidth uint16 BoundingShapeExtentsHeight uint16 ClipShapeExtentsX int16 ClipShapeExtentsY int16 ClipShapeExtentsWidth uint16 ClipShapeExtentsHeight uint16 }
QueryVersionCookie is a cookie used only for QueryVersion requests.
type QueryVersionCookie struct { *xgb.Cookie }
func QueryVersion(c *xgb.Conn) QueryVersionCookie
QueryVersion sends a checked request. If an error occurs, it will be returned with the reply by calling QueryVersionCookie.Reply()
func QueryVersionUnchecked(c *xgb.Conn) QueryVersionCookie
QueryVersionUnchecked sends an unchecked request. If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.
func (cook QueryVersionCookie) Reply() (*QueryVersionReply, error)
Reply blocks and returns the reply data for a QueryVersion request.
QueryVersionReply represents the data returned from a QueryVersion request.
type QueryVersionReply struct { Sequence uint16 // sequence number of the request for this reply Length uint32 // number of bytes in this reply // padding: 1 bytes MajorVersion uint16 MinorVersion uint16 }
RectanglesCookie is a cookie used only for Rectangles requests.
type RectanglesCookie struct { *xgb.Cookie }
func Rectangles(c *xgb.Conn, Operation Op, DestinationKind Kind, Ordering byte, DestinationWindow xproto.Window, XOffset int16, YOffset int16, Rectangles []xproto.Rectangle) RectanglesCookie
Rectangles sends an unchecked request. If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.
func RectanglesChecked(c *xgb.Conn, Operation Op, DestinationKind Kind, Ordering byte, DestinationWindow xproto.Window, XOffset int16, YOffset int16, Rectangles []xproto.Rectangle) RectanglesCookie
RectanglesChecked sends a checked request. If an error occurs, it can be retrieved using RectanglesCookie.Check()
func (cook RectanglesCookie) Check() error
Check returns an error if one occurred for checked requests that are not expecting a reply. This cannot be called for requests expecting a reply, nor for unchecked requests.
SelectInputCookie is a cookie used only for SelectInput requests.
type SelectInputCookie struct { *xgb.Cookie }
func SelectInput(c *xgb.Conn, DestinationWindow xproto.Window, Enable bool) SelectInputCookie
SelectInput sends an unchecked request. If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.
func SelectInputChecked(c *xgb.Conn, DestinationWindow xproto.Window, Enable bool) SelectInputCookie
SelectInputChecked sends a checked request. If an error occurs, it can be retrieved using SelectInputCookie.Check()
func (cook SelectInputCookie) Check() error
Check returns an error if one occurred for checked requests that are not expecting a reply. This cannot be called for requests expecting a reply, nor for unchecked requests.