Class ScalableXHTMLPanel

    • Constructor Detail

      • ScalableXHTMLPanel

        public ScalableXHTMLPanel()
        Instantiates an XHTMLPanel with no Document loaded by default.
      • ScalableXHTMLPanel

        public ScalableXHTMLPanel​(UserAgentCallback uac)
        Instantiates a panel with a custom UserAgentCallback implementation.
        Parameters:
        uac - The custom UserAgentCallback implementation.
    • Method Detail

      • setDocument

        public void setDocument​(Document doc,
                                @Nullable
                                String url)
        Renders a Document using a URL as a base URL for relative paths.
        Overrides:
        setDocument in class XHTMLPanel
        Parameters:
        doc - The new document value
        url - The new document value
      • setDocument

        public void setDocument​(InputStream stream,
                                String url)
        Renders a Document read from an InputStream using a URL as a base URL for relative paths.
        Overrides:
        setDocument in class XHTMLPanel
        Parameters:
        stream - The stream to read the Document from.
        url - The URL used to resolve relative path references.
      • find

        public Box find​(int x,
                        int y)
        Search Box according to scale factor
        Overrides:
        find in class RootPanel
        Parameters:
        x - The displayed x position
        y - the displayed y position
      • getScale

        public double getScale()
      • removeScaleChangeListener

        public void removeScaleChangeListener​(ScaleChangeListener scl)
      • doRender

        protected void doRender​(RenderingContext c,
                                Layer root)
        Renders according to scale factor
        Overrides:
        doRender in class BasicPanel
        Parameters:
        c - the RenderingContext to use
        root - The Layer to render
      • calculateScaleAccordingToPolicy

        protected void calculateScaleAccordingToPolicy​(Dimension layoutSize)
      • convertToScaled

        protected Point convertToScaled​(Point origin)
      • convertFromScaled

        protected Point convertFromScaled​(Point origin)
      • convertToScaled

        protected Point convertToScaled​(int x,
                                        int y)
      • convertFromScaled

        protected Point convertFromScaled​(int x,
                                          int y)
      • getScalePolicy

        public int getScalePolicy()
      • setScalePolicy

        public void setScalePolicy​(int scalePolicy)