Added supporting logic to SaveText and SaveContents for Editorial Spell Checker
Added supporting logic to SpellCheckNext for Editorial Spell Checker Save text changes before starting up the spell checker Added supporting logic to UpdateEditor for Editorial Spell Checker
This commit is contained in:
@@ -3252,7 +3252,7 @@ namespace Volian.Controls.Library
|
||||
get { return StepRTB._DoSpellCheck; }
|
||||
set { StepRTB._DoSpellCheck = value; }
|
||||
}
|
||||
// We made the Spell Checker method a static so that all of the StepRTB boxes will bare the same instance of the dictionary.
|
||||
// We made the Spell Checker method a static so that all of the StepRTB boxes will share the same instance of the dictionary.
|
||||
// This allow all the StepRTB's to automatically update when a new word is added.
|
||||
private static C1.Win.C1SpellChecker.C1SpellChecker _C1SpellChecker2;
|
||||
|
||||
@@ -3337,7 +3337,6 @@ namespace Volian.Controls.Library
|
||||
//_ContextMenuStepRTB.MyRTBItem.MyStepPanel.MyStepTabPanel.MyStepTabRibbon.OpenContextMenu(tsmi.Owner.Location);
|
||||
_ContextMenuStepRTB.OnOpenContextMenu(sender, new StepRTBLocationEventArgs(tsmi.Owner.Location));
|
||||
}
|
||||
|
||||
// This is our customized Spell Check dialog
|
||||
// This is display when the use clicks the Spell button from the Ribbon
|
||||
// or when the "Spell" item is selected from the context menu when on a mis-spelled word
|
||||
@@ -3352,15 +3351,20 @@ namespace Volian.Controls.Library
|
||||
}
|
||||
}
|
||||
|
||||
// B2015-024 have Spell Checker text changes be in editorial mode (not assign a change bar but keep existing change bar)
|
||||
public static bool DidEditorialSpellCheck = false;
|
||||
|
||||
// This is used when walking through the section doing a spell check
|
||||
// (from the Spell button on the ribbon)
|
||||
public bool SpellCheckNext()
|
||||
{
|
||||
int nBad = C1SpellChecker2.CheckControl(this, false, MySpellCheckDlg);
|
||||
if (MyItemInfo.ActiveFormat.PlantFormat.FormatData.EditData.EditoralSpellCheck)
|
||||
DidEditorialSpellCheck = MySpellCheckDlg.DidCorrectSpelling; // B2015-024 spell checker in editoral mode
|
||||
return (nBad >= 0); // nBad = -1 means user pressed Cancel button
|
||||
}
|
||||
|
||||
// This allows us to turn off/on the specll check context menu when we toggle in and out of View Mode.
|
||||
// This allows us to turn off/on the spell check context menu when we toggle in and out of View Mode.
|
||||
// see btnToggleEditView_Click() in StepTabRibbon.cs
|
||||
public void SpellCheckContextMenuOn(bool turnOnMenu)
|
||||
{
|
||||
|
Reference in New Issue
Block a user