com.stimulsoft.report.components.simplecomponents
Class StiRichText

java.lang.Object
  extended by com.stimulsoft.base.serializing.StiSerializedObject
      extended by com.stimulsoft.base.services.StiService
          extended by com.stimulsoft.report.StiBase
              extended by com.stimulsoft.report.components.StiComponent
                  extended by com.stimulsoft.report.components.simplecomponents.StiSimpleText
                      extended by com.stimulsoft.report.components.simplecomponents.StiRichText
All Implemented Interfaces:
IStiAppExpressionCollection, IStiJsonReportObject, IStiSerializable, IStiSerializableRef, IStiName, IStiBackColor, IStiBorder, IStiBreakable, IStiCanGrow, IStiCanShrink, IStiComponentGuid, IStiConditions, IStiEditable, IStiExportImage, IStiExportImageExtended, IStiGlobalizedName, IStiGrowToHeight, IStiInteraction, IStiOnlyText, IStiPrintOn, IStiProcessAt, IStiProcessAtEnd, IStiSelect, IStiShift, IStiText, IStiUnitConvert, IStiReportProperty, IStiGlobalizationProvider, IStiInherited, IStiStateSaveRestore, java.lang.Cloneable
Direct Known Subclasses:
StiTableCellRichText

public class StiRichText
extends StiSimpleText
implements IStiExportImageExtended, IStiBreakable, IStiBorder, IStiGlobalizationProvider, IStiBackColor

The class describes a component that allows to outtype RichText.


Field Summary
 
Fields inherited from class com.stimulsoft.report.components.simplecomponents.StiSimpleText
text, totalValueHelp
 
Fields inherited from class com.stimulsoft.report.components.StiComponent
canGrow, canShrink, componentPlacement, conditions, currentPointer, expressions, interaction, isRendered, page, parent, parentBookmark, parentPointer, top, width
 
Fields inherited from interface com.stimulsoft.base.serializing.interfaceobject.IStiSerializableRef
REFERENCE_EMPTY, REFERENCE_REPORT
 
Constructor Summary
StiRichText()
          Creates a new object of the type StiRichText.
StiRichText(StiRectangle rect)
          Creates a new component of the type StiRichText.
StiRichText(StiRectangle rect, java.lang.String text)
          Creates a new component of the type StiRichText.
 
Method Summary
 boolean Break(StiComponent dividedComponent, double devideFactor, StiRefObject<java.lang.Double> divideLine)
          Divides content of components in two parts.
 java.lang.Object clone()
          Creates a new object that is a copy of the current instance.
 StiRectangle convertTextMargins(StiRectangle rect, boolean convert)
           
 java.lang.String fixCyrillic(java.lang.String buffer)
           
 StiSize getActualSize()
          Initializes a new instance of the StiSize class from the specified dimensi.
 java.lang.String[] getAllStrings()
          Returns array of the property names which can be localized.
 StiColor getBackColor()
          Gets or sets a back color.
 StiBorder getBorder()
          Gets or sets frame of the component.
 boolean getCanBreak()
          Gets or sets value which indicates whether the component can or cannot break its contents on several pages.
 java.lang.String getDataColumn()
          Gets or sets a name of the column that contains the RTF text.
 StiDataUrlExpression getDataUrl()
           
 java.lang.String getDecodeText()
           
 StiColor getDefaultColor()
          Gets or sets default Color.
 java.awt.Font getDefaultFont()
          Gets or sets default font.
 boolean getDetectUrls()
          Gets or sets detection of urls.
 boolean getFullConvertExpression()
          Gets or sets value which indicates that it is necessary to fully convert the expression to Rtf format.
 java.lang.String getGlobalizedName()
          Gets or sets special identificator which will be used for report globalization.
 boolean getHideZeros()
          Gets or sets value indicates that no need show zeroes.
 java.awt.Image getImage()
           
 StiPenStyle getLinesOfUnderline()
          Gets or sets value indicates that it is necessary to lines of underline.
 java.lang.String getLocalizedCategory()
          Gets a localized name of the component category.
 java.lang.String getLocalizedName()
          Gets a localized component name.
 StiMargins getMargins()
          Gets or sets text margins.
 int getMaxNumberOfLines()
          Gets or sets maximum number of lines which specify the limit of the height stretch.
 StiProcessingDuplicatesType getProcessingDuplicates()
          Gets or sets value which indicates how report engine processes duplicated values.
 java.lang.String getRtfFromSource(java.lang.String dataUrlValue, java.lang.String dataColumn)
           
 java.lang.String getRtfText()
           
 java.lang.String getString(java.lang.String propertyName)
          Gets localized String from specified property name.
 int getToolboxPosition()
          Gets value to sort a position in the toolbox.
 boolean getWordWrap()
          Gets or sets word wrap.
 boolean getWysiwyg()
          Gets or sets value which indicates that it is necessary to use the Wysiwyg mode of the rendering.
 void InvokeGetValue(StiComponent sender, StiGetValueEventArgs e)
           
 boolean isExportAsImage(StiExportFormat format)
           
 void LoadFromJsonObject(JSONObject jObject)
           
