Paste P252

Masterwork From Distant Lands
ActivePublic

Authored by dkazakov on Aug 20 2018, 8:04 AM.
diff --git a/libs/ui/kis_node_view_color_scheme.cpp b/libs/ui/kis_node_view_color_scheme.cpp
index 7f402c1..d4b59af 100644
--- a/libs/ui/kis_node_view_color_scheme.cpp
+++ b/libs/ui/kis_node_view_color_scheme.cpp
@@ -87,7 +87,7 @@ int KisNodeViewColorScheme::visibilityMargin() const
}
-int KisNodeViewColorScheme::thumbnailSize()
+int KisNodeViewColorScheme::thumbnailSize() const
{
KisConfig cfg(true);
return cfg.layerThumbnailSize(false);
@@ -130,7 +130,7 @@ int KisNodeViewColorScheme::border() const
return 1;
}
-int KisNodeViewColorScheme::rowHeight()
+int KisNodeViewColorScheme::rowHeight() const
{
return border() + 2 * thumbnailMargin() + thumbnailSize();
}
@@ -142,14 +142,14 @@ int KisNodeViewColorScheme::visibilityColumnWidth() const
border();
}
-int KisNodeViewColorScheme::indentation()
+int KisNodeViewColorScheme::indentation() const
{
return
2 * thumbnailMargin() + thumbnailSize() +
border();
}
-QRect KisNodeViewColorScheme::relThumbnailRect()
+QRect KisNodeViewColorScheme::relThumbnailRect() const
{
return QRect(-indentation(),
border(),
@@ -165,7 +165,7 @@ QRect KisNodeViewColorScheme::relDecorationRect() const
decorationSize());
}
-QRect KisNodeViewColorScheme::relExpandButtonRect()
+QRect KisNodeViewColorScheme::relExpandButtonRect() const
{
const int newY = rowHeight() - decorationMargin() - decorationSize();
QRect rc = relDecorationRect();
diff --git a/libs/ui/kis_node_view_color_scheme.h b/libs/ui/kis_node_view_color_scheme.h
index c290a89..ef96293 100644
--- a/libs/ui/kis_node_view_color_scheme.h
+++ b/libs/ui/kis_node_view_color_scheme.h
@@ -41,7 +41,7 @@ public:
int visibilitySize() const;
int visibilityMargin() const;
- int thumbnailSize();
+ int thumbnailSize() const;
int thumbnailMargin() const;
int decorationSize() const;
@@ -54,13 +54,13 @@ public:
int border() const;
- int rowHeight();
+ int rowHeight() const;
int visibilityColumnWidth() const;
- int indentation();
+ int indentation() const;
- QRect relThumbnailRect();
+ QRect relThumbnailRect() const;
QRect relDecorationRect() const;
- QRect relExpandButtonRect();
+ QRect relExpandButtonRect() const;
QColor colorLabel(int index) const;
QVector<QColor> allColorLabels() const;
dkazakov edited the content of this paste. (Show Details)Aug 20 2018, 8:04 AM
dkazakov changed the title of this paste from untitled to Masterwork From Distant Lands.