Karya, built on 2018-05-31T02:46:59 (patch 0a1a35479c514820d77330ae8a978975ba22a47a)

Safe HaskellNone

Types

Description

This re-exports especially popular types, since they are frequently mentioned in type signatures. Unlike most of the other modules, it's meant to be imported unqualified.

Synopsis

Documentation

type TrackNum = Int Source #

Index into a block's tracks.

data ScoreTime Source #

Score time is the abstract unit of time, and its mapping to real time is dependent on the score context. ScoreTime units can be negative, but blocks only display events at >=0 ScoreTime.

Instances
Eq ScoreTime # 
Instance details

Defined in Ui.ScoreTime

Fractional ScoreTime # 
Instance details

Defined in Ui.ScoreTime

Num ScoreTime # 
Instance details

Defined in Ui.ScoreTime

Ord ScoreTime # 
Instance details

Defined in Ui.ScoreTime

Read ScoreTime # 
Instance details

Defined in Ui.ScoreTime

Real ScoreTime # 
Instance details

Defined in Ui.ScoreTime

RealFrac ScoreTime # 
Instance details

Defined in Ui.ScoreTime

Show ScoreTime # 
Instance details

Defined in Ui.ScoreTime

NFData ScoreTime # 
Instance details

Defined in Ui.ScoreTime

Methods

rnf :: ScoreTime -> () #

CStorable ScoreTime # 
Instance details

Defined in Ui.ScoreTime

CRC32 ScoreTime # 
Instance details

Defined in Ui.ScoreTime

ApproxEq ScoreTime # 
Instance details

Defined in Ui.ScoreTime

Methods

eq :: Double -> ScoreTime -> ScoreTime -> Bool Source #

Pretty ScoreTime # 
Instance details

Defined in Ui.ScoreTime

Serialize ScoreTime # 
Instance details

Defined in Ui.ScoreTime

ShowVal ScoreTime # 
Instance details

Defined in Ui.ScoreTime

ToVal ScoreTime # 
Instance details

Defined in Derive.RestrictedEnviron

Methods

to_val :: ScoreTime -> Val Source #

Time ScoreTime # 
Instance details

Defined in Derive.Deriver.Internal

TypecheckNum ScoreTime # 
Instance details

Defined in Derive.Typecheck

ToVal ScoreTime # 
Instance details

Defined in Derive.Typecheck

Methods

to_val :: ScoreTime -> Val Source #

Typecheck ScoreTime # 
Instance details

Defined in Derive.Typecheck

type TrackTime = ScoreTime Source #

This is also ScoreTime, but it's relative to the beginning of the track. I.e., UI events are all in track time, but when they get shifted and stretched as by note slicing they're no longer in TrackTime, but not yet in RealTime.

I'd like to make a type-level distinction because it's easy to get confused about whether a time has or hasn't been transformed, but when I tried it seemed like a big hassle since I'd really like for TrackTime to be a subtype of ScoreTime. I could do it with a phantom type, but it would change about a million type declarations. And since Events start in TrackTime but are then ScoreTime if transformed, they would also need a type parameter, along with probably a few other basic data types.

Unless I work up the courage to do that someday, the least I can do is document the difference with a type synonym.

data RealTime Source #

A concrete unit of time.

This must have negative values because it's used for signals, which are used for the warp map, which is oriented with zero at the note start. If a note wants to get the real time before it, it must look up a negative RealTime.

Instances
Eq RealTime # 
Instance details

Defined in Perform.RealTime

Fractional RealTime # 
Instance details

Defined in Perform.RealTime

Num RealTime # 
Instance details

Defined in Perform.RealTime

Ord RealTime # 
Instance details

Defined in Perform.RealTime

Read RealTime # 
Instance details

Defined in Perform.RealTime

Real RealTime # 
Instance details

Defined in Perform.RealTime

RealFrac RealTime # 
Instance details

Defined in Perform.RealTime

Methods

properFraction :: Integral b => RealTime -> (b, RealTime) #

truncate :: Integral b => RealTime -> b #

round :: Integral b => RealTime -> b #

ceiling :: Integral b => RealTime -> b #

floor :: Integral b => RealTime -> b #

Show RealTime # 
Instance details

Defined in Perform.RealTime

Storable RealTime # 
Instance details

Defined in Perform.RealTime

NFData RealTime # 
Instance details

Defined in Perform.RealTime

Methods

rnf :: RealTime -> () #

CStorable RealTime # 
Instance details

Defined in Perform.RealTime

CRC32 RealTime # 
Instance details

Defined in Perform.RealTime

