Methods' Details |
selectFont
void |
selectFont( |
[in] string |
sFontName, |
| [in] double |
size, |
| [in] bool |
bold, |
| [in] bool |
italic ); |
- Description
- Select a font.
This method selects the specified font (or a close substitute)
as the current font for text output.
- Parameter sFontName
- The name of the font (like e.g. Arial)
- Parameter size
- The size of the font (note that this is not the usual points
unit, but in the same coordinate system as the other rendering
operations - usually, device pixel).
- Parameter bold
- When true, selected font is bold.
- Parameter italic
- When true, selected font is italic
|
|
setPenColor
void |
setPenColor( |
[in] ::com::sun::star::util::Color |
nsRgbaColor ); |
- Description
- Sets the color used by line and text operations.
To disable stroking, simply set this color to something with
zero alpha (i.e. fully transparent).
- Parameter nsRgbaColor
- RGBA color tuple, interpreted in the sRGB color space.
|
|
setFillColor
void |
setFillColor( |
[in] ::com::sun::star::util::Color |
nsRgbaColor ); |
- Description
- Sets the fill color.
To disable filling, simply set this color to something with
zero alpha (i.e. fully transparent).
- Parameter nsRgbaColor
- RGBA color tuple, interpreted in the sRGB color space.
|
|
setRectClip
void |
setRectClip( |
[in] ::com::sun::star::geometry::RealRectangle2D |
aRect ); |
- Description
- Sets the clip to the specified rectangle.
|
|
setTransformation
void |
setTransformation( |
[in] ::com::sun::star::geometry::AffineMatrix2D |
aTransform ); |
- Description
- Set the current transform matrix.
|
|
drawPixel
void |
drawPixel( |
[in] ::com::sun::star::geometry::RealPoint2D |
aPoint ); |
- Description
- Sets a single pixel on the canvas.
|
|
drawLine
void |
drawLine( |
[in] ::com::sun::star::geometry::RealPoint2D |
aStartPoint, |
| [in] ::com::sun::star::geometry::RealPoint2D |
aEndPoint ); |
- Description
- Draws a line on the canvas.
|
|
drawRect
void |
drawRect( |
[in] ::com::sun::star::geometry::RealRectangle2D |
aRect ); |
- Description
- Draws a rectangle on the canvas.
|
|
drawPolyPolygon
- Description
- Draws a poly-polygon on the canvas.
|
|
drawText
void |
drawText( |
[in] StringContext |
aText, |
| [in] ::com::sun::star::geometry::RealPoint2D |
aOutPos, |
| [in] byte |
nTextDirection ); |
- Description
- Draws text on the canvas.
- Parameter aText
- Text to render
- Parameter aOutPos
- Output position of the text. This is the left or right edge,
depending on nTextDirection. Output position is always
relative to the font baseline.
- Parameter nTextDirection
- A value from the TextDirection collection,
denoting the main writing direction for this string. The main
writing direction determines the origin of the text output,
i.e. the left edge for left-to-right and the right edge for
right-to-left text.
|
|
drawBitmap
void |
drawBitmap( |
[in] XBitmap |
xBitmap, |
| [in] ::com::sun::star::geometry::RealPoint2D |
aLeftTop ); |
- Description
- Draws the bitmap on the canvas.
- Parameter xBitmap
- Bitmap to render
- Parameter aLeftTop
- Left, top position of the bitmap on the destination canvas.
|
|
getDevice
- Description
- Request the associated graphic device for this canvas.
A graphic device provides methods specific to the underlying
output device capabilities, which are common for all canvases
rendering to such a device. This includes device resolution,
color space, or bitmap formats.
- Returns
- the associated XGraphicDevice .
|
|
getCanvas
- Description
- Query the underlying XCanvas .
- Returns
- the canvas interface this object is internally based
on.
|
|
getFontMetrics
- Description
- Request the font metrics of the current font.
- Returns
- the font metrics of the currently selected font.
|
|
getCurrentFont
- Description
- Retrieve currently selected font.
- Returns
- the font instance that's currently used for rendering
text.
|
|
getCurrentPenColor
::com::sun::star::util::Color |
getCurrentPenColor(); |
- Description
- Retrieve color currently used for lines.
|
|
getCurrentFillColor
::com::sun::star::util::Color |
getCurrentFillColor(); |
- Description
- Retrieve color currently used for fills
|
|
getCurrentClipRect
::com::sun::star::geometry::RealRectangle2D |
getCurrentClipRect(); |
- Description
- Retrieve current clip rect
|
|
getCurrentTransformation
::com::sun::star::geometry::AffineMatrix2D |
getCurrentTransformation(); |
- Description
- Retrieve current transformation matrix
|
|
getCurrentViewState
- Description
- Retrieve view state.
- Returns
- the view state, that would generate matching output,
when rendering to an XCanvas instead.
|
|
getCurrentRenderState
- Description
- Retrieve render state.
- Returns
- the render state, that would generate matching output,
when rendering to an XCanvas instead.
|
|
Copyright © 2003 Sun Microsystems, Inc.