Krita Source Code Documentation
Loading...
Searching...
No Matches
KisConfig Class Reference

#include <kis_config.h>

Public Types

enum  AssistantsDrawMode { ASSISTANTS_DRAW_MODE_DIRECT = 0 , ASSISTANTS_DRAW_MODE_PIXMAP_CACHE = 1 , ASSISTANTS_DRAW_MODE_LARGE_PIXMAP_CACHE = 2 }
 
enum  BackgroundStyle { RASTER_LAYER = 0 , CANVAS_COLOR = 1 , FILL_LAYER = 2 }
 
enum class  CanvasSurfaceBitDepthMode { DepthAuto = 0 , Depth8Bit , Depth10Bit }
 
enum class  CanvasSurfaceMode { Preferred = 0 , Rec709g22 , Rec709g10 , Unmanaged }
 
enum  LayerInfoTextStyle { INFOTEXT_NONE = 0 , INFOTEXT_SIMPLE , INFOTEXT_BALANCED , INFOTEXT_DETAILED }
 
enum  OcioColorManagementMode { INTERNAL = 0 , OCIO_CONFIG , OCIO_ENVIRONMENT }
 
enum  RootSurfaceFormat { BT709_G22 = 0 , BT709_G10 , BT2020_PQ }
 
enum  SessionOnStartup { SOS_BlankSession , SOS_PreviousSession , SOS_ShowSessionManager }
 
enum  TouchPainting { TOUCH_PAINTING_AUTO , TOUCH_PAINTING_ENABLED , TOUCH_PAINTING_DISABLED }
 

Public Slots

void logImportantSettings () const
 Log the most interesting settings to the usage log.
 

Public Member Functions

bool activateTransformToolAfterPaste (bool defaultValue=false) const
 
bool adaptivePlaybackRange (bool defaultValue=false) const
 
bool allowLCMSOptimization (bool defaultValue=false) const
 
bool animationDropFrames (bool defaultValue=false) const
 
int animationPlaybackBackend (bool defaultValue=false) const
 
bool antialiasCurves (bool defaultValue=false) const
 
bool antialiasSelectionOutline (bool defaultValue=false) const
 
AssistantsDrawMode assistantsDrawMode (bool defaultValue=false) const
 
int audioOffsetTolerance (bool defaultValue=false) const
 
bool autoPinLayersToTimeline (bool defaultValue=false) const
 
int autoSaveInterval (bool defaultValue=false) const
 
bool autoSmoothBezierCurves (bool defaultValue=false) const
 
bool autoZoomTimelineToPlaybackRange (bool defaultValue=false) const
 
bool backupFile (bool defaultValue=false) const
 
QString brushHudSetting (bool defaultValue=false) const
 
bool calculateAnimationCacheInBackground (bool defaultValue=false) const
 
QColor canvasBorderColor (bool defaultValue=false) const
 
QString canvasState (bool defaultValue=false) const
 
CanvasSurfaceBitDepthMode canvasSurfaceBitDepthMode (bool defaultValue=false) const
 
CanvasSurfaceMode canvasSurfaceColorSpaceManagementMode (bool defaultValue=false) const
 
QColor checkersColor1 (bool defaultValue=false) const
 
QColor checkersColor2 (bool defaultValue=false) const
 
qint32 checkSize (bool defaultValue=false) const
 
bool clicklessSpacePan (bool defaultValue=false) const
 
bool colorHistoryPerDocument (bool defaultValue=false) const
 
QRect colorPreviewRect () const
 
bool compressKra (bool defaultValue=false) const
 
bool convertLayerColorSpaceInProperties (bool defaultValue=false) const
 
bool convertToImageColorspaceOnImport (bool defaultValue=false) const
 
KisCumulativeUndoData cumulativeUndoData (bool defaultValue=false) const
 
QString currentInputProfile (bool defaultValue=false) const
 
const KoColorSpacecustomColorSelectorColorSpace (bool defaultValue=false) const
 
QColor defaultAssistantsColor (bool defaultValue=false) const
 
QColor defaultBackgroundColor (bool defaultValue=false) const
 
quint8 defaultBackgroundOpacity (bool defaultValue=false) const
 
BackgroundStyle defaultBackgroundStyle (bool defaultValue=false) const
 
QString defaultColorDepth (bool defaultValue=false) const
 
QString defaultPalette (bool defaultValue=false) const
 
QString defColorModel (bool defaultValue=false) const
 
void defColorModel (const QString &model) const
 
QString defColorProfile (bool defaultValue=false) const
 
void defColorProfile (const QString &depth) const
 
qint32 defImageHeight (bool defaultValue=false) const
 
void defImageHeight (qint32 height) const
 
qreal defImageResolution (bool defaultValue=false) const
 
void defImageResolution (qreal res) const
 
qint32 defImageWidth (bool defaultValue=false) const
 
void defImageWidth (qint32 width) const
 
bool disableAVXOptimizations (bool defaultValue=false) const
 
void disableOpenGL () const
 
bool disableTouchOnCanvas () const
 
bool disableVectorOptimizations (bool defaultValue=false) const
 
const KoColorProfiledisplayProfile (int screen) const
 
CanvasSurfaceBitDepthMode effectiveCanvasSurfaceBitDepthMode (const QSurfaceFormat &format) const
 
bool enableBrushSpeedLogging (bool defaultValue=false) const
 
bool enableCanvasSurfaceColorSpaceManagement (bool defaultValue=false) const
 
bool enableOpenGLFramerateLogging (bool defaultValue=false) const
 
void enablePixelGrid (bool v) const
 
CursorStyle eraserCursorStyle (bool defaultValue=false) const
 
OutlineStyle eraserOutlineStyle (bool defaultValue=false) const
 
KisPropertiesConfigurationSP exportConfiguration (const QString &filterId, bool defaultValue=false) const
 
QString exportConfigurationXML (const QString &filterId, bool defaultValue=false) const
 
QString exportMimeType (bool defaultValue) const
 
QStringList favoriteCompositeOps (bool defaultValue=false) const
 
int favoritePresets (bool defaultValue=false) const
 
QString ffmpegLocation (bool defaultValue=false) const
 
bool firstRun (bool defaultValue=false) const
 
bool forceAlwaysFullSizedEraserOutline (bool defaultValue=false) const
 
bool forceAlwaysFullSizedOutline (bool defaultValue=false) const
 
bool forceOpenGLFenceWorkaround (bool defaultValue=false) const
 
bool forcePaletteColors (bool defaultValue=false) const
 
bool forceShowAutosaveMessages (bool defaultValue=true) const
 
bool forceShowSaveMessages (bool defaultValue=true) const
 
bool fullscreenMode (bool defaultValue=false) const
 
QColor getCursorMainColor (bool defaultValue=false) const
 
QPoint getDefaultGridSpacing (bool defaultValue=false) const
 
QColor getEraserCursorMainColor (bool defaultValue=false) const
 
QColor getGridIsoVerticalColor (bool defaultValue=false) const
 
quint32 getGridIsoVerticalStyle (bool defaultValue=false) const
 
QColor getGridMainColor (bool defaultValue=false) const
 
quint32 getGridMainStyle (bool defaultValue=false) const
 
QColor getGridSubdivisionColor (bool defaultValue=false) const
 
quint32 getGridSubdivisionStyle (bool defaultValue=false) const
 
QString getMDIBackgroundColor (bool defaultValue=false) const
 
QString getMDIBackgroundImage (bool defaultValue=false) const
 
QColor getPixelGridColor (bool defaultValue=false) const
 
qreal getPixelGridDrawingThreshold (bool defaultValue=false) const
 
const QString getScreenStringIdentfier (int screenNo) const
 
QColor guidesColor (bool defaultValue=false) const
 
quint32 guidesLineStyle (bool defaultValue=false) const
 
bool hideDevFundBanner (bool defaultValue=false) const
 
bool hideDockersFullscreen (bool defaultValue=false) const
 
bool hideMenuFullscreen (bool defaultValue=false) const
 
bool hidePopups (bool defaultValue=false) const
 
bool hideScrollbars (bool defaultValue=false) const
 
bool hideScrollbarsFullscreen (bool defaultValue=false) const
 
bool hideStatusbarFullscreen (bool defaultValue=false) const
 
bool hideTitlebarFullscreen (bool defaultValue=false) const
 
bool hideToolbarFullscreen (bool defaultValue=false) const
 
int horizontalSplitLines (bool defaultValue=false) const
 
bool ignoreHighFunctionKeys (bool defaultValue=false) const
 
QString importConfiguration (const QString &filterId, bool defaultValue=false) const
 
QString importProfile (bool defaultValue=false) const
 
bool kineticScrollingEnabled (bool defaultValue=false) const
 
int kineticScrollingGesture (bool defaultValue=false) const
 
bool kineticScrollingHiddenScrollbars (bool defaultValue=false) const
 
int kineticScrollingSensitivity (bool defaultValue=false) const
 
 KisConfig (bool readOnly)
 KisConfig create a kisconfig object.
 
OutlineStyle lastUsedOutlineStyle (bool defaultValue=false) const
 
int layerInfoTextOpacity (bool defaultValue=false) const
 
LayerInfoTextStyle layerInfoTextStyle (bool defaultValue=false) const
 
int layerThumbnailSize (bool defaultValue=false) const
 
int layerTreeIndentation (bool defaultValue=false) const
 
bool levelOfDetailEnabled (bool defaultValue=false) const
 
qreal lineSmoothingDelayDistance (bool defaultValue=false) const
 
bool lineSmoothingDistanceKeepAspectRatio (bool defaultValue=false) const
 
qreal lineSmoothingDistanceMax (bool defaultValue=false) const
 
qreal lineSmoothingDistanceMin (bool defaultValue=false) const
 
bool lineSmoothingFinishStabilizedCurve (bool defaultValue=false) const
 
bool lineSmoothingScalableDistance (bool defaultValue=false) const
 
bool lineSmoothingSmoothPressure (bool defaultValue=false) const
 
bool lineSmoothingStabilizeSensors (bool defaultValue=false) const
 
qreal lineSmoothingTailAggressiveness (bool defaultValue=false) const
 
int lineSmoothingType (bool defaultValue=false) const
 
bool lineSmoothingUseDelayDistance (bool defaultValue=false) const
 
void loadSnapConfig (KisSnapConfig *config, bool defaultValue=false) const
 
bool longPressEnabled (bool defaultValue=false) const
 
QString monitorForScreen (int screen, const QString &defaultMonitor, bool defaultValue=true) const
 
QString monitorProfile (int screen) const
 get the profile the user has selected for the given screen
 
qint32 monitorRenderIntent (bool defaultValue=false) const
 
CursorStyle newCursorStyle (bool defaultValue=false) const
 
OutlineStyle newOutlineStyle (bool defaultValue=false) const
 
int numDefaultLayers (bool defaultValue=false) const
 
int numMipmapLevels (bool defaultValue=false) const
 
OcioColorManagementMode ocioColorManagementMode (bool defaultValue=false) const
 
KisOcioConfiguration ocioConfiguration (bool defaultValue=false) const
 
bool ocioLockColorVisualRepresentation (bool defaultValue=false) const
 
int ocioLutEdgeSize (bool defaultValue=false) const
 
int openGLFilteringMode (bool defaultValue=false) const
 
int openGLTextureSize (bool defaultValue=false) const
 
qreal outlineSizeMinimum (bool defaultValue=false) const
 
bool paintopPopupDetached (bool defaultValue=false) const
 
qint32 pasteBehaviour (bool defaultValue=false) const
 
qint32 pasteFormat (bool defaultValue) const
 
bool pixelGridEnabled (bool defaultValue=false) const
 
int preferredVectorImportResolutionPPI (bool defaultValue=false) const
 
int presetChooserViewMode (bool defaultValue=false) const
 
int presetIconSize (bool defaultValue=false) const
 
bool presetStripVisible (bool defaultValue=false) const
 
QString pressureTabletCurve (bool defaultValue=false) const
 
QString printerColorSpace (bool defaultValue=false) const
 
QString printerProfile (bool defaultValue=false) const
 
template<class T >
readEntry (const QString &name, const T &defaultValue=T())
 
KoColor readKoColor (const QString &name, const KoColor &color=KoColor()) const
 
QList< KoColorreadKoColors (const QString &name) const
 
template<class T >
QList< T > readList (const QString &name, const QList< T > &defaultValue=QList< T >())
 
bool renamePastedLayers (bool defaultValue=false) const
 
RootSurfaceFormat rootSurfaceFormat (bool defaultValue=false) const
 
bool rulersTrackMouse (bool defaultValue=false) const
 
bool saveSessionOnQuit (bool defaultValue) const
 
void saveSnapConfig (const KisSnapConfig &config)
 
bool scratchpadVisible (bool defaultValue=false) const
 
bool scrollbarZoomEnabled (bool defaultValue=false) const
 
bool scrollCheckers (bool defaultValue=false) const
 
int scrubbingAudioUpdatesDelay (bool defaultValue=false) const
 
int scrubbingUpdatesDelay (bool defaultValue=false) const
 
bool selectionActionBar (bool defaultValue=false) const
 
qreal selectionViewSizeMinimum (bool defaultValue=false) const
 
bool separateEraserCursor (bool defaultValue=false) const
 
SessionOnStartup sessionOnStartup (bool defaultValue=false) const
 
void setActivateTransformToolAfterPaste (bool value)
 
void setAdaptivePlaybackRange (bool value)
 
void setAllowLCMSOptimization (bool allowLCMSOptimization)
 
void setAnimationDropFrames (bool value)
 
void setAnimationPlaybackBackend (int value)
 
void setAntialiasCurves (bool v) const
 
void setAntialiasSelectionOutline (bool v) const
 
void setAssistantsDrawMode (AssistantsDrawMode value)
 
void setAudioOffsetTolerance (int value)
 
void setAutoPinLayersToTimeline (bool value)
 
void setAutoSaveInterval (int seconds) const
 
void setAutoSmoothBezierCurves (bool value)
 
void setAutoZoomTimelineToPlaybackRange (bool value)
 
void setBackupFile (bool backupFile) const
 
void setBrushHudSetting (const QString &value) const
 
void setCalculateAnimationCacheInBackground (bool value)
 
void setCanvasBorderColor (const QColor &color) const
 
void setCanvasState (const QString &state) const
 
void setCanvasSurfaceBitDepthMode (CanvasSurfaceBitDepthMode value)
 
void setCanvasSurfaceColorSpaceManagementMode (CanvasSurfaceMode value)
 
void setCheckersColor1 (const QColor &v) const
 
void setCheckersColor2 (const QColor &v) const
 
void setCheckSize (qint32 checkSize) const
 
void setClicklessSpacePan (const bool toggle) const
 
void setColorPreviewRect (const QRect &rect)
 
void setCompressKra (bool compress)
 
void setConvertLayerColorSpaceInProperties (bool value)
 
void setConvertToImageColorspaceOnImport (bool value)
 
void setCumulativeUndoData (KisCumulativeUndoData value)
 
void setCumulativeUndoRedo (bool value)
 
void setCurrentInputProfile (const QString &name)
 
void setCursorMainColor (const QColor &v) const
 
void setCustomColorSelectorColorSpace (const KoColorSpace *cs)
 
void setDefaultAssistantsColor (const QColor &color) const
 
void setDefaultBackgroundColor (const QColor &value)
 
void setDefaultBackgroundOpacity (quint8 value)
 
void setDefaultBackgroundStyle (BackgroundStyle value)
 
void setDefaultColorDepth (const QString &depth) const
 
void setDefaultGridSpacing (QPoint gridSpacing)
 
void setDefaultPalette (const QString &name) const
 
void setDisableAVXOptimizations (bool value)
 
void setDisableVectorOptimizations (bool value)
 
void setEnableBrushSpeedLogging (bool value) const
 
void setEnableCanvasSurfaceColorSpaceManagement (bool value)
 
void setEnableOpenGLFramerateLogging (bool value) const
 
void setEraserCursorMainColor (const QColor &v) const
 
void setEraserCursorStyle (CursorStyle style)
 
void setEraserOutlineStyle (OutlineStyle style)
 
void setExportConfiguration (const QString &filterId, KisPropertiesConfigurationSP properties) const
 
void setExportMimeType (const QString &defaultExportMimeType)
 
void setFavoriteCompositeOps (const QStringList &compositeOps) const
 
void setFavoritePresets (const int value)
 
void setFFMpegLocation (const QString &value)
 
void setFirstRun (const bool firstRun) const
 
void setForceAlwaysFullSizedEraserOutline (bool value) const
 
void setForceAlwaysFullSizedOutline (bool value) const
 
void setForcePaletteColors (bool forcePaletteColors)
 
void setForceShowAutosaveMessages (bool ShowAutosaveMessages) const
 
void setForceShowSaveMessages (bool value) const
 
void setFullscreenMode (const bool value) const
 
void setGridIsoVerticalColor (const QColor &v) const
 
void setGridIsoVerticalStyle (quint32 v) const
 
void setGridMainColor (const QColor &v) const
 
void setGridMainStyle (quint32 v) const
 
void setGridSubdivisionColor (const QColor &v) const
 
void setGridSubdivisionStyle (quint32 v) const
 
void setGuidesColor (const QColor &v) const
 
void setGuidesLineStyle (quint32 v) const
 
void setHideDevFundBanner (bool value=true)
 
void setHideDockersFullscreen (const bool value) const
 
void setHideMenuFullscreen (const bool value) const
 
void setHidePopups (bool hidePopups)
 
void setHideScrollbars (bool value) const
 
void setHideScrollbarsFullscreen (const bool value) const
 
void setHideStatusbarFullscreen (const bool value) const
 
void setHideTitlebarFullscreen (const bool value) const
 
void setHideToolbarFullscreen (const bool value) const
 
void setHorizontalSplitLines (const int numberLines) const
 
void setIgnoreHighFunctionKeys (bool value)
 
void setImportConfiguration (const QString &filterId, KisPropertiesConfigurationSP properties) const
 
void setImportProfile (const QString &importProfile) const
 
void setKineticScrollingEnabled (bool enabled)
 
void setKineticScrollingGesture (int kineticScroll)
 
void setKineticScrollingHideScrollbars (bool scrollbar)
 
void setKineticScrollingSensitivity (int sensitivity)
 
void setLastUsedOutlineStyle (OutlineStyle style)
 
void setLayerInfoTextOpacity (int value)
 
void setLayerInfoTextStyle (LayerInfoTextStyle value)
 
void setLayerThumbnailSize (int size)
 
void setLayerTreeIndentation (int percentage)
 
void setLevelOfDetailEnabled (bool value)
 
void setLineSmoothingDelayDistance (qreal value)
 
void setLineSmoothingDistanceKeepAspectRatio (bool value)
 
void setLineSmoothingDistanceMax (qreal value)
 
void setLineSmoothingDistanceMin (qreal value)
 
void setLineSmoothingFinishStabilizedCurve (bool value)
 
void setLineSmoothingScalableDistance (bool value)
 
void setLineSmoothingSmoothPressure (bool value)
 
void setLineSmoothingStabilizeSensors (bool value)
 
void setLineSmoothingTailAggressiveness (qreal value)
 
void setLineSmoothingType (int value)
 
void setLineSmoothingUseDelayDistance (bool value)
 
void setLongPressEnabled (bool value)
 
void setMDIBackgroundColor (const QString &v) const
 
void setMDIBackgroundImage (const QString &fileName) const
 
void setMonitorForScreen (int screen, const QString &monitor)
 
void setMonitorProfile (int screen, const QString &monitorProfile, bool override) const
 
void setNewCursorStyle (CursorStyle style)
 
void setNewOutlineStyle (OutlineStyle style)
 
void setNumDefaultLayers (int num)
 
void setOcioColorManagementMode (OcioColorManagementMode mode) const
 
void setOcioConfiguration (const KisOcioConfiguration &cfg)
 
void setOcioLockColorVisualRepresentation (bool value)
 
void setOcioLutEdgeSize (int value)
 
void setOpenGLFilteringMode (int filteringMode)
 
void setOutlineSizeMinimum (qreal outlineSizeMinimum) const
 
void setPaintopPopupDetached (bool detached) const
 
void setPasteBehaviour (qint32 behaviour) const
 
void setPasteFormat (qint32 format)
 
void setPixelGridColor (const QColor &v) const
 
void setPixelGridDrawingThreshold (qreal v) const
 
void setPreferredVectorImportResolutionPPI (int value) const
 
void setPresetChooserViewMode (const int mode) const
 
void setPresetIconSize (const int value) const
 
void setPresetStripVisible (bool visible)
 
void setPressureTabletCurve (const QString &curveString) const
 
void setPrinterColorSpace (const QString &printerColorSpace) const
 
void setPrinterProfile (const QString &printerProfile) const
 
void setRenamePastedLayers (bool value)
 
void setRenderIntent (qint32 monitorRenderIntent) const
 
void setRootSurfaceFormat (RootSurfaceFormat value)
 
void setRulersTrackMouse (bool value) const
 
void setSaveSessionOnQuit (bool value)
 
void setScratchpadVisible (bool visible)
 
void setScrollbarZoomEnabled (bool enabled) const
 
void setScrollingCheckers (bool scrollCheckers) const
 
void setScrubbingAudioUpdatesDelay (int value)
 
void setScrubbingUpdatesDelay (int value)
 
void setSelectionActionBar (bool value)
 
void setSelectionViewSizeMinimum (qreal outlineSizeMinimum) const
 
void setSeparateEraserCursor (bool value) const
 
void setSessionOnStartup (SessionOnStartup value)
 
void setShowBrushHud (bool value)
 
void setShowCanvasMessages (bool show)
 
void setShowDockers (const bool value) const
 
void setShowDockerTitleBars (const bool value) const
 
void setShowEraserOutlineWhilePainting (bool showEraserOutlineWhilePainting) const
 
void setShowFilterGallery (bool showFilterGallery) const
 
void setShowFilterGalleryLayerMaskDialog (bool showFilterGallery) const
 
void setShowGlobalSelection (bool showGlobalSelection) const
 
void setShowOutlineWhilePainting (bool showOutlineWhilePainting) const
 
void setShowPaletteBottomBar (bool value)
 
void setShowRootLayer (bool showRootLayer) const
 
void setShowRulers (bool rulers) const
 
void setShowSingleChannelAsColor (bool asColor)
 
void setShowStatusBar (const bool value) const
 
void setSliderLabels (bool enabled)
 
void setStabilizerDelayedPaint (bool value)
 
void setStabilizerSampleSize (int value)
 
void setSwitchSelectionCtrlAlt (bool value)
 
void setTabletEventsDelay (int value)
 
void setTestingAcceptCompressedTabletEvents (bool value)
 
void setTestingCompressBrushEvents (bool value)
 
void setTimelineZoom (qreal value)
 
void setToolbarSlider (int sliderNumber, const QString &slider)
 
void setToolOptionsInDocker (bool inDocker)
 
void setToolOptionsPopupDetached (bool detached) const
 
void setTouchPainting (TouchPainting value) const
 
void setTrackTabletEventLatency (bool value)
 
void setTrimFramesImport (bool trim)
 
void setTrimKra (bool trim)
 
void setUndoEnabled (bool undo) const
 
void setUndoStackLimit (int limit) const
 
void setUseBlackPointCompensation (bool useBlackPointCompensation) const
 
void setUseDefaultColorSpace (bool value) const
 
void setUseDirtyPresets (bool value)
 
void setUseEraserBrushOpacity (bool value)
 
void setUseEraserBrushSize (bool value)
 
void setUseInlineLayerInfoText (bool value)
 
void setUseLayerSelectionCheckbox (bool value)
 
void setUseOcio (bool useOCIO) const
 
void setUseOpenGLTextureBuffer (bool useBuffer)
 
void setUseProjections (bool useProj) const
 
void setUseRightMiddleTabletButtonWorkaround (bool value)
 
void setUseSystemMonitorProfile (bool _useSystemMonitorProfile) const
 
void setUseWin8PointerInput (bool value)
 
void setUseZip64 (bool value)
 
void setVastScrolling (const qreal factor) const
 
void setVerticalSplitLines (const int numberLines) const
 
void setWidgetStyle (QString name)
 
void setWorkingColorSpace (const QString &workingColorSpace) const
 
void setZoomHorizontal (bool value)
 
void setZoomMarginSize (int zoomMarginSize)
 
void setZoomSteps (int steps)
 
bool shouldEatDriverShortcuts (bool defaultValue=false) const
 
bool showBrushHud (bool defaultValue=false) const
 
bool showCanvasMessages (bool defaultValue=false) const
 
bool showDockers (bool defaultValue=false) const
 
bool showDockerTitleBars (bool defaultValue=false) const
 
bool showEraserOutlineWhilePainting (bool defaultValue=false) const
 
bool showFilterGallery (bool defaultValue=false) const
 
bool showFilterGalleryLayerMaskDialog (bool defaultValue=false) const
 
bool showGlobalSelection (bool defaultValue=false) const
 
bool showOutlineWhilePainting (bool defaultValue=false) const
 
bool showPaletteBottomBar (bool defaultValue=false) const
 
bool showRootLayer (bool defaultValue=false) const
 
bool showRulers (bool defaultValue=false) const
 
bool showSingleChannelAsColor (bool defaultValue=false) const
 
bool showStatusBar (bool defaultValue=false) const
 
bool sliderLabels (bool defaultValue=false) const
 
bool stabilizerDelayedPaint (bool defaultValue=false) const
 
int stabilizerSampleSize (bool defaultValue=false) const
 
bool switchSelectionCtrlAlt (bool defaultValue=false) const
 
int tabletEventsDelay (bool defaultValue=false) const
 
