Argument arg1 = (Argument)args.get(0); Argument arg2 = (Argument)args.get(1);
	public Argument evaluate(ContextStack context, Argument arg1, Argument arg2)		throws MapyrusException	{		String s = arg1.getStringValue();		double maxWidth = arg2.getNumericValue();		StringTokenizer st = new StringTokenizer(s);		String token;		StringDimension dim;		double lineWidth = 0;		double wordWidth;		StringBuffer sb = new StringBuffer(s.length() + 5);		/*		 * Break string into lines, not exceeding maxWidth in length.		 */		while (st.hasMoreTokens())		{			token = st.nextToken();			if (lineWidth > 0)				token = " " + token;			/*			 * Calculate width of next word.  If word is too long to			 * add to current line then start a new line, then add word.			 */			dim = context.getStringDimension(token);			wordWidth = dim.getWidth();			if (lineWidth > 0 && lineWidth + wordWidth > maxWidth)			{				sb.append(Constants.LINE_SEPARATOR);								/*				 * Trim any leading space we added before starting new line.				 */				token = token.trim();				dim = context.getStringDimension(token);				wordWidth = dim.getWidth();				lineWidth = 0;			}			/*			 * If this word alone is too long for a line, then split it into			 * a hyphenated word (like "compli-cations") over two lines.			 */			while (lineWidth + wordWidth > maxWidth)			{				int tokenLength = token.length();				int i = 1;				String lastPartToken = null;				String partToken = "";				wordWidth = 0;				while (i < tokenLength && lineWidth + wordWidth <= maxWidth)				{					lastPartToken = partToken;					partToken = token.substring(0, i);					dim = context.getStringDimension(partToken + "-");					wordWidth = dim.getWidth();					i++;				}								/*				 * Ensure that there is at least one letter on each line,				 * regardless of whether it fits or not.				 */				if (lastPartToken.length() == 0)					lastPartToken = token.substring(0, 1);				sb.append(lastPartToken);				sb.append("-");				sb.append(Constants.LINE_SEPARATOR);				token = token.substring(lastPartToken.length());				dim = context.getStringDimension(token);				wordWidth = dim.getWidth();			}			sb.append(token);			lineWidth += wordWidth;		}		Argument retval = new Argument(Argument.STRING, sb.toString());		return(retval);	}