diff --git a/drawinglayer/Library_drawinglayer.mk b/drawinglayer/Library_drawinglayer.mk index 28e073f983c8..8945e1c462c8 100644 --- a/drawinglayer/Library_drawinglayer.mk +++ b/drawinglayer/Library_drawinglayer.mk @@ -165,7 +165,6 @@ $(eval $(call gb_Library_add_exception_objects,drawinglayer,\ drawinglayer/source/processor2d/hittestprocessor2d \ drawinglayer/source/processor2d/linegeometryextractor2d \ drawinglayer/source/processor2d/objectinfoextractor2d \ - drawinglayer/source/processor2d/processorfromoutputdevice \ drawinglayer/source/processor2d/textaspolygonextractor2d \ drawinglayer/source/processor2d/vclhelperbufferdevice \ drawinglayer/source/processor2d/vclmetafileprocessor2d \ diff --git a/drawinglayer/qa/unit/border.cxx b/drawinglayer/qa/unit/border.cxx index 53bd420ee726..f6f9feba5427 100644 --- a/drawinglayer/qa/unit/border.cxx +++ b/drawinglayer/qa/unit/border.cxx @@ -15,7 +15,7 @@ #include #include #include -#include +#include #include #include #include @@ -93,7 +93,7 @@ CPPUNIT_TEST_FIXTURE(DrawinglayerBorderTest, testDoublePixelProcessing) ScopedVclPtrInstance pDev; drawinglayer::geometry::ViewInformation2D aView; std::unique_ptr pProcessor( - drawinglayer::processor2d::createBaseProcessor2DFromOutputDevice(*pDev, aView)); + drawinglayer::processor2d::createProcessor2DFromOutputDevice(*pDev, aView)); CPPUNIT_ASSERT(pProcessor); GDIMetaFile aMetaFile; // Start recording after the processor is created, so we can test the pixel processor. diff --git a/drawinglayer/qa/unit/vclmetafileprocessor2d.cxx b/drawinglayer/qa/unit/vclmetafileprocessor2d.cxx index 0467df867f63..4f0a312ec1d7 100644 --- a/drawinglayer/qa/unit/vclmetafileprocessor2d.cxx +++ b/drawinglayer/qa/unit/vclmetafileprocessor2d.cxx @@ -19,7 +19,7 @@ #include #include #include -#include +#include #include #include @@ -83,7 +83,7 @@ public: metafile.Record(metadevice); drawinglayer::geometry::ViewInformation2D view; std::unique_ptr processor( - processor2d::createBaseProcessor2DFromOutputDevice(*metadevice, view)); + processor2d::createProcessor2DFromOutputDevice(*metadevice, view)); CPPUNIT_ASSERT(processor); // Match the values Impress uses. basegfx::B2DPolygon polygon = { { 15601, 0 }, { 15602, 5832 } }; diff --git a/drawinglayer/qa/unit/vclpixelprocessor2d.cxx b/drawinglayer/qa/unit/vclpixelprocessor2d.cxx index 17ef17969fe4..daf54c910e29 100644 --- a/drawinglayer/qa/unit/vclpixelprocessor2d.cxx +++ b/drawinglayer/qa/unit/vclpixelprocessor2d.cxx @@ -17,7 +17,7 @@ #include #include #include -#include +#include using namespace drawinglayer; @@ -53,7 +53,7 @@ public: drawinglayer::geometry::ViewInformation2D view; std::unique_ptr processor( - processor2d::createBaseProcessor2DFromOutputDevice(*device, view)); + processor2d::createProcessor2DFromOutputDevice(*device, view)); CPPUNIT_ASSERT(processor); basegfx::B2DRange definitionRange(0, 0, 100, 200); diff --git a/drawinglayer/source/processor2d/processorfromoutputdevice.cxx b/drawinglayer/source/processor2d/processorfromoutputdevice.cxx deleted file mode 100644 index c8433753aeff..000000000000 --- a/drawinglayer/source/processor2d/processorfromoutputdevice.cxx +++ /dev/null @@ -1,50 +0,0 @@ -/* -*- 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 -#include -#include -#include "vclmetafileprocessor2d.hxx" -#include "vclpixelprocessor2d.hxx" - -using namespace com::sun::star; - -namespace drawinglayer::processor2d -{ - std::unique_ptr createBaseProcessor2DFromOutputDevice( - OutputDevice& rTargetOutDev, - const drawinglayer::geometry::ViewInformation2D& rViewInformation2D) - { - const GDIMetaFile* pMetaFile = rTargetOutDev.GetConnectMetaFile(); - const bool bOutputToRecordingMetaFile(pMetaFile && pMetaFile->IsRecord() && !pMetaFile->IsPause()); - - if(bOutputToRecordingMetaFile) - { - // create MetaFile Vcl-Processor and process - return std::make_unique(rViewInformation2D, rTargetOutDev); - } - else - { - // create Pixel Vcl-Processor - return std::make_unique(rViewInformation2D, rTargetOutDev); - } - } -} // end of namespace - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/include/drawinglayer/processor2d/processorfromoutputdevice.hxx b/include/drawinglayer/processor2d/processorfromoutputdevice.hxx deleted file mode 100644 index f5ba9da79987..000000000000 --- a/include/drawinglayer/processor2d/processorfromoutputdevice.hxx +++ /dev/null @@ -1,47 +0,0 @@ -/* -*- 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 INCLUDED_DRAWINGLAYER_PROCESSOR2D_PROCESSORFROMOUTPUTDEVICE_HXX -#define INCLUDED_DRAWINGLAYER_PROCESSOR2D_PROCESSORFROMOUTPUTDEVICE_HXX - -#include -#include - -class OutputDevice; - -namespace drawinglayer::processor2d { - class BaseProcessor2D; -} - -namespace drawinglayer::geometry { class ViewInformation2D; } - -namespace drawinglayer::processor2d - { - // create a mating VCL-Processor for given OutputDevice. This includes - // looking for MetaFile-recording. The returned renderer changes owner, - // deletion is duty of the caller - DRAWINGLAYER_DLLPUBLIC std::unique_ptr createBaseProcessor2DFromOutputDevice( - OutputDevice& rTargetOutDev, - const drawinglayer::geometry::ViewInformation2D& rViewInformation2D); - -} // end of namespace drawinglayer::processor2d - -#endif // INCLUDED_DRAWINGLAYER_PROCESSOR2D_PROCESSORFROMOUTPUTDEVICE_HXX - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sc/source/ui/view/output.cxx b/sc/source/ui/view/output.cxx index 8e5020d0b3e6..77bc4810f4a6 100644 --- a/sc/source/ui/view/output.cxx +++ b/sc/source/ui/view/output.cxx @@ -30,7 +30,7 @@ #include #include #include -#include +#include #include #include #include @@ -1723,7 +1723,7 @@ std::unique_ptr ScOutputData::Create GetXDrawPageForSdrPage( pDrawPage ), 0.0); - return drawinglayer::processor2d::createBaseProcessor2DFromOutputDevice( + return drawinglayer::processor2d::createProcessor2DFromOutputDevice( *mpDev, aNewViewInfos ); } diff --git a/sfx2/source/control/thumbnailview.cxx b/sfx2/source/control/thumbnailview.cxx index 4371d6ab5eb8..8ec9b80ea6d4 100644 --- a/sfx2/source/control/thumbnailview.cxx +++ b/sfx2/source/control/thumbnailview.cxx @@ -21,7 +21,7 @@ #include #include #include -#include +#include #include #include #include @@ -895,7 +895,7 @@ void ThumbnailView::Paint(vcl::RenderContext& rRenderContext, const ::tools::Rec const drawinglayer::geometry::ViewInformation2D aNewViewInfos; std::unique_ptr pProcessor( - drawinglayer::processor2d::createBaseProcessor2DFromOutputDevice(rRenderContext, aNewViewInfos)); + drawinglayer::processor2d::createProcessor2DFromOutputDevice(rRenderContext, aNewViewInfos)); pProcessor->process(aSeq); // draw items diff --git a/sfx2/source/dialog/infobar.cxx b/sfx2/source/dialog/infobar.cxx index 144a3cd85c6a..aca75bffadd1 100644 --- a/sfx2/source/dialog/infobar.cxx +++ b/sfx2/source/dialog/infobar.cxx @@ -12,7 +12,7 @@ #include #include #include -#include +#include #include #include #include @@ -108,7 +108,7 @@ void SfxInfoBarWindow::SetCloseButtonImage() const ViewInformation2D aNewViewInfos; const std::unique_ptr pProcessor( - createBaseProcessor2DFromOutputDevice(*xDevice, aNewViewInfos)); + createProcessor2DFromOutputDevice(*xDevice, aNewViewInfos)); const ::tools::Rectangle aRect(aBtnPos, xDevice->PixelToLogic(aSize)); diff --git a/sw/source/core/layout/paintfrm.cxx b/sw/source/core/layout/paintfrm.cxx index e7cdef70f132..6348fb14bc59 100644 --- a/sw/source/core/layout/paintfrm.cxx +++ b/sw/source/core/layout/paintfrm.cxx @@ -96,7 +96,7 @@ #include #include #include -#include +#include #include #include #include @@ -5195,7 +5195,7 @@ std::unique_ptr SwFrame::CreateProce GetXDrawPageForSdrPage( pDrawPage ), 0.0); - return drawinglayer::processor2d::createBaseProcessor2DFromOutputDevice( + return drawinglayer::processor2d::createProcessor2DFromOutputDevice( *getRootFrame()->GetCurrShell()->GetOut(), aNewViewInfos ); } diff --git a/sw/source/uibase/docvw/AnnotationWin2.cxx b/sw/source/uibase/docvw/AnnotationWin2.cxx index 0455fb909898..6a4cebd56cdf 100644 --- a/sw/source/uibase/docvw/AnnotationWin2.cxx +++ b/sw/source/uibase/docvw/AnnotationWin2.cxx @@ -74,7 +74,7 @@ #include #include -#include +#include #include #include #include @@ -123,7 +123,7 @@ void SwAnnotationWin::PaintTile(vcl::RenderContext& rRenderContext, const tools: m_xContainer->draw(rRenderContext, rRect.TopLeft(), GetSizePixel()); const drawinglayer::geometry::ViewInformation2D aViewInformation; - std::unique_ptr pProcessor(drawinglayer::processor2d::createBaseProcessor2DFromOutputDevice(rRenderContext, aViewInformation)); + std::unique_ptr pProcessor(drawinglayer::processor2d::createProcessor2DFromOutputDevice(rRenderContext, aViewInformation)); // drawinglayer sets the map mode to pixels, not needed here. rRenderContext.Pop(); @@ -216,7 +216,7 @@ void SwAnnotationWin::DrawForPage(OutputDevice* pDev, const Point& rPt) const drawinglayer::geometry::ViewInformation2D aNewViewInfos; std::unique_ptr pProcessor( - drawinglayer::processor2d::createBaseProcessor2DFromOutputDevice( + drawinglayer::processor2d::createProcessor2DFromOutputDevice( *pDev, aNewViewInfos )); if (mpAnchor) diff --git a/sw/source/uibase/docvw/DashedLine.cxx b/sw/source/uibase/docvw/DashedLine.cxx index 5727cf280537..2ec691b4c643 100644 --- a/sw/source/uibase/docvw/DashedLine.cxx +++ b/sw/source/uibase/docvw/DashedLine.cxx @@ -14,7 +14,7 @@ #include #include #include -#include +#include #include #include #include @@ -33,7 +33,7 @@ void SwDashedLine::Paint(vcl::RenderContext& rRenderContext, const tools::Rectan { const drawinglayer::geometry::ViewInformation2D aNewViewInfos; std::unique_ptr pProcessor( - drawinglayer::processor2d::createBaseProcessor2DFromOutputDevice(rRenderContext, aNewViewInfos)); + drawinglayer::processor2d::createProcessor2DFromOutputDevice(rRenderContext, aNewViewInfos)); // Compute the start and end points const tools::Rectangle aRect(tools::Rectangle(Point(0, 0), rRenderContext.PixelToLogic(GetSizePixel()))); diff --git a/sw/source/uibase/docvw/HeaderFooterWin.cxx b/sw/source/uibase/docvw/HeaderFooterWin.cxx index 33df6419b154..ce703c679e90 100644 --- a/sw/source/uibase/docvw/HeaderFooterWin.cxx +++ b/sw/source/uibase/docvw/HeaderFooterWin.cxx @@ -42,7 +42,7 @@ #include #include #include -#include +#include #include #include #include @@ -374,7 +374,7 @@ void SwHeaderFooterWin::PaintButton() // Create the processor and process the primitives const drawinglayer::geometry::ViewInformation2D aNewViewInfos; std::unique_ptr pProcessor( - drawinglayer::processor2d::createBaseProcessor2DFromOutputDevice(*m_xVirDev, aNewViewInfos)); + drawinglayer::processor2d::createProcessor2DFromOutputDevice(*m_xVirDev, aNewViewInfos)); // TODO Ghost it all if needed drawinglayer::primitive2d::Primitive2DContainer aGhostedSeq(1); diff --git a/sw/source/uibase/docvw/PageBreakWin.cxx b/sw/source/uibase/docvw/PageBreakWin.cxx index eb169c0b4f45..50b1dcfa88de 100644 --- a/sw/source/uibase/docvw/PageBreakWin.cxx +++ b/sw/source/uibase/docvw/PageBreakWin.cxx @@ -41,7 +41,7 @@ #include #include #include -#include +#include #include #include #include @@ -243,7 +243,7 @@ void SwPageBreakWin::PaintButton() // Create the processor and process the primitives const drawinglayer::geometry::ViewInformation2D aNewViewInfos; std::unique_ptr pProcessor( - drawinglayer::processor2d::createBaseProcessor2DFromOutputDevice(*m_xVirDev, aNewViewInfos)); + drawinglayer::processor2d::createProcessor2DFromOutputDevice(*m_xVirDev, aNewViewInfos)); pProcessor->process(aGhostedSeq); diff --git a/sw/source/uibase/docvw/UnfloatTableButton.cxx b/sw/source/uibase/docvw/UnfloatTableButton.cxx index 2f0f596cc3c0..4b2c18f1d500 100644 --- a/sw/source/uibase/docvw/UnfloatTableButton.cxx +++ b/sw/source/uibase/docvw/UnfloatTableButton.cxx @@ -36,7 +36,7 @@ #include #include #include -#include +#include #include #include #include @@ -230,8 +230,7 @@ void UnfloatTableButton::PaintButton() // Create the processor and process the primitives const drawinglayer::geometry::ViewInformation2D aNewViewInfos; std::unique_ptr pProcessor( - drawinglayer::processor2d::createBaseProcessor2DFromOutputDevice(*m_xVirDev, - aNewViewInfos)); + drawinglayer::processor2d::createProcessor2DFromOutputDevice(*m_xVirDev, aNewViewInfos)); pProcessor->process(aSeq); diff --git a/sw/source/uibase/docvw/contentcontrolaliasbutton.cxx b/sw/source/uibase/docvw/contentcontrolaliasbutton.cxx index f1edd71919dc..abb792dcd943 100644 --- a/sw/source/uibase/docvw/contentcontrolaliasbutton.cxx +++ b/sw/source/uibase/docvw/contentcontrolaliasbutton.cxx @@ -15,7 +15,7 @@ #include #include #include -#include +#include #include #include @@ -125,7 +125,7 @@ void SwContentControlAliasButton::PaintButton() // Create the processor and process the primitives drawinglayer::geometry::ViewInformation2D aViewInfo; std::unique_ptr pProcessor - = drawinglayer::processor2d::createBaseProcessor2DFromOutputDevice(*m_xVirDev, aViewInfo); + = drawinglayer::processor2d::createProcessor2DFromOutputDevice(*m_xVirDev, aViewInfo); pProcessor->process(aSeq);