[yast-commit] r56961 - in /trunk/printer: VERSION package/yast2-printer.changes src/connectionwizard.ycp src/helps.ycp
Author: jsmeix Date: Fri Apr 24 12:33:14 2009 New Revision: 56961 URL: http://svn.opensuse.org/viewcvs/yast?rev=56961&view=rev Log: - 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 Modified: trunk/printer/VERSION trunk/printer/package/yast2-printer.changes trunk/printer/src/connectionwizard.ycp trunk/printer/src/helps.ycp Modified: trunk/printer/VERSION URL: http://svn.opensuse.org/viewcvs/yast/trunk/printer/VERSION?rev=56961&r1=56960&r2=56961&view=diff ============================================================================== --- trunk/printer/VERSION (original) +++ trunk/printer/VERSION Fri Apr 24 12:33:14 2009 @@ -1 +1 @@ -2.18.13 +2.18.14 Modified: trunk/printer/package/yast2-printer.changes URL: http://svn.opensuse.org/viewcvs/yast/trunk/printer/package/yast2-printer.changes?rev=56961&r1=56960&r2=56961&view=diff ============================================================================== --- trunk/printer/package/yast2-printer.changes (original) +++ trunk/printer/package/yast2-printer.changes Fri Apr 24 12:33:14 2009 @@ -1,4 +1,12 @@ ------------------------------------------------------------------- +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 Modified: trunk/printer/src/connectionwizard.ycp URL: http://svn.opensuse.org/viewcvs/yast/trunk/printer/src/connectionwizard.ycp?rev=56961&r1=56960&r2=56961&view=diff ============================================================================== --- trunk/printer/src/connectionwizard.ycp (original) +++ trunk/printer/src/connectionwizard.ycp Fri Apr 24 12:33:14 2009 @@ -209,6 +209,26 @@ content = getContentFromBackend("usb"); break; 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(`serial): @@ -325,11 +345,10 @@ // The preset values are from backend/serial.c // in the CUPS 1.3.9 sources: [ `item( `id(""), "", true ), - `item( `id("soft"), "soft" ), - `item( `id("hard"), "hard" ), `item( `id("none"), "none" ), - `item( `id("rtscts"), "rtscts" ), - `item( `id("dtrdsr"), "dtrdsr" ) + `item( `id("soft"), "XON/XOFF (software)" ), + `item( `id("hard"), "RTS/CTS (hardware)" ), + `item( `id("dtrdsr"), "DTR/DSR (hardware)" ) ] ) ), @@ -356,9 +375,26 @@ ); break; case(`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 = _("Run 'hcitool scan' to get a 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: @@ -428,9 +464,10 @@ case(`scsi): // 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 = _("Run 'lsscsi -g' to get a list of SCSI generic devices (/dev/sg...)."); - if( ! Printerlib::ExecuteBashCommand( "lsscsi -g | tr -s ' ' | cut -s -d ' ' -f 3- | grep '/dev/sg'" ) ) - { Popup::ErrorDetails( // Popup::ErrorDetails message: + 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"]:"" ); @@ -515,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 @@ -629,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 @@ -688,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 @@ -700,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 @@ -911,8 +1016,8 @@ { Popup::Error( _("The 'space' parity checking is only supported with 7 data bits.") ); } else - { if( "mark" == serial_parity && "7" != serial_data_bits ) - { Popup::Error( _("The 'mark' parity checking is only supported with 7 data bits.") ); + { 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; Modified: trunk/printer/src/helps.ycp URL: http://svn.opensuse.org/viewcvs/yast/trunk/printer/src/helps.ycp?rev=56961&r1=56960&r2=56961&view=diff ============================================================================== --- trunk/printer/src/helps.ycp (original) +++ trunk/printer/src/helps.ycp Fri Apr 24 12:33:14 2009 @@ -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. -- To unsubscribe, e-mail: yast-commit+unsubscribe@opensuse.org For additional commands, e-mail: yast-commit+help@opensuse.org
participants (1)
-
jsmeix@svn.opensuse.org