Compare commits

..

No commits in common. "249b0af4d1e149903b80294dd647fac944de7e85" and "b00080d5ed55fcf8ad657d7eed2f648c654642cf" have entirely different histories.

8 changed files with 900 additions and 326 deletions

View file

@ -1,5 +0,0 @@
wf-worldstate:
pyuic5 gui_base.ui -o gui_base.py
python -m nuitka main.py --follow-imports --nofollow-import-to=requests --nofollow-import-to=PyQt5
mv main.bin wf-worldstate && rm main.build/ -r

View file

@ -1,9 +0,0 @@
# wf-worldstate
Desktop based GUI for monitoring the warframe worldstate.
Looks ugly as hell but covers almost everything relevant.
Requires python, python-pyqt5 and python-requests.
`python main.py` to run, or use the makefile to create a single binary to execute.

9
api.py
View file

@ -1,6 +1,5 @@
import requests, json
# API request handler and data access
class WorldState():
def __init__(self):
self.client = requests.Session()
@ -13,15 +12,9 @@ class WorldState():
except requests.exceptions.ConnectionError:
return False
# aribtrary mapping, some skipped, some not-standard anyway
# better way is probably to do setattr in a loop, but then need to
# change code and handle baro.
# not willing to change it on the off chance much of this is replaced if
# content API becomes useful and names change again
self.fissures = self.ws.get('fissures')
self.invasions = self.ws.get('invasions')
self.sorties = self.ws.get('sortie')
self.sorties = self.ws.get('sorties')
self.archon_hunt = self.ws.get('archonHunt')
self.arbitration = self.ws.get('arbitration')
self.alerts = self.ws.get('alerts')

View file

@ -1,18 +1,9 @@
# custom widgets, code is largely ripped from placeholders from
# a generated gui_base.py file and additional bits slapped on
# and some minor changes in create_gui, mostly in naming of
# widgets including indexing and subobjects as well with self.i
from PyQt5 import QtWidgets, QtGui, QtCore
from datetime import datetime, timedelta
import time
# util for clocks
utcoffset = time.time() - time.mktime(time.gmtime())
class Fissure(QtWidgets.QWidget):
def __init__(self, parent, fissure_info = {}, i = 0):
def __init__(self, parent, fissure_info, i):
super().__init__(parent)
self.i = str(i)
self.fissure_info = fissure_info
@ -53,32 +44,26 @@ class Fissure(QtWidgets.QWidget):
self.FissureNode.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignTop)
self.FissureNode.setObjectName("FissureNode_" + self.i)
self.gridLayout_3.addWidget(self.FissureNode, 1, 0, 1, 1)
self.FissureType = QtWidgets.QLabel(self)
self.FissureType = QtWidgets.QLabel(Fissure)
self.FissureType.setAlignment(QtCore.Qt.AlignCenter)
self.FissureType.setObjectName("FissureType_" + self.i)
self.gridLayout_3.addWidget(self.FissureType, 1, 1, 1, 1)
def update_gui(self):
# attempt an update, will fail during initial pass before worldstate init so try-except
try:
self.FissureTier.setText(f"{self.fissure_info['tier']} - T{self.fissure_info['tierNum']}")
self.update_timer()
self.FissureNode.setText(f"{self.fissure_info['node']}")
self.FissureType.setText(f"{'Steel Path' if self.fissure_info['isHard'] else ('Storm' if self.fissure_info['isStorm'] else '')}")
except:
pass
self.FissureTier.setText(f"{self.fissure_info['tier']} - T{self.fissure_info['tierNum']}")
self.update_timer(self)
self.FissureNode.setText(f"{self.fissure_info['node']}")
self.FissureType.setText(f"{'Steel Path' if self.fissure_info['isHard'] else ('Storm' if self.fissure_info['isStorm'] else '')}")
def update_timer(self):
# update timer, same as global timers in main
eta = round(time.mktime(time.strptime(self.fissure_info['expiry'], '%Y-%m-%dT%H:%M:%S.%fZ')) - time.time() + utcoffset)
if eta >= 0:
self.FissureTimer.setText(f"{str(eta // 3600) + 'h' if eta // 3600 > 0 else ''} {(eta // 60) % 60}m {eta % 60}s")
else:
self.FissureTimer.setText("Expired")
def udpdate_timer(self):
eta = datetime.strptime(self.fissure_info['expiry'], '%Y-%m-%dT%H:%M:%SZ') - datetime.now()
eta -= timedelta(microseconds=eta.microseconds)
self.FissureTimer.setText(f"{eta.seconds // 3600}h {(eta.seconds // 60) % 60}m {eta.seconds % 60}s")
class Invasion(QtWidgets.QWidget):
def __init__(self, parent, invasion_info = {}, i = 0):
def __init__(self, parent, invasion_info, i):
super().__init__(parent)
self.i = str(i)
self.invasion_info = invasion_info
@ -93,7 +78,7 @@ class Invasion(QtWidgets.QWidget):
self.setSizePolicy(sizePolicy)
self.setMinimumSize(QtCore.QSize(0, 100))
self.setObjectName("Invasion_" + self.i)
self.gridLayout_4 = QtWidgets.QGridLayout(self)
self.gridLayout_4 = QtWidgets.QGridLayout(self.Invasion)
self.gridLayout_4.setObjectName("gridLayout_4_" + self.i)
self.Reward2 = QtWidgets.QLabel(self)
font = QtGui.QFont()
@ -121,22 +106,16 @@ class Invasion(QtWidgets.QWidget):
self.gridLayout_4.addWidget(self.Reward1, 0, 0, 1, 1)
def update_gui(self):
# same as Fissures, progress bars are colored according to factions involved, update css
try:
faction_colors = {'Grineer': 'red', 'Corpus': 'blue', 'Infested': 'green'}
self.Reward1.setText(f"{self.invasion_info['attackerReward']['itemString']}")
self.Reward2.setText(f"{self.invasion_info['defenderReward']['itemString']}")
self.InvasionProgress.setStyleSheet(f'QProgressBar {{background-color:{faction_colors.get(self.invasion_info["defendingFaction"])};border-color:red; border:0px}}\nQProgressBar::chunk {{background-color:{faction_colors.get(self.invasion_info["attackingFaction"])};}}')
self.update_progress()
except KeyError:
pass
faction_colors = {'Gineer': 'red', 'Corpus': 'blue', 'Infested': 'green'}
self.Reward1.setText(f"{self.invasion_info['attackerReward']['itemString']}")
self.Reward2.setText(f"{self.invasion_info['defenderReward']['itemString']}")
self.InvasionProgress.setStyleSheet(f'QProgressBar {{background-color:{faction_colors.get(self.invasion_info["defendingFaction"])};border-color:red; border:0px}}\nQProgressBar::chunk {{background-color:{faction_colors.get(self.invasion_info["attackingFaction"])};}}')
def update_progress(self):
# invasion progerss tracked with progressbar, set here as psuedo-timer
self.InvasionProgress.setProperty('value', self.invasion_info['completion'])
class Alert(QtWidgets.QWidget):
def __init__(self, parent, alert_info = {}, i = 0):
def __init__(self, parent, alert_info, i):
super().__init__(parent)
self.i = str(i)
self.alert_info = alert_info
@ -172,23 +151,16 @@ class Alert(QtWidgets.QWidget):
self.horizontalLayout_6.addWidget(self.AlertTimer)
def update_gui(self):
# same as fissure
try:
self.AlertReward.setText(self.alert_info['mission']['reward']['itemString'])
self.update_timer()
except:
pass
self.AlertReward.setText(self.alert_info['mission']['reward']['itemString'])
self.update_timer()
def update_timer(self):
# same as fissure
eta = round(time.mktime(time.strptime(self.alert_info['expiry'], '%Y-%m-%dT%H:%M:%S.%fZ')) - time.time() + utcoffset)
if eta > 0:
self.AlertTimer.setText(f'{str(eta // 86400) + "d " if eta // 86400 > 0 else ""}{str((eta // 3600) % 24) + "h" if eta // 3600 > 0 else ""} {(eta // 60) % 60}m {eta % 60}s')
else:
self.AlertTimer.setText('Expired')
eta = datetime.strptime(self.alert_info['expiry'], '%Y-%m-%dT%H:%M:%SZ') - datetime.now()
eta -= deltatime(microseconds=eta.microseconds)
self.AlertTimer.setText(f'{eta.days}d {eta.seconds // 3600}h {(eta.seconds // 60) % 60}m {eta.seconds % 60}s')
class BaroItem(QtWidgets.QWidget):
def __init__(self, parent, item_info = {}, i = 0):
def __init__(self, parent, item_info, i):
super().__init__(parent)
self.item_info = item_info
self.i = str(i)
@ -210,14 +182,10 @@ class BaroItem(QtWidgets.QWidget):
self.gridLayout_7.addWidget(self.ItemName, 0, 0, 1, 1)
def update_gui(self):
# same as fissure, except no dynamic timer needing updates
try:
self.ItemName.setText(self.item_info['item'])
except:
pass
self.ItemName.setText(self.item_info['item'])
class Event(QtWidgets.QWidget):
def __init__(self, parent, event_info = {}, i = 0):
def __init__(self, parent, event_info, i):
super().__init__(parent)
self.event_info = event_info
self.i = str(i)
@ -252,23 +220,16 @@ class Event(QtWidgets.QWidget):
self.horizontalLayout_11.addWidget(self.EventTimer)
def update_gui(self):
# same as fissure
try:
self.EventName.setText(self.event_info['description'])
self.update_timer()
except:
pass
self.EventName.setText(self.event_info['description'])
self.update_timer()
def update_timer(self):
# same as fissure
eta = round(time.mktime(time.strptime(self.event_info['expiry'], '%Y-%m-%dT%H:%M:%S.%fZ')) - time.time() + utcoffset)
if eta > 0:
self.EventTimer.setText(f'{str(eta // 86400) + "d " if eta // 86400 > 0 else ""}{(eta // 3600) % 24}h')
else:
self.EventTimer.setText('Expired')
eta = datetime.strptime(self.event_info['expiry'], '%Y-%m-%dT%H:%M:%SZ') - datetime.now()
eta -= deltatime(microseconds=eta.microseconds)
self.EventTimer.setText(f'{eta.days}d {eta.seconds // 3600}h {(eta.seconds // 60) % 60}m {eta.seconds % 60}s')
class NewsBlurb(QtWidgets.QWidget):
def __init__(self, parent, news_info = {}, i = 0):
def __init__(self, parent, news_info, i):
super().__init__(parent)
self.i = str(i)
self.news_info = news_info
@ -310,37 +271,14 @@ class NewsBlurb(QtWidgets.QWidget):
self.horizontalLayout_12.addWidget(self.NewsBlurbRelTimer)
def update_gui(self):
# same as fissure, except populate hyperlink instead of setting labels.
try:
self.NewsBlurbHyperLink.setText(f'<a href=\"{self.news_info["link"]}\">{self.news_info["message"]}</a>')
self.update_timer()
except:
pass
self.NewsBlurbHyperLink.setText(f'<a href=\"{self.news_info["link"]}\">{self.news_info["message"]}</a>')
self.update_timer()
def update_timer(self):
# timers are wonkier than fissure since there can be both start and end dates
# chosen strat:
# if event starts in the future:
# starts in
# elif event has started and end date not reached:
# ends in
# else if no end date and start date past if it even existed:
# just display time difference to date, as in 1d ago
#
# if time delta is > 1d, only display day, else h and min
prefix = ''
if self.news_info.get('startDate'):
eta = round(time.mktime(time.strptime(self.news_info.get('startDate'), '%Y-%m-%dT%H:%M:%S.%fZ')) - time.time() + utcoffset)
if eta > 0:
prefix = 'Starts in '
if self.news_info.get('endDate') and not prefix:
eta = round(time.mktime(time.strptime(self.news_info.get('endDate'), '%Y-%m-%dT%H:%M:%S.%fZ')) - time.time() + utcoffset)
if eta > 0:
prefix = 'Ends in '
eta = datetime.strptime(self.news_info['expiry'], '%Y-%m-%dT%H:%M:%SZ') - datetime.now()
eta -= deltatime(microseconds=eta.microseconds)
if abs(eta.days) >= 1:
self.NewsBlurbRelTimer.setText(f'{"Starts in " if eta.days > 0 else ""}{abs(eta.days)}')
else:
eta = round(time.mktime(time.strptime(self.news_info.get('date'), '%Y-%m-%dT%H:%M:%S.%fZ')) - time.time() + utcoffset)
if abs(eta) // 86400 >= 1:
self.NewsBlurbRelTimer.setText(f'{prefix}{abs(eta) // 86400}d')
else:
self.NewsBlurbRelTimer.setText(f'{prefix}{(abs(eta) // 3600) % 24}h {(abs(eta) // 60) % 60}m')
self.NewsBlurbRelTimer.setText(f'{"Starts in " if eta.seconds > 0 else ""}{abs(eta.seconds) // 3600}h {(abs(eta.seconds) // 60) % 60}m')