bool testingAcceptCompressedTabletEvents (bool defaultValue=false) const
 
bool testingCompressBrushEvents (bool defaultValue=false) const
 
int textureOverlapBorder () const
 
qreal timelineZoom (bool defaultValue=false) const
 
QString toolbarSlider (int sliderNumber, bool defaultValue=false) const
 
bool toolOptionsInDocker (bool defaultValue=false) const
 
bool toolOptionsPopupDetached (bool defaultValue=false) const
 
TouchPainting touchPainting (bool defaultValue=false) const
 
bool trackTabletEventLatency (bool defaultValue=false) const
 
bool trimFramesImport (bool defaultValue=false) const
 
bool trimKra (bool defaultValue=false) const
 
bool undoEnabled (bool defaultValue=false) const
 
int undoStackLimit (bool defaultValue=false) const
 
bool useBlackPointCompensation (bool defaultValue=false) const
 
bool useCumulativeUndoRedo (bool defaultValue=false) const
 
bool useDefaultColorSpace (bool defaultvalue=false) const
 
bool useDirtyPresets (bool defaultValue=false) const
 
bool useEraserBrushOpacity (bool defaultValue=false) const
 
bool useEraserBrushSize (bool defaultValue=false) const
 
bool useInlineLayerInfoText (bool defaultValue=false) const
 
bool useLayerSelectionCheckbox (bool defaultValue=false) const
 
bool useOcio (bool defaultValue=false) const
 
bool useOpenGL (bool defaultValue=false) const
 
bool useOpenGLTextureBuffer (bool defaultValue=false) const
 
bool useProjections (bool defaultValue=false) const
 
bool useRightMiddleTabletButtonWorkaround (bool defaultValue=false) const
 
bool useSystemMonitorProfile (bool defaultValue=false) const
 
bool useWin8PointerInput (bool defaultValue=false) const
 
bool useZip64 (bool defaultValue=false) const
 
qreal vastScrolling (bool defaultValue=false) const
 
int verticalSplitLines (bool defaultValue=false) const
 
QString widgetStyle (bool defaultValue=false)
 
int workaroundX11SmoothPressureSteps (bool defaultValue=false) const
 
QString workingColorSpace (bool defaultValue=false) const
 
template<class T >
void writeEntry (const QString &name, const T &value)
 
void writeKoColor (const QString &name, const KoColor &color) const
 
void writeKoColors (const QString &name, const QList< KoColor > &colors) const
 
template<class T >
void writeList (const QString &name, const QList< T > &value)
 
bool zoomHorizontal (bool defaultValue=false) const
 
int zoomMarginSize (bool defaultValue=false) const
 
int zoomSteps (bool defaultValue=false) const
 
 ~KisConfig ()
 

Static Public Member Functions

static CanvasSurfaceBitDepthMode canvasSurfaceBitDepthMode (QSettings *settings, bool defaultValue=false)
 
static const KoColorProfilegetScreenProfile (int screen)
 get the profile the color management system has stored for the given screen
 
static RootSurfaceFormat rootSurfaceFormat (QSettings *displayrc, bool defaultValue=false)
 
static void setCanvasSurfaceBitDepthMode (QSettings *settings, CanvasSurfaceBitDepthMode value)
 
static void setRootSurfaceFormat (QSettings *displayrc, RootSurfaceFormat value)
 
static void setUseWin8PointerInputNoApp (QSettings *settings, bool value)
 
static bool useWin8PointerInputNoApp (QSettings *settings, bool defaultValue=false)
 

Private Member Functions

 KisConfig (const KisConfig &)
 
KisConfigoperator= (const KisConfig &) const
 

Private Attributes

KConfigGroup m_cfg
 
bool m_readOnly
 

Detailed Description

Definition at line 30 of file kis_config.h.

Member Enumeration Documentation

◆ AssistantsDrawMode

Enumerator
ASSISTANTS_DRAW_MODE_DIRECT 
ASSISTANTS_DRAW_MODE_PIXMAP_CACHE 
ASSISTANTS_DRAW_MODE_LARGE_PIXMAP_CACHE 

Definition at line 767 of file kis_config.h.

767 {
768 ASSISTANTS_DRAW_MODE_DIRECT = 0, // no caching, draw directly on canvas
771 };
@ ASSISTANTS_DRAW_MODE_PIXMAP_CACHE
Definition kis_config.h:769
@ ASSISTANTS_DRAW_MODE_DIRECT
Definition kis_config.h:768
@ ASSISTANTS_DRAW_MODE_LARGE_PIXMAP_CACHE
Definition kis_config.h:770

◆ BackgroundStyle

Enumerator
RASTER_LAYER 
CANVAS_COLOR 
FILL_LAYER 

Definition at line 530 of file kis_config.h.

530 {
531 RASTER_LAYER = 0,
532 CANVAS_COLOR = 1,
533 FILL_LAYER = 2
534 };

◆ CanvasSurfaceBitDepthMode

Enumerator
DepthAuto 
Depth8Bit 
Depth10Bit 

Definition at line 167 of file kis_config.h.

◆ CanvasSurfaceMode

enum class KisConfig::CanvasSurfaceMode
strong
Enumerator
Preferred 
Rec709g22 
Rec709g10 
Unmanaged 

Definition at line 152 of file kis_config.h.

◆ LayerInfoTextStyle

Enumerator
INFOTEXT_NONE 
INFOTEXT_SIMPLE 
INFOTEXT_BALANCED 
INFOTEXT_DETAILED 

Definition at line 749 of file kis_config.h.

749 {
750 INFOTEXT_NONE = 0,
754 };
@ INFOTEXT_SIMPLE
Definition kis_config.h:751
@ INFOTEXT_BALANCED
Definition kis_config.h:752
@ INFOTEXT_DETAILED
Definition kis_config.h:753

◆ OcioColorManagementMode

Enumerator
INTERNAL 
OCIO_CONFIG 
OCIO_ENVIRONMENT 

Definition at line 471 of file kis_config.h.

471 {
472 INTERNAL = 0,
475 };
@ OCIO_ENVIRONMENT
Definition kis_config.h:474

◆ RootSurfaceFormat

Enumerator
BT709_G22 
BT709_G10 
BT2020_PQ 

Definition at line 729 of file kis_config.h.

729 {
730 BT709_G22 = 0,
731 BT709_G10,
733 };

◆ SessionOnStartup

Enumerator
SOS_BlankSession 
SOS_PreviousSession 
SOS_ShowSessionManager 

Definition at line 343 of file kis_config.h.

343 {
347 };
@ SOS_PreviousSession
Definition kis_config.h:345
@ SOS_ShowSessionManager
Definition kis_config.h:346
@ SOS_BlankSession
Definition kis_config.h:344

◆ TouchPainting

Enumerator
TOUCH_PAINTING_AUTO 
TOUCH_PAINTING_ENABLED 
TOUCH_PAINTING_DISABLED 

Definition at line 47 of file kis_config.h.

Constructor & Destructor Documentation

◆ KisConfig() [1/2]

KisConfig::KisConfig ( bool readOnly)

KisConfig create a kisconfig object.

Parameters
readOnlyif true, there will be no call to sync when the object is deleted. Any KisConfig object created in a thread must be read-only.

Definition at line 52 of file kis_config.cc.

53 : m_cfg( KSharedConfig::openConfig()->group(""))
54 , m_readOnly(readOnly)
55{
56 if (!readOnly) {
57 KIS_SAFE_ASSERT_RECOVER_RETURN(qApp && qApp->thread() == QThread::currentThread());
58 }
59}
KConfigGroup m_cfg
Definition kis_config.h:807
bool m_readOnly
Definition kis_config.h:808
#define KIS_SAFE_ASSERT_RECOVER_RETURN(cond)
Definition kis_assert.h:128

References KIS_SAFE_ASSERT_RECOVER_RETURN.

◆ ~KisConfig()

KisConfig::~KisConfig ( )

Definition at line 61 of file kis_config.cc.

62{
63 if (m_readOnly) return;
64
65 if (qApp && qApp->thread() != QThread::currentThread()) {
66 dbgKrita.noquote() << "WARNING: KisConfig: requested config synchronization from nonGUI thread! Called from:" << kisBacktrace();
67 return;
68 }
69
70 m_cfg.sync();
71}
QString kisBacktrace()
Definition kis_debug.cpp:51
#define dbgKrita
Definition kis_debug.h:45

References dbgKrita, kisBacktrace(), m_cfg, and m_readOnly.

◆ KisConfig() [2/2]

KisConfig::KisConfig ( const KisConfig & )
private

Member Function Documentation

◆ activateTransformToolAfterPaste()

bool KisConfig::activateTransformToolAfterPaste ( bool defaultValue = false) const

Definition at line 2621 of file kis_config.cc.

2622{
2623 return defaultValue ? false : m_cfg.readEntry("activateTransformToolAfterPaste", false);
2624}

References m_cfg.

◆ adaptivePlaybackRange()

bool KisConfig::adaptivePlaybackRange ( bool defaultValue = false) const

Definition at line 2436 of file kis_config.cc.

2437{
2438 return (defaultValue ? true : m_cfg.readEntry("adaptivePlaybackRange", true));
2439}
T readEntry(const QString &name, const T &defaultValue=T())
Definition kis_config.h:789

References m_cfg.

◆ allowLCMSOptimization()

bool KisConfig::allowLCMSOptimization ( bool defaultValue = false) const

Definition at line 893 of file kis_config.cc.

894{
895 return (defaultValue ? true : m_cfg.readEntry("allowLCMSOptimization", true));
896}

References m_cfg.

◆ animationDropFrames()

bool KisConfig::animationDropFrames ( bool defaultValue = false) const

Definition at line 2474 of file kis_config.cc.

2475{
2476 return (defaultValue ? true : m_cfg.readEntry("animationDropFrames", true));
2477}

References m_cfg.

◆ animationPlaybackBackend()

int KisConfig::animationPlaybackBackend ( bool defaultValue = false) const

Definition at line 2411 of file kis_config.cc.

2412{
2413 return (defaultValue ? 1 : m_cfg.readEntry("animationPlaybackBackend", 1));
2414}

References m_cfg.

◆ antialiasCurves()

bool KisConfig::antialiasCurves ( bool defaultValue = false) const

Definition at line 1297 of file kis_config.cc.

1298{
1299 return (defaultValue ? true : m_cfg.readEntry("antialiascurves", true));
1300}

References m_cfg.

◆ antialiasSelectionOutline()

bool KisConfig::antialiasSelectionOutline ( bool defaultValue = false) const

Definition at line 1307 of file kis_config.cc.

1308{
1309 return (defaultValue ? false : m_cfg.readEntry("AntialiasSelectionOutline", false));
1310}

References m_cfg.

◆ assistantsDrawMode()

KisConfig::AssistantsDrawMode KisConfig::assistantsDrawMode ( bool defaultValue = false) const

Definition at line 2760 of file kis_config.cc.

2761{
2762 if (defaultValue) {
2764 }
2765
2766 return static_cast<AssistantsDrawMode>(
2767 m_cfg.readEntry("assistantsDrawMode", static_cast<int>(ASSISTANTS_DRAW_MODE_DIRECT)));
2768}

References ASSISTANTS_DRAW_MODE_DIRECT, and m_cfg.

◆ audioOffsetTolerance()

int KisConfig::audioOffsetTolerance ( bool defaultValue = false) const

Definition at line 2499 of file kis_config.cc.

2500{
2501 return (defaultValue ? -1 : m_cfg.readEntry("audioOffsetTolerance", -1));
2502}

References m_cfg.

◆ autoPinLayersToTimeline()

bool KisConfig::autoPinLayersToTimeline ( bool defaultValue = false) const

Definition at line 2426 of file kis_config.cc.

2427{
2428 return (defaultValue ? true : m_cfg.readEntry("autoPinLayers", true));
2429}

References m_cfg.

◆ autoSaveInterval()

int KisConfig::autoSaveInterval ( bool defaultValue = false) const

Definition at line 1430 of file kis_config.cc.

1431{
1432 int def = 7 * 60;
1433 return (defaultValue ? def : m_cfg.readEntry("AutoSaveInterval", def));
1434}

References m_cfg.

◆ autoSmoothBezierCurves()

bool KisConfig::autoSmoothBezierCurves ( bool defaultValue = false) const

Definition at line 2611 of file kis_config.cc.

2612{
2613 return defaultValue ? false : m_cfg.readEntry("autoSmoothBezierCurves", false);
2614}

References m_cfg.

◆ autoZoomTimelineToPlaybackRange()

bool KisConfig::autoZoomTimelineToPlaybackRange ( bool defaultValue = false) const

Definition at line 2446 of file kis_config.cc.

2447{
2448 return (defaultValue ? true : m_cfg.readEntry("autoZoomTimelineToPlaybackRange", true));
2449}

References m_cfg.

◆ backupFile()

bool KisConfig::backupFile ( bool defaultValue = false) const

Definition at line 1441 of file kis_config.cc.

1442{
1443 return (defaultValue ? true : m_cfg.readEntry("CreateBackupFile", true));
1444}

References m_cfg.

◆ brushHudSetting()

QString KisConfig::brushHudSetting ( bool defaultValue = false) const

Definition at line 2579 of file kis_config.cc.

2580{
2581 QString defaultDoc = "<!DOCTYPE hud_properties>\n<hud_properties>\n <version value=\"1\" type=\"value\"/>\n <paintbrush>\n <properties_list type=\"array\">\n <item_0 value=\"size\" type=\"value\"/>\n <item_1 value=\"opacity\" type=\"value\"/>\n <item_2 value=\"angle\" type=\"value\"/>\n </properties_list>\n </paintbrush>\n <colorsmudge>\n <properties_list type=\"array\">\n <item_0 value=\"size\" type=\"value\"/>\n <item_1 value=\"opacity\" type=\"value\"/>\n <item_2 value=\"smudge_mode\" type=\"value\"/>\n <item_3 value=\"smudge_length\" type=\"value\"/>\n <item_4 value=\"smudge_color_rate\" type=\"value\"/>\n </properties_list>\n </colorsmudge>\n <sketchbrush>\n <properties_list type=\"array\">\n <item_0 value=\"opacity\" type=\"value\"/>\n <item_1 value=\"size\" type=\"value\"/>\n </properties_list>\n </sketchbrush>\n <hairybrush>\n <properties_list type=\"array\">\n <item_0 value=\"size\" type=\"value\"/>\n <item_1 value=\"opacity\" type=\"value\"/>\n </properties_list>\n </hairybrush>\n <experimentbrush>\n <properties_list type=\"array\">\n <item_0 value=\"opacity\" type=\"value\"/>\n <item_1 value=\"shape_windingfill\" type=\"value\"/>\n </properties_list>\n </experimentbrush>\n <spraybrush>\n <properties_list type=\"array\">\n <item_0 value=\"size\" type=\"value\"/>\n <item_1 value=\"opacity\" type=\"value\"/>\n <item_2 value=\"spray_particlecount\" type=\"value\"/>\n <item_3 value=\"spray_density\" type=\"value\"/>\n </properties_list>\n </spraybrush>\n <hatchingbrush>\n <properties_list type=\"array\">\n <item_0 value=\"size\" type=\"value\"/>\n <item_1 value=\"opacity\" type=\"value\"/>\n <item_2 value=\"hatching_angle\" type=\"value\"/>\n <item_3 value=\"hatching_thickness\" type=\"value\"/>\n <item_4 value=\"hatching_separation\" type=\"value\"/>\n </properties_list>\n </hatchingbrush>\n <gridbrush>\n <properties_list type=\"array\">\n <item_0 value=\"size\" type=\"value\"/>\n <item_1 value=\"opacity\" type=\"value\"/>\n <item_2 value=\"grid_divisionlevel\" type=\"value\"/>\n </properties_list>\n </gridbrush>\n <curvebrush>\n <properties_list type=\"array\">\n <item_0 value=\"opacity\" type=\"value\"/>\n <item_1 value=\"curve_historysize\" type=\"value\"/>\n <item_2 value=\"curve_linewidth\" type=\"value\"/>\n <item_3 value=\"curve_lineopacity\" type=\"value\"/>\n <item_4 value=\"curve_connectionline\" type=\"value\"/>\n </properties_list>\n </curvebrush>\n <dynabrush>\n <properties_list type=\"array\">\n <item_0 value=\"dyna_diameter\" type=\"value\"/>\n <item_1 value=\"opacity\" type=\"value\"/>\n <item_2 value=\"dyna_mass\" type=\"value\"/>\n <item_3 value=\"dyna_drag\" type=\"value\"/>\n </properties_list>\n </dynabrush>\n <particlebrush>\n <properties_list type=\"array\">\n <item_0 value=\"opacity\" type=\"value\"/>\n <item_1 value=\"particle_particles\" type=\"value\"/>\n <item_2 value=\"particle_opecityweight\" type=\"value\"/>\n <item_3 value=\"particle_iterations\" type=\"value\"/>\n </properties_list>\n </particlebrush>\n <duplicate>\n <properties_list type=\"array\">\n <item_0 value=\"size\" type=\"value\"/>\n <item_1 value=\"opacity\" type=\"value\"/>\n <item_2 value=\"clone_healing\" type=\"value\"/>\n <item_3 value=\"clone_movesource\" type=\"value\"/>\n </properties_list>\n </duplicate>\n <deformbrush>\n <properties_list type=\"array\">\n <item_0 value=\"size\" type=\"value\"/>\n <item_1 value=\"opacity\" type=\"value\"/>\n <item_2 value=\"deform_amount\" type=\"value\"/>\n <item_3 value=\"deform_mode\" type=\"value\"/>\n </properties_list>\n </deformbrush>\n <tangentnormal>\n <properties_list type=\"array\">\n <item_0 value=\"size\" type=\"value\"/>\n <item_1 value=\"opacity\" type=\"value\"/>\n </properties_list>\n </tangentnormal>\n <filter>\n <properties_list type=\"array\">\n <item_0 value=\"size\" type=\"value\"/>\n <item_1 value=\"opacity\" type=\"value\"/>\n </properties_list>\n </filter>\n <roundmarker>\n <properties_list type=\"array\">\n <item_0 vlue=\"opacity\" type=\"value\"/>\n <item_1 value=\"size\" type=\"value\"/>\n </properties_list>\n </roundmarker>\n</hud_properties>\n";
2582 return defaultValue ? defaultDoc : m_cfg.readEntry("brushHudSettings", defaultDoc);
2583}

References m_cfg.

◆ calculateAnimationCacheInBackground()

bool KisConfig::calculateAnimationCacheInBackground ( bool defaultValue = false) const

Definition at line 2590 of file kis_config.cc.

2591{
2592 return defaultValue ? true : m_cfg.readEntry("calculateAnimationCacheInBackground", true);
2593}

References m_cfg.

◆ canvasBorderColor()

QColor KisConfig::canvasBorderColor ( bool defaultValue = false) const

Definition at line 1245 of file kis_config.cc.

1246{
1247 QColor color(QColor(128,128,128));
1248 return (defaultValue ? color : m_cfg.readEntry("canvasBorderColor", color));
1249}

References m_cfg.

◆ canvasState()

QString KisConfig::canvasState ( bool defaultValue = false) const

Definition at line 1471 of file kis_config.cc.

1472{
1473 const QString configPath = QStandardPaths::writableLocation(QStandardPaths::GenericConfigLocation);
1474 QSettings kritarc(configPath + QStringLiteral("/kritadisplayrc"), QSettings::IniFormat);
1475 return (defaultValue ? "OPENGL_NOT_TRIED" : kritarc.value("canvasState", "OPENGL_NOT_TRIED").toString());
1476}
float value(const T *src, size_t ch)
QString toString(const QString &value)

◆ canvasSurfaceBitDepthMode() [1/2]

KisConfig::CanvasSurfaceBitDepthMode KisConfig::canvasSurfaceBitDepthMode ( bool defaultValue = false) const

Definition at line 681 of file kis_config.cc.

682{
683 const QString configPath = QStandardPaths::writableLocation(QStandardPaths::GenericConfigLocation);
684 QSettings kritarc(configPath + QStringLiteral("/kritadisplayrc"), QSettings::IniFormat);
685 return canvasSurfaceBitDepthMode(&kritarc, defaultValue);
686}
static CanvasSurfaceBitDepthMode canvasSurfaceBitDepthMode(QSettings *settings, bool defaultValue=false)

References canvasSurfaceBitDepthMode().

◆ canvasSurfaceBitDepthMode() [2/2]

KisConfig::CanvasSurfaceBitDepthMode KisConfig::canvasSurfaceBitDepthMode ( QSettings * settings,
bool defaultValue = false )
static

Definition at line 647 of file kis_config.cc.

648{
649 QString modeStr = defaultValue ? "auto" : settings->value("canvasSurfaceBitDepthMode", "auto").toString();
650
651 if (modeStr == "auto") {
653 } else if (modeStr == "8bit") {
655 } else if (modeStr == "10bit") {
657 }
658
660}

References Depth10Bit, Depth8Bit, and DepthAuto.

◆ canvasSurfaceColorSpaceManagementMode()

KisConfig::CanvasSurfaceMode KisConfig::canvasSurfaceColorSpaceManagementMode ( bool defaultValue = false) const

The user-selected mode for the canvas color management mode. The value is meaningful when the operating system supports managed surfaces mode and if the canvas has native surface under it.

Definition at line 609 of file kis_config.cc.

609 {
610 QString modeStr = defaultValue ? "preferred" : m_cfg.readEntry("canvasSurfaceColorSpaceManagementMode", "preferred");
611
612 if (modeStr == "preferred") {
614 } else if (modeStr == "rec709g22") {
616 } else if (modeStr == "rec709g10") {
618 } else if (modeStr == "unmanaged") {
620 } else {
622 }
623}

References m_cfg, Preferred, Rec709g10, Rec709g22, and Unmanaged.

◆ checkersColor1()

QColor KisConfig::checkersColor1 ( bool defaultValue = false) const

Definition at line 1276 of file kis_config.cc.

1277{
1278 QColor col(220, 220, 220);
1279 return (defaultValue ? col : m_cfg.readEntry("checkerscolor", col));
1280}

References m_cfg.

◆ checkersColor2()

QColor KisConfig::checkersColor2 ( bool defaultValue = false) const

Definition at line 1287 of file kis_config.cc.

1288{
1289 return (defaultValue ? QColor(Qt::white) : m_cfg.readEntry("checkerscolor2", QColor(Qt::white)));
1290}

References m_cfg.

◆ checkSize()

qint32 KisConfig::checkSize ( bool defaultValue = false) const

Definition at line 1220 of file kis_config.cc.

1221{
1222 qint32 size = (defaultValue ? 32 : m_cfg.readEntry("checksize", 32));
1223 if (size == 0) size = 32;
1224 return size;
1225}
int size(const Forest< T > &forest)
Definition KisForest.h:1232

References m_cfg.

◆ clicklessSpacePan()

bool KisConfig::clicklessSpacePan ( bool defaultValue = false) const

Definition at line 1631 of file kis_config.cc.

1632{
1633 return (defaultValue ? true : m_cfg.readEntry("clicklessSpacePan", true));
1634}

References m_cfg.

◆ colorHistoryPerDocument()

bool KisConfig::colorHistoryPerDocument ( bool defaultValue = false) const

Definition at line 913 of file kis_config.cc.

914{
915 KConfigGroup cfg = KSharedConfig::openConfig()->group("advancedColorSelector");
916 return (defaultValue ? false : cfg.readEntry("lastUsedColorsPerDocument", false));
917}

◆ colorPreviewRect()

QRect KisConfig::colorPreviewRect ( ) const

Definition at line 523 of file kis_config.cc.

524{
525 return m_cfg.readEntry("colorPreviewRect", QVariant(QRect(32, 32, 48, 48))).toRect();
526}

References m_cfg.

◆ compressKra()

bool KisConfig::compressKra ( bool defaultValue = false) const

Definition at line 2218 of file kis_config.cc.

2219{
2220 return (defaultValue ? false : m_cfg.readEntry("compressLayersInKra", false));
2221}

References m_cfg.

◆ convertLayerColorSpaceInProperties()

bool KisConfig::convertLayerColorSpaceInProperties ( bool defaultValue = false) const

Definition at line 2700 of file kis_config.cc.

2701{
2702 return defaultValue ? true : m_cfg.readEntry("convertLayerColorSpaceInProperties", true);
2703}

References m_cfg.

◆ convertToImageColorspaceOnImport()

bool KisConfig::convertToImageColorspaceOnImport ( bool defaultValue = false) const

Definition at line 2519 of file kis_config.cc.

2520{
2521 return defaultValue ? false : m_cfg.readEntry("ConvertToImageColorSpaceOnImport", false);
2522}

References m_cfg.

◆ cumulativeUndoData()

KisCumulativeUndoData KisConfig::cumulativeUndoData ( bool defaultValue = false) const

Definition at line 209 of file kis_config.cc.

210{
211 if (defaultValue) {
213 }
214
216 data.read(&m_cfg);
217 return data;
218}
static const KisCumulativeUndoData defaultValue
bool read(const KConfigGroup *config)

References KisCumulativeUndoData::defaultValue, m_cfg, and KisCumulativeUndoData::read().

◆ currentInputProfile()

QString KisConfig::currentInputProfile ( bool defaultValue = false) const

Definition at line 1938 of file kis_config.cc.

1939{
1940 return (defaultValue ? QString() : m_cfg.readEntry("currentInputProfile", QString()));
1941}

References m_cfg.

◆ customColorSelectorColorSpace()

const KoColorSpace * KisConfig::customColorSelectorColorSpace ( bool defaultValue = false) const

