bump product version to 6.3.0.0.beta1
[LibreOffice.git] / vcl / qt5 / Qt5SvpGraphics.cxx
blobf746381e65615e78d9f52791f44c16fef64f3b6a
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
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/.
8 */
10 #include <sal/config.h>
11 #include <sal/log.hxx>
13 #include <config_cairo_canvas.h>
15 #include <Qt5SvpGraphics.hxx>
16 #include <Qt5SvpSurface.hxx>
18 #include <QtWidgets/QWidget>
20 Qt5SvpGraphics::Qt5SvpGraphics(QWidget* pQWidget)
21 : SvpSalGraphics()
22 , m_pQWidget(pQWidget)
26 Qt5SvpGraphics::~Qt5SvpGraphics() {}
28 void Qt5SvpGraphics::updateQWidget() const
30 if (m_pQWidget)
31 m_pQWidget->update(m_pQWidget->rect());
34 #if ENABLE_CAIRO_CANVAS
36 bool Qt5SvpGraphics::SupportsCairo() const { return true; }
38 cairo::SurfaceSharedPtr
39 Qt5SvpGraphics::CreateSurface(const cairo::CairoSurfaceSharedPtr& rSurface) const
41 return cairo::SurfaceSharedPtr(new cairo::Qt5SvpSurface(rSurface));
44 cairo::SurfaceSharedPtr Qt5SvpGraphics::CreateSurface(const OutputDevice& /*rRefDevice*/, int x,
45 int y, int width, int height) const
47 return cairo::SurfaceSharedPtr(new cairo::Qt5SvpSurface(this, x, y, width, height));
50 #endif
52 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */