yi-core-0.19.4: Yi editor core library

License | GPL-2
Maintainer | yi-devel@googlegroups.com
Stability | experimental
Portability | portable
Safe Haskell | None
Language | Haskell2010

Extensions

- TemplateHaskell
- TemplateHaskellQuotes
- DeriveDataTypeable

Yi.Window

Description

Operations on `Window`s, in the emacs sense of the word.

Synopsis

- data Window = Window {
  - isMini :: !Bool
  - bufkey :: !BufferRef
  - bufAccessList :: ![BufferRef]
  - height :: !Int
  - width :: !Int
  - winRegion :: !Region
  - wkey :: !WindowRef
  - actualLines :: !Int
  - jumpList :: !JumpList
  }
- actualLinesA :: Lens' Window Int
- bufAccessListA :: Lens' Window [BufferRef]
- bufkeyA :: Lens' Window BufferRef
- heightA :: Lens' Window Int
- isMiniA :: Lens' Window Bool
- jumpListA :: Lens' Window JumpList
- widthA :: Lens' Window Int
- winRegionA :: Lens' Window Region
- wkeyA :: Lens' Window WindowRef
- winkey :: Window -> (Bool, BufferRef)
- dummyWindow :: BufferRef -> Window

# Documentation

data Window Source #

A window onto a buffer.

Constructors

Window |

Fields

- isMini :: !Bool

  regular or mini window?

- bufkey :: !BufferRef

  the buffer this window opens to

- bufAccessList :: ![BufferRef]

  list of last accessed buffers (former bufKeys). Last accessed one is first element

- height :: !Int

  height of the window (in number of screen lines displayed)

- width :: !Int

  width of the window (in number of chars)

- winRegion :: !Region

  view area. note that the top point is also available as a buffer mark.

- wkey :: !WindowRef

  identifier for the window (for UI sync) This is required for accurate scrolling. Scrolling depends on the actual number of buffer lines displayed. Line wrapping changes that number relative to the height so we can't use height for that purpose.

- actualLines :: !Int

  The actual number of buffer lines displayed. Taking into account line wrapping

- jumpList :: !JumpList

#### Instances

Instances details

Binary Window Source # |
Instance details Defined in Yi.Window Methods put :: Window -> Put Source # get :: Get Window Source # putList :: [Window] -> Put Source #
Show Window Source # |
Instance details Defined in Yi.Window Methods showsPrec :: Int -> Window -> ShowS Source # show :: Window -> String Source # showList :: [Window] -> ShowS Source #
Eq Window Source # |
Instance details Defined in Yi.Window Methods (==) :: Window -> Window -> Bool Source # (/=) :: Window -> Window -> Bool Source #
MonadReader Window BufferM Source # |
Instance details Defined in Yi.Types Methods ask :: BufferM Window Source # local :: (Window -> Window) -> BufferM a -> BufferM a Source # reader :: (Window -> a) -> BufferM a Source #

actualLinesA :: Lens' Window Int Source #

bufAccessListA :: Lens' Window [BufferRef] Source #

bufkeyA :: Lens' Window BufferRef Source #

heightA :: Lens' Window Int Source #

isMiniA :: Lens' Window Bool Source #

jumpListA :: Lens' Window JumpList Source #

widthA :: Lens' Window Int Source #

winRegionA :: Lens' Window Region Source #

wkeyA :: Lens' Window WindowRef Source #

winkey :: Window -> (Bool, BufferRef) Source #

Get the identification of a window.

dummyWindow :: BufferRef -> Window Source #

Return a "fake" window onto a buffer.