Skip to content

Commit

Permalink
I am failing my most important exams
Browse files Browse the repository at this point in the history
  • Loading branch information
KorryKatti committed Apr 3, 2024
1 parent 3b3eb46 commit 39df9c0
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 16 deletions.
5 changes: 5 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,3 +23,8 @@ yay -S python-pyqt5 qt5-webengine

yay -S python-gobject python-gobject-cairo gtk3 webkit2gtk

sudo pacman -S base-devel

sudo pacman -S python-gobject python-cairo gtk3 webkit2gtk


25 changes: 10 additions & 15 deletions appfiles/comm/community.py
Original file line number Diff line number Diff line change
@@ -1,26 +1,21 @@
import sys
from PyQt5.QtWidgets import QApplication, QMainWindow, QWidget, QVBoxLayout
from PyQt5.QtWidgets import QApplication, QMainWindow
from PyQt5.QtCore import QUrl
from PyQt5.QtWebEngineWidgets import QWebEngineView

class WebWindow(QMainWindow):
def __init__(self, url):
class MainWindow(QMainWindow):
def __init__(self):
super().__init__()

self.setWindowTitle("Embedded Web Page")
self.setGeometry(100, 100, 800, 600)

self.central_widget = QWidget()
self.setCentralWidget(self.central_widget)
self.layout = QVBoxLayout(self.central_widget)
self.setWindowTitle("Embedded Web Browser")
self.setGeometry(100, 100, 800, 600)

self.browser = QWebEngineView()
self.layout.addWidget(self.browser)
self.browser.load(QUrl(url))
web_view = QWebEngineView()
web_view.setUrl(QUrl('https://example.com')) # Create QUrl object from URL string
self.setCentralWidget(web_view)

if __name__ == "__main__":
if __name__ == '__main__':
app = QApplication(sys.argv)
url = "https://www.example.com"
window = WebWindow(url)
window = MainWindow()
window.show()
sys.exit(app.exec_())
2 changes: 1 addition & 1 deletion index.py
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ def optionmenu_callback(choice):
create_labels()
elif choice == "Client Update":
app.destroy() # Close the current window
subprocess.Popen(["python", "updater.py"]) # Run updater.py
subprocess.Popen(["python", "main.py"]) # Run main.py

# Callback Function for Libmenu
def libmenu_callback(choice):
Expand Down
2 changes: 2 additions & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,6 @@ PyQtWebEngine
PyQt5
tkhtmlview
tkinterweb
PyGObject


0 comments on commit 39df9c0

Please sign in to comment.