|
|
|
@ -41,7 +41,7 @@ namespace ICSharpCode.SharpDevelop.Gui |
|
|
|
this.console = new ConsoleControl(); |
|
|
|
this.console = new ConsoleControl(); |
|
|
|
|
|
|
|
|
|
|
|
// creating the toolbar accesses the WordWrap property, so we must do this after creating the console
|
|
|
|
// creating the toolbar accesses the WordWrap property, so we must do this after creating the console
|
|
|
|
this.toolbar = ToolBarService.CreateToolBar(this, toolBarTreePath); |
|
|
|
this.toolbar = BuildToolBar(); |
|
|
|
this.toolbar.SetValue(DockPanel.DockProperty, Dock.Top); |
|
|
|
this.toolbar.SetValue(DockPanel.DockProperty, Dock.Top); |
|
|
|
|
|
|
|
|
|
|
|
this.panel.Children.Add(toolbar); |
|
|
|
this.panel.Children.Add(toolbar); |
|
|
|
@ -56,6 +56,11 @@ namespace ICSharpCode.SharpDevelop.Gui |
|
|
|
this.InitializeConsole(); |
|
|
|
this.InitializeConsole(); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
protected virtual ToolBar BuildToolBar() |
|
|
|
|
|
|
|
{ |
|
|
|
|
|
|
|
return ToolBarService.CreateToolBar(this, toolBarTreePath); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
public virtual ITextEditor TextEditor { |
|
|
|
public virtual ITextEditor TextEditor { |
|
|
|
get { |
|
|
|
get { |
|
|
|
return console.TextEditor; |
|
|
|
return console.TextEditor; |
|
|
|
@ -310,6 +315,9 @@ namespace ICSharpCode.SharpDevelop.Gui |
|
|
|
|
|
|
|
|
|
|
|
public IEnumerable<ISegment> GetDeletableSegments(ISegment segment) |
|
|
|
public IEnumerable<ISegment> GetDeletableSegments(ISegment segment) |
|
|
|
{ |
|
|
|
{ |
|
|
|
|
|
|
|
if (segment.EndOffset < this.EndOffset) |
|
|
|
|
|
|
|
return Enumerable.Empty<ISegment>(); |
|
|
|
|
|
|
|
|
|
|
|
return new[] { |
|
|
|
return new[] { |
|
|
|
new TextSegment() { |
|
|
|
new TextSegment() { |
|
|
|
StartOffset = Math.Max(this.EndOffset, segment.Offset), |
|
|
|
StartOffset = Math.Max(this.EndOffset, segment.Offset), |
|
|
|
|