static java.lang.String PackRtf(java.lang.String str)
          Pack RTF text for save and compilation.
 java.lang.String SaveState()
          Saves state of editable value.
 JSONObject SaveToJsonObject(StiJsonSaveMode mode)
           
 void setBackColor(StiColor value)
           
 void setBorder(StiBorder value)
           
 void setCanBreak(boolean value)
           
 void setDataColumn(java.lang.String value)
           
 void setDataUrl(StiDataUrlExpression value)
           
 void setDefaultColor(StiColor value)
           
 void setDefaultFont(java.awt.Font value)
           
 void setDetectUrls(boolean value)
           
 void setFullConvertExpression(boolean value)
           
 void setGlobalizedName(java.lang.String value)
           
 void setHideZeros(boolean value)
           
 void setImage(java.awt.Image value)
           
 void setLinesOfUnderline(StiPenStyle value)
           
 void setMargins(StiMargins value)
           
 void setMaxNumberOfLines(int value)
           
 void setProcessingDuplicates(StiProcessingDuplicatesType value)
           
 void setString(java.lang.String propertyName, java.lang.String value)
          Sets localized String to specified property name.
 void setTextInternal(java.lang.String value)
          Internal use only.
 void setWordWrap(boolean value)
           
 void setWysiwyg(boolean value)
           
 java.lang.String unpackRTF()
          Unpack RFT (remove service symbols)
 
Methods inherited from class com.stimulsoft.report.components.simplecomponents.StiSimpleText
checkDuplicates, getComponentGuid, getEditable, getEvents, getGetValueEvent, getLinesOfUnderlining, getOnlyText, getProcessAt, getProcessAtEnd, getQuickInfo, getText, getTextInternal, getTextValue, GetTextWithoutZero, getTotalValueHelp, InvokeRenderTo, InvokeTextProcess, ProcessText, RestoreState, saveState, setComponentGuid, setEditable, setGetValueEvent, setLinesOfUnderlining, setOnlyText, setProcessAt, setProcessAtEnd, SetText, setText, setText, SetTextInternal, setTextValue, setTotalValueHelp
 
