...

Package xf86vidmode

import "github.com/jezek/xgb/xf86vidmode"
Overview
Index

Overview ▾

Package xf86vidmode is the X client API for the XFree86-VidModeExtension extension.

Index ▾

Constants
func BadClockErrorNew(buf []byte) xgb.Error
func BadHTimingsErrorNew(buf []byte) xgb.Error
func BadVTimingsErrorNew(buf []byte) xgb.Error
func ClientNotLocalErrorNew(buf []byte) xgb.Error
func ExtensionDisabledErrorNew(buf []byte) xgb.Error
func Init(c *xgb.Conn) error
func ModeInfoListBytes(buf []byte, list []ModeInfo) int
func ModeInfoRead(buf []byte, v *ModeInfo) int
func ModeInfoReadList(buf []byte, dest []ModeInfo) int
func ModeUnsuitableErrorNew(buf []byte) xgb.Error
func ZoomLockedErrorNew(buf []byte) xgb.Error
type AddModeLineCookie
    func AddModeLine(c *xgb.Conn, Screen uint32, Dotclock Dotclock, Hdisplay uint16, Hsyncstart uint16, Hsyncend uint16, Htotal uint16, Hskew uint16, Vdisplay uint16, Vsyncstart uint16, Vsyncend uint16, Vtotal uint16, Flags uint32, Privsize uint32, AfterDotclock Dotclock, AfterHdisplay uint16, AfterHsyncstart uint16, AfterHsyncend uint16, AfterHtotal uint16, AfterHskew uint16, AfterVdisplay uint16, AfterVsyncstart uint16, AfterVsyncend uint16, AfterVtotal uint16, AfterFlags uint32, Private []byte) AddModeLineCookie
    func AddModeLineChecked(c *xgb.Conn, Screen uint32, Dotclock Dotclock, Hdisplay uint16, Hsyncstart uint16, Hsyncend uint16, Htotal uint16, Hskew uint16, Vdisplay uint16, Vsyncstart uint16, Vsyncend uint16, Vtotal uint16, Flags uint32, Privsize uint32, AfterDotclock Dotclock, AfterHdisplay uint16, AfterHsyncstart uint16, AfterHsyncend uint16, AfterHtotal uint16, AfterHskew uint16, AfterVdisplay uint16, AfterVsyncstart uint16, AfterVsyncend uint16, AfterVtotal uint16, AfterFlags uint32, Private []byte) AddModeLineCookie
    func (cook AddModeLineCookie) Check() error
type BadClockError
    func (err BadClockError) BadId() uint32
    func (err BadClockError) Error() string
    func (err BadClockError) SequenceId() uint16
type BadHTimingsError
    func (err BadHTimingsError) BadId() uint32
    func (err BadHTimingsError) Error() string
    func (err BadHTimingsError) SequenceId() uint16
type BadVTimingsError
    func (err BadVTimingsError) BadId() uint32
    func (err BadVTimingsError) Error() string
    func (err BadVTimingsError) SequenceId() uint16
type ClientNotLocalError
    func (err ClientNotLocalError) BadId() uint32
    func (err ClientNotLocalError) Error() string
    func (err ClientNotLocalError) SequenceId() uint16
type DeleteModeLineCookie
    func DeleteModeLine(c *xgb.Conn, Screen uint32, Dotclock Dotclock, Hdisplay uint16, Hsyncstart uint16, Hsyncend uint16, Htotal uint16, Hskew uint16, Vdisplay uint16, Vsyncstart uint16, Vsyncend uint16, Vtotal uint16, Flags uint32, Privsize uint32, Private []byte) DeleteModeLineCookie
    func DeleteModeLineChecked(c *xgb.Conn, Screen uint32, Dotclock Dotclock, Hdisplay uint16, Hsyncstart uint16, Hsyncend uint16, Htotal uint16, Hskew uint16, Vdisplay uint16, Vsyncstart uint16, Vsyncend uint16, Vtotal uint16, Flags uint32, Privsize uint32, Private []byte) DeleteModeLineCookie
    func (cook DeleteModeLineCookie) Check() error
type Dotclock
type ExtensionDisabledError
    func (err ExtensionDisabledError) BadId() uint32
    func (err ExtensionDisabledError) Error() string
    func (err ExtensionDisabledError) SequenceId() uint16
type GetAllModeLinesCookie
    func GetAllModeLines(c *xgb.Conn, Screen uint16) GetAllModeLinesCookie
    func GetAllModeLinesUnchecked(c *xgb.Conn, Screen uint16) GetAllModeLinesCookie
    func (cook GetAllModeLinesCookie) Reply() (*GetAllModeLinesReply, error)
type GetAllModeLinesReply
type GetDotClocksCookie
    func GetDotClocks(c *xgb.Conn, Screen uint16) GetDotClocksCookie
    func GetDotClocksUnchecked(c *xgb.Conn, Screen uint16) GetDotClocksCookie
    func (cook GetDotClocksCookie) Reply() (*GetDotClocksReply, error)
type GetDotClocksReply
type GetGammaCookie
    func GetGamma(c *xgb.Conn, Screen uint16) GetGammaCookie
    func GetGammaUnchecked(c *xgb.Conn, Screen uint16) GetGammaCookie
    func (cook GetGammaCookie) Reply() (*GetGammaReply, error)
type GetGammaRampCookie
    func GetGammaRamp(c *xgb.Conn, Screen uint16, Size uint16) GetGammaRampCookie
    func GetGammaRampUnchecked(c *xgb.Conn, Screen uint16, Size uint16) GetGammaRampCookie
    func (cook GetGammaRampCookie) Reply() (*GetGammaRampReply, error)
