yi-0.6.6.0: The Haskell-Scriptable Editor

Safe HaskellSafe-Infered

Yi.Style

Description

Colors and friends.

Synopsis

Documentation

data Attributes Source

Visual text attributes to be applied during layout.

Constructors

Attributes 

Fields

foreground :: !Color
 
background :: !Color
 
reverseAttr :: !Bool

The text should be show as active or selected. This can be implemented by reverse video on the terminal.

bold :: !Bool
 
italic :: !Bool
 
underline :: !Bool
 

type Style = Endo AttributesSource

The style is used to transform attributes by modifying one or more of the visual text attributes.

data UIStyle Source

The UI type

Constructors

UIStyle 

Fields

modelineAttributes :: Attributes

ground attributes for the modeline

modelineFocusStyle :: Style

transformation of modeline in focus

tabBarAttributes :: Attributes

ground attributes for the tabbar

tabInFocusStyle :: Style

a tab that currently holds the focus

tabNotFocusedStyle :: Style

a tab that does not have the current focus

baseAttributes :: Attributes

ground attributes for the main text views

selectedStyle :: Style

the selected portion

eofStyle :: Style

empty file marker colours

errorStyle :: Style

indicates errors in text

hintStyle :: Style

search matchesparen matchesother hints

strongHintStyle :: Style

current search match

commentStyle :: Style

all comments

blockCommentStyle :: Style

additional only for block comments

keywordStyle :: Style

applied to language keywords

numberStyle :: Style

numbers

preprocessorStyle :: Style

preprocessor directive (often in Haskell or C)

stringStyle :: Style

constant strings

longStringStyle :: Style

additional style for long strings

typeStyle :: Style

type name (such as class in an OO language)

dataConstructorStyle :: Style

data constructor

importStyle :: Style

style of import names

builtinStyle :: Style

builtin things, e.g. Array in JavaScript

regexStyle :: Style

regular expressions

variableStyle :: Style

any standard variable (identifier)

operatorStyle :: Style

infix operators

quoteStyle :: Style

Style of a quotation (e.g. in template haskell)

makeFileAction :: Style

stuff that's passed to the shell in a Makefile

makeFileRuleHead :: Style

makefile rule headers

type StyleName = UIStyle -> StyleSource

A StyleName determines what style to use, taking into account the set of rendering preferences given by a UIStyle. Typically, style names will be Style-valued field names of UIStyle.

withFg, withBg :: Color -> StyleSource

A style that sets the foreground.

withBd, withReverse, withUnderline, withItlc :: Bool -> StyleSource

A style that sets the font to bold

defaultStyle :: StyleNameSource

The identity transform.

data Color Source

Constructors

RGB !Word8 !Word8 !Word8 
Default

The system-default color of the engine used. e.g. in Gtk this should pick whatever the user has chosen as default color (background or forground depending on usage) for the text.

Instances

colorToText :: Color -> StringSource

Convert a color to its text specification, as to be accepted by XParseColor