Tgif Home
----
About Tgif
Current Release & Download
FAQ
Copyright Info
A Screendump of Tgif
Release History
Tools That Tgif Uses
Tools That Work with Tgif
Author of Tgif
Miscellaneous Info
----
 
Return to Tgif's Home Page
William Chia-Wei Cheng
(bill.cheng@usc.edu)
 

Tgif FAQ - System-specific Problems

 
My Mac doesn't have xmkmf. How can I install tgif?
Please give Homebrew a try. After you have installed Homebrew, please do:
    brew install homebrew/X11/tgif
My cygwin doesn't have cjpeg and djpeg. How can I import/export JPEG files?
Please add the following lines to your ~/.Xdefaults file:
    Tgif.PpmToJpeg:  convert %s jpeg:-
    Tgif.JpegToPpm6: convert "%s" ppm:-
This will use the "convert" program from ImageMagick instead of cjpeg and djpeg.
Ever since tgif-4.2.3, tgif generates bad PS/EPS files for Japanese characters (EUC fonts). Is there a fix for this?
Please apply the tgif-QPL-4.2-patch5b patch. Sorry about the bug!
On Ubuntu 10, I'm getting "Warning: No type converter registered for 'String' to 'Bitmap' conversion" when tgif starts. Is there a fix for this?
This warning is caused by the Tgif.IconPixmap line in /etc/X11/app-defaults/Tgif. Just add a ! at the beginning of that line to comment it out.

Another problematic entry in the same file is Tgif.ColorFromXPixmap. You should also comment it out.

I'm running on 64-bit Ubuntu 10 and when I try double-clicking the latex-equation object, I'm getting all kinds of error messages. The latex-equation stuff used to work before. Is there a fix for this?
The tgif you are running may be compiled under a 32-bit version of your OS. You might want to download the latest version of tgif, compile it, and install it.

If you are running Ubuntu 10, you can also download a 64-bit version of tgif from ubuntu.com.

For Ubuntu or Debian systems, you can also open up a Terminal and run the following command to download and install tgif:

sudo apt-get install tgif
I just switched to Debian (or Ubuntu). When I run tgif, it complained about Fatal Error in OpenFont(): Cannot open the Default(Msg)Font '-*-courier-medium-r-normal-*-14-*-*-*-*-*-iso8859-1'. Under xfontsel, there is no Courier fonts at all. What should I do?
Long time ago, standard Adobe fonts such as Courier, Helvetica, Times, etc. were available in all sizes (as scalable fonts) by default on Red Hat Linux (and probably early Fedora releases). Looks like Debian releases do not make the standard Adobe fonts available.

The first thing to try is to install the Adobe fonts:

sudo apt-get install xorg-x11-fonts-ISO8859-1-75dpi
sudo apt-get install xfonts-75dpi
sudo apt-get install gsfonts-x11
xset fp rehash
If this doesn't help, you can run:
xlsfonts
and look at what fonts are available on your system. For example, if the "clean" and "utopia" fonts are available on your system, you can try the folloting X defaults:
        Tgif.DefFixedWidthFont:           -*-fixed-medium-r-normal--12-*-*-*-*-*-*-*
        Tgif.DefFixedWidthRulerFont:      -*-fixed-medium-r-normal--10-*-*-*-*-*-*-*
        Tgif.MenuFont:                    -*-utopia-bold-r-normal--12-*-*-*-*-*-*-*
        Tgif.BoldMsgFont:                 -*-utopia-bold-r-normal--12-*-*-*-*-*-*-*
        Tgif.MsgFont:                     -*-utopia-medium-r-normal--12-*-*-*-*-*-*-*
        
        Tgif.HasAlternateDefaultFonts: true
        Tgif.Times-Roman:                 -*-clean-medium-r-*-*-%d-*-*-*-*-*-iso8859-1
        Tgif.Times-Bold:                  -*-clean-bold-r-*-*-%d-*-*-*-*-*-iso8859-1
        Tgif.Times-Italic:                -*-clean-medium-i-*-*-%d-*-*-*-*-*-iso8859-1
        Tgif.Times-BoldItalic:            -*-clean-bold-i-*-*-%d-*-*-*-*-*-iso8859-1
        Tgif.Courier:                     -*-fixed-medium-r-*-*-%d-*-*-*-*-*-iso8859-1
        Tgif.Courier-Bold:                -*-fixed-bold-r-*-*-%d-*-*-*-*-*-iso8859-1
        Tgif.Courier-Oblique:             -*-fixed-medium-o-*-*-%d-*-*-*-*-*-iso8859-1
        Tgif.Courier-BoldOblique:         -*-fixed-bold-o-*-*-%d-*-*-*-*-*-iso8859-1
        Tgif.Helvetica:                   -*-utopia-medium-r-*-*-%d-*-*-*-*-*-iso8859-1
        Tgif.Helvetica-Bold:              -*-utopia-bold-r-*-*-%d-*-*-*-*-*-iso8859-1
        Tgif.Helvetica-Oblique:           -*-utopia-medium-i-*-*-%d-*-*-*-*-*-iso8859-1
        Tgif.Helvetica-BoldOblique:       -*-utopia-bold-i-*-*-%d-*-*-*-*-*-iso8859-1
        Tgif.NewCenturySchlbk-Roman:      -*-clean-medium-r-normal--%d-*
        Tgif.NewCenturySchlbk-Bold:       -*-clean-bold-r-normal--%d-*
        Tgif.NewCenturySchlbk-Italic:     -*-clean-medium-r-semicondensed--%d-*
        Tgif.NewCenturySchlbk-BoldItalic: -*-clean-bold-r-semicondensed--%d-*
        !Tgif.Symbol:                     -*-standard symbols l-medium-r-normal--%d-*-*-*-*-*-adobe-symbol
Please note that the last line is commented out. You should look for "symbol" in the output of "xlsfonts" and replace the last line with the appropriate font and remove the comment symbol.
 
I just switched to Fedora 8. When I run tgif, it complained about Fatal Error in OpenFont(): Cannot open the RulerFont '-*-courier-medium-r-normal-*-10-*-*-*-*-*-iso8859-1'. Under xfontsel, Courier-10 is not available. What should I do?
Long time ago, standard Adobe fonts such as Courier, Helvetica, Times, etc. were available in all sizes (as scalable fonts) by default on Red Hat Linux (and probably early Fedora releases). Looks like newer Fedora releases do not make the standard Adobe fonts available in all sizes.

To get around the problem, you can use X resources to override the default settings. For example, you can try using the following X default:

Tgif.RulerFontSize: 11
If the only font sizes that are available are 11, 14, 17, 20, 25, and 34, you can use the following X default:
Tgif.FontSizes: 11 14 17 20 25 34
However, if you do this, when you need other font sizes, you will need to use SetSelectedFontSize under the Properties Menu to enter a new font size.

Under newer Fedora releases, I'm starting to use the scalable Utopia fonts. To add Utopia fonts to tgif, you can use the following X default:

Tgif.AdditionalFonts: \n\
utopia-medium-r-normal,iso8859-1,Utopia-Regular \n\
utopia-bold-r-normal,iso8859-1,Utopia-Bold \n\
utopia-medium-i-normal,iso8859-1,Utopia-Italic \n\
utopia-bold-i-normal,iso8859-1,Utopia-BoldItalic
 
I'm running SuSE Linux and when I try to use Times-20 font, I get a message saying that Times-20 font is not available. Can this be fixed?
On some Linux systems, scalable fonts from Adobe are not longer available. (It's probably due to some copyright issues.) However, you can use URW fonts instead of Adobe fonts. Please find urw-fonts-*.rpm from your installation CD and install it on your system. Also, please make sure that you either
a) do not have Tgif.FontNamePrefix specified in your X resource file; or
b) use the following X default:
Tgif.FontNamePrefix: -*
 
I'm running Red Hat 9.0 and tgif has trouble copying and pasting. What's going on?
This is a bug with older version of tgif. In the older version, tgif implemented copy and paste using a fairly old X11 mechanism. It has been fixed in tgif-4.1.45 to use the X Selections mechanism to perform copy and paste.

For now, to get around this problem, please try the following.

  1. Run klipper
  2. Select Configure Klipper from the klipper menu
  3. Make sure the Prevent empty clipboard checkbox is not checked
  4. Make sure Separate clipboard and selection is chosen in Clipboard/Selection Behavior
  5. Click on OK

If this happens in a newer system, please check if klipper (or something equivalent) is running or not. If it's running, you should be able to see it in the system tray. If it's running and pasting is still not working, you can switch back to the old copy and paste mechanism by setting the following X default:

Tgif.PasteFromXSelectionOnly: false
The downside with doing this is that the old clipboard mechanism in X uses a buffer that has a size limit. So, you will not be able to copy and paste large objects.

Finally, if you get a message saying that "selection conversion was refused", you may want to try clearing the history buffer of klipper and see if it helps before trying the above approaches.

 
I'm running CentOS 7.2 and tgif won't compile. How can I fix this?
Assuming that you start with the "DVD" distribution of CentOS 7.2 (i.e., CentOS-7-x86_64-DVD-1511.iso), you need to run the following commands as root:
    yum install imake
    yum install libX11-devel libXt-devel zlib-devel
    yum install xorg-x11-fonts-ISO8859-1-75dpi
Then you need to replace Tgif.tmpl with the "Tgif.tmpl-centos" here. Then just do:
    xmkmf
    make depend
    make tgif
    ./tgif