Definition at line 2333 of file kis_config.cc.

2334{
2335 const KoColorSpace *cs = 0;
2336
2337 KConfigGroup cfg = KSharedConfig::openConfig()->group("advancedColorSelector");
2338 if (defaultValue || cfg.readEntry("useCustomColorSpace", true)) {
2340 QString modelID = cfg.readEntry("customColorSpaceModel", "RGBA");
2341 QString depthID = cfg.readEntry("customColorSpaceDepthID", "U8");
2342 QString profile = cfg.readEntry("customColorSpaceProfile", "sRGB built-in - (lcms internal)");
2343 if (profile == "default") {
2344 // qDebug() << "Falling back to default color profile.";
2345 profile = "sRGB built-in - (lcms internal)";
2346 }
2347 cs = csr->colorSpace(modelID, depthID, profile);
2348 }
2349
2350 return cs;
2351}
const KoColorSpace * colorSpace(const QString &colorModelId, const QString &colorDepthId, const KoColorProfile *profile)
static KoColorSpaceRegistry * instance()

References KoColorSpaceRegistry::colorSpace(), and KoColorSpaceRegistry::instance().

◆ defaultAssistantsColor()

QColor KisConfig::defaultAssistantsColor ( bool defaultValue = false) const

Definition at line 2600 of file kis_config.cc.

2601{
2602 static const QColor defaultColor = QColor(176, 176, 176, 255);
2603 return defaultValue ? defaultColor : m_cfg.readEntry("defaultAssistantsColor", defaultColor);
2604}

References m_cfg.

◆ defaultBackgroundColor()

QColor KisConfig::defaultBackgroundColor ( bool defaultValue = false) const

Definition at line 2018 of file kis_config.cc.

2019{
2020 return (defaultValue ? QColor(Qt::white) : m_cfg.readEntry("BackgroundColorForNewImage", QColor(Qt::white)));
2021}

References m_cfg.

◆ defaultBackgroundOpacity()

quint8 KisConfig::defaultBackgroundOpacity ( bool defaultValue = false) const

Definition at line 2008 of file kis_config.cc.

2009{
2010 return (defaultValue ? (int)OPACITY_OPAQUE_U8 : m_cfg.readEntry("BackgroundOpacityForNewImage", (int)OPACITY_OPAQUE_U8));
2011}
const quint8 OPACITY_OPAQUE_U8

References m_cfg, and OPACITY_OPAQUE_U8.

◆ defaultBackgroundStyle()

KisConfig::BackgroundStyle KisConfig::defaultBackgroundStyle ( bool defaultValue = false) const

Definition at line 2028 of file kis_config.cc.

2029{
2030 return (KisConfig::BackgroundStyle)(defaultValue ? RASTER_LAYER : m_cfg.readEntry("BackgroundStyleForNewImage", (int)RASTER_LAYER));
2031}

References m_cfg, and RASTER_LAYER.

◆ defaultColorDepth()

QString KisConfig::defaultColorDepth ( bool defaultValue = false) const
Returns
the id of the default color depth used for creating new images.

Definition at line 251 of file kis_config.cc.

252{
253 return (defaultValue ? KoColorSpaceRegistry::instance()->rgb8()->colorDepthId().id()
254 : m_cfg.readEntry("colorDepthDef", KoColorSpaceRegistry::instance()->rgb8()->colorDepthId().id()));
255}
PythonPluginManager * instance

References KoColorSpaceRegistry::instance(), and m_cfg.

◆ defaultPalette()

QString KisConfig::defaultPalette ( bool defaultValue = false) const

Definition at line 1881 of file kis_config.cc.

1882{
1883 return (defaultValue ? QString() : m_cfg.readEntry("defaultPalette", "Default"));
1884}

References m_cfg.

◆ defColorModel() [1/2]

QString KisConfig::defColorModel ( bool defaultValue = false) const
Returns
the id of the default color model used for creating new images.

Definition at line 240 of file kis_config.cc.

241{
242 return (defaultValue ? KoColorSpaceRegistry::instance()->rgb8()->colorModelId().id()
243 : m_cfg.readEntry("colorModelDef", KoColorSpaceRegistry::instance()->rgb8()->colorModelId().id()));
244}

References KoColorSpaceRegistry::instance(), and m_cfg.

◆ defColorModel() [2/2]

void KisConfig::defColorModel ( const QString & model) const

set the id of the default color model used for creating new images.

Definition at line 246 of file kis_config.cc.

247{
248 m_cfg.writeEntry("colorModelDef", model);
249}

References m_cfg.

◆ defColorProfile() [1/2]

QString KisConfig::defColorProfile ( bool defaultValue = false) const
Returns
the id of the default color profile used for creating new images.

Definition at line 262 of file kis_config.cc.

263{
264 return (defaultValue ? KoColorSpaceRegistry::instance()->rgb8()->profile()->name() :
265 m_cfg.readEntry("colorProfileDef",
266 KoColorSpaceRegistry::instance()->rgb8()->profile()->name()));
267}
const char * name(StandardAction id)

References KoColorSpaceRegistry::instance(), and m_cfg.

◆ defColorProfile() [2/2]

void KisConfig::defColorProfile ( const QString & depth) const

set the id of the default color profile used for creating new images.

Definition at line 269 of file kis_config.cc.

270{
271 m_cfg.writeEntry("colorProfileDef", profile);
272}

References m_cfg.

◆ defImageHeight() [1/2]

qint32 KisConfig::defImageHeight ( bool defaultValue = false) const

Definition at line 230 of file kis_config.cc.

231{
232 return (defaultValue ? 3508 : m_cfg.readEntry("imageHeightDef", 3508));
233}

References m_cfg.

◆ defImageHeight() [2/2]

void KisConfig::defImageHeight ( qint32 height) const

Definition at line 279 of file kis_config.cc.

280{
281 m_cfg.writeEntry("imageHeightDef", height);
282}

References m_cfg.

◆ defImageResolution() [1/2]

qreal KisConfig::defImageResolution ( bool defaultValue = false) const

Definition at line 235 of file kis_config.cc.

236{
237 return (defaultValue ? 300.0 : m_cfg.readEntry("imageResolutionDef", 300.0)) / 72.0;
238}

References m_cfg.

◆ defImageResolution() [2/2]

void KisConfig::defImageResolution ( qreal res) const

Definition at line 284 of file kis_config.cc.

285{
286 m_cfg.writeEntry("imageResolutionDef", res*72.0);
287}

References m_cfg.

◆ defImageWidth() [1/2]

qint32 KisConfig::defImageWidth ( bool defaultValue = false) const

Definition at line 225 of file kis_config.cc.

226{
227 return (defaultValue ? 2480 : m_cfg.readEntry("imageWidthDef", 2480));
228}

References m_cfg.

◆ defImageWidth() [2/2]

void KisConfig::defImageWidth ( qint32 width) const

Definition at line 274 of file kis_config.cc.

275{
276 m_cfg.writeEntry("imageWidthDef", width);
277}

References m_cfg.

◆ disableAVXOptimizations()

bool KisConfig::disableAVXOptimizations ( bool defaultValue = false) const

Definition at line 2401 of file kis_config.cc.

2402{
2403 return (defaultValue ? false : m_cfg.readEntry("disableAVXOptimizations", false));
2404}

References m_cfg.

◆ disableOpenGL()

void KisConfig::disableOpenGL ( ) const

Definition at line 1006 of file kis_config.cc.

1007{
1008 const QString configPath = QStandardPaths::writableLocation(QStandardPaths::GenericConfigLocation);
1009 QSettings kritarc(configPath + QStringLiteral("/kritadisplayrc"), QSettings::IniFormat);
1010
1011 kritarc.setValue("OpenGLRenderer", "none");
1012}

◆ disableTouchOnCanvas()

bool KisConfig::disableTouchOnCanvas ( ) const

Definition at line 154 of file kis_config.cc.

155{
156 switch (touchPainting()) {
158 return false;
160 return true;
161 default:
162 // Automatic detection: enable or disable touch input based on whether
163 // we've received a tablet input during this session and therefore know
164 // that the user has a pen available.
166 }
167}
TouchPainting touchPainting(bool defaultValue=false) const
static bool tabletInputReceived()

References KoPointerEvent::tabletInputReceived(), TOUCH_PAINTING_DISABLED, TOUCH_PAINTING_ENABLED, and touchPainting().

◆ disableVectorOptimizations()

bool KisConfig::disableVectorOptimizations ( bool defaultValue = false) const

Definition at line 2390 of file kis_config.cc.

2391{
2392 // use the old key name for compatibility
2393 return (defaultValue ? false : m_cfg.readEntry("amdDisableVectorWorkaround", false));
2394}

References m_cfg.

◆ displayProfile()

const KoColorProfile * KisConfig::displayProfile ( int screen) const

Get the actual profile to be used for the given screen, which is either the screen profile set by the color management system or the custom monitor profile set by the user, depending on the configuration

Definition at line 785 of file kis_config.cc.

786{
787 if (screen < 0) return 0;
788
789 // if the user plays with the settings, they can override the display profile, in which case
790 // we don't want the system setting.
791 bool override = useSystemMonitorProfile();
792 //dbgKrita << "KisConfig::displayProfile(). Override X11:" << override;
793 const KoColorProfile *profile = 0;
794 if (override) {
795 //dbgKrita << "\tGoing to get the screen profile";
796 profile = KisConfig::getScreenProfile(screen);
797 }
798
799 // if it fails. check the configuration
800 if (!profile || !profile->isSuitableForDisplay()) {
801 //dbgKrita << "\tGoing to get the monitor profile";
802 QString monitorProfileName = monitorProfile(screen);
803 //dbgKrita << "\t\tmonitorProfileName:" << monitorProfileName;
804 if (!monitorProfileName.isEmpty()) {
805 profile = KoColorSpaceRegistry::instance()->profileByName(monitorProfileName);
806 }
807 if (profile) {
808 //dbgKrita << "\t\tsuitable for display" << profile->isSuitableForDisplay();
809 }
810 else {
811 //dbgKrita << "\t\tstill no profile";
812 }
813 }
814 // if we still don't have a profile, or the profile isn't suitable for display,
815 // we need to get a last-resort profile. the built-in sRGB is a good choice then.
816 if (!profile || !profile->isSuitableForDisplay()) {
817 //dbgKrita << "\tnothing worked, going to get sRGB built-in";
818 profile = KoColorSpaceRegistry::instance()->profileByName("sRGB Built-in");
819 }
820
821 if (profile) {
822 //dbgKrita << "\tKisConfig::displayProfile for screen" << screen << "is" << profile->name();
823 }
824 else {
825 //dbgKrita << "\tCouldn't get a display profile at all";
826 }
827
828 return profile;
829}
QString monitorProfile(int screen) const
get the profile the user has selected for the given screen
bool useSystemMonitorProfile(bool defaultValue=false) const
static const KoColorProfile * getScreenProfile(int screen)
get the profile the color management system has stored for the given screen
virtual bool isSuitableForDisplay() const =0
const KoColorProfile * profileByName(const QString &name) const

References getScreenProfile(), KoColorSpaceRegistry::instance(), KoColorProfile::isSuitableForDisplay(), monitorProfile(), KoColorSpaceRegistry::profileByName(), and useSystemMonitorProfile().

◆ effectiveCanvasSurfaceBitDepthMode()

KisConfig::CanvasSurfaceBitDepthMode KisConfig::effectiveCanvasSurfaceBitDepthMode ( const QSurfaceFormat & format) const

Definition at line 695 of file kis_config.cc.

696{
697 auto mode = canvasSurfaceBitDepthMode();
698
700 if (format.redBufferSize() == 10 &&
701 format.greenBufferSize() == 10 &&
702 format.blueBufferSize() == 10) {
703
705 } else {
707 }
708 }
709
710 return mode;
711}

References canvasSurfaceBitDepthMode(), Depth10Bit, Depth8Bit, and DepthAuto.

◆ enableBrushSpeedLogging()

bool KisConfig::enableBrushSpeedLogging ( bool defaultValue = false) const

Definition at line 2374 of file kis_config.cc.

2375{
2376 return (defaultValue ? false : m_cfg.readEntry("enableBrushSpeedLogging", false));
2377}

References m_cfg.

◆ enableCanvasSurfaceColorSpaceManagement()

bool KisConfig::enableCanvasSurfaceColorSpaceManagement ( bool defaultValue = false) const

Controls if the canvas should have a separate color managed surface. Even though the surface can be created on any platform the proper color management support for it may be not present (currently supported on Wayland only). To check if the current platform supports surface management mode, test if KisMainWindow::managedSurfaceProfile() is not null.

Definition at line 599 of file kis_config.cc.

600{
601 return (defaultValue ? true : m_cfg.readEntry("enableCanvasSurfaceColorSpaceManagement",true));
602}

References m_cfg.

◆ enableOpenGLFramerateLogging()

bool KisConfig::enableOpenGLFramerateLogging ( bool defaultValue = false) const

Definition at line 2364 of file kis_config.cc.

2365{
2366 return (defaultValue ? false : m_cfg.readEntry("enableOpenGLFramerateLogging", false));
2367}

References m_cfg.

◆ enablePixelGrid()

void KisConfig::enablePixelGrid ( bool v) const

Definition at line 1161 of file kis_config.cc.

1162{
1163 m_cfg.writeEntry("pixelGridEnabled", v);
1164}
qreal v

References m_cfg, and v.

◆ eraserCursorStyle()

CursorStyle KisConfig::eraserCursorStyle ( bool defaultValue = false) const

Definition at line 469 of file kis_config.cc.

470{
471 if (defaultValue) {
472 return CURSOR_STYLE_ERASER;
473 }
474
475 int style = m_cfg.readEntry("eraserCursorStyle", int(-1));
476
477 // compatibility with future versions
478 if (style < 0 || style >= N_CURSOR_STYLE_SIZE) {
479 style = CURSOR_STYLE_ERASER;
480 }
481
482 return (CursorStyle) style;
483}
CursorStyle
Definition kis_global.h:62
@ N_CURSOR_STYLE_SIZE
Definition kis_global.h:74
@ CURSOR_STYLE_ERASER
Definition kis_global.h:72

References CURSOR_STYLE_ERASER, m_cfg, and N_CURSOR_STYLE_SIZE.

◆ eraserOutlineStyle()

OutlineStyle KisConfig::eraserOutlineStyle ( bool defaultValue = false) const

Definition at line 502 of file kis_config.cc.

503{
504 if (defaultValue) {
505 return OUTLINE_FULL;
506 }
507
508 int style = m_cfg.readEntry("eraserOutlineStyle", int(-1));
509
510 // compatibility with future versions
511 if (style < 0 || style >= N_OUTLINE_STYLE_SIZE) {
512 style = OUTLINE_FULL;
513 }
514
515 return (OutlineStyle) style;
516}
OutlineStyle
Definition kis_global.h:53
@ N_OUTLINE_STYLE_SIZE
Definition kis_global.h:59
@ OUTLINE_FULL
Definition kis_global.h:56

References m_cfg, N_OUTLINE_STYLE_SIZE, and OUTLINE_FULL.

◆ exportConfiguration()

KisPropertiesConfigurationSP KisConfig::exportConfiguration ( const QString & filterId,
bool defaultValue = false ) const

Definition at line 1759 of file kis_config.cc.

1760{
1762 const QString xmlData = exportConfigurationXML(filterId, defaultValue);
1763 cfg->fromXML(xmlData);
1764 return cfg;
1765}
QString exportConfigurationXML(const QString &filterId, bool defaultValue=false) const

References exportConfigurationXML().

◆ exportConfigurationXML()

QString KisConfig::exportConfigurationXML ( const QString & filterId,
bool defaultValue = false ) const

Definition at line 1754 of file kis_config.cc.

1755{
1756 return (defaultValue ? QString() : m_cfg.readEntry("ExportConfiguration-" + filterId, QString()));
1757}

References m_cfg.

◆ exportMimeType()

QString KisConfig::exportMimeType ( bool defaultValue) const

Definition at line 2247 of file kis_config.cc.

2248{
2249 return (defaultValue ? 0 : m_cfg.readEntry("defaultExportMimeType", QString()));
2250}

References m_cfg.

◆ favoriteCompositeOps()

QStringList KisConfig::favoriteCompositeOps ( bool defaultValue = false) const

Definition at line 1742 of file kis_config.cc.

1743{
1744 return (defaultValue ? QStringList() :
1745 m_cfg.readEntry("favoriteCompositeOps",
1746 QString("normal,erase,multiply,burn,darken,add,dodge,screen,overlay,soft_light_svg,luminize,lighten,saturation,color,divide").split(',')));
1747}
QList< QString > QStringList
QList< KoSubpath * > split(const KoPathShape &path)

References m_cfg.

◆ favoritePresets()

int KisConfig::favoritePresets ( bool defaultValue = false) const

Definition at line 1799 of file kis_config.cc.

1800{
1801 return (defaultValue ? 10: m_cfg.readEntry("numFavoritePresets", 10));
1802}

References m_cfg.

◆ ffmpegLocation()

QString KisConfig::ffmpegLocation ( bool defaultValue = false) const

Definition at line 2456 of file kis_config.cc.

2456 {
2457 return (defaultValue ? "" : m_cfg.readEntry("ffmpegLocation", ""));
2458}

References m_cfg.

◆ firstRun()

bool KisConfig::firstRun ( bool defaultValue = false) const

Definition at line 1602 of file kis_config.cc.

1603{
1604 return (defaultValue ? true : m_cfg.readEntry("firstRun", true));
1605}

References m_cfg.

◆ forceAlwaysFullSizedEraserOutline()

bool KisConfig::forceAlwaysFullSizedEraserOutline ( bool defaultValue = false) const

Definition at line 1371 of file kis_config.cc.

1372{
1373 return (defaultValue ? false : m_cfg.readEntry("forceAlwaysFullSizedEraserOutline", false));
1374}

References m_cfg.

◆ forceAlwaysFullSizedOutline()

bool KisConfig::forceAlwaysFullSizedOutline ( bool defaultValue = false) const

Definition at line 1349 of file kis_config.cc.

1350{
1351 return (defaultValue ? false : m_cfg.readEntry("forceAlwaysFullSizedOutline", false));
1352}

References m_cfg.

◆ forceOpenGLFenceWorkaround()

bool KisConfig::forceOpenGLFenceWorkaround ( bool defaultValue = false) const

Definition at line 1049 of file kis_config.cc.

1050{
1051 return (defaultValue ? false : m_cfg.readEntry("forceOpenGLFenceWorkaround", false));
1052}

References m_cfg.

◆ forcePaletteColors()

bool KisConfig::forcePaletteColors ( bool defaultValue = false) const

Definition at line 903 of file kis_config.cc.

904{
905 return (defaultValue ? false : m_cfg.readEntry("colorsettings/forcepalettecolors", false));
906}

References m_cfg.

◆ forceShowAutosaveMessages()

bool KisConfig::forceShowAutosaveMessages ( bool defaultValue = true) const

Definition at line 939 of file kis_config.cc.

940{
941 return (defaultValue ? false : m_cfg.readEntry("forceShowAutosaveMessages", false));
942}

References m_cfg.

◆ forceShowSaveMessages()

bool KisConfig::forceShowSaveMessages ( bool defaultValue = true) const

Definition at line 929 of file kis_config.cc.

930{
931 return (defaultValue ? false : m_cfg.readEntry("forceShowSaveMessages", false));
932}

References m_cfg.

◆ fullscreenMode()

bool KisConfig::fullscreenMode ( bool defaultValue = false) const

Definition at line 1732 of file kis_config.cc.

1733{
1734 return (defaultValue ? true : m_cfg.readEntry("fullscreenMode", false));
1735}

References m_cfg.

◆ getCursorMainColor()

QColor KisConfig::getCursorMainColor ( bool defaultValue = false) const

Definition at line 380 of file kis_config.cc.

381{
382 QColor col;
383 col.setRgbF(1.0, 0.0, 1.0);
384 return (defaultValue ? col : m_cfg.readEntry("cursorMaincColor", col));
385}

References m_cfg.

◆ getDefaultGridSpacing()

QPoint KisConfig::getDefaultGridSpacing ( bool defaultValue = false) const

Definition at line 565 of file kis_config.cc.

566{
567 return (defaultValue ? QPoint(16, 16) : m_cfg.readEntry("defaultGridSpacing", QPoint(16, 16)));
568}

References m_cfg.

◆ getEraserCursorMainColor()

QColor KisConfig::getEraserCursorMainColor ( bool defaultValue = false) const

Definition at line 490 of file kis_config.cc.

491{
492 QColor col;
493 col.setRgbF(0.501961, 1.0, 0.501961);
494 return (defaultValue ? col : m_cfg.readEntry("eraserCursorMaincColor", col));
495}

References m_cfg.

◆ getGridIsoVerticalColor()

QColor KisConfig::getGridIsoVerticalColor ( bool defaultValue = false) const

Definition at line 1122 of file kis_config.cc.

1123{
1124 QColor col(150, 150, 150);
1125 return (defaultValue ? col : m_cfg.readEntry("gridisoverticalcolor", col));
1126}

References m_cfg.

◆ getGridIsoVerticalStyle()

quint32 KisConfig::getGridIsoVerticalStyle ( bool defaultValue = false) const

Definition at line 1088 of file kis_config.cc.

1089{
1090 int v = m_cfg.readEntry("gridisoverticalstyle", 0);
1091 v = qBound(0, v, 3);
1092 return (defaultValue ? 0 : v);
1093}

References m_cfg, and v.

◆ getGridMainColor()

QColor KisConfig::getGridMainColor ( bool defaultValue = false) const

Definition at line 1100 of file kis_config.cc.

1101{
1102 QColor col(99, 99, 99);
1103 return (defaultValue ? col : m_cfg.readEntry("gridmaincolor", col));
1104}

References m_cfg.

◆ getGridMainStyle()

quint32 KisConfig::getGridMainStyle ( bool defaultValue = false) const

Definition at line 1064 of file kis_config.cc.

1065{
1066 int v = m_cfg.readEntry("gridmainstyle", 0);
1067 v = qBound(0, v, 2);
1068 return (defaultValue ? 0 : v);
1069}

References m_cfg, and v.

◆ getGridSubdivisionColor()

QColor KisConfig::getGridSubdivisionColor ( bool defaultValue = false) const

Definition at line 1111 of file kis_config.cc.

1112{
1113 QColor col(150, 150, 150);
1114 return (defaultValue ? col : m_cfg.readEntry("gridsubdivisioncolor", col));
1115}

References m_cfg.

◆ getGridSubdivisionStyle()

quint32 KisConfig::getGridSubdivisionStyle ( bool defaultValue = false) const

Definition at line 1076 of file kis_config.cc.

1077{
1078 quint32 v = m_cfg.readEntry("gridsubdivisionstyle", 1);
1079 if (v > 2) v = 2;
1080 return (defaultValue ? 1 : v);
1081}

References m_cfg, and v.

◆ getMDIBackgroundColor()

QString KisConfig::getMDIBackgroundColor ( bool defaultValue = false) const

Definition at line 575 of file kis_config.cc.

576{
577 QColor col(77, 77, 77);
579 kol.fromQColor(col);
580 QString xml = kol.toXML();
581 return (defaultValue ? xml : m_cfg.readEntry("mdiBackgroundColorXML", xml));
582}

References KoColor::fromQColor(), KoColorSpaceRegistry::instance(), m_cfg, and KoColor::toXML().

◆ getMDIBackgroundImage()

QString KisConfig::getMDIBackgroundImage ( bool defaultValue = false) const

Definition at line 589 of file kis_config.cc.

590{
591 return (defaultValue ? "" : m_cfg.readEntry("mdiBackgroundImage", ""));
592}

References m_cfg.

◆ getPixelGridColor()

QColor KisConfig::getPixelGridColor ( bool defaultValue = false) const

Definition at line 1133 of file kis_config.cc.

1134{
1135 QColor col(255, 255, 255);
1136 return (defaultValue ? col : m_cfg.readEntry("pixelGridColor", col));
1137}

References m_cfg.

◆ getPixelGridDrawingThreshold()

qreal KisConfig::getPixelGridDrawingThreshold ( bool defaultValue = false) const

Definition at line 1144 of file kis_config.cc.

1145{
1146 qreal border = 24.0f;
1147 return (defaultValue ? border : m_cfg.readEntry("pixelGridDrawingThreshold", border));
1148}

References m_cfg.

◆ getScreenProfile()

const KoColorProfile * KisConfig::getScreenProfile ( int screen)
static

get the profile the color management system has stored for the given screen

Definition at line 759 of file kis_config.cc.

760{
761 if (screen < 0) return 0;
762
763 KisConfig cfg(true);
764 QString monitorId;
765 if (KisColorManager::instance()->devices().size() > screen) {
766 monitorId = cfg.monitorForScreen(screen, KisColorManager::instance()->devices()[screen]);
767 }
768 //dbgKrita << "getScreenProfile(). Screen" << screen << "monitor id" << monitorId;
769
770 if (monitorId.isEmpty()) {
771 return 0;
772 }
773
774 QByteArray bytes = KisColorManager::instance()->displayProfile(monitorId);
775
776 //dbgKrita << "\tgetScreenProfile()" << bytes.size();
777 const KoColorProfile * profile = 0;
778 if (bytes.length() > 0) {
780 //dbgKrita << "\tKisConfig::getScreenProfile for screen" << screen << profile->name();
781 }
782 return profile;
783}
const KoID Integer8BitsColorDepthID("U8", ki18n("8-bit integer/channel"))
const KoID RGBAColorModelID("RGBA", ki18n("RGB/Alpha"))
QByteArray displayProfile(const QString &device, int profile=0) const
Return the icc profile for the given device and index (if a device has more than one profile)
static KisColorManager * instance()
QString id() const
Definition KoID.cpp:63
const KoColorProfile * createColorProfile(const QString &colorModelId, const QString &colorDepthId, const QByteArray &rawData)

