Skip to content

Commit

Permalink
update to 3.2
Browse files Browse the repository at this point in the history
-improved GUI
-outlines menu functionality
  • Loading branch information
SIG-Labo committed Feb 13, 2024
1 parent 9b76c7a commit 05cd53d
Show file tree
Hide file tree
Showing 8 changed files with 228 additions and 75 deletions.
Binary file not shown.
10 changes: 8 additions & 2 deletions E-Matrix 3.0 AES/README-AES.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# eisenhower personal organizer AES
Eisenhower Personal Organizer v 3.0 AES
Eisenhower Personal Organizer v 3.2 AES

This is a straightforward organizer written in Python, designed for individuals who struggle with organizing long-term and medium-term tasks.

Expand All @@ -14,6 +14,8 @@ Adjust the code and recompile to create a less strict environment or use the pro

Installation: compile the source into your own exe using pyinstaller --onefile --windowed source.py
or use the exe from the repository
Add some data to Brain Dump and restart the program to get your workflow going.


Functions:
Brain Dump: Allows the spawning of fresh new ideas.
Expand All @@ -25,13 +27,17 @@ List Tasks: Displays tasks.
Remove Tasks: Deletes tasks.
Clear All Tasks: Removes all tasks.
Add Your Goalset to Any Task: Attach your goals to any task.
Keep Track of new ideas and their outlines.


(c) Peter De Ceuster 2024
Software Distribution Notice: https://peterdeceuster.uk/doc/code-terms
This software is released under the FPA General Code License.



virustotal for the exe: MD5 7adf6231368637966f72510bbce44b38
(5 false positives and 65 passed)
https://www.virustotal.com/gui/file/2cfb501d9dddf06ac58e65767339d0dfc53183bbd80cbbf02c83926ad7bef0a8/details



Expand Down
Binary file modified E-Matrix 3.0 AES/launcher.exe
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -1,28 +1,34 @@

"""
Eisenhower-Matrix Personal Planner 3.0
Copyright (c) 2024 Peter De Ceuster
https://peterdeceuster.uk/
Free to distribute
Distributed under the FPA General Code License
"""


import subprocess
import tkinter as tk
from tkinter import simpledialog, messagebox
from tkinter import messagebox
import webbrowser
import subprocess
import shutil
import os
import json
import winsound

class AboutDialog(tk.Toplevel):
def __init__(self, parent):
super().__init__(parent)
self.title("About")

label = tk.Label(self, text="E-Matrix v 3.2\n(c) 2024 Peter De Ceuster\n peterdeceuster.uk \nFree to distribute\nDistributed under the FPA General Code License", justify="center", fg="blue", cursor="hand2")
label.pack(padx=10, pady=10)
label.bind("<Button-1>", self.open_url)

ok_button = tk.Button(self, text="OK", command=self.destroy)
ok_button.pack(pady=5)

def open_url(self, event):
webbrowser.open("https://peterdeceuster.uk/")

class DailyPlannerGUI:
def __init__(self):
self.root = tk.Tk()
self.root.title("Eisenhower-Matrix Personal Planner 3.0 - Welcome")
self.root.title("Eisenhower-Matrix Personal Planner 3.2 - Welcome")
self.root.state('zoomed')
self.root.configure(bg='lightblue')

# Play chimes sound
# winsound.PlaySound("SystemHand", winsound.SND_ALIAS)

Expand All @@ -39,14 +45,14 @@ def __init__(self):
self.eisenhower_matrix_results = None
self.last_review_results = None
self.data_file = "eisenhower-data.json"
self.backup_file = "eisenhower-data-backup.json" # Added backup file path
self.backup_file = "eisenhower-data-backup.json"

self.load_backup_data() # Load backup data
self.load_backup_data()
self.load_data()
self.create_menu()
self.create_widgets()
self.center_window()
self.display_eisenhower_matrix_results() # Display Eisenhower Matrix results
self.display_eisenhower_matrix_results()

def create_menu(self):
menu = tk.Menu(self.root)
Expand All @@ -67,23 +73,38 @@ def create_menu(self):
planner_menu.add_command(label="Review Day", command=self.review_day)
planner_menu.add_command(label="List All Tasks", command=self.list_all_tasks)
planner_menu.add_command(label="Remove a Task", command=self.remove_task)
planner_menu.add_command(label="Clear All Tasks", command=self.clear_all_tasks) # Added clear all tasks command
planner_menu.add_command(label="Clear All Tasks", command=self.clear_all_tasks)
menu.add_cascade(label="Planner", menu=planner_menu)

