Pencil2D Animation
Download Community News Docs Contribute
  • Overview
  • Articles
  • Code
  •  
  • Class List
  • Class Index
  • Class Hierarchy
  • Class Members
  • File List
Loading...
Searching...
No Matches
  • app
  • src
bucketoptionswidget.h
1/*
2
3Pencil2D - Traditional Animation Software
4Copyright (C) 2005-2007 Patrick Corrieri & Pascal Naidon
5Copyright (C) 2012-2020 Matthew Chiawen Chang
6
7This program is free software; you can redistribute it and/or
8modify it under the terms of the GNU General Public License
9as published by the Free Software Foundation; version 2 of the License.
10
11This program is distributed in the hope that it will be useful,
12but WITHOUT ANY WARRANTY; without even the implied warranty of
13MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14GNU General Public License for more details.
15
16*/
17#ifndef BUCKETOPTIONSWIDGET_H
18#define BUCKETOPTIONSWIDGET_H
19
20#include <QWidget>
21#include "pencildef.h"
22
23class Editor;
24class Layer;
25
26namespace Ui {
27class BucketOptionsWidget;
28}
29
30class BucketOptionsWidget : public QWidget
31{
32 Q_OBJECT
33
34public:
35 explicit BucketOptionsWidget(Editor* editor, QWidget* parent);
36 ~BucketOptionsWidget();
37
38 void setStrokeWidth(qreal value);
39 void setColorToleranceEnabled(bool enabled);
40 void setFillExpandEnabled(bool enabled);
41 void setFillExpand(int value);
42 void setColorTolerance(int tolerance);
43 void setFillReferenceMode(int referenceMode);
44 void setFillMode(int mode);
45
46 void onPropertyChanged(ToolType, const ToolPropertyType propertyType);
47 void onLayerChanged(int);
48
49private:
50 void updatePropertyVisibility();
51
52 Ui::BucketOptionsWidget *ui;
53 Editor* mEditor = nullptr;
54
55 const static int MAX_EXPAND = 25;
56 const static int MAX_COLOR_TOLERANCE = 100;
57 const static int MAX_STROKE_THICKNESS = 200;
58};
59
60#endif // BUCKETOPTIONSWIDGET_H
BucketOptionsWidget
Definition: bucketoptionswidget.h:31
Editor
Definition: editor.h:71
Layer
Definition: layer.h:33
QObject::Q_OBJECT
Q_OBJECTQ_OBJECT
QObject::parent
QObject * parent() const const
QWidget
QWidget::enabled
enabled
Generated on Thu May 8 2025 04:47:53 for Pencil2D by doxygen 1.9.6 based on revision 4513250b1d5b1a3676ec0e67b06b7a885ceaae39