Skip to Content.
Sympa Menu

sm-commit - [SM-Commit] GIT changes to master grimoire by Eric Sandall (bcec4bd7cf33ed4a36456b1dd34a626956539541)

sm-commit AT lists.ibiblio.org

Subject: Source Mage code commit list

List archive

Chronological Thread  
  • From: Eric Sandall <scm AT sourcemage.org>
  • To: sm-commit AT lists.ibiblio.org
  • Subject: [SM-Commit] GIT changes to master grimoire by Eric Sandall (bcec4bd7cf33ed4a36456b1dd34a626956539541)
  • Date: Sat, 4 Sep 2010 17:57:49 -0500

GIT changes to master grimoire by Eric Sandall <sandalle AT sourcemage.org>:

dev/null |binary
xorg-app/xditview/DETAILS | 13
xorg-app/xditview/HISTORY | 7
xorg-app/xditview/xditview-1.0.2.tar.bz2.sig |binary
xorg-app/xditview/xditview-X11R7.0-1.0.1.tar.bz2.sig | 0
xorg-app/xmore/DETAILS | 12
xorg-app/xmore/HISTORY | 8
xorg-app/xmore/PRE_BUILD | 10
xorg-app/xmore/xmore-1.0.2.tar.bz2.sig |binary
xorg-app/xmore/xmore-patch1.diff | 21
xorg-app/xmore/xmore-patch2.diff | 20
xorg-app/xmore/xmore-patch3.diff | 21
xorg-app/xmore/xmore-patch4.diff | 2216
-------------
xorg-app/xmore/xmore-patch5.diff | 20
xorg-app/xmore/xmore-patch6.diff | 390 --
xorg-app/xmore/xmore-patch7.diff | 156
xorg-app/xrandr/DETAILS | 2
xorg-app/xrandr/HISTORY | 4
xorg-app/xrandr/xrandr-1.3.2.tar.bz2.sig | 0
xorg-app/xrandr/xrandr-1.3.3.tar.bz2.sig |binary
xorg-app/xset/DEPENDS | 21
xorg-app/xset/DETAILS | 5
xorg-app/xset/HISTORY | 7
xorg-app/xset/xset-1.2.0.tar.bz2.sig |binary
xorg-driver/xf86-video-nv/DETAILS | 2
xorg-driver/xf86-video-nv/HISTORY | 4
xorg-driver/xf86-video-nv/xf86-video-nv-2.1.17.tar.bz2.sig | 0
xorg-driver/xf86-video-nv/xf86-video-nv-2.1.18.tar.bz2.sig |binary
xorg-proto/glproto/DETAILS | 2
xorg-proto/glproto/HISTORY | 3
xorg-proto/kbproto/DETAILS | 4
xorg-proto/kbproto/HISTORY | 5
32 files changed, 64 insertions(+), 2889 deletions(-)

New commits:
commit bcec4bd7cf33ed4a36456b1dd34a626956539541
Author: Eric Sandall <sandalle AT sourcemage.org>
Commit: Eric Sandall <sandalle AT sourcemage.org>

xset: Updated to 1.2.0
SOURCE matches upstream posted SHA1
xf86misc and fontcache configure flags added
libx11 is required
Removed *proto optional dependencies (depended upon by libraries used)

commit aed32d6852f8cf7c356f04ba426497ddf852c302
Author: Eric Sandall <sandalle AT sourcemage.org>
Commit: Eric Sandall <sandalle AT sourcemage.org>

xditview: Updated to 1.0.2
SOURCE matches upstream posted SHA1
Removed PATCHLEVEL
Removed PKG and XORG_VER
SOURCE_URL is now under individual/apps/

commit 16b285d2395687d8952800d9ff3e0125b061b950
Author: Eric Sandall <sandalle AT sourcemage.org>
Commit: Eric Sandall <sandalle AT sourcemage.org>

xmore: Removed XORG_VER and PKG

commit afe0d5d4ed68ea12267741d4f538dc02ed1ab019
Author: Eric Sandall <sandalle AT sourcemage.org>
Commit: Eric Sandall <sandalle AT sourcemage.org>

xmore: Updated to 1.0.2
SOURCE matches upstream posted SHA1
Removed PATCHLEVEL
Removed xmore-patch{1,2,3,4,5,6,7}.diff, included in release
Removed PRE_BUILD, no longer needed

commit abd214f43ec3a1b471e16b8bcaea80c2c7aa62e3
Author: Eric Sandall <sandalle AT sourcemage.org>
Commit: Eric Sandall <sandalle AT sourcemage.org>

xrandr: Updated to 1.3.3
SOURCE matches upstream posted SHA1

commit 7ee628606b99bb710eb26c8555cf15c1c24b9229
Author: Eric Sandall <sandalle AT sourcemage.org>
Commit: Eric Sandall <sandalle AT sourcemage.org>

xf86-video-nv: Updated to 2.1.18
SOURCE matches upstream posted SHA1

commit 993ec403d86cfb147173b731342ef77cd841aea5
Author: Eric Sandall <sandalle AT sourcemage.org>
Commit: Eric Sandall <sandalle AT sourcemage.org>

kbproto: Cleanup whitespace

commit d568b19ee4b6a8deb47de131977d6ccd7466b7cd
Author: Eric Sandall <sandalle AT sourcemage.org>
Commit: Eric Sandall <sandalle AT sourcemage.org>

glproto: Cleanup whitespace

diff --git a/xorg-app/xditview/DETAILS b/xorg-app/xditview/DETAILS
index 8e2ae20..3c8792d 100755
--- a/xorg-app/xditview/DETAILS
+++ b/xorg-app/xditview/DETAILS
@@ -1,15 +1,12 @@
SPELL=xditview
- PKG=xditview
- VERSION=1.0.1
- XORG_VER=X11R7.0
- SOURCE=${PKG}-${XORG_VER}-${VERSION}.tar.bz2
-
SOURCE_URL[0]=http://xorg.freedesktop.org/releases/${XORG_VER}/src/app/${SOURCE}
- SOURCE_GPG="gurus.gpg:${SOURCE}.sig"
-SOURCE_DIRECTORY=${BUILD_DIRECTORY}/${PKG}-${XORG_VER}-${VERSION}
+ VERSION=1.0.2
+ SOURCE=${SPELL}-${VERSION}.tar.bz2
+ SOURCE_GPG="gurus.gpg:${SOURCE}.sig:UPSTREAM_HASH"
+
SOURCE_URL[0]=http://xorg.freedesktop.org/releases/individual/app/${SOURCE}
+SOURCE_DIRECTORY=${BUILD_DIRECTORY}/${SPELL}-${VERSION}
WEB_SITE=http://xorg.freedesktop.org
ENTERED=20051125
LICENSE[0]=XCL
- PATCHLEVEL=1
SHORT="Module xditview for xorg"
cat << EOF
The XOrg Foundation, (a.k.a. X.org) has changed to an Open Source model to
diff --git a/xorg-app/xditview/HISTORY b/xorg-app/xditview/HISTORY
index 9ac793d..77e157e 100644
--- a/xorg-app/xditview/HISTORY
+++ b/xorg-app/xditview/HISTORY
@@ -1,3 +1,10 @@
+2010-09-04 Eric Sandall <sandalle AT sourcemage.org>
+ * DETAILS: Updated to 1.0.2
+ SOURCE matches upstream posted SHA1
+ Removed PATCHLEVEL
+ Removed PKG and XORG_VER
+ SOURCE_URL is now under individual/apps/
+
2009-01-26 Andraž "ruskie" Levstik <ruskie AT mages.ath.cx>
* DEPENDS: killing off XPrint
* DETAILS: patchlevel++
diff --git a/xorg-app/xditview/xditview-1.0.2.tar.bz2.sig
b/xorg-app/xditview/xditview-1.0.2.tar.bz2.sig
new file mode 100644
index 0000000..a8b6026
Binary files /dev/null and b/xorg-app/xditview/xditview-1.0.2.tar.bz2.sig
differ
diff --git a/xorg-app/xditview/xditview-X11R7.0-1.0.1.tar.bz2.sig
b/xorg-app/xditview/xditview-X11R7.0-1.0.1.tar.bz2.sig
deleted file mode 100644
index 4e80f66..0000000
Binary files a/xorg-app/xditview/xditview-X11R7.0-1.0.1.tar.bz2.sig and
/dev/null differ
diff --git a/xorg-app/xmore/DETAILS b/xorg-app/xmore/DETAILS
index 7fc5b0c..aae11d7 100755
--- a/xorg-app/xmore/DETAILS
+++ b/xorg-app/xmore/DETAILS
@@ -1,14 +1,12 @@
SPELL=xmore
- PKG=xmore
- VERSION=1.0.1
- XORG_VER=X11R7.0
- SOURCE=${PKG}-${VERSION}.tar.bz2
+ VERSION=1.0.2
+ SOURCE=${SPELL}-${VERSION}.tar.bz2
+ SOURCE_GPG="gurus.gpg:$SOURCE.sig:UPSTREAM_HASH"