ToJSON RealTime # 
Instance details

Defined in Perform.RealTime

FromJSON RealTime # 
Instance details

Defined in Perform.RealTime

ApproxEq RealTime # 
Instance details

Defined in Perform.RealTime

Methods

eq :: Double -> RealTime -> RealTime -> Bool Source #

Pretty RealTime # 
Instance details

Defined in Perform.RealTime

Serialize RealTime # 
Instance details

Defined in Perform.RealTime

ShowVal RealTime # 
Instance details

Defined in Perform.RealTime

ShowVal Function # 
Instance details

Defined in Derive.Typecheck

ShowVal TypedFunction # 
Instance details

Defined in Derive.Typecheck

ToVal RealTime # 
Instance details

Defined in Derive.RestrictedEnviron

Methods

to_val :: RealTime -> Val Source #

Time RealTime # 
Instance details

Defined in Derive.Deriver.Internal

TypecheckNum RealTime # 
Instance details

Defined in Derive.Typecheck

ToVal RealTime # 
Instance details

Defined in Derive.Typecheck

Methods

to_val :: RealTime -> Val Source #

Typecheck RealTime # 
Instance details

Defined in Derive.Typecheck

Typecheck Function # 
Instance details

Defined in Derive.Typecheck

Typecheck TypedFunction # 
Instance details

Defined in Derive.Typecheck

data BlockId Source #

Reference to a Block. Use this to look up Blocks in the State.

The convention is that BlockId should name a block which is expected to exist, and the only way to create a BlockId is via create_block. The name of a block which is to be created is simply Id.

However, since the constructor is exported, this isn't rigorously enforced.

Unlike other Ids, block names have no restrictions, except no spaces. This is because they become note calls, and it's convenient to have arbitrary names for the same reason it's convenient to allow arbitrary characters in call names.

Instances
Eq BlockId # 
Instance details

Defined in Ui.Id

Methods

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

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

Ord BlockId # 
Instance details

Defined in Ui.Id

Read BlockId # 
Instance details

Defined in Ui.Id

Show BlockId # 
Instance details

Defined in Ui.Id

NFData BlockId # 
Instance details

Defined in Ui.Id

Methods

rnf :: BlockId -> () #

CRC32 BlockId # 
Instance details

Defined in Ui.Id

Pretty BlockId # 
Instance details

Defined in Ui.Id

Serialize BlockId # 
Instance details

Defined in Ui.Id

Ident BlockId # 
Instance details

Defined in Ui.Id

data ViewId Source #

Reference to a View, as per BlockId.

Instances
Eq ViewId # 
Instance details

Defined in Ui.Id

Methods

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

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

Ord ViewId # 
Instance details

Defined in Ui.Id

Read ViewId # 
Instance details

Defined in Ui.Id

Show ViewId # 
Instance details

Defined in Ui.Id

NFData ViewId # 
Instance details

Defined in Ui.Id

Methods

rnf :: ViewId -> () #

CRC32 ViewId # 
Instance details

Defined in Ui.Id

Pretty ViewId # 
Instance details

Defined in Ui.Id

Serialize ViewId # 
Instance details

Defined in Ui.Id

Ident ViewId # 
Instance details

Defined in Ui.Id

data TrackId Source #

Instances
Eq TrackId # 
Instance details

Defined in Ui.Id

Methods

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

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

Ord TrackId # 
Instance details

Defined in Ui.Id

Read TrackId # 
Instance details

Defined in Ui.Id

Show TrackId # 
Instance details

Defined in Ui.Id

NFData TrackId # 
Instance details

Defined in Ui.Id

Methods

rnf :: TrackId -> () #

CRC32 TrackId # 
Instance details

Defined in Ui.Id

Pretty TrackId # 
Instance details

Defined in Ui.Id

Serialize TrackId # 
Instance details

Defined in Ui.Id

Ident TrackId # 
Instance details

Defined in Ui.Id

data RulerId Source #

Instances
Eq RulerId # 
Instance details

Defined in Ui.Id

Methods

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

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

Ord RulerId # 
Instance details

Defined in Ui.Id

Read RulerId # 
Instance details

Defined in Ui.Id

Show RulerId # 
Instance details

Defined in Ui.Id

NFData RulerId # 
Instance details

Defined in Ui.Id

Methods

rnf :: RulerId -> () #

CRC32 RulerId # 
Instance details

Defined in Ui.Id

Pretty RulerId # 
Instance details

Defined in Ui.Id

Serialize RulerId # 
Instance details

Defined in Ui.Id

Ident RulerId # 
Instance details

Defined in Ui.Id