0% found this document useful (0 votes)
10 views18 pages

Code Python 2

The document outlines the creation of a modern web browser named Quarix, which incorporates various features such as a user-friendly GUI, tabbed browsing, bookmarks, history management, and a chat interface with an AI assistant. It utilizes multiple libraries including PyQt5 for the interface and SQLite for data storage, and includes functionalities for navigation, settings management, and a customizable appearance. The code provides a comprehensive structure for setting up the browser, including database initialization, UI setup, and user interaction handling.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
10 views18 pages

Code Python 2

The document outlines the creation of a modern web browser named Quarix, which incorporates various features such as a user-friendly GUI, tabbed browsing, bookmarks, history management, and a chat interface with an AI assistant. It utilizes multiple libraries including PyQt5 for the interface and SQLite for data storage, and includes functionalities for navigation, settings management, and a customizable appearance. The code provides a comprehensive structure for setting up the browser, including database initialization, UI setup, and user interaction handling.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 18

I'll create a modern browser with all the features you requested.

This will be
a comprehensive application using multiple libraries for the best GUI
experience.
import sys
import os
import json
import sqlite3
from datetime import datetime
import requests
import threading
import webbrowser
from urllib.parse import urlparse, urljoin
import re

# GUI Libraries
import customtkinter as ctk
from PyQt5.QtWidgets import *
from PyQt5.QtCore import *
from PyQt5.QtGui import *
from PyQt5.QtWebEngineWidgets import *
import tkinter as tk
from tkinter import ttk, messagebox, filedialog

# Set appearance
ctk.set_appearance_mode("dark")
ctk.set_default_color_theme("blue")

class QuarixBrowser:
def __init__(self):
self.app = QApplication(sys.argv)
self.main_window = QMainWindow()
self.tabs = QTabWidget()
self.bookmarks = []
self.history = []
self.downloads = []
self.settings = self.load_settings()
self.gemini_api_key = "YOUR_GEMINI_API_KEY_HERE" # Replace
with your actual API key

self.setup_database()
self.setup_ui()
self.setup_styles()

def setup_database(self):
"""Setup SQLite database for browser data"""
self.conn = sqlite3.connect('quarix_browser.db')
cursor = self.conn.cursor()
# Create tables
cursor.execute('''
CREATE TABLE IF NOT EXISTS history (
id INTEGER PRIMARY KEY,
url TEXT,
title TEXT,
timestamp DATETIME
)
''')

cursor.execute('''
CREATE TABLE IF NOT EXISTS bookmarks (
id INTEGER PRIMARY KEY,
url TEXT,
title TEXT,
folder TEXT
)
''')

cursor.execute('''
CREATE TABLE IF NOT EXISTS downloads (
id INTEGER PRIMARY KEY,
filename TEXT,
url TEXT,
path TEXT,
timestamp DATETIME
)
''')

self.conn.commit()

