Skip to content

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

C

function editor zig zag line color

konero7dbdde0dac21
diff --git a/toonz/sources/include/toonzqt/spreadsheetviewer.h b/toonz/sources/include/toonzqt/spreadsheetviewer.h
index 66438ca04..70d29f002 100644
--- a/toonz/sources/include/toonzqt/spreadsheetviewer.h
+++ b/toonz/sources/include/toonzqt/spreadsheetviewer.h
@@ -239,6 +239,7 @@ class DVAPI SpreadsheetViewer : public QDialog {
QColor m_secMarkerLineColor; // second marker lines
QColor m_textColor; // text (black)
QColor m_currentRowTextColor; // text color for the current row
+ QColor m_cycleColor; // color of zig zag line
QColor m_verticalLineColor; // vertical line (black)
Q_PROPERTY(QColor CurrentRowBgColor READ getCurrentRowBgColor WRITE
@@ -250,6 +251,7 @@ class DVAPI SpreadsheetViewer : public QDialog {
Q_PROPERTY(QColor TextColor READ getTextColor WRITE setTextColor)
Q_PROPERTY(QColor CurrentRowTextColor READ getCurrentRowTextColor WRITE
setCurrentRowTextColor)
+ Q_PROPERTY(QColor CycleColor READ getCycleColor WRITE setCycleColor)
Q_PROPERTY(QColor VerticalLineColor READ getVerticalLineColor WRITE
setVerticalLineColor)
@@ -367,6 +369,8 @@ public:
m_currentRowTextColor = color;
}
QColor getCurrentRowTextColor() const { return m_currentRowTextColor; }
+ void setCycleColor(const QColor &color) { m_cycleColor = color; }
+ QColor getCycleColor() const { return m_cycleColor; }
void setVerticalLineColor(const QColor &color) {
m_verticalLineColor = color;
}
diff --git a/toonz/sources/toonzqt/functionsheet.cpp b/toonz/sources/toonzqt/functionsheet.cpp
index 6cf78badf..09d9f0235 100644
--- a/toonz/sources/toonzqt/functionsheet.cpp
+++ b/toonz/sources/toonzqt/functionsheet.cpp
@@ -880,7 +880,7 @@ void FunctionSheetCellViewer::drawCells(QPainter &painter, int r0, int c0,
int qx = x0 + 4;
int qy = m_sheet->rowToY(kr1 + 1);
int zig = 2;
- QColor zigzagColor = (isStageObjectCycled) ? getViewer()->getTextColor()
+ QColor zigzagColor = (isStageObjectCycled) ? getViewer()->getCycleColor()
: KeyFrameBorderColor;
painter.setPen(zigzagColor);
painter.drawLine(QPoint(qx, qy), QPoint(qx - zig, qy + zig));