|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.stimulsoft.base.drawing.StiGraphics
public class StiGraphics
Graphics adapter class that translate sti commands to graphics representation. Copyright Stimulsoft
| Nested Class Summary | |
|---|---|
class |
StiGraphics.Cubic
This class represents a cubic polynomial |
| Field Summary | |
|---|---|
static Float |
HTML_SCALE
HTML JTextPane scale |
| Constructor Summary | |
|---|---|
StiGraphics(Graphics g)
Constructor |
|
| Method Summary | |
|---|---|
Stroke |
beginFill(StiBrush brush,
StiPen pen,
StiRectangle rect,
Double zoom)
Set fill format |
void |
clearOffset()
Clear coordinates offset |
void |
clearRotate()
Pop rotation from stack |
StiRectangle |
drawAttributedString(String allText,
Font awtFont,
StiRectangle rect,
Boolean underline,
Boolean wordWrap,
StiTextHorAlignment horAlignment,
Boolean draw,
List<StiLineInfo> lines,
Boolean useRightToLeft)
Draw attribute string |
void |
drawCurve(StiPoint[] points,
StiPen pen,
Double zoom,
Boolean transformRect)
Draw curve |
void |
drawEllise(StiRectangle rect,
StiPen pen,
StiBrush brush,
Double zoom,
Double pageZoom)
Draw ellipse |
void |
drawElliseBegin(StiRectangle rect,
StiPen pen,
StiBrush brush,
Double zoom)
Begin draw ellipse |
void |
drawElliseEnd(StiRectangle rect)
End draw ellipse |
void |
drawHTMLText(String text,
StiRectangle rect,
StiFont font,
StiColor color,
StiTextHorAlignment horAlignment,
StiVertAlignment vertAlignment,
Boolean wordWrap,
StiPenStyle linesOfUnderline,
StiBorder border,
StiTextOptions textOptions,
Double zoom)
Draw HTML text |
void |
drawImage(BufferedImage image,
StiRectangle rect,
Boolean stretch,
Boolean smooth,
Boolean scaleBitmap,
Double zoom)
Draw BufferedImage with alpha value 1 |
void |
drawImage(BufferedImage image,
StiRectangle rect,
Boolean stretch,
Boolean smooth,
Boolean scaleBitmap,
float alpha,
Double zoom)
Draw BufferedImage |
void |
drawImage(BufferedImage image,
StiRectangle rect,
Boolean stretch,
Boolean smooth,
double zoom)
Draw BufferedImage with scaling alpha value 1 |
void |
drawLine(StiPoint start,
StiPoint end,
StiPen pen,
Double zoom)
Draw line by start & end StiPoint with transofmation coordinates with stored offsets |
void |
drawLine(StiPoint start,
StiPoint end,
StiPen pen,
Double zoom,
Boolean transformRect)
Draw line by start & end StiPoint |
void |
drawLineXY(Double x1,
Double y1,
Double x2,
Double y2,
StiPen pen,
Double zoom)
Draw line by coordinates |
void |
drawLineXY(Double x1,
Double y1,
Double x2,
Double y2,
StiPen pen,
Double zoom,
Boolean transformRect)
Draw line by coordinates |
StiRectangle |
drawPath(List<StiPathCommand> path,
StiPen pen,
StiBrush brush,
Boolean transformCoord,
double zoom,
double pageZoom)
Draw path sotred in List StiPathCommand |
StiRectangle |
drawPath(List<StiPathCommand> path,
StiPen pen,
StiBrush brush,
Boolean transformCoord,
double zoom,
double pageZoom,
boolean draw)
Draw path sotred in List StiPathCommand |
void |
drawPath(List<StiPathCommand> path,
StiPen pen,
StiBrush brush,
double zoom,
double pageZoom)
Draw path sotred in List StiPathCommand |
void |
drawRectangle(StiRectangle rect,
StiPen pen,
StiBrush brush,
Double zoom,
Double pageZoom)
Draw rectangle |
void |
drawRectangle(StiRectangle rect,
StiPen pen,
StiBrush brush,
Double cornerRadius,
Double zoom,
Double pageZoom)
Draw rounded rectangle |
void |
drawRTFText(String text,
StiRectangle rect,
Double zoom)
Draw RFT text |
void |
drawText(String text,
StiRectangle rect,
StiFont font,
StiBrush brush,
StiTextHorAlignment horAlignment,
StiVertAlignment vertAlignment,
Boolean wordWrap,
Double zoom,
StiPenStyle linesOfUnderline,
StiBorder border,
StiTextOptions textOptions)
Draw text |
static StiGraphics |
fromImage(BufferedImage image)
|
Graphics2D |
getG()
|
Boolean |
getIntegerCoords()
Round coorditates before painting |
Double |
getOffsetX()
Return X offset |
Double |
getOffsetY()
Return Y offset |
Rectangle |
restoreClip()
Restore clip from clip stack |
void |
setClip(StiRectangle rect)
Set clip & fit it in old(stored in stack) clip |
void |
setFixedClip(StiRectangle rect)
Set clip without fiting to old(stored in stack) clip |
void |
setG(Graphics2D g)
|
void |
setIntegerCoords(Boolean value)
Round coordinates |
Stroke |
setLineStyle(StiPen pen,
StiRectangle rect,
double zoom)
Set line style |
void |
setOffset(double x,
double y)
Set coordinates offset |
void |
setRotate(double angle,
double centerX,
double centerY)
Set rotation params & store it in stack |
void |
setTransformedClip(StiRectangle rect)
Set clip (push it to stack) with trasnform it with offsets & fit clip in older(stored) clip |
StiPoint |
transformCoords(Double x,
Double y,
Double ox,
Double oy)
Tramsform coordinates |
StiPoint |
transformPoint(StiPoint point,
Double ox,
Double oy)
Transform StiPoint with offsets |
StiPoint |
transformPointRound(StiPoint point,
Double ox,
Double oy)
Transform StiPoint with offsets & round coordinates with stored digits after point |
StiRectangle |
transformRect(StiRectangle rect)
Transform StiRectangle |
StiRectangle |
transformRect(StiRectangle rect,
Double ox,
Double oy)
Transform StiRectangle with offsets |
StiRectangle |
transformRectRound(StiRectangle rect)
Transform StiRectangle with stored offsets & round with stored digits after point |
StiRectangle |
transformRectRound(StiRectangle rect,
Double ox,
Double oy,
Integer digits)
Transform StiRectangle & round it with digits after point |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final Float HTML_SCALE
JTextPane scale
| Constructor Detail |
|---|
public StiGraphics(Graphics g)
g - | Method Detail |
|---|
public static StiGraphics fromImage(BufferedImage image)
public Boolean getIntegerCoords()
public void setIntegerCoords(Boolean value)
value -
public void setOffset(double x,
double y)
x - y - public void clearOffset()
public void setTransformedClip(StiRectangle rect)
rect - public Rectangle restoreClip()
public void setFixedClip(StiRectangle rect)
rect - public void setClip(StiRectangle rect)
rect -
public void setRotate(double angle,
double centerX,
double centerY)
angle - centerX - x coordinate to rotatecenterY - y coordinate to rotatepublic void clearRotate()
public StiPoint transformCoords(Double x,
Double y,
Double ox,
Double oy)
x - y - ox - oy -
public StiPoint transformPointRound(StiPoint point,
Double ox,
Double oy)
StiPoint with offsets & round coordinates with stored digits after point
point - StiPointox - X offsetoy - Y offset
public StiPoint transformPoint(StiPoint point,
Double ox,
Double oy)
StiPoint with offsets
point - StiPointox - oy -
public StiRectangle transformRectRound(StiRectangle rect,
Double ox,
Double oy,
Integer digits)
StiRectangle & round it with digits after point
rect - StiRectangleox - X offsetoy - Y offsetdigits - Round to digits after point
public StiRectangle transformRectRound(StiRectangle rect)
StiRectangle with stored offsets & round with stored digits after point
rect - StiRectangle
public StiRectangle transformRect(StiRectangle rect)
StiRectangle
rect - StiRectangle
public StiRectangle transformRect(StiRectangle rect,
Double ox,
Double oy)
StiRectangle with offsets
rect - StiRectangleox - X offsetoy - Y offset
public Stroke setLineStyle(StiPen pen,
StiRectangle rect,
double zoom)
pen - StiPointrect - StiRectanglezoom -
public Stroke beginFill(StiBrush brush,
StiPen pen,
StiRectangle rect,
Double zoom)
brush - StiBrushpen - StiPenrect - StiRectangle to paint inzoom -
public void drawPath(List<StiPathCommand> path,
StiPen pen,
StiBrush brush,
double zoom,
double pageZoom)
StiPathCommand
path - List StiPathCommandpen - StiPenbrush - StiBrushzoom - pageZoom -
public StiRectangle drawPath(List<StiPathCommand> path,
StiPen pen,
StiBrush brush,
Boolean transformCoord,
double zoom,
double pageZoom)
StiPathCommand
path - List StiPathCommandpen - StiPenbrush - StiBrushtransformCoord - is need to transform coordinates with stored offsetszoom - pageZoom - draw -
public StiRectangle drawPath(List<StiPathCommand> path,
StiPen pen,
StiBrush brush,
Boolean transformCoord,
double zoom,
double pageZoom,
boolean draw)
StiPathCommand
path - List StiPathCommandpen - StiPenbrush - StiBrushtransformCoord - is need to transform coordinates with stored offsetszoom - pageZoom - draw -
public void drawRectangle(StiRectangle rect,
StiPen pen,
StiBrush brush,
Double zoom,
Double pageZoom)
rect - StiRectanglepen - StiPenbrush - StiBrushzoom - pageZoom -
public void drawRectangle(StiRectangle rect,
StiPen pen,
StiBrush brush,
Double cornerRadius,
Double zoom,
Double pageZoom)
rect - StiRectanglepen - StiPenbrush - StiBrushcornerRadius - zoom - pageZoom -
public void drawEllise(StiRectangle rect,
StiPen pen,
StiBrush brush,
Double zoom,
Double pageZoom)
rect - StiRectanglepen - StiPenbrush - StiBrushzoom - pageZoom -
public void drawElliseBegin(StiRectangle rect,
StiPen pen,
StiBrush brush,
Double zoom)
rect - StiRectanglepen - StiPenbrush - StiBrushzoom - public void drawElliseEnd(StiRectangle rect)
rect - StiRectangle
public void drawLineXY(Double x1,
Double y1,
Double x2,
Double y2,
StiPen pen,
Double zoom,
Boolean transformRect)
x1 - y1 - x2 - y2 - pen - StiPenzoom - transformRect - is need to transform coordinates with stored offsets
public void drawLineXY(Double x1,
Double y1,
Double x2,
Double y2,
StiPen pen,
Double zoom)
x1 - y1 - x2 - y2 - pen - StiPenzoom -
public void drawLine(StiPoint start,
StiPoint end,
StiPen pen,
Double zoom)
StiPoint with transofmation coordinates with stored offsets
start - StiPointend - StiPointpen - StiPenzoom -
public void drawLine(StiPoint start,
StiPoint end,
StiPen pen,
Double zoom,
Boolean transformRect)
StiPoint
start - StiPointend - StiPointpen - StiPenzoom - transformRect - is need to transform coordinates with sored offsets
public void drawCurve(StiPoint[] points,
StiPen pen,
Double zoom,
Boolean transformRect)
polygon - pen - zoom - transformRect -
public void drawImage(BufferedImage image,
StiRectangle rect,
Boolean stretch,
Boolean smooth,
double zoom)
BufferedImage with scaling alpha value 1
image - BufferedImagerect - StiRectanglestretch - is need to stretch imagesmooth - is need to smooth imagezoom -
public void drawImage(BufferedImage image,
StiRectangle rect,
Boolean stretch,
Boolean smooth,
Boolean scaleBitmap,
Double zoom)
BufferedImage with alpha value 1
image - BufferedImagerect - StiRectanglestretch - is need to stretch imagesmooth - is need to smooth imagescaleBitmap - is need to scale imagezoom -
public void drawImage(BufferedImage image,
StiRectangle rect,
Boolean stretch,
Boolean smooth,
Boolean scaleBitmap,
float alpha,
Double zoom)
BufferedImage
image - BufferedImagerect - StiRectanglestretch - is need to stretch imagesmooth - is need to smooth imagescaleBitmap - is need to scale imagealpha - alphe valuezoom -
public void drawRTFText(String text,
StiRectangle rect,
Double zoom)
text - rect - StiRectangle with RTF textzoom -
public void drawHTMLText(String text,
StiRectangle rect,
StiFont font,
StiColor color,
StiTextHorAlignment horAlignment,
StiVertAlignment vertAlignment,
Boolean wordWrap,
StiPenStyle linesOfUnderline,
StiBorder border,
StiTextOptions textOptions,
Double zoom)
text - rect - StiRectanglefont - StiFontcolor - StiColorhorAlignment - StiTextHorAlignmentvertAlignment - StiVertAlignmentwordWrap - is need wo wrap wordslinesOfUnderline - is need do draw lines of underlineborder - StiBordertextOptions - StiTextOptionszoom -
public void drawText(String text,
StiRectangle rect,
StiFont font,
StiBrush brush,
StiTextHorAlignment horAlignment,
StiVertAlignment vertAlignment,
Boolean wordWrap,
Double zoom,
StiPenStyle linesOfUnderline,
StiBorder border,
StiTextOptions textOptions)
text - rect - StiRectangle text rectanglefont - StiFontbrush - StiBrushhorAlignment - StiTextHorAlignmentvertAlignment - StiVertAlignmentwordWrap - is need to wrap wordszoom - linesOfUnderline - is need to draw liens of underlineborder - StiBordertextOptions - StiTextOptions
public StiRectangle drawAttributedString(String allText,
Font awtFont,
StiRectangle rect,
Boolean underline,
Boolean wordWrap,
StiTextHorAlignment horAlignment,
Boolean draw,
List<StiLineInfo> lines,
Boolean useRightToLeft)
allText - awtFont - Fontrect - StiRectangleunderline - in underline fornwordWrap - is need to wrap wordshorAlignment - StiTextHorAlignmentdraw - is need to draw or only calculate text rectlines - - returns string fit linesuseRightToLeft - - Right to left text
public Graphics2D getG()
Graphics2Dpublic Double getOffsetX()
public Double getOffsetY()
public void setG(Graphics2D g)
g - the g to set
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||