about_menu = tk.Menu(menu, tearoff=False)
about_menu.add_command(label="About", command=self.about)
menu.add_cascade(label="About", menu=about_menu)

future_ideas_menu = tk.Menu(menu, tearoff=False)
future_ideas_menu.add_command(label="Enter Future Ideas", command=self.enter_future_ideas)
future_ideas_menu.add_command(label="Retrieve Future Ideas", command=self.retrieve_future_ideas)
menu.add_cascade(label="Future Ideas", menu=future_ideas_menu)

def create_widgets(self):
self.scrollbar = tk.Scrollbar(self.root)
self.scrollbar.pack(side=tk.RIGHT, fill=tk.Y)

self.review_text_widget = tk.Text(self.root, height=10, width=80, bg="black", fg="green")
self.review_text_widget.pack(pady=10)

# New widget for displaying Eisenhower Matrix results
self.review_text_widget.pack(fill=tk.BOTH, expand=True, padx=10, pady=10)
self.review_text_widget.config(wrap="word")
self.review_text_widget.config(yscrollcommand=self.scrollbar.set)
self.review_text_widget.config(xscrollcommand=self.scrollbar.set)
self.scrollbar.config(command=self.review_text_widget.yview)

self.eisenhower_matrix_label = tk.Label(self.root, text="Eisenhower Matrix Results:", bg='lightblue')
self.eisenhower_matrix_label.pack(pady=10)

self.eisenhower_matrix_display = tk.Text(self.root, height=10, width=80, bg="black", fg="red") # Changed background and text color
self.eisenhower_matrix_display.pack(pady=10)
self.eisenhower_matrix_display = tk.Text(self.root, height=10, width=80, bg="black", fg="red")
self.eisenhower_matrix_display.pack(fill=tk.BOTH, expand=True, padx=10, pady=10)
self.eisenhower_matrix_display.config(wrap="word")
self.eisenhower_matrix_display.config(yscrollcommand=self.scrollbar.set)
self.eisenhower_matrix_display.config(xscrollcommand=self.scrollbar.set)


def center_window(self):
self.root.update_idletasks()
Expand All @@ -94,7 +115,7 @@ def center_window(self):
self.root.geometry('{}x{}+{}+{}'.format(width, height, x, y))

def exit_program(self):
self.save_data() # Save data before exiting
self.save_data()
subprocess.run(["python", "locksoft.py"], check=True)

self.root.quit()
Expand All @@ -103,7 +124,7 @@ def brain_dump(self):
def add_task():
task = entry_task.get().strip()
if task:
if task not in self.tasks: # Check for duplicates
if task not in self.tasks:
self.tasks.append(task)
listbox_tasks.insert(tk.END, task)
entry_task.delete(0, tk.END)
Expand Down Expand Up @@ -143,7 +164,7 @@ def done():

listbox_tasks = tk.Listbox(dialog_window, width=50)
listbox_tasks.pack(pady=5)
# Display all current tasks

original_tasks = self.tasks.copy()
for task in self.tasks:
listbox_tasks.insert(tk.END, task)
Expand Down Expand Up @@ -172,7 +193,7 @@ def separate_tasks(self):
self.eisenhower_matrix_results["Not Urgent, but Important"] = not_urgent_important
self.eisenhower_matrix_results["Urgent, but Not Important"] = urgent_not_important
self.eisenhower_matrix_results["Not Urgent and Not Important"] = not_urgent_not_important
self.display_eisenhower_matrix_results() # Update Eisenhower Matrix results display
self.display_eisenhower_matrix_results()
self.save_data()

def create_morning_routine(self):
Expand Down Expand Up @@ -249,10 +270,9 @@ def review_day(self):
completed_tasks.append(task)
incompleted_tasks = [task for task in self.tasks if task not in completed_tasks]
self.last_review_results = {"completed_tasks": completed_tasks, "incompleted_tasks": incompleted_tasks}
self.display_eisenhower_matrix_results() # Update Eisenhower Matrix results display
self.display_eisenhower_matrix_results()
self.save_data()

# Displaying the last result of the review day in the text widget
review_text = f"Completed Tasks (from last review):\n{', '.join(completed_tasks)}\n\nUncompleted Tasks (from last review):\n{', '.join(incompleted_tasks)}"
self.review_text_widget.delete(1.0, tk.END)
self.review_text_widget.insert(tk.END, review_text)
Expand Down Expand Up @@ -286,7 +306,7 @@ def remove_selected_task():

