int [] items = new int [1];
int font = args [7]; int [] buffer = new int [1];
public Point computeSize (int wHint, int hHint, boolean changed) {	checkWidget();	/**	 * Feature in Photon - The preferred width calculated by	 * PtWidgetPreferredSize is the current width.	 */	PhDim_t dim = new PhDim_t();	if (!OS.PtWidgetIsRealized (handle)) OS.PtExtentWidget (handle);	OS.PtWidgetPreferredSize(handle, dim);	int width = 0, height = dim.h;	int [] args = new int [] {		OS.Pt_ARG_LIST_ITEM_COUNT, 0, 0,		OS.Pt_ARG_ITEMS, 0, 0,		OS.Pt_ARG_LIST_FONT, 0, 0,	};	OS.PtGetResources (handle, args.length / 3, args);	PhRect_t rect = new PhRect_t();	int [] items = new int [1];	for (int i = 0; i < args [1]; i++) {		OS.memmove (items, args [4] + (i * 4), 4);		int length = OS.strlen (items [0]);		OS.PfExtentText(rect, null, args [7], items [0], length);		width = Math.max(width, rect.lr_x - rect.ul_x + 1);	}	rect = new PhRect_t ();	PhArea_t area = new PhArea_t ();	rect.lr_x = (short) (width + 1);	OS.PtSetAreaFromWidgetCanvas (handle, rect, area);	width = area.size_w;	if (wHint != SWT.DEFAULT || hHint != SWT.DEFAULT) {		rect = new PhRect_t ();		area = new PhArea_t ();		rect.lr_x = (short) (wHint - 1);		rect.lr_y = (short) (hHint - 1);		OS.PtSetAreaFromWidgetCanvas (handle, rect, area);		ScrollBar scroll;		if (wHint != SWT.DEFAULT) {			width = area.size_w;			if ((scroll = getVerticalBar()) != null)				width += scroll.getSize().x;		}		if (hHint != SWT.DEFAULT) {			height = area.size_h;			if ((scroll = getHorizontalBar()) != null)				height += scroll.getSize().y;		}	}	return new Point(width, height);}