Fix first tag items being improperly enumerated
authorJack Miller <jack@codezen.org>
Wed, 8 Jul 2015 17:32:06 +0000 (12:32 -0500)
committerJack Miller <jack@codezen.org>
Wed, 8 Jul 2015 17:32:06 +0000 (12:32 -0500)
canto_curses/tag.py

index 2dbc2a6..18add3a 100644 (file)
@@ -90,10 +90,10 @@ class Tag(PluginHandler, list):
         self.post_format = ""
 
         # Global indices (for enumeration)
-        self.item_offset = 0
-        self.visible_tag_offset = 0
-        self.tag_offset = 0
-        self.sel_offset = 0
+        self.item_offset = -1
+        self.visible_tag_offset = -1
+        self.tag_offset = -1
+        self.sel_offset = -1
 
         on_hook("curses_opt_change", self.on_opt_change, self)
         on_hook("curses_tag_opt_change", self.on_tag_opt_change, self)