References KoColorSpaceRegistry::createColorProfile(), KisColorManager::displayProfile(), KoID::id(), KisColorManager::instance(), KoColorSpaceRegistry::instance(), Integer8BitsColorDepthID, monitorForScreen(), and RGBAColorModelID.

◆ getScreenStringIdentfier()

const QString KisConfig::getScreenStringIdentfier ( int screenNo) const

Definition at line 831 of file kis_config.cc.

831 {
832 if (screenNo < 0 || screenNo >= QGuiApplication::screens().length()) {
833 return QString();
834 }
835 QScreen* screen = QGuiApplication::screens()[screenNo];
836
837 QString manufacturer = screen->manufacturer();
838 QString model = screen->model();
839 QString serialNumber = screen->serialNumber();
840
841 if (manufacturer == "" && model == "" && serialNumber == "") {
842 return QString(); // it would be scary to base the profile just on resolution
843 }
844
845 QString identifier = QStringList({manufacturer, model, serialNumber}).join("_");
846 return identifier;
847}
qreal length(const QPointF &vec)
Definition Ellipse.cc:82

References length().

◆ guidesColor()

QColor KisConfig::guidesColor ( bool defaultValue = false) const

Definition at line 1178 of file kis_config.cc.

1179{
1180 QColor col(99, 99, 99);
1181 return (defaultValue ? col : m_cfg.readEntry("guidesColor", col));
1182}

References m_cfg.

◆ guidesLineStyle()

quint32 KisConfig::guidesLineStyle ( bool defaultValue = false) const

Definition at line 1166 of file kis_config.cc.

1167{
1168 int v = m_cfg.readEntry("guidesLineStyle", 0);
1169 v = qBound(0, v, 2);
1170 return (defaultValue ? 0 : v);
1171}

References m_cfg, and v.

◆ hideDevFundBanner()

bool KisConfig::hideDevFundBanner ( bool defaultValue = false) const

Definition at line 1400 of file kis_config.cc.

1401{
1402 return defaultValue ? false : m_cfg.readEntry("hideDevFundBanner", false);
1403}

References m_cfg.

◆ hideDockersFullscreen()

bool KisConfig::hideDockersFullscreen ( bool defaultValue = false) const

Definition at line 1642 of file kis_config.cc.

1643{
1644 return (defaultValue ? true : m_cfg.readEntry("hideDockersFullScreen", true));
1645}

References m_cfg.

◆ hideMenuFullscreen()

bool KisConfig::hideMenuFullscreen ( bool defaultValue = false) const

Definition at line 1682 of file kis_config.cc.

1683{
1684 return (defaultValue ? true: m_cfg.readEntry("hideMenuFullScreen", true));
1685}

References m_cfg.

◆ hidePopups()

bool KisConfig::hidePopups ( bool defaultValue = false) const

Definition at line 1988 of file kis_config.cc.

1989{
1990 return (defaultValue ? false : m_cfg.readEntry("hidePopups", false));
1991}

References m_cfg.

◆ hideScrollbars()

bool KisConfig::hideScrollbars ( bool defaultValue = false) const

Definition at line 1256 of file kis_config.cc.

1257{
1258 return (defaultValue ? false : m_cfg.readEntry("hideScrollbars", false));
1259}

References m_cfg.

◆ hideScrollbarsFullscreen()

bool KisConfig::hideScrollbarsFullscreen ( bool defaultValue = false) const

Definition at line 1692 of file kis_config.cc.

1693{
1694 return (defaultValue ? true : m_cfg.readEntry("hideScrollbarsFullScreen", true));
1695}

References m_cfg.

◆ hideStatusbarFullscreen()

bool KisConfig::hideStatusbarFullscreen ( bool defaultValue = false) const

Definition at line 1702 of file kis_config.cc.

1703{
1704 return (defaultValue ? true: m_cfg.readEntry("hideStatusbarFullScreen", true));
1705}

References m_cfg.

◆ hideTitlebarFullscreen()

bool KisConfig::hideTitlebarFullscreen ( bool defaultValue = false) const

Definition at line 1712 of file kis_config.cc.

1713{
1714 return (defaultValue ? true : m_cfg.readEntry("hideTitleBarFullscreen", true));
1715}

References m_cfg.

◆ hideToolbarFullscreen()

bool KisConfig::hideToolbarFullscreen ( bool defaultValue = false) const

Definition at line 1722 of file kis_config.cc.

1723{
1724 return (defaultValue ? true : m_cfg.readEntry("hideToolbarFullscreen", true));
1725}

References m_cfg.

◆ horizontalSplitLines()

int KisConfig::horizontalSplitLines ( bool defaultValue = false) const

Definition at line 1612 of file kis_config.cc.

1613{
1614 return (defaultValue ? 1 : m_cfg.readEntry("horizontalSplitLines", 1));
1615}

References m_cfg.

◆ ignoreHighFunctionKeys()

bool KisConfig::ignoreHighFunctionKeys ( bool defaultValue = false) const

Definition at line 2168 of file kis_config.cc.

2169{
2170 return (defaultValue ? true : m_cfg.readEntry("ignoreHighFunctionKeys", true));
2171}

References m_cfg.

◆ importConfiguration()

QString KisConfig::importConfiguration ( const QString & filterId,
bool defaultValue = false ) const

Definition at line 1773 of file kis_config.cc.

1774{
1775 return (defaultValue ? QString() : m_cfg.readEntry("ImportConfiguration-" + filterId, QString()));
1776}

References m_cfg.

◆ importProfile()

QString KisConfig::importProfile ( bool defaultValue = false) const

◆ kineticScrollingEnabled()

bool KisConfig::kineticScrollingEnabled ( bool defaultValue = false) const

Definition at line 2267 of file kis_config.cc.

2268{
2269 return (defaultValue ? true : m_cfg.readEntry("KineticScrollingEnabled", true));
2270}

References m_cfg.

◆ kineticScrollingGesture()

int KisConfig::kineticScrollingGesture ( bool defaultValue = false) const

Definition at line 2277 of file kis_config.cc.

2278{
2279#ifdef Q_OS_ANDROID
2280 int defaultGesture = 1; // LeftMouseButtonGesture
2281#else
2282 int defaultGesture = 2; // MiddleMouseButtonGesture
2283#endif
2284
2285 return (defaultValue ? defaultGesture : m_cfg.readEntry("KineticScrollingGesture", defaultGesture));
2286}

References m_cfg.

◆ kineticScrollingHiddenScrollbars()

bool KisConfig::kineticScrollingHiddenScrollbars ( bool defaultValue = false) const

Definition at line 2303 of file kis_config.cc.

2304{
2305 return (defaultValue ? false : m_cfg.readEntry("KineticScrollingHideScrollbar", false));
2306}

References m_cfg.

◆ kineticScrollingSensitivity()

int KisConfig::kineticScrollingSensitivity ( bool defaultValue = false) const

Definition at line 2293 of file kis_config.cc.

2294{
2295 return (defaultValue ? 75 : m_cfg.readEntry("KineticScrollingSensitivity", 75));
2296}

References m_cfg.

◆ lastUsedOutlineStyle()

OutlineStyle KisConfig::lastUsedOutlineStyle ( bool defaultValue = false) const

Definition at line 441 of file kis_config.cc.

442{
443 if (defaultValue) {
444 return OUTLINE_NONE;
445 }
446
447 int style = m_cfg.readEntry("lastUsedOutlineStyle", int(-1));
448
449 return (OutlineStyle) style;
450}
@ OUTLINE_NONE
Definition kis_global.h:54

References m_cfg, and OUTLINE_NONE.

◆ layerInfoTextOpacity()

int KisConfig::layerInfoTextOpacity ( bool defaultValue = false) const

Definition at line 2730 of file kis_config.cc.

2731{
2732 return defaultValue ? 55 : m_cfg.readEntry("layerInfoTextOpacity", 55);
2733}

References m_cfg.

◆ layerInfoTextStyle()

KisConfig::LayerInfoTextStyle KisConfig::layerInfoTextStyle ( bool defaultValue = false) const

Definition at line 2720 of file kis_config.cc.

2721{
2722 return (KisConfig::LayerInfoTextStyle)(defaultValue ? INFOTEXT_NONE : m_cfg.readEntry("layerInfoTextStyle", (int)INFOTEXT_NONE));
2723}

References INFOTEXT_NONE, and m_cfg.

◆ layerThumbnailSize()

int KisConfig::layerThumbnailSize ( bool defaultValue = false) const

Definition at line 1908 of file kis_config.cc.

1909{
1910 return (defaultValue ? 20 : m_cfg.readEntry("layerThumbnailSize", 20));
1911}

References m_cfg.

◆ layerTreeIndentation()

int KisConfig::layerTreeIndentation ( bool defaultValue = false) const

Definition at line 1918 of file kis_config.cc.

1919{
1920 return (defaultValue ? 50 : m_cfg.readEntry("layerTreeIndentation", 50));
1921}

References m_cfg.

◆ levelOfDetailEnabled()

bool KisConfig::levelOfDetailEnabled ( bool defaultValue = false) const

Definition at line 1809 of file kis_config.cc.

1810{
1811 return (defaultValue ? false : m_cfg.readEntry("levelOfDetailEnabled", false));
1812}

References m_cfg.

◆ lineSmoothingDelayDistance()

qreal KisConfig::lineSmoothingDelayDistance ( bool defaultValue = false) const

Definition at line 2108 of file kis_config.cc.

2109{
2110 return (defaultValue ? 50.0 : m_cfg.readEntry("LineSmoothingDelayDistance", 50.0));
2111}

References m_cfg.

◆ lineSmoothingDistanceKeepAspectRatio()

bool KisConfig::lineSmoothingDistanceKeepAspectRatio ( bool defaultValue = false) const

Definition at line 2068 of file kis_config.cc.

2069{
2070 return (defaultValue ? true : m_cfg.readEntry("LineSmoothingDistanceKeepAspectRatio", true));
2071}

References m_cfg.

◆ lineSmoothingDistanceMax()

qreal KisConfig::lineSmoothingDistanceMax ( bool defaultValue = false) const

Definition at line 2058 of file kis_config.cc.

2059{
2060 return (defaultValue ? 50.0 : m_cfg.readEntry("LineSmoothingDistanceMax", 50.0));
2061}

References m_cfg.

◆ lineSmoothingDistanceMin()

qreal KisConfig::lineSmoothingDistanceMin ( bool defaultValue = false) const

Definition at line 2048 of file kis_config.cc.

2049{
2050 return (defaultValue ? 50.0 : m_cfg.readEntry("LineSmoothingDistanceMin", 50.0));
2051}

References m_cfg.

◆ lineSmoothingFinishStabilizedCurve()

bool KisConfig::lineSmoothingFinishStabilizedCurve ( bool defaultValue = false) const

Definition at line 2128 of file kis_config.cc.

2129{
2130 return (defaultValue ? true : m_cfg.readEntry("LineSmoothingFinishStabilizedCurve", true));
2131}

References m_cfg.

◆ lineSmoothingScalableDistance()

bool KisConfig::lineSmoothingScalableDistance ( bool defaultValue = false) const

Definition at line 2098 of file kis_config.cc.

2099{
2100 return (defaultValue ? true : m_cfg.readEntry("LineSmoothingScalableDistance", true));
2101}

References m_cfg.

◆ lineSmoothingSmoothPressure()

bool KisConfig::lineSmoothingSmoothPressure ( bool defaultValue = false) const

Definition at line 2088 of file kis_config.cc.

2089{
2090 return (defaultValue ? false : m_cfg.readEntry("LineSmoothingSmoothPressure", false));
2091}

References m_cfg.

◆ lineSmoothingStabilizeSensors()

bool KisConfig::lineSmoothingStabilizeSensors ( bool defaultValue = false) const

Definition at line 2138 of file kis_config.cc.

2139{
2140 return (defaultValue ? true : m_cfg.readEntry("LineSmoothingStabilizeSensors", true));
2141}

References m_cfg.

◆ lineSmoothingTailAggressiveness()

qreal KisConfig::lineSmoothingTailAggressiveness ( bool defaultValue = false) const

Definition at line 2078 of file kis_config.cc.

2079{
2080 return (defaultValue ? 0.15 : m_cfg.readEntry("LineSmoothingTailAggressiveness", 0.15));
2081}

References m_cfg.

◆ lineSmoothingType()

int KisConfig::lineSmoothingType ( bool defaultValue = false) const

Definition at line 2038 of file kis_config.cc.

2039{
2040 return (defaultValue ? 1 : m_cfg.readEntry("LineSmoothingType", 1));
2041}

References m_cfg.

◆ lineSmoothingUseDelayDistance()

bool KisConfig::lineSmoothingUseDelayDistance ( bool defaultValue = false) const

Definition at line 2118 of file kis_config.cc.

2119{
2120 return (defaultValue ? true : m_cfg.readEntry("LineSmoothingUseDelayDistance", true));
2121}

References m_cfg.

◆ loadSnapConfig()

void KisConfig::loadSnapConfig ( KisSnapConfig * config,
bool defaultValue = false ) const

Definition at line 1189 of file kis_config.cc.

1190{
1191 KisSnapConfig defaultConfig(false);
1192
1193 if (defaultValue) {
1194 *config = defaultConfig;
1195 return;
1196 }
1197
1198 config->setOrthogonal(m_cfg.readEntry("globalSnapOrthogonal", defaultConfig.orthogonal()));
1199 config->setNode(m_cfg.readEntry("globalSnapNode", defaultConfig.node()));
1200 config->setExtension(m_cfg.readEntry("globalSnapExtension", defaultConfig.extension()));
1201 config->setIntersection(m_cfg.readEntry("globalSnapIntersection", defaultConfig.intersection()));
1202 config->setBoundingBox(m_cfg.readEntry("globalSnapBoundingBox", defaultConfig.boundingBox()));
1203 config->setImageBounds(m_cfg.readEntry("globalSnapImageBounds", defaultConfig.imageBounds()));
1204 config->setImageCenter(m_cfg.readEntry("globalSnapImageCenter", defaultConfig.imageCenter()));
1205 config->setToPixel(m_cfg.readEntry("globalSnapToPixel", defaultConfig.toPixel()));
1206}
void setImageCenter(bool value)
void setIntersection(bool value)
void setOrthogonal(bool value)
void setExtension(bool value)
void setToPixel(bool value)
void setBoundingBox(bool value)
void setImageBounds(bool value)
void setNode(bool value)

References KisSnapConfig::boundingBox(), KisSnapConfig::extension(), KisSnapConfig::imageBounds(), KisSnapConfig::imageCenter(), KisSnapConfig::intersection(), m_cfg, KisSnapConfig::node(), KisSnapConfig::orthogonal(), KisSnapConfig::setBoundingBox(), KisSnapConfig::setExtension(), KisSnapConfig::setImageBounds(), KisSnapConfig::setImageCenter(), KisSnapConfig::setIntersection(), KisSnapConfig::setNode(), KisSnapConfig::setOrthogonal(), KisSnapConfig::setToPixel(), and KisSnapConfig::toPixel().

◆ logImportantSettings

void KisConfig::logImportantSettings ( ) const
slot

Log the most interesting settings to the usage log.

Definition at line 73 of file kis_config.cc.

74{
75 KisUsageLogger::writeSysInfo("Current Settings\n");
76 KisUsageLogger::writeSysInfo(QString(" Current Swap Location: %1").arg(KisImageConfig(true).swapDir()));
77 KisUsageLogger::writeSysInfo(QString(" Current Swap Location writable: %1").arg(QFileInfo(KisImageConfig(true).swapDir()).isWritable() ? "true" : "false"));
78 KisUsageLogger::writeSysInfo(QString(" Undo Enabled: %1").arg(undoEnabled()? "true" : "false"));
79 KisUsageLogger::writeSysInfo(QString(" Undo Stack Limit: %1").arg(undoStackLimit()));
80 KisUsageLogger::writeSysInfo(QString(" Use OpenGL: %1").arg(useOpenGL() ? "true" : "false"));
81 KisUsageLogger::writeSysInfo(QString(" Use OpenGL Texture Buffer: %1").arg(useOpenGLTextureBuffer() ? "true" : "false"));
82 KisUsageLogger::writeSysInfo(QString(" Disable Vector Optimizations: %1").arg(disableVectorOptimizations() ? "true" : "false"));
83 KisUsageLogger::writeSysInfo(QString(" Disable AVX Optimizations: %1").arg(disableAVXOptimizations() ? "true" : "false"));
84 KisUsageLogger::writeSysInfo(QString(" Canvas State: %1").arg(canvasState()));
85 KisUsageLogger::writeSysInfo(QString(" Autosave Interval: %1").arg(autoSaveInterval()));
86 KisUsageLogger::writeSysInfo(QString(" Use Backup Files: %1").arg(backupFile() ? "true" : "false"));
87 KisUsageLogger::writeSysInfo(QString(" Number of Backups Kept: %1").arg(m_cfg.readEntry("numberofbackupfiles", 1)));
88 KisUsageLogger::writeSysInfo(QString(" Backup File Suffix: %1").arg(m_cfg.readEntry("backupfilesuffix", "~")));
89
90 QString backupDir;
91 switch(m_cfg.readEntry("backupfilelocation", 0)) {
92 case 1:
93 backupDir = QStandardPaths::writableLocation(QStandardPaths::HomeLocation);
94 break;
95 case 2:
96 backupDir = QStandardPaths::writableLocation(QStandardPaths::TempLocation);
97 break;
98 default:
99 // Do nothing: the empty string is user file location
100 backupDir = "Same Folder as the File";
101 }
102 KisUsageLogger::writeSysInfo(QString(" Backup Location: %1").arg(backupDir));
103 KisUsageLogger::writeSysInfo(QString(" Backup Location writable: %1").arg(QFileInfo(backupDir).isWritable() ? "true" : "false"));
104 KisUsageLogger::writeSysInfo(QString(" Resource Location: %1").arg(m_cfg.readEntry(KisResourceLocator::resourceLocationKey)));
105
106 KisUsageLogger::writeSysInfo(QString(" Use Win8 Pointer Input: %1").arg(useWin8PointerInput() ? "true" : "false"));
107 KisUsageLogger::writeSysInfo(QString(" Use RightMiddleTabletButton Workaround: %1").arg(useRightMiddleTabletButtonWorkaround() ? "true" : "false"));
108 KisUsageLogger::writeSysInfo(QString(" Levels of Detail Enabled: %1").arg(levelOfDetailEnabled() ? "true" : "false"));
109 KisUsageLogger::writeSysInfo(QString(" Use Zip64: %1").arg(useZip64() ? "true" : "false"));
110
112
113 // Tablet API information
114#if defined Q_OS_WIN && QT_VERSION > QT_VERSION_CHECK(6, 0, 0)
115{
116 auto tabletAPIName = [] (bool useWinTab) {
117 return useWinTab ? "WinTab" : "WinInk";
118 };
119
120 QString actualTabletProtocol = "<unknown>";
121
122 using QWindowsApplication = QNativeInterface::Private::QWindowsApplication;
123 if (auto nativeWindowsApp = dynamic_cast<QWindowsApplication *>(QGuiApplicationPrivate::platformIntegration())) {
124 actualTabletProtocol = tabletAPIName(nativeWindowsApp->isWinTabEnabled());
125 } else {
126 KisUsageLogger::log("WARNING: Failed to fetch WinTab protocol status: QWindowsApplication is not available");
127 }
128
129 KisUsageLogger::writeSysInfo("Tablet API Information\n");
130 KisUsageLogger::writeSysInfo(QString(" User-selected tablet API: %1").arg(tabletAPIName(!useWin8PointerInput())));
131 KisUsageLogger::writeSysInfo(QString(" Actually used tablet API: %1").arg(actualTabletProtocol));
133}
134#endif
135
136}
bool backupFile(bool defaultValue=false) const
bool disableVectorOptimizations(bool defaultValue=false) const
bool levelOfDetailEnabled(bool defaultValue=false) const
bool useZip64(bool defaultValue=false) const
bool useWin8PointerInput(bool defaultValue=false) const
bool useOpenGLTextureBuffer(bool defaultValue=false) const
bool useRightMiddleTabletButtonWorkaround(bool defaultValue=false) const
int autoSaveInterval(bool defaultValue=false) const
QString canvasState(bool defaultValue=false) const
bool useOpenGL(bool defaultValue=false) const
int undoStackLimit(bool defaultValue=false) const
bool disableAVXOptimizations(bool defaultValue=false) const
bool undoEnabled(bool defaultValue=false) const
static const QString resourceLocationKey
static void log(const QString &message)
Logs with date/time.
static void writeSysInfo(const QString &message)
Writes to the system information file and Krita log.

References autoSaveInterval(), backupFile(), canvasState(), disableAVXOptimizations(), disableVectorOptimizations(), levelOfDetailEnabled(), KisUsageLogger::log(), m_cfg, KisResourceLocator::resourceLocationKey, undoEnabled(), undoStackLimit(), useOpenGL(), useOpenGLTextureBuffer(), useRightMiddleTabletButtonWorkaround(), useWin8PointerInput(), useZip64(), and KisUsageLogger::writeSysInfo().

◆ longPressEnabled()

bool KisConfig::longPressEnabled ( bool defaultValue = false) const

Definition at line 2775 of file kis_config.cc.

2776{
2777#ifdef Q_OS_ANDROID
2778 bool defaultEnabled = true;
2779#else
2780 bool defaultEnabled = false;
2781#endif
2782 if (defaultValue) {
2783 return defaultEnabled;
2784 } else {
2785 return m_cfg.readEntry("longPressEnabled", defaultEnabled);
2786 }
2787}

References m_cfg.

◆ monitorForScreen()

QString KisConfig::monitorForScreen ( int screen,
const QString & defaultMonitor,
bool defaultValue = true ) const

Definition at line 738 of file kis_config.cc.

739{
740 return (defaultValue ? defaultMonitor
741 : m_cfg.readEntry(QString("monitor_for_screen_%1").arg(screen), defaultMonitor));
742}

References m_cfg.

◆ monitorProfile()

QString KisConfig::monitorProfile ( int screen) const

get the profile the user has selected for the given screen

Screen identifier may be empty (e.g. on macOS), so the identifier key will be plain 'monitorProfile', which is the key for the first display's profile, so we shouldn't fall into this trap...

Definition at line 714 of file kis_config.cc.

715{
716 // Note: keep this in sync with the default profile for the RGB colorspaces!
717 const QString defaultProfile = "sRGB-elle-V2-srgbtrc.icc";
718
719 QString profile;
720 const QString screenIdentifier = getScreenStringIdentfier(screen);
721 const QString screenIdentifierKey = "monitorProfile" + screenIdentifier;
722
728 if (!screenIdentifier.isEmpty() && m_cfg.hasKey(screenIdentifierKey)) {
729 profile = m_cfg.readEntry(screenIdentifierKey, defaultProfile);
730 } else {
731 profile = m_cfg.readEntry("monitorProfile" + QString(screen == 0 ? "": QString("_%1").arg(screen)), defaultProfile);
732 }
733
734 //dbgKrita << "KisConfig::monitorProfile()" << profile;
735 return profile;
736}
const QString getScreenStringIdentfier(int screenNo) const

References getScreenStringIdentfier(), and m_cfg.

◆ monitorRenderIntent()

qint32 KisConfig::monitorRenderIntent ( bool defaultValue = false) const

Definition at line 979 of file kis_config.cc.

980{
981 qint32 intent = m_cfg.readEntry("renderIntent", INTENT_PERCEPTUAL);
982 if (intent > 3) intent = 3;
983 if (intent < 0) intent = 0;
984 return (defaultValue ? INTENT_PERCEPTUAL : intent);
985}
#define INTENT_PERCEPTUAL
Definition kis_global.h:103

References INTENT_PERCEPTUAL, and m_cfg.

◆ newCursorStyle()

CursorStyle KisConfig::newCursorStyle ( bool defaultValue = false) const

Definition at line 320 of file kis_config.cc.

321{
322 if (defaultValue) {
324 }
325
326
327 int style = m_cfg.readEntry("newCursorStyle", int(-1));
328
329 if (style < 0) {
330 // old style format
331 style = m_cfg.readEntry("cursorStyleDef", int(OLD_CURSOR_STYLE_OUTLINE));
332
333 switch (style) {
335 style = CURSOR_STYLE_TOOLICON;
336 break;
340 break;
342 style = CURSOR_STYLE_POINTER;
343 break;
347 break;
351 break;
355 break;
359 break;
360 default:
361 style = -1;
362 }
363 }
364
366
367 // compatibility with future versions
368 if (style < 0 || style >= N_CURSOR_STYLE_SIZE) {
370 }
371
372 return (CursorStyle) style;
373}
void cleanOldCursorStyleKeys(KConfigGroup &cfg)
@ OLD_CURSOR_STYLE_OUTLINE_TRIANGLE_RIGHTHANDED
Definition kis_global.h:93
@ OLD_CURSOR_STYLE_OUTLINE
Definition kis_global.h:82
@ OLD_CURSOR_STYLE_OUTLINE_CENTER_CROSS
Definition kis_global.h:88
@ OLD_CURSOR_STYLE_CROSSHAIR
Definition kis_global.h:79
@ OLD_CURSOR_STYLE_NO_CURSOR
Definition kis_global.h:84
@ OLD_CURSOR_STYLE_TOOLICON
Definition kis_global.h:78
@ OLD_CURSOR_STYLE_TRIANGLE_LEFTHANDED
Definition kis_global.h:91
@ OLD_CURSOR_STYLE_POINTER
Definition kis_global.h:80
@ OLD_CURSOR_STYLE_OUTLINE_CENTER_DOT
Definition kis_global.h:87
@ OLD_CURSOR_STYLE_OUTLINE_TRIANGLE_LEFTHANDED
Definition kis_global.h:94
@ OLD_CURSOR_STYLE_TRIANGLE_RIGHTHANDED
Definition kis_global.h:90
@ OLD_CURSOR_STYLE_SMALL_ROUND
Definition kis_global.h:85
@ CURSOR_STYLE_POINTER
Definition kis_global.h:65
@ CURSOR_STYLE_SMALL_ROUND
Definition kis_global.h:66
@ CURSOR_STYLE_CROSSHAIR
Definition kis_global.h:67
@ CURSOR_STYLE_TOOLICON
Definition kis_global.h:64
@ CURSOR_STYLE_TRIANGLE_RIGHTHANDED
Definition kis_global.h:68
@ CURSOR_STYLE_TRIANGLE_LEFTHANDED
Definition kis_global.h:69
@ CURSOR_STYLE_NO_CURSOR
Definition kis_global.h:63

