diff --git a/brightnessdialog.cpp b/brightnessdialog.cpp index d9883ba..34b9ab1 100644 --- a/brightnessdialog.cpp +++ b/brightnessdialog.cpp @@ -29,7 +29,7 @@ brightnessDialog::brightnessDialog(QWidget *parent) : value = brightness_checkconfig(".config/03-brightness/config"); } else { - ; + value = get_brightness(); } // Setting the slider to the appropriate position @@ -71,7 +71,7 @@ brightnessDialog::brightnessDialog(QWidget *parent) : oldValue = brightness_checkconfig(".config/03-brightness/config"); } else { - ; + oldValue = get_brightness(); } } @@ -135,7 +135,10 @@ void brightnessDialog::pre_set_brightness(int brightnessValue) { if(global::isN705 == true or global::isN905C == true) { set_brightness(brightnessValue); } - else { + else if(global::isN613 == true) { set_brightness_ntxio(brightnessValue); } + else { + set_brightness(brightnessValue); + } } diff --git a/koboxappsdialog.cpp b/koboxappsdialog.cpp index 1cfc1f1..1a92624 100644 --- a/koboxappsdialog.cpp +++ b/koboxappsdialog.cpp @@ -97,7 +97,7 @@ void koboxAppsDialog::on_launchBtn_clicked() // DPI setting string_checkconfig(".config/00-kobox/dpiSetting"); if(checkconfig_str_val == "") { - string_checkconfig_ro("/opt/inkbox_device\n"); + string_checkconfig_ro("/opt/inkbox_device"); if(checkconfig_str_val == "n705\n" or checkconfig_str_val == "n905\n") { dpiSetting = "125"; } diff --git a/mainwindow.cpp b/mainwindow.cpp index b6d4c65..269fd1d 100644 --- a/mainwindow.cpp +++ b/mainwindow.cpp @@ -90,6 +90,14 @@ MainWindow::MainWindow(QWidget *parent) homeIconWidth = sW / 18.5; homeIconHeight = sW / 18.5; } + else { + stdIconWidth = sW / 14; + stdIconHeight = sH / 14; + brightnessIconWidth = sW / 26; + brightnessIconHeight = sH / 26; + homeIconWidth = sW / 20; + homeIconHeight = sW / 20; + } // Setting icons up ui->pushButton->setIcon(QIcon(":/resources/book.png")); diff --git a/reader.cpp b/reader.cpp index dbb9077..4f81e49 100644 --- a/reader.cpp +++ b/reader.cpp @@ -87,6 +87,9 @@ reader::reader(QWidget *parent) : int id = QFontDatabase::addApplicationFont(":/resources/fonts/CrimsonPro-Italic.ttf"); QString family = QFontDatabase::applicationFontFamilies(id).at(0); QFont crimson(family); + int id_1 = QFontDatabase::addApplicationFont(":/resources/fonts/CrimsonPro-Bold.ttf"); + QString family_1 = QFontDatabase::applicationFontFamilies(id).at(0); + QFont crimson_1(family_1); // Custom settings // Font @@ -164,7 +167,7 @@ reader::reader(QWidget *parent) : brightness_value = brightness_checkconfig(".config/03-brightness/config"); } else { - ; + brightness_value = get_brightness(); } ui->brightnessStatus->setValue(brightness_value); @@ -175,7 +178,7 @@ reader::reader(QWidget *parent) : // Defining what the icons' size will be if(checkconfig("/opt/inkbox_genuine") == true) { string_checkconfig_ro("/opt/inkbox_device"); - if(checkconfig_str_val == "n705\n" or checkconfig_str_val == "n905\n") { + if(checkconfig_str_val == "n705\n" or checkconfig_str_val == "n905\n" or checkconfig_str_val == "n613\n") { float stdIconWidth = sW / 16; float stdIconHeight = sW / 16; QPixmap chargingPixmap(":/resources/battery_charging.png"); @@ -829,7 +832,7 @@ void reader::on_brightnessDecBtn_clicked() bval = brightness_checkconfig(".config/03-brightness/config"); } else { - ; + bval = get_brightness(); } int set_bval = bval - 1; if(set_bval < 0) { @@ -838,7 +841,6 @@ void reader::on_brightnessDecBtn_clicked() pre_set_brightness(set_bval); brightness_writeconfig(set_bval); - bval = get_brightness(); ui->brightnessStatus->setValue(set_bval); } @@ -853,7 +855,7 @@ void reader::on_brightnessIncBtn_clicked() bval = brightness_checkconfig(".config/03-brightness/config"); } else { - ; + bval = get_brightness(); } int set_bval = bval + 1; if(set_bval > 100) { @@ -1391,14 +1393,17 @@ void reader::on_nightModeBtn_clicked() void reader::pre_set_brightness(int brightnessValue) { if(deviceChecked == false) { - checkDevice(); + string_checkconfig_ro("/opt/inkbox_device"); deviceChecked = true; } - if(device == "n705\n" or device == "n905\n") { + if(checkconfig_str_val == "n705\n" or checkconfig_str_val == "n905\n") { set_brightness(brightnessValue); } - else { + else if(checkconfig_str_val == "n613\n") { set_brightness_ntxio(brightnessValue); } + else { + set_brightness(brightnessValue); + } }