2
* Copyright (c) 2002 Patrick Julien <freak@codepimps.org>
3
* Copyright (c) 2004-2008 Boudewijn Rempt <boud@valdyas.org>
4
* Copyright (c) 2004 Clarence Dang <dang@kde.org>
5
* Copyright (c) 2004 Adrian Page <adrian@pagenet.plus.com>
6
* Copyright (c) 2004 Cyrille Berger <cberger@cberger.net>
8
* This program is free software; you can redistribute it and/or modify
9
* it under the terms of the GNU General Public License as published by
10
* the Free Software Foundation; either version 2 of the License, or
11
* (at your option) any later version.
13
* This program is distributed in the hope that it will be useful,
14
* but WITHOUT ANY WARRANTY; without even the implied warranty of
15
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16
* GNU General Public License for more details.
18
* You should have received a copy of the GNU General Public License
19
* along with this program; if not, write to the Free Software
20
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
23
#include "kis_penop_settings_widget.h"
24
#include "kis_brush_based_paintop_settings.h"
25
#include <kis_properties_configuration.h>
26
#include <kis_pressure_darken_option.h>
27
#include <kis_pressure_opacity_option.h>
28
#include <kis_pressure_size_option.h>
29
#include <kis_paint_action_type_option.h>
30
#include <kis_curve_option_widget.h>
32
KisPenOpSettingsWidget::KisPenOpSettingsWidget(QWidget* parent)
33
: KisBrushBasedPaintopOptionWidget(parent)
35
setObjectName("brush option widget");
37
addPaintOpOption(new KisCurveOptionWidget(new KisPressureSizeOption()));
38
addPaintOpOption(new KisCurveOptionWidget(new KisPressureOpacityOption()));
39
addPaintOpOption(new KisCurveOptionWidget(new KisPressureDarkenOption()));
40
addPaintOpOption(new KisPaintActionTypeOption());
44
KisPenOpSettingsWidget::~KisPenOpSettingsWidget()
48
KisPropertiesConfiguration* KisPenOpSettingsWidget::configuration() const
50
KisBrushBasedPaintOpSettings *config = new KisBrushBasedPaintOpSettings();
51
config->setOptionsWidget(const_cast<KisPenOpSettingsWidget*>(this));
52
config->setProperty("paintop", "pencil"); // XXX: make this a const id string
53
writeConfiguration(config);
57
#include "kis_penop_settings_widget.moc"