XDrawRectangle
NAMESYNTAX
ARGUMENTS
DESCRIPTION
STRUCTURES
DIAGNOSTICS
SEE ALSO
NAME
XDrawRectangle, XDrawRectangles, XRectangle − draw rectangles and rectangles structure
SYNTAX
int XDrawRectangle(Display *display, Drawable d, GC gc, int x, int y, unsigned int width, unsigned int height); | |
int XDrawRectangles(Display *display, Drawable d, GC gc, XRectangle rectangles[], int nrectangles); |
ARGUMENTS
d |
Specifies the drawable. |
|||
display |
Specifies the connection to the X server. |
|||
gc |
Specifies the GC. |
nrectangles
Specifies the number of rectangles in the array.
rectangles
Specifies an array of rectangles.
width |
|||
height |
Specify the width and height, which specify the dimensions of the rectangle. | ||
x |
|||
y |
Specify the x and y coordinates, which specify the upper-left corner of the rectangle. |
DESCRIPTION
The XDrawRectangle and XDrawRectangles functions draw the outlines of the specified rectangle or rectangles as if a five-point PolyLine protocol request were specified for each rectangle:
[x,y] [x+width,y] [x+width,y+height] [x,y+height] [x,y]
For the specified rectangle or rectangles, these functions do not draw a pixel more than once. XDrawRectangles draws the rectangles in the order listed in the array. If rectangles intersect, the intersecting pixels are drawn multiple times.
Both functions use these GC components: function, plane-mask, line-width, line-style, cap-style, join-style, fill-style, subwindow-mode, clip-x-origin, clip-y-origin, and clip-mask. They also use these GC mode-dependent components: foreground, background, tile, stipple, tile-stipple-x-origin, tile-stipple-y-origin, dash-offset, and dash-list.
XDrawRectangle and XDrawRectangles can generate BadDrawable, BadGC, and BadMatch errors.
STRUCTURES
The XRectangle structure contains:
typedef struct {
short x, y; | |
unsigned short width, height; |
} XRectangle;
All x and y members are signed integers. The width and height members are 16-bit unsigned integers. You should be careful not to generate coordinates and sizes out of the 16-bit ranges, because the protocol only has 16-bit fields for these values.
DIAGNOSTICS
BadDrawable
A value for a Drawable argument does not name a defined Window or Pixmap.
BadGC |
A value for a GContext argument does not name a defined GContext. | ||
BadMatch |
An InputOnly window is used as a Drawable. | ||
BadMatch |
Some argument or pair of arguments has the correct type and range but fails to match in some other way required by the request. |
SEE ALSO
XDrawArc(3),
XDrawLine(3), XDrawPoint(3)
Xlib − C Language X Interface
More Linux Commands
manpages/gnutls_record_get_direction.3.html
gnutls_record_get_direction(3) - API function (Man Page)....
This function provides information about the internals of the record protocol and is only useful if a prior gnutls function call (e.g. gnutls_handshake()) was i
manpages/hcidump.1.html
hcidump(1) Parse HCI data (Commands - Linux manual page)....
hcidump reads raw HCI data coming from and going to a Bluetooth device (which can be specified with the option -i, default is the first available one) and print
manpages/com_err.3.html
com_err(3) - common error display routine - Linux man page
Com_err displays an error message on the standard error stream stderr (see stdio(3S)) composed of the whoami string, which should specify the program name or so
manpages/ber_put_ostring.3.html
ber_put_ostring(3) - OpenLDAP LBER simplified Basic Encoding
These routines provide a subroutine interface to a simplified implementation of the Basic Encoding Rules of ASN.1. The version of BER these routines support is
manpages/MIME::Parser::Results.3pm.html
MIME::Parser::Results(3pm) - results of the last entity pars
Results from the last MIME::Parser parse. PUBLIC INTERFACE new Constructor. msgs Instance method. Return all messages that we logged, in order. Every message is
manpages/macros.jpackage.7.html
macros.jpackage(7) - RPM macros for Java packagers and devel
This is a library of generic rpm macros which should be used on jpackage.org compatible distributions. FILES /etc/rpm/macros.jpackage Definitions of macros. For
manpages/gnutls_x509_crt_import_pkcs11_url.3.html
gnutls_x509_crt_import_pkcs11_url(3) - API function.........
This function will import a PKCS 11 certificate directly from a token without involving the gnutls_pkcs11_obj_t structure. This function will fail if the certif
manpages/libutempter.8.html
libutempter(8) privileged helper program for utmp wtmp updat
libutempter.8 - utempter is a privileged helper program that writes utmp/wtmp entries for unprivileged programs. OPTIONS The following options are supported: -a
manpages/clearok.3ncurses.html
clearok(3ncurses) - curses output options - Linux man page
These routines set options that change the style of output within curses. All options are initially FALSE, unless otherwise stated. It is not necessary to turn
manpages/fslsfonts.1.html
fslsfonts(1) - list fonts served by X font server (ManPage)
fslsfonts lists the fonts that match the given pattern. The wildcard character * may be used to match any sequence of characters (including none), and ? to matc
manpages/setsyx.3ncurses.html
setsyx(3ncurses) - low-level curses routines (Man Page).....
The following routines give low-level access to various curses capabilities. These routines typically are used inside library routines. The def_prog_mode and de
manpages/bkgrnd.3ncurses.html
bkgrnd(3ncurses) - curses window complex background manipula
The bkgrndset and wbkgrndset routines manipulate the background of the named window. The window background is a cchar_t consisting of any combination of attribu
