Table of Contents

Class Fuzzy

Namespace
MiniTui
Assembly
MiniTui.dll

Fuzzy matching, as in CommandPalette (1.x spec §13.5).

public static class Fuzzy
Inheritance
Fuzzy
Inherited Members

Methods

Match(string, string)

Match pattern against text, ignoring case. Spaces in the pattern are skipped; every other pattern character must appear in the text in order. Word starts (after a space or punctuation, or a capital after a lowercase letter), runs of consecutive characters and the same case score higher, and skipped characters lower; a prefix of the text scores higher still.

public static FuzzyMatch? Match(string pattern, string text)

Parameters

pattern string
text string

Returns

FuzzyMatch?

The match with the highest score, or null if the text doesn't match. An empty or all-space pattern matches every text with score 0.