C# Class SIL.FieldWorks.LexText.Controls.PatternView

This class represents a Views rootsite control that is used to display a pattern. It notifies the pattern control about key presses and right clicks.
Inheritance: SIL.FieldWorks.Common.RootSites.RootSiteControl
Mostra file Open project: sillsdev/FieldWorks Class Usage Examples

Public Methods

Method Description
Init ( XCore.Mediator mediator, int hvo, IPatternControl patternControl, PatternVcBase vc, int rootFrag, ISilDataAccess sda ) : void
MakeRoot ( ) : void
SelectAt ( object ctxt, int index, bool initial, bool editable, bool install ) : IVwSelection

Moves the cursor to the specified position in the specified cell.

Protected Methods

Method Description
CreateEditingHelper ( ) : EditingHelper
HandleSelectionChange ( IVwRootBox prootb, IVwSelection vwselNew ) : void
OnKeyDown ( KeyEventArgs e ) : void

override this to allow deleting an item IF the key is Delete.

OnKeyPress ( KeyPressEventArgs e ) : void

override this to allow deleting an item IF the key is Backspace.

OnRightMouseUp ( Point pt, Rectangle rcSrcRoot, Rectangle rcDstRoot ) : bool

Private Methods

Method Description
AdjustSelection ( SelectionHelper sel ) : void

Adjusts the selection.

GetSelectionInfo ( SelectionHelper sel, SelectionHelper limit, IVwSelection &vwSel, int &curHvo, int &curIch, int &curTag ) : bool

Creates a selection IP for the specified limit.

SelectCell ( object ctxt, bool initial, bool install ) : IVwSelection
SelectLeftBoundary ( object ctxt, int index, bool install ) : void
SelectRightBoundary ( object ctxt, int index, bool install ) : void
UpdateSelection ( IVwSelection vwselNew ) : void

Update the new selection. This is called by rule formula view when selection changes.

Method Details

CreateEditingHelper() protected method

protected CreateEditingHelper ( ) : EditingHelper
return EditingHelper

HandleSelectionChange() protected method

protected HandleSelectionChange ( IVwRootBox prootb, IVwSelection vwselNew ) : void
prootb IVwRootBox
vwselNew IVwSelection
return void

Init() public method

public Init ( XCore.Mediator mediator, int hvo, IPatternControl patternControl, PatternVcBase vc, int rootFrag, ISilDataAccess sda ) : void
mediator XCore.Mediator
hvo int
patternControl IPatternControl
vc PatternVcBase
rootFrag int
sda ISilDataAccess
return void

MakeRoot() public method

public MakeRoot ( ) : void
return void

OnKeyDown() protected method

override this to allow deleting an item IF the key is Delete.
protected OnKeyDown ( KeyEventArgs e ) : void
e System.Windows.Forms.KeyEventArgs
return void

OnKeyPress() protected method

override this to allow deleting an item IF the key is Backspace.
protected OnKeyPress ( KeyPressEventArgs e ) : void
e System.Windows.Forms.KeyPressEventArgs
return void

OnRightMouseUp() protected method

protected OnRightMouseUp ( Point pt, Rectangle rcSrcRoot, Rectangle rcDstRoot ) : bool
pt Point
rcSrcRoot System.Drawing.Rectangle
rcDstRoot System.Drawing.Rectangle
return bool

SelectAt() public method

Moves the cursor to the specified position in the specified cell.
public SelectAt ( object ctxt, int index, bool initial, bool editable, bool install ) : IVwSelection
ctxt object The context.
index int Index of the item in the cell.
initial bool if true move the cursor to the beginning of the specified item, otherwise it is moved to the end
editable bool if true move the cursor to the first editable position
install bool if true install the selection
return IVwSelection