Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-18 10:14:36

0001 /*
0002  * This file generated automatically from dpms.xml by c_client.py.
0003  * Edit at your peril.
0004  */
0005 
0006 /**
0007  * @defgroup XCB_DPMS_API XCB DPMS API
0008  * @brief DPMS XCB Protocol Implementation.
0009  * @{
0010  **/
0011 
0012 #ifndef __DPMS_H
0013 #define __DPMS_H
0014 
0015 #include "xcb.h"
0016 #include "xproto.h"
0017 
0018 #ifdef __cplusplus
0019 extern "C" {
0020 #endif
0021 
0022 #define XCB_DPMS_MAJOR_VERSION 1
0023 #define XCB_DPMS_MINOR_VERSION 2
0024 
0025 extern xcb_extension_t xcb_dpms_id;
0026 
0027 /**
0028  * @brief xcb_dpms_get_version_cookie_t
0029  **/
0030 typedef struct xcb_dpms_get_version_cookie_t {
0031     unsigned int sequence;
0032 } xcb_dpms_get_version_cookie_t;
0033 
0034 /** Opcode for xcb_dpms_get_version. */
0035 #define XCB_DPMS_GET_VERSION 0
0036 
0037 /**
0038  * @brief xcb_dpms_get_version_request_t
0039  **/
0040 typedef struct xcb_dpms_get_version_request_t {
0041     uint8_t  major_opcode;
0042     uint8_t  minor_opcode;
0043     uint16_t length;
0044     uint16_t client_major_version;
0045     uint16_t client_minor_version;
0046 } xcb_dpms_get_version_request_t;
0047 
0048 /**
0049  * @brief xcb_dpms_get_version_reply_t
0050  **/
0051 typedef struct xcb_dpms_get_version_reply_t {
0052     uint8_t  response_type;
0053     uint8_t  pad0;
0054     uint16_t sequence;
0055     uint32_t length;
0056     uint16_t server_major_version;
0057     uint16_t server_minor_version;
0058 } xcb_dpms_get_version_reply_t;
0059 
0060 /**
0061  * @brief xcb_dpms_capable_cookie_t
0062  **/
0063 typedef struct xcb_dpms_capable_cookie_t {
0064     unsigned int sequence;
0065 } xcb_dpms_capable_cookie_t;
0066 
0067 /** Opcode for xcb_dpms_capable. */
0068 #define XCB_DPMS_CAPABLE 1
0069 
0070 /**
0071  * @brief xcb_dpms_capable_request_t
0072  **/
0073 typedef struct xcb_dpms_capable_request_t {
0074     uint8_t  major_opcode;
0075     uint8_t  minor_opcode;
0076     uint16_t length;
0077 } xcb_dpms_capable_request_t;
0078 
0079 /**
0080  * @brief xcb_dpms_capable_reply_t
0081  **/
0082 typedef struct xcb_dpms_capable_reply_t {
0083     uint8_t  response_type;
0084     uint8_t  pad0;
0085     uint16_t sequence;
0086     uint32_t length;
0087     uint8_t  capable;
0088     uint8_t  pad1[23];
0089 } xcb_dpms_capable_reply_t;
0090 
0091 /**
0092  * @brief xcb_dpms_get_timeouts_cookie_t
0093  **/
0094 typedef struct xcb_dpms_get_timeouts_cookie_t {
0095     unsigned int sequence;
0096 } xcb_dpms_get_timeouts_cookie_t;
0097 
0098 /** Opcode for xcb_dpms_get_timeouts. */
0099 #define XCB_DPMS_GET_TIMEOUTS 2
0100 
0101 /**
0102  * @brief xcb_dpms_get_timeouts_request_t
0103  **/
0104 typedef struct xcb_dpms_get_timeouts_request_t {
0105     uint8_t  major_opcode;
0106     uint8_t  minor_opcode;
0107     uint16_t length;
0108 } xcb_dpms_get_timeouts_request_t;
0109 
0110 /**
0111  * @brief xcb_dpms_get_timeouts_reply_t
0112  **/
0113 typedef struct xcb_dpms_get_timeouts_reply_t {
0114     uint8_t  response_type;
0115     uint8_t  pad0;
0116     uint16_t sequence;
0117     uint32_t length;
0118     uint16_t standby_timeout;
0119     uint16_t suspend_timeout;
0120     uint16_t off_timeout;
0121     uint8_t  pad1[18];
0122 } xcb_dpms_get_timeouts_reply_t;
0123 
0124 /** Opcode for xcb_dpms_set_timeouts. */
0125 #define XCB_DPMS_SET_TIMEOUTS 3
0126 
0127 /**
0128  * @brief xcb_dpms_set_timeouts_request_t
0129  **/
0130 typedef struct xcb_dpms_set_timeouts_request_t {
0131     uint8_t  major_opcode;
0132     uint8_t  minor_opcode;
0133     uint16_t length;
0134     uint16_t standby_timeout;
0135     uint16_t suspend_timeout;
0136     uint16_t off_timeout;
0137 } xcb_dpms_set_timeouts_request_t;
0138 
0139 /** Opcode for xcb_dpms_enable. */
0140 #define XCB_DPMS_ENABLE 4
0141 
0142 /**
0143  * @brief xcb_dpms_enable_request_t
0144  **/
0145 typedef struct xcb_dpms_enable_request_t {
0146     uint8_t  major_opcode;
0147     uint8_t  minor_opcode;
0148     uint16_t length;
0149 } xcb_dpms_enable_request_t;
0150 
0151 /** Opcode for xcb_dpms_disable. */
0152 #define XCB_DPMS_DISABLE 5
0153 
0154 /**
0155  * @brief xcb_dpms_disable_request_t
0156  **/
0157 typedef struct xcb_dpms_disable_request_t {
0158     uint8_t  major_opcode;
0159     uint8_t  minor_opcode;
0160     uint16_t length;
0161 } xcb_dpms_disable_request_t;
0162 
0163 typedef enum xcb_dpms_dpms_mode_t {
0164     XCB_DPMS_DPMS_MODE_ON = 0,
0165     XCB_DPMS_DPMS_MODE_STANDBY = 1,
0166     XCB_DPMS_DPMS_MODE_SUSPEND = 2,
0167     XCB_DPMS_DPMS_MODE_OFF = 3
0168 } xcb_dpms_dpms_mode_t;
0169 
0170 /** Opcode for xcb_dpms_force_level. */
0171 #define XCB_DPMS_FORCE_LEVEL 6
0172 
0173 /**
0174  * @brief xcb_dpms_force_level_request_t
0175  **/
0176 typedef struct xcb_dpms_force_level_request_t {
0177     uint8_t  major_opcode;
0178     uint8_t  minor_opcode;
0179     uint16_t length;
0180     uint16_t power_level;
0181 } xcb_dpms_force_level_request_t;
0182 
0183 /**
0184  * @brief xcb_dpms_info_cookie_t
0185  **/
0186 typedef struct xcb_dpms_info_cookie_t {
0187     unsigned int sequence;
0188 } xcb_dpms_info_cookie_t;
0189 
0190 /** Opcode for xcb_dpms_info. */
0191 #define XCB_DPMS_INFO 7
0192 
0193 /**
0194  * @brief xcb_dpms_info_request_t
0195  **/
0196 typedef struct xcb_dpms_info_request_t {
0197     uint8_t  major_opcode;
0198     uint8_t  minor_opcode;
0199     uint16_t length;
0200 } xcb_dpms_info_request_t;
0201 
0202 /**
0203  * @brief xcb_dpms_info_reply_t
0204  **/
0205 typedef struct xcb_dpms_info_reply_t {
0206     uint8_t  response_type;
0207     uint8_t  pad0;
0208     uint16_t sequence;
0209     uint32_t length;
0210     uint16_t power_level;
0211     uint8_t  state;
0212     uint8_t  pad1[21];
0213 } xcb_dpms_info_reply_t;
0214 
0215 typedef enum xcb_dpms_event_mask_t {
0216     XCB_DPMS_EVENT_MASK_INFO_NOTIFY = 1
0217 } xcb_dpms_event_mask_t;
0218 
0219 /** Opcode for xcb_dpms_select_input. */
0220 #define XCB_DPMS_SELECT_INPUT 8
0221 
0222 /**
0223  * @brief xcb_dpms_select_input_request_t
0224  **/
0225 typedef struct xcb_dpms_select_input_request_t {
0226     uint8_t  major_opcode;
0227     uint8_t  minor_opcode;
0228     uint16_t length;
0229     uint32_t event_mask;
0230 } xcb_dpms_select_input_request_t;
0231 
0232 /** Opcode for xcb_dpms_info_notify. */
0233 #define XCB_DPMS_INFO_NOTIFY 0
0234 
0235 /**
0236  * @brief xcb_dpms_info_notify_event_t
0237  **/
0238 typedef struct xcb_dpms_info_notify_event_t {
0239     uint8_t         response_type;
0240     uint8_t         extension;
0241     uint16_t        sequence;
0242     uint32_t        length;
0243     uint16_t        event_type;
0244     uint8_t         pad0[2];
0245     xcb_timestamp_t timestamp;
0246     uint16_t        power_level;
0247     uint8_t         state;
0248     uint8_t         pad1[21];
0249 } xcb_dpms_info_notify_event_t;
0250 
0251 /**
0252  *
0253  * @param c The connection
0254  * @return A cookie
0255  *
0256  * Delivers a request to the X server.
0257  *
0258  */
0259 xcb_dpms_get_version_cookie_t
0260 xcb_dpms_get_version (xcb_connection_t *c,
0261                       uint16_t          client_major_version,
0262                       uint16_t          client_minor_version);
0263 
0264 /**
0265  *
0266  * @param c The connection
0267  * @return A cookie
0268  *
0269  * Delivers a request to the X server.
0270  *
0271  * This form can be used only if the request will cause
0272  * a reply to be generated. Any returned error will be
0273  * placed in the event queue.
0274  */
0275 xcb_dpms_get_version_cookie_t
0276 xcb_dpms_get_version_unchecked (xcb_connection_t *c,
0277                                 uint16_t          client_major_version,
0278                                 uint16_t          client_minor_version);
0279 
0280 /**
0281  * Return the reply
0282  * @param c      The connection
0283  * @param cookie The cookie
0284  * @param e      The xcb_generic_error_t supplied
0285  *
0286  * Returns the reply of the request asked by
0287  *
0288  * The parameter @p e supplied to this function must be NULL if
0289  * xcb_dpms_get_version_unchecked(). is used.
0290  * Otherwise, it stores the error if any.
0291  *
0292  * The returned value must be freed by the caller using free().
0293  */
0294 xcb_dpms_get_version_reply_t *
0295 xcb_dpms_get_version_reply (xcb_connection_t               *c,
0296                             xcb_dpms_get_version_cookie_t   cookie  /**< */,
0297                             xcb_generic_error_t           **e);
0298 
0299 /**
0300  *
0301  * @param c The connection
0302  * @return A cookie
0303  *
0304  * Delivers a request to the X server.
0305  *
0306  */
0307 xcb_dpms_capable_cookie_t
0308 xcb_dpms_capable (xcb_connection_t *c);
0309 
0310 /**
0311  *
0312  * @param c The connection
0313  * @return A cookie
0314  *
0315  * Delivers a request to the X server.
0316  *
0317  * This form can be used only if the request will cause
0318  * a reply to be generated. Any returned error will be
0319  * placed in the event queue.
0320  */
0321 xcb_dpms_capable_cookie_t
0322 xcb_dpms_capable_unchecked (xcb_connection_t *c);
0323 
0324 /**
0325  * Return the reply
0326  * @param c      The connection
0327  * @param cookie The cookie
0328  * @param e      The xcb_generic_error_t supplied
0329  *
0330  * Returns the reply of the request asked by
0331  *
0332  * The parameter @p e supplied to this function must be NULL if
0333  * xcb_dpms_capable_unchecked(). is used.
0334  * Otherwise, it stores the error if any.
0335  *
0336  * The returned value must be freed by the caller using free().
0337  */
0338 xcb_dpms_capable_reply_t *
0339 xcb_dpms_capable_reply (xcb_connection_t           *c,
0340                         xcb_dpms_capable_cookie_t   cookie  /**< */,
0341                         xcb_generic_error_t       **e);
0342 
0343 /**
0344  *
0345  * @param c The connection
0346  * @return A cookie
0347  *
0348  * Delivers a request to the X server.
0349  *
0350  */
0351 xcb_dpms_get_timeouts_cookie_t
0352 xcb_dpms_get_timeouts (xcb_connection_t *c);
0353 
0354 /**
0355  *
0356  * @param c The connection
0357  * @return A cookie
0358  *
0359  * Delivers a request to the X server.
0360  *
0361  * This form can be used only if the request will cause
0362  * a reply to be generated. Any returned error will be
0363  * placed in the event queue.
0364  */
0365 xcb_dpms_get_timeouts_cookie_t
0366 xcb_dpms_get_timeouts_unchecked (xcb_connection_t *c);
0367 
0368 /**
0369  * Return the reply
0370  * @param c      The connection
0371  * @param cookie The cookie
0372  * @param e      The xcb_generic_error_t supplied
0373  *
0374  * Returns the reply of the request asked by
0375  *
0376  * The parameter @p e supplied to this function must be NULL if
0377  * xcb_dpms_get_timeouts_unchecked(). is used.
0378  * Otherwise, it stores the error if any.
0379  *
0380  * The returned value must be freed by the caller using free().
0381  */
0382 xcb_dpms_get_timeouts_reply_t *
0383 xcb_dpms_get_timeouts_reply (xcb_connection_t                *c,
0384                              xcb_dpms_get_timeouts_cookie_t   cookie  /**< */,
0385                              xcb_generic_error_t            **e);
0386 
0387 /**
0388  *
0389  * @param c The connection
0390  * @return A cookie
0391  *
0392  * Delivers a request to the X server.
0393  *
0394  * This form can be used only if the request will not cause
0395  * a reply to be generated. Any returned error will be
0396  * saved for handling by xcb_request_check().
0397  */
0398 xcb_void_cookie_t
0399 xcb_dpms_set_timeouts_checked (xcb_connection_t *c,
0400                                uint16_t          standby_timeout,
0401                                uint16_t          suspend_timeout,
0402                                uint16_t          off_timeout);
0403 
0404 /**
0405  *
0406  * @param c The connection
0407  * @return A cookie
0408  *
0409  * Delivers a request to the X server.
0410  *
0411  */
0412 xcb_void_cookie_t
0413 xcb_dpms_set_timeouts (xcb_connection_t *c,
0414                        uint16_t          standby_timeout,
0415                        uint16_t          suspend_timeout,
0416                        uint16_t          off_timeout);
0417 
0418 /**
0419  *
0420  * @param c The connection
0421  * @return A cookie
0422  *
0423  * Delivers a request to the X server.
0424  *
0425  * This form can be used only if the request will not cause
0426  * a reply to be generated. Any returned error will be
0427  * saved for handling by xcb_request_check().
0428  */
0429 xcb_void_cookie_t
0430 xcb_dpms_enable_checked (xcb_connection_t *c);
0431 
0432 /**
0433  *
0434  * @param c The connection
0435  * @return A cookie
0436  *
0437  * Delivers a request to the X server.
0438  *
0439  */
0440 xcb_void_cookie_t
0441 xcb_dpms_enable (xcb_connection_t *c);
0442 
0443 /**
0444  *
0445  * @param c The connection
0446  * @return A cookie
0447  *
0448  * Delivers a request to the X server.
0449  *
0450  * This form can be used only if the request will not cause
0451  * a reply to be generated. Any returned error will be
0452  * saved for handling by xcb_request_check().
0453  */
0454 xcb_void_cookie_t
0455 xcb_dpms_disable_checked (xcb_connection_t *c);
0456 
0457 /**
0458  *
0459  * @param c The connection
0460  * @return A cookie
0461  *
0462  * Delivers a request to the X server.
0463  *
0464  */
0465 xcb_void_cookie_t
0466 xcb_dpms_disable (xcb_connection_t *c);
0467 
0468 /**
0469  *
0470  * @param c The connection
0471  * @return A cookie
0472  *
0473  * Delivers a request to the X server.
0474  *
0475  * This form can be used only if the request will not cause
0476  * a reply to be generated. Any returned error will be
0477  * saved for handling by xcb_request_check().
0478  */
0479 xcb_void_cookie_t
0480 xcb_dpms_force_level_checked (xcb_connection_t *c,
0481                               uint16_t          power_level);
0482 
0483 /**
0484  *
0485  * @param c The connection
0486  * @return A cookie
0487  *
0488  * Delivers a request to the X server.
0489  *
0490  */
0491 xcb_void_cookie_t
0492 xcb_dpms_force_level (xcb_connection_t *c,
0493                       uint16_t          power_level);
0494 
0495 /**
0496  *
0497  * @param c The connection
0498  * @return A cookie
0499  *
0500  * Delivers a request to the X server.
0501  *
0502  */
0503 xcb_dpms_info_cookie_t
0504 xcb_dpms_info (xcb_connection_t *c);
0505 
0506 /**
0507  *
0508  * @param c The connection
0509  * @return A cookie
0510  *
0511  * Delivers a request to the X server.
0512  *
0513  * This form can be used only if the request will cause
0514  * a reply to be generated. Any returned error will be
0515  * placed in the event queue.
0516  */
0517 xcb_dpms_info_cookie_t
0518 xcb_dpms_info_unchecked (xcb_connection_t *c);
0519 
0520 /**
0521  * Return the reply
0522  * @param c      The connection
0523  * @param cookie The cookie
0524  * @param e      The xcb_generic_error_t supplied
0525  *
0526  * Returns the reply of the request asked by
0527  *
0528  * The parameter @p e supplied to this function must be NULL if
0529  * xcb_dpms_info_unchecked(). is used.
0530  * Otherwise, it stores the error if any.
0531  *
0532  * The returned value must be freed by the caller using free().
0533  */
0534 xcb_dpms_info_reply_t *
0535 xcb_dpms_info_reply (xcb_connection_t        *c,
0536                      xcb_dpms_info_cookie_t   cookie  /**< */,
0537                      xcb_generic_error_t    **e);
0538 
0539 /**
0540  *
0541  * @param c The connection
0542  * @return A cookie
0543  *
0544  * Delivers a request to the X server.
0545  *
0546  * This form can be used only if the request will not cause
0547  * a reply to be generated. Any returned error will be
0548  * saved for handling by xcb_request_check().
0549  */
0550 xcb_void_cookie_t
0551 xcb_dpms_select_input_checked (xcb_connection_t *c,
0552                                uint32_t          event_mask);
0553 
0554 /**
0555  *
0556  * @param c The connection
0557  * @return A cookie
0558  *
0559  * Delivers a request to the X server.
0560  *
0561  */
0562 xcb_void_cookie_t
0563 xcb_dpms_select_input (xcb_connection_t *c,
0564                        uint32_t          event_mask);
0565 
0566 
0567 #ifdef __cplusplus
0568 }
0569 #endif
0570 
0571 #endif
0572 
0573 /**
0574  * @}
0575  */