ソースを参照

updated settings widget and pilotwidget

fiffty-50 4 年 前
コミット
d6aa15bfba

BIN
assets/database/logbook.db


+ 5 - 5
src/gui/dialogues/firstrundialog.cpp

@@ -57,21 +57,21 @@ void FirstRunDialog::on_finishButton_clicked()
         settings.setValue("flightlogging/function", ui->functionComboBox->currentText());
         settings.setValue("flightlogging/rules", ui->rulesComboBox->currentText());
         settings.setValue("flightlogging/approach", ui->approachComboBox->currentText());
-        settings.setValue("flightlogging/nightlogging", ui->functionComboBox->currentIndex());
+        settings.setValue("flightlogging/nightlogging", ui->nightComboBox->currentIndex());
         settings.setValue("flightlogging/flightnumberPrefix", ui->prefixLineEdit->text());
 
         QMap<QString,QString> data;
         switch (ui->aliasComboBox->currentIndex()) {
         case 0:
-            settings.setValue("userdata/displayselfas","self");
+            settings.setValue("userdata/displayselfas",ui->aliasComboBox->currentIndex());
             data.insert("displayname","self");
             break;
         case 1:
-            settings.setValue("userdata/displayselfas","SELF");
+            settings.setValue("userdata/displayselfas",ui->aliasComboBox->currentIndex());
             data.insert("displayname","SELF");
             break;
         case 2:{
-            settings.setValue("userdata/displayselfas","Last,F.");
+            settings.setValue("userdata/displayselfas",ui->aliasComboBox->currentIndex());
             QString name;
             name.append(ui->piclastnameLineEdit->text());
             name.append(QLatin1String(", "));
@@ -89,7 +89,7 @@ void FirstRunDialog::on_finishButton_clicked()
         data.insert("phone",ui->phoneLineEdit->text());
         data.insert("email",ui->emailLineEdit->text());
 
-        Pilot pic("pilots",1);
+        Pilot pic(1);
         pic.setData(data);
         pic.commit();
         accept();

+ 1 - 1
src/gui/dialogues/firstrundialog.ui

@@ -395,7 +395,7 @@
        <item row="0" column="0" colspan="2">
         <widget class="QLabel" name="label_4">
          <property name="text">
-          <string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p align=&quot;center&quot;&gt;&lt;span style=&quot; font-size:16pt;&quot;&gt;Finish&lt;/span&gt;&lt;/p&gt;&lt;p align=&quot;center&quot;&gt;&lt;br/&gt;Almost done! Here you can select the theme to be used for the application.&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
+          <string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p align=&quot;center&quot;&gt;&lt;span style=&quot; font-size:16pt;&quot;&gt;Finish&lt;/span&gt;&lt;/p&gt;&lt;p align=&quot;center&quot;&gt;&lt;br/&gt;Almost done! Here you can select the theme to be used for the application.&lt;/p&gt;&lt;p align=&quot;center&quot;&gt;This change will take effect the next time the application is launched.&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
          </property>
          <property name="textFormat">
           <enum>Qt::RichText</enum>

+ 47 - 33
src/gui/dialogues/newpilot.ui

@@ -14,13 +14,6 @@
    <string>Dialog</string>
   </property>
   <layout class="QGridLayout" name="gridLayout">
-   <item row="4" column="1">
-    <widget class="QLineEdit" name="phoneLineEdit">
-     <property name="maxLength">
-      <number>40</number>
-     </property>
-    </widget>
-   </item>
    <item row="0" column="0">
     <widget class="QLabel" name="picfirstnameLabel">
      <property name="text">
@@ -28,80 +21,101 @@
      </property>
     </widget>
    </item>
-   <item row="4" column="0">
-    <widget class="QLabel" name="phoneLabel">
+   <item row="0" column="1">
+    <widget class="QLineEdit" name="picfirstnameLineEdit">
+     <property name="maxLength">
+      <number>40</number>
+     </property>
+    </widget>
+   </item>
+   <item row="1" column="0">
+    <widget class="QLabel" name="piclastnameLabel">
      <property name="text">
-      <string>Phone</string>
+      <string>Last Name</string>
      </property>
     </widget>
    </item>
-   <item row="5" column="1">
-    <widget class="QLineEdit" name="emailLineEdit">
+   <item row="1" column="1">
+    <widget class="QLineEdit" name="piclastnameLineEdit">
      <property name="maxLength">
       <number>40</number>
      </property>
     </widget>
    </item>
    <item row="2" column="0">
-    <widget class="QLabel" name="aliasLabel">
+    <widget class="QLabel" name="companyLabel">
      <property name="text">
-      <string>Alias</string>
+      <string>Company</string>
      </property>
     </widget>
    </item>
-   <item row="5" column="0">
-    <widget class="QLabel" name="emailLabel">
-     <property name="text">
-      <string>eMail</string>
+   <item row="2" column="1">
+    <widget class="QLineEdit" name="companyLineEdit">
+     <property name="maxLength">
+      <number>40</number>
      </property>
     </widget>
    </item>
    <item row="3" column="0">
-    <widget class="QLabel" name="employeeidLabel">
+    <widget class="QLabel" name="aliasLabel">
      <property name="text">
-      <string>Employee ID</string>
+      <string>Alias</string>
      </property>
     </widget>
    </item>
-   <item row="1" column="1">
-    <widget class="QLineEdit" name="piclastnameLineEdit">
+   <item row="3" column="1">
+    <widget class="QLineEdit" name="aliasLineEdit">
      <property name="maxLength">
       <number>40</number>
      </property>
     </widget>
    </item>
-   <item row="0" column="1">
-    <widget class="QLineEdit" name="picfirstnameLineEdit">
+   <item row="4" column="0">
+    <widget class="QLabel" name="employeeidLabel">
+     <property name="text">
+      <string>Employee ID</string>
+     </property>
+    </widget>
+   </item>
+   <item row="4" column="1">
+    <widget class="QLineEdit" name="employeeidLineEdit">
+     <property name="text">
+      <string/>
+     </property>
      <property name="maxLength">
       <number>40</number>
      </property>
     </widget>
    </item>
-   <item row="1" column="0">
-    <widget class="QLabel" name="piclastnameLabel">
+   <item row="5" column="0">
+    <widget class="QLabel" name="phoneLabel">
      <property name="text">
-      <string>Last Name</string>
+      <string>Phone</string>
      </property>
     </widget>
    </item>
-   <item row="2" column="1">
-    <widget class="QLineEdit" name="aliasLineEdit">
+   <item row="5" column="1">
+    <widget class="QLineEdit" name="phoneLineEdit">
      <property name="maxLength">
       <number>40</number>
      </property>
     </widget>
    </item>
-   <item row="3" column="1">
-    <widget class="QLineEdit" name="employeeidLineEdit">
+   <item row="6" column="0">
+    <widget class="QLabel" name="emailLabel">
      <property name="text">
-      <string/>
+      <string>eMail</string>
      </property>
+    </widget>
+   </item>
+   <item row="6" column="1">
+    <widget class="QLineEdit" name="emailLineEdit">
      <property name="maxLength">
       <number>40</number>
      </property>
     </widget>
    </item>
-   <item row="6" column="0" colspan="2">
+   <item row="7" column="0" colspan="2">
     <widget class="QDialogButtonBox" name="buttonBox">
      <property name="orientation">
       <enum>Qt::Horizontal</enum>

+ 2 - 2
src/gui/widgets/pilotswidget.cpp

@@ -110,8 +110,8 @@ void PilotsWidget::refreshView()
     view->setEditTriggers(QAbstractItemView::NoEditTriggers);
     view->horizontalHeader()->setStretchLastSection(QHeaderView::Stretch);
     view->setColumnWidth(0, 60);
-    view->setColumnWidth(1, 240);
-    view->setColumnWidth(2, 180);
+    view->setColumnWidth(1, 180);
+    view->setColumnWidth(2, 120);
     view->verticalHeader()->hide();
     view->setAlternatingRowColors(true);
     view->setSortingEnabled(true);

+ 183 - 48
src/gui/widgets/settingswidget.cpp

@@ -19,6 +19,10 @@
 #include "ui_settingswidget.h"
 #include "src/database/dbinfo.h"
 
+// Debug Makro
+#define DEB(expr) \
+    qDebug() << __PRETTY_FUNCTION__ << "\t" << expr
+
 
 
 SettingsWidget::SettingsWidget(QWidget *parent) :
@@ -27,18 +31,46 @@ SettingsWidget::SettingsWidget(QWidget *parent) :
 {
     ui->setupUi(this);
     ui->tabWidget->setCurrentIndex(0);
-    QSettings settings;
 
-    /*
-     * General Tab
-     */
     auto *themeGroup = new QButtonGroup;
     themeGroup->addButton(ui->systemThemeCheckBox, 0);
     themeGroup->addButton(ui->lightThemeCheckBox, 1);
     themeGroup->addButton(ui->darkThemeCheckBox, 2);
     connect(themeGroup, SIGNAL(buttonClicked(int)), this, SLOT(themeGroup_toggled(int)));
 
+    fillSettings();
+    setupValidators();
+
+}
 
+SettingsWidget::~SettingsWidget()
+{
+    delete ui;
+}
+
+void SettingsWidget::fillSettings()
+{
+    QSettings settings;
+    /*
+     * Personal Tab
+     */
+    ui->piclastnameLineEdit->setText(settings.value("userdata/piclastname").toString());
+    ui->picfirstnameLineEdit->setText(settings.value("userdata/picfirstname").toString());
+    ui->employeeidLineEdit->setText(settings.value("userdata/employeeid").toString());
+    ui->phoneLineEdit->setText(settings.value("userdata/phone").toString());
+    ui->emailLineEdit->setText(settings.value("userdata/email").toString());
+    /*
+     * Flight Logging Tab
+     */
+    ui->aliasComboBox->setCurrentIndex(settings.value("userdata/displayselfas").toInt());
+    ui->functionComboBox->setCurrentText(settings.value("flightlogging/function").toString());
+    ui->rulesComboBox->setCurrentText(settings.value("flightlogging/rules").toString());
+    ui->approachComboBox->setCurrentText(settings.value("flightlogging/approach").toString());
+    ui->nightComboBox->setCurrentIndex(settings.value("flightlogging/nightlogging").toInt());
+    ui->prefixLineEdit->setText(settings.value("flightlogging/flightnumberPrefix").toString());
+    /*
+     * Theme Group
+     */
     switch (settings.value("main/theme").toInt()) {
     case 0:
         ui->systemThemeCheckBox->setChecked(true);
@@ -50,39 +82,131 @@ SettingsWidget::SettingsWidget(QWidget *parent) :
         ui->darkThemeCheckBox->setChecked(true);
     }
     /*
-     * Flight Logging Tab
+     * Aircraft Tab
      */
-    //QString storedPrefix = db::singleSelect("setting","settings","setting_id","50",sql::exactMatch);
-    QString storedPrefix = settings.value("flightlogging/flightnumberPrefix").toString();
-    if (storedPrefix.length() != 0) {
-        ui->flightNumberPrefixLineEdit->setText(storedPrefix);
-    }
+    ui->acSortComboBox->setCurrentIndex(settings.value("userdata/acSortColumn").toInt());
+    ui->pilotSortComboBox->setCurrentIndex(settings.value("userdata/pilSortColumn").toInt());
+    ui->acAllowIncompleteComboBox->setCurrentIndex(settings.value("userdata/acAllowIncomplete").toInt());
+}
 
+void SettingsWidget::setupValidators()
+{
     QRegExp flightNumberPrefix_rx("[a-zA-Z0-9]?[a-zA-Z0-9]?[a-zA-Z0-9]"); // allow max 3 letters (upper and lower) and numbers
     QValidator *flightNumberPrefixValidator = new QRegExpValidator(flightNumberPrefix_rx, this);
-    ui->flightNumberPrefixLineEdit->setValidator(flightNumberPrefixValidator);
-    /*
-     * Aircraft Tab
-     */
-    ui->acSortComboBox->setCurrentIndex(settings.value("userdata/acSortColumn").toInt());
+    ui->prefixLineEdit->setValidator(flightNumberPrefixValidator);
+}
 
+/*
+ * Slots
+ */
+
+
+/*
+ * Personal Tab
+ */
+
+void SettingsWidget::on_piclastnameLineEdit_editingFinished()
+{
+    QSettings settings;
+    if(ui->piclastnameLineEdit->text().isEmpty()){
+        ui->piclastnameLineEdit->setText(settings.value("userdata/piclastname").toString());
+        ui->piclastnameLineEdit->setFocus();
+    } else {
+        settings.setValue("userdata/piclastname",ui->piclastnameLineEdit->text());
+    }
 }
 
-SettingsWidget::~SettingsWidget()
+void SettingsWidget::on_picfirstnameLineEdit_editingFinished()
 {
-    delete ui;
+    QSettings settings;
+    if(ui->picfirstnameLineEdit->text().isEmpty()){
+        ui->picfirstnameLineEdit->setText(settings.value("userdata/picfirstname").toString());
+        ui->picfirstnameLineEdit->setFocus();
+    } else {
+        settings.setValue("userdata/picfirstname",ui->picfirstnameLineEdit->text());
+    }
+}
+
+void SettingsWidget::on_employeeidLineEdit_editingFinished()
+{
+    QSettings settings;
+    settings.setValue("userdata/employeeid",ui->employeeidLineEdit->text());
+}
+
+void SettingsWidget::on_emailLineEdit_editingFinished()
+{
+    QSettings settings;
+    settings.setValue("userdata/email",ui->emailLineEdit->text());
+}
+
+void SettingsWidget::on_phoneLineEdit_editingFinished()
+{
+    QSettings settings;
+    settings.setValue("userdata/phone",ui->phoneLineEdit->text());
 }
 
 /*
- * Slots
+ * Flight Logging Tab
  */
 
-void SettingsWidget::on_flightNumberPrefixLineEdit_textEdited(const QString &arg1)
+void SettingsWidget::on_aliasComboBox_currentIndexChanged(int index)
+{
+    QSettings settings;
+    settings.setValue("userdata/displayselfas",index);
+    /*QSettings settings;
+    switch (index) {
+    case 0:
+        settings.setValue("userdata/displayselfas","self");
+        break;
+    case 1:
+        settings.setValue("userdata/displayselfas","SELF");
+        break;
+    default:
+        settings.setValue("userdata/displayselfas","Last,F.");
+    }*/
+}
+
+void SettingsWidget::on_functionComboBox_currentIndexChanged(const QString &arg1)
+{
+    QSettings settings;
+    settings.setValue("flightlogging/function", arg1);
+}
+
+void SettingsWidget::on_rulesComboBox_currentIndexChanged(const QString &arg1)
+{
+    QSettings settings;
+    settings.setValue("flightlogging/rules", arg1);
+}
+
+void SettingsWidget::on_approachComboBox_currentIndexChanged(const QString &arg1)
+{
+    QSettings settings;
+    settings.setValue("flightlogging/approach", arg1);
+}
+
+void SettingsWidget::on_nightComboBox_currentIndexChanged(int index)
+{
+    if(index == 2){
+        auto mb = new QMessageBox(this);
+        mb->setText("This option is not yet available.");
+        mb->show();
+        ui->nightComboBox->setCurrentIndex(0);
+    } else {
+        QSettings settings;
+        settings.setValue("flightlogging/nightlogging", index);
+    }
+
+}
+
+void SettingsWidget::on_prefixLineEdit_textChanged(const QString &arg1)
 {
     QSettings settings;
     settings.setValue("flightlogging/flightnumberPrefix", arg1);
 }
 
+/*
+ * Misc Tab
+ */
 void SettingsWidget::themeGroup_toggled(int id)
 {
     QSettings settings;
@@ -104,6 +228,46 @@ void SettingsWidget::themeGroup_toggled(int id)
     }
 }
 
+void SettingsWidget::on_pilotSortComboBox_currentIndexChanged(int index)
+{
+    QSettings settings;
+    settings.setValue("userdata/pilSortColumn", index);
+}
+
+void SettingsWidget::on_acSortComboBox_currentIndexChanged(int index)
+{
+    QSettings settings;
+    settings.setValue("userdata/acSortColumn", index);
+}
+
+void SettingsWidget::on_acAllowIncompleteComboBox_currentIndexChanged(int index)
+{
+    QSettings settings;
+    settings.setValue("userdata/acAllowIncomplete", index);
+    if (index) {
+        QMessageBox::StandardButton reply;
+        reply = QMessageBox::warning(this, "Warning",
+                                      "Enabling incomplete logging will enable you to add aircraft with incomplete data.\n\n"
+                                      "If you do not fill out the aircraft details, "
+                                      "it will be impossible to automatically determine Single/Multi Pilot Times or Single/Multi Engine Time."
+                                      "This will also impact statistics and auto-logging capabilites as well as jeopardise database integrity.\n\n"
+                                      "It is highly recommended to keep this option off unless you have a specific reason not to.\n\n"
+                                      "Are you sure you want to proceed?",
+                                      QMessageBox::Yes | QMessageBox::No);
+        if (reply == QMessageBox::Yes) {
+            QSettings settings;
+            settings.setValue("userdata/acAllowIncomplete", index);
+        } else {
+            ui->acAllowIncompleteComboBox->setCurrentIndex(0);
+        }
+    }
+}
+
+/*
+ * About Tab
+ */
+
+
 void SettingsWidget::on_aboutPushButton_clicked()
 {
     auto mb = new QMessageBox(this);
@@ -142,32 +306,3 @@ void SettingsWidget::on_aboutPushButton_clicked()
     mb->setText(text);
     mb->open();
 }
-
-void SettingsWidget::on_acSortComboBox_currentIndexChanged(int index)
-{
-    QSettings settings;
-    settings.setValue("userdata/acSortColumn", index);
-}
-
-void SettingsWidget::on_acAllowIncompleteComboBox_currentIndexChanged(int index)
-{
-    QSettings settings;
-    settings.setValue("userdata/acAllowIncomplete", index);
-    if (index) {
-        QMessageBox::StandardButton reply;
-        reply = QMessageBox::question(this, "Warning",
-                                      "Warning: Enabling incomplete logging will enable you to add aircraft with incomplete data.\n\n"
-                                      "If you do not fill out the aircraft details, "
-                                      "it will be impossible to automatically determine Single/Multi Pilot Times or Single/Multi Engine Time."
-                                      "This will also impact statistics and auto-logging capabilites.\n\n"
-                                      "It is highly recommended to keep this option off unless you have a specific reason not to.\n\n"
-                                      "Are you sure you want to proceed?",
-                                      QMessageBox::Yes | QMessageBox::No);
-        if (reply == QMessageBox::Yes) {
-            QSettings settings;
-            settings.setValue("userdata/acAllowIncomplete", index);
-        } else {
-            ui->acAllowIncompleteComboBox->setCurrentIndex(0);
-        }
-    }
-}

+ 27 - 1
src/gui/widgets/settingswidget.h

@@ -41,7 +41,6 @@ public:
     ~SettingsWidget();
 
 private slots:
-    void on_flightNumberPrefixLineEdit_textEdited(const QString &arg1);
 
     void themeGroup_toggled(int id);
 
@@ -51,9 +50,36 @@ private slots:
 
     void on_acAllowIncompleteComboBox_currentIndexChanged(int index);
 
+    void on_prefixLineEdit_textChanged(const QString &arg1);
+
+    void on_piclastnameLineEdit_editingFinished();
+
+    void on_picfirstnameLineEdit_editingFinished();
+
+    void on_employeeidLineEdit_editingFinished();
+
+    void on_emailLineEdit_editingFinished();
+
+    void on_phoneLineEdit_editingFinished();
+
+    void on_aliasComboBox_currentIndexChanged(int index);
+
+    void on_functionComboBox_currentIndexChanged(const QString &arg1);
+
+    void on_rulesComboBox_currentIndexChanged(const QString &arg1);
+
+    void on_approachComboBox_currentIndexChanged(const QString &arg1);
+
+    void on_nightComboBox_currentIndexChanged(int index);
+
+    void on_pilotSortComboBox_currentIndexChanged(int index);
+
 private:
     Ui::SettingsWidget *ui;
 
+    void fillSettings();
+
+    void setupValidators();
 };
 
 #endif // SETTINGSWIDGET_H