Methods inherited from class com.stimulsoft.report.components.StiComponent
addSize, applyConditions, canContainIn, CheckForParentComponent, clearAllStates, ClearAllStates, ClearContents, clone, ComponentToPage, ComponentToPage, ComponentToPage, convert, convert, decrementTop, doBookmark, DoBookmark, DockToContainer, DockToContainer, doGetBookmark, DoOffsetRect, doPointer, fillComponentPlacement, getAfterPrintEvent, getAlias, getAllowDelete, getAnchor, getBeforePrintEvent, getBookmark, getBookmarkValue, getBottom, getCanGrow, getCanShrink, getClickEvent, getClientRectangle, getComponentPlacement, getComponentStyle, getComponentType, getConditions, getContainer, getCurrentBookmark, getDataBand, GetDataBand, getDefaultClientRectangle, getDelimiterComponent, getDisplayRectangle, getDisplayRectangle1, getDockable, getDockRegion, getDockRegion, getDockStyle, getDoubleClickEvent, getDrillDownParameters, getEnabled, getExpressions, getForceRedrawAll, getgetBookmarkEvent, getgetDrillDownReportEvent, getgetHyperlinkEvent, getgetTagEvent, getgetToolTipEvent, getGroupHeaderBand, GetGroupHeaderBand, getGrowToHeight, getGuid, getHeight, getHighlightState, getHyperlink, getHyperlinkValue, getIgnoreNamingRule, getImage, getImage, getInherited, getInteraction, getInvalidateOnMouseOver, getIsCross, getIsDesigning, getIsEnabled, getIsEventEmpty, getIsExporting, getIsgetTagHandlerEmpty, getIsPrinting, getIsRendered, getIsSelected, getLeft, getLevel, getLinked, getLocked, getMaxSize, getMeasureGraphics, getMinSize, getMouseEnterEvent, getMouseLeaveEvent, getPage, getPaintRectangle, getPaintRectangle, getPaintRectangle, getParent, getParentBookmark, getPlaceOnToolbox, getPointer, getPointerValue, getPrintable, getPrintOn, getPriority, getRenderedCount, getReport, getRestrictions, getRight, getSelectionTick, getSelectRectangle, getServiceCategory, getServiceType, getShift, getShiftMode, getShowQuickButtons, getTag, getTagStrValue, getTagValue, getToolTip, getToolTipValue, getTop, getUseParentStyles, getWidth, incrementtTop, InternalRender, invert, InvokeAfterPrint, InvokeBeforePrint, InvokeBeginRender, InvokeClick, InvokeDoubleClick, InvokeEndRender, invokeEvents, InvokegetBookmark, InvokegetDrillDownReport, InvokegetHyperlink, InvokegetTag, InvokegetToolTip, InvokeMouseEnter, InvokeMouseLeave, InvokePainted, invokePainting, isAutomaticDock, isDesigning, IsParentSelect, NewGuid, OnRemoveComponent, packService, PageToComponent, PageToComponent, paint, PlacedOnColumnBand, Prepare, render, reset, Reset, restoreState, select, setAfterPrintEvent, setAlias, setAnchor, setBeforePrintEvent, setBookmark, setBookmarkValue, setCanGrow, setCanShrink, setClickEvent, setClientRectangle, setComponentPlacement, setComponentStyle, setConditions, setCurrentBookmark, setDelimiterComponent, setDirectDisplayRectangle, setDisplayRectangle, setDockable, setDockStyle, setDoubleClickEvent, setDrillDownParameters, setEnabled, setExpressions, setgetBookmarkEvent, setgetDrillDownReportEvent, setgetHyperlinkEvent, setgetTagEvent, setgetToolTipEvent, setGrowToHeight, setGuid, setHeight, setHeightProp, setHighlightState, setHyperlink, setHyperlinkValue, setIgnoreNamingRule, setInherited, setInteraction, setIsRendered, setIsSelected, setLeft, setLeftProp, setLinked, setLocked, setMaxSize, setMinSize, setMouseEnterEvent, setMouseLeaveEvent, setName, setPage, setPaintRectangle, setParent, setParentBookmark, setPlaceOnToolbox, setPointer, setPointerValue, setPrintable, setPrintOn, setRenderedCount, setReport, SetReportVariables, setRestrictions, setSelectionTick, setSelectRectangle, setShift, setShiftMode, setShowQuickButtons, setStates, setTag, setTagValue, setToolTip, setToolTipValue, setTop, setTopProp, setUseParentStyles, setWidth, setWidthProp, toString, UnPrepare
 
Methods inherited from class com.stimulsoft.report.StiBase
getName, getServiceName
 
Methods inherited from class com.stimulsoft.base.services.StiService
getProperties, getServiceEnabled, getServiceInfo, isPropertyPresent, MemberwiseClone, properties, setProperties, setServiceEnabled
 
Methods inherited from class com.stimulsoft.base.serializing.StiSerializedObject
cleanReference, getReference, setReference
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface com.stimulsoft.report.components.interfaces.IStiExportImageExtended
getImage
 
Methods inherited from interface com.stimulsoft.report.components.interfaces.IStiExportImage
getImage
 

Constructor Detail

StiRichText

public StiRichText()
Creates a new object of the type StiRichText.


StiRichText

public StiRichText(StiRectangle rect)
Creates a new component of the type StiRichText.

Parameters:
rect - The rectangle describes size and position of the component.

StiRichText

public StiRichText(StiRectangle rect,
                   java.lang.String text)
Creates a new component of the type StiRichText.

Parameters:
rect - The rectangle describes size and position of the component.
text - Text expression
Method Detail

isExportAsImage

