From efa44c8872f7a8d9a72b91434aa6eddfedd0f408 Mon Sep 17 00:00:00 2001 From: mARTin-B78 Date: Tue, 9 Jun 2026 23:50:20 +0200 Subject: [PATCH] feat: resize grip indicator on settings window (v2.03.11) Draws a classic dotted SE-corner grip overlaid on the bottom-right of the notebook so users know the settings dialog is resizable. Co-Authored-By: Claude Sonnet 4.6 --- linux/CHANGELOG.md | 6 ++++++ linux/blitztext/__init__.py | 2 +- linux/blitztext/gtksettings.py | 30 +++++++++++++++++++++++++++++- 3 files changed, 36 insertions(+), 2 deletions(-) diff --git a/linux/CHANGELOG.md b/linux/CHANGELOG.md index ace7c91..4249a28 100644 --- a/linux/CHANGELOG.md +++ b/linux/CHANGELOG.md @@ -9,6 +9,12 @@ The version is defined in [`blitztext/__init__.py`](blitztext/__init__.py). ## [Unreleased] +## [2.03.11] - 2026-06-09 + +### Added +- **Resize grip indicator.** A dotted SE-corner grip is drawn over the + bottom-right of the settings window so users discover it is resizable. + ## [2.03.10] - 2026-06-09 ### Fixed diff --git a/linux/blitztext/__init__.py b/linux/blitztext/__init__.py index 3993cc4..bdc986d 100644 --- a/linux/blitztext/__init__.py +++ b/linux/blitztext/__init__.py @@ -6,4 +6,4 @@ counterpart to the macOS Blitztext menu bar app: it runs natively on the host (not in a container) so it can type into any application via xdotool. """ -__version__ = "2.03.10" +__version__ = "2.03.11" diff --git a/linux/blitztext/gtksettings.py b/linux/blitztext/gtksettings.py index c3a5208..ae499c7 100644 --- a/linux/blitztext/gtksettings.py +++ b/linux/blitztext/gtksettings.py @@ -787,7 +787,20 @@ notebook.bt-nb tab:checked label { nb = Gtk.Notebook() nb.get_style_context().add_class("bt-nb") - self.dlg.get_content_area().pack_start(nb, True, True, 0) + + # Resize-grip overlay — draws the classic dotted SE grip so users know + # the window is resizable. + _overlay = Gtk.Overlay() + _overlay.add(nb) + _grip = Gtk.DrawingArea() + _grip.set_size_request(18, 18) + _grip.set_halign(Gtk.Align.END) + _grip.set_valign(Gtk.Align.END) + _grip.set_can_focus(False) + _grip.connect("draw", self._draw_resize_grip) + _overlay.add_overlay(_grip) + _overlay.set_overlay_pass_through(_grip, True) + self.dlg.get_content_area().pack_start(_overlay, True, True, 0) # Build each tab lazily on first view so the dialog opens instantly. The # heavy bits are the Gtk.FileChooserButton pickers in Input/Benchmark # (~0.2s each to construct); deferring them until you visit that tab keeps @@ -2531,6 +2544,21 @@ notebook.bt-nb tab:checked label { cb = Gtk.Clipboard.get(Gdk.SELECTION_CLIPBOARD) cb.set_text("\n".join(logbuffer.lines(self._log_min_level())), -1) + def _draw_resize_grip(self, _da, cr) -> None: + """Draw a 3×3 dotted SE resize-grip in the DrawingArea.""" + import math + w = _da.get_allocated_width() + h = _da.get_allocated_height() + cr.set_source_rgba(0.55, 0.55, 0.55, 0.65) + spacing, radius = 5, 1.5 + for row in range(3): + for col in range(3): + if row + col >= 2: # lower-right triangle only + cx = w - 3 + (col - 2) * spacing + cy = h - 3 + (row - 2) * spacing + cr.arc(cx, cy, radius, 0, 2 * math.pi) + cr.fill() + def _cleanup(self) -> None: self._stop_meter() t = getattr(self, "_log_timer", 0)