Skip to content
Snippets Groups Projects
Unverified Commit a2ef9f1e authored by Kali Kaneko's avatar Kali Kaneko
Browse files

[ui] use configuration file

parent 0efd19b9
No related branches found
No related tags found
No related merge requests found
......@@ -9,8 +9,9 @@ ThemedPage {
Column {
id: prefCol
// FIXME the checkboxes seem to have a bigger lineHeight themselves, need to pack more.
spacing: 1
// FIXME checkboxes in Material style force lineHeights too big.
// need to override the style
// See: https://bugreports.qt.io/browse/QTBUG-95385
topPadding: root.width * 0.05
leftPadding: root.width * 0.1
rightPadding: root.width * 0.15
......
......@@ -2,6 +2,7 @@
<qresource prefix="/">
<file>main.qml</file>
<file>qtquickcontrols2.conf</file>
<!-- gui components -->
<file>themes/themes.js</file>
......
......@@ -173,6 +173,7 @@ int main(int argc, char **argv) {
QJsonModel *model = new QJsonModel;
// FIXME use qgetenv
QString desktop = QString::fromStdString(getEnv("XDG_CURRENT_DESKTOP"));
QString debug = QString::fromStdString(getEnv("DEBUG"));
......@@ -190,7 +191,10 @@ int main(int argc, char **argv) {
ctx->setContextProperty("systrayAvailable", availableSystray);
ctx->setContextProperty("qmlDebug", debug == "1");
QQuickStyle::setStyle("Material");
//XXX we're doing configuration via config file, but this is a mechanism
//to change to Dark Theme if desktop has it.
//qputenv("QT_QUICK_CONTROLS_MATERIAL_VARIANT", "Dense");
//QQuickStyle::setStyle("Material");
engine.load(QUrl(QStringLiteral("qrc:/main.qml")));
/* connect the jsonChanged signal explicitely.
......
[Controls]
Style=Material
[Material]
Theme=Light
Variant=Dense
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment