-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #5 from rohitagr0310/basic-window
Basic window has been created and text editor iss refined
- Loading branch information
Showing
4 changed files
with
26 additions
and
139 deletions.
There are no files selected for viewing
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
import tkinter as tk | ||
from menu_bar import create_menu_bar | ||
from tkinter import scrolledtext | ||
|
||
def create_base_window(): | ||
root = tk.Tk() | ||
root.title("My Python IDE") | ||
|
||
# Create a menu bar using the imported function | ||
create_menu_bar(root) | ||
|
||
# Create a text widget (for code editing) | ||
text_widget = scrolledtext.ScrolledText( | ||
root, | ||
wrap=tk.WORD, | ||
font=("Consolas", 12), # Use a monospaced font like Consolas | ||
insertbackground="Black", # Color of the cursor | ||
selectbackground="lightblue" # Color of selected text | ||
) | ||
text_widget.pack(expand=tk.YES, fill=tk.BOTH) | ||
|
||
return root | ||
|
||
if __name__ == "__main__": | ||
app = create_base_window() | ||
app.mainloop() |
This file was deleted.
Oops, something went wrong.