From f9911987af3f74c5a2fed51c69673ab8d1fbddd0 Mon Sep 17 00:00:00 2001 From: Isaiah Odhner Date: Wed, 6 Sep 2023 22:01:57 -0400 Subject: [PATCH] Show position in the gallery in the header --- src/textual_paint/gallery.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/textual_paint/gallery.py b/src/textual_paint/gallery.py index 5f33624..46bdd2a 100644 --- a/src/textual_paint/gallery.py +++ b/src/textual_paint/gallery.py @@ -221,6 +221,8 @@ class GalleryApp(App[None]): else: gallery_item.animate("position", value=position, final_value=position, duration=0.3) + self.sub_title = f"{current_index + 1}/{len(self.paths)}" + def action_next(self) -> None: """Scroll to the next item.""" self.path_index += 1