private void EditBoxOnUnloaded(object sender, RoutedEventArgs routedEventArgs) { Settings.Default.WordWrapEnabled = EditBox.WordWrap; Settings.Default.SpellCheckEnabled = SpellCheck; Settings.Default.AutoSave = AutoSave; FindReplaceDialog.Dispose(); }
public MainWindow(IMarkdownConverter markdownConverter, ISpellCheckProvider spellCheckProvider, FindReplaceDialog findReplaceDialog) { InitializeComponent(); MarkdownConverter = markdownConverter; SpellCheckProvider = spellCheckProvider; FindReplaceDialog = findReplaceDialog; Loaded += OnLoaded; Closing += OnClosing; SizeChanged += (s, e) => CalculateEditorMargins(); Editor.PropertyChanged += EditorOnPropertyChanged; Editor.TextChanged += (s, e) => Preview.UpdatePreview(Editor.Text); Editor.ScrollChanged += (s, e) => Preview.SetScrollOffset(e); }
public void FindPrevious() => Execute(() => FindReplaceDialog.FindPrevious());
public void FindNext() => Execute(() => FindReplaceDialog.FindNext());
public void ReplaceDialog() => Execute(() => FindReplaceDialog.ShowReplaceDialog());
public void FindDialog() { Execute(() => FindReplaceDialog.ShowFindDialog()); }