MCPcopy Create free account
hub / github.com/KDE/labplot / themes

Method themes

src/frontend/ThemeHandler.cpp:98–116  ·  view source on GitHub ↗

! * get list of all theme names */

Source from the content-addressed store, hash-verified

96 * get list of all theme names
97 */
98QStringList ThemeHandler::themes() {
99 DEBUG(Q_FUNC_INFO);
100 QStringList themePaths = themeList();
101
102 QStringList themes;
103 for (int i = 0; i < themePaths.size(); ++i) {
104 QFileInfo fileinfo(themePaths.at(i));
105 themes.append(fileinfo.fileName().split(QLatin1Char('.')).at(0));
106 }
107
108 if (!themes.isEmpty()) {
109 DEBUG(" first theme: " << STDSTRING(themes.first()));
110 QDEBUG(" themes = " << themes);
111 }
112
113 themes.sort();
114
115 return themes;
116}
117
118/*!
119 * get path for theme of name 'name'

Callers

nothing calls this directly

Calls 6

appendMethod · 0.80
splitMethod · 0.80
sortMethod · 0.80
sizeMethod · 0.45
fileNameMethod · 0.45
isEmptyMethod · 0.45

Tested by

no test coverage detected