}
/** Creates a selection helper for a document. */
private static SelectionHelper createSelectionHelper(ContentDocument doc) {
Element e = doc.getFullContentView().getDocumentElement().getImplNodelet();
HtmlSelectionHelper htmlSelection = new HtmlSelectionHelperImpl(e);
return new PassiveSelectionHelper(
htmlSelection, doc.getNodeManager(), doc.getRenderedView(), doc.getLocationMapper());
}