summaryrefslogtreecommitdiff
path: root/vcl
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2014-03-21 10:03:06 +0000
committerCaolán McNamara <caolanm@redhat.com>2014-03-21 11:23:02 +0000
commit1d81ca98f8d10431ea69eef71d8f633c27648743 (patch)
treea54ab72c2e41bc255b9526ddcae98ed33fa12447 /vcl
parentf6cd982a68528ac1bfd130080cea3f96e6cc7edd (diff)
move remaining padmin dialogs into vcl
and so padmin is no more Change-Id: I554cefa8b38581daad8a78bafa167448b0a0ef61
Diffstat (limited to 'vcl')
-rw-r--r--vcl/Library_vcl.mk10
-rw-r--r--vcl/Library_vclplug_gen.mk1
-rw-r--r--vcl/UIConfig_vcl.mk3
-rw-r--r--vcl/generic/print/genprnpsp.cxx38
-rw-r--r--vcl/generic/print/prtsetup.cxx487
-rw-r--r--vcl/generic/print/prtsetup.hxx129
-rw-r--r--vcl/inc/cupsmgr.hxx2
-rw-r--r--vcl/inc/svids.hrc1
-rw-r--r--vcl/source/src/print.src5
-rw-r--r--vcl/uiconfig/ui/printerdevicepage.ui209
-rw-r--r--vcl/uiconfig/ui/printerpaperpage.ui134
-rw-r--r--vcl/uiconfig/ui/printerpropertiesdialog.ui104
-rw-r--r--vcl/unx/generic/printer/printerinfomanager.cxx8
13 files changed, 1080 insertions, 51 deletions
diff --git a/vcl/Library_vcl.mk b/vcl/Library_vcl.mk
index e605343cb943..d7c13f184298 100644
--- a/vcl/Library_vcl.mk
+++ b/vcl/Library_vcl.mk
@@ -463,6 +463,7 @@ vcl_generic_code= \
vcl/generic/print/psputil \
vcl/generic/print/genpspgraphics \
vcl/generic/print/genprnpsp \
+ vcl/generic/print/prtsetup \
vcl/generic/print/text_gfx \
vcl/generic/fontmanager/fontsubst \
vcl/generic/glyphs/gcach_ftyp \
@@ -490,9 +491,6 @@ vcl_headless_freetype_code=\
vcl/headless/svptext \
ifeq ($(GUIBASE),unx)
-$(eval $(call gb_Library_add_defs,vcl,\
- -D_XSALSET_LIBNAME=\"$(call gb_Library_get_runtime_filename,spa)\" \
-))
$(eval $(call gb_Library_add_exception_objects,vcl,\
$(vcl_generic_code) \
vcl/unx/generic/plugadapt/salplug \
@@ -515,9 +513,6 @@ $(eval $(call gb_Library_use_externals,vcl,\
endif
ifeq ($(ENABLE_HEADLESS),TRUE)
-$(eval $(call gb_Library_add_defs,vcl,\
- -D_XSALSET_LIBNAME=\"$(call gb_Library_get_runtime_filename,spa)\" \
-))
$(eval $(call gb_Library_add_exception_objects,vcl,\
$(vcl_generic_code) \
vcl/unx/generic/printer/jobdata \
@@ -544,9 +539,6 @@ $(eval $(call gb_Library_add_libs,vcl,\
-landroid \
-llo-bootstrap \
))
-$(eval $(call gb_Library_add_defs,vcl,\
- -D_XSALSET_LIBNAME=\"$(call gb_Library_get_runtime_filename,spa)\" \
-))
$(eval $(call gb_Library_add_exception_objects,vcl,\
$(vcl_generic_code) \
vcl/unx/generic/printer/jobdata \
diff --git a/vcl/Library_vclplug_gen.mk b/vcl/Library_vclplug_gen.mk
index 51dd69224049..23900200491c 100644
--- a/vcl/Library_vclplug_gen.mk
+++ b/vcl/Library_vclplug_gen.mk
@@ -101,7 +101,6 @@ $(eval $(call gb_Library_add_exception_objects,vclplug_gen,\
# into their own library I think.
$(eval $(call gb_Library_add_defs,vclplug_gen,\
- -D_XSALSET_LIBNAME=\"$(call gb_Library_get_runtime_filename,spa)\" \
-DVCLPLUG_GEN_IMPLEMENTATION \
))
diff --git a/vcl/UIConfig_vcl.mk b/vcl/UIConfig_vcl.mk
index f2937b531e49..a81b30ed497a 100644
--- a/vcl/UIConfig_vcl.mk
+++ b/vcl/UIConfig_vcl.mk
@@ -14,6 +14,9 @@ $(eval $(call gb_UIConfig_add_uifiles,vcl,\
vcl/uiconfig/ui/errornocontentdialog \
vcl/uiconfig/ui/errornoprinterdialog \
vcl/uiconfig/ui/printdialog \
+ vcl/uiconfig/ui/printerdevicepage \
+ vcl/uiconfig/ui/printerpaperpage \
+ vcl/uiconfig/ui/printerpropertiesdialog \
vcl/uiconfig/ui/printprogressdialog \
vcl/uiconfig/ui/querydialog \
))
diff --git a/vcl/generic/print/genprnpsp.cxx b/vcl/generic/print/genprnpsp.cxx
index a60e5b66fa4c..d6e891192e2e 100644
--- a/vcl/generic/print/genprnpsp.cxx
+++ b/vcl/generic/print/genprnpsp.cxx
@@ -39,8 +39,6 @@
#include "rtl/ustring.hxx"
-#include "osl/module.h"
-
#include "vcl/button.hxx"
#include "vcl/dialog.hxx"
#include "vcl/edit.hxx"
@@ -58,6 +56,7 @@
#include "jobset.h"
#include "print.h"
+#include "prtsetup.hxx"
#include "salptype.hxx"
#include <com/sun/star/beans/PropertyValue.hpp>
@@ -69,16 +68,6 @@ using namespace com::sun::star;
/*
* static helpers
*/
-
-#if defined( UNX ) && !( defined( MACOSX ) || defined( IOS ) || defined( ANDROID ) )
-static oslModule driverLib = NULL;
-#endif
-extern "C"
-{
-typedef int(*setupFunction)(PrinterInfo&);
-static setupFunction pSetupFunction = NULL;
-}
-
static OUString getPdfDir( const PrinterInfo& rInfo )
{
OUString aDir;
@@ -153,24 +142,6 @@ namespace
}
}
-static void getPaLib()
-{
-#if defined( UNX ) && !( defined( MACOSX ) || defined( IOS ) || defined( ANDROID ) )
- if( ! driverLib )
- {
- driverLib = osl_loadModuleRelativeAscii( (oslGenericFunction)getPaLib,
- _XSALSET_LIBNAME,
- SAL_LOADMODULE_DEFAULT );
- if ( !driverLib )
- return;
-
- pSetupFunction = (setupFunction)osl_getAsciiFunctionSymbol( driverLib, "Sal_SetupPrinterDriver" );
- if ( !pSetupFunction )
- fprintf( stderr, "could not resolve Sal_SetupPrinterDriver\n" );
- }
-#endif
-}
-
inline int PtTo10Mu( int nPoints ) { return (int)((((double)nPoints)*35.27777778)+0.5); }
inline int TenMuToPt( int nUnits ) { return (int)((((double)nUnits)/35.27777778)+0.5); }
@@ -572,11 +543,6 @@ bool PspSalInfoPrinter::Setup( SalFrame* pFrame, ImplJobSetup* pJobSetup )
if( ! pFrame || ! pJobSetup )
return false;
- getPaLib();
-
- if( ! pSetupFunction )
- return false;
-
PrinterInfoManager& rManager = PrinterInfoManager::get();
PrinterInfo aInfo( rManager.getPrinterInfo( pJobSetup->maPrinterName ) );
@@ -586,7 +552,7 @@ bool PspSalInfoPrinter::Setup( SalFrame* pFrame, ImplJobSetup* pJobSetup )
JobData::constructFromStreamBuffer( pJobSetup->mpDriverData, pJobSetup->mnDriverDataLen, aInfo );
}
- if( pSetupFunction( aInfo ) )
+ if (SetupPrinterDriver(aInfo))
{
aInfo.resolveDefaultBackend();
rtl_freeMemory( pJobSetup->mpDriverData );
diff --git a/vcl/generic/print/prtsetup.cxx b/vcl/generic/print/prtsetup.cxx
new file mode 100644
index 000000000000..ce1f65516f7b
--- /dev/null
+++ b/vcl/generic/print/prtsetup.cxx
@@ -0,0 +1,487 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * This file incorporates work covered by the following license notice:
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed
+ * with this work for additional information regarding copyright
+ * ownership. The ASF licenses this file to you under the Apache
+ * License, Version 2.0 (the "License"); you may not use this file
+ * except in compliance with the License. You may obtain a copy of
+ * the License at http://www.apache.org/licenses/LICENSE-2.0 .
+ */
+
+#include "prtsetup.hxx"
+#include "svdata.hxx"
+#include "svids.hrc"
+
+#include "osl/thread.h"
+
+#include <officecfg/Office/Common.hxx>
+
+using namespace psp;
+
+void RTSDialog::insertAllPPDValues( ListBox& rBox, const PPDParser* pParser, const PPDKey* pKey )
+{
+ if( ! pKey || ! pParser )
+ return;
+
+ const PPDValue* pValue = NULL;
+ sal_Int32 nPos = 0;
+ OUString aOptionText;
+
+ for( int i = 0; i < pKey->countValues(); i++ )
+ {
+ pValue = pKey->getValue( i );
+ aOptionText = pParser->translateOption( pKey->getKey(), pValue->m_aOption) ;
+
+ if( m_aJobData.m_aContext.checkConstraints( pKey, pValue ) )
+ {
+ if( rBox.GetEntryPos( (void*)pValue ) == LISTBOX_ENTRY_NOTFOUND )
+ {
+ nPos = rBox.InsertEntry( aOptionText, LISTBOX_APPEND );
+ rBox.SetEntryData( nPos, (void*)pValue );
+ }
+ }
+ else
+ {
+ if( ( nPos = rBox.GetEntryPos( (void*)pValue ) ) != LISTBOX_ENTRY_NOTFOUND )
+ rBox.RemoveEntry( nPos );
+ }
+ }
+ pValue = m_aJobData.m_aContext.getValue( pKey );
+ if( pValue )
+ {
+ if( ( nPos = rBox.GetEntryPos( (void*)pValue ) ) != LISTBOX_ENTRY_NOTFOUND )
+ rBox.SelectEntryPos( nPos );
+ }
+ else
+ rBox.SelectEntry( m_aInvalidString );
+}
+
+
+
+/*
+ * RTSDialog
+ */
+
+RTSDialog::RTSDialog(const PrinterInfo& rJobData, const OUString& rPrinter, Window* pParent)
+ : TabDialog(pParent, "PrinterPropertiesDialog", "vcl/ui/printerpropertiesdialog.ui")
+ , m_aJobData(rJobData)
+ , m_aPrinter(rPrinter)
+ , m_pPaperPage(NULL)
+ , m_pDevicePage(NULL)
+ , m_aInvalidString(VclResId(SV_PRINT_INVALID_TXT))
+{
+ get(m_pOKButton, "ok");
+ get(m_pCancelButton, "cancel");
+ get(m_pTabControl, "notebook");
+
+ OUString aTitle(GetText());
+ SetText(aTitle.replaceAll("%s", m_aJobData.m_aPrinterName));
+
+ m_pTabControl->SetActivatePageHdl( LINK( this, RTSDialog, ActivatePage ) );
+ m_pOKButton->SetClickHdl( LINK( this, RTSDialog, ClickButton ) );
+ m_pCancelButton->SetClickHdl( LINK( this, RTSDialog, ClickButton ) );
+ ActivatePage(m_pTabControl);
+}
+
+RTSDialog::~RTSDialog()
+{
+ delete m_pPaperPage;
+ delete m_pDevicePage;
+}
+
+IMPL_LINK( RTSDialog, ActivatePage, TabControl*, pTabCtrl )
+{
+ if( pTabCtrl != m_pTabControl )
+ return 0;
+
+ sal_uInt16 nId = m_pTabControl->GetCurPageId();
+ OString sPage = m_pTabControl->GetPageName(nId);
+ if ( ! m_pTabControl->GetTabPage( nId ) )
+ {
+ TabPage *pPage = NULL;
+ if (sPage == "paper")
+ pPage = m_pPaperPage = new RTSPaperPage( this );
+ else if (sPage == "device")
+ pPage = m_pDevicePage = new RTSDevicePage( this );
+ if( pPage )
+ m_pTabControl->SetTabPage( nId, pPage );
+ }
+ else
+ {
+ if (sPage == "paper")
+ m_pPaperPage->update();
+ else if (sPage == "device")
+ m_pDevicePage->update();
+ }
+
+ return 0;
+}
+
+
+
+IMPL_LINK( RTSDialog, ClickButton, Button*, pButton )
+{
+ if( pButton == m_pOKButton )
+ {
+ // refresh the changed values
+ if( m_pPaperPage )
+ {
+ // orientation
+ m_aJobData.m_eOrientation = m_pPaperPage->getOrientation() == 0 ?
+ orientation::Portrait : orientation::Landscape;
+ }
+ if( m_pDevicePage )
+ {
+ m_aJobData.m_nColorDepth = m_pDevicePage->getDepth();
+ m_aJobData.m_nColorDevice = m_pDevicePage->getColorDevice();
+ m_aJobData.m_nPSLevel = m_pDevicePage->getLevel();
+ m_aJobData.m_nPDFDevice = m_pDevicePage->getPDFDevice();
+ }
+ EndDialog( 1 );
+ }
+ else if( pButton == m_pCancelButton )
+ EndDialog( 0 );
+
+ return 0;
+}
+
+
+
+/*
+ * RTSPaperPage
+ */
+
+RTSPaperPage::RTSPaperPage(RTSDialog* pParent)
+ : TabPage(pParent->m_pTabControl, "PrinterPaperPage", "vcl/ui/printerpaperpage.ui")
+ , m_pParent( pParent )
+{
+ get(m_pPaperText, "paperft");
+ get(m_pPaperBox, "paperlb");
+ get(m_pOrientBox, "orientlb");
+ get(m_pDuplexText, "duplexft");
+ get(m_pDuplexBox, "duplexlb");
+ get(m_pSlotText, "slotft");
+ get(m_pSlotBox, "slotlb");
+
+ m_pPaperBox->SetSelectHdl( LINK( this, RTSPaperPage, SelectHdl ) );
+ m_pOrientBox->SetSelectHdl( LINK( this, RTSPaperPage, SelectHdl ) );
+ m_pDuplexBox->SetSelectHdl( LINK( this, RTSPaperPage, SelectHdl ) );
+ m_pSlotBox->SetSelectHdl( LINK( this, RTSPaperPage, SelectHdl ) );
+
+ sal_Int32 nPos = 0;
+
+ // duplex
+ nPos = m_pDuplexBox->InsertEntry( m_pParent->m_aInvalidString );
+ m_pDuplexBox->SetEntryData( nPos, NULL );
+
+ // paper does not have an invalid entry
+
+ // input slots
+ nPos = m_pSlotBox->InsertEntry( m_pParent->m_aInvalidString );
+ m_pSlotBox->SetEntryData( nPos, NULL );
+
+ update();
+}
+
+
+
+RTSPaperPage::~RTSPaperPage()
+{
+}
+
+
+
+void RTSPaperPage::update()
+{
+ const PPDKey* pKey = NULL;
+
+ // orientation
+ m_pOrientBox->SelectEntryPos(
+ m_pParent->m_aJobData.m_eOrientation == orientation::Portrait ? 0 : 1);
+
+ // duplex
+ if( m_pParent->m_aJobData.m_pParser &&
+ (pKey = m_pParent->m_aJobData.m_pParser->getKey( OUString( "Duplex" ) )) )
+ {
+ m_pParent->insertAllPPDValues( *m_pDuplexBox, m_pParent->m_aJobData.m_pParser, pKey );
+ }
+ else
+ {
+ m_pDuplexText->Enable( false );
+ m_pDuplexBox->Enable( false );
+ }
+
+ // paper
+ if( m_pParent->m_aJobData.m_pParser &&
+ (pKey = m_pParent->m_aJobData.m_pParser->getKey( OUString( "PageSize" ) )) )
+ {
+ m_pParent->insertAllPPDValues( *m_pPaperBox, m_pParent->m_aJobData.m_pParser, pKey );
+ }
+ else
+ {
+ m_pPaperText->Enable( false );
+ m_pPaperBox->Enable( false );
+ }
+
+ // input slots
+ if( m_pParent->m_aJobData.m_pParser &&
+ (pKey = m_pParent->m_aJobData.m_pParser->getKey( OUString("InputSlot") )) )
+ {
+ m_pParent->insertAllPPDValues( *m_pSlotBox, m_pParent->m_aJobData.m_pParser, pKey );
+ }
+ else
+ {
+ m_pSlotText->Enable( false );
+ m_pSlotBox->Enable( false );
+ }
+}
+
+
+
+IMPL_LINK( RTSPaperPage, SelectHdl, ListBox*, pBox )
+{
+ const PPDKey* pKey = NULL;
+ if( pBox == m_pPaperBox )
+ {
+ if( m_pParent->m_aJobData.m_pParser )
+ pKey = m_pParent->m_aJobData.m_pParser->getKey( OUString( "PageSize" ) );
+ }
+ else if( pBox == m_pDuplexBox )
+ {
+ if( m_pParent->m_aJobData.m_pParser )
+ pKey = m_pParent->m_aJobData.m_pParser->getKey( OUString( "Duplex" ) );
+ }
+ else if( pBox == m_pSlotBox )
+ {
+ if( m_pParent->m_aJobData.m_pParser )
+ pKey = m_pParent->m_aJobData.m_pParser->getKey( OUString( "InputSlot" ) );
+ }
+ else if( pBox == m_pOrientBox )
+ {
+ m_pParent->m_aJobData.m_eOrientation = m_pOrientBox->GetSelectEntryPos() == 0 ? orientation::Portrait : orientation::Landscape;
+ }
+ if( pKey )
+ {
+ PPDValue* pValue =
+ (PPDValue*)pBox->GetEntryData( pBox->GetSelectEntryPos() );
+ m_pParent->m_aJobData.m_aContext.setValue( pKey, pValue );
+ update();
+ }
+ return 0;
+}
+
+
+
+/*
+ * RTSDevicePage
+ */
+
+RTSDevicePage::RTSDevicePage( RTSDialog* pParent )
+ : TabPage(pParent->m_pTabControl, "PrinterDevicePage", "vcl/ui/printerdevicepage.ui" )
+ , m_pParent( pParent )
+{
+ get(m_pPPDKeyBox, "options");
+ get(m_pPPDValueBox, "values");
+
+ m_pPPDKeyBox->SetDropDownLineCount(12);
+ m_pPPDValueBox->SetDropDownLineCount(12);
+
+ get(m_pLevelBox, "level");
+ get(m_pSpaceBox, "colorspace");
+ get(m_pDepthBox, "colordepth");
+
+ m_pPPDKeyBox->SetSelectHdl( LINK( this, RTSDevicePage, SelectHdl ) );
+ m_pPPDValueBox->SetSelectHdl( LINK( this, RTSDevicePage, SelectHdl ) );
+
+ switch( m_pParent->m_aJobData.m_nColorDevice )
+ {
+ case 0: m_pSpaceBox->SelectEntryPos(0);break;
+ case 1: m_pSpaceBox->SelectEntryPos(1);break;
+ case -1: m_pSpaceBox->SelectEntryPos(2);break;
+ }
+
+ sal_uLong nLevelEntryData = 0; //automatic
+ if( m_pParent->m_aJobData.m_nPDFDevice == 2 ) //explicitly PDF
+ nLevelEntryData = 10;
+ else if (m_pParent->m_aJobData.m_nPSLevel > 0) //explicit PS Level
+ nLevelEntryData = m_pParent->m_aJobData.m_nPSLevel+1;
+ else if (m_pParent->m_aJobData.m_nPDFDevice == 1) //automatically PDF
+ nLevelEntryData = 0;
+ else if (m_pParent->m_aJobData.m_nPDFDevice == -1) //explicitly PS from driver
+ nLevelEntryData = 1;
+
+ bool bAutoIsPDF = officecfg::Office::Common::Print::Option::Printer::PDFAsStandardPrintJobFormat::get();
+
+ assert(nLevelEntryData != 0
+ || "Generic Printer" == m_pParent->m_aJobData.m_aPrinterName
+ || int(bAutoIsPDF) == m_pParent->m_aJobData.m_nPDFDevice);
+
+ OUString sStr = m_pLevelBox->GetEntry(0);
+ m_pLevelBox->InsertEntry(sStr.replaceAll("%s", bAutoIsPDF ? m_pLevelBox->GetEntry(5) : m_pLevelBox->GetEntry(1)), 0);
+ m_pLevelBox->SetEntryData(0, m_pLevelBox->GetEntryData(1));
+ m_pLevelBox->RemoveEntry(1);
+
+ for( sal_uInt16 i = 0; i < m_pLevelBox->GetEntryCount(); i++ )
+ {
+ if( (sal_uLong)m_pLevelBox->GetEntryData( i ) == nLevelEntryData )
+ {
+ m_pLevelBox->SelectEntryPos( i );
+ break;
+ }
+ }
+
+ if (m_pParent->m_aJobData.m_nColorDepth == 8)
+ m_pDepthBox->SelectEntryPos(0);
+ else if (m_pParent->m_aJobData.m_nColorDepth == 24)
+ m_pDepthBox->SelectEntryPos(1);
+
+ // fill ppd boxes
+ if( m_pParent->m_aJobData.m_pParser )
+ {
+ for( int i = 0; i < m_pParent->m_aJobData.m_pParser->getKeys(); i++ )
+ {
+ const PPDKey* pKey = m_pParent->m_aJobData.m_pParser->getKey( i );
+ if( pKey->isUIKey() &&
+ ! pKey->getKey().equalsAscii( "PageSize" ) &&
+ ! pKey->getKey().equalsAscii( "InputSlot" ) &&
+ ! pKey->getKey().equalsAscii( "PageRegion" ) &&
+ ! pKey->getKey().equalsAscii( "Duplex" )
+ )
+ {
+ OUString aEntry( m_pParent->m_aJobData.m_pParser->translateKey( pKey->getKey() ) );
+ sal_uInt16 nPos = m_pPPDKeyBox->InsertEntry( aEntry );
+ m_pPPDKeyBox->SetEntryData( nPos, (void*)pKey );
+ }
+ }
+ }
+}
+
+
+
+RTSDevicePage::~RTSDevicePage()
+{
+}
+
+
+
+void RTSDevicePage::update()
+{
+}
+
+sal_uLong RTSDevicePage::getDepth()
+{
+ sal_uInt16 nSelectPos = m_pDepthBox->GetSelectEntryPos();
+ if (nSelectPos == 0)
+ return 8;
+ else
+ return 24;
+}
+
+sal_uLong RTSDevicePage::getColorDevice()
+{
+ sal_uInt16 nSelectPos = m_pSpaceBox->GetSelectEntryPos();
+ switch (nSelectPos)
+ {
+ case 0:
+ return 0;
+ case 1:
+ return 1;
+ case 2:
+ return -1;
+ }
+ return 0;
+}
+
+
+
+sal_uLong RTSDevicePage::getLevel()
+{
+ sal_uLong nLevel = (sal_uLong)m_pLevelBox->GetEntryData( m_pLevelBox->GetSelectEntryPos() );
+ if (nLevel == 0)
+ return 0; //automatic
+ return nLevel < 10 ? nLevel-1 : 0;
+}
+
+
+
+sal_uLong RTSDevicePage::getPDFDevice()
+{
+ sal_uLong nLevel = (sal_uLong)m_pLevelBox->GetEntryData( m_pLevelBox->GetSelectEntryPos() );
+ if (nLevel > 9)
+ return 2; //explictly PDF
+ else if (nLevel == 0)
+ return 0; //automatic
+ return -1; //explicitly PS
+}
+
+
+
+IMPL_LINK( RTSDevicePage, SelectHdl, ListBox*, pBox )
+{
+ if( pBox == m_pPPDKeyBox )
+ {
+ const PPDKey* pKey = (PPDKey*)m_pPPDKeyBox->GetEntryData( m_pPPDKeyBox->GetSelectEntryPos() );
+ FillValueBox( pKey );
+ }
+ else if( pBox == m_pPPDValueBox )
+ {
+ const PPDKey* pKey = (PPDKey*)m_pPPDKeyBox->GetEntryData( m_pPPDKeyBox->GetSelectEntryPos() );
+ const PPDValue* pValue = (PPDValue*)m_pPPDValueBox->GetEntryData( m_pPPDValueBox->GetSelectEntryPos() );
+ if( pKey && pValue )
+ {
+ m_pParent->m_aJobData.m_aContext.setValue( pKey, pValue );
+ FillValueBox( pKey );
+ }
+ }
+ return 0;
+}
+
+
+
+void RTSDevicePage::FillValueBox( const PPDKey* pKey )
+{
+ m_pPPDValueBox->Clear();
+
+ if( ! pKey )
+ return;
+
+ const PPDValue* pValue = NULL;
+ for( int i = 0; i < pKey->countValues(); i++ )
+ {
+ pValue = pKey->getValue( i );
+ if( m_pParent->m_aJobData.m_aContext.checkConstraints( pKey, pValue ) &&
+ m_pParent->m_aJobData.m_pParser )
+ {
+ OUString aEntry( m_pParent->m_aJobData.m_pParser->translateOption( pKey->getKey(), pValue->m_aOption ) );
+ sal_uInt16 nPos = m_pPPDValueBox->InsertEntry( aEntry );
+ m_pPPDValueBox->SetEntryData( nPos, (void*)pValue );
+ }
+ }
+ pValue = m_pParent->m_aJobData.m_aContext.getValue( pKey );
+ m_pPPDValueBox->SelectEntryPos( m_pPPDValueBox->GetEntryPos( (void*)pValue ) );
+}
+
+int SetupPrinterDriver(::psp::PrinterInfo& rJobData)
+{
+ int nRet = 0;
+ RTSDialog aDialog( rJobData, rJobData.m_aPrinterName, false );
+
+ if( aDialog.Execute() )
+ {
+ rJobData = aDialog.getSetup();
+ nRet = 1;
+ }
+
+ return nRet;
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/vcl/generic/print/prtsetup.hxx b/vcl/generic/print/prtsetup.hxx
new file mode 100644
index 000000000000..dd1d1094adaf
--- /dev/null
+++ b/vcl/generic/print/prtsetup.hxx
@@ -0,0 +1,129 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * This file incorporates work covered by the following license notice:
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed
+ * with this work for additional information regarding copyright
+ * ownership. The ASF licenses this file to you under the Apache
+ * License, Version 2.0 (the "License"); you may not use this file
+ * except in compliance with the License. You may obtain a copy of
+ * the License at http://www.apache.org/licenses/LICENSE-2.0 .
+ */
+
+#ifndef _PAD_PRTSETUP_HXX_
+#define _PAD_PRTSETUP_HXX_
+
+#include "tools/link.hxx"
+
+#include "vcl/tabdlg.hxx"
+#include "vcl/tabpage.hxx"
+#include "vcl/tabctrl.hxx"
+#include "vcl/button.hxx"
+#include "vcl/fixed.hxx"
+#include "vcl/lstbox.hxx"
+#include "vcl/field.hxx"
+#include "vcl/combobox.hxx"
+#include "vcl/ppdparser.hxx"
+#include "vcl/printerinfomanager.hxx"
+
+class RTSPaperPage;
+class RTSDevicePage;
+
+class RTSDialog : public TabDialog
+{
+ friend class RTSPaperPage;
+ friend class RTSDevicePage;
+
+ ::psp::PrinterInfo m_aJobData;
+ OUString m_aPrinter;
+
+ // controls
+ TabControl* m_pTabControl;
+ OKButton* m_pOKButton;
+ CancelButton* m_pCancelButton;
+
+ // pages
+ RTSPaperPage* m_pPaperPage;
+ RTSDevicePage* m_pDevicePage;
+
+ // some resources
+ OUString m_aInvalidString;
+
+ DECL_LINK( ActivatePage, TabControl* );
+ DECL_LINK( ClickButton, Button* );
+
+ // helper functions
+ void insertAllPPDValues( ListBox&, const psp::PPDParser*, const psp::PPDKey* );
+public:
+ RTSDialog(const ::psp::PrinterInfo& rJobData, const OUString& rPrinter, Window* pParent = NULL);
+ ~RTSDialog();
+
+ const ::psp::PrinterInfo& getSetup() const { return m_aJobData; }
+};
+
+class RTSPaperPage : public TabPage
+{
+ RTSDialog* m_pParent;
+
+ FixedText* m_pPaperText;
+ ListBox* m_pPaperBox;
+
+ ListBox* m_pOrientBox;
+
+ FixedText* m_pDuplexText;
+ ListBox* m_pDuplexBox;
+
+ FixedText* m_pSlotText;
+ ListBox* m_pSlotBox;
+
+ DECL_LINK( SelectHdl, ListBox* );
+public:
+ RTSPaperPage( RTSDialog* );
+ ~RTSPaperPage();
+
+ void update();
+
+ sal_uInt16 getOrientation() { return m_pOrientBox->GetSelectEntryPos(); }
+};
+
+class RTSDevicePage : public TabPage
+{
+ RTSDialog* m_pParent;
+
+ OUString m_aSpaceColor;
+ OUString m_aSpaceGray;
+
+ ListBox* m_pPPDKeyBox;
+ ListBox* m_pPPDValueBox;
+
+ ListBox* m_pLevelBox;
+ ListBox* m_pSpaceBox;
+ ListBox* m_pDepthBox;
+
+ void FillValueBox( const ::psp::PPDKey* );
+
+ DECL_LINK( SelectHdl, ListBox* );
+public:
+ RTSDevicePage( RTSDialog* );
+ ~RTSDevicePage();
+
+ void update();
+
+ sal_uLong getLevel();
+ sal_uLong getPDFDevice();
+ sal_uLong getDepth();
+ sal_uLong getColorDevice();
+};
+
+int SetupPrinterDriver(::psp::PrinterInfo& rJobData);
+
+#endif // _PAD_PRTSETUP_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/vcl/inc/cupsmgr.hxx b/vcl/inc/cupsmgr.hxx
index cfbd7744b792..3b0d7d6985fe 100644
--- a/vcl/inc/cupsmgr.hxx
+++ b/vcl/inc/cupsmgr.hxx
@@ -86,7 +86,7 @@ public:
/// check if the printer configuration has changed
virtual bool checkPrintersChanged( bool bWait );
- // members for administration (->padmin)
+ // members for administration
// disable for CUPS
virtual bool addPrinter( const OUString& rPrinterName, const OUString& rDriverName );
virtual bool removePrinter( const OUString& rPrinterName, bool bCheckOnly = false );
diff --git a/vcl/inc/svids.hrc b/vcl/inc/svids.hrc
index 6cb7d7310fa9..2bd0e223de30 100644
--- a/vcl/inc/svids.hrc
+++ b/vcl/inc/svids.hrc
@@ -213,6 +213,7 @@
#define SV_PRINT_COLLATE_IMG 10613
#define SV_PRINT_NOCOLLATE_IMG 10614
#define SV_PRINT_QUERYFAXNUMBER_TXT 10615
+#define SV_PRINT_INVALID_TXT 10616
#define SV_EDIT_WARNING_BOX 10650
diff --git a/vcl/source/src/print.src b/vcl/source/src/print.src
index 738adb3eedfc..bd9f85b0991c 100644
--- a/vcl/source/src/print.src
+++ b/vcl/source/src/print.src
@@ -110,4 +110,9 @@ String SV_PRINT_QUERYFAXNUMBER_TXT
Text [ en-US ] = "Please enter the fax number.";
};
+String SV_PRINT_INVALID_TXT
+{
+ Text [ en-US ] = "<ignore>";
+};
+
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/vcl/uiconfig/ui/printerdevicepage.ui b/vcl/uiconfig/ui/printerdevicepage.ui
new file mode 100644
index 000000000000..45dc09584c18
--- /dev/null
+++ b/vcl/uiconfig/ui/printerdevicepage.ui
@@ -0,0 +1,209 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<interface>
+ <!-- interface-requires gtk+ 3.0 -->
+ <object class="GtkGrid" id="PrinterDevicePage">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="hexpand">True</property>
+ <property name="vexpand">True</property>
+ <property name="border_width">6</property>
+ <property name="row_spacing">6</property>
+ <property name="column_spacing">12</property>
+ <property name="column_homogeneous">True</property>
+ <child>
+ <object class="GtkLabel" id="label7">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Option</property>
+ <property name="use_underline">True</property>
+ <attributes>
+ <attribute name="weight" value="bold"/>
+ </attributes>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">0</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label8">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Current _value</property>
+ <property name="use_underline">True</property>
+ <attributes>
+ <attribute name="weight" value="bold"/>
+ </attributes>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">0</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label9">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Printer _Language type</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">2</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label10">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Color</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">3</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label11">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Color _depth</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">4</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkComboBoxText" id="colorspace">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="entry_text_column">0</property>
+ <property name="id_column">1</property>
+ <items>
+ <item translatable="yes">From driver</item>
+ <item translatable="yes">Color</item>
+ <item translatable="yes">Grayscale</item>
+ </items>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">3</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkComboBoxText" id="colordepth">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="entry_text_column">0</property>
+ <property name="id_column">1</property>
+ <items>
+ <item translatable="yes">8 Bit</item>
+ <item translatable="yes">24 Bit</item>
+ </items>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">4</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkComboBox" id="level">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="model">liststore1</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">2</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkTreeView" id="options:border">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <child internal-child="selection">
+ <object class="GtkTreeSelection" id="treeview-selection1"/>
+ </child>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">1</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkTreeView" id="values:border">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <child internal-child="selection">
+ <object class="GtkTreeSelection" id="treeview-selection2"/>
+ </child>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">1</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ </object>
+ <object class="GtkListStore" id="liststore1">
+ <columns>
+ <!-- column-name gchararray1 -->
+ <column type="gchararray"/>
+ <!-- column-name gint1 -->
+ <column type="gint"/>
+ </columns>
+ <data>
+ <row>
+ <col id="0" translatable="yes">Automatic : %s</col>
+ <col id="1">0</col>
+ </row>
+ <row>
+ <col id="0" translatable="yes">PostScript (Level from driver)</col>
+ <col id="1">1</col>
+ </row>
+ <row>
+ <col id="0" translatable="yes">PostScript Level 1</col>
+ <col id="1">2</col>
+ </row>
+ <row>
+ <col id="0" translatable="yes">PostScript Level 2</col>
+ <col id="1">3</col>
+ </row>
+ <row>
+ <col id="0" translatable="yes">PostScript Level 3</col>
+ <col id="1">4</col>
+ </row>
+ <row>
+ <col id="0" translatable="yes">PDF</col>
+ <col id="1">10</col>
+ </row>
+ </data>
+ </object>
+</interface>
diff --git a/vcl/uiconfig/ui/printerpaperpage.ui b/vcl/uiconfig/ui/printerpaperpage.ui
new file mode 100644
index 000000000000..422ba176cd1e
--- /dev/null
+++ b/vcl/uiconfig/ui/printerpaperpage.ui
@@ -0,0 +1,134 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<interface>
+ <!-- interface-requires gtk+ 3.0 -->
+ <object class="GtkGrid" id="PrinterPaperPage">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="hexpand">True</property>
+ <property name="vexpand">True</property>
+ <property name="border_width">6</property>
+ <property name="row_spacing">6</property>
+ <property name="column_spacing">12</property>
+ <property name="column_homogeneous">True</property>
+ <child>
+ <object class="GtkLabel" id="paperft">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Paper size</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">0</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label4">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Orientation</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">1</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="duplexft">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Duplex</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">2</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="slotft">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Paper tray</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">3</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkComboBoxText" id="paperlb">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="entry_text_column">0</property>
+ <property name="id_column">1</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">0</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkComboBoxText" id="orientlb">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="entry_text_column">0</property>
+ <property name="id_column">1</property>
+ <items>
+ <item translatable="yes">Portrait</item>
+ <item translatable="yes">Landscape</item>
+ </items>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">1</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkComboBoxText" id="duplexlb">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="entry_text_column">0</property>
+ <property name="id_column">1</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">2</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkComboBoxText" id="slotlb">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="entry_text_column">0</property>
+ <property name="id_column">1</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">3</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ </object>
+</interface>
diff --git a/vcl/uiconfig/ui/printerpropertiesdialog.ui b/vcl/uiconfig/ui/printerpropertiesdialog.ui
new file mode 100644
index 000000000000..0df264d7a66c
--- /dev/null
+++ b/vcl/uiconfig/ui/printerpropertiesdialog.ui
@@ -0,0 +1,104 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<interface>
+ <!-- interface-requires gtk+ 3.0 -->
+ <object class="GtkDialog" id="PrinterPropertiesDialog">
+ <property name="can_focus">False</property>
+ <property name="border_width">6</property>
+ <property name="title" translatable="yes">Properties of %s</property>
+ <property name="type_hint">dialog</property>
+ <child internal-child="vbox">
+ <object class="GtkBox" id="dialog-vbox1">
+ <property name="can_focus">False</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">12</property>
+ <child internal-child="action_area">
+ <object class="GtkButtonBox" id="dialog-action_area1">
+ <property name="can_focus">False</property>
+ <property name="layout_style">end</property>
+ <child>
+ <object class="GtkButton" id="ok">
+ <property name="label">gtk-ok</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="can_default">True</property>
+ <property name="has_default">True</property>
+ <property name="receives_default">True</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="cancel">
+ <property name="label">gtk-cancel</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="pack_type">end</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkNotebook" id="notebook">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="hexpand">True</property>
+ <property name="vexpand">True</property>
+ <child>
+ <placeholder/>
+ </child>
+ <child type="tab">
+ <object class="GtkLabel" id="paper">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">Paper</property>
+ </object>
+ <packing>
+ <property name="position">1</property>
+ <property name="tab_fill">False</property>
+ </packing>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child type="tab">
+ <object class="GtkLabel" id="device">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">Device</property>
+ </object>
+ <packing>
+ <property name="position">2</property>
+ <property name="tab_fill">False</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ <action-widgets>
+ <action-widget response="0">ok</action-widget>
+ <action-widget response="0">cancel</action-widget>
+ </action-widgets>
+ </object>
+</interface>
diff --git a/vcl/unx/generic/printer/printerinfomanager.cxx b/vcl/unx/generic/printer/printerinfomanager.cxx
index 35116c1e8348..bf92b77383a7 100644
--- a/vcl/unx/generic/printer/printerinfomanager.cxx
+++ b/vcl/unx/generic/printer/printerinfomanager.cxx
@@ -529,7 +529,7 @@ void PrinterInfoManager::initialize()
aPrinterName += ">";
if( m_aPrinters.find( aPrinterName ) != m_aPrinters.end() )
- // probably user made this one permanent in padmin
+ // probably user made this one permanent
continue;
OUString aCmd( m_aSystemPrintCommand );
@@ -544,7 +544,7 @@ void PrinterInfoManager::initialize()
aPrinter.m_aInfo.m_aComment = it->m_aComment;
aPrinter.m_aInfo.m_aLocation = it->m_aLocation;
aPrinter.m_bModified = false;
- aPrinter.m_aGroup = OUStringToOString(aPrinterName, aEncoding); //provide group name in case user makes this one permanent in padmin
+ aPrinter.m_aGroup = OUStringToOString(aPrinterName, aEncoding); //provide group name in case user makes this one permanent
m_aPrinters[ aPrinterName ] = aPrinter;
}
@@ -787,8 +787,8 @@ bool PrinterInfoManager::addPrinter( const OUString& rPrinterName, const OUStrin
#endif
// comment: logically one should writePrinterConfig() here
// but immediately after addPrinter() a changePrinterInfo()
- // will follow (see padmin code), which writes it again,
- // so we can currently save some performance here
+ // will follow which writes it again, so we can currently save some
+ // performance here
}
return bSuccess;
}