type GetGammaRampReply
type GetGammaRampSizeCookie
    func GetGammaRampSize(c *xgb.Conn, Screen uint16) GetGammaRampSizeCookie
    func GetGammaRampSizeUnchecked(c *xgb.Conn, Screen uint16) GetGammaRampSizeCookie
    func (cook GetGammaRampSizeCookie) Reply() (*GetGammaRampSizeReply, error)
type GetGammaRampSizeReply
type GetGammaReply
type GetModeLineCookie
    func GetModeLine(c *xgb.Conn, Screen uint16) GetModeLineCookie
    func GetModeLineUnchecked(c *xgb.Conn, Screen uint16) GetModeLineCookie
    func (cook GetModeLineCookie) Reply() (*GetModeLineReply, error)
type GetModeLineReply
type GetMonitorCookie
    func GetMonitor(c *xgb.Conn, Screen uint16) GetMonitorCookie
    func GetMonitorUnchecked(c *xgb.Conn, Screen uint16) GetMonitorCookie
    func (cook GetMonitorCookie) Reply() (*GetMonitorReply, error)
type GetMonitorReply
type GetPermissionsCookie
    func GetPermissions(c *xgb.Conn, Screen uint16) GetPermissionsCookie
    func GetPermissionsUnchecked(c *xgb.Conn, Screen uint16) GetPermissionsCookie
    func (cook GetPermissionsCookie) Reply() (*GetPermissionsReply, error)
type GetPermissionsReply
type GetViewPortCookie
    func GetViewPort(c *xgb.Conn, Screen uint16) GetViewPortCookie
    func GetViewPortUnchecked(c *xgb.Conn, Screen uint16) GetViewPortCookie
    func (cook GetViewPortCookie) Reply() (*GetViewPortReply, error)
type GetViewPortReply
type LockModeSwitchCookie
    func LockModeSwitch(c *xgb.Conn, Screen uint16, Lock uint16) LockModeSwitchCookie
    func LockModeSwitchChecked(c *xgb.Conn, Screen uint16, Lock uint16) LockModeSwitchCookie
    func (cook LockModeSwitchCookie) Check() error
type ModModeLineCookie
    func ModModeLine(c *xgb.Conn, Screen uint32, Hdisplay uint16, Hsyncstart uint16, Hsyncend uint16, Htotal uint16, Hskew uint16, Vdisplay uint16, Vsyncstart uint16, Vsyncend uint16, Vtotal uint16, Flags uint32, Privsize uint32, Private []byte) ModModeLineCookie
    func ModModeLineChecked(c *xgb.Conn, Screen uint32, Hdisplay uint16, Hsyncstart uint16, Hsyncend uint16, Htotal uint16, Hskew uint16, Vdisplay uint16, Vsyncstart uint16, Vsyncend uint16, Vtotal uint16, Flags uint32, Privsize uint32, Private []byte) ModModeLineCookie
    func (cook ModModeLineCookie) Check() error
type ModeInfo
    func (v ModeInfo) Bytes() []byte
type ModeUnsuitableError
    func (err ModeUnsuitableError) BadId() uint32
    func (err ModeUnsuitableError) Error() string
    func (err ModeUnsuitableError) SequenceId() uint16
type QueryVersionCookie
    func QueryVersion(c *xgb.Conn) QueryVersionCookie
    func QueryVersionUnchecked(c *xgb.Conn) QueryVersionCookie
    func (cook QueryVersionCookie) Reply() (*QueryVersionReply, error)
type QueryVersionReply
type SetClientVersionCookie
    func SetClientVersion(c *xgb.Conn, Major uint16, Minor uint16) SetClientVersionCookie
    func SetClientVersionChecked(c *xgb.Conn, Major uint16, Minor uint16) SetClientVersionCookie
    func (cook SetClientVersionCookie) Check() error
type SetGammaCookie
    func SetGamma(c *xgb.Conn, Screen uint16, Red uint32, Green uint32, Blue uint32) SetGammaCookie
    func SetGammaChecked(c *xgb.Conn, Screen uint16, Red uint32, Green uint32, Blue uint32) SetGammaCookie
    func (cook SetGammaCookie) Check() error
type SetGammaRampCookie
    func SetGammaRamp(c *xgb.Conn, Screen uint16, Size uint16, Red []uint16, Green []uint16, Blue []uint16) SetGammaRampCookie
    func SetGammaRampChecked(c *xgb.Conn, Screen uint16, Size uint16, Red []uint16, Green []uint16, Blue []uint16) SetGammaRampCookie
    func (cook SetGammaRampCookie) Check() error
type SetViewPortCookie
    func SetViewPort(c *xgb.Conn, Screen uint16, X uint32, Y uint32) SetViewPortCookie
    func SetViewPortChecked(c *xgb.Conn, Screen uint16, X uint32, Y uint32) SetViewPortCookie
    func (cook SetViewPortCookie) Check() error
type SwitchModeCookie
    func SwitchMode(c *xgb.Conn, Screen uint16, Zoom uint16) SwitchModeCookie
    func SwitchModeChecked(c *xgb.Conn, Screen uint16, Zoom uint16) SwitchModeCookie
    func (cook SwitchModeCookie) Check() error
type SwitchToModeCookie
    func SwitchToMode(c *xgb.Conn, Screen uint32, Dotclock Dotclock, Hdisplay uint16, Hsyncstart uint16, Hsyncend uint16, Htotal uint16, Hskew uint16, Vdisplay uint16, Vsyncstart uint16, Vsyncend uint16, Vtotal uint16, Flags uint32, Privsize uint32, Private []byte) SwitchToModeCookie
    func SwitchToModeChecked(c *xgb.Conn, Screen uint32, Dotclock Dotclock, Hdisplay uint16, Hsyncstart uint16, Hsyncend uint16, Htotal uint16, Hskew uint16, Vdisplay uint16, Vsyncstart uint16, Vsyncend uint16, Vtotal uint16, Flags uint32, Privsize uint32, Private []byte) SwitchToModeCookie
    func (cook SwitchToModeCookie) Check() error
type Syncrange
type ValidateModeLineCookie
    func ValidateModeLine(c *xgb.Conn, Screen uint32, Dotclock Dotclock, Hdisplay uint16, Hsyncstart uint16, Hsyncend uint16, Htotal uint16, Hskew uint16, Vdisplay uint16, Vsyncstart uint16, Vsyncend uint16, Vtotal uint16, Flags uint32, Privsize uint32, Private []byte) ValidateModeLineCookie
    func ValidateModeLineUnchecked(c *xgb.Conn, Screen uint32, Dotclock Dotclock, Hdisplay uint16, Hsyncstart uint16, Hsyncend uint16, Htotal uint16, Hskew uint16, Vdisplay uint16, Vsyncstart uint16, Vsyncend uint16, Vtotal uint16, Flags uint32, Privsize uint32, Private []byte) ValidateModeLineCookie
    func (cook ValidateModeLineCookie) Reply() (*ValidateModeLineReply, error)
type ValidateModeLineReply
type ZoomLockedError
    func (err ZoomLockedError) BadId() uint32
    func (err ZoomLockedError) Error() string
    func (err ZoomLockedError) SequenceId() uint16

Package files

xf86vidmode.go

Constants

const (
    ModeFlagPositiveHsync = 1
    ModeFlagNegativeHsync = 2
    ModeFlagPositiveVsync = 4
    ModeFlagNegativeVsync = 8
    ModeFlagInterlace     = 16
    ModeFlagCompositeSync = 32
    ModeFlagPositiveCsync = 64
    ModeFlagNegativeCsync = 128
    ModeFlagHSkew         = 256
    ModeFlagBroadcast     = 512
    ModeFlagPixmux        = 1024
    ModeFlagDoubleClock   = 2048
    ModeFlagHalfClock     = 4096
)
const (
    PermissionRead  = 1
    PermissionWrite = 2
)

BadBadClock is the error number for a BadBadClock.

const BadBadClock = 0

BadBadHTimings is the error number for a BadBadHTimings.

const BadBadHTimings = 1

BadBadVTimings is the error number for a BadBadVTimings.

const BadBadVTimings = 2

BadClientNotLocal is the error number for a BadClientNotLocal.

const BadClientNotLocal = 5

BadExtensionDisabled is the error number for a BadExtensionDisabled.

const BadExtensionDisabled = 4

BadModeUnsuitable is the error number for a BadModeUnsuitable.

const BadModeUnsuitable = 3

BadZoomLocked is the error number for a BadZoomLocked.

const BadZoomLocked = 6
const (
    ClockFlagProgramable = 1
)

func BadClockErrorNew

func BadClockErrorNew(buf []byte) xgb.Error

BadClockErrorNew constructs a BadClockError value that implements xgb.Error from a byte slice.

func BadHTimingsErrorNew

func BadHTimingsErrorNew(buf []byte) xgb.Error

BadHTimingsErrorNew constructs a BadHTimingsError value that implements xgb.Error from a byte slice.

func BadVTimingsErrorNew

func BadVTimingsErrorNew(buf []byte) xgb.Error

BadVTimingsErrorNew constructs a BadVTimingsError value that implements xgb.Error from a byte slice.

func ClientNotLocalErrorNew

func ClientNotLocalErrorNew(buf []byte) xgb.Error

ClientNotLocalErrorNew constructs a ClientNotLocalError value that implements xgb.Error from a byte slice.

func ExtensionDisabledErrorNew

func ExtensionDisabledErrorNew(buf []byte) xgb.Error

ExtensionDisabledErrorNew constructs a ExtensionDisabledError value that implements xgb.Error from a byte slice.

func Init

func Init(c *xgb.Conn) error

Init must be called before using the XFree86-VidModeExtension extension.

func ModeInfoListBytes

func ModeInfoListBytes(buf []byte, list []ModeInfo) int

ModeInfoListBytes writes a list of ModeInfo values to a byte slice.

func ModeInfoRead

func ModeInfoRead(buf []byte, v *ModeInfo) int

ModeInfoRead reads a byte slice into a ModeInfo value.

func ModeInfoReadList

func ModeInfoReadList(buf []byte, dest []ModeInfo) int

ModeInfoReadList reads a byte slice into a list of ModeInfo values.

func ModeUnsuitableErrorNew

func ModeUnsuitableErrorNew(buf []byte) xgb.Error

ModeUnsuitableErrorNew constructs a ModeUnsuitableError value that implements xgb.Error from a byte slice.

func ZoomLockedErrorNew

func ZoomLockedErrorNew(buf []byte) xgb.Error

ZoomLockedErrorNew constructs a ZoomLockedError value that implements xgb.Error from a byte slice.

type AddModeLineCookie

AddModeLineCookie is a cookie used only for AddModeLine requests.

type AddModeLineCookie struct {
    *xgb.Cookie
}

func AddModeLine

func AddModeLine(c *xgb.Conn, Screen uint32, Dotclock Dotclock, Hdisplay uint16, Hsyncstart uint16, Hsyncend uint16, Htotal uint16, Hskew uint16, Vdisplay uint16, Vsyncstart uint16, Vsyncend uint16, Vtotal uint16, Flags uint32, Privsize uint32, AfterDotclock Dotclock, AfterHdisplay uint16, AfterHsyncstart uint16, AfterHsyncend uint16, AfterHtotal uint16, AfterHskew uint16, AfterVdisplay uint16, AfterVsyncstart uint16, AfterVsyncend uint16, AfterVtotal uint16, AfterFlags uint32, Private []byte) AddModeLineCookie

AddModeLine sends an unchecked request. If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.

func AddModeLineChecked

