Skip to content

armgit / krita

Public Imported from GitHub
0

Krita is a free and open source cross-platform application that offers an end-to-end solution for creating digital art files from scratch built on the KDE and Qt frameworks.

C++
1.2 KB
Raw Blame
/* This file is part of the KDE project
 * SPDX-FileCopyrightText: 2007 Thomas Zander <[email protected]>
 *
 * SPDX-License-Identifier: LGPL-2.0-or-later
 */
#ifndef PATHTOOLOPTIONWIDGET_H
#define PATHTOOLOPTIONWIDGET_H

#include <QWidget>
#include <QFlags>

#include <ui_PathToolOptionWidgetBase.h>

class KoPathTool;
class KoPathShape;
class KoShapeConfigWidgetBase;
class KoCanvasBase;


class PathToolOptionWidget : public QWidget
{
    Q_OBJECT
public:
    enum Type {
        PlainPath = 1,
        ParametricShape = 2
    };
    Q_DECLARE_FLAGS(Types, Type)

    explicit PathToolOptionWidget(KoPathTool *tool, QWidget *parent = 0);
    ~PathToolOptionWidget() override;

public Q_SLOTS:
    void setSelectionType(int type);
    void setCurrentShape(KoPathShape *pathShape);

private Q_SLOTS:
    void slotShapePropertyChanged();

Q_SIGNALS:
    void sigRequestUpdateActions();

protected:
    void showEvent(QShowEvent *event) override;

private:
    Ui::PathToolOptionWidgetBase widget;

    KoPathShape *m_currentShape;
    QString m_currentShapeId;
    KoShapeConfigWidgetBase *m_currentPanel;
    KoCanvasBase *m_canvas;
};

Q_DECLARE_OPERATORS_FOR_FLAGS(PathToolOptionWidget::Types)

#endif