~ubuntu-branches/ubuntu/precise/koffice/precise

« back to all changes in this revision

Viewing changes to krita/plugins/paintops/defaultpaintops/airbrush/kis_airbrushop_settings_widget.cpp

  • Committer: Bazaar Package Importer
  • Author(s): Jonathan Riddell
  • Date: 2010-09-21 15:36:35 UTC
  • mfrom: (1.4.1 upstream) (60.2.11 maverick)
  • Revision ID: james.westby@ubuntu.com-20100921153635-6tejqkiro2u21ydi
Tags: 1:2.2.2-0ubuntu3
Add kubuntu_03_fix-crash-on-closing-sqlite-connection-2.2.2.diff and
kubuntu_04_support-large-memo-values-for-msaccess-2.2.2.diff as
recommended by upstream http://kexi-
project.org/wiki/wikiview/index.php@Kexi2.2_Patches.html#sqlite_stab
ility

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/*
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>
7
 
 *
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.
12
 
 *
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.
17
 
 *
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.
21
 
 */
22
 
 
23
 
#include "kis_airbrushop_settings_widget.h"
24
 
#include "kis_airbrushop_settings.h"
25
 
#include <kis_properties_configuration.h>
26
 
#include <kis_brush_option.h>
27
 
#include <kis_paintop_options_widget.h>
28
 
#include <kis_pressure_darken_option.h>
29
 
#include <kis_pressure_opacity_option.h>
30
 
#include <kis_pressure_size_option.h>
31
 
#include <kis_paint_action_type_option.h>
32
 
 
33
 
KisAirbrushOpSettingsWidget::KisAirbrushOpSettingsWidget(QWidget* parent)
34
 
        : KisPaintOpOptionsWidget(parent)
35
 
{
36
 
    setObjectName("airbrush option widget");
37
 
 
38
 
    m_brushOption = new KisBrushOption();
39
 
 
40
 
    m_brushOption->setAutoBrush(true);
41
 
    m_brushOption->setPredefinedBrushes(false);
42
 
    m_brushOption->setCustomBrush(false);
43
 
    m_brushOption->setTextBrush(false);
44
 
 
45
 
    addPaintOpOption(m_brushOption);
46
 
 
47
 
}
48
 
 
49
 
KisAirbrushOpSettingsWidget::~KisAirbrushOpSettingsWidget()
50
 
{
51
 
    delete m_brushOption;
52
 
}
53
 
 
54
 
KisPropertiesConfiguration* KisAirbrushOpSettingsWidget::configuration() const
55
 
{
56
 
    KisAirbrushOpSettings *config = new KisAirbrushOpSettings();
57
 
    config->setOptionsWidget(const_cast<KisAirbrushOpSettingsWidget*>(this));
58
 
    config->setProperty("paintop", "airbrush"); // XXX: make this a const id string
59
 
    writeConfiguration(config);
60
 
    return config;
61
 
}
62
 
 
63
 
void KisAirbrushOpSettingsWidget::setImage(KisImageWSP image)
64
 
{
65
 
    m_brushOption->setImage(image);
66
 
}
67
 
 
68
 
#include "kis_airbrushop_settings_widget.moc"