Karya, built on 2020-11-26T21:03:17 (patch 23b5be2d53a9e8e7d6136cda5aae2849abe5cded)
Safe HaskellNone

Ui.Zoom

Description

The Zoom type.

Synopsis

Documentation

data Zoom Source #

View zoom and time scroll offset.

Constructors

Zoom 

Instances

Instances details
Eq Zoom # 
Instance details

Defined in Ui.Zoom

Methods

(==) :: Zoom -> Zoom -> Bool #

(/=) :: Zoom -> Zoom -> Bool #

Ord Zoom # 
Instance details

Defined in Ui.Zoom

Methods

compare :: Zoom -> Zoom -> Ordering #

(<) :: Zoom -> Zoom -> Bool #

(<=) :: Zoom -> Zoom -> Bool #

(>) :: Zoom -> Zoom -> Bool #

(>=) :: Zoom -> Zoom -> Bool #

max :: Zoom -> Zoom -> Zoom #

min :: Zoom -> Zoom -> Zoom #

Read Zoom # 
Instance details

Defined in Ui.Zoom

Show Zoom # 
Instance details

Defined in Ui.Zoom

Methods

showsPrec :: Int -> Zoom -> ShowS #

show :: Zoom -> String #

showList :: [Zoom] -> ShowS #

CStorable Zoom # 
Instance details

Defined in Ui.Zoom

Methods

sizeOf :: Zoom -> Int #

alignment :: Zoom -> Int #

peekElemOff :: Ptr Zoom -> Int -> IO Zoom #

pokeElemOff :: Ptr Zoom -> Int -> Zoom -> IO () #

peekByteOff :: Ptr b -> Int -> IO Zoom #

pokeByteOff :: Ptr b -> Int -> Zoom -> IO () #

peek :: Ptr Zoom -> IO Zoom #

poke :: Ptr Zoom -> Zoom -> IO () #

Pretty Zoom # 
Instance details

Defined in Ui.Zoom

Serialize Zoom # 
Instance details

Defined in Cmd.Serialize

to_pixels :: Zoom -> ScoreTime.TrackTime -> Int Source #

Convert a position at a given zoom factor to a pixel position. Doesn't take the zoom offset into account.

to_time :: Zoom -> Int -> ScoreTime.TrackTime Source #

Convert a pixel position to a TrackTime at the given zoom factor. Doesn't take the zoom offset into account.