From 2fbdf9adc7486498d378a938f034e4ef3ee840d1 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Fri, 19 Feb 2016 09:22:26 +1100 Subject: Fix frame node text ignoring blank lines --- source/blender/editors/space_node/drawnode.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to 'source') diff --git a/source/blender/editors/space_node/drawnode.c b/source/blender/editors/space_node/drawnode.c index a130436770a..ed207e2da02 100644 --- a/source/blender/editors/space_node/drawnode.c +++ b/source/blender/editors/space_node/drawnode.c @@ -441,9 +441,14 @@ static void node_draw_frame_label(bNodeTree *ntree, bNode *node, const float asp for (line = text->lines.first; line; line = line->next) { struct ResultBLF info; - BLF_position(fontid, x, y, 0); - BLF_draw_ex(fontid, line->line, line->len, &info); - y -= line_spacing * info.lines; + if (line->line[0]) { + BLF_position(fontid, x, y, 0); + BLF_draw_ex(fontid, line->line, line->len, &info); + y -= line_spacing * info.lines; + } + else { + y -= line_spacing; + } if (y < y_min) { break; } -- cgit v1.2.3