# -*- coding: utf-8 -*-

# Form implementation generated from reading ui file 'main2.ui'
#
# Created: Tue Jul 25 13:14:22 2017
#      by: PyQt5 UI code generator 5.3.2
#
# WARNING! All changes made in this file will be lost!

from PyQt5 import QtCore, QtGui, QtWidgets
from controller import MatplotlibWidget

class Ui_Form(object):
    def setupUi(self, Form):
        self.form = Form
        Form.setObjectName("Form")
        Form.resize(750, 646)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Expanding)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(Form.sizePolicy().hasHeightForWidth())
        Form.setSizePolicy(sizePolicy)
        Form.setMinimumSize(QtCore.QSize(647, 640))
        self.verticalLayout_6 = QtWidgets.QVBoxLayout(Form)
        self.verticalLayout_6.setObjectName("verticalLayout_6")
        self.verticalLayout = QtWidgets.QVBoxLayout()
        self.verticalLayout.setSpacing(10)
        self.verticalLayout.setObjectName("verticalLayout")
        self.horizontalLayout = QtWidgets.QHBoxLayout()
        self.horizontalLayout.setObjectName("horizontalLayout")
        self.btnOpen = QtWidgets.QPushButton(Form)
        self.btnOpen.setMinimumSize(QtCore.QSize(90, 0))
        self.btnOpen.setObjectName("btnOpen")
        self.horizontalLayout.addWidget(self.btnOpen)
        self.btnRun = QtWidgets.QPushButton(Form)
        self.btnRun.setMinimumSize(QtCore.QSize(90, 0))
        self.btnRun.setObjectName("btnRun")
        self.horizontalLayout.addWidget(self.btnRun)
        self.btnLiveRun = QtWidgets.QPushButton(Form)
        self.btnLiveRun.setObjectName("btnLiveRun")
        self.horizontalLayout.addWidget(self.btnLiveRun)
        self.btnWrite = QtWidgets.QPushButton(Form)
        self.btnWrite.setMinimumSize(QtCore.QSize(90, 0))
        self.btnWrite.setObjectName("btnWrite")
        self.horizontalLayout.addWidget(self.btnWrite)
        self.btnPause = QtWidgets.QPushButton(Form)
        self.btnPause.setMinimumSize(QtCore.QSize(90, 0))
        self.btnPause.setObjectName("btnPause")
        self.horizontalLayout.addWidget(self.btnPause)
        self.btnStop = QtWidgets.QPushButton(Form)
        self.btnStop.setMinimumSize(QtCore.QSize(90, 0))
        self.btnStop.setObjectName("btnStop")
        self.horizontalLayout.addWidget(self.btnStop)
        spacerItem = QtWidgets.QSpacerItem(40, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum)
        self.horizontalLayout.addItem(spacerItem)
        self.lblTime = QtWidgets.QLabel(Form)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Preferred)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.lblTime.sizePolicy().hasHeightForWidth())
        self.lblTime.setSizePolicy(sizePolicy)
        self.lblTime.setMinimumSize(QtCore.QSize(80, 0))
        self.lblTime.setObjectName("lblTime")
        self.horizontalLayout.addWidget(self.lblTime)
        self.verticalLayout.addLayout(self.horizontalLayout)
        self.horizontalLayout_2 = QtWidgets.QHBoxLayout()
        self.horizontalLayout_2.setContentsMargins(10, -1, 10, -1)
        self.horizontalLayout_2.setObjectName("horizontalLayout_2")
        self.lblProcess = QtWidgets.QLabel(Form)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Preferred)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.lblProcess.sizePolicy().hasHeightForWidth())
        self.lblProcess.setSizePolicy(sizePolicy)
        self.lblProcess.setObjectName("lblProcess")
        self.horizontalLayout_2.addWidget(self.lblProcess)
        self.lblCurrent = QtWidgets.QLabel(Form)
        self.lblCurrent.setObjectName("lblCurrent")
        self.horizontalLayout_2.addWidget(self.lblCurrent)
        spacerItem1 = QtWidgets.QSpacerItem(40, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum)
        self.horizontalLayout_2.addItem(spacerItem1)
        self.label_7 = QtWidgets.QLabel(Form)
        font = QtGui.QFont()
        font.setPointSize(8)
        font.setBold(True)
        font.setUnderline(False)
        font.setWeight(75)
        self.label_7.setFont(font)
        self.label_7.setObjectName("label_7")
        self.horizontalLayout_2.addWidget(self.label_7)
        spacerItem2 = QtWidgets.QSpacerItem(80, 20, QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Minimum)
        self.horizontalLayout_2.addItem(spacerItem2)
        self.lblHap = QtWidgets.QLabel(Form)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Preferred)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.lblHap.sizePolicy().hasHeightForWidth())
        self.lblHap.setSizePolicy(sizePolicy)
        self.lblHap.setObjectName("lblHap")
        self.horizontalLayout_2.addWidget(self.lblHap)
        self.progressBar = QtWidgets.QProgressBar(Form)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.progressBar.sizePolicy().hasHeightForWidth())
        self.progressBar.setSizePolicy(sizePolicy)
        self.progressBar.setMinimumSize(QtCore.QSize(120, 0))
        self.progressBar.setMinimum(0)
        self.progressBar.setMaximum(100)
        self.progressBar.setProperty("value", 0)
        self.progressBar.setTextVisible(True)
        self.progressBar.setOrientation(QtCore.Qt.Horizontal)
        self.progressBar.setInvertedAppearance(False)
        self.progressBar.setTextDirection(QtWidgets.QProgressBar.TopToBottom)
        self.progressBar.setObjectName("progressBar")
        self.horizontalLayout_2.addWidget(self.progressBar)
        self.verticalLayout.addLayout(self.horizontalLayout_2)
        self.line_8 = QtWidgets.QFrame(Form)
        self.line_8.setFrameShape(QtWidgets.QFrame.HLine)
        self.line_8.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_8.setObjectName("line_8")
        self.verticalLayout.addWidget(self.line_8)
        self.gridLayout_7 = QtWidgets.QGridLayout()
        self.gridLayout_7.setContentsMargins(10, -1, 10, -1)
        self.gridLayout_7.setVerticalSpacing(5)
        self.gridLayout_7.setObjectName("gridLayout_7")
        self.dateTimeEdit_filterEnd = QtWidgets.QDateTimeEdit(Form)
        self.dateTimeEdit_filterEnd.setDate(QtCore.QDate(2020, 1, 1))
        self.dateTimeEdit_filterEnd.setCalendarPopup(True)
        self.dateTimeEdit_filterEnd.setObjectName("dateTimeEdit_filterEnd")
        self.gridLayout_7.addWidget(self.dateTimeEdit_filterEnd, 2, 4, 1, 1)
        self.label_14 = QtWidgets.QLabel(Form)
        self.label_14.setObjectName("label_14")
        self.gridLayout_7.addWidget(self.label_14, 1, 3, 1, 1)
        self.label_12 = QtWidgets.QLabel(Form)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.label_12.sizePolicy().hasHeightForWidth())
        self.label_12.setSizePolicy(sizePolicy)
        self.label_12.setObjectName("label_12")
        self.gridLayout_7.addWidget(self.label_12, 1, 1, 1, 1)
        self.label = QtWidgets.QLabel(Form)
        self.label.setObjectName("label")
        self.gridLayout_7.addWidget(self.label, 1, 4, 1, 1)
        self.label_11 = QtWidgets.QLabel(Form)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.label_11.sizePolicy().hasHeightForWidth())
        self.label_11.setSizePolicy(sizePolicy)
        self.label_11.setObjectName("label_11")
        self.gridLayout_7.addWidget(self.label_11, 1, 0, 1, 1)
        self.comboBox_config = QtWidgets.QComboBox(Form)
        self.comboBox_config.setMaximumSize(QtCore.QSize(16777215, 20))
        self.comboBox_config.setToolTip("")
        self.comboBox_config.setCurrentText("")
        self.comboBox_config.setMinimumContentsLength(0)
        self.comboBox_config.setModelColumn(0)
        self.comboBox_config.setObjectName("comboBox_config")
        self.gridLayout_7.addWidget(self.comboBox_config, 2, 2, 1, 1)
        self.dateTimeEdit_filterStart = QtWidgets.QDateTimeEdit(Form)
        self.dateTimeEdit_filterStart.setCalendarPopup(True)
        self.dateTimeEdit_filterStart.setObjectName("dateTimeEdit_filterStart")
        self.gridLayout_7.addWidget(self.dateTimeEdit_filterStart, 2, 3, 1, 1)
        self.lineEdit_filter_model = QtWidgets.QLineEdit(Form)
        self.lineEdit_filter_model.setObjectName("lineEdit_filter_model")
        self.gridLayout_7.addWidget(self.lineEdit_filter_model, 2, 1, 1, 1)
        self.label_13 = QtWidgets.QLabel(Form)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.label_13.sizePolicy().hasHeightForWidth())
        self.label_13.setSizePolicy(sizePolicy)
        self.label_13.setObjectName("label_13")
        self.gridLayout_7.addWidget(self.label_13, 1, 2, 1, 1)
        self.lineEdit_filter_airline = QtWidgets.QLineEdit(Form)
        self.lineEdit_filter_airline.setObjectName("lineEdit_filter_airline")
        self.gridLayout_7.addWidget(self.lineEdit_filter_airline, 2, 0, 1, 1)
        self.pushButton_resetFilter = QtWidgets.QPushButton(Form)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.pushButton_resetFilter.sizePolicy().hasHeightForWidth())
        self.pushButton_resetFilter.setSizePolicy(sizePolicy)
        self.pushButton_resetFilter.setMaximumSize(QtCore.QSize(40, 16777215))
        self.pushButton_resetFilter.setObjectName("pushButton_resetFilter")
        self.gridLayout_7.addWidget(self.pushButton_resetFilter, 2, 5, 1, 1)
        self.verticalLayout.addLayout(self.gridLayout_7)
        self.line = QtWidgets.QFrame(Form)
        self.line.setFrameShape(QtWidgets.QFrame.HLine)
        self.line.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line.setObjectName("line")
        self.verticalLayout.addWidget(self.line)
        self.tabWidget = QtWidgets.QTabWidget(Form)
        self.tabWidget.setObjectName("tabWidget")
        self.Configuration = QtWidgets.QWidget()
        self.Configuration.setEnabled(True)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Minimum)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.Configuration.sizePolicy().hasHeightForWidth())
        self.Configuration.setSizePolicy(sizePolicy)
        self.Configuration.setAutoFillBackground(False)
        self.Configuration.setObjectName("Configuration")
        self.gridLayout_3 = QtWidgets.QGridLayout(self.Configuration)
        self.gridLayout_3.setObjectName("gridLayout_3")
        self.verticalLayout_5 = QtWidgets.QVBoxLayout()
        self.verticalLayout_5.setSizeConstraint(QtWidgets.QLayout.SetDefaultConstraint)
        self.verticalLayout_5.setContentsMargins(0, 0, 0, 0)
        self.verticalLayout_5.setObjectName("verticalLayout_5")
        self.lbl_config = QtWidgets.QLabel(self.Configuration)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.lbl_config.sizePolicy().hasHeightForWidth())
        self.lbl_config.setSizePolicy(sizePolicy)
        self.lbl_config.setObjectName("lbl_config")
        self.verticalLayout_5.addWidget(self.lbl_config)
        self.tableConfig = QtWidgets.QTableWidget(self.Configuration)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.tableConfig.sizePolicy().hasHeightForWidth())
        self.tableConfig.setSizePolicy(sizePolicy)
        self.tableConfig.setMinimumSize(QtCore.QSize(0, 50))
        self.tableConfig.setMaximumSize(QtCore.QSize(16777215, 164))
        font = QtGui.QFont()
        font.setPointSize(10)
        self.tableConfig.setFont(font)
        self.tableConfig.setAutoFillBackground(False)
        self.tableConfig.setEditTriggers(QtWidgets.QAbstractItemView.NoEditTriggers)
        self.tableConfig.setAlternatingRowColors(True)
        self.tableConfig.setSelectionMode(QtWidgets.QAbstractItemView.NoSelection)
        self.tableConfig.setShowGrid(True)
        self.tableConfig.setGridStyle(QtCore.Qt.SolidLine)
        self.tableConfig.setRowCount(1)
        self.tableConfig.setColumnCount(15)
        self.tableConfig.setObjectName("tableConfig")
        self.tableConfig.horizontalHeader().setCascadingSectionResizes(False)
        self.tableConfig.horizontalHeader().setDefaultSectionSize(100)
        self.tableConfig.horizontalHeader().setHighlightSections(True)
        self.tableConfig.horizontalHeader().setSortIndicatorShown(True)
        self.tableConfig.horizontalHeader().setStretchLastSection(False)
        self.tableConfig.verticalHeader().setSortIndicatorShown(False)
        self.verticalLayout_5.addWidget(self.tableConfig)
        self.lbl_histo = QtWidgets.QLabel(self.Configuration)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.lbl_histo.sizePolicy().hasHeightForWidth())
        self.lbl_histo.setSizePolicy(sizePolicy)
        self.lbl_histo.setObjectName("lbl_histo")
        self.verticalLayout_5.addWidget(self.lbl_histo)
        self.horizontalLayout_6 = QtWidgets.QHBoxLayout()
        self.horizontalLayout_6.setObjectName("horizontalLayout_6")

        self.matplotlibWidget = MatplotlibWidget(self.Configuration)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.matplotlibWidget.sizePolicy().hasHeightForWidth())
        self.matplotlibWidget.setSizePolicy(sizePolicy)
        self.matplotlibWidget.setMinimumSize(QtCore.QSize(0, 0))
        self.matplotlibWidget.setObjectName("matplotlibWidget")
        # self.horizontalLayout_5 = QtWidgets.QHBoxLayout(self.matplotlibWidget)
        # self.horizontalLayout_5.setContentsMargins(0, 0, 0, 0)
        # self.horizontalLayout_5.setObjectName("horizontalLayout_5")
        self.horizontalLayout_6.addWidget(self.matplotlibWidget)
        self.verticalLayout_5.addLayout(self.horizontalLayout_6)

        self.gridLayout_3.addLayout(self.verticalLayout_5, 0, 0, 1, 1)
        self.tabWidget.addTab(self.Configuration, "")
        self.Operations = QtWidgets.QWidget()
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Expanding)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.Operations.sizePolicy().hasHeightForWidth())
        self.Operations.setSizePolicy(sizePolicy)
        self.Operations.setAutoFillBackground(False)
        self.Operations.setObjectName("Operations")
        self.gridLayout_2 = QtWidgets.QGridLayout(self.Operations)
        self.gridLayout_2.setObjectName("gridLayout_2")
        self.verticalLayout_7 = QtWidgets.QVBoxLayout()
        self.verticalLayout_7.setContentsMargins(0, 0, 0, 0)
        self.verticalLayout_7.setObjectName("verticalLayout_7")
        self.lbl_flights = QtWidgets.QLabel(self.Operations)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Maximum)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.lbl_flights.sizePolicy().hasHeightForWidth())
        self.lbl_flights.setSizePolicy(sizePolicy)
        self.lbl_flights.setObjectName("lbl_flights")
        self.verticalLayout_7.addWidget(self.lbl_flights)
        self.tableFlights = QtWidgets.QTableWidget(self.Operations)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.tableFlights.sizePolicy().hasHeightForWidth())
        self.tableFlights.setSizePolicy(sizePolicy)
        font = QtGui.QFont()
        font.setPointSize(8)
        self.tableFlights.setFont(font)
        self.tableFlights.setFrameShape(QtWidgets.QFrame.StyledPanel)
        self.tableFlights.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.tableFlights.setEditTriggers(QtWidgets.QAbstractItemView.NoEditTriggers)
        self.tableFlights.setAlternatingRowColors(True)
        self.tableFlights.setSelectionMode(QtWidgets.QAbstractItemView.NoSelection)
        self.tableFlights.setSelectionBehavior(QtWidgets.QAbstractItemView.SelectRows)
        self.tableFlights.setRowCount(200)
        self.tableFlights.setColumnCount(15)
        self.tableFlights.setObjectName("tableFlights")
        self.tableFlights.horizontalHeader().setStretchLastSection(False)
        self.verticalLayout_7.addWidget(self.tableFlights)
        self.gridLayout_2.addLayout(self.verticalLayout_7, 0, 0, 1, 1)
        self.tabWidget.addTab(self.Operations, "")
        self.Settings = QtWidgets.QWidget()
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.Settings.sizePolicy().hasHeightForWidth())
        self.Settings.setSizePolicy(sizePolicy)
        self.Settings.setObjectName("Settings")
        self.gridLayout_4 = QtWidgets.QGridLayout(self.Settings)
        self.gridLayout_4.setObjectName("gridLayout_4")
        self.gridLayout = QtWidgets.QGridLayout()
        self.gridLayout.setSizeConstraint(QtWidgets.QLayout.SetDefaultConstraint)
        self.gridLayout.setContentsMargins(5, 10, 5, 5)
        self.gridLayout.setHorizontalSpacing(10)
        self.gridLayout.setVerticalSpacing(15)
        self.gridLayout.setObjectName("gridLayout")
        self.line_5 = QtWidgets.QFrame(self.Settings)
        self.line_5.setFrameShape(QtWidgets.QFrame.VLine)
        self.line_5.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_5.setObjectName("line_5")
        self.gridLayout.addWidget(self.line_5, 0, 1, 1, 1)
        self.console = QtWidgets.QPlainTextEdit(self.Settings)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Expanding)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(1)
        sizePolicy.setHeightForWidth(self.console.sizePolicy().hasHeightForWidth())
        self.console.setSizePolicy(sizePolicy)
        font = QtGui.QFont()
        font.setPointSize(11)
        self.console.setFont(font)
        self.console.setFocusPolicy(QtCore.Qt.ClickFocus)
        self.console.setSizeAdjustPolicy(QtWidgets.QAbstractScrollArea.AdjustToContents)
        self.console.setReadOnly(True)
        self.console.setObjectName("console")
        self.gridLayout.addWidget(self.console, 7, 0, 1, 3)
        self.line_2 = QtWidgets.QFrame(self.Settings)
        self.line_2.setFrameShape(QtWidgets.QFrame.HLine)
        self.line_2.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_2.setObjectName("line_2")
        self.gridLayout.addWidget(self.line_2, 1, 0, 1, 1)
        self.line_4 = QtWidgets.QFrame(self.Settings)
        self.line_4.setFrameShape(QtWidgets.QFrame.VLine)
        self.line_4.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_4.setObjectName("line_4")
        self.gridLayout.addWidget(self.line_4, 2, 1, 1, 1)
        self.gridLayout_8 = QtWidgets.QGridLayout()
        self.gridLayout_8.setSpacing(10)
        self.gridLayout_8.setObjectName("gridLayout_8")
        self.lbl_start_time = QtWidgets.QLabel(self.Settings)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.lbl_start_time.sizePolicy().hasHeightForWidth())
        self.lbl_start_time.setSizePolicy(sizePolicy)
        self.lbl_start_time.setMinimumSize(QtCore.QSize(200, 0))
        self.lbl_start_time.setMaximumSize(QtCore.QSize(200, 50))
        self.lbl_start_time.setScaledContents(False)
        self.lbl_start_time.setObjectName("lbl_start_time")
        self.gridLayout_8.addWidget(self.lbl_start_time, 1, 0, 1, 1)
        self.dateTimeEdit_analyseEnd = QtWidgets.QDateTimeEdit(self.Settings)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.dateTimeEdit_analyseEnd.sizePolicy().hasHeightForWidth())
        self.dateTimeEdit_analyseEnd.setSizePolicy(sizePolicy)
        self.dateTimeEdit_analyseEnd.setMinimumSize(QtCore.QSize(200, 0))
        self.dateTimeEdit_analyseEnd.setMaximumSize(QtCore.QSize(200, 16777215))
        self.dateTimeEdit_analyseEnd.setDate(QtCore.QDate(2017, 7, 6))
        self.dateTimeEdit_analyseEnd.setTime(QtCore.QTime(12, 0, 0))
        self.dateTimeEdit_analyseEnd.setCalendarPopup(True)
        self.dateTimeEdit_analyseEnd.setObjectName("dateTimeEdit_analyseEnd")
        self.gridLayout_8.addWidget(self.dateTimeEdit_analyseEnd, 2, 1, 1, 1)
        self.checkBoxDelimit = QtWidgets.QCheckBox(self.Settings)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.checkBoxDelimit.sizePolicy().hasHeightForWidth())
        self.checkBoxDelimit.setSizePolicy(sizePolicy)
        self.checkBoxDelimit.setMinimumSize(QtCore.QSize(200, 0))
        self.checkBoxDelimit.setMaximumSize(QtCore.QSize(200, 50))
        self.checkBoxDelimit.setObjectName("checkBoxDelimit")
        self.gridLayout_8.addWidget(self.checkBoxDelimit, 0, 0, 1, 1)
        self.dateTimeEdit_analyseStart = QtWidgets.QDateTimeEdit(self.Settings)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.dateTimeEdit_analyseStart.sizePolicy().hasHeightForWidth())
        self.dateTimeEdit_analyseStart.setSizePolicy(sizePolicy)
        self.dateTimeEdit_analyseStart.setMinimumSize(QtCore.QSize(200, 0))
        self.dateTimeEdit_analyseStart.setMaximumSize(QtCore.QSize(200, 50))
        self.dateTimeEdit_analyseStart.setDate(QtCore.QDate(2017, 7, 6))
        self.dateTimeEdit_analyseStart.setCalendarPopup(True)
        self.dateTimeEdit_analyseStart.setObjectName("dateTimeEdit_analyseStart")
        self.gridLayout_8.addWidget(self.dateTimeEdit_analyseStart, 2, 0, 1, 1)
        self.lbl_end_time = QtWidgets.QLabel(self.Settings)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.lbl_end_time.sizePolicy().hasHeightForWidth())
        self.lbl_end_time.setSizePolicy(sizePolicy)
        self.lbl_end_time.setMinimumSize(QtCore.QSize(200, 0))
        self.lbl_end_time.setMaximumSize(QtCore.QSize(200, 16777215))
        self.lbl_end_time.setObjectName("lbl_end_time")
        self.gridLayout_8.addWidget(self.lbl_end_time, 1, 1, 1, 1)
        self.gridLayout.addLayout(self.gridLayout_8, 2, 0, 1, 1)
        self.line_6 = QtWidgets.QFrame(self.Settings)
        self.line_6.setFrameShape(QtWidgets.QFrame.HLine)
        self.line_6.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_6.setObjectName("line_6")
        self.gridLayout.addWidget(self.line_6, 3, 0, 1, 1)
        self.line_3 = QtWidgets.QFrame(self.Settings)
        self.line_3.setFrameShape(QtWidgets.QFrame.HLine)
        self.line_3.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_3.setObjectName("line_3")
        self.gridLayout.addWidget(self.line_3, 1, 2, 1, 1)
        self.line_7 = QtWidgets.QFrame(self.Settings)
        self.line_7.setFrameShape(QtWidgets.QFrame.VLine)
        self.line_7.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_7.setObjectName("line_7")
        self.gridLayout.addWidget(self.line_7, 4, 1, 1, 1)
        self.horizontalLayout_3 = QtWidgets.QHBoxLayout()
        self.horizontalLayout_3.setSpacing(10)
        self.horizontalLayout_3.setObjectName("horizontalLayout_3")
        self.label_2 = QtWidgets.QLabel(self.Settings)
        self.label_2.setObjectName("label_2")
        self.horizontalLayout_3.addWidget(self.label_2)
        self.spinBoxRate = QtWidgets.QSpinBox(self.Settings)
        self.spinBoxRate.setMaximumSize(QtCore.QSize(60, 16777215))
        self.spinBoxRate.setMinimum(1)
        self.spinBoxRate.setMaximum(1000)
        self.spinBoxRate.setProperty("value", 5)
        self.spinBoxRate.setObjectName("spinBoxRate")
        self.horizontalLayout_3.addWidget(self.spinBoxRate)
        spacerItem3 = QtWidgets.QSpacerItem(20, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum)
        self.horizontalLayout_3.addItem(spacerItem3)
        self.gridLayout.addLayout(self.horizontalLayout_3, 0, 2, 1, 1)
        self.gridLayout_9 = QtWidgets.QGridLayout()
        self.gridLayout_9.setSpacing(10)
        self.gridLayout_9.setObjectName("gridLayout_9")
        self.checkBox_alt_ths = QtWidgets.QCheckBox(self.Settings)
        self.checkBox_alt_ths.setChecked(True)
        self.checkBox_alt_ths.setObjectName("checkBox_alt_ths")
        self.gridLayout_9.addWidget(self.checkBox_alt_ths, 0, 0, 1, 1)
        spacerItem4 = QtWidgets.QSpacerItem(10, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum)
        self.gridLayout_9.addItem(spacerItem4, 0, 3, 1, 1)
        self.label_16 = QtWidgets.QLabel(self.Settings)
        self.label_16.setObjectName("label_16")
        self.gridLayout_9.addWidget(self.label_16, 0, 2, 1, 1)
        self.lineEdit_alt_ths = QtWidgets.QLineEdit(self.Settings)
        self.lineEdit_alt_ths.setMinimumSize(QtCore.QSize(20, 0))
        self.lineEdit_alt_ths.setMaximumSize(QtCore.QSize(60, 16777215))
        self.lineEdit_alt_ths.setObjectName("lineEdit_alt_ths")
        self.gridLayout_9.addWidget(self.lineEdit_alt_ths, 0, 1, 1, 1)
        self.checkBox_waypoints = QtWidgets.QCheckBox(self.Settings)
        self.checkBox_waypoints.setChecked(True)
        self.checkBox_waypoints.setObjectName("checkBox_waypoints")
        self.gridLayout_9.addWidget(self.checkBox_waypoints, 1, 0, 1, 1)
        self.gridLayout.addLayout(self.gridLayout_9, 0, 0, 1, 1)
        self.line_9 = QtWidgets.QFrame(self.Settings)
        self.line_9.setFrameShape(QtWidgets.QFrame.HLine)
        self.line_9.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_9.setObjectName("line_9")
        self.gridLayout.addWidget(self.line_9, 5, 0, 1, 1)
        self.line_10 = QtWidgets.QFrame(self.Settings)
        self.line_10.setFrameShape(QtWidgets.QFrame.HLine)
        self.line_10.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_10.setObjectName("line_10")
        self.gridLayout.addWidget(self.line_10, 5, 2, 1, 1)
        self.label_4 = QtWidgets.QLabel(self.Settings)
        self.label_4.setObjectName("label_4")
        self.gridLayout.addWidget(self.label_4, 6, 0, 1, 1)
        self.gridLayout_5 = QtWidgets.QGridLayout()
        self.gridLayout_5.setSizeConstraint(QtWidgets.QLayout.SetDefaultConstraint)
        self.gridLayout_5.setSpacing(10)
        self.gridLayout_5.setObjectName("gridLayout_5")
        self.label_3 = QtWidgets.QLabel(self.Settings)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Preferred)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.label_3.sizePolicy().hasHeightForWidth())
        self.label_3.setSizePolicy(sizePolicy)
        self.label_3.setObjectName("label_3")
        self.gridLayout_5.addWidget(self.label_3, 0, 0, 1, 1)
        self.lineEdit_outName = QtWidgets.QLineEdit(self.Settings)
        self.lineEdit_outName.setObjectName("lineEdit_outName")
        self.gridLayout_5.addWidget(self.lineEdit_outName, 0, 1, 1, 1)
        self.label_8 = QtWidgets.QLabel(self.Settings)
        self.label_8.setObjectName("label_8")
        self.gridLayout_5.addWidget(self.label_8, 0, 2, 1, 1)
        self.gridLayout.addLayout(self.gridLayout_5, 4, 0, 1, 1)
        self.gridLayout_6 = QtWidgets.QGridLayout()
        self.gridLayout_6.setSizeConstraint(QtWidgets.QLayout.SetDefaultConstraint)
        self.gridLayout_6.setSpacing(10)
        self.gridLayout_6.setObjectName("gridLayout_6")
        self.checkBox_gridOn = QtWidgets.QCheckBox(self.Settings)
        self.checkBox_gridOn.setText("")
        self.checkBox_gridOn.setChecked(True)
        self.checkBox_gridOn.setObjectName("checkBox_gridOn")
        self.gridLayout_6.addWidget(self.checkBox_gridOn, 7, 1, 1, 1)
        self.label_10 = QtWidgets.QLabel(self.Settings)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Preferred)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.label_10.sizePolicy().hasHeightForWidth())
        self.label_10.setSizePolicy(sizePolicy)
        self.label_10.setMinimumSize(QtCore.QSize(70, 0))
        self.label_10.setObjectName("label_10")
        self.gridLayout_6.addWidget(self.label_10, 2, 0, 1, 1)
        self.checkBox_plotOff = QtWidgets.QCheckBox(self.Settings)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.checkBox_plotOff.sizePolicy().hasHeightForWidth())
        self.checkBox_plotOff.setSizePolicy(sizePolicy)
        self.checkBox_plotOff.setMinimumSize(QtCore.QSize(60, 0))
        self.checkBox_plotOff.setText("")
        self.checkBox_plotOff.setObjectName("checkBox_plotOff")
        self.gridLayout_6.addWidget(self.checkBox_plotOff, 2, 1, 1, 1)
        self.label_6 = QtWidgets.QLabel(self.Settings)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Preferred)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.label_6.sizePolicy().hasHeightForWidth())
        self.label_6.setSizePolicy(sizePolicy)
        self.label_6.setMinimumSize(QtCore.QSize(70, 0))
        self.label_6.setObjectName("label_6")
        self.gridLayout_6.addWidget(self.label_6, 4, 0, 1, 1)
        self.comboBox_plotBin = QtWidgets.QComboBox(self.Settings)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.comboBox_plotBin.sizePolicy().hasHeightForWidth())
        self.comboBox_plotBin.setSizePolicy(sizePolicy)
        self.comboBox_plotBin.setMinimumSize(QtCore.QSize(60, 0))
        self.comboBox_plotBin.setObjectName("comboBox_plotBin")
        self.gridLayout_6.addWidget(self.comboBox_plotBin, 4, 1, 1, 1)
        self.label_15 = QtWidgets.QLabel(self.Settings)
        self.label_15.setObjectName("label_15")
        self.gridLayout_6.addWidget(self.label_15, 7, 0, 1, 1)
        self.label_9 = QtWidgets.QLabel(self.Settings)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Preferred)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.label_9.sizePolicy().hasHeightForWidth())
        self.label_9.setSizePolicy(sizePolicy)
        self.label_9.setMinimumSize(QtCore.QSize(70, 0))
        self.label_9.setObjectName("label_9")
        self.gridLayout_6.addWidget(self.label_9, 6, 0, 1, 1)
        self.checkBox_labels = QtWidgets.QCheckBox(self.Settings)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.checkBox_labels.sizePolicy().hasHeightForWidth())
        self.checkBox_labels.setSizePolicy(sizePolicy)
        self.checkBox_labels.setMinimumSize(QtCore.QSize(60, 0))
        self.checkBox_labels.setText("")
        self.checkBox_labels.setObjectName("checkBox_labels")
        self.gridLayout_6.addWidget(self.checkBox_labels, 6, 1, 1, 1)
        self.checkBox_scrollable = QtWidgets.QCheckBox(self.Settings)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.checkBox_scrollable.sizePolicy().hasHeightForWidth())
        self.checkBox_scrollable.setSizePolicy(sizePolicy)
        self.checkBox_scrollable.setMinimumSize(QtCore.QSize(60, 0))
        self.checkBox_scrollable.setText("")
        self.checkBox_scrollable.setObjectName("checkBox_scrollable")
        self.gridLayout_6.addWidget(self.checkBox_scrollable, 5, 1, 1, 1)
        self.label_5 = QtWidgets.QLabel(self.Settings)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Preferred)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.label_5.sizePolicy().hasHeightForWidth())
        self.label_5.setSizePolicy(sizePolicy)
        self.label_5.setObjectName("label_5")
        self.gridLayout_6.addWidget(self.label_5, 5, 0, 1, 1)
        spacerItem5 = QtWidgets.QSpacerItem(20, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum)
        self.gridLayout_6.addItem(spacerItem5, 5, 2, 1, 1)
        self.gridLayout.addLayout(self.gridLayout_6, 2, 2, 3, 1)
        self.gridLayout_4.addLayout(self.gridLayout, 0, 0, 1, 1)
        self.tabWidget.addTab(self.Settings, "")
        self.verticalLayout.addWidget(self.tabWidget)
        self.verticalLayout_6.addLayout(self.verticalLayout)

        self.retranslateUi(Form)
        self.tabWidget.setCurrentIndex(0)
        QtCore.QMetaObject.connectSlotsByName(Form)
        Form.setTabOrder(self.btnRun, self.btnOpen)
        Form.setTabOrder(self.btnOpen, self.btnWrite)
        Form.setTabOrder(self.btnWrite, self.btnStop)
        Form.setTabOrder(self.btnStop, self.btnOpen)
        Form.setTabOrder(self.btnOpen, self.btnRun)
        Form.setTabOrder(self.btnRun, self.btnWrite)
        Form.setTabOrder(self.btnWrite, self.btnStop)

    def retranslateUi(self, Form):
        _translate = QtCore.QCoreApplication.translate
        Form.setWindowTitle(_translate("Form", "Runway Allocation"))
        self.btnOpen.setText(_translate("Form", "Select files"))
        self.btnRun.setText(_translate("Form", "Run"))
        self.btnLiveRun.setText(_translate("Form", "Live run"))
        self.btnWrite.setText(_translate("Form", "Write logs"))
        self.btnPause.setText(_translate("Form", "Pause"))
        self.btnStop.setText(_translate("Form", "Stop"))
        self.lblTime.setText(_translate("Form", "..."))
        self.lblProcess.setText(_translate("Form", "Process..."))
        self.lblCurrent.setText(_translate("Form", "..."))
        self.label_7.setText(_translate("Form", "[Press Alt if app does not refresh]"))
        self.lblHap.setText(_translate("Form", "Ready..."))
        self.dateTimeEdit_filterEnd.setDisplayFormat(_translate("Form", "yyyy-MM-dd hh:mm:ss"))
        self.label_14.setText(_translate("Form", "Start time:"))
        self.label_12.setText(_translate("Form", "Filter by aircraft model"))
        self.label.setText(_translate("Form", "End time:"))
        self.label_11.setText(_translate("Form", "Filter by airline"))
        self.dateTimeEdit_filterStart.setDisplayFormat(_translate("Form", "yyyy-MM-dd hh:mm:ss"))
        self.label_13.setText(_translate("Form", "Filter by config"))
        self.pushButton_resetFilter.setText(_translate("Form", "Reset"))
        self.lbl_config.setText(_translate("Form", "Configuration table"))
        self.tableConfig.setSortingEnabled(True)
        self.lbl_histo.setText(_translate("Form", "Throughput histogram"))
        self.tabWidget.setTabText(self.tabWidget.indexOf(self.Configuration), _translate("Form", "Configuration"))
        self.lbl_flights.setText(_translate("Form", "Operations table"))
        self.tableFlights.setSortingEnabled(True)
        self.tabWidget.setTabText(self.tabWidget.indexOf(self.Operations), _translate("Form", "Operations"))
        self.lbl_start_time.setText(_translate("Form", "Start date and time (UTC)"))
        self.dateTimeEdit_analyseEnd.setDisplayFormat(_translate("Form", "yyyy-MM-dd hh:mm:ss"))
        self.checkBoxDelimit.setText(_translate("Form", "Delimited time range"))
        self.dateTimeEdit_analyseStart.setDisplayFormat(_translate("Form", "yyyy-MM-dd hh:mm:ss"))
        self.lbl_end_time.setText(_translate("Form", "End date and time (UTC)"))
        self.label_2.setText(_translate("Form", "Refresh rate for live run"))
        self.spinBoxRate.setSuffix(_translate("Form", " (s)"))
        self.checkBox_alt_ths.setText(_translate("Form", "Operation timestamp on altitude threshold of"))
        self.label_16.setText(_translate("Form", " feet"))
        self.lineEdit_alt_ths.setText(_translate("Form", "3000"))
        self.checkBox_waypoints.setText(_translate("Form", "Evaluate waypoints (heavy processing)"))
        self.label_4.setText(_translate("Form", "Console:"))
        self.label_3.setText(_translate("Form", "Out file name:"))
        self.label_8.setText(_translate("Form", "(first database name by default)"))
        self.label_10.setText(_translate("Form", "Plotting off:"))
        self.label_6.setText(_translate("Form", "Bin size (min):"))
        self.label_15.setText(_translate("Form", "Grid on:"))
        self.label_9.setText(_translate("Form", "Labels:"))
        self.label_5.setText(_translate("Form", "Scrollable:"))
        self.tabWidget.setTabText(self.tabWidget.indexOf(self.Settings), _translate("Form", "Settings"))

    def set_controller(self, controller2):
        self.controller = controller2


class Form(QtWidgets.QWidget):
    def __init__(self):
        QtWidgets.QWidget.__init__(self)
        self.resizeEvent = self.onRezise

    def closeEvent(self, QCloseEvent):
        QCloseEvent.ignore()
        self.ui.controller.close_application()

    def set_ui(self, ui):
        self.ui = ui

    def onRezise(self, event):
        self.ui.matplotlibWidget.resize_fig()


def run():
    import controller
    import sys
    app = QtWidgets.QApplication(sys.argv)
    form = Form()
    ui = Ui_Form()
    ui.setupUi(form)
    ui.set_controller(controller.make_controller(ui))
    form.set_ui(ui)
    form.show()
    sys.exit(app.exec_())

