Krita Source Code Documentation
Loading...
Searching...
No Matches
DefaultToolGeometryWidget.h
Go to the documentation of this file.
1/* This file is part of the KDE project
2 * SPDX-FileCopyrightText: 2007 Martin Pfeiffer <hubipete@gmx.net>
3 * SPDX-FileCopyrightText: 2007 Jan Hambrecht <jaham@gmx.net>
4 * SPDX-FileCopyrightText: 2010 Thomas Zander <zander@kde.org>
5 *
6 * SPDX-License-Identifier: LGPL-2.0-or-later
7 */
8#ifndef DEFAULTTOOLGEOMETRYWIDGET_H
9#define DEFAULTTOOLGEOMETRYWIDGET_H
10
11#include <ui_DefaultToolGeometryWidget.h>
12#include <KoFlake.h>
13
14#include <QWidget>
15
16
19
20class DefaultToolGeometryWidget : public QWidget, Ui::DefaultToolGeometryWidget
21{
22 Q_OBJECT
23public:
24 explicit DefaultToolGeometryWidget(KoInteractionTool *tool, QWidget *parent = 0);
26
28 void setUnit(const KoUnit &unit);
29
30 bool useUniformScaling() const;
31
32protected:
33 void showEvent(QShowEvent *event) override;
34
35private Q_SLOTS:
37 void resourceChanged(int key, const QVariant &res);
38
41
42 void slotUpdateSizeBoxes(bool updateAspect = true);
44 void slotResizeShapes();
45
47
50
51 void slotOpacitySliderChanged(qreal newOpacity);
53
56
57private:
59 QScopedPointer<KisAspectRatioLocker> m_sizeAspectLocker;
61};
62
63#endif
void setUnit(const KoUnit &unit)
Sets the unit used by the unit aware child widgets.
QScopedPointer< KisAspectRatioLocker > m_sizeAspectLocker
void slotUpdateSizeBoxes(bool updateAspect=true)
void showEvent(QShowEvent *event) override
DefaultToolGeometryWidget(KoInteractionTool *tool, QWidget *parent=0)
void resourceChanged(int key, const QVariant &res)
void slotOpacitySliderChanged(qreal newOpacity)