gdk-Graphics-Contexts {RGtk2} | R Documentation |
Objects to encapsulate drawing properties
gdkGCNew(drawable)
gdkGCNewWithValues(object, values)
gdkGCGetScreen(object)
gdkGCSetValues(object, values)
gdkGCGetValues(object)
gdkGCSetForeground(object, color)
gdkGCSetBackground(object, color)
gdkGCSetRgbFgColor(object, color)
gdkGCSetRgbBgColor(object, color)
gdkGCSetFont(object, font)
gdkGCSetFunction(object, fun)
gdkGCSetFill(object, fill)
gdkGCSetTile(object, tile)
gdkGCSetStipple(object, stipple)
gdkGCSetTsOrigin(object, x, y)
gdkGCSetClipOrigin(object, x, y)
gdkGCSetClipMask(object, mask)
gdkGCSetClipRectangle(object, rectangle)
gdkGCSetClipRegion(object, region)
gdkGCSetSubwindow(object, mode)
gdkGCSetExposures(object, exposures)
gdkGCSetLineAttributes(object, line.width, line.style, cap.style, join.style)
gdkGCSetDashes(object, dash.list)
gdkGCCopy(object, src.gc)
gdkGCSetColormap(object, colormap)
gdkGCGetColormap(object)
gdkGCOffset(object, x.offset, y.offset)
gdkGC(drawable)
GObject +----GdkGC
All drawing operations in GDK take a graphics context (GC) argument. A graphics context encapsulates information about the way things are drawn, such as the foreground color or line width. By using graphics contexts, the number of arguments to each drawing call is greatly reduced, and communication overhead is minimized, since identical arguments do not need to be passed repeatedly.
Most values of a graphics context can be set at
creation time by using gdkGCNewWithValues
,
or can be set one-by-one using functions such
as gdkGCSetForeground
. A few of the values
in the GC, such as the dash pattern, can only
be set by the latter method.
GdkGC
GdkGC
structure represents a graphics context.
It is an opaque structure with no user-visible
elements.
GdkGCValues
GdkGCValues
structure holds a set of values used
to create or modify a graphics context.
GdkGCValues
is a transparent-type.
foreground
GdkColor
] the foreground color. Note that gdkGCGetValues
only sets the pixel value.background
GdkColor
] the background color. Note that gdkGCGetValues
only sets the pixel value.font
GdkFont
] the default font.function
GdkFunction
] the bitwise operation used when drawing.fill
GdkFill
] the fill style.tile
GdkPixmap
] the tile pixmap.stipple
GdkPixmap
] the stipple bitmap.clip_mask
GdkPixmap
] the clip mask bitmap.subwindow_mode
GdkSubwindowMode
] the subwindow mode.ts_x_origin
ts_y_origin
clip_x_origin
clip_y_origin
graphics_exposures
line_width
line_style
GdkLineStyle
] the way dashed lines are drawn.cap_style
GdkCapStyle
] the way the ends of lines are drawn.join_style
GdkJoinStyle
] the way joins between lines are drawn.
gdkGC
is the equivalent of gdkGCNew
.
GdkGCValuesMask
GdkGCValues
structure are set.
foreground
foreground
is set.background
background
is set.font
font
is set.function
function
is set.fill
fill
is set.tile
tile
is set.stipple
stipple
is set.clip-mask
clip.mask
is set.subwindow
subwindow.mode
is set.ts-x-origin
ts.x.origin
is set.ts-y-origin
ts.y.origin
is set.clip-x-origin
clip.x.origin
is set.clip-y-origin
clip.y.origin
is set.exposures
graphics.exposures
is set.line-width
line.width
is set.line-style
line.style
is set.cap-style
cap.style
is set.join-style
join.style
is set.
GdkFunction
GDK_COPY
, GDK_XOR
and GDK_INVERT
are generally
useful. For bitmaps, GDK_AND
and GDK_OR
are also useful.
copy
dst = src
invert
dst = NOT dst
xor
dst = src XOR dst
clear
dst = 0
and
dst = dst AND src
and-reverse
dst = src AND (NOT dst)
and-invert
dst = (NOT src) AND dst
noop
dst = dst
or
dst = src OR dst
equiv
dst = (NOT src) XOR dst
or-reverse
dst = src OR (NOT dst)
copy-invert
dst = NOT src
or-invert
dst = (NOT src) OR dst
nand
dst = (NOT src) OR (NOT dst)
nor
dst = (NOT src) AND (NOT dst)
set
dst = 1
GdkFill
solid
tiled
stippled
opaque-stippled
GdkSubwindowMode
clip-by-children
include-inferiors
GdkLineStyle
solid
on-off-dash
double-dash
GDK_SOLID
, or in the background
color masked by the stipple if the fill style is GDK_STIPPLED
.
GdkCapStyle
not-last
GDK_CAP_BUTT
for lines of non-zero width.
for zero width lines, the final point on the line will not be drawn.butt
round
projecting
GdkJoinStyle
miter
round
bevel
Derived by RGtkGen from GTK+ documentation
http://developer.gnome.org/doc/API/2.0/gdk/gdk-Graphics-Contexts.html