+ 426 - 89
src/gui/widgets/settingswidget.ui

@@ -6,8 +6,8 @@
    <rect>
     <x>0</x>
     <y>0</y>
-    <width>400</width>
-    <height>300</height>
+    <width>731</width>
+    <height>411</height>
    </rect>
   </property>
   <property name="windowTitle">
@@ -17,38 +17,101 @@
    <item row="0" column="0">
     <widget class="QTabWidget" name="tabWidget">
      <property name="currentIndex">
-      <number>0</number>
+      <number>2</number>
      </property>
-     <widget class="QWidget" name="generalTab">
+     <widget class="QWidget" name="personalTab">
       <attribute name="title">
-       <string>General</string>
+       <string>Personal</string>
       </attribute>
       <layout class="QGridLayout" name="gridLayout">
+       <item row="4" column="1">
+        <widget class="QLineEdit" name="phoneLineEdit">
+         <property name="maxLength">
+          <number>40</number>
+         </property>
+         <property name="placeholderText">
+          <string>optional</string>
+         </property>
+        </widget>
+       </item>
+       <item row="0" column="1">
+        <widget class="QLineEdit" name="piclastnameLineEdit">
+         <property name="maxLength">
+          <number>40</number>
+         </property>
+         <property name="placeholderText">
+          <string>required</string>
+         </property>
+        </widget>
+       </item>
+       <item row="3" column="0">
+        <widget class="QLabel" name="emailLabel">
+         <property name="text">
+          <string>eMail</string>
+         </property>
+        </widget>
+       </item>
+       <item row="4" column="0">
+        <widget class="QLabel" name="phoneLabel">
+         <property name="text">
+          <string>Phone</string>
+         </property>
+        </widget>
+       </item>
        <item row="0" column="0">
