KQuickImageEditor

resizecommand.h
1/* SPDX-FileCopyrightText: (C) 2020 Carl Schwan <carl@carlschwan.eu>
2 * SPDX-FileCopyrightText: 2021 Noah Davis <noahadvs@gmail.com>
3 * SPDX-License-Identifier: LGPL-2.1-or-later
4 */
5
6#pragma once
7
8#include "undocommand.h"
9
10#include <QImage>
11
12/**
13 * @brief ResizeCommand that resizes the current image.
14 */
16{
17public:
18 /**
19 * Contructor
20 */
21 ResizeCommand(const QSize &resizeSize);
22 ~ResizeCommand() override = default;
23
24 QImage redo(QImage image) override;
25
26 QImage undo(QImage image) override;
27
28private:
29 QImage m_image;
30 QSize m_resizeSize;
31};
ResizeCommand that resizes the current image.
QImage undo(QImage image) override
Revert a change to the document.
QImage redo(QImage image) override
Applies the change to the document.
ResizeCommand(const QSize &resizeSize)
Contructor.
A class implementing the command pattern.
Definition undocommand.h:15
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Fri Dec 27 2024 11:49:24 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.