Commit 08968e7b authored by Victor Wåhlström's avatar Victor Wåhlström

Extracted filter category KoIDs to a separate file

Ref T6560

Differential Revision https://phabricator.kde.org/D14164
parent 55fcc4d4
......@@ -115,6 +115,7 @@ set(kritaimage_LIB_SRCS
processing/kis_transform_processing_visitor.cpp
processing/kis_mirror_processing_visitor.cpp
filter/kis_filter.cc
filter/kis_filter_category_ids.cpp
filter/kis_filter_configuration.cc
filter/kis_color_transformation_configuration.cc
filter/kis_filter_registry.cc
......
......@@ -31,58 +31,6 @@
#include <kis_painter.h>
#include <KoUpdater.h>
KoID KisFilter::categoryAdjust()
{
return KoID("adjust_filters", i18n("Adjust"));
}
KoID KisFilter::categoryArtistic()
{
return KoID("artistic_filters", i18n("Artistic"));
}
KoID KisFilter::categoryBlur()
{
return KoID("blur_filters", i18n("Blur"));
}
KoID KisFilter::categoryColors()
{
return KoID("color_filters", i18n("Colors"));
}
KoID KisFilter::categoryEdgeDetection()
{
return KoID("edge_filters", i18n("Edge Detection"));
}
KoID KisFilter::categoryEmboss()
{
return KoID("emboss_filters", i18n("Emboss"));
}
KoID KisFilter::categoryEnhance()
{
return KoID("enhance_filters", i18n("Enhance"));
}
KoID KisFilter::categoryMap()
{
return KoID("map_filters", i18n("Map"));
}
KoID KisFilter::categoryNonPhotorealistic()
{
return KoID("nonphotorealistic_filters", i18n("Non-photorealistic"));
}
KoID KisFilter::categoryOther()
{
return KoID("other_filters", i18n("Other"));
}
KisFilter::KisFilter(const KoID& _id, const KoID & category, const QString & entry)
: KisBaseProcessor(_id, category, entry),
m_supportsLevelOfDetail(false)
......
......@@ -37,19 +37,6 @@
*/
class KRITAIMAGE_EXPORT KisFilter : public KisBaseProcessor
{
public:
static KoID categoryAdjust();
static KoID categoryArtistic();
static KoID categoryBlur();
static KoID categoryColors();
static KoID categoryEdgeDetection();
static KoID categoryEmboss();
static KoID categoryEnhance();
static KoID categoryMap();
static KoID categoryNonPhotorealistic();
static KoID categoryOther();
public:
/**
......@@ -58,8 +45,6 @@ public:
KisFilter(const KoID& id, const KoID & category, const QString & entry);
~KisFilter() override;
public:
/**
* Override this function with the implementation of your filter.
*
......
/*
* Copyright (c) 2018 Victor Wåhlström <victor.wahlstrom@initiali.se>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public License
* along with this library; see the file COPYING.LIB. If not, write to
* the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
* Boston, MA 02110-1301, USA.
*/
#include "kis_filter_category_ids.h"
#include <klocalizedstring.h>
const KoID FiltersCategoryAdjustId("adjust_filters", i18n("Adjust"));
const KoID FiltersCategoryArtisticId("artistic_filters", i18n("Artistic"));
const KoID FiltersCategoryBlurId("blur_filters", i18n("Blur"));
const KoID FiltersCategoryColorId("color_filters", i18n("Colors"));
const KoID FiltersCategoryEdgeDetectionId("edge_filters", i18n("Edge Detection"));
const KoID FiltersCategoryEmbossId("emboss_filters", i18n("Emboss"));
const KoID FiltersCategoryEnhanceId("enhance_filters", i18n("Enhance"));
const KoID FiltersCategoryMapId("map_filters", i18n("Map"));
const KoID FiltersCategoryNonPhotorealisticId("nonphotorealistic_filters", i18n("Non-photorealistic"));
const KoID FiltersCategoryOtherId("other_filters", i18n("Other"));
/*
* Copyright (c) 2018 Victor Wåhlström <victor.wahlstrom@initiali.se>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public License
* along with this library; see the file COPYING.LIB. If not, write to
* the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
* Boston, MA 02110-1301, USA.
*/
#ifndef _KIS_FILTER_CATEGORY_IDS_H_
#define _KIS_FILTER_CATEGORY_IDS_H_
#include <KoID.h>
#include "kritaimage_export.h"
extern const KoID KRITAIMAGE_EXPORT FiltersCategoryAdjustId;
extern const KoID KRITAIMAGE_EXPORT FiltersCategoryArtisticId;
extern const KoID KRITAIMAGE_EXPORT FiltersCategoryBlurId;
extern const KoID KRITAIMAGE_EXPORT FiltersCategoryColorId;
extern const KoID KRITAIMAGE_EXPORT FiltersCategoryEdgeDetectionId;
extern const KoID KRITAIMAGE_EXPORT FiltersCategoryEmbossId;
extern const KoID KRITAIMAGE_EXPORT FiltersCategoryEnhanceId;
extern const KoID KRITAIMAGE_EXPORT FiltersCategoryMapId;
extern const KoID KRITAIMAGE_EXPORT FiltersCategoryNonPhotorealisticId;
extern const KoID KRITAIMAGE_EXPORT FiltersCategoryOtherId;
#endif // _KIS_FILTER_CATEGORY_IDS_H_
......@@ -20,6 +20,7 @@
#include "kis_wdg_asccdl.h"
#include <kpluginfactory.h>
#include <klocalizedstring.h>
#include <filter/kis_filter_category_ids.h>
#include <filter/kis_filter_registry.h>
#include <filter/kis_color_transformation_configuration.h>
#include <qmath.h>
......@@ -39,7 +40,7 @@ KritaASCCDL::~KritaASCCDL()
}
KisFilterASCCDL::KisFilterASCCDL(): KisColorTransformationFilter(id(), categoryAdjust(), i18n("&Slope, Offset, Power..."))
KisFilterASCCDL::KisFilterASCCDL(): KisColorTransformationFilter(id(), FiltersCategoryAdjustId, i18n("&Slope, Offset, Power..."))
{
setSupportsPainting(true);
setSupportsAdjustmentLayers(true);
......
......@@ -28,6 +28,7 @@
#include "kis_wdg_blur.h"
#include "ui_wdgblur.h"
#include <filter/kis_filter_category_ids.h>
#include <filter/kis_filter_configuration.h>
#include <kis_selection.h>
#include <kis_paint_device.h>
......@@ -36,7 +37,7 @@
#include "kis_lod_transform.h"
KisBlurFilter::KisBlurFilter() : KisFilter(id(), categoryBlur(), i18n("&Blur..."))
KisBlurFilter::KisBlurFilter() : KisFilter(id(), FiltersCategoryBlurId, i18n("&Blur..."))
{
setSupportsPainting(true);
setSupportsAdjustmentLayers(true);
......
......@@ -30,6 +30,7 @@
#include "ui_wdg_gaussian_blur.h"
#include <filter/kis_filter_category_ids.h>
#include <filter/kis_filter_configuration.h>
#include <kis_selection.h>
#include <kis_paint_device.h>
......@@ -40,7 +41,7 @@
#include <math.h>
KisGaussianBlurFilter::KisGaussianBlurFilter() : KisFilter(id(), categoryBlur(), i18n("&Gaussian Blur..."))
KisGaussianBlurFilter::KisGaussianBlurFilter() : KisFilter(id(), FiltersCategoryBlurId, i18n("&Gaussian Blur..."))
{
setSupportsPainting(true);
setSupportsAdjustmentLayers(true);
......
......@@ -29,6 +29,7 @@
#include "ui_wdg_lens_blur.h"
#include <filter/kis_filter_category_ids.h>
#include <filter/kis_filter_configuration.h>
#include <kis_selection.h>
#include <kis_paint_device.h>
......@@ -41,7 +42,7 @@
#include <math.h>
KisLensBlurFilter::KisLensBlurFilter() : KisFilter(id(), categoryBlur(), i18n("&Lens Blur..."))
KisLensBlurFilter::KisLensBlurFilter() : KisFilter(id(), FiltersCategoryBlurId, i18n("&Lens Blur..."))
{
setSupportsPainting(true);
setSupportsAdjustmentLayers(true);
......
......@@ -29,6 +29,7 @@
#include "ui_wdg_motion_blur.h"
#include <filter/kis_filter_category_ids.h>
#include <filter/kis_filter_configuration.h>
#include <kis_selection.h>
#include <kis_paint_device.h>
......@@ -41,7 +42,7 @@
#include <math.h>
KisMotionBlurFilter::KisMotionBlurFilter() : KisFilter(id(), categoryBlur(), i18n("&Motion Blur..."))
KisMotionBlurFilter::KisMotionBlurFilter() : KisFilter(id(), FiltersCategoryBlurId, i18n("&Motion Blur..."))
{
setSupportsPainting(true);
setSupportsAdjustmentLayers(true);
......
......@@ -28,6 +28,7 @@
#include "kis_progress_update_helper.h"
#include <kis_paint_device.h>
#include <kis_selection.h>
#include <filter/kis_filter_category_ids.h>
#include <filter/kis_filter_configuration.h>
#include <kis_processing_information.h>
......@@ -37,7 +38,7 @@
#include <KisSequentialIteratorProgress.h>
KisFilterColorToAlpha::KisFilterColorToAlpha()
: KisFilter(id(), categoryColors(), i18n("&Color to Alpha..."))
: KisFilter(id(), FiltersCategoryColorId, i18n("&Color to Alpha..."))
{
setSupportsPainting(true);
setSupportsAdjustmentLayers(true);
......
......@@ -21,6 +21,7 @@
#include "kis_minmax_filters.h"
#include <KoUpdater.h>
#include <KoChannelInfo.h>
#include <filter/kis_filter_category_ids.h>
#include <filter/kis_filter_configuration.h>
#include <kis_selection.h>
#include <kis_paint_device.h>
......@@ -66,7 +67,7 @@ void minimize(const quint8* s, quint8* d, uint nbpixels)
}
}
KisFilterMax::KisFilterMax() : KisFilter(id(), categoryColors(), i18n("M&aximize Channel"))
KisFilterMax::KisFilterMax() : KisFilter(id(), FiltersCategoryColorId, i18n("M&aximize Channel"))
{
setSupportsPainting(true);
setSupportsLevelOfDetail(true);
......@@ -104,7 +105,7 @@ void KisFilterMax::processImpl(KisPaintDeviceSP device,
}
}
KisFilterMin::KisFilterMin() : KisFilter(id(), categoryColors(), i18n("M&inimize Channel"))
KisFilterMin::KisFilterMin() : KisFilter(id(), FiltersCategoryColorId, i18n("M&inimize Channel"))
{
setSupportsPainting(true);
setColorSpaceIndependence(FULLY_INDEPENDENT);
......
......@@ -38,6 +38,7 @@
#include "KoBasicHistogramProducers.h"
#include <KoColorSpace.h>
#include <KoColorTransformation.h>
#include <filter/kis_filter_category_ids.h>
#include <filter/kis_filter_configuration.h>
#include <kis_paint_device.h>
#include <kis_processing_information.h>
......@@ -85,7 +86,7 @@ ColorsFilters::~ColorsFilters()
//==================================================================
KisAutoContrast::KisAutoContrast() : KisFilter(id(), categoryAdjust(), i18n("&Auto Contrast"))
KisAutoContrast::KisAutoContrast() : KisFilter(id(), FiltersCategoryAdjustId, i18n("&Auto Contrast"))
{
setSupportsPainting(false);
setSupportsThreading(false);
......
......@@ -18,13 +18,14 @@
*/
#include "kis_color_balance_filter.h"
#include <filter/kis_filter_category_ids.h>
#include "filter/kis_color_transformation_configuration.h"
#include "kis_selection.h"
#include "kis_paint_device.h"
#include "kis_processing_information.h"
KisColorBalanceFilter::KisColorBalanceFilter()
: KisColorTransformationFilter(id(), categoryAdjust(), i18n("&Color Balance..."))
: KisColorTransformationFilter(id(), FiltersCategoryAdjustId, i18n("&Color Balance..."))
{
setShortcut(QKeySequence(Qt::CTRL + Qt::Key_B));
setSupportsPainting(true);
......
......@@ -39,6 +39,7 @@
#include "KoBasicHistogramProducers.h"
#include <KoColorSpace.h>
#include <KoColorTransformation.h>
#include <filter/kis_filter_category_ids.h>
#include <filter/kis_color_transformation_configuration.h>
#include <kis_paint_device.h>
#include <kis_processing_information.h>
......@@ -55,7 +56,7 @@
#include <kis_iterator_ng.h>
KisDesaturateFilter::KisDesaturateFilter()
: KisColorTransformationFilter(id(), categoryAdjust(), i18n("&Desaturate..."))
: KisColorTransformationFilter(id(), FiltersCategoryAdjustId, i18n("&Desaturate..."))
{
setShortcut(QKeySequence(Qt::CTRL + Qt::SHIFT + Qt::Key_U));
setSupportsPainting(true);
......
......@@ -19,6 +19,7 @@
#include "kis_hsv_adjustment_filter.h"
#include <filter/kis_filter_category_ids.h>
#include <filter/kis_color_transformation_configuration.h>
#include <kis_selection.h>
#include <kis_paint_device.h>
......@@ -90,7 +91,7 @@ inline const WidgetSlidersConfig& getCurrentWidgetConfig(int type, bool colorize
}
KisHSVAdjustmentFilter::KisHSVAdjustmentFilter()
: KisColorTransformationFilter(id(), categoryAdjust(), i18n("&HSV Adjustment..."))
: KisColorTransformationFilter(id(), FiltersCategoryAdjustId, i18n("&HSV Adjustment..."))
{
setShortcut(QKeySequence(Qt::CTRL + Qt::Key_U));
setSupportsPainting(true);
......
......@@ -42,6 +42,7 @@
#include "kis_bookmarked_configuration_manager.h"
#include "kis_config_widget.h"
#include <filter/kis_filter_category_ids.h>
#include <filter/kis_filter_configuration.h>
#include <kis_selection.h>
#include <kis_paint_device.h>
......@@ -52,7 +53,7 @@
#include "widgets/kis_curve_widget.h"
KisMultiChannelFilter::KisMultiChannelFilter(const KoID& id, const QString &entry)
: KisColorTransformationFilter(id, categoryAdjust(), entry)
: KisColorTransformationFilter(id, FiltersCategoryAdjustId, entry)
{
setSupportsPainting(true);
setColorSpaceIndependence(TO_LAB16);
......
......@@ -19,6 +19,7 @@
#include "kis_wdg_convert_height_to_normal_map.h"
#include <kpluginfactory.h>
#include <klocalizedstring.h>
#include <filter/kis_filter_category_ids.h>
#include <filter/kis_filter_registry.h>
#include <filter/kis_filter_configuration.h>
#include "kis_lod_transform.h"
......@@ -37,7 +38,7 @@ KritaConvertHeightToNormalMapFilter::~KritaConvertHeightToNormalMapFilter()
{
}
KisConvertHeightToNormalMapFilter::KisConvertHeightToNormalMapFilter(): KisFilter(id(), categoryEdgeDetection(), i18n("&Height to Normal Map..."))
KisConvertHeightToNormalMapFilter::KisConvertHeightToNormalMapFilter(): KisFilter(id(), FiltersCategoryEdgeDetectionId, i18n("&Height to Normal Map..."))
{
setSupportsPainting(true);
setSupportsAdjustmentLayers(true);
......
......@@ -29,6 +29,7 @@
#include <kis_convolution_kernel.h>
#include <kis_convolution_painter.h>
#include <filter/kis_filter_category_ids.h>
#include <filter/kis_filter_configuration.h>
#include <kis_selection.h>
#include <kis_paint_device.h>
......@@ -56,7 +57,7 @@ KritaConvolutionFilters::~KritaConvolutionFilters()
}
KisSharpenFilter::KisSharpenFilter()
: KisConvolutionFilter(id(), categoryEnhance(), i18n("&Sharpen"))
: KisConvolutionFilter(id(), FiltersCategoryEnhanceId, i18n("&Sharpen"))
{
setSupportsPainting(true);
setShowConfigurationWidget(false);
......@@ -70,7 +71,7 @@ KisSharpenFilter::KisSharpenFilter()
}
KisMeanRemovalFilter::KisMeanRemovalFilter()
: KisConvolutionFilter(id(), categoryEnhance(), i18n("&Mean Removal"))
: KisConvolutionFilter(id(), FiltersCategoryEnhanceId, i18n("&Mean Removal"))
{
setSupportsPainting(false);
setShowConfigurationWidget(false);
......@@ -84,7 +85,7 @@ KisMeanRemovalFilter::KisMeanRemovalFilter()
}
KisEmbossLaplascianFilter::KisEmbossLaplascianFilter()
: KisConvolutionFilter(id(), categoryEmboss(), i18n("Emboss (Laplacian)"))
: KisConvolutionFilter(id(), FiltersCategoryEmbossId, i18n("Emboss (Laplacian)"))
{
setSupportsPainting(false);
setShowConfigurationWidget(false);
......@@ -99,7 +100,7 @@ KisEmbossLaplascianFilter::KisEmbossLaplascianFilter()
}
KisEmbossInAllDirectionsFilter::KisEmbossInAllDirectionsFilter()
: KisConvolutionFilter(id(), categoryEmboss(), i18n("Emboss in All Directions"))
: KisConvolutionFilter(id(), FiltersCategoryEmbossId, i18n("Emboss in All Directions"))
{
setSupportsPainting(false);
setShowConfigurationWidget(false);
......@@ -114,7 +115,7 @@ KisEmbossInAllDirectionsFilter::KisEmbossInAllDirectionsFilter()
}
KisEmbossHorizontalVerticalFilter::KisEmbossHorizontalVerticalFilter()
: KisConvolutionFilter(id(), categoryEmboss(), i18n("Emboss Horizontal && Vertical"))
: KisConvolutionFilter(id(), FiltersCategoryEmbossId, i18n("Emboss Horizontal && Vertical"))
{
setSupportsPainting(false);
setShowConfigurationWidget(false);
......@@ -129,7 +130,7 @@ KisEmbossHorizontalVerticalFilter::KisEmbossHorizontalVerticalFilter()
}
KisEmbossVerticalFilter::KisEmbossVerticalFilter()
: KisConvolutionFilter(id(), categoryEmboss(), i18n("Emboss Vertical Only"))
: KisConvolutionFilter(id(), FiltersCategoryEmbossId, i18n("Emboss Vertical Only"))
{
setSupportsPainting(false);
setShowConfigurationWidget(false);
......@@ -144,7 +145,7 @@ KisEmbossVerticalFilter::KisEmbossVerticalFilter()
}
KisEmbossHorizontalFilter::KisEmbossHorizontalFilter() :
KisConvolutionFilter(id(), categoryEmboss(), i18n("Emboss Horizontal Only"))
KisConvolutionFilter(id(), FiltersCategoryEmbossId, i18n("Emboss Horizontal Only"))
{
setSupportsPainting(false);
setShowConfigurationWidget(false);
......@@ -159,7 +160,7 @@ KisEmbossHorizontalFilter::KisEmbossHorizontalFilter() :
}
KisEmbossDiagonalFilter::KisEmbossDiagonalFilter()
: KisConvolutionFilter(id(), categoryEdgeDetection(), i18n("Top Edge Detection"))
: KisConvolutionFilter(id(), FiltersCategoryEdgeDetectionId, i18n("Top Edge Detection"))
{
setSupportsPainting(false);
setShowConfigurationWidget(false);
......
......@@ -16,12 +16,13 @@
*/
#include "DodgeBurn.h"
#include <filter/kis_filter_category_ids.h>
#include <filter/kis_color_transformation_configuration.h>
#include <kis_paint_device.h>
#include "ui_DodgeBurnConfigurationBaseWidget.h"
KisFilterDodgeBurn::KisFilterDodgeBurn(const QString& id, const QString& prefix, const QString& name ) : KisColorTransformationFilter(KoID(id, name), categoryAdjust(), name), m_prefix(prefix)
KisFilterDodgeBurn::KisFilterDodgeBurn(const QString& id, const QString& prefix, const QString& name ) : KisColorTransformationFilter(KoID(id, name), FiltersCategoryAdjustId, name), m_prefix(prefix)
{
setColorSpaceIndependence(FULLY_INDEPENDENT);
setSupportsPainting(true);
......
......@@ -24,6 +24,7 @@
#include <KoColorSpaceRegistry.h>
#include <KoColorModelStandardIds.h>
#include <filter/kis_filter_category_ids.h>
#include <filter/kis_filter_configuration.h>
#include <kis_selection.h>
#include <kis_paint_device.h>
......@@ -47,7 +48,7 @@ KritaEdgeDetectionFilter::~KritaEdgeDetectionFilter()
{
}
KisEdgeDetectionFilter::KisEdgeDetectionFilter(): KisFilter(id(), categoryEdgeDetection(), i18n("&Edge Detection..."))
KisEdgeDetectionFilter::KisEdgeDetectionFilter(): KisFilter(id(), FiltersCategoryEdgeDetectionId, i18n("&Edge Detection..."))
{
setSupportsPainting(true);
setSupportsAdjustmentLayers(true);
......
......@@ -43,6 +43,7 @@
#include <kis_global.h>
#include <kis_selection.h>
#include <kis_types.h>
#include <filter/kis_filter_category_ids.h>
#include <filter/kis_filter_configuration.h>
#include <kis_paint_device.h>
#include <kis_processing_information.h>
......@@ -51,7 +52,7 @@
#include <KisSequentialIteratorProgress.h>
KisEmbossFilter::KisEmbossFilter() : KisFilter(id(), categoryEmboss(), i18n("&Emboss with Variable Depth..."))
KisEmbossFilter::KisEmbossFilter() : KisFilter(id(), FiltersCategoryEmbossId, i18n("&Emboss with Variable Depth..."))
{
setSupportsPainting(false);
setColorSpaceIndependence(TO_RGBA8);
......
......@@ -33,6 +33,7 @@
#include <kis_types.h>
#include <kis_selection.h>
#include <kis_layer.h>
#include <filter/kis_filter_category_ids.h>
#include <filter/kis_filter_registry.h>
#include <kis_global.h>
#include "KoColorModelStandardIds.h"
......@@ -49,7 +50,7 @@ KritaExample::~KritaExample()
{
}
KisFilterInvert::KisFilterInvert() : KisColorTransformationFilter(id(), categoryAdjust(), i18n("&Invert"))
KisFilterInvert::KisFilterInvert() : KisColorTransformationFilter(id(), FiltersCategoryAdjustId, i18n("&Invert"))
{
setShortcut(QKeySequence(Qt::CTRL + Qt::Key_I));
setColorSpaceIndependence(FULLY_INDEPENDENT);
......
......@@ -33,6 +33,7 @@
#include <kis_image.h>
#include <kis_paint_device.h>
#include <kis_selection.h>
#include <filter/kis_filter_category_ids.h>
#include <filter/kis_filter_configuration.h>
#include <kis_processing_information.h>
......@@ -56,7 +57,7 @@ FastColorTransferPlugin::~FastColorTransferPlugin()
{
}
KisFilterFastColorTransfer::KisFilterFastColorTransfer() : KisFilter(id(), categoryColors(), i18n("&Color Transfer..."))
KisFilterFastColorTransfer::KisFilterFastColorTransfer() : KisFilter(id(), FiltersCategoryColorId, i18n("&Color Transfer..."))
{
setColorSpaceIndependence(FULLY_INDEPENDENT);
setSupportsThreading(false);
......
......@@ -25,6 +25,7 @@
#include <kis_global.h>
#include <kis_types.h>
#include <filter/kis_filter_category_ids.h>
#include "kis_config_widget.h"
#include <KoResourceServerProvider.h>
#include <KoResourceServer.h>
......@@ -36,7 +37,7 @@
#include <KisSequentialIteratorProgress.h>
KritaFilterGradientMap::KritaFilterGradientMap() : KisFilter(id(), categoryMap(), i18n("&Gradient Map..."))
KritaFilterGradientMap::KritaFilterGradientMap() : KisFilter(id(), FiltersCategoryMapId, i18n("&Gradient Map..."))
{
setColorSpaceIndependence(FULLY_INDEPENDENT);
setShowConfigurationWidget(true);
......
......@@ -26,6 +26,7 @@
#include <KoUpdater.h>
#include <KoCompositeOps.h>
#include <filter/kis_filter_category_ids.h>
#include "kis_filter_configuration.h"
#include <kis_filter_registry.h>
......@@ -51,7 +52,7 @@ KritaHalftone::~KritaHalftone()
}
KisHalftoneFilter::KisHalftoneFilter()
: KisFilter(id(), categoryArtistic(), i18n("&Halftone..."))
: KisFilter(id(), FiltersCategoryArtisticId, i18n("&Halftone..."))
{
setColorSpaceIndependence(FULLY_INDEPENDENT);
......
......@@ -30,6 +30,7 @@
#include <kis_convolution_painter.h>
#include <kis_global.h>
#include <widgets/kis_multi_integer_filter_widget.h>
#include <filter/kis_filter_category_ids.h>
#include <filter/kis_filter_configuration.h>
#include <kis_processing_information.h>
#include <kis_paint_device.h>
......@@ -38,7 +39,7 @@
KisSimpleNoiseReducer::KisSimpleNoiseReducer()
: KisFilter(id(), categoryEnhance(), i18n("&Gaussian Noise Reduction..."))
: KisFilter(id(), FiltersCategoryEnhanceId, i18n("&Gaussian Noise Reduction..."))
{
setSupportsPainting(false);
}
......
......@@ -29,12 +29,13 @@
#include <widgets/kis_multi_double_filter_widget.h>
#include <widgets/kis_multi_integer_filter_widget.h>
#include <kis_paint_device.h>
#include <filter/kis_filter_category_ids.h>
#include <filter/kis_filter_configuration.h>
#include <kis_processing_information.h>
#include "kis_global.h"
KisWaveletNoiseReduction::KisWaveletNoiseReduction()
: KisFilter(id(), categoryEnhance(), i18n("&Wavelet Noise Reducer..."))
: KisFilter(id(), FiltersCategoryEnhanceId, i18n("&Wavelet Noise Reducer..."))
{
setSupportsPainting(false);
setSupportsThreading(false);
......
......@@ -27,6 +27,7 @@
#include <kis_global.h>
#include <KoColorSpaceMaths.h>
#include <KoColorSpaceRegistry.h>
#include <filter/kis_filter_category_ids.h>
#include <filter/kis_color_transformation_configuration.h>
#include <widgets/kis_multi_integer_filter_widget.h>
......@@ -45,7 +46,7 @@ IndexColors::~IndexColors()
{
}
KisFilterIndexColors::KisFilterIndexColors() : KisColorTransformationFilter(id(), categoryArtistic(), i18n("&Index Colors..."))
KisFilterIndexColors::KisFilterIndexColors() : KisColorTransformationFilter(id(), FiltersCategoryArtisticId, i18n("&Index Colors..."))
{
setColorSpaceIndependence(FULLY_INDEPENDENT); // Technically it is TO_LAB16 but that would only display a warning we don't want
// This filter will always degrade the color space, that is it's purpose
......
......@@ -41,10 +41,11 @@
#include "kis_processing_information.h"
#include "kis_selection.h"
#include "kis_types.h"
#include <filter/kis_filter_category_ids.h>
#include "filter/kis_color_transformation_configuration.h"
KisLevelFilter::KisLevelFilter()
: KisColorTransformationFilter(id(), categoryAdjust(), i18n("&Levels..."))
: KisColorTransformationFilter(id(), FiltersCategoryAdjustId, i18n("&Levels..."))
{
setShortcut(QKeySequence(Qt::CTRL + Qt::Key_L));
setSupportsPainting(false);
......
......@@ -40,6 +40,7 @@
#include <kis_random_generator.h>
#include <kis_selection.h>
#include <kis_types.h>
#include <filter/kis_filter_category_ids.h>
#include <filter/kis_filter_configuration.h>
#include <kis_processing_information.h>
......@@ -61,7 +62,7 @@ KritaNoiseFilter::~KritaNoiseFilter()
{
}
KisFilterNoise::KisFilterNoise() : KisFilter(id(), categoryOther(), i18n("&Random Noise..."))
KisFilterNoise::KisFilterNoise() : KisFilter(id(), FiltersCategoryOtherId, i18n("&Random Noise..."))
{
setColorSpaceIndependence(FULLY_INDEPENDENT);
setSupportsPainting(true);
......
......@@ -33,6 +33,7 @@
#include <kis_types.h>
#include <kis_selection.h>
#include <kis_layer.h>
#include <filter/kis_filter_category_ids.h>
#include <filter/kis_filter_registry.h>
#include <kis_global.h>
......@@ -53,8 +54,8 @@ KritaNormalizeFilter::~KritaNormalizeFilter()
KisFilterNormalize::KisFilterNormalize()
: KisColorTransformationFilter(KoID("normalize" , i18n("Normalize"))
, KisFilter::categoryMap(), i18n("&Normalize..."))
: KisColorTransformationFilter(KoID("normalize", i18n("Normalize")),
FiltersCategoryMapId, i18n("&Normalize..."))
{
setColorSpaceIndependence(FULLY_INDEPENDENT);
setSupportsPainting(true);
......
......@@ -45,13 +45,14 @@
#include <filter/kis_filter_registry.h>
#include <kis_global.h>
#include <kis_types.h>
#include <filter/kis_filter_category_ids.h>
#include <filter/kis_filter_configuration.h>
#include <kis_processing_information.h>
#include <kis_paint_device.h>
#include "widgets/kis_multi_integer_filter_widget.h"
KisOilPaintFilter::KisOilPaintFilter() : KisFilter(id(), KisFilter::categoryArtistic(), i18n("&Oilpaint..."))
KisOilPaintFilter::KisOilPaintFilter() : KisFilter(id(), FiltersCategoryArtisticId, i18n("&Oilpaint..."))
{