References cleanOldCursorStyleKeys(), CURSOR_STYLE_CROSSHAIR, CURSOR_STYLE_NO_CURSOR, CURSOR_STYLE_POINTER, CURSOR_STYLE_SMALL_ROUND, CURSOR_STYLE_TOOLICON, CURSOR_STYLE_TRIANGLE_LEFTHANDED, CURSOR_STYLE_TRIANGLE_RIGHTHANDED, m_cfg, N_CURSOR_STYLE_SIZE, OLD_CURSOR_STYLE_CROSSHAIR, OLD_CURSOR_STYLE_NO_CURSOR, OLD_CURSOR_STYLE_OUTLINE, OLD_CURSOR_STYLE_OUTLINE_CENTER_CROSS, OLD_CURSOR_STYLE_OUTLINE_CENTER_DOT, OLD_CURSOR_STYLE_OUTLINE_TRIANGLE_LEFTHANDED, OLD_CURSOR_STYLE_OUTLINE_TRIANGLE_RIGHTHANDED, OLD_CURSOR_STYLE_POINTER, OLD_CURSOR_STYLE_SMALL_ROUND, OLD_CURSOR_STYLE_TOOLICON, OLD_CURSOR_STYLE_TRIANGLE_LEFTHANDED, and OLD_CURSOR_STYLE_TRIANGLE_RIGHTHANDED.

◆ newOutlineStyle()

OutlineStyle KisConfig::newOutlineStyle ( bool defaultValue = false) const

Definition at line 392 of file kis_config.cc.

393{
394 if (defaultValue) {
395 return OUTLINE_FULL;
396 }
397
398 int style = m_cfg.readEntry("newOutlineStyle", int(-1));
399
400 if (style < 0) {
401 // old style format
402 style = m_cfg.readEntry("cursorStyleDef", int(OLD_CURSOR_STYLE_OUTLINE));
403
404 switch (style) {
412 style = OUTLINE_NONE;
413 break;
419 style = OUTLINE_FULL;
420 break;
421 default:
422 style = -1;
423 }
424 }
425
427
428 // compatibility with future versions
429 if (style < 0 || style >= N_OUTLINE_STYLE_SIZE) {
430 style = OUTLINE_FULL;
431 }
432
433 return (OutlineStyle) style;
434}

References cleanOldCursorStyleKeys(), m_cfg, N_OUTLINE_STYLE_SIZE, OLD_CURSOR_STYLE_CROSSHAIR, OLD_CURSOR_STYLE_NO_CURSOR, OLD_CURSOR_STYLE_OUTLINE, OLD_CURSOR_STYLE_OUTLINE_CENTER_CROSS, OLD_CURSOR_STYLE_OUTLINE_CENTER_DOT, OLD_CURSOR_STYLE_OUTLINE_TRIANGLE_LEFTHANDED, OLD_CURSOR_STYLE_OUTLINE_TRIANGLE_RIGHTHANDED, OLD_CURSOR_STYLE_POINTER, OLD_CURSOR_STYLE_SMALL_ROUND, OLD_CURSOR_STYLE_TOOLICON, OLD_CURSOR_STYLE_TRIANGLE_LEFTHANDED, OLD_CURSOR_STYLE_TRIANGLE_RIGHTHANDED, OUTLINE_FULL, and OUTLINE_NONE.

◆ numDefaultLayers()

int KisConfig::numDefaultLayers ( bool defaultValue = false) const

Definition at line 1998 of file kis_config.cc.

1999{
2000 return (defaultValue ? 2 : m_cfg.readEntry("NumberOfLayersForNewImage", 2));
2001}

References m_cfg.

◆ numMipmapLevels()

int KisConfig::numMipmapLevels ( bool defaultValue = false) const

Definition at line 1054 of file kis_config.cc.

1055{
1056 return (defaultValue ? 4 : m_cfg.readEntry("numMipmapLevels", 4));
1057}

References m_cfg.

◆ ocioColorManagementMode()

KisConfig::OcioColorManagementMode KisConfig::ocioColorManagementMode ( bool defaultValue = false) const

Definition at line 1848 of file kis_config.cc.

1849{
1850 // FIXME: this option duplicates ocioConfiguration(), please deprecate it
1851 return (OcioColorManagementMode)(defaultValue ? INTERNAL
1852 : m_cfg.readEntry("Krita/Ocio/OcioColorManagementMode", (int) INTERNAL));
1853}
OcioColorManagementMode
Definition kis_config.h:471

References INTERNAL, and m_cfg.

◆ ocioConfiguration()

KisOcioConfiguration KisConfig::ocioConfiguration ( bool defaultValue = false) const

Definition at line 1819 of file kis_config.cc.

1820{
1822
1823 if (!defaultValue) {
1824 cfg.mode = (KisOcioConfiguration::Mode)m_cfg.readEntry("Krita/Ocio/OcioColorManagementMode", 0);
1825 cfg.configurationPath = m_cfg.readEntry("Krita/Ocio/OcioConfigPath", QString());
1826 cfg.lutPath = m_cfg.readEntry("Krita/Ocio/OcioLutPath", QString());
1827 cfg.inputColorSpace = m_cfg.readEntry("Krita/Ocio/InputColorSpace", QString());
1828 cfg.displayDevice = m_cfg.readEntry("Krita/Ocio/DisplayDevice", QString());
1829 cfg.displayView = m_cfg.readEntry("Krita/Ocio/DisplayView", QString());
1830 cfg.look = m_cfg.readEntry("Krita/Ocio/DisplayLook", QString());
1831 }
1832
1833 return cfg;
1834}

References KisOcioConfiguration::configurationPath, KisOcioConfiguration::displayDevice, KisOcioConfiguration::displayView, KisOcioConfiguration::inputColorSpace, KisOcioConfiguration::look, KisOcioConfiguration::lutPath, m_cfg, and KisOcioConfiguration::mode.

◆ ocioLockColorVisualRepresentation()

bool KisConfig::ocioLockColorVisualRepresentation ( bool defaultValue = false) const

Definition at line 1871 of file kis_config.cc.

1872{
1873 return (defaultValue ? false : m_cfg.readEntry("Krita/Ocio/OcioLockColorVisualRepresentation", false));
1874}

References m_cfg.

◆ ocioLutEdgeSize()

int KisConfig::ocioLutEdgeSize ( bool defaultValue = false) const

Definition at line 1861 of file kis_config.cc.

1862{
1863 return (defaultValue ? 64 : m_cfg.readEntry("Krita/Ocio/LutEdgeSize", 64));
1864}

References m_cfg.

◆ openGLFilteringMode()

int KisConfig::openGLFilteringMode ( bool defaultValue = false) const

Definition at line 1014 of file kis_config.cc.

1015{
1016 return (defaultValue ? 3 : m_cfg.readEntry("OpenGLFilterMode", 3));
1017}

References m_cfg.

◆ openGLTextureSize()

int KisConfig::openGLTextureSize ( bool defaultValue = false) const

Definition at line 1044 of file kis_config.cc.

1045{
1046 return (defaultValue ? 256 : m_cfg.readEntry("textureSize", 256));
1047}

References m_cfg.

◆ operator=()

KisConfig & KisConfig::operator= ( const KisConfig & ) const
private

◆ outlineSizeMinimum()

qreal KisConfig::outlineSizeMinimum ( bool defaultValue = false) const

Definition at line 1410 of file kis_config.cc.

1411{
1412 return (defaultValue ? 1.0 : m_cfg.readEntry("OutlineSizeMinimum", 1.0));
1413}

References m_cfg.

◆ paintopPopupDetached()

bool KisConfig::paintopPopupDetached ( bool defaultValue = false) const

Definition at line 1502 of file kis_config.cc.

1503{
1504 return (defaultValue ? true : m_cfg.readEntry("PaintopPopupDetached", true));
1505}

References m_cfg.

◆ pasteBehaviour()

qint32 KisConfig::pasteBehaviour ( bool defaultValue = false) const

Definition at line 959 of file kis_config.cc.

960{
961 return (defaultValue ? 2 : m_cfg.readEntry("pasteBehaviour", 2));
962}

References m_cfg.

◆ pasteFormat()

qint32 KisConfig::pasteFormat ( bool defaultValue) const

Definition at line 969 of file kis_config.cc.

970{
971 return defaultValue ? 0 : m_cfg.readEntry("pasteFormat", 0);
972}

References m_cfg.

◆ pixelGridEnabled()

bool KisConfig::pixelGridEnabled ( bool defaultValue = false) const

Definition at line 1155 of file kis_config.cc.

1156{
1157 bool enabled = true;
1158 return (defaultValue ? enabled : m_cfg.readEntry("pixelGridEnabled", enabled));
1159}

References m_cfg.

◆ preferredVectorImportResolutionPPI()

int KisConfig::preferredVectorImportResolutionPPI ( bool defaultValue = false) const

Definition at line 289 of file kis_config.cc.

290{
291 return defaultValue ? 100.0 : m_cfg.readEntry("preferredVectorImportResolution", 100.0);
292}

References m_cfg.

◆ presetChooserViewMode()

int KisConfig::presetChooserViewMode ( bool defaultValue = false) const

Definition at line 1582 of file kis_config.cc.

1583{
1584 return (defaultValue ? 0 : m_cfg.readEntry("presetChooserViewMode", 0));
1585}

References m_cfg.

◆ presetIconSize()

int KisConfig::presetIconSize ( bool defaultValue = false) const

Definition at line 1592 of file kis_config.cc.

1593{
1594 return (defaultValue ? 60 : m_cfg.readEntry("presetIconSize", 60));
1595}

References m_cfg.

◆ presetStripVisible()

bool KisConfig::presetStripVisible ( bool defaultValue = false) const

Definition at line 1958 of file kis_config.cc.

1959{
1960 return (defaultValue ? true : m_cfg.readEntry("presetStripVisible", true));
1961}

References m_cfg.

◆ pressureTabletCurve()

QString KisConfig::pressureTabletCurve ( bool defaultValue = false) const

Definition at line 1512 of file kis_config.cc.

1513{
1514 return (defaultValue ? "0,0;1,1" : m_cfg.readEntry("tabletPressureCurve","0,0;1,1;"));
1515}

References m_cfg.

◆ printerColorSpace()

QString KisConfig::printerColorSpace ( bool defaultValue = false) const

Definition at line 859 of file kis_config.cc.

860{
861 //TODO currently only rgb8 is supported
862 //return (defaultValue ? "RGBA" : m_cfg.readEntry("printerColorSpace", "RGBA"));
863 return QString("RGBA");
864}

◆ printerProfile()

QString KisConfig::printerProfile ( bool defaultValue = false) const

Definition at line 872 of file kis_config.cc.

873{
874 return (defaultValue ? "" : m_cfg.readEntry("printerProfile", ""));
875}

References m_cfg.

◆ readEntry()

template<class T >
T KisConfig::readEntry ( const QString & name,
const T & defaultValue = T() )
inline

Definition at line 789 of file kis_config.h.

789 {
790 return m_cfg.readEntry(name, defaultValue);
791 }

◆ readKoColor()

KoColor KisConfig::readKoColor ( const QString & name,
const KoColor & color = KoColor() ) const

Definition at line 2808 of file kis_config.cc.

2809{
2810 QDomDocument doc;
2811
2812 KoColor color = _color;
2813
2814 if (!m_cfg.readEntry(name).isNull()) {
2815 doc.setContent(m_cfg.readEntry(name));
2816 QDomElement e = doc.documentElement().firstChild().toElement();
2818 }
2819 else {
2820 QString blackColor = "<!DOCTYPE Color>\n<Color>\n <RGB r=\"0\" space=\"sRGB-elle-V2-srgbtrc.icc\" b=\"0\" g=\"0\"/>\n</Color>\n";
2821 doc.setContent(blackColor);
2822 QDomElement e = doc.documentElement().firstChild().toElement();
2824 }
2825 return color;
2826}
const KoID Integer16BitsColorDepthID("U16", ki18n("16-bit integer/channel"))
static KoColor fromXML(const QDomElement &elt, const QString &channelDepthId)
Definition KoColor.cpp:350

References KoColor::fromXML(), KoID::id(), Integer16BitsColorDepthID, and m_cfg.

◆ readKoColors()

QList< KoColor > KisConfig::readKoColors ( const QString & name) const

Definition at line 2841 of file kis_config.cc.

2842{
2843 QList<KoColor> colors;
2844 QString colorListXML = m_cfg.readEntry(name);
2845
2846 if (!colorListXML.isNull()) {
2847 QDomDocument doc;
2848 doc.setContent(colorListXML);
2849 QDomElement colorsElement = doc.firstChildElement();
2850 if (!colorsElement.isNull()) {
2851 QDomNodeList colorNodes = colorsElement.childNodes();
2852 colors.reserve(colorNodes.size());
2853
2854 for (int k = 0; k < colorNodes.size(); k++) {
2855 QDomElement colorElement = colorNodes.at(k).toElement();
2856 KoColor color = KoColor::fromXML(colorElement, Integer16BitsColorDepthID.id());
2857 colors.push_back(color);
2858 }
2859 }
2860 }
2861
2862 return colors;
2863}

References KoColor::fromXML(), KoID::id(), Integer16BitsColorDepthID, and m_cfg.

◆ readList()

template<class T >
QList< T > KisConfig::readList ( const QString & name,
const QList< T > & defaultValue = QList<T>() )
inline

Definition at line 794 of file kis_config.h.

794 {
795 return m_cfg.readEntry(name, defaultValue);
796 }

◆ renamePastedLayers()

bool KisConfig::renamePastedLayers ( bool defaultValue = false) const

Definition at line 2710 of file kis_config.cc.

2711{
2712 return defaultValue ? true : m_cfg.readEntry("renamePastedLayers", true);
2713}

References m_cfg.

◆ rootSurfaceFormat() [1/2]

KisConfig::RootSurfaceFormat KisConfig::rootSurfaceFormat ( bool defaultValue = false) const

Definition at line 2651 of file kis_config.cc.

2652{
2653 const QString configPath = QStandardPaths::writableLocation(QStandardPaths::GenericConfigLocation);
2654 QSettings kritarc(configPath + QStringLiteral("/kritadisplayrc"), QSettings::IniFormat);
2655
2656 return rootSurfaceFormat(&kritarc, defaultValue);
2657}
RootSurfaceFormat rootSurfaceFormat(bool defaultValue=false) const

References rootSurfaceFormat().

◆ rootSurfaceFormat() [2/2]

KisConfig::RootSurfaceFormat KisConfig::rootSurfaceFormat ( QSettings * displayrc,
bool defaultValue = false )
static

Definition at line 2667 of file kis_config.cc.

2668{
2669 QString textValue = "bt709-g22";
2670
2671 if (!defaultValue) {
2672 textValue = displayrc->value("rootSurfaceFormat", textValue).toString();
2673 }
2674
2675 return textValue == "bt709-g10" ? BT709_G10 :
2676 textValue == "bt2020-pq" ? BT2020_PQ :
2677 BT709_G22;
2678}

References BT2020_PQ, BT709_G10, and BT709_G22.

◆ rulersTrackMouse()

bool KisConfig::rulersTrackMouse ( bool defaultValue = false) const

Definition at line 949 of file kis_config.cc.

950{
951 return (defaultValue ? true : m_cfg.readEntry("rulersTrackMouse", true));
952}

References m_cfg.

◆ saveSessionOnQuit()

bool KisConfig::saveSessionOnQuit ( bool defaultValue) const

Definition at line 1391 of file kis_config.cc.

1392{
1393 return defaultValue ? false : m_cfg.readEntry("saveSessionOnQuit", false);
1394}

References m_cfg.

◆ saveSnapConfig()

void KisConfig::saveSnapConfig ( const KisSnapConfig & config)

Definition at line 1208 of file kis_config.cc.

1209{
1210 m_cfg.writeEntry("globalSnapOrthogonal", config.orthogonal());
1211 m_cfg.writeEntry("globalSnapNode", config.node());
1212 m_cfg.writeEntry("globalSnapExtension", config.extension());
1213 m_cfg.writeEntry("globalSnapIntersection", config.intersection());
1214 m_cfg.writeEntry("globalSnapBoundingBox", config.boundingBox());
1215 m_cfg.writeEntry("globalSnapImageBounds", config.imageBounds());
1216 m_cfg.writeEntry("globalSnapImageCenter", config.imageCenter());
1217 m_cfg.writeEntry("globalSnapToPixel", config.toPixel());
1218}
bool orthogonal() const
bool node() const
bool toPixel() const
bool imageBounds() const
bool boundingBox() const
bool intersection() const
bool extension() const
bool imageCenter() const

References KisSnapConfig::boundingBox(), KisSnapConfig::extension(), KisSnapConfig::imageBounds(), KisSnapConfig::imageCenter(), KisSnapConfig::intersection(), m_cfg, KisSnapConfig::node(), KisSnapConfig::orthogonal(), and KisSnapConfig::toPixel().

◆ scratchpadVisible()

bool KisConfig::scratchpadVisible ( bool defaultValue = false) const

Definition at line 1968 of file kis_config.cc.

1969{
1970 return (defaultValue ? true : m_cfg.readEntry("scratchpadVisible", true));
1971}

References m_cfg.

◆ scrollbarZoomEnabled()

bool KisConfig::scrollbarZoomEnabled ( bool defaultValue = false) const

Definition at line 1266 of file kis_config.cc.

1267{
1268 return (defaultValue ? true : m_cfg.readEntry("scrollbarZoomEnabled", true));
1269}

References m_cfg.

◆ scrollCheckers()

bool KisConfig::scrollCheckers ( bool defaultValue = false) const

Definition at line 1235 of file kis_config.cc.

1236{
1237 return (defaultValue ? false : m_cfg.readEntry("scrollingcheckers", false));
1238}

References m_cfg.

◆ scrubbingAudioUpdatesDelay()

int KisConfig::scrubbingAudioUpdatesDelay ( bool defaultValue = false) const

Definition at line 2489 of file kis_config.cc.

2490{
2491 return (defaultValue ? -1 : m_cfg.readEntry("scrubbingAudioUpdatesDelay", -1));
2492}

References m_cfg.

◆ scrubbingUpdatesDelay()

int KisConfig::scrubbingUpdatesDelay ( bool defaultValue = false) const

Definition at line 2479 of file kis_config.cc.

2480{
2481 return (defaultValue ? 30 : m_cfg.readEntry("scrubbingUpdatesDelay", 30));
2482}

References m_cfg.

◆ selectionActionBar()

bool KisConfig::selectionActionBar ( bool defaultValue = false) const

Definition at line 2641 of file kis_config.cc.

2642{
2643 return defaultValue ? true : m_cfg.readEntry("selectionActionBar", true);
2644}

References m_cfg.

◆ selectionViewSizeMinimum()

qreal KisConfig::selectionViewSizeMinimum ( bool defaultValue = false) const

Definition at line 1420 of file kis_config.cc.

1421{
1422 return (defaultValue ? 5.0 : m_cfg.readEntry("SelectionViewSizeMinimum", 5.0));
1423}

References m_cfg.

◆ separateEraserCursor()

bool KisConfig::separateEraserCursor ( bool defaultValue = false) const

Definition at line 459 of file kis_config.cc.

460{
461 return (defaultValue ? false : m_cfg.readEntry("separateEraserCursor", false));
462}

References m_cfg.

◆ sessionOnStartup()

KisConfig::SessionOnStartup KisConfig::sessionOnStartup ( bool defaultValue = false) const

Definition at line 1381 of file kis_config.cc.

1382{
1383 int value = defaultValue ? SOS_BlankSession : m_cfg.readEntry("sessionOnStartup", (int)SOS_BlankSession);
1385}

References m_cfg, SOS_BlankSession, and value().

◆ setActivateTransformToolAfterPaste()

void KisConfig::setActivateTransformToolAfterPaste ( bool value)

Definition at line 2626 of file kis_config.cc.

2627{
2628 m_cfg.writeEntry("activateTransformToolAfterPaste", value);
2629}

References m_cfg, and value().

◆ setAdaptivePlaybackRange()

void KisConfig::setAdaptivePlaybackRange ( bool value)

Definition at line 2441 of file kis_config.cc.

2442{
2443 m_cfg.writeEntry("adaptivePlaybackRange", value);
2444}

References m_cfg, and value().

◆ setAllowLCMSOptimization()

void KisConfig::setAllowLCMSOptimization ( bool allowLCMSOptimization)

Definition at line 898 of file kis_config.cc.

899{
900 m_cfg.writeEntry("allowLCMSOptimization", allowLCMSOptimization);
901}
bool allowLCMSOptimization(bool defaultValue=false) const

References allowLCMSOptimization(), and m_cfg.

◆ setAnimationDropFrames()

void KisConfig::setAnimationDropFrames ( bool value)

Definition at line 2416 of file kis_config.cc.

2417{
2418 bool oldValue = animationDropFrames();
2419
2420 if (value == oldValue) return;
2421
2422 m_cfg.writeEntry("animationDropFrames", value);
2424}
static KisConfigNotifier * instance()
bool animationDropFrames(bool defaultValue=false) const

References animationDropFrames(), KisConfigNotifier::instance(), m_cfg, KisConfigNotifier::notifyDropFramesModeChanged(), and value().

◆ setAnimationPlaybackBackend()

void KisConfig::setAnimationPlaybackBackend ( int value)

Definition at line 2406 of file kis_config.cc.

2407{
2408 m_cfg.writeEntry("animationPlaybackBackend", value);
2409}

References m_cfg, and value().

◆ setAntialiasCurves()

void KisConfig::setAntialiasCurves ( bool v) const

Definition at line 1302 of file kis_config.cc.

1303{
1304 m_cfg.writeEntry("antialiascurves", v);
1305}

References m_cfg, and v.

◆ setAntialiasSelectionOutline()

void KisConfig::setAntialiasSelectionOutline ( bool v) const

Definition at line 1312 of file kis_config.cc.

1313{
1314 m_cfg.writeEntry("AntialiasSelectionOutline", v);
1315}

References m_cfg, and v.

◆ setAssistantsDrawMode()

void KisConfig::setAssistantsDrawMode ( AssistantsDrawMode value)

Definition at line 2770 of file kis_config.cc.

2771{
2772 m_cfg.writeEntry("assistantsDrawMode", static_cast<int>(value));
2773}

References m_cfg, and value().

◆ setAudioOffsetTolerance()

void KisConfig::setAudioOffsetTolerance ( int value)

Definition at line 2504 of file kis_config.cc.

2505{
2506 m_cfg.writeEntry("audioOffsetTolerance", value);
2507}

References m_cfg, and value().

◆ setAutoPinLayersToTimeline()

void KisConfig::setAutoPinLayersToTimeline ( bool value)

Definition at line 2431 of file kis_config.cc.

2432{
2433 m_cfg.writeEntry("autoPinLayers", value);
2434}

References m_cfg, and value().

◆ setAutoSaveInterval()

void KisConfig::setAutoSaveInterval ( int seconds) const

Definition at line 1436 of file kis_config.cc.

1437{
1438 return m_cfg.writeEntry("AutoSaveInterval", seconds);
1439}

References m_cfg.

◆ setAutoSmoothBezierCurves()

void KisConfig::setAutoSmoothBezierCurves ( bool value)

Definition at line 2616 of file kis_config.cc.

2617{
2618 m_cfg.writeEntry("autoSmoothBezierCurves", value);
2619}

References m_cfg, and value().

◆ setAutoZoomTimelineToPlaybackRange()

void KisConfig::setAutoZoomTimelineToPlaybackRange ( bool value)

Definition at line 2451 of file kis_config.cc.

2452{
2453 m_cfg.writeEntry("autoZoomTimelineToPlaybackRange", value);
2454}

References m_cfg, and value().

◆ setBackupFile()

void KisConfig::setBackupFile ( bool backupFile) const

Definition at line 1446 of file kis_config.cc.

1447{
1448 m_cfg.writeEntry("CreateBackupFile", backupFile);
1449}

References backupFile(), and m_cfg.

◆ setBrushHudSetting()

void KisConfig::setBrushHudSetting ( const QString & value) const

Definition at line 2585 of file kis_config.cc.

2586{
2587 m_cfg.writeEntry("brushHudSettings", value);
2588}

References m_cfg, and value().

◆ setCalculateAnimationCacheInBackground()

void KisConfig::setCalculateAnimationCacheInBackground ( bool value)

