mirror of
https://github.com/YACReader/yacreader
synced 2025-07-23 07:24:58 -04:00
added 'add new label' support
This commit is contained in:
@ -27,3 +27,34 @@ QAction * YACReader::createSeparator()
|
||||
a->setSeparator(true);
|
||||
return a;
|
||||
}
|
||||
|
||||
|
||||
QString YACReader::colorToName(LabelColors colors)
|
||||
{
|
||||
switch(colors){
|
||||
case 0:
|
||||
return "red";
|
||||
case 1:
|
||||
return "orange";
|
||||
case 2:
|
||||
return "yellow";
|
||||
case 3:
|
||||
return "green";
|
||||
case 4:
|
||||
return "cyan";
|
||||
case 5:
|
||||
return "blue";
|
||||
case 6:
|
||||
return "violet";
|
||||
case 7:
|
||||
return "purple";
|
||||
case 8:
|
||||
return "pink";
|
||||
case 9:
|
||||
return "white";
|
||||
case 10:
|
||||
return "light";
|
||||
case 11:
|
||||
return "dark";
|
||||
}
|
||||
}
|
||||
|
@ -112,9 +112,25 @@ namespace YACReader
|
||||
ByAuthor
|
||||
};
|
||||
|
||||
enum LabelColors{
|
||||
YRed = 0,
|
||||
YOrange,
|
||||
YYellow,
|
||||
YGreen,
|
||||
YCyan,
|
||||
YBlue,
|
||||
YViolet,
|
||||
YPurple,
|
||||
YPink,
|
||||
YWhite,
|
||||
YLight,
|
||||
YDark
|
||||
};
|
||||
|
||||
QString getSettingsPath();
|
||||
void addSperator(QWidget * w);
|
||||
QAction * createSeparator();
|
||||
QString colorToName(LabelColors colors);
|
||||
}
|
||||
#endif
|
||||
|
||||
|
Reference in New Issue
Block a user