8
gui.py
View file

@ -1,18 +1,14 @@
import gui_base
from PyQt5 import QtCore, QtGui, QtWidgets
from PyQt5.QtWidgets import QApplication
import sys
import gui_base
# GUI constructor from generated gui_base file
# doesn't really need to exist but its here now
class GUI(QtWidgets.QMainWindow, gui_base.Ui_MainWindow):
class ExampleApp(QtWidgets.QMainWindow, gui_base.Ui_MainWindow):
def __init__(self, parent=None):
super().__init__(parent)
self.setupUi(self)
# test code
def main():
app = QApplication(sys.argv)
gui = ExampleApp()

810
gui_base.py Normal file
View file

@ -0,0 +1,810 @@
# -*- coding: utf-8 -*-
# Form implementation generated from reading ui file 'gui_base.ui'
#
# Created by: PyQt5 UI code generator 5.15.7
#
# WARNING: Any manual changes made to this file will be lost when pyuic5 is
# run again. Do not edit this file unless you know what you are doing.
from PyQt5 import QtCore, QtGui, QtWidgets
class Ui_MainWindow(object):
def setupUi(self, MainWindow):
MainWindow.setObjectName("MainWindow")
MainWindow.resize(1136, 890)
self.centralwidget = QtWidgets.QWidget(MainWindow)
self.centralwidget.setObjectName("centralwidget")
self.verticalLayout_18 = QtWidgets.QVBoxLayout(self.centralwidget)
self.verticalLayout_18.setObjectName("verticalLayout_18")
self.tabWidget = QtWidgets.QTabWidget(self.centralwidget)
self.tabWidget.setObjectName("tabWidget")
self.Timers = QtWidgets.QWidget()
self.Timers.setObjectName("Timers")
self.gridLayout = QtWidgets.QGridLayout(self.Timers)
self.gridLayout.setObjectName("gridLayout")
self.GlobalTimers = QtWidgets.QWidget(self.Timers)
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(1)
sizePolicy.setHeightForWidth(self.GlobalTimers.sizePolicy().hasHeightForWidth())
self.GlobalTimers.setSizePolicy(sizePolicy)
self.GlobalTimers.setObjectName("GlobalTimers")
self.horizontalLayout = QtWidgets.QHBoxLayout(self.GlobalTimers)
self.horizontalLayout.setObjectName("horizontalLayout")
self.BaroTimer = QtWidgets.QWidget(self.GlobalTimers)
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred)
sizePolicy.setHorizontalStretch(1)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.BaroTimer.sizePolicy().hasHeightForWidth())
self.BaroTimer.setSizePolicy(sizePolicy)
self.BaroTimer.setObjectName("BaroTimer")
self.verticalLayout_3 = QtWidgets.QVBoxLayout(self.BaroTimer)
self.verticalLayout_3.setObjectName("verticalLayout_3")
self.BaroStateStr = QtWidgets.QLabel(self.BaroTimer)
self.BaroStateStr.setScaledContents(False)
self.BaroStateStr.setAlignment(QtCore.Qt.AlignBottom|QtCore.Qt.AlignHCenter)
self.BaroStateStr.setObjectName("BaroStateStr")
self.verticalLayout_3.addWidget(self.BaroStateStr)
self.BaroTimeStr = QtWidgets.QLabel(self.BaroTimer)
font = QtGui.QFont()
font.setPointSize(17)
font.setBold(True)
font.setUnderline(False)
font.setWeight(75)
font.setKerning(True)
self.BaroTimeStr.setFont(font)
self.BaroTimeStr.setAlignment(QtCore.Qt.AlignCenter)
self.BaroTimeStr.setObjectName("BaroTimeStr")
self.verticalLayout_3.addWidget(self.BaroTimeStr)
self.horizontalLayout.addWidget(self.BaroTimer)
self.WeeklyTimer = QtWidgets.QWidget(self.GlobalTimers)
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred)
sizePolicy.setHorizontalStretch(1)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.WeeklyTimer.sizePolicy().hasHeightForWidth())
self.WeeklyTimer.setSizePolicy(sizePolicy)
self.WeeklyTimer.setObjectName("WeeklyTimer")
self.gridLayout_2 = QtWidgets.QGridLayout(self.WeeklyTimer)
self.gridLayout_2.setObjectName("gridLayout_2")
self.WeeklyResetTimeDayStr = QtWidgets.QLabel(self.WeeklyTimer)
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred)
sizePolicy.setHorizontalStretch(1)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.WeeklyResetTimeDayStr.sizePolicy().hasHeightForWidth())
self.WeeklyResetTimeDayStr.setSizePolicy(sizePolicy)
font = QtGui.QFont()
font.setPointSize(12)
font.setBold(True)
font.setWeight(75)
self.WeeklyResetTimeDayStr.setFont(font)
self.WeeklyResetTimeDayStr.setAlignment(QtCore.Qt.AlignRight|QtCore.Qt.AlignTrailing|QtCore.Qt.AlignVCenter)
self.WeeklyResetTimeDayStr.setObjectName("WeeklyResetTimeDayStr")
self.gridLayout_2.addWidget(self.WeeklyResetTimeDayStr, 1, 0, 1, 1)
self.WeeklyResetTimeStr = QtWidgets.QLabel(self.WeeklyTimer)
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred)
sizePolicy.setHorizontalStretch(2)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.WeeklyResetTimeStr.sizePolicy().hasHeightForWidth())
self.WeeklyResetTimeStr.setSizePolicy(sizePolicy)
font = QtGui.QFont()
font.setPointSize(17)
font.setBold(True)
font.setWeight(75)
self.WeeklyResetTimeStr.setFont(font)
self.WeeklyResetTimeStr.setObjectName("WeeklyResetTimeStr")
self.gridLayout_2.addWidget(self.WeeklyResetTimeStr, 1, 1, 1, 1)
self.WeeklyResetTextStr = QtWidgets.QLabel(self.WeeklyTimer)
self.WeeklyResetTextStr.setAlignment(QtCore.Qt.AlignBottom|QtCore.Qt.AlignHCenter)
self.WeeklyResetTextStr.setObjectName("WeeklyResetTextStr")
self.gridLayout_2.addWidget(self.WeeklyResetTextStr, 0, 0, 1, 2)
self.horizontalLayout.addWidget(self.WeeklyTimer)
self.BountyTimer = QtWidgets.QWidget(self.GlobalTimers)
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred)
sizePolicy.setHorizontalStretch(1)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.BountyTimer.sizePolicy().hasHeightForWidth())
self.BountyTimer.setSizePolicy(sizePolicy)
self.BountyTimer.setObjectName("BountyTimer")
self.verticalLayout_4 = QtWidgets.QVBoxLayout(self.BountyTimer)
self.verticalLayout_4.setObjectName("verticalLayout_4")
self.BountyStr = QtWidgets.QLabel(self.BountyTimer)
self.BountyStr.setAlignment(QtCore.Qt.AlignBottom|QtCore.Qt.AlignHCenter)
self.BountyStr.setObjectName("BountyStr")
self.verticalLayout_4.addWidget(self.BountyStr)
self.BountyTimeStr = QtWidgets.QLabel(self.BountyTimer)
font = QtGui.QFont()
font.setPointSize(17)
font.setBold(True)
font.setWeight(75)
self.BountyTimeStr.setFont(font)
self.BountyTimeStr.setAlignment(QtCore.Qt.AlignCenter)
self.BountyTimeStr.setObjectName("BountyTimeStr")
self.verticalLayout_4.addWidget(self.BountyTimeStr)
self.horizontalLayout.addWidget(self.BountyTimer)
self.gridLayout.addWidget(self.GlobalTimers, 0, 0, 1, 1)
self.MissionTimers = QtWidgets.QWidget(self.Timers)
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(2)
sizePolicy.setHeightForWidth(self.MissionTimers.sizePolicy().hasHeightForWidth())
self.MissionTimers.setSizePolicy(sizePolicy)
self.MissionTimers.setObjectName("MissionTimers")
self.horizontalLayout_2 = QtWidgets.QHBoxLayout(self.MissionTimers)
self.horizontalLayout_2.setObjectName("horizontalLayout_2")
self.Fissures = QtWidgets.QWidget(self.MissionTimers)
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred)
sizePolicy.setHorizontalStretch(1)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.Fissures.sizePolicy().hasHeightForWidth())
self.Fissures.setSizePolicy(sizePolicy)
self.Fissures.setObjectName("Fissures")
self.verticalLayout_5 = QtWidgets.QVBoxLayout(self.Fissures)
self.verticalLayout_5.setObjectName("verticalLayout_5")
self.label = QtWidgets.QLabel(self.Fissures)
self.label.setAlignment(QtCore.Qt.AlignCenter)
self.label.setObjectName("label")
self.verticalLayout_5.addWidget(self.label)
self.scrollArea = QtWidgets.QScrollArea(self.Fissures)
self.scrollArea.setWidgetResizable(True)
self.scrollArea.setObjectName("scrollArea")
self.scrollAreaWidgetContents = QtWidgets.QWidget()
self.scrollAreaWidgetContents.setGeometry(QtCore.QRect(0, 0, 240, 457))
self.scrollAreaWidgetContents.setObjectName("scrollAreaWidgetContents")
self.verticalLayout_6 = QtWidgets.QVBoxLayout(self.scrollAreaWidgetContents)
self.verticalLayout_6.setObjectName("verticalLayout_6")
self.Fissure = Fissure(self.scrollAreaWidgetContents)
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.Fissure.sizePolicy().hasHeightForWidth())
self.Fissure.setSizePolicy(sizePolicy)
self.Fissure.setMinimumSize(QtCore.QSize(0, 100))
self.Fissure.setObjectName("Fissure")
self.gridLayout_3 = QtWidgets.QGridLayout(self.Fissure)
self.gridLayout_3.setObjectName("gridLayout_3")
self.verticalLayout_6.addWidget(self.Fissure)
self.scrollArea.setWidget(self.scrollAreaWidgetContents)
self.verticalLayout_5.addWidget(self.scrollArea)
self.horizontalLayout_2.addWidget(self.Fissures)
self.Invasions = QtWidgets.QWidget(self.MissionTimers)
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred)
sizePolicy.setHorizontalStretch(1)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.Invasions.sizePolicy().hasHeightForWidth())
self.Invasions.setSizePolicy(sizePolicy)
self.Invasions.setObjectName("Invasions")
self.verticalLayout_7 = QtWidgets.QVBoxLayout(self.Invasions)
self.verticalLayout_7.setObjectName("verticalLayout_7")
self.label_2 = QtWidgets.QLabel(self.Invasions)
self.label_2.setAlignment(QtCore.Qt.AlignCenter)
self.label_2.setObjectName("label_2")
self.verticalLayout_7.addWidget(self.label_2)
self.scrollArea_2 = QtWidgets.QScrollArea(self.Invasions)
self.scrollArea_2.setWidgetResizable(True)
self.scrollArea_2.setObjectName("scrollArea_2")
self.scrollAreaWidgetContents_2 = QtWidgets.QWidget()
self.scrollAreaWidgetContents_2.setGeometry(QtCore.QRect(0, 0, 239, 457))
self.scrollAreaWidgetContents_2.setObjectName("scrollAreaWidgetContents_2")
self.verticalLayout_8 = QtWidgets.QVBoxLayout(self.scrollAreaWidgetContents_2)
self.verticalLayout_8.setObjectName("verticalLayout_8")
self.Invasion = Invasion(self.scrollAreaWidgetContents_2)
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.Invasion.sizePolicy().hasHeightForWidth())
self.Invasion.setSizePolicy(sizePolicy)
self.Invasion.setMinimumSize(QtCore.QSize(0, 100))
self.Invasion.setObjectName("Invasion")
self.gridLayout_4 = QtWidgets.QGridLayout(self.Invasion)
self.gridLayout_4.setObjectName("gridLayout_4")
self.verticalLayout_8.addWidget(self.Invasion)
self.scrollArea_2.setWidget(self.scrollAreaWidgetContents_2)
self.verticalLayout_7.addWidget(self.scrollArea_2)
self.horizontalLayout_2.addWidget(self.Invasions)
self.Sorties = QtWidgets.QWidget(self.MissionTimers)
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred)
sizePolicy.setHorizontalStretch(1)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.Sorties.sizePolicy().hasHeightForWidth())
self.Sorties.setSizePolicy(sizePolicy)
self.Sorties.setObjectName("Sorties")
self.verticalLayout_9 = QtWidgets.QVBoxLayout(self.Sorties)
self.verticalLayout_9.setObjectName("verticalLayout_9")
self.Sortie = QtWidgets.QWidget(self.Sorties)
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(1)
sizePolicy.setHeightForWidth(self.Sortie.sizePolicy().hasHeightForWidth())
self.Sortie.setSizePolicy(sizePolicy)
self.Sortie.setObjectName("Sortie")
self.verticalLayout_10 = QtWidgets.QVBoxLayout(self.Sortie)
self.verticalLayout_10.setObjectName("verticalLayout_10")
self.label_7 = QtWidgets.QLabel(self.Sortie)
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.label_7.sizePolicy().hasHeightForWidth())
self.label_7.setSizePolicy(sizePolicy)
self.label_7.setAlignment(QtCore.Qt.AlignCenter)
self.label_7.setObjectName("label_7")
self.verticalLayout_10.addWidget(self.label_7)
self.SortieResetTimer = QtWidgets.QLabel(self.Sortie)
font = QtGui.QFont()
font.setPointSize(12)
font.setBold(True)
font.setWeight(75)
self.SortieResetTimer.setFont(font)
self.SortieResetTimer.setAlignment(QtCore.Qt.AlignCenter)
self.SortieResetTimer.setObjectName("SortieResetTimer")
self.verticalLayout_10.addWidget(self.SortieResetTimer)
self.widget = QtWidgets.QWidget(self.Sortie)
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Expanding)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.widget.sizePolicy().hasHeightForWidth())
self.widget.setSizePolicy(sizePolicy)
self.widget.setObjectName("widget")
self.gridLayout_5 = QtWidgets.QGridLayout(self.widget)
self.gridLayout_5.setObjectName("gridLayout_5")
self.SortieM1 = QtWidgets.QLabel(self.widget)
self.SortieM1.setObjectName("SortieM1")
self.gridLayout_5.addWidget(self.SortieM1, 0, 0, 1, 1)
self.SortieM1Mod = QtWidgets.QLabel(self.widget)
self.SortieM1Mod.setAlignment(QtCore.Qt.AlignRight|QtCore.Qt.AlignTrailing|QtCore.Qt.AlignVCenter)
self.SortieM1Mod.setObjectName("SortieM1Mod")
self.gridLayout_5.addWidget(self.SortieM1Mod, 0, 1, 1, 1)
self.SortieM2 = QtWidgets.QLabel(self.widget)
self.SortieM2.setWordWrap(True)
self.SortieM2.setObjectName("SortieM2")
self.gridLayout_5.addWidget(self.SortieM2, 1, 0, 1, 1)
self.SrotieM2Mod = QtWidgets.QLabel(self.widget)
self.SrotieM2Mod.setAlignment(QtCore.Qt.AlignRight|QtCore.Qt.AlignTrailing|QtCore.Qt.AlignVCenter)
self.SrotieM2Mod.setWordWrap(True)
self.SrotieM2Mod.setObjectName("SrotieM2Mod")
self.gridLayout_5.addWidget(self.SrotieM2Mod, 1, 1, 1, 1)
self.SortieM3 = QtWidgets.QLabel(self.widget)
self.SortieM3.setObjectName("SortieM3")
self.gridLayout_5.addWidget(self.SortieM3, 2, 0, 1, 1)
self.SortieM3Mod = QtWidgets.QLabel(self.widget)
self.SortieM3Mod.setAlignment(QtCore.Qt.AlignRight|QtCore.Qt.AlignTrailing|QtCore.Qt.AlignVCenter)
self.SortieM3Mod.setObjectName("SortieM3Mod")
self.gridLayout_5.addWidget(self.SortieM3Mod, 2, 1, 1, 1)
self.verticalLayout_10.addWidget(self.widget)
self.verticalLayout_9.addWidget(self.Sortie)
self.ArchonHunt = QtWidgets.QWidget(self.Sorties)
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(1)
sizePolicy.setHeightForWidth(self.ArchonHunt.sizePolicy().hasHeightForWidth())
self.ArchonHunt.setSizePolicy(sizePolicy)
self.ArchonHunt.setObjectName("ArchonHunt")
self.verticalLayout_11 = QtWidgets.QVBoxLayout(self.ArchonHunt)
self.verticalLayout_11.setObjectName("verticalLayout_11")
self.ArchonHuntStr = QtWidgets.QLabel(self.ArchonHunt)
self.ArchonHuntStr.setAlignment(QtCore.Qt.AlignCenter)
self.ArchonHuntStr.setObjectName("ArchonHuntStr")
self.verticalLayout_11.addWidget(self.ArchonHuntStr)
self.ArchonHuntTimer = QtWidgets.QLabel(self.ArchonHunt)
font = QtGui.QFont()
font.setPointSize(12)
font.setBold(True)
font.setWeight(75)
self.ArchonHuntTimer.setFont(font)
self.ArchonHuntTimer.setAlignment(QtCore.Qt.AlignCenter)
self.ArchonHuntTimer.setObjectName("ArchonHuntTimer")
self.verticalLayout_11.addWidget(self.ArchonHuntTimer)
self.widget_2 = QtWidgets.QWidget(self.ArchonHunt)
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Expanding)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.widget_2.sizePolicy().hasHeightForWidth())
self.widget_2.setSizePolicy(sizePolicy)
self.widget_2.setObjectName("widget_2")
self.verticalLayout_12 = QtWidgets.QVBoxLayout(self.widget_2)
self.verticalLayout_12.setObjectName("verticalLayout_12")
self.ArchonHuntM1 = QtWidgets.QLabel(self.widget_2)
self.ArchonHuntM1.setAlignment(QtCore.Qt.AlignCenter)
self.ArchonHuntM1.setObjectName("ArchonHuntM1")
self.verticalLayout_12.addWidget(self.ArchonHuntM1)
self.ArchonHuntM2 = QtWidgets.QLabel(self.widget_2)
self.ArchonHuntM2.setAlignment(QtCore.Qt.AlignCenter)
self.ArchonHuntM2.setObjectName("ArchonHuntM2")
self.verticalLayout_12.addWidget(self.ArchonHuntM2)
self.ArchonHuntM3 = QtWidgets.QLabel(self.widget_2)
self.ArchonHuntM3.setAlignment(QtCore.Qt.AlignCenter)
self.ArchonHuntM3.setObjectName("ArchonHuntM3")
self.verticalLayout_12.addWidget(self.ArchonHuntM3)
self.verticalLayout_11.addWidget(self.widget_2)
self.verticalLayout_9.addWidget(self.ArchonHunt)
self.horizontalLayout_2.addWidget(self.Sorties)
self.Misc = QtWidgets.QWidget(self.MissionTimers)
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred)
sizePolicy.setHorizontalStretch(1)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.Misc.sizePolicy().hasHeightForWidth())
self.Misc.setSizePolicy(sizePolicy)
self.Misc.setObjectName("Misc")
self.verticalLayout_13 = QtWidgets.QVBoxLayout(self.Misc)
self.verticalLayout_13.setObjectName("verticalLayout_13")
self.Arbitration = QtWidgets.QWidget(self.Misc)
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(1)
sizePolicy.setHeightForWidth(self.Arbitration.sizePolicy().hasHeightForWidth())
self.Arbitration.setSizePolicy(sizePolicy)
self.Arbitration.setObjectName("Arbitration")
self.verticalLayout_14 = QtWidgets.QVBoxLayout(self.Arbitration)
self.verticalLayout_14.setObjectName("verticalLayout_14")
self.label_6 = QtWidgets.QLabel(self.Arbitration)
self.label_6.setAlignment(QtCore.Qt.AlignCenter)
self.label_6.setObjectName("label_6")
self.verticalLayout_14.addWidget(self.label_6)
self.stackedWidget = QtWidgets.QStackedWidget(self.Arbitration)
self.stackedWidget.setObjectName("stackedWidget")
self.ArbitrationNA = QtWidgets.QWidget()
self.ArbitrationNA.setObjectName("ArbitrationNA")
self.horizontalLayout_3 = QtWidgets.QHBoxLayout(self.ArbitrationNA)
self.horizontalLayout_3.setObjectName("horizontalLayout_3")
self.label_8 = QtWidgets.QLabel(self.ArbitrationNA)
self.label_8.setAlignment(QtCore.Qt.AlignCenter)
self.label_8.setObjectName("label_8")
self.horizontalLayout_3.addWidget(self.label_8)
self.stackedWidget.addWidget(self.ArbitrationNA)
self.ArbitrationData = QtWidgets.QWidget()
self.ArbitrationData.setObjectName("ArbitrationData")
self.horizontalLayout_4 = QtWidgets.QHBoxLayout(self.ArbitrationData)
self.horizontalLayout_4.setObjectName("horizontalLayout_4")
self.ArbitrationMT = QtWidgets.QLabel(self.ArbitrationData)
font = QtGui.QFont()
font.setPointSize(10)
font.setBold(True)
font.setWeight(75)
self.ArbitrationMT.setFont(font)
self.ArbitrationMT.setObjectName("ArbitrationMT")
self.horizontalLayout_4.addWidget(self.ArbitrationMT)
self.ArbitrationTimer = QtWidgets.QLabel(self.ArbitrationData)
font = QtGui.QFont()
font.setBold(True)
font.setWeight(75)
self.ArbitrationTimer.setFont(font)
self.ArbitrationTimer.setAlignment(QtCore.Qt.AlignRight|QtCore.Qt.AlignTrailing|QtCore.Qt.AlignVCenter)
self.ArbitrationTimer.setObjectName("ArbitrationTimer")
self.horizontalLayout_4.addWidget(self.ArbitrationTimer)
self.stackedWidget.addWidget(self.ArbitrationData)
self.verticalLayout_14.addWidget(self.stackedWidget)
self.verticalLayout_13.addWidget(self.Arbitration)
self.Alerts = QtWidgets.QWidget(self.Misc)
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(3)
sizePolicy.setHeightForWidth(self.Alerts.sizePolicy().hasHeightForWidth())
self.Alerts.setSizePolicy(sizePolicy)
self.Alerts.setObjectName("Alerts")
self.verticalLayout_15 = QtWidgets.QVBoxLayout(self.Alerts)
self.verticalLayout_15.setObjectName("verticalLayout_15")
self.label_9 = QtWidgets.QLabel(self.Alerts)
self.label_9.setAlignment(QtCore.Qt.AlignCenter)
self.label_9.setObjectName("label_9")
self.verticalLayout_15.addWidget(self.label_9)
self.scrollArea_3 = QtWidgets.QScrollArea(self.Alerts)
self.scrollArea_3.setWidgetResizable(True)
self.scrollArea_3.setObjectName("scrollArea_3")
self.scrollAreaWidgetContents_3 = QtWidgets.QWidget()
self.scrollAreaWidgetContents_3.setGeometry(QtCore.QRect(0, 0, 221, 313))
self.scrollAreaWidgetContents_3.setObjectName("scrollAreaWidgetContents_3")
self.verticalLayout_16 = QtWidgets.QVBoxLayout(self.scrollAreaWidgetContents_3)
self.verticalLayout_16.setObjectName("verticalLayout_16")
self.Alert = Alert(self.scrollAreaWidgetContents_3)
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.Alert.sizePolicy().hasHeightForWidth())
self.Alert.setSizePolicy(sizePolicy)
self.Alert.setMinimumSize(QtCore.QSize(0, 100))
self.Alert.setObjectName("Alert")
self.horizontalLayout_6 = QtWidgets.QHBoxLayout(self.Alert)
self.horizontalLayout_6.setObjectName("horizontalLayout_6")
self.verticalLayout_16.addWidget(self.Alert)
self.scrollArea_3.setWidget(self.scrollAreaWidgetContents_3)
self.verticalLayout_15.addWidget(self.scrollArea_3)
self.verticalLayout_13.addWidget(self.Alerts)
self.horizontalLayout_2.addWidget(self.Misc)
self.gridLayout.addWidget(self.MissionTimers, 1, 0, 1, 1)
self.tabWidget.addTab(self.Timers, "")
self.Baro = QtWidgets.QWidget()
self.Baro.setObjectName("Baro")
self.verticalLayout_2 = QtWidgets.QVBoxLayout(self.Baro)
self.verticalLayout_2.setObjectName("verticalLayout_2")
self.stackedWidget_2 = QtWidgets.QStackedWidget(self.Baro)
self.stackedWidget_2.setObjectName("stackedWidget_2")
self.BaroNA = QtWidgets.QWidget()
self.BaroNA.setObjectName("BaroNA")
self.verticalLayout_17 = QtWidgets.QVBoxLayout(self.BaroNA)
self.verticalLayout_17.setObjectName("verticalLayout_17")
self.label_10 = QtWidgets.QLabel(self.BaroNA)
font = QtGui.QFont()
font.setPointSize(25)
font.setBold(True)
font.setWeight(75)
self.label_10.setFont(font)
self.label_10.setAlignment(QtCore.Qt.AlignCenter)
self.label_10.setObjectName("label_10")
self.verticalLayout_17.addWidget(self.label_10)
self.stackedWidget_2.addWidget(self.BaroNA)
self.BaroData = QtWidgets.QWidget()
self.BaroData.setObjectName("BaroData")
self.gridLayout_6 = QtWidgets.QGridLayout(self.BaroData)
self.gridLayout_6.setObjectName("gridLayout_6")
self.BaroItem = BaroItem(self.BaroData)
self.BaroItem.setMaximumSize(QtCore.QSize(250, 250))
self.BaroItem.setObjectName("BaroItem")
self.gridLayout_7 = QtWidgets.QGridLayout(self.BaroItem)
self.gridLayout_7.setObjectName("gridLayout_7")
self.gridLayout_6.addWidget(self.BaroItem, 0, 0, 1, 1)
self.stackedWidget_2.addWidget(self.BaroData)
self.verticalLayout_2.addWidget(self.stackedWidget_2)
self.tabWidget.addTab(self.Baro, "")
self.Nightwave = QtWidgets.QWidget()
self.Nightwave.setObjectName("Nightwave")
self.horizontalLayout_7 = QtWidgets.QHBoxLayout(self.Nightwave)
self.horizontalLayout_7.setObjectName("horizontalLayout_7")
self.stackedWidget_3 = QtWidgets.QStackedWidget(self.Nightwave)
self.stackedWidget_3.setObjectName("stackedWidget_3")
self.NightwaveNA = QtWidgets.QWidget()
self.NightwaveNA.setObjectName("NightwaveNA")
self.horizontalLayout_8 = QtWidgets.QHBoxLayout(self.NightwaveNA)
self.horizontalLayout_8.setObjectName("horizontalLayout_8")
self.label_11 = QtWidgets.QLabel(self.NightwaveNA)
font = QtGui.QFont()
font.setPointSize(25)
font.setBold(True)
font.setWeight(75)
self.label_11.setFont(font)
self.label_11.setAlignment(QtCore.Qt.AlignCenter)
self.label_11.setObjectName("label_11")
self.horizontalLayout_8.addWidget(self.label_11)
self.stackedWidget_3.addWidget(self.NightwaveNA)
self.NightwaveData = QtWidgets.QWidget()
self.NightwaveData.setObjectName("NightwaveData")
self.gridLayout_8 = QtWidgets.QGridLayout(self.NightwaveData)
self.gridLayout_8.setObjectName("gridLayout_8")
self.widget_3 = QtWidgets.QWidget(self.NightwaveData)
self.widget_3.setObjectName("widget_3")
self.horizontalLayout_5 = QtWidgets.QHBoxLayout(self.widget_3)
self.horizontalLayout_5.setObjectName("horizontalLayout_5")
self.NightwaveDaily1 = QtWidgets.QWidget(self.widget_3)
self.NightwaveDaily1.setObjectName("NightwaveDaily1")
self.verticalLayout_19 = QtWidgets.QVBoxLayout(self.NightwaveDaily1)
self.verticalLayout_19.setObjectName("verticalLayout_19")
self.Daily1Name = QtWidgets.QLabel(self.NightwaveDaily1)
font = QtGui.QFont()
font.setPointSize(13)
font.setBold(True)
font.setWeight(75)
self.Daily1Name.setFont(font)
self.Daily1Name.setAlignment(QtCore.Qt.AlignBottom|QtCore.Qt.AlignHCenter)
self.Daily1Name.setObjectName("Daily1Name")
self.verticalLayout_19.addWidget(self.Daily1Name)
self.Daily1Desc = QtWidgets.QLabel(self.NightwaveDaily1)
self.Daily1Desc.setAlignment(QtCore.Qt.AlignHCenter|QtCore.Qt.AlignTop)
self.Daily1Desc.setObjectName("Daily1Desc")
self.verticalLayout_19.addWidget(self.Daily1Desc)
self.horizontalLayout_5.addWidget(self.NightwaveDaily1)
self.NightwaveDaily2 = QtWidgets.QWidget(self.widget_3)
self.NightwaveDaily2.setObjectName("NightwaveDaily2")
self.verticalLayout = QtWidgets.QVBoxLayout(self.NightwaveDaily2)
self.verticalLayout.setObjectName("verticalLayout")
self.Daily2Name = QtWidgets.QLabel(self.NightwaveDaily2)
font = QtGui.QFont()
font.setPointSize(13)
font.setBold(True)
font.setWeight(75)
self.Daily2Name.setFont(font)
self.Daily2Name.setAlignment(QtCore.Qt.AlignBottom|QtCore.Qt.AlignHCenter)
self.Daily2Name.setObjectName("Daily2Name")
self.verticalLayout.addWidget(self.Daily2Name)
self.Daily2Desc = QtWidgets.QLabel(self.NightwaveDaily2)
self.Daily2Desc.setAlignment(QtCore.Qt.AlignHCenter|QtCore.Qt.AlignTop)
self.Daily2Desc.setObjectName("Daily2Desc")
self.verticalLayout.addWidget(self.Daily2Desc)
self.horizontalLayout_5.addWidget(self.NightwaveDaily2)
self.NightwaveDaily3 = QtWidgets.QWidget(self.widget_3)
self.NightwaveDaily3.setObjectName("NightwaveDaily3")
self.verticalLayout_20 = QtWidgets.QVBoxLayout(self.NightwaveDaily3)
self.verticalLayout_20.setObjectName("verticalLayout_20")
self.Daily3Name = QtWidgets.QLabel(self.NightwaveDaily3)
font = QtGui.QFont()
font.setPointSize(13)
font.setBold(True)
font.setWeight(75)
self.Daily3Name.setFont(font)
self.Daily3Name.setAlignment(QtCore.Qt.AlignBottom|QtCore.Qt.AlignHCenter)
self.Daily3Name.setObjectName("Daily3Name")
self.verticalLayout_20.addWidget(self.Daily3Name)
self.Daily3Desc = QtWidgets.QLabel(self.NightwaveDaily3)
self.Daily3Desc.setAlignment(QtCore.Qt.AlignHCenter|QtCore.Qt.AlignTop)
self.Daily3Desc.setObjectName("Daily3Desc")
self.verticalLayout_20.addWidget(self.Daily3Desc)
self.horizontalLayout_5.addWidget(self.NightwaveDaily3)
self.NightwaveWeekly1 = QtWidgets.QWidget(self.widget_3)
self.NightwaveWeekly1.setObjectName("NightwaveWeekly1")
self.verticalLayout_21 = QtWidgets.QVBoxLayout(self.NightwaveWeekly1)
self.verticalLayout_21.setObjectName("verticalLayout_21")
self.Weekly1Name = QtWidgets.QLabel(self.NightwaveWeekly1)
font = QtGui.QFont()
font.setPointSize(13)
font.setBold(True)
font.setWeight(75)
self.Weekly1Name.setFont(font)
self.Weekly1Name.setAlignment(QtCore.Qt.AlignBottom|QtCore.Qt.AlignHCenter)
self.Weekly1Name.setObjectName("Weekly1Name")
self.verticalLayout_21.addWidget(self.Weekly1Name)
self.Weekly1Desc = QtWidgets.QLabel(self.NightwaveWeekly1)
self.Weekly1Desc.setAlignment(QtCore.Qt.AlignHCenter|QtCore.Qt.AlignTop)
self.Weekly1Desc.setObjectName("Weekly1Desc")
self.verticalLayout_21.addWidget(self.Weekly1Desc)
self.horizontalLayout_5.addWidget(self.NightwaveWeekly1)
self.NightwaveWeekly2 = QtWidgets.QWidget(self.widget_3)
self.NightwaveWeekly2.setObjectName("NightwaveWeekly2")
self.verticalLayout_22 = QtWidgets.QVBoxLayout(self.NightwaveWeekly2)
self.verticalLayout_22.setObjectName("verticalLayout_22")
self.Weekly2Name = QtWidgets.QLabel(self.NightwaveWeekly2)
font = QtGui.QFont()
font.setPointSize(13)
font.setBold(True)
font.setWeight(75)
self.Weekly2Name.setFont(font)
self.Weekly2Name.setAlignment(QtCore.Qt.AlignBottom|QtCore.Qt.AlignHCenter)
self.Weekly2Name.setObjectName("Weekly2Name")
self.verticalLayout_22.addWidget(self.Weekly2Name)
self.Weekly2Desc = QtWidgets.QLabel(self.NightwaveWeekly2)
self.Weekly2Desc.setAlignment(QtCore.Qt.AlignHCenter|QtCore.Qt.AlignTop)
self.Weekly2Desc.setObjectName("Weekly2Desc")
self.verticalLayout_22.addWidget(self.Weekly2Desc)
self.horizontalLayout_5.addWidget(self.NightwaveWeekly2)
self.gridLayout_8.addWidget(self.widget_3, 0, 0, 1, 1)
self.widget_4 = QtWidgets.QWidget(self.NightwaveData)
self.widget_4.setObjectName("widget_4")
self.horizontalLayout_9 = QtWidgets.QHBoxLayout(self.widget_4)
self.horizontalLayout_9.setObjectName("horizontalLayout_9")
self.NightwaveWeekly3 = QtWidgets.QWidget(self.widget_4)
self.NightwaveWeekly3.setObjectName("NightwaveWeekly3")
self.verticalLayout_23 = QtWidgets.QVBoxLayout(self.NightwaveWeekly3)
self.verticalLayout_23.setObjectName("verticalLayout_23")
self.Weekly3Name = QtWidgets.QLabel(self.NightwaveWeekly3)
font = QtGui.QFont()
font.setPointSize(13)
font.setBold(True)
font.setWeight(75)
self.Weekly3Name.setFont(font)
self.Weekly3Name.setAlignment(QtCore.Qt.AlignBottom|QtCore.Qt.AlignHCenter)
self.Weekly3Name.setObjectName("Weekly3Name")
self.verticalLayout_23.addWidget(self.Weekly3Name)
self.Weekly3Desc = QtWidgets.QLabel(self.NightwaveWeekly3)
self.Weekly3Desc.setAlignment(QtCore.Qt.AlignHCenter|QtCore.Qt.AlignTop)
self.Weekly3Desc.setObjectName("Weekly3Desc")
self.verticalLayout_23.addWidget(self.Weekly3Desc)
self.horizontalLayout_9.addWidget(self.NightwaveWeekly3)
self.NightwaveWeekly4 = QtWidgets.QWidget(self.widget_4)
self.NightwaveWeekly4.setObjectName("NightwaveWeekly4")
self.verticalLayout_24 = QtWidgets.QVBoxLayout(self.NightwaveWeekly4)
self.verticalLayout_24.setObjectName("verticalLayout_24")
self.Weekly4Name = QtWidgets.QLabel(self.NightwaveWeekly4)
font = QtGui.QFont()
font.setPointSize(13)
font.setBold(True)
font.setWeight(75)
self.Weekly4Name.setFont(font)
self.Weekly4Name.setAlignment(QtCore.Qt.AlignBottom|QtCore.Qt.AlignHCenter)
self.Weekly4Name.setObjectName("Weekly4Name")
self.verticalLayout_24.addWidget(self.Weekly4Name)
self.Weekly4Desc = QtWidgets.QLabel(self.NightwaveWeekly4)
self.Weekly4Desc.setAlignment(QtCore.Qt.AlignHCenter|QtCore.Qt.AlignTop)
self.Weekly4Desc.setObjectName("Weekly4Desc")
self.verticalLayout_24.addWidget(self.Weekly4Desc)
self.horizontalLayout_9.addWidget(self.NightwaveWeekly4)
self.NightwaveWeekly5 = QtWidgets.QWidget(self.widget_4)
self.NightwaveWeekly5.setObjectName("NightwaveWeekly5")
self.verticalLayout_25 = QtWidgets.QVBoxLayout(self.NightwaveWeekly5)
self.verticalLayout_25.setObjectName("verticalLayout_25")
self.Weekly5Name = QtWidgets.QLabel(self.NightwaveWeekly5)
font = QtGui.QFont()
font.setPointSize(13)
font.setBold(True)
font.setWeight(75)
self.Weekly5Name.setFont(font)
self.Weekly5Name.setAlignment(QtCore.Qt.AlignBottom|QtCore.Qt.AlignHCenter)
self.Weekly5Name.setObjectName("Weekly5Name")
self.verticalLayout_25.addWidget(self.Weekly5Name)
self.Weekly5Desc = QtWidgets.QLabel(self.NightwaveWeekly5)
self.Weekly5Desc.setAlignment(QtCore.Qt.AlignHCenter|QtCore.Qt.AlignTop)
self.Weekly5Desc.setObjectName("Weekly5Desc")
self.verticalLayout_25.addWidget(self.Weekly5Desc)
self.horizontalLayout_9.addWidget(self.NightwaveWeekly5)
self.NightwaveElite1 = QtWidgets.QWidget(self.widget_4)
self.NightwaveElite1.setObjectName("NightwaveElite1")
self.verticalLayout_26 = QtWidgets.QVBoxLayout(self.NightwaveElite1)
self.verticalLayout_26.setObjectName("verticalLayout_26")
self.Elite1Name = QtWidgets.QLabel(self.NightwaveElite1)
font = QtGui.QFont()
font.setPointSize(13)
font.setBold(True)
font.setWeight(75)
self.Elite1Name.setFont(font)
self.Elite1Name.setAlignment(QtCore.Qt.AlignBottom|QtCore.Qt.AlignHCenter)
self.Elite1Name.setObjectName("Elite1Name")
self.verticalLayout_26.addWidget(self.Elite1Name)
self.Elite1Desc = QtWidgets.QLabel(self.NightwaveElite1)
self.Elite1Desc.setAlignment(QtCore.Qt.AlignHCenter|QtCore.Qt.AlignTop)
self.Elite1Desc.setObjectName("Elite1Desc")
self.verticalLayout_26.addWidget(self.Elite1Desc)
self.horizontalLayout_9.addWidget(self.NightwaveElite1)
self.NightwaveElite2 = QtWidgets.QWidget(self.widget_4)
self.NightwaveElite2.setObjectName("NightwaveElite2")
self.verticalLayout_27 = QtWidgets.QVBoxLayout(self.NightwaveElite2)
self.verticalLayout_27.setObjectName("verticalLayout_27")
self.Elite2Name = QtWidgets.QLabel(self.NightwaveElite2)
font = QtGui.QFont()
font.setPointSize(13)
font.setBold(True)
font.setWeight(75)
self.Elite2Name.setFont(font)
self.Elite2Name.setAlignment(QtCore.Qt.AlignBottom|QtCore.Qt.AlignHCenter)
self.Elite2Name.setObjectName("Elite2Name")
self.verticalLayout_27.addWidget(self.Elite2Name)
self.Elite3Desc = QtWidgets.QLabel(self.NightwaveElite2)
self.Elite3Desc.setAlignment(QtCore.Qt.AlignHCenter|QtCore.Qt.AlignTop)
self.Elite3Desc.setObjectName("Elite3Desc")
self.verticalLayout_27.addWidget(self.Elite3Desc)
self.horizontalLayout_9.addWidget(self.NightwaveElite2)
self.gridLayout_8.addWidget(self.widget_4, 1, 0, 1, 1)
self.stackedWidget_3.addWidget(self.NightwaveData)
self.horizontalLayout_7.addWidget(self.stackedWidget_3)
self.tabWidget.addTab(self.Nightwave, "")
self.NewsAndEvents = QtWidgets.QWidget()
self.NewsAndEvents.setObjectName("NewsAndEvents")
self.horizontalLayout_10 = QtWidgets.QHBoxLayout(self.NewsAndEvents)
self.horizontalLayout_10.setObjectName("horizontalLayout_10")
self.Events = QtWidgets.QWidget(self.NewsAndEvents)
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred)
sizePolicy.setHorizontalStretch(1)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.Events.sizePolicy().hasHeightForWidth())
self.Events.setSizePolicy(sizePolicy)
self.Events.setObjectName("Events")
self.verticalLayout_30 = QtWidgets.QVBoxLayout(self.Events)
self.verticalLayout_30.setObjectName("verticalLayout_30")
self.label_12 = QtWidgets.QLabel(self.Events)
self.label_12.setAlignment(QtCore.Qt.AlignCenter)
self.label_12.setObjectName("label_12")
self.verticalLayout_30.addWidget(self.label_12)
self.scrollArea_4 = QtWidgets.QScrollArea(self.Events)
self.scrollArea_4.setWidgetResizable(True)
self.scrollArea_4.setObjectName("scrollArea_4")
self.scrollAreaWidgetContents_4 = QtWidgets.QWidget()
self.scrollAreaWidgetContents_4.setGeometry(QtCore.QRect(0, 0, 518, 743))
self.scrollAreaWidgetContents_4.setObjectName("scrollAreaWidgetContents_4")
self.verticalLayout_31 = QtWidgets.QVBoxLayout(self.scrollAreaWidgetContents_4)
self.verticalLayout_31.setObjectName("verticalLayout_31")
self.Event = Event(self.scrollAreaWidgetContents_4)
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.Event.sizePolicy().hasHeightForWidth())
self.Event.setSizePolicy(sizePolicy)
self.Event.setMinimumSize(QtCore.QSize(0, 100))
self.Event.setObjectName("Event")
self.horizontalLayout_11 = QtWidgets.QHBoxLayout(self.Event)
self.horizontalLayout_11.setObjectName("horizontalLayout_11")
self.verticalLayout_31.addWidget(self.Event)
self.scrollArea_4.setWidget(self.scrollAreaWidgetContents_4)
self.verticalLayout_30.addWidget(self.scrollArea_4)
self.horizontalLayout_10.addWidget(self.Events)
self.News = QtWidgets.QWidget(self.NewsAndEvents)
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred)
sizePolicy.setHorizontalStretch(1)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.News.sizePolicy().hasHeightForWidth())
self.News.setSizePolicy(sizePolicy)
self.News.setObjectName("News")
self.verticalLayout_32 = QtWidgets.QVBoxLayout(self.News)
self.verticalLayout_32.setObjectName("verticalLayout_32")
self.label_18 = QtWidgets.QLabel(self.News)
self.label_18.setAlignment(QtCore.Qt.AlignCenter)
self.label_18.setObjectName("label_18")
self.verticalLayout_32.addWidget(self.label_18)
self.scrollArea_5 = QtWidgets.QScrollArea(self.News)
self.scrollArea_5.setWidgetResizable(True)
self.scrollArea_5.setObjectName("scrollArea_5")
self.scrollAreaWidgetContents_5 = QtWidgets.QWidget()
self.scrollAreaWidgetContents_5.setGeometry(QtCore.QRect(0, 0, 518, 743))
self.scrollAreaWidgetContents_5.setObjectName("scrollAreaWidgetContents_5")
self.verticalLayout_33 = QtWidgets.QVBoxLayout(self.scrollAreaWidgetContents_5)
self.verticalLayout_33.setObjectName("verticalLayout_33")
self.NewsBlurb = NewsBlurb(self.scrollAreaWidgetContents_5)
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.NewsBlurb.sizePolicy().hasHeightForWidth())
self.NewsBlurb.setSizePolicy(sizePolicy)
self.NewsBlurb.setMinimumSize(QtCore.QSize(0, 100))
self.NewsBlurb.setObjectName("NewsBlurb")
self.horizontalLayout_12 = QtWidgets.QHBoxLayout(self.NewsBlurb)
self.horizontalLayout_12.setObjectName("horizontalLayout_12")
self.verticalLayout_33.addWidget(self.NewsBlurb)
self.scrollArea_5.setWidget(self.scrollAreaWidgetContents_5)
self.verticalLayout_32.addWidget(self.scrollArea_5)
self.horizontalLayout_10.addWidget(self.News)
self.tabWidget.addTab(self.NewsAndEvents, "")
self.verticalLayout_18.addWidget(self.tabWidget)
MainWindow.setCentralWidget(self.centralwidget)
self.statusbar = QtWidgets.QStatusBar(MainWindow)
self.statusbar.setObjectName("statusbar")
MainWindow.setStatusBar(self.statusbar)
self.retranslateUi(MainWindow)
self.tabWidget.setCurrentIndex(0)
QtCore.QMetaObject.connectSlotsByName(MainWindow)
def retranslateUi(self, MainWindow):
_translate = QtCore.QCoreApplication.translate
MainWindow.setWindowTitle(_translate("MainWindow", "Warframe World State"))
self.BaroStateStr.setText(_translate("MainWindow", "Baro Arrives in:"))
self.BaroTimeStr.setText(_translate("MainWindow", "0d 17h 25m 10s"))
self.WeeklyResetTimeDayStr.setText(_translate("MainWindow", "5d"))
self.WeeklyResetTimeStr.setText(_translate("MainWindow", "10h 29m 8s"))
self.WeeklyResetTextStr.setText(_translate("MainWindow", "Weekly Reset in:"))
self.BountyStr.setText(_translate("MainWindow", "Bounties reset in:"))
self.BountyTimeStr.setText(_translate("MainWindow", "2h 10m 5s"))
self.label.setText(_translate("MainWindow", "Fissures"))
self.label_2.setText(_translate("MainWindow", "Invasions"))
self.label_7.setText(_translate("MainWindow", "Sortie"))
self.SortieResetTimer.setText(_translate("MainWindow", "9h 18m 10s"))
self.SortieM1.setText(_translate("MainWindow", "Exterminate"))
self.SortieM1Mod.setText(_translate("MainWindow", "Energy Reduction"))
self.SortieM2.setText(_translate("MainWindow", "Sabotage"))
self.SrotieM2Mod.setText(_translate("MainWindow", "Enemy Elemental Enhancements"))
self.SortieM3.setText(_translate("MainWindow", "Assasination"))
self.SortieM3Mod.setText(_translate("MainWindow", "Sniper Only"))
self.ArchonHuntStr.setText(_translate("MainWindow", "Archon Hunt: Amar"))
self.ArchonHuntTimer.setText(_translate("MainWindow", "9d 9h 19m 8s"))
self.ArchonHuntM1.setText(_translate("MainWindow", "Sabotage"))
self.ArchonHuntM2.setText(_translate("MainWindow", "Survival"))
self.ArchonHuntM3.setText(_translate("MainWindow", "Assasinate"))
self.label_6.setText(_translate("MainWindow", "Arbitration"))
self.label_8.setText(_translate("MainWindow", "Arbitration not available"))
self.ArbitrationMT.setText(_translate("MainWindow", "Defection"))
self.ArbitrationTimer.setText(_translate("MainWindow", "55m 14s"))
self.label_9.setText(_translate("MainWindow", "Alerts"))
self.tabWidget.setTabText(self.tabWidget.indexOf(self.Timers), _translate("MainWindow", "Timers"))
self.label_10.setText(_translate("MainWindow", "Baro not here"))
self.tabWidget.setTabText(self.tabWidget.indexOf(self.Baro), _translate("MainWindow", "Baro"))
self.label_11.setText(_translate("MainWindow", "Nightwave not active"))
self.Daily1Name.setText(_translate("MainWindow", "Agent"))
self.Daily1Desc.setText(_translate("MainWindow", "Complete a Mission"))
self.Daily2Name.setText(_translate("MainWindow", "Agent"))
self.Daily2Desc.setText(_translate("MainWindow", "Complete a Mission"))
self.Daily3Name.setText(_translate("MainWindow", "Agent"))
self.Daily3Desc.setText(_translate("MainWindow", "Complete a Mission"))
self.Weekly1Name.setText(_translate("MainWindow", "Agent"))
self.Weekly1Desc.setText(_translate("MainWindow", "Complete a Mission"))
self.Weekly2Name.setText(_translate("MainWindow", "Agent"))
self.Weekly2Desc.setText(_translate("MainWindow", "Complete a Mission"))
self.Weekly3Name.setText(_translate("MainWindow", "Agent"))
self.Weekly3Desc.setText(_translate("MainWindow", "Complete a Mission"))
self.Weekly4Name.setText(_translate("MainWindow", "Agent"))
self.Weekly4Desc.setText(_translate("MainWindow", "Complete a Mission"))
self.Weekly5Name.setText(_translate("MainWindow", "Agent"))
self.Weekly5Desc.setText(_translate("MainWindow", "Complete a Mission"))
self.Elite1Name.setText(_translate("MainWindow", "Agent"))
self.Elite1Desc.setText(_translate("MainWindow", "Complete a Mission"))
self.Elite2Name.setText(_translate("MainWindow", "Agent"))
self.Elite3Desc.setText(_translate("MainWindow", "Complete a Mission"))
self.tabWidget.setTabText(self.tabWidget.indexOf(self.Nightwave), _translate("MainWindow", "Nightwave"))
self.label_12.setText(_translate("MainWindow", "Events"))
self.label_18.setText(_translate("MainWindow", "News"))
self.tabWidget.setTabText(self.tabWidget.indexOf(self.NewsAndEvents), _translate("MainWindow", "News and Events"))
from extra_widgets import Alert, BaroItem, Event, Fissure, Invasion, NewsBlurb

