1568N/Adiff --git a/src/Makefile.am b/src/Makefile.am
1568N/Aindex 37671e4..6d34ad3 100644
1568N/A--- a/src/Makefile.am
1568N/A+++ b/src/Makefile.am
535N/A@@ -17,6 +17,7 @@ libXp_la_SOURCES = \
535N/A XpPrinter.c \
535N/A XpPutData.c \
535N/A XpScreens.c \
535N/A+ XpDpi.c \
535N/A \
535N/A XpExtUtil.h
535N/A
1568N/Adiff --git a/./tmp-regen/src/XpDpi.c b/src/XpDpi.c
1568N/Anew file mode 100644
1568N/Aindex 0000000..cb9b909
1568N/A--- /dev/null
1568N/A+++ b/src/XpDpi.c
1408N/A@@ -0,0 +1,101 @@
535N/A+/* $XConsortium: XpDpi.c /main/4 1996/12/04 10:24:31 lehors $ */
535N/A+/******************************************************************************
535N/A+ ******************************************************************************
535N/A+ **
535N/A+ ** (c) Copyright 1996 Hewlett-Packard Company
535N/A+ ** (c) Copyright 1996 International Business Machines Corp.
943N/A+ ** (c) Copyright 1996, Oracle and/or its affiliates. All rights reserved.
535N/A+ ** (c) Copyright 1996 Novell, Inc.
535N/A+ ** (c) Copyright 1996 Digital Equipment Corp.
535N/A+ ** (c) Copyright 1996 Fujitsu Limited
535N/A+ ** (c) Copyright 1996 Hitachi, Ltd.
535N/A+ **
535N/A+ ** Permission is hereby granted, free of charge, to any person obtaining a copy
535N/A+ ** of this software and associated documentation files (the "Software"), to deal
535N/A+ ** in the Software without restriction, including without limitation the rights
535N/A+ ** to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
535N/A+ ** copies of the Software, and to permit persons to whom the Software is
535N/A+ ** furnished to do so, subject to the following conditions:
535N/A+ **
535N/A+ ** The above copyright notice and this permission notice shall be included in
535N/A+ ** all copies or substantial portions of the Software.
535N/A+ **
535N/A+ ** THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
535N/A+ ** IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
535N/A+ ** FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
535N/A+ ** COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
535N/A+ ** IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
535N/A+ ** CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
535N/A+ **
535N/A+ ** Except as contained in this notice, the names of the copyright holders shall
535N/A+ ** not be used in advertising or otherwise to promote the sale, use or other
535N/A+ ** dealings in this Software without prior written authorization from said
535N/A+ ** copyright holders.
535N/A+ **
535N/A+ ******************************************************************************
535N/A+ *****************************************************************************/
1408N/A+#ifdef HAVE_CONFIG_H
1408N/A+#include <config.h>
1408N/A+#endif
535N/A+#include <X11/extensions/Printstr.h>
1233N/A+#include "XpExtUtil.h"
535N/A+#include <X11/Xlibint.h>
1233N/A+#include <X11/Xos.h>
535N/A+#include <limits.h>
535N/A+#ifndef WIN32
535N/A+#define X_INCLUDE_PWD_H
535N/A+#define XOS_USE_XLIB_LOCKING
535N/A+#include <X11/Xos_r.h>
535N/A+#endif
535N/A+#include <limits.h>
535N/A+
535N/A+
535N/A+Bool
535N/A+XpClientDPI (
535N/A+ Display *dpy,
535N/A+ int client_dpi
535N/A+)
535N/A+{
535N/A+ xPrintClientDpiReq *req;
535N/A+ xPrintClientDpiReply rep;
535N/A+ XExtDisplayInfo *info = (XExtDisplayInfo *) xp_find_display (dpy);
535N/A+ short dpi = (short)client_dpi;
535N/A+
535N/A+ XPContext context;
535N/A+
535N/A+ if (XpCheckExtInit(dpy, XP_SECOND_RELEASE) == -1)
535N/A+ return (False); /* NoSuchExtension */
535N/A+
535N/A+ LockDisplay (dpy);
535N/A+
535N/A+ GetReq(PrintClientDpi,req);
535N/A+ req->reqType = info->codes->major_opcode;
535N/A+ req->printReqType = X_PrintClientDpi;
535N/A+ req->clientDPI = (CARD16) dpi;
535N/A+
535N/A+ if (! _XReply (dpy, (xReply *) &rep, 0, xTrue)) {
535N/A+ UnlockDisplay (dpy);
535N/A+ SyncHandle ();
535N/A+ return (False);
535N/A+ }
535N/A+
535N/A+ UnlockDisplay(dpy);
535N/A+ SyncHandle ();
535N/A+
535N/A+ return ( rep.status );
535N/A+}
535N/A+
535N/A+/*
535N/A+ * Bug 4402782: Add Sun specific propietary call until X.Org takes the
535N/A+ * change.
535N/A+ */
535N/A+#ifdef SUNSOFT
535N/A+Bool
535N/A+XpClientDPI_SUNW (
535N/A+ Display *dpy,
535N/A+ int client_dpi
535N/A+)
535N/A+{
535N/A+ return XpClientDPI(dpy, client_dpi);
535N/A+}
535N/A+#endif
1568N/Adiff --git a/src/XpExtUtil.c b/src/XpExtUtil.c
1568N/Aindex 89f66c0..b5ef6b8 100644
1568N/A--- a/src/XpExtUtil.c
1568N/A+++ b/src/XpExtUtil.c
1568N/A@@ -103,6 +103,7 @@ static XEXT_GENERATE_ERROR_STRING (XpError, xp_extension_name,
1568N/A */
1568N/A
1568N/A static XPrintLocalExtensionVersion xpprintversions[] = {{XP_ABSENT,0,0},
1568N/A+ {XP_PRESENT, XP_PROTO_MAJOR, 0},
1568N/A {XP_PRESENT, XP_PROTO_MAJOR, XP_PROTO_MINOR}};
1568N/A
1568N/A