summaryrefslogtreecommitdiffstats
path: root/generic/tkCanvUtil.c
diff options
context:
space:
mode:
authorferrieux <ferrieux@users.sourceforge.net>2008-11-27 23:47:09 (GMT)
committerferrieux <ferrieux@users.sourceforge.net>2008-11-27 23:47:09 (GMT)
commit01a618069d775fcdce058d2fc203f55073e95435 (patch)
treec9fc8e9cb71b8cf58580375c8cbc29a24be76984 /generic/tkCanvUtil.c
parent713876e1f5bca010fe3fa12da61c8fdf67cd5665 (diff)
downloadtk-01a618069d775fcdce058d2fc203f55073e95435.zip
tk-01a618069d775fcdce058d2fc203f55073e95435.tar.gz
tk-01a618069d775fcdce058d2fc203f55073e95435.tar.bz2
Millimeter patch. Fixes [1813597,2218964] by eliminating the functional redundancy and unnecessary loss of precision of the {pixel,mm}ObjType tandem.
Diffstat (limited to 'generic/tkCanvUtil.c')
-rw-r--r--generic/tkCanvUtil.c9
1 files changed, 2 insertions, 7 deletions
diff --git a/generic/tkCanvUtil.c b/generic/tkCanvUtil.c
index 31e3af6..85a6c1f 100644
--- a/generic/tkCanvUtil.c
+++ b/generic/tkCanvUtil.c
@@ -9,7 +9,7 @@
* See the file "license.terms" for information on usage and redistribution of
* this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkCanvUtil.c,v 1.23 2008/11/09 21:53:39 nijtmans Exp $
+ * RCS: @(#) $Id: tkCanvUtil.c,v 1.24 2008/11/27 23:47:09 ferrieux Exp $
*/
#include "tkInt.h"
@@ -261,12 +261,7 @@ Tk_CanvasGetCoordFromObj(
* form may be used here). */
double *doublePtr) /* Place to store converted coordinate. */
{
- if (Tk_GetMMFromObj(Canvas(canvas)->interp, Canvas(canvas)->tkwin, obj,
- doublePtr) != TCL_OK) {
- return TCL_ERROR;
- }
- *doublePtr *= Canvas(canvas)->pixelsPerMM;
- return TCL_OK;
+ return Tk_GetDoublePixelsFromObj(Canvas(canvas)->interp, Canvas(canvas)->tkwin, obj, doublePtr);
}
/*