aboutsummaryrefslogtreecommitdiff
path: root/nexgb/xprint/xprint.go
diff options
context:
space:
mode:
Diffstat (limited to 'nexgb/xprint/xprint.go')
-rw-r--r--nexgb/xprint/xprint.go149
1 files changed, 62 insertions, 87 deletions
diff --git a/nexgb/xprint/xprint.go b/nexgb/xprint/xprint.go
index 7d7d3e4..7b4da5b 100644
--- a/nexgb/xprint/xprint.go
+++ b/nexgb/xprint/xprint.go
@@ -451,7 +451,7 @@ type CreateContextCookie struct {
// CreateContext sends an unchecked request.
// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.
-func CreateContext(c *xgb.Conn, ContextId uint32, PrinterNameLen uint32, LocaleLen uint32, PrinterName []String8, Locale []String8) CreateContextCookie {
+func CreateContext(c *xgb.Conn, ContextId, PrinterNameLen, LocaleLen uint32, PrinterName, Locale []String8) CreateContextCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XpExtension"]; !ok {
@@ -463,8 +463,8 @@ func CreateContext(c *xgb.Conn, ContextId uint32, PrinterNameLen uint32, LocaleL
}
// CreateContextChecked sends a checked request.
-// If an error occurs, it can be retrieved using CreateContextCookie.Check()
-func CreateContextChecked(c *xgb.Conn, ContextId uint32, PrinterNameLen uint32, LocaleLen uint32, PrinterName []String8, Locale []String8) CreateContextCookie {
+// If an error occurs, it can be retrieved using CreateContextCookie.Check.
+func CreateContextChecked(c *xgb.Conn, ContextId, PrinterNameLen, LocaleLen uint32, PrinterName, Locale []String8) CreateContextCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XpExtension"]; !ok {
@@ -481,9 +481,8 @@ func (cook CreateContextCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for CreateContext
-// createContextRequest writes a CreateContext request to a byte slice.
-func createContextRequest(c *xgb.Conn, ContextId uint32, PrinterNameLen uint32, LocaleLen uint32, PrinterName []String8, Locale []String8) []byte {
+// createContextRequest writes a CreateContext request to a byte slice for transfer.
+func createContextRequest(c *xgb.Conn, ContextId, PrinterNameLen, LocaleLen uint32, PrinterName, Locale []String8) []byte {
size := xgb.Pad(((16 + xgb.Pad((int(PrinterNameLen) * 1))) + xgb.Pad((int(LocaleLen) * 1))))
b := 0
buf := make([]byte, size)
@@ -540,7 +539,7 @@ func PrintDestroyContext(c *xgb.Conn, Context uint32) PrintDestroyContextCookie
}
// PrintDestroyContextChecked sends a checked request.
-// If an error occurs, it can be retrieved using PrintDestroyContextCookie.Check()
+// If an error occurs, it can be retrieved using PrintDestroyContextCookie.Check.
func PrintDestroyContextChecked(c *xgb.Conn, Context uint32) PrintDestroyContextCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -558,8 +557,7 @@ func (cook PrintDestroyContextCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for PrintDestroyContext
-// printDestroyContextRequest writes a PrintDestroyContext request to a byte slice.
+// printDestroyContextRequest writes a PrintDestroyContext request to a byte slice for transfer.
func printDestroyContextRequest(c *xgb.Conn, Context uint32) []byte {
size := 8
b := 0
@@ -601,7 +599,7 @@ func PrintEndDoc(c *xgb.Conn, Cancel bool) PrintEndDocCookie {
}
// PrintEndDocChecked sends a checked request.
-// If an error occurs, it can be retrieved using PrintEndDocCookie.Check()
+// If an error occurs, it can be retrieved using PrintEndDocCookie.Check.
func PrintEndDocChecked(c *xgb.Conn, Cancel bool) PrintEndDocCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -619,8 +617,7 @@ func (cook PrintEndDocCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for PrintEndDoc
-// printEndDocRequest writes a PrintEndDoc request to a byte slice.
+// printEndDocRequest writes a PrintEndDoc request to a byte slice for transfer.
func printEndDocRequest(c *xgb.Conn, Cancel bool) []byte {
size := 8
b := 0
@@ -666,7 +663,7 @@ func PrintEndJob(c *xgb.Conn, Cancel bool) PrintEndJobCookie {
}
// PrintEndJobChecked sends a checked request.
-// If an error occurs, it can be retrieved using PrintEndJobCookie.Check()
+// If an error occurs, it can be retrieved using PrintEndJobCookie.Check.
func PrintEndJobChecked(c *xgb.Conn, Cancel bool) PrintEndJobCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -684,8 +681,7 @@ func (cook PrintEndJobCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for PrintEndJob
-// printEndJobRequest writes a PrintEndJob request to a byte slice.
+// printEndJobRequest writes a PrintEndJob request to a byte slice for transfer.
func printEndJobRequest(c *xgb.Conn, Cancel bool) []byte {
size := 8
b := 0
@@ -731,7 +727,7 @@ func PrintEndPage(c *xgb.Conn, Cancel bool) PrintEndPageCookie {
}
// PrintEndPageChecked sends a checked request.
-// If an error occurs, it can be retrieved using PrintEndPageCookie.Check()
+// If an error occurs, it can be retrieved using PrintEndPageCookie.Check.
func PrintEndPageChecked(c *xgb.Conn, Cancel bool) PrintEndPageCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -749,8 +745,7 @@ func (cook PrintEndPageCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for PrintEndPage
-// printEndPageRequest writes a PrintEndPage request to a byte slice.
+// printEndPageRequest writes a PrintEndPage request to a byte slice for transfer.
func printEndPageRequest(c *xgb.Conn, Cancel bool) []byte {
size := 8
b := 0
@@ -785,7 +780,7 @@ type PrintGetAttributesCookie struct {
}
// PrintGetAttributes sends a checked request.
-// If an error occurs, it will be returned with the reply by calling PrintGetAttributesCookie.Reply()
+// If an error occurs, it will be returned with the reply by calling PrintGetAttributesCookie.Reply.
func PrintGetAttributes(c *xgb.Conn, Context Pcontext, Pool byte) PrintGetAttributesCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -859,8 +854,7 @@ func printGetAttributesReply(buf []byte) *PrintGetAttributesReply {
return v
}
-// Write request to wire for PrintGetAttributes
-// printGetAttributesRequest writes a PrintGetAttributes request to a byte slice.
+// printGetAttributesRequest writes a PrintGetAttributes request to a byte slice for transfer.
func printGetAttributesRequest(c *xgb.Conn, Context Pcontext, Pool byte) []byte {
size := 12
b := 0
@@ -894,7 +888,7 @@ type PrintGetContextCookie struct {
}
// PrintGetContext sends a checked request.
-// If an error occurs, it will be returned with the reply by calling PrintGetContextCookie.Reply()
+// If an error occurs, it will be returned with the reply by calling PrintGetContextCookie.Reply.
func PrintGetContext(c *xgb.Conn) PrintGetContextCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -958,8 +952,7 @@ func printGetContextReply(buf []byte) *PrintGetContextReply {
return v
}
-// Write request to wire for PrintGetContext
-// printGetContextRequest writes a PrintGetContext request to a byte slice.
+// printGetContextRequest writes a PrintGetContext request to a byte slice for transfer.
func printGetContextRequest(c *xgb.Conn) []byte {
size := 4
b := 0
@@ -985,7 +978,7 @@ type PrintGetDocumentDataCookie struct {
}
// PrintGetDocumentData sends a checked request.
-// If an error occurs, it will be returned with the reply by calling PrintGetDocumentDataCookie.Reply()
+// If an error occurs, it will be returned with the reply by calling PrintGetDocumentDataCookie.Reply.
func PrintGetDocumentData(c *xgb.Conn, Context Pcontext, MaxBytes uint32) PrintGetDocumentDataCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -1065,8 +1058,7 @@ func printGetDocumentDataReply(buf []byte) *PrintGetDocumentDataReply {
return v
}
-// Write request to wire for PrintGetDocumentData
-// printGetDocumentDataRequest writes a PrintGetDocumentData request to a byte slice.
+// printGetDocumentDataRequest writes a PrintGetDocumentData request to a byte slice for transfer.
func printGetDocumentDataRequest(c *xgb.Conn, Context Pcontext, MaxBytes uint32) []byte {
size := 12
b := 0
@@ -1098,7 +1090,7 @@ type PrintGetImageResolutionCookie struct {
}
// PrintGetImageResolution sends a checked request.
-// If an error occurs, it will be returned with the reply by calling PrintGetImageResolutionCookie.Reply()
+// If an error occurs, it will be returned with the reply by calling PrintGetImageResolutionCookie.Reply.
func PrintGetImageResolution(c *xgb.Conn, Context Pcontext) PrintGetImageResolutionCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -1162,8 +1154,7 @@ func printGetImageResolutionReply(buf []byte) *PrintGetImageResolutionReply {
return v
}
-// Write request to wire for PrintGetImageResolution
-// printGetImageResolutionRequest writes a PrintGetImageResolution request to a byte slice.
+// printGetImageResolutionRequest writes a PrintGetImageResolution request to a byte slice for transfer.
func printGetImageResolutionRequest(c *xgb.Conn, Context Pcontext) []byte {
size := 8
b := 0
@@ -1192,7 +1183,7 @@ type PrintGetOneAttributesCookie struct {
}
// PrintGetOneAttributes sends a checked request.
-// If an error occurs, it will be returned with the reply by calling PrintGetOneAttributesCookie.Reply()
+// If an error occurs, it will be returned with the reply by calling PrintGetOneAttributesCookie.Reply.
func PrintGetOneAttributes(c *xgb.Conn, Context Pcontext, NameLen uint32, Pool byte, Name []String8) PrintGetOneAttributesCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -1266,8 +1257,7 @@ func printGetOneAttributesReply(buf []byte) *PrintGetOneAttributesReply {
return v
}
-// Write request to wire for PrintGetOneAttributes
-// printGetOneAttributesRequest writes a PrintGetOneAttributes request to a byte slice.
+// printGetOneAttributesRequest writes a PrintGetOneAttributes request to a byte slice for transfer.
func printGetOneAttributesRequest(c *xgb.Conn, Context Pcontext, NameLen uint32, Pool byte, Name []String8) []byte {
size := xgb.Pad((16 + xgb.Pad((int(NameLen) * 1))))
b := 0
@@ -1309,7 +1299,7 @@ type PrintGetPageDimensionsCookie struct {
}
// PrintGetPageDimensions sends a checked request.
-// If an error occurs, it will be returned with the reply by calling PrintGetPageDimensionsCookie.Reply()
+// If an error occurs, it will be returned with the reply by calling PrintGetPageDimensionsCookie.Reply.
func PrintGetPageDimensions(c *xgb.Conn, Context Pcontext) PrintGetPageDimensionsCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -1393,8 +1383,7 @@ func printGetPageDimensionsReply(buf []byte) *PrintGetPageDimensionsReply {
return v
}
-// Write request to wire for PrintGetPageDimensions
-// printGetPageDimensionsRequest writes a PrintGetPageDimensions request to a byte slice.
+// printGetPageDimensionsRequest writes a PrintGetPageDimensions request to a byte slice for transfer.
func printGetPageDimensionsRequest(c *xgb.Conn, Context Pcontext) []byte {
size := 8
b := 0
@@ -1423,8 +1412,8 @@ type PrintGetPrinterListCookie struct {
}
// PrintGetPrinterList sends a checked request.
-// If an error occurs, it will be returned with the reply by calling PrintGetPrinterListCookie.Reply()
-func PrintGetPrinterList(c *xgb.Conn, PrinterNameLen uint32, LocaleLen uint32, PrinterName []String8, Locale []String8) PrintGetPrinterListCookie {
+// If an error occurs, it will be returned with the reply by calling PrintGetPrinterListCookie.Reply.
+func PrintGetPrinterList(c *xgb.Conn, PrinterNameLen, LocaleLen uint32, PrinterName, Locale []String8) PrintGetPrinterListCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XpExtension"]; !ok {
@@ -1437,7 +1426,7 @@ func PrintGetPrinterList(c *xgb.Conn, PrinterNameLen uint32, LocaleLen uint32, P
// PrintGetPrinterListUnchecked sends an unchecked request.
// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.
-func PrintGetPrinterListUnchecked(c *xgb.Conn, PrinterNameLen uint32, LocaleLen uint32, PrinterName []String8, Locale []String8) PrintGetPrinterListCookie {
+func PrintGetPrinterListUnchecked(c *xgb.Conn, PrinterNameLen, LocaleLen uint32, PrinterName, Locale []String8) PrintGetPrinterListCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XpExtension"]; !ok {
@@ -1494,9 +1483,8 @@ func printGetPrinterListReply(buf []byte) *PrintGetPrinterListReply {
return v
}
-// Write request to wire for PrintGetPrinterList
-// printGetPrinterListRequest writes a PrintGetPrinterList request to a byte slice.
-func printGetPrinterListRequest(c *xgb.Conn, PrinterNameLen uint32, LocaleLen uint32, PrinterName []String8, Locale []String8) []byte {
+// printGetPrinterListRequest writes a PrintGetPrinterList request to a byte slice for transfer.
+func printGetPrinterListRequest(c *xgb.Conn, PrinterNameLen, LocaleLen uint32, PrinterName, Locale []String8) []byte {
size := xgb.Pad(((12 + xgb.Pad((int(PrinterNameLen) * 1))) + xgb.Pad((int(LocaleLen) * 1))))
b := 0
buf := make([]byte, size)
@@ -1537,7 +1525,7 @@ type PrintGetScreenOfContextCookie struct {
}
// PrintGetScreenOfContext sends a checked request.
-// If an error occurs, it will be returned with the reply by calling PrintGetScreenOfContextCookie.Reply()
+// If an error occurs, it will be returned with the reply by calling PrintGetScreenOfContextCookie.Reply.
func PrintGetScreenOfContext(c *xgb.Conn) PrintGetScreenOfContextCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -1601,8 +1589,7 @@ func printGetScreenOfContextReply(buf []byte) *PrintGetScreenOfContextReply {
return v
}
-// Write request to wire for PrintGetScreenOfContext
-// printGetScreenOfContextRequest writes a PrintGetScreenOfContext request to a byte slice.
+// printGetScreenOfContextRequest writes a PrintGetScreenOfContext request to a byte slice for transfer.
func printGetScreenOfContextRequest(c *xgb.Conn) []byte {
size := 4
b := 0
@@ -1628,7 +1615,7 @@ type PrintInputSelectedCookie struct {
}
// PrintInputSelected sends a checked request.
-// If an error occurs, it will be returned with the reply by calling PrintInputSelectedCookie.Reply()
+// If an error occurs, it will be returned with the reply by calling PrintInputSelectedCookie.Reply.
func PrintInputSelected(c *xgb.Conn, Context Pcontext) PrintInputSelectedCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -1696,8 +1683,7 @@ func printInputSelectedReply(buf []byte) *PrintInputSelectedReply {
return v
}
-// Write request to wire for PrintInputSelected
-// printInputSelectedRequest writes a PrintInputSelected request to a byte slice.
+// printInputSelectedRequest writes a PrintInputSelected request to a byte slice for transfer.
func printInputSelectedRequest(c *xgb.Conn, Context Pcontext) []byte {
size := 8
b := 0
@@ -1727,7 +1713,7 @@ type PrintPutDocumentDataCookie struct {
// PrintPutDocumentData sends an unchecked request.
// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.
-func PrintPutDocumentData(c *xgb.Conn, Drawable xproto.Drawable, LenData uint32, LenFmt uint16, LenOptions uint16, Data []byte, DocFormat []String8, Options []String8) PrintPutDocumentDataCookie {
+func PrintPutDocumentData(c *xgb.Conn, Drawable xproto.Drawable, LenData uint32, LenFmt, LenOptions uint16, Data []byte, DocFormat, Options []String8) PrintPutDocumentDataCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XpExtension"]; !ok {
@@ -1739,8 +1725,8 @@ func PrintPutDocumentData(c *xgb.Conn, Drawable xproto.Drawable, LenData uint32,
}
// PrintPutDocumentDataChecked sends a checked request.
-// If an error occurs, it can be retrieved using PrintPutDocumentDataCookie.Check()
-func PrintPutDocumentDataChecked(c *xgb.Conn, Drawable xproto.Drawable, LenData uint32, LenFmt uint16, LenOptions uint16, Data []byte, DocFormat []String8, Options []String8) PrintPutDocumentDataCookie {
+// If an error occurs, it can be retrieved using PrintPutDocumentDataCookie.Check.
+func PrintPutDocumentDataChecked(c *xgb.Conn, Drawable xproto.Drawable, LenData uint32, LenFmt, LenOptions uint16, Data []byte, DocFormat, Options []String8) PrintPutDocumentDataCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XpExtension"]; !ok {
@@ -1757,9 +1743,8 @@ func (cook PrintPutDocumentDataCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for PrintPutDocumentData
-// printPutDocumentDataRequest writes a PrintPutDocumentData request to a byte slice.
-func printPutDocumentDataRequest(c *xgb.Conn, Drawable xproto.Drawable, LenData uint32, LenFmt uint16, LenOptions uint16, Data []byte, DocFormat []String8, Options []String8) []byte {
+// printPutDocumentDataRequest writes a PrintPutDocumentData request to a byte slice for transfer.
+func printPutDocumentDataRequest(c *xgb.Conn, Drawable xproto.Drawable, LenData uint32, LenFmt, LenOptions uint16, Data []byte, DocFormat, Options []String8) []byte {
size := xgb.Pad((((16 + xgb.Pad((int(LenData) * 1))) + xgb.Pad((int(LenFmt) * 1))) + xgb.Pad((int(LenOptions) * 1))))
b := 0
buf := make([]byte, size)
@@ -1809,7 +1794,7 @@ type PrintQueryScreensCookie struct {
}
// PrintQueryScreens sends a checked request.
-// If an error occurs, it will be returned with the reply by calling PrintQueryScreensCookie.Reply()
+// If an error occurs, it will be returned with the reply by calling PrintQueryScreensCookie.Reply.
func PrintQueryScreens(c *xgb.Conn) PrintQueryScreensCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -1883,8 +1868,7 @@ func printQueryScreensReply(buf []byte) *PrintQueryScreensReply {
return v
}
-// Write request to wire for PrintQueryScreens
-// printQueryScreensRequest writes a PrintQueryScreens request to a byte slice.
+// printQueryScreensRequest writes a PrintQueryScreens request to a byte slice for transfer.
func printQueryScreensRequest(c *xgb.Conn) []byte {
size := 4
b := 0
@@ -1910,7 +1894,7 @@ type PrintQueryVersionCookie struct {
}
// PrintQueryVersion sends a checked request.
-// If an error occurs, it will be returned with the reply by calling PrintQueryVersionCookie.Reply()
+// If an error occurs, it will be returned with the reply by calling PrintQueryVersionCookie.Reply.
func PrintQueryVersion(c *xgb.Conn) PrintQueryVersionCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -1978,8 +1962,7 @@ func printQueryVersionReply(buf []byte) *PrintQueryVersionReply {
return v
}
-// Write request to wire for PrintQueryVersion
-// printQueryVersionRequest writes a PrintQueryVersion request to a byte slice.
+// printQueryVersionRequest writes a PrintQueryVersion request to a byte slice for transfer.
func printQueryVersionRequest(c *xgb.Conn) []byte {
size := 4
b := 0
@@ -2018,7 +2001,7 @@ func PrintRehashPrinterList(c *xgb.Conn) PrintRehashPrinterListCookie {
}
// PrintRehashPrinterListChecked sends a checked request.
-// If an error occurs, it can be retrieved using PrintRehashPrinterListCookie.Check()
+// If an error occurs, it can be retrieved using PrintRehashPrinterListCookie.Check.
func PrintRehashPrinterListChecked(c *xgb.Conn) PrintRehashPrinterListCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -2036,8 +2019,7 @@ func (cook PrintRehashPrinterListCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for PrintRehashPrinterList
-// printRehashPrinterListRequest writes a PrintRehashPrinterList request to a byte slice.
+// printRehashPrinterListRequest writes a PrintRehashPrinterList request to a byte slice for transfer.
func printRehashPrinterListRequest(c *xgb.Conn) []byte {
size := 4
b := 0
@@ -2076,7 +2058,7 @@ func PrintSelectInput(c *xgb.Conn, Context Pcontext, EventMask uint32) PrintSele
}
// PrintSelectInputChecked sends a checked request.
-// If an error occurs, it can be retrieved using PrintSelectInputCookie.Check()
+// If an error occurs, it can be retrieved using PrintSelectInputCookie.Check.
func PrintSelectInputChecked(c *xgb.Conn, Context Pcontext, EventMask uint32) PrintSelectInputCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -2094,8 +2076,7 @@ func (cook PrintSelectInputCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for PrintSelectInput
-// printSelectInputRequest writes a PrintSelectInput request to a byte slice.
+// printSelectInputRequest writes a PrintSelectInput request to a byte slice for transfer.
func printSelectInputRequest(c *xgb.Conn, Context Pcontext, EventMask uint32) []byte {
size := 12
b := 0
@@ -2128,7 +2109,7 @@ type PrintSetAttributesCookie struct {
// PrintSetAttributes sends an unchecked request.
// If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.
-func PrintSetAttributes(c *xgb.Conn, Context Pcontext, StringLen uint32, Pool byte, Rule byte, Attributes []String8) PrintSetAttributesCookie {
+func PrintSetAttributes(c *xgb.Conn, Context Pcontext, StringLen uint32, Pool, Rule byte, Attributes []String8) PrintSetAttributesCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XpExtension"]; !ok {
@@ -2140,8 +2121,8 @@ func PrintSetAttributes(c *xgb.Conn, Context Pcontext, StringLen uint32, Pool by
}
// PrintSetAttributesChecked sends a checked request.
-// If an error occurs, it can be retrieved using PrintSetAttributesCookie.Check()
-func PrintSetAttributesChecked(c *xgb.Conn, Context Pcontext, StringLen uint32, Pool byte, Rule byte, Attributes []String8) PrintSetAttributesCookie {
+// If an error occurs, it can be retrieved using PrintSetAttributesCookie.Check.
+func PrintSetAttributesChecked(c *xgb.Conn, Context Pcontext, StringLen uint32, Pool, Rule byte, Attributes []String8) PrintSetAttributesCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
if _, ok := c.Extensions["XpExtension"]; !ok {
@@ -2158,9 +2139,8 @@ func (cook PrintSetAttributesCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for PrintSetAttributes
-// printSetAttributesRequest writes a PrintSetAttributes request to a byte slice.
-func printSetAttributesRequest(c *xgb.Conn, Context Pcontext, StringLen uint32, Pool byte, Rule byte, Attributes []String8) []byte {
+// printSetAttributesRequest writes a PrintSetAttributes request to a byte slice for transfer.
+func printSetAttributesRequest(c *xgb.Conn, Context Pcontext, StringLen uint32, Pool, Rule byte, Attributes []String8) []byte {
size := xgb.Pad((16 + xgb.Pad((len(Attributes) * 1))))
b := 0
buf := make([]byte, size)
@@ -2217,7 +2197,7 @@ func PrintSetContext(c *xgb.Conn, Context uint32) PrintSetContextCookie {
}
// PrintSetContextChecked sends a checked request.
-// If an error occurs, it can be retrieved using PrintSetContextCookie.Check()
+// If an error occurs, it can be retrieved using PrintSetContextCookie.Check.
func PrintSetContextChecked(c *xgb.Conn, Context uint32) PrintSetContextCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -2235,8 +2215,7 @@ func (cook PrintSetContextCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for PrintSetContext
-// printSetContextRequest writes a PrintSetContext request to a byte slice.
+// printSetContextRequest writes a PrintSetContext request to a byte slice for transfer.
func printSetContextRequest(c *xgb.Conn, Context uint32) []byte {
size := 8
b := 0
@@ -2265,7 +2244,7 @@ type PrintSetImageResolutionCookie struct {
}
// PrintSetImageResolution sends a checked request.
-// If an error occurs, it will be returned with the reply by calling PrintSetImageResolutionCookie.Reply()
+// If an error occurs, it will be returned with the reply by calling PrintSetImageResolutionCookie.Reply.
func PrintSetImageResolution(c *xgb.Conn, Context Pcontext, ImageResolution uint16) PrintSetImageResolutionCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -2334,8 +2313,7 @@ func printSetImageResolutionReply(buf []byte) *PrintSetImageResolutionReply {
return v
}
-// Write request to wire for PrintSetImageResolution
-// printSetImageResolutionRequest writes a PrintSetImageResolution request to a byte slice.
+// printSetImageResolutionRequest writes a PrintSetImageResolution request to a byte slice for transfer.
func printSetImageResolutionRequest(c *xgb.Conn, Context Pcontext, ImageResolution uint16) []byte {
size := 12
b := 0
@@ -2380,7 +2358,7 @@ func PrintStartDoc(c *xgb.Conn, DriverMode byte) PrintStartDocCookie {
}
// PrintStartDocChecked sends a checked request.
-// If an error occurs, it can be retrieved using PrintStartDocCookie.Check()
+// If an error occurs, it can be retrieved using PrintStartDocCookie.Check.
func PrintStartDocChecked(c *xgb.Conn, DriverMode byte) PrintStartDocCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -2398,8 +2376,7 @@ func (cook PrintStartDocCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for PrintStartDoc
-// printStartDocRequest writes a PrintStartDoc request to a byte slice.
+// printStartDocRequest writes a PrintStartDoc request to a byte slice for transfer.
func printStartDocRequest(c *xgb.Conn, DriverMode byte) []byte {
size := 8
b := 0
@@ -2441,7 +2418,7 @@ func PrintStartJob(c *xgb.Conn, OutputMode byte) PrintStartJobCookie {
}
// PrintStartJobChecked sends a checked request.
-// If an error occurs, it can be retrieved using PrintStartJobCookie.Check()
+// If an error occurs, it can be retrieved using PrintStartJobCookie.Check.
func PrintStartJobChecked(c *xgb.Conn, OutputMode byte) PrintStartJobCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -2459,8 +2436,7 @@ func (cook PrintStartJobCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for PrintStartJob
-// printStartJobRequest writes a PrintStartJob request to a byte slice.
+// printStartJobRequest writes a PrintStartJob request to a byte slice for transfer.
func printStartJobRequest(c *xgb.Conn, OutputMode byte) []byte {
size := 8
b := 0
@@ -2502,7 +2478,7 @@ func PrintStartPage(c *xgb.Conn, Window xproto.Window) PrintStartPageCookie {
}
// PrintStartPageChecked sends a checked request.
-// If an error occurs, it can be retrieved using PrintStartPageCookie.Check()
+// If an error occurs, it can be retrieved using PrintStartPageCookie.Check.
func PrintStartPageChecked(c *xgb.Conn, Window xproto.Window) PrintStartPageCookie {
c.ExtLock.RLock()
defer c.ExtLock.RUnlock()
@@ -2520,8 +2496,7 @@ func (cook PrintStartPageCookie) Check() error {
return cook.Cookie.Check()
}
-// Write request to wire for PrintStartPage
-// printStartPageRequest writes a PrintStartPage request to a byte slice.
+// printStartPageRequest writes a PrintStartPage request to a byte slice for transfer.
func printStartPageRequest(c *xgb.Conn, Window xproto.Window) []byte {
size := 8
b := 0