public void setDocumentRelative(String id) {
		try {
			Box box = xHTMLPanel.getSharedContext().getBoxById(id);
			if (box != null) {
				Point pt;
				if (box.getStyle().isInline()) {
					pt = new Point(box.getAbsX(), box.getAbsY());
				} else {
					RectPropertySet margin = box.getMargin(xHTMLPanel
							.getLayoutContext());
					pt = new Point(box.getAbsX() + (int) margin.left(),
							box.getAbsY() + (int) margin.top());
				}
				xHTMLPanel.scrollTo(pt);
			}

		} catch (NullPointerException e) {
			System.err.println(e.getMessage());
		}
	}