当前位置: 首页>>代码示例>>C#>>正文


C# TextEditor.DocumentLocationEventArgs类代码示例

本文整理汇总了C#中Mono.TextEditor.DocumentLocationEventArgs的典型用法代码示例。如果您正苦于以下问题:C# DocumentLocationEventArgs类的具体用法?C# DocumentLocationEventArgs怎么用?C# DocumentLocationEventArgs使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


DocumentLocationEventArgs类属于Mono.TextEditor命名空间,在下文中一共展示了DocumentLocationEventArgs类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: EditorCarethandlePositionChanged

		void EditorCarethandlePositionChanged (object sender, DocumentLocationEventArgs e)
		{
			if (!editor.GetTextEditorData ().HighlightCaretLine || e.Location.Line == editor.Caret.Line)
				return;
			editor.RedrawMarginLine (this, e.Location.Line);
			editor.RedrawMarginLine (this, editor.Caret.Line);
		}
开发者ID:pabloescribanoloza,项目名称:monodevelop,代码行数:7,代码来源:FoldMarkerMargin.cs

示例2: EditorCarethandlePositionChanged

		void EditorCarethandlePositionChanged (object sender, DocumentLocationEventArgs e)
		{
			if (e.Location.Line == editor.Caret.Line)
				return;
			editor.RedrawMarginLine (this, e.Location.Line);
			editor.RedrawMarginLine (this, editor.Caret.Line);
		}
开发者ID:IBBoard,项目名称:monodevelop,代码行数:7,代码来源:GutterMargin.cs

示例3: HandleTextEditorDataCaretPositionChanged

		void HandleTextEditorDataCaretPositionChanged(object sender, DocumentLocationEventArgs e)
		{
			if (!MonoDevelop.Core.PropertyService.Get<bool>("EnableHighlightUsages"))
				return;
			if (!textEditorData.IsSomethingSelected && markers.Values.Any(m => m.Contains(textEditorData.Caret.Offset)))
				return;
			RemoveMarkers();
			RemoveTimer();
			if (!textEditorData.IsSomethingSelected)
				popupTimer = GLib.Timeout.Add(1000, UpdateMarkers);
		}
开发者ID:rikkimax,项目名称:Mono-D,代码行数:11,代码来源:HighlightUsagesExtension.cs

示例4: HandleEditorCaretPositionChanged

		void HandleEditorCaretPositionChanged (object sender, DocumentLocationEventArgs e)
		{
			if (!IsInCodeFocusMode) 
				return;
			LineSegment lineSegment = editor.Document.GetLine (editor.Caret.Line);
			if (lineSegment == null) {
				RemoveBackgroundRenderer ();
				return;
			}
			
			IEnumerable<FoldSegment> newFoldings = editor.Document.GetFoldingContaining (lineSegment);
			if (newFoldings == null) {
				RemoveBackgroundRenderer ();
				return;
			}
			
			bool areEqual = foldings != null;
			
			if (areEqual && foldings.Count () != newFoldings.Count ())
				areEqual = false;
			if (areEqual) {
				List<FoldSegment> list1 = new List<FoldSegment> (foldings);
				List<FoldSegment> list2 = new List<FoldSegment> (newFoldings);
				for (int i = 0; i < list1.Count; i++) {
					if (list1[i] != list2[i]) {
						areEqual = false;
						break;
					}
				}
			}
			
			if (!areEqual) {
				foldings = newFoldings;
				DelayTimerElapsed (this, null);
			}
		}
开发者ID:transformersprimeabcxyz,项目名称:monodevelop-1,代码行数:36,代码来源:FoldMarkerMargin.cs

示例5: CaretPositionChanged

		void CaretPositionChanged (object o, DocumentLocationEventArgs args)
		{
			UpdateLineCol ();
			LineSegment curLine = TextEditor.Document.GetLine (TextEditor.Caret.Line);
			MonoDevelop.SourceEditor.MessageBubbleTextMarker marker = null;
			if (curLine != null && curLine.Markers.Any (m => m is MonoDevelop.SourceEditor.MessageBubbleTextMarker)) {
				marker = (MonoDevelop.SourceEditor.MessageBubbleTextMarker)curLine.Markers.First (m => m is MonoDevelop.SourceEditor.MessageBubbleTextMarker);
				marker.CollapseExtendedErrors = false;
				if (oldExpandedMarker == null)
					Document.CommitLineToEndUpdate (Document.OffsetToLineNumber (curLine.Offset));
			}
			
			if (oldExpandedMarker != null && oldExpandedMarker != marker) {
				oldExpandedMarker.CollapseExtendedErrors = true;
				int markerOffset = marker != null && marker.LineSegment != null ? marker.LineSegment.Offset : Int32.MaxValue;
				int oldMarkerOffset = oldExpandedMarker.LineSegment != null ? oldExpandedMarker.LineSegment.Offset : Int32.MaxValue;
				Document.CommitLineToEndUpdate (Document.OffsetToLineNumber (Math.Min (markerOffset, oldMarkerOffset)));
			}
			oldExpandedMarker = marker;
		}
开发者ID:silk,项目名称:monodevelop,代码行数:20,代码来源:SourceEditorWidget.cs

