class HistoryFilter extends DelegateFilter
Provides history navigation up and down, saving the current line, a well
as history-search functionality (Ctrl R in bash) letting you quickly find
& filter previous commands by entering a sub-string.
- Alphabetic
- By Inheritance
- HistoryFilter
- DelegateFilter
- Filter
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Instance Constructors
- new HistoryFilter(history: () => IndexedSeq[String], commentStartColor: Attrs)
Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##: Int
- Definition Classes
- AnyRef → Any
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- def activeHistory: Boolean
- def activeSearch: Boolean
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def backspace(b: Vector[Char], c: Int): (Vector[Char], Int, String)
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @native()
- def ctrlR(b: Vector[Char], c: Int): (Vector[Char], Int, String)
- def down(b: Vector[Char], c: Int): (Vector[Char], Int, String)
- val dropHistoryChars: Set[Int]
- implicit val enclosing: Enclosing
- Definition Classes
- DelegateFilter
- def endHistory(): Unit
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def equals(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef → Any
- def filter: Filter
- Definition Classes
- HistoryFilter → DelegateFilter
- def filter0: Filter
- def finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable])
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- def hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- var historyIndex: Int
-1means we haven't started looking at history,n >= 0means we're currently at history commandn - def identifier: String
the
.toStringof this object, except by making it separate we force the implementer to provide something and stop them from accidentally leaving it as the meaningless default.the
.toStringof this object, except by making it separate we force the implementer to provide something and stop them from accidentally leaving it as the meaningless default.- Definition Classes
- DelegateFilter → Filter
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- def op(ti: TermInfo): Option[TermAction]
- Definition Classes
- DelegateFilter → Filter
- def prelude: Filter
- var prevBuffer: Option[Vector[Char]]
Records the last buffer that the filter has observed while it's in search/history mode.
Records the last buffer that the filter has observed while it's in search/history mode. If the new buffer differs from this, assume that some other filter modified the buffer and drop out of search/history
- def printableChar(char: Char)(b: Vector[Char], c: Int): (Vector[Char], Int, String)
- def searchHistory(start: Int, increment: Int, buffer: Vector[Char], skipped: Vector[Char]): (Vector[Char], Int, String)
- def searchOrHistoryAnd(cond: Boolean): Boolean
Predicate to check if either we're searching for a term or if we're in history-browsing mode and some predicate is true.
Predicate to check if either we're searching for a term or if we're in history-browsing mode and some predicate is true.
Very often we want to capture keystrokes in search-mode more aggressively than in history-mode, e.g. search-mode drops you out more aggressively than history-mode does, and its up/down keys cycle through history more aggressively on every keystroke while history-mode only cycles when you reach the top/bottom line of the multi-line input.
- var searchTerm: Option[Vector[Char]]
The term we're searching for, if any.
The term we're searching for, if any.
-
Nonemeans we're not searching for anything, e.g. we're just browsing history-
Some(term)wheretermis not empty is what it normally looks like when we're searching for something-
Some(term)wheretermis empty only really happens when you start searching and delete things, or if youCtrl-Ron an empty prompt - def startHistory(b: Vector[Char], c: Int): (Vector[Char], Int, String)
Kicks the HistoryFilter from passive-mode into search-history mode
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def toString(): String
- Definition Classes
- Filter → AnyRef → Any
- def up(b: Vector[Char], c: Int): (Vector[Char], Int, String)
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()
- def wrap(rest: LazyList[Int], out: (Vector[Char], Int, String)): TermState