listbox_tasks = tk.Listbox(dialog_window, width=50)
listbox_tasks.pack(pady=5)
# Display all current tasks

for task in self.tasks:
listbox_tasks.insert(tk.END, task)

Expand All @@ -296,16 +316,66 @@ def remove_selected_task():
def clear_all_tasks(self):
confirm = messagebox.askyesno("Confirm", "Are you sure you want to clear all tasks?")
if confirm:
self.tasks = [] # Clear all tasks
self.eisenhower_matrix_results = None # Reset Eisenhower Matrix results
self.tasks = []
self.eisenhower_matrix_results = None
self.save_data()
self.display_eisenhower_matrix_results() # Update Eisenhower Matrix display
self.display_eisenhower_matrix_results()
messagebox.showinfo("Success", "All tasks cleared successfully.")
else:
messagebox.showinfo("Cancelled", "Operation cancelled.")

def about(self):
messagebox.showinfo("About", "E-Matrix v 3.0\n(c) 2024 Peter De Ceuster\nhttps://peterdeceuster.uk/\nFree to distribute\nDistributed under the FPA General Code License")
about_dialog = AboutDialog(self.root)

def retrieve_future_ideas(self):
try:
with open(self.data_file, 'r') as f:
data = json.load(f)
future_ideas = data.get("future_ideas", [])
if future_ideas:
idea_list = "\n".join([f"Idea: {idea['idea']}\nOutline: {idea['outline']}\n" for idea in future_ideas])
messagebox.showinfo("Future Ideas", idea_list)
else:
messagebox.showinfo("Future Ideas", "No future ideas have been entered yet.")
except Exception as e:
messagebox.showerror("Error", f"An error occurred while retrieving future ideas: {str(e)}")

def enter_future_ideas(self):
dialog_window = tk.Toplevel(self.root)
dialog_window.title("Enter Future Ideas")
dialog_window.attributes('-topmost', True)

frame = tk.Frame(dialog_window)
frame.pack(padx=10, pady=10)

label_idea = tk.Label(frame, text="Enter Future Idea:")
label_idea.grid(row=0, column=0, sticky=tk.W)

entry_idea = tk.Entry(frame, width=50)
entry_idea.grid(row=0, column=1, padx=5)

label_outline = tk.Label(frame, text="Enter Outline:")
label_outline.grid(row=1, column=0, sticky=tk.W)

entry_outline = tk.Entry(frame, width=50)
entry_outline.grid(row=1, column=1, padx=5)

def save_idea():
idea = entry_idea.get().strip()
outline = entry_outline.get().strip()
if idea and outline:
with open(self.data_file, 'r+') as f:
data = json.load(f)
future_ideas = data.get("future_ideas", [])
future_ideas.append({"idea": idea, "outline": outline})
f.seek(0)
json.dump(data, f)
messagebox.showinfo("Success", "Future idea and outline saved successfully.")
else:
messagebox.showwarning("Incomplete Information", "Please enter both idea and outline.")

button_save = tk.Button(frame, text="Save", command=save_idea)
button_save.grid(row=2, column=0, columnspan=2, pady=5)

def save_data(self):
data = {
Expand All @@ -314,14 +384,16 @@ def save_data(self):
"morning_routine": self.morning_routine,
"deleted_tasks": self.deleted_tasks,
"eisenhower_matrix_results": self.eisenhower_matrix_results,
"last_review_results": self.last_review_results
"last_review_results": self.last_review_results,
"future_ideas": [] # Initialize future_ideas as an empty list
}
try:
with open(self.data_file, 'w') as f:
json.dump(data, f)
except Exception as e:
messagebox.showerror("Error", f"An error occurred while saving data: {str(e)}")


def load_data(self):
try:
with open(self.data_file, 'r') as f:
Expand Down
2 changes: 1 addition & 1 deletion E-Matrix 3.0 AES/sourcecode/launcher.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ def main():
process.wait()

# Launch E-Matrix 3.0.exe after unlocksoft.py has exited
os.startfile("E-Matrix 3.0.exe")
os.startfile("E-Matrix 3.2.exe")

if __name__ == "__main__":
main()
Binary file renamed E-Matrix 3.0.exe → E-Matrix 3.2.exe
Binary file not shown.
Loading

0 comments on commit 05cd53d

Please sign in to comment.