func AddModeLineChecked(c *xgb.Conn, Screen uint32, Dotclock Dotclock, Hdisplay uint16, Hsyncstart uint16, Hsyncend uint16, Htotal uint16, Hskew uint16, Vdisplay uint16, Vsyncstart uint16, Vsyncend uint16, Vtotal uint16, Flags uint32, Privsize uint32, AfterDotclock Dotclock, AfterHdisplay uint16, AfterHsyncstart uint16, AfterHsyncend uint16, AfterHtotal uint16, AfterHskew uint16, AfterVdisplay uint16, AfterVsyncstart uint16, AfterVsyncend uint16, AfterVtotal uint16, AfterFlags uint32, Private []byte) AddModeLineCookie

AddModeLineChecked sends a checked request. If an error occurs, it can be retrieved using AddModeLineCookie.Check()

func (AddModeLineCookie) Check

func (cook AddModeLineCookie) Check() error

Check returns an error if one occurred for checked requests that are not expecting a reply. This cannot be called for requests expecting a reply, nor for unchecked requests.

type BadClockError

type BadClockError struct {
    Sequence uint16
    NiceName string
}

func (BadClockError) BadId

func (err BadClockError) BadId() uint32

BadId returns the 'BadValue' number if one exists for the BadBadClock error. If no bad value exists, 0 is returned.

func (BadClockError) Error

func (err BadClockError) Error() string

func (BadClockError) SequenceId

func (err BadClockError) SequenceId() uint16

SequenceId returns the sequence id attached to the BadBadClock error. This is mostly used internally.

type BadHTimingsError

type BadHTimingsError struct {
    Sequence uint16
    NiceName string
}

func (BadHTimingsError) BadId

func (err BadHTimingsError) BadId() uint32

BadId returns the 'BadValue' number if one exists for the BadBadHTimings error. If no bad value exists, 0 is returned.

func (BadHTimingsError) Error

func (err BadHTimingsError) Error() string

func (BadHTimingsError) SequenceId

func (err BadHTimingsError) SequenceId() uint16

SequenceId returns the sequence id attached to the BadBadHTimings error. This is mostly used internally.

type BadVTimingsError

type BadVTimingsError struct {
    Sequence uint16
    NiceName string
}

func (BadVTimingsError) BadId

func (err BadVTimingsError) BadId() uint32

BadId returns the 'BadValue' number if one exists for the BadBadVTimings error. If no bad value exists, 0 is returned.

func (BadVTimingsError) Error

func (err BadVTimingsError) Error() string

func (BadVTimingsError) SequenceId

func (err BadVTimingsError) SequenceId() uint16

SequenceId returns the sequence id attached to the BadBadVTimings error. This is mostly used internally.

type ClientNotLocalError

type ClientNotLocalError struct {
    Sequence uint16
    NiceName string
}

func (ClientNotLocalError) BadId

func (err ClientNotLocalError) BadId() uint32

BadId returns the 'BadValue' number if one exists for the BadClientNotLocal error. If no bad value exists, 0 is returned.

func (ClientNotLocalError) Error

func (err ClientNotLocalError) Error() string

func (ClientNotLocalError) SequenceId

func (err ClientNotLocalError) SequenceId() uint16

SequenceId returns the sequence id attached to the BadClientNotLocal error. This is mostly used internally.

type DeleteModeLineCookie

DeleteModeLineCookie is a cookie used only for DeleteModeLine requests.

type DeleteModeLineCookie struct {
    *xgb.Cookie
}

func DeleteModeLine

func DeleteModeLine(c *xgb.Conn, Screen uint32, Dotclock Dotclock, Hdisplay uint16, Hsyncstart uint16, Hsyncend uint16, Htotal uint16, Hskew uint16, Vdisplay uint16, Vsyncstart uint16, Vsyncend uint16, Vtotal uint16, Flags uint32, Privsize uint32, Private []byte) DeleteModeLineCookie

DeleteModeLine sends an unchecked request. If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.

func DeleteModeLineChecked

func DeleteModeLineChecked(c *xgb.Conn, Screen uint32, Dotclock Dotclock, Hdisplay uint16, Hsyncstart uint16, Hsyncend uint16, Htotal uint16, Hskew uint16, Vdisplay uint16, Vsyncstart uint16, Vsyncend uint16, Vtotal uint16, Flags uint32, Privsize uint32, Private []byte) DeleteModeLineCookie

DeleteModeLineChecked sends a checked request. If an error occurs, it can be retrieved using DeleteModeLineCookie.Check()

func (DeleteModeLineCookie) Check

func (cook DeleteModeLineCookie) Check() error

Check returns an error if one occurred for checked requests that are not expecting a reply. This cannot be called for requests expecting a reply, nor for unchecked requests.

type Dotclock

type Dotclock uint32

type ExtensionDisabledError

type ExtensionDisabledError struct {
    Sequence uint16
    NiceName string
}

func (ExtensionDisabledError) BadId

func (err ExtensionDisabledError) BadId() uint32

BadId returns the 'BadValue' number if one exists for the BadExtensionDisabled error. If no bad value exists, 0 is returned.

func (ExtensionDisabledError) Error

func (err ExtensionDisabledError) Error() string

func (ExtensionDisabledError) SequenceId

func (err ExtensionDisabledError) SequenceId() uint16

SequenceId returns the sequence id attached to the BadExtensionDisabled error. This is mostly used internally.

type GetAllModeLinesCookie

GetAllModeLinesCookie is a cookie used only for GetAllModeLines requests.

type GetAllModeLinesCookie struct {
    *xgb.Cookie
}

func GetAllModeLines

func GetAllModeLines(c *xgb.Conn, Screen uint16) GetAllModeLinesCookie

GetAllModeLines sends a checked request. If an error occurs, it will be returned with the reply by calling GetAllModeLinesCookie.Reply()

func GetAllModeLinesUnchecked

func GetAllModeLinesUnchecked(c *xgb.Conn, Screen uint16) GetAllModeLinesCookie

