home *** CD-ROM | disk | FTP | other *** search
/ Usenet 1994 January / usenetsourcesnewsgroupsinfomagicjanuary1994.iso / sources / x / volume2 / xtroff / patch3 / update.sh < prev    next >
Encoding:
Linux/UNIX/POSIX Shell Script  |  1988-11-14  |  27.3 KB  |  876 lines

  1. #! /bin/sh
  2. # Removing some junk files, and renaming the manual page
  3. if test -d xtroff ; then
  4.     cd xtroff
  5. fi
  6. if test -f suntroff.c -a -f xtroff.man ; then
  7.     thisdir=`pwd`
  8. else
  9.     echo 'Please cd to contrib/clients/xtroff before running this script'
  10.     exit 1
  11. fi
  12. rm -f Makefile.old Window.c Window.h WindowP.h make.out
  13. mv xtroff.man xtroff.manX
  14. cd XtStuff
  15. rm -f make.out
  16. cd $thisdir
  17. # Ok - this is the real thing.
  18. patch -p1 << \WhAt_A_mArOoN
  19. diff -r -c /h/xwindows/X/contrib/clients/xtroff/patchlevel.h xtroff/patchlevel.h
  20. *** /h/xwindows/X/contrib/clients/xtroff/patchlevel.h    Mon Sep 26 09:44:48 1988
  21. --- xtroff/patchlevel.h    Sat Nov 12 06:34:11 1988
  22. ***************
  23. *** 1,2 ****
  24. ! #define PATCHLEVEL 2
  25.   
  26. --- 1,2 ----
  27. ! #define PATCHLEVEL 3
  28.   
  29. Common subdirectories: /h/xwindows/X/contrib/clients/xtroff/Fixes and xtroff/Fixes
  30. diff -r -c /h/xwindows/X/contrib/clients/xtroff/Imakefile xtroff/Imakefile
  31. *** /h/xwindows/X/contrib/clients/xtroff/Imakefile    Thu Sep  1 01:57:40 1988
  32. --- xtroff/Imakefile    Sat Nov 12 06:27:36 1988
  33. ***************
  34. *** 33,39 ****
  35.   RSTFONTS=/usr/uturing/ron/rst
  36.   # Xfonts go here - wish the X11 server could read vfonts like 
  37.   # the X10 server used to.
  38. ! SUNTROFF_FONTS=/local/share/X11/fonts
  39.   #DEVICE=imp    #imagen
  40.   DEVICE=sun    #versatec - other printers like lw.
  41.   WIDTHDIR=/local/share/troff
  42. --- 33,39 ----
  43.   RSTFONTS=/usr/uturing/ron/rst
  44.   # Xfonts go here - wish the X11 server could read vfonts like 
  45.   # the X10 server used to.
  46. ! SUNTROFF_FONTS=/local/share/X11/fonts/xtroff
  47.   #DEVICE=imp    #imagen
  48.   DEVICE=sun    #versatec - other printers like lw.
  49.   WIDTHDIR=/local/share/troff
  50. ***************
  51. *** 65,76 ****
  52.   # These should be defined in an Imake.tmpl - except that the 
  53.   # normal Imake.tmpl insists on these being compiled in the 
  54.   # X directory tree.
  55. ! XAWLIB=$(USRLIBDIR)/libXaw.a
  56. ! XTOOLLIB=$(USRLIBDIR)/libXt.a
  57. ! XLIB=$(USRLIBDIR)/libX11.a
  58.   MATHLIB=-lm
  59.   
  60. ! FC = fc
  61.   XTSTUFF =     XtStuff/libXtStuff.a
  62.   OBJS1 =        xwindows.o suntroff.o parse.o font.o draw.o \
  63.           fixpoint.o curves.o
  64. --- 65,76 ----
  65.   # These should be defined in an Imake.tmpl - except that the 
  66.   # normal Imake.tmpl insists on these being compiled in the 
  67.   # X directory tree.
  68. ! #XAWLIB=$(USRLIBDIR)/libXaw.a
  69. ! #XTOOLLIB=$(USRLIBDIR)/libXt.a
  70. ! #XLIB=$(USRLIBDIR)/libX11.a
  71.   MATHLIB=-lm
  72.   
  73. ! FC = bdftosnf
  74.   XTSTUFF =     XtStuff/libXtStuff.a
  75.   OBJS1 =        xwindows.o suntroff.o parse.o font.o draw.o \
  76.           fixpoint.o curves.o
  77. ***************
  78. *** 79,92 ****
  79.   PROGRAMS =     xtroff
  80.   PREVIEWER =     xtroff
  81.   
  82. ! ComplexProgramTarget_1(xtroff,$(XTSTUFF) $(XAWLIB) $(XTOOLLIB) $(XLIB),$(MATHLIB))
  83.   
  84.   $(XTSTUFF):
  85.           cd XtStuff; make $(MFLAGS)            
  86.   
  87.   xfonts:
  88.           -mkdir $(SUNTROFF_FONTS)
  89. !         cd fontstuff; make $(MFLAGS) CFLAGS="$(CFLAGS)" \
  90.               VFONTS=$(VFONTS) \
  91.               RSTFONTS=$(RSTFONTS) PREVIEWER=$(PREVIEWER) \
  92.               FC=$(FC) PERCENT=$(PERCENT) \
  93. --- 79,99 ----
  94.   PROGRAMS =     xtroff
  95.   PREVIEWER =     xtroff
  96.   
  97. ! .SUFFIXES: .manX .man
  98.   
  99. + .manX.man:
  100. +     rm -f $*.man
  101. +     sed -e 's?WIDTHDIR?$(WIDTHDIR)?g'\
  102. +         -e 's?FONTDIR?$(SUNTROFF_FONTS)?g' $*.manX > $*.man
  103. + ComplexProgramTarget_1(xtroff,$(XTSTUFF) $(XAWLIB) $(XMULIB) $(XTOOLLIB) $(XLIB),$(MATHLIB))
  104.   $(XTSTUFF):
  105.           cd XtStuff; make $(MFLAGS)            
  106.   
  107.   xfonts:
  108.           -mkdir $(SUNTROFF_FONTS)
  109. !         cd fontstuff; make $(MFLAGS) CDEBUGFLAGS="$(CDEBUGFLAGS)" \
  110.               VFONTS=$(VFONTS) \
  111.               RSTFONTS=$(RSTFONTS) PREVIEWER=$(PREVIEWER) \
  112.               FC=$(FC) PERCENT=$(PERCENT) \
  113. ***************
  114. *** 106,111 ****
  115. --- 113,119 ----
  116.   clean::
  117.           cd XtStuff ; make $(MFLAGS) clean
  118.           cd fontstuff ; make $(MFLAGS) clean
  119. +         rm -f xtroff.man
  120.   
  121.   depend::
  122.           cd XtStuff; make $(MFLAGS) depend
  123. Only in xtroff: RCS
  124. Common subdirectories: /h/xwindows/X/contrib/clients/xtroff/XtStuff and xtroff/XtStuff
  125. Common subdirectories: /h/xwindows/X/contrib/clients/xtroff/bitmaps and xtroff/bitmaps
  126. Only in xtroff: dave
  127. Common subdirectories: /h/xwindows/X/contrib/clients/xtroff/devsun and xtroff/devsun
  128. Common subdirectories: /h/xwindows/X/contrib/clients/xtroff/fontstuff and xtroff/fontstuff
  129. diff -r -c /h/xwindows/X/contrib/clients/xtroff/xwindows.c xtroff/xwindows.c
  130. *** /h/xwindows/X/contrib/clients/xtroff/xwindows.c    Fri Sep 23 10:16:37 1988
  131. --- xtroff/xwindows.c    Sat Nov 12 06:26:52 1988
  132. ***************
  133. *** 19,25 ****
  134.    *  X11.  - Mark Moraes.
  135.    */
  136.   #ifndef lint
  137. ! static char rcsid[]="$Header";
  138.   #endif
  139.   
  140.   #include    <stdio.h>
  141. --- 19,25 ----
  142.    *  X11.  - Mark Moraes.
  143.    */
  144.   #ifndef lint
  145. ! static char rcsid[]="$Header: xwindows.c,v 1.1 88/11/12 06:26:27 moraes Exp $";
  146.   #endif
  147.   
  148.   #include    <stdio.h>
  149. ***************
  150. *** 175,180 ****
  151. --- 175,181 ----
  152.   static XColor bg = {0, 0, 0, 0};
  153.   static XColor fg = {0, ~0, ~0, ~0};
  154.   unsigned int depth;
  155. + Dimension xwidth, xheight;
  156.   
  157.   Display *dpy;
  158.   Screen *scn;
  159. ***************
  160. *** 207,214 ****
  161.   static Arg query_args[] = {
  162.       {XtNbackground, (XtArgVal) &bgcolor},
  163.       {XtNforeground, (XtArgVal) &fgcolor},
  164. !     {XtNwidth, (XtArgVal) &ViewWidth},
  165. !     {XtNheight, (XtArgVal) &ViewHeight},
  166.   };
  167.   
  168.   /* args for the canvas window - we fill in translations by hand */
  169. --- 208,215 ----
  170.   static Arg query_args[] = {
  171.       {XtNbackground, (XtArgVal) &bgcolor},
  172.       {XtNforeground, (XtArgVal) &fgcolor},
  173. !     {XtNwidth, (XtArgVal) &xwidth},
  174. !     {XtNheight, (XtArgVal) &xheight},
  175.   };
  176.   
  177.   /* args for the canvas window - we fill in translations by hand */
  178. ***************
  179. *** 237,247 ****
  180.    *  XtNfromHoriz also changes to XtNfromVert.
  181.    */
  182.   static Arg scroll_args[] = {
  183. !     XtNlength, (XtArgVal) 850,
  184. !     XtNorientation, (XtArgVal) XtorientVertical,
  185. !     XtNfromHoriz, (XtArgVal) NULL,
  186. !     XtNscrollProc, (XtArgVal) scrollCallbacks,
  187. !     XtNthumbProc, (XtArgVal) thumbCallbacks,
  188.   };
  189.   
  190.   static MenuItemsList menu_list[] = {
  191. --- 238,250 ----
  192.    *  XtNfromHoriz also changes to XtNfromVert.
  193.    */
  194.   static Arg scroll_args[] = {
  195. !     {XtNlength, (XtArgVal) 850},
  196. !     {XtNorientation, (XtArgVal) XtorientVertical},
  197. !     {XtNfromHoriz, (XtArgVal) NULL},
  198. !     {XtNtop, (XtArgVal) 0.0},
  199. !     {XtNshown, (XtArgVal) 0.0},
  200. !     {XtNscrollProc, (XtArgVal) scrollCallbacks},
  201. !     {XtNthumbProc, (XtArgVal) thumbCallbacks},
  202.   };
  203.   
  204.   static MenuItemsList menu_list[] = {
  205. ***************
  206. *** 349,358 ****
  207. --- 352,367 ----
  208.       CanvasWidget = XtCreateManagedWidget("canvas", windowWidgetClass, 
  209.        BaseFrame, canvas_args, XtNumber(canvas_args));
  210.       XtGetValues(CanvasWidget, query_args, XtNumber(query_args));
  211. +     ViewWidth = xwidth;
  212. +     ViewHeight = xheight;
  213.       if (Scrollbars) {
  214.           /* vertical scrollbar to the right of the canvas */
  215.           XtSetArg(scroll_args[0], XtNlength, ViewHeight);
  216.           XtSetArg(scroll_args[2], XtNfromHoriz, CanvasWidget);
  217. +         XtSetArg(scroll_args[3], XtNtop, 
  218. +          (float) ((float) ViewTop / (float) PAGE_PIXEL_HEIGHT));
  219. +         XtSetArg(scroll_args[4], XtNshown, 
  220. +          (float) ((float) ViewHeight / (float) PAGE_PIXEL_HEIGHT));
  221.           VertScroll = XtCreateManagedWidget("vscroll", 
  222.            scrollbarWidgetClass, BaseFrame, 
  223.            scroll_args, XtNumber(scroll_args));
  224. ***************
  225. *** 360,365 ****
  226. --- 369,378 ----
  227.           XtSetArg(scroll_args[0], XtNlength, ViewWidth);
  228.           XtSetArg(scroll_args[1], XtNorientation, XtorientHorizontal);
  229.           XtSetArg(scroll_args[2], XtNfromVert, CanvasWidget);
  230. +         XtSetArg(scroll_args[3], XtNtop, 
  231. +          (float) ((float) ViewLeft / (float) PAGE_PIXEL_WIDTH));
  232. +         XtSetArg(scroll_args[4], XtNshown, 
  233. +          (float) ((float) ViewWidth / (float) PAGE_PIXEL_WIDTH));
  234.           HorizScroll = XtCreateManagedWidget("hscroll", 
  235.            scrollbarWidgetClass, BaseFrame, 
  236.            scroll_args, XtNumber(scroll_args));
  237. ***************
  238. *** 388,397 ****
  239.           minibuf_args[2].value = (XtArgVal) CanvasWidget;
  240.       InputWidget = XtCreateManagedWidget("minibuf", minibufWidgetClass,
  241.           BaseFrame, minibuf_args, XtNumber(minibuf_args));
  242. -     if (Scrollbars)
  243. -         SetScrollBar();
  244.       XtRealizeWidget(topLevel);
  245.       XFlush(dpy);
  246.       DrawingCanvas = XtWindow(CanvasWidget);
  247.       OuterFrame = XtWindow(topLevel);
  248.       InputWin = XtWindow(InputWidget);
  249. --- 401,410 ----
  250.           minibuf_args[2].value = (XtArgVal) CanvasWidget;
  251.       InputWidget = XtCreateManagedWidget("minibuf", minibufWidgetClass,
  252.           BaseFrame, minibuf_args, XtNumber(minibuf_args));
  253.       XtRealizeWidget(topLevel);
  254.       XFlush(dpy);
  255. +     if (Scrollbars)
  256. +         SetScrollBar();
  257.       DrawingCanvas = XtWindow(CanvasWidget);
  258.       OuterFrame = XtWindow(topLevel);
  259.       InputWin = XtWindow(InputWidget);
  260. ***************
  261. *** 768,778 ****
  262.   }
  263.   
  264.   
  265. ! static void Thumbed(w, closure, top)
  266.   Widget w;
  267.   caddr_t closure;
  268. ! float top;
  269.   {
  270.   #ifdef WINDOWDEBUG
  271.       printf( "thumbed to %f%%\n", top );
  272.   #endif
  273. --- 781,792 ----
  274.   }
  275.   
  276.   
  277. ! static void Thumbed(w, closure, percent)
  278.   Widget w;
  279.   caddr_t closure;
  280. ! caddr_t percent;
  281.   {
  282. +     float top = *((float *) percent);
  283.   #ifdef WINDOWDEBUG
  284.       printf( "thumbed to %f%%\n", top );
  285.   #endif
  286. diff -r -c /h/xwindows/X/contrib/clients/xtroff/XtStuff/CheckItem.c xtroff/XtStuff/CheckItem.c
  287. *** /h/xwindows/X/contrib/clients/xtroff/XtStuff/CheckItem.c    Fri Jun 10 01:20:10 1988
  288. --- xtroff/XtStuff/CheckItem.c    Fri Nov 11 23:53:27 1988
  289. ***************
  290. *** 121,126 ****
  291. --- 121,128 ----
  292.       NULL,                                  /* callback_private    */
  293.       defaultTranslations,           /* tm_table          */
  294.       NULL,                                  /* query_geometry    */
  295. +     /* display_accelerator    */    XtInheritDisplayAccelerator,
  296. +     /* extension        */    NULL
  297.     },  /* CoreClass fields initialization */
  298.     {
  299.       0,                                     /* field not used    */
  300. diff -r -c /h/xwindows/X/contrib/clients/xtroff/XtStuff/CheckItem.h xtroff/XtStuff/CheckItem.h
  301. *** /h/xwindows/X/contrib/clients/xtroff/XtStuff/CheckItem.h    Fri Jun 10 01:20:10 1988
  302. --- xtroff/XtStuff/CheckItem.h    Fri Nov 11 23:44:49 1988
  303. ***************
  304. *** 43,61 ****
  305.    *
  306.    ***********************************************************************/
  307.   
  308. - #ifndef _XtJustify_e
  309. - #define _XtJustify_e
  310. - typedef enum {
  311. -     XtJustifyLeft,       /* justify text to left side of button   */
  312. -     XtJustifyCenter,     /* justify text in center of button      */
  313. -     XtJustifyRight       /* justify text to right side of button  */
  314. - } XtJustify;
  315. - #endif _XtJustify_e
  316.   #define XtNcallback        "callback"
  317.   #define XtNhighlightThickness   "hightlightThickness"
  318.   #define XtNtranslations        "translations"
  319. --- 43,48 ----
  320. diff -r -c /h/xwindows/X/contrib/clients/xtroff/XtStuff/Menu.c xtroff/XtStuff/Menu.c
  321. *** /h/xwindows/X/contrib/clients/xtroff/XtStuff/Menu.c    Fri Jun 10 01:20:11 1988
  322. --- xtroff/XtStuff/Menu.c    Sat Nov 12 00:20:49 1988
  323. ***************
  324. *** 37,47 ****
  325.   
  326.   #include    <X11/IntrinsicP.h>
  327.   #include    <X11/StringDefs.h>
  328. ! #include    <X11/Misc.h>
  329.   #include    "MenuP.h"
  330.   #include    "MenuItem.h"
  331.   #include    "CheckItem.h"
  332. ! #include        <X11/Label.h>
  333.   #include    <ctype.h>
  334.   
  335.   /****************************************************************
  336. --- 37,48 ----
  337.   
  338.   #include    <X11/IntrinsicP.h>
  339.   #include    <X11/StringDefs.h>
  340. ! #include    <X11/XawMisc.h>
  341. ! #include    <X11/Xmu.h>
  342.   #include    "MenuP.h"
  343.   #include    "MenuItem.h"
  344.   #include    "CheckItem.h"
  345. ! #include     <X11/Label.h>
  346.   #include    <ctype.h>
  347.   
  348.   /****************************************************************
  349. ***************
  350. *** 56,64 ****
  351.        XtOffset(MenuWidget, menu.x_margin), XtRString, "0"},
  352.       {XtNyMargin, XtCVSpace, XtRInt, sizeof(int),
  353.        XtOffset(MenuWidget, menu.y_margin), XtRString, "0"},
  354. !     {XtNx, XtCPosition, XtRInt, sizeof(int),
  355.            XtOffset(MenuWidget,core.x),XtRString, "800"},
  356. !     {XtNy, XtCPosition, XtRInt, sizeof(int),
  357.            XtOffset(MenuWidget,core.y),XtRString, "800"},
  358.       {XtNborder,"MyBorder",XtRPixel,sizeof(Pixel),
  359.            XtOffset(MenuWidget,core.border_pixel),XtRString, "Black"},
  360. --- 57,65 ----
  361.        XtOffset(MenuWidget, menu.x_margin), XtRString, "0"},
  362.       {XtNyMargin, XtCVSpace, XtRInt, sizeof(int),
  363.        XtOffset(MenuWidget, menu.y_margin), XtRString, "0"},
  364. !     {XtNx, XtCPosition, XtRPosition, sizeof(Position),
  365.            XtOffset(MenuWidget,core.x),XtRString, "800"},
  366. !     {XtNy, XtCPosition, XtRPosition, sizeof(Position),
  367.            XtOffset(MenuWidget,core.y),XtRString, "800"},
  368.       {XtNborder,"MyBorder",XtRPixel,sizeof(Pixel),
  369.            XtOffset(MenuWidget,core.border_pixel),XtRString, "Black"},
  370. ***************
  371. *** 72,78 ****
  372.            XtOffset(MenuWidget,menu.check_foreground_pixel),XtRString, "Black"},
  373.       {XtNbackground, XtCBackground,XtRPixel, sizeof(Pixel),
  374.            XtOffset(MenuWidget,core.background_pixel),XtRString, "White"},
  375. !     {XtNborderWidth, XtCBorderWidth, XtRInt, sizeof(int),
  376.            XtOffset(MenuWidget,core.border_width),XtRString, "2"},
  377.       {XtNorientation, XtCOrientation, XtROrientation, sizeof(XtOrientation),
  378.            XtOffset(MenuWidget,menu.orient),XtRString, "vertical"},
  379. --- 73,79 ----
  380.            XtOffset(MenuWidget,menu.check_foreground_pixel),XtRString, "Black"},
  381.       {XtNbackground, XtCBackground,XtRPixel, sizeof(Pixel),
  382.            XtOffset(MenuWidget,core.background_pixel),XtRString, "White"},
  383. !     {XtNborderWidth, XtCBorderWidth, XtRDimension, sizeof(Dimension),
  384.            XtOffset(MenuWidget,core.border_width),XtRString, "2"},
  385.       {XtNorientation, XtCOrientation, XtROrientation, sizeof(XtOrientation),
  386.            XtOffset(MenuWidget,menu.orient),XtRString, "vertical"},
  387. ***************
  388. *** 126,131 ****
  389. --- 127,134 ----
  390.       /* callback_private   */    NULL,
  391.       /* tm_table           */    NULL,
  392.       /* query_geometry     */    NULL,
  393. +     /* display_accelerator    */    XtInheritDisplayAccelerator,
  394. +     /* extension        */    NULL
  395.     },{
  396.   /* composite_class fields */
  397.       /* geometry_manager   */    GeometryManager,
  398. ***************
  399. *** 132,139 ****
  400.       /* change_managed     */    ChangeManaged,
  401.       /* insert_child      */    NULL,    /* Inherit from superclass */
  402.       /* delete_child      */    NULL,    /* Inherit from superclass */
  403. -     /* move_focus_to_next */    NULL,
  404. -     /* move_focus_to_prev */    NULL
  405.     },{
  406.       /* mumble          */    0    /* Make C compiler happy   */
  407.     }
  408. --- 135,140 ----
  409. diff -r -c /h/xwindows/X/contrib/clients/xtroff/XtStuff/Menu.h xtroff/XtStuff/Menu.h
  410. *** /h/xwindows/X/contrib/clients/xtroff/XtStuff/Menu.h    Fri Jun 10 01:20:11 1988
  411. --- xtroff/XtStuff/Menu.h    Fri Nov 11 23:44:49 1988
  412. ***************
  413. *** 58,68 ****
  414.   #define XtitemCheckable        0x02    /* 0=uncheckable, 1=checkable    */
  415.   #define XtitemIsChecked        0x01    /* 0=unchecked, 1=checked    */
  416.   
  417. - #ifndef _XtOrientation_e
  418. - #define _XtOrientation_e
  419. - typedef enum {XtorientHorizontal, XtorientVertical} XtOrientation;
  420. - #endif _XtOrientation_e
  421.   /* Class record constants */
  422.   
  423.   extern WidgetClass menuWidgetClass;
  424. --- 58,63 ----
  425. diff -r -c /h/xwindows/X/contrib/clients/xtroff/XtStuff/MenuItem.c xtroff/XtStuff/MenuItem.c
  426. *** /h/xwindows/X/contrib/clients/xtroff/XtStuff/MenuItem.c    Fri Jul  8 05:42:16 1988
  427. --- xtroff/XtStuff/MenuItem.c    Fri Nov 11 23:53:27 1988
  428. ***************
  429. *** 116,121 ****
  430. --- 116,123 ----
  431.       NULL,                                  /* callback_private    */
  432.       defaultTranslations,           /* tm_table          */
  433.       NULL,                                  /* query_geometry    */
  434. +     /* display_accelerator    */    XtInheritDisplayAccelerator,
  435. +     /* extension        */    NULL
  436.     },  /* CoreClass fields initialization */
  437.     {
  438.       0,                                     /* field not used    */
  439. diff -r -c /h/xwindows/X/contrib/clients/xtroff/XtStuff/MenuItem.h xtroff/XtStuff/MenuItem.h
  440. *** /h/xwindows/X/contrib/clients/xtroff/XtStuff/MenuItem.h    Fri Jun 10 01:20:11 1988
  441. --- xtroff/XtStuff/MenuItem.h    Fri Nov 11 23:42:35 1988
  442. ***************
  443. *** 43,61 ****
  444.    *
  445.    ***********************************************************************/
  446.   
  447. - #ifndef _XtJustify_e
  448. - #define _XtJustify_e
  449. - typedef enum {
  450. -     XtJustifyLeft,       /* justify text to left side of button   */
  451. -     XtJustifyCenter,     /* justify text in center of button      */
  452. -     XtJustifyRight       /* justify text to right side of button  */
  453. - } XtJustify;
  454. - #endif _XtJustify_e
  455.   #define XtNcallback        "callback"
  456.   #define XtNhighlightThickness   "hightlightThickness"
  457.   #define XtNtranslations        "translations"
  458. --- 43,48 ----
  459. diff -r -c /h/xwindows/X/contrib/clients/xtroff/XtStuff/Minibuf.c xtroff/XtStuff/Minibuf.c
  460. *** /h/xwindows/X/contrib/clients/xtroff/XtStuff/Minibuf.c    Wed Aug 31 18:23:45 1988
  461. --- xtroff/XtStuff/Minibuf.c    Sat Nov 12 04:35:06 1988
  462. ***************
  463. *** 79,85 ****
  464.   #define BUF_BLOCK         128
  465.   
  466.   #define MIN_COLS         5
  467. ! #define DEFAULTFONT        "Fixed"
  468.   #define ABORT_MSG        "[Aborted]"
  469.   #define DELAY            300000        /*
  470.                                        *  Microseconds of delay for cursor
  471. --- 79,85 ----
  472.   #define BUF_BLOCK         128
  473.   
  474.   #define MIN_COLS         5
  475. ! #define DEFAULTFONT        "8x13"
  476.   #define ABORT_MSG        "[Aborted]"
  477.   #define DELAY            300000        /*
  478.                                        *  Microseconds of delay for cursor
  479. ***************
  480. *** 170,176 ****
  481.       {XtNforeground, XtCForeground, XtRPixel, sizeof(Pixel),
  482.        offset(minibuf.foreground), XtRString, "Black"},
  483.       {XtNfont,  XtCFont, XtRFontStruct, sizeof(XFontStruct *),
  484. !      offset(minibuf.finfo),XtRString, "Fixed"},
  485.       {XtNcursor, XtCCursor, XtRCursor, sizeof(Cursor),
  486.        offset(minibuf.cursor), XtRString, "xterm"},
  487.       {XtNfinishedCallback, XtCCallback, XtRCallback, sizeof(XtProc),
  488. --- 170,176 ----
  489.       {XtNforeground, XtCForeground, XtRPixel, sizeof(Pixel),
  490.        offset(minibuf.foreground), XtRString, "Black"},
  491.       {XtNfont,  XtCFont, XtRFontStruct, sizeof(XFontStruct *),
  492. !      offset(minibuf.finfo),XtRString, DEFAULTFONT},
  493.       {XtNcursor, XtCCursor, XtRCursor, sizeof(Cursor),
  494.        offset(minibuf.cursor), XtRString, "xterm"},
  495.       {XtNfinishedCallback, XtCCallback, XtRCallback, sizeof(XtProc),
  496. ***************
  497. *** 220,225 ****
  498. --- 220,227 ----
  499.           NULL,                            /* callback_private          */
  500.           defaultTranslations,            /* tm_table                  */
  501.           NULL,                            /* query_geometry          */
  502. +         XtInheritDisplayAccelerator,    /* display_accelerator    */
  503. +         NULL                            /* extension        */
  504.       },  /* CoreClass fields initialization */
  505.       {
  506.           0,                                /* field not used        */
  507. ***************
  508. *** 257,264 ****
  509.           mcore(height) = fontheight(mbuf(finfo));
  510.   
  511.       if (mbuf(finfo)->per_char != NULL) {
  512.           /* default font since we must have a fixed width font */
  513. !         XtConvert(new, XtRString, (XrmValuePtr) DEFAULTFONT,
  514.            XtRFontStruct, (XrmValuePtr) mbuf(finfo));
  515.   #ifdef DEBUG
  516.           fprintf(stderr, "Need fixed font - falling back on default \"%s\"\n",
  517. --- 259,269 ----
  518.           mcore(height) = fontheight(mbuf(finfo));
  519.   
  520.       if (mbuf(finfo)->per_char != NULL) {
  521. +         XrmValue value;
  522. +         value.size = sizeof(DEFAULTFONT);
  523. +         value.addr = DEFAULTFONT;
  524.           /* default font since we must have a fixed width font */
  525. !         XtConvert(new, XtRString, &value,
  526.            XtRFontStruct, (XrmValuePtr) mbuf(finfo));
  527.   #ifdef DEBUG
  528.           fprintf(stderr, "Need fixed font - falling back on default \"%s\"\n",
  529. diff -r -c /h/xwindows/X/contrib/clients/xtroff/XtStuff/Window.c xtroff/XtStuff/Window.c
  530. *** /h/xwindows/X/contrib/clients/xtroff/XtStuff/Window.c    Thu Aug 18 23:55:31 1988
  531. --- xtroff/XtStuff/Window.c    Sat Nov 12 01:10:51 1988
  532. ***************
  533. *** 79,84 ****
  534. --- 79,87 ----
  535.       /* version            */    XtVersion,
  536.       /* callback_private   */    NULL,
  537.       /* tm_table           */    NULL,
  538. +     /* query_geometry     */    NULL,
  539. +     /* display_accelerator*/    XtInheritDisplayAccelerator,
  540. +     /* extension          */    NULL
  541.     }
  542.   };
  543.   
  544. diff -r -c /h/xwindows/X/contrib/clients/xtroff/XtStuff/Window.h xtroff/XtStuff/Window.h
  545. *** /h/xwindows/X/contrib/clients/xtroff/XtStuff/Window.h    Thu Aug 18 23:55:44 1988
  546. --- xtroff/XtStuff/Window.h    Sat Nov 12 00:02:01 1988
  547. ***************
  548. *** 11,17 ****
  549.    *
  550.    ***********************************************************************/
  551.   
  552. - #define XtNpixmap    "Pixmap"
  553.   #define XtCpixmap    "Pixmap"
  554.   
  555.   /* Class record constants */
  556. --- 11,16 ----
  557. diff -r -c /h/xwindows/X/contrib/clients/xtroff/fontstuff/MakeImFonts xtroff/fontstuff/MakeImFonts
  558. *** /h/xwindows/X/contrib/clients/xtroff/fontstuff/MakeImFonts    Thu Sep  1 00:06:10 1988
  559. --- xtroff/fontstuff/MakeImFonts    Sat Nov 12 02:34:18 1988
  560. ***************
  561. *** 23,29 ****
  562.   if test x$XWIN != x ; then
  563.       if test $XWIN != suntroff ; then
  564.           XWIN=x
  565. !         FC=${5-fc}
  566.       else
  567.           XWIN=
  568.           FC=
  569. --- 23,29 ----
  570.   if test x$XWIN != x ; then
  571.       if test $XWIN != suntroff ; then
  572.           XWIN=x
  573. !         FC=${5-bdftosnf}
  574.       else
  575.           XWIN=
  576.           FC=
  577. ***************
  578. *** 62,68 ****
  579.           NewSize=`expr $Size \* 100 / $PERCENT`
  580.           if test x$XWIN != x ; then
  581.               fname=`echo $Font | tr A-Z a-z`
  582. !             fname=$DEVICE.$fname.$NewSize.snf
  583.           else
  584.               fname=$Font.$NewSize
  585.           fi
  586. --- 62,69 ----
  587.           NewSize=`expr $Size \* 100 / $PERCENT`
  588.           if test x$XWIN != x ; then
  589.               fname=`echo $Font | tr A-Z a-z`
  590. !             fontname=$DEVICE.$fname.$NewSize
  591. !             fname=$fontname.snf
  592.           else
  593.               fname=$Font.$NewSize
  594.           fi
  595. ***************
  596. *** 76,82 ****
  597.                       $SUNTROFF_FONTS/$fname
  598.               else
  599.                   $BIN_DIR/ch2vft $TEMP > $TEMP2
  600. !                 $BIN_DIR/vf2bdf $TEMP2 $NewSize |
  601.                   $FC > $SUNTROFF_FONTS/$fname
  602.               fi
  603.   
  604. --- 77,84 ----
  605.                       $SUNTROFF_FONTS/$fname
  606.               else
  607.                   $BIN_DIR/ch2vft $TEMP > $TEMP2
  608. !                 $BIN_DIR/vf2bdf $TEMP2 $NewSize | \
  609. !                 sed 's?^FONT .*$?FONT '$fontname'?' | \
  610.                   $FC > $SUNTROFF_FONTS/$fname
  611.               fi
  612.   
  613. ***************
  614. *** 103,118 ****
  615.           else
  616.               extension=
  617.           fi
  618. !         f1=$SUNTROFF_FONTS/$Font.`expr $Size - 1`$extension
  619. !         f2=$SUNTROFF_FONTS/$Font.`expr $Size`$extension
  620. !         f3=$SUNTROFF_FONTS/$Font.`expr $Size + 1`$extension
  621.   
  622.           if [ -r $f1 -o -r $f2 -o -r $f3 ]
  623.           then
  624.               true
  625.           else
  626.               echo scaling and converting $RSTFONTS/$i to \
  627. !                 $SUNTROFF_FONTS/$DEVICE.$Font.$Size$extension
  628.               $BIN_DIR/rst2ch $RSTFONTS/$i > $TEMP
  629.               $BIN_DIR/scalech -s$PERCENT  $TEMP > $TEMP2
  630.               if test x$XWIN = x ; then
  631. --- 105,129 ----
  632.           else
  633.               extension=
  634.           fi
  635. !         if [ x$XWIN = x ]
  636. !         then
  637. !             f1=$SUNTROFF_FONTS/$Font.`expr $Size - 1`$extension
  638. !             f2=$SUNTROFF_FONTS/$Font.`expr $Size`$extension
  639. !             f3=$SUNTROFF_FONTS/$Font.`expr $Size + 1`$extension
  640. !         else
  641. !             f1=$SUNTROFF_FONTS/$DEVICE.$Font.`expr $Size - 1`$extension
  642. !             f2=$SUNTROFF_FONTS/$DEVICE.$Font.`expr $Size`$extension
  643. !             f3=$SUNTROFF_FONTS/$DEVICE.$Font.`expr $Size + 1`$extension
  644. !         fi
  645.   
  646.           if [ -r $f1 -o -r $f2 -o -r $f3 ]
  647.           then
  648.               true
  649.           else
  650. +             fontname=$DEVICE.$Font.$Size
  651. +             fname=$fontname$extension
  652.               echo scaling and converting $RSTFONTS/$i to \
  653. !                 $SUNTROFF_FONTS/$fname
  654.               $BIN_DIR/rst2ch $RSTFONTS/$i > $TEMP
  655.               $BIN_DIR/scalech -s$PERCENT  $TEMP > $TEMP2
  656.               if test x$XWIN = x ; then
  657. ***************
  658. *** 120,127 ****
  659.               else
  660.                   $BIN_DIR/ch2vft $TEMP2 > $TEMP
  661.                   $BIN_DIR/vf2bdf $TEMP $Size |
  662. !                 $FC > $SUNTROFF_FONTS/$DEVICE.$Font.$Size$extension
  663.               fi
  664.           fi
  665.       fi
  666.   done
  667. --- 131,142 ----
  668.               else
  669.                   $BIN_DIR/ch2vft $TEMP2 > $TEMP
  670.                   $BIN_DIR/vf2bdf $TEMP $Size |
  671. !                 sed 's?^FONT .*$?FONT '$fontname'?' | \
  672. !                 $FC > $SUNTROFF_FONTS/$fname
  673.               fi
  674.           fi
  675.       fi
  676.   done
  677. + if [ x$XWIN != x ]; then
  678. +     mkfontdir $SUNTROFF_FONTS
  679. + fi
  680. diff -r -c /h/xwindows/X/contrib/clients/xtroff/fontstuff/MakeSunFonts xtroff/fontstuff/MakeSunFonts
  681. *** /h/xwindows/X/contrib/clients/xtroff/fontstuff/MakeSunFonts    Thu Sep  1 01:42:57 1988
  682. --- xtroff/fontstuff/MakeSunFonts    Sat Nov 12 02:34:17 1988
  683. ***************
  684. *** 22,28 ****
  685.   if test x$XWIN != x ; then
  686.       if test $XWIN != suntroff ; then
  687.           XWIN=x
  688. !         FC=${5-fc}
  689.       else
  690.           XWIN=
  691.           FC=
  692. --- 22,28 ----
  693.   if test x$XWIN != x ; then
  694.       if test $XWIN != suntroff ; then
  695.           XWIN=x
  696. !         FC=${5-bdftosnf}
  697.       else
  698.           XWIN=
  699.           FC=
  700. ***************
  701. *** 69,75 ****
  702.           NewSize=`expr $Size \* 100 / $PERCENT`
  703.           if test x$XWIN != x ; then
  704.               fname=`echo $Font | tr A-Z a-z`
  705. !             fname=$DEVICE.$fname.$NewSize.snf
  706.           else
  707.               fname=$Font.$NewSize
  708.           fi
  709. --- 69,76 ----
  710.           NewSize=`expr $Size \* 100 / $PERCENT`
  711.           if test x$XWIN != x ; then
  712.               fname=`echo $Font | tr A-Z a-z`
  713. !             fontname=$DEVICE.$fname.$NewSize
  714. !             fname=$fontname.snf
  715.           else
  716.               fname=$Font.$NewSize
  717.           fi
  718. ***************
  719. *** 82,87 ****
  720. --- 83,89 ----
  721.                             $SUNTROFF_FONTS/$fname
  722.               else
  723.                   $BIN_DIR/vf2bdf $VFONTS/$i $NewSize | \
  724. +                 sed 's?^FONT .*$?FONT '$fontname'?' | \
  725.                   $FC > $SUNTROFF_FONTS/$fname
  726.               fi
  727.           fi
  728. ***************
  729. *** 107,122 ****
  730.           else
  731.               extension=
  732.           fi
  733. !         f1=$SUNTROFF_FONTS/$Font.`expr $Size - 1`$extension
  734. !         f2=$SUNTROFF_FONTS/$Font.`expr $Size`$extension
  735. !         f3=$SUNTROFF_FONTS/$Font.`expr $Size + 1`$extension
  736.   
  737.           if [ -r $f1 -o -r $f2 -o -r $f3 ]
  738.           then
  739.               true
  740.           else
  741.               echo scaling and converting $VFONTS/$i to \
  742. !                 $SUNTROFF_FONTS/$DEVICE.$Font.$Size$extension
  743.               $BIN_DIR/vft2ch $VFONTS/$i > $TEMP
  744.               $BIN_DIR/scalech -s$PERCENT  $TEMP > $TEMP2
  745.               if test x$XWIN = x ; then
  746. --- 109,133 ----
  747.           else
  748.               extension=
  749.           fi
  750. !         if [ x$XWIN = x ]
  751. !         then
  752. !             f1=$SUNTROFF_FONTS/$Font.`expr $Size - 1`$extension
  753. !             f2=$SUNTROFF_FONTS/$Font.`expr $Size`$extension
  754. !             f3=$SUNTROFF_FONTS/$Font.`expr $Size + 1`$extension
  755. !         else
  756. !             f1=$SUNTROFF_FONTS/$DEVICE.$Font.`expr $Size - 1`$extension
  757. !             f2=$SUNTROFF_FONTS/$DEVICE.$Font.`expr $Size`$extension
  758. !             f3=$SUNTROFF_FONTS/$DEVICE.$Font.`expr $Size + 1`$extension
  759. !         fi
  760.   
  761.           if [ -r $f1 -o -r $f2 -o -r $f3 ]
  762.           then
  763.               true
  764.           else
  765. +             fontname=$DEVICE.$Font.$Size
  766. +             fname=$fontname$extension
  767.               echo scaling and converting $VFONTS/$i to \
  768. !                 $SUNTROFF_FONTS/$fname
  769.               $BIN_DIR/vft2ch $VFONTS/$i > $TEMP
  770.               $BIN_DIR/scalech -s$PERCENT  $TEMP > $TEMP2
  771.               if test x$XWIN = x ; then
  772. ***************
  773. *** 124,131 ****
  774.               else
  775.                   $BIN_DIR/ch2vft $TEMP2 > $TEMP
  776.                   $BIN_DIR/vf2bdf $TEMP $Size |
  777. !                 $FC > $SUNTROFF_FONTS/$DEVICE.$Font.$Size$extension
  778.               fi
  779.           fi
  780.       fi
  781.   done
  782. --- 135,146 ----
  783.               else
  784.                   $BIN_DIR/ch2vft $TEMP2 > $TEMP
  785.                   $BIN_DIR/vf2bdf $TEMP $Size |
  786. !                 sed 's?^FONT .*$?FONT '$fontname'?' | \
  787. !                 $FC > $SUNTROFF_FONTS/$fname
  788.               fi
  789.           fi
  790.       fi
  791.   done
  792. + if [ x$XWIN != x ]; then
  793. +     mkfontdir $SUNTROFF_FONTS
  794. + fi
  795. diff -r -c /h/xwindows/X/contrib/clients/xtroff/fontstuff/Makefile xtroff/fontstuff/Makefile
  796. *** /h/xwindows/X/contrib/clients/xtroff/fontstuff/Makefile    Thu Sep  1 00:13:25 1988
  797. --- xtroff/fontstuff/Makefile    Sat Nov 12 01:37:44 1988
  798. ***************
  799. *** 1,5 ****
  800.   #    Not standalone - it gets a lot of variables from the invocation.
  801. ! #    VFONTS, RSTFONTS, SUNTROFF_FONTS, PERCENT, PREVIEWER, FC
  802.   
  803.   all: install
  804.   
  805. --- 1,7 ----
  806.   #    Not standalone - it gets a lot of variables from the invocation.
  807. ! #    VFONTS, RSTFONTS, SUNTROFF_FONTS, PERCENT, PREVIEWER, FC, CDEBUGFLAGS
  808. ! CFLAGS = $(CDEBUGFLAGS)
  809.   
  810.   all: install
  811.   
  812. diff -r -c /h/xwindows/X/contrib/clients/xtroff/fontstuff/vf2bdf.c xtroff/fontstuff/vf2bdf.c
  813. *** /h/xwindows/X/contrib/clients/xtroff/fontstuff/vf2bdf.c    Fri Jun 10 02:13:08 1988
  814. --- xtroff/fontstuff/vf2bdf.c    Sat Nov 12 02:04:12 1988
  815. ***************
  816. *** 127,133 ****
  817.           {
  818.               for (k = (pd->left + pd->right + 7) / 8; --k >= 0; )
  819.                   printf("%02x", *p++);
  820. !             printf(" \n");
  821.           }
  822.           printf("ENDCHAR\n");
  823.       }
  824. --- 127,133 ----
  825.           {
  826.               for (k = (pd->left + pd->right + 7) / 8; --k >= 0; )
  827.                   printf("%02x", *p++);
  828. !             printf("\n");
  829.           }
  830.           printf("ENDCHAR\n");
  831.       }
  832. diff -r -c /h/xwindows/X/contrib/clients/xtroff/xtroff.man xtroff/xtroff.manX
  833. *** /h/xwindows/X/contrib/clients/xtroff/xtroff.man    Thu Jul 14 18:59:28 1988
  834. --- xtroff/xtroff.manX    Sat Nov 12 03:03:22 1988
  835. ***************
  836. *** 234,244 ****
  837.   "-xrm".
  838.   Some of the options are meaningless for \fIxtroff\fP. 
  839.   .SH "FILES"
  840. ! .na
  841. ! .ta \w'/usr/local/lib/xtroff/*   'u
  842. ! /usr/local/lib/troff/*    - troff width tables
  843. ! /usr/local/lib/xtroff/*    - bitmap fonts for xtroff
  844. ! .ad
  845.   .SH "SEE ALSO"
  846.   .LP
  847.   .I Using and Specifiying X Resources
  848. --- 234,242 ----
  849.   "-xrm".
  850.   Some of the options are meaningless for \fIxtroff\fP. 
  851.   .SH "FILES"
  852. ! WIDTHDIR/*    - troff width tables
  853. ! .br
  854. ! FONTDIR/*    - bitmap fonts for xtroff
  855.   .SH "SEE ALSO"
  856.   .LP
  857.   .I Using and Specifiying X Resources
  858. WhAt_A_mArOoN
  859. echo 'Now run ximake in this directory, and XtStuff to generate the Makefiles'
  860. echo 'And you are ready to go...'
  861. exit
  862.