The function returns the actual type of the property; the actual format of the property; the number of 8-bit, 16-bit, or 32-bit items transferred; the number of bytes remaining to be read in the property; and a pointer to the data actually returned. sets the return arguments as follows:
•
If the specified property does not exist for the specified window, returns to actual_type_return and the value zero to actual_format_return and bytes_after_return. The nitems_return argument is empty. In this case, the delete argument is ignored.
•
If the specified property exists but its type does not match the specified type, returns the actual property type to actual_type_return, the actual property format (never zero) to actual_format_return, and the property length in bytes (even if the actual_format_return is 16 or 32) to bytes_after_return. It also ignores the delete argument. The nitems_return argument is empty.
•
If the specified property exists and either you assign to the req_type argument or the specified type matches the actual property type, returns the actual property type to actual_type_return and the actual property format (never zero) to actual_format_return. It also returns a value to bytes_after_return and nitems_return, by defining the following values:
N = actual length of the stored property in bytes
(even if the format is 16 or 32)
I = 4 * long_offset
T = N - I
L = MINIMUM(T, 4 * long_length)
A = N - (I + L)
The returned value starts at byte index I in the property (indexing from zero), and its length in bytes is L. If the value for long_offset causes L to be negative, a error results. The value of bytes_after_return is A, giving the number of trailing unread bytes in the stored property.
If the returned format is 8, the returned data is represented as a array. If the returned format is 16, the returned data is represented as a array and should be cast to that type to obtain the elements. If the returned format is 32, the returned data is represented as a array and should be cast to that type to obtain the elements.
always allocates one extra byte in prop_return (even if the property is zero length) and sets it to zero so that simple properties consisting of characters do not have to be copied into yet another string before use.
If delete is and bytes_after_return is zero, deletes the property from the window and generates a event on the window.
The function returns if it executes successfully. To free the resulting data, use
can generate and errors.
The function returns a pointer to an array of atom properties that are defined for the specified window or returns NULL if no properties were found. To free the memory allocated by this function, use
can generate a error.
The function alters the property for the specified window and causes the X server to generate a event on that window. performs the following:
•
If mode is discards the previous property value and stores the new data.
•
If mode is or inserts the specified data before the beginning of the existing data or onto the end of the existing data, respectively. The type and format must match the existing property value, or a error results. If the property is undefined, it is treated as defined with the correct type and format with zero-length data.
If the specified format is 8, the property data must be a array. If the specified format is 16, the property data must be a array. If the specified format is 32, the property data must be a array.
The lifetime of a property is not tied to the storing client. Properties remain until explicitly deleted, until the window is destroyed, or until the server resets. For a discussion of what happens when the connection to the X server is closed, see section 2.6. The maximum size of a property is server dependent and can vary dynamically depending on the amount of memory the server has available. (If there is insufficient space, a error results.)
can generate and errors.
The function allows you to rotate properties on a window and causes the X server to generate events. If the property names in the properties array are viewed as being numbered starting from zero and if there are num_prop property names in the list, then the value associated with property name I becomes the value associated with property name (I + npositions) mod N for all I from zero to N - 1. The effect is to rotate the states by npositions places around the virtual ring of property names (right for positive npositions, left for negative npositions). If npositions mod N is nonzero, the X server generates a event for each property in the order that they are listed in the array. If an atom occurs more than once in the list or no property with that name is defined for the window, a error results. If a or error results, no properties are changed.
can generate and errors.
The function deletes the specified property only if the property was defined on the specified window and causes the X server to generate a event on the window unless the property does not exist.
can generate and errors.