Definition at line 2595 of file kis_config.cc.

2596{
2597 m_cfg.writeEntry("calculateAnimationCacheInBackground", value);
2598}

References m_cfg, and value().

◆ setCanvasBorderColor()

void KisConfig::setCanvasBorderColor ( const QColor & color) const

Definition at line 1251 of file kis_config.cc.

1252{
1253 m_cfg.writeEntry("canvasBorderColor", color);
1254}

References m_cfg.

◆ setCanvasState()

void KisConfig::setCanvasState ( const QString & state) const

Definition at line 1478 of file kis_config.cc.

1479{
1480 static QStringList acceptableStates;
1481 if (acceptableStates.isEmpty()) {
1482 acceptableStates << "OPENGL_SUCCESS" << "TRY_OPENGL" << "OPENGL_NOT_TRIED" << "OPENGL_FAILED";
1483 }
1484 if (acceptableStates.contains(state)) {
1485 const QString configPath = QStandardPaths::writableLocation(QStandardPaths::GenericConfigLocation);
1486 QSettings kritarc(configPath + QStringLiteral("/kritadisplayrc"), QSettings::IniFormat);
1487 kritarc.setValue("canvasState", state);
1488 }
1489}

◆ setCanvasSurfaceBitDepthMode() [1/2]

void KisConfig::setCanvasSurfaceBitDepthMode ( CanvasSurfaceBitDepthMode value)

Definition at line 688 of file kis_config.cc.

689{
690 const QString configPath = QStandardPaths::writableLocation(QStandardPaths::GenericConfigLocation);
691 QSettings kritarc(configPath + QStringLiteral("/kritadisplayrc"), QSettings::IniFormat);
693}
static void setCanvasSurfaceBitDepthMode(QSettings *settings, CanvasSurfaceBitDepthMode value)

References setCanvasSurfaceBitDepthMode(), and value().

◆ setCanvasSurfaceBitDepthMode() [2/2]

void KisConfig::setCanvasSurfaceBitDepthMode ( QSettings * settings,
CanvasSurfaceBitDepthMode value )
static

Definition at line 662 of file kis_config.cc.

663{
664 QString modeStr;
665
666 switch (value) {
668 modeStr = "auto";
669 break;
671 modeStr = "8bit";
672 break;
674 modeStr = "10bit";
675 break;
676 }
677
678 settings->setValue("canvasSurfaceBitDepthMode", modeStr);
679}

References Depth10Bit, Depth8Bit, DepthAuto, and value().

◆ setCanvasSurfaceColorSpaceManagementMode()

void KisConfig::setCanvasSurfaceColorSpaceManagementMode ( KisConfig::CanvasSurfaceMode value)

Definition at line 625 of file kis_config.cc.

625 {
626 QString modeStr;
627
628 switch (value) {
630 modeStr = "preferred";
631 break;
633 modeStr = "rec709g22";
634 break;
636 modeStr = "rec709g10";
637 break;
639 modeStr = "unmanaged";
640 break;
641 }
642
643 m_cfg.writeEntry("canvasSurfaceColorSpaceManagementMode", modeStr);
644}

References m_cfg, Preferred, Rec709g10, Rec709g22, Unmanaged, and value().

◆ setCheckersColor1()

void KisConfig::setCheckersColor1 ( const QColor & v) const

Definition at line 1282 of file kis_config.cc.

1283{
1284 m_cfg.writeEntry("checkerscolor", v);
1285}

References m_cfg, and v.

◆ setCheckersColor2()

void KisConfig::setCheckersColor2 ( const QColor & v) const

Definition at line 1292 of file kis_config.cc.

1293{
1294 m_cfg.writeEntry("checkerscolor2", v);
1295}

References m_cfg, and v.

◆ setCheckSize()

void KisConfig::setCheckSize ( qint32 checkSize) const

Definition at line 1227 of file kis_config.cc.

1228{
1229 if (checksize == 0) {
1230 checksize = 32;
1231 }
1232 m_cfg.writeEntry("checksize", checksize);
1233}

References m_cfg.

◆ setClicklessSpacePan()

void KisConfig::setClicklessSpacePan ( const bool toggle) const

Definition at line 1636 of file kis_config.cc.

1637{
1638 m_cfg.writeEntry("clicklessSpacePan", toggle);
1639}

References m_cfg.

◆ setColorPreviewRect()

void KisConfig::setColorPreviewRect ( const QRect & rect)

Definition at line 528 of file kis_config.cc.

529{
530 m_cfg.writeEntry("colorPreviewRect", QVariant(rect));
531}

References m_cfg.

◆ setCompressKra()

void KisConfig::setCompressKra ( bool compress)

Definition at line 2223 of file kis_config.cc.

2224{
2225 m_cfg.writeEntry("compressLayersInKra", compress);
2226}

References m_cfg.

◆ setConvertLayerColorSpaceInProperties()

void KisConfig::setConvertLayerColorSpaceInProperties ( bool value)

Definition at line 2705 of file kis_config.cc.

2706{
2707 m_cfg.writeEntry("convertLayerColorSpaceInProperties", value);
2708}

References m_cfg, and value().

◆ setConvertToImageColorspaceOnImport()

void KisConfig::setConvertToImageColorspaceOnImport ( bool value)

Definition at line 2524 of file kis_config.cc.

2525{
2526 m_cfg.writeEntry("ConvertToImageColorSpaceOnImport", value);
2527}

References m_cfg, and value().

◆ setCumulativeUndoData()

void KisConfig::setCumulativeUndoData ( KisCumulativeUndoData value)

Definition at line 220 of file kis_config.cc.

221{
222 value.write(&m_cfg);
223}

References m_cfg, value(), and KisCumulativeUndoData::write().

◆ setCumulativeUndoRedo()

void KisConfig::setCumulativeUndoRedo ( bool value)

Definition at line 204 of file kis_config.cc.

205{
206 m_cfg.writeEntry("useCumulativeUndoRedo", value);
207}

References m_cfg, and value().

◆ setCurrentInputProfile()

void KisConfig::setCurrentInputProfile ( const QString & name)

Definition at line 1943 of file kis_config.cc.

1944{
1945 m_cfg.writeEntry("currentInputProfile", name);
1946}

References m_cfg.

◆ setCursorMainColor()

void KisConfig::setCursorMainColor ( const QColor & v) const

Definition at line 387 of file kis_config.cc.

388{
389 m_cfg.writeEntry("cursorMaincColor", v);
390}

References m_cfg, and v.

◆ setCustomColorSelectorColorSpace()

void KisConfig::setCustomColorSelectorColorSpace ( const KoColorSpace * cs)

Definition at line 2353 of file kis_config.cc.

2354{
2355 KConfigGroup cfg = KSharedConfig::openConfig()->group("advancedColorSelector");
2356 cfg.writeEntry("useCustomColorSpace", bool(cs));
2357 if(cs) {
2358 cfg.writeEntry("customColorSpaceModel", cs->colorModelId().id());
2359 cfg.writeEntry("customColorSpaceDepthID", cs->colorDepthId().id());
2360 cfg.writeEntry("customColorSpaceProfile", cs->profile()->name());
2361 }
2362}
virtual KoID colorModelId() const =0
virtual KoID colorDepthId() const =0
virtual const KoColorProfile * profile() const =0

References KoColorSpace::colorDepthId(), KoColorSpace::colorModelId(), KoID::id(), KoColorProfile::name, and KoColorSpace::profile().

◆ setDefaultAssistantsColor()

void KisConfig::setDefaultAssistantsColor ( const QColor & color) const

Definition at line 2606 of file kis_config.cc.

2607{
2608 m_cfg.writeEntry("defaultAssistantsColor", color);
2609}

References m_cfg.

◆ setDefaultBackgroundColor()

void KisConfig::setDefaultBackgroundColor ( const QColor & value)

Definition at line 2023 of file kis_config.cc.

2024{
2025 m_cfg.writeEntry("BackgroundColorForNewImage", value);
2026}

References m_cfg, and value().

◆ setDefaultBackgroundOpacity()

void KisConfig::setDefaultBackgroundOpacity ( quint8 value)

Definition at line 2013 of file kis_config.cc.

2014{
2015 m_cfg.writeEntry("BackgroundOpacityForNewImage", (int)value);
2016}

References m_cfg, and value().

◆ setDefaultBackgroundStyle()

void KisConfig::setDefaultBackgroundStyle ( KisConfig::BackgroundStyle value)

Definition at line 2033 of file kis_config.cc.

2034{
2035 m_cfg.writeEntry("BackgroundStyleForNewImage", (int)value);
2036}

References m_cfg, and value().

◆ setDefaultColorDepth()

void KisConfig::setDefaultColorDepth ( const QString & depth) const

set the id of the default color depth used for creating new images.

Definition at line 257 of file kis_config.cc.

258{
259 m_cfg.writeEntry("colorDepthDef", depth);
260}

References m_cfg.

◆ setDefaultGridSpacing()

void KisConfig::setDefaultGridSpacing ( QPoint gridSpacing)

Definition at line 570 of file kis_config.cc.

571{
572 m_cfg.writeEntry("defaultGridSpacing", gridSpacing);
573}

References m_cfg.

◆ setDefaultPalette()

void KisConfig::setDefaultPalette ( const QString & name) const

Definition at line 1886 of file kis_config.cc.

1887{
1888 m_cfg.writeEntry("defaultPalette", name);
1889}

References m_cfg.

◆ setDisableAVXOptimizations()

void KisConfig::setDisableAVXOptimizations ( bool value)

Definition at line 2396 of file kis_config.cc.

2397{
2398 m_cfg.writeEntry("disableAVXOptimizations", value);
2399}

References m_cfg, and value().

◆ setDisableVectorOptimizations()

void KisConfig::setDisableVectorOptimizations ( bool value)

Definition at line 2384 of file kis_config.cc.

2385{
2386 // use the old key name for compatibility
2387 m_cfg.writeEntry("amdDisableVectorWorkaround", value);
2388}

References m_cfg, and value().

◆ setEnableBrushSpeedLogging()

void KisConfig::setEnableBrushSpeedLogging ( bool value) const

Definition at line 2379 of file kis_config.cc.

2380{
2381 m_cfg.writeEntry("enableBrushSpeedLogging", value);
2382}

References m_cfg, and value().

◆ setEnableCanvasSurfaceColorSpaceManagement()

void KisConfig::setEnableCanvasSurfaceColorSpaceManagement ( bool value)

Definition at line 604 of file kis_config.cc.

605{
606 m_cfg.writeEntry("enableCanvasSurfaceColorSpaceManagement", value);
607}

References m_cfg, and value().

◆ setEnableOpenGLFramerateLogging()

void KisConfig::setEnableOpenGLFramerateLogging ( bool value) const

Definition at line 2369 of file kis_config.cc.

2370{
2371 m_cfg.writeEntry("enableOpenGLFramerateLogging", value);
2372}

References m_cfg, and value().

◆ setEraserCursorMainColor()

void KisConfig::setEraserCursorMainColor ( const QColor & v) const

Definition at line 497 of file kis_config.cc.

498{
499 m_cfg.writeEntry("eraserCursorMaincColor", v);
500}

References m_cfg, and v.

◆ setEraserCursorStyle()

void KisConfig::setEraserCursorStyle ( CursorStyle style)

Definition at line 485 of file kis_config.cc.

486{
487 m_cfg.writeEntry("eraserCursorStyle", (int)style);
488}

References m_cfg.

◆ setEraserOutlineStyle()

void KisConfig::setEraserOutlineStyle ( OutlineStyle style)

Definition at line 518 of file kis_config.cc.

519{
520 m_cfg.writeEntry("eraserOutlineStyle", (int)style);
521}

References m_cfg.

◆ setExportConfiguration()

void KisConfig::setExportConfiguration ( const QString & filterId,
KisPropertiesConfigurationSP properties ) const

Definition at line 1767 of file kis_config.cc.

1768{
1769 QString exportConfig = properties->toXML();
1770 m_cfg.writeEntry("ExportConfiguration-" + filterId, exportConfig);
1771}

References m_cfg.

◆ setExportMimeType()

void KisConfig::setExportMimeType ( const QString & defaultExportMimeType)

Definition at line 2252 of file kis_config.cc.

2253{
2254 m_cfg.writeEntry("defaultExportMimeType", defaultExportMimeType);
2255}

References m_cfg.

◆ setFavoriteCompositeOps()

void KisConfig::setFavoriteCompositeOps ( const QStringList & compositeOps) const

Definition at line 1749 of file kis_config.cc.

1750{
1751 m_cfg.writeEntry("favoriteCompositeOps", compositeOps);
1752}

References m_cfg.

◆ setFavoritePresets()

void KisConfig::setFavoritePresets ( const int value)

Definition at line 1804 of file kis_config.cc.

1805{
1806 m_cfg.writeEntry("numFavoritePresets", value);
1807}

References m_cfg, and value().

◆ setFFMpegLocation()

void KisConfig::setFFMpegLocation ( const QString & value)

Definition at line 2460 of file kis_config.cc.

2460 {
2461 m_cfg.writeEntry("ffmpegLocation", value);
2462}

References m_cfg, and value().

◆ setFirstRun()

void KisConfig::setFirstRun ( const bool firstRun) const

Definition at line 1607 of file kis_config.cc.

1608{
1609 m_cfg.writeEntry("firstRun", first);
1610}

References m_cfg.

◆ setForceAlwaysFullSizedEraserOutline()

void KisConfig::setForceAlwaysFullSizedEraserOutline ( bool value) const

Definition at line 1376 of file kis_config.cc.

1377{
1378 m_cfg.writeEntry("forceAlwaysFullSizedEraserOutline", value);
1379}

References m_cfg, and value().

◆ setForceAlwaysFullSizedOutline()

void KisConfig::setForceAlwaysFullSizedOutline ( bool value) const

Definition at line 1354 of file kis_config.cc.

1355{
1356 m_cfg.writeEntry("forceAlwaysFullSizedOutline", value);
1357}

References m_cfg, and value().

◆ setForcePaletteColors()

void KisConfig::setForcePaletteColors ( bool forcePaletteColors)

Definition at line 908 of file kis_config.cc.

909{
910 m_cfg.writeEntry("colorsettings/forcepalettecolors", forcePaletteColors);
911}
bool forcePaletteColors(bool defaultValue=false) const

References forcePaletteColors(), and m_cfg.

◆ setForceShowAutosaveMessages()

void KisConfig::setForceShowAutosaveMessages ( bool ShowAutosaveMessages) const

Definition at line 944 of file kis_config.cc.

945{
946 m_cfg.writeEntry("forceShowAutosaveMessages", value);
947}

References m_cfg, and value().

◆ setForceShowSaveMessages()

void KisConfig::setForceShowSaveMessages ( bool value) const

Definition at line 934 of file kis_config.cc.

935{
936 m_cfg.writeEntry("forceShowSaveMessages", value);
937}

References m_cfg, and value().

◆ setFullscreenMode()

void KisConfig::setFullscreenMode ( const bool value) const

Definition at line 1737 of file kis_config.cc.

1738{
1739 m_cfg.writeEntry("fullscreenMode", value);
1740}

References m_cfg, and value().

◆ setGridIsoVerticalColor()

void KisConfig::setGridIsoVerticalColor ( const QColor & v) const

Definition at line 1128 of file kis_config.cc.

1129{
1130 m_cfg.writeEntry("gridisoverticalcolor", v);
1131}

References m_cfg, and v.

◆ setGridIsoVerticalStyle()

void KisConfig::setGridIsoVerticalStyle ( quint32 v) const

Definition at line 1095 of file kis_config.cc.

1096{
1097 m_cfg.writeEntry("gridisoverticalstyle", v);
1098}

References m_cfg, and v.

◆ setGridMainColor()

void KisConfig::setGridMainColor ( const QColor & v) const

Definition at line 1106 of file kis_config.cc.

1107{
1108 m_cfg.writeEntry("gridmaincolor", v);
1109}

References m_cfg, and v.

◆ setGridMainStyle()

void KisConfig::setGridMainStyle ( quint32 v) const

Definition at line 1071 of file kis_config.cc.

1072{
1073 m_cfg.writeEntry("gridmainstyle", v);
1074}

References m_cfg, and v.

◆ setGridSubdivisionColor()

void KisConfig::setGridSubdivisionColor ( const QColor & v) const

Definition at line 1117 of file kis_config.cc.

1118{
1119 m_cfg.writeEntry("gridsubdivisioncolor", v);
1120}

References m_cfg, and v.

◆ setGridSubdivisionStyle()

void KisConfig::setGridSubdivisionStyle ( quint32 v) const

Definition at line 1083 of file kis_config.cc.

1084{
1085 m_cfg.writeEntry("gridsubdivisionstyle", v);
1086}

References m_cfg, and v.

◆ setGuidesColor()

void KisConfig::setGuidesColor ( const QColor & v) const

Definition at line 1184 of file kis_config.cc.

1185{
1186 m_cfg.writeEntry("guidesColor", v);
1187}

References m_cfg, and v.

◆ setGuidesLineStyle()

void KisConfig::setGuidesLineStyle ( quint32 v) const

Definition at line 1173 of file kis_config.cc.

1174{
1175 m_cfg.writeEntry("guidesLineStyle", v);
1176}

References m_cfg, and v.

◆ setHideDevFundBanner()

void KisConfig::setHideDevFundBanner ( bool value = true)

Definition at line 1405 of file kis_config.cc.

1406{
1407 m_cfg.writeEntry("hideDevFundBanner", value);
1408}

References m_cfg, and value().

◆ setHideDockersFullscreen()

void KisConfig::setHideDockersFullscreen ( const bool value) const

Definition at line 1647 of file kis_config.cc.

1648{
1649 m_cfg.writeEntry("hideDockersFullScreen", value);
1650}

References m_cfg, and value().

◆ setHideMenuFullscreen()

void KisConfig::setHideMenuFullscreen ( const bool value) const

Definition at line 1687 of file kis_config.cc.

1688{
1689 m_cfg.writeEntry("hideMenuFullScreen", value);
1690}

References m_cfg, and value().

◆ setHidePopups()

void KisConfig::setHidePopups ( bool hidePopups)

Definition at line 1993 of file kis_config.cc.

1994{
1995 m_cfg.writeEntry("hidePopups", hidePopups);
1996}
bool hidePopups(bool defaultValue=false) const

References hidePopups(), and m_cfg.

◆ setHideScrollbars()

void KisConfig::setHideScrollbars ( bool value) const

Definition at line 1261 of file kis_config.cc.

1262{
1263 m_cfg.writeEntry("hideScrollbars", value);
1264}

References m_cfg, and value().

◆ setHideScrollbarsFullscreen()

void KisConfig::setHideScrollbarsFullscreen ( const bool value) const

Definition at line 1697 of file kis_config.cc.

1698{
1699 m_cfg.writeEntry("hideScrollbarsFullScreen", value);
1700}

References m_cfg, and value().

◆ setHideStatusbarFullscreen()

void KisConfig::setHideStatusbarFullscreen ( const bool value) const

Definition at line 1707 of file kis_config.cc.

1708{
1709 m_cfg.writeEntry("hideStatusbarFullScreen", value);
1710}

References m_cfg, and value().

◆ setHideTitlebarFullscreen()

void KisConfig::setHideTitlebarFullscreen ( const bool value) const

Definition at line 1717 of file kis_config.cc.

1718{
1719 m_cfg.writeEntry("hideTitleBarFullscreen", value);
1720}

References m_cfg, and value().

◆ setHideToolbarFullscreen()

void KisConfig::setHideToolbarFullscreen ( const bool value) const

Definition at line 1727 of file kis_config.cc.

1728{
1729 m_cfg.writeEntry("hideToolbarFullscreen", value);
1730}

References m_cfg, and value().

◆ setHorizontalSplitLines()

void KisConfig::setHorizontalSplitLines ( const int numberLines) const

Definition at line 1616 of file kis_config.cc.

1617{
1618 m_cfg.writeEntry("horizontalSplitLines", numberLines);
1619}

References m_cfg.

◆ setIgnoreHighFunctionKeys()

void KisConfig::setIgnoreHighFunctionKeys ( bool value)

Definition at line 2173 of file kis_config.cc.

2174{
2175 m_cfg.writeEntry("ignoreHighFunctionKeys", value);
2176}

References m_cfg, and value().

◆ setImportConfiguration()

void KisConfig::setImportConfiguration ( const QString & filterId,
KisPropertiesConfigurationSP properties ) const

Definition at line 1778 of file kis_config.cc.

1779{
1780 QString importConfig = properties->toXML();
1781 m_cfg.writeEntry("ImportConfiguration-" + filterId, importConfig);
1782}

References m_cfg.

◆ setImportProfile()

void KisConfig::setImportProfile ( const QString & importProfile) const

◆ setKineticScrollingEnabled()

void KisConfig::setKineticScrollingEnabled ( bool enabled)

Definition at line 2272 of file kis_config.cc.

2273{
2274 m_cfg.writeEntry("KineticScrollingEnabled", value);
2275}

References m_cfg, and value().

◆ setKineticScrollingGesture()

void KisConfig::setKineticScrollingGesture ( int kineticScroll)

Definition at line 2288 of file kis_config.cc.

2289{
2290 m_cfg.writeEntry("KineticScrollingGesture", gesture);
2291}

References m_cfg.

◆ setKineticScrollingHideScrollbars()

void KisConfig::setKineticScrollingHideScrollbars ( bool scrollbar)

Definition at line 2308 of file kis_config.cc.

2309{
2310 m_cfg.writeEntry("KineticScrollingHideScrollbar", scrollbar);
2311}

References m_cfg.

◆ setKineticScrollingSensitivity()

void KisConfig::setKineticScrollingSensitivity ( int sensitivity)

Definition at line 2298 of file kis_config.cc.

2299{
2300 m_cfg.writeEntry("KineticScrollingSensitivity", sensitivity);
2301}

References m_cfg.

◆ setLastUsedOutlineStyle()

void KisConfig::setLastUsedOutlineStyle ( OutlineStyle style)

Definition at line 452 of file kis_config.cc.

453{
454 m_cfg.writeEntry("lastUsedOutlineStyle", (int)style);
455}

References m_cfg.

◆ setLayerInfoTextOpacity()

void KisConfig::setLayerInfoTextOpacity ( int value)

Definition at line 2735 of file kis_config.cc.

2736{
2737 m_cfg.writeEntry("layerInfoTextOpacity", value);
2738}

References m_cfg, and value().

◆ setLayerInfoTextStyle()

void KisConfig::setLayerInfoTextStyle ( KisConfig::LayerInfoTextStyle value)

Definition at line 2725 of file kis_config.cc.

2726{
2727 m_cfg.writeEntry("layerInfoTextStyle", (int)value);
2728}

References m_cfg, and value().

◆ setLayerThumbnailSize()

void KisConfig::setLayerThumbnailSize ( int size)

Definition at line 1913 of file kis_config.cc.

1914{
1915 m_cfg.writeEntry("layerThumbnailSize", size);
1916}

References m_cfg.

◆ setLayerTreeIndentation()

void KisConfig::setLayerTreeIndentation ( int percentage)

Definition at line 1923 of file kis_config.cc.

1924{
1925 m_cfg.writeEntry("layerTreeIndentation", percentage);
1926}

References m_cfg.

◆ setLevelOfDetailEnabled()

void KisConfig::setLevelOfDetailEnabled ( bool value)

Definition at line 1814 of file kis_config.cc.

1815{
1816 m_cfg.writeEntry("levelOfDetailEnabled", value);
1817}

References m_cfg, and value().

◆ setLineSmoothingDelayDistance()

void KisConfig::setLineSmoothingDelayDistance ( qreal value)

Definition at line 2113 of file kis_config.cc.

2114{
2115 m_cfg.writeEntry("LineSmoothingDelayDistance", value);
2116}

References m_cfg, and value().

◆ setLineSmoothingDistanceKeepAspectRatio()

void KisConfig::setLineSmoothingDistanceKeepAspectRatio ( bool value)

Definition at line 2073 of file kis_config.cc.

2074{
2075 m_cfg.writeEntry("LineSmoothingDistanceKeepAspectRatio", value);
2076}

References m_cfg, and value().

◆ setLineSmoothingDistanceMax()

void KisConfig::setLineSmoothingDistanceMax ( qreal value)

Definition at line 2063 of file kis_config.cc.

2064{
2065 m_cfg.writeEntry("LineSmoothingDistanceMax", value);
2066}

References m_cfg, and value().

◆ setLineSmoothingDistanceMin()

void KisConfig::setLineSmoothingDistanceMin ( qreal value)

Definition at line 2053 of file kis_config.cc.

2054{
2055 m_cfg.writeEntry("LineSmoothingDistanceMin", value);
2056}

References m_cfg, and value().

◆ setLineSmoothingFinishStabilizedCurve()

void KisConfig::setLineSmoothingFinishStabilizedCurve ( bool value)

Definition at line 2133 of file kis_config.cc.

2134{
2135 m_cfg.writeEntry("LineSmoothingFinishStabilizedCurve", value);
2136}

References m_cfg, and value().

◆ setLineSmoothingScalableDistance()

void KisConfig::setLineSmoothingScalableDistance ( bool value)

Definition at line 2103 of file kis_config.cc.

2104{
2105 m_cfg.writeEntry("LineSmoothingScalableDistance", value);
2106}

References m_cfg, and value().

◆ setLineSmoothingSmoothPressure()

void KisConfig::setLineSmoothingSmoothPressure ( bool value)

Definition at line 2093 of file kis_config.cc.

2094{
2095 m_cfg.writeEntry("LineSmoothingSmoothPressure", value);
2096}

