/* examples/misc/tips.c */ #include He_node *princ, *panel, *canvas, *tmp; int main (int argc, char *argv[]) { HeInit (&argc, &argv); princ = HeCreateFrame (); HeSetFrameLabel (princ, "Petits conseils (tips)"); panel = HeCreatePanel (princ); tmp = HeCreateButtonP (panel, "Bouton", NULL, NULL); HeSetTip (tmp, "Ceci est un bouton"); tmp = HeCreateToggleLedP (panel, "Led", NULL, TRUE); HeSetTip (tmp, "Ceci est un led"); tmp = HeCreateMessageP (panel, "Message", TRUE); HeSetTip (tmp, "Ceci est un message"); HeSetPanelLayout (panel, HE_LINE_FEED); tmp = HeCreateText (panel); HeSetTextValue (tmp, "Champ de saisie"); HeSetTip (tmp, "Ceci est un champ text"); HeFit (panel); canvas = HeCreateCanvas (princ); HeJustify (canvas, panel, HE_TOP); HeExpand (canvas, NULL, HE_BOTTOM_RIGHT); HeSetTip (canvas, "Les tips fonctionnent aussi\n" "pour les Canvas et les GLArea"); return HeMainLoop (princ); }