-        <widget class="QLabel" name="themeLabel">
+        <widget class="QLabel" name="lastNameLabel">
          <property name="text">
-          <string>Theme</string>
+          <string>Last Name</string>
          </property>
         </widget>
        </item>
-       <item row="0" column="1">
-        <widget class="QCheckBox" name="systemThemeCheckBox">
+       <item row="2" column="0">
+        <widget class="QLabel" name="employeeLabel">
          <property name="text">
-          <string>System</string>
+          <string>Employee ID</string>
          </property>
         </widget>
        </item>
        <item row="1" column="1">
-        <widget class="QCheckBox" name="lightThemeCheckBox">
-         <property name="text">
-          <string>Light</string>
+        <widget class="QLineEdit" name="picfirstnameLineEdit">
+         <property name="maxLength">
+          <number>40</number>
+         </property>
+         <property name="placeholderText">
+          <string>required</string>
          </property>
         </widget>
        </item>
        <item row="2" column="1">
-        <widget class="QCheckBox" name="darkThemeCheckBox">
+        <widget class="QLineEdit" name="employeeidLineEdit">
+         <property name="focusPolicy">
+          <enum>Qt::StrongFocus</enum>
+         </property>
          <property name="text">
-          <string>Dark</string>
+          <string/>
+         </property>
+         <property name="maxLength">
+          <number>40</number>
+         </property>
+         <property name="placeholderText">
+          <string>optional</string>
+         </property>
+        </widget>
+       </item>
+       <item row="1" column="0">
+        <widget class="QLabel" name="firstNameLabel">
+         <property name="text">
+          <string>First Name</string>
+         </property>
+        </widget>
+       </item>
+       <item row="3" column="1">
+        <widget class="QLineEdit" name="emailLineEdit">
+         <property name="maxLength">
+          <number>40</number>
+         </property>
+         <property name="placeholderText">
+          <string>optional</string>
          </property>
         </widget>
        </item>
