genRCode        package:RGtkBindingGenerator        R Documentation

_G_e_n_e_r_a_t_e _S _a_n_d _C _i_n_t_e_r_f_a_c_e _c_o_d_e _f_o_r _a _C _r_o_u_t_i_n_e

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

     These functions generate S and C code that interface to a Gtk
     function defined in the .defs files. These are the glue between
     the interactive S language and the raw Gtk method definined in the
     C library.

_U_s_a_g_e:

     genRCode(fun, defs, name, sname, className = NULL, package = "RGtk")
     genCCode(fun, defs, name) 

_A_r_g_u_m_e_n_t_s:

     fun: the definition of the C routine for which we are generating
          either the S or C interface. This is an object of class
          'FunctionDef' that is created by reading the .defs files.

    defs: the collection of all the definitions read from .defs files,
          including classes, functions, enumerations, etc.

    name: the name of the C routine for which the interface is being
          generated.

   sname: the name of the S function to create.

className: not used.

 package: the name of the S package in which the S code will be
          located. This is used as the value of 'PACKAGE' argument when
          calling the associated C interface routine via a '.GtkCall'.

_V_a_l_u_e:

     'genRCode' returns string giving the full definition of the S
     function that interfaces to the C routine. This includes the
     assignment to the appropriate function name. 'genCCode' returns a
     list with two elements: 

    code: a string giving the full definition of the S-C interface
          routine that interfaces to the underlying C routine. This can
          be put into a .c file, compiled and accessed from S via
          '.GtkCall'.

    decl: a string giving the declaration of the S-C interface routine
          which can be used in a header file (.h). This can be used
          when creating the registration table of routines in the
          generated package.

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

     Duncan Temple Lang <duncan@research.bell-labs.com>

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

     <URL: http://www.omegahat.org/RGtk>, <URL:
     http://www.omegahat.org/RGtkBindingGenerator>, <URL:
     http://www.gtk.org> <URL: http://www.pygtk.org>(?)

_S_e_e _A_l_s_o:

     'genCode' 'generateCodeFiles'

_E_x_a_m_p_l_e_s:

