License | BSD-3-Clause |
---|---|
Safe Haskell | Safe-Inferred |
Language | Haskell2010 |
Types for styling custom entity attributes
Synopsis
- data StyleFlag
- = Standout
- | Italic
- | Strikethrough
- | Underline
- | ReverseVideo
- | Blink
- | Dim
- | Bold
- styleFlagJsonOptions :: Options
- newtype HexColor = HexColor Text
- data CustomAttr = CustomAttr {}
- toHifiPair :: CustomAttr -> Maybe (WorldAttr, PreservableColor)
Documentation
Instances
FromJSON StyleFlag Source # | |
Defined in Swarm.Game.Scenario.Style | |
ToJSON StyleFlag Source # | |
Generic StyleFlag Source # | |
Show StyleFlag Source # | |
Eq StyleFlag Source # | |
Ord StyleFlag Source # | |
Defined in Swarm.Game.Scenario.Style | |
type Rep StyleFlag Source # | |
Defined in Swarm.Game.Scenario.Style type Rep StyleFlag = D1 ('MetaData "StyleFlag" "Swarm.Game.Scenario.Style" "swarm-0.6.0.0-ERx1HMcRMba59aI2b6aNrS-swarm-scenario" 'False) (((C1 ('MetaCons "Standout" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Italic" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "Strikethrough" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Underline" 'PrefixI 'False) (U1 :: Type -> Type))) :+: ((C1 ('MetaCons "ReverseVideo" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Blink" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "Dim" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Bold" 'PrefixI 'False) (U1 :: Type -> Type)))) |
Hexadecimal color notation.
May include a leading hash symbol (see sRGB24read
).
data CustomAttr Source #
Instances
toHifiPair :: CustomAttr -> Maybe (WorldAttr, PreservableColor) Source #
Must specify either a foreground or background color; just a style is not sufficient.