From bbf9a4d8366bb795dfbcff5fba3801099a3b1e64 Mon Sep 17 00:00:00 2001 From: mdb Date: Sun, 12 Aug 2001 03:11:19 +0000 Subject: [PATCH] No longer need this class now that we're using Java 2D for rendering. git-svn-id: https://samskivert.googlecode.com/svn/trunk@245 6335cc39-0255-0410-8fd6-9bcaacd3b74c --- .../viztool/layout/PostscriptUtil.java | 24 ------------------- 1 file changed, 24 deletions(-) delete mode 100644 projects/viztool/src/java/com/samskivert/viztool/layout/PostscriptUtil.java diff --git a/projects/viztool/src/java/com/samskivert/viztool/layout/PostscriptUtil.java b/projects/viztool/src/java/com/samskivert/viztool/layout/PostscriptUtil.java deleted file mode 100644 index d1b2aa1b..00000000 --- a/projects/viztool/src/java/com/samskivert/viztool/layout/PostscriptUtil.java +++ /dev/null @@ -1,24 +0,0 @@ -// -// $Id: PostscriptUtil.java,v 1.1 2001/07/13 23:25:13 mdb Exp $ - -package com.samskivert.viztool.viz; - -/** - * Postscript related utility functions. - */ -public class PostscriptUtil -{ - /** - * Estimates the width of the supplied string rendered in a font of - * the specified point size. It does this by assuming the average - * character width is 60% of the point size and multiplies that by the - * length of the supplied string. Not the most accurate mechanism in - * the world but you should only use this for rough estimates and - * should include postscript code to do the right thing (using strwid) - * when actually rendering the page. - */ - public static int estimateWidth (String text, int pointSize) - { - return (pointSize * text.length() * 6) / 10; - } -}