1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
3 * This file is part of the LibreOffice project.
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
9 * This file incorporates work covered by the following license notice:
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
22 #include <jobdata.hxx>
26 class VCL_DLLPUBLIC PspSalInfoPrinter
: public SalInfoPrinter
29 std::unique_ptr
<GenPspGraphics
> m_pGraphics
;
30 psp::JobData m_aJobData
;
33 virtual ~PspSalInfoPrinter() override
;
35 // override all pure virtual methods
36 virtual SalGraphics
* AcquireGraphics() override
;
37 virtual void ReleaseGraphics( SalGraphics
* pGraphics
) override
;
38 virtual bool Setup( weld::Window
* pFrame
, ImplJobSetup
* pSetupData
) override
;
39 virtual bool SetPrinterData( ImplJobSetup
* pSetupData
) override
;
40 virtual bool SetData( JobSetFlags nFlags
, ImplJobSetup
* pSetupData
) override
;
41 virtual void GetPageInfo( const ImplJobSetup
* pSetupData
,
42 tools::Long
& rOutWidth
, tools::Long
& rOutHeight
,
44 Size
& rPaperSize
) override
;
45 virtual sal_uInt32
GetCapabilities( const ImplJobSetup
* pSetupData
, PrinterCapType nType
) override
;
46 virtual sal_uInt16
GetPaperBinCount( const ImplJobSetup
* pSetupData
) override
;
47 virtual OUString
GetPaperBinName( const ImplJobSetup
* pSetupData
, sal_uInt16 nPaperBin
) override
;
48 virtual sal_uInt16
GetPaperBinBySourceIndex(const ImplJobSetup
* pSetupData
,
49 sal_uInt16 nPaperSource
) override
;
50 virtual sal_uInt16
GetSourceIndexByPaperBin(const ImplJobSetup
* pSetupData
,
51 sal_uInt16 nPaperBin
) override
;
52 virtual void InitPaperFormats( const ImplJobSetup
* pSetupData
) override
;
53 virtual int GetLandscapeAngle( const ImplJobSetup
* pSetupData
) override
;
56 class VCL_DLLPUBLIC PspSalPrinter
: public SalPrinter
59 SalInfoPrinter
* m_pInfoPrinter
;
60 psp::JobData m_aJobData
;
62 PspSalPrinter( SalInfoPrinter
*pPrinter
);
63 virtual ~PspSalPrinter() override
;
65 // override all pure virtual methods
66 virtual bool StartJob( const OUString
* pFileName
,
67 const OUString
& rJobName
,
68 const OUString
& rAppName
,
72 ImplJobSetup
* pSetupData
) override
;
73 virtual bool StartJob( const OUString
*,
77 vcl::PrinterController
& i_rController
) override
;
78 virtual bool EndJob() override
;
79 virtual SalGraphics
* StartPage( ImplJobSetup
* pSetupData
, bool bNewJobData
) override
;
80 virtual void EndPage() override
;
83 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */