You should have received a copy of the GNU General Public License along with this program. If not, see <http://www.gnu.org/licenses/>.\r
*/\r
using System;\r
+using System.Text;\r
+using System.Threading.Tasks;\r
using System.Runtime.InteropServices;\r
using System.Windows;\r
using System.Windows.Input;\r
DispatcherTimer timer;\r
bool disposed = false;\r
FooTextBoxAutomationPeer peer;\r
+ bool nowCaretMove = false;\r
\r
static FooTextBox()\r
{\r
this.textStore = new TextStore();\r
this.textStore.IsLoading += textStore_IsLoading;\r
this.textStore.IsReadOnly += textStore_IsReadOnly;\r
+ this.textStore.GetDpi += textStore_GetDpi;\r
this.textStore.GetStringLength += () => this.Document.Length;\r
this.textStore.GetString += _textStore_GetString;\r
this.textStore.GetSelectionIndex += _textStore_GetSelectionIndex;\r
this.textStore.CompositionUpdated += textStore_CompositionUpdated;\r
this.textStore.CompositionEnded += textStore_CompositionEnded;\r
\r
- this.Document = new Document();\r
- DocumentExtend.Progress += new EventHandler<ProgressEventArgs>(Document_Progress);\r
-\r
this.Render = new D2DRender(this, 200, 200,this.image);\r
this.Render.ShowFullSpace = this.ShowFullSpace;\r
this.Render.ShowHalfSpace = this.ShowHalfSpace;\r
this.Render.ShowTab = this.ShowTab;\r
\r
- this.View = new EditView(this.Document, this.Render,new Margin(5,5,5,5));\r
+ this.Document = new Document();\r
+ this.Document.LayoutLines.Render = this.Render;\r
+\r
+ this.View = new EditView(this.Document, this.Render, new Padding(5, 5, 5, 5));\r
this.View.SrcChanged += View_SrcChanged;\r
this.View.InsertMode = this.InsertMode;\r
this.View.DrawLineNumber = this.DrawLineNumber;\r
this.View.TabStops = this.TabChars;\r
\r
this._Controller = new Controller(this.Document, this.View);\r
- this._Controller.CaretMoved += new EventHandler(Controller_CaretMoved);\r
+ this._Controller.SelectionChanged += new EventHandler(Controller_SelectionChanged);\r
\r
//Viewを作成した後に追加しないと例外が発生する\r
this.Document.Update += new DocumentUpdateEventHandler(Document_Update);\r
/// <param name="length">長さ</param>\r
public void Select(int start, int length)\r
{\r
- if (this.Document.State == AsyncState.Loading)\r
- throw new InvalidOperationException();\r
this._Controller.Select(start, length);\r
this.textStore.NotifySelectionChanged();\r
}\r
/// <remarks>このメソッドを呼び出すと選択状態は解除されます</remarks>\r
public void JumpCaret(int index)\r
{\r
- if (this.Document.State == AsyncState.Loading)\r
- throw new InvalidOperationException();\r
this._Controller.JumpCaret(index);\r
}\r
/// <summary>\r
/// <remarks>このメソッドを呼び出すと選択状態は解除されます</remarks>\r
public void JumpCaret(int row, int col)\r
{\r
- if (this.Document.State == AsyncState.Loading)\r
- throw new InvalidOperationException();\r
this._Controller.JumpCaret(row, col);\r
}\r
\r
/// </summary>\r
public void Copy()\r
{\r
- if (this.Document.State == AsyncState.Loading)\r
- throw new InvalidOperationException();\r
string text = this._Controller.SelectedText;\r
if (text != null && text != string.Empty)\r
Clipboard.SetText(text);\r
/// </summary>\r
public void Cut()\r
{\r
- if (this.Document.State == AsyncState.Loading)\r
- throw new InvalidOperationException();\r
string text = this._Controller.SelectedText;\r
if (text != null && text != string.Empty)\r
{\r
/// </summary>\r
public void Paste()\r
{\r
- if (this.Document.State == AsyncState.Loading)\r
- throw new InvalidOperationException();\r
if (Clipboard.ContainsText() == false)\r
return;\r
string text = Clipboard.GetText();\r
/// </summary>\r
public void DeSelectAll()\r
{\r
- if (this.Document.State == AsyncState.Loading)\r
- throw new InvalidOperationException();\r
this._Controller.DeSelectAll();\r
this.textStore.NotifySelectionChanged();\r
}\r
/// <remarks>テキストポイントがクライアント領域の原点より外にある場合、返される値は原点に丸められます</remarks>\r
public System.Windows.Point GetPostionFromTextPoint(TextPoint tp)\r
{\r
- if (this.Document.State == AsyncState.Loading)\r
- throw new InvalidOperationException();\r
if (this.Document.FireUpdateEvent == false)\r
throw new InvalidOperationException("");\r
return this.View.GetPostionFromTextPoint(tp);\r
/// <returns>テキストポイント</returns>\r
public TextPoint GetTextPointFromPostion(System.Windows.Point p)\r
{\r
- if (this.Document.State == AsyncState.Loading)\r
- throw new InvalidOperationException();\r
if (this.Document.FireUpdateEvent == false)\r
throw new InvalidOperationException("");\r
return this.View.GetTextPointFromPostion(p);\r
/// <returns>行の高さ</returns>\r
public double GetLineHeight(int row)\r
{\r
- if (this.Document.State == AsyncState.Loading)\r
- throw new InvalidOperationException();\r
if (this.Document.FireUpdateEvent == false)\r
throw new InvalidOperationException("");\r
return this.View.LayoutLines.GetLayout(row).Height;;\r
/// <returns>座標を返す</returns>\r
public System.Windows.Point GetPostionFromIndex(int index)\r
{\r
- if (this.Document.State == AsyncState.Loading)\r
- throw new InvalidOperationException();\r
if (this.Document.FireUpdateEvent == false)\r
throw new InvalidOperationException("");\r
TextPoint tp = this.View.GetLayoutLineFromIndex(index);\r
/// <returns>インデックスを返す</returns>\r
public int GetIndexFromPostion(System.Windows.Point p)\r
{\r
- if (this.Document.State == AsyncState.Loading)\r
- throw new InvalidOperationException();\r
if (this.Document.FireUpdateEvent == false)\r
throw new InvalidOperationException("");\r
TextPoint tp = this.View.GetTextPointFromPostion(p);\r
}\r
\r
/// <summary>\r
+ /// ストリームからドキュメントを構築する\r
+ /// </summary>\r
+ /// <param name="tr">TextReader</param>\r
+ /// <param name="token">キャンセル用トークン</param>\r
+ /// <returns>Taskオブジェクト</returns>\r
+ public async Task LoadAsync(System.IO.TextReader tr, System.Threading.CancellationTokenSource token)\r
+ {\r
+ WinFileReader fs = new WinFileReader(tr);\r
+ await this.LoadAsyncImpl(fs, token);\r
+ }\r
+\r
+ /// <summary>\r
+ /// ファイルからドキュメントを構築する\r
+ /// </summary>\r
+ /// <param name="filepath">ファイルパス</param>\r
+ /// <param name="enc">エンコード</param>\r
+ /// <param name="token">キャンセル用トークン</param>\r
+ /// <returns>Taskオブジェクト</returns>\r
+ public async Task LoadFileAsync(string filepath, Encoding enc,System.Threading.CancellationTokenSource token)\r
+ {\r
+ WinFileReader fs = new WinFileReader(filepath, enc);\r
+ await this.LoadAsyncImpl(fs, token);\r
+ fs.Close();\r
+ }\r
+\r
+ async Task LoadAsyncImpl(WinFileReader fs,System.Threading.CancellationTokenSource token)\r
+ {\r
+ this.IsEnabled = false;\r
+ this.View.LayoutLines.IsFrozneDirtyFlag = true;\r
+ await this.Document.LoadAsync(fs, token);\r
+ this.View.LayoutLines.IsFrozneDirtyFlag = false;\r
+ TextStoreHelper.NotifyTextChanged(this.textStore, 0, 0, this.Document.Length);\r
+ if (this.verticalScrollBar != null)\r
+ this.verticalScrollBar.Maximum = this.View.LayoutLines.Count;\r
+ this.View.CalculateLineCountOnScreen();\r
+ this.IsEnabled = true;\r
+ }\r
+\r
+ /// <summary>\r
+ /// ドキュメントの内容をファイルに保存する\r
+ /// </summary>\r
+ /// <param name="filepath">ファイルパス</param>\r
+ /// <param name="newLine">改行コード</param>\r
+ /// <param name="enc">エンコード</param>\r
+ /// <returns>Taskオブジェクト</returns>\r
+ public async Task SaveFile(string filepath, Encoding enc,string newLine, System.Threading.CancellationTokenSource token)\r
+ {\r
+ WinFileWriter fs = new WinFileWriter(filepath, enc);\r
+ fs.NewLine = newLine;\r
+ await this.Document.SaveAsync(fs, token);\r
+ fs.Close();\r
+ }\r
+\r
+ /// <summary>\r
/// アンマネージドリソースを開放する\r
/// </summary>\r
public void Dispose()\r
this.Render.Dispose();\r
}\r
SystemEvents.UserPreferenceChanged -= new UserPreferenceChangedEventHandler(SystemEvents_UserPreferenceChanged);\r
- DocumentExtend.Progress -= this.Document_Progress;\r
}\r
\r
void Refresh(Rectangle updateRect)\r
this.timer.Stop();\r
\r
this.Render.BegineDraw();\r
- if (this.Document.State != AsyncState.Loading)\r
+ if (this.IsEnabled)\r
this.View.Draw(updateRect);\r
else\r
this.Render.FillBackground(updateRect);\r
#region Commands\r
void CanExecute(object sender, CanExecuteRoutedEventArgs e)\r
{\r
- e.CanExecute = this.Document.State != FooEditEngine.AsyncState.Loading;\r
+ e.CanExecute = this.IsEnabled;\r
}\r
\r
void ToggleCodePointCommand(object sender, RoutedEventArgs e)\r
get { return this.textStore; }\r
}\r
\r
+ double textStore_GetDpi()\r
+ {\r
+ float dpi;\r
+ this.Render.GetDpi(out dpi, out dpi);\r
+ return dpi;\r
+ }\r
+\r
bool textStore_IsReadOnly()\r
{\r
return false;\r
\r
bool textStore_IsLoading()\r
{\r
- return this.Document.State == AsyncState.Loading;\r
+ return false;\r
}\r
\r
void textStore_CompositionEnded()\r
\r
void _textStore_SetSelectionIndex(int i_startIndex, int i_endIndex)\r
{\r
- if (this.Document.State == AsyncState.Loading)\r
- return;\r
TextStoreHelper.SetSelectionIndex(this._Controller, this.View, i_startIndex, i_endIndex);\r
this.Refresh();\r
}\r
/// <inheritdoc/>\r
protected override void OnTextInput(TextCompositionEventArgs e)\r
{\r
- if (this.Document.State == AsyncState.Loading)\r
- return;\r
if (e.Text == "\r")\r
{\r
this._Controller.DoEnterAction();\r
}\r
else\r
{\r
- this._Controller.DoInputString(e.Text);\r
+ if(this.IsInputString(e.Text))\r
+ this._Controller.DoInputString(e.Text);\r
}\r
this.Refresh();\r
base.OnTextInput(e);\r
e.Handled = true;\r
}\r
\r
+ bool IsInputString(string s)\r
+ {\r
+ foreach (char charCode in s)\r
+ {\r
+ if ((0x20 <= charCode && charCode <= 0x7e)\r
+ || 0x7f < charCode)\r
+ return true;\r
+ }\r
+ return false;\r
+ }\r
+\r
/// <inheritdoc/>\r
protected override void OnKeyDown(KeyEventArgs e)\r
{\r
- if (this.Document.State == AsyncState.Loading)\r
- return;\r
if (this.textStore.IsLocked())\r
return;\r
\r
if (this.IsPressedModifierKey(modiferKeys, ModifierKeys.Control))\r
this._Controller.JumpToHead(this.IsPressedModifierKey(modiferKeys, ModifierKeys.Shift));\r
else\r
- this._Controller.JumpCaret(this.View.CaretPostion.row, 0);\r
+ this._Controller.JumpToLineHead(this.View.CaretPostion.row, this.IsPressedModifierKey(modiferKeys, ModifierKeys.Shift));\r
this.Refresh();\r
movedCaret = true;\r
break;\r
if (this.IsPressedModifierKey(modiferKeys, ModifierKeys.Control))\r
this._Controller.JumpToEnd(this.IsPressedModifierKey(modiferKeys, ModifierKeys.Shift));\r
else\r
- this._Controller.JumpCaret(this.View.CaretPostion.row, this.View.LayoutLines[this.View.CaretPostion.row].Length - 1);\r
+ this._Controller.JumpToLineEnd(this.View.CaretPostion.row, this.IsPressedModifierKey(modiferKeys, ModifierKeys.Shift));\r
this.Refresh();\r
movedCaret = true;\r
break;\r
case Key.Tab:\r
int oldLength = this.Document.Length;\r
- if (this.SelectionLength == 0)\r
+ if (this.Selection.Length == 0)\r
this._Controller.DoInputChar('\t');\r
else if(this.IsPressedModifierKey(modiferKeys,ModifierKeys.Shift))\r
this._Controller.DownIndent();\r
/// </remarks>\r
protected override void OnMouseDoubleClick(MouseButtonEventArgs e)\r
{\r
- if (this.Document.State == AsyncState.Loading)\r
- return;\r
System.Windows.Point p = e.GetPosition(this);\r
TextPoint tp = this.View.GetTextPointFromPostion(p);\r
if (tp == TextPoint.Null)\r
/// </remarks>\r
protected override void OnMouseDown(MouseButtonEventArgs e)\r
{\r
- if (this.Document.State == AsyncState.Loading)\r
- return;\r
- \r
System.Windows.Point p = e.GetPosition(this);\r
TextPoint tp = this.View.GetTextPointFromPostion(p);\r
if (tp == TextPoint.Null)\r
}\r
if (this.peer != null)\r
this.peer.OnNotifyCaretChanged();\r
- this.Refresh();\r
+ this.View.IsFocused = true;\r
this.Focus();\r
+ this.Refresh();\r
}\r
}\r
\r
/// </remarks>\r
protected override void OnMouseMove(MouseEventArgs e)\r
{\r
- if (this.Document.State == AsyncState.Loading)\r
- {\r
- this.Cursor = Cursors.Wait;\r
- base.OnMouseMove(e);\r
- return;\r
- }\r
System.Windows.Point p = e.GetPosition(this);\r
TextPoint tp = this.View.GetTextPointFromPostion(p);\r
if (tp == TextPoint.Null)\r
/// <inheritdoc/>\r
protected override void OnMouseWheel(MouseWheelEventArgs e)\r
{\r
- if (this.Document.State == AsyncState.Loading)\r
- return;\r
if(Keyboard.Modifiers == ModifierKeys.None)\r
{\r
if (e.Delta > 0)\r
\r
void Document_Update(object sender, DocumentUpdateEventArgs e)\r
{\r
- if (this.textStore.IsLocked() || e.type == UpdateType.Clear)\r
+ if (this.textStore.IsLocked())\r
return;\r
- if(e.removeLength == 0)\r
- this.textStore.NotifyTextChanged(e.startIndex,e.startIndex,e.startIndex + e.insertLength);\r
- else\r
- this.textStore.NotifyTextChanged(e.startIndex,e.startIndex + 1,e.startIndex + e.insertLength - e.removeLength);\r
- }\r
-\r
- void Document_Progress(object sender, ProgressEventArgs e)\r
- {\r
- if (this.Document.State == AsyncState.Loading)\r
- return;\r
- switch (e.state)\r
- {\r
- case ProgressState.Start:\r
- this.textStore.NotifyTextChanged(0, this.Document.Length, 0);\r
- break;\r
- case ProgressState.Complete:\r
- this.textStore.NotifyTextChanged(0, 0, this.Document.Length);\r
- this.OnMouseMove(new MouseEventArgs(Mouse.PrimaryDevice, new TimeSpan(DateTime.Now.Ticks).Milliseconds));\r
- if(this.verticalScrollBar != null)\r
- this.verticalScrollBar.Maximum = this.View.LayoutLines.Count;\r
- this.View.CalculateLineCountOnScreen();\r
- break;\r
- }\r
+ TextStoreHelper.NotifyTextChanged(this.textStore, e.startIndex, e.removeLength, e.insertLength);\r
}\r
\r
void timer_Tick(object sender, EventArgs e)\r
{\r
if (this.image.ActualWidth == 0 || this.image.ActualHeight == 0)\r
return;\r
- if (this.Document.State == AsyncState.Loading || this.Resize(this.image.ActualWidth, this.image.ActualHeight))\r
+ if (this.Resize(this.image.ActualWidth, this.image.ActualHeight))\r
{\r
this.Refresh();\r
return;\r
\r
void horizontalScrollBar_Scroll(object sender, ScrollEventArgs e)\r
{\r
- if (this.Document.State == AsyncState.Loading)\r
- return;\r
if (this.horizontalScrollBar == null)\r
return;\r
double toX;\r
\r
void verticalScrollBar_Scroll(object sender, ScrollEventArgs e)\r
{\r
- if (this.Document.State == AsyncState.Loading)\r
- return;\r
if (this.verticalScrollBar == null)\r
return;\r
int newRow = (int)this.verticalScrollBar.Value;\r
this.horizontalScrollBar.Value = Math.Abs(view.Src.X);\r
}\r
\r
- void Controller_CaretMoved(object sender, EventArgs e)\r
+ void Controller_SelectionChanged(object sender, EventArgs e)\r
{\r
this.View.CaretBlink = this.View.CaretBlink;\r
this.CaretMoved(this, null);\r
- SetValue(CaretPostionPropertyKey, this.View.CaretPostion);\r
+ //こうしないと選択できなくなってしまう\r
+ this.nowCaretMove = true;\r
+ SetValue(SelectionProperty, new TextRange(this._Controller.SelectionStart, this._Controller.SelectionLength));\r
+ SetValue(CaretPostionProperty, this.View.CaretPostion);\r
+ this.nowCaretMove = false; \r
if(this.textStore.IsLocked() == false)\r
this.textStore.NotifySelectionChanged();\r
}\r
{\r
if (width == 0 || height == 0)\r
throw new ArgumentOutOfRangeException();\r
- if (this.Render.Resize(width, height) && this.Document.State != AsyncState.Loading)\r
+ if (this.Render.Resize(width, height))\r
{\r
this.View.PageBound = new Rectangle(0, 0, width, height);\r
\r
{\r
switch (e.Property.Name)\r
{\r
+ case "Selection":\r
+ if(!this.nowCaretMove)\r
+ this.Select(this.Selection.Index, this.Selection.Length);\r
+ break;\r
case "CaretPostion":\r
- this.JumpCaret(this.CaretPostion.row, this.CaretPostion.col);\r
+ if (!this.nowCaretMove)\r
+ this.JumpCaret(this.CaretPostion.row, this.CaretPostion.col);\r
break;\r
case "LineBreakMethod":\r
this.View.LineBreak = this.LineBreakMethod;\r
this.Render.FontWeigth = this.FontWeight;\r
break;\r
case "Foreground":\r
- this.Render.Foreground = this.Foreground;\r
+ this.Render.Foreground = D2DRender.ToColor4(this.Foreground);\r
break;\r
case "Background":\r
- this.Render.Background = this.Background;\r
+ this.Render.Background = D2DRender.ToColor4(this.Background);\r
break;\r
case "ControlChar":\r
- this.Render.ControlChar = this.ControlChar;\r
+ this.Render.ControlChar =D2DRender.ToColor4( this.ControlChar);\r
break;\r
case "Hilight":\r
- this.Render.Hilight = this.Hilight;\r
+ this.Render.Hilight = D2DRender.ToColor4(this.Hilight);\r
break;\r
case "Keyword1":\r
- this.Render.Keyword1 = this.Keyword1;\r
+ this.Render.Keyword1 = D2DRender.ToColor4(this.Keyword1);\r
break;\r
case "Keyword2":\r
- this.Render.Keyword2 = this.Keyword2;\r
+ this.Render.Keyword2 = D2DRender.ToColor4(this.Keyword2);\r
break;\r
case "Comment":\r
- this.Render.Comment = this.Comment;\r
+ this.Render.Comment = D2DRender.ToColor4(this.Comment);\r
break;\r
case "Literal":\r
- this.Render.Literal = this.Literal;\r
+ this.Render.Literal = D2DRender.ToColor4(this.Literal);\r
break;\r
case "URL":\r
- this.Render.Url = this.URL;\r
+ this.Render.Url = D2DRender.ToColor4(this.URL);\r
break;\r
case "InsertCaret":\r
- this.Render.InsertCaret = this.InsertCaret;\r
+ this.Render.InsertCaret = D2DRender.ToColor4(this.InsertCaret);\r
break;\r
case "OverwriteCaret":\r
- this.Render.OverwriteCaret = this.OverwriteCaret;\r
+ this.Render.OverwriteCaret = D2DRender.ToColor4(this.OverwriteCaret);\r
+ break;\r
+ case "Padding":\r
+ this.View.Padding = new Padding((int)this.Padding.Left, (int)this.Padding.Top, (int)this.Padding.Right, (int)this.Padding.Bottom);\r
break;\r
case "LineMarker":\r
- this.Render.LineMarker = this.LineMarker;\r
+ this.Render.LineMarker = D2DRender.ToColor4(this.LineMarker);\r
break;\r
case "MarkURL":\r
this.View.UrlMark = this.MarkURL;\r
this.View.HideRuler = !this.DrawRuler;\r
this._Controller.JumpCaret(this.View.CaretPostion.row, this.View.CaretPostion.col);\r
break;\r
+ case "UpdateArea":\r
+ this.Render.UpdateArea = D2DRender.ToColor4(this.UpdateArea);\r
+ break;\r
}\r
base.OnPropertyChanged(e);\r
}\r
}\r
\r
/// <summary>\r
+ /// マーカーパターンセット\r
+ /// </summary>\r
+ public MarkerPatternSet MarkerPatternSet\r
+ {\r
+ get\r
+ {\r
+ return this.View.MarkerPatternSet;\r
+ }\r
+ }\r
+\r
+ /// <summary>\r
/// ドキュメントを表す\r
/// </summary>\r
public Document Document\r
}\r
\r
/// <summary>\r
- /// é\81¸æ\8a\9eç¯\84å\9b²ã\81®é\96\8bå§\8bã\82¤ã\83³ã\83\87ã\83\83ã\82¯ã\82¹\r
+ /// é\81¸æ\8a\9eç¯\84å\9b²ã\82\92表ã\81\99\r
/// </summary>\r
- /// <remarks>SelectionLengthが0の場合はキャレット位置を表します</remarks>\r
- public int SelectionStart\r
+ /// <remarks>\r
+ /// Lengthが0の場合はキャレット位置を表します。\r
+ /// 矩形選択モードの場合、選択範囲の文字数ではなく、開始位置から終了位置までの長さとなります\r
+ /// </remarks>\r
+ public TextRange Selection\r
{\r
- get { return this._Controller.SelectionStart; }\r
+ get { return (TextRange)GetValue(SelectionProperty); }\r
+ set { SetValue(SelectionProperty, value); }\r
}\r
\r
/// <summary>\r
- /// 選択範囲の長さ\r
+ /// Selectionの依存プロパティを表す\r
/// </summary>\r
- /// <remarks>矩形選択モードの場合、選択範囲の文字数ではなく、開始位置から終了位置までの長さとなります</remarks>\r
- public int SelectionLength\r
- {\r
- get { return this._Controller.SelectionLength; }\r
- }\r
+ public static readonly DependencyProperty SelectionProperty =\r
+ DependencyProperty.Register("Selection", typeof(TextRange), typeof(FooTextBox), new PropertyMetadata(TextRange.Null));\r
\r
/// <summary>\r
/// 拡大率を表す\r
set { SetValue(CaretPostionProperty, value); }\r
}\r
\r
- // Using a DependencyProperty as the backing store for CaretPostion. This enables animation, styling, binding, etc...\r
+ /// <summary>\r
+ /// CaretPostionの依存プロパティを表す\r
+ /// </summary>\r
public static readonly DependencyProperty CaretPostionProperty =\r
DependencyProperty.Register("CaretPostion", typeof(TextPoint), typeof(FooTextBox), new PropertyMetadata(TextPoint.Null));\r
\r
DependencyProperty.Register("InsertCaret", typeof(System.Windows.Media.Color), typeof(FooTextBox), new FrameworkPropertyMetadata(SystemColors.WindowTextColor));\r
\r
/// <summary>\r
+ /// 行更新フラグの色を表す\r
+ /// </summary>\r
+ public System.Windows.Media.Color UpdateArea\r
+ {\r
+ get { return (System.Windows.Media.Color)GetValue(UpdateAreaProperty); }\r
+ set { SetValue(UpdateAreaProperty, value); }\r
+ }\r
+\r
+ /// <summary>\r
+ /// UpdateAreaの依存プロパティを表す\r
+ /// </summary>\r
+ public static readonly DependencyProperty UpdateAreaProperty =\r
+ DependencyProperty.Register("UpdateArea", typeof(System.Windows.Media.Color), typeof(FooTextBox), new PropertyMetadata(Colors.MediumSeaGreen)); \r
+\r
+ /// <summary>\r
/// 上書きモード時のキャレット職を表す\r
/// </summary>\r
public System.Windows.Media.Color OverwriteCaret\r