From: stuart@genethon.FR (Stuart Pook)
Subject: gpic and text
Keywords: gpic
Organization: Genethon -- CEPHB Human Polymorphism Study Center, Paris, France
Distribution: gnu
Date: Thu, 23 Jul 1992 15:52:18 GMT

I have been having great difficulty using the compass
points associated with gpic objects (version 1.05 though I
had the same problems with 1.03).

I would have thought that the following input would draw
"foo" inside the box rather than to the left of it.

	.PS
	scale = 25.4
	T: "foo" width 5 height 3
	box from T.ne to T.sw
	.PE

And why does the following draw a right angle rather than a 'T' ?

	.PS
	line down
	line right with .c at last line.n
	.PE

Thanks for any enlightenment that you can offer me.

Stuart Pook

PS.  I am using a Sun Sparc running SunOS 4.1.2 and compiled groff
with Sun's CC 2.1.  This required changing three files because
of complaints about type mismatches.  Here are the diffs:

*** dvi/tfmtodit.c.orig	Mon Mar  2 17:40:11 1992
--- dvi/tfmtodit.c	Thu Jul 23 13:52:23 1992
***************
*** 288,294 ****
    int lf = (c1 << 8) + c2;
    int toread = lf*4 - 2;
    unsigned char *buf = new unsigned char[toread];