GetAllModeLinesUnchecked sends an unchecked request. If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.

func (GetAllModeLinesCookie) Reply

func (cook GetAllModeLinesCookie) Reply() (*GetAllModeLinesReply, error)

Reply blocks and returns the reply data for a GetAllModeLines request.

type GetAllModeLinesReply

GetAllModeLinesReply represents the data returned from a GetAllModeLines request.

type GetAllModeLinesReply struct {
    Sequence uint16 // sequence number of the request for this reply
    Length   uint32 // number of bytes in this reply
    // padding: 1 bytes
    Modecount uint32
    // padding: 20 bytes
    Modeinfo []ModeInfo // size: xgb.Pad((int(Modecount) * 48))
}

type GetDotClocksCookie

GetDotClocksCookie is a cookie used only for GetDotClocks requests.

type GetDotClocksCookie struct {
    *xgb.Cookie
}

func GetDotClocks

func GetDotClocks(c *xgb.Conn, Screen uint16) GetDotClocksCookie

GetDotClocks sends a checked request. If an error occurs, it will be returned with the reply by calling GetDotClocksCookie.Reply()

func GetDotClocksUnchecked

func GetDotClocksUnchecked(c *xgb.Conn, Screen uint16) GetDotClocksCookie

GetDotClocksUnchecked sends an unchecked request. If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.

func (GetDotClocksCookie) Reply

func (cook GetDotClocksCookie) Reply() (*GetDotClocksReply, error)

Reply blocks and returns the reply data for a GetDotClocks request.

type GetDotClocksReply

GetDotClocksReply represents the data returned from a GetDotClocks request.

type GetDotClocksReply struct {
    Sequence uint16 // sequence number of the request for this reply
    Length   uint32 // number of bytes in this reply
    // padding: 1 bytes
    Flags     uint32
    Clocks    uint32
    Maxclocks uint32
    // padding: 12 bytes
    Clock []uint32 // size: xgb.Pad((((1 - (int(Flags) & 1)) * int(Clocks)) * 4))
}

type GetGammaCookie

GetGammaCookie is a cookie used only for GetGamma requests.

type GetGammaCookie struct {
    *xgb.Cookie
}

func GetGamma

func GetGamma(c *xgb.Conn, Screen uint16) GetGammaCookie

GetGamma sends a checked request. If an error occurs, it will be returned with the reply by calling GetGammaCookie.Reply()

func GetGammaUnchecked

func GetGammaUnchecked(c *xgb.Conn, Screen uint16) GetGammaCookie

GetGammaUnchecked sends an unchecked request. If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.

func (GetGammaCookie) Reply

func (cook GetGammaCookie) Reply() (*GetGammaReply, error)

Reply blocks and returns the reply data for a GetGamma request.

type GetGammaRampCookie

GetGammaRampCookie is a cookie used only for GetGammaRamp requests.

type GetGammaRampCookie struct {
    *xgb.Cookie
}

func GetGammaRamp

func GetGammaRamp(c *xgb.Conn, Screen uint16, Size uint16) GetGammaRampCookie

GetGammaRamp sends a checked request. If an error occurs, it will be returned with the reply by calling GetGammaRampCookie.Reply()

func GetGammaRampUnchecked

func GetGammaRampUnchecked(c *xgb.Conn, Screen uint16, Size uint16) GetGammaRampCookie

GetGammaRampUnchecked sends an unchecked request. If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.

func (GetGammaRampCookie) Reply

func (cook GetGammaRampCookie) Reply() (*GetGammaRampReply, error)

Reply blocks and returns the reply data for a GetGammaRamp request.

type GetGammaRampReply

GetGammaRampReply represents the data returned from a GetGammaRamp request.

type GetGammaRampReply struct {
    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
    Red []uint16 // size: xgb.Pad((((int(Size) + 1) & -2) * 2))
    // alignment gap to multiple of 2
    Green []uint16 // size: xgb.Pad((((int(Size) + 1) & -2) * 2))
    // alignment gap to multiple of 2
    Blue []uint16 // size: xgb.Pad((((int(Size) + 1) & -2) * 2))
}

type GetGammaRampSizeCookie

GetGammaRampSizeCookie is a cookie used only for GetGammaRampSize requests.

type GetGammaRampSizeCookie struct {
    *xgb.Cookie
}

func GetGammaRampSize

func GetGammaRampSize(c *xgb.Conn, Screen uint16) GetGammaRampSizeCookie

GetGammaRampSize sends a checked request. If an error occurs, it will be returned with the reply by calling GetGammaRampSizeCookie.Reply()

func GetGammaRampSizeUnchecked

func GetGammaRampSizeUnchecked(c *xgb.Conn, Screen uint16) GetGammaRampSizeCookie

GetGammaRampSizeUnchecked sends an unchecked request. If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.

func (GetGammaRampSizeCookie) Reply

func (cook GetGammaRampSizeCookie) Reply() (*GetGammaRampSizeReply, error)

Reply blocks and returns the reply data for a GetGammaRampSize request.

type GetGammaRampSizeReply

GetGammaRampSizeReply represents the data returned from a GetGammaRampSize request.

type GetGammaRampSizeReply struct {
    Sequence uint16 // sequence number of the request for this reply
    Length   uint32 // number of bytes in this reply
    // padding: 1 bytes
    Size uint16
}

type GetGammaReply

GetGammaReply represents the data returned from a GetGamma request.

type GetGammaReply struct {
    Sequence uint16 // sequence number of the request for this reply
    Length   uint32 // number of bytes in this reply
    // padding: 1 bytes
    Red   uint32
    Green uint32
    Blue  uint32
}

type GetModeLineCookie

GetModeLineCookie is a cookie used only for GetModeLine requests.

type GetModeLineCookie struct {
    *xgb.Cookie
}

func GetModeLine

