yi-0.8.1: The Haskell-Scriptable Editor

Safe HaskellNone




spawnMinibufferE :: String -> KeymapEndo -> EditorM BufferRef Source

Open a minibuffer window with the given prompt and keymap The third argument is an action to perform after the minibuffer is opened such as move to the first occurence of a searched for string. If you don't need this just supply return ()

withMinibuffer :: String -> (String -> YiM [String]) -> (String -> YiM ()) -> YiM () Source

withMinibuffer prompt completer act: open a minibuffer with prompt. Once a string s is obtained, run act s. completer can be used to complete functions: it returns a list of possible matches.

withMinibufferGen :: String -> (String -> YiM [String]) -> String -> (String -> YiM String) -> (String -> YiM ()) -> (String -> YiM ()) -> YiM () Source

withMinibufferGen proposal getHint prompt completer onTyping act: open a minibuffer with prompt, and initial content proposal. Once a string s is obtained, run act s. completer can be used to complete inputs by returning an incrementally better match, and getHint can give an immediate feedback to the user on the current input.

on Typing is an extra action which will fire with every user key-press and receives minibuffer contents. Use something like const $ return () if you don't need this.

withMinibufferFin :: String -> [String] -> (String -> YiM ()) -> YiM () Source

Open a minibuffer, given a finite number of suggestions.

matchingBufferNames :: String -> YiM [String] Source

Returns all the buffer names.

newtype t ::: doc Source

Tag a type with a documentation




fromDoc :: t


Eq t => Eq ((:::) t doc) 
Num t => Num ((:::) t doc) 
Show x => Show ((:::) x t) 
IsString t => IsString ((:::) t doc) 
Typeable (* -> * -> *) (:::) 

data RegexTag Source