View file

@ -6,8 +6,8 @@
<rect>
<x>0</x>
<y>0</y>
<width>1155</width>
<height>877</height>
<width>1136</width>
<height>890</height>
</rect>
</property>
<property name="windowTitle">
@ -91,7 +91,7 @@
<widget class="QLabel" name="WeeklyResetTimeDayStr">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>2</horstretch>
<horstretch>1</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
@ -114,7 +114,7 @@
<widget class="QLabel" name="WeeklyResetTimeStr">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>3</horstretch>
<horstretch>2</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
@ -218,16 +218,16 @@
<property name="widgetResizable">
<bool>true</bool>
</property>
<widget class="QWidget" name="FissureHolder">
<widget class="QWidget" name="scrollAreaWidgetContents">
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>244</width>
<height>449</height>
<width>240</width>
<height>457</height>
</rect>
</property>
<layout class="QVBoxLayout" name="FissureList">
<layout class="QVBoxLayout" name="verticalLayout_6">
<item>
<widget class="Fissure" name="Fissure" native="true">
<property name="sizePolicy">
@ -276,16 +276,16 @@
<property name="widgetResizable">
<bool>true</bool>
</property>
<widget class="QWidget" name="InvasionHolder">
<widget class="QWidget" name="scrollAreaWidgetContents_2">
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>245</width>
<height>449</height>
<width>239</width>
<height>457</height>
</rect>
</property>
<layout class="QVBoxLayout" name="InvasionList">
<layout class="QVBoxLayout" name="verticalLayout_8">
<item>
<widget class="Invasion" name="Invasion" native="true">
<property name="sizePolicy">
@ -398,7 +398,7 @@
</widget>
</item>
<item row="1" column="1">
<widget class="QLabel" name="SortieM2Mod">
<widget class="QLabel" name="SrotieM2Mod">
<property name="text">
<string>Enemy Elemental Enhancements</string>
</property>
@ -452,6 +452,23 @@
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="ArchonHuntTimer">
<property name="font">
<font>
<pointsize>12</pointsize>
<weight>75</weight>
<bold>true</bold>
</font>
</property>
<property name="text">
<string>9d 9h 19m 8s</string>
</property>
<property name="alignment">
<set>Qt::AlignCenter</set>
</property>
</widget>
</item>
<item>
<widget class="QWidget" name="widget_2" native="true">
<property name="sizePolicy">
@ -529,7 +546,7 @@
</widget>
</item>
<item>
<widget class="QStackedWidget" name="ArbitrationTabs">
<widget class="QStackedWidget" name="stackedWidget">
<widget class="QWidget" name="ArbitrationNA">
<layout class="QHBoxLayout" name="horizontalLayout_3">
<item>
@ -561,7 +578,7 @@
</widget>
</item>
<item>
<widget class="QLabel" name="ArbitrationFaction">
<widget class="QLabel" name="ArbitrationTimer">
<property name="font">
<font>
<weight>75</weight>
@ -569,7 +586,7 @@
</font>
</property>
<property name="text">
<string>Infested</string>
<string>55m 14s</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
@ -607,16 +624,16 @@
<property name="widgetResizable">
<bool>true</bool>
</property>
<widget class="QWidget" name="AlertHolder">
<widget class="QWidget" name="scrollAreaWidgetContents_3">
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>226</width>
<height>307</height>
<width>221</width>
<height>313</height>
</rect>
</property>
<layout class="QVBoxLayout" name="AlertList">
<layout class="QVBoxLayout" name="verticalLayout_16">
<item>
<widget class="Alert" name="Alert" native="true">
<property name="sizePolicy">
@ -655,7 +672,7 @@
</attribute>
<layout class="QVBoxLayout" name="verticalLayout_2">
<item>
<widget class="QStackedWidget" name="BaroTabs">
<widget class="QStackedWidget" name="stackedWidget_2">
<widget class="QWidget" name="BaroNA">
<layout class="QVBoxLayout" name="verticalLayout_17">
<item>
@ -702,7 +719,7 @@
</attribute>
<layout class="QHBoxLayout" name="horizontalLayout_7">
<item>
<widget class="QStackedWidget" name="NightwaveTabs">
<widget class="QStackedWidget" name="stackedWidget_3">
<widget class="QWidget" name="NightwaveNA">
<layout class="QHBoxLayout" name="horizontalLayout_8">
<item>
@ -1053,7 +1070,7 @@
</widget>
</item>
<item>
<widget class="QLabel" name="Elite2Desc">
<widget class="QLabel" name="Elite3Desc">
<property name="text">
<string>Complete a Mission</string>
</property>
@ -1103,16 +1120,16 @@
<property name="widgetResizable">
<bool>true</bool>
</property>
<widget class="QWidget" name="EventHolder">
<widget class="QWidget" name="scrollAreaWidgetContents_4">
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>528</width>
<height>730</height>
<width>518</width>
<height>743</height>
</rect>
</property>
<layout class="QVBoxLayout" name="EventsList">
<layout class="QVBoxLayout" name="verticalLayout_31">
<item>
<widget class="Event" name="Event" native="true">
<property name="sizePolicy">
@ -1161,16 +1178,16 @@
<property name="widgetResizable">
<bool>true</bool>
</property>
<widget class="QWidget" name="NewsHolder">
<widget class="QWidget" name="scrollAreaWidgetContents_5">
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>527</width>
<height>730</height>
<width>518</width>
<height>743</height>
</rect>
</property>
<layout class="QVBoxLayout" name="NewsList">
<layout class="QVBoxLayout" name="verticalLayout_33">
<item>
<widget class="NewsBlurb" name="NewsBlurb" native="true">
<property name="sizePolicy">

