Hello community,
here is the log from the commit of package yast2-printer for openSUSE:Factory
checked in at Fri Apr 24 19:48:32 CEST 2009.
--------
--- yast2-printer/yast2-printer.changes 2009-04-16 17:09:04.000000000 +0200
+++ yast2-printer/yast2-printer.changes 2009-04-24 12:34:08.665987000 +0200
@@ -1,0 +2,27 @@
+Fri Apr 24 10:42:09 CEST 2009 - jsmeix@suse.de
+
+- Fixed the Connection Wizard which now checks for each connection
+ which is not natively supported by CUPS if the RPM package
+ which provides the matching CUPS backend is installed.
+- 2.18.14
+
+-------------------------------------------------------------------
+Thu Apr 23 13:24:07 CEST 2009 - jsmeix@suse.de
+
+- When printing a testpage in the Overview dialog, explicitely
+ show the pending print jobs so that the user can now better
+ decide whether or not the pending jobs could be deleted.
+- Fixed serial printer setup in the Connection Wizard
+ (see Novell/Suse Bugzilla bnc#488655) and
+ fixed SCSI printer setup in the Connection Wizard accordingly.
+- Makeshift fix of the bluetooth setup in the Connection Wizard
+ so that manual bluetooth printer setup is possible now
+ (see Novell/Suse Bugzilla bnc#467220 comment #11).
+- Removed all stuff regarding "infra" from the Connection Wizard
+ because we do not and did not provide a CUPS backend for
+ infrared access (IrDA) which does not mean that such a setup
+ is impossible because any special case can be set up
+ via "Specify Arbitrary Device URI".
+- 2.18.13
+
+-------------------------------------------------------------------
calling whatdependson for head-i586
Old:
----
yast2-printer-2.18.12.tar.bz2
New:
----
yast2-printer-2.18.14.tar.bz2
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ yast2-printer.spec ++++++
--- /var/tmp/diff_new_pack.aP4706/_old 2009-04-24 19:40:57.000000000 +0200
+++ /var/tmp/diff_new_pack.aP4706/_new 2009-04-24 19:40:57.000000000 +0200
@@ -1,5 +1,5 @@
#
-# spec file for package yast2-printer (Version 2.18.12)
+# spec file for package yast2-printer (Version 2.18.14)
#
# Copyright (c) 2009 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
@@ -20,12 +20,12 @@
Url: http://en.opensuse.org/YaST/Modules/Printer
Name: yast2-printer
-Version: 2.18.12
+Version: 2.18.14
Release: 1
License: GPL v2 or later
Group: System/YaST
BuildRoot: %{_tmppath}/%{name}-%{version}-build
-Source0: yast2-printer-2.18.12.tar.bz2
+Source0: yast2-printer-2.18.14.tar.bz2
Prefix: /usr
BuildRequires: cups-devel update-desktop-files yast2 yast2-core-devel yast2-devtools yast2-testsuite
Recommends: netcat
@@ -65,7 +65,7 @@
Michal Zugec
%prep
-%setup -n yast2-printer-2.18.12
+%setup -n yast2-printer-2.18.14
%build
%{prefix}/bin/y2tool y2autoconf
@@ -127,6 +127,27 @@
%exclude %{prefix}/share/doc/packages/yast2-printer/COPYING
%exclude %{prefix}/share/doc/packages/yast2-printer/README
%changelog
+* Fri Apr 24 2009 jsmeix@suse.de
+- Fixed the Connection Wizard which now checks for each connection
+ which is not natively supported by CUPS if the RPM package
+ which provides the matching CUPS backend is installed.
+- 2.18.14
+* Thu Apr 23 2009 jsmeix@suse.de
+- When printing a testpage in the Overview dialog, explicitely
+ show the pending print jobs so that the user can now better
+ decide whether or not the pending jobs could be deleted.
+- Fixed serial printer setup in the Connection Wizard
+ (see Novell/Suse Bugzilla bnc#488655) and
+ fixed SCSI printer setup in the Connection Wizard accordingly.
+- Makeshift fix of the bluetooth setup in the Connection Wizard
+ so that manual bluetooth printer setup is possible now
+ (see Novell/Suse Bugzilla bnc#467220 comment #11).
+- Removed all stuff regarding "infra" from the Connection Wizard
+ because we do not and did not provide a CUPS backend for
+ infrared access (IrDA) which does not mean that such a setup
+ is impossible because any special case can be set up
+ via "Specify Arbitrary Device URI".
+- 2.18.13
* Thu Apr 16 2009 jsmeix@suse.de
- Undo using "-o document-format=application/vnd.cups-postscript"
when submitting the test page because it does not work for
++++++ yast2-printer-2.18.12.tar.bz2 -> yast2-printer-2.18.14.tar.bz2 ++++++
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-printer-2.18.12/configure new/yast2-printer-2.18.14/configure
--- old/yast2-printer-2.18.12/configure 2009-04-16 17:04:50.000000000 +0200
+++ new/yast2-printer-2.18.14/configure 2009-04-24 12:18:46.000000000 +0200
@@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.63 for yast2-printer 2.18.12.
+# Generated by GNU Autoconf 2.63 for yast2-printer 2.18.14.
#
# Report bugs to http://bugs.opensuse.org/.
#
@@ -596,8 +596,8 @@
# Identity of this package.
PACKAGE_NAME='yast2-printer'
PACKAGE_TARNAME='yast2-printer'
-PACKAGE_VERSION='2.18.12'
-PACKAGE_STRING='yast2-printer 2.18.12'
+PACKAGE_VERSION='2.18.14'
+PACKAGE_STRING='yast2-printer 2.18.14'
PACKAGE_BUGREPORT='http://bugs.opensuse.org/'
ac_unique_file="RPMNAME"
@@ -1274,7 +1274,7 @@
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
-\`configure' configures yast2-printer 2.18.12 to adapt to many kinds of systems.
+\`configure' configures yast2-printer 2.18.14 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@@ -1345,7 +1345,7 @@
if test -n "$ac_init_help"; then
case $ac_init_help in
- short | recursive ) echo "Configuration of yast2-printer 2.18.12:";;
+ short | recursive ) echo "Configuration of yast2-printer 2.18.14:";;
esac
cat <<\_ACEOF
@@ -1425,7 +1425,7 @@
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
-yast2-printer configure 2.18.12
+yast2-printer configure 2.18.14
generated by GNU Autoconf 2.63
Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
@@ -1439,7 +1439,7 @@
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
-It was created by yast2-printer $as_me 2.18.12, which was
+It was created by yast2-printer $as_me 2.18.14, which was
generated by GNU Autoconf 2.63. Invocation command line was
$ $0 $@
@@ -2286,7 +2286,7 @@
# Define the identity of the package.
PACKAGE='yast2-printer'
- VERSION='2.18.12'
+ VERSION='2.18.14'
cat >>confdefs.h <<_ACEOF
@@ -2510,7 +2510,7 @@
-VERSION="2.18.12"
+VERSION="2.18.14"
RPMNAME="yast2-printer"
MAINTAINER="Michal Zugec "
@@ -3451,7 +3451,7 @@
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
-This file was extended by yast2-printer $as_me 2.18.12, which was
+This file was extended by yast2-printer $as_me 2.18.14, which was
generated by GNU Autoconf 2.63. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
@@ -3501,7 +3501,7 @@
_ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_version="\\
-yast2-printer config.status 2.18.12
+yast2-printer config.status 2.18.14
configured by $0, generated by GNU Autoconf 2.63,
with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-printer-2.18.12/configure.in new/yast2-printer-2.18.14/configure.in
--- old/yast2-printer-2.18.12/configure.in 2009-04-16 17:04:45.000000000 +0200
+++ new/yast2-printer-2.18.14/configure.in 2009-04-24 12:18:40.000000000 +0200
@@ -3,7 +3,7 @@
dnl -- This file is generated by y2autoconf 2.17.6 - DO NOT EDIT! --
dnl (edit configure.in.in instead)
-AC_INIT(yast2-printer, 2.18.12, http://bugs.opensuse.org/, yast2-printer)
+AC_INIT(yast2-printer, 2.18.14, http://bugs.opensuse.org/, yast2-printer)
dnl Check for presence of file 'RPMNAME'
AC_CONFIG_SRCDIR([RPMNAME])
@@ -18,7 +18,7 @@
AM_INIT_AUTOMAKE(tar-ustar -Wno-portability)
dnl Important YaST2 variables
-VERSION="2.18.12"
+VERSION="2.18.14"
RPMNAME="yast2-printer"
MAINTAINER="Michal Zugec "
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-printer-2.18.12/src/connectionwizard.ycp new/yast2-printer-2.18.14/src/connectionwizard.ycp
--- old/yast2-printer-2.18.12/src/connectionwizard.ycp 2009-04-16 16:57:36.000000000 +0200
+++ new/yast2-printer-2.18.14/src/connectionwizard.ycp 2009-04-24 12:18:37.000000000 +0200
@@ -208,20 +208,311 @@
case(`usb):
content = getContentFromBackend("usb");
break;
- case(`serial):
- content = getContentFromBackend("serial");
+ case(`hplip):
+ if( ! Printerlib::TestAndInstallPackage( "hplip", "installed" ) )
+ // Only a notification but no installation of HPLIP in the Connection Wizard.
+ // Installing the package hplip can pull in tons of required packages
+ // because the hplip package does not only provide the 'hp' backend but is a
+ // full featured multifunction solution with GUI for HP printers and all-in-one devices.
+ // HPLIP supports printing, scanning, faxing, photo card access, and device management.
+ // Additionally installing hplip can become very complicated (see driveradd.ycp).
+ // Therefore the Connection Wizard is not bloated with installing HPLIP.
+ { Popup::Message( // Popup::Message when the user had selected "HP Devices (HPLIP)"
+ // in the Connection Wizard but the RPM package hplip is not installed:
+ _("To access a HP device via the 'hp' backend,\nthe RPM package hplip must be installed.")
+ );
+ content = `VBox
+ ( `Left
+ ( `Label
+ ( _("The RPM package hplip is not installed.") )
+ )
+ );
+ break;
+ }
+ content = getContentFromBackend("hp");
break;
- case(`infra):
- content = getContentFromBackend("infra");
+ case(`serial):
+ content = `VBox
+ ( `Left
+ ( `ComboBox
+ ( `id(`serial_device_node),
+ // This ComboBox is editable because there could be
+ // any kind of serial device node name "/dev/whatever":
+ `opt(`editable),
+ // Label for an editable ComboBox where
+ // a serial device node (e.g. /dev/ttyS0 or /dev/ttyS1)
+ // can be selected or entered:
+ _("&Serial device"),
+ [ // Have nothing preselected to be on the safe side because
+ // the CUPS serial backend may blindly write to the device,
+ // (see backend/serial.c in the CUPS 1.3.9 sources):
+ `item( `id(""), "", true ),
+ `item( `id("/dev/ttyS0"), "/dev/ttyS0" ),
+ `item( `id("/dev/ttyS1"), "/dev/ttyS1" ),
+ `item( `id("/dev/ttyS2"), "/dev/ttyS2" ),
+ `item( `id("/dev/ttyS3"), "/dev/ttyS3" ),
+ `item( `id("/dev/ttyS4"), "/dev/ttyS4" ),
+ `item( `id("/dev/ttyS5"), "/dev/ttyS5" ),
+ `item( `id("/dev/ttyS6"), "/dev/ttyS6" ),
+ `item( `id("/dev/ttyS7"), "/dev/ttyS7" )
+ ]
+ )
+ ),
+ `Left
+ ( `ComboBox
+ ( `id(`serial_baud_rate),
+ // The backend/serial.c in the CUPS 1.3.9 sources
+ // supports only the preset values below.
+ // Nevertheless this ComboBox is editable to be future-proof:
+ `opt(`editable),
+ // Label for an editable ComboBox where
+ // the baud rate for a serial device
+ // can be selected or entered:
+ _("&Baud rate"),
+ // The preset values are from backend/serial.c
+ // in the CUPS 1.3.9 sources:
+ [ // Have nothing preselected to be on the safe side because the baud rate
+ // may have to be exactly what is set in the printer (e.g. via DIP switches):
+ `item( `id(""), "", true ),
+ `item( `id("1200"), "1200" ),
+ `item( `id("2400"), "2400" ),
+ `item( `id("4800"), "4800" ),
+ `item( `id("9600"), "9600" ),
+ `item( `id("19200"), "19200" ),
+ `item( `id("38400"), "38400" ),
+ `item( `id("57600"), "57600" ),
+ `item( `id("115200"), "115200" ),
+ `item( `id("230400"), "230400" )
+ ]
+ )
+ ),
+ `Left
+ ( `ComboBox
+ ( `id(`serial_data_bits),
+ // The backend/serial.c in the CUPS 1.3.9 sources
+ // supports only the preset values below (7 and 8).
+ // Nevertheless this ComboBox is editable to be future-proof
+ // because according to http://en.wikipedia.org/wiki/Serial_port
+ // a serial port might also have 5, 6, or 9 data bits.
+ `opt(`editable),
+ // Label for an editable ComboBox where
+ // the number of data bits for a serial device
+ // can be selected or entered:
+ _("&Data bits"),
+ // The preset values are from backend/serial.c
+ // in the CUPS 1.3.9 sources:
+ [ `item( `id(""), "", true ),
+ `item( `id("7"), "7" ),
+ `item( `id("8"), "8" )
+ ]
+ )
+ ),
+ `Left
+ ( `ComboBox
+ ( `id(`serial_parity),
+ // The backend/serial.c in the CUPS 1.3.9 sources
+ // supports only the preset values below.
+ // Nevertheless this ComboBox is editable to be future-proof:
+ `opt(`editable),
+ // Label for an editable ComboBox where
+ // the parity checking for a serial device
+ // can be selected or entered:
+ _("&Parity checking"),
+ // The preset values are from backend/serial.c
+ // in the CUPS 1.3.9 sources:
+ [ `item( `id(""), "", true ),
+ `item( `id("even"), "even" ),
+ `item( `id("odd"), "odd" ),
+ `item( `id("none"), "none" ),
+ `item( `id("space"), "space" ),
+ `item( `id("mark"), "mark" )
+ ]
+ )
+ ),
+ `Left
+ ( `ComboBox
+ ( `id(`serial_flow_control),
+ // The backend/serial.c in the CUPS 1.3.9 sources
+ // supports only the preset values below.
+ // Nevertheless this ComboBox is editable to be future-proof
+ // because according to http://en.wikipedia.org/wiki/Flow_control
+ // a serial port might also have another kind of flow control.
+ `opt(`editable),
+ // Label for an editable ComboBox where
+ // the flow control for a serial device
+ // can be selected or entered:
+ _("&Flow control"),
+ // The preset values are from backend/serial.c
+ // in the CUPS 1.3.9 sources:
+ [ `item( `id(""), "", true ),
+ `item( `id("none"), "none" ),
+ `item( `id("soft"), "XON/XOFF (software)" ),
+ `item( `id("hard"), "RTS/CTS (hardware)" ),
+ `item( `id("dtrdsr"), "DTR/DSR (hardware)" )
+ ]
+ )
+ ),
+ `Left
+ ( `ComboBox
+ ( `id(`serial_stop_bits),
+ // The backend/serial.c in the CUPS 1.3.9 sources
+ // supports only the preset values below.
+ // Nevertheless this ComboBox is editable to be future-proof:
+ `opt(`editable),
+ // Label for an editable ComboBox where
+ // the number of stop bits for a serial device
+ // can be selected or entered:
+ _("S&top bits"),
+ // The preset values are from backend/serial.c
+ // in the CUPS 1.3.9 sources:
+ [ `item( `id(""), "", true ),
+ `item( `id("1"), "1" ),
+ `item( `id("2"), "2" )
+ ]
+ )
+ ),
+ model_for_using_driver_content
+ );
break;
case(`bluetooth):
- content = getContentFromBackend("bluetooth");
+ if( ! Printerlib::TestAndInstallPackage( "bluez-cups", "installed" ) )
+ { if( Popup::ContinueCancel( _("To access a bluetooth printer, the RPM package bluez-cups must be installed.") ) )
+ { Printerlib::TestAndInstallPackage( "bluez-cups", "install" );
+ }
+ // The user can also decide during the actual installation not to install it
+ // or the installation may have failed for whatever reason
+ // so that we test again whether or not it is now actually installed:
+ if( ! Printerlib::TestAndInstallPackage( "bluez-cups", "installed" ) )
+ { content = `VBox
+ ( `Left
+ ( `Label
+ ( _("The RPM package bluez-cups is not installed.") )
+ )
+ );
+ break;
+ }
+ }
+ // Fallback message what the user may run manually when it fails
+ // to generate a valid list of bluetooth device IDs:
+ string bluetooth_device_list = _("It seems there are no bluetooth device IDs.\nRun 'hcitool scan' to get the bluetooth device IDs.\nEnter the ID without colons like '1A2B3C4D5E6F'.");
+ Popup::ShowFeedback( // No title for a simple busy message:
+ "",
+ // Busy message:
+ // Body of a Popup::ShowFeedback:
+ _("Retrieving bluetooth device IDs...")
+ );
+ // The command "hcitool scan" might need very much time or hang up.
+ // To kill exactly hcitool there is the workaround via the temporary file because
+ // hcitool scan | grep '...' & sleep 10 ; kill -9 $!
+ // would kill only grep and
+ // ( hcitool scan | grep '...' ) & sleep 10 ; kill -9 $!
+ // would kill only the sub shell.
+ if( ! Printerlib::ExecuteBashCommand( "hcitool scan >/tmp/hcitool_scan.out & sleep 10 ; kill -9 $! ; grep '..:..:..:..:..:..' /tmp/hcitool_scan.out | tr -s ' ' ; rm -f /tmp/hcitool_scan.out" ) )
+ { // Will probably never fail because the final "rm -f ..." should exit successfully in any case:
+ Popup::ErrorDetails( // Popup::ErrorDetails message:
+ _("Failed to get a list of bluetooth device IDs."),
+ "hcitool scan" + "\n" + Printerlib::result["stderr"]:""
+ );
+ }
+ else
+ { if( "" != Printerlib::result["stdout"]:"" )
+ { bluetooth_device_list = Printerlib::result["stdout"]:"";
+ }
+ }
+ Popup::ClearFeedback();
+ y2milestone( "bluetooth_device_list '%1'", bluetooth_device_list );
+ // Have an empty string preselected to be on the safe side because
+ // the bluetooth backend may blindly write to the device:
+ list <term> bluetooth_device_id_items = [ `item( `id(""), "", true ) ];
+ foreach( string word,
+ splitstring( bluetooth_device_list, " " ),
+ { if( regexpmatch( word, "..:..:..:..:..:..") )
+ { // A bluetooth device ID has the form 1A:2B:3C:4D:5E:6F
+ // but the bluetooth backend needs it without the colons ':'
+ // in its DeviceURI which has the form bluetooth://1A2B3C4D5E6F
+ string hexnumber = filterchars( word, "0123456789ABCDEFabcdef" );
+ if( "" != hexnumber )
+ { bluetooth_device_id_items = add( bluetooth_device_id_items, `item( `id( hexnumber ), hexnumber ) );
+ }
+ }
+ }
+ );
+ content = `VBox
+ ( `Left
+ ( `ComboBox
+ ( `id(`bluetooth_device_id),
+ `opt(`editable),
+ // Label for an editable ComboBox where
+ // a bluetooth device ID
+ // can be selected or entered:
+ _("&Bluetooth device ID"),
+ bluetooth_device_id_items
+ )
+ ),
+ `Left
+ ( `Frame
+ ( // TRANSLATORS: Frame label for a list of bluetooth device IDs:
+ _("Currently available bluetooth device IDs"),
+ // The RichText widget is required here to get scroll bars if needed
+ // (a Label cuts the content because it does not provide scroll bars):
+ `RichText( "<pre>" + bluetooth_device_list + "</pre>" )
+ )
+ ),
+ model_for_using_driver_content
+ );
break;
case(`scsi):
- content = getContentFromBackend("scsi");
- break;
- case(`hplip):
- content = getContentFromBackend("hp");
+ // Fallback message what the user may run manually when it fails
+ // to generate the current list of SCSI generic device nodes:
+ string scsi_device_list = _("It seems there are no SCSI generic devices (/dev/sg...).\nRun 'lsscsi -g' to get a list of SCSI generic devices.");
+ if( ! Printerlib::ExecuteBashCommand( "lsscsi -g | tr -s ' ' | cut -s -d ' ' -f 3- | grep '/dev/sg' || echo 'no SCSI generic device found' 1>&2" ) )
+ { // Will probably never fail because the final "echo" should exit successfully in any case:
+ Popup::ErrorDetails( // Popup::ErrorDetails message:
+ _("Failed to get a list of SCSI generic devices."),
+ "lsscsi -g" + "\n" + Printerlib::result["stderr"]:""
+ );
+ }
+ else
+ { if( "" != Printerlib::result["stdout"]:"" )
+ { scsi_device_list = Printerlib::result["stdout"]:"";
+ }
+ }
+ y2milestone( "scsi_device_list '%1'", scsi_device_list );
+ content = `VBox
+ ( `Left
+ ( `ComboBox
+ ( `id(`scsi_device_node),
+ `opt(`editable),
+ // Label for an editable ComboBox where
+ // a SCSI generic device node (e.g. /dev/sg0 or /dev/sg1)
+ // can be selected or entered:
+ _("&SCSI generic device"),
+ [ // Have nothing preselected to be on the safe side because
+ // the CUPS scsi backend may blindly write to the device,
+ // (see backend/scsi-linux.c in the CUPS 1.3.9 sources):
+ `item( `id(""), "", true ),
+ `item( `id("/dev/sg0"), "/dev/sg0" ),
+ `item( `id("/dev/sg1"), "/dev/sg1" ),
+ `item( `id("/dev/sg2"), "/dev/sg2" ),
+ `item( `id("/dev/sg3"), "/dev/sg3" ),
+ `item( `id("/dev/sg4"), "/dev/sg4" ),
+ `item( `id("/dev/sg5"), "/dev/sg5" ),
+ `item( `id("/dev/sg6"), "/dev/sg6" ),
+ `item( `id("/dev/sg7"), "/dev/sg7" )
+ ]
+ )
+ ),
+ `Left
+ ( `Frame
+ ( // TRANSLATORS: Frame label for a list of SCSI generic devices:
+ _("Currently available SCSI generic devices"),
+ // The RichText widget is required here to get scroll bars if needed
+ // (a Label cuts the content because it does not provide scroll bars):
+ `RichText( "<pre>" + scsi_device_list + "</pre>" )
+ )
+ ),
+ model_for_using_driver_content
+ );
break;
// network printer
case(`tcp):
@@ -261,6 +552,23 @@
break;
// print via
case(`smb):
+ if( ! Printerlib::TestAndInstallPackage( "samba-client", "installed" ) )
+ { if( Popup::ContinueCancel( _("To access a SMB printer share, the RPM package samba-client must be installed.") ) )
+ { Printerlib::TestAndInstallPackage( "samba-client", "install" );
+ }
+ // The user can also decide during the actual installation not to install it
+ // or the installation may have failed for whatever reason
+ // so that we test again whether or not it is now actually installed:
+ if( ! Printerlib::TestAndInstallPackage( "samba-client", "installed" ) )
+ { content = `VBox
+ ( `Left
+ ( `Label
+ ( _("The RPM package samba-client is not installed.") )
+ )
+ );
+ break;
+ }
+ }
content = `VBox
( `Left
( `HBox
@@ -375,6 +683,23 @@
);
break;
case(`ipx):
+ if( ! Printerlib::TestAndInstallPackage( "ncpfs", "installed" ) )
+ { if( Popup::ContinueCancel( _("To access an IPX print queue, the RPM package ncpfs must be installed.") ) )
+ { Printerlib::TestAndInstallPackage( "ncpfs", "install" );
+ }
+ // The user can also decide during the actual installation not to install it
+ // or the installation may have failed for whatever reason
+ // so that we test again whether or not it is now actually installed:
+ if( ! Printerlib::TestAndInstallPackage( "ncpfs", "installed" ) )
+ { content = `VBox
+ ( `Left
+ ( `Label
+ ( _("The RPM package ncpfs is not installed.") )
+ )
+ );
+ break;
+ }
+ }
content = `VBox
( `Left
( `InputField
@@ -434,6 +759,23 @@
);
break;
case(`pipe):
+ if( ! Printerlib::TestAndInstallPackage( "cups-backends", "installed" ) )
+ { if( Popup::ContinueCancel( _("To print via 'pipe', the RPM package cups-backends must be installed.") ) )
+ { Printerlib::TestAndInstallPackage( "cups-backends", "install" );
+ }
+ // The user can also decide during the actual installation not to install it
+ // or the installation may have failed for whatever reason
+ // so that we test again whether or not it is now actually installed:
+ if( ! Printerlib::TestAndInstallPackage( "cups-backends", "installed" ) )
+ { content = `VBox
+ ( `Left
+ ( `Label
+ ( _("The RPM package cups-backends is not installed.") )
+ )
+ );
+ break;
+ }
+ }
content = `VBox
( `Left
( `InputField
@@ -446,6 +788,23 @@
);
break;
case(`beh):
+ if( ! Printerlib::TestAndInstallPackage( "cups-backends", "installed" ) )
+ { if( Popup::ContinueCancel( _("To use 'beh', the RPM package cups-backends must be installed.") ) )
+ { Printerlib::TestAndInstallPackage( "cups-backends", "install" );
+ }
+ // The user can also decide during the actual installation not to install it
+ // or the installation may have failed for whatever reason
+ // so that we test again whether or not it is now actually installed:
+ if( ! Printerlib::TestAndInstallPackage( "cups-backends", "installed" ) )
+ { content = `VBox
+ ( `Left
+ ( `Label
+ ( _("The RPM package cups-backends is not installed.") )
+ )
+ );
+ break;
+ }
+ }
model_content = getContentFromCurrentModel();
content = `VBox
( `Left
@@ -497,7 +856,7 @@
default:
y2error( "Unknown selected item %1", selected );
}
- UI::ReplaceWidget( `rp, content );
+ UI::ReplaceWidget( `connection_settings_replace_point, content );
}
any ConnectionWizardDialog()
@@ -520,14 +879,13 @@
// TRANSLATORS: Tree widget item
`item(`id(`usb), _("USB Port") ),
// TRANSLATORS: Tree widget item
+ `item( `id(`hplip), _("HP Devices (HPLIP)") ),
+ // TRANSLATORS: Tree widget item
`item( `id(`serial), _("Serial Port") ),
- // `item( `id(`infra), _("Infrared Port (IrDA)") ),
// TRANSLATORS: Tree widget item
`item( `id(`bluetooth), _("Bluetooth") ),
// TRANSLATORS: Tree widget item
- `item( `id(`scsi), _("SCSI") ),
- // TRANSLATORS: Tree widget item
- `item( `id(`hplip), _("HP Devices (HPLIP)") )
+ `item( `id(`scsi), _("SCSI") )
]
),
`item
@@ -582,7 +940,7 @@
`Frame
( // TRANSLATORS: Connection details widget
_("Connection Settings"),
- `ReplacePoint( `id(`rp),
+ `ReplacePoint( `id(`connection_settings_replace_point),
`VBox
( `Left
( `Label
@@ -625,10 +983,6 @@
switch(type)
{ case(`parallel):
case(`usb):
- case(`serial):
- case(`infra):
- case(`bluetooth):
- case(`scsi):
case(`hplip):
integer selected_connection_index = (integer)UI::QueryWidget( `id(`connection_selection), `CurrentItem );
if( nil == selected_connection_index )
@@ -645,19 +999,99 @@
{ valid = true;
}
break;
+ case(`serial):
+ string serial_device_node = (string)UI::QueryWidget( `serial_device_node, `Value );
+ string serial_baud_rate = (string)UI::QueryWidget( `serial_baud_rate, `Value );
+ string serial_data_bits = (string)UI::QueryWidget( `serial_data_bits, `Value );
+ string serial_parity = (string)UI::QueryWidget( `serial_parity, `Value );
+ string serial_flow_control = (string)UI::QueryWidget( `serial_flow_control, `Value );
+ string serial_stop_bits = (string)UI::QueryWidget( `serial_stop_bits, `Value );
+ if( size( serial_device_node ) == 0
+ || size( serial_baud_rate ) == 0
+ )
+ { Popup::Error( _("Serial device and baud rate could not be empty.") );
+ }
+ else
+ { if( "space" == serial_parity && "7" != serial_data_bits )
+ { Popup::Error( _("The 'space' parity checking is only supported with 7 data bits.") );
+ }
+ else
+ { if( "mark" == serial_parity && "7" != serial_data_bits && "1" != serial_stop_bits )
+ { Popup::Error( _("The 'mark' parity checking is only supported with 7 data bits and 1 stop bit.") );
+ }
+ else
+ { connection_uri = "serial:" + serial_device_node + "?baud=" + serial_baud_rate;
+ if( size( serial_data_bits ) > 0 )
+ { connection_uri = connection_uri + "+bits=" + serial_data_bits;
+ }
+ if( size( serial_parity ) > 0 )
+ { connection_uri = connection_uri + "+parity=" + serial_parity;
+ }
+ if( size( serial_flow_control ) > 0 )
+ { connection_uri = connection_uri + "+flow=" + serial_flow_control;
+ }
+ if( size( serial_stop_bits ) > 0 )
+ { connection_uri = connection_uri + "+stop=" + serial_stop_bits;
+ }
+ valid = true;
+ }
+ }
+ }
+ if( valid )
+ { connection_model = (string)UI::QueryWidget( `id("manufacturers_combo_box"), `Value );
+ if( "" == connection_model )
+ { valid = false;
+ Popup::Error( _("Select a manufacturer.") );
+ }
+ }
+ break;
+ case(`bluetooth):
+ string bluetooth_device_id = (string)UI::QueryWidget( `bluetooth_device_id, `Value );
+ if( size( bluetooth_device_id ) == 0 )
+ { Popup::Error( _("Bluetooth device ID could not be empty.") );
+ }
+ else
+ { connection_uri = "bluetooth://" + bluetooth_device_id;
+ valid = true;
+ }
+ if( valid )
+ { connection_model = (string)UI::QueryWidget( `id("manufacturers_combo_box"), `Value );
+ if( "" == connection_model )
+ { valid = false;
+ Popup::Error( _("Select a manufacturer.") );
+ }
+ }
+ break;
+ case(`scsi):
+ string scsi_device_node = (string)UI::QueryWidget( `scsi_device_node, `Value );
+ if( size( scsi_device_node ) == 0 )
+ { Popup::Error( _("SCSI generic device could not be empty.") );
+ }
+ else
+ { connection_uri = "scsi:" + scsi_device_node;
+ valid = true;
+ }
+ if( valid )
+ { connection_model = (string)UI::QueryWidget( `id("manufacturers_combo_box"), `Value );
+ if( "" == connection_model )
+ { valid = false;
+ Popup::Error( _("Select a manufacturer.") );
+ }
+ }
+ break;
case(`uri):
connection_uri = (string)UI::QueryWidget( `uri, `Value );
if( size( connection_uri ) > 0 )
{ valid = true;
}
else
- { Popup::Error( _("URI couldn't be empty!") );
+ { Popup::Error( _("URI could not be empty.") );
}
if( valid )
{ connection_model = (string)UI::QueryWidget( `id("manufacturers_combo_box"), `Value );
if( "" == connection_model )
{ valid = false;
- Popup::Error( _("Select a manufacturer!") );
+ Popup::Error( _("Select a manufacturer.") );
}
}
break;
@@ -667,13 +1101,13 @@
{ valid = true;
}
else
- { Popup::Error( _("URI couldn't be empty!") );
+ { Popup::Error( _("URI could not be empty.") );
}
if( valid )
{ connection_model = (string)UI::QueryWidget( `id("manufacturers_combo_box"), `Value );
if( "" == connection_model )
{ valid = false;
- Popup::Error( _("Select a manufacturer!") );
+ Popup::Error( _("Select a manufacturer.") );
}
}
break;
@@ -687,13 +1121,13 @@
if( size( smb["hostname"]:"" ) == 0
|| size( smb["printer"]:"" ) == 0
)
- { Popup::Error( _("Servername and printer couldn't be empty!") );
+ { Popup::Error( _("Servername and printer could not be empty.") );
}
else
{ if( ( size( smb["user"]:"" ) > 0 && size( smb["pass"]:"" ) == 0 )
|| ( size( smb["user"]:"" ) == 0 && size( smb["pass"]:"" ) > 0 )
)
- { Popup::Error( _("Both user and password must be specified!") );
+ { Popup::Error( _("Both user and password must be specified.") );
}
else
{ connection_uri = "smb://";
@@ -724,7 +1158,7 @@
{ connection_model = (string)UI::QueryWidget( `id("manufacturers_combo_box"), `Value );
if( "" == connection_model )
{ valid = false;
- Popup::Error( _("Select a manufacturer!") );
+ Popup::Error( _("Select a manufacturer.") );
}
}
break;
@@ -739,13 +1173,13 @@
valid = true;
}
else
- { Popup::Error( _("Servername and port couldn't be empty!") );
+ { Popup::Error( _("Servername and port could not be empty.") );
}
if( valid )
{ connection_model = (string)UI::QueryWidget( `id("manufacturers_combo_box"), `Value );
if( "" == connection_model )
{ valid = false;
- Popup::Error( _("Select a manufacturer!") );
+ Popup::Error( _("Select a manufacturer.") );
}
}
break;
@@ -760,13 +1194,13 @@
valid=true;
}
else
- { Popup::Error( _("Servername and queue name couldn't be empty!") );
+ { Popup::Error( _("Servername and queue name could not be empty.") );
}
if( valid )
{ connection_model = (string)UI::QueryWidget( `id("manufacturers_combo_box"), `Value );
if( "" == connection_model )
{ valid = false;
- Popup::Error( _("Select a manufacturer!") );
+ Popup::Error( _("Select a manufacturer.") );
}
}
break;
@@ -781,13 +1215,13 @@
valid=true;
}
else
- { Popup::Error( _("Servername and queue name couldn't be empty!") );
+ { Popup::Error( _("Servername and queue name could not be empty.") );
}
if( valid )
{ connection_model = (string)UI::QueryWidget( `id("manufacturers_combo_box"), `Value );
if( "" == connection_model )
{ valid = false;
- Popup::Error( _("Select a manufacturer!") );
+ Popup::Error( _("Select a manufacturer.") );
}
}
break;
@@ -802,13 +1236,13 @@
valid=true;
}
else
- { Popup::Error( _("Servername and queue name couldn't be empty!") );
+ { Popup::Error( _("Servername and queue name could not be empty.") );
}
if( valid )
{ connection_model = (string)UI::QueryWidget( `id("manufacturers_combo_box"), `Value );
if( "" == connection_model )
{ valid = false;
- Popup::Error( _("Select a manufacturer!") );
+ Popup::Error( _("Select a manufacturer.") );
}
}
break;
@@ -822,7 +1256,7 @@
if( size( ipx["hostname"]:"" ) == 0
|| size( ipx["queue"]:"" ) == 0
)
- { Popup::Error( _("Servername and queue name couldn't be empty!") );
+ { Popup::Error( _("Servername and queue name could not be empty.") );
}
else
{ connection_uri = "novell://";
@@ -838,7 +1272,7 @@
{ connection_model = (string)UI::QueryWidget( `id("manufacturers_combo_box"), `Value );
if( "" == connection_model )
{ valid=false;
- Popup::Error( _("Select a manufacturer!") );
+ Popup::Error( _("Select a manufacturer.") );
}
}
break;
@@ -853,7 +1287,7 @@
|| size( beh["attempts"]:"" ) == 0
|| size( beh["delay"]:"" ) == 0
)
- { Popup::Error( _("Device URI, number of retries, and delay couldn't be empty!" ) );
+ { Popup::Error( _("Device URI, number of retries, and delay could not be empty." ) );
}
else
{ connection_uri = sformat( "beh:/%1/%2/%3/%4",
@@ -868,7 +1302,7 @@
{ connection_model = (string)UI::QueryWidget( `id("manufacturers_combo_box"), `Value );
if( "" == connection_model )
{ valid = false;
- Popup::Error( _("Select a manufacturer!") );
+ Popup::Error( _("Select a manufacturer.") );
}
}
break;
@@ -879,13 +1313,13 @@
valid = true;
}
else
- { Popup::Error( _("Couldn't be empty!") );
+ { Popup::Error( _("Could not be empty.") );
}
if( valid )
{ connection_model = (string)UI::QueryWidget( `id("manufacturers_combo_box"), `Value );
if( "" == connection_model )
{ valid = false;
- Popup::Error( _("Select a manufacturer!") );
+ Popup::Error( _("Select a manufacturer.") );
}
}
break;
@@ -1108,7 +1542,7 @@
storeQueue( selected );
}
else
- { y2error( "Couldn't validate %1", selected );
+ { y2error( "Could not validate %1", selected );
ret=nil;
}
break;
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-printer-2.18.12/src/helps.ycp new/yast2-printer-2.18.14/src/helps.ycp
--- old/yast2-printer-2.18.12/src/helps.ycp 2009-04-16 16:57:36.000000000 +0200
+++ new/yast2-printer-2.18.14/src/helps.ycp 2009-04-23 18:38:08.000000000 +0200
@@ -410,7 +410,23 @@
hp:/usb/HP_LaserJet?serial=1234<br>
Usually only the autogenerated device URIs work.
When the device is not autodetected, there is usually no communication
-with the device possible and no data can be sent to the device.
+with the device possible and no data can be sent to the device.<br>
+To access a HP printer or all-in-one device via the backend 'hp',
+the RPM package hplip must be installed.
+The package provides HP's printing and scanning software HPLIP.<br>
+In contrast devices which are connected via serial port, bluetooth,
+or SCSI are usually not autodetected so that the device URI must be
+manually specified.
+The serial device URI parameters must comply with
+what the serial port in the printer requires,
+see the manual of your serial printer.
+Example device URIs:<br>
+serial:/dev/ttyS9?baud=9600+bits=8+parity=none+flow=soft+stop=1<br>
+bluetooth://1A2B3C4D5E6F<br>
+scsi:/dev/sg9<br>
+To access a device via bluetooth, the RPM package bluez-cups must be installed.
+The package provides the CUPS backend 'bluetooth' which actually sends the data
+to a bluetooth printer.
</p>") +
// ConnectionWizardDialog help 4/6:
_("<p>
@@ -458,6 +474,10 @@
Ask your network administrator what which print server machine
provides in your particular network:<br>
<b>Microsoft Windows/SAMBA (SMB/CIFS)</b><br>
+To access a SMB printer share, the RPM package samba-client must be installed.
+The package provides the CUPS backend 'smb' which is a link to
+the <tt>/usr/bin/smbspool</tt> program which actually sends the data
+to a SMB printer share.
A server name and a printer share name and optionally a workgroup name
is needed to access it.
Furthermore a user name and a password may be required to get access.
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-printer-2.18.12/src/overview.ycp new/yast2-printer-2.18.14/src/overview.ycp
--- old/yast2-printer-2.18.12/src/overview.ycp 2009-04-16 17:00:00.000000000 +0200
+++ new/yast2-printer-2.18.14/src/overview.ycp 2009-04-23 16:28:29.000000000 +0200
@@ -442,18 +442,31 @@
+ "-[0-9]+'"
)
)
- { if( Popup::AnyQuestion( // Header of a confirmation popup before all pending jobs in a queue will be deleted:
- _("Delete Pending Print Jobs"),
- // Body of a confirmation popup before a queue will be deleted:
- _("There are pending print jobs which might be deleted before the testpage is printed."),
- // 'Yes' button label of a confirmation popup
- // before all pending jobs in a queue will be deleted:
- sformat( _("Delete all pending jobs for %1"), queue_name ),
- // 'No' button label of a confirmation popup
- // before all pending jobs in a queue will be deleted:
- _("Print the testpage after the other jobs"),
- `focus_no
- )
+ { // Fallback body of a confirmation popup before pending print jobs will be deleted:
+ string pending_job_info = _("There are pending print jobs which might be deleted before the testpage is printed.");
+ if( Printerlib::ExecuteBashCommand( "/usr/bin/lpstat -h localhost -o '"
+ + queue_name
+ + "' -p '"
+ + queue_name
+ + "'"
+ )
+ )
+ { pending_job_info = Printerlib::result["stdout"]:"";
+ }
+ if( Popup::AnyQuestionRichText( // Header of a confirmation popup before pending print jobs will be deleted
+ // where %1 will be replaced by the queue name.
+ sformat( _("Delete Pending Print Jobs For %1"), queue_name ),
+ "<pre>" + pending_job_info + "</pre>",
+ 70,
+ 20,
+ // 'Yes' button label of a confirmation popup
+ // before all pending jobs in a queue will be deleted:
+ _("Delete them before printing testpage"),
+ // 'No' button label of a confirmation popup
+ // before all pending jobs in a queue will be deleted:
+ _("Print testpage after the other jobs"),
+ `focus_no
+ )
)
{ if( ! Printerlib::ExecuteBashCommand( "/usr/bin/cancel -a -h localhost '" + queue_name + "'" ) )
{ Popup::ErrorDetails( sformat( // Message of a Popup::ErrorDetails
@@ -527,18 +540,31 @@
+ "-[0-9]+'"
)
)
- { if( Popup::AnyQuestion( // Header of a confirmation popup before all pending jobs in a queue will be deleted:
- _("Delete Pending Print Jobs"),
- // Body of a confirmation popup before a queue will be deleted:
- _("There are pending print jobs which might be deleted now."),
- // 'Yes' button label of a confirmation popup
- // before all pending jobs in a queue will be deleted:
- sformat( _("Delete all pending jobs for %1"), queue_name ),
- // 'No' button label of a confirmation popup
- // before all pending jobs in a queue will be deleted:
- _("Do not delete them"),
- `focus_no
- )
+ { // Fallback body of a confirmation popup before pending print jobs will be deleted:
+ string pending_job_info = _("There are pending print jobs which might be deleted now.");
+ if( Printerlib::ExecuteBashCommand( "/usr/bin/lpstat -h localhost -o '"
+ + queue_name
+ + "' -p '"
+ + queue_name
+ + "'"
+ )
+ )
+ { pending_job_info = Printerlib::result["stdout"]:"";
+ }
+ if( Popup::AnyQuestionRichText( // Header of a confirmation popup before pending print jobs will be deleted
+ // where %1 will be replaced by the queue name.
+ sformat( _("Delete Pending Print Jobs For %1"), queue_name ),
+ "<pre>" + pending_job_info + "</pre>",
+ 70,
+ 20,
+ // 'Yes' button label of a confirmation popup
+ // before all pending jobs in a queue will be deleted:
+ _("Delete all pending jobs"),
+ // 'No' button label of a confirmation popup
+ // before all pending jobs in a queue will be deleted:
+ _("Do not delete them"),
+ `focus_no
+ )
)
{ if( ! Printerlib::ExecuteBashCommand( "/usr/bin/cancel -a -h localhost '" + queue_name + "'" ) )
{ Popup::ErrorDetails( sformat( // Message of a Popup::ErrorDetails
@@ -553,7 +579,9 @@
// Deal with the backend process regardless whether or not
// the above cancel command was successful because
// killing the backend process is an emergency brake
- // when something is really wrong:
+ // when something is really wrong.
+ // Sleep 1 second in any case to let the backend process terminate orderly:
+ sleep( 1000 );
string backend_is_running_commandline = "ps -C '"
+ uri_scheme
+ "' -o pid=,args= | grep '"
@@ -562,8 +590,8 @@
// Do nothing to be on the safe side if the next command fails for whatever reason:
if( Printerlib::ExecuteBashCommand( backend_is_running_commandline ) )
{ // A matching backend process is running.
- // Sleep 10 seconds to let the backend process terminate orderly
- // when the filters have finished because of the above cancel command.
+ // Sleep 10 seconds to give the backend process more time to terminate orderly
+ // which may still wait for the filters to finish because of the above cancel command.
// There is no user feedback while waiting here because I assume that
// the user expects that it takes a bit of time to delete all pending jobs.
sleep( 10000 );
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-printer-2.18.12/src/policies.ycp new/yast2-printer-2.18.14/src/policies.ycp
--- old/yast2-printer-2.18.12/src/policies.ycp 2009-04-16 16:57:36.000000000 +0200
+++ new/yast2-printer-2.18.14/src/policies.ycp 2009-04-23 16:28:29.000000000 +0200
@@ -67,11 +67,11 @@
( `ComboBox
( `id("error_policy"),
// Header for a ComboBox to specify the CUPS error policy:
- _("Specify the &error policy"),
- [ `item( `id("stop-printer"), error_policy_stop_printer_string ),
- `item( `id("retry-job"), error_policy_retry_job_string ),
- `item( `id("abort-job"), error_policy_abort_job_string ),
- ]
+ _("Specify the &error policy"),
+ [ `item( `id("stop-printer"), error_policy_stop_printer_string ),
+ `item( `id("retry-job"), error_policy_retry_job_string ),
+ `item( `id("abort-job"), error_policy_abort_job_string )
+ ]
)
),
`Left
@@ -90,8 +90,8 @@
( `ComboBox
( `id("operation_policy"),
// Header for a ComboBox to specify the CUPS operation policy:
- _("Specify the &operation policy"),
- [""]
+ _("Specify the &operation policy"),
+ [""]
)
),
`Left
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-printer-2.18.12/VERSION new/yast2-printer-2.18.14/VERSION
--- old/yast2-printer-2.18.12/VERSION 2009-04-16 17:00:09.000000000 +0200
+++ new/yast2-printer-2.18.14/VERSION 2009-04-23 16:28:52.000000000 +0200
@@ -1 +1 @@
-2.18.12
+2.18.14
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Remember to have fun...
--
To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org
For additional commands, e-mail: opensuse-commit+help@opensuse.org