func GetModeLine(c *xgb.Conn, Screen uint16) GetModeLineCookie

GetModeLine sends a checked request. If an error occurs, it will be returned with the reply by calling GetModeLineCookie.Reply()

func GetModeLineUnchecked

func GetModeLineUnchecked(c *xgb.Conn, Screen uint16) GetModeLineCookie

GetModeLineUnchecked sends an unchecked request. If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.

func (GetModeLineCookie) Reply

func (cook GetModeLineCookie) Reply() (*GetModeLineReply, error)

Reply blocks and returns the reply data for a GetModeLine request.

type GetModeLineReply

GetModeLineReply represents the data returned from a GetModeLine request.

type GetModeLineReply struct {
    Sequence uint16 // sequence number of the request for this reply
    Length   uint32 // number of bytes in this reply
    // padding: 1 bytes
    Dotclock   Dotclock
    Hdisplay   uint16
    Hsyncstart uint16
    Hsyncend   uint16
    Htotal     uint16
    Hskew      uint16
    Vdisplay   uint16
    Vsyncstart uint16
    Vsyncend   uint16
    Vtotal     uint16
    // padding: 2 bytes
    Flags uint32
    // padding: 12 bytes
    Privsize uint32
    Private  []byte // size: xgb.Pad((int(Privsize) * 1))
}

type GetMonitorCookie

GetMonitorCookie is a cookie used only for GetMonitor requests.

type GetMonitorCookie struct {
    *xgb.Cookie
}

func GetMonitor

func GetMonitor(c *xgb.Conn, Screen uint16) GetMonitorCookie

GetMonitor sends a checked request. If an error occurs, it will be returned with the reply by calling GetMonitorCookie.Reply()

func GetMonitorUnchecked

func GetMonitorUnchecked(c *xgb.Conn, Screen uint16) GetMonitorCookie

GetMonitorUnchecked sends an unchecked request. If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.

func (GetMonitorCookie) Reply

func (cook GetMonitorCookie) Reply() (*GetMonitorReply, error)

Reply blocks and returns the reply data for a GetMonitor request.

type GetMonitorReply

GetMonitorReply represents the data returned from a GetMonitor request.

type GetMonitorReply struct {
    Sequence uint16 // sequence number of the request for this reply
    Length   uint32 // number of bytes in this reply
    // padding: 1 bytes
    VendorLength byte
    ModelLength  byte
    NumHsync     byte
    NumVsync     byte
    // padding: 20 bytes
    Hsync []Syncrange // size: xgb.Pad((int(NumHsync) * 4))
    // alignment gap to multiple of 4
    Vsync        []Syncrange // size: xgb.Pad((int(NumVsync) * 4))
    Vendor       string      // size: xgb.Pad((int(VendorLength) * 1))
    AlignmentPad []byte      // size: xgb.Pad(((((int(VendorLength) + 3) & -4) - int(VendorLength)) * 1))
    Model        string      // size: xgb.Pad((int(ModelLength) * 1))
}

type GetPermissionsCookie

GetPermissionsCookie is a cookie used only for GetPermissions requests.

type GetPermissionsCookie struct {
    *xgb.Cookie
}

func GetPermissions

func GetPermissions(c *xgb.Conn, Screen uint16) GetPermissionsCookie

GetPermissions sends a checked request. If an error occurs, it will be returned with the reply by calling GetPermissionsCookie.Reply()

func GetPermissionsUnchecked

func GetPermissionsUnchecked(c *xgb.Conn, Screen uint16) GetPermissionsCookie

GetPermissionsUnchecked sends an unchecked request. If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.

func (GetPermissionsCookie) Reply

func (cook GetPermissionsCookie) Reply() (*GetPermissionsReply, error)

Reply blocks and returns the reply data for a GetPermissions request.

type GetPermissionsReply

GetPermissionsReply represents the data returned from a GetPermissions request.

type GetPermissionsReply struct {
    Sequence uint16 // sequence number of the request for this reply
    Length   uint32 // number of bytes in this reply
    // padding: 1 bytes
    Permissions uint32
}

type GetViewPortCookie

GetViewPortCookie is a cookie used only for GetViewPort requests.

type GetViewPortCookie struct {
    *xgb.Cookie
}

func GetViewPort

func GetViewPort(c *xgb.Conn, Screen uint16) GetViewPortCookie

GetViewPort sends a checked request. If an error occurs, it will be returned with the reply by calling GetViewPortCookie.Reply()

func GetViewPortUnchecked

func GetViewPortUnchecked(c *xgb.Conn, Screen uint16) GetViewPortCookie

GetViewPortUnchecked sends an unchecked request. If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.

func (GetViewPortCookie) Reply

func (cook GetViewPortCookie) Reply() (*GetViewPortReply, error)

Reply blocks and returns the reply data for a GetViewPort request.

type GetViewPortReply

GetViewPortReply represents the data returned from a GetViewPort request.

type GetViewPortReply struct {
    Sequence uint16 // sequence number of the request for this reply
    Length   uint32 // number of bytes in this reply
    // padding: 1 bytes
    X uint32
    Y uint32
}

type LockModeSwitchCookie

LockModeSwitchCookie is a cookie used only for LockModeSwitch requests.

type LockModeSwitchCookie struct {
    *xgb.Cookie
}

func LockModeSwitch

func LockModeSwitch(c *xgb.Conn, Screen uint16, Lock uint16) LockModeSwitchCookie

LockModeSwitch sends an unchecked request. If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.

func LockModeSwitchChecked

func LockModeSwitchChecked(c *xgb.Conn, Screen uint16, Lock uint16) LockModeSwitchCookie

LockModeSwitchChecked sends a checked request. If an error occurs, it can be retrieved using LockModeSwitchCookie.Check()

func (LockModeSwitchCookie) Check

func (cook LockModeSwitchCookie) Check() error