示例6: HandlePositionChanged

 void HandlePositionChanged(object sender, DocumentLocationEventArgs e)
 {
     QueueDraw ();
 }
开发者ID:csammis,项目名称:VimAddin,代码行数:4,代码来源:ViStatusArea.cs

示例7: HandleTextEditorDataCaretPositionChanged

		void HandleTextEditorDataCaretPositionChanged (object sender, DocumentLocationEventArgs e)
		{
			if (!textEditorData.IsSomethingSelected && markers.Values.Any (m => m.Contains (textEditorData.Caret.Offset)))
				return;
			RemoveMarkers (textEditorData.IsSomethingSelected);
			RemoveTimer ();
			if (!textEditorData.IsSomethingSelected)
				popupTimer = GLib.Timeout.Add (1000, DelayedTooltipShow);
		}
开发者ID:rohdef,项目名称:monodevelop,代码行数:9,代码来源:HighlightUsagesExtension.cs

示例8: HandleWidgetTextEditorCaretPositionChanged

		void HandleWidgetTextEditorCaretPositionChanged (object sender, DocumentLocationEventArgs e)
		{
			UpdateResultInformLabel ();
		}
开发者ID:RainsSoft,项目名称:playscript-monodevelop,代码行数:4,代码来源:SearchAndReplaceWidget.cs

示例9: HandlePositionChanged

		void HandlePositionChanged (object sender, DocumentLocationEventArgs e)
		{
			OnCaretPositionSet (EventArgs.Empty);
			FireCompletionContextChanged ();
			OnCaretPositionChanged (EventArgs.Empty);
		}
开发者ID:stephenoakman,项目名称:monodevelop,代码行数:6,代码来源:SourceEditorView.cs

示例10: CaretPositionChanged

		void CaretPositionChanged (object sender, DocumentLocationEventArgs args)
		{
			if (!caret.PreserveSelection)
				this.ClearSelection ();
			
			if (Options.RemoveTrailingWhitespaces && args.Location.Line != Caret.Line) {
				LineSegment line = Document.GetLine (args.Location.Line);
				if (line != null && line.WasChanged)
					Document.RemoveTrailingWhitespaces (this, line);
			}
		}
开发者ID:hduregger,项目名称:monodevelop,代码行数:11,代码来源:TextEditorData.cs

示例11: CaretPositionChanged

		void CaretPositionChanged (object sender, DocumentLocationEventArgs args)
		{
			if (!caret.PreserveSelection)
				this.ClearSelection ();
		}
开发者ID:dodev,项目名称:monodevelop,代码行数:5,代码来源:TextEditorData.cs

示例12: CaretPositionChanged

		internal static void CaretPositionChanged (object sender, DocumentLocationEventArgs e)
		{
			Caret caret = (Caret)sender;
			UpdateCaretPosition (caret);
		}
开发者ID:acken,项目名称:monodevelop,代码行数:5,代码来源:ComparisonWidget.cs

示例13: DataCaretPositionChanged

			public void DataCaretPositionChanged (object sender, DocumentLocationEventArgs e)
			{
				data.ExtendSelectionTo (data.Caret.Location);
			}
开发者ID:yayanyang,项目名称:monodevelop,代码行数:4,代码来源:SelectionActions.cs

示例14: HandlePositionChanged

		void HandlePositionChanged (object sender, DocumentLocationEventArgs e)
		{
			var node = unit.GetNodeAt (editor.Caret.Line, editor.Caret.Column);
			if (node == null)
				return;
			TreeIter iter;
			if (!iterDict.TryGetValue (node, out iter))
				return;
			this.treeviewNodes.Selection.Changed -= SelectionChanged;
			treeviewNodes.Selection.SelectIter (iter);
			
			treeviewNodes.ScrollToCell (store.GetPath (iter), null, true, 0, 0);
			this.treeviewNodes.Selection.Changed += SelectionChanged;
		}
开发者ID:Netring,项目名称:ILSpy,代码行数:14,代码来源:MainWindow.cs

示例15: CaretPositionChanged

		void CaretPositionChanged (object o, DocumentLocationEventArgs args)
		{
			UpdateLineCol ();
			DocumentLine curLine = TextEditor.Document.GetLine (TextEditor.Caret.Line);
			MonoDevelop.SourceEditor.MessageBubbleTextMarker marker = null;
			if (curLine != null && curLine.Markers.Any (m => m is MonoDevelop.SourceEditor.MessageBubbleTextMarker)) {
				marker = (MonoDevelop.SourceEditor.MessageBubbleTextMarker)curLine.Markers.First (m => m is MonoDevelop.SourceEditor.MessageBubbleTextMarker);
//				marker.CollapseExtendedErrors = false;
			}
			
			if (oldExpandedMarker != null && oldExpandedMarker != marker) {
//				oldExpandedMarker.CollapseExtendedErrors = true;
			}
			oldExpandedMarker = marker;
		}
开发者ID:telebovich,项目名称:monodevelop,代码行数:15,代码来源:SourceEditorWidget.cs


注:本文中的Mono.TextEditor.DocumentLocationEventArgs类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。