diff options
Diffstat (limited to 'nexgb/randr')
| -rw-r--r-- | nexgb/randr/randr.go | 632 | 
1 files changed, 363 insertions, 269 deletions
| diff --git a/nexgb/randr/randr.go b/nexgb/randr/randr.go index ba8c0f2..35de3bf 100644 --- a/nexgb/randr/randr.go +++ b/nexgb/randr/randr.go @@ -2,7 +2,7 @@  package randr  /* -	This file was generated by randr.xml on May 10 2012 8:04:31pm EDT. +	This file was generated by randr.xml on May 10 2012 11:56:19pm EDT.  	This file is automatically generated. Edit at your peril!  */ @@ -41,6 +41,12 @@ func init() {  	xgb.NewExtErrorFuncs["RANDR"] = make(map[int]xgb.NewErrorFun)  } +// Skipping definition for base type 'Card8' + +// Skipping definition for base type 'Int16' + +// Skipping definition for base type 'Int32' +  // Skipping definition for base type 'Void'  // Skipping definition for base type 'Byte' @@ -59,12 +65,6 @@ func init() {  // Skipping definition for base type 'Float' -// Skipping definition for base type 'Card8' - -// Skipping definition for base type 'Int16' - -// Skipping definition for base type 'Int32' -  const (  	RotationRotate0   = 1  	RotationRotate90  = 2 @@ -147,8 +147,6 @@ func NewOutputId(c *xgb.Conn) (Output, error) {  	return Output(id), nil  } -// 'ScreenSize' struct definition -// Size: 8  type ScreenSize struct {  	Width   uint16  	Height  uint16 @@ -156,7 +154,7 @@ type ScreenSize struct {  	Mheight uint16  } -// Struct read ScreenSize +// ScreenSizeRead reads a byte slice into a ScreenSize value.  func ScreenSizeRead(buf []byte, v *ScreenSize) int {  	b := 0 @@ -175,7 +173,7 @@ func ScreenSizeRead(buf []byte, v *ScreenSize) int {  	return b  } -// Struct list read ScreenSize +// ScreenSizeReadList reads a byte slice into a list of ScreenSize values.  func ScreenSizeReadList(buf []byte, dest []ScreenSize) int {  	b := 0  	for i := 0; i < len(dest); i++ { @@ -185,7 +183,7 @@ func ScreenSizeReadList(buf []byte, dest []ScreenSize) int {  	return xgb.Pad(b)  } -// Struct write ScreenSize +// Bytes writes a ScreenSize value to a byte slice.  func (v ScreenSize) Bytes() []byte {  	buf := make([]byte, 8)  	b := 0 @@ -205,7 +203,7 @@ func (v ScreenSize) Bytes() []byte {  	return buf  } -// Write struct list ScreenSize +// ScreenSizeListBytes writes a list of %s(MISSING) values to a byte slice.  func ScreenSizeListBytes(buf []byte, list []ScreenSize) int {  	b := 0  	var structBytes []byte @@ -217,14 +215,12 @@ func ScreenSizeListBytes(buf []byte, list []ScreenSize) int {  	return b  } -// 'RefreshRates' struct definition -// Size: (2 + xgb.Pad((int(NRates) * 2)))  type RefreshRates struct {  	NRates uint16  	Rates  []uint16 // size: xgb.Pad((int(NRates) * 2))  } -// Struct read RefreshRates +// RefreshRatesRead reads a byte slice into a RefreshRates value.  func RefreshRatesRead(buf []byte, v *RefreshRates) int {  	b := 0 @@ -241,7 +237,7 @@ func RefreshRatesRead(buf []byte, v *RefreshRates) int {  	return b  } -// Struct list read RefreshRates +// RefreshRatesReadList reads a byte slice into a list of RefreshRates values.  func RefreshRatesReadList(buf []byte, dest []RefreshRates) int {  	b := 0  	for i := 0; i < len(dest); i++ { @@ -251,7 +247,7 @@ func RefreshRatesReadList(buf []byte, dest []RefreshRates) int {  	return xgb.Pad(b)  } -// Struct write RefreshRates +// Bytes writes a RefreshRates value to a byte slice.  func (v RefreshRates) Bytes() []byte {  	buf := make([]byte, (2 + xgb.Pad((int(v.NRates) * 2))))  	b := 0 @@ -268,7 +264,7 @@ func (v RefreshRates) Bytes() []byte {  	return buf  } -// Write struct list RefreshRates +// RefreshRatesListBytes writes a list of %s(MISSING) values to a byte slice.  func RefreshRatesListBytes(buf []byte, list []RefreshRates) int {  	b := 0  	var structBytes []byte @@ -280,7 +276,7 @@ func RefreshRatesListBytes(buf []byte, list []RefreshRates) int {  	return b  } -// Struct list size RefreshRates +// RefreshRatesListSize computes the size (bytes) of a list of RefreshRates values.  func RefreshRatesListSize(list []RefreshRates) int {  	size := 0  	for _, item := range list { @@ -289,8 +285,6 @@ func RefreshRatesListSize(list []RefreshRates) int {  	return size  } -// 'ModeInfo' struct definition -// Size: 32  type ModeInfo struct {  	Id         uint32  	Width      uint16 @@ -307,7 +301,7 @@ type ModeInfo struct {  	ModeFlags  uint32  } -// Struct read ModeInfo +// ModeInfoRead reads a byte slice into a ModeInfo value.  func ModeInfoRead(buf []byte, v *ModeInfo) int {  	b := 0 @@ -353,7 +347,7 @@ func ModeInfoRead(buf []byte, v *ModeInfo) int {  	return b  } -// Struct list read ModeInfo +// ModeInfoReadList reads a byte slice into a list of ModeInfo values.  func ModeInfoReadList(buf []byte, dest []ModeInfo) int {  	b := 0  	for i := 0; i < len(dest); i++ { @@ -363,7 +357,7 @@ func ModeInfoReadList(buf []byte, dest []ModeInfo) int {  	return xgb.Pad(b)  } -// Struct write ModeInfo +// Bytes writes a ModeInfo value to a byte slice.  func (v ModeInfo) Bytes() []byte {  	buf := make([]byte, 32)  	b := 0 @@ -410,7 +404,7 @@ func (v ModeInfo) Bytes() []byte {  	return buf  } -// Write struct list ModeInfo +// ModeInfoListBytes writes a list of %s(MISSING) values to a byte slice.  func ModeInfoListBytes(buf []byte, list []ModeInfo) int {  	b := 0  	var structBytes []byte @@ -422,8 +416,6 @@ func ModeInfoListBytes(buf []byte, list []ModeInfo) int {  	return b  } -// 'CrtcChange' struct definition -// Size: 28  type CrtcChange struct {  	Timestamp xproto.Timestamp  	Window    xproto.Window @@ -437,7 +429,7 @@ type CrtcChange struct {  	Height uint16  } -// Struct read CrtcChange +// CrtcChangeRead reads a byte slice into a CrtcChange value.  func CrtcChangeRead(buf []byte, v *CrtcChange) int {  	b := 0 @@ -473,7 +465,7 @@ func CrtcChangeRead(buf []byte, v *CrtcChange) int {  	return b  } -// Struct list read CrtcChange +// CrtcChangeReadList reads a byte slice into a list of CrtcChange values.  func CrtcChangeReadList(buf []byte, dest []CrtcChange) int {  	b := 0  	for i := 0; i < len(dest); i++ { @@ -483,7 +475,7 @@ func CrtcChangeReadList(buf []byte, dest []CrtcChange) int {  	return xgb.Pad(b)  } -// Struct write CrtcChange +// Bytes writes a CrtcChange value to a byte slice.  func (v CrtcChange) Bytes() []byte {  	buf := make([]byte, 28)  	b := 0 @@ -520,7 +512,7 @@ func (v CrtcChange) Bytes() []byte {  	return buf  } -// Write struct list CrtcChange +// CrtcChangeListBytes writes a list of %s(MISSING) values to a byte slice.  func CrtcChangeListBytes(buf []byte, list []CrtcChange) int {  	b := 0  	var structBytes []byte @@ -532,8 +524,6 @@ func CrtcChangeListBytes(buf []byte, list []CrtcChange) int {  	return b  } -// 'OutputChange' struct definition -// Size: 28  type OutputChange struct {  	Timestamp       xproto.Timestamp  	ConfigTimestamp xproto.Timestamp @@ -546,7 +536,7 @@ type OutputChange struct {  	SubpixelOrder   byte  } -// Struct read OutputChange +// OutputChangeRead reads a byte slice into a OutputChange value.  func OutputChangeRead(buf []byte, v *OutputChange) int {  	b := 0 @@ -580,7 +570,7 @@ func OutputChangeRead(buf []byte, v *OutputChange) int {  	return b  } -// Struct list read OutputChange +// OutputChangeReadList reads a byte slice into a list of OutputChange values.  func OutputChangeReadList(buf []byte, dest []OutputChange) int {  	b := 0  	for i := 0; i < len(dest); i++ { @@ -590,7 +580,7 @@ func OutputChangeReadList(buf []byte, dest []OutputChange) int {  	return xgb.Pad(b)  } -// Struct write OutputChange +// Bytes writes a OutputChange value to a byte slice.  func (v OutputChange) Bytes() []byte {  	buf := make([]byte, 28)  	b := 0 @@ -625,7 +615,7 @@ func (v OutputChange) Bytes() []byte {  	return buf  } -// Write struct list OutputChange +// OutputChangeListBytes writes a list of %s(MISSING) values to a byte slice.  func OutputChangeListBytes(buf []byte, list []OutputChange) int {  	b := 0  	var structBytes []byte @@ -637,8 +627,6 @@ func OutputChangeListBytes(buf []byte, list []OutputChange) int {  	return b  } -// 'OutputProperty' struct definition -// Size: 28  type OutputProperty struct {  	Window    xproto.Window  	Output    Output @@ -648,7 +636,7 @@ type OutputProperty struct {  	// padding: 11 bytes  } -// Struct read OutputProperty +// OutputPropertyRead reads a byte slice into a OutputProperty value.  func OutputPropertyRead(buf []byte, v *OutputProperty) int {  	b := 0 @@ -672,7 +660,7 @@ func OutputPropertyRead(buf []byte, v *OutputProperty) int {  	return b  } -// Struct list read OutputProperty +// OutputPropertyReadList reads a byte slice into a list of OutputProperty values.  func OutputPropertyReadList(buf []byte, dest []OutputProperty) int {  	b := 0  	for i := 0; i < len(dest); i++ { @@ -682,7 +670,7 @@ func OutputPropertyReadList(buf []byte, dest []OutputProperty) int {  	return xgb.Pad(b)  } -// Struct write OutputProperty +// Bytes writes a OutputProperty value to a byte slice.  func (v OutputProperty) Bytes() []byte {  	buf := make([]byte, 28)  	b := 0 @@ -707,7 +695,7 @@ func (v OutputProperty) Bytes() []byte {  	return buf  } -// Write struct list OutputProperty +// OutputPropertyListBytes writes a list of %s(MISSING) values to a byte slice.  func OutputPropertyListBytes(buf []byte, list []OutputProperty) int {  	b := 0  	var structBytes []byte @@ -719,7 +707,7 @@ func OutputPropertyListBytes(buf []byte, list []OutputProperty) int {  	return b  } -// Union definition NotifyDataUnion +// NotifyDataUnion is a represention of the NotifyDataUnion union type.  // Note that to *create* a Union, you should *never* create  // this struct directly (unless you know what you're doing).  // Instead use one of the following constructors for 'NotifyDataUnion': @@ -732,7 +720,7 @@ type NotifyDataUnion struct {  	Op OutputProperty  } -// Union constructor for NotifyDataUnion for field Cc. +// NotifyDataUnionCcNew constructs a new NotifyDataUnion union type with the Cc field.  func NotifyDataUnionCcNew(Cc CrtcChange) NotifyDataUnion {  	var b int  	buf := make([]byte, 28) @@ -763,7 +751,7 @@ func NotifyDataUnionCcNew(Cc CrtcChange) NotifyDataUnion {  	return v  } -// Union constructor for NotifyDataUnion for field Oc. +// NotifyDataUnionOcNew constructs a new NotifyDataUnion union type with the Oc field.  func NotifyDataUnionOcNew(Oc OutputChange) NotifyDataUnion {  	var b int  	buf := make([]byte, 28) @@ -794,7 +782,7 @@ func NotifyDataUnionOcNew(Oc OutputChange) NotifyDataUnion {  	return v  } -// Union constructor for NotifyDataUnion for field Op. +// NotifyDataUnionOpNew constructs a new NotifyDataUnion union type with the Op field.  func NotifyDataUnionOpNew(Op OutputProperty) NotifyDataUnion {  	var b int  	buf := make([]byte, 28) @@ -825,7 +813,7 @@ func NotifyDataUnionOpNew(Op OutputProperty) NotifyDataUnion {  	return v  } -// Union read NotifyDataUnion +// NotifyDataUnionRead reads a byte slice into a NotifyDataUnion value.  func NotifyDataUnionRead(buf []byte, v *NotifyDataUnion) int {  	var b int @@ -844,7 +832,7 @@ func NotifyDataUnionRead(buf []byte, v *NotifyDataUnion) int {  	return 28  } -// Union list read NotifyDataUnion +// NotifyDataUnionReadList reads a byte slice into a list of NotifyDataUnion values.  func NotifyDataUnionReadList(buf []byte, dest []NotifyDataUnion) int {  	b := 0  	for i := 0; i < len(dest); i++ { @@ -854,7 +842,7 @@ func NotifyDataUnionReadList(buf []byte, dest []NotifyDataUnion) int {  	return xgb.Pad(b)  } -// Union write NotifyDataUnion +// Bytes writes a NotifyDataUnion value to a byte slice.  // Each field in a union must contain the same data.  // So simply pick the first field and write that to the wire.  func (v NotifyDataUnion) Bytes() []byte { @@ -869,7 +857,7 @@ func (v NotifyDataUnion) Bytes() []byte {  	return buf  } -// Union list write NotifyDataUnion +// NotifyDataUnionListBytes writes a list of %s(MISSING) values to a byte slice.  func NotifyDataUnionListBytes(buf []byte, list []NotifyDataUnion) int {  	b := 0  	var unionBytes []byte @@ -881,9 +869,7 @@ func NotifyDataUnionListBytes(buf []byte, list []NotifyDataUnion) int {  	return b  } -// Event definition ScreenChangeNotify (0) -// Size: 32 - +// ScreenChangeNotify is the event number for a ScreenChangeNotifyEvent.  const ScreenChangeNotify = 0  type ScreenChangeNotifyEvent struct { @@ -901,7 +887,7 @@ type ScreenChangeNotifyEvent struct {  	Mheight         uint16  } -// Event read ScreenChangeNotify +// ScreenChangeNotifyEventNew constructs a ScreenChangeNotifyEvent value that implements xgb.Event from a byte slice.  func ScreenChangeNotifyEventNew(buf []byte) xgb.Event {  	v := ScreenChangeNotifyEvent{}  	b := 1 // don't read event number @@ -945,7 +931,7 @@ func ScreenChangeNotifyEventNew(buf []byte) xgb.Event {  	return v  } -// Event write ScreenChangeNotify +// Bytes writes a ScreenChangeNotifyEvent value to a byte slice.  func (v ScreenChangeNotifyEvent) Bytes() []byte {  	buf := make([]byte, 32)  	b := 0 @@ -992,12 +978,14 @@ func (v ScreenChangeNotifyEvent) Bytes() []byte {  	return buf  } -func (v ScreenChangeNotifyEvent) ImplementsEvent() {} - +// SequenceId returns the sequence id attached to the ScreenChangeNotify event. +// Events without a sequence number (KeymapNotify) return 0. +// This is mostly used internally.  func (v ScreenChangeNotifyEvent) SequenceId() uint16 {  	return v.Sequence  } +// String is a rudimentary string representation of ScreenChangeNotifyEvent.  func (v ScreenChangeNotifyEvent) String() string {  	fieldVals := make([]string, 0, 11)  	fieldVals = append(fieldVals, xgb.Sprintf("Sequence: %d", v.Sequence)) @@ -1019,9 +1007,7 @@ func init() {  	xgb.NewExtEventFuncs["RANDR"][0] = ScreenChangeNotifyEventNew  } -// Event definition Notify (1) -// Size: 32 - +// Notify is the event number for a NotifyEvent.  const Notify = 1  type NotifyEvent struct { @@ -1030,7 +1016,7 @@ type NotifyEvent struct {  	U        NotifyDataUnion  } -// Event read Notify +// NotifyEventNew constructs a NotifyEvent value that implements xgb.Event from a byte slice.  func NotifyEventNew(buf []byte) xgb.Event {  	v := NotifyEvent{}  	b := 1 // don't read event number @@ -1047,7 +1033,7 @@ func NotifyEventNew(buf []byte) xgb.Event {  	return v  } -// Event write Notify +// Bytes writes a NotifyEvent value to a byte slice.  func (v NotifyEvent) Bytes() []byte {  	buf := make([]byte, 32)  	b := 0 @@ -1070,12 +1056,14 @@ func (v NotifyEvent) Bytes() []byte {  	return buf  } -func (v NotifyEvent) ImplementsEvent() {} - +// 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) SequenceId() uint16 {  	return v.Sequence  } +// String is a rudimentary string representation of NotifyEvent.  func (v NotifyEvent) String() string {  	fieldVals := make([]string, 0, 2)  	fieldVals = append(fieldVals, xgb.Sprintf("Sequence: %d", v.Sequence)) @@ -1087,9 +1075,7 @@ func init() {  	xgb.NewExtEventFuncs["RANDR"][1] = NotifyEventNew  } -// Error definition BadOutput (0) -// Size: 32 - +// BadBadOutput is the error number for a BadBadOutput.  const BadBadOutput = 0  type BadOutputError struct { @@ -1097,7 +1083,7 @@ type BadOutputError struct {  	NiceName string  } -// Error read BadOutput +// BadOutputErrorNew constructs a BadOutputError value that implements xgb.Error from a byte slice.  func BadOutputErrorNew(buf []byte) xgb.Error {  	v := BadOutputError{}  	v.NiceName = "BadOutput" @@ -1111,8 +1097,8 @@ func BadOutputErrorNew(buf []byte) xgb.Error {  	return v  } -func (err BadOutputError) ImplementsError() {} - +// SequenceId returns the sequence id attached to the BadBadOutput error. +// This is mostly used internally.  func (err BadOutputError) SequenceId() uint16 {  	return err.Sequence  } @@ -1132,9 +1118,7 @@ func init() {  	xgb.NewExtErrorFuncs["RANDR"][0] = BadOutputErrorNew  } -// Error definition BadCrtc (1) -// Size: 32 - +// BadBadCrtc is the error number for a BadBadCrtc.  const BadBadCrtc = 1  type BadCrtcError struct { @@ -1142,7 +1126,7 @@ type BadCrtcError struct {  	NiceName string  } -// Error read BadCrtc +// BadCrtcErrorNew constructs a BadCrtcError value that implements xgb.Error from a byte slice.  func BadCrtcErrorNew(buf []byte) xgb.Error {  	v := BadCrtcError{}  	v.NiceName = "BadCrtc" @@ -1156,8 +1140,8 @@ func BadCrtcErrorNew(buf []byte) xgb.Error {  	return v  } -func (err BadCrtcError) ImplementsError() {} - +// SequenceId returns the sequence id attached to the BadBadCrtc error. +// This is mostly used internally.  func (err BadCrtcError) SequenceId() uint16 {  	return err.Sequence  } @@ -1177,9 +1161,7 @@ func init() {  	xgb.NewExtErrorFuncs["RANDR"][1] = BadCrtcErrorNew  } -// Error definition BadMode (2) -// Size: 32 - +// BadBadMode is the error number for a BadBadMode.  const BadBadMode = 2  type BadModeError struct { @@ -1187,7 +1169,7 @@ type BadModeError struct {  	NiceName string  } -// Error read BadMode +// BadModeErrorNew constructs a BadModeError value that implements xgb.Error from a byte slice.  func BadModeErrorNew(buf []byte) xgb.Error {  	v := BadModeError{}  	v.NiceName = "BadMode" @@ -1201,8 +1183,8 @@ func BadModeErrorNew(buf []byte) xgb.Error {  	return v  } -func (err BadModeError) ImplementsError() {} - +// SequenceId returns the sequence id attached to the BadBadMode error. +// This is mostly used internally.  func (err BadModeError) SequenceId() uint16 {  	return err.Sequence  } @@ -1222,36 +1204,38 @@ func init() {  	xgb.NewExtErrorFuncs["RANDR"][2] = BadModeErrorNew  } -// Request QueryVersion -// size: 12 +// QueryVersionCookie is a cookie used only for QueryVersion requests.  type QueryVersionCookie struct {  	*xgb.Cookie  } +// QueryVersion sends a checked request. +// If an error occurs, it will be returned with the reply by calling QueryVersionCookie.Reply()  func QueryVersion(c *xgb.Conn, MajorVersion uint32, MinorVersion uint32) QueryVersionCookie {  	cookie := c.NewCookie(true, true)  	c.NewRequest(queryVersionRequest(c, MajorVersion, MinorVersion), cookie)  	return QueryVersionCookie{cookie}  } +// QueryVersionUnchecked sends an unchecked request. +// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.  func QueryVersionUnchecked(c *xgb.Conn, MajorVersion uint32, MinorVersion uint32) QueryVersionCookie {  	cookie := c.NewCookie(false, true)  	c.NewRequest(queryVersionRequest(c, MajorVersion, MinorVersion), cookie)  	return QueryVersionCookie{cookie}  } -// Request reply for QueryVersion -// size: 32 +// QueryVersionReply represents the data returned from a QueryVersion request.  type QueryVersionReply struct { -	Sequence uint16 -	Length   uint32 +	Sequence uint16 // sequence number of the request for this reply +	Length   uint32 // number of bytes in this reply  	// padding: 1 bytes  	MajorVersion uint32  	MinorVersion uint32  	// padding: 16 bytes  } -// Waits and reads reply data from request QueryVersion +// Reply blocks and returns the reply data for a QueryVersion request.  func (cook QueryVersionCookie) Reply() (*QueryVersionReply, error) {  	buf, err := cook.Cookie.Reply()  	if err != nil { @@ -1263,7 +1247,7 @@ func (cook QueryVersionCookie) Reply() (*QueryVersionReply, error) {  	return queryVersionReply(buf), nil  } -// Read reply into structure from buffer for QueryVersion +// queryVersionReply reads a byte slice into a QueryVersionReply value.  func queryVersionReply(buf []byte) *QueryVersionReply {  	v := new(QueryVersionReply)  	b := 1 // skip reply determinant @@ -1288,6 +1272,7 @@ func queryVersionReply(buf []byte) *QueryVersionReply {  }  // Write request to wire for QueryVersion +// queryVersionRequest writes a QueryVersion request to a byte slice.  func queryVersionRequest(c *xgb.Conn, MajorVersion uint32, MinorVersion uint32) []byte {  	size := 12  	b := 0 @@ -1311,29 +1296,31 @@ func queryVersionRequest(c *xgb.Conn, MajorVersion uint32, MinorVersion uint32)  	return buf  } -// Request SetScreenConfig -// size: 24 +// SetScreenConfigCookie is a cookie used only for SetScreenConfig requests.  type SetScreenConfigCookie struct {  	*xgb.Cookie  } +// SetScreenConfig sends a checked request. +// If an error occurs, it will be returned with the reply by calling SetScreenConfigCookie.Reply()  func SetScreenConfig(c *xgb.Conn, Window xproto.Window, Timestamp xproto.Timestamp, ConfigTimestamp xproto.Timestamp, SizeID uint16, Rotation uint16, Rate uint16) SetScreenConfigCookie {  	cookie := c.NewCookie(true, true)  	c.NewRequest(setScreenConfigRequest(c, Window, Timestamp, ConfigTimestamp, SizeID, Rotation, Rate), cookie)  	return SetScreenConfigCookie{cookie}  } +// SetScreenConfigUnchecked sends an unchecked request. +// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.  func SetScreenConfigUnchecked(c *xgb.Conn, Window xproto.Window, Timestamp xproto.Timestamp, ConfigTimestamp xproto.Timestamp, SizeID uint16, Rotation uint16, Rate uint16) SetScreenConfigCookie {  	cookie := c.NewCookie(false, true)  	c.NewRequest(setScreenConfigRequest(c, Window, Timestamp, ConfigTimestamp, SizeID, Rotation, Rate), cookie)  	return SetScreenConfigCookie{cookie}  } -// Request reply for SetScreenConfig -// size: 32 +// SetScreenConfigReply represents the data returned from a SetScreenConfig request.  type SetScreenConfigReply struct { -	Sequence        uint16 -	Length          uint32 +	Sequence        uint16 // sequence number of the request for this reply +	Length          uint32 // number of bytes in this reply  	Status          byte  	NewTimestamp    xproto.Timestamp  	ConfigTimestamp xproto.Timestamp @@ -1342,7 +1329,7 @@ type SetScreenConfigReply struct {  	// padding: 10 bytes  } -// Waits and reads reply data from request SetScreenConfig +// Reply blocks and returns the reply data for a SetScreenConfig request.  func (cook SetScreenConfigCookie) Reply() (*SetScreenConfigReply, error) {  	buf, err := cook.Cookie.Reply()  	if err != nil { @@ -1354,7 +1341,7 @@ func (cook SetScreenConfigCookie) Reply() (*SetScreenConfigReply, error) {  	return setScreenConfigReply(buf), nil  } -// Read reply into structure from buffer for SetScreenConfig +// setScreenConfigReply reads a byte slice into a SetScreenConfigReply value.  func setScreenConfigReply(buf []byte) *SetScreenConfigReply {  	v := new(SetScreenConfigReply)  	b := 1 // skip reply determinant @@ -1386,6 +1373,7 @@ func setScreenConfigReply(buf []byte) *SetScreenConfigReply {  }  // Write request to wire for SetScreenConfig +// setScreenConfigRequest writes a SetScreenConfig request to a byte slice.  func setScreenConfigRequest(c *xgb.Conn, Window xproto.Window, Timestamp xproto.Timestamp, ConfigTimestamp xproto.Timestamp, SizeID uint16, Rotation uint16, Rate uint16) []byte {  	size := 24  	b := 0 @@ -1423,30 +1411,35 @@ func setScreenConfigRequest(c *xgb.Conn, Window xproto.Window, Timestamp xproto.  	return buf  } -// Request SelectInput -// size: 12 +// SelectInputCookie is a cookie used only for SelectInput requests.  type SelectInputCookie struct {  	*xgb.Cookie  } -// Write request to wire for SelectInput +// SelectInput sends an unchecked request. +// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.  func SelectInput(c *xgb.Conn, Window xproto.Window, Enable uint16) SelectInputCookie {  	cookie := c.NewCookie(false, false)  	c.NewRequest(selectInputRequest(c, Window, Enable), cookie)  	return SelectInputCookie{cookie}  } +// SelectInputChecked sends a checked request. +// If an error occurs, it can be retrieved using SelectInputCookie.Check()  func SelectInputChecked(c *xgb.Conn, Window xproto.Window, Enable uint16) SelectInputCookie {  	cookie := c.NewCookie(true, false)  	c.NewRequest(selectInputRequest(c, Window, Enable), cookie)  	return SelectInputCookie{cookie}  } +// 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.  func (cook SelectInputCookie) Check() error {  	return cook.Cookie.Check()  }  // Write request to wire for SelectInput +// selectInputRequest writes a SelectInput request to a byte slice.  func selectInputRequest(c *xgb.Conn, Window xproto.Window, Enable uint16) []byte {  	size := 12  	b := 0 @@ -1472,29 +1465,31 @@ func selectInputRequest(c *xgb.Conn, Window xproto.Window, Enable uint16) []byte  	return buf  } -// Request GetScreenInfo -// size: 8 +// GetScreenInfoCookie is a cookie used only for GetScreenInfo requests.  type GetScreenInfoCookie struct {  	*xgb.Cookie  } +// GetScreenInfo sends a checked request. +// If an error occurs, it will be returned with the reply by calling GetScreenInfoCookie.Reply()  func GetScreenInfo(c *xgb.Conn, Window xproto.Window) GetScreenInfoCookie {  	cookie := c.NewCookie(true, true)  	c.NewRequest(getScreenInfoRequest(c, Window), cookie)  	return GetScreenInfoCookie{cookie}  } +// GetScreenInfoUnchecked sends an unchecked request. +// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.  func GetScreenInfoUnchecked(c *xgb.Conn, Window xproto.Window) GetScreenInfoCookie {  	cookie := c.NewCookie(false, true)  	c.NewRequest(getScreenInfoRequest(c, Window), cookie)  	return GetScreenInfoCookie{cookie}  } -// Request reply for GetScreenInfo -// size: ((32 + xgb.Pad((int(NSizes) * 8))) + RefreshRatesListSize(Rates)) +// GetScreenInfoReply represents the data returned from a GetScreenInfo request.  type GetScreenInfoReply struct { -	Sequence        uint16 -	Length          uint32 +	Sequence        uint16 // sequence number of the request for this reply +	Length          uint32 // number of bytes in this reply  	Rotations       byte  	Root            xproto.Window  	Timestamp       xproto.Timestamp @@ -1509,7 +1504,7 @@ type GetScreenInfoReply struct {  	Rates []RefreshRates // size: RefreshRatesListSize(Rates)  } -// Waits and reads reply data from request GetScreenInfo +// Reply blocks and returns the reply data for a GetScreenInfo request.  func (cook GetScreenInfoCookie) Reply() (*GetScreenInfoReply, error) {  	buf, err := cook.Cookie.Reply()  	if err != nil { @@ -1521,7 +1516,7 @@ func (cook GetScreenInfoCookie) Reply() (*GetScreenInfoReply, error) {  	return getScreenInfoReply(buf), nil  } -// Read reply into structure from buffer for GetScreenInfo +// getScreenInfoReply reads a byte slice into a GetScreenInfoReply value.  func getScreenInfoReply(buf []byte) *GetScreenInfoReply {  	v := new(GetScreenInfoReply)  	b := 1 // skip reply determinant @@ -1571,6 +1566,7 @@ func getScreenInfoReply(buf []byte) *GetScreenInfoReply {  }  // Write request to wire for GetScreenInfo +// getScreenInfoRequest writes a GetScreenInfo request to a byte slice.  func getScreenInfoRequest(c *xgb.Conn, Window xproto.Window) []byte {  	size := 8  	b := 0 @@ -1591,29 +1587,31 @@ func getScreenInfoRequest(c *xgb.Conn, Window xproto.Window) []byte {  	return buf  } -// Request GetScreenSizeRange -// size: 8 +// GetScreenSizeRangeCookie is a cookie used only for GetScreenSizeRange requests.  type GetScreenSizeRangeCookie struct {  	*xgb.Cookie  } +// GetScreenSizeRange sends a checked request. +// If an error occurs, it will be returned with the reply by calling GetScreenSizeRangeCookie.Reply()  func GetScreenSizeRange(c *xgb.Conn, Window xproto.Window) GetScreenSizeRangeCookie {  	cookie := c.NewCookie(true, true)  	c.NewRequest(getScreenSizeRangeRequest(c, Window), cookie)  	return GetScreenSizeRangeCookie{cookie}  } +// GetScreenSizeRangeUnchecked sends an unchecked request. +// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.  func GetScreenSizeRangeUnchecked(c *xgb.Conn, Window xproto.Window) GetScreenSizeRangeCookie {  	cookie := c.NewCookie(false, true)  	c.NewRequest(getScreenSizeRangeRequest(c, Window), cookie)  	return GetScreenSizeRangeCookie{cookie}  } -// Request reply for GetScreenSizeRange -// size: 32 +// GetScreenSizeRangeReply represents the data returned from a GetScreenSizeRange request.  type GetScreenSizeRangeReply struct { -	Sequence uint16 -	Length   uint32 +	Sequence uint16 // sequence number of the request for this reply +	Length   uint32 // number of bytes in this reply  	// padding: 1 bytes  	MinWidth  uint16  	MinHeight uint16 @@ -1622,7 +1620,7 @@ type GetScreenSizeRangeReply struct {  	// padding: 16 bytes  } -// Waits and reads reply data from request GetScreenSizeRange +// Reply blocks and returns the reply data for a GetScreenSizeRange request.  func (cook GetScreenSizeRangeCookie) Reply() (*GetScreenSizeRangeReply, error) {  	buf, err := cook.Cookie.Reply()  	if err != nil { @@ -1634,7 +1632,7 @@ func (cook GetScreenSizeRangeCookie) Reply() (*GetScreenSizeRangeReply, error) {  	return getScreenSizeRangeReply(buf), nil  } -// Read reply into structure from buffer for GetScreenSizeRange +// getScreenSizeRangeReply reads a byte slice into a GetScreenSizeRangeReply value.  func getScreenSizeRangeReply(buf []byte) *GetScreenSizeRangeReply {  	v := new(GetScreenSizeRangeReply)  	b := 1 // skip reply determinant @@ -1665,6 +1663,7 @@ func getScreenSizeRangeReply(buf []byte) *GetScreenSizeRangeReply {  }  // Write request to wire for GetScreenSizeRange +// getScreenSizeRangeRequest writes a GetScreenSizeRange request to a byte slice.  func getScreenSizeRangeRequest(c *xgb.Conn, Window xproto.Window) []byte {  	size := 8  	b := 0 @@ -1685,30 +1684,35 @@ func getScreenSizeRangeRequest(c *xgb.Conn, Window xproto.Window) []byte {  	return buf  } -// Request SetScreenSize -// size: 20 +// SetScreenSizeCookie is a cookie used only for SetScreenSize requests.  type SetScreenSizeCookie struct {  	*xgb.Cookie  } -// Write request to wire for SetScreenSize +// SetScreenSize sends an unchecked request. +// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.  func SetScreenSize(c *xgb.Conn, Window xproto.Window, Width uint16, Height uint16, MmWidth uint32, MmHeight uint32) SetScreenSizeCookie {  	cookie := c.NewCookie(false, false)  	c.NewRequest(setScreenSizeRequest(c, Window, Width, Height, MmWidth, MmHeight), cookie)  	return SetScreenSizeCookie{cookie}  } +// SetScreenSizeChecked sends a checked request. +// If an error occurs, it can be retrieved using SetScreenSizeCookie.Check()  func SetScreenSizeChecked(c *xgb.Conn, Window xproto.Window, Width uint16, Height uint16, MmWidth uint32, MmHeight uint32) SetScreenSizeCookie {  	cookie := c.NewCookie(true, false)  	c.NewRequest(setScreenSizeRequest(c, Window, Width, Height, MmWidth, MmHeight), cookie)  	return SetScreenSizeCookie{cookie}  } +// 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.  func (cook SetScreenSizeCookie) Check() error {  	return cook.Cookie.Check()  }  // Write request to wire for SetScreenSize +// setScreenSizeRequest writes a SetScreenSize request to a byte slice.  func setScreenSizeRequest(c *xgb.Conn, Window xproto.Window, Width uint16, Height uint16, MmWidth uint32, MmHeight uint32) []byte {  	size := 20  	b := 0 @@ -1741,29 +1745,31 @@ func setScreenSizeRequest(c *xgb.Conn, Window xproto.Window, Width uint16, Heigh  	return buf  } -// Request GetScreenResources -// size: 8 +// GetScreenResourcesCookie is a cookie used only for GetScreenResources requests.  type GetScreenResourcesCookie struct {  	*xgb.Cookie  } +// GetScreenResources sends a checked request. +// If an error occurs, it will be returned with the reply by calling GetScreenResourcesCookie.Reply()  func GetScreenResources(c *xgb.Conn, Window xproto.Window) GetScreenResourcesCookie {  	cookie := c.NewCookie(true, true)  	c.NewRequest(getScreenResourcesRequest(c, Window), cookie)  	return GetScreenResourcesCookie{cookie}  } +// GetScreenResourcesUnchecked sends an unchecked request. +// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.  func GetScreenResourcesUnchecked(c *xgb.Conn, Window xproto.Window) GetScreenResourcesCookie {  	cookie := c.NewCookie(false, true)  	c.NewRequest(getScreenResourcesRequest(c, Window), cookie)  	return GetScreenResourcesCookie{cookie}  } -// Request reply for GetScreenResources -// size: ((((32 + xgb.Pad((int(NumCrtcs) * 4))) + xgb.Pad((int(NumOutputs) * 4))) + xgb.Pad((int(NumModes) * 32))) + xgb.Pad((int(NamesLen) * 1))) +// GetScreenResourcesReply represents the data returned from a GetScreenResources request.  type GetScreenResourcesReply struct { -	Sequence uint16 -	Length   uint32 +	Sequence uint16 // sequence number of the request for this reply +	Length   uint32 // number of bytes in this reply  	// padding: 1 bytes  	Timestamp       xproto.Timestamp  	ConfigTimestamp xproto.Timestamp @@ -1778,7 +1784,7 @@ type GetScreenResourcesReply struct {  	Names   []byte     // size: xgb.Pad((int(NamesLen) * 1))  } -// Waits and reads reply data from request GetScreenResources +// Reply blocks and returns the reply data for a GetScreenResources request.  func (cook GetScreenResourcesCookie) Reply() (*GetScreenResourcesReply, error) {  	buf, err := cook.Cookie.Reply()  	if err != nil { @@ -1790,7 +1796,7 @@ func (cook GetScreenResourcesCookie) Reply() (*GetScreenResourcesReply, error) {  	return getScreenResourcesReply(buf), nil  } -// Read reply into structure from buffer for GetScreenResources +// getScreenResourcesReply reads a byte slice into a GetScreenResourcesReply value.  func getScreenResourcesReply(buf []byte) *GetScreenResourcesReply {  	v := new(GetScreenResourcesReply)  	b := 1 // skip reply determinant @@ -1848,6 +1854,7 @@ func getScreenResourcesReply(buf []byte) *GetScreenResourcesReply {  }  // Write request to wire for GetScreenResources +// getScreenResourcesRequest writes a GetScreenResources request to a byte slice.  func getScreenResourcesRequest(c *xgb.Conn, Window xproto.Window) []byte {  	size := 8  	b := 0 @@ -1868,29 +1875,31 @@ func getScreenResourcesRequest(c *xgb.Conn, Window xproto.Window) []byte {  	return buf  } -// Request GetOutputInfo -// size: 12 +// GetOutputInfoCookie is a cookie used only for GetOutputInfo requests.  type GetOutputInfoCookie struct {  	*xgb.Cookie  } +// GetOutputInfo sends a checked request. +// If an error occurs, it will be returned with the reply by calling GetOutputInfoCookie.Reply()  func GetOutputInfo(c *xgb.Conn, Output Output, ConfigTimestamp xproto.Timestamp) GetOutputInfoCookie {  	cookie := c.NewCookie(true, true)  	c.NewRequest(getOutputInfoRequest(c, Output, ConfigTimestamp), cookie)  	return GetOutputInfoCookie{cookie}  } +// GetOutputInfoUnchecked sends an unchecked request. +// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.  func GetOutputInfoUnchecked(c *xgb.Conn, Output Output, ConfigTimestamp xproto.Timestamp) GetOutputInfoCookie {  	cookie := c.NewCookie(false, true)  	c.NewRequest(getOutputInfoRequest(c, Output, ConfigTimestamp), cookie)  	return GetOutputInfoCookie{cookie}  } -// Request reply for GetOutputInfo -// size: ((((36 + xgb.Pad((int(NumCrtcs) * 4))) + xgb.Pad((int(NumModes) * 4))) + xgb.Pad((int(NumClones) * 4))) + xgb.Pad((int(NameLen) * 1))) +// GetOutputInfoReply represents the data returned from a GetOutputInfo request.  type GetOutputInfoReply struct { -	Sequence      uint16 -	Length        uint32 +	Sequence      uint16 // sequence number of the request for this reply +	Length        uint32 // number of bytes in this reply  	Status        byte  	Timestamp     xproto.Timestamp  	Crtc          Crtc @@ -1909,7 +1918,7 @@ type GetOutputInfoReply struct {  	Name          []byte   // size: xgb.Pad((int(NameLen) * 1))  } -// Waits and reads reply data from request GetOutputInfo +// Reply blocks and returns the reply data for a GetOutputInfo request.  func (cook GetOutputInfoCookie) Reply() (*GetOutputInfoReply, error) {  	buf, err := cook.Cookie.Reply()  	if err != nil { @@ -1921,7 +1930,7 @@ func (cook GetOutputInfoCookie) Reply() (*GetOutputInfoReply, error) {  	return getOutputInfoReply(buf), nil  } -// Read reply into structure from buffer for GetOutputInfo +// getOutputInfoReply reads a byte slice into a GetOutputInfoReply value.  func getOutputInfoReply(buf []byte) *GetOutputInfoReply {  	v := new(GetOutputInfoReply)  	b := 1 // skip reply determinant @@ -1997,6 +2006,7 @@ func getOutputInfoReply(buf []byte) *GetOutputInfoReply {  }  // Write request to wire for GetOutputInfo +// getOutputInfoRequest writes a GetOutputInfo request to a byte slice.  func getOutputInfoRequest(c *xgb.Conn, Output Output, ConfigTimestamp xproto.Timestamp) []byte {  	size := 12  	b := 0 @@ -2020,36 +2030,38 @@ func getOutputInfoRequest(c *xgb.Conn, Output Output, ConfigTimestamp xproto.Tim  	return buf  } -// Request ListOutputProperties -// size: 8 +// ListOutputPropertiesCookie is a cookie used only for ListOutputProperties requests.  type ListOutputPropertiesCookie struct {  	*xgb.Cookie  } +// ListOutputProperties sends a checked request. +// If an error occurs, it will be returned with the reply by calling ListOutputPropertiesCookie.Reply()  func ListOutputProperties(c *xgb.Conn, Output Output) ListOutputPropertiesCookie {  	cookie := c.NewCookie(true, true)  	c.NewRequest(listOutputPropertiesRequest(c, Output), cookie)  	return ListOutputPropertiesCookie{cookie}  } +// ListOutputPropertiesUnchecked sends an unchecked request. +// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.  func ListOutputPropertiesUnchecked(c *xgb.Conn, Output Output) ListOutputPropertiesCookie {  	cookie := c.NewCookie(false, true)  	c.NewRequest(listOutputPropertiesRequest(c, Output), cookie)  	return ListOutputPropertiesCookie{cookie}  } -// Request reply for ListOutputProperties -// size: (32 + xgb.Pad((int(NumAtoms) * 4))) +// ListOutputPropertiesReply represents the data returned from a ListOutputProperties request.  type ListOutputPropertiesReply struct { -	Sequence uint16 -	Length   uint32 +	Sequence uint16 // sequence number of the request for this reply +	Length   uint32 // number of bytes in this reply  	// padding: 1 bytes  	NumAtoms uint16  	// padding: 22 bytes  	Atoms []xproto.Atom // size: xgb.Pad((int(NumAtoms) * 4))  } -// Waits and reads reply data from request ListOutputProperties +// Reply blocks and returns the reply data for a ListOutputProperties request.  func (cook ListOutputPropertiesCookie) Reply() (*ListOutputPropertiesReply, error) {  	buf, err := cook.Cookie.Reply()  	if err != nil { @@ -2061,7 +2073,7 @@ func (cook ListOutputPropertiesCookie) Reply() (*ListOutputPropertiesReply, erro  	return listOutputPropertiesReply(buf), nil  } -// Read reply into structure from buffer for ListOutputProperties +// listOutputPropertiesReply reads a byte slice into a ListOutputPropertiesReply value.  func listOutputPropertiesReply(buf []byte) *ListOutputPropertiesReply {  	v := new(ListOutputPropertiesReply)  	b := 1 // skip reply determinant @@ -2090,6 +2102,7 @@ func listOutputPropertiesReply(buf []byte) *ListOutputPropertiesReply {  }  // Write request to wire for ListOutputProperties +// listOutputPropertiesRequest writes a ListOutputProperties request to a byte slice.  func listOutputPropertiesRequest(c *xgb.Conn, Output Output) []byte {  	size := 8  	b := 0 @@ -2110,29 +2123,31 @@ func listOutputPropertiesRequest(c *xgb.Conn, Output Output) []byte {  	return buf  } -// Request QueryOutputProperty -// size: 12 +// QueryOutputPropertyCookie is a cookie used only for QueryOutputProperty requests.  type QueryOutputPropertyCookie struct {  	*xgb.Cookie  } +// QueryOutputProperty sends a checked request. +// If an error occurs, it will be returned with the reply by calling QueryOutputPropertyCookie.Reply()  func QueryOutputProperty(c *xgb.Conn, Output Output, Property xproto.Atom) QueryOutputPropertyCookie {  	cookie := c.NewCookie(true, true)  	c.NewRequest(queryOutputPropertyRequest(c, Output, Property), cookie)  	return QueryOutputPropertyCookie{cookie}  } +// QueryOutputPropertyUnchecked sends an unchecked request. +// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.  func QueryOutputPropertyUnchecked(c *xgb.Conn, Output Output, Property xproto.Atom) QueryOutputPropertyCookie {  	cookie := c.NewCookie(false, true)  	c.NewRequest(queryOutputPropertyRequest(c, Output, Property), cookie)  	return QueryOutputPropertyCookie{cookie}  } -// Request reply for QueryOutputProperty -// size: (32 + xgb.Pad((int(Length) * 4))) +// QueryOutputPropertyReply represents the data returned from a QueryOutputProperty request.  type QueryOutputPropertyReply struct { -	Sequence uint16 -	Length   uint32 +	Sequence uint16 // sequence number of the request for this reply +	Length   uint32 // number of bytes in this reply  	// padding: 1 bytes  	Pending   bool  	Range     bool @@ -2141,7 +2156,7 @@ type QueryOutputPropertyReply struct {  	ValidValues []int32 // size: xgb.Pad((int(Length) * 4))  } -// Waits and reads reply data from request QueryOutputProperty +// Reply blocks and returns the reply data for a QueryOutputProperty request.  func (cook QueryOutputPropertyCookie) Reply() (*QueryOutputPropertyReply, error) {  	buf, err := cook.Cookie.Reply()  	if err != nil { @@ -2153,7 +2168,7 @@ func (cook QueryOutputPropertyCookie) Reply() (*QueryOutputPropertyReply, error)  	return queryOutputPropertyReply(buf), nil  } -// Read reply into structure from buffer for QueryOutputProperty +// queryOutputPropertyReply reads a byte slice into a QueryOutputPropertyReply value.  func queryOutputPropertyReply(buf []byte) *QueryOutputPropertyReply {  	v := new(QueryOutputPropertyReply)  	b := 1 // skip reply determinant @@ -2200,6 +2215,7 @@ func queryOutputPropertyReply(buf []byte) *QueryOutputPropertyReply {  }  // Write request to wire for QueryOutputProperty +// queryOutputPropertyRequest writes a QueryOutputProperty request to a byte slice.  func queryOutputPropertyRequest(c *xgb.Conn, Output Output, Property xproto.Atom) []byte {  	size := 12  	b := 0 @@ -2223,30 +2239,35 @@ func queryOutputPropertyRequest(c *xgb.Conn, Output Output, Property xproto.Atom  	return buf  } -// Request ConfigureOutputProperty -// size: xgb.Pad((16 + xgb.Pad((len(Values) * 4)))) +// ConfigureOutputPropertyCookie is a cookie used only for ConfigureOutputProperty requests.  type ConfigureOutputPropertyCookie struct {  	*xgb.Cookie  } -// Write request to wire for ConfigureOutputProperty +// ConfigureOutputProperty sends an unchecked request. +// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.  func ConfigureOutputProperty(c *xgb.Conn, Output Output, Property xproto.Atom, Pending bool, Range bool, Values []int32) ConfigureOutputPropertyCookie {  	cookie := c.NewCookie(false, false)  	c.NewRequest(configureOutputPropertyRequest(c, Output, Property, Pending, Range, Values), cookie)  	return ConfigureOutputPropertyCookie{cookie}  } +// ConfigureOutputPropertyChecked sends a checked request. +// If an error occurs, it can be retrieved using ConfigureOutputPropertyCookie.Check()  func ConfigureOutputPropertyChecked(c *xgb.Conn, Output Output, Property xproto.Atom, Pending bool, Range bool, Values []int32) ConfigureOutputPropertyCookie {  	cookie := c.NewCookie(true, false)  	c.NewRequest(configureOutputPropertyRequest(c, Output, Property, Pending, Range, Values), cookie)  	return ConfigureOutputPropertyCookie{cookie}  } +// 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.  func (cook ConfigureOutputPropertyCookie) Check() error {  	return cook.Cookie.Check()  }  // Write request to wire for ConfigureOutputProperty +// configureOutputPropertyRequest writes a ConfigureOutputProperty request to a byte slice.  func configureOutputPropertyRequest(c *xgb.Conn, Output Output, Property xproto.Atom, Pending bool, Range bool, Values []int32) []byte {  	size := xgb.Pad((16 + xgb.Pad((len(Values) * 4))))  	b := 0 @@ -2292,30 +2313,35 @@ func configureOutputPropertyRequest(c *xgb.Conn, Output Output, Property xproto.  	return buf  } -// Request ChangeOutputProperty -// size: xgb.Pad((24 + xgb.Pad((((int(NumUnits) * int(Format)) / 8) * 1)))) +// ChangeOutputPropertyCookie is a cookie used only for ChangeOutputProperty requests.  type ChangeOutputPropertyCookie struct {  	*xgb.Cookie  } -// Write request to wire for ChangeOutputProperty +// ChangeOutputProperty sends an unchecked request. +// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.  func ChangeOutputProperty(c *xgb.Conn, Output Output, Property xproto.Atom, Type xproto.Atom, Format byte, Mode byte, NumUnits uint32, Data []byte) ChangeOutputPropertyCookie {  	cookie := c.NewCookie(false, false)  	c.NewRequest(changeOutputPropertyRequest(c, Output, Property, Type, Format, Mode, NumUnits, Data), cookie)  	return ChangeOutputPropertyCookie{cookie}  } +// ChangeOutputPropertyChecked sends a checked request. +// If an error occurs, it can be retrieved using ChangeOutputPropertyCookie.Check()  func ChangeOutputPropertyChecked(c *xgb.Conn, Output Output, Property xproto.Atom, Type xproto.Atom, Format byte, Mode byte, NumUnits uint32, Data []byte) ChangeOutputPropertyCookie {  	cookie := c.NewCookie(true, false)  	c.NewRequest(changeOutputPropertyRequest(c, Output, Property, Type, Format, Mode, NumUnits, Data), cookie)  	return ChangeOutputPropertyCookie{cookie}  } +// 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.  func (cook ChangeOutputPropertyCookie) Check() error {  	return cook.Cookie.Check()  }  // Write request to wire for ChangeOutputProperty +// changeOutputPropertyRequest writes a ChangeOutputProperty request to a byte slice.  func changeOutputPropertyRequest(c *xgb.Conn, Output Output, Property xproto.Atom, Type xproto.Atom, Format byte, Mode byte, NumUnits uint32, Data []byte) []byte {  	size := xgb.Pad((24 + xgb.Pad((((int(NumUnits) * int(Format)) / 8) * 1))))  	b := 0 @@ -2356,30 +2382,35 @@ func changeOutputPropertyRequest(c *xgb.Conn, Output Output, Property xproto.Ato  	return buf  } -// Request DeleteOutputProperty -// size: 12 +// DeleteOutputPropertyCookie is a cookie used only for DeleteOutputProperty requests.  type DeleteOutputPropertyCookie struct {  	*xgb.Cookie  } -// Write request to wire for DeleteOutputProperty +// DeleteOutputProperty sends an unchecked request. +// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.  func DeleteOutputProperty(c *xgb.Conn, Output Output, Property xproto.Atom) DeleteOutputPropertyCookie {  	cookie := c.NewCookie(false, false)  	c.NewRequest(deleteOutputPropertyRequest(c, Output, Property), cookie)  	return DeleteOutputPropertyCookie{cookie}  } +// DeleteOutputPropertyChecked sends a checked request. +// If an error occurs, it can be retrieved using DeleteOutputPropertyCookie.Check()  func DeleteOutputPropertyChecked(c *xgb.Conn, Output Output, Property xproto.Atom) DeleteOutputPropertyCookie {  	cookie := c.NewCookie(true, false)  	c.NewRequest(deleteOutputPropertyRequest(c, Output, Property), cookie)  	return DeleteOutputPropertyCookie{cookie}  } +// 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.  func (cook DeleteOutputPropertyCookie) Check() error {  	return cook.Cookie.Check()  }  // Write request to wire for DeleteOutputProperty +// deleteOutputPropertyRequest writes a DeleteOutputProperty request to a byte slice.  func deleteOutputPropertyRequest(c *xgb.Conn, Output Output, Property xproto.Atom) []byte {  	size := 12  	b := 0 @@ -2403,29 +2434,31 @@ func deleteOutputPropertyRequest(c *xgb.Conn, Output Output, Property xproto.Ato  	return buf  } -// Request GetOutputProperty -// size: 28 +// GetOutputPropertyCookie is a cookie used only for GetOutputProperty requests.  type GetOutputPropertyCookie struct {  	*xgb.Cookie  } +// GetOutputProperty sends a checked request. +// If an error occurs, it will be returned with the reply by calling GetOutputPropertyCookie.Reply()  func GetOutputProperty(c *xgb.Conn, Output Output, Property xproto.Atom, Type xproto.Atom, LongOffset uint32, LongLength uint32, Delete bool, Pending bool) GetOutputPropertyCookie {  	cookie := c.NewCookie(true, true)  	c.NewRequest(getOutputPropertyRequest(c, Output, Property, Type, LongOffset, LongLength, Delete, Pending), cookie)  	return GetOutputPropertyCookie{cookie}  } +// GetOutputPropertyUnchecked sends an unchecked request. +// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.  func GetOutputPropertyUnchecked(c *xgb.Conn, Output Output, Property xproto.Atom, Type xproto.Atom, LongOffset uint32, LongLength uint32, Delete bool, Pending bool) GetOutputPropertyCookie {  	cookie := c.NewCookie(false, true)  	c.NewRequest(getOutputPropertyRequest(c, Output, Property, Type, LongOffset, LongLength, Delete, Pending), cookie)  	return GetOutputPropertyCookie{cookie}  } -// Request reply for GetOutputProperty -// size: (32 + xgb.Pad(((int(NumItems) * (int(Format) / 8)) * 1))) +// GetOutputPropertyReply represents the data returned from a GetOutputProperty request.  type GetOutputPropertyReply struct { -	Sequence   uint16 -	Length     uint32 +	Sequence   uint16 // sequence number of the request for this reply +	Length     uint32 // number of bytes in this reply  	Format     byte  	Type       xproto.Atom  	BytesAfter uint32 @@ -2434,7 +2467,7 @@ type GetOutputPropertyReply struct {  	Data []byte // size: xgb.Pad(((int(NumItems) * (int(Format) / 8)) * 1))  } -// Waits and reads reply data from request GetOutputProperty +// Reply blocks and returns the reply data for a GetOutputProperty request.  func (cook GetOutputPropertyCookie) Reply() (*GetOutputPropertyReply, error) {  	buf, err := cook.Cookie.Reply()  	if err != nil { @@ -2446,7 +2479,7 @@ func (cook GetOutputPropertyCookie) Reply() (*GetOutputPropertyReply, error) {  	return getOutputPropertyReply(buf), nil  } -// Read reply into structure from buffer for GetOutputProperty +// getOutputPropertyReply reads a byte slice into a GetOutputPropertyReply value.  func getOutputPropertyReply(buf []byte) *GetOutputPropertyReply {  	v := new(GetOutputPropertyReply)  	b := 1 // skip reply determinant @@ -2479,6 +2512,7 @@ func getOutputPropertyReply(buf []byte) *GetOutputPropertyReply {  }  // Write request to wire for GetOutputProperty +// getOutputPropertyRequest writes a GetOutputProperty request to a byte slice.  func getOutputPropertyRequest(c *xgb.Conn, Output Output, Property xproto.Atom, Type xproto.Atom, LongOffset uint32, LongLength uint32, Delete bool, Pending bool) []byte {  	size := 28  	b := 0 @@ -2527,35 +2561,37 @@ func getOutputPropertyRequest(c *xgb.Conn, Output Output, Property xproto.Atom,  	return buf  } -// Request CreateMode -// size: xgb.Pad((40 + xgb.Pad((len(Name) * 1)))) +// CreateModeCookie is a cookie used only for CreateMode requests.  type CreateModeCookie struct {  	*xgb.Cookie  } +// CreateMode sends a checked request. +// If an error occurs, it will be returned with the reply by calling CreateModeCookie.Reply()  func CreateMode(c *xgb.Conn, Window xproto.Window, ModeInfo ModeInfo, Name string) CreateModeCookie {  	cookie := c.NewCookie(true, true)  	c.NewRequest(createModeRequest(c, Window, ModeInfo, Name), cookie)  	return CreateModeCookie{cookie}  } +// CreateModeUnchecked sends an unchecked request. +// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.  func CreateModeUnchecked(c *xgb.Conn, Window xproto.Window, ModeInfo ModeInfo, Name string) CreateModeCookie {  	cookie := c.NewCookie(false, true)  	c.NewRequest(createModeRequest(c, Window, ModeInfo, Name), cookie)  	return CreateModeCookie{cookie}  } -// Request reply for CreateMode -// size: 32 +// CreateModeReply represents the data returned from a CreateMode request.  type CreateModeReply struct { -	Sequence uint16 -	Length   uint32 +	Sequence uint16 // sequence number of the request for this reply +	Length   uint32 // number of bytes in this reply  	// padding: 1 bytes  	Mode Mode  	// padding: 20 bytes  } -// Waits and reads reply data from request CreateMode +// Reply blocks and returns the reply data for a CreateMode request.  func (cook CreateModeCookie) Reply() (*CreateModeReply, error) {  	buf, err := cook.Cookie.Reply()  	if err != nil { @@ -2567,7 +2603,7 @@ func (cook CreateModeCookie) Reply() (*CreateModeReply, error) {  	return createModeReply(buf), nil  } -// Read reply into structure from buffer for CreateMode +// createModeReply reads a byte slice into a CreateModeReply value.  func createModeReply(buf []byte) *CreateModeReply {  	v := new(CreateModeReply)  	b := 1 // skip reply determinant @@ -2589,6 +2625,7 @@ func createModeReply(buf []byte) *CreateModeReply {  }  // Write request to wire for CreateMode +// createModeRequest writes a CreateMode request to a byte slice.  func createModeRequest(c *xgb.Conn, Window xproto.Window, ModeInfo ModeInfo, Name string) []byte {  	size := xgb.Pad((40 + xgb.Pad((len(Name) * 1))))  	b := 0 @@ -2618,30 +2655,35 @@ func createModeRequest(c *xgb.Conn, Window xproto.Window, ModeInfo ModeInfo, Nam  	return buf  } -// Request DestroyMode -// size: 8 +// DestroyModeCookie is a cookie used only for DestroyMode requests.  type DestroyModeCookie struct {  	*xgb.Cookie  } -// Write request to wire for DestroyMode +// DestroyMode sends an unchecked request. +// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.  func DestroyMode(c *xgb.Conn, Mode Mode) DestroyModeCookie {  	cookie := c.NewCookie(false, false)  	c.NewRequest(destroyModeRequest(c, Mode), cookie)  	return DestroyModeCookie{cookie}  } +// DestroyModeChecked sends a checked request. +// If an error occurs, it can be retrieved using DestroyModeCookie.Check()  func DestroyModeChecked(c *xgb.Conn, Mode Mode) DestroyModeCookie {  	cookie := c.NewCookie(true, false)  	c.NewRequest(destroyModeRequest(c, Mode), cookie)  	return DestroyModeCookie{cookie}  } +// 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.  func (cook DestroyModeCookie) Check() error {  	return cook.Cookie.Check()  }  // Write request to wire for DestroyMode +// destroyModeRequest writes a DestroyMode request to a byte slice.  func destroyModeRequest(c *xgb.Conn, Mode Mode) []byte {  	size := 8  	b := 0 @@ -2662,30 +2704,35 @@ func destroyModeRequest(c *xgb.Conn, Mode Mode) []byte {  	return buf  } -// Request AddOutputMode -// size: 12 +// AddOutputModeCookie is a cookie used only for AddOutputMode requests.  type AddOutputModeCookie struct {  	*xgb.Cookie  } -// Write request to wire for AddOutputMode +// AddOutputMode sends an unchecked request. +// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.  func AddOutputMode(c *xgb.Conn, Output Output, Mode Mode) AddOutputModeCookie {  	cookie := c.NewCookie(false, false)  	c.NewRequest(addOutputModeRequest(c, Output, Mode), cookie)  	return AddOutputModeCookie{cookie}  } +// AddOutputModeChecked sends a checked request. +// If an error occurs, it can be retrieved using AddOutputModeCookie.Check()  func AddOutputModeChecked(c *xgb.Conn, Output Output, Mode Mode) AddOutputModeCookie {  	cookie := c.NewCookie(true, false)  	c.NewRequest(addOutputModeRequest(c, Output, Mode), cookie)  	return AddOutputModeCookie{cookie}  } +// 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.  func (cook AddOutputModeCookie) Check() error {  	return cook.Cookie.Check()  }  // Write request to wire for AddOutputMode +// addOutputModeRequest writes a AddOutputMode request to a byte slice.  func addOutputModeRequest(c *xgb.Conn, Output Output, Mode Mode) []byte {  	size := 12  	b := 0 @@ -2709,30 +2756,35 @@ func addOutputModeRequest(c *xgb.Conn, Output Output, Mode Mode) []byte {  	return buf  } -// Request DeleteOutputMode -// size: 12 +// DeleteOutputModeCookie is a cookie used only for DeleteOutputMode requests.  type DeleteOutputModeCookie struct {  	*xgb.Cookie  } -// Write request to wire for DeleteOutputMode +// DeleteOutputMode sends an unchecked request. +// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.  func DeleteOutputMode(c *xgb.Conn, Output Output, Mode Mode) DeleteOutputModeCookie {  	cookie := c.NewCookie(false, false)  	c.NewRequest(deleteOutputModeRequest(c, Output, Mode), cookie)  	return DeleteOutputModeCookie{cookie}  } +// DeleteOutputModeChecked sends a checked request. +// If an error occurs, it can be retrieved using DeleteOutputModeCookie.Check()  func DeleteOutputModeChecked(c *xgb.Conn, Output Output, Mode Mode) DeleteOutputModeCookie {  	cookie := c.NewCookie(true, false)  	c.NewRequest(deleteOutputModeRequest(c, Output, Mode), cookie)  	return DeleteOutputModeCookie{cookie}  } +// 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.  func (cook DeleteOutputModeCookie) Check() error {  	return cook.Cookie.Check()  }  // Write request to wire for DeleteOutputMode +// deleteOutputModeRequest writes a DeleteOutputMode request to a byte slice.  func deleteOutputModeRequest(c *xgb.Conn, Output Output, Mode Mode) []byte {  	size := 12  	b := 0 @@ -2756,29 +2808,31 @@ func deleteOutputModeRequest(c *xgb.Conn, Output Output, Mode Mode) []byte {  	return buf  } -// Request GetCrtcInfo -// size: 12 +// GetCrtcInfoCookie is a cookie used only for GetCrtcInfo requests.  type GetCrtcInfoCookie struct {  	*xgb.Cookie  } +// GetCrtcInfo sends a checked request. +// If an error occurs, it will be returned with the reply by calling GetCrtcInfoCookie.Reply()  func GetCrtcInfo(c *xgb.Conn, Crtc Crtc, ConfigTimestamp xproto.Timestamp) GetCrtcInfoCookie {  	cookie := c.NewCookie(true, true)  	c.NewRequest(getCrtcInfoRequest(c, Crtc, ConfigTimestamp), cookie)  	return GetCrtcInfoCookie{cookie}  } +// GetCrtcInfoUnchecked sends an unchecked request. +// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.  func GetCrtcInfoUnchecked(c *xgb.Conn, Crtc Crtc, ConfigTimestamp xproto.Timestamp) GetCrtcInfoCookie {  	cookie := c.NewCookie(false, true)  	c.NewRequest(getCrtcInfoRequest(c, Crtc, ConfigTimestamp), cookie)  	return GetCrtcInfoCookie{cookie}  } -// Request reply for GetCrtcInfo -// size: ((32 + xgb.Pad((int(NumOutputs) * 4))) + xgb.Pad((int(NumPossibleOutputs) * 4))) +// GetCrtcInfoReply represents the data returned from a GetCrtcInfo request.  type GetCrtcInfoReply struct { -	Sequence           uint16 -	Length             uint32 +	Sequence           uint16 // sequence number of the request for this reply +	Length             uint32 // number of bytes in this reply  	Status             byte  	Timestamp          xproto.Timestamp  	X                  int16 @@ -2794,7 +2848,7 @@ type GetCrtcInfoReply struct {  	Possible           []Output // size: xgb.Pad((int(NumPossibleOutputs) * 4))  } -// Waits and reads reply data from request GetCrtcInfo +// Reply blocks and returns the reply data for a GetCrtcInfo request.  func (cook GetCrtcInfoCookie) Reply() (*GetCrtcInfoReply, error) {  	buf, err := cook.Cookie.Reply()  	if err != nil { @@ -2806,7 +2860,7 @@ func (cook GetCrtcInfoCookie) Reply() (*GetCrtcInfoReply, error) {  	return getCrtcInfoReply(buf), nil  } -// Read reply into structure from buffer for GetCrtcInfo +// getCrtcInfoReply reads a byte slice into a GetCrtcInfoReply value.  func getCrtcInfoReply(buf []byte) *GetCrtcInfoReply {  	v := new(GetCrtcInfoReply)  	b := 1 // skip reply determinant @@ -2868,6 +2922,7 @@ func getCrtcInfoReply(buf []byte) *GetCrtcInfoReply {  }  // Write request to wire for GetCrtcInfo +// getCrtcInfoRequest writes a GetCrtcInfo request to a byte slice.  func getCrtcInfoRequest(c *xgb.Conn, Crtc Crtc, ConfigTimestamp xproto.Timestamp) []byte {  	size := 12  	b := 0 @@ -2891,35 +2946,37 @@ func getCrtcInfoRequest(c *xgb.Conn, Crtc Crtc, ConfigTimestamp xproto.Timestamp  	return buf  } -// Request SetCrtcConfig -// size: xgb.Pad((28 + xgb.Pad((len(Outputs) * 4)))) +// SetCrtcConfigCookie is a cookie used only for SetCrtcConfig requests.  type SetCrtcConfigCookie struct {  	*xgb.Cookie  } +// SetCrtcConfig sends a checked request. +// If an error occurs, it will be returned with the reply by calling SetCrtcConfigCookie.Reply()  func SetCrtcConfig(c *xgb.Conn, Crtc Crtc, Timestamp xproto.Timestamp, ConfigTimestamp xproto.Timestamp, X int16, Y int16, Mode Mode, Rotation uint16, Outputs []Output) SetCrtcConfigCookie {  	cookie := c.NewCookie(true, true)  	c.NewRequest(setCrtcConfigRequest(c, Crtc, Timestamp, ConfigTimestamp, X, Y, Mode, Rotation, Outputs), cookie)  	return SetCrtcConfigCookie{cookie}  } +// SetCrtcConfigUnchecked sends an unchecked request. +// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.  func SetCrtcConfigUnchecked(c *xgb.Conn, Crtc Crtc, Timestamp xproto.Timestamp, ConfigTimestamp xproto.Timestamp, X int16, Y int16, Mode Mode, Rotation uint16, Outputs []Output) SetCrtcConfigCookie {  	cookie := c.NewCookie(false, true)  	c.NewRequest(setCrtcConfigRequest(c, Crtc, Timestamp, ConfigTimestamp, X, Y, Mode, Rotation, Outputs), cookie)  	return SetCrtcConfigCookie{cookie}  } -// Request reply for SetCrtcConfig -// size: 32 +// SetCrtcConfigReply represents the data returned from a SetCrtcConfig request.  type SetCrtcConfigReply struct { -	Sequence  uint16 -	Length    uint32 +	Sequence  uint16 // sequence number of the request for this reply +	Length    uint32 // number of bytes in this reply  	Status    byte  	Timestamp xproto.Timestamp  	// padding: 20 bytes  } -// Waits and reads reply data from request SetCrtcConfig +// Reply blocks and returns the reply data for a SetCrtcConfig request.  func (cook SetCrtcConfigCookie) Reply() (*SetCrtcConfigReply, error) {  	buf, err := cook.Cookie.Reply()  	if err != nil { @@ -2931,7 +2988,7 @@ func (cook SetCrtcConfigCookie) Reply() (*SetCrtcConfigReply, error) {  	return setCrtcConfigReply(buf), nil  } -// Read reply into structure from buffer for SetCrtcConfig +// setCrtcConfigReply reads a byte slice into a SetCrtcConfigReply value.  func setCrtcConfigReply(buf []byte) *SetCrtcConfigReply {  	v := new(SetCrtcConfigReply)  	b := 1 // skip reply determinant @@ -2954,6 +3011,7 @@ func setCrtcConfigReply(buf []byte) *SetCrtcConfigReply {  }  // Write request to wire for SetCrtcConfig +// setCrtcConfigRequest writes a SetCrtcConfig request to a byte slice.  func setCrtcConfigRequest(c *xgb.Conn, Crtc Crtc, Timestamp xproto.Timestamp, ConfigTimestamp xproto.Timestamp, X int16, Y int16, Mode Mode, Rotation uint16, Outputs []Output) []byte {  	size := xgb.Pad((28 + xgb.Pad((len(Outputs) * 4))))  	b := 0 @@ -3000,35 +3058,37 @@ func setCrtcConfigRequest(c *xgb.Conn, Crtc Crtc, Timestamp xproto.Timestamp, Co  	return buf  } -// Request GetCrtcGammaSize -// size: 8 +// GetCrtcGammaSizeCookie is a cookie used only for GetCrtcGammaSize requests.  type GetCrtcGammaSizeCookie struct {  	*xgb.Cookie  } +// GetCrtcGammaSize sends a checked request. +// If an error occurs, it will be returned with the reply by calling GetCrtcGammaSizeCookie.Reply()  func GetCrtcGammaSize(c *xgb.Conn, Crtc Crtc) GetCrtcGammaSizeCookie {  	cookie := c.NewCookie(true, true)  	c.NewRequest(getCrtcGammaSizeRequest(c, Crtc), cookie)  	return GetCrtcGammaSizeCookie{cookie}  } +// GetCrtcGammaSizeUnchecked sends an unchecked request. +// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.  func GetCrtcGammaSizeUnchecked(c *xgb.Conn, Crtc Crtc) GetCrtcGammaSizeCookie {  	cookie := c.NewCookie(false, true)  	c.NewRequest(getCrtcGammaSizeRequest(c, Crtc), cookie)  	return GetCrtcGammaSizeCookie{cookie}  } -// Request reply for GetCrtcGammaSize -// size: 32 +// GetCrtcGammaSizeReply represents the data returned from a GetCrtcGammaSize request.  type GetCrtcGammaSizeReply struct { -	Sequence uint16 -	Length   uint32 +	Sequence uint16 // sequence number of the request for this reply +	Length   uint32 // number of bytes in this reply  	// padding: 1 bytes  	Size uint16  	// padding: 22 bytes  } -// Waits and reads reply data from request GetCrtcGammaSize +// Reply blocks and returns the reply data for a GetCrtcGammaSize request.  func (cook GetCrtcGammaSizeCookie) Reply() (*GetCrtcGammaSizeReply, error) {  	buf, err := cook.Cookie.Reply()  	if err != nil { @@ -3040,7 +3100,7 @@ func (cook GetCrtcGammaSizeCookie) Reply() (*GetCrtcGammaSizeReply, error) {  	return getCrtcGammaSizeReply(buf), nil  } -// Read reply into structure from buffer for GetCrtcGammaSize +// getCrtcGammaSizeReply reads a byte slice into a GetCrtcGammaSizeReply value.  func getCrtcGammaSizeReply(buf []byte) *GetCrtcGammaSizeReply {  	v := new(GetCrtcGammaSizeReply)  	b := 1 // skip reply determinant @@ -3062,6 +3122,7 @@ func getCrtcGammaSizeReply(buf []byte) *GetCrtcGammaSizeReply {  }  // Write request to wire for GetCrtcGammaSize +// getCrtcGammaSizeRequest writes a GetCrtcGammaSize request to a byte slice.  func getCrtcGammaSizeRequest(c *xgb.Conn, Crtc Crtc) []byte {  	size := 8  	b := 0 @@ -3082,29 +3143,31 @@ func getCrtcGammaSizeRequest(c *xgb.Conn, Crtc Crtc) []byte {  	return buf  } -// Request GetCrtcGamma -// size: 8 +// GetCrtcGammaCookie is a cookie used only for GetCrtcGamma requests.  type GetCrtcGammaCookie struct {  	*xgb.Cookie  } +// GetCrtcGamma sends a checked request. +// If an error occurs, it will be returned with the reply by calling GetCrtcGammaCookie.Reply()  func GetCrtcGamma(c *xgb.Conn, Crtc Crtc) GetCrtcGammaCookie {  	cookie := c.NewCookie(true, true)  	c.NewRequest(getCrtcGammaRequest(c, Crtc), cookie)  	return GetCrtcGammaCookie{cookie}  } +// GetCrtcGammaUnchecked sends an unchecked request. +// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.  func GetCrtcGammaUnchecked(c *xgb.Conn, Crtc Crtc) GetCrtcGammaCookie {  	cookie := c.NewCookie(false, true)  	c.NewRequest(getCrtcGammaRequest(c, Crtc), cookie)  	return GetCrtcGammaCookie{cookie}  } -// Request reply for GetCrtcGamma -// size: (((32 + xgb.Pad((int(Size) * 2))) + xgb.Pad((int(Size) * 2))) + xgb.Pad((int(Size) * 2))) +// GetCrtcGammaReply represents the data returned from a GetCrtcGamma request.  type GetCrtcGammaReply struct { -	Sequence uint16 -	Length   uint32 +	Sequence uint16 // sequence number of the request for this reply +	Length   uint32 // number of bytes in this reply  	// padding: 1 bytes  	Size uint16  	// padding: 22 bytes @@ -3113,7 +3176,7 @@ type GetCrtcGammaReply struct {  	Blue  []uint16 // size: xgb.Pad((int(Size) * 2))  } -// Waits and reads reply data from request GetCrtcGamma +// Reply blocks and returns the reply data for a GetCrtcGamma request.  func (cook GetCrtcGammaCookie) Reply() (*GetCrtcGammaReply, error) {  	buf, err := cook.Cookie.Reply()  	if err != nil { @@ -3125,7 +3188,7 @@ func (cook GetCrtcGammaCookie) Reply() (*GetCrtcGammaReply, error) {  	return getCrtcGammaReply(buf), nil  } -// Read reply into structure from buffer for GetCrtcGamma +// getCrtcGammaReply reads a byte slice into a GetCrtcGammaReply value.  func getCrtcGammaReply(buf []byte) *GetCrtcGammaReply {  	v := new(GetCrtcGammaReply)  	b := 1 // skip reply determinant @@ -3168,6 +3231,7 @@ func getCrtcGammaReply(buf []byte) *GetCrtcGammaReply {  }  // Write request to wire for GetCrtcGamma +// getCrtcGammaRequest writes a GetCrtcGamma request to a byte slice.  func getCrtcGammaRequest(c *xgb.Conn, Crtc Crtc) []byte {  	size := 8  	b := 0 @@ -3188,30 +3252,35 @@ func getCrtcGammaRequest(c *xgb.Conn, Crtc Crtc) []byte {  	return buf  } -// Request SetCrtcGamma -// size: xgb.Pad((((12 + xgb.Pad((int(Size) * 2))) + xgb.Pad((int(Size) * 2))) + xgb.Pad((int(Size) * 2)))) +// SetCrtcGammaCookie is a cookie used only for SetCrtcGamma requests.  type SetCrtcGammaCookie struct {  	*xgb.Cookie  } -// Write request to wire for SetCrtcGamma +// SetCrtcGamma sends an unchecked request. +// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.  func SetCrtcGamma(c *xgb.Conn, Crtc Crtc, Size uint16, Red []uint16, Green []uint16, Blue []uint16) SetCrtcGammaCookie {  	cookie := c.NewCookie(false, false)  	c.NewRequest(setCrtcGammaRequest(c, Crtc, Size, Red, Green, Blue), cookie)  	return SetCrtcGammaCookie{cookie}  } +// SetCrtcGammaChecked sends a checked request. +// If an error occurs, it can be retrieved using SetCrtcGammaCookie.Check()  func SetCrtcGammaChecked(c *xgb.Conn, Crtc Crtc, Size uint16, Red []uint16, Green []uint16, Blue []uint16) SetCrtcGammaCookie {  	cookie := c.NewCookie(true, false)  	c.NewRequest(setCrtcGammaRequest(c, Crtc, Size, Red, Green, Blue), cookie)  	return SetCrtcGammaCookie{cookie}  } +// 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.  func (cook SetCrtcGammaCookie) Check() error {  	return cook.Cookie.Check()  }  // Write request to wire for SetCrtcGamma +// setCrtcGammaRequest writes a SetCrtcGamma request to a byte slice.  func setCrtcGammaRequest(c *xgb.Conn, Crtc Crtc, Size uint16, Red []uint16, Green []uint16, Blue []uint16) []byte {  	size := xgb.Pad((((12 + xgb.Pad((int(Size) * 2))) + xgb.Pad((int(Size) * 2))) + xgb.Pad((int(Size) * 2))))  	b := 0 @@ -3255,29 +3324,31 @@ func setCrtcGammaRequest(c *xgb.Conn, Crtc Crtc, Size uint16, Red []uint16, Gree  	return buf  } -// Request GetScreenResourcesCurrent -// size: 8 +// GetScreenResourcesCurrentCookie is a cookie used only for GetScreenResourcesCurrent requests.  type GetScreenResourcesCurrentCookie struct {  	*xgb.Cookie  } +// GetScreenResourcesCurrent sends a checked request. +// If an error occurs, it will be returned with the reply by calling GetScreenResourcesCurrentCookie.Reply()  func GetScreenResourcesCurrent(c *xgb.Conn, Window xproto.Window) GetScreenResourcesCurrentCookie {  	cookie := c.NewCookie(true, true)  	c.NewRequest(getScreenResourcesCurrentRequest(c, Window), cookie)  	return GetScreenResourcesCurrentCookie{cookie}  } +// GetScreenResourcesCurrentUnchecked sends an unchecked request. +// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.  func GetScreenResourcesCurrentUnchecked(c *xgb.Conn, Window xproto.Window) GetScreenResourcesCurrentCookie {  	cookie := c.NewCookie(false, true)  	c.NewRequest(getScreenResourcesCurrentRequest(c, Window), cookie)  	return GetScreenResourcesCurrentCookie{cookie}  } -// Request reply for GetScreenResourcesCurrent -// size: ((((32 + xgb.Pad((int(NumCrtcs) * 4))) + xgb.Pad((int(NumOutputs) * 4))) + xgb.Pad((int(NumModes) * 32))) + xgb.Pad((int(NamesLen) * 1))) +// GetScreenResourcesCurrentReply represents the data returned from a GetScreenResourcesCurrent request.  type GetScreenResourcesCurrentReply struct { -	Sequence uint16 -	Length   uint32 +	Sequence uint16 // sequence number of the request for this reply +	Length   uint32 // number of bytes in this reply  	// padding: 1 bytes  	Timestamp       xproto.Timestamp  	ConfigTimestamp xproto.Timestamp @@ -3292,7 +3363,7 @@ type GetScreenResourcesCurrentReply struct {  	Names   []byte     // size: xgb.Pad((int(NamesLen) * 1))  } -// Waits and reads reply data from request GetScreenResourcesCurrent +// Reply blocks and returns the reply data for a GetScreenResourcesCurrent request.  func (cook GetScreenResourcesCurrentCookie) Reply() (*GetScreenResourcesCurrentReply, error) {  	buf, err := cook.Cookie.Reply()  	if err != nil { @@ -3304,7 +3375,7 @@ func (cook GetScreenResourcesCurrentCookie) Reply() (*GetScreenResourcesCurrentR  	return getScreenResourcesCurrentReply(buf), nil  } -// Read reply into structure from buffer for GetScreenResourcesCurrent +// getScreenResourcesCurrentReply reads a byte slice into a GetScreenResourcesCurrentReply value.  func getScreenResourcesCurrentReply(buf []byte) *GetScreenResourcesCurrentReply {  	v := new(GetScreenResourcesCurrentReply)  	b := 1 // skip reply determinant @@ -3362,6 +3433,7 @@ func getScreenResourcesCurrentReply(buf []byte) *GetScreenResourcesCurrentReply  }  // Write request to wire for GetScreenResourcesCurrent +// getScreenResourcesCurrentRequest writes a GetScreenResourcesCurrent request to a byte slice.  func getScreenResourcesCurrentRequest(c *xgb.Conn, Window xproto.Window) []byte {  	size := 8  	b := 0 @@ -3382,30 +3454,35 @@ func getScreenResourcesCurrentRequest(c *xgb.Conn, Window xproto.Window) []byte  	return buf  } -// Request SetCrtcTransform -// size: xgb.Pad(((48 + xgb.Pad((int(FilterLen) * 1))) + xgb.Pad((len(FilterParams) * 4)))) +// SetCrtcTransformCookie is a cookie used only for SetCrtcTransform requests.  type SetCrtcTransformCookie struct {  	*xgb.Cookie  } -// Write request to wire for SetCrtcTransform +// SetCrtcTransform sends an unchecked request. +// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.  func SetCrtcTransform(c *xgb.Conn, Crtc Crtc, Transform render.Transform, FilterLen uint16, FilterName string, FilterParams []render.Fixed) SetCrtcTransformCookie {  	cookie := c.NewCookie(false, false)  	c.NewRequest(setCrtcTransformRequest(c, Crtc, Transform, FilterLen, FilterName, FilterParams), cookie)  	return SetCrtcTransformCookie{cookie}  } +// SetCrtcTransformChecked sends a checked request. +// If an error occurs, it can be retrieved using SetCrtcTransformCookie.Check()  func SetCrtcTransformChecked(c *xgb.Conn, Crtc Crtc, Transform render.Transform, FilterLen uint16, FilterName string, FilterParams []render.Fixed) SetCrtcTransformCookie {  	cookie := c.NewCookie(true, false)  	c.NewRequest(setCrtcTransformRequest(c, Crtc, Transform, FilterLen, FilterName, FilterParams), cookie)  	return SetCrtcTransformCookie{cookie}  } +// 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.  func (cook SetCrtcTransformCookie) Check() error {  	return cook.Cookie.Check()  }  // Write request to wire for SetCrtcTransform +// setCrtcTransformRequest writes a SetCrtcTransform request to a byte slice.  func setCrtcTransformRequest(c *xgb.Conn, Crtc Crtc, Transform render.Transform, FilterLen uint16, FilterName string, FilterParams []render.Fixed) []byte {  	size := xgb.Pad(((48 + xgb.Pad((int(FilterLen) * 1))) + xgb.Pad((len(FilterParams) * 4))))  	b := 0 @@ -3446,29 +3523,31 @@ func setCrtcTransformRequest(c *xgb.Conn, Crtc Crtc, Transform render.Transform,  	return buf  } -// Request GetCrtcTransform -// size: 8 +// GetCrtcTransformCookie is a cookie used only for GetCrtcTransform requests.  type GetCrtcTransformCookie struct {  	*xgb.Cookie  } +// GetCrtcTransform sends a checked request. +// If an error occurs, it will be returned with the reply by calling GetCrtcTransformCookie.Reply()  func GetCrtcTransform(c *xgb.Conn, Crtc Crtc) GetCrtcTransformCookie {  	cookie := c.NewCookie(true, true)  	c.NewRequest(getCrtcTransformRequest(c, Crtc), cookie)  	return GetCrtcTransformCookie{cookie}  } +// GetCrtcTransformUnchecked sends an unchecked request. +// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.  func GetCrtcTransformUnchecked(c *xgb.Conn, Crtc Crtc) GetCrtcTransformCookie {  	cookie := c.NewCookie(false, true)  	c.NewRequest(getCrtcTransformRequest(c, Crtc), cookie)  	return GetCrtcTransformCookie{cookie}  } -// Request reply for GetCrtcTransform -// size: ((((96 + xgb.Pad((int(PendingLen) * 1))) + xgb.Pad((int(PendingNparams) * 4))) + xgb.Pad((int(CurrentLen) * 1))) + xgb.Pad((int(CurrentNparams) * 4))) +// GetCrtcTransformReply represents the data returned from a GetCrtcTransform request.  type GetCrtcTransformReply struct { -	Sequence uint16 -	Length   uint32 +	Sequence uint16 // sequence number of the request for this reply +	Length   uint32 // number of bytes in this reply  	// padding: 1 bytes  	PendingTransform render.Transform  	HasTransforms    bool @@ -3485,7 +3564,7 @@ type GetCrtcTransformReply struct {  	CurrentParams     []render.Fixed // size: xgb.Pad((int(CurrentNparams) * 4))  } -// Waits and reads reply data from request GetCrtcTransform +// Reply blocks and returns the reply data for a GetCrtcTransform request.  func (cook GetCrtcTransformCookie) Reply() (*GetCrtcTransformReply, error) {  	buf, err := cook.Cookie.Reply()  	if err != nil { @@ -3497,7 +3576,7 @@ func (cook GetCrtcTransformCookie) Reply() (*GetCrtcTransformReply, error) {  	return getCrtcTransformReply(buf), nil  } -// Read reply into structure from buffer for GetCrtcTransform +// getCrtcTransformReply reads a byte slice into a GetCrtcTransformReply value.  func getCrtcTransformReply(buf []byte) *GetCrtcTransformReply {  	v := new(GetCrtcTransformReply)  	b := 1 // skip reply determinant @@ -3571,6 +3650,7 @@ func getCrtcTransformReply(buf []byte) *GetCrtcTransformReply {  }  // Write request to wire for GetCrtcTransform +// getCrtcTransformRequest writes a GetCrtcTransform request to a byte slice.  func getCrtcTransformRequest(c *xgb.Conn, Crtc Crtc) []byte {  	size := 8  	b := 0 @@ -3591,29 +3671,31 @@ func getCrtcTransformRequest(c *xgb.Conn, Crtc Crtc) []byte {  	return buf  } -// Request GetPanning -// size: 8 +// GetPanningCookie is a cookie used only for GetPanning requests.  type GetPanningCookie struct {  	*xgb.Cookie  } +// GetPanning sends a checked request. +// If an error occurs, it will be returned with the reply by calling GetPanningCookie.Reply()  func GetPanning(c *xgb.Conn, Crtc Crtc) GetPanningCookie {  	cookie := c.NewCookie(true, true)  	c.NewRequest(getPanningRequest(c, Crtc), cookie)  	return GetPanningCookie{cookie}  } +// GetPanningUnchecked sends an unchecked request. +// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.  func GetPanningUnchecked(c *xgb.Conn, Crtc Crtc) GetPanningCookie {  	cookie := c.NewCookie(false, true)  	c.NewRequest(getPanningRequest(c, Crtc), cookie)  	return GetPanningCookie{cookie}  } -// Request reply for GetPanning -// size: 36 +// GetPanningReply represents the data returned from a GetPanning request.  type GetPanningReply struct { -	Sequence     uint16 -	Length       uint32 +	Sequence     uint16 // sequence number of the request for this reply +	Length       uint32 // number of bytes in this reply  	Status       byte  	Timestamp    xproto.Timestamp  	Left         uint16 @@ -3630,7 +3712,7 @@ type GetPanningReply struct {  	BorderBottom int16  } -// Waits and reads reply data from request GetPanning +// Reply blocks and returns the reply data for a GetPanning request.  func (cook GetPanningCookie) Reply() (*GetPanningReply, error) {  	buf, err := cook.Cookie.Reply()  	if err != nil { @@ -3642,7 +3724,7 @@ func (cook GetPanningCookie) Reply() (*GetPanningReply, error) {  	return getPanningReply(buf), nil  } -// Read reply into structure from buffer for GetPanning +// getPanningReply reads a byte slice into a GetPanningReply value.  func getPanningReply(buf []byte) *GetPanningReply {  	v := new(GetPanningReply)  	b := 1 // skip reply determinant @@ -3699,6 +3781,7 @@ func getPanningReply(buf []byte) *GetPanningReply {  }  // Write request to wire for GetPanning +// getPanningRequest writes a GetPanning request to a byte slice.  func getPanningRequest(c *xgb.Conn, Crtc Crtc) []byte {  	size := 8  	b := 0 @@ -3719,34 +3802,36 @@ func getPanningRequest(c *xgb.Conn, Crtc Crtc) []byte {  	return buf  } -// Request SetPanning -// size: 36 +// SetPanningCookie is a cookie used only for SetPanning requests.  type SetPanningCookie struct {  	*xgb.Cookie  } +// SetPanning sends a checked request. +// If an error occurs, it will be returned with the reply by calling SetPanningCookie.Reply()  func SetPanning(c *xgb.Conn, Crtc Crtc, Timestamp xproto.Timestamp, Left uint16, Top uint16, Width uint16, Height uint16, TrackLeft uint16, TrackTop uint16, TrackWidth uint16, TrackHeight uint16, BorderLeft int16, BorderTop int16, BorderRight int16, BorderBottom int16) SetPanningCookie {  	cookie := c.NewCookie(true, true)  	c.NewRequest(setPanningRequest(c, Crtc, Timestamp, Left, Top, Width, Height, TrackLeft, TrackTop, TrackWidth, TrackHeight, BorderLeft, BorderTop, BorderRight, BorderBottom), cookie)  	return SetPanningCookie{cookie}  } +// SetPanningUnchecked sends an unchecked request. +// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.  func SetPanningUnchecked(c *xgb.Conn, Crtc Crtc, Timestamp xproto.Timestamp, Left uint16, Top uint16, Width uint16, Height uint16, TrackLeft uint16, TrackTop uint16, TrackWidth uint16, TrackHeight uint16, BorderLeft int16, BorderTop int16, BorderRight int16, BorderBottom int16) SetPanningCookie {  	cookie := c.NewCookie(false, true)  	c.NewRequest(setPanningRequest(c, Crtc, Timestamp, Left, Top, Width, Height, TrackLeft, TrackTop, TrackWidth, TrackHeight, BorderLeft, BorderTop, BorderRight, BorderBottom), cookie)  	return SetPanningCookie{cookie}  } -// Request reply for SetPanning -// size: 12 +// SetPanningReply represents the data returned from a SetPanning request.  type SetPanningReply struct { -	Sequence  uint16 -	Length    uint32 +	Sequence  uint16 // sequence number of the request for this reply +	Length    uint32 // number of bytes in this reply  	Status    byte  	Timestamp xproto.Timestamp  } -// Waits and reads reply data from request SetPanning +// Reply blocks and returns the reply data for a SetPanning request.  func (cook SetPanningCookie) Reply() (*SetPanningReply, error) {  	buf, err := cook.Cookie.Reply()  	if err != nil { @@ -3758,7 +3843,7 @@ func (cook SetPanningCookie) Reply() (*SetPanningReply, error) {  	return setPanningReply(buf), nil  } -// Read reply into structure from buffer for SetPanning +// setPanningReply reads a byte slice into a SetPanningReply value.  func setPanningReply(buf []byte) *SetPanningReply {  	v := new(SetPanningReply)  	b := 1 // skip reply determinant @@ -3779,6 +3864,7 @@ func setPanningReply(buf []byte) *SetPanningReply {  }  // Write request to wire for SetPanning +// setPanningRequest writes a SetPanning request to a byte slice.  func setPanningRequest(c *xgb.Conn, Crtc Crtc, Timestamp xproto.Timestamp, Left uint16, Top uint16, Width uint16, Height uint16, TrackLeft uint16, TrackTop uint16, TrackWidth uint16, TrackHeight uint16, BorderLeft int16, BorderTop int16, BorderRight int16, BorderBottom int16) []byte {  	size := 36  	b := 0 @@ -3838,30 +3924,35 @@ func setPanningRequest(c *xgb.Conn, Crtc Crtc, Timestamp xproto.Timestamp, Left  	return buf  } -// Request SetOutputPrimary -// size: 12 +// SetOutputPrimaryCookie is a cookie used only for SetOutputPrimary requests.  type SetOutputPrimaryCookie struct {  	*xgb.Cookie  } -// Write request to wire for SetOutputPrimary +// SetOutputPrimary sends an unchecked request. +// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.  func SetOutputPrimary(c *xgb.Conn, Window xproto.Window, Output Output) SetOutputPrimaryCookie {  	cookie := c.NewCookie(false, false)  	c.NewRequest(setOutputPrimaryRequest(c, Window, Output), cookie)  	return SetOutputPrimaryCookie{cookie}  } +// SetOutputPrimaryChecked sends a checked request. +// If an error occurs, it can be retrieved using SetOutputPrimaryCookie.Check()  func SetOutputPrimaryChecked(c *xgb.Conn, Window xproto.Window, Output Output) SetOutputPrimaryCookie {  	cookie := c.NewCookie(true, false)  	c.NewRequest(setOutputPrimaryRequest(c, Window, Output), cookie)  	return SetOutputPrimaryCookie{cookie}  } +// 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.  func (cook SetOutputPrimaryCookie) Check() error {  	return cook.Cookie.Check()  }  // Write request to wire for SetOutputPrimary +// setOutputPrimaryRequest writes a SetOutputPrimary request to a byte slice.  func setOutputPrimaryRequest(c *xgb.Conn, Window xproto.Window, Output Output) []byte {  	size := 12  	b := 0 @@ -3885,34 +3976,36 @@ func setOutputPrimaryRequest(c *xgb.Conn, Window xproto.Window, Output Output) [  	return buf  } -// Request GetOutputPrimary -// size: 8 +// GetOutputPrimaryCookie is a cookie used only for GetOutputPrimary requests.  type GetOutputPrimaryCookie struct {  	*xgb.Cookie  } +// GetOutputPrimary sends a checked request. +// If an error occurs, it will be returned with the reply by calling GetOutputPrimaryCookie.Reply()  func GetOutputPrimary(c *xgb.Conn, Window xproto.Window) GetOutputPrimaryCookie {  	cookie := c.NewCookie(true, true)  	c.NewRequest(getOutputPrimaryRequest(c, Window), cookie)  	return GetOutputPrimaryCookie{cookie}  } +// GetOutputPrimaryUnchecked sends an unchecked request. +// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.  func GetOutputPrimaryUnchecked(c *xgb.Conn, Window xproto.Window) GetOutputPrimaryCookie {  	cookie := c.NewCookie(false, true)  	c.NewRequest(getOutputPrimaryRequest(c, Window), cookie)  	return GetOutputPrimaryCookie{cookie}  } -// Request reply for GetOutputPrimary -// size: 12 +// GetOutputPrimaryReply represents the data returned from a GetOutputPrimary request.  type GetOutputPrimaryReply struct { -	Sequence uint16 -	Length   uint32 +	Sequence uint16 // sequence number of the request for this reply +	Length   uint32 // number of bytes in this reply  	// padding: 1 bytes  	Output Output  } -// Waits and reads reply data from request GetOutputPrimary +// Reply blocks and returns the reply data for a GetOutputPrimary request.  func (cook GetOutputPrimaryCookie) Reply() (*GetOutputPrimaryReply, error) {  	buf, err := cook.Cookie.Reply()  	if err != nil { @@ -3924,7 +4017,7 @@ func (cook GetOutputPrimaryCookie) Reply() (*GetOutputPrimaryReply, error) {  	return getOutputPrimaryReply(buf), nil  } -// Read reply into structure from buffer for GetOutputPrimary +// getOutputPrimaryReply reads a byte slice into a GetOutputPrimaryReply value.  func getOutputPrimaryReply(buf []byte) *GetOutputPrimaryReply {  	v := new(GetOutputPrimaryReply)  	b := 1 // skip reply determinant @@ -3944,6 +4037,7 @@ func getOutputPrimaryReply(buf []byte) *GetOutputPrimaryReply {  }  // Write request to wire for GetOutputPrimary +// getOutputPrimaryRequest writes a GetOutputPrimary request to a byte slice.  func getOutputPrimaryRequest(c *xgb.Conn, Window xproto.Window) []byte {  	size := 8  	b := 0 | 
