C# Class WikiFunctions.WikiDiff

This class renders MediaWiki-like HTML diffs
Afficher le fichier Open project: reedy/AutoWikiBrowser Class Usage Examples

Méthodes publiques

Méthode Description
DiffHead ( ) : string

Returns style header, from style.css file if present, else default style

GetDiff ( string leftText, string rightText, int contextLines ) : string

Renders diff

ResetCustomStyles ( ) : void
UndoAddition ( int right ) : string
UndoChange ( int left, int right ) : string
UndoDeletion ( int left, int right ) : string

Private Methods

Méthode Description
ContextHeader ( int left, int right ) : void
ContextLine ( int line ) : void

Renders a context row

LineAdded ( int line ) : void
LineChanged ( int leftLine, int rightLine ) : void
LineDeleted ( int left, int right ) : void
RenderContext ( Diff hunk ) : void
RenderDifference ( Diff hunk ) : void
WhitespaceDiff ( StringBuilder res, Word left, Word right ) : void
WordDiff ( StringBuilder res, Range range, Range otherRange, IList words, IList otherWords ) : void

Method Details

DiffHead() public static méthode

Returns style header, from style.css file if present, else default style
public static DiffHead ( ) : string
Résultat string

GetDiff() public méthode

Renders diff
public GetDiff ( string leftText, string rightText, int contextLines ) : string
leftText string Earlier version of the text
rightText string Later version of the text
contextLines int Number of unchanged lines to show around changed ones
Résultat string

ResetCustomStyles() public static méthode

public static ResetCustomStyles ( ) : void
Résultat void

UndoAddition() public méthode

public UndoAddition ( int right ) : string
right int
Résultat string

UndoChange() public méthode

public UndoChange ( int left, int right ) : string
left int
right int
Résultat string

UndoDeletion() public méthode

public UndoDeletion ( int left, int right ) : string
left int
right int
Résultat string