Add settings window and Qt imports
This commit is contained in:
parent
fdc7c90e84
commit
df81802291
11
UI/settings.py
Normal file
11
UI/settings.py
Normal file
@ -0,0 +1,11 @@
|
||||
import PyQt5.QtWidgets as QtWidgets
|
||||
|
||||
class Settings(QtWidgets.QWidget):
|
||||
def __init__(self, parent=None):
|
||||
super().__init__(parent)
|
||||
self.show_window()
|
||||
|
||||
def show_window(self):
|
||||
self.resize(300, 100)
|
||||
self.setWindowTitle("Prosty kalkulator")
|
||||
self.show()
|
@ -2,7 +2,7 @@ import pygame as pg
|
||||
import numpy as np
|
||||
import random
|
||||
from UI.grid import Grid, Node
|
||||
from UI.Apath import a_path
|
||||
from Logic.Apath import a_path
|
||||
|
||||
|
||||
class Window():
|
||||
|
8
main.py
8
main.py
@ -1,8 +1,14 @@
|
||||
from UI.grid import Grid
|
||||
from UI.window import Window
|
||||
|
||||
from UI.settings import Settings
|
||||
import PyQt5.QtWidgets as QtWidgets
|
||||
|
||||
def main():
|
||||
import sys
|
||||
|
||||
app = QtWidgets.QApplication(sys.argv)
|
||||
Settings()
|
||||
app.exec()
|
||||
# initialize grid
|
||||
grid = Grid(20, 20)
|
||||
# initialize window (grid, start,end,mode)
|
||||
|
Loading…
Reference in New Issue
Block a user