profile: rename GF_LINE color to DURATION_LINE

The color was misnamed, since it has only been used for the
duration line for quite some time (since 893bea700c to be
exact).

Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
Berthold Stoeger 2021-05-08 13:06:49 +02:00 committed by Robert C. Helling
parent a7002f4089
commit dc645ce8c6
3 changed files with 3 additions and 3 deletions

View file

@ -65,7 +65,7 @@ static QMap<color_index_t, std::array<QColor, 2>> profile_color = {
{ CALC_CEILING_SHALLOW, {{ FUNGREEN1_HIGH_TRANS, BLACK1_HIGH_TRANS }} },
{ CALC_CEILING_DEEP, {{ APPLE1_HIGH_TRANS, BLACK1_HIGH_TRANS }} },
{ TISSUE_PERCENTAGE, {{ GOVERNORBAY2, BLACK1_LOW_TRANS }} },
{ GF_LINE, {{ BLACK1, BLACK1_LOW_TRANS }} }
{ DURATION_LINE, {{ BLACK1, BLACK1_LOW_TRANS }} }
};
QColor getColor(const color_index_t i, bool isGrayscale)

View file

@ -135,7 +135,7 @@ typedef enum {
CALC_CEILING_SHALLOW,
CALC_CEILING_DEEP,
TISSUE_PERCENTAGE,
GF_LINE
DURATION_LINE
} color_index_t;
QColor getColor(const color_index_t i, bool isGrayscale = false);

View file

@ -1910,7 +1910,7 @@ void ProfileWidget2::updateDurationLine(PictureEntry &e)
double durationLineWidth = unscaledDurationLineWidth / scale;
double durationLinePenWidth = unscaledDurationLinePenWidth / scale;
e.durationLine.reset(new QGraphicsRectItem(begin, y - durationLineWidth - durationLinePenWidth, end - begin, durationLineWidth));
e.durationLine->setPen(QPen(getColor(GF_LINE, isGrayscale), durationLinePenWidth));
e.durationLine->setPen(QPen(getColor(DURATION_LINE, isGrayscale), durationLinePenWidth));
e.durationLine->setBrush(getColor(::BACKGROUND, isGrayscale));
e.durationLine->setVisible(prefs.show_pictures_in_profile);
scene()->addItem(e.durationLine.get());