def setup_ui(self):
"""Setup the main user interface"""
self.main_window.setWindowTitle("Quarix Browser - Next
Generation Web Experience")
self.main_window.setGeometry(100, 100, 1400, 900)
self.main_window.setWindowIcon(QIcon("quarix_logo.png")) #
Add your logo here

# Central widget
central_widget = QWidget()
self.main_window.setCentralWidget(central_widget)
layout = QVBoxLayout(central_widget)

# Create toolbar
self.create_toolbar()

# Create address bar


self.create_address_bar()
# Setup tabs
self.tabs.setTabsClosable(True)
self.tabs.tabCloseRequested.connect(self.close_tab)
self.tabs.currentChanged.connect(self.current_tab_changed)

layout.addWidget(self.tabs)

# Create initial tab


self.add_new_tab("https://www.google.com", "New Tab")

# Create status bar


self.status_bar = QStatusBar()
self.main_window.setStatusBar(self.status_bar)

# Create side panel for Quarix Chat


self.create_quarix_chat_panel()

def create_toolbar(self):
"""Create the main toolbar"""
toolbar = QToolBar()
self.main_window.addToolBar(toolbar)

# Navigation buttons
back_btn = QAction("←", self.main_window)
back_btn.setStatusTip("Go back")
back_btn.triggered.connect(self.navigate_back)
toolbar.addAction(back_btn)

forward_btn = QAction("→", self.main_window)


forward_btn.setStatusTip("Go forward")
forward_btn.triggered.connect(self.navigate_forward)
toolbar.addAction(forward_btn)

reload_btn = QAction("⟳", self.main_window)


reload_btn.setStatusTip("Reload page")
reload_btn.triggered.connect(self.reload_page)
toolbar.addAction(reload_btn)

home_btn = QAction("🏠", self.main_window)


home_btn.setStatusTip("Go home")
home_btn.triggered.connect(self.navigate_home)
toolbar.addAction(home_btn)

toolbar.addSeparator()

# New tab button


new_tab_btn = QAction("+ Tab", self.main_window)
new_tab_btn.setStatusTip("Open new tab")
new_tab_btn.triggered.connect(lambda: self.add_new_tab())
toolbar.addAction(new_tab_btn)
toolbar.addSeparator()

# Bookmarks button
bookmarks_btn = QAction("★", self.main_window)
bookmarks_btn.setStatusTip("Bookmarks")
bookmarks_btn.triggered.connect(self.show_bookmarks)
toolbar.addAction(bookmarks_btn)

# History button
history_btn = QAction("📚", self.main_window)
history_btn.setStatusTip("History")
history_btn.triggered.connect(self.show_history)
toolbar.addAction(history_btn)

# Downloads button
downloads_btn = QAction("📥", self.main_window)
downloads_btn.setStatusTip("Downloads")
downloads_btn.triggered.connect(self.show_downloads)
toolbar.addAction(downloads_btn)

toolbar.addSeparator()

# Quarix Chat button


quarix_btn = QAction("🤖 Chat with Quarix", self.main_window)
quarix_btn.setStatusTip("Chat with Quarix AI")
quarix_btn.triggered.connect(self.toggle_quarix_chat)
toolbar.addAction(quarix_btn)

# Settings button
settings_btn = QAction("⚙️
", self.main_window)
settings_btn.setStatusTip("Settings")
settings_btn.triggered.connect(self.show_settings)
toolbar.addAction(settings_btn)

def create_address_bar(self):
"""Create the address bar with search functionality"""
address_widget = QWidget()
address_layout = QHBoxLayout(address_widget)

# Security indicator
self.security_indicator = QLabel("🔒")
address_layout.addWidget(self.security_indicator)

# Address bar
self.address_bar = QLineEdit()
self.address_bar.setPlaceholderText("Search or enter web
address...")
self.address_bar.returnPressed.connect(self.navigate_to_url)
address_layout.addWidget(self.address_bar)
# Search button
search_btn = QPushButton("🔍")
search_btn.clicked.connect(self.navigate_to_url)
address_layout.addWidget(search_btn)

# Add to main toolbar


toolbar = self.main_window.toolBar()
toolbar.addWidget(address_widget)

def create_quarix_chat_panel(self):
"""Create the Quarix AI chat panel"""
self.chat_dock = QDockWidget("Chat with Quarix",
self.main_window)
self.chat_dock.setAllowedAreas(Qt.RightDockWidgetArea |
Qt.LeftDockWidgetArea)

chat_widget = QWidget()
chat_layout = QVBoxLayout(chat_widget)

# Chat header
header = QLabel("🤖 Quarix AI Assistant")
header.setStyleSheet("font-size: 16px; font-weight: bold;
padding: 10px;")
chat_layout.addWidget(header)

# Chat display
self.chat_display = QTextEdit()
self.chat_display.setReadOnly(True)
self.chat_display.setPlaceholderText("Chat with Quarix AI...")
chat_layout.addWidget(self.chat_display)

# Chat input
input_layout = QHBoxLayout()
self.chat_input = QLineEdit()
self.chat_input.setPlaceholderText("Chat with Quarix")
self.chat_input.returnPressed.connect(self.send_chat_message)

send_btn = QPushButton("Send")
send_btn.clicked.connect(self.send_chat_message)

input_layout.addWidget(self.chat_input)
input_layout.addWidget(send_btn)
chat_layout.addLayout(input_layout)

self.chat_dock.setWidget(chat_widget)
self.main_window.addDockWidget(Qt.RightDockWidgetArea,
self.chat_dock)
self.chat_dock.hide() # Initially hidden
def setup_styles(self):
"""Setup modern dark/light theme styles"""
if self.settings.get('theme', 'dark') == 'dark':
style = """
QMainWindow {
background: qlineargradient(x1:0, y1:0, x2:1, y2:1,
stop:0 #1a1a2e, stop:0.5 #16213e, stop:1 #0f3460);
}
QToolBar {
background: rgba(30, 30, 30, 0.9);
border: none;
spacing: 5px;
padding: 5px;
}
QTabWidget::pane {
border: 1px solid #555;
background: #2b2b2b;
}
QTabBar::tab {
background: #3c3c3c;
color: white;
padding: 8px 16px;
margin-right: 2px;
border-top-left-radius: 8px;
border-top-right-radius: 8px;
}
QTabBar::tab:selected {
background: #0078d4;
}
QLineEdit {
padding: 8px;
border: 2px solid #555;
border-radius: 20px;
background: #2b2b2b;
color: white;
font-size: 14px;
}
QLineEdit:focus {
border-color: #0078d4;
}
QPushButton {
background: #0078d4;
color: white;
border: none;
padding: 8px 16px;
border-radius: 6px;
font-weight: bold;
}
QPushButton:hover {
background: #106ebe;
}
QTextEdit {
background: #2b2b2b;
color: white;
border: 1px solid #555;
border-radius: 8px;
padding: 10px;
}
QDockWidget {
background: rgba(40, 40, 40, 0.95);
color: white;
}
"""
else:
style = """
QMainWindow {
background: qlineargradient(x1:0, y1:0, x2:1, y2:1,
stop:0 #e3f2fd, stop:0.5 #bbdefb, stop:1 #90caf9);
}
QToolBar {
background: rgba(255, 255, 255, 0.9);
border: none;
spacing: 5px;
padding: 5px;
}
QTabWidget::pane {
border: 1px solid #ccc;
background: white;
}
QTabBar::tab {
background: #f0f0f0;
color: black;
padding: 8px 16px;
margin-right: 2px;
border-top-left-radius: 8px;
border-top-right-radius: 8px;
}
QTabBar::tab:selected {
background: #0078d4;
color: white;
}
"""

self.main_window.setStyleSheet(style)

def add_new_tab(self, qurl=None, label="New Tab"):


"""Add a new browser tab"""
if qurl is None:
qurl = QUrl("https://www.google.com")
elif isinstance(qurl, str):
qurl = QUrl(qurl)

browser = QWebEngineView()
browser.setUrl(qurl)

# Connect signals
browser.urlChanged.connect(lambda qurl, browser=browser:
self.update_url_bar(qurl, browser))
browser.loadFinished.connect(lambda _, browser=browser:
self.update_title(browser))
browser.loadProgress.connect(self.update_progress)

# Add tab
i = self.tabs.addTab(browser, label)
self.tabs.setCurrentIndex(i)

# Update address bar


self.address_bar.setText(qurl.toString())

def close_tab(self, i):


"""Close a tab"""
if self.tabs.count() < 2:
return
self.tabs.removeTab(i)

def current_tab_changed(self, i):


"""Handle tab change"""
qurl = self.tabs.currentWidget().url()
self.address_bar.setText(qurl.toString())
self.update_security_indicator(qurl)

def navigate_to_url(self):
"""Navigate to URL or search"""
url = self.address_bar.text()

# Check if it's a search query or URL


if not url.startswith('http'):
if '.' in url and ' ' not in url:
url = 'https://' + url
else:
# Search query
url = f"https://www.google.com/search?q={url}"

qurl = QUrl(url)
self.tabs.currentWidget().setUrl(qurl)
self.add_to_history(url, "")

def navigate_back(self):
"""Navigate back"""
self.tabs.currentWidget().back()
def navigate_forward(self):
"""Navigate forward"""
self.tabs.currentWidget().forward()

def reload_page(self):
"""Reload current page"""
self.tabs.currentWidget().reload()

def navigate_home(self):
"""Navigate to home page"""
home_url = self.settings.get('home_page',
'https://www.google.com')
self.tabs.currentWidget().setUrl(QUrl(home_url))

def update_url_bar(self, qurl, browser=None):


"""Update address bar with current URL"""
if browser == self.tabs.currentWidget():
self.address_bar.setText(qurl.toString())
self.update_security_indicator(qurl)

def update_title(self, browser):


"""Update tab title"""
if browser == self.tabs.currentWidget():
title = browser.page().title()
i = self.tabs.currentIndex()
self.tabs.setTabText(i, title[:20] + "..." if len(title) >
20 else title)

def update_progress(self, progress):


"""Update loading progress"""
self.status_bar.showMessage(f"Loading... {progress}%")
if progress == 100:
self.status_bar.showMessage("Ready")

def update_security_indicator(self, qurl):


"""Update security indicator"""
if qurl.scheme() == 'https':
self.security_indicator.setText("🔒")
self.security_indicator.setToolTip("Secure connection")
else:
self.security_indicator.setText("⚠️
")
self.security_indicator.setToolTip("Not secure")

def toggle_quarix_chat(self):
"""Toggle Quarix chat panel"""
if self.chat_dock.isVisible():
self.chat_dock.hide()
else:
self.chat_dock.show()
def send_chat_message(self):
"""Send message to Quarix AI"""
message = self.chat_input.text().strip()
if not message:
return

# Display user message


self.chat_display.append(f"<b>You:</b> {message}")
self.chat_input.clear()

# Send to Quarix AI (simulated - replace with actual Gemini


API call)
threading.Thread(target=self.get_quarix_response,
args=(message,)).start()

def get_quarix_response(self, message):


"""Get response from Quarix AI using Gemini API"""
try:
# This is a placeholder - implement actual Gemini API call
response = self.call_gemini_api(message)

# Display Quarix response


QTimer.singleShot(0, lambda:
self.chat_display.append(f"<b>🤖 Quarix:</b> {response}"))

except Exception as e:
QTimer.singleShot(0, lambda:
self.chat_display.append(f"<b>🤖 Quarix:</b> Sorry, I'm having trouble
connecting right now."))

def call_gemini_api(self, message):


"""Call Gemini API (implement with your API key)"""
# Placeholder response - implement actual API call
responses = [
"Hello! I'm Quarix, your AI assistant. How can I help you
today?",
"I'm here to help you with web browsing and answer your
questions!",
"That's an interesting question! Let me think about
that...",
"As Quarix, I'm designed to make your browsing experience
better!",
"I can help you with searches, bookmarks, and general
questions!"
]
import random
return random.choice(responses)

def show_bookmarks(self):
"""Show bookmarks manager"""
self.bookmarks_window = BookmarksWindow(self)
self.bookmarks_window.show()

def show_history(self):
"""Show history manager"""
self.history_window = HistoryWindow(self)
self.history_window.show()

def show_downloads(self):
"""Show downloads manager"""
self.downloads_window = DownloadsWindow(self)
self.downloads_window.show()

def show_settings(self):
"""Show settings window"""
self.settings_window = SettingsWindow(self)
self.settings_window.show()

def add_to_history(self, url, title):


"""Add URL to history"""
cursor = self.conn.cursor()
cursor.execute("INSERT INTO history (url, title, timestamp)
VALUES (?, ?, ?)",
(url, title, datetime.now()))
self.conn.commit()

def add_bookmark(self, url, title, folder="Default"):


"""Add bookmark"""
cursor = self.conn.cursor()
cursor.execute("INSERT INTO bookmarks (url, title, folder)
VALUES (?, ?, ?)",
(url, title, folder))
self.conn.commit()

def load_settings(self):
"""Load browser settings"""
try:
with open('quarix_settings.json', 'r') as f:
return json.load(f)
except:
return {
'theme': 'dark',
'home_page': 'https://www.google.com',
'search_engine': 'google',
'privacy_mode': False
}

def save_settings(self):
"""Save browser settings"""
with open('quarix_settings.json', 'w') as f:
json.dump(self.settings, f)

def run(self):
"""Run the browser"""
self.main_window.show()
return self.app.exec_()

class BookmarksWindow(QMainWindow):
"""Bookmarks manager window"""
def __init__(self, browser):
super().__init__()
self.browser = browser
self.setWindowTitle("Bookmarks Manager")
self.setGeometry(200, 200, 800, 600)
self.setup_ui()

def setup_ui(self):
central_widget = QWidget()
self.setCentralWidget(central_widget)
layout = QVBoxLayout(central_widget)

# Bookmarks list
self.bookmarks_list = QListWidget()
layout.addWidget(self.bookmarks_list)

# Buttons
button_layout = QHBoxLayout()

add_btn = QPushButton("Add Current Page")


add_btn.clicked.connect(self.add_current_page)
button_layout.addWidget(add_btn)

delete_btn = QPushButton("Delete")
delete_btn.clicked.connect(self.delete_bookmark)
button_layout.addWidget(delete_btn)

open_btn = QPushButton("Open")
open_btn.clicked.connect(self.open_bookmark)
button_layout.addWidget(open_btn)

layout.addLayout(button_layout)
self.load_bookmarks()

def load_bookmarks(self):
"""Load bookmarks from database"""
cursor = self.browser.conn.cursor()
cursor.execute("SELECT * FROM bookmarks")
bookmarks = cursor.fetchall()
self.bookmarks_list.clear()
for bookmark in bookmarks:
item = QListWidgetItem(f"{bookmark[2]} - {bookmark[1]}")
item.setData(Qt.UserRole, bookmark)
self.bookmarks_list.addItem(item)

def add_current_page(self):
"""Add current page to bookmarks"""
current_tab = self.browser.tabs.currentWidget()
url = current_tab.url().toString()
title = current_tab.page().title()

self.browser.add_bookmark(url, title)
self.load_bookmarks()

def delete_bookmark(self):
"""Delete selected bookmark"""
current_item = self.bookmarks_list.currentItem()
if current_item:
bookmark = current_item.data(Qt.UserRole)
cursor = self.browser.conn.cursor()
cursor.execute("DELETE FROM bookmarks WHERE id = ?",
(bookmark[0],))
self.browser.conn.commit()
self.load_bookmarks()

def open_bookmark(self):
"""Open selected bookmark"""
current_item = self.bookmarks_list.currentItem()
if current_item:
bookmark = current_item.data(Qt.UserRole)
self.browser.add_new_tab(bookmark[1], bookmark[2])

class HistoryWindow(QMainWindow):
"""History manager window"""
def __init__(self, browser):
super().__init__()
self.browser = browser
self.setWindowTitle("Browsing History")
self.setGeometry(200, 200, 800, 600)
self.setup_ui()

def setup_ui(self):
central_widget = QWidget()
self.setCentralWidget(central_widget)
layout = QVBoxLayout(central_widget)

# History list
self.history_list = QListWidget()
layout.addWidget(self.history_list)
# Buttons
button_layout = QHBoxLayout()

clear_btn = QPushButton("Clear History")


clear_btn.clicked.connect(self.clear_history)
button_layout.addWidget(clear_btn)

open_btn = QPushButton("Open")
open_btn.clicked.connect(self.open_history_item)
button_layout.addWidget(open_btn)

layout.addLayout(button_layout)
self.load_history()

def load_history(self):
"""Load history from database"""
cursor = self.browser.conn.cursor()
cursor.execute("SELECT * FROM history ORDER BY timestamp DESC
LIMIT 100")
history = cursor.fetchall()

self.history_list.clear()
for item in history:
list_item = QListWidgetItem(f"{item[3]} - {item[1]}")
list_item.setData(Qt.UserRole, item)
self.history_list.addItem(list_item)

def clear_history(self):
"""Clear browsing history"""
cursor = self.browser.conn.cursor()
cursor.execute("DELETE FROM history")
self.browser.conn.commit()
self.load_history()

def open_history_item(self):
"""Open selected history item"""
current_item = self.history_list.currentItem()
if current_item:
history_item = current_item.data(Qt.UserRole)
self.browser.add_new_tab(history_item[1], history_item[2])

class DownloadsWindow(QMainWindow):
"""Downloads manager window"""
def __init__(self, browser):
super().__init__()
self.browser = browser
self.setWindowTitle("Downloads")
self.setGeometry(200, 200, 800, 600)
self.setup_ui()
def setup_ui(self):
central_widget = QWidget()
self.setCentralWidget(central_widget)
layout = QVBoxLayout(central_widget)

# Downloads list
self.downloads_list = QListWidget()
layout.addWidget(self.downloads_list)

# Buttons
button_layout = QHBoxLayout()

clear_btn = QPushButton("Clear Downloads")


clear_btn.clicked.connect(self.clear_downloads)
button_layout.addWidget(clear_btn)

open_folder_btn = QPushButton("Open Folder")


open_folder_btn.clicked.connect(self.open_downloads_folder)
button_layout.addWidget(open_folder_btn)

layout.addLayout(button_layout)
self.load_downloads()

def load_downloads(self):
"""Load downloads from database"""
cursor = self.browser.conn.cursor()
cursor.execute("SELECT * FROM downloads ORDER BY timestamp
DESC")
downloads = cursor.fetchall()

self.downloads_list.clear()
for download in downloads:
item = QListWidgetItem(f"{download[1]} - {download[4]}")
item.setData(Qt.UserRole, download)
self.downloads_list.addItem(item)

def clear_downloads(self):
"""Clear downloads list"""
cursor = self.browser.conn.cursor()
cursor.execute("DELETE FROM downloads")
self.browser.conn.commit()
self.load_downloads()

def open_downloads_folder(self):
"""Open downloads folder"""
downloads_path = os.path.expanduser("~/Downloads")
os.startfile(downloads_path)

class SettingsWindow(QMainWindow):
"""Settings window"""
def __init__(self, browser):
super().__init__()
self.browser = browser
self.setWindowTitle("Quarix Browser Settings")
self.setGeometry(200, 200, 600, 500)
self.setup_ui()

def setup_ui(self):
central_widget = QWidget()
self.setCentralWidget(central_widget)
layout = QVBoxLayout(central_widget)

# Theme settings
theme_group = QGroupBox("Appearance")
theme_layout = QVBoxLayout(theme_group)

self.theme_combo = QComboBox()
self.theme_combo.addItems(["Dark", "Light"])

self.theme_combo.setCurrentText(self.browser.settings.get('theme',
'dark').title())
theme_layout.addWidget(QLabel("Theme:"))
theme_layout.addWidget(self.theme_combo)

layout.addWidget(theme_group)

# Home page settings


home_group = QGroupBox("Home Page")
home_layout = QVBoxLayout(home_group)

self.home_page_input = QLineEdit()

self.home_page_input.setText(self.browser.settings.get('home_page',
'https://www.google.com'))
home_layout.addWidget(QLabel("Home Page URL:"))
home_layout.addWidget(self.home_page_input)

layout.addWidget(home_group)

# Privacy settings
privacy_group = QGroupBox("Privacy")
privacy_layout = QVBoxLayout(privacy_group)

self.privacy_mode = QCheckBox("Enable Privacy Mode")

self.privacy_mode.setChecked(self.browser.settings.get('privacy_mode',
False))
privacy_layout.addWidget(self.privacy_mode)
layout.addWidget(privacy_group)

# Buttons
button_layout = QHBoxLayout()

save_btn = QPushButton("Save Settings")


save_btn.clicked.connect(self.save_settings)
button_layout.addWidget(save_btn)

cancel_btn = QPushButton("Cancel")
cancel_btn.clicked.connect(self.close)
button_layout.addWidget(cancel_btn)

layout.addLayout(button_layout)

def save_settings(self):
"""Save settings"""
self.browser.settings['theme'] =
self.theme_combo.currentText().lower()
self.browser.settings['home_page'] =
self.home_page_input.text()
self.browser.settings['privacy_mode'] =
self.privacy_mode.isChecked()

self.browser.save_settings()
self.browser.setup_styles()
self.close()

def main():
"""Main function to run the browser"""
try:
browser = QuarixBrowser()
sys.exit(browser.run())
except Exception as e:
print(f"Error starting Quarix Browser: {e}")
input("Press Enter to exit...")

if __name__ == "__main__":
main()

Now, create a requirements.txt file for all the dependencies:


PyQt5==5.15.9
PyQtWebEngine==5.15.6
customtkinter==5.2.0
requests==2.31.0
sqlite3

And here's a simple setup script to install dependencies:


# setup.py
import subprocess
import sys

def install_requirements():
"""Install required packages"""
requirements = [
"PyQt5==5.15.9",
"PyQtWebEngine==5.15.6",
"customtkinter==5.2.0",
"requests==2.31.0"
]

for requirement in requirements:


try:
subprocess.check_call([sys.executable, "-m", "pip",
"install", requirement])
print(f"✅ Installed {requirement}")
except subprocess.CalledProcessError:
print(f"❌ Failed to install {requirement}")

if __name__ == "__main__":
print("🚀 Setting up Quarix Browser...")
install_requirements()
print("✅ Setup complete! Run the browser with: python
quarix_browser.py")

Features Included:
🌟 Core Browser Features:
 Multi-tab browsing with closable tabs
 Navigation controls (back, forward,

You might also like