Added a tooltip like feature to display variables' labels when the mouse hovers
[pspp-builds.git] / src / libpspp / tower.h
index e0ee12a758229bef02e9ae934c0437ee44b3a6bc..a3a1be8981670862b4e095c374e3022b1f2a895a 100644 (file)
@@ -57,7 +57,7 @@
         ((STRUCT *) ((char *) (NODE) - offsetof (STRUCT, MEMBER)))
 
 /* A node within a tower. */
-struct tower_node 
+struct tower_node
   {
     struct abt_node abt_node;         /* ABT node. */
     unsigned long int subtree_height; /* Node's plus descendants' heights. */
@@ -66,15 +66,17 @@ struct tower_node
 
 /* Returns the height of a tower node. */
 static inline unsigned long
-tower_node_get_height (const struct tower_node *node) 
+tower_node_get_height (const struct tower_node *node)
 {
   return node->height;
 }
 
 /* A tower. */
-struct tower 
+struct tower
   {
-    struct abt abt;              /* Tree. */
+    struct abt abt;                   /* Tree. */
+    struct tower_node *cache;         /* Cache node. */
+    unsigned long int cache_bottom;   /* Height of cache's bottom. */
   };
 
 void tower_init (struct tower *);
@@ -95,7 +97,10 @@ struct tower_node *tower_lookup (const struct tower *,
                                  unsigned long int level,
                                  unsigned long int *node_start);
 struct tower_node *tower_first (const struct tower *);
+struct tower_node *tower_last (const struct tower *);
 struct tower_node *tower_next (const struct tower *,
                                const struct tower_node *);
+struct tower_node *tower_prev (const struct tower *,
+                               const struct tower_node *);
 
 #endif /* libpspp/tower.h */