SOURCE_URL[0]=http://xorg.freedesktop.org/releases/individual/app/${SOURCE}
-
SOURCE_HASH=sha512:4264f711d252d5ef9b2eecb4cf07b6957288691261e725c16850c4bf51761682686d09ee5508974b8b223f0b79aa71fa0f63ef796be2738646b71e736b60e5ed
-SOURCE_DIRECTORY=${BUILD_DIRECTORY}/${PKG}-${VERSION}
+#
SOURCE_HASH=sha512:4264f711d252d5ef9b2eecb4cf07b6957288691261e725c16850c4bf51761682686d09ee5508974b8b223f0b79aa71fa0f63ef796be2738646b71e736b60e5ed
+SOURCE_DIRECTORY=${BUILD_DIRECTORY}/${SPELL}-${VERSION}
WEB_SITE=http://xorg.freedesktop.org
ENTERED=20051125
- PATCHLEVEL=1
LICENSE[0]=XCL
SHORT="plain text display program for the X Window System"
cat << EOF
diff --git a/xorg-app/xmore/HISTORY b/xorg-app/xmore/HISTORY
index 987aead..5004cdf 100644
--- a/xorg-app/xmore/HISTORY
+++ b/xorg-app/xmore/HISTORY
@@ -1,3 +1,11 @@
+2010-09-04 Eric Sandall <sandalle AT sourcemage.org>
+ * DETAILS: Updated to 1.0.2
+ SOURCE matches upstream posted SHA1
+ Removed PATCHLEVEL
+ Removed XORG_VER and PKG
+ * xmore-patch{1,2,3,4,5,6,7}.diff: Removed, included in release
+ * PRE_BUILD: Removed, no longer needed
+
2009-01-26 Andraž "ruskie" Levstik <ruskie AT mages.ath.cx>
* DEPENDS: no more xaw8 and no more xprint
* CONFIGURE: removed
diff --git a/xorg-app/xmore/PRE_BUILD b/xorg-app/xmore/PRE_BUILD
deleted file mode 100755
index 9c67fcf..0000000
--- a/xorg-app/xmore/PRE_BUILD
+++ /dev/null
@@ -1,10 +0,0 @@
-default_pre_build &&
-cd $SOURCE_DIRECTORY &&
-local patches &&
-mkdir app-defaults &&
-mv XMore.ad app-defaults/XMore.ad &&
-for patches in $SPELL_DIRECTORY/xmore-patch*.diff ; do
- patch -p1 < $patches
-done &&
-mv app-defaults/XMore.ad app-defaults/XMore &&
-autoreconf
diff --git a/xorg-app/xmore/xmore-1.0.2.tar.bz2.sig
b/xorg-app/xmore/xmore-1.0.2.tar.bz2.sig
new file mode 100644
index 0000000..58d05a8
Binary files /dev/null and b/xorg-app/xmore/xmore-1.0.2.tar.bz2.sig differ
diff --git a/xorg-app/xmore/xmore-patch1.diff
b/xorg-app/xmore/xmore-patch1.diff
deleted file mode 100644
index adb2dcb..0000000
--- a/xorg-app/xmore/xmore-patch1.diff
+++ /dev/null
@@ -1,21 +0,0 @@
-From 8bd714835159aa32a64343a8dc41684d7c36ab43 Mon Sep 17 00:00:00 2001
-From: Jeremy Huddleston<jeremyhu AT freedesktop.org>
-Date: Fri, 28 Mar 2008 03:07:52 +0000
-Subject: Build fix for file systems that are not case sensitive
-
----
-diff --git a/Makefile.am b/Makefile.am
-index a2931af..007ade8 100644
---- a/Makefile.am
-+++ b/Makefile.am
-@@ -48,7 +48,7 @@ appdefaultdir = @appdefaultdir@
-
-
- APPDEFAULTFILES = \
-- XMore
-+ app-defaults/XMore
-
- SUFFIXES = .ad
-
---
-cgit v0.8.1-24-ge5fb
diff --git a/xorg-app/xmore/xmore-patch2.diff
b/xorg-app/xmore/xmore-patch2.diff
deleted file mode 100644
index 8ae7397..0000000
--- a/xorg-app/xmore/xmore-patch2.diff
+++ /dev/null
@@ -1,20 +0,0 @@
-From a85334f153e05119f237ff412a2ff15dce95878d Mon Sep 17 00:00:00 2001
-From: Jeremy Huddleston<jeremyhu AT freedesktop.org>
-Date: Fri, 28 Mar 2008 03:29:51 +0000
-Subject: Added missing AM_PROG_CC_C_O
-
----
-diff --git a/configure.ac b/configure.ac
-index 5c233b6..c07e54c 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -29,6 +29,7 @@ AM_MAINTAINER_MODE
- AM_CONFIG_HEADER(config.h)
-
- AC_PROG_CC
-+AM_PROG_CC_C_O
- AC_PROG_INSTALL
-
- # Checks for pkg-config packages
---
-cgit v0.8.1-24-ge5fb
diff --git a/xorg-app/xmore/xmore-patch3.diff
b/xorg-app/xmore/xmore-patch3.diff
deleted file mode 100644
index c0eff93..0000000
--- a/xorg-app/xmore/xmore-patch3.diff
+++ /dev/null
@@ -1,21 +0,0 @@
-From 56ff9e213249bbdc0ecd3b5e7e4cffee60f46ef4 Mon Sep 17 00:00:00 2001
-From: James Cloos<cloos AT jhcloos.com>
-Date: Wed, 20 Aug 2008 14:32:52 +0000
-Subject: xaw8 is gone, use xaw7
-
----
-diff --git a/configure.ac b/configure.ac
-index c07e54c..b67765c 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -33,7 +33,7 @@ AM_PROG_CC_C_O
- AC_PROG_INSTALL
-
- # Checks for pkg-config packages
--XAW_CHECK_XPRINT_SUPPORT(XMORE)
-+PKG_CHECK_MODULES(XMORE, xaw7)
- if test "x$xaw_use_xprint" = "xyes" ; then
- PKG_CHECK_MODULES(XPRINT_UTIL, xprintutil xp)
-
---
-cgit v0.8.1-24-ge5fb
diff --git a/xorg-app/xmore/xmore-patch4.diff
b/xorg-app/xmore/xmore-patch4.diff
deleted file mode 100644
index f65b0e5..0000000
--- a/xorg-app/xmore/xmore-patch4.diff
+++ /dev/null
@@ -1,2216 +0,0 @@
-From 7739b19df6a7eba2c35fc34688c40d64a65b79f5 Mon Sep 17 00:00:00 2001
-From: Julien Cristau<jcristau AT debian.org>
-Date: Wed, 20 Aug 2008 22:42:51 +0000
-Subject: Build fix: remove xprint remnants
-
----
-diff --git a/Makefile.am b/Makefile.am
-index 007ade8..d8aa027 100644
---- a/Makefile.am
-+++ b/Makefile.am
-@@ -28,17 +28,6 @@ xmore_SOURCES = \
- xmore.c \
- xmore.h
-
--if XAW_USE_XPRINT
--xmore_CFLAGS += -DUSE_XPRINT
--
--xmore_SOURCES += \
-- print.c \
-- printdialog.c \
-- printdialog.h \
-- printdialogprivates.h \
-- print.h
--endif
--
- appman_PRE = \
- xmore.man
-
-diff --git a/configure.ac b/configure.ac
-index b67765c..34d6aa6 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -34,12 +34,6 @@ AC_PROG_INSTALL
-
- # Checks for pkg-config packages
- PKG_CHECK_MODULES(XMORE, xaw7)
--if test "x$xaw_use_xprint" = "xyes" ; then
-- PKG_CHECK_MODULES(XPRINT_UTIL, xprintutil xp)
--
-- XMORE_CFLAGS="$XMORE_CFLAGS $XPRINT_UTIL_CFLAGS"
-- XMORE_LIBS="$XMORE_LIBS $XPRINT_UTIL_LIBS"
--fi
-
- AC_SUBST(XMORE_CFLAGS)
- AC_SUBST(XMORE_LIBS)
-diff --git a/print.c b/print.c
-deleted file mode 100644
-index fbb260b..0000000
---- a/print.c
-+++ b/dev/null
-@@ -1,435 +0,0 @@
--/*
-- * $Xorg: print.c,v 1.1 2004/04/30 02:05:54 gisburn Exp $
-- *
--Copyright 2004 Roland Mainz <roland.mainz AT nrubsig.org>
--
--Permission to use, copy, modify, distribute, and sell this software and its
--documentation for any purpose is hereby granted without fee, provided that
--the above copyright notice appear in all copies and that both that
--copyright notice and this permission notice appear in supporting
--documentation.
--
--The above copyright notice and this permission notice shall be included in
--all copies or substantial portions of the Software.
--
--THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
--IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
--FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
--OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
--AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
--CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
--
--Except as contained in this notice, the name of The Open Group shall not be
--used in advertising or otherwise to promote the sale, use or other dealings
--in this Software without prior written authorization from The Open Group.
-- *
-- */
--
--/* Turn a NULL pointer string into an empty string */
--#define NULLSTR(x) (((x)!=NULL)?(x):(""))
--
--#define Error(x) { printf x ; exit(EXIT_FAILURE); }
--#define Assertion(expr, msg) { if (!(expr)) { Error msg } }
--#define Log(x) { if(True) printf x; }
--
--#ifdef XEDIT
--#include "xedit.h"
--#endif /* XEDIT */
--#include "print.h"
--#include <X11/Xaw/Form.h>
--#include <X11/Xaw/Label.h>
--#include <X11/Xaw/AsciiText.h>
--#include <stdio.h>
--#include <stdlib.h>
--
--static Widget
--CreatePrintShell(Widget videoshell,
-- Screen *pscreen,
-- Visual *pvisual,
-- String printshell_name,
-- ArgList args,
-- Cardinal numargs)
--{
-- String videoname,
-- videoclass;
-- Widget pappshell,
-- printshell;
-- Display *pdpy = XDisplayOfScreen(pscreen);
-- int dummyc = 0;
-- String dummys = "";
-- Cardinal shell_n;
-- Arg shell_args[5];
--
-- XtGetApplicationNameAndClass(XtDisplay(videoshell),
-- &videoname, &videoclass);
--
-- /* XXX: Why is the |dummyc|&&|dummys| stuff needed here ? */
-- XtDisplayInitialize(XtWidgetToApplicationContext(videoshell), pdpy,
-- videoname, videoclass,
-- NULL, 0,
-- &dummyc, &dummys);
--
-- shell_n = 0;
-- XtSetArg(shell_args[shell_n], XtNscreen, pscreen); shell_n++;
-- if (pvisual) {
-- XtSetArg(shell_args[shell_n], XtNvisual, pvisual); shell_n++;
-- }
-- pappshell = XtAppCreateShell(videoname, videoclass,
-- applicationShellWidgetClass,
-- pdpy,
-- shell_args, shell_n);
-- printshell = XtCreatePopupShell(printshell_name,
-- xawPrintShellWidgetClass,
-- pappshell, args, numargs);
--
--
-- /* we're mapping/unmapping at start/end page time */
-- XtSetMappedWhenManaged(printshell, False);
--
-- /* We realise the widget when we're done with building the widget
tree... */
--
-- return printshell;
--}
--
--typedef struct
--{
-- const char *programname;
-- Widget toplevel;
-- Bool isPrinting;
-- Widget printshell;
-- struct
-- {
-- Widget form;
-- Widget pageheaderlabel;
-- Widget text;
-- } content; /* content to print */
-- int numpages;
-- Display *pdpy;
-- Screen *pscreen;
-- XPContext pcontext;
-- XtCallbackProc pdpyDestroyCallback;
-- void *printtofile_handle;
-- const char *jobtitle;
--} AppPrintData;
--
--static AppPrintData apdx;
--static AppPrintData *apd = &apdx;
--
--/* Count pages in a text widget
-- * WARNING: This will reset the current position of the text widget
-- * back to the beginning */
--static
--long CountPages(Widget textWidget)
--{
-- long numpages = 0;
--
-- XawTextPosition prevpagepos = -1,
-- currpos = 0;
--
-- /* Move to the top of the file... */
-- XtCallActionProc(textWidget, "beginning-of-file", NULL, NULL, 0);
--
-- /* ... count pages ...*/
-- do
-- {
-- prevpagepos = XawTextTopPosition(textWidget);
-- XtCallActionProc(textWidget, "next-page", NULL, NULL, 0);
-- currpos = XawTextTopPosition(textWidget);
-- numpages++;
-- } while(prevpagepos != currpos);
--
-- /* ... and move to the top of the file... */
-- XtCallActionProc(textWidget, "beginning-of-file", NULL, NULL, 0);
--
-- Log(("CountPages() found %ld pages.\n", numpages))
--
-- return numpages;
--}
--
--static void
--PageSetupCB(Widget widget, XtPointer client_data, XtPointer call_data)
--{
-- Widget pshell = widget;
-- XawPrintShellCallbackStruct *psp = (XawPrintShellCallbackStruct
*)call_data;
-- AppPrintData *p = (AppPrintData *)client_data;
--
-- Log(("--> PageSetupCB\n"));
--
-- if (!psp->last_page_in_job) {
-- int currpage;
-- char buffer[256];
--
-- XtVaGetValues(pshell, XawNcurrPageNumInJob, &currpage, NULL);
--
-- sprintf(buffer, "Title: %s / Page: %d/%d", p->jobtitle, currpage,
p->numpages);
-- XtVaSetValues(apd->content.pageheaderlabel, XtNlabel, buffer, NULL);
--
-- /* Note: XawPrintShell's pagecount starts with '1'
-- * (=first page is page no. '1') */
-- if (currpage > 1) {
-- Log(("pagedown %d\n", currpage));
-- XtCallActionProc(p->content.text, "next-page", NULL, NULL, 0);
-- }
-- else
-- {
-- Log(("first page\n"));
-- }
--
-- if (currpage >= p->numpages) {
-- psp->last_page_in_job = True;
-- }
-- }
--}
--
--static
--void FinishPrinting(AppPrintData *p)
--{
-- char *scr;
--
-- if (p->printtofile_handle) {
-- if (XpuWaitForPrintFileChild(p->printtofile_handle) !=
XPGetDocFinished) {
-- PrintMsg(("Error while printing to file.\n"));
-- }
-- p->printtofile_handle = NULL;
-- }
--
-- /* Job completed, check if there are any messages from the spooler
command */
-- scr = XpGetOneAttribute(p->pdpy, p->pcontext, XPJobAttr,
"xp-spooler-command-results");
-- if( scr )
-- {
-- if( strlen(scr) > 0 )
-- {
-- const char *msg = XpuCompoundTextToXmb(p->pdpy, scr);
-- if( msg )
-- {
-- PrintMsg(("Spooler command returned:\n%s", msg));
-- XpuFreeXmbString(msg);
-- }
-- else
-- {
-- PrintMsg(("Spooler command returned (unconverted):\n%s", scr));
-- }
-- }
--
-- XFree((void *)scr);
-- }
--
-- if (p->printshell) {
-- XtDestroyWidget(p->printshell);
-- p->printshell = NULL;
-- }
--
-- /* Two issues here:
-- * 1. The print display connection is owned by the print dialog
-- * To avoid any problems with that use a callback back to the main
-- * application which calls
-- * |XawPrintDialogClosePrinterConnection(w, False)| to ask the
-- * print dialog widget to close all print display resources and
-- * disown the object.
-- * 2. We have to use XpDestroyContext() and XtCloseDisplay()
-- * instead of XpuClosePrinterDisplay() to make libXt happy...
-- *
-- * Call callback... */
-- (*apd->pdpyDestroyCallback)(NULL, NULL, NULL); /* HACK! */
--
-- /* ... and then get rid of the display */
-- if (p->pcontext != None) {
-- XpDestroyContext(p->pdpy, p->pcontext);
-- }
-- XtCloseDisplay(p->pdpy);
--
-- p->toplevel = NULL;
-- p->isPrinting = False;
-- p->pdpy = NULL;
-- p->pscreen = NULL;
-- p->pcontext = None;
--}
--
--static
--void PrintEndJobCB(Widget pshell, XtPointer client_data, XtPointer
call_data)
--{
-- AppPrintData *p = (AppPrintData *)client_data;
--
-- Log(("--> PrintEndJobCB\n"));
--
-- /* Finish printing and destroy print shell (it's legal to destroy Xt
-- * widgets from within it's own callbacks) */
-- FinishPrinting(p);
--}
--
--static
--XFontSet GetPrintTextFontSet(const char *appname, Display *pdpy, long
dpi_x, long dpi_y)
--{
-- XFontSet fontset;
-- char fontname[1024];
-- char **missing_charset_list_return;
-- int missing_charset_count_return;
-- char *def_string_return;
-- int i;
--
-- sprintf(fontname, /* Default font for CDE */
-- "-dt-interface
user-medium-r-normal-s*-*-120-%ld-%ld-*-*,"
-- /* Default font */
-- "-adobe-courier-medium-r-normal--*-120-%ld-%ld-*-*,"
-- /* Default font for Linux/Japanese locales
(ja_JP.SJIS) */
-- "-watanabe-mincho-medium-r-normal--*-120-%ld-%ld-*-*,"
-- "-wadalab-gothic-medium-r-normal--*-120-%ld-%ld-*-*,"
-- /* Fallback */
-- "-*-*-*-*-*--*-120-%ld-%ld-*-*",
-- dpi_x, dpi_y,
-- dpi_x, dpi_y,
-- dpi_x, dpi_y,
-- dpi_x, dpi_y,
-- dpi_x, dpi_y);
-- fontset = XCreateFontSet(pdpy, fontname,
-- &missing_charset_list_return,
-- &missing_charset_count_return,
-- &def_string_return);
--
-- for( i=0 ; i < missing_charset_count_return ; i++ ) {
-- fprintf(stderr, "%s: warning: font for charset %s is lacking.\n",
-- appname, missing_charset_list_return[i]);
-- }
--
-- if (!fontset)
-- Error(("GetPrintTextFontSet: XCreateFontSet() failure.\n"));
-- return fontset;
--}
--
--void DoPrintTextSource(const char *programname,
-- Widget textsource, Widget toplevel,
-- Display *pdpy, XPContext pcontext,
-- XpuColorspaceRec *colorspace,
-- XtCallbackProc pdpyDestroyCB,
-- const char *jobtitle, const char *toFile)
--{
-- long dpi_x = 0L,
-- dpi_y = 0L;
-- int n;
-- Arg args[20];
-- XFontSet textfontset = NULL;
-- XFontSetExtents *font_extents;
--
-- apd->programname = programname;
-- apd->pdpyDestroyCallback = pdpyDestroyCB;
--
-- if (apd->isPrinting) {
-- PrintMsg(("Already busy with printing.\n"));
-- return;
-- }
--
-- /* Configure the print context (paper size, title etc.)
-- * We must do this before creating any Xt widgets - otherwise they will
-- * make wrong assuptions about fonts, resultions etc. ...
-- */
-- XpuSetJobTitle(pdpy, pcontext, jobtitle);
--
-- /* Configuration done, set the context */
-- XpSetContext(pdpy, pcontext);
--
-- /* Get default printer resolution */
-- if (XpuGetResolution(pdpy, pcontext, &dpi_x, &dpi_y) != 1) {
-- PrintMsg(("No default resolution for printer.\n"));
-- XpuClosePrinterDisplay(pdpy, pcontext);
-- return;
-- }
--
-- apd->toplevel = toplevel;
-- apd->pdpy = pdpy;
-- apd->pcontext = pcontext;
-- apd->pscreen = XpGetScreenOfContext(pdpy, pcontext);
-- apd->jobtitle = jobtitle;
--
-- n = 0;
-- /* Override any geometry resource settings as XawPrintShell adjusts
it's size
-- * to the current page siue when |XawPrintLAYOUTMODE_DRAWABLEAREA| or
-- * |XawPrintLAYOUTMODE_PAGESIZE| are used. */
-- XtSetArg(args[n], XtNgeometry, "+0+0"); n++;
-- XtSetArg(args[n], XawNlayoutMode, XawPrintLAYOUTMODE_DRAWABLEAREA); n++;
-- if (colorspace) {
-- printf("Setting visual to id=0x%lx.\n",
colorspace->visualinfo.visualid);
-- }
-- apd->printshell = CreatePrintShell(toplevel, apd->pscreen,
--
(colorspace?(colorspace->visualinfo.visual):(NULL)),
-- "printshell", args, n);
-- n = 0;
-- XtSetArg(args[n], XtNresizable, True); n++;
-- XtSetArg(args[n], XtNright, XtChainRight); n++;
-- apd->content.form = XtCreateManagedWidget("form", formWidgetClass,
apd->printshell, args, n);
--
-- textfontset = GetPrintTextFontSet(apd->programname, pdpy, dpi_x, dpi_y);
--
-- n = 0;
-- XtSetArg(args[n], XtNinternational, True); n++;
-- XtSetArg(args[n], XtNfromHoriz, NULL); n++;
-- XtSetArg(args[n], XtNfromVert, NULL); n++;
-- XtSetArg(args[n], XtNtop, XtChainTop); n++;
-- XtSetArg(args[n], XtNright, XtChainRight); n++;
-- XtSetArg(args[n], XtNresizable, True); n++;
-- XtSetArg(args[n], XtNfontSet, textfontset); n++;
-- XtSetArg(args[n], XtNlabel, "Page: n/n"); n++;
-- XtSetArg(args[n], XtNjustify, XtJustifyRight); n++;
-- apd->content.pageheaderlabel = XtCreateManagedWidget("pageinfo",
labelWidgetClass, apd->content.form, args, n);
--
-- font_extents = XExtentsOfFontSet(textfontset);
--
-- n = 0;
-- XtSetArg(args[n], XtNinternational, True);
n++;
-- XtSetArg(args[n], XtNtextSource, textsource);
n++;
-- XtSetArg(args[n], XtNscrollHorizontal, XawtextScrollNever);
n++;
-- XtSetArg(args[n], XtNscrollVertical, XawtextScrollNever);
n++;
--
--/* Usually I would expect that using |XtNfromVert,
apd->content.pageheaderlabel|
-- * would be the correct way to place the text widget with the main content
below
-- * the page header widget - but for an unknown reason this doesn not work:
The
-- * text widget squishes itself into the bottom half of the page and only
occupies
-- * 1/2 of the page's with... ;-(( */
--#define WORKAROUND_FOR_SOMETHING_IS_WRONG 1
--#ifdef WORKAROUND_FOR_SOMETHING_IS_WRONG
-- XtSetArg(args[n], XtNtop, XtChainTop);
n++;
-- XtSetArg(args[n], XtNright, XtChainRight);
n++;
-- XtSetArg(args[n], XtNvertDistance,
(font_extents->max_logical_extent.height+2)*2); n++;
--#else
-- XtSetArg(args[n], XtNfromHoriz, NULL);
n++;
-- XtSetArg(args[n], XtNfromVert, apd->content.pageheaderlabel);
n++;
--#endif
-- XtSetArg(args[n], XtNfontSet, textfontset);
n++;
-- apd->content.text = XtCreateManagedWidget("text", asciiTextWidgetClass,
apd->content.form, args, n);
--
-- /* Disable the caret - that is not needed for printing */
-- XawTextDisplayCaret(apd->content.text, False);
--
-- XtAddCallback(apd->printshell, XawNpageSetupCallback, PageSetupCB,
(XtPointer)apd);
-- XtAddCallback(apd->printshell, XawNendJobCallback, PrintEndJobCB,
(XtPointer)apd);
--
-- /* Realise print shell (which will set position+size of the child
-- * widgets based on the current page size) */
-- XtRealizeWidget(apd->printshell);
--
-- /* Count number of pages in the text widget */
-- apd->numpages = CountPages(apd->content.text);
--
-- /* Make sure that the Xt machinery is really using the right screen
(assertion) */
-- if (XpGetScreenOfContext(XtDisplay(apd->printshell), apd->pcontext) !=
XtScreen(apd->printshell))
-- Error(("Widget's screen != print screen. BAD.\n"));
--
-- apd->isPrinting = True;
--
-- if (toFile) {
-- PrintMsg(("Printing to file '%s'...\n", toFile));
-- apd->printtofile_handle = XpuStartJobToFile(pdpy, pcontext, toFile);
-- if (!apd->printtofile_handle) {
-- perror("XpuStartJobToFile failure");
-- PrintMsg(("Printing failed: XpuStartJobToFile\n"));
-- apd->isPrinting = False;
-- return;
-- }
-- }
-- else
-- {
-- PrintMsg(("Printing to printer...\n"));
-- XpuStartJobToSpooler(pdpy);
-- }
--}
--
--
-diff --git a/print.h b/print.h
-deleted file mode 100644
-index a87779c..0000000
---- a/print.h
-+++ b/dev/null
-@@ -1,56 +0,0 @@
--/*
-- * $Xorg: print.h,v 1.1 2004/04/30 02:05:54 gisburn Exp $
-- *
--Copyright 2004 Roland Mainz <roland.mainz AT nrubsig.org>
--
--Permission to use, copy, modify, distribute, and sell this software and its
--documentation for any purpose is hereby granted without fee, provided that
--the above copyright notice appear in all copies and that both that
--copyright notice and this permission notice appear in supporting
--documentation.
--
--The above copyright notice and this permission notice shall be included in
--all copies or substantial portions of the Software.
--
--THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
--IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
--FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
--OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
--AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
--CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
--
--Except as contained in this notice, the name of The Open Group shall not be
--used in advertising or otherwise to promote the sale, use or other dealings
--in this Software without prior written authorization from The Open Group.
-- *
-- */
--
--#ifndef XMORE_PRINT_H
--#define XMORE_PRINT_H 1
--
--#include <X11/Intrinsic.h>
--#include <X11/StringDefs.h>
--#include <X11/Shell.h>
--#include <X11/Xaw/Print.h>
--#include <X11/Xaw/Cardinals.h>
--#include <X11/XprintUtil/xprintutil.h>
--
--#if defined(XMORE)
--#define PrintMsg(x) { printf("xmore: "); printf x ; }
--#elif defined(XEDIT)
--#define PrintMsg(x) { XeditPrintf x ; }
--#else
--#error unknown application
--#endif
--
--/* Prototypes */
--void DoPrintTextSource(const char *programname,
-- Widget textsource,
-- Widget toplevel,
-- Display *pdpy, XPContext pcontext,
-- XpuColorspaceRec *colorspace,
-- XtCallbackProc printDisplayDestroyCallback,
-- const char *jobTitle,
-- const char *toFile);
--
--#endif /* !XMORE_PRINT_H */
-diff --git a/printdialog.c b/printdialog.c
-deleted file mode 100644
-index 50d2a88..0000000
---- a/printdialog.c
-+++ b/dev/null
-@@ -1,1396 +0,0 @@
--/*
-- * $Xorg: printdialog.c,v 1.1 2004/05/12 02:05:54 gisburn Exp $
-- *
--Copyright 2004 Roland Mainz <roland.mainz AT nrubsig.org>
--
--Permission to use, copy, modify, distribute, and sell this software and its
--documentation for any purpose is hereby granted without fee, provided that
--the above copyright notice appear in all copies and that both that
--copyright notice and this permission notice appear in supporting
--documentation.
--
--The above copyright notice and this permission notice shall be included in
--all copies or substantial portions of the Software.
--
--THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
--IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
--FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
--OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
--AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
--CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
--
--Except as contained in this notice, the name of The Open Group shall not be
--used in advertising or otherwise to promote the sale, use or other dealings
--in this Software without prior written authorization from The Open Group.
-- *
-- */
--
--/* Force ANSI C prototypes from X11 headers */
--#ifndef FUNCPROTO
--#define FUNCPROTO 15
--#endif /* !FUNCPROTO */
--
--#include <X11/StringDefs.h>
--#include <X11/Intrinsic.h>
--#include <X11/Shell.h>
--#include <X11/Xaw/Form.h>
--#include <X11/Xaw/Toggle.h>
--#include <X11/Xaw/List.h>
--#include <X11/Xaw/Command.h>
--#include <X11/Xaw/AsciiText.h>
--#include <X11/Xaw/Dialog.h>
--
--#ifdef XKB
--#include <X11/extensions/XKBbells.h>
--#endif /* XKB */
--
--#ifdef XEDIT
--#include "xedit.h"
--#endif /* XEDIT */
--#include "printdialog.h"
--#include "printdialogprivates.h"
--#include "print.h"
--
--#include <stdlib.h>
--#include <ctype.h>
--#include <stdio.h>
--
--/* Turn a NULL pointer string into an empty string */
--#define NULLSTR(x) (((x)!=NULL)?(x):(""))
--
--#define Error(x) { printf x ; exit(EXIT_FAILURE); }
--#define Assertion(expr, msg) { if (!(expr)) { Error msg } }
--#ifdef DEBUG
--# define Log(x) { if(True) printf x; }
--#else
--# define Log(x) { if(False) printf x; }
--#endif /* DEBUG */
--
--/* Local prototypes */
--static void do_beep(PrintDialogWidget pdw);
--static void center_popup(Widget parent, Widget popup);
--static void updateWidgetStates(PrintDialogWidget pdw);
--static void printSetupClose(PrintDialogWidget pdw);
--static void printSetupOKXtProc(Widget w, XtPointer client_data,
XtPointer callData);
--static void printSetupCancelXtProc(Widget w, XtPointer client_data,
XtPointer callData);
--static void printSetupJobCopiesXtProc(Widget w, XtPointer client_data,
XtPointer callData);
--static void printDialogDestXtProc(Widget w, XtPointer client_data,
XtPointer callData);
--static void printSelectFileXtProc(Widget w, XtPointer client_data,
XtPointer callData);
--static void printOKXtProc(Widget w, XtPointer client_data, XtPointer
callData);
--static void printSetupXtProc(Widget w, XtPointer client_data, XtPointer
callData);
--static void printFileSelectedXtProc(Widget w, XtPointer client_data,
XtPointer callData);
--static void buildFileDialog(PrintDialogWidget pdw);
--static void closePrinterConnection(PrintDialogWidget pdw, Bool
closeDisplay);
--static Bool openPrinterConnection(PrintDialogWidget pdw);
--static void destroyPrintSetupDialog(PrintDialogWidget pdw);
--static Widget buildPrintSetupDialog(PrintDialogWidget pdw);
--static String *xpprinterlist_to_widget_printerlist(XPPrinterList
printerlist, int num_printers);
--static String *xppaperlist_to_widget_paperlist(XpuMediumSourceSizeList
paperlist, int num_papers);
--static String *xpresolutionlist_to_widget_resolutionlist(XpuResolutionList
reslist, int num_resolutions);
--static String
*xporientationlist_to_widget_orientationlist(XpuOrientationList
orientationlist, int num_orientations);
--static String *xpplexlist_to_widget_plexlist(XpuPlexList plexlist, int
num_plex);
--static String *xpcolorspacelist_to_widget_colorspacelist(XpuColorspaceList
colorspacelist, int num_colorspaces);
--static void printerSelectionPrinterSelectedXtProc(Widget w, XtPointer
client_data, XtPointer callData);
--static void printSelectPrinterXtProc(Widget w, XtPointer client_data,
XtPointer callData);
--static void printerSelectionClose(PrintDialogWidget pdw);
--static void printerSelectionOKXtProc(Widget w, XtPointer client_data,
XtPointer callData);
--static void printerSelectionCancelXtProc(Widget w, XtPointer
client_data, XtPointer callData);
--static Bool buildPrinterSelectionDialog(PrintDialogWidget pdw);
--static void destroyPrinterSelectionDialog(PrintDialogWidget pdw);
--static void createprintdialogchildren(Widget w);
--
--static
--void do_beep(PrintDialogWidget pdw)
--{
-- Log(("*** Beep!\n"));
--#ifdef XKB
-- XkbStdBell(XtDisplay((Widget)pdw), XtWindow((Widget)pdw), 0,
XkbBI_MinorError);
--#else
-- XBell(XtDisplay((Widget)pdw), 0);
--#endif /* XKB */
--}
--
--/* Center popup (on parent, not on screen - which would be a bad idea
-- * in the Xinerama case) */
--static
--void center_popup(Widget parent, Widget popup)
--{
-- Dimension width,
-- height;
-- Position x,
-- y;
--
-- XtVaGetValues(parent,
-- XtNx, &x,
-- XtNy, &y,
-- NULL);
-- XtVaGetValues(popup,
-- XtNwidth, &width,
-- XtNheight, &height,
-- NULL);
--
-- x += (Position)width / 2;
-- y += (Position)height / 3;
--
-- XtVaSetValues(popup,
-- XtNx, x,
-- XtNy, y,
-- NULL);
--}
--
--static
--void updateWidgetStates(PrintDialogWidget pdw)
--{
-- PrintDialogPart *pdp = &pdw->printdialog;
--
-- /* Do not update anything if we will be destroyed */
-- if (pdw->core.being_destroyed)
-- return;
--
-- if (pdp->printToFile == False) {
-- XtVaSetValues(pdp->main.printtoprinter, XtNstate, True, NULL);
-- XtVaSetValues(pdp->main.printtofile, XtNstate, False, NULL);
-- /* Disable the widgets which depend on print-to-file */
-- XtVaSetValues(pdp->main.filenamelabel, XtNsensitive, False, NULL);
-- XtVaSetValues(pdp->main.filename, XtNsensitive, False, NULL);
-- XtVaSetValues(pdp->main.selectfile, XtNsensitive, False, NULL);
-- }
-- else
-- {
-- XtVaSetValues(pdp->main.printtoprinter, XtNstate, False, NULL);
-- XtVaSetValues(pdp->main.printtofile, XtNstate, True, NULL);
-- /* Enable the widgets which depend on print-to-file */
-- XtVaSetValues(pdp->main.filenamelabel, XtNsensitive, True, NULL);
-- XtVaSetValues(pdp->main.filename, XtNsensitive, True, NULL);
-- XtVaSetValues(pdp->main.selectfile, XtNsensitive, True, NULL);
-- }
--
-- /* Update file name */
-- XtVaSetValues(pdp->main.filename, XtNlabel,
pdp->filename?pdp->filename:"-", NULL);
--
-- /* General check whether we can print... */
-- pdp->canPrint = True;
-- if (pdp->printer_name == NULL) {
-- pdp->canPrint = False;
-- }
-- else if (strlen(pdp->printer_name) == 0) {
-- pdp->canPrint = False;
-- }
--
-- pdp->canReallyPrint = pdp->canPrint;
--
-- /* Some extra checks for print-to-file */
-- if (pdp->printToFile) {
-- if (pdp->filename == NULL) {
-- pdp->canReallyPrint = False;
-- }
-- else if (strlen(pdp->filename) == 0) {
-- pdp->canReallyPrint = False;
-- }
-- }
--
-- XtVaSetValues(pdp->main.ok, XtNsensitive, pdp->canReallyPrint, NULL);
-- XtVaSetValues(pdp->main.setup, XtNsensitive, pdp->canPrint, NULL);
--}
--
--static void
--printSetupClose(PrintDialogWidget pdw)
--{
-- PrintDialogPart *pdp = &pdw->printdialog;
-- if (pdp->setup.popup) {
-- XtPopdown(pdp->setup.popup);
-- }
--}
--
--static void
--printSetupOKXtProc(Widget w, XtPointer client_data, XtPointer callData)
--{
-- PrintDialogWidget pdw = (PrintDialogWidget)client_data;
-- PrintDialogPart *pdp = &pdw->printdialog;
-- char *s;
-- XawListReturnStruct *lrs;
-- Log(("## printSetupOK: closing print setup!\n"));
--
-- /* Set copy count (if the value is invalid beep and return to the user
) */
-- XtVaGetValues(pdp->setup.jobcopies, XtNstring, &s, NULL);
-- if (s) {
-- int c = atoi(s);
-- if (c < 1 || c > 999) {
-- do_beep(pdw);
-- XtVaSetValues(pdp->setup.jobcopies, XtNstring, "1", NULL);
-- Log(("## printSetupOKXtProc: not a valid copy count value\n"));
-- return;
-- }
--
-- /* Fix me: We should set the number of _job_ copies here, not _doc_
copies */
-- XpuSetDocumentCopies(pdp->pdpy, pdp->pcontext, c);
-- }
--
-- /* Set paper size */
-- lrs = XawListShowCurrent(pdp->setup.paperlist);
-- if (lrs->list_index != XAW_LIST_NONE) {
-- Log(("selected paper is '%s'/'%d'\n", lrs->string,
lrs->list_index));
-- Assertion(lrs->list_index < pdp->num_papers, (("Error:
lrs->list_index < pdp->num_papers\n")));
-- XpuSetDocMediumSourceSize(pdp->pdpy, pdp->pcontext,
&pdp->paperlist[lrs->list_index]);
-- }
-- XtFree((char *)lrs);
--
-- /* Set resolution */
-- lrs = XawListShowCurrent(pdp->setup.resolutionlist);
-- if (lrs->list_index != XAW_LIST_NONE) {
-- Log(("selected resolution is '%s'/'%d'\n", lrs->string,
lrs->list_index));
-- Assertion(lrs->list_index < pdp->num_resolutions, (("Error:
lrs->list_index < pdp->num_resolutions\n")));
-- XpuSetDocResolution(pdp->pdpy, pdp->pcontext,
&pdp->resolutionlist[lrs->list_index]);
-- }
-- XtFree((char *)lrs);
--
-- /* Set orientation */
-- lrs = XawListShowCurrent(pdp->setup.orientationlist);
-- if (lrs->list_index != XAW_LIST_NONE) {
-- Log(("selected orientation is '%s'/'%d'\n", lrs->string,
lrs->list_index));
-- Assertion(lrs->list_index < pdp->num_orientations, (("Error:
lrs->list_index < pdp->num_orientations\n")));
-- XpuSetDocOrientation(pdp->pdpy, pdp->pcontext,
&pdp->orientationlist[lrs->list_index]);
-- }
-- XtFree((char *)lrs);
--
-- /* Set plex mode */
-- lrs = XawListShowCurrent(pdp->setup.plexlist);
-- if (lrs->list_index != XAW_LIST_NONE) {
-- Log(("selected plex is '%s'/'%d'\n", lrs->string, lrs->list_index));
-- Assertion(lrs->list_index < pdp->num_plex, (("Error:
lrs->list_index < pdp->num_plex\n")));
-- XpuSetDocPlex(pdp->pdpy, pdp->pcontext,
&pdp->plexlist[lrs->list_index]);
-- }
-- XtFree((char *)lrs);
--
-- /* Set colorspace */
-- lrs = XawListShowCurrent(pdp->setup.colorspacelist);
-- if (lrs->list_index != XAW_LIST_NONE) {
-- Log(("selected colorspace is '%s'/'%d'\n", lrs->string,
lrs->list_index));
-- Assertion(lrs->list_index < pdp->num_colorspaces, (("Error:
lrs->list_index < pdp->num_colorspaces\n")));
-- pdp->selected_colorspace = &pdp->colorspacelist[lrs->list_index];
-- }
-- XtFree((char *)lrs);
--
-- printSetupClose(pdw);
--}
--
--static void
--printSetupCancelXtProc(Widget w, XtPointer client_data, XtPointer callData)
--{
-- PrintDialogWidget pdw = (PrintDialogWidget)client_data;
-- Log(("## printSetupCancel: closing print setup!\n"));
--
-- printSetupClose(pdw);
--}
--
--static void
--printSetupJobCopiesXtProc(Widget w, XtPointer client_data, XtPointer
callData)
--{
-- PrintDialogWidget pdw = (PrintDialogWidget)client_data;
-- PrintDialogPart *pdp = &pdw->printdialog;
-- char *string = NULL;
--
-- Log(("## printSetupJobCopiesXtProc!\n"));
--
-- /* Check whether the input is a valid number - and in the case of
invalid input reset the value */
-- XtVaGetValues(pdp->setup.jobcopies, XtNstring, &string, NULL);
-- if (string) {
-- char *s;
-- int i;
-- Bool isValidNumber = True;
--
-- /* First check for invalid characters... */
-- for( s = string ; *s != '\0' ; s++ ) {
-- if (!isdigit(*s)) {
-- isValidNumber = False;
-- break;
-- }
-- }
--
-- /* .. and the do a range check... */
-- i = atoi(string);
-- if (i < 1 || i > 999) {
-- isValidNumber = False;
-- }
--
-- if (!isValidNumber) {
-- do_beep(pdw);
-- XtVaSetValues(pdp->setup.jobcopies, XtNstring, "1", NULL);
-- Log(("## printSetupJobCopiesXtProc: not a valid number\n"));
-- }
-- }
--}
--
--static void
--printCancelXtProc(Widget w, XtPointer client_data, XtPointer callData)
--{
-- PrintDialogWidget pdw = (PrintDialogWidget)client_data;
-- PrintDialogPart *pdp = &pdw->printdialog;
--
-- printSetupClose(pdw);
--
-- if (pdp->cancel_callback) {
-- Log(("printCancelXtProc: calling callback\n"));
-- XtCallCallbackList((Widget)pdw, pdp->cancel_callback, NULL);
-- }
--}
--
--static void
--printDialogDestXtProc(Widget w, XtPointer client_data, XtPointer callData)
--{
-- PrintDialogWidget pdw = (PrintDialogWidget)client_data;
-- PrintDialogPart *pdp = &pdw->printdialog;
--
-- if (w == pdp->main.printtoprinter) {
-- pdp->printToFile = False;
-- }
-- else if (w == pdp->main.printtofile) {
-- pdp->printToFile = True;
-- }
-- else
-- {
-- Log(("printDialogDestXtProc: ERROR: Unknown widget.\n"));
-- }
--
-- updateWidgetStates(pdw);
--}
--
--static void
--printSelectFileXtProc(Widget w, XtPointer client_data, XtPointer callData)
--{
-- PrintDialogWidget pdw = (PrintDialogWidget)client_data;
-- PrintDialogPart *pdp = &pdw->printdialog;
--
-- Log(("## printSelectFileXtProc!\n"));
--
-- if (!pdp->selectFile.shell) {
-- buildFileDialog(pdw);
-- }
--
-- center_popup((Widget)pdw, pdp->selectFile.shell);
--
-- XtPopup(pdp->selectFile.shell, XtGrabExclusive);
--}
--
--static void
--printOKXtProc(Widget w, XtPointer client_data, XtPointer callData)
--{
-- PrintDialogWidget pdw = (PrintDialogWidget)client_data;
-- PrintDialogPart *pdp = &pdw->printdialog;
-- Log(("## printing!\n"));
--
-- if (!pdp->pdpy) {
-- Log(("printOKXtProc: no printer connection, opening one....\n"));
-- openPrinterConnection(pdw);
--
-- if (!pdp->pdpy) {
-- Log(("printOKXtProc: still no printer connection - BAD (this
should never happen).\n"));
-- do_beep(pdw);
-- return;
-- }
-- }
--
-- if (pdp->ok_callback) {
-- XawPrintDialogCallbackStruct pdcs;
--
-- Log(("printOKXtProc: calling callbacks...\n"));
-- memset(&pdcs, 0, sizeof(pdcs));
-- pdcs.pdpy = pdp->pdpy;
-- pdcs.pcontext = pdp->pcontext;
-- pdcs.printToFile = pdp->printToFile;
-- pdcs.printToFileName = (const char *)pdp->filename;
-- pdcs.colorspace = pdp->selected_colorspace;
-- XtCallCallbackList((Widget)pdw, pdp->ok_callback, &pdcs);
-- }
--
-- printSetupClose(pdw);
--}
--
--static void
--printSetupXtProc(Widget w, XtPointer client_data, XtPointer callData)
--{
-- PrintDialogWidget pdw = (PrintDialogWidget)client_data;
-- PrintDialogPart *pdp = &pdw->printdialog;
--
-- Log(("## setup!\n"));
--
-- if (!pdp->setup.popup) {
-- if (buildPrintSetupDialog(pdw) == NULL) {
-- Log(("printSetupXtProc: buildPrintSetupDialog failure.\n"));
-- return;
-- }
-- }
--
-- center_popup((Widget)pdw, pdp->setup.popup);
--
-- XtPopup(pdp->setup.popup, XtGrabExclusive);
--}
--
--static void
--printFileSelectedXtProc(Widget w, XtPointer client_data, XtPointer callData)
--{
-- PrintDialogWidget pdw = (PrintDialogWidget)client_data;
-- PrintDialogPart *pdp = &pdw->printdialog;
-- const char *filename;
--
-- Log(("printFileSelectedXtProc: User selected file.\n"));
-- filename = XawDialogGetValueString(pdp->selectFile.dialog);
--
-- if (pdp->filename)
-- free(pdp->filename);
-- pdp->filename = strdup(filename);
--
-- XtPopdown(pdp->selectFile.shell);
--
-- updateWidgetStates(pdw);
--}
--
--static
--void buildFileDialog(PrintDialogWidget pdw)
--{
-- PrintDialogPart *pdp = &pdw->printdialog;
-- int n;
-- Arg args[20];
--
-- pdp->selectFile.shell = XtCreatePopupShell("selectfile",
-- transientShellWidgetClass,
-- (Widget)pdw, NULL, 0);
-- n = 0;
-- XtSetArg(args[n], XtNvalue, pdp->filename?pdp->filename:""); n++;
-- pdp->selectFile.dialog = XtCreateManagedWidget("dialog",
dialogWidgetClass,
-- pdp->selectFile.shell,
args, n);
-- XawDialogAddButton(pdp->selectFile.dialog, "Accept",
printFileSelectedXtProc, pdw);
--
-- XtRealizeWidget(pdp->selectFile.shell);
--}
--
--static
--void closePrinterConnection(PrintDialogWidget pdw, Bool closeDisplay)
--{
-- PrintDialogPart *pdp = &pdw->printdialog;
--
-- Log(("# closePrinterConnection\n"));
--
-- destroyPrintSetupDialog(pdw);
--
-- if (pdp->paperlist) {
-- XpuFreeMediumSourceSizeList(pdp->paperlist);
-- pdp->paperlist = NULL;
-- }
--
-- if (pdp->widget_paperlist) {
-- free(pdp->widget_paperlist);
-- pdp->widget_paperlist = NULL;
-- }
--
-- if (pdp->resolutionlist) {
-- XpuFreeResolutionList(pdp->resolutionlist);
-- pdp->resolutionlist = NULL;
-- }
--
-- if (pdp->widget_resolutionlist) {
-- free(pdp->widget_resolutionlist);
-- pdp->widget_resolutionlist = NULL;
-- }
--
--
-- if (pdp->orientationlist) {
-- XpuFreeOrientationList(pdp->orientationlist);
-- pdp->orientationlist = NULL;
-- }
--
-- if (pdp->widget_orientationlist) {
-- free(pdp->widget_orientationlist);
-- pdp->widget_orientationlist = NULL;
-- }
--
-- if (pdp->plexlist) {
-- XpuFreePlexList(pdp->plexlist);
-- pdp->plexlist = NULL;
-- }
--
-- if (pdp->widget_plexlist) {
-- free(pdp->widget_plexlist);
-- pdp->widget_plexlist = NULL;
-- }
--
-- if (pdp->colorspacelist) {
-- XpuFreeColorspaceList(pdp->colorspacelist);
-- pdp->colorspacelist = NULL;
-- }
--
-- if (pdp->widget_colorspacelist) {
-- free(pdp->widget_colorspacelist);
-- pdp->widget_colorspacelist = NULL;
-- }
-- pdp->selected_colorspace = NULL;
--
-- if (pdp->pdpy) {
-- if (closeDisplay) {
-- XpuClosePrinterDisplay(pdp->pdpy, pdp->pcontext);
-- }
-- pdp->pdpy = NULL;
-- pdp->pcontext = None;
-- }
--
-- updateWidgetStates(pdw);
--}
--
--static
--Bool openPrinterConnection(PrintDialogWidget pdw)
--{
-- PrintDialogPart *pdp = &pdw->printdialog;
--
-- Log(("# openPrinterConnection\n"));
--
-- /* Close any outstanding connection first... */
-- closePrinterConnection(pdw, True);
--
-- if (!pdp->printer_name) {
-- Log(("# error: openPrinterConnection: No printer name.\n"));
-- return False;
-- }
--
-- if (XpuGetPrinter(pdp->printer_name, &pdp->pdpy, &pdp->pcontext) ==
False) {
-- Log(("openPrinterConnection: could not open printer.\n"));
-- return False;
-- }
--
-- pdp->paperlist = XpuGetMediumSourceSizeList(pdp->pdpy,
pdp->pcontext, &pdp->num_papers);
-- pdp->resolutionlist = XpuGetResolutionList(pdp->pdpy,
pdp->pcontext, &pdp->num_resolutions);
-- pdp->orientationlist = XpuGetOrientationList(pdp->pdpy,
pdp->pcontext, &pdp->num_orientations);
-- pdp->plexlist = XpuGetPlexList(pdp->pdpy,
pdp->pcontext, &pdp->num_plex);
-- pdp->colorspacelist = XpuGetColorspaceList(pdp->pdpy,
pdp->pcontext, &pdp->num_colorspaces);
--
-- pdp->widget_paperlist =
xppaperlist_to_widget_paperlist(pdp->paperlist, pdp->num_papers);
-- pdp->widget_resolutionlist =
xpresolutionlist_to_widget_resolutionlist(pdp->resolutionlist,
pdp->num_resolutions);
-- pdp->widget_orientationlist =
xporientationlist_to_widget_orientationlist(pdp->orientationlist,
pdp->num_orientations);
-- pdp->widget_plexlist =
xpplexlist_to_widget_plexlist(pdp->plexlist, pdp->num_plex);
-- pdp->widget_colorspacelist =
xpcolorspacelist_to_widget_colorspacelist(pdp->colorspacelist,
pdp->num_colorspaces);
--
-- updateWidgetStates(pdw);
--
-- return True;
--}
--
--#undef DEFAULT_WIDTH
--#define DEFAULT_WIDTH 120
--#undef DEFAULT_INFOLABEL_WIDTH
--#define DEFAULT_INFOLABEL_WIDTH 250
--
--static
--void destroyPrintSetupDialog(PrintDialogWidget pdw)
--{
-- PrintDialogPart *pdp = &pdw->printdialog;
--
-- if (pdp->setup.popup) {
-- XtDestroyWidget(pdp->setup.popup);
-- }
--
-- /* |XtDestroyWidget(pdp->setup.popup);| above will recursively destroy
-- * all children so we only have to reset the pointers here... */
-- pdp->setup.popup = NULL;
-- pdp->setup.form = NULL;
-- pdp->setup.paperlist = NULL;
-- pdp->setup.resolutionlist = NULL;
-- pdp->setup.orientationlist = NULL;
-- pdp->setup.plexlist = NULL;
-- pdp->setup.colorspacelist = NULL;
-- pdp->setup.ok = NULL;
-- pdp->setup.cancel = NULL;
--}
--
--static
--Widget buildPrintSetupDialog(PrintDialogWidget pdw)
--{
-- PrintDialogPart *pdp = &pdw->printdialog;
-- int n;
-- Arg args[20];
-- Widget listform;
-- XpuSupportedFlags jobflags,
-- docflags;
-- Bool canChangeJobCopies,
-- canChangePaperSize,
-- canChangeResolution,
-- canChangeOrientation,
-- canChangePlex;
--
-- if (!pdp->pdpy) {
-- Log(("buildPrintSetupDialog: no printer connection, opening
one....\n"));
-- openPrinterConnection(pdw);
--
-- if (!pdp->pdpy) {
-- Log(("buildPrintSetupDialog: still no printer connection -
BAD.\n"));
-- do_beep(pdw);
-- return NULL;
-- }
-- }
--
-- /* Get flags which types of attributes can be modified */
-- jobflags = XpuGetSupportedDocAttributes(pdp->pdpy, pdp->pcontext);
-- docflags = XpuGetSupportedDocAttributes(pdp->pdpy, pdp->pcontext);
-- canChangeJobCopies = (jobflags & XPUATTRIBUTESUPPORTED_COPY_COUNT) ==
XPUATTRIBUTESUPPORTED_COPY_COUNT;
-- canChangePaperSize = (docflags &
XPUATTRIBUTESUPPORTED_DEFAULT_MEDIUM) == XPUATTRIBUTESUPPORTED_DEFAULT_MEDIUM;
-- canChangeResolution = (docflags &
XPUATTRIBUTESUPPORTED_DEFAULT_PRINTER_RESOLUTION) ==
XPUATTRIBUTESUPPORTED_DEFAULT_PRINTER_RESOLUTION;
-- canChangeOrientation = (docflags &
XPUATTRIBUTESUPPORTED_CONTENT_ORIENTATION) ==
XPUATTRIBUTESUPPORTED_CONTENT_ORIENTATION;
-- canChangePlex = (docflags & XPUATTRIBUTESUPPORTED_PLEX) ==
XPUATTRIBUTESUPPORTED_PLEX;
--
-- n = 0;
-- XtSetArg(args[n], XtNallowShellResize, True); n++;
-- pdp->setup.popup = XtCreatePopupShell("setup",
transientShellWidgetClass, (Widget)pdw, args, n);
--
-- n = 0;
-- pdp->setup.form = XtCreateManagedWidget("form", formWidgetClass,
pdp->setup.popup, args, n);
--
-- n = 0;
-- listform = XtCreateManagedWidget("list", formWidgetClass,
pdp->setup.form, args, n);
--
-- n = 0;
-- XtSetArg(args[n], XtNresizable, True);
n++;
-- XtSetArg(args[n], XtNforceColumns, True);
n++;
-- XtSetArg(args[n], XtNdefaultColumns, 1);
n++;
-- XtSetArg(args[n], XtNsensitive, canChangePaperSize);
n++;
-- XtSetArg(args[n], XtNlist, pdp->widget_paperlist);
n++;
-- XtSetArg(args[n], XtNwidth, DEFAULT_WIDTH);
n++;
-- pdp->setup.paperlist = XtCreateManagedWidget("paperlist",
listWidgetClass, listform, args, n);
--
-- n = 0;
-- XtSetArg(args[n], XtNresizable, True);
n++;
-- XtSetArg(args[n], XtNforceColumns, True);
n++;
-- XtSetArg(args[n], XtNdefaultColumns, 1);
n++;
-- XtSetArg(args[n], XtNsensitive, canChangeResolution);
n++;
-- XtSetArg(args[n], XtNlist, pdp->widget_resolutionlist);
n++;
-- XtSetArg(args[n], XtNwidth, DEFAULT_WIDTH);
n++;
-- pdp->setup.resolutionlist = XtCreateManagedWidget("resolutionlist",
listWidgetClass, listform, args, n);
--
-- n = 0;
-- XtSetArg(args[n], XtNresizable, True);
n++;
-- XtSetArg(args[n], XtNforceColumns, True);
n++;
-- XtSetArg(args[n], XtNdefaultColumns, 1);
n++;
-- XtSetArg(args[n], XtNsensitive, canChangeOrientation);
n++;
-- XtSetArg(args[n], XtNlist, pdp->widget_orientationlist);
n++;
-- XtSetArg(args[n], XtNwidth, DEFAULT_WIDTH);
n++;
-- pdp->setup.orientationlist = XtCreateManagedWidget("orientationlist",
listWidgetClass, listform, args, n);
--
-- n = 0;
-- XtSetArg(args[n], XtNresizable, True);
n++;
-- XtSetArg(args[n], XtNforceColumns, True);
n++;
-- XtSetArg(args[n], XtNdefaultColumns, 1);
n++;
-- XtSetArg(args[n], XtNsensitive, canChangePlex);
n++;
-- XtSetArg(args[n], XtNlist, pdp->widget_plexlist);
n++;
-- XtSetArg(args[n], XtNwidth, DEFAULT_WIDTH);
n++;
-- pdp->setup.plexlist = XtCreateManagedWidget("plexlist",
listWidgetClass, listform, args, n);
--
-- n = 0;
-- XtSetArg(args[n], XtNresizable, True);
n++;
-- XtSetArg(args[n], XtNforceColumns, True);
n++;
-- XtSetArg(args[n], XtNdefaultColumns, 1);
n++;
-- XtSetArg(args[n], XtNsensitive, True);
n++;
-- XtSetArg(args[n], XtNlist, pdp->widget_colorspacelist);
n++;
-- XtSetArg(args[n], XtNwidth, DEFAULT_WIDTH);
n++;
-- pdp->setup.colorspacelist = XtCreateManagedWidget("colorspacelist",
listWidgetClass, listform, args, n);
--
-- n = 0;
-- XtSetArg(args[n], XtNborderWidth, 0);
n++;
-- XtSetArg(args[n], XtNresizable, False);
n++;
-- XtSetArg(args[n], XtNjustify, XtJustifyRight);
n++;
-- XtSetArg(args[n], XtNwidth, DEFAULT_WIDTH);
n++;
-- XtSetArg(args[n], XtNsensitive, canChangeJobCopies);
n++;
-- pdp->setup.jobcopieslabel = XtCreateManagedWidget("jobcopieslabel",
labelWidgetClass, listform, args, n);
--
-- n = 0;
-- XtSetArg(args[n], XtNstring, "1");
n++;
-- XtSetArg(args[n], XtNresizable, True);
n++;
-- XtSetArg(args[n], XtNeditType, XawtextEdit);
n++;
-- XtSetArg(args[n], XtNsensitive, canChangeJobCopies);
n++;
-- pdp->setup.jobcopies = XtCreateManagedWidget("jobcopies",
asciiTextWidgetClass, listform, args, n);
-- XtAddCallback(pdp->setup.jobcopies, XtNpositionCallback,
printSetupJobCopiesXtProc, pdw);
--
-- n = 0;
-- pdp->setup.ok = XtCreateManagedWidget("ok", commandWidgetClass,
pdp->setup.form, args, n);
-- XtAddCallback(pdp->setup.ok, XtNcallback, printSetupOKXtProc, pdw);
--
-- n = 0;
-- pdp->setup.cancel = XtCreateManagedWidget("cancel", commandWidgetClass,
pdp->setup.form, args, n);
-- XtAddCallback(pdp->setup.cancel, XtNcallback, printSetupCancelXtProc,
pdw);
--
-- XtRealizeWidget(pdp->setup.popup);
--
-- return pdp->setup.popup;
--}
--
--#undef DEFAULT_WIDTH
--#define DEFAULT_WIDTH 150
--
--static
--String *xpprinterlist_to_widget_printerlist(XPPrinterList printerlist, int
num_printers)
--{
-- int i;
-- String *names;
--
-- names = malloc(sizeof(String *) * (num_printers+1));
-- if(!names)
-- return NULL;
--
-- for(i = 0 ; i < num_printers ; i++)
-- names[i] = printerlist[i].name;
--
-- names[i] = NULL; /* Terminate the list */
--
-- return names;
--}
--
--static
--String *xppaperlist_to_widget_paperlist(XpuMediumSourceSizeList paperlist,
int num_papers)
--{
-- int i;
-- String *names;
--
-- names = malloc(sizeof(String *) * (num_papers+1));
-- if (!names)
-- return NULL;
--
-- for(i = 0 ; i < num_papers ; i++)
-- names[i] = (char *)paperlist[i].medium_name; /* FixMe: tray
selection missing */
--
-- names[i] = NULL; /* Terminate the list */
--
-- return names;
--}
--
--static
--String *xpresolutionlist_to_widget_resolutionlist(XpuResolutionList
reslist, int num_resolutions)
--{
-- int i;
-- String *names;
--
-- names = malloc(sizeof(String *) * (num_resolutions+1));
-- if (!names)
-- return NULL;
--
-- for(i = 0 ; i < num_resolutions ; i++)
-- names[i] = (char *)reslist[i].name;
--
-- names[i] = NULL; /* Terminate the list */
--
-- return names;
--}
--
--static
--String *xporientationlist_to_widget_orientationlist(XpuOrientationList
orientationlist, int num_orientations)
--{
-- int i;
-- String *names;
--
-- names = malloc(sizeof(String *) * (num_orientations+1));
-- if (!names)
-- return NULL;
--
-- for(i = 0 ; i < num_orientations ; i++)
-- names[i] = (char *)orientationlist[i].orientation;
--
-- names[i] = NULL; /* Terminate the list */
--
-- return names;
--}
--
--static
--String *xpplexlist_to_widget_plexlist(XpuPlexList plexlist, int num_plex)
--{
-- int i;
-- String *names;
--
-- names = malloc(sizeof(String *) * (num_plex+1));
-- if(!names)
-- return NULL;
--
-- for(i = 0 ; i < num_plex ; i++)
-- names[i] = (char *)plexlist[i].plex;
--
-- names[i] = NULL; /* Terminate the list */
--
-- return names;
--}
--
--static
--String *xpcolorspacelist_to_widget_colorspacelist(XpuColorspaceList
colorspacelist, int num_colorspaces)
--{
-- int i;
-- String *names;
--
-- names = malloc(sizeof(String *) * (num_colorspaces+1));
-- if(!names)
-- return NULL;
--
-- for(i = 0 ; i < num_colorspaces ; i++)
-- names[i] = (char *)colorspacelist[i].name;
--
-- names[i] = NULL; /* Terminate the list */
--
-- return names;
--}
--
--static void
--printerSelectionPrinterSelectedXtProc(Widget w, XtPointer client_data,
XtPointer callData)
--{
-- PrintDialogWidget pdw = (PrintDialogWidget)client_data;
-- PrintDialogPart *pdp = &pdw->printdialog;
-- XawListReturnStruct *lrs = (XawListReturnStruct *)callData;
-- int list_index;
--
-- Log(("## user selected a printer\n"));
--
-- list_index = lrs->list_index;
-- if (list_index == XAW_LIST_NONE) {
-- Log(("printerSelectionPrinterSelectedXtProc: Nothing selected.\n"));
-- return;
-- }
--
-- Log(("selected printer is '%d'/'%s'/'%s'\n",
-- list_index, lrs->string,
NULLSTR(pdp->printerlist[list_index].name)));
--
-- /* Enable OK button */
-- XtVaSetValues(pdp->selectPrinter.ok, XtNsensitive, True, NULL);
--}
--
--static void
--printSelectPrinterXtProc(Widget w, XtPointer client_data, XtPointer
callData)
--{
-- PrintDialogWidget pdw = (PrintDialogWidget)client_data;
-- PrintDialogPart *pdp = &pdw->printdialog;
--
-- Log(("## select printer!\n"));
--
-- if (!pdp->selectPrinter.popup) {
-- if (!buildPrinterSelectionDialog(pdw)) {
-- Log(("printSelectPrinterXtProc: buildPrinterSelectionDialog
failure.\n"));
-- return;
-- }
-- }
--
-- center_popup((Widget)pdw, pdp->selectPrinter.popup);
--
-- XtPopup(pdp->selectPrinter.popup, XtGrabExclusive);
--}
--
--static void
--printerSelectionClose(PrintDialogWidget pdw)
--{
-- PrintDialogPart *pdp = &pdw->printdialog;
--
-- if (pdp->selectPrinter.popup) {
-- XtPopdown(pdp->selectPrinter.popup);
-- }
--}
--
--static void
--printerSelectionOKXtProc(Widget w, XtPointer client_data, XtPointer
callData)
--{
-- PrintDialogWidget pdw = (PrintDialogWidget)client_data;
-- PrintDialogPart *pdp = &pdw->printdialog;
-- XawListReturnStruct *lrs;
-- int list_index;
--
-- Log(("## printerSelectionOKXtProc: closing printer selection!\n"));
--
-- /* Copy current selection in printer list widget and open a printer
connection */
-- lrs = XawListShowCurrent(pdp->selectPrinter.list);
-- if (!lrs) {
-- Log(("printerSelectionOKXtProc: |lrs|==NULL\n"));
-- return;
-- }
--
-- list_index = lrs->list_index;
-- if (lrs->list_index == XAW_LIST_NONE) {
-- Log(("printerSelectionOKXtProc: rs->list_index ==
XAW_LIST_NONE\n"));
-- XtFree((char *)lrs);
-- return;
-- }
--
-- /* Set printer name and description in main dialog */
-- XtVaSetValues(pdp->main.name, XtNlabel,
NULLSTR(pdp->printerlist[list_index].name), NULL);
-- XtVaSetValues(pdp->main.desc, XtNlabel,
NULLSTR(pdp->printerlist[list_index].desc), NULL);
--
-- if (pdp->printer_name)
-- free(pdp->printer_name);
-- pdp->printer_name = strdup(lrs->string);
--
-- /* Close any outstanding printer connection since user has selected
-- * a different printer */
-- closePrinterConnection(pdw, True);
--
-- printerSelectionClose(pdw);
--
-- XtFree((char *)lrs);
--}
--
--static void
--printerSelectionCancelXtProc(Widget w, XtPointer client_data, XtPointer
callData)
--{
-- PrintDialogWidget pdw = (PrintDialogWidget)client_data;
-- Log(("## printerSelectionCancelXtProc: closing printer selection!\n"));
--
-- printerSelectionClose(pdw);
--}
--
--static
--Bool buildPrinterSelectionDialog(PrintDialogWidget pdw)
--{
-- PrintDialogPart *pdp = &pdw->printdialog;
--
-- int n;
-- Arg args[20];
--
-- n = 0;
-- XtSetArg(args[n], XtNallowShellResize, True); n++;
-- pdp->selectPrinter.popup = XtCreatePopupShell("printerselection",
transientShellWidgetClass, (Widget)pdw, args, n);
--
-- n = 0;
-- pdp->selectPrinter.form = XtCreateManagedWidget("form",
formWidgetClass, pdp->selectPrinter.popup, args, n);
--
-- n = 0;
-- XtSetArg(args[n], XtNresizable, True); n++;
-- XtSetArg(args[n], XtNforceColumns, True); n++;
-- XtSetArg(args[n], XtNdefaultColumns, 1); n++;
-- XtSetArg(args[n], XtNlist, pdp->widget_printerlist); n++;
-- XtSetArg(args[n], XtNwidth, DEFAULT_WIDTH); n++;
-- pdp->selectPrinter.list = XtCreateManagedWidget("list",
listWidgetClass, pdp->selectPrinter.form, args, n);
-- XtAddCallback(pdp->selectPrinter.list, XtNcallback,
printerSelectionPrinterSelectedXtProc, pdw);
--
-- n = 0;
-- XtSetArg(args[n], XtNsensitive, False); n++;
-- pdp->selectPrinter.ok = XtCreateManagedWidget("ok", commandWidgetClass,
pdp->selectPrinter.form, args, n);
-- XtAddCallback(pdp->selectPrinter.ok, XtNcallback,
printerSelectionOKXtProc, pdw);
--
-- n = 0;
-- pdp->selectPrinter.cancel = XtCreateManagedWidget("cancel",
commandWidgetClass, pdp->selectPrinter.form, args, n);
-- XtAddCallback(pdp->selectPrinter.cancel, XtNcallback,
printerSelectionCancelXtProc, pdw);
--
-- XtRealizeWidget(pdp->selectPrinter.popup);
--
-- return True;
--}
--
--static
--void destroyPrinterSelectionDialog(PrintDialogWidget pdw)
--{
-- PrintDialogPart *pdp = &pdw->printdialog;
--
-- if (pdp->selectPrinter.popup) {
-- XtDestroyWidget(pdp->selectPrinter.popup);
-- }
--
-- /* |XtDestroyWidget(pdp->setup.popup);| above will recursively destroy
-- * all children so we only have to reset the pointers here... */
-- pdp->selectPrinter.popup = NULL;
-- pdp->selectPrinter.form = NULL;
-- pdp->selectPrinter.list = NULL;
-- pdp->selectPrinter.popup = NULL;
-- pdp->selectPrinter.cancel = NULL;
--}
--
--/*
-- * Function:
-- * createprintdialogchildren
-- *
-- * Parameters:
-- * w - print dialog widget
-- *
-- * Description:
-- * Creates the print dialog widgets.
-- *
-- * Note
-- * -
-- */
--static void
--createprintdialogchildren(Widget w)
--{
-- int n;
-- Arg args[20];
-- PrintDialogWidget pdw = (PrintDialogWidget)w;
-- PrintDialogPart *pdp = &pdw->printdialog;
-- const char *default_printername = NULL,
-- *default_printerdesc = NULL;
-- Bool has_default_printer = False;
--
-- pdp->printerlist = XpuGetPrinterList(NULL, &pdp->num_printers);
-- pdp->widget_printerlist =
xpprinterlist_to_widget_printerlist(pdp->printerlist, pdp->num_printers);
--
-- if (pdp->num_printers > 0) {
-- if (pdp->printerlist[0].name && strlen(pdp->printerlist[0].name)) {
-- /* XprintUtils moves the default printer to the top */
-- default_printername = pdp->printerlist[0].name;
-- default_printerdesc = pdp->printerlist[0].desc;
-- pdp->printer_name = strdup(pdp->printerlist[0].name);
-- has_default_printer = True;
-- }
-- }
-- else
-- {
-- PrintMsg(("No Xprint servers could be found.\n"
-- "Check whether the XPSERVERLIST environment variable
contains any valid Xprint server(s).\n"));
-- }
--
-- n = 0;
-- XtSetArg(args[n], XtNborderWidth, 0); n++;
-- pdp->main.form = XtCreateManagedWidget("main", formWidgetClass,
(Widget)pdw, args, n);
--
-- n = 0;
-- pdp->main.innerform = XtCreateManagedWidget("innerform",
formWidgetClass, pdp->main.form, args, n);
--
-- n = 0;
-- XtSetArg(args[n], XtNborderWidth, 0); n++;
-- XtSetArg(args[n], XtNresizable, False); n++;
-- XtSetArg(args[n], XtNjustify, XtJustifyRight); n++;
-- XtSetArg(args[n], XtNwidth, DEFAULT_WIDTH); n++;
-- pdp->main.desclabel = XtCreateManagedWidget("desclabel",
labelWidgetClass, pdp->main.innerform, args, n);
--
-- n = 0;
-- XtSetArg(args[n], XtNborderWidth, 0); n++;
-- XtSetArg(args[n], XtNresizable, False); n++;
-- XtSetArg(args[n], XtNjustify, XtJustifyLeft); n++;
-- XtSetArg(args[n], XtNwidth, DEFAULT_INFOLABEL_WIDTH); n++;
-- XtSetArg(args[n], XtNlabel,
default_printerdesc?default_printerdesc:"-"); n++;
-- pdp->main.desc = XtCreateManagedWidget("desc", labelWidgetClass,
pdp->main.innerform, args, n);
--
-- n = 0;
-- XtSetArg(args[n], XtNsensitive, has_default_printer); n++;
-- pdp->main.info = XtCreateManagedWidget("info", commandWidgetClass,
pdp->main.innerform, args, n);
-- /*
-- XtAddCallback(pdp->main.info, XtNcallback, printerInfoXtProc, pdw);
-- */
-- n = 0;
-- XtSetArg(args[n], XtNborderWidth, 0); n++;
-- XtSetArg(args[n], XtNresizable, False); n++;
-- XtSetArg(args[n], XtNjustify, XtJustifyRight); n++;
-- XtSetArg(args[n], XtNwidth, DEFAULT_WIDTH); n++;
-- pdp->main.namelabel = XtCreateManagedWidget("namelabel",
labelWidgetClass, pdp->main.innerform, args, n);
--
-- n = 0;
-- XtSetArg(args[n], XtNborderWidth, 0); n++;
-- XtSetArg(args[n], XtNresizable, False); n++;
-- XtSetArg(args[n], XtNjustify, XtJustifyLeft); n++;
-- XtSetArg(args[n], XtNlabel,
default_printername?default_printername:"-"); n++;
-- XtSetArg(args[n], XtNwidth, DEFAULT_INFOLABEL_WIDTH); n++;
-- pdp->main.name = XtCreateManagedWidget("name", labelWidgetClass,
pdp->main.innerform, args, n);
--
-- n = 0;
-- pdp->main.selectprinter = XtCreateManagedWidget("selectprinter",
commandWidgetClass, pdp->main.innerform, args, n);
-- XtAddCallback(pdp->main.selectprinter, XtNcallback,
printSelectPrinterXtProc, pdw);
--
-- /* Line: "File selection" */
--
-- n = 0;
-- XtSetArg(args[n], XtNborderWidth, 0); n++;
-- XtSetArg(args[n], XtNresizable, False); n++;
-- XtSetArg(args[n], XtNjustify, XtJustifyRight); n++;
-- XtSetArg(args[n], XtNwidth, DEFAULT_WIDTH); n++;
-- XtSetArg(args[n], XtNsensitive, False); n++;
-- pdp->main.filenamelabel = XtCreateManagedWidget("filenamelabel",
labelWidgetClass, pdp->main.innerform, args, n);
--
-- n = 0;
-- XtSetArg(args[n], XtNborderWidth, 0); n++;
-- XtSetArg(args[n], XtNresizable, False); n++;
-- XtSetArg(args[n], XtNjustify, XtJustifyLeft); n++;
-- XtSetArg(args[n], XtNlabel, "-"); n++;
-- XtSetArg(args[n], XtNwidth, DEFAULT_INFOLABEL_WIDTH); n++;
-- XtSetArg(args[n], XtNsensitive, False); n++;
-- pdp->main.filename = XtCreateManagedWidget("filename",
labelWidgetClass, pdp->main.innerform, args, n);
--
-- n = 0;
-- XtSetArg(args[n], XtNsensitive, False); n++;
-- pdp->main.selectfile = XtCreateManagedWidget("selectfile",
commandWidgetClass, pdp->main.innerform, args, n);
-- XtAddCallback(pdp->main.selectfile, XtNcallback, printSelectFileXtProc,
pdw);
--
-- /* Line: Misc (Print destination toggles, copy-count etc.)*/
-- n = 0;
-- XtSetArg(args[n], XtNstate, True); n++;
-- pdp->main.printtoprinter = XtCreateManagedWidget("printtoprinter",
toggleWidgetClass, pdp->main.innerform, args, n);
-- XtAddCallback(pdp->main.printtoprinter, XtNcallback,
printDialogDestXtProc, pdw);
--
-- n = 0;
-- XtSetArg(args[n], XtNstate, False); n++;
-- pdp->main.printtofile = XtCreateManagedWidget("printtofile",
toggleWidgetClass, pdp->main.innerform, args, n);
-- XtAddCallback(pdp->main.printtofile, XtNcallback,
printDialogDestXtProc, pdw);
--
-- /* End-of-Inner-Form-Content */
--
-- n = 0;
-- XtSetArg(args[n], XtNsensitive, has_default_printer); n++;
-- pdp->main.ok = XtCreateManagedWidget("ok", commandWidgetClass,
pdp->main.form, args, n);
-- XtAddCallback(pdp->main.ok, XtNcallback, printOKXtProc, pdw);
--
-- n = 0;
-- XtSetArg(args[n], XtNsensitive, has_default_printer); n++;
-- pdp->main.setup = XtCreateManagedWidget("setup", commandWidgetClass,
pdp->main.form, args, n);
-- XtAddCallback(pdp->main.setup, XtNcallback, printSetupXtProc, pdw);
--
-- n = 0;
-- pdp->main.cancel = XtCreateManagedWidget("cancel", commandWidgetClass,
pdp->main.form, args, n);
-- XtAddCallback(pdp->main.cancel, XtNcallback, printCancelXtProc, pdw);
--}
--
--/*
-- * Class Methods
-- */
--static void XawPrintDialogConstraintInitialize(Widget, Widget, ArgList,
Cardinal *);
--static void XawPrintDialogGetValuesHook(Widget, ArgList, Cardinal*);
--static void XawPrintDialogInitialize(Widget, Widget, ArgList, Cardinal*);
--static void XawPrintDialogDestroy(Widget);
--static Boolean XawPrintDialogSetValues(Widget, Widget, Widget, ArgList,
Cardinal *);
--
--/*
-- * Initialization
-- */
--static XtResource resources[] = {
-- {
-- XtNicon,
-- XtCIcon,
-- XtRBitmap,
-- sizeof(Pixmap),
-- XtOffsetOf(PrintDialogRec, printdialog.icon),
-- XtRImmediate,
-- 0
-- },
-- {
-- XawNOkCallback, XtCCallback, XtRCallback,
-- sizeof(XtCallbackList), XtOffsetOf(PrintDialogRec,
printdialog.ok_callback),
-- XtRImmediate, (XtPointer)NULL
-- },
-- {
-- XawNCancelCallback, XtCCallback, XtRCallback,
-- sizeof(XtCallbackList), XtOffsetOf(PrintDialogRec,
printdialog.cancel_callback),
-- XtRImmediate, (XtPointer)NULL
-- },
--};
--
--PrintDialogClassRec printdialogClassRec = {
-- /* core */
-- {
-- (WidgetClass)&formClassRec, /* superclass */
-- "PrintDialog", /* class_name */
-- sizeof(PrintDialogRec), /* widget_size */
-- XawInitializeWidgetSet, /* class_initialize */
-- NULL, /* class_part init */
-- False, /* class_inited */
-- XawPrintDialogInitialize, /* initialize */
-- NULL, /* initialize_hook */
-- XtInheritRealize, /* realize */
-- NULL, /* actions */
-- 0, /* num_actions */
-- resources, /* resources */
-- XtNumber(resources), /* num_resources */
-- NULLQUARK, /* xrm_class */
-- True, /* compress_motion */
-- True, /* compress_exposure */
-- True, /* compress_enterleave */
-- False, /* visible_interest */
-- XawPrintDialogDestroy, /* destroy */
-- XtInheritResize, /* resize */
-- XtInheritExpose, /* expose */
-- XawPrintDialogSetValues, /* set_values */
-- NULL, /* set_values_hook */
-- XtInheritSetValuesAlmost, /* set_values_almost */
-- XawPrintDialogGetValuesHook, /* get_values_hook */
-- NULL, /* accept_focus */
-- XtVersion, /* version */
-- NULL, /* callback_private */
-- NULL, /* tm_table */
-- XtInheritQueryGeometry, /* query_geometry */
-- XtInheritDisplayAccelerator, /* display_accelerator */
-- NULL, /* extension */
-- },
-- /* composite */
-- {
-- XtInheritGeometryManager, /* geometry_manager */
-- XtInheritChangeManaged, /* change_managed */
-- XtInheritInsertChild, /* insert_child */
-- XtInheritDeleteChild, /* delete_child */
-- NULL, /* extension */
-- },
-- /* constraint */
-- {
-- NULL, /* subresourses */
-- 0, /* subresource_count */
-- sizeof(PrintDialogConstraintsRec), /* constraint_size */
-- XawPrintDialogConstraintInitialize, /* initialize */
-- NULL, /* destroy */
-- NULL, /* set_values */
-- NULL, /* extension */
-- },
-- /* form */
-- {
-- XtInheritLayout, /* layout */
-- },
-- /* printdialog */
-- {
-- NULL, /* extension */
-- }
--};
--
--WidgetClass printDialogWidgetClass = (WidgetClass)&printdialogClassRec;
--
--/*
-- * Implementation
-- */
--/*ARGSUSED*/
--static void
--XawPrintDialogInitialize(Widget request, Widget cnew, ArgList args,
Cardinal *num_args)
--{
-- PrintDialogWidget dw = (PrintDialogWidget)cnew;
-- Arg arglist[9];
-- Cardinal arg_cnt = 0;
--
-- XtSetArg(arglist[arg_cnt], XtNborderWidth, 0); arg_cnt++;
-- XtSetArg(arglist[arg_cnt], XtNleft, XtChainLeft); arg_cnt++;
--
-- if (dw->printdialog.icon != (Pixmap)0) {
-- XtSetArg(arglist[arg_cnt], XtNbitmap, dw->printdialog.icon);
arg_cnt++;
-- XtSetArg(arglist[arg_cnt], XtNright, XtChainLeft);
arg_cnt++;
-- dw->printdialog.iconW = XtCreateManagedWidget("icon",
labelWidgetClass,
-- cnew, arglist,
arg_cnt);
-- arg_cnt = 2;
-- XtSetArg(arglist[arg_cnt], XtNfromHoriz, dw->printdialog.iconW);
arg_cnt++;
-- }
-- else {
-- dw->printdialog.iconW = NULL;
-- }
--
-- createprintdialogchildren((Widget)dw);
--}
--
--/*ARGSUSED*/
--static void
--XawPrintDialogConstraintInitialize(Widget request, Widget cnew,
-- ArgList args, Cardinal *num_args)
--{
-- PrintDialogWidget dw = (PrintDialogWidget)cnew->core.parent;
-- PrintDialogConstraints constraint =
(PrintDialogConstraints)cnew->core.constraints;
--
-- if (!XtIsSubclass(cnew, commandWidgetClass)) /* if not a button */
-- return; /* then just use defaults
*/
--
-- constraint->form.left = constraint->form.right = XtChainLeft;
-- constraint->form.vert_base = dw->printdialog.main.form;
--
-- if (dw->composite.num_children > 1) {
-- WidgetList children = dw->composite.children;
-- Widget *childP;
--
-- for (childP = children + dw->composite.num_children - 1;
-- childP >= children; childP-- ) {
-- if (*childP == dw->printdialog.main.form)
-- break;
-- if (XtIsManaged(*childP) &&
-- XtIsSubclass(*childP, commandWidgetClass)) {
-- constraint->form.horiz_base = *childP;
-- break;
-- }
-- }
-- }
--}
--
--#define ICON 0
--#define NUM_CHECKS 1
--/*ARGSUSED*/
--static Boolean
--XawPrintDialogSetValues(Widget current, Widget request, Widget cnew,
-- ArgList in_args, Cardinal *in_num_args)
--{
-- PrintDialogWidget w = (PrintDialogWidget)cnew;
-- PrintDialogWidget old = (PrintDialogWidget)current;
-- Arg args[5];
-- unsigned int i;
-- Bool checks[NUM_CHECKS];
--
-- for (i = 0; i < NUM_CHECKS; i++)
-- checks[i] = False;
--
-- for (i = 0; i < *in_num_args; i++) {
-- if (!strcmp(XtNicon, in_args[i].name))
-- checks[ICON] = True;
-- }
--
-- if (checks[ICON]) {
-- if (w->printdialog.icon != 0) {
-- XtSetArg(args[0], XtNbitmap, w->printdialog.icon);
-- if (old->printdialog.iconW != NULL) {
-- XtSetValues(old->printdialog.iconW, args, 1);
-- }
-- else {
-- XtSetArg(args[1], XtNborderWidth, 0);
-- XtSetArg(args[2], XtNleft, XtChainLeft);
-- XtSetArg(args[3], XtNright, XtChainLeft);
-- w->printdialog.iconW = XtCreateWidget("icon",
labelWidgetClass,
-- cnew, args, 4);
-- XtManageChild(w->printdialog.iconW);
-- }
-- }
-- else if (old->printdialog.icon != 0) {
-- XtDestroyWidget(old->printdialog.iconW);
-- w->printdialog.iconW = NULL;
-- }
-- }
--
-- return True;
--}
--
--/*
-- * Function:
-- * XawPrintDialogGetValuesHook
-- *
-- * Parameters:
-- * w - Print Dialog Widget
-- * args - argument list
-- * num_args - number of args
-- *
-- * Description:
-- * This is a get values hook routine that gets the values in the
dialog.
-- */
--static void
--XawPrintDialogGetValuesHook(Widget w, ArgList args, Cardinal *num_args)
--{
-- /* NO-OP for now */
--}
--
--static void
--XawPrintDialogDestroy(Widget w)
--{
-- PrintDialogWidget pdw = (PrintDialogWidget)w;
-- Log(("# XawPrintDialogDestroy: start.\n"));
--
-- destroyPrintSetupDialog(pdw);
-- destroyPrinterSelectionDialog(pdw);
-- closePrinterConnection(pdw, True);
--
-- Log(("# XawPrintDialogDestroy: done.\n"));
--}
--
--/*
-- * Function:
-- * XawPrintDialogClosePrinterConnection
-- *
-- * Parameters:
-- * w - Print Dialog Widget
-- * closeDisplay - Boolean which decides whether |Display *|
-- * and |XPContext| should be disposed, too.
-- *
-- * Description:
-- * The print display connection is owned by the print dialog
-- * by default.
-- * If the application wishes to close the display connection
-- * to the print server, either to close it itself or force
-- * a disconnection for other reasons this function can be used.
-- *
-- * Notes
-- * 1. PUBLIC API
-- * 2. After this function returns all resources returned by the
-- * print dialog which are related to the status of the printer
-- * connection are stale.
-- */
--void
--XawPrintDialogClosePrinterConnection(Widget w, Bool closeDisplay)
--{
-- closePrinterConnection((PrintDialogWidget)w, closeDisplay);
--}
--
-diff --git a/printdialog.h b/printdialog.h
-deleted file mode 100644
-index f166a27..0000000
---- a/printdialog.h
-+++ b/dev/null
-@@ -1,70 +0,0 @@
--/*
-- * $Xorg: printdialog.h,v 1.1 2004/04/30 02:05:54 gisburn Exp $
-- *
--Copyright 2004 Roland Mainz <roland.mainz AT nrubsig.org>
--
--Permission to use, copy, modify, distribute, and sell this software and its
--documentation for any purpose is hereby granted without fee, provided that
--the above copyright notice appear in all copies and that both that
--copyright notice and this permission notice appear in supporting
--documentation.
--
--The above copyright notice and this permission notice shall be included in
--all copies or substantial portions of the Software.
--
--THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
--IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
--FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
--OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
--AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
--CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
--
--Except as contained in this notice, the name of The Open Group shall not be
--used in advertising or otherwise to promote the sale, use or other dealings
--in this Software without prior written authorization from The Open Group.
-- *
-- */
--
--#ifndef XMORE_PRINTDIALOG_H
--#define XMORE_PRINTDIALOG_H 1
--
--#include <X11/Intrinsic.h>
--#include <X11/StringDefs.h>
--#include <X11/Shell.h>
--#include <X11/Xaw/Print.h>
--#include <X11/Xaw/Cardinals.h>
--#include <X11/Xaw/Form.h>
--#include <X11/XprintUtil/xprintutil.h>
--
--/* Resources:
-- NOT WRITTEN YET
--*/
--
--#define XtCIcon "Icon"
--#define XtNicon "icon"
--
--#define XawNOkCallback "okCallback"
--#define XawNCancelCallback "cancelCallback"
--
--typedef struct
--{
-- Display *pdpy;
-- XPContext pcontext;
-- const char *printToFileName;
-- Boolean printToFile;
-- XpuColorspaceRec *colorspace;
--} XawPrintDialogCallbackStruct;
--
--typedef struct _PrintDialogClassRec *PrintDialogWidgetClass;
--typedef struct _PrintDialogRec *PrintDialogWidget;
--
--extern WidgetClass printDialogWidgetClass;
--
--_XFUNCPROTOBEGIN
--
--/* Prototypes */
--void XawPrintDialogClosePrinterConnection(Widget w, Bool closeDisplay);
--
--_XFUNCPROTOEND
--
--#endif /* !XMORE_PRINTDIALOG_H */
-diff --git a/printdialogprivates.h b/printdialogprivates.h
-deleted file mode 100644
-index 1e66eb8..0000000
---- a/printdialogprivates.h
-+++ b/dev/null
-@@ -1,182 +0,0 @@
--/*
-- * $Xorg: printdialogprivates.h,v 1.1 2004/05/12 02:05:54 gisburn Exp $
-- *
--Copyright 2004 Roland Mainz <roland.mainz AT nrubsig.org>
--
--Permission to use, copy, modify, distribute, and sell this software and its
--documentation for any purpose is hereby granted without fee, provided that
--the above copyright notice appear in all copies and that both that
--copyright notice and this permission notice appear in supporting
--documentation.
--
--The above copyright notice and this permission notice shall be included in
--all copies or substantial portions of the Software.
--
--THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
--IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
--FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
--OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
--AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
--CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
--
--Except as contained in this notice, the name of The Open Group shall not be
--used in advertising or otherwise to promote the sale, use or other dealings
--in this Software without prior written authorization from The Open Group.
-- *
-- */
--
--#ifndef _XawPrintDialogP_h
--#define _XawPrintDialogP_h 1
--
--#include <X11/IntrinsicP.h>
--#include <X11/StringDefs.h>
--#include <X11/Xos.h>
--#include <X11/Xmu/Misc.h>
--#include <X11/CoreP.h>
--#include <X11/Xaw/AsciiText.h>
--#include <X11/Xaw/Cardinals.h>
--#include <X11/Xaw/Command.h>
--#include <X11/Xaw/Label.h>
--#include <X11/Xaw/DialogP.h>
--#include <X11/Xaw/XawInit.h>
--#include <X11/Xaw/Dialog.h>
--#include <X11/Xaw/FormP.h>
--
--/* From Xaw/Privates.h */
--#ifndef XtWidth
--#define XtWidth(w) (((RectObj)w)->rectangle.width)
--#endif
--#ifndef XtHeight
--#define XtHeight(w) (((RectObj)w)->rectangle.height)
--#endif
--
--
--typedef struct {
-- XtPointer extension;
--} PrintDialogClassPart;
--
--typedef struct _PrintDialogClassRec {
-- CoreClassPart core_class;
-- CompositeClassPart composite_class;
-- ConstraintClassPart constraint_class;
-- FormClassPart form_class;
-- PrintDialogClassPart print_dialog_class;
--} PrintDialogClassRec;
--
--extern PrintDialogClassRec printDialogClassRec;
--
--typedef struct _PrintDialogPart {
-- /* resources */
-- String label; /* description of the dialog */
-- String value; /* for the user response */
-- Pixmap icon; /* icon bitmap */
-- XtCallbackList ok_callback,
-- cancel_callback;
--
-- /* private */
-- Widget iconW; /* widget to display the icon */
--
-- struct
-- {
-- Widget form,
-- innerform,
-- desclabel,
-- desc,
-- info,
-- namelabel,
-- name,
-- selectprinter,
-- filenamelabel,
-- filename,
-- selectfile,
-- printtoprinter,
-- printtofile,
-- ok,
-- setup,
-- cancel;
-- } main;
--
-- Bool printToFile;
-- char *filename;
-- Bool canPrint, /* can we print ? */
-- canReallyPrint; /* is it really save to print ? */
-- XpuColorspaceRec *selected_colorspace;
--
-- struct
-- {
-- Widget popup,
-- form,
-- list,
-- ok,
-- cancel;
-- } selectPrinter;
--
-- struct
-- {
-- Widget popup,
-- form,
-- paperlist,
-- resolutionlist,
-- orientationlist,
-- plexlist,
-- colorspacelist,
-- jobcopieslabel,
-- jobcopies,
-- ok,
-- cancel;
-- } setup;
--
-- struct
-- {
-- Widget dialog,
-- shell;
-- } selectFile;
--
-- XPPrinterList printerlist;
-- int num_printers;
-- String *widget_printerlist;
--
-- String printer_name;
-- Display *pdpy;
-- XPContext pcontext;
--
-- XpuMediumSourceSizeList paperlist;
-- int num_papers;
-- String *widget_paperlist;
--
-- XpuResolutionList resolutionlist;
-- int num_resolutions;
-- String *widget_resolutionlist;
--
-- XpuOrientationList orientationlist;
-- int num_orientations;
-- String *widget_orientationlist;
--
-- XpuPlexList plexlist;
-- int num_plex;
-- String *widget_plexlist;
--
-- XpuColorspaceList colorspacelist;
-- int num_colorspaces;
-- String *widget_colorspacelist;
--} PrintDialogPart;
--
--typedef struct _PrintDialogRec {
-- CorePart core;
-- CompositePart composite;
-- ConstraintPart constraint;
-- FormPart form;
-- PrintDialogPart printdialog;
--} PrintDialogRec;
--
--typedef struct {
-- XtPointer extension;
--} PrintDialogConstraintsPart;
--
--typedef struct _PrintDialogConstraintsRec {
-- FormConstraintsPart form;
-- PrintDialogConstraintsPart printdialog;
--} PrintDialogConstraintsRec, *PrintDialogConstraints;
--
--#endif /* !_XawPrintDialogP_h */
--
---
-cgit v0.8.1-24-ge5fb
diff --git a/xorg-app/xmore/xmore-patch5.diff
b/xorg-app/xmore/xmore-patch5.diff
deleted file mode 100644
index 0570b15..0000000
--- a/xorg-app/xmore/xmore-patch5.diff
+++ /dev/null
@@ -1,20 +0,0 @@
-From d9b5448a77ff3ee06f6128faa69f43066cd16fe1 Mon Sep 17 00:00:00 2001
-From: Julien Cristau<jcristau AT debian.org>
-Date: Wed, 20 Aug 2008 22:46:51 +0000
-Subject: Fix build outside of source dir
-
----
-diff --git a/Makefile.am b/Makefile.am
-index d8aa027..3ba5868 100644
---- a/Makefile.am
-+++ b/Makefile.am
-@@ -42,6 +42,7 @@ APPDEFAULTFILES = \
- SUFFIXES = .ad
-
- .ad:
-+ $(mkdir_p) app-defaults
- cp $< $@
-
- appdefault_DATA = $(APPDEFAULTFILES)
---
-cgit v0.8.1-24-ge5fb
diff --git a/xorg-app/xmore/xmore-patch6.diff
b/xorg-app/xmore/xmore-patch6.diff
deleted file mode 100644
index 0b8578d..0000000
--- a/xorg-app/xmore/xmore-patch6.diff
+++ /dev/null
@@ -1,390 +0,0 @@
-From 747f76737a8e7a7f50bd06fd111e5ada8305884d Mon Sep 17 00:00:00 2001
-From: Julien Cristau<jcristau AT debian.org>
-Date: Sun, 16 Nov 2008 20:49:56 +0000
-Subject: More xprint pruning
-
----
-diff --git a/app-defaults/XMore.ad b/app-defaults/XMore.ad
-index 98704d9..78b1e0a 100644
---- a/app-defaults/XMore.ad
-+++ b/app-defaults/XMore.ad
-@@ -13,7 +13,6 @@
- <Key>Return: scroll-one-line-up()\n\
- <Key>J: scroll-one-line-up()\n\
- <Key>E: scroll-one-line-up()\n\
-- <Key>p: print()\n\
- <Key>q: quit()\n
- *text.baseTranslations: #override\n\
- <Key>space: next-page()\n\
-@@ -24,107 +23,9 @@
- <Key>Return: scroll-one-line-up()\n\
- <Key>J: scroll-one-line-up()\n\
- <Key>E: scroll-one-line-up()\n\
-- <Key>p: print()\n\
- <Key>q: quit()\n
-
- ! tip messages
- *quit.tip: Quit application
--*print.tip: Print file
--
--! Use "white" as background for printing
--*printshell*background: white
--
--! Print dialog
--*printdialogshell*geometry: 600x120
--*printdialogshell*title: Print
--*printdialogshell*main*ok.fromVert: innerform
--*printdialogshell*main*ok.label: Print
--*printdialogshell*main*ok.tip: Print
--*printdialogshell*main*setup.fromHoriz: ok
--*printdialogshell*main*setup.fromVert: innerform
--*printdialogshell*main*setup.label: Setup...
--*printdialogshell*main*setup.tip: Configure print job
options (page size, orientation, etc.)
--*printdialogshell*main*cancel.fromHoriz: setup
--*printdialogshell*main*cancel.fromVert: innerform
--*printdialogshell*main*cancel.label: Cancel
--*printdialogshell*main*cancel.tip: Cancel printing
--*printdialogshell*main*desclabel.label: Printer Description:
--*printdialogshell*main*desclabel.tip: Short description of
printer
--*printdialogshell*main*desc.fromHoriz: desclabel
--*printdialogshell*main*desc.tip: Short description of
printer
--*printdialogshell*main*info.fromHoriz: desc
--*printdialogshell*main*info.label: Printer info...
--*printdialogshell*main*info.tip: Display additional
information about this printer
--*printdialogshell*main*namelabel.fromVert: desclabel
--*printdialogshell*main*namelabel.label: Printer Name:
--*printdialogshell*main*namelabel.tip: Name of selected printer
--*printdialogshell*main*name.fromHoriz: namelabel
--*printdialogshell*main*name.fromVert: desclabel
--*printdialogshell*main*name.tip: Name of selected printer
--*printdialogshell*main*selectprinter.fromHoriz: name
--*printdialogshell*main*selectprinter.fromVert: desclabel
--*printdialogshell*main*selectprinter.label: Select Printer...
--*printdialogshell*main*selectprinter.label: Select Printer...
--*printdialogshell*main*selectprinter.tip: Select a different printer
--*printdialogshell*main*filenamelabel.fromVert: namelabel
--*printdialogshell*main*filenamelabel.label: File Name:
--*printdialogshell*main*filenamelabel.tip: File where the output
should be stored
--*printdialogshell*main*filename.fromHoriz: filenamelabel
--*printdialogshell*main*filename.fromVert: namelabel
--*printdialogshell*main*filename.tip: File where the output
should be stored
--*printdialogshell*main*selectfile.fromHoriz: filename
--*printdialogshell*main*selectfile.fromVert: namelabel
--*printdialogshell*main*selectfile.label: Select File...
--*printdialogshell*main*selectfile.tip: Select file where the
output should be stored
--*printdialogshell*main*printtoprinter.fromVert: filenamelabel
--*printdialogshell*main*printtoprinter.label: Print to Printer
--*printdialogshell*main*printtoprinter.tip: Send print job to printer
--*printdialogshell*main*printtofile.fromVert: filenamelabel
--*printdialogshell*main*printtofile.fromHoriz: printtoprinter
--*printdialogshell*main*printtofile.label: Print to File
--*printdialogshell*main*printtofile.tip: Save print job in a file
--
--! Print job options dialog
--*printdialogshell*setup*geometry: 600x400
--*printdialogshell*setup*title: Print: Print job
options
--*printdialogshell*setup*ok.fromVert: list
--*printdialogshell*setup*ok.label: OK
--*printdialogshell*setup*ok.tip: Commit changes
--*printdialogshell*setup*cancel.fromHoriz: ok
--*printdialogshell*setup*cancel.fromVert: list
--*printdialogshell*setup*cancel.label: Cancel
--*printdialogshell*setup*cancel.tip: Cancel and reset to
defaults
--*printdialogshell*setup*paperlist.tip: Select paper size
--*printdialogshell*setup*resolutionlist.fromHoriz: paperlist
--*printdialogshell*setup*resolutionlist.tip: Select page resolution
--*printdialogshell*setup*orientationlist.fromHoriz: resolutionlist
--*printdialogshell*setup*orientationlist.tip: Select page
orientation
--*printdialogshell*setup*plexlist.fromHoriz: orientationlist
--*printdialogshell*setup*plexlist.tip: Select page plex mode
(simplex, duplex, etc.)
--*printdialogshell*setup*colorspacelist.fromHoriz: plexlist
--*printdialogshell*setup*colorspacelist.tip: Select color space
(color, grayscale, CYMK, etc.)
--*printdialogshell*setup*jobcopieslabel.fromVert: paperlist
--*printdialogshell*setup*jobcopieslabel.tip: Set number of job
copies
--*printdialogshell*setup*jobcopieslabel.label: Job Copies:
--*printdialogshell*setup*jobcopies.fromHoriz: jobcopieslabel
--*printdialogshell*setup*jobcopies.fromVert: paperlist
--*printdialogshell*setup*jobcopies.tip: Set number of job
copies
--
--! Printer selection
--*printdialogshell*printerselection*geometry: 400x150
--*printdialogshell*printerselection*title: Print: Select printer
--*printdialogshell*printerselection*ok.fromVert: list
--*printdialogshell*printerselection*ok.label: OK
--*printdialogshell*printerselection*ok.tip: Switch printer
--*printdialogshell*printerselection*cancel.fromHoriz: ok
--*printdialogshell*printerselection*cancel.fromVert: list
--*printdialogshell*printerselection*cancel.label: Cancel
--*printdialogshell*printerselection*cancel.tip: Cancel printer
selection
--*printdialogshell*printerselection*list.tip: Select printer name
from list
--
--! Select job file
--*printdialogshell*selectfile*geometry: 400x80
--*printdialogshell*selectfile*title: Print: Select job file
--*printdialogshell*selectfile*dialog.label: Select Filename:
-
- ! EOF.
-diff --git a/xmore.c b/xmore.c
-index 4ed6e23..ff8c299 100644
---- a/xmore.c
-+++ b/xmore.c
-@@ -41,13 +41,6 @@ in this Software without prior written authorization from
The Open Group.
-
- #include "xmore.h"
-
--#ifdef USE_XPRINT
--
--#include "printdialog.h"
--#include "print.h"
--
--#endif
--
- #include <stdlib.h>
- #include <stdio.h>
- #include <limits.h>
-@@ -60,21 +53,14 @@ in this Software without prior written authorization
from The Open Group.
- #define Log(x) { if (userOptions.verbose) printf x; }
-
- /* Global vars */
--static Widget printdialog_shell = NULL;
--static Widget printdialog = NULL;
- static Widget toplevel = NULL;
- static Widget text = NULL;
--static char printJobNameBuffer[PATH_MAX+256];
- static const char *ProgramName; /* program name (from argv[0]) */
- static const char *viewFileName; /* file to browse (from argv[1]) */
-
- /* prototypes */
- static void quitAction(Widget w, XEvent *event, String *params, Cardinal
*num_params);
- static void quitXtProc(Widget w, XtPointer client_data, XtPointer callData);
--#ifdef USE_XPRINT
--static void printAction(Widget w, XEvent *event, String *params, Cardinal
*num_params);
--static void printXtProc(Widget w, XtPointer client_data, XtPointer
callData);
--#endif
-
- static XrmOptionDescRec options[] = {
- {
-@@ -84,9 +70,6 @@ static XrmOptionDescRec options[] = {
-
- static XtActionsRec actions[] = {
- { "quit", quitAction },
--#ifdef USE_XPRINT
-- { "print", printAction }
--#endif
- };
-
- /* See xmore.h */
-@@ -119,7 +102,6 @@ String fallback_resources[] = {
- "\t<Key>Return: scroll-one-line-up()\\n\\"
- "\t<Key>J: scroll-one-line-up()\\n\\"
- "\t<Key>E: scroll-one-line-up()\\n\\"
-- "\t<Key>p: print()\\n\\"
- "\t<Key>q: quit()\\n",
- "*text.baseTranslations: #override \\n\\"
- "\t<Key>space: next-page()\\n\\"
-@@ -130,7 +112,6 @@ String fallback_resources[] = {
- "\t<Key>Return: scroll-one-line-up()\\n\\"
- "\t<Key>J: scroll-one-line-up()\\n\\"
- "\t<Key>E: scroll-one-line-up()\\n\\"
-- "\t<Key>p: print()\\n\\"
- "\t<Key>q: quit()\\n",
- NULL,
- };
-@@ -147,114 +128,10 @@ quitXtProc(Widget w, XtPointer client_data, XtPointer
callData)
- XtCallActionProc(w, "quit", NULL, NULL, 0);
- }
-
--static void
--printshellDestroyXtProc(Widget w, XtPointer client_data, XtPointer callData)
--{
-- XawPrintDialogClosePrinterConnection(printdialog, False);
--}
--
--#ifdef USE_XPRINT
--
--static void
--printOKXtProc(Widget w, XtPointer client_data, XtPointer callData)
--{
-- XawPrintDialogCallbackStruct *pdcs = (XawPrintDialogCallbackStruct
*)callData;
-- Cardinal n;
-- Arg args[2];
-- Widget textsource;
--
-- Log(("printOKXtProc: OK.\n"));
--
-- /* Get TextSource object */
-- n = 0;
-- XtSetArg(args[n], XtNtextSource, &textsource); n++;
-- XtGetValues(text, args, n);
--
-- Assertion(textsource != NULL, (("printOKXtProc: textsource ==
NULL.\n")));
--
-- /* ||printJobNameBuffer| must live as long the print job prints
-- * because it is used for the job title AND the page headers... */
-- sprintf(printJobNameBuffer, "XMore print job %s", viewFileName);
--
-- DoPrintTextSource(ProgramName,
-- textsource, toplevel,
-- pdcs->pdpy, pdcs->pcontext, pdcs->colorspace,
-- printshellDestroyXtProc,
-- printJobNameBuffer,
-- pdcs->printToFile?pdcs->printToFileName:NULL);
--
-- XtPopdown(printdialog_shell);
--}
--
--static void
--printCancelXtProc(Widget w, XtPointer client_data, XtPointer callData)
--{
-- Log(("printCancelXtProc: cancel.\n"));
-- XtPopdown(printdialog_shell);
--
-- Log(("destroying print dialog shell...\n"));
-- XtDestroyWidget(printdialog_shell);
-- printdialog_shell = NULL;
-- printdialog = NULL;
-- Log(("... done\n"));
--}
--
--static void
--printXtProc(Widget w, XtPointer client_data, XtPointer callData)
--{
-- XtCallActionProc(toplevel, "print", NULL, NULL, 0);
--}
--
--static void
--printAction(Widget w, XEvent *event, String *params, Cardinal *num_params)
--{
-- Dimension width, height;
-- Position x, y;
-- Widget parent = toplevel;
-- Log(("print!\n"));
--
-- if (!printdialog) {
-- int n;
-- Arg args[20];
--
-- n = 0;
-- XtSetArg(args[n], XtNallowShellResize, True); n++;
-- printdialog_shell = XtCreatePopupShell("printdialogshell",
-- transientShellWidgetClass,
-- toplevel, args, n);
-- n = 0;
-- printdialog = XtCreateManagedWidget("printdialog",
printDialogWidgetClass,
-- printdialog_shell, args, n);
-- XtAddCallback(printdialog, XawNOkCallback, printOKXtProc, NULL);
-- XtAddCallback(printdialog, XawNCancelCallback, printCancelXtProc, NULL);
--
-- XtRealizeWidget(printdialog_shell);
-- }
--
-- /* Center dialog */
-- XtVaGetValues(printdialog_shell,
-- XtNwidth, &width,
-- XtNheight, &height,
-- NULL);
--
-- x = (Position)(XWidthOfScreen( XtScreen(parent)) - width) / 2;
-- y = (Position)(XHeightOfScreen(XtScreen(parent)) - height) / 3;
--
-- XtVaSetValues(printdialog_shell,
-- XtNx, x,
-- XtNy, y,
-- NULL);
--
-- XtPopup(printdialog_shell, XtGrabNonexclusive);
--}
--
--#endif
--
- int main( int argc, char *argv[] )
- {
- XtAppContext app;
- Widget form;
-- Widget printbutton;
- Widget quitbutton;
- int n;
- Arg args[8];
-@@ -292,25 +169,13 @@ int main( int argc, char *argv[] )
- XtSetArg(args[n], XtNfontSet, userOptions.textfont); n++;
- text = XtCreateManagedWidget("text", asciiTextWidgetClass, form, args, n);
-
--#ifdef USE_XPRINT
- n = 0;
-- XtSetArg(args[n], XtNfromHoriz, NULL); n++;
-- XtSetArg(args[n], XtNfromVert, text); n++;
-- XtSetArg(args[n], XtNlabel, "Print..."); n++;
-- printbutton = XtCreateManagedWidget("print", commandWidgetClass, form,
args, n);
-- XtAddCallback(printbutton, XtNcallback, printXtProc, 0);
--#endif
--
-- n = 0;
-- XtSetArg(args[n], XtNfromHoriz, printbutton); n++;
-+ XtSetArg(args[n], XtNfromHoriz, NULL); n++;
- XtSetArg(args[n], XtNfromVert, text); n++;
- XtSetArg(args[n], XtNlabel, "Quit"); n++;
- quitbutton = XtCreateManagedWidget("quit", commandWidgetClass, form,
args, n);
- XtAddCallback(quitbutton, XtNcallback, quitXtProc, 0);
-
-- printdialog_shell = NULL;
-- printdialog = NULL;
--
- XtRealizeWidget(toplevel);
-
- XtAppMainLoop(app);
-diff --git a/xmore.man b/xmore.man
-index 2936397..6475822 100644
---- a/xmore.man
-+++ b/xmore.man
-@@ -12,12 +12,5 @@ xmore \- plain text display program for the X Window
System
- .ad b
- .SH DESCRIPTION
- xmore is a plain text browser.
--.SH ENVIRONMENT
--.TP
--\fBXPSERVERLIST\fR
--\fB${XPSERVERLIST}\fR must be set,
--identifying the available Xprint servers.
--See \fBXprint\fR(__miscmansuffix__)
--for more details.
- .SH "SEE ALSO"
- \fBX11\fR(__miscmansuffix__), \fBxman\fR(__appmansuffix__)
-diff --git a/xmore.sgml b/xmore.sgml
-index ec766c0..a92b317 100644
---- a/xmore.sgml
-+++ b/xmore.sgml
-@@ -38,24 +38,6 @@ manual volume numbers.
-
- </refsect1>
-
-- <refsect1>
-- <title>ENVIRONMENT</title>
-- <variablelist>
-- <varlistentry>
-- <term><envar>XPSERVERLIST</envar>
-- </term>
-- <listitem>
-- <para>
-- <envar>${XPSERVERLIST}</envar> must be set,
-- identifying the available Xprint servers.
-- See
<citerefentry><refentrytitle>Xprint</refentrytitle><manvolnum>__miscmansuffix__</manvolnum></citerefentry>
-- for more details.
-- </para>
-- </listitem>
-- </varlistentry>
-- </variablelist>
-- </refsect1>
--
- <!-- not yet
- <refsect1>
- <title>KNOWN BUGS</title>
-@@ -71,7 +53,6 @@ manual volume numbers.
- <!-- specific references -->
- <!-- none -->
-
-- <!-- Xprint general references -->
-
<member><citerefentry><refentrytitle>X11</refentrytitle><manvolnum>__miscmansuffix__</manvolnum></citerefentry></member>
-
<member><citerefentry><refentrytitle>xman</refentrytitle><manvolnum>__appmansuffix__</manvolnum></citerefentry></member>
- </simplelist>
---
-cgit v0.8.1-24-ge5fb
diff --git a/xorg-app/xmore/xmore-patch7.diff
b/xorg-app/xmore/xmore-patch7.diff
deleted file mode 100644
index 239a8a5..0000000
--- a/xorg-app/xmore/xmore-patch7.diff
+++ /dev/null
@@ -1,156 +0,0 @@
-From ab8110b8978cb965d49e0c2e9c1cb7e7608c185e Mon Sep 17 00:00:00 2001
-From: Paulo Cesar Pereira de Andrade<pcpa AT mandriva.com.br>
-Date: Thu, 22 Jan 2009 18:49:25 +0000
-Subject: Correct make distcheck and sparse warnings.
-
----
-diff --git a/Makefile.am b/Makefile.am
-index 3ba5868..63e18dc 100644
---- a/Makefile.am
-+++ b/Makefile.am
-@@ -21,7 +21,7 @@
-
- bin_PROGRAMS = xmore
-
--xmore_CFLAGS = $(XMORE_CFLAGS) -DXMORE
-+AM_CFLAGS = $(XMORE_CFLAGS) -DXMORE
- xmore_LDADD = $(XMORE_LIBS)
-
- xmore_SOURCES = \
-@@ -31,34 +31,22 @@ xmore_SOURCES = \
- appman_PRE = \
- xmore.man
-
--# App default files (*.ad)
-+# App default files
-+DISTCHECK_CONFIGURE_FLAGS =
--with-appdefaultdir=\$${datadir}/X11/app-defaults
-
- appdefaultdir = @appdefaultdir@
-
--
--APPDEFAULTFILES = \
-+dist_appdefault_DATA = \
- app-defaults/XMore
-
--SUFFIXES = .ad
--
--.ad:
-- $(mkdir_p) app-defaults
-- cp $< $@
--
--appdefault_DATA = $(APPDEFAULTFILES)
--
--EXTRA_DIST = $(APPDEFAULTFILES:%=%.ad)
--
--CLEANFILES = $(APPDEFAULTFILES)
--
--EXTRA_DIST += xmore.sgml
-+EXTRA_DIST = xmore.sgml
-
- appmandir = $(APP_MAN_DIR)
-
- appman_DATA = $(appman_PRE:man=@APP_MAN_SUFFIX@)
-
- EXTRA_DIST += $(appman_PRE)
--CLEANFILES += $(appman_DATA)
-+CLEANFILES = $(appman_DATA)
-
- SED = sed
-
-@@ -79,7 +67,7 @@ MAN_SUBSTS = \
- -e 's|__miscmansuffix__|$(MISC_MAN_SUFFIX)|g' \
- -e 's|__filemansuffix__|$(FILE_MAN_SUFFIX)|g'
-
--SUFFIXES += .$(APP_MAN_SUFFIX) .man
-+SUFFIXES = .$(APP_MAN_SUFFIX) .man
-
- .man.$(APP_MAN_SUFFIX):
- sed $(MAN_SUBSTS) < $< > $@
-diff --git a/app-defaults/XMore.ad b/app-defaults/XMore.ad
-index 78b1e0a..9227efa 100644
---- a/app-defaults/XMore.ad
-+++ b/app-defaults/XMore.ad
-@@ -28,4 +28,6 @@
- ! tip messages
- *quit.tip: Quit application
-
-+*international: True
-+
- ! EOF.
-diff --git a/configure.ac b/configure.ac
-index 34d6aa6..a427a9c 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -26,23 +26,34 @@ AC_INIT(xmore,[1.0.1],
[https://bugs.freedesktop.org/enter_bug.cgi?product=xorg]
- AM_INIT_AUTOMAKE([dist-bzip2])
- AM_MAINTAINER_MODE
-
-+# Require xorg-macros: XORG_CWARNFLAGS, XORG_CHANGELOG
-+m4_ifndef([XORG_MACROS_VERSION], [AC_FATAL([must install xorg-macros 1.2 or
later before running autoconf/autogen])])
-+XORG_MACROS_VERSION(1.2)
-+
- AM_CONFIG_HEADER(config.h)
-
- AC_PROG_CC
- AM_PROG_CC_C_O
- AC_PROG_INSTALL
-
-+XORG_CWARNFLAGS
-+
- # Checks for pkg-config packages
- PKG_CHECK_MODULES(XMORE, xaw7)
--
-+XMORE_CFLAGS="$CWARNFLAGS $XMORE_CFLAGS"
- AC_SUBST(XMORE_CFLAGS)
- AC_SUBST(XMORE_LIBS)
-
- PKG_CHECK_MODULES(APPDEFS, xt)
--appdefaultdir=$(pkg-config --variable=appdefaultdir xt)
-+xt_appdefaultdir=$(pkg-config --variable=appdefaultdir xt)
-+AC_ARG_WITH(appdefaultdir,
-+ AC_HELP_STRING([--with-appdefaultdir=<pathname>],
-+ [specify directory for app-defaults files (default is
autodetected)]),
-+ [appdefaultdir="$withval"], [appdefaultdir="${xt_appdefaultdir}"])
- AC_SUBST(appdefaultdir)
-
- XORG_MANPAGE_SECTIONS
- XORG_RELEASE_VERSION
-+XORG_CHANGELOG
-
- AC_OUTPUT([Makefile])
-diff --git a/xmore.c b/xmore.c
-index ff8c299..ed6be29 100644
---- a/xmore.c
-+++ b/xmore.c
-@@ -73,17 +73,17 @@ static XtActionsRec actions[] = {
- };
-
- /* See xmore.h */
--XMoreResourceData userOptions;
-+static XMoreResourceData userOptions;
-
- #define Offset(field) XtOffsetOf(XMoreResourceData, field)
-
--XtResource resources[] = {
-+static XtResource resources[] = {
- {"verbose", "Verbose", XtRBoolean, sizeof(Boolean), Offset(verbose),
XtRImmediate, (XtPointer)False},
- {"textfont", XtCFont, XtRFontSet, sizeof(XFontSet), Offset(textfont),
XtRString, STANDARDFONT},
- };
-
-
--String fallback_resources[] = {
-+static String fallback_resources[] = {
- #ifdef NOTYET
- "*iconPixmap: xmore32",
- "*iconMask: xmore32",
-@@ -174,7 +174,7 @@ int main( int argc, char *argv[] )
- XtSetArg(args[n], XtNfromVert, text); n++;
- XtSetArg(args[n], XtNlabel, "Quit"); n++;
- quitbutton = XtCreateManagedWidget("quit", commandWidgetClass, form,
args, n);
-- XtAddCallback(quitbutton, XtNcallback, quitXtProc, 0);
-+ XtAddCallback(quitbutton, XtNcallback, quitXtProc, NULL);
-
- XtRealizeWidget(toplevel);
-
---
-cgit v0.8.1-24-ge5fb
diff --git a/xorg-app/xrandr/DETAILS b/xorg-app/xrandr/DETAILS
index 640e685..f42e85c 100755
--- a/xorg-app/xrandr/DETAILS
+++ b/xorg-app/xrandr/DETAILS
@@ -1,5 +1,5 @@
SPELL=xrandr
- VERSION=1.3.2
+ VERSION=1.3.3
SOURCE=$SPELL-$VERSION.tar.bz2

SOURCE_URL[0]=http://xorg.freedesktop.org/releases/individual/app/${SOURCE}
#
SOURCE_HASH=sha512:d4060a11010653c7461583b3b9702b8bf7134b181be177266fa0eb4f2f7e6b794b717ab8b2b29d7c6dcd4493a228438b198aeb7b0e4a9d341583cc6b6fa28b61
diff --git a/xorg-app/xrandr/HISTORY b/xorg-app/xrandr/HISTORY
index 55324de..5af58d3 100644
--- a/xorg-app/xrandr/HISTORY
+++ b/xorg-app/xrandr/HISTORY
@@ -1,3 +1,7 @@
+2010-09-04 Eric Sandall <sandalle AT sourcemage.org>
+ * DETAILS: Updated to 1.3.3
+ SOURCE matches upstream posted SHA1
+
2009-09-11 Eric Sandall <sandalle AT sourcemage.org>
* DETAILS: Updated to 1.3.2
SOURCE matches upstream posted MD5
diff --git a/xorg-app/xrandr/xrandr-1.3.2.tar.bz2.sig
b/xorg-app/xrandr/xrandr-1.3.2.tar.bz2.sig
deleted file mode 100644
index de279ca..0000000
Binary files a/xorg-app/xrandr/xrandr-1.3.2.tar.bz2.sig and /dev/null differ
diff --git a/xorg-app/xrandr/xrandr-1.3.3.tar.bz2.sig
b/xorg-app/xrandr/xrandr-1.3.3.tar.bz2.sig
new file mode 100644
index 0000000..79e35b2
Binary files /dev/null and b/xorg-app/xrandr/xrandr-1.3.3.tar.bz2.sig differ
diff --git a/xorg-app/xset/DEPENDS b/xorg-app/xset/DEPENDS
index 0a8a08f..85cb125 100755
--- a/xorg-app/xset/DEPENDS
+++ b/xorg-app/xset/DEPENDS
@@ -1,10 +1,15 @@
depends util-macros &&
+depends libx11 &&
depends libxmu &&
-optional_depends xextproto "" "" "Someone needs to describe this nicely." &&
-optional_depends libxext "" "" "Someone needs to describe this nicely." &&
-optional_depends kbproto "" "" "Someone needs to describe this nicely." &&
-optional_depends libx11 "" "" "Someone needs to describe this nicely." &&
-optional_depends xf86miscproto "" "" "Someone needs to describe this
nicely." &&
-optional_depends libxxf86misc "" "" "Someone needs to describe this nicely."
&&
-optional_depends fontcacheproto "" "" "Someone needs to describe this
nicely." &&
-optional_depends libxfontcache "" "" "Someone needs to describe this
nicely."
+optional_depends libxext \
+ "" \
+ "" \
+ "for X11 Nonrectangular Window Shape Extension" &&
+optional_depends libxxf86misc \
+ "--with-xf86misc" \
+ "--without-xf86misc" \
+ "" &&
+optional_depends libxfontcache \
+ "--with-fontcache" \
+ "--without-fontcache" \
+ ""
diff --git a/xorg-app/xset/DETAILS b/xorg-app/xset/DETAILS
index 4f033e5..b1ac047 100755
--- a/xorg-app/xset/DETAILS
+++ b/xorg-app/xset/DETAILS
@@ -1,10 +1,11 @@
SPELL=xset
PKG=xset
- VERSION=1.1.0
+ VERSION=1.2.0
XORG_VER=X11R7.1
SOURCE=${PKG}-${VERSION}.tar.bz2
+ SOURCE_GPG="gurus.gpg:$SOURCE.sig:UPSTREAM_HASH"

SOURCE_URL[0]=http://xorg.freedesktop.org/releases/individual/app/${SOURCE}
-
SOURCE_HASH=sha512:5817b93f75b98bf261057405cd1e78be3eada5124e3ea8d0d3fa7191ac95c2a3264521d554b27a76e8e06cbe025adaac1124e91f9a76efeb11c425f5c49326f8
+#
SOURCE_HASH=sha512:5817b93f75b98bf261057405cd1e78be3eada5124e3ea8d0d3fa7191ac95c2a3264521d554b27a76e8e06cbe025adaac1124e91f9a76efeb11c425f5c49326f8
SOURCE_DIRECTORY=${BUILD_DIRECTORY}/${PKG}-${VERSION}
WEB_SITE=http://xorg.freedesktop.org/wiki
ENTERED=20051125
diff --git a/xorg-app/xset/HISTORY b/xorg-app/xset/HISTORY
index 2412ee1..34fb3e8 100644
--- a/xorg-app/xset/HISTORY
+++ b/xorg-app/xset/HISTORY
@@ -1,3 +1,10 @@
+2010-09-04 Eric Sandall <sandalle AT sourcemage.org>
+ * DETAILS: Updated to 1.2.0
+ SOURCE matches upstream posted SHA1
+ * DEPENDS: xf86misc and fontcache configure flags added
+ libx11 is required
+ Removed *proto optional dependencies (depended upon by libraries
used)
+
2009-09-24 Andraž "ruskie" Levstik <ruskie+f03a580f AT codemages.net>
* DETAILS: updated spell to 1.1.0

diff --git a/xorg-app/xset/xset-1.2.0.tar.bz2.sig
b/xorg-app/xset/xset-1.2.0.tar.bz2.sig
new file mode 100644
index 0000000..ec4f3d6
Binary files /dev/null and b/xorg-app/xset/xset-1.2.0.tar.bz2.sig differ
diff --git a/xorg-driver/xf86-video-nv/DETAILS
b/xorg-driver/xf86-video-nv/DETAILS
index 580a905..e0f582e 100755
--- a/xorg-driver/xf86-video-nv/DETAILS
+++ b/xorg-driver/xf86-video-nv/DETAILS
@@ -1,5 +1,5 @@
SPELL=xf86-video-nv
- VERSION=2.1.17
+ VERSION=2.1.18
SOURCE=$SPELL-$VERSION.tar.bz2
SOURCE_GPG="gurus.gpg:$SOURCE.sig:UPSTREAM_HASH"

SOURCE_URL[0]=http://xorg.freedesktop.org/releases/individual/driver/${SOURCE}
diff --git a/xorg-driver/xf86-video-nv/HISTORY
b/xorg-driver/xf86-video-nv/HISTORY
index 0be1cfc..da307ba 100644
--- a/xorg-driver/xf86-video-nv/HISTORY
+++ b/xorg-driver/xf86-video-nv/HISTORY
@@ -1,3 +1,7 @@
+2010-09-04 Eric Sandall <sandalle AT sourcemage.org>
+ * DETAILS: Updated to 2.1.18
+ SOURCE matches upstream posted SHA1
+
2010-03-11 Sukneet Basuta <sukneet AT sourcemage.org>
* DETAILS: updated spell to 2.1.17

diff --git a/xorg-driver/xf86-video-nv/xf86-video-nv-2.1.17.tar.bz2.sig
b/xorg-driver/xf86-video-nv/xf86-video-nv-2.1.17.tar.bz2.sig
deleted file mode 100644
index f4110f7..0000000
Binary files a/xorg-driver/xf86-video-nv/xf86-video-nv-2.1.17.tar.bz2.sig and
/dev/null differ
diff --git a/xorg-driver/xf86-video-nv/xf86-video-nv-2.1.18.tar.bz2.sig
b/xorg-driver/xf86-video-nv/xf86-video-nv-2.1.18.tar.bz2.sig
new file mode 100644
index 0000000..8c100af
Binary files /dev/null and
b/xorg-driver/xf86-video-nv/xf86-video-nv-2.1.18.tar.bz2.sig differ
diff --git a/xorg-proto/glproto/DETAILS b/xorg-proto/glproto/DETAILS
index cf28f53..22e1832 100755
--- a/xorg-proto/glproto/DETAILS
+++ b/xorg-proto/glproto/DETAILS
@@ -11,6 +11,6 @@ SOURCE_DIRECTORY=$BUILD_DIRECTORY/${SPELL}-${VERSION}
SHORT="the X.Org OpenGL related protocol headers"
cat << EOF
glproto provides the wire protocols for various OpenGL related
-extensions in X.Org. These are used to enable the rendering of
+extensions in X.Org. These are used to enable the rendering of
applications using OpenGL.
EOF
diff --git a/xorg-proto/glproto/HISTORY b/xorg-proto/glproto/HISTORY
index 3baf16b..e051003 100644
--- a/xorg-proto/glproto/HISTORY
+++ b/xorg-proto/glproto/HISTORY
@@ -47,6 +47,5 @@
* DEPENDS: auto-created or updated

2005-11-24 Robin Cook <rcook AT wyrms.net>
- * INITIAL: break up of xorg into modules X11R7.0.0
-
+ * INITIAL: break up of xorg into modules X11R7.0.0

diff --git a/xorg-proto/kbproto/DETAILS b/xorg-proto/kbproto/DETAILS
index 690cecb..04abbbf 100755
--- a/xorg-proto/kbproto/DETAILS
+++ b/xorg-proto/kbproto/DETAILS
@@ -11,8 +11,8 @@ SOURCE_DIRECTORY=$BUILD_DIRECTORY/${SPELL}-${VERSION}
SHORT="the X.Org XKEYBOARD protocol headers"
cat << EOF
kbproto provides the wire protocol for the XKEYBAORD extension in
-X.Org. It is used to control all manner of options related to
-keyboard handling and layout in particular. It does not control the
+X.Org. It is used to control all manner of options related to
+keyboard handling and layout in particular. It does not control the
addition/enabling/disabling of keyboard however, that is done with the
XINPUT extension.
EOF
diff --git a/xorg-proto/kbproto/HISTORY b/xorg-proto/kbproto/HISTORY
index 3d45187..cbe50ee 100644
--- a/xorg-proto/kbproto/HISTORY
+++ b/xorg-proto/kbproto/HISTORY
@@ -2,7 +2,7 @@
* DETAILS: Updated to 1.0.5
SOURCE matches upstream posted SHA1

-2009-10-13 Treeve Jelbert <treeve AT sourcemage.org>
+2009-10-13 Treeve Jelbert <treeve AT sourcemage.org>
* DETAILS: version 1.0.4

2008-03-17 Eric Sandall <sandalle AT sourcemage.org>
@@ -34,6 +34,5 @@
* DEPENDS: auto-created or updated

2005-11-24 Robin Cook <rcook AT wyrms.net>
- * INITIAL: break up of xorg into modules X11R7.0.0
-
+ * INITIAL: break up of xorg into modules X11R7.0.0




  • [SM-Commit] GIT changes to master grimoire by Eric Sandall (bcec4bd7cf33ed4a36456b1dd34a626956539541), Eric Sandall, 09/04/2010

Archive powered by MHonArc 2.6.24.

Top of Page