home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #18 / NN_1992_18.iso / spool / comp / windows / x / motif / 5671 < prev    next >
Encoding:
Text File  |  1992-08-17  |  1.9 KB  |  60 lines

  1. Path: sparky!uunet!mcsun!corton!cenaath.cena.dgac.fr!stna.dgac.fr!quinton
  2. From: quinton@stna.dgac.fr (Marc Quinton STNA 7SU p8046 BD24)
  3. Newsgroups: comp.windows.x.motif
  4. Subject: available : Motif terminal widget Term.
  5. Keywords: Motif, terminal, widget
  6. Message-ID: <1992Aug18.085245.10255@cenaath.cena.dgac.fr>
  7. Date: 18 Aug 92 08:52:45 GMT
  8. Sender: news@cenaath.cena.dgac.fr
  9. Organization: STNA 95 rue Henri Rochefort 91025 Evry Cedex 33(1)60.79.80.00
  10. Lines: 48
  11.  
  12.  
  13. You can find a sample implementation of a terminal widget for Motif at
  14.  
  15.     ftp.stna7.stna.dgac.fr file pub/Term-1.0.tar.Z
  16.  
  17. This Motif version is derived from CTW Widget from P. D. Fox. This is a color widget
  18. with vt100 emulation.
  19.  
  20. Here is an exemple of Term widget :
  21.  
  22. main(argc,argv)
  23. int argc;
  24. char **argv;
  25. {
  26.  
  27.     Widget top, term;
  28.  
  29.     top = XtInitialize("main","Term",NULL,0,&argc,argv);
  30.  
  31.     /* create the terminal widget */
  32.     term = XtVaCreateManagedWidget("Term",
  33.         termWidgetClass,    top,
  34.         XmNrows,        25,
  35.         XmNcolumns,        80,
  36.         XmNcommand,        "csh"
  37.         NULL);
  38.  
  39.     /* handle signal when sub shell is done */
  40.     XtAddSignalHandler(SIGCHLD, child_handler, term);
  41.  
  42.     /* handle signal applied to this process */
  43.     XtAddSignalHandler(SIGINT , int_handler, term);
  44.     XtAddSignalHandler(SIGTERM , int_handler, term);
  45.     XtAddSignalHandler(SIGHUP , int_handler, term);
  46.  
  47.     XtRealizeWidget(top);
  48.     XtMainLoop();
  49. } /* End main */
  50.  
  51. -- 
  52.  _____________________________________________________________________________
  53. |   ___    ___   |                  |                                         |
  54. |  /__ \  / __\  |   QUINTON Marc   | Technical Department of Civil Aviation  |
  55. |   __\ \/ /     |__________________|_________________________________________|
  56. |  / __   |   _  |                  |                                         |
  57. |  \ \_\   \_//  |   Evry France    | e_mail : quinton@stna7.stna.dgac.fr     |
  58. |   \___/\___/   |                  |                                         |
  59.  -----------------------------------------------------------------------------
  60.