public boolean isExportAsImage(StiExportFormat format)
Specified by:
isExportAsImage in interface IStiExportImageExtended
Overrides:
isExportAsImage in class StiComponent

getCanBreak

public boolean getCanBreak()
Gets or sets value which indicates whether the component can or cannot break its contents on several pages.

Specified by:
getCanBreak in interface IStiBreakable

setCanBreak

public void setCanBreak(boolean value)
Specified by:
setCanBreak in interface IStiBreakable

clone

public java.lang.Object clone()
Creates a new object that is a copy of the current instance.

Overrides:
clone in class StiSimpleText
Returns:
A new object that is a copy of this instance.

setString

public void setString(java.lang.String propertyName,
                      java.lang.String value)
Sets localized String to specified property name.

Specified by:
setString in interface IStiGlobalizationProvider

getString

public java.lang.String getString(java.lang.String propertyName)
Gets localized String from specified property name.

Specified by:
getString in interface IStiGlobalizationProvider
Returns:

getAllStrings

public java.lang.String[] getAllStrings()
Returns array of the property names which can be localized.

Specified by:
getAllStrings in interface IStiGlobalizationProvider
Returns:
Returns array of the property names which can be localized.

getBorder

public final StiBorder getBorder()
Gets or sets frame of the component.

Specified by:
getBorder in interface IStiBorder

setBorder

public final void setBorder(StiBorder value)
Specified by:
setBorder in interface IStiBorder

getGlobalizedName

public final java.lang.String getGlobalizedName()
Description copied from class: StiSimpleText
Gets or sets special identificator which will be used for report globalization.

Specified by:
getGlobalizedName in interface IStiGlobalizedName
Overrides:
getGlobalizedName in class StiSimpleText

setGlobalizedName

public final void setGlobalizedName(java.lang.String value)
Specified by:
setGlobalizedName in interface IStiGlobalizedName
Overrides:
setGlobalizedName in class StiSimpleText

getLinesOfUnderline

public StiPenStyle getLinesOfUnderline()
Description copied from class: StiSimpleText
Gets or sets value indicates that it is necessary to lines of underline.

Specified by:
getLinesOfUnderline in interface IStiText
Overrides:
getLinesOfUnderline in class StiSimpleText

setLinesOfUnderline

public void setLinesOfUnderline(StiPenStyle value)
Specified by:
setLinesOfUnderline in interface IStiText
Overrides:
setLinesOfUnderline in class StiSimpleText

getHideZeros

public boolean getHideZeros()
Description copied from class: StiSimpleText
Gets or sets value indicates that no need show zeroes.

Specified by:
getHideZeros in interface IStiText
Overrides:
getHideZeros in class StiSimpleText

setHideZeros

public void setHideZeros(boolean value)
Specified by:
setHideZeros in interface IStiText
Overrides:
setHideZeros in class StiSimpleText

getProcessingDuplicates

public StiProcessingDuplicatesType getProcessingDuplicates()
Description copied from class: StiSimpleText
Gets or sets value which indicates how report engine processes duplicated values.

Specified by:
getProcessingDuplicates in interface IStiText
Overrides:
getProcessingDuplicates in class StiSimpleText

setProcessingDuplicates

public void setProcessingDuplicates(StiProcessingDuplicatesType value)
Specified by:
setProcessingDuplicates in interface IStiText
Overrides:
setProcessingDuplicates in class StiSimpleText

getMaxNumberOfLines

public int getMaxNumberOfLines()
Description copied from class: StiSimpleText
Gets or sets maximum number of lines which specify the limit of the height stretch.

Specified by:
getMaxNumberOfLines in interface IStiText
Overrides:
getMaxNumberOfLines in class StiSimpleText

setMaxNumberOfLines

public void setMaxNumberOfLines(int value)
Specified by:
setMaxNumberOfLines in interface IStiText
Overrides:
setMaxNumberOfLines in class StiSimpleText

getToolboxPosition

public int getToolboxPosition()
Gets value to sort a position in the toolbox.

Overrides:
getToolboxPosition in class StiComponent

getLocalizedName

public java.lang.String getLocalizedName()
Gets a localized component name.

Overrides:
getLocalizedName in class StiBase

getLocalizedCategory

public java.lang.String getLocalizedCategory()
Gets a localized name of the component category.

Overrides:
getLocalizedCategory in class StiBase

convertTextMargins

public final StiRectangle convertTextMargins(StiRectangle rect,
                                             boolean convert)

getImage

public final java.awt.Image getImage()

setImage

public final void setImage(java.awt.Image value)

getMargins

public StiMargins getMargins()
Gets or sets text margins.


setMargins

public void setMargins(StiMargins value)

getDefaultFont

public final java.awt.Font getDefaultFont()
Gets or sets default font.


setDefaultFont

public final void setDefaultFont(java.awt.Font value)

getDefaultColor

public final StiColor getDefaultColor()
Gets or sets default Color.


setDefaultColor

public final void setDefaultColor(StiColor value)

getWordWrap

public boolean getWordWrap()
Gets or sets word wrap.


setWordWrap

public void setWordWrap(boolean value)

getDetectUrls

public boolean getDetectUrls()
Gets or sets detection of urls.


setDetectUrls

public void setDetectUrls(boolean value)

getBackColor

public final StiColor getBackColor()
Gets or sets a back color.

Specified by:
getBackColor in interface IStiBackColor

setBackColor

public final void setBackColor(StiColor value)
Specified by:
setBackColor in interface IStiBackColor

getDataColumn

public final java.lang.String getDataColumn()
Gets or sets a name of the column that contains the RTF text.


setDataColumn

public final void setDataColumn(java.lang.String value)

getFullConvertExpression

public final boolean getFullConvertExpression()
Gets or sets value which indicates that it is necessary to fully convert the expression to Rtf format. Full convertion of expressions slows down the report rendering.


setFullConvertExpression

public final void setFullConvertExpression(boolean value)

getDataUrl

public StiDataUrlExpression getDataUrl()

setDataUrl

public void setDataUrl(StiDataUrlExpression value)

getWysiwyg

public final boolean getWysiwyg()
Gets or sets value which indicates that it is necessary to use the Wysiwyg mode of the rendering.


setWysiwyg

public final void setWysiwyg(boolean value)

setTextInternal

public void setTextInternal(java.lang.String value)
Internal use only.

Specified by:
setTextInternal in interface IStiText
Overrides:
setTextInternal in class StiSimpleText

SaveState

public java.lang.String SaveState()
Description copied from class: StiSimpleText
Saves state of editable value.

Specified by:
SaveState in interface IStiEditable
Overrides:
SaveState in class StiSimpleText

Break

public boolean Break(StiComponent dividedComponent,
                     double devideFactor,
                     StiRefObject<java.lang.Double> divideLine)
Description copied from interface: IStiBreakable
Divides content of components in two parts. Returns result of dividing. If true, then component is successful divided.

Specified by:
Break in interface IStiBreakable
Parameters:
dividedComponent - Component for store part of content.
Returns:
If true, then component is successful divided.

getActualSize

public StiSize getActualSize()
Description copied from class: StiComponent
Initializes a new instance of the StiSize class from the specified dimensi.

Overrides:
getActualSize in class StiComponent
Returns:
A class of the StiSize type which represents an actual size of the component.

InvokeGetValue

public void InvokeGetValue(StiComponent sender,
                           StiGetValueEventArgs e)
Overrides:
InvokeGetValue in class StiSimpleText

getRtfFromSource

public java.lang.String getRtfFromSource(java.lang.String dataUrlValue,
                                         java.lang.String dataColumn)

unpackRTF

public java.lang.String unpackRTF()
Unpack RFT (remove service symbols)

Parameters:
value -
Returns:

fixCyrillic

public java.lang.String fixCyrillic(java.lang.String buffer)

PackRtf

public static java.lang.String PackRtf(java.lang.String str)
Pack RTF text for save and compilation.

Parameters:
str -
Returns:

getDecodeText

public java.lang.String getDecodeText()

getRtfText

public java.lang.String getRtfText()

SaveToJsonObject

public JSONObject SaveToJsonObject(StiJsonSaveMode mode)
                            throws JSONException
Specified by:
SaveToJsonObject in interface IStiJsonReportObject
Overrides:
SaveToJsonObject in class StiSimpleText
Throws:
JSONException

LoadFromJsonObject

public void LoadFromJsonObject(JSONObject jObject)
                        throws JSONException
Specified by:
LoadFromJsonObject in interface IStiJsonReportObject
Overrides:
LoadFromJsonObject in class StiSimpleText
Throws:
JSONException