Skip to content

OpenToonz - An open-source full-featured 2D animation creation software

C

Update toonz/sources/toonzqt/styleeditor.cpp

shun-iwasawa16effcc4a657
diff --git a/toonz/sources/toonzqt/styleeditor.cpp b/toonz/sources/toonzqt/styleeditor.cpp
index d6a7a3aeb..99533969f 100644
--- a/toonz/sources/toonzqt/styleeditor.cpp
+++ b/toonz/sources/toonzqt/styleeditor.cpp
@@ -1274,6 +1274,7 @@ void ColorSlider::paintEvent(QPaintEvent *event) {
h -= 2;
}
}
+ if (w < 2 || h < 2) return;
QPixmap bgPixmap =
makeLinearShading(m_color, m_channel, isVertical ? h : w, isVertical);