Class orion.editor.AnnotationStyler
				
				
			
				This object represents a styler for annotation attached to a text view.
				
				
					
Defined in:  </shared/eclipse/e4/orion/I201404012230/bundles/org.eclipse.orion.client.editor/web/orion/editor/annotations.js>.
				
			
| Constructor Attributes | Constructor Name and Description | 
|---|---|
| 
								orion.editor.AnnotationStyler(view, view)
							 Constructs a new styler for annotations. | 
| Method Attributes | Method Name and Description | 
|---|---|
| addAnnotationType(type)
								 Adds an annotation type to the receiver. | |
| destroy()
								 Destroys the styler. | |
| getAnnotationsByType(annotationModel, start, end)
								 Returns an array of annotations in the specified annotation model for the given range of text sorted by type. | |
| Gets the annotation type priority. | |
| isAnnotationTypeVisible(type)
								 Returns whether the receiver shows annotations of the specified type. | |
| removeAnnotationType(type)
								 Removes an annotation type from the receiver. | 
					Class Detail
				
				
				
						orion.editor.AnnotationStyler(view, view)
				
				
				
					Constructs a new styler for annotations.
					
				
				
				
				
				
					
						- Parameters:
- {orion.editor.TextView} view
- The styler view.
- {orion.editor.AnnotationModel} view
- The styler annotation model.
					Method Detail
				
				
					 
					
					
					
					addAnnotationType(type)
					
					
					
						Adds an annotation type to the receiver.
					
					
					
						
							Only annotations of the specified types will be shown by the receiver.
- Parameters:
- {Object} type
- the annotation type to be shown
- See:
- orion.editor.AnnotationTypeList#removeAnnotationType
- orion.editor.AnnotationTypeList#isAnnotationTypeVisible
					
					
					destroy()
					
					
					
						Destroys the styler. 
					
					
					
						
						
						
						
						
						
						
					Removes all listeners added by this styler.
					
					{orion.editor.Annotation[]}
					getAnnotationsByType(annotationModel, start, end)
					
					
					
						Returns an array of annotations in the specified annotation model for the given range of text sorted by type.
						
						
					
					
					
					
						
							- Parameters:
- {orion.editor.AnnotationModel} annotationModel
- the annotation model.
- {Number} start
- the start offset of the range.
- {Number} end
- the end offset of the range.
- Returns:
- {orion.editor.Annotation[]} an annotation array.
					
					
					getAnnotationTypePriority(type)
					
					
					
						Gets the annotation type priority.  The priority is determined by the
order the annotation type is added to the receiver.  Annotation types
added first have higher priority.
					
					
					
						
							
Returns 0 if the annotation type is not added.
- Parameters:
- {Object} type
- the annotation type
- See:
- orion.editor.AnnotationTypeList#addAnnotationType
- orion.editor.AnnotationTypeList#removeAnnotationType
- orion.editor.AnnotationTypeList#isAnnotationTypeVisible
					
					{Boolean}
					isAnnotationTypeVisible(type)
					
					
					
						Returns whether the receiver shows annotations of the specified type.
						
						
					
					
					
					
						
							- Parameters:
- {Object} type
- the annotation type
- Returns:
- {Boolean} whether the specified annotation type is shown
- See:
- orion.editor.AnnotationTypeList#addAnnotationType
- orion.editor.AnnotationTypeList#removeAnnotationType
					
					
					removeAnnotationType(type)
					
					
					
						Removes an annotation type from the receiver.
						
						
					
					
					
					
						
							- Parameters:
- {Object} type
- the annotation type to be removed
- See:
- orion.editor.AnnotationTypeList#addAnnotationType
- orion.editor.AnnotationTypeList#isAnnotationTypeVisible