Check returns an error if one occurred for checked requests that are not expecting a reply. This cannot be called for requests expecting a reply, nor for unchecked requests.

type ModModeLineCookie

ModModeLineCookie is a cookie used only for ModModeLine requests.

type ModModeLineCookie struct {
    *xgb.Cookie
}

func ModModeLine

func ModModeLine(c *xgb.Conn, Screen uint32, Hdisplay uint16, Hsyncstart uint16, Hsyncend uint16, Htotal uint16, Hskew uint16, Vdisplay uint16, Vsyncstart uint16, Vsyncend uint16, Vtotal uint16, Flags uint32, Privsize uint32, Private []byte) ModModeLineCookie

ModModeLine sends an unchecked request. If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.

func ModModeLineChecked

func ModModeLineChecked(c *xgb.Conn, Screen uint32, Hdisplay uint16, Hsyncstart uint16, Hsyncend uint16, Htotal uint16, Hskew uint16, Vdisplay uint16, Vsyncstart uint16, Vsyncend uint16, Vtotal uint16, Flags uint32, Privsize uint32, Private []byte) ModModeLineCookie

ModModeLineChecked sends a checked request. If an error occurs, it can be retrieved using ModModeLineCookie.Check()

func (ModModeLineCookie) Check

func (cook ModModeLineCookie) Check() error

Check returns an error if one occurred for checked requests that are not expecting a reply. This cannot be called for requests expecting a reply, nor for unchecked requests.

type ModeInfo

type ModeInfo struct {
    Dotclock   Dotclock
    Hdisplay   uint16
    Hsyncstart uint16
    Hsyncend   uint16
    Htotal     uint16
    Hskew      uint32
    Vdisplay   uint16
    Vsyncstart uint16
    Vsyncend   uint16
    Vtotal     uint16
    // padding: 4 bytes
    Flags uint32
    // padding: 12 bytes
    Privsize uint32
}

func (ModeInfo) Bytes

func (v ModeInfo) Bytes() []byte

Bytes writes a ModeInfo value to a byte slice.

type ModeUnsuitableError

type ModeUnsuitableError struct {
    Sequence uint16
    NiceName string
}

func (ModeUnsuitableError) BadId

func (err ModeUnsuitableError) BadId() uint32

BadId returns the 'BadValue' number if one exists for the BadModeUnsuitable error. If no bad value exists, 0 is returned.

func (ModeUnsuitableError) Error

func (err ModeUnsuitableError) Error() string

func (ModeUnsuitableError) SequenceId

func (err ModeUnsuitableError) SequenceId() uint16

SequenceId returns the sequence id attached to the BadModeUnsuitable error. This is mostly used internally.

type QueryVersionCookie

QueryVersionCookie is a cookie used only for QueryVersion requests.

type QueryVersionCookie struct {
    *xgb.Cookie
}

func QueryVersion

func QueryVersion(c *xgb.Conn) QueryVersionCookie

QueryVersion sends a checked request. If an error occurs, it will be returned with the reply by calling QueryVersionCookie.Reply()

func QueryVersionUnchecked

func QueryVersionUnchecked(c *xgb.Conn) QueryVersionCookie

QueryVersionUnchecked sends an unchecked request. If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.

func (QueryVersionCookie) Reply

func (cook QueryVersionCookie) Reply() (*QueryVersionReply, error)

Reply blocks and returns the reply data for a QueryVersion request.

type QueryVersionReply

QueryVersionReply represents the data returned from a QueryVersion request.

type QueryVersionReply struct {
    Sequence uint16 // sequence number of the request for this reply
    Length   uint32 // number of bytes in this reply
    // padding: 1 bytes
    MajorVersion uint16
    MinorVersion uint16
}

type SetClientVersionCookie

SetClientVersionCookie is a cookie used only for SetClientVersion requests.

type SetClientVersionCookie struct {
    *xgb.Cookie
}

func SetClientVersion

func SetClientVersion(c *xgb.Conn, Major uint16, Minor uint16) SetClientVersionCookie

SetClientVersion sends an unchecked request. If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.

func SetClientVersionChecked

func SetClientVersionChecked(c *xgb.Conn, Major uint16, Minor uint16) SetClientVersionCookie

SetClientVersionChecked sends a checked request. If an error occurs, it can be retrieved using SetClientVersionCookie.Check()

func (SetClientVersionCookie) Check

func (cook SetClientVersionCookie) Check() error

Check returns an error if one occurred for checked requests that are not expecting a reply. This cannot be called for requests expecting a reply, nor for unchecked requests.

type SetGammaCookie

SetGammaCookie is a cookie used only for SetGamma requests.

type SetGammaCookie struct {
    *xgb.Cookie
}

func SetGamma

func SetGamma(c *xgb.Conn, Screen uint16, Red uint32, Green uint32, Blue uint32) SetGammaCookie

SetGamma sends an unchecked request. If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.

func SetGammaChecked

func SetGammaChecked(c *xgb.Conn, Screen uint16, Red uint32, Green uint32, Blue uint32) SetGammaCookie

SetGammaChecked sends a checked request. If an error occurs, it can be retrieved using SetGammaCookie.Check()

func (SetGammaCookie) Check

func (cook SetGammaCookie) Check() error

Check returns an error if one occurred for checked requests that are not expecting a reply. This cannot be called for requests expecting a reply, nor for unchecked requests.

type SetGammaRampCookie

SetGammaRampCookie is a cookie used only for SetGammaRamp requests.

type SetGammaRampCookie struct {
    *xgb.Cookie
}

func SetGammaRamp

func SetGammaRamp(c *xgb.Conn, Screen uint16, Size uint16, Red []uint16, Green []uint16, Blue []uint16) SetGammaRampCookie

SetGammaRamp sends an unchecked request. If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.

func SetGammaRampChecked

