better faulty encoding detection
This commit is contained in:
1 parent
ec8e79bb1a
commit
2a4c5f4f7c
12 files changed
+299
-25
No files matched your search
+15
-5
@@ -325,7 +325,7 @@ class CopienatorApp(tk.Tk):
|
||||
|
||||
top = ttk.Frame(self, padding=(10, 8))
|
||||
top.grid(row=0, column=0, sticky="ew")
|
||||
top.columnconfigure(5, weight=1)
|
||||
top.columnconfigure(6, weight=1)
|
||||
ttk.Button(top, text="Charger", command=self._load_evaluation).grid(
|
||||
row=0, column=0, padx=(0, 8)
|
||||
)
|
||||
@@ -333,14 +333,19 @@ class CopienatorApp(tk.Tk):
|
||||
self.evaluation_entry = ttk.Entry(top, textvariable=self.evaluation_var, width=42)
|
||||
self.evaluation_entry.grid(row=0, column=2, sticky="w")
|
||||
self.evaluation_entry.bind("<Return>", lambda _event: self._load_evaluation())
|
||||
self.browse_evaluation_button = ttk.Button(
|
||||
top, text="Parcourir…", command=self._browse_evaluation
|
||||
)
|
||||
self.browse_evaluation_button.grid(row=0, column=3, padx=(6, 0))
|
||||
self.open_evaluation_button = ttk.Button(
|
||||
top, text="Ouvrir le dossier", command=self._open_evaluation_folder
|
||||
)
|
||||
self.open_evaluation_button.grid(row=0, column=3, padx=(6, 0))
|
||||
ttk.Button(top, text="Parcourir…", command=self._browse_evaluation).grid(
|
||||
row=0, column=4, padx=6
|
||||
self.open_evaluation_button.grid(row=0, column=4, padx=(12, 0))
|
||||
self.open_statement_button = ttk.Button(
|
||||
top, text="Ouvrir l’énoncé", command=self._open_statement_pdf
|
||||
)
|
||||
ttk.Button(top, text="Diagnostic…", command=self._show_diagnostics).grid(row=0, column=6, padx=(6, 0))
|
||||
self.open_statement_button.grid(row=0, column=5, padx=(6, 0))
|
||||
ttk.Button(top, text="Diagnostic…", command=self._show_diagnostics).grid(row=0, column=7, padx=(6, 0))
|
||||
|
||||
ttk.Label(top, text="Clé Gemini").grid(row=1, column=0, sticky="w", padx=(0, 8), pady=(7, 0))
|
||||
ttk.Entry(top, textvariable=self.api_key_var, show="•", width=32).grid(
|
||||
@@ -560,6 +565,11 @@ class CopienatorApp(tk.Tk):
|
||||
def _open_evaluation_folder(self) -> None:
|
||||
self._open_desktop_path(self.evaluation, "dossier d’évaluation")
|
||||
|
||||
def _open_statement_pdf(self) -> None:
|
||||
evaluation = self.evaluation
|
||||
statement = EvaluationWorkspace(evaluation).statement_pdf_file if evaluation else None
|
||||
self._open_desktop_path(statement, "fichier enonce.pdf")
|
||||
|
||||
def _toggle_proxy(self) -> None:
|
||||
self.proxy_entry.configure(state="normal" if self.use_proxy_var.get() else "disabled")
|
||||
|
||||
|
||||
Reference in new issue
Block a user