tk2tip                package:tcltk2                R Documentation

_D_i_s_p_l_a_y _a_n_d _m_a_n_a_g_e _t_o_o_l_t_i_p_s _i_n _t_k _w_i_d_g_e_t_s

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

     'tk2tip' provides a simple mechanism to display tooltips on tk
     widgets when the mouse hoover on top of them.

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

       tk2tip(widget, message)
       tk2killtip()

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

  widget: The widget to which a tooltip is attached 

 message: The message of the tooltip ("" to remove the tooltip) 

_N_o_t_e:

     This implementation is done in pure tcl code

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

     Philippe Grosjean

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

     'tk2widgets', 'tk2theme'

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

       ## Not run: 
         ## These cannot be run by examples() but should be OK when pasted
         ## into an interactive R session with the tcltk package loaded

             tt2 <- tktoplevel()
         lb <- tk2label(tt2, text = "Move mouse over me, or over the button to see tooltip")
         tkgrid(lb)
         tk2tip(lb, "A tooltip for the label \ndisplayed on two lines")
         but <- tk2button(tt2, text = "OK", width = 10,
             command = function() tkdestroy(tt2))
         tkgrid(but)
         tk2tip(but, "Another tooltip for the button")
         #### TO DO: show the use of tk2killtip()!
       ## End(Not run)