References m_cfg, and value().

◆ setLineSmoothingStabilizeSensors()

void KisConfig::setLineSmoothingStabilizeSensors ( bool value)

Definition at line 2143 of file kis_config.cc.

2144{
2145 m_cfg.writeEntry("LineSmoothingStabilizeSensors", value);
2146}

References m_cfg, and value().

◆ setLineSmoothingTailAggressiveness()

void KisConfig::setLineSmoothingTailAggressiveness ( qreal value)

Definition at line 2083 of file kis_config.cc.

2084{
2085 m_cfg.writeEntry("LineSmoothingTailAggressiveness", value);
2086}

References m_cfg, and value().

◆ setLineSmoothingType()

void KisConfig::setLineSmoothingType ( int value)

Definition at line 2043 of file kis_config.cc.

2044{
2045 m_cfg.writeEntry("LineSmoothingType", value);
2046}

References m_cfg, and value().

◆ setLineSmoothingUseDelayDistance()

void KisConfig::setLineSmoothingUseDelayDistance ( bool value)

Definition at line 2123 of file kis_config.cc.

2124{
2125 m_cfg.writeEntry("LineSmoothingUseDelayDistance", value);
2126}

References m_cfg, and value().

◆ setLongPressEnabled()

void KisConfig::setLongPressEnabled ( bool value)

Definition at line 2789 of file kis_config.cc.

2790{
2791 m_cfg.writeEntry("longPressEnabled", value);
2793}
void notifyLongPressChanged(bool enabled)

References KisConfigNotifier::instance(), m_cfg, KisConfigNotifier::notifyLongPressChanged(), and value().

◆ setMDIBackgroundColor()

void KisConfig::setMDIBackgroundColor ( const QString & v) const

Definition at line 584 of file kis_config.cc.

585{
586 m_cfg.writeEntry("mdiBackgroundColorXML", v);
587}

References m_cfg, and v.

◆ setMDIBackgroundImage()

void KisConfig::setMDIBackgroundImage ( const QString & fileName) const

Definition at line 594 of file kis_config.cc.

595{
596 m_cfg.writeEntry("mdiBackgroundImage", filename);
597}

References m_cfg.

◆ setMonitorForScreen()

void KisConfig::setMonitorForScreen ( int screen,
const QString & monitor )

Definition at line 744 of file kis_config.cc.

745{
746 m_cfg.writeEntry(QString("monitor_for_screen_%1").arg(screen), monitor);
747}

References m_cfg.

◆ setMonitorProfile()

void KisConfig::setMonitorProfile ( int screen,
const QString & monitorProfile,
bool override ) const

Definition at line 749 of file kis_config.cc.

750{
751 m_cfg.writeEntry("monitorProfile/OverrideX11", override);
752 m_cfg.writeEntry("monitorProfile" + QString(screen == 0 ? "": QString("_%1").arg(screen)), monitorProfile);
753 if (!getScreenStringIdentfier(screen).isEmpty()) {
754 m_cfg.writeEntry("monitorProfile" + getScreenStringIdentfier(screen), monitorProfile);
755 }
756}

References getScreenStringIdentfier(), m_cfg, and monitorProfile().

◆ setNewCursorStyle()

void KisConfig::setNewCursorStyle ( CursorStyle style)

Definition at line 375 of file kis_config.cc.

376{
377 m_cfg.writeEntry("newCursorStyle", (int)style);
378}

References m_cfg.

◆ setNewOutlineStyle()

void KisConfig::setNewOutlineStyle ( OutlineStyle style)

Definition at line 436 of file kis_config.cc.

437{
438 m_cfg.writeEntry("newOutlineStyle", (int)style);
439}

References m_cfg.

◆ setNumDefaultLayers()

void KisConfig::setNumDefaultLayers ( int num)

Definition at line 2003 of file kis_config.cc.

2004{
2005 m_cfg.writeEntry("NumberOfLayersForNewImage", num);
2006}

References m_cfg.

◆ setOcioColorManagementMode()

void KisConfig::setOcioColorManagementMode ( OcioColorManagementMode mode) const

Definition at line 1855 of file kis_config.cc.

1856{
1857 // FIXME: this option duplicates ocioConfiguration(), please deprecate it
1858 m_cfg.writeEntry("Krita/Ocio/OcioColorManagementMode", (int) mode);
1859}

References m_cfg.

◆ setOcioConfiguration()

void KisConfig::setOcioConfiguration ( const KisOcioConfiguration & cfg)

Definition at line 1836 of file kis_config.cc.

1837{
1838 m_cfg.writeEntry("Krita/Ocio/OcioColorManagementMode", (int) cfg.mode);
1839 m_cfg.writeEntry("Krita/Ocio/OcioConfigPath", cfg.configurationPath);
1840 m_cfg.writeEntry("Krita/Ocio/OcioLutPath", cfg.lutPath);
1841 m_cfg.writeEntry("Krita/Ocio/InputColorSpace", cfg.inputColorSpace);
1842 m_cfg.writeEntry("Krita/Ocio/DisplayDevice", cfg.displayDevice);
1843 m_cfg.writeEntry("Krita/Ocio/DisplayView", cfg.displayView);
1844 m_cfg.writeEntry("Krita/Ocio/DisplayLook", cfg.look);
1845}

References KisOcioConfiguration::configurationPath, KisOcioConfiguration::displayDevice, KisOcioConfiguration::displayView, KisOcioConfiguration::inputColorSpace, KisOcioConfiguration::look, KisOcioConfiguration::lutPath, m_cfg, and KisOcioConfiguration::mode.

◆ setOcioLockColorVisualRepresentation()

void KisConfig::setOcioLockColorVisualRepresentation ( bool value)

Definition at line 1876 of file kis_config.cc.

1877{
1878 m_cfg.writeEntry("Krita/Ocio/OcioLockColorVisualRepresentation", value);
1879}

References m_cfg, and value().

◆ setOcioLutEdgeSize()

void KisConfig::setOcioLutEdgeSize ( int value)

Definition at line 1866 of file kis_config.cc.

1867{
1868 m_cfg.writeEntry("Krita/Ocio/LutEdgeSize", value);
1869}

References m_cfg, and value().

◆ setOpenGLFilteringMode()

void KisConfig::setOpenGLFilteringMode ( int filteringMode)

Definition at line 1019 of file kis_config.cc.

1020{
1021 m_cfg.writeEntry("OpenGLFilterMode", filteringMode);
1022}

References m_cfg.

◆ setOutlineSizeMinimum()

void KisConfig::setOutlineSizeMinimum ( qreal outlineSizeMinimum) const

Definition at line 1415 of file kis_config.cc.

1416{
1417 m_cfg.writeEntry("OutlineSizeMinimum", outlineSizeMinimum);
1418}
qreal outlineSizeMinimum(bool defaultValue=false) const

References m_cfg, and outlineSizeMinimum().

◆ setPaintopPopupDetached()

void KisConfig::setPaintopPopupDetached ( bool detached) const

Definition at line 1507 of file kis_config.cc.

1508{
1509 m_cfg.writeEntry("PaintopPopupDetached", detached);
1510}

References m_cfg.

◆ setPasteBehaviour()

void KisConfig::setPasteBehaviour ( qint32 behaviour) const

Definition at line 964 of file kis_config.cc.

965{
966 m_cfg.writeEntry("pasteBehaviour", renderIntent);
967}

References m_cfg.

◆ setPasteFormat()

void KisConfig::setPasteFormat ( qint32 format)

Definition at line 974 of file kis_config.cc.

975{
976 m_cfg.writeEntry("pasteFormat", format);
977}

References m_cfg.

◆ setPixelGridColor()

void KisConfig::setPixelGridColor ( const QColor & v) const

Definition at line 1139 of file kis_config.cc.

1140{
1141 m_cfg.writeEntry("pixelGridColor", v);
1142}

References m_cfg, and v.

◆ setPixelGridDrawingThreshold()

void KisConfig::setPixelGridDrawingThreshold ( qreal v) const

Definition at line 1150 of file kis_config.cc.

1151{
1152 m_cfg.writeEntry("pixelGridDrawingThreshold", v);
1153}

References m_cfg, and v.

◆ setPreferredVectorImportResolutionPPI()

void KisConfig::setPreferredVectorImportResolutionPPI ( int value) const

Definition at line 294 of file kis_config.cc.

295{
296 m_cfg.writeEntry("preferredVectorImportResolution", value);
297}

References m_cfg, and value().

◆ setPresetChooserViewMode()

void KisConfig::setPresetChooserViewMode ( const int mode) const

Definition at line 1587 of file kis_config.cc.

1588{
1589 m_cfg.writeEntry("presetChooserViewMode", mode);
1590}

References m_cfg.

◆ setPresetIconSize()

void KisConfig::setPresetIconSize ( const int value) const

Definition at line 1597 of file kis_config.cc.

1598{
1599 m_cfg.writeEntry("presetIconSize", value);
1600}

References m_cfg, and value().

◆ setPresetStripVisible()

void KisConfig::setPresetStripVisible ( bool visible)

Definition at line 1963 of file kis_config.cc.

1964{
1965 m_cfg.writeEntry("presetStripVisible", visible);
1966}

References m_cfg.

◆ setPressureTabletCurve()

void KisConfig::setPressureTabletCurve ( const QString & curveString) const

Definition at line 1517 of file kis_config.cc.

1518{
1519 m_cfg.writeEntry("tabletPressureCurve", curveString);
1520}

References m_cfg.

◆ setPrinterColorSpace()

void KisConfig::setPrinterColorSpace ( const QString & printerColorSpace) const

Definition at line 866 of file kis_config.cc.

867{
868 m_cfg.writeEntry("printerColorSpace", printerColorSpace);
869}
QString printerColorSpace(bool defaultValue=false) const

References m_cfg, and printerColorSpace().

◆ setPrinterProfile()

void KisConfig::setPrinterProfile ( const QString & printerProfile) const

Definition at line 877 of file kis_config.cc.

878{
879 m_cfg.writeEntry("printerProfile", printerProfile);
880}
QString printerProfile(bool defaultValue=false) const

References m_cfg, and printerProfile().

◆ setRenamePastedLayers()

void KisConfig::setRenamePastedLayers ( bool value)

Definition at line 2715 of file kis_config.cc.

2716{
2717 m_cfg.writeEntry("renamePastedLayers", value);
2718}

References m_cfg, and value().

◆ setRenderIntent()

void KisConfig::setRenderIntent ( qint32 monitorRenderIntent) const

Definition at line 987 of file kis_config.cc.

988{
989 if (renderIntent > 3) renderIntent = 3;
990 if (renderIntent < 0) renderIntent = 0;
991 m_cfg.writeEntry("renderIntent", renderIntent);
992}

References m_cfg.

◆ setRootSurfaceFormat() [1/2]

void KisConfig::setRootSurfaceFormat ( QSettings * displayrc,
KisConfig::RootSurfaceFormat value )
static

Definition at line 2680 of file kis_config.cc.

2681{
2682 const QString textValue =
2683 value == BT709_G10 ? "bt709-g10" :
2684 value == BT2020_PQ ? "bt2020-pq" :
2685 "bt709-g22";
2686
2687 displayrc->setValue("rootSurfaceFormat", textValue);
2688}

References BT2020_PQ, BT709_G10, and value().

◆ setRootSurfaceFormat() [2/2]

void KisConfig::setRootSurfaceFormat ( KisConfig::RootSurfaceFormat value)

Definition at line 2659 of file kis_config.cc.

2660{
2661 const QString configPath = QStandardPaths::writableLocation(QStandardPaths::GenericConfigLocation);
2662 QSettings kritarc(configPath + QStringLiteral("/kritadisplayrc"), QSettings::IniFormat);
2663
2664 setRootSurfaceFormat(&kritarc, value);
2665}
void setRootSurfaceFormat(RootSurfaceFormat value)

References setRootSurfaceFormat(), and value().

◆ setRulersTrackMouse()

void KisConfig::setRulersTrackMouse ( bool value) const

Definition at line 954 of file kis_config.cc.

955{
956 m_cfg.writeEntry("rulersTrackMouse", value);
957}

References m_cfg, and value().

◆ setSaveSessionOnQuit()

void KisConfig::setSaveSessionOnQuit ( bool value)

Definition at line 1395 of file kis_config.cc.

1396{
1397 m_cfg.writeEntry("saveSessionOnQuit", value);
1398}

References m_cfg, and value().

◆ setScratchpadVisible()

void KisConfig::setScratchpadVisible ( bool visible)

Definition at line 1973 of file kis_config.cc.

1974{
1975 m_cfg.writeEntry("scratchpadVisible", visible);
1976}

References m_cfg.

◆ setScrollbarZoomEnabled()

void KisConfig::setScrollbarZoomEnabled ( bool enabled) const

Definition at line 1271 of file kis_config.cc.

1272{
1273 m_cfg.writeEntry("scrollbarZoomEnabled", enabled);
1274}

References m_cfg.

◆ setScrollingCheckers()

void KisConfig::setScrollingCheckers ( bool scrollCheckers) const

Definition at line 1240 of file kis_config.cc.

1241{
1242 m_cfg.writeEntry("scrollingcheckers", sc);
1243}

References m_cfg.

◆ setScrubbingAudioUpdatesDelay()

void KisConfig::setScrubbingAudioUpdatesDelay ( int value)

Definition at line 2494 of file kis_config.cc.

2495{
2496 m_cfg.writeEntry("scrubbingAudioUpdatesDelay", value);
2497}

References m_cfg, and value().

◆ setScrubbingUpdatesDelay()

void KisConfig::setScrubbingUpdatesDelay ( int value)

Definition at line 2484 of file kis_config.cc.

2485{
2486 m_cfg.writeEntry("scrubbingUpdatesDelay", value);
2487}

References m_cfg, and value().

◆ setSelectionActionBar()

void KisConfig::setSelectionActionBar ( bool value)

Definition at line 2646 of file kis_config.cc.

2647{
2648 m_cfg.writeEntry("selectionActionBar", value);
2649}

References m_cfg, and value().

◆ setSelectionViewSizeMinimum()

void KisConfig::setSelectionViewSizeMinimum ( qreal outlineSizeMinimum) const

Definition at line 1425 of file kis_config.cc.

1426{
1427 m_cfg.writeEntry("SelectionViewSizeMinimum", outlineSizeMinimum);
1428}

References m_cfg, and outlineSizeMinimum().

◆ setSeparateEraserCursor()

void KisConfig::setSeparateEraserCursor ( bool value) const

Definition at line 464 of file kis_config.cc.

465{
466 m_cfg.writeEntry("separateEraserCursor", value);
467}

References m_cfg, and value().

◆ setSessionOnStartup()

void KisConfig::setSessionOnStartup ( SessionOnStartup value)

Definition at line 1386 of file kis_config.cc.

1387{
1388 m_cfg.writeEntry("sessionOnStartup", (int)value);
1389}

References m_cfg, and value().

◆ setShowBrushHud()

void KisConfig::setShowBrushHud ( bool value)

Definition at line 2564 of file kis_config.cc.

2565{
2566 m_cfg.writeEntry("showBrushHud", value);
2567}

References m_cfg, and value().

◆ setShowCanvasMessages()

void KisConfig::setShowCanvasMessages ( bool show)

Definition at line 2213 of file kis_config.cc.

2214{
2215 m_cfg.writeEntry("showOnCanvasMessages", show);
2216}

References m_cfg.

◆ setShowDockers()

void KisConfig::setShowDockers ( const bool value) const

Definition at line 1667 of file kis_config.cc.

1668{
1669 m_cfg.writeEntry("showDockers", value);
1670}

References m_cfg, and value().

◆ setShowDockerTitleBars()

void KisConfig::setShowDockerTitleBars ( const bool value) const

Definition at line 1657 of file kis_config.cc.

1658{
1659 m_cfg.writeEntry("showDockerTitleBars", value);
1660}

References m_cfg, and value().

◆ setShowEraserOutlineWhilePainting()

void KisConfig::setShowEraserOutlineWhilePainting ( bool showEraserOutlineWhilePainting) const

Definition at line 1366 of file kis_config.cc.

1367{
1368 m_cfg.writeEntry("ShowEraserOutlineWhilePainting", showEraserOutlineWhilePainting);
1369}
bool showEraserOutlineWhilePainting(bool defaultValue=false) const

References m_cfg, and showEraserOutlineWhilePainting().

◆ setShowFilterGallery()

void KisConfig::setShowFilterGallery ( bool showFilterGallery) const

Definition at line 1456 of file kis_config.cc.

1457{
1458 m_cfg.writeEntry("showFilterGallery", showFilterGallery);
1459}
bool showFilterGallery(bool defaultValue=false) const

References m_cfg, and showFilterGallery().

◆ setShowFilterGalleryLayerMaskDialog()

void KisConfig::setShowFilterGalleryLayerMaskDialog ( bool showFilterGallery) const

Definition at line 1466 of file kis_config.cc.

1467{
1468 m_cfg.writeEntry("setShowFilterGalleryLayerMaskDialog", showFilterGallery);
1469}

References m_cfg, and showFilterGallery().

◆ setShowGlobalSelection()

void KisConfig::setShowGlobalSelection ( bool showGlobalSelection) const

Definition at line 1332 of file kis_config.cc.

1333{
1334 m_cfg.writeEntry("ShowGlobalSelection", showGlobalSelection);
1335}
bool showGlobalSelection(bool defaultValue=false) const

References m_cfg, and showGlobalSelection().

◆ setShowOutlineWhilePainting()

void KisConfig::setShowOutlineWhilePainting ( bool showOutlineWhilePainting) const

Definition at line 1344 of file kis_config.cc.

1345{
1346 m_cfg.writeEntry("ShowOutlineWhilePainting", showOutlineWhilePainting);
1347}
bool showOutlineWhilePainting(bool defaultValue=false) const

References m_cfg, and showOutlineWhilePainting().

◆ setShowPaletteBottomBar()

void KisConfig::setShowPaletteBottomBar ( bool value)

Definition at line 2574 of file kis_config.cc.

2575{
2576 m_cfg.writeEntry("showPaletteBottomBar", value);
2577}

References m_cfg, and value().

◆ setShowRootLayer()

void KisConfig::setShowRootLayer ( bool showRootLayer) const

Definition at line 1322 of file kis_config.cc.

1323{
1324 m_cfg.writeEntry("ShowRootLayer", showRootLayer);
1325}
bool showRootLayer(bool defaultValue=false) const

References m_cfg, and showRootLayer().

◆ setShowRulers()

void KisConfig::setShowRulers ( bool rulers) const

Definition at line 924 of file kis_config.cc.

925{
926 m_cfg.writeEntry("showrulers", rulers);
927}

References m_cfg.

◆ setShowSingleChannelAsColor()

void KisConfig::setShowSingleChannelAsColor ( bool asColor)

Definition at line 1983 of file kis_config.cc.

1984{
1985 m_cfg.writeEntry("showSingleChannelAsColor", asColor);
1986}

References m_cfg.

◆ setShowStatusBar()

void KisConfig::setShowStatusBar ( const bool value) const

Definition at line 1677 of file kis_config.cc.

1678{
1679 m_cfg.writeEntry("showStatusBar", value);
1680}

References m_cfg, and value().

◆ setSliderLabels()

void KisConfig::setSliderLabels ( bool enabled)

Definition at line 1933 of file kis_config.cc.

1934{
1935 m_cfg.writeEntry("sliderLabels", enabled);
1936}

References m_cfg.

◆ setStabilizerDelayedPaint()

void KisConfig::setStabilizerDelayedPaint ( bool value)

Definition at line 2554 of file kis_config.cc.

2555{
2556 m_cfg.writeEntry("stabilizerDelayedPaint", value);
2557}

References m_cfg, and value().

◆ setStabilizerSampleSize()

void KisConfig::setStabilizerSampleSize ( int value)

Definition at line 2541 of file kis_config.cc.

2542{
2543 m_cfg.writeEntry("stabilizerSampleSize", value);
2544}

References m_cfg, and value().

◆ setSwitchSelectionCtrlAlt()

void KisConfig::setSwitchSelectionCtrlAlt ( bool value)

Definition at line 2514 of file kis_config.cc.

2515{
2516 m_cfg.writeEntry("switchSelectionCtrlAlt", value);
2517}

References m_cfg, and value().

◆ setTabletEventsDelay()

void KisConfig::setTabletEventsDelay ( int value)

Definition at line 2153 of file kis_config.cc.

2154{
2155 m_cfg.writeEntry("tabletEventsDelay", value);
2156}

References m_cfg, and value().

◆ setTestingAcceptCompressedTabletEvents()

void KisConfig::setTestingAcceptCompressedTabletEvents ( bool value)

Definition at line 2183 of file kis_config.cc.

2184{
2185 m_cfg.writeEntry("testingAcceptCompressedTabletEvents", value);
2186}

References m_cfg, and value().

◆ setTestingCompressBrushEvents()

void KisConfig::setTestingCompressBrushEvents ( bool value)

Definition at line 2198 of file kis_config.cc.

2199{
2200 m_cfg.writeEntry("testingCompressBrushEvents", value);
2201}

References m_cfg, and value().

◆ setTimelineZoom()

void KisConfig::setTimelineZoom ( qreal value)

Definition at line 2469 of file kis_config.cc.

2470{
2471 m_cfg.writeEntry("timelineZoom", value);
2472}

References m_cfg, and value().

◆ setToolbarSlider()

void KisConfig::setToolbarSlider ( int sliderNumber,
const QString & slider )

Definition at line 1903 of file kis_config.cc.

1904{
1905 m_cfg.writeEntry(QString("toolbarslider_%1").arg(sliderNumber), slider);
1906}

References m_cfg.

◆ setToolOptionsInDocker()

void KisConfig::setToolOptionsInDocker ( bool inDocker)

Definition at line 2262 of file kis_config.cc.

2263{
2264 m_cfg.writeEntry("ToolOptionsInDocker", inDocker);
2265}

References m_cfg.

◆ setToolOptionsPopupDetached()

void KisConfig::setToolOptionsPopupDetached ( bool detached) const

Definition at line 1496 of file kis_config.cc.

1497{
1498 m_cfg.writeEntry("ToolOptionsPopupDetached", detached);
1499}

References m_cfg.

◆ setTouchPainting()

void KisConfig::setTouchPainting ( TouchPainting value) const

Definition at line 148 of file kis_config.cc.

149{
150 m_cfg.writeEntry("touchPainting", int(value));
152}

References KisConfigNotifier::instance(), m_cfg, KisConfigNotifier::notifyTouchPaintingChanged(), and value().

◆ setTrackTabletEventLatency()

void KisConfig::setTrackTabletEventLatency ( bool value)

Definition at line 2163 of file kis_config.cc.

2164{
2165 m_cfg.writeEntry("trackTabletEventLatency", value);
2166}

References m_cfg, and value().

◆ setTrimFramesImport()

void KisConfig::setTrimFramesImport ( bool trim)

Definition at line 2242 of file kis_config.cc.

2243{
2244 m_cfg.writeEntry("TrimFramesImport", trim);
2245}

References m_cfg.

◆ setTrimKra()

void KisConfig::setTrimKra ( bool trim)

Definition at line 2233 of file kis_config.cc.

2234{
2235 m_cfg.writeEntry("TrimKra", trim);
2236}

References m_cfg.

◆ setUndoEnabled()

void KisConfig::setUndoEnabled ( bool undo) const

Definition at line 184 of file kis_config.cc.

185{
186 m_cfg.writeEntry("undoEnabled", undo);
187}

References m_cfg.

◆ setUndoStackLimit()

void KisConfig::setUndoStackLimit ( int limit) const

Definition at line 194 of file kis_config.cc.

195{
196 m_cfg.writeEntry("undoStackLimit", limit);
197}

References m_cfg.

◆ setUseBlackPointCompensation()

void KisConfig::setUseBlackPointCompensation ( bool useBlackPointCompensation) const

Definition at line 888 of file kis_config.cc.

889{
890 m_cfg.writeEntry("useBlackPointCompensation", useBlackPointCompensation);
891}
bool useBlackPointCompensation(bool defaultValue=false) const

References m_cfg, and useBlackPointCompensation().

◆ setUseDefaultColorSpace()

void KisConfig::setUseDefaultColorSpace ( bool value) const

Definition at line 304 of file kis_config.cc.

305{
306 m_cfg.writeEntry("useDefaultColorSpace", value);
307}

References m_cfg, and value().

◆ setUseDirtyPresets()

void KisConfig::setUseDirtyPresets ( bool value)

Definition at line 537 of file kis_config.cc.

538{
539 m_cfg.writeEntry("useDirtyPresets",value);
541}

References KisConfigNotifier::instance(), m_cfg, KisConfigNotifier::notifyConfigChanged(), and value().

◆ setUseEraserBrushOpacity()

void KisConfig::setUseEraserBrushOpacity ( bool value)

Definition at line 559 of file kis_config.cc.

560{
561 m_cfg.writeEntry("useEraserBrushOpacity",value);
563}

References KisConfigNotifier::instance(), m_cfg, KisConfigNotifier::notifyConfigChanged(), and value().

◆ setUseEraserBrushSize()

void KisConfig::setUseEraserBrushSize ( bool value)

Definition at line 548 of file kis_config.cc.

549{
550 m_cfg.writeEntry("useEraserBrushSize",value);
552}

References KisConfigNotifier::instance(), m_cfg, KisConfigNotifier::notifyConfigChanged(), and value().

◆ setUseInlineLayerInfoText()

void KisConfig::setUseInlineLayerInfoText ( bool value)

Definition at line 2745 of file kis_config.cc.