func SetGammaRampChecked(c *xgb.Conn, Screen uint16, Size uint16, Red []uint16, Green []uint16, Blue []uint16) SetGammaRampCookie

SetGammaRampChecked sends a checked request. If an error occurs, it can be retrieved using SetGammaRampCookie.Check()

func (SetGammaRampCookie) Check

func (cook SetGammaRampCookie) Check() error

Check returns an error if one occurred for checked requests that are not expecting a reply. This cannot be called for requests expecting a reply, nor for unchecked requests.

type SetViewPortCookie

SetViewPortCookie is a cookie used only for SetViewPort requests.

type SetViewPortCookie struct {
    *xgb.Cookie
}

func SetViewPort

func SetViewPort(c *xgb.Conn, Screen uint16, X uint32, Y uint32) SetViewPortCookie

SetViewPort sends an unchecked request. If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.

func SetViewPortChecked

func SetViewPortChecked(c *xgb.Conn, Screen uint16, X uint32, Y uint32) SetViewPortCookie

SetViewPortChecked sends a checked request. If an error occurs, it can be retrieved using SetViewPortCookie.Check()

func (SetViewPortCookie) Check

func (cook SetViewPortCookie) Check() error

Check returns an error if one occurred for checked requests that are not expecting a reply. This cannot be called for requests expecting a reply, nor for unchecked requests.

type SwitchModeCookie

SwitchModeCookie is a cookie used only for SwitchMode requests.

type SwitchModeCookie struct {
    *xgb.Cookie
}

func SwitchMode

func SwitchMode(c *xgb.Conn, Screen uint16, Zoom uint16) SwitchModeCookie

SwitchMode sends an unchecked request. If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.

func SwitchModeChecked

func SwitchModeChecked(c *xgb.Conn, Screen uint16, Zoom uint16) SwitchModeCookie

SwitchModeChecked sends a checked request. If an error occurs, it can be retrieved using SwitchModeCookie.Check()

func (SwitchModeCookie) Check

func (cook SwitchModeCookie) Check() error

Check returns an error if one occurred for checked requests that are not expecting a reply. This cannot be called for requests expecting a reply, nor for unchecked requests.

type SwitchToModeCookie

SwitchToModeCookie is a cookie used only for SwitchToMode requests.

type SwitchToModeCookie struct {
    *xgb.Cookie
}

func SwitchToMode

func SwitchToMode(c *xgb.Conn, Screen uint32, Dotclock Dotclock, Hdisplay uint16, Hsyncstart uint16, Hsyncend uint16, Htotal uint16, Hskew uint16, Vdisplay uint16, Vsyncstart uint16, Vsyncend uint16, Vtotal uint16, Flags uint32, Privsize uint32, Private []byte) SwitchToModeCookie

SwitchToMode sends an unchecked request. If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.

func SwitchToModeChecked

func SwitchToModeChecked(c *xgb.Conn, Screen uint32, Dotclock Dotclock, Hdisplay uint16, Hsyncstart uint16, Hsyncend uint16, Htotal uint16, Hskew uint16, Vdisplay uint16, Vsyncstart uint16, Vsyncend uint16, Vtotal uint16, Flags uint32, Privsize uint32, Private []byte) SwitchToModeCookie

SwitchToModeChecked sends a checked request. If an error occurs, it can be retrieved using SwitchToModeCookie.Check()

func (SwitchToModeCookie) Check

func (cook SwitchToModeCookie) Check() error

Check returns an error if one occurred for checked requests that are not expecting a reply. This cannot be called for requests expecting a reply, nor for unchecked requests.

type Syncrange

type Syncrange uint32

type ValidateModeLineCookie

ValidateModeLineCookie is a cookie used only for ValidateModeLine requests.

type ValidateModeLineCookie struct {
    *xgb.Cookie
}

func ValidateModeLine

func ValidateModeLine(c *xgb.Conn, Screen uint32, Dotclock Dotclock, Hdisplay uint16, Hsyncstart uint16, Hsyncend uint16, Htotal uint16, Hskew uint16, Vdisplay uint16, Vsyncstart uint16, Vsyncend uint16, Vtotal uint16, Flags uint32, Privsize uint32, Private []byte) ValidateModeLineCookie

ValidateModeLine sends a checked request. If an error occurs, it will be returned with the reply by calling ValidateModeLineCookie.Reply()

func ValidateModeLineUnchecked

func ValidateModeLineUnchecked(c *xgb.Conn, Screen uint32, Dotclock Dotclock, Hdisplay uint16, Hsyncstart uint16, Hsyncend uint16, Htotal uint16, Hskew uint16, Vdisplay uint16, Vsyncstart uint16, Vsyncend uint16, Vtotal uint16, Flags uint32, Privsize uint32, Private []byte) ValidateModeLineCookie

ValidateModeLineUnchecked sends an unchecked request. If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent.

func (ValidateModeLineCookie) Reply

func (cook ValidateModeLineCookie) Reply() (*ValidateModeLineReply, error)

Reply blocks and returns the reply data for a ValidateModeLine request.

type ValidateModeLineReply

ValidateModeLineReply represents the data returned from a ValidateModeLine request.

type ValidateModeLineReply struct {
    Sequence uint16 // sequence number of the request for this reply
    Length   uint32 // number of bytes in this reply
    // padding: 1 bytes
    Status uint32
}

type ZoomLockedError

type ZoomLockedError struct {
    Sequence uint16
    NiceName string
}

func (ZoomLockedError) BadId

func (err ZoomLockedError) BadId() uint32

BadId returns the 'BadValue' number if one exists for the BadZoomLocked error. If no bad value exists, 0 is returned.

func (ZoomLockedError) Error

func (err ZoomLockedError) Error() string

func (ZoomLockedError) SequenceId

func (err ZoomLockedError) SequenceId() uint16

SequenceId returns the sequence id attached to the BadZoomLocked error. This is mostly used internally.