From b24f7b45279f7f95c396d594f3f606b685c6e611 Mon Sep 17 00:00:00 2001
From: Jonathan Wilkes <jon.w.wilkes@gmail.com>
Date: Mon, 8 Jun 2020 22:06:55 -0400
Subject: [PATCH] fix #645 anchor bar graphs at bottom when the graph has its
 own window

---
 pd/src/g_template.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/pd/src/g_template.c b/pd/src/g_template.c
index e177742bf..4bdd67f3c 100644
--- a/pd/src/g_template.c
+++ b/pd/src/g_template.c
@@ -6148,8 +6148,10 @@ static void plot_vis(t_gobj *z, t_glist *glist, t_glist *parentglist,
                         }
                         else
                         {
-                            /* case for open window displaying the array */
-                            /* tbd */
+                            /* case for open window displaying the array,
+                               apparently we use the same value for the bottom
+                               of the bar */
+                            py2 = glist->gl_y2;
                         }
                     }
                     int mex1 = fielddesc_cvttocoord(xfielddesc, usexloc);
-- 
GitLab