gdk-Graphics-Contexts         package:RGtk2         R Documentation

_G_r_a_p_h_i_c_s _C_o_n_t_e_x_t_s

_D_e_s_c_r_i_p_t_i_o_n:

     Objects to encapsulate drawing properties

_M_e_t_h_o_d_s _a_n_d _F_u_n_c_t_i_o_n_s:

     '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)'

_H_i_e_r_a_r_c_h_y:

     GObject
        +----GdkGC 

_D_e_t_a_i_l_e_d _D_e_s_c_r_i_p_t_i_o_n:

     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.

_S_t_r_u_c_t_u_r_e_s:


     '_G_d_k_G_C' The 'GdkGC' structure represents a graphics context. It is
          an opaque structure with no user-visible elements.


     '_G_d_k_G_C_V_a_l_u_e_s' The 'GdkGCValues' structure holds a set of values
          used to create or modify a graphics context. *'GdkGCValues'
          is a transparent-type.*

          '_f_o_r_e_g_r_o_u_n_d' ['GdkColor'] the foreground color. Note that
               'gdkGCGetValues' only sets the pixel value.

          '_b_a_c_k_g_r_o_u_n_d' ['GdkColor'] the background color. Note that
               'gdkGCGetValues' only sets the pixel value.

          '_f_o_n_t' ['GdkFont'] the default font.

          '_f_u_n_c_t_i_o_n' ['GdkFunction'] the bitwise operation used when
               drawing.

          '_f_i_l_l' ['GdkFill'] the fill style.

          '_t_i_l_e' ['GdkPixmap'] the tile pixmap.

          '_s_t_i_p_p_l_e' ['GdkPixmap'] the stipple bitmap.

          '_c_l_i_p__m_a_s_k' ['GdkPixmap'] the clip mask bitmap.

          '_s_u_b_w_i_n_d_o_w__m_o_d_e' ['GdkSubwindowMode'] the subwindow mode.

          '_t_s__x__o_r_i_g_i_n' [integer] the x origin of the tile or stipple.

          '_t_s__y__o_r_i_g_i_n' [integer] the y origin of the tile or stipple.

          '_c_l_i_p__x__o_r_i_g_i_n' [integer] the x origin of the clip mask.

          '_c_l_i_p__y__o_r_i_g_i_n' [integer] the y origin of the clip mask.

          '_g_r_a_p_h_i_c_s__e_x_p_o_s_u_r_e_s' [integer] whether graphics exposures are
               enabled.

          '_l_i_n_e__w_i_d_t_h' [integer] the line width.

          '_l_i_n_e__s_t_y_l_e' ['GdkLineStyle'] the way dashed lines are drawn.

          '_c_a_p__s_t_y_l_e' ['GdkCapStyle'] the way the ends of lines are
               drawn.

          '_j_o_i_n__s_t_y_l_e' ['GdkJoinStyle'] the way joins between lines are
               drawn.


_C_o_n_v_e_n_i_e_n_t _C_o_n_s_t_r_u_c_t_i_o_n:

     'gdkGC' is the equivalent of 'gdkGCNew'.

