From 386872b98b548fcd9cb753ec8d5f2e07136e4dda Mon Sep 17 00:00:00 2001 From: Julian Eisel Date: Wed, 16 Mar 2016 12:51:15 +0100 Subject: [PATCH] Fix text on collapsed node not positioned correctly with high DPI Reported by @JacquesLucke via IRC, thx! --- source/blender/editors/space_node/node_draw.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/blender/editors/space_node/node_draw.c b/source/blender/editors/space_node/node_draw.c index 85c8f50fcd3..d9c51e427c8 100644 --- a/source/blender/editors/space_node/node_draw.c +++ b/source/blender/editors/space_node/node_draw.c @@ -1066,7 +1066,7 @@ static void node_draw_hidden(const bContext *C, ARegion *ar, SpaceNode *snode, b // BLI_snprintf(showname, sizeof(showname), "[%s]", showname); /* XXX - don't print into self! */ uiDefBut(node->block, UI_BTYPE_LABEL, 0, showname, - (int)(rct->xmin + (NODE_MARGIN_X)), (int)(centy - 10), + iroundf(rct->xmin + NODE_MARGIN_X), iroundf(centy - NODE_DY * 0.5f), (short)(BLI_rctf_size_x(rct) - 18.0f - 12.0f), (short)NODE_DY, NULL, 0, 0, 0, 0, ""); }