!   if (fread(buf, 1, toread, fp) != toread) {
      if (feof(fp))
        error("unexpected end of file on `%1'", file);
      else
--- 288,294 ----
    int lf = (c1 << 8) + c2;
    int toread = lf*4 - 2;
    unsigned char *buf = new unsigned char[toread];
!   if (fread((char *)buf, 1, toread, fp) != toread) {
      if (feof(fp))
        error("unexpected end of file on `%1'", file);
      else
*** refer/indxbib.c.orig	Mon Mar  2 17:27:55 1992
--- refer/indxbib.c	Thu Jul 23 13:46:59 1992
***************
*** 95,101 ****
  static void fwrite_or_die(const void *ptr, int size, int nitems, FILE *fp);
  static char *get_cwd();
  
! extern "C" { void fatal_signal(int); }
  
  extern "C" { long dir_name_max(const char *); }
  
--- 95,101 ----
  static void fwrite_or_die(const void *ptr, int size, int nitems, FILE *fp);
  static char *get_cwd();
  
! extern "C" { void fatal_signal(int, ...); }
  
  extern "C" { long dir_name_max(const char *); }
  
***************
*** 709,715 ****
  
  static void fwrite_or_die(const void *ptr, int size, int nitems, FILE *fp)
  {
!   if (fwrite(ptr, size, nitems, fp) != nitems)
      fatal("fwrite failed: %1", strerror(errno));
  }
  
--- 709,715 ----
  
  static void fwrite_or_die(const void *ptr, int size, int nitems, FILE *fp)
  {
!   if (fwrite((char const *)ptr, size, nitems, fp) != nitems)
      fatal("fwrite failed: %1", strerror(errno));
  }
  
***************
*** 722,728 ****
  
  extern "C" {
  
! void fatal_signal(int signum)
  {
    signal(signum, SIG_DFL);
    if (temp_index_file)
--- 722,728 ----
  
  extern "C" {
  
! void fatal_signal(int signum, ...)
  {
    signal(signum, SIG_DFL);
    if (temp_index_file)
*** Makefile.orig	Tue Mar 17 19:49:48 1992
--- Makefile	Thu Jul 23 14:13:10 1992
***************
*** 122,131 ****
  D1=#-DCFRONT_ANSI_BUG
  
  # Uncomment the next line if you have vfork().
! D2=#-DHAVE_VFORK
  
  # Uncomment the next line if you have sys_siglist[].
! D3=#-DHAVE_SYS_SIGLIST
  
  # Uncomment the next line if you have the mmap() system call (and you
  # want to use it).
--- 122,131 ----
  D1=#-DCFRONT_ANSI_BUG
  
  # Uncomment the next line if you have vfork().
! D2=-DHAVE_VFORK
  
  # Uncomment the next line if you have sys_siglist[].
! D3=-DHAVE_SYS_SIGLIST
  
  # Uncomment the next line if you have the mmap() system call (and you
  # want to use it).
***************
*** 132,138 ****
  D4=#-DHAVE_MMAP
  
  # Uncomment the next line if you have the rename() system call.
! D5=#-DHAVE_RENAME
  
  # Uncomment the next line if the argument to localtime() is a long*
  # rather than a time_t*.
--- 132,138 ----
  D4=#-DHAVE_MMAP
  
  # Uncomment the next line if you have the rename() system call.
! D5=-DHAVE_RENAME
  
  # Uncomment the next line if the argument to localtime() is a long*
  # rather than a time_t*.
***************
*** 140,150 ****
  
  # Uncomment the next line if wait is declared by your C++ header files
  # to take an argument of type union wait *.
! D7=#-DHAVE_UNION_WAIT
  
  # Uncoment the next line if your C++ header files declare a type pid_t
  # which is used as the return type of fork() and wait().
! D8=#-DHAVE_PID_T
  
  # Uncomment the next line if the 0200 bit of the status returned by
  # wait() indicates whether a core image was produced for a process
--- 140,150 ----
  
  # Uncomment the next line if wait is declared by your C++ header files
  # to take an argument of type union wait *.
! D7=-DHAVE_UNION_WAIT
  
  # Uncoment the next line if your C++ header files declare a type pid_t
  # which is used as the return type of fork() and wait().
! D8=-DHAVE_PID_T
  
  # Uncomment the next line if the 0200 bit of the status returned by
  # wait() indicates whether a core image was produced for a process
***************
*** 154,160 ****
  
  # Uncomment the next line if <sys/wait.h> should not be included
  # when using wait().  Use this with the libg++ header files.
! D10=-DNO_SYS_WAIT_H
  
  # Uncomment the next line if you C++ compiler requires delete [n] rather
  # than delete []. This is needed for g++ 1.x and cfront 2.0.
--- 154,160 ----
  
  # Uncomment the next line if <sys/wait.h> should not be included
  # when using wait().  Use this with the libg++ header files.
! D10=#-DNO_SYS_WAIT_H
  
  # Uncomment the next line if you C++ compiler requires delete [n] rather
  # than delete []. This is needed for g++ 1.x and cfront 2.0.
***************
*** 204,216 ****
  # in /usr/bin you'll have to edit etc/grog.pl by hand.
  # The next line should be uncommented if you want to use the old shell
  # version.
! GROG=grog.sh
  # The next line should be uncommented if you want to use the new perl
  # version.
! # GROG=grog.pl
  
  # CC is the C++ compiler
! CC=g++
  # This is the flag that tells the C++ compiler to treat a .c file as C++.
  C++LANG_FLAG=
  # I'm told that -fno-inline is needed on a 68030-based Apollo
--- 204,216 ----
  # in /usr/bin you'll have to edit etc/grog.pl by hand.
  # The next line should be uncommented if you want to use the old shell
  # version.
! #GROG=grog.sh
  # The next line should be uncommented if you want to use the new perl
  # version.
! GROG=grog.pl
  
  # CC is the C++ compiler
! CC=CC
  # This is the flag that tells the C++ compiler to treat a .c file as C++.
  C++LANG_FLAG=
  # I'm told that -fno-inline is needed on a 68030-based Apollo
***************
*** 221,230 ****
  # C++LANG_FLAG=-xc++
  
  # OLDCC is the C compiler.
! OLDCC=gcc
  
  PROFILE_FLAG=
! DEBUG_FLAG=-g
  # With gcc/g++ 2.0 on a sparc, -O works better than -O2.
  OPTIMIZE_FLAG=-O
  WARNING_FLAGS=#-Wall -Wcast-qual -Wwrite-strings
--- 221,230 ----
  # C++LANG_FLAG=-xc++
  
  # OLDCC is the C compiler.
! OLDCC=acc
  
  PROFILE_FLAG=
! DEBUG_FLAG=#-g
  # With gcc/g++ 2.0 on a sparc, -O works better than -O2.
  OPTIMIZE_FLAG=-O
  WARNING_FLAGS=#-Wall -Wcast-qual -Wwrite-strings

Newsgroups: gnu.ghostscript.bug