Examples of layout()


Examples of org.xhtmlrenderer.render.BlockBox.layout()

  private void layout(int width) {
    Rectangle rect = new Rectangle(0, 0, width, DEFAULT_HEIGHT);
    sharedContext.set_TempCanvas(rect);
    BlockBox root = BoxBuilder.createRootBox(layoutContext, doc);
    root.setContainingBlock(new ViewportBox(rect));
    root.layout(layoutContext);
    this.root = root;
  }

  private Document loadDocument(final String uri) {
    return sharedContext.getUac().getXMLResource(uri).getDocument();
View Full Code Here

Examples of org.xhtmlrenderer.render.BlockBox.layout()

    public void layout() {
        LayoutContext c = newLayoutContext();
        BlockBox root = BoxBuilder.createRootBox(c, _doc);
        root.setContainingBlock(new ViewportBox(getInitialExtents(c)));
        root.layout(c);
        Dimension dim = root.getLayer().getPaintingDimension(c);
        root.getLayer().trimEmptyPages(c, dim.height);
        root.getLayer().layoutPages(c);
        _root = root;
    }
View Full Code Here

Examples of org.xhtmlrenderer.render.BlockBox.layout()

    Rectangle rect = new Rectangle(0, 0, width, DEFAULT_HEIGHT);
    sharedContext.set_TempCanvas(rect);
    LayoutContext c = newLayoutContext();
    BlockBox root = BoxBuilder.createRootBox(c, doc);
    root.setContainingBlock(new ViewportBox(rect));
    root.layout(c);
    this.root = root;
  }

  private LayoutContext newLayoutContext() {
    LayoutContext result = sharedContext.newLayoutContextInstance();
View Full Code Here

Examples of org.xhtmlrenderer.render.PageBox.layout()

   
    public void layoutPages(LayoutContext c) {
        c.setRootDocumentLayer(c.getRootLayer());
        for (Iterator i = _pages.iterator(); i.hasNext(); ) {
            PageBox pageBox = (PageBox)i.next();
            pageBox.layout(c);
        }
    }
   
    public void addPageSequence(BlockBox start) {
        if (_pageSequences == null) {
View Full Code Here

Examples of org.xhtmlrenderer.simple.Graphics2DRenderer.layout()

        BufferedImage buff = new BufferedImage(width, height, BufferedImage.TYPE_4BYTE_ABGR);
        Graphics2D g = (Graphics2D) buff.getGraphics();

        Dimension dim = new Dimension(width, height);
        renderer.layout(g, dim);
        renderer.render(g);

        StringBuffer sb = new StringBuffer();
        getDiff(sb, renderer.getPanel().getRootBox(), "");
        return sb.toString();
View Full Code Here

Examples of sun.font.GlyphLayout.layout()

                                         int start,
                                         int limit,
                                         int flags) {

        GlyphLayout gl = GlyphLayout.get(null); // !!! no custom layout engines
        StandardGlyphVector gv = gl.layout(this, frc, text,
                                           start, limit-start, flags, null);
        GlyphLayout.done(gl);
        return gv;
    }
View Full Code Here

Examples of util.settings.WindowSetting.layout()

      setting = new WindowSetting(defaultSize);

      mWindowSettings.put(windowId, setting);
    }

    setting.layout(window);
  }
}
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.