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) 141AnnotationComponentChooser 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); 267_root.ClearValue(AnnotationService.ServiceProperty); 279public static AnnotationService GetService(DocumentViewerBase viewer) 283return viewer.GetValue(AnnotationService.ServiceProperty) as AnnotationService; 294public static AnnotationService GetService(FlowDocumentReader reader) 298return reader.GetValue(AnnotationService.ServiceProperty) as AnnotationService; 309public static AnnotationService GetService(FlowDocumentScrollViewer viewer) 313return viewer.GetValue(AnnotationService.ServiceProperty) as AnnotationService; 446public static readonly RoutedUICommand CreateHighlightCommand = new RoutedUICommand(SR.CreateHighlight, "CreateHighlight", typeof(AnnotationService), null); 451public static readonly RoutedUICommand CreateTextStickyNoteCommand = new RoutedUICommand(SR.CreateTextNote, "CreateTextStickyNote", typeof(AnnotationService), null); 456public static readonly RoutedUICommand CreateInkStickyNoteCommand = new RoutedUICommand(SR.CreateInkNote, "CreateInkStickyNote", typeof(AnnotationService), null); 461public static readonly RoutedUICommand ClearHighlightsCommand = new RoutedUICommand(SR.ClearHighlight, "ClearHighlights", typeof(AnnotationService), null); 466public static readonly RoutedUICommand DeleteStickyNotesCommand = new RoutedUICommand(SR.DeleteNotes, "DeleteStickyNotes", typeof(AnnotationService), null); 471public static readonly RoutedUICommand DeleteAnnotationsCommand = new RoutedUICommand(SR.DeleteAnnotations, "DeleteAnnotations", typeof(AnnotationService), null); 513internal static AnnotationService GetService(DependencyObject d) 517return d.GetValue(AnnotationService.ServiceProperty) as AnnotationService; 526internal static readonly DependencyProperty ChooserProperty = DependencyProperty.RegisterAttached("Chooser", typeof(AnnotationComponentChooser), typeof(AnnotationService), new FrameworkPropertyMetadata(new AnnotationComponentChooser(), FrameworkPropertyMetadataOptions.Inherits | FrameworkPropertyMetadataOptions.OverridesInheritanceBehavior)); 549internal static readonly DependencyProperty SubTreeProcessorIdProperty = LocatorManager.SubTreeProcessorIdProperty.AddOwner(typeof(AnnotationService)); 587internal static readonly DependencyProperty DataIdProperty = DataIdProcessor.DataIdProperty.AddOwner(typeof(AnnotationService)); 685internal static readonly DependencyProperty ServiceProperty = DependencyProperty.RegisterAttached("Service", typeof(AnnotationService), typeof(AnnotationService), new FrameworkPropertyMetadata(null, FrameworkPropertyMetadataOptions.Inherits | FrameworkPropertyMetadataOptions.OverridesInheritanceBehavior)); 1036if (AnnotationService.GetService(root) != null) 1120AnnotationService existingService = node.ReadLocalValue(AnnotationService.ServiceProperty) as AnnotationService; 1180List<IAttachedAnnotation> annotationsOnNode = node.GetValue(AnnotationService.AttachedAnnotationsProperty) as List<IAttachedAnnotation>; 1466List<IAttachedAnnotation> list = element.GetValue(AnnotationService.AttachedAnnotationsProperty) as List<IAttachedAnnotation>; 1471element.SetValue(AnnotationService.AttachedAnnotationsProperty, list); 1494List<IAttachedAnnotation> list = element.GetValue(AnnotationService.AttachedAnnotationsProperty) as List<IAttachedAnnotation>; 1503element.ClearValue(AnnotationService.AttachedAnnotationsProperty); 1713private static readonly DependencyProperty AttachedAnnotationsProperty = DependencyProperty.RegisterAttached("AttachedAnnotations", typeof(IList<IAttachedAnnotation>), typeof(AnnotationService));
System\Windows\Controls\FlowDocumentScrollViewer.cs (3)
76AnnotationService.SetDataId(this, "FlowDocument"); 946AnnotationService 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);