aboutsummaryrefslogtreecommitdiff
path: root/nexgb/xfixes/xfixes.go
diff options
context:
space:
mode:
Diffstat (limited to 'nexgb/xfixes/xfixes.go')
-rw-r--r--nexgb/xfixes/xfixes.go249
1 files changed, 108 insertions, 141 deletions
diff --git a/nexgb/xfixes/xfixes.go b/nexgb/xfixes/xfixes.go
index 50bf40d..3a3dd15 100644
--- a/nexgb/xfixes/xfixes.go
+++ b/nexgb/xfixes/xfixes.go
@@ -384,7 +384,7 @@ type ChangeCursorCookie struct {
// ChangeCursor sends an unchecked request.
// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.
-func ChangeCursor(c *xgb.Conn, Source xproto.Cursor, Destination xproto.Cursor) ChangeCursorCookie {
+func ChangeCursor(c *xgb.Conn, Source, Destination xproto.Cursor) ChangeCursorCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XFIXES"]; !ok {
@@ -396,8 +396,8 @@ func ChangeCursor(c *xgb.Conn, Source xproto.Cursor, Destination xproto.Cursor)
}
// ChangeCursorChecked sends a checked request.
-// If an error occurs, it can be retrieved using ChangeCursorCookie.Check()
-func ChangeCursorChecked(c *xgb.Conn, Source xproto.Cursor, Destination xproto.Cursor) ChangeCursorCookie {
+// If an error occurs, it can be retrieved using ChangeCursorCookie.Check.
+func ChangeCursorChecked(c *xgb.Conn, Source, Destination xproto.Cursor) ChangeCursorCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XFIXES"]; !ok {
@@ -414,9 +414,8 @@ func (cook ChangeCursorCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for ChangeCursor
-// changeCursorRequest writes a ChangeCursor request to a byte slice.
-func changeCursorRequest(c *xgb.Conn, Source xproto.Cursor, Destination xproto.Cursor) []byte {
+// changeCursorRequest writes a ChangeCursor request to a byte slice for transfer.
+func changeCursorRequest(c *xgb.Conn, Source, Destination xproto.Cursor) []byte {
size := 12
b := 0
buf := make([]byte, size)
@@ -460,7 +459,7 @@ func ChangeCursorByName(c *xgb.Conn, Src xproto.Cursor, Nbytes uint16, Name stri
}
// ChangeCursorByNameChecked sends a checked request.
-// If an error occurs, it can be retrieved using ChangeCursorByNameCookie.Check()
+// If an error occurs, it can be retrieved using ChangeCursorByNameCookie.Check.
func ChangeCursorByNameChecked(c *xgb.Conn, Src xproto.Cursor, Nbytes uint16, Name string) ChangeCursorByNameCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -478,8 +477,7 @@ func (cook ChangeCursorByNameCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for ChangeCursorByName
-// changeCursorByNameRequest writes a ChangeCursorByName request to a byte slice.
+// changeCursorByNameRequest writes a ChangeCursorByName request to a byte slice for transfer.
func changeCursorByNameRequest(c *xgb.Conn, Src xproto.Cursor, Nbytes uint16, Name string) []byte {
size := xgb.Pad((12 + xgb.Pad((int(Nbytes) * 1))))
b := 0
@@ -517,7 +515,7 @@ type ChangeSaveSetCookie struct {
// ChangeSaveSet sends an unchecked request.
// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.
-func ChangeSaveSet(c *xgb.Conn, Mode byte, Target byte, Map byte, Window xproto.Window) ChangeSaveSetCookie {
+func ChangeSaveSet(c *xgb.Conn, Mode, Target, Map byte, Window xproto.Window) ChangeSaveSetCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XFIXES"]; !ok {
@@ -529,8 +527,8 @@ func ChangeSaveSet(c *xgb.Conn, Mode byte, Target byte, Map byte, Window xproto.
}
// ChangeSaveSetChecked sends a checked request.
-// If an error occurs, it can be retrieved using ChangeSaveSetCookie.Check()
-func ChangeSaveSetChecked(c *xgb.Conn, Mode byte, Target byte, Map byte, Window xproto.Window) ChangeSaveSetCookie {
+// If an error occurs, it can be retrieved using ChangeSaveSetCookie.Check.
+func ChangeSaveSetChecked(c *xgb.Conn, Mode, Target, Map byte, Window xproto.Window) ChangeSaveSetCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XFIXES"]; !ok {
@@ -547,9 +545,8 @@ func (cook ChangeSaveSetCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for ChangeSaveSet
-// changeSaveSetRequest writes a ChangeSaveSet request to a byte slice.
-func changeSaveSetRequest(c *xgb.Conn, Mode byte, Target byte, Map byte, Window xproto.Window) []byte {
+// changeSaveSetRequest writes a ChangeSaveSet request to a byte slice for transfer.
+func changeSaveSetRequest(c *xgb.Conn, Mode, Target, Map byte, Window xproto.Window) []byte {
size := 12
b := 0
buf := make([]byte, size)
@@ -589,7 +586,7 @@ type CopyRegionCookie struct {
// CopyRegion sends an unchecked request.
// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.
-func CopyRegion(c *xgb.Conn, Source Region, Destination Region) CopyRegionCookie {
+func CopyRegion(c *xgb.Conn, Source, Destination Region) CopyRegionCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XFIXES"]; !ok {
@@ -601,8 +598,8 @@ func CopyRegion(c *xgb.Conn, Source Region, Destination Region) CopyRegionCookie
}
// CopyRegionChecked sends a checked request.
-// If an error occurs, it can be retrieved using CopyRegionCookie.Check()
-func CopyRegionChecked(c *xgb.Conn, Source Region, Destination Region) CopyRegionCookie {
+// If an error occurs, it can be retrieved using CopyRegionCookie.Check.
+func CopyRegionChecked(c *xgb.Conn, Source, Destination Region) CopyRegionCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XFIXES"]; !ok {
@@ -619,9 +616,8 @@ func (cook CopyRegionCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for CopyRegion
-// copyRegionRequest writes a CopyRegion request to a byte slice.
-func copyRegionRequest(c *xgb.Conn, Source Region, Destination Region) []byte {
+// copyRegionRequest writes a CopyRegion request to a byte slice for transfer.
+func copyRegionRequest(c *xgb.Conn, Source, Destination Region) []byte {
size := 12
b := 0
buf := make([]byte, size)
@@ -653,7 +649,7 @@ type CreatePointerBarrierCookie struct {
// CreatePointerBarrier sends an unchecked request.
// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.
-func CreatePointerBarrier(c *xgb.Conn, Barrier Barrier, Window xproto.Window, X1 uint16, Y1 uint16, X2 uint16, Y2 uint16, Directions uint32, NumDevices uint16, Devices []uint16) CreatePointerBarrierCookie {
+func CreatePointerBarrier(c *xgb.Conn, Barrier Barrier, Window xproto.Window, X1, Y1, X2, Y2 uint16, Directions uint32, NumDevices uint16, Devices []uint16) CreatePointerBarrierCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XFIXES"]; !ok {
@@ -665,8 +661,8 @@ func CreatePointerBarrier(c *xgb.Conn, Barrier Barrier, Window xproto.Window, X1
}
// CreatePointerBarrierChecked sends a checked request.
-// If an error occurs, it can be retrieved using CreatePointerBarrierCookie.Check()
-func CreatePointerBarrierChecked(c *xgb.Conn, Barrier Barrier, Window xproto.Window, X1 uint16, Y1 uint16, X2 uint16, Y2 uint16, Directions uint32, NumDevices uint16, Devices []uint16) CreatePointerBarrierCookie {
+// If an error occurs, it can be retrieved using CreatePointerBarrierCookie.Check.
+func CreatePointerBarrierChecked(c *xgb.Conn, Barrier Barrier, Window xproto.Window, X1, Y1, X2, Y2 uint16, Directions uint32, NumDevices uint16, Devices []uint16) CreatePointerBarrierCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XFIXES"]; !ok {
@@ -683,9 +679,8 @@ func (cook CreatePointerBarrierCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for CreatePointerBarrier
-// createPointerBarrierRequest writes a CreatePointerBarrier request to a byte slice.
-func createPointerBarrierRequest(c *xgb.Conn, Barrier Barrier, Window xproto.Window, X1 uint16, Y1 uint16, X2 uint16, Y2 uint16, Directions uint32, NumDevices uint16, Devices []uint16) []byte {
+// createPointerBarrierRequest writes a CreatePointerBarrier request to a byte slice for transfer.
+func createPointerBarrierRequest(c *xgb.Conn, Barrier Barrier, Window xproto.Window, X1, Y1, X2, Y2 uint16, Directions uint32, NumDevices uint16, Devices []uint16) []byte {
size := xgb.Pad((28 + xgb.Pad((int(NumDevices) * 2))))
b := 0
buf := make([]byte, size)
@@ -754,7 +749,7 @@ func CreateRegion(c *xgb.Conn, Region Region, Rectangles []xproto.Rectangle) Cre
}
// CreateRegionChecked sends a checked request.
-// If an error occurs, it can be retrieved using CreateRegionCookie.Check()
+// If an error occurs, it can be retrieved using CreateRegionCookie.Check.
func CreateRegionChecked(c *xgb.Conn, Region Region, Rectangles []xproto.Rectangle) CreateRegionCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -772,8 +767,7 @@ func (cook CreateRegionCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for CreateRegion
-// createRegionRequest writes a CreateRegion request to a byte slice.
+// createRegionRequest writes a CreateRegion request to a byte slice for transfer.
func createRegionRequest(c *xgb.Conn, Region Region, Rectangles []xproto.Rectangle) []byte {
size := xgb.Pad((8 + xgb.Pad((len(Rectangles) * 8))))
b := 0
@@ -817,7 +811,7 @@ func CreateRegionFromBitmap(c *xgb.Conn, Region Region, Bitmap xproto.Pixmap) Cr
}
// CreateRegionFromBitmapChecked sends a checked request.
-// If an error occurs, it can be retrieved using CreateRegionFromBitmapCookie.Check()
+// If an error occurs, it can be retrieved using CreateRegionFromBitmapCookie.Check.
func CreateRegionFromBitmapChecked(c *xgb.Conn, Region Region, Bitmap xproto.Pixmap) CreateRegionFromBitmapCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -835,8 +829,7 @@ func (cook CreateRegionFromBitmapCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for CreateRegionFromBitmap
-// createRegionFromBitmapRequest writes a CreateRegionFromBitmap request to a byte slice.
+// createRegionFromBitmapRequest writes a CreateRegionFromBitmap request to a byte slice for transfer.
func createRegionFromBitmapRequest(c *xgb.Conn, Region Region, Bitmap xproto.Pixmap) []byte {
size := 12
b := 0
@@ -881,7 +874,7 @@ func CreateRegionFromGC(c *xgb.Conn, Region Region, Gc xproto.Gcontext) CreateRe
}
// CreateRegionFromGCChecked sends a checked request.
-// If an error occurs, it can be retrieved using CreateRegionFromGCCookie.Check()
+// If an error occurs, it can be retrieved using CreateRegionFromGCCookie.Check.
func CreateRegionFromGCChecked(c *xgb.Conn, Region Region, Gc xproto.Gcontext) CreateRegionFromGCCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -899,8 +892,7 @@ func (cook CreateRegionFromGCCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for CreateRegionFromGC
-// createRegionFromGCRequest writes a CreateRegionFromGC request to a byte slice.
+// createRegionFromGCRequest writes a CreateRegionFromGC request to a byte slice for transfer.
func createRegionFromGCRequest(c *xgb.Conn, Region Region, Gc xproto.Gcontext) []byte {
size := 12
b := 0
@@ -945,7 +937,7 @@ func CreateRegionFromPicture(c *xgb.Conn, Region Region, Picture render.Picture)
}
// CreateRegionFromPictureChecked sends a checked request.
-// If an error occurs, it can be retrieved using CreateRegionFromPictureCookie.Check()
+// If an error occurs, it can be retrieved using CreateRegionFromPictureCookie.Check.
func CreateRegionFromPictureChecked(c *xgb.Conn, Region Region, Picture render.Picture) CreateRegionFromPictureCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -963,8 +955,7 @@ func (cook CreateRegionFromPictureCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for CreateRegionFromPicture
-// createRegionFromPictureRequest writes a CreateRegionFromPicture request to a byte slice.
+// createRegionFromPictureRequest writes a CreateRegionFromPicture request to a byte slice for transfer.
func createRegionFromPictureRequest(c *xgb.Conn, Region Region, Picture render.Picture) []byte {
size := 12
b := 0
@@ -1009,7 +1000,7 @@ func CreateRegionFromWindow(c *xgb.Conn, Region Region, Window xproto.Window, Ki
}
// CreateRegionFromWindowChecked sends a checked request.
-// If an error occurs, it can be retrieved using CreateRegionFromWindowCookie.Check()
+// If an error occurs, it can be retrieved using CreateRegionFromWindowCookie.Check.
func CreateRegionFromWindowChecked(c *xgb.Conn, Region Region, Window xproto.Window, Kind shape.Kind) CreateRegionFromWindowCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -1027,8 +1018,7 @@ func (cook CreateRegionFromWindowCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for CreateRegionFromWindow
-// createRegionFromWindowRequest writes a CreateRegionFromWindow request to a byte slice.
+// createRegionFromWindowRequest writes a CreateRegionFromWindow request to a byte slice for transfer.
func createRegionFromWindowRequest(c *xgb.Conn, Region Region, Window xproto.Window, Kind shape.Kind) []byte {
size := 16
b := 0
@@ -1078,7 +1068,7 @@ func DeletePointerBarrier(c *xgb.Conn, Barrier Barrier) DeletePointerBarrierCook
}
// DeletePointerBarrierChecked sends a checked request.
-// If an error occurs, it can be retrieved using DeletePointerBarrierCookie.Check()
+// If an error occurs, it can be retrieved using DeletePointerBarrierCookie.Check.
func DeletePointerBarrierChecked(c *xgb.Conn, Barrier Barrier) DeletePointerBarrierCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -1096,8 +1086,7 @@ func (cook DeletePointerBarrierCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for DeletePointerBarrier
-// deletePointerBarrierRequest writes a DeletePointerBarrier request to a byte slice.
+// deletePointerBarrierRequest writes a DeletePointerBarrier request to a byte slice for transfer.
func deletePointerBarrierRequest(c *xgb.Conn, Barrier Barrier) []byte {
size := 8
b := 0
@@ -1139,7 +1128,7 @@ func DestroyRegion(c *xgb.Conn, Region Region) DestroyRegionCookie {
}
// DestroyRegionChecked sends a checked request.
-// If an error occurs, it can be retrieved using DestroyRegionCookie.Check()
+// If an error occurs, it can be retrieved using DestroyRegionCookie.Check.
func DestroyRegionChecked(c *xgb.Conn, Region Region) DestroyRegionCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -1157,8 +1146,7 @@ func (cook DestroyRegionCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for DestroyRegion
-// destroyRegionRequest writes a DestroyRegion request to a byte slice.
+// destroyRegionRequest writes a DestroyRegion request to a byte slice for transfer.
func destroyRegionRequest(c *xgb.Conn, Region Region) []byte {
size := 8
b := 0
@@ -1188,7 +1176,7 @@ type ExpandRegionCookie struct {
// ExpandRegion sends an unchecked request.
// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.
-func ExpandRegion(c *xgb.Conn, Source Region, Destination Region, Left uint16, Right uint16, Top uint16, Bottom uint16) ExpandRegionCookie {
+func ExpandRegion(c *xgb.Conn, Source, Destination Region, Left, Right, Top, Bottom uint16) ExpandRegionCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XFIXES"]; !ok {
@@ -1200,8 +1188,8 @@ func ExpandRegion(c *xgb.Conn, Source Region, Destination Region, Left uint16, R
}
// ExpandRegionChecked sends a checked request.
-// If an error occurs, it can be retrieved using ExpandRegionCookie.Check()
-func ExpandRegionChecked(c *xgb.Conn, Source Region, Destination Region, Left uint16, Right uint16, Top uint16, Bottom uint16) ExpandRegionCookie {
+// If an error occurs, it can be retrieved using ExpandRegionCookie.Check.
+func ExpandRegionChecked(c *xgb.Conn, Source, Destination Region, Left, Right, Top, Bottom uint16) ExpandRegionCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XFIXES"]; !ok {
@@ -1218,9 +1206,8 @@ func (cook ExpandRegionCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for ExpandRegion
-// expandRegionRequest writes a ExpandRegion request to a byte slice.
-func expandRegionRequest(c *xgb.Conn, Source Region, Destination Region, Left uint16, Right uint16, Top uint16, Bottom uint16) []byte {
+// expandRegionRequest writes a ExpandRegion request to a byte slice for transfer.
+func expandRegionRequest(c *xgb.Conn, Source, Destination Region, Left, Right, Top, Bottom uint16) []byte {
size := 20
b := 0
buf := make([]byte, size)
@@ -1263,7 +1250,7 @@ type FetchRegionCookie struct {
}
// FetchRegion sends a checked request.
-// If an error occurs, it will be returned with the reply by calling FetchRegionCookie.Reply()
+// If an error occurs, it will be returned with the reply by calling FetchRegionCookie.Reply.
func FetchRegion(c *xgb.Conn, Region Region) FetchRegionCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -1334,8 +1321,7 @@ func fetchRegionReply(buf []byte) *FetchRegionReply {
return v
}
-// Write request to wire for FetchRegion
-// fetchRegionRequest writes a FetchRegion request to a byte slice.
+// fetchRegionRequest writes a FetchRegion request to a byte slice for transfer.
func fetchRegionRequest(c *xgb.Conn, Region Region) []byte {
size := 8
b := 0
@@ -1364,7 +1350,7 @@ type GetCursorImageCookie struct {
}
// GetCursorImage sends a checked request.
-// If an error occurs, it will be returned with the reply by calling GetCursorImageCookie.Reply()
+// If an error occurs, it will be returned with the reply by calling GetCursorImageCookie.Reply.
func GetCursorImage(c *xgb.Conn) GetCursorImageCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -1462,8 +1448,7 @@ func getCursorImageReply(buf []byte) *GetCursorImageReply {
return v
}
-// Write request to wire for GetCursorImage
-// getCursorImageRequest writes a GetCursorImage request to a byte slice.
+// getCursorImageRequest writes a GetCursorImage request to a byte slice for transfer.
func getCursorImageRequest(c *xgb.Conn) []byte {
size := 4
b := 0
@@ -1489,7 +1474,7 @@ type GetCursorImageAndNameCookie struct {
}
// GetCursorImageAndName sends a checked request.
-// If an error occurs, it will be returned with the reply by calling GetCursorImageAndNameCookie.Reply()
+// If an error occurs, it will be returned with the reply by calling GetCursorImageAndNameCookie.Reply.
func GetCursorImageAndName(c *xgb.Conn) GetCursorImageAndNameCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -1603,8 +1588,7 @@ func getCursorImageAndNameReply(buf []byte) *GetCursorImageAndNameReply {
return v
}
-// Write request to wire for GetCursorImageAndName
-// getCursorImageAndNameRequest writes a GetCursorImageAndName request to a byte slice.
+// getCursorImageAndNameRequest writes a GetCursorImageAndName request to a byte slice for transfer.
func getCursorImageAndNameRequest(c *xgb.Conn) []byte {
size := 4
b := 0
@@ -1630,7 +1614,7 @@ type GetCursorNameCookie struct {
}
// GetCursorName sends a checked request.
-// If an error occurs, it will be returned with the reply by calling GetCursorNameCookie.Reply()
+// If an error occurs, it will be returned with the reply by calling GetCursorNameCookie.Reply.
func GetCursorName(c *xgb.Conn, Cursor xproto.Cursor) GetCursorNameCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -1709,8 +1693,7 @@ func getCursorNameReply(buf []byte) *GetCursorNameReply {
return v
}
-// Write request to wire for GetCursorName
-// getCursorNameRequest writes a GetCursorName request to a byte slice.
+// getCursorNameRequest writes a GetCursorName request to a byte slice for transfer.
func getCursorNameRequest(c *xgb.Conn, Cursor xproto.Cursor) []byte {
size := 8
b := 0
@@ -1752,7 +1735,7 @@ func HideCursor(c *xgb.Conn, Window xproto.Window) HideCursorCookie {
}
// HideCursorChecked sends a checked request.
-// If an error occurs, it can be retrieved using HideCursorCookie.Check()
+// If an error occurs, it can be retrieved using HideCursorCookie.Check.
func HideCursorChecked(c *xgb.Conn, Window xproto.Window) HideCursorCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -1770,8 +1753,7 @@ func (cook HideCursorCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for HideCursor
-// hideCursorRequest writes a HideCursor request to a byte slice.
+// hideCursorRequest writes a HideCursor request to a byte slice for transfer.
func hideCursorRequest(c *xgb.Conn, Window xproto.Window) []byte {
size := 8
b := 0
@@ -1801,7 +1783,7 @@ type IntersectRegionCookie struct {
// IntersectRegion sends an unchecked request.
// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.
-func IntersectRegion(c *xgb.Conn, Source1 Region, Source2 Region, Destination Region) IntersectRegionCookie {
+func IntersectRegion(c *xgb.Conn, Source1, Source2, Destination Region) IntersectRegionCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XFIXES"]; !ok {
@@ -1813,8 +1795,8 @@ func IntersectRegion(c *xgb.Conn, Source1 Region, Source2 Region, Destination Re
}
// IntersectRegionChecked sends a checked request.
-// If an error occurs, it can be retrieved using IntersectRegionCookie.Check()
-func IntersectRegionChecked(c *xgb.Conn, Source1 Region, Source2 Region, Destination Region) IntersectRegionCookie {
+// If an error occurs, it can be retrieved using IntersectRegionCookie.Check.
+func IntersectRegionChecked(c *xgb.Conn, Source1, Source2, Destination Region) IntersectRegionCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XFIXES"]; !ok {
@@ -1831,9 +1813,8 @@ func (cook IntersectRegionCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for IntersectRegion
-// intersectRegionRequest writes a IntersectRegion request to a byte slice.
-func intersectRegionRequest(c *xgb.Conn, Source1 Region, Source2 Region, Destination Region) []byte {
+// intersectRegionRequest writes a IntersectRegion request to a byte slice for transfer.
+func intersectRegionRequest(c *xgb.Conn, Source1, Source2, Destination Region) []byte {
size := 16
b := 0
buf := make([]byte, size)
@@ -1880,7 +1861,7 @@ func InvertRegion(c *xgb.Conn, Source Region, Bounds xproto.Rectangle, Destinati
}
// InvertRegionChecked sends a checked request.
-// If an error occurs, it can be retrieved using InvertRegionCookie.Check()
+// If an error occurs, it can be retrieved using InvertRegionCookie.Check.
func InvertRegionChecked(c *xgb.Conn, Source Region, Bounds xproto.Rectangle, Destination Region) InvertRegionCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -1898,8 +1879,7 @@ func (cook InvertRegionCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for InvertRegion
-// invertRegionRequest writes a InvertRegion request to a byte slice.
+// invertRegionRequest writes a InvertRegion request to a byte slice for transfer.
func invertRegionRequest(c *xgb.Conn, Source Region, Bounds xproto.Rectangle, Destination Region) []byte {
size := 20
b := 0
@@ -1937,8 +1917,8 @@ type QueryVersionCookie struct {
}
// 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, ClientMajorVersion uint32, ClientMinorVersion uint32) QueryVersionCookie {
+// If an error occurs, it will be returned with the reply by calling QueryVersionCookie.Reply.
+func QueryVersion(c *xgb.Conn, ClientMajorVersion, ClientMinorVersion uint32) QueryVersionCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XFIXES"]; !ok {
@@ -1951,7 +1931,7 @@ func QueryVersion(c *xgb.Conn, ClientMajorVersion uint32, ClientMinorVersion uin
// 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, ClientMajorVersion uint32, ClientMinorVersion uint32) QueryVersionCookie {
+func QueryVersionUnchecked(c *xgb.Conn, ClientMajorVersion, ClientMinorVersion uint32) QueryVersionCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XFIXES"]; !ok {
@@ -2008,9 +1988,8 @@ func queryVersionReply(buf []byte) *QueryVersionReply {
return v
}
-// Write request to wire for QueryVersion
-// queryVersionRequest writes a QueryVersion request to a byte slice.
-func queryVersionRequest(c *xgb.Conn, ClientMajorVersion uint32, ClientMinorVersion uint32) []byte {
+// queryVersionRequest writes a QueryVersion request to a byte slice for transfer.
+func queryVersionRequest(c *xgb.Conn, ClientMajorVersion, ClientMinorVersion uint32) []byte {
size := 12
b := 0
buf := make([]byte, size)
@@ -2042,7 +2021,7 @@ type RegionExtentsCookie struct {
// RegionExtents sends an unchecked request.
// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.
-func RegionExtents(c *xgb.Conn, Source Region, Destination Region) RegionExtentsCookie {
+func RegionExtents(c *xgb.Conn, Source, Destination Region) RegionExtentsCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XFIXES"]; !ok {
@@ -2054,8 +2033,8 @@ func RegionExtents(c *xgb.Conn, Source Region, Destination Region) RegionExtents
}
// RegionExtentsChecked sends a checked request.
-// If an error occurs, it can be retrieved using RegionExtentsCookie.Check()
-func RegionExtentsChecked(c *xgb.Conn, Source Region, Destination Region) RegionExtentsCookie {
+// If an error occurs, it can be retrieved using RegionExtentsCookie.Check.
+func RegionExtentsChecked(c *xgb.Conn, Source, Destination Region) RegionExtentsCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XFIXES"]; !ok {
@@ -2072,9 +2051,8 @@ func (cook RegionExtentsCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for RegionExtents
-// regionExtentsRequest writes a RegionExtents request to a byte slice.
-func regionExtentsRequest(c *xgb.Conn, Source Region, Destination Region) []byte {
+// regionExtentsRequest writes a RegionExtents request to a byte slice for transfer.
+func regionExtentsRequest(c *xgb.Conn, Source, Destination Region) []byte {
size := 12
b := 0
buf := make([]byte, size)
@@ -2118,7 +2096,7 @@ func SelectCursorInput(c *xgb.Conn, Window xproto.Window, EventMask uint32) Sele
}
// SelectCursorInputChecked sends a checked request.
-// If an error occurs, it can be retrieved using SelectCursorInputCookie.Check()
+// If an error occurs, it can be retrieved using SelectCursorInputCookie.Check.
func SelectCursorInputChecked(c *xgb.Conn, Window xproto.Window, EventMask uint32) SelectCursorInputCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -2136,8 +2114,7 @@ func (cook SelectCursorInputCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for SelectCursorInput
-// selectCursorInputRequest writes a SelectCursorInput request to a byte slice.
+// selectCursorInputRequest writes a SelectCursorInput request to a byte slice for transfer.
func selectCursorInputRequest(c *xgb.Conn, Window xproto.Window, EventMask uint32) []byte {
size := 12
b := 0
@@ -2182,7 +2159,7 @@ func SelectSelectionInput(c *xgb.Conn, Window xproto.Window, Selection xproto.At
}
// SelectSelectionInputChecked sends a checked request.
-// If an error occurs, it can be retrieved using SelectSelectionInputCookie.Check()
+// If an error occurs, it can be retrieved using SelectSelectionInputCookie.Check.
func SelectSelectionInputChecked(c *xgb.Conn, Window xproto.Window, Selection xproto.Atom, EventMask uint32) SelectSelectionInputCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -2200,8 +2177,7 @@ func (cook SelectSelectionInputCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for SelectSelectionInput
-// selectSelectionInputRequest writes a SelectSelectionInput request to a byte slice.
+// selectSelectionInputRequest writes a SelectSelectionInput request to a byte slice for transfer.
func selectSelectionInputRequest(c *xgb.Conn, Window xproto.Window, Selection xproto.Atom, EventMask uint32) []byte {
size := 16
b := 0
@@ -2249,7 +2225,7 @@ func SetCursorName(c *xgb.Conn, Cursor xproto.Cursor, Nbytes uint16, Name string
}
// SetCursorNameChecked sends a checked request.
-// If an error occurs, it can be retrieved using SetCursorNameCookie.Check()
+// If an error occurs, it can be retrieved using SetCursorNameCookie.Check.
func SetCursorNameChecked(c *xgb.Conn, Cursor xproto.Cursor, Nbytes uint16, Name string) SetCursorNameCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -2267,8 +2243,7 @@ func (cook SetCursorNameCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for SetCursorName
-// setCursorNameRequest writes a SetCursorName request to a byte slice.
+// setCursorNameRequest writes a SetCursorName request to a byte slice for transfer.
func setCursorNameRequest(c *xgb.Conn, Cursor xproto.Cursor, Nbytes uint16, Name string) []byte {
size := xgb.Pad((12 + xgb.Pad((int(Nbytes) * 1))))
b := 0
@@ -2306,7 +2281,7 @@ type SetGCClipRegionCookie struct {
// SetGCClipRegion sends an unchecked request.
// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.
-func SetGCClipRegion(c *xgb.Conn, Gc xproto.Gcontext, Region Region, XOrigin int16, YOrigin int16) SetGCClipRegionCookie {
+func SetGCClipRegion(c *xgb.Conn, Gc xproto.Gcontext, Region Region, XOrigin, YOrigin int16) SetGCClipRegionCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XFIXES"]; !ok {
@@ -2318,8 +2293,8 @@ func SetGCClipRegion(c *xgb.Conn, Gc xproto.Gcontext, Region Region, XOrigin int
}
// SetGCClipRegionChecked sends a checked request.
-// If an error occurs, it can be retrieved using SetGCClipRegionCookie.Check()
-func SetGCClipRegionChecked(c *xgb.Conn, Gc xproto.Gcontext, Region Region, XOrigin int16, YOrigin int16) SetGCClipRegionCookie {
+// If an error occurs, it can be retrieved using SetGCClipRegionCookie.Check.
+func SetGCClipRegionChecked(c *xgb.Conn, Gc xproto.Gcontext, Region Region, XOrigin, YOrigin int16) SetGCClipRegionCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XFIXES"]; !ok {
@@ -2336,9 +2311,8 @@ func (cook SetGCClipRegionCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for SetGCClipRegion
-// setGCClipRegionRequest writes a SetGCClipRegion request to a byte slice.
-func setGCClipRegionRequest(c *xgb.Conn, Gc xproto.Gcontext, Region Region, XOrigin int16, YOrigin int16) []byte {
+// setGCClipRegionRequest writes a SetGCClipRegion request to a byte slice for transfer.
+func setGCClipRegionRequest(c *xgb.Conn, Gc xproto.Gcontext, Region Region, XOrigin, YOrigin int16) []byte {
size := 16
b := 0
buf := make([]byte, size)
@@ -2376,7 +2350,7 @@ type SetPictureClipRegionCookie struct {
// SetPictureClipRegion sends an unchecked request.
// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.
-func SetPictureClipRegion(c *xgb.Conn, Picture render.Picture, Region Region, XOrigin int16, YOrigin int16) SetPictureClipRegionCookie {
+func SetPictureClipRegion(c *xgb.Conn, Picture render.Picture, Region Region, XOrigin, YOrigin int16) SetPictureClipRegionCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XFIXES"]; !ok {
@@ -2388,8 +2362,8 @@ func SetPictureClipRegion(c *xgb.Conn, Picture render.Picture, Region Region, XO
}
// SetPictureClipRegionChecked sends a checked request.
-// If an error occurs, it can be retrieved using SetPictureClipRegionCookie.Check()
-func SetPictureClipRegionChecked(c *xgb.Conn, Picture render.Picture, Region Region, XOrigin int16, YOrigin int16) SetPictureClipRegionCookie {
+// If an error occurs, it can be retrieved using SetPictureClipRegionCookie.Check.
+func SetPictureClipRegionChecked(c *xgb.Conn, Picture render.Picture, Region Region, XOrigin, YOrigin int16) SetPictureClipRegionCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XFIXES"]; !ok {
@@ -2406,9 +2380,8 @@ func (cook SetPictureClipRegionCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for SetPictureClipRegion
-// setPictureClipRegionRequest writes a SetPictureClipRegion request to a byte slice.
-func setPictureClipRegionRequest(c *xgb.Conn, Picture render.Picture, Region Region, XOrigin int16, YOrigin int16) []byte {
+// setPictureClipRegionRequest writes a SetPictureClipRegion request to a byte slice for transfer.
+func setPictureClipRegionRequest(c *xgb.Conn, Picture render.Picture, Region Region, XOrigin, YOrigin int16) []byte {
size := 16
b := 0
buf := make([]byte, size)
@@ -2458,7 +2431,7 @@ func SetRegion(c *xgb.Conn, Region Region, Rectangles []xproto.Rectangle) SetReg
}
// SetRegionChecked sends a checked request.
-// If an error occurs, it can be retrieved using SetRegionCookie.Check()
+// If an error occurs, it can be retrieved using SetRegionCookie.Check.
func SetRegionChecked(c *xgb.Conn, Region Region, Rectangles []xproto.Rectangle) SetRegionCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -2476,8 +2449,7 @@ func (cook SetRegionCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for SetRegion
-// setRegionRequest writes a SetRegion request to a byte slice.
+// setRegionRequest writes a SetRegion request to a byte slice for transfer.
func setRegionRequest(c *xgb.Conn, Region Region, Rectangles []xproto.Rectangle) []byte {
size := xgb.Pad((8 + xgb.Pad((len(Rectangles) * 8))))
b := 0
@@ -2509,7 +2481,7 @@ type SetWindowShapeRegionCookie struct {
// SetWindowShapeRegion sends an unchecked request.
// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.
-func SetWindowShapeRegion(c *xgb.Conn, Dest xproto.Window, DestKind shape.Kind, XOffset int16, YOffset int16, Region Region) SetWindowShapeRegionCookie {
+func SetWindowShapeRegion(c *xgb.Conn, Dest xproto.Window, DestKind shape.Kind, XOffset, YOffset int16, Region Region) SetWindowShapeRegionCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XFIXES"]; !ok {
@@ -2521,8 +2493,8 @@ func SetWindowShapeRegion(c *xgb.Conn, Dest xproto.Window, DestKind shape.Kind,
}
// SetWindowShapeRegionChecked sends a checked request.
-// If an error occurs, it can be retrieved using SetWindowShapeRegionCookie.Check()
-func SetWindowShapeRegionChecked(c *xgb.Conn, Dest xproto.Window, DestKind shape.Kind, XOffset int16, YOffset int16, Region Region) SetWindowShapeRegionCookie {
+// If an error occurs, it can be retrieved using SetWindowShapeRegionCookie.Check.
+func SetWindowShapeRegionChecked(c *xgb.Conn, Dest xproto.Window, DestKind shape.Kind, XOffset, YOffset int16, Region Region) SetWindowShapeRegionCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XFIXES"]; !ok {
@@ -2539,9 +2511,8 @@ func (cook SetWindowShapeRegionCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for SetWindowShapeRegion
-// setWindowShapeRegionRequest writes a SetWindowShapeRegion request to a byte slice.
-func setWindowShapeRegionRequest(c *xgb.Conn, Dest xproto.Window, DestKind shape.Kind, XOffset int16, YOffset int16, Region Region) []byte {
+// setWindowShapeRegionRequest writes a SetWindowShapeRegion request to a byte slice for transfer.
+func setWindowShapeRegionRequest(c *xgb.Conn, Dest xproto.Window, DestKind shape.Kind, XOffset, YOffset int16, Region Region) []byte {
size := 20
b := 0
buf := make([]byte, size)
@@ -2596,7 +2567,7 @@ func ShowCursor(c *xgb.Conn, Window xproto.Window) ShowCursorCookie {
}
// ShowCursorChecked sends a checked request.
-// If an error occurs, it can be retrieved using ShowCursorCookie.Check()
+// If an error occurs, it can be retrieved using ShowCursorCookie.Check.
func ShowCursorChecked(c *xgb.Conn, Window xproto.Window) ShowCursorCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -2614,8 +2585,7 @@ func (cook ShowCursorCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for ShowCursor
-// showCursorRequest writes a ShowCursor request to a byte slice.
+// showCursorRequest writes a ShowCursor request to a byte slice for transfer.
func showCursorRequest(c *xgb.Conn, Window xproto.Window) []byte {
size := 8
b := 0
@@ -2645,7 +2615,7 @@ type SubtractRegionCookie struct {
// SubtractRegion sends an unchecked request.
// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.
-func SubtractRegion(c *xgb.Conn, Source1 Region, Source2 Region, Destination Region) SubtractRegionCookie {
+func SubtractRegion(c *xgb.Conn, Source1, Source2, Destination Region) SubtractRegionCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XFIXES"]; !ok {
@@ -2657,8 +2627,8 @@ func SubtractRegion(c *xgb.Conn, Source1 Region, Source2 Region, Destination Reg
}
// SubtractRegionChecked sends a checked request.
-// If an error occurs, it can be retrieved using SubtractRegionCookie.Check()
-func SubtractRegionChecked(c *xgb.Conn, Source1 Region, Source2 Region, Destination Region) SubtractRegionCookie {
+// If an error occurs, it can be retrieved using SubtractRegionCookie.Check.
+func SubtractRegionChecked(c *xgb.Conn, Source1, Source2, Destination Region) SubtractRegionCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XFIXES"]; !ok {
@@ -2675,9 +2645,8 @@ func (cook SubtractRegionCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for SubtractRegion
-// subtractRegionRequest writes a SubtractRegion request to a byte slice.
-func subtractRegionRequest(c *xgb.Conn, Source1 Region, Source2 Region, Destination Region) []byte {
+// subtractRegionRequest writes a SubtractRegion request to a byte slice for transfer.
+func subtractRegionRequest(c *xgb.Conn, Source1, Source2, Destination Region) []byte {
size := 16
b := 0
buf := make([]byte, size)
@@ -2712,7 +2681,7 @@ type TranslateRegionCookie struct {
// TranslateRegion sends an unchecked request.
// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.
-func TranslateRegion(c *xgb.Conn, Region Region, Dx int16, Dy int16) TranslateRegionCookie {
+func TranslateRegion(c *xgb.Conn, Region Region, Dx, Dy int16) TranslateRegionCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XFIXES"]; !ok {
@@ -2724,8 +2693,8 @@ func TranslateRegion(c *xgb.Conn, Region Region, Dx int16, Dy int16) TranslateRe
}
// TranslateRegionChecked sends a checked request.
-// If an error occurs, it can be retrieved using TranslateRegionCookie.Check()
-func TranslateRegionChecked(c *xgb.Conn, Region Region, Dx int16, Dy int16) TranslateRegionCookie {
+// If an error occurs, it can be retrieved using TranslateRegionCookie.Check.
+func TranslateRegionChecked(c *xgb.Conn, Region Region, Dx, Dy int16) TranslateRegionCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XFIXES"]; !ok {
@@ -2742,9 +2711,8 @@ func (cook TranslateRegionCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for TranslateRegion
-// translateRegionRequest writes a TranslateRegion request to a byte slice.
-func translateRegionRequest(c *xgb.Conn, Region Region, Dx int16, Dy int16) []byte {
+// translateRegionRequest writes a TranslateRegion request to a byte slice for transfer.
+func translateRegionRequest(c *xgb.Conn, Region Region, Dx, Dy int16) []byte {
size := 12
b := 0
buf := make([]byte, size)
@@ -2779,7 +2747,7 @@ type UnionRegionCookie struct {
// UnionRegion sends an unchecked request.
// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.
-func UnionRegion(c *xgb.Conn, Source1 Region, Source2 Region, Destination Region) UnionRegionCookie {
+func UnionRegion(c *xgb.Conn, Source1, Source2, Destination Region) UnionRegionCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XFIXES"]; !ok {
@@ -2791,8 +2759,8 @@ func UnionRegion(c *xgb.Conn, Source1 Region, Source2 Region, Destination Region
}
// UnionRegionChecked sends a checked request.
-// If an error occurs, it can be retrieved using UnionRegionCookie.Check()
-func UnionRegionChecked(c *xgb.Conn, Source1 Region, Source2 Region, Destination Region) UnionRegionCookie {
+// If an error occurs, it can be retrieved using UnionRegionCookie.Check.
+func UnionRegionChecked(c *xgb.Conn, Source1, Source2, Destination Region) UnionRegionCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XFIXES"]; !ok {
@@ -2809,9 +2777,8 @@ func (cook UnionRegionCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for UnionRegion
-// unionRegionRequest writes a UnionRegion request to a byte slice.
-func unionRegionRequest(c *xgb.Conn, Source1 Region, Source2 Region, Destination Region) []byte {
+// unionRegionRequest writes a UnionRegion request to a byte slice for transfer.
+func unionRegionRequest(c *xgb.Conn, Source1, Source2, Destination Region) []byte {
size := 16
b := 0
buf := make([]byte, size)