@@ -58,87 +121,361 @@
       <attribute name="title">
        <string>Flight Logging</string>
       </attribute>
-      <layout class="QGridLayout" name="gridLayout_7">
+      <layout class="QGridLayout" name="gridLayout_4">
        <item row="0" column="0">
-        <layout class="QGridLayout" name="gridLayout_4">
-         <item row="0" column="0">
-          <widget class="QLabel" name="flightNumberPrefixLabel">
-           <property name="text">
-            <string>Flight Number Prefix</string>
-           </property>
-          </widget>
-         </item>
-         <item row="0" column="1">
-          <widget class="QLineEdit" name="flightNumberPrefixLineEdit">
-           <property name="placeholderText">
-            <string>optional</string>
-           </property>
-          </widget>
-         </item>
-        </layout>
+        <widget class="QLabel" name="aliasLabel">
+         <property name="text">
+          <string>Show own name as</string>
+         </property>
+        </widget>
+       </item>
+       <item row="0" column="1">
+        <widget class="QComboBox" name="aliasComboBox">
+         <item>
+          <property name="text">
+           <string>self</string>
+          </property>
+         </item>
+         <item>
+          <property name="text">
+           <string>SELF</string>
+          </property>
+         </item>
+         <item>
+          <property name="text">
+           <string>Lastname, Firstname</string>
+          </property>
+         </item>
+        </widget>
+       </item>
+       <item row="1" column="0">
+        <widget class="QLabel" name="functionLabel">
+         <property name="text">
+          <string>Function</string>
+         </property>
+        </widget>
+       </item>
+       <item row="1" column="1">
+        <widget class="QComboBox" name="functionComboBox">
+         <item>
+          <property name="text">
+           <string>PIC</string>
+          </property>
+         </item>
+         <item>
+          <property name="text">
+           <string>SIC</string>
+          </property>
+         </item>
+         <item>
+          <property name="text">
+           <string>DUAL</string>
+          </property>
+         </item>
+         <item>
+          <property name="text">
+           <string>INSTRUCTOR</string>
+          </property>
+         </item>
+        </widget>
+       </item>
+       <item row="2" column="0">
+        <widget class="QLabel" name="rulesLabel">
+         <property name="text">
+          <string>Flight Rules</string>
+         </property>
+        </widget>
+       </item>
+       <item row="2" column="1">
+        <widget class="QComboBox" name="rulesComboBox">
+         <item>
+          <property name="text">
+           <string>VFR</string>
+          </property>
+         </item>
+         <item>
+          <property name="text">
+           <string>IFR</string>
+          </property>
+         </item>
+        </widget>
+       </item>
+       <item row="3" column="0">
+        <widget class="QLabel" name="approachLabel">
+         <property name="text">
+          <string>Approach</string>
+         </property>
+        </widget>
+       </item>
+       <item row="3" column="1">
+        <widget class="QComboBox" name="approachComboBox">
+         <item>
+          <property name="text">
+           <string>VISUAL</string>
+          </property>
+         </item>
+         <item>
+          <property name="text">
+           <string>ILS CAT I</string>
+          </property>
+         </item>
+         <item>
+          <property name="text">
+           <string>ILS CAT II</string>
+          </property>
+         </item>
+         <item>
+          <property name="text">
+           <string>ILS CAT III</string>
+          </property>
+         </item>
+         <item>
+          <property name="text">
+           <string>GLS</string>
+          </property>
+         </item>
+         <item>
+          <property name="text">
+           <string>MLS</string>
+          </property>
+         </item>
+         <item>
+          <property name="text">
+           <string>LOC</string>
+          </property>
+         </item>
+         <item>
+          <property name="text">
+           <string>LOC/DME</string>
+          </property>
+         </item>
+         <item>
+          <property name="text">
+           <string>RNAV</string>
+          </property>
+         </item>
+         <item>
+          <property name="text">
+           <string>RNAV (LNAV)</string>
+          </property>
+         </item>
+         <item>
+          <property name="text">
+           <string>RNAV (LNAV/VNAV)</string>
+          </property>
+         </item>
+         <item>
+          <property name="text">
+           <string>RNAV (LPV)</string>
+          </property>
+         </item>
+         <item>
+          <property name="text">
+           <string>RNAV (RNP)</string>
+          </property>
+         </item>
+         <item>
+          <property name="text">
+           <string>RNAV (RNP-AR)</string>
+          </property>
+         </item>
+         <item>
+          <property name="text">
+           <string>VOR</string>
+          </property>
+         </item>
+         <item>
+          <property name="text">
+           <string>VOR/DME</string>
+          </property>
+         </item>
+         <item>
+          <property name="text">
+           <string>NDB</string>
+          </property>
+         </item>
+         <item>
+          <property name="text">
+           <string>NDB/DME</string>
+          </property>
+         </item>
+         <item>
+          <property name="text">
+           <string>TACAN</string>
+          </property>
+         </item>
+         <item>
+          <property name="text">
+           <string>SRA</string>
+          </property>
+         </item>
+         <item>
+          <property name="text">
+           <string>PAR</string>
+          </property>
+         </item>
+        </widget>
+       </item>
+       <item row="4" column="0">
+        <widget class="QLabel" name="nightLabel">
+         <property name="text">
+          <string>Night Time</string>
+         </property>
+        </widget>
+       </item>
+       <item row="4" column="1">
+        <widget class="QComboBox" name="nightComboBox">
+         <item>
+          <property name="text">
+           <string>NO</string>
+          </property>
+         </item>
+         <item>
+          <property name="text">
+           <string>YES (EASA)</string>
+          </property>
+         </item>
+         <item>
+          <property name="text">
+           <string>YES (SR/SS)</string>
+          </property>
+         </item>
+        </widget>
+       </item>
+       <item row="5" column="0">
+        <widget class="QLabel" name="prefixLabel">
+         <property name="text">
+          <string>Airline Prefix</string>
+         </property>
+        </widget>
+       </item>
+       <item row="5" column="1">
+        <widget class="QLineEdit" name="prefixLineEdit">
+         <property name="maxLength">
+          <number>10</number>
+         </property>
+         <property name="placeholderText">
+          <string>optional</string>
+         </property>
+        </widget>
        </item>
       </layout>
      </widget>
-     <widget class="QWidget" name="aircraftTab">
+     <widget class="QWidget" name="miscTab">
       <attribute name="title">
-       <string>Aircraft</string>
+       <string>Misc</string>
       </attribute>
-      <layout class="QGridLayout" name="gridLayout_6">
+      <layout class="QGridLayout" name="gridLayout_5">
        <item row="0" column="0">
-        <layout class="QGridLayout" name="gridLayout_5">
-         <item row="0" column="0">
-          <widget class="QLabel" name="acSortLabel">
-           <property name="text">
-            <string>Sort by</string>
-           </property>
-          </widget>
-         </item>
-         <item row="0" column="1">
-          <widget class="QComboBox" name="acSortComboBox">
-           <item>
-            <property name="text">
-             <string>ID</string>
-            </property>
-           </item>
-           <item>
-            <property name="text">
-             <string>Registration</string>
-            </property>
-           </item>
-           <item>
-            <property name="text">
-             <string>Type</string>
-            </property>
-           </item>
-           <item>
-            <property name="text">
-             <string>Company</string>
-            </property>
-           </item>
-          </widget>
-         </item>
-         <item row="1" column="0">
-          <widget class="QLabel" name="acAllowIncompleteLabel">
-           <property name="text">
-            <string>Allow incomplete</string>
-           </property>
-          </widget>
-         </item>
-         <item row="1" column="1">
-          <widget class="QComboBox" name="acAllowIncompleteComboBox">
-           <item>
-            <property name="text">
-             <string>No</string>
-            </property>
-           </item>
-           <item>
-            <property name="text">
-             <string>Yes</string>
-            </property>
-           </item>
-          </widget>
-         </item>
-        </layout>
+        <widget class="QLabel" name="themeLabel">
+         <property name="text">
+          <string>Theme</string>
+         </property>
+        </widget>
+       </item>
+       <item row="0" column="1">
+        <widget class="QCheckBox" name="systemThemeCheckBox">
+         <property name="text">
+          <string>System</string>
+         </property>
+        </widget>
+       </item>
+       <item row="1" column="1">
+        <widget class="QCheckBox" name="lightThemeCheckBox">
+         <property name="text">
+          <string>Light</string>
+         </property>
+        </widget>
+       </item>
+       <item row="2" column="1">
+        <widget class="QCheckBox" name="darkThemeCheckBox">
+         <property name="text">
+          <string>Dark</string>
+         </property>
+        </widget>
+       </item>
+       <item row="3" column="0">
+        <widget class="QLabel" name="pilotSortLabel">
+         <property name="text">
+          <string>Sort Pilots by</string>
+         </property>
+        </widget>
+       </item>
+       <item row="3" column="1">
+        <widget class="QComboBox" name="pilotSortComboBox">
+         <item>
+          <property name="text">
+           <string>ID</string>
+          </property>
+         </item>
+         <item>
+          <property name="text">
+           <string>Last Name</string>
+          </property>
+         </item>
+         <item>
+          <property name="text">
+           <string>First Name</string>
+          </property>
+         </item>
+         <item>
+          <property name="text">
+           <string>Company</string>
+          </property>
+         </item>
+        </widget>
+       </item>
+       <item row="4" column="0">
+        <widget class="QLabel" name="acSortLabel">
+         <property name="text">
+          <string>Sort Aircraft by</string>
+         </property>
+        </widget>
+       </item>
+       <item row="4" column="1">
+        <widget class="QComboBox" name="acSortComboBox">
+         <item>
+          <property name="text">
+           <string>ID</string>
+          </property>
+         </item>
+         <item>
+          <property name="text">
+           <string>Registration</string>
+          </property>
+         </item>
+         <item>
+          <property name="text">
+           <string>Type</string>
+          </property>
+         </item>
+         <item>
+          <property name="text">
+           <string>Company</string>
+          </property>
+         </item>
+        </widget>
+       </item>
+       <item row="5" column="0">
+        <widget class="QLabel" name="acAllowIncompleteLabel">
+         <property name="text">
+          <string>Allow incomplete Entries</string>
+         </property>
+        </widget>
+       </item>
+       <item row="5" column="1">
+        <widget class="QComboBox" name="acAllowIncompleteComboBox">
+         <item>
+          <property name="text">
+           <string>No</string>
+          </property>
+         </item>
+         <item>
+          <property name="text">
+           <string>Yes</string>
+          </property>
+         </item>
+        </widget>
        </item>
       </layout>
      </widget>