95 references to AnnotationService
PresentationFramework (95)
MS\Internal\Annotations\Anchoring\AttachedAnnotation.cs (2)
279AnnotationService service = AnnotationService.GetService(this.Parent);
MS\Internal\Annotations\Anchoring\DataIdProcessor.cs (4)
117AnnotationService service = AnnotationService.GetService(node); 359AnnotationService service = AnnotationService.GetService(d);
MS\Internal\Annotations\Anchoring\LocatorManager.cs (4)
274AnnotationService service = AnnotationService.GetService(node); 924AnnotationService svc = AnnotationService.GetService(startNode);
MS\Internal\Annotations\Anchoring\PathNode.cs (1)
278if (node.ReadLocalValue(AnnotationService.ServiceProperty) != DependencyProperty.UnsetValue)
MS\Internal\Annotations\Component\AnnotationComponentManager.cs (2)
30internal AnnotationComponentManager(AnnotationService service) 144AnnotationComponentChooser chooser = AnnotationService.GetChooser(annotatedElement);
MS\Internal\Controls\StickyNote\StickyNoteAnnotations.cs (2)
107AnnotationService service = null; 111service = AnnotationService.GetService(((IAnnotationComponent)snc).AnnotatedElement);
System\Windows\Annotations\AnnotationDocumentPaginator.cs (2)
320AnnotationService.SetSubTreeProcessorId(decorator, FixedPageProcessor.Id); 327AnnotationService.SetDataId(decorator, "FlowDocument");
System\Windows\Annotations\AnnotationHelper.cs (29)
43public static Annotation CreateHighlightForSelection(AnnotationService service, string author, Brush highlightBrush) 73public static Annotation CreateTextStickyNoteForSelection(AnnotationService service, string author) 89public static Annotation CreateInkStickyNoteForSelection(AnnotationService service, string author) 104public static void ClearHighlightsForSelection(AnnotationService service) 127public static void DeleteTextStickyNotesForSelection(AnnotationService service) 150public static void DeleteInkStickyNotesForSelection(AnnotationService service) 172public static IAnchorInfo GetAnchorInfo(AnnotationService service, Annotation annotation) 283CreateHighlightForSelection(AnnotationService.GetService(viewer), null, e.Parameter != null ? e.Parameter as Brush : null); 297CreateTextStickyNoteForSelection(AnnotationService.GetService(viewer), e.Parameter as String); 311CreateInkStickyNoteForSelection(AnnotationService.GetService(viewer), e.Parameter as String); 326ClearHighlightsForSelection(AnnotationService.GetService(viewer)); 341DeleteTextStickyNotesForSelection(AnnotationService.GetService(viewer)); 342DeleteInkStickyNotesForSelection(AnnotationService.GetService(viewer)); 361AnnotationService service = AnnotationService.GetService(viewer); 485private static Annotation CreateStickyNoteForSelection(AnnotationService service, XmlQualifiedName noteType, string author) 558private static IList<IAttachedAnnotation> GetSpannedAnnotations(AnnotationService service) 665private static IList<IAttachedAnnotation> GetSpannedAnnotationsForFlow(AnnotationService service, ITextSelection selection) 715private static IList<IAttachedAnnotation> GetSpannedAnnotationsForFixed(AnnotationService service, int startPage, int endPage) 773private static List<IAttachedAnnotation> ResolveAnnotations(AnnotationService service, IList<Annotation> annotations) 800private static void DeleteSpannedAnnotations(AnnotationService service, XmlQualifiedName annotationType) 878private static Annotation CreateAnnotationForSelection(AnnotationService service, ITextRange textSelection, XmlQualifiedName annotationType, string author) 909private static Annotation Highlight(AnnotationService service, string author, Brush highlightBrush, bool create) 962private static Annotation ProcessHighlights(AnnotationService service, ITextRange textRange, string author, Nullable<Color> color, bool create) 1014private static Annotation CreateHighlight(AnnotationService service, ITextRange textRange, string author, Nullable<Color> color) 1051private static void SetAnchor(AnnotationService service, Annotation annot, object selection) 1078private static void CheckInputs(AnnotationService service) 1122AnnotationService service = AnnotationService.GetService(viewer);
System\Windows\Annotations\AnnotationService.cs (35)
177_root.SetValue(AnnotationService.ServiceProperty, this); 273_root.ClearValue(AnnotationService.ServiceProperty); 285public static AnnotationService GetService(DocumentViewerBase viewer) 289return viewer.GetValue(AnnotationService.ServiceProperty) as AnnotationService; 300public static AnnotationService GetService(FlowDocumentReader reader) 304return reader.GetValue(AnnotationService.ServiceProperty) as AnnotationService; 315public static AnnotationService GetService(FlowDocumentScrollViewer viewer) 319return viewer.GetValue(AnnotationService.ServiceProperty) as AnnotationService; 452public static readonly RoutedUICommand CreateHighlightCommand = new RoutedUICommand(SR.CreateHighlight, "CreateHighlight", typeof(AnnotationService), null); 457public static readonly RoutedUICommand CreateTextStickyNoteCommand = new RoutedUICommand(SR.CreateTextNote, "CreateTextStickyNote", typeof(AnnotationService), null); 462public static readonly RoutedUICommand CreateInkStickyNoteCommand = new RoutedUICommand(SR.CreateInkNote, "CreateInkStickyNote", typeof(AnnotationService), null); 467public static readonly RoutedUICommand ClearHighlightsCommand = new RoutedUICommand(SR.ClearHighlight, "ClearHighlights", typeof(AnnotationService), null); 472public static readonly RoutedUICommand DeleteStickyNotesCommand = new RoutedUICommand(SR.DeleteNotes, "DeleteStickyNotes", typeof(AnnotationService), null); 477public static readonly RoutedUICommand DeleteAnnotationsCommand = new RoutedUICommand(SR.DeleteAnnotations, "DeleteAnnotations", typeof(AnnotationService), null); 519internal static AnnotationService GetService(DependencyObject d) 523return d.GetValue(AnnotationService.ServiceProperty) as AnnotationService; 532internal static readonly DependencyProperty ChooserProperty = DependencyProperty.RegisterAttached("Chooser", typeof(AnnotationComponentChooser), typeof(AnnotationService), new FrameworkPropertyMetadata(new AnnotationComponentChooser(), FrameworkPropertyMetadataOptions.Inherits | FrameworkPropertyMetadataOptions.OverridesInheritanceBehavior)); 555internal static readonly DependencyProperty SubTreeProcessorIdProperty = LocatorManager.SubTreeProcessorIdProperty.AddOwner(typeof(AnnotationService)); 593internal static readonly DependencyProperty DataIdProperty = DataIdProcessor.DataIdProperty.AddOwner(typeof(AnnotationService)); 691internal static readonly DependencyProperty ServiceProperty = DependencyProperty.RegisterAttached("Service", typeof(AnnotationService), typeof(AnnotationService), new FrameworkPropertyMetadata(null, FrameworkPropertyMetadataOptions.Inherits | FrameworkPropertyMetadataOptions.OverridesInheritanceBehavior)); 1049if (AnnotationService.GetService(root) != null) 1133AnnotationService existingService = node.ReadLocalValue(AnnotationService.ServiceProperty) as AnnotationService; 1193List<IAttachedAnnotation> annotationsOnNode = node.GetValue(AnnotationService.AttachedAnnotationsProperty) as List<IAttachedAnnotation>; 1479List<IAttachedAnnotation> list = element.GetValue(AnnotationService.AttachedAnnotationsProperty) as List<IAttachedAnnotation>; 1484element.SetValue(AnnotationService.AttachedAnnotationsProperty, list); 1507List<IAttachedAnnotation> list = element.GetValue(AnnotationService.AttachedAnnotationsProperty) as List<IAttachedAnnotation>; 1516element.ClearValue(AnnotationService.AttachedAnnotationsProperty); 1727private static readonly DependencyProperty AttachedAnnotationsProperty = DependencyProperty.RegisterAttached("AttachedAnnotations", typeof(IList<IAttachedAnnotation>), typeof(AnnotationService));
System\Windows\Controls\FlowDocumentScrollViewer.cs (3)
76AnnotationService.SetDataId(this, "FlowDocument"); 952AnnotationService service = AnnotationService.GetService(this);
System\Windows\Controls\Primitives\DocumentViewerBase.cs (11)
989AnnotationService service = AnnotationService.GetService(this); 1351this.ClearValue(AnnotationService.DataIdProperty); 1353AnnotationService.SetSubTreeProcessorId(this, FixedPageProcessor.Id); 1357AnnotationService service = AnnotationService.GetService(this); 1370AnnotationService service = AnnotationService.GetService(this); 1378AnnotationService.SetDataId(this, "FlowDocument"); 1383this.ClearValue(AnnotationService.SubTreeProcessorIdProperty); 1384this.ClearValue(AnnotationService.DataIdProperty);