C# Class SIL.FieldWorks.IText.SandboxEditMonitor

Inheritance: SIL.Utils.FwDisposableBase, IVwNotifyChange
Datei anzeigen Open project: sillsdev/FieldWorks Class Usage Examples

Private Properties

Property Type Description
BuildCurrentMorphsString string
BuildCurrentMorphsString string
IsBaseWordPhrase bool
RecreateDelayedSelection void
SandboxEditMonitor System
SetMorphemes void
StartMonitoring void
StopMonitoring void
UpdateMorphemes void

Public Methods

Method Description
DoPendingMorphemeUpdates ( ) : void
HandleBackspace ( ) : bool

Handle an otherwise-difficult backspace (joining morphemes by deleting a 'space') Return true if successful.

HandleDelete ( ) : bool

Handle an otherwise-difficult delete (joining morphemes by deleting a 'space').

IsPropMorphBreak ( int hvo, int tag, int ws ) : bool

Is the property one of the ones that represents a morpheme breakdown?

PropChanged ( int hvo, int tag, int ivMin, int cvIns, int cvDel ) : void

A property changed. Is it one of the ones that requires us to update the morpheme list? Even if so, we shouldn't do it now, because it's dangerous to issue new PropChanged messages for the same property during a PropChanged. Instead we wait for a DoUpdates call. Also don't do it if we're in the middle of processing such an update already.

Protected Methods

Method Description
DisposeManagedResources ( ) : void
DisposeUnmanagedResources ( ) : void

Private Methods

Method Description
BuildCurrentMorphsString ( ) : string
BuildCurrentMorphsString ( IVwSelection sel ) : string
IsBaseWordPhrase ( string baseWord ) : bool
RecreateDelayedSelection ( object sender, EventArgs e ) : void

Recreate a selection that has (almost certainly) been overwritten by TSF since it can't handle a "selection changed" notification in the middle of it calling into our code to deliver new text.

See https://jira.sil.org/browse/LT-16766 "Keyman 9 IPA - insert morpheme breaks can put cursor in undesirable location, or cause a crash".

SandboxEditMonitor ( SandboxBase sandbox ) : System
SetMorphemes ( string currentMorphemes ) : void
StartMonitoring ( ) : void
StopMonitoring ( ) : void
UpdateMorphemes ( ) : void

Method Details

DisposeManagedResources() protected method

protected DisposeManagedResources ( ) : void
return void

DisposeUnmanagedResources() protected method

protected DisposeUnmanagedResources ( ) : void
return void

DoPendingMorphemeUpdates() public method

public DoPendingMorphemeUpdates ( ) : void
return void

HandleBackspace() public method

Handle an otherwise-difficult backspace (joining morphemes by deleting a 'space') Return true if successful.
public HandleBackspace ( ) : bool
return bool

HandleDelete() public method

Handle an otherwise-difficult delete (joining morphemes by deleting a 'space').
public HandleDelete ( ) : bool
return bool

IsPropMorphBreak() public method

Is the property one of the ones that represents a morpheme breakdown?
public IsPropMorphBreak ( int hvo, int tag, int ws ) : bool
hvo int
tag int
ws int
return bool

PropChanged() public method

A property changed. Is it one of the ones that requires us to update the morpheme list? Even if so, we shouldn't do it now, because it's dangerous to issue new PropChanged messages for the same property during a PropChanged. Instead we wait for a DoUpdates call. Also don't do it if we're in the middle of processing such an update already.
public PropChanged ( int hvo, int tag, int ivMin, int cvIns, int cvDel ) : void
hvo int
tag int
ivMin int
cvIns int
cvDel int
return void