c73823892aa5384025c64a22b5da8e4332d38efd braney Wed Sep 30 14:53:48 2020 -0700 get the postscript driver to allow font specification. Use the correct names for fonts. diff --git src/hg/hgTracks/hgTracks.c src/hg/hgTracks/hgTracks.c index 30baf0f..d541c7d 100644 --- src/hg/hgTracks/hgTracks.c +++ src/hg/hgTracks/hgTracks.c @@ -621,42 +621,42 @@ bands overlaps by one. */ if (winEnd > cb->chromStart && winEnd <= cb->chromEnd) { safef(endBand, buffSize, "%s", cb->name); } } } static void maybeNewFonts(struct hvGfx *hvg) /* Check to see if we want to use the alternate font engine (FreeType2). */ { if (sameString(cfgOptionDefault("freeType", "off"), "on")) { char *fontDir = cfgOptionDefault("freeTypeDir", "/usr/share/fonts/default/Type1"); - char *defaultFont = cfgOptionDefault("freeTypeDefault", "n022003l.pfb"); char buffer[4096]; extern char *freeTypeFontNames[]; extern char *freeTypeFontFiles[]; int ii; for(ii=0; ii < 33; ii++) if (sameString(freeTypeFontNames[ii], tl.textFont)) break; - defaultFont = freeTypeFontFiles[ii]; - safef(buffer, sizeof buffer, "%s/%s", fontDir, defaultFont); - hvGfxSetFontMethod(hvg, FONT_METHOD_FREETYPE, buffer ); + char *fontFile = freeTypeFontFiles[ii]; + char *fontName = freeTypeFontNames[ii]; + safef(buffer, sizeof buffer, "%s/%s", fontDir, fontFile); + hvGfxSetFontMethod(hvg, FONT_METHOD_FREETYPE, fontName, buffer ); } } boolean makeChromIdeoImage(struct track **pTrackList, char *psOutput, struct tempName *ideoTn) /* Make an ideogram image of the chromosome and our position in it. If the * ideoTn parameter is not NULL, it is filled in if the ideogram is created. */ { struct track *ideoTrack = NULL; MgFont *font = tl.font; char *mapName = "ideoMap"; struct hvGfx *hvg; boolean doIdeo = TRUE; int ideoWidth = round(.8 *tl.picWidth); int ideoHeight = 0;