[Bf-blender-cvs] [df3394a] master: Fix vertical scrollbar adding to region width in graph editor

Julian Eisel noreply at git.blender.org
Fri Sep 16 16:21:56 CEST 2016


Commit: df3394a3865af81d1cd955caed04021a476013dd
Author: Julian Eisel
Date:   Fri Sep 16 16:20:28 2016 +0200
Branches: master
https://developer.blender.org/rBdf3394a3865af81d1cd955caed04021a476013dd

Fix vertical scrollbar adding to region width in graph editor

Had to calculate draw region width based on region size excluding scrollbars.

===================================================================

M	source/blender/editors/space_graph/graph_draw.c

===================================================================

diff --git a/source/blender/editors/space_graph/graph_draw.c b/source/blender/editors/space_graph/graph_draw.c
index ae91a46..96a078b 100644
--- a/source/blender/editors/space_graph/graph_draw.c
+++ b/source/blender/editors/space_graph/graph_draw.c
@@ -1131,7 +1131,7 @@ void graph_draw_channel_names(bContext *C, bAnimContext *ac, ARegion *ar)
 	 *	  start of list offset, and the second is as a correction for the scrollers.
 	 */
 	height = (float)((items * ACHANNEL_STEP(ac)) + (ACHANNEL_HEIGHT(ac) * 2));
-	UI_view2d_totRect_set(v2d, ar->winx, height);
+	UI_view2d_totRect_set(v2d, BLI_rcti_size_x(&ar->v2d.mask), height);
 	
 	/* loop through channels, and set up drawing depending on their type  */
 	{   /* first pass: just the standard GL-drawing for backdrop + text */




More information about the Bf-blender-cvs mailing list