//
// XPDFApp.cc
//
-// Copyright 2002 Glyph & Cog, LLC
+// Copyright 2002-2003 Glyph & Cog, LLC
//
//========================================================================
//------------------------------------------------------------------------
static String fallbackResources[] = {
+ "*.zoomComboBox*fontList: -*-helvetica-medium-r-normal--12-*-*-*-*-*-iso8859-1",
"*XmTextField.fontList: -*-courier-medium-r-normal--12-*-*-*-*-*-iso8859-1",
"*.fontList: -*-helvetica-medium-r-normal--12-*-*-*-*-*-iso8859-1",
"*XmTextField.translations: #override\\n"
installCmap = (GBool)resources.installCmap;
rgbCubeSize = resources.rgbCubeSize;
reverseVideo = (GBool)resources.reverseVideo;
- paperColor = reverseVideo ? BlackPixel(display, screenNum) :
- WhitePixel(display, screenNum);
+ if (reverseVideo) {
+ paperRGB = splashMakeRGB8(0x00, 0x00, 0x00);
+ paperColor = BlackPixel(display, screenNum);
+ } else {
+ paperRGB = splashMakeRGB8(0xff, 0xff, 0xff);
+ paperColor = WhitePixel(display, screenNum);
+ }
if (resources.paperColor) {
XtVaGetValues(appShell, XmNcolormap, &colormap, NULL);
if (XAllocNamedColor(display, colormap, resources.paperColor,
&xcol, &xcol2)) {
+ paperRGB = splashMakeRGB8(xcol.red >> 8,
+ xcol.green >> 8,
+ xcol.blue >> 8);
paperColor = xcol.pixel;
} else {
error(-1, "Couldn't allocate color '%s'", resources.paperColor);
while (viewers->getLength() > 0) {
delete (XPDFViewer *)viewers->del(0);
}
+#if HAVE_XTAPPSETEXITFLAG
XtAppSetExitFlag(appContext);
+#else
+ exit(0);
+#endif
}
void XPDFApp::run() {
app->remoteViewer->open(fileName, page, destName);
delete fileName;
}
- XFree((XPointer)cmd);
if (destName) {
delete destName;
}
XMapRaised(app->display, XtWindow(app->remoteWin));
XFlush(app->display);
}
+
+ XFree((XPointer)cmd);
}