2746{
2747 m_cfg.writeEntry("useInlineLayerInfoText", value);
2748}

References m_cfg, and value().

◆ setUseLayerSelectionCheckbox()

void KisConfig::setUseLayerSelectionCheckbox ( bool value)

Definition at line 2755 of file kis_config.cc.

2756{
2757 m_cfg.writeEntry("useLayerSelectionCheckbox", value);
2758}

References m_cfg, and value().

◆ setUseOcio()

void KisConfig::setUseOcio ( bool useOCIO) const

Definition at line 1794 of file kis_config.cc.

1795{
1796 m_cfg.writeEntry("Krita/Ocio/UseOcio", useOCIO);
1797}

References m_cfg.

◆ setUseOpenGLTextureBuffer()

void KisConfig::setUseOpenGLTextureBuffer ( bool useBuffer)

Definition at line 1039 of file kis_config.cc.

1040{
1041 m_cfg.writeEntry("useOpenGLTextureBuffer", useBuffer);
1042}

References m_cfg.

◆ setUseProjections()

void KisConfig::setUseProjections ( bool useProj) const

Definition at line 174 of file kis_config.cc.

175{
176 m_cfg.writeEntry("useProjections", useProj);
177}

References m_cfg.

◆ setUseRightMiddleTabletButtonWorkaround()

void KisConfig::setUseRightMiddleTabletButtonWorkaround ( bool value)

Definition at line 1567 of file kis_config.cc.

1568{
1569 m_cfg.writeEntry("useRightMiddleTabletButtonWorkaround", value);
1570}

References m_cfg, and value().

◆ setUseSystemMonitorProfile()

void KisConfig::setUseSystemMonitorProfile ( bool _useSystemMonitorProfile) const

Definition at line 1953 of file kis_config.cc.

1954{
1955 m_cfg.writeEntry("ColorManagement/UseSystemMonitorProfile", _useSystemMonitorProfile);
1956}

References m_cfg.

◆ setUseWin8PointerInput()

void KisConfig::setUseWin8PointerInput ( bool value)

Definition at line 1535 of file kis_config.cc.

1536{
1537#ifdef Q_OS_WIN
1538
1539 // Special handling: Only set value if changed
1540 // I don't want it to be set if the user hasn't touched it
1541 if (useWin8PointerInput() != value) {
1542 const QString configPath = QStandardPaths::writableLocation(QStandardPaths::GenericConfigLocation);
1543 QSettings kritarc(configPath + QStringLiteral("/kritadisplayrc"), QSettings::IniFormat);
1545 }
1546
1547#else
1548 Q_UNUSED(value);
1549#endif
1550}
static void setUseWin8PointerInputNoApp(QSettings *settings, bool value)

References setUseWin8PointerInputNoApp(), useWin8PointerInput(), and value().

◆ setUseWin8PointerInputNoApp()

void KisConfig::setUseWin8PointerInputNoApp ( QSettings * settings,
bool value )
static

Definition at line 1557 of file kis_config.cc.

1558{
1559 settings->setValue("useWin8PointerInput", value);
1560}

References value().

◆ setUseZip64()

void KisConfig::setUseZip64 ( bool value)

Definition at line 2695 of file kis_config.cc.

2696{
2697 m_cfg.writeEntry("UseZip64", value);
2698}

References m_cfg, and value().

◆ setVastScrolling()

void KisConfig::setVastScrolling ( const qreal factor) const

Definition at line 1577 of file kis_config.cc.

1578{
1579 m_cfg.writeEntry("vastScrolling", factor);
1580}

References m_cfg.

◆ setVerticalSplitLines()

void KisConfig::setVerticalSplitLines ( const int numberLines) const

Definition at line 1626 of file kis_config.cc.

1627{
1628 m_cfg.writeEntry("verticalSplitLines", numberLines);
1629}

References m_cfg.

◆ setWidgetStyle()

void KisConfig::setWidgetStyle ( QString name)

Definition at line 1024 of file kis_config.cc.

1025{
1026 m_cfg.writeEntry("widgetStyle", name);
1027}

References m_cfg.

◆ setWorkingColorSpace()

void KisConfig::setWorkingColorSpace ( const QString & workingColorSpace) const

Definition at line 854 of file kis_config.cc.

855{
856 m_cfg.writeEntry("workingColorSpace", workingColorSpace);
857}
QString workingColorSpace(bool defaultValue=false) const

References m_cfg, and workingColorSpace().

◆ setZoomHorizontal()

void KisConfig::setZoomHorizontal ( bool value)

Definition at line 2636 of file kis_config.cc.

2637{
2638 m_cfg.writeEntry("zoomHorizontal", value);
2639}

References m_cfg, and value().

◆ setZoomMarginSize()

void KisConfig::setZoomMarginSize ( int zoomMarginSize)

Definition at line 2328 of file kis_config.cc.

2329{
2330 m_cfg.writeEntry("zoomMarginSize", zoomMarginSize);
2331}
int zoomMarginSize(bool defaultValue=false) const

References m_cfg, and zoomMarginSize().

◆ setZoomSteps()

void KisConfig::setZoomSteps ( int steps)

Definition at line 2318 of file kis_config.cc.

2319{
2320 m_cfg.writeEntry("zoomSteps", steps);
2321}

References m_cfg.

◆ shouldEatDriverShortcuts()

bool KisConfig::shouldEatDriverShortcuts ( bool defaultValue = false) const

Definition at line 2188 of file kis_config.cc.

2189{
2190 return (defaultValue ? false : m_cfg.readEntry("shouldEatDriverShortcuts", false));
2191}

References m_cfg.

◆ showBrushHud()

bool KisConfig::showBrushHud ( bool defaultValue = false) const

Definition at line 2559 of file kis_config.cc.

2560{
2561 return defaultValue ? false : m_cfg.readEntry("showBrushHud", false);
2562}

References m_cfg.

◆ showCanvasMessages()

bool KisConfig::showCanvasMessages ( bool defaultValue = false) const

Definition at line 2208 of file kis_config.cc.

2209{
2210 return (defaultValue ? true : m_cfg.readEntry("showOnCanvasMessages", true));
2211}

References m_cfg.

◆ showDockers()

bool KisConfig::showDockers ( bool defaultValue = false) const

Definition at line 1662 of file kis_config.cc.

1663{
1664 return (defaultValue ? true : m_cfg.readEntry("showDockers", true));
1665}

References m_cfg.

◆ showDockerTitleBars()

bool KisConfig::showDockerTitleBars ( bool defaultValue = false) const

Definition at line 1652 of file kis_config.cc.

1653{
1654 return (defaultValue ? true : m_cfg.readEntry("showDockerTitleBars", true));
1655}

References m_cfg.

◆ showEraserOutlineWhilePainting()

bool KisConfig::showEraserOutlineWhilePainting ( bool defaultValue = false) const

Definition at line 1361 of file kis_config.cc.

1362{
1363 return (defaultValue ? true : m_cfg.readEntry("ShowEraserOutlineWhilePainting", true));
1364}

References m_cfg.

◆ showFilterGallery()

bool KisConfig::showFilterGallery ( bool defaultValue = false) const

Definition at line 1451 of file kis_config.cc.

1452{
1453 return (defaultValue ? false : m_cfg.readEntry("showFilterGallery", false));
1454}

References m_cfg.

◆ showFilterGalleryLayerMaskDialog()

bool KisConfig::showFilterGalleryLayerMaskDialog ( bool defaultValue = false) const

Definition at line 1461 of file kis_config.cc.

1462{
1463 return (defaultValue ? true : m_cfg.readEntry("showFilterGalleryLayerMaskDialog", true));
1464}

References m_cfg.

◆ showGlobalSelection()

bool KisConfig::showGlobalSelection ( bool defaultValue = false) const

Definition at line 1327 of file kis_config.cc.

1328{
1329 return (defaultValue ? false : m_cfg.readEntry("ShowGlobalSelection", false));
1330}

References m_cfg.

◆ showOutlineWhilePainting()

bool KisConfig::showOutlineWhilePainting ( bool defaultValue = false) const

Definition at line 1339 of file kis_config.cc.

1340{
1341 return (defaultValue ? true : m_cfg.readEntry("ShowOutlineWhilePainting", true));
1342}

References m_cfg.

◆ showPaletteBottomBar()

bool KisConfig::showPaletteBottomBar ( bool defaultValue = false) const

Definition at line 2569 of file kis_config.cc.

2570{
2571 return defaultValue ? true : m_cfg.readEntry("showPaletteBottomBar", true);
2572}

References m_cfg.

◆ showRootLayer()

bool KisConfig::showRootLayer ( bool defaultValue = false) const

Definition at line 1317 of file kis_config.cc.

1318{
1319 return (defaultValue ? false : m_cfg.readEntry("ShowRootLayer", false));
1320}

References m_cfg.

◆ showRulers()

bool KisConfig::showRulers ( bool defaultValue = false) const

Definition at line 919 of file kis_config.cc.

920{
921 return (defaultValue ? false : m_cfg.readEntry("showrulers", false));
922}

References m_cfg.

◆ showSingleChannelAsColor()

bool KisConfig::showSingleChannelAsColor ( bool defaultValue = false) const

Definition at line 1978 of file kis_config.cc.

1979{
1980 return (defaultValue ? false : m_cfg.readEntry("showSingleChannelAsColor", false));
1981}

References m_cfg.

◆ showStatusBar()

bool KisConfig::showStatusBar ( bool defaultValue = false) const

Definition at line 1672 of file kis_config.cc.

1673{
1674 return (defaultValue ? true : m_cfg.readEntry("showStatusBar", true));
1675}

References m_cfg.

◆ sliderLabels()

bool KisConfig::sliderLabels ( bool defaultValue = false) const

Definition at line 1928 of file kis_config.cc.

1929{
1930 return (defaultValue ? true : m_cfg.readEntry("sliderLabels", true));
1931}

References m_cfg.

◆ stabilizerDelayedPaint()

bool KisConfig::stabilizerDelayedPaint ( bool defaultValue = false) const

Definition at line 2546 of file kis_config.cc.

2547{
2548 const bool defaultEnabled = true;
2549
2550 return defaultValue ?
2551 defaultEnabled : m_cfg.readEntry("stabilizerDelayedPaint", defaultEnabled);
2552}

References m_cfg.

◆ stabilizerSampleSize()

int KisConfig::stabilizerSampleSize ( bool defaultValue = false) const

Definition at line 2529 of file kis_config.cc.

2530{
2531#ifdef Q_OS_WIN
2532 const int defaultSampleSize = 50;
2533#else
2534 const int defaultSampleSize = 15;
2535#endif
2536
2537 return defaultValue ?
2538 defaultSampleSize : m_cfg.readEntry("stabilizerSampleSize", defaultSampleSize);
2539}

References m_cfg.

◆ switchSelectionCtrlAlt()

bool KisConfig::switchSelectionCtrlAlt ( bool defaultValue = false) const

Definition at line 2509 of file kis_config.cc.

2510{
2511 return defaultValue ? false : m_cfg.readEntry("switchSelectionCtrlAlt", false);
2512}

References m_cfg.

◆ tabletEventsDelay()

int KisConfig::tabletEventsDelay ( bool defaultValue = false) const

Definition at line 2148 of file kis_config.cc.

2149{
2150 return (defaultValue ? 10 : m_cfg.readEntry("tabletEventsDelay", 10));
2151}

References m_cfg.

◆ testingAcceptCompressedTabletEvents()

bool KisConfig::testingAcceptCompressedTabletEvents ( bool defaultValue = false) const

Definition at line 2178 of file kis_config.cc.

2179{
2180 return (defaultValue ? false : m_cfg.readEntry("testingAcceptCompressedTabletEvents", false));
2181}

References m_cfg.

◆ testingCompressBrushEvents()

bool KisConfig::testingCompressBrushEvents ( bool defaultValue = false) const

Definition at line 2193 of file kis_config.cc.

2194{
2195 return (defaultValue ? false : m_cfg.readEntry("testingCompressBrushEvents", false));
2196}

References m_cfg.

◆ textureOverlapBorder()

int KisConfig::textureOverlapBorder ( ) const

Definition at line 1059 of file kis_config.cc.

1060{
1061 return 1 << qMax(0, numMipmapLevels());
1062}
int numMipmapLevels(bool defaultValue=false) const

References numMipmapLevels().

◆ timelineZoom()

qreal KisConfig::timelineZoom ( bool defaultValue = false) const

Definition at line 2464 of file kis_config.cc.

2465{
2466 return (defaultValue ? 1.0f : m_cfg.readEntry("timelineZoom", 1.0f));
2467}

References m_cfg.

◆ toolbarSlider()

QString KisConfig::toolbarSlider ( int sliderNumber,
bool defaultValue = false ) const

Definition at line 1891 of file kis_config.cc.

1892{
1893 QString def = "flow";
1894 if (sliderNumber == 1) {
1895 def = "opacity";
1896 }
1897 if (sliderNumber == 2) {
1898 def = "size";
1899 }
1900 return (defaultValue ? def : m_cfg.readEntry(QString("toolbarslider_%1").arg(sliderNumber), def));
1901}

References m_cfg.

◆ toolOptionsInDocker()

bool KisConfig::toolOptionsInDocker ( bool defaultValue = false) const

Definition at line 2257 of file kis_config.cc.

2258{
2259 return (defaultValue ? true : m_cfg.readEntry("ToolOptionsInDocker", true));
2260}

References m_cfg.

◆ toolOptionsPopupDetached()

bool KisConfig::toolOptionsPopupDetached ( bool defaultValue = false) const

Definition at line 1491 of file kis_config.cc.

1492{
1493 return (defaultValue ? false : m_cfg.readEntry("ToolOptionsPopupDetached", false));
1494}

References m_cfg.

◆ touchPainting()

KisConfig::TouchPainting KisConfig::touchPainting ( bool defaultValue = false) const

Definition at line 138 of file kis_config.cc.

139{
140 if (defaultValue) {
141 return TOUCH_PAINTING_AUTO;
142 } else {
143 int value = m_cfg.readEntry("touchPainting", int(TOUCH_PAINTING_AUTO));
144 return TouchPainting(value);
145 }
146}

References m_cfg, TOUCH_PAINTING_AUTO, and value().

◆ trackTabletEventLatency()

bool KisConfig::trackTabletEventLatency ( bool defaultValue = false) const

Definition at line 2158 of file kis_config.cc.

2159{
2160 return (defaultValue ? false : m_cfg.readEntry("trackTabletEventLatency", false));
2161}

References m_cfg.

◆ trimFramesImport()

bool KisConfig::trimFramesImport ( bool defaultValue = false) const

Definition at line 2238 of file kis_config.cc.

2239{
2240 return (defaultValue ? false : m_cfg.readEntry("TrimFramesImport", false));
2241}

References m_cfg.

◆ trimKra()

bool KisConfig::trimKra ( bool defaultValue = false) const

Definition at line 2228 of file kis_config.cc.

2229{
2230 return (defaultValue ? false : m_cfg.readEntry("TrimKra", false));
2231}

References m_cfg.

◆ undoEnabled()

bool KisConfig::undoEnabled ( bool defaultValue = false) const

Definition at line 179 of file kis_config.cc.

180{
181 return (defaultValue ? true : m_cfg.readEntry("undoEnabled", true));
182}

References m_cfg.

◆ undoStackLimit()

int KisConfig::undoStackLimit ( bool defaultValue = false) const

Definition at line 189 of file kis_config.cc.

190{
191 return (defaultValue ? 200 : m_cfg.readEntry("undoStackLimit", 200));
192}

References m_cfg.

◆ useBlackPointCompensation()

bool KisConfig::useBlackPointCompensation ( bool defaultValue = false) const

Definition at line 883 of file kis_config.cc.

884{
885 return (defaultValue ? true : m_cfg.readEntry("useBlackPointCompensation", true));
886}

References m_cfg.

◆ useCumulativeUndoRedo()

bool KisConfig::useCumulativeUndoRedo ( bool defaultValue = false) const

Definition at line 199 of file kis_config.cc.

200{
201 return (defaultValue ? false : m_cfg.readEntry("useCumulativeUndoRedo",false));
202}

References m_cfg.

◆ useDefaultColorSpace()

bool KisConfig::useDefaultColorSpace ( bool defaultvalue = false) const

Definition at line 299 of file kis_config.cc.

300{
301 return (defaultvalue? false: m_cfg.readEntry("useDefaultColorSpace", false));
302}

References m_cfg.

◆ useDirtyPresets()

bool KisConfig::useDirtyPresets ( bool defaultValue = false) const

Definition at line 533 of file kis_config.cc.

534{
535 return (defaultValue ? false : m_cfg.readEntry("useDirtyPresets", true));
536}

References m_cfg.

◆ useEraserBrushOpacity()

bool KisConfig::useEraserBrushOpacity ( bool defaultValue = false) const

Definition at line 554 of file kis_config.cc.

555{
556 return (defaultValue ? false : m_cfg.readEntry("useEraserBrushOpacity",false));
557}

References m_cfg.

◆ useEraserBrushSize()

bool KisConfig::useEraserBrushSize ( bool defaultValue = false) const

Definition at line 543 of file kis_config.cc.

544{
545 return (defaultValue ? false : m_cfg.readEntry("useEraserBrushSize", false));
546}

References m_cfg.

◆ useInlineLayerInfoText()

bool KisConfig::useInlineLayerInfoText ( bool defaultValue = false) const

Definition at line 2740 of file kis_config.cc.

2741{
2742 return defaultValue ? false : m_cfg.readEntry("useInlineLayerInfoText", false);
2743}

References m_cfg.

◆ useLayerSelectionCheckbox()

bool KisConfig::useLayerSelectionCheckbox ( bool defaultValue = false) const

Definition at line 2750 of file kis_config.cc.

2751{
2752 return defaultValue ? false : m_cfg.readEntry("useLayerSelectionCheckbox", true);
2753}

References m_cfg.

◆ useOcio()

bool KisConfig::useOcio ( bool defaultValue = false) const

Definition at line 1784 of file kis_config.cc.

1785{
1786#ifdef HAVE_OCIO
1787 return (defaultValue ? false : m_cfg.readEntry("Krita/Ocio/UseOcio", false));
1788#else
1789 Q_UNUSED(defaultValue);
1790 return false;
1791#endif
1792}

References m_cfg.

◆ useOpenGL()

bool KisConfig::useOpenGL ( bool defaultValue = false) const

Definition at line 994 of file kis_config.cc.

995{
996 if (defaultValue) {
997 return true;
998 }
999
1000 const QString configPath = QStandardPaths::writableLocation(QStandardPaths::GenericConfigLocation);
1001 QSettings kritarc(configPath + QStringLiteral("/kritadisplayrc"), QSettings::IniFormat);
1002
1003 return kritarc.value("OpenGLRenderer", "auto").toString() != "none";
1004}

◆ useOpenGLTextureBuffer()

bool KisConfig::useOpenGLTextureBuffer ( bool defaultValue = false) const

Definition at line 1034 of file kis_config.cc.

1035{
1036 return (defaultValue ? true : m_cfg.readEntry("useOpenGLTextureBuffer", true));
1037}

References m_cfg.

◆ useProjections()

bool KisConfig::useProjections ( bool defaultValue = false) const

Definition at line 169 of file kis_config.cc.

170{
171 return (defaultValue ? true : m_cfg.readEntry("useProjections", true));
172}

References m_cfg.

◆ useRightMiddleTabletButtonWorkaround()

bool KisConfig::useRightMiddleTabletButtonWorkaround ( bool defaultValue = false) const

Definition at line 1562 of file kis_config.cc.

1563{
1564 return (defaultValue ? false : m_cfg.readEntry("useRightMiddleTabletButtonWorkaround", false));
1565}

References m_cfg.

◆ useSystemMonitorProfile()

bool KisConfig::useSystemMonitorProfile ( bool defaultValue = false) const

Definition at line 1948 of file kis_config.cc.

1949{
1950 return (defaultValue ? false : m_cfg.readEntry("ColorManagement/UseSystemMonitorProfile", false));
1951}

References m_cfg.

◆ useWin8PointerInput()

bool KisConfig::useWin8PointerInput ( bool defaultValue = false) const

Definition at line 1522 of file kis_config.cc.

1523{
1524#ifdef Q_OS_WIN
1525 const QString configPath = QStandardPaths::writableLocation(QStandardPaths::GenericConfigLocation);
1526 QSettings kritarc(configPath + QStringLiteral("/kritadisplayrc"), QSettings::IniFormat);
1527
1528 return useWin8PointerInputNoApp(&kritarc, defaultValue);
1529#else
1530 Q_UNUSED(defaultValue);
1531 return false;
1532#endif
1533}
static bool useWin8PointerInputNoApp(QSettings *settings, bool defaultValue=false)

References useWin8PointerInputNoApp().

◆ useWin8PointerInputNoApp()

bool KisConfig::useWin8PointerInputNoApp ( QSettings * settings,
bool defaultValue = false )
static

Definition at line 1552 of file kis_config.cc.

1553{
1554 return defaultValue ? false : settings->value("useWin8PointerInput", false).toBool();
1555}

◆ useZip64()

bool KisConfig::useZip64 ( bool defaultValue = false) const

Definition at line 2690 of file kis_config.cc.

2691{
2692 return defaultValue ? false : m_cfg.readEntry("UseZip64", false);
2693}

References m_cfg.

◆ vastScrolling()

qreal KisConfig::vastScrolling ( bool defaultValue = false) const

Definition at line 1572 of file kis_config.cc.

1573{
1574 return (defaultValue ? 0.9 : m_cfg.readEntry("vastScrolling", 0.9));
1575}

References m_cfg.

◆ verticalSplitLines()

int KisConfig::verticalSplitLines ( bool defaultValue = false) const

Definition at line 1621 of file kis_config.cc.

1622{
1623 return (defaultValue ? 1 : m_cfg.readEntry("verticalSplitLines", 1));
1624}

References m_cfg.

◆ widgetStyle()

QString KisConfig::widgetStyle ( bool defaultValue = false)

Definition at line 1029 of file kis_config.cc.

1030{
1031 return (defaultValue ? "" : m_cfg.readEntry("widgetStyle", ""));
1032}

References m_cfg.

◆ workaroundX11SmoothPressureSteps()

int KisConfig::workaroundX11SmoothPressureSteps ( bool defaultValue = false) const

Definition at line 2203 of file kis_config.cc.

2204{
2205 return (defaultValue ? 0 : m_cfg.readEntry("workaroundX11SmoothPressureSteps", 0));
2206}

References m_cfg.

◆ workingColorSpace()

QString KisConfig::workingColorSpace ( bool defaultValue = false) const

Definition at line 849 of file kis_config.cc.

850{
851 return (defaultValue ? "RGBA" : m_cfg.readEntry("workingColorSpace", "RGBA"));
852}

References m_cfg.

◆ writeEntry()

template<class T >
void KisConfig::writeEntry ( const QString & name,
const T & value )
inline

Definition at line 779 of file kis_config.h.

779 {
780 m_cfg.writeEntry(name, value);
781 }

References value().

◆ writeKoColor()

void KisConfig::writeKoColor ( const QString & name,
const KoColor & color ) const

Definition at line 2798 of file kis_config.cc.

2799{
2800 QDomDocument doc = QDomDocument(name);
2801 QDomElement el = doc.createElement(name);
2802 doc.appendChild(el);
2803 color.toXML(doc, el);
2804 m_cfg.writeEntry(name, doc.toString());
2805}
void toXML(QDomDocument &doc, QDomElement &colorElt) const
Definition KoColor.cpp:304

References m_cfg, and KoColor::toXML().

◆ writeKoColors()

void KisConfig::writeKoColors ( const QString & name,
const QList< KoColor > & colors ) const

Definition at line 2828 of file kis_config.cc.

2829{
2830 QDomDocument doc = QDomDocument(name);
2831 QDomElement colorsElement = doc.createElement("colors");
2832 doc.appendChild(colorsElement);
2833
2834 // Writes like <colors><RGB ../><RGB .. /> ... </colors>
2835 Q_FOREACH(const KoColor & color, colors) {
2836 color.toXML(doc, colorsElement);
2837 }
2838 m_cfg.writeEntry(name, doc.toString());
2839}

References m_cfg, and KoColor::toXML().

◆ writeList()

template<class T >
void KisConfig::writeList ( const QString & name,
const QList< T > & value )
inline

Definition at line 784 of file kis_config.h.

784 {
785 m_cfg.writeEntry(name, value);
786 }

References value().

◆ zoomHorizontal()

bool KisConfig::zoomHorizontal ( bool defaultValue = false) const

Definition at line 2631 of file kis_config.cc.

2632{
2633 return defaultValue ? false : m_cfg.readEntry("zoomHorizontal", false);
2634}

References m_cfg.

◆ zoomMarginSize()

int KisConfig::zoomMarginSize ( bool defaultValue = false) const

Definition at line 2323 of file kis_config.cc.

2324{
2325 return (defaultValue ? 0 : m_cfg.readEntry("zoomMarginSize", 0));
2326}

References m_cfg.

◆ zoomSteps()

int KisConfig::zoomSteps ( bool defaultValue = false) const

Definition at line 2313 of file kis_config.cc.

2314{
2315 return (defaultValue ? 2 : m_cfg.readEntry("zoomSteps", 2));
2316}

References m_cfg.

Member Data Documentation

◆ m_cfg

KConfigGroup KisConfig::m_cfg
mutableprivate

Definition at line 807 of file kis_config.h.

◆ m_readOnly

bool KisConfig::m_readOnly
private

Definition at line 808 of file kis_config.h.


The documentation for this class was generated from the following files: