Language

The Free and Open Productivity Suite
Released: Apache OpenOffice 4.1.15

API

SDK

Tips ‘n’ Tricks

Miscellaneous


:: com :: sun :: star :: text ::

service TextPortion
Description
A TextPortion is a piece of text within a paragraph that does not contain changes of its attributes inside.

It is created by an enumeration implemented in a paragraph service. It may be used to export the content of the paragraph to an external document format.

See also
TextPortionEnumeration, com::sun::star::text::XTextPortionEnumeration
Developers Guide
Text - Iterating over Text
Text - Formatting

Included Services - Summary
TextRange
(referenced entity's summary:)
points to a sequence of characters within a Text.
Exported Interfaces - Summary
::com::sun::star::container::XContentEnumerationAccess

contains text frames, graphic objects, embedded objects or shapes that are anchored at or as character. (details)

::com::sun::star::beans::XTolerantMultiPropertySet

gives access to a sequence of properties. (details)

Properties' Summary
[ readonly ] string
TextPortionType
contains the type of the text portion.  
[ readonly ] short
ControlCharacter
[ DEPRECATED ]
contains the control character of a text portion of type ControlCharacter.  
[ readonly ] XTextContent
Bookmark
[ OPTIONAL ]
contains the bookmark of a text portion of type Bookmark.  
[ readonly ] XTextContent
DocumentIndexMark
[ OPTIONAL ]
contains the document index mark of a text portion of type DocumentIndexMark.  
[ readonly ] XTextContent
ReferenceMark
[ OPTIONAL ]
contains the bookmark of a text portion of type ReferenceMark.  
[ readonly ] XFootnote
Footnote
[ OPTIONAL ]
contains the footnote of a text portion of type Footnote.  
[ readonly ] XTextField
TextField
[ OPTIONAL ]
contains the text field of a text portion of type TextField.  
[ readonly ] XTextContent
InContentMetadata
[ OPTIONAL ]
contains the text range of a text portion of type InContentMetadata.  
[ readonly ] boolean
IsCollapsed
[ OPTIONAL ]
contains whether the portion is a point only.  
[ readonly ] boolean
IsStart
[ OPTIONAL ]
contains whether the portion is the start of the portion.  
Included Services - Details
TextRange
(referenced entity's summary:)
points to a sequence of characters within a Text.
Exported Interfaces - Details
::com::sun::star::container::XContentEnumerationAccess
Usage Restrictions
optional
Description
contains text frames, graphic objects, embedded objects or shapes that are anchored at or as character.
See also
com.sun.star.text.TextFrame, com.sun.star.text.TextGraphicObject
::com::sun::star::beans::XTolerantMultiPropertySet
Usage Restrictions
optional
Description
gives access to a sequence of properties.
Since
OOo 2.0
Properties' Details
TextPortionType
[ readonly ] string TextPortionType;
Description
contains the type of the text portion.

Valid content type names are:

Text
string content
TextField
a text field
TextContent
text content - supplied via the interface ::com::sun::star::container::XContentEnumerationAccess
ControlCharacter
a control character
Footnote
a footnote or an endnote
ReferenceMark
a reference mark
DocumentIndexMark
a document index mark
Bookmark
a bookmark
Redline
a redline portion which is a result of the change tracking feature
Ruby
a ruby attribute which is used in Asian text
Frame
a frame
SoftPageBreak
a soft page break
InContentMetadata
a text range with attached metadata

For Reference marks, document index marks, etc., 2 text portions will be generated, one for the start position and one for the end position.

ControlCharacter
[ readonly ] short ControlCharacter;
Usage Restrictions
deprecated
Deprecation Info
type ControlCharacter no longer implemented
Description
contains the control character of a text portion of type ControlCharacter.
Bookmark
[ readonly ] XTextContent Bookmark;
Usage Restrictions
optional
Description
contains the bookmark of a text portion of type Bookmark.
DocumentIndexMark
[ readonly ] XTextContent DocumentIndexMark;
Usage Restrictions
optional
Description
contains the document index mark of a text portion of type DocumentIndexMark.
ReferenceMark
[ readonly ] XTextContent ReferenceMark;
Usage Restrictions
optional
Description
contains the bookmark of a text portion of type ReferenceMark.
Footnote
[ readonly ] XFootnote Footnote;
Usage Restrictions
optional
Description
contains the footnote of a text portion of type Footnote.
TextField
[ readonly ] XTextField TextField;
Usage Restrictions
optional
Description
contains the text field of a text portion of type TextField.
InContentMetadata
[ readonly ] XTextContent InContentMetadata;
Usage Restrictions
optional
Description
contains the text range of a text portion of type InContentMetadata.
Since
OOo 3.2
IsCollapsed
[ readonly ] boolean IsCollapsed;
Usage Restrictions
optional
Description
contains whether the portion is a point only.
IsStart
[ readonly ] boolean IsStart;
Usage Restrictions
optional
Description
contains whether the portion is the start of the portion.

This is used for portions which are represented by 2 TextPortion objects (e.g., DocmentIndexMark).


 
Top of Page

Apache Software Foundation

Copyright & License | Privacy | Contact Us | Donate | Thanks

Apache, OpenOffice, OpenOffice.org and the seagull logo are registered trademarks of The Apache Software Foundation. The Apache feather logo is a trademark of The Apache Software Foundation. Other names appearing on the site may be trademarks of their respective owners.