[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [59025] trunk/blender/source/blender/ editors/interface/interface_templates.c: Fix incorrect display of constraint names on retina / high DPI.
Brecht Van Lommel
brechtvanlommel at pandora.be
Thu Aug 8 19:36:19 CEST 2013
Revision: 59025
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=59025
Author: blendix
Date: 2013-08-08 17:36:19 +0000 (Thu, 08 Aug 2013)
Log Message:
-----------
Fix incorrect display of constraint names on retina / high DPI.
Modified Paths:
--------------
trunk/blender/source/blender/editors/interface/interface_templates.c
Modified: trunk/blender/source/blender/editors/interface/interface_templates.c
===================================================================
--- trunk/blender/source/blender/editors/interface/interface_templates.c 2013-08-08 17:22:49 UTC (rev 59024)
+++ trunk/blender/source/blender/editors/interface/interface_templates.c 2013-08-08 17:36:19 UTC (rev 59025)
@@ -1147,7 +1147,7 @@
uiBlockSetEmboss(block, UI_EMBOSS);
/* name */
- uiDefBut(block, LABEL, B_CONSTRAINT_TEST, typestr, xco + 10, yco, 100, 18, NULL, 0.0, 0.0, 0.0, 0.0, "");
+ uiDefBut(block, LABEL, B_CONSTRAINT_TEST, typestr, xco + 0.5f*UI_UNIT_X, yco, 5 * UI_UNIT_X, 0.9f*UI_UNIT_Y, NULL, 0.0, 0.0, 0.0, 0.0, "");
if (con->flag & CONSTRAINT_DISABLE)
uiLayoutSetRedAlert(row, TRUE);
@@ -1165,9 +1165,9 @@
uiBlockSetEmboss(block, UI_EMBOSSN);
/* draw a ghost icon (for proxy) and also a lock beside it, to show that constraint is "proxy locked" */
- uiDefIconBut(block, BUT, B_CONSTRAINT_TEST, ICON_GHOST, xco + 244, yco, 19, 19,
+ uiDefIconBut(block, BUT, B_CONSTRAINT_TEST, ICON_GHOST, xco + 12.2f * UI_UNIT_X, yco, 0.95f * UI_UNIT_X, 0.95f * UI_UNIT_Y,
NULL, 0.0, 0.0, 0.0, 0.0, TIP_("Proxy Protected"));
- uiDefIconBut(block, BUT, B_CONSTRAINT_TEST, ICON_LOCKED, xco + 262, yco, 19, 19,
+ uiDefIconBut(block, BUT, B_CONSTRAINT_TEST, ICON_LOCKED, xco + 13.1f * UI_UNIT_X, yco, 0.95f * UI_UNIT_X, 0.95f * UI_UNIT_Y,
NULL, 0.0, 0.0, 0.0, 0.0, TIP_("Proxy Protected"));
uiBlockSetEmboss(block, UI_EMBOSS);
@@ -1226,7 +1226,7 @@
/* Draw constraint data */
if ((con->flag & CONSTRAINT_EXPAND) == 0) {
- (yco) -= 21;
+ (yco) -= 10.5f * UI_UNIT_Y;
}
else {
box = uiLayoutBox(col);
More information about the Bf-blender-cvs
mailing list