XpsCanvas

Inheritance: java.lang.Object, com.aspose.xps.XpsObject, com.aspose.xps.XpsElement, com.aspose.xps.XpsHyperlinkElement, com.aspose.xps.XpsContentElement

public final class XpsCanvas extends XpsContentElement

Class incapsulating Canvas element features. This element groups elements together. For example, Glyphs and Path elements can be grouped in a canvas in order to be identified as a unit (as a hyperlink destination) or to apply a composed property value to each child and ancestor element.

Methods

MethodDescription
add(T element)Adds an element to this canvas’s child list.
insert(int index, T element)Inserts an element to this canvas’s child list at index position.
addCanvas()Adds a new canvas to this canvas’s child list.
addGlyphs(String fontFamily, float fontSize, XpsFontStyle fontStyle, float originX, float originY, String unicodeString)Adds new glyphs to this canvas’s child list.
addPath(XpsPathGeometry data)Adds a new path to this canvas’s child list.
deepClone()Clones this canvas.
equals(Object arg0)
get(int i)Provides access to element’s children by index i .
getClass()
getClip()Returns the path geometry limiting the rendered region of the element.
getEdgeMode()Returns the value that controls how edges of paths within the canvas are rendered.
getHyperlinkTarget()Returns hyperlink target object.
getOpacity()Returns the value defining the uniform transparency of the element.
getOpacityMask()Returns the brush specifying a mask of alpha values that is applied to the element in the same fashion as the Opacity attribute, but allowing different alpha values for different areas of the element.
getRenderTransform()Returns the affine transformation matrix establishing a new coordinate frame for all attributes of the element and for all child elements (if any).
hashCode()
insertCanvas(int index)Inserts a new canvas to this canvas’s child list at index position.
insertGlyphs(int index, String fontFamily, float fontSize, XpsFontStyle fontStyle, float originX, float originY, String unicodeString)Inserts new glyphs to this canvas’s child list at index position.
insertPath(int index, XpsPathGeometry data)Inserts a new path to this canvas’s child list at index position.
iterator()Implementation of Iterable interface.
notify()
notifyAll()
setClip(XpsPathGeometry value)Sets the path geometry limiting the rendered region of the element.
setEdgeMode(XpsEdgeMode value)Sets the value that controls how edges of paths within the canvas are rendered.
setHyperlinkTarget(XpsHyperlinkTarget value)Sets hyperlink target object.
setOpacity(float value)Sets the value defining the uniform transparency of the element.
setOpacityMask(XpsBrush value)Sets the brush specifying a mask of alpha values that is applied to the element in the same fashion as the Opacity attribute, but allowing different alpha values for different areas of the element.
setRenderTransform(XpsMatrix value)Sets the affine transformation matrix establishing a new coordinate frame for all attributes of the element and for all child elements (if any).
size()Returns the number of child elements.
toString()
wait()
wait(long arg0)
wait(long arg0, int arg1)

add(T element)

public T <T>add(T element)

Adds an element to this canvas’s child list.

Parameters:

ParameterTypeDescription
elementTThe element to add.

Returns: T - Added element.

insert(int index, T element)

public T <T>insert(int index, T element)

Inserts an element to this canvas’s child list at index position.

Parameters:

ParameterTypeDescription
indexintPosition at which an element should be inserted.
elementTThe element to insert.

Returns: T - Inserted element.

addCanvas()

public XpsCanvas addCanvas()

Adds a new canvas to this canvas’s child list.

Returns: XpsCanvas - Added canvas.

addGlyphs(String fontFamily, float fontSize, XpsFontStyle fontStyle, float originX, float originY, String unicodeString)

public XpsGlyphs addGlyphs(String fontFamily, float fontSize, XpsFontStyle fontStyle, float originX, float originY, String unicodeString)

Adds new glyphs to this canvas’s child list.

Parameters:

ParameterTypeDescription
fontFamilyjava.lang.StringFont family.
fontSizefloatFont size.
fontStyleXpsFontStyleFont style.
originXfloatGlyphs origin X coordinate.
originYfloatGlyphs origin T coordinate.
unicodeStringjava.lang.StringString to be printed.

Returns: XpsGlyphs - Added glyphs.

addPath(XpsPathGeometry data)

public XpsPath addPath(XpsPathGeometry data)

Adds a new path to this canvas’s child list.

Parameters:

ParameterTypeDescription
dataXpsPathGeometryThe geometry of the path.

Returns: XpsPath - Added path.

deepClone()

public XpsCanvas deepClone()

Clones this canvas.

Returns: XpsCanvas - Clone of this canvas.

equals(Object arg0)

public boolean equals(Object arg0)

Parameters:

ParameterTypeDescription
arg0java.lang.Object

Returns: boolean

get(int i)

public XpsContentElement get(int i)

Provides access to element’s children by index i .

Parameters:

ParameterTypeDescription
iintIndex of child element.

Returns: XpsContentElement - Child element at i position.

getClass()

public final native Class<?> getClass()

Returns: java.lang.Class

getClip()

public XpsPathGeometry getClip()

Returns the path geometry limiting the rendered region of the element.

Returns: XpsPathGeometry - The path geometry limiting the rendered region of the element.

getEdgeMode()

public XpsEdgeMode getEdgeMode()

Returns the value that controls how edges of paths within the canvas are rendered.

Returns: XpsEdgeMode - The edge rendering mode.

getHyperlinkTarget()

public XpsHyperlinkTarget getHyperlinkTarget()

Returns hyperlink target object.

Returns: XpsHyperlinkTarget - Hyperlink target object.

getOpacity()

public float getOpacity()

Returns the value defining the uniform transparency of the element.

Returns: float - The value defining the uniform transparency of the element.

getOpacityMask()

public XpsBrush getOpacityMask()

Returns the brush specifying a mask of alpha values that is applied to the element in the same fashion as the Opacity attribute, but allowing different alpha values for different areas of the element.

Returns: XpsBrush - The brush specifying a mask.

getRenderTransform()

public XpsMatrix getRenderTransform()

Returns the affine transformation matrix establishing a new coordinate frame for all attributes of the element and for all child elements (if any).

Returns: XpsMatrix - The affine transformation matrix.

hashCode()

public native int hashCode()

Returns: int

insertCanvas(int index)

public XpsCanvas insertCanvas(int index)

Inserts a new canvas to this canvas’s child list at index position.

Parameters:

ParameterTypeDescription
indexintPosition at which a new canvas should be inserted.

Returns: XpsCanvas - Inserted canvas.

insertGlyphs(int index, String fontFamily, float fontSize, XpsFontStyle fontStyle, float originX, float originY, String unicodeString)

public XpsGlyphs insertGlyphs(int index, String fontFamily, float fontSize, XpsFontStyle fontStyle, float originX, float originY, String unicodeString)

Inserts new glyphs to this canvas’s child list at index position.

Parameters:

ParameterTypeDescription
indexintPosition at which new glyphs should be inserted.
fontFamilyjava.lang.StringFont family.
fontSizefloatFont size.
fontStyleXpsFontStyleFont style.
originXfloatGlyphs origin X coordinate.
originYfloatGlyphs origin T coordinate.
unicodeStringjava.lang.StringString to be printed.

Returns: XpsGlyphs - Added glyphs.

insertPath(int index, XpsPathGeometry data)

public XpsPath insertPath(int index, XpsPathGeometry data)

Inserts a new path to this canvas’s child list at index position.

Parameters:

ParameterTypeDescription
indexintPosition at which a new path should be inserted.
dataXpsPathGeometryThe geometry of the path.

Returns: XpsPath - Inserted path.

iterator()

public Iterator<XpsContentElement> iterator()

Implementation of Iterable interface.

Returns: java.util.Iterator<com.aspose.xps.XpsContentElement> - Returns enumerator for the list.

notify()

public final native void notify()

notifyAll()

public final native void notifyAll()

setClip(XpsPathGeometry value)

public void setClip(XpsPathGeometry value)

Sets the path geometry limiting the rendered region of the element.

Parameters:

ParameterTypeDescription
valueXpsPathGeometryThe path geometry limiting the rendered region of the element.

setEdgeMode(XpsEdgeMode value)

public void setEdgeMode(XpsEdgeMode value)

Sets the value that controls how edges of paths within the canvas are rendered.

Parameters:

ParameterTypeDescription
valueXpsEdgeModeThe edge rendering mode.

setHyperlinkTarget(XpsHyperlinkTarget value)

public void setHyperlinkTarget(XpsHyperlinkTarget value)

Sets hyperlink target object.

Parameters:

ParameterTypeDescription
valueXpsHyperlinkTargetHyperlink target object.

setOpacity(float value)

public void setOpacity(float value)

Sets the value defining the uniform transparency of the element.

Parameters:

ParameterTypeDescription
valuefloatThe value defining the uniform transparency of the element.

setOpacityMask(XpsBrush value)

public void setOpacityMask(XpsBrush value)

Sets the brush specifying a mask of alpha values that is applied to the element in the same fashion as the Opacity attribute, but allowing different alpha values for different areas of the element.

Parameters:

ParameterTypeDescription
valueXpsBrushThe brush specifying a mask.

setRenderTransform(XpsMatrix value)

public void setRenderTransform(XpsMatrix value)

Sets the affine transformation matrix establishing a new coordinate frame for all attributes of the element and for all child elements (if any).

Parameters:

ParameterTypeDescription
valueXpsMatrixThe affine transformation matrix.

size()

public int size()

Returns the number of child elements.

Returns: int - The number of child elements.

toString()

public String toString()

Returns: java.lang.String

wait()

public final void wait()

wait(long arg0)

public final native void wait(long arg0)

Parameters:

ParameterTypeDescription
arg0long

wait(long arg0, int arg1)

public final void wait(long arg0, int arg1)

Parameters:

ParameterTypeDescription
arg0long
arg1int