[Libreoffice-commits] core.git: solenv/clang-format vcl/inc vcl/source
solenv/clang-format/excludelist |4 vcl/inc/pdf/pdfwriter_impl.hxx | 10 vcl/source/gdi/pdfbuildin_fonts.cxx |4 vcl/source/gdi/pdffontcache.cxx |5 vcl/source/gdi/pdfobjectcopier.cxx |8 vcl/source/gdi/pdfwriter.cxx|3 vcl/source/gdi/pdfwriter_impl.cxx |3 vcl/source/gdi/pdfwriter_impl2.cxx |2 vcl/source/gdi/print2.cxx | 1229 --- vcl/source/outdev/transparent.cxx | 1237 +++- 10 files changed, 1249 insertions(+), 1256 deletions(-) New commits: commit 3ab647fa6cb0587668f93bea0b8de9237b71a0cc Author: Chris Sherlock AuthorDate: Tue Aug 31 03:51:23 2021 +1000 Commit: Tomaž Vajngerl CommitDate: Tue Aug 31 15:16:19 2021 +0200 vcl: move RemoveTransparenciesFromMetaFile() to outdev/transparent.cxx Don't know why an OutputDevice function was used in print2.cxx, but definitely needs to be in the outdev source directory, and transparent.cxx is the most appropriate place to add this. To be honest, that function only operates on metafiles, so perhaps we should make this part of GDIMetafile, so added a TODO. Also, a number of local header files (all to do with PDFs) needed to become module local headers, so I have moved these to the vcl/inc/pdf directory. Change-Id: I1feb8e5e8aedc7399740a035beacd2dad3de317f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121321 Tested-by: Tomaž Vajngerl Reviewed-by: Tomaž Vajngerl diff --git a/solenv/clang-format/excludelist b/solenv/clang-format/excludelist index 7d3055c3c12d..ac3161286bc4 100644 --- a/solenv/clang-format/excludelist +++ b/solenv/clang-format/excludelist @@ -14488,6 +14488,8 @@ vcl/inc/osx/salsys.h vcl/inc/osx/saltimer.h vcl/inc/osx/vclnsapp.h vcl/inc/outdev.h +vcl/inc/pdf/pdffontcache.hxx +vcl/inc/pdf/pdfwriter_impl.hxx vcl/inc/ppdparser.hxx vcl/inc/print.h vcl/inc/printdlg.hxx @@ -14982,10 +14984,8 @@ vcl/source/gdi/mtfxmldump.cxx vcl/source/gdi/oldprintadaptor.cxx vcl/source/gdi/pdfextoutdevdata.cxx vcl/source/gdi/pdffontcache.cxx -vcl/source/gdi/pdffontcache.hxx vcl/source/gdi/pdfwriter.cxx vcl/source/gdi/pdfwriter_impl.cxx -vcl/source/gdi/pdfwriter_impl.hxx vcl/source/gdi/pdfwriter_impl2.cxx vcl/source/gdi/print.cxx vcl/source/gdi/print2.cxx diff --git a/vcl/source/gdi/pdfbuildin_fonts.hxx b/vcl/inc/pdf/pdfbuildin_fonts.hxx similarity index 100% rename from vcl/source/gdi/pdfbuildin_fonts.hxx rename to vcl/inc/pdf/pdfbuildin_fonts.hxx diff --git a/vcl/source/gdi/pdffontcache.hxx b/vcl/inc/pdf/pdffontcache.hxx similarity index 100% rename from vcl/source/gdi/pdffontcache.hxx rename to vcl/inc/pdf/pdffontcache.hxx diff --git a/vcl/source/gdi/pdfwriter_impl.hxx b/vcl/inc/pdf/pdfwriter_impl.hxx similarity index 99% rename from vcl/source/gdi/pdfwriter_impl.hxx rename to vcl/inc/pdf/pdfwriter_impl.hxx index e594d6332683..c345fbf23d42 100644 --- a/vcl/source/gdi/pdfwriter_impl.hxx +++ b/vcl/inc/pdf/pdfwriter_impl.hxx @@ -16,8 +16,8 @@ * 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_VCL_SOURCE_GDI_PDFWRITER_IMPL_HXX -#define INCLUDED_VCL_SOURCE_GDI_PDFWRITER_IMPL_HXX + +#pragma once #include #include @@ -54,8 +54,8 @@ #include #include -#include "pdffontcache.hxx" -#include "pdfbuildin_fonts.hxx" +#include +#include class StyleSettings; class FontSelectPattern; @@ -1274,6 +1274,4 @@ public: } // namespace vcl -#endif //_VCL_PDFEXPORT_HXX - /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/vcl/source/gdi/pdfbuildin_fonts.cxx b/vcl/source/gdi/pdfbuildin_fonts.cxx index 92cf2c7e2145..a821b7cb253c 100644 --- a/vcl/source/gdi/pdfbuildin_fonts.cxx +++ b/vcl/source/gdi/pdfbuildin_fonts.cxx @@ -17,10 +17,10 @@ * the License at http://www.apache.org/licenses/LICENSE-2.0 . */ -#include "pdfbuildin_fonts.hxx" - #include +#include + namespace vcl::pdf { OString BuildinFont::getNameObject() const diff --git a/vcl/source/gdi/pdffontcache.cxx b/vcl/source/gdi/pdffontcache.cxx index b79753c0ffb4..e7206701562f 100644 --- a/vcl/source/gdi/pdffontcache.cxx +++ b/vcl/source/gdi/pdffontcache.cxx @@ -17,14 +17,13 @@ * the License at http://www.apache.org/licenses/LICENSE-2.0 . */ -#include - #include #include +#include #include -#include "pdffontcache.hxx" +#include using namespace vcl; diff --git a/vcl/source/gdi/pdfobjectcopier.cxx b/vcl/source/gdi/pdfobjectcopier.cxx index 35dae59237ee..1372d419ce99 100644 --- a/vcl/source/gdi/pdfobjectcopier.cxx +++ b/vcl/source/gdi/pdfobjectcopier.cxx @@ -7,17 +7,17 @@ * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ -#include - -#include #include #include +#include #include #include + #include #include -#include "pdfwriter_impl.hxx" +#include +#include namespace vcl { diff
[Libreoffice-commits] core.git: solenv/clang-format vcl/inc vcl/source
solenv/clang-format/excludelist |1 vcl/inc/accel.h | 41 vcl/inc/accel.hxx | 15 +- vcl/source/window/accel.cxx |1 vcl/source/window/accmgr.cxx|1 vcl/source/window/keycod.cxx|2 - 6 files changed, 15 insertions(+), 46 deletions(-) New commits: commit 7a8d7c9bd97dd52bde2182e395167f2e3cc9fda6 Author: Caolán McNamara AuthorDate: Wed Aug 4 20:18:11 2021 +0100 Commit: Caolán McNamara CommitDate: Thu Aug 5 11:50:41 2021 +0200 merge accel.h and accel.hxx now both are vcl internals Change-Id: If73604d1e329f089a357021bdce2163f6f059160 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120014 Tested-by: Jenkins Reviewed-by: Caolán McNamara diff --git a/solenv/clang-format/excludelist b/solenv/clang-format/excludelist index c78867fd03db..83baec466610 100644 --- a/solenv/clang-format/excludelist +++ b/solenv/clang-format/excludelist @@ -14431,7 +14431,6 @@ vcl/inc/PhysicalFontFamily.hxx vcl/inc/ResampleKernel.hxx vcl/inc/WidgetThemeLibraryTypes.hxx vcl/inc/bitmap/bmpfast.hxx -vcl/inc/accel.h vcl/inc/accel.hxx vcl/inc/accmgr.hxx vcl/inc/brdwin.hxx diff --git a/vcl/inc/accel.h b/vcl/inc/accel.h deleted file mode 100644 index 0c27a5411983.. --- a/vcl/inc/accel.h +++ /dev/null @@ -1,41 +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_VCL_INC_ACCEL_H -#define INCLUDED_VCL_INC_ACCEL_H - -#include - -class Accelerator; - -class ImplAccelEntry -{ -public: -sal_uInt16 mnId; -vcl::KeyCodemaKeyCode; -Accelerator*mpAccel; -Accelerator*mpAutoAccel; -boolmbEnabled; -}; - -bool ImplGetKeyCode( KeyFuncType eFunc, sal_uInt16& rCode1, sal_uInt16& rCode2, sal_uInt16& rCode3, sal_uInt16& rCode4 ); - -#endif // INCLUDED_VCL_INC_ACCEL_H - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/vcl/inc/accel.hxx b/vcl/inc/accel.hxx index 53677cfcfb7c..fc763bd58f3d 100644 --- a/vcl/inc/accel.hxx +++ b/vcl/inc/accel.hxx @@ -26,9 +26,20 @@ #include class ImplAccelData; -class ImplAccelEntry; class CommandEvent; +class Accelerator; + +class ImplAccelEntry +{ +public: +sal_uInt16 mnId; +vcl::KeyCodemaKeyCode; +Accelerator*mpAccel; +Accelerator*mpAutoAccel; +boolmbEnabled; +}; + class Accelerator { friend class ImplAccelManager; @@ -73,4 +84,6 @@ public: Accelerator&operator=( const Accelerator& rAccel ); }; +bool ImplGetKeyCode( KeyFuncType eFunc, sal_uInt16& rCode1, sal_uInt16& rCode2, sal_uInt16& rCode3, sal_uInt16& rCode4 ); + /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/vcl/source/window/accel.cxx b/vcl/source/window/accel.cxx index 1a0039bd2e0c..14861258c352 100644 --- a/vcl/source/window/accel.cxx +++ b/vcl/source/window/accel.cxx @@ -20,7 +20,6 @@ #include #include #include -#include #include #include #include diff --git a/vcl/source/window/accmgr.cxx b/vcl/source/window/accmgr.cxx index c588bb4d8f5a..26ea9846e8dc 100644 --- a/vcl/source/window/accmgr.cxx +++ b/vcl/source/window/accmgr.cxx @@ -18,7 +18,6 @@ */ -#include #include #include diff --git a/vcl/source/window/keycod.cxx b/vcl/source/window/keycod.cxx index 349e87ecbf43..e0ab290486ff 100644 --- a/vcl/source/window/keycod.cxx +++ b/vcl/source/window/keycod.cxx @@ -19,7 +19,7 @@ #include -#include +#include #include #include
[Libreoffice-commits] core.git: solenv/clang-format vcl/inc vcl/source
solenv/clang-format/blacklist|6 +++--- vcl/inc/graphic/UnoGraphic.hxx |4 ++-- vcl/source/gdi/graph.cxx | 22 -- vcl/source/graphic/UnoGraphic.cxx|3 ++- vcl/source/graphic/UnoGraphicDescriptor.cxx |2 +- vcl/source/graphic/UnoGraphicProvider.cxx|4 ++-- vcl/source/graphic/UnoGraphicTransformer.cxx |4 ++-- 7 files changed, 20 insertions(+), 25 deletions(-) New commits: commit 185a7a1868f8bc46924e03b77bc36361c3af8919 Author: Tomaž VajngerlDate: Sun Mar 18 08:22:51 2018 +0900 use UnoGraphic directly in GetXGraphic, move hxx to inc/graphic Change-Id: I6f170709255f396e82591572efef399fa438dc0e Reviewed-on: https://gerrit.libreoffice.org/52145 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl diff --git a/solenv/clang-format/blacklist b/solenv/clang-format/blacklist index 5e1551bdcc14..407db28b157d 100644 --- a/solenv/clang-format/blacklist +++ b/solenv/clang-format/blacklist @@ -17575,6 +17575,9 @@ vcl/inc/fontattributes.hxx vcl/inc/fontinstance.hxx vcl/inc/fontselect.hxx vcl/inc/fontsubset.hxx +vcl/inc/graphic/UnoGraphic.hxx +vcl/inc/graphic/UnoGraphicDescriptor.hxx +vcl/inc/graphic/UnoGraphicTransformer.hxx vcl/inc/headless/svpbmp.hxx vcl/inc/headless/svpcairotextrender.hxx vcl/inc/headless/svpdummies.hxx @@ -18207,13 +18210,10 @@ vcl/source/gdi/wall.cxx vcl/source/graphic/GraphicObject.cxx vcl/source/graphic/GraphicObject2.cxx vcl/source/graphic/UnoGraphic.cxx -vcl/source/graphic/UnoGraphic.hxx vcl/source/graphic/UnoGraphicDescriptor.cxx -vcl/source/graphic/UnoGraphicDescriptor.hxx vcl/source/graphic/UnoGraphicObject.cxx vcl/source/graphic/UnoGraphicProvider.cxx vcl/source/graphic/UnoGraphicTransformer.cxx -vcl/source/graphic/UnoGraphicTransformer.hxx vcl/source/graphic/grfattr.cxx vcl/source/graphic/grfcache.cxx vcl/source/graphic/grfcache.hxx diff --git a/vcl/source/graphic/UnoGraphic.hxx b/vcl/inc/graphic/UnoGraphic.hxx similarity index 97% rename from vcl/source/graphic/UnoGraphic.hxx rename to vcl/inc/graphic/UnoGraphic.hxx index f987d902eace..e0ec65d83a31 100644 --- a/vcl/source/graphic/UnoGraphic.hxx +++ b/vcl/inc/graphic/UnoGraphic.hxx @@ -25,8 +25,8 @@ #include #include -#include "UnoGraphicDescriptor.hxx" -#include "UnoGraphicTransformer.hxx" +#include +#include #include diff --git a/vcl/source/graphic/UnoGraphicDescriptor.hxx b/vcl/inc/graphic/UnoGraphicDescriptor.hxx similarity index 100% rename from vcl/source/graphic/UnoGraphicDescriptor.hxx rename to vcl/inc/graphic/UnoGraphicDescriptor.hxx diff --git a/vcl/source/graphic/UnoGraphicTransformer.hxx b/vcl/inc/graphic/UnoGraphicTransformer.hxx similarity index 100% rename from vcl/source/graphic/UnoGraphicTransformer.hxx rename to vcl/inc/graphic/UnoGraphicTransformer.hxx diff --git a/vcl/source/gdi/graph.cxx b/vcl/source/gdi/graph.cxx index 1b753414b60e..6d9d972efc55 100644 --- a/vcl/source/gdi/graph.cxx +++ b/vcl/source/gdi/graph.cxx @@ -31,6 +31,7 @@ #include #include #include +#include using namespace ::com::sun::star; @@ -360,25 +361,18 @@ const BitmapEx& Graphic::GetBitmapExRef() const return mxImpGraphic->ImplGetBitmapExRef(); } -uno::Reference< graphic::XGraphic > Graphic::GetXGraphic() const +uno::Reference Graphic::GetXGraphic() const { -uno::Reference< graphic::XGraphic > xRet; +uno::Reference xGraphic; -if( GetType() != GraphicType::NONE ) +if (GetType() != GraphicType::NONE) { -uno::Reference < uno::XComponentContext > xContext( ::comphelper::getProcessComponentContext() ); -uno::Reference< graphic::XGraphicProvider > xProv( graphic::GraphicProvider::create( xContext ) ); - -uno::Sequence< beans::PropertyValue > aLoadProps( 1 ); -OUString aURL = "private:memorygraphic/" + OUString::number( reinterpret_cast< sal_Int64 >( this ) ); - -aLoadProps[ 0 ].Name = "URL"; -aLoadProps[ 0 ].Value <<= aURL; - -xRet = xProv->queryGraphic( aLoadProps ); +unographic::Graphic* pUnoGraphic = new unographic::Graphic; +pUnoGraphic->init(*this); +xGraphic = pUnoGraphic; } -return xRet; +return xGraphic; } Size Graphic::GetPrefSize() const diff --git a/vcl/source/graphic/UnoGraphic.cxx b/vcl/source/graphic/UnoGraphic.cxx index 5821a254da92..bc09e40d045d 100644 --- a/vcl/source/graphic/UnoGraphic.cxx +++ b/vcl/source/graphic/UnoGraphic.cxx @@ -17,11 +17,12 @@ * the License at http://www.apache.org/licenses/LICENSE-2.0 . */ +#include + #include #include #include #include -#include "UnoGraphic.hxx" #include #include #include diff --git a/vcl/source/graphic/UnoGraphicDescriptor.cxx b/vcl/source/graphic/UnoGraphicDescriptor.cxx index cdc54568d387..d8281f13732d 100644 --- a/vcl/source/graphic/UnoGraphicDescriptor.cxx +++