Commit ae2d5df7 authored by Ivica Bukvic's avatar Ivica Bukvic
Browse files

*forced hidetext on all gop arrays to make its resizing sane. Later update...

*forced hidetext on all gop arrays to make its resizing sane. Later update properties to reflect lack of this option.
parent 76c614ca
......@@ -592,7 +592,16 @@ void glist_glist(t_glist *g, t_symbol *s, int argc, t_atom *argv)
otherwise it appears as a text box. */
int glist_isgraph(t_glist *x)
{
return (x->gl_isgraph|(x->gl_hidetext<<1));
// testing to see if we have an array and force hiding text (later update GUI accordingly)
t_gobj *g = x->gl_list;
int hasarray = 0;
while (g) {
if (pd_class(&g->g_pd) == garray_class) hasarray = 1;
g = g->g_next;
}
if (hasarray && x->gl_isgraph && !x->gl_hidetext)
x->gl_hidetext = 1;
return (x->gl_isgraph|(x->gl_hidetext<<1));
}
/* This is sent from the GUI to inform a toplevel that its window has been
......
......@@ -2370,6 +2370,19 @@ void canvas_setgraph(t_glist *x, int flag, int nogoprect)
}
x->gl_isgraph = 1;
x->gl_hidetext = !(!(flag&2));
// check if we have array inside GOP, if so, make sure hidetext is always hidden no matter what
t_gobj *g = x->gl_list;
int hasarray = 0;
while (g) {
if (pd_class(&g->g_pd) == garray_class) hasarray = 1;
g = g->g_next;
}
if (hasarray)
x->gl_hidetext = 1;
if (!nogoprect && !x->gl_goprect)
{
/* Ivica Ico Bukvic 5/16/10 <ico@bukvic.net> */
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment