if (this.peer != null)\r
this.peer.OnNotifyCaretChanged();\r
this.View.IsFocused = true;\r
+ this.Focus(FocusState.Programmatic);\r
this.Refresh();\r
}\r
\r
}\r
void Refresh(Rectangle updateRect)\r
{\r
- if (this.rectangle.ActualWidth == 0 || this.rectangle.ActualHeight == 0/* || !this.Render.IsCanDraw()*/)\r
+ if (this.rectangle.ActualWidth == 0 || this.rectangle.ActualHeight == 0 || this.Visibility == Windows.UI.Xaml.Visibility.Collapsed)\r
return;\r
\r
this.Render.BegineDraw();\r
{\r
source.View.HideRuler = !source.DrawRuler;\r
source._Controller.JumpCaret(source.View.CaretPostion.row, source.View.CaretPostion.col);\r
- } \r
+ }\r
}\r
#endregion\r
\r
}\r
}\r
\r
- bool _IsRTL, _ShowRuler, _ShowLineNumber, _ShowLineMarker, _HilightXML;\r
+ bool _IsRTL, _ShowRuler, _ShowLineNumber, _ShowLineMarker, _HilightXML, _IsVisible = true;\r
ObservableCollection<LineBreakMethodItem> _LineBreakMethodList;\r
LineBreakMethodItem _CurrentLineBreakMethod;\r
\r
}\r
}\r
\r
+ public bool IsVisible\r
+ {\r
+ get\r
+ {\r
+ return this._IsVisible;\r
+ }\r
+ set\r
+ {\r
+ this._IsVisible = value;\r
+ if (ChangedSetting != null)\r
+ ChangedSetting(this, null);\r
+ }\r
+ }\r
+\r
public bool IsRTL\r
{\r
get\r
this.fooTextBox.Hilighter = null;\r
this.fooTextBox.LayoutLineCollection.ClearHilight();\r
}\r
+ this.fooTextBox.Visibility = setting.IsVisible ? Visibility.Visible : Visibility.Collapsed;\r
this.fooTextBox.LineBreakMethod = setting.CurrentLineBreakMethod.Method;\r
this.fooTextBox.LineBreakCharCount = 50;\r
this.fooTextBox.Refresh();\r
<ToggleSwitch Margin="-6, 0, 0, 0" IsOn="{Binding ShowLineNumber,Mode=TwoWay}" Header = "行番号を表示する" HorizontalAlignment="Stretch"/>\r
<ToggleSwitch Margin="-6, 0, 0, 0" IsOn="{Binding ShowLineMarker,Mode=TwoWay}" Header = "キャレットラインを表示する" HorizontalAlignment="Stretch"/>\r
<ToggleSwitch Margin="-6, 0, 0, 0" IsOn="{Binding HilightXML,Mode=TwoWay}" Header = "XMLドキュメントのハイライトを行う" HorizontalAlignment="Stretch"/>\r
+ <ToggleSwitch Margin="-6, 0, 0, 0" IsOn="{Binding IsVisible,Mode=TwoWay}" Header = "Visiblity is visible" HorizontalAlignment="Stretch"/>\r
<ComboBox ItemsSource="{Binding LineBreakMethodList}" SelectedItem="{Binding CurrentLineBreakMethod,Mode=TwoWay}">\r
<ComboBox.ItemTemplate>\r
<DataTemplate>\r
\r
void Refresh(Rectangle updateRect)\r
{\r
- if (this.disposed)\r
+ if (this.disposed || this.Visibility == Visibility.Collapsed)\r
return;\r
\r
this.timer.Stop();\r