java.lang.Object
org.xhtmlrenderer.render.RenderingContext
- All Implemented Interfaces:
CssContext
Supplies information about the context in which rendering will take place
- Author:
- jmarinacci November 16, 2004
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionRenderingContext(SharedContext sharedContext) needs a new instance every run -
Method Summary
Modifier and TypeMethodDescriptionbooleanbooleanbooleanbooleangetBoxById(String id) getCss()intfloatgetDPI()getFont(FontSpecification font) floatgetFSFontMetrics(FSFont font) intfloatgetPage()intintgetUac()floatgetXHeight(FontSpecification parentFont) booleanbooleanisPaged()Returns true if the currently set media type is paged.booleanisPrint()voidsetBaseURL(String url) voidsetContext(SharedContext sharedContext) voidsetFontContext(FontContext fontContext) voidsetInitialPageNo(int initialPageNo) voidsetOutputDevice(OutputDevice outputDevice) voidvoidsetPageCount(int pageCount) voidsetRootLayer(Layer rootLayer)
-
Field Details
-
Constructor Details
-
Method Details
-
setBaseURL
-
getUac
-
getBaseURL
-
getDPI
public float getDPI() -
getMmPerDot
public float getMmPerDot()- Specified by:
getMmPerDotin interfaceCssContext
-
getDotsPerPixel
public int getDotsPerPixel()- Specified by:
getDotsPerPixelin interfaceCssContext
-
getFontSize2D
- Specified by:
getFontSize2Din interfaceCssContext
-
getXHeight
- Specified by:
getXHeightin interfaceCssContext
-
getTextRenderer
-
isPaged
public boolean isPaged()Returns true if the currently set media type is paged. Currently, returns true only for print , projection , and embossed , handheld , and tv . See the media section of the CSS 2.1 spec for more information on media types.- Returns:
- The paged value
-
getFontResolver
-
getFont
- Specified by:
getFontin interfaceCssContext
-
getCanvas
-
getFixedRectangle
-
getViewportRectangle
-
debugDrawBoxes
public boolean debugDrawBoxes() -
debugDrawLineBoxes
public boolean debugDrawLineBoxes() -
debugDrawInlineBoxes
public boolean debugDrawInlineBoxes() -
debugDrawFontMetrics
public boolean debugDrawFontMetrics() -
isInteractive
public boolean isInteractive() -
isPrint
public boolean isPrint() -
getOutputDevice
-
setOutputDevice
-
getFontContext
-
setFontContext
-
setPage
-
getPageCount
public int getPageCount() -
setPageCount
public void setPageCount(int pageCount) -
getPage
-
getPageNo
public int getPageNo() -
getCss
- Specified by:
getCssin interfaceCssContext
-
getFSFontMetrics
- Specified by:
getFSFontMetricsin interfaceCssContext
-
getRootLayer
-
setRootLayer
-
getInitialPageNo
public int getInitialPageNo() -
setInitialPageNo
public void setInitialPageNo(int initialPageNo) -
getBoxById