Skip to content

Commit

Permalink
Merge branch 'develop'
Browse files Browse the repository at this point in the history
  • Loading branch information
rohitagr0310 committed Oct 5, 2023
2 parents a0ddc06 + edc4824 commit 08975db
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions main.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import tkinter as tk
from menu_bar import create_menu_bar
from tkinter import scrolledtext

def create_base_window():
root = tk.Tk()
Expand All @@ -9,15 +10,15 @@ def create_base_window():
create_menu_bar(root)

# Create a text widget (for code editing)
text_widget = tk.Text(root, wrap=tk.WORD)
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)

# Create a scrollbar for the text widget
scrollbar = tk.Scrollbar(text_widget)
scrollbar.pack(side=tk.RIGHT, fill=tk.Y)
text_widget.config(yscrollcommand=scrollbar.set)
scrollbar.config(command=text_widget.yview)

return root

if __name__ == "__main__":
Expand Down

0 comments on commit 08975db

Please sign in to comment.