_E_n_u_m_s _a_n_d _F_l_a_g_s:


     '_G_d_k_G_C_V_a_l_u_e_s_M_a_s_k' A set of bit flags used to indicate which fields
          'GdkGCValues' structure are set.

          '_f_o_r_e_g_r_o_u_n_d' the 'foreground' is set.

          '_b_a_c_k_g_r_o_u_n_d' the 'background' is set.

          '_f_o_n_t' the 'font' is set.

          '_f_u_n_c_t_i_o_n' the 'function' is set.

          '_f_i_l_l' the 'fill' is set.

          '_t_i_l_e' the 'tile' is set.

          '_s_t_i_p_p_l_e' the 'stipple' is set.

          '_c_l_i_p-_m_a_s_k' the 'clip.mask' is set.

          '_s_u_b_w_i_n_d_o_w' the 'subwindow.mode' is set.

          '_t_s-_x-_o_r_i_g_i_n' the 'ts.x.origin' is set.

          '_t_s-_y-_o_r_i_g_i_n' the 'ts.y.origin' is set.

          '_c_l_i_p-_x-_o_r_i_g_i_n' the 'clip.x.origin' is set.

          '_c_l_i_p-_y-_o_r_i_g_i_n' the 'clip.y.origin' is set.

          '_e_x_p_o_s_u_r_e_s' the 'graphics.exposures' is set.

          '_l_i_n_e-_w_i_d_t_h' the 'line.width' is set.

          '_l_i_n_e-_s_t_y_l_e' the 'line.style' is set.

          '_c_a_p-_s_t_y_l_e' the 'cap.style' is set.

          '_j_o_i_n-_s_t_y_l_e' the 'join.style' is set.


     '_G_d_k_F_u_n_c_t_i_o_n' Determines how the bit values for the source pixels
          are combined with the bit values for destination pixels to
          produce the final result. The sixteen values here correspond
          to the 16 different possible 2x2 truth tables.  Only a couple
          of these values are usually useful; for colored images, only
          'GDK_COPY', 'GDK_XOR' and 'GDK_INVERT' are generally useful.
          For bitmaps, 'GDK_AND' and 'GDK_OR' are also useful.

          '_c_o_p_y' 'dst = src'

          '_i_n_v_e_r_t' 'dst = NOT dst'

          '_x_o_r' 'dst = src XOR dst'

          '_c_l_e_a_r' 'dst = 0'

          '_a_n_d' 'dst = dst AND src'

          '_a_n_d-_r_e_v_e_r_s_e' 'dst = src AND (NOT dst)'

          '_a_n_d-_i_n_v_e_r_t' 'dst = (NOT src) AND dst'

          '_n_o_o_p' 'dst = dst'

          '_o_r' 'dst = src OR dst'

          '_e_q_u_i_v' 'dst = (NOT src) XOR dst'

          '_o_r-_r_e_v_e_r_s_e' 'dst = src OR (NOT dst)'

          '_c_o_p_y-_i_n_v_e_r_t' 'dst = NOT src'

          '_o_r-_i_n_v_e_r_t' 'dst = (NOT src) OR dst'

          '_n_a_n_d' 'dst = (NOT src) OR (NOT dst)'

          '_n_o_r' 'dst = (NOT src) AND (NOT dst)'

          '_s_e_t' 'dst = 1'


     '_G_d_k_F_i_l_l' Determines how primitives are drawn.

          '_s_o_l_i_d' draw with the foreground color.

          '_t_i_l_e_d' draw with a tiled pixmap.

          '_s_t_i_p_p_l_e_d' draw using the stipple bitmap. Pixels
               corresponding to bits in the stipple bitmap that are set
               will be drawn in the foreground color; pixels
               corresponding to bits that are not set will be left
               untouched.

          '_o_p_a_q_u_e-_s_t_i_p_p_l_e_d' draw using the stipple bitmap. Pixels
               corresponding to bits in the stipple bitmap that are set
               will be drawn in the foreground color; pixels
               corresponding to bits that are not set will be drawn
               with the background color.


     '_G_d_k_S_u_b_w_i_n_d_o_w_M_o_d_e' Determines how drawing onto a window will
          affect child windows of that window. 

          '_c_l_i_p-_b_y-_c_h_i_l_d_r_e_n' only draw onto the window itself.

          '_i_n_c_l_u_d_e-_i_n_f_e_r_i_o_r_s' draw onto the window and child windows.


     '_G_d_k_L_i_n_e_S_t_y_l_e' Determines how lines are drawn.

          '_s_o_l_i_d' lines are drawn solid.

          '_o_n-_o_f_f-_d_a_s_h' even segments are drawn; odd segments are not
               drawn.

          '_d_o_u_b_l_e-_d_a_s_h' even segments are normally. Odd segments are
               drawn in the background color if the fill style is
               'GDK_SOLID', or in the background color masked by the
               stipple if the fill style is 'GDK_STIPPLED'.


     '_G_d_k_C_a_p_S_t_y_l_e' Determines how the end of lines are drawn.

          '_n_o_t-_l_a_s_t' the same as 'GDK_CAP_BUTT' for lines of non-zero
               width. for zero width lines, the final point on the line
               will not be drawn.

          '_b_u_t_t' the ends of the lines are drawn squared off and
               extending to the coordinates of the end point.

          '_r_o_u_n_d' the ends of the lines are drawn as semicircles with
               the diameter equal to the line width and centered at the
               end point.

          '_p_r_o_j_e_c_t_i_n_g' the ends of the lines are drawn squared off and
               extending half the width of the line beyond the end
               point.


     '_G_d_k_J_o_i_n_S_t_y_l_e' Determines how the joins between segments of a
          polygon are drawn.

          '_m_i_t_e_r' the sides of each line are extended to meet at an
               angle.

          '_r_o_u_n_d' the sides of the two lines are joined by a circular
               arc.

          '_b_e_v_e_l' the sides of the two lines are joined by a straight
               line which makes an equal angle with each line.


_A_u_t_h_o_r(_s):

     Derived by RGtkGen from GTK+ documentation

_R_e_f_e_r_e_n_c_e_s:

     <URL:
     http://developer.gnome.org/doc/API/2.0/gdk/gdk-Graphics-Contexts.html>

