Skip to main content

highlight_contains

Function highlight_contains 

Source
pub fn highlight_contains(
    query: &str,
    item: &CompletionItem,
) -> Vec<Range<usize>>
Expand description

Highlight the first case-insensitive occurrence of query in the label.

An empty query, or a query that does not occur as a contiguous span, paints nothing.