Java Doc for TextPresentation.java in  » IDE-Eclipse » jface » org » eclipse » jface » text » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » IDE Eclipse » jface » org.eclipse.jface.text 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   org.eclipse.jface.text.TextPresentation

TextPresentation
public class TextPresentation (Code)
Describes the presentation styles for a section of an indexed text such as a document or string. A text presentation defines a default style for the whole section and in addition style differences for individual subsections. Text presentations can be narrowed down to a particular result window. All methods are result window aware, i.e. ranges outside the result window are always ignored.

All iterators provided by a text presentation assume that they enumerate non overlapping, consecutive ranges inside the default range. Thus, all these iterators do not include the default range. The default style range must be explicitly asked for using getDefaultStyleRange.


Inner Class :class FilterIterator implements Iterator


Constructor Summary
public  TextPresentation()
     Creates a new empty text presentation.
public  TextPresentation(int sizeHint)
     Creates a new empty text presentation.
public  TextPresentation(IRegion extent, int sizeHint)
     Creates a new empty text presentation with the given extent.

Method Summary
public  voidaddStyleRange(StyleRange range)
     Add the given range to the presentation.
public static  voidapplyTextPresentation(TextPresentation presentation, StyledText text)
     Applies the given presentation to the given text widget.
public  voidclear()
     Clears this presentation by resetting all applied changes.
public  IteratorgetAllStyleRangeIterator()
     Returns an iterator which enumerates all style ranges of this presentation except the default style range.
public  IRegiongetCoverage()
     Returns the coverage of this presentation as clipped by the presentation's result window.
public  StyleRangegetDefaultStyleRange()
     Returns this presentation's default style range.
public  intgetDenumerableRanges()
     Returns the number of style ranges in the presentation not counting the default style range.
public  IRegiongetExtent()
     Returns the extent of this presentation clipped by the presentation's result window.
public  StyleRangegetFirstStyleRange()
     Returns the style range with the smallest offset ignoring the default style range or null if the presentation is empty.
public  StyleRangegetLastStyleRange()
     Returns the style range with the highest offset ignoring the default style range.
public  IteratorgetNonDefaultStyleRangeIterator()
     Returns an iterator which enumerates all style ranged which define a style different from the presentation's default style range.
public  booleanisEmpty()
     Returns whether this collection contains any style range including the default style range.
public  voidmergeStyleRange(StyleRange range)
     Merges the given range into this presentation.
public  voidmergeStyleRanges(StyleRange[] ranges)
     Merges the given ranges into this presentation.
public  voidreplaceStyleRange(StyleRange range)
     Replaces the given range in this presentation.
public  voidreplaceStyleRanges(StyleRange[] ranges)
     Replaces the given ranges in this presentation.
public  voidsetDefaultStyleRange(StyleRange range)
     Set the default style range of this presentation.
public  voidsetResultWindow(IRegion resultWindow)
     Sets the result window for this presentation.


Constructor Detail
TextPresentation
public TextPresentation()(Code)
Creates a new empty text presentation.



TextPresentation
public TextPresentation(int sizeHint)(Code)
Creates a new empty text presentation. sizeHint tells the expected size of this presentation.
Parameters:
  sizeHint - the expected size of this presentation



TextPresentation
public TextPresentation(IRegion extent, int sizeHint)(Code)
Creates a new empty text presentation with the given extent. sizeHint tells the expected size of this presentation.
Parameters:
  extent - the extent of the created TextPresentation
Parameters:
  sizeHint - the expected size of this presentation
since:
   3.0




Method Detail
addStyleRange
public void addStyleRange(StyleRange range)(Code)
Add the given range to the presentation. The range must be a subrange of the presentation's default range.
Parameters:
  range - the range to be added



applyTextPresentation
public static void applyTextPresentation(TextPresentation presentation, StyledText text)(Code)
Applies the given presentation to the given text widget. Helper method.
Parameters:
  presentation - the style information
Parameters:
  text - the widget to which to apply the style information
since:
   2.0



clear
public void clear()(Code)
Clears this presentation by resetting all applied changes.
since:
   2.0



getAllStyleRangeIterator
public Iterator getAllStyleRangeIterator()(Code)
Returns an iterator which enumerates all style ranges of this presentation except the default style range. The returned StyleRanges are relative to the start of the presentation's result window. a style range iterator



getCoverage
public IRegion getCoverage()(Code)
Returns the coverage of this presentation as clipped by the presentation's result window. the coverage of this presentation



getDefaultStyleRange
public StyleRange getDefaultStyleRange()(Code)
Returns this presentation's default style range. The returned StyleRange is relative to the start of the result window. this presentation's default style range



getDenumerableRanges
public int getDenumerableRanges()(Code)
Returns the number of style ranges in the presentation not counting the default style range. the number of style ranges in the presentation excluding the default style range



getExtent
public IRegion getExtent()(Code)
Returns the extent of this presentation clipped by the presentation's result window. the clipped extent
since:
   3.0



getFirstStyleRange
public StyleRange getFirstStyleRange()(Code)
Returns the style range with the smallest offset ignoring the default style range or null if the presentation is empty. the style range with the smallest offset different from the default style range



getLastStyleRange
public StyleRange getLastStyleRange()(Code)
Returns the style range with the highest offset ignoring the default style range. the style range with the highest offset different from the default style range



getNonDefaultStyleRangeIterator
public Iterator getNonDefaultStyleRangeIterator()(Code)
Returns an iterator which enumerates all style ranged which define a style different from the presentation's default style range. The default style range is not enumerated. a style range iterator



isEmpty
public boolean isEmpty()(Code)
Returns whether this collection contains any style range including the default style range. true if there is no style range in this presentation



mergeStyleRange
public void mergeStyleRange(StyleRange range)(Code)
Merges the given range into this presentation. The range must be a subrange of the presentation's default range.
Parameters:
  range - the range to be added
since:
   3.0



mergeStyleRanges
public void mergeStyleRanges(StyleRange[] ranges)(Code)
Merges the given ranges into this presentation. Each range must be a subrange of the presentation's default range. The ranges must be ordered by increasing offset and must not overlap (but may be adjacent).
Parameters:
  ranges - the ranges to be added
since:
   3.0



replaceStyleRange
public void replaceStyleRange(StyleRange range)(Code)
Replaces the given range in this presentation. The range must be a subrange of the presentation's default range.
Parameters:
  range - the range to be added
since:
   3.0



replaceStyleRanges
public void replaceStyleRanges(StyleRange[] ranges)(Code)
Replaces the given ranges in this presentation. Each range must be a subrange of the presentation's default range. The ranges must be ordered by increasing offset and must not overlap (but may be adjacent).
Parameters:
  ranges - the ranges to be added
since:
   3.0



setDefaultStyleRange
public void setDefaultStyleRange(StyleRange range)(Code)
Set the default style range of this presentation. The default style range defines the overall area covered by this presentation and its style information.
Parameters:
  range - the range describing the default region



setResultWindow
public void setResultWindow(IRegion resultWindow)(Code)
Sets the result window for this presentation. When dealing with this presentation all ranges which are outside the result window are ignored. For example, the size of the presentation is 0 when there is no range inside the window even if there are ranges outside the window. All methods are aware of the result window.
Parameters:
  resultWindow - the result window



Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.