166
main.py
View file

@ -1,166 +0,0 @@
# central controller, main loop
from gui import GUI
from api import WorldState
from extra_widgets import *
from PyQt5.QtWidgets import QApplication, QMessageBox
from PyQt5.QtCore import QTimer
import sys
class App(GUI):
def __init__(self):
super().__init__()
# fetch world state info from API
self.ws = WorldState()
# if bad fetch, error for retry until quit or fetched
while self.ws.ws == {}:
self.network_error()
sys.exit(1)
# remove placeholder templates for given widgets, replaced with actual data later in redraw
[widget.setParent(None) for widget in [self.Fissure, self.Invasion, self.Alert, self.BaroItem, self.Event, self.NewsBlurb]]
# update interval for clocks
self.timers_timer = QTimer(self)
self.timers_timer.timeout.connect(self.update_timers)
self.timers_timer.start(1000)
# update interval for data refresh
self.ws_update_timer = QTimer(self)
self.ws_update_timer.timeout.connect(self.update_world_state)
self.ws_update_timer.start(1000 * 60 * 5)
# largely just creating custom widgets, and mapping to existing parent widgets
self.redraw_content()
def redraw_content(self):
self.redraw_content_dynamic() # content that varies in number, invasions, fissures, etc
self.redraw_content_static() # static content that won't change/only one, arbi, archons, etc
def redraw_content_dynamic(self):
self.Fissure_list = [Fissure(self.FissureHolder, fissure_info, fissure_i) for (fissure_i, fissure_info) in enumerate(self.ws.fissures)]
[self.FissureList.addWidget(i) for i in self.Fissure_list]
self.Invasion_list = [Invasion(self.InvasionHolder, invasion_info, invasion_i) for (invasion_i, invasion_info) in enumerate(self.ws.invasions)]
[self.InvasionList.addWidget(i) for i in self.Invasion_list]
self.Alert_list = [Alert(self.AlertHolder, alert_info, alert_i) for (alert_i, alert_info) in enumerate(self.ws.alerts)]
[self.AlertList.addWidget(i) for i in self.Alert_list]
# if baro key is [], no baro, switch tab to inactive, else populate grid
if len(self.ws.baro_items) == 0:
self.BaroTabs.setCurrentIndex(0)
else:
self.BaroTabs.setCurrentIndex(1)
self.baro_items_list = [BaroItem(self.BaroData, item_info, item_i) for (item_i, item_info) in enumerate(self.ws.baro_items)]
[self.gridLayout_6.addWidget(i, index // 7, index % 7, 1, 1) for (index, i) in enumerate(self.baro_items_list)]
self.events_list = [Event(self.EventHolder, event_info, event_i) for (event_i, event_info) in enumerate(self.ws.events)]
[self.EventsList.addWidget(i) for i in self.events_list]
self.newsblurb_list = [NewsBlurb(self.NewsHolder, newsblurb_info, newsblurb_i) for (newsblurb_i, newsblurb_info) in enumerate(self.ws.news)]
[self.NewsList.addWidget(i) for i in self.newsblurb_list]
def redraw_content_static(self):
for i in range(1, 4):
getattr(self, 'SortieM' + str(i)).setText(self.ws.sorties['variants'][i - 1]['missionType'])
getattr(self, 'SortieM' + str(i) + 'Mod').setText(self.ws.sorties['variants'][i-1]['modifier'])
self.ArchonHuntStr.setText('Archon Hunt: ' + self.ws.archon_hunt['boss'])
for i in range(1, 4):
getattr(self, 'ArchonHuntM' + str(i)).setText(self.ws.archon_hunt['missions'][i - 1]['type'])
# warframestat.us arbi jank fix until content API adds arbis and can use that directly
if not self.ws.arbitration:
self.ArbitrationTabs.setCurrentIndex(0)
else:
self.ArbitrationTabs.setCurrentIndex(1)
self.ArbitrationMT.setText(self.ws.arbitration['type'])
self.ArbitrationFaction.setText(self.ws.arbitration['enemy'])
# nightwave mission mapping if active
daily_i = 1
weekly_i = 1
elite_i = 1
if self.ws.nightwave:
self.NightwaveTabs.setCurrentIndex(1)
for challenge in self.ws.nightwave['activeChallenges']:
if challenge.get('isDaily'):
challenge_type = 'Daily'
challenge_i = daily_i
daily_i += 1
elif challenge.get('isElite'):
challenge_type = 'Elite'
challenge_i = weekly_i
weekly_i += 1
else:
challenge_type = 'Weekly'
challenge_i = elite_i
elite_i += 1
getattr(self, challenge_type + str(challenge_i) + 'Name').setText(challenge['title'])
getattr(self, challenge_type + str(challenge_i) + 'Desc').setText(challenge['desc'])
else:
self.NightwaveTabs.setCurrentIndex(0)
def update_timers(self):
# call timer updates and invasion progress changes
[i.update_timer() for i in self.Fissure_list]
[i.update_progress() for i in self.Invasion_list]
[i.update_timer() for i in self.Alert_list]
[i.update_timer() for i in self.events_list]
[i.update_timer() for i in self.newsblurb_list]
# parse expiry datestring and calc sortie expiry time delta from now to listed expiry
sortie_eta = round(time.mktime(time.strptime(self.ws.sorties['expiry'], '%Y-%m-%dT%H:%M:%S.%fZ')) - time.mktime(time.gmtime()))
if sortie_eta >= 0:
self.SortieResetTimer.setText(f'{str(sortie_eta // 3600) + "h " if sortie_eta // 3600 > 0 else ""}{(sortie_eta // 60) % 60}m {sortie_eta % 60}s')
else:
self.SortieResetTimer.setText('Expired')
# same as sortie, except expiry happens at Monday 00:00 UTC), 3 days for epoch adjust from Wed
# % week for weekly timer diff since last Monday
# day str listed separately for display formatting
weekly_eta = round(time.mktime(time.strptime('1970-1-1T00:00:00.000Z', '%Y-%m-%dT%H:%M:%S.%fZ')) - time.mktime(time.gmtime()) - 3 * 86400) % (7 * 86400)
self.WeeklyResetTimeDayStr.setText(str(weekly_eta // 86400) + 'd')
self.WeeklyResetTimeStr.setText(f'{(weekly_eta // 3600) % 24}h {(weekly_eta // 60) % 60}m {weekly_eta % 60}s')
# same as above, bounties reset at given time adjust, 2.5hr cycle
bounty_eta = round(time.mktime(time.strptime('1970-1-1T00:00:00.000Z', '%Y-%m-%dT%H:%M:%S.%fZ')) - time.mktime(time.gmtime()) + 120) % (9000)
self.BountyTimeStr.setText(f'{bounty_eta // 3600}h {(bounty_eta // 60) % 60}m {bounty_eta % 60}s')
# baro reset adjust, 2 week cycle in full.
# arrives at 2 days left, present < 2 days.
baro_eta = round(time.mktime(time.strptime('1970-1-1T00:00:00.000Z', '%Y-%m-%dT%H:%M:%S.%fZ')) - time.mktime(time.gmtime()) + (10*86400 + 13 * 3600)) % (14 * 86400)
if baro_eta >= 2 * 86400:
self.BaroStateStr.setText('Baro Arrives in:')
baro_eta = baro_eta - 2 * 86400
else:
self.BaroStateStr.setText('Baro Leaves in:')
self.BaroTimeStr.setText(f'{str(baro_eta // 86400) + "d " if baro_eta // 86400 > 0 else ""}{(baro_eta // 3600) % 24}h {(baro_eta // 60) % 60}m {baro_eta % 60}s')
def update_world_state(self):
if self.ws.get_ws():
self.redraw_content()
else:
self.network_error()
def network_error(self):
# slapped on later, just a dialog box for network error
msg = QMessageBox()
msg.setIcon(QMessageBox.Critical)
msg.setText('Network Error')
msg.setInformativeText('Could not connect to api.warframestat.us')
msg.setWindowTitle('Error')
msg.exec_()
if __name__ == '__main__':
app_handle = QApplication(sys.argv)
app = App()
app.show()
app_handle.exec_()