~jaro/balkon

ref: 75e3b64a230f131fcde0b12604a187aef4ee2853 balkon/src/Data/Text/ParagraphLayout/Internal/ResolvedBox.hs -rw-r--r-- 483 bytes
75e3b64aJaro Store direction in ResolvedBox. 1 year, 10 days ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
module Data.Text.ParagraphLayout.Internal.ResolvedBox (ResolvedBox (..))
where

import Data.Text.Glyphize (Direction)

import Data.Text.ParagraphLayout.Internal.BoxOptions

-- | Internal structure describing an inline box.
-- May be shared by multiple fragments.
data ResolvedBox d = ResolvedBox
    { boxUserData :: d
    , boxIndex :: Int
    , boxOptions :: BoxOptions
    , boxDirection :: Direction
    }

instance Eq (ResolvedBox d) where
    a == b = boxIndex a == boxIndex b