package css

  1. Overview
  2. Docs
CSS parser and printer

Install

Dune Dependency

Authors

Maintainers

Sources

ocaml-css-0.1.0.tar.bz2
md5=bc4bdcf47b37c7bd50bf9f31c391dcd2
sha512=8fa12c193638ba8c2d307f48e477cdac839ca25f865f7f350bc7675086c3c4a70bc1e5936d35d64aab9d8da2c9806005be70c59ac3d7f3c407a3861f6e0a7cf8

doc/css/Css/T/index.html

Module Css.TSource

Types and base definitions.

Utils

Sourcemodule Smap : sig ... end

Maps of strings.

Sourcemodule Sset : sig ... end

String sets.

Sourcemodule Imap : sig ... end

Maps over integers.

Sourceval mk_pp : ('a -> string) -> Format.formatter -> 'a -> unit

mk_pp f creates a formatter -> x -> unit function from the given x -> string function.

Sourceval string_of_list : string -> ('a -> string) -> 'a list -> string

string_of_list sep to_string l is String.concat sep (List.map to_string l).

Sourceval mk_of_string : ?case_sensitive:bool -> ('a -> string) -> 'a list -> string -> 'a option

mk_of_string to_string l returns a function mapping strings to values, according to the reverse function to_string. Optional argument case_sensitive (default is true) indicates where case is taken into account when mapping from string to values. The returned function returns None if the given string could not be mapped to a value, else Some value.

Positions and locations

Sourcetype loc = pos * pos
Sourcetype 'a with_loc = 'a * loc
Sourcetype 'a with_loc_option = 'a * loc option
Sourceval string_of_loc : (Lexing.position * Lexing.position) -> string
Sourceval string_of_loc_option : (Lexing.position * Lexing.position) option -> string
Sourceval pp_loc_option : Format.formatter -> (Lexing.position * Lexing.position) option -> unit
Sourceval pos_of_string_at : ?fname:string -> ?from:(int * Lexing.position) -> string -> int -> Lexing.position

pos_of_string_at str at returns the pos corresponding to offset at in the given string. Optional arguments:

  • fname specifies a filename to use in the returned position.
  • from, as a pair (offset, p), specifies to start at offset, using p as initial pos structure. The fname in returned position still is the optiona fname argument.
Sourceval loc_of_string_at : string -> int -> Lexing.position * Lexing.position

Parsing contexts

Sourcetype ctx = {
  1. get_pos : pos Angstrom.t;
  2. last_pos : pos Angstrom.t;
  3. string_of_loc : loc -> string;
}

A context is used in parsers to retrieve location information. get_pos returns the current position. last_pos returns the most advanced position seen. string_of_loc returns the string corresponding to the given location.

Sourceval ctx : (int -> pos) -> ctx

ctx get_pos builds a new context with the given get_pos functions.

Sourceval string_ctx : ?fname:string -> string -> ctx

 string_ctx str creates a context from the given string str. Computing of pos structure is cached. fname can be specified to set this field in positions.

Error handling

Sourcetype parse_error =
  1. | Unterminated_string
  2. | Unterminated_comment
  3. | Unterminated_char_escape
  4. | Invalid_iri of string * Iri.error
  5. | Other of string

Parsing errors.

Sourcetype error =
  1. | Parse_error of pos option * parse_error
  2. | Undefined_namespace of string * loc
Sourceexception Error of error
Sourceval string_of_parse_error : parse_error -> string
Sourceval string_of_error : ?to_loc:(loc -> string) -> error -> string
Sourceval pp_error : Format.formatter -> error -> unit
Sourceval error : error -> 'a

Global keywords

Sourcetype global_kw = [
  1. | `Inherit
  2. | `Initial
  3. | `Revert
  4. | `Revert_layer
  5. | `Unset
]
Sourceval global_kws : [> `Inherit | `Initial | `Revert | `Revert_layer | `Unset ] list
Sourcetype 'a p_value = [
  1. | global_kw
  2. | `Var of string * string option
  3. | `V of 'a
]

A 'a p_value is either a global keyword, a variable (`Var (name, optional string value)) or a value (`V 'a). We do not know at variable definition time in which property this variable will be used. The parser associated to a property will parse the optional default variable value when the variable is expanded.

Sourceval string_of_p_value : ('a -> string) -> 'a p_value -> string
Sourceval pp_p_value : (Format.formatter -> 'a -> unit) -> Format.formatter -> 'a p_value -> unit
Sourcetype str = {
  1. s : string;
  2. quoted : bool;
}

Parsed strings, with a quoted flag indicating whether string is quoted.

Sourceval string_of_str : str -> string
Sourceval pp_str : Format.formatter -> str -> unit

CSS Value types

Sourcetype side = [
  1. | `Bottom
  2. | `Left
  3. | `Right
  4. | `Top
]
Sourceval sides : [> `Bottom | `Left | `Right | `Top ] list
Sourceval string_of_side : side -> string
Sourcetype lcr = [
  1. | `Left
  2. | `Center
  3. | `Right
]
Sourcetype number = float
Sourceval string_of_number : float -> string
Sourceval pp_number : Format.formatter -> float -> unit
Sourcetype rel_length_unit = [
  1. | `em
    (*

    Font size of the element.

    *)
  2. | `ex
    (*

    x-height of the element's font.

    *)
  3. | `cap
    (*

    Cap height (the nominal height of capital letters) of the element's font.

    *)
  4. | `ch
    (*

    Average character advance of a narrow glyph in the element's font, as represented by the "0" (ZERO, U+0030) glyph.

    *)
  5. | `ic
    (*

    Average character advance of a full width glyph in the element's font, as represented by the "水" (CJK water ideograph, U+6C34) glyph.

    *)
  6. | `rem
    (*

    Font size of the root element.

    *)
  7. | `lh
    (*

    Line height of the element.

    *)
  8. | `rlh
    (*

    Line height of the root element.

    *)
  9. | `vw
    (*

    1% of viewport's width.

    *)
  10. | `vh
    (*

    1% of viewport's height.

    *)
  11. | `vi
    (*

    1% of viewport's size in the root element's inline axis.

    *)
  12. | `vb
    (*

    1% of viewport's size in the root element's block axis.

    *)
  13. | `vmin
    (*

    1% of viewport's smaller dimension.

    *)
  14. | `vmax
    (*

    1% of viewport's larger dimension.

    *)
  15. | `cqw
    (*

    1% of a query container's width

    *)
  16. | `cqh
    (*

    1% of a query container's height

    *)
  17. | `cqi
    (*

    1% of a query container's inline size

    *)
  18. | `cqb
    (*

    1% of a query container's block size

    *)
  19. | `cqmin
    (*

    The smaller value of cqi or cqb

    *)
  20. | `cqmax
    (*

    The larger value of cqi or cqb

    *)
]
Sourceval rel_length_units : [> `cap | `ch | `cqb | `cqh | `cqi | `cqmax | `cqmin | `cqw | `em | `ex | `ic | `lh | `rem | `rlh | `vb | `vh | `vi | `vmax | `vmin | `vw ] list
Sourceval string_of_rel_length_unit : rel_length_unit -> string
Sourcetype abs_length_unit = [
  1. | `cm
    (*

    Centimeters 1cm = 96px/2.54

    *)
  2. | `mm
    (*

    Millimeters 1mm = 1/10th of 1cm

    *)
  3. | `q
  4. | `In
    (*

    Inches 1in = 2.54cm = 96px

    *)
  5. | `pc
    (*

    Picas 1pc = 1/6th of 1in

    *)
  6. | `pt
    (*

    Points 1pt = 1/72th of 1in

    *)
  7. | `px
    (*

    Pixels 1px = 1/96th of 1in

    *)
]
Sourceval abs_length_units : [> `In | `cm | `mm | `pc | `pt | `px | `q ] list
Sourceval string_of_abs_length_unit : abs_length_unit -> string
Sourcetype length_unit = [
  1. | rel_length_unit
  2. | abs_length_unit
]
Sourceval string_of_length_unit : length_unit -> string
Sourceval pp_length_unit : Format.formatter -> length_unit -> unit
Sourcetype angle_unit = [
  1. | `deg
    (*

    Degrees There are 360 degrees in a full circle.

    *)
  2. | `grad
    (*

    Gradians There are 400 gradians in a full circle.

    *)
  3. | `rad
    (*

    Radians There are 2__pi__ radians in a full circle.

    *)
  4. | `turn
    (*

    Turns There is 1 turn in a full circle.

    *)
]
Sourceval angle_units : [> `deg | `grad | `rad | `turn ] list
Sourceval string_of_angle_unit : angle_unit -> string
Sourceval pp_angle_unit : Format.formatter -> angle_unit -> unit
Sourcetype angle = number * angle_unit
Sourceval string_of_angle : (float * angle_unit) -> string
Sourceval pp_angle : Format.formatter -> (float * angle_unit) -> unit
Sourcetype time_unit = [
  1. | `s
  2. | `ms
]
Sourceval time_units : [> `ms | `s ] list
Sourceval string_of_time_unit : time_unit -> string
Sourceval pp_time_unit : Format.formatter -> time_unit -> unit
Sourcetype freq_unit = [
  1. | `hz
  2. | `khz
]
Sourceval freq_units : [> `hz | `khz ] list
Sourceval string_of_freq_unit : freq_unit -> string
Sourceval pp_freq_unit : Format.formatter -> freq_unit -> unit
Sourcetype flex_unit = [
  1. | `fr
]
Sourceval flex_units : [> `fr ] list
Sourceval string_of_flex_unit : flex_unit -> string
Sourceval pp_flex_unit : Format.formatter -> flex_unit -> unit
Sourcetype resolution_unit = [
  1. | `dpi
    (*

    Dots per inch.

    *)
  2. | `dpcm
    (*

    Dots per centimeter.

    *)
  3. | `dppx
  4. | `x
    (*

    Dots per px unit.

    *)
]
Sourceval resolution_units : [> `dpcm | `dpi | `dppx | `x ] list
Sourceval string_of_resolution_unit : resolution_unit -> string
Sourceval pp_resolution_unit : Format.formatter -> resolution_unit -> unit
Sourceval string_of_dim_unit : dim_unit -> string
Sourceval pp_dim_unit : Format.formatter -> dim_unit -> unit
Sourcetype dimension = number * dim_unit
Sourceval string_of_dimension : float -> dim_unit -> string
Sourcetype system_color = [
  1. | `AccentColorText
  2. | `ActiveText
  3. | `ButtonBorder
  4. | `ButtonFace
  5. | `ButtonText
  6. | `Canvas
  7. | `CanvasText
  8. | `Field
  9. | `FieldText
  10. | `GrayText
  11. | `Highlight
  12. | `HighlightText
  13. | `LinkText
  14. | `Mark
  15. | `MarkText
  16. | `SelectedItem
  17. | `SelectedItemText
  18. | `VisitedText
]
Sourceval system_colors : [> `AccentColorText | `ActiveText | `ButtonBorder | `ButtonFace | `ButtonText | `Canvas | `CanvasText | `Field | `FieldText | `GrayText | `Highlight | `HighlightText | `LinkText | `Mark | `MarkText | `SelectedItem | `SelectedItemText | `VisitedText ] list
Sourceval string_of_system_color : system_color -> string
Sourceval pp_system_color : Format.formatter -> system_color -> unit
Sourceval system_color_of_string : string -> system_color option
Sourcetype color_kw = [
  1. | `Current_color
  2. | `Transparent
]
Sourceval color_kws : color_kw list
Sourcetype color = [
  1. | `Rgba of float * float * float * float
  2. | `Named_color of string
  3. | `System_color of system_color
  4. | color_kw
]
Sourceval string_of_color : color -> string
Sourceval pp_color : Format.formatter -> color -> unit
Sourcetype trblc = [
  1. | `Top
  2. | `Right
  3. | `Bottom
  4. | `Left
  5. | `Center
]
Sourceval trblc_kws : trblc list
Sourceval string_of_trblc : [< trblc ] -> string
Sourcetype x_position_kw = [
  1. | `Left
  2. | `Center
  3. | `Right
]
Sourceval x_position_kws : [> `Center | `Left | `Right ] list
Sourceval string_of_x_position_kw : x_position_kw -> string
Sourcetype y_position_kw = [
  1. | `Top
  2. | `Center
  3. | `Bottom
]
Sourceval y_position_kws : [> `Bottom | `Center | `Top ] list
Sourceval string_of_y_position_kw : y_position_kw -> string
Sourcetype percentage = [
  1. | `Percent of number
]
Sourceval string_of_percentage : percentage -> string
Sourcetype length_percentage = [
  1. | `Length of number * length_unit
  2. | percentage
]
Sourceval string_of_length : float -> length_unit -> string
Sourceval pp_length : Format.formatter -> (float * length_unit) -> unit
Sourceval string_of_length_percentage : length_percentage -> string
Sourceval pp_length_percentage : Format.formatter -> length_percentage -> unit
Sourcetype 'a axis_pos =
  1. | Offset of length_percentage
  2. | Kw of 'a
  3. | KO of 'a * length_percentage
Sourceval string_of_axis_pos : [< trblc ] axis_pos -> string
Sourcetype axis_position =
  1. | Single_kw of trblc
  2. | XY of x_position_kw axis_pos * y_position_kw axis_pos
Sourcetype x_position = x_position_kw axis_pos
Sourcetype y_position = y_position_kw axis_pos
Sourceval string_of_x_position : x_position -> string
Sourceval string_of_y_position : y_position -> string
Sourceval string_of_axis_position : axis_position -> string
Sourceval pp_axis_position : Format.formatter -> axis_position -> unit
Sourceval string_of_p_number : float p_value -> string
Sourcetype size_kw = [
  1. | `Auto
  2. | `Max_content
  3. | `Min_content
]
Sourceval size_kws : size_kw list
Sourcetype size = [
  1. | length_percentage
  2. | `Fit_content of length_percentage
  3. | size_kw
]
Sourceval string_of_size : size -> string
Sourceval pp_size : Format.formatter -> size -> unit
Sourcetype max_size_kw = [
  1. | `None
  2. | `Max_content
  3. | `Min_content
]
Sourceval max_size_kws : max_size_kw list
Sourcetype max_size = [
  1. | length_percentage
  2. | `Fit_content of length_percentage
  3. | max_size_kw
]
Sourceval string_of_max_size : max_size -> string
Sourceval pp_max_size : Format.formatter -> max_size -> unit
Sourceval string_of_url : Iri.t -> string
Sourceval pp_url : Format.formatter -> Iri.t -> unit
Sourcetype line_style = [
  1. | `None
  2. | `Hidden
  3. | `Dotted
  4. | `Dashed
  5. | `Solid
  6. | `Double
  7. | `Groove
  8. | `Ridge
  9. | `Inset
  10. | `Outset
]
Sourceval line_styles : line_style list
Sourceval string_of_line_style : line_style -> string
Sourceval pp_line_style : Format.formatter -> line_style -> unit
Sourcetype gradient = [
  1. | `Linear
  2. | `Repeating_linear
  3. | `Radial
  4. | `Repeating_radial
]
Sourceval string_of_gradient : gradient -> string
Sourceval pp_gradient : Format.formatter -> gradient -> unit
Sourcetype image = [
  1. | `Url of Iri.t
  2. | `Gradient of gradient * string
  3. | `Function of string * string
]
Sourceval string_of_image : image -> string
Sourceval pp_image : Format.formatter -> image -> unit
Sourcetype value =
  1. | String of str
  2. | Integer of int
  3. | Number of number
  4. | Dimension of dimension
  5. | Percent of number
  6. | Color of color
  7. | Position of axis_position
Sourceval string_of_value : value -> string
Sourceval pp_value : Format.formatter -> value -> unit
Sourcetype accent_color_kw = [
  1. | `Auto
]
Sourceval accent_color_kws : accent_color_kw list
Sourcetype accent_color = [
  1. | color
  2. | accent_color_kw
]
Sourceval string_of_accent_color : accent_color -> string
Sourceval pp_accent_color : Format.formatter -> accent_color -> unit
Sourcetype baseline_position_kw = [
  1. | `Baseline
]
Sourceval baseline_position_kws : baseline_position_kw list
Sourcetype baseline_position = [
  1. | baseline_position_kw
  2. | `First_baseline
  3. | `Last_baseline
]
Sourceval string_of_baseline_position : baseline_position -> string
Sourceval pp_baseline_position : Format.formatter -> baseline_position -> unit
Sourcetype content_position_kw = [
  1. | `Center
  2. | `End
  3. | `Flex_end
  4. | `Flex_start
  5. | `Start
]
Sourceval content_position_kws : [> `Center | `End | `Flex_end | `Flex_start | `Start ] list
Sourcetype content_position = content_position_kw
Sourceval string_of_content_position : content_position -> string
Sourceval pp_content_position : Format.formatter -> content_position -> unit
Sourcetype content_position_lr_kw = [
  1. | content_position_kw
  2. | `Left
  3. | `Right
]
Sourceval content_position_lr_kws : [> `Center | `End | `Flex_end | `Flex_start | `Left | `Right | `Start ] list
Sourcetype content_position_lr = content_position_lr_kw
Sourceval string_of_content_position_lr : content_position_lr -> string
Sourceval pp_content_position_lr : Format.formatter -> content_position_lr -> unit
Sourcetype self_position_kw = [
  1. | `Self_start
  2. | `Self_end
  3. | content_position_kw
]
Sourceval self_position_kws : [> `Center | `End | `Flex_end | `Flex_start | `Self_end | `Self_start | `Start ] list
Sourcetype self_position = self_position_kw
Sourceval string_of_self_position : self_position -> string
Sourceval pp_self_position : Format.formatter -> self_position -> unit
Sourcetype self_position_lr_kw = [
  1. | self_position_kw
  2. | `Left
  3. | `Right
]
Sourceval self_position_lr_kws : [> `Center | `End | `Flex_end | `Flex_start | `Left | `Right | `Self_end | `Self_start | `Start ] list
Sourcetype self_position_lr = self_position_lr_kw
Sourceval string_of_self_position_lr : self_position_lr -> string
Sourceval pp : 'a -> Format.formatter -> self_position_lr -> unit
Sourcetype content_distribution_kw = [
  1. | `Space_around
  2. | `Space_between
  3. | `Space_evenly
  4. | `Stretch
]
Sourceval content_distribution_kws : [> `Space_around | `Space_between | `Space_evenly | `Stretch ] list
Sourcetype content_distribution = content_distribution_kw
Sourceval string_of_content_distribution : content_distribution -> string
Sourceval pp_content_distribution : Format.formatter -> content_distribution -> unit
Sourcetype align_content_kw = [
  1. | `Normal
]
Sourceval align_content_kws : align_content_kw list
Sourceval string_of_align_content : align_content -> string
Sourceval pp_align_content : Format.formatter -> align_content -> unit
Sourcetype align_items_kw = [
  1. | `Normal
  2. | `Stretch
]
Sourceval align_items_kws : align_items_kw list
Sourcetype align_items = [
  1. | baseline_position
  2. | self_position
  3. | `Safe_self_pos of self_position
  4. | `Unsafe_self_pos of self_position
  5. | align_items_kw
]
Sourceval string_of_align_items : align_items -> string
Sourceval pp_align_items : Format.formatter -> align_items -> unit
Sourcetype align_self_kw = [
  1. | `Auto
]
Sourceval align_self_kws : align_self_kw list
Sourcetype align_self = [
  1. | align_self_kw
  2. | align_items
]
Sourceval string_of_align_self : align_self -> string
Sourceval pp_align_self : Format.formatter -> align_self -> unit
Sourcetype aspect_ratio_kw = [
  1. | `Auto
]
Sourceval aspect_ratio_kws : aspect_ratio_kw list
Sourcetype aspect_ratio = [
  1. | `Ratio of number * number option
  2. | aspect_ratio_kw
]
Sourceval string_of_aspect_ratio : aspect_ratio -> string
Sourceval pp_aspect_ratio : Format.formatter -> aspect_ratio -> unit
Sourceval string_of_background_ : ('a -> string) -> 'a list -> string
Sourcetype background_attachment_kw = [
  1. | `Fixed
  2. | `Local
  3. | `Scroll
]
Sourceval background_attachment_kws : background_attachment_kw list
Sourcetype background_attachment_ = background_attachment_kw
Sourcetype background_attachment = background_attachment_ list
Sourceval string_of_background_attachment : background_attachment -> string
Sourceval pp_background_attachment : Format.formatter -> background_attachment -> unit
Sourcetype background_clip_kw = [
  1. | `Border_box
  2. | `Content_box
  3. | `Padding_box
  4. | `Text
]
Sourceval background_clip_kws : background_clip_kw list
Sourcetype background_clip_ = background_clip_kw
Sourcetype background_clip = background_clip_ list
Sourceval string_of_background_clip : background_clip -> string
Sourceval pp_background_clip : Format.formatter -> background_clip -> unit
Sourcetype background_image_kw = [
  1. | `None
]
Sourceval background_image_kws : background_image_kw list
Sourcetype background_image_ = [
  1. | `Image of image
  2. | background_image_kw
]
Sourceval string_of_background_image_ : background_image_ -> string
Sourcetype background_image = background_image_ list
Sourceval string_of_background_image : background_image -> string
Sourceval pp_background_image : Format.formatter -> background_image -> unit
Sourcetype background_origin_kw = [
  1. | `Border_box
  2. | `Content_box
  3. | `Padding_box
]
Sourceval background_origin_kws : background_origin_kw list
Sourcetype background_origin_ = background_origin_kw
Sourcetype background_origin = background_origin_ list
Sourceval string_of_background_origin : background_origin -> string
Sourceval pp_background_origin : Format.formatter -> background_origin -> unit
Sourcetype background_position_x = x_position list
Sourceval string_of_background_position_x : background_position_x -> string
Sourceval pp_background_position_x : Format.formatter -> background_position_x -> unit
Sourcetype background_position_y = y_position list
Sourceval string_of_background_position_y : background_position_y -> string
Sourceval pp_background_position_y : Format.formatter -> background_position_y -> unit
Sourcetype repeat = [
  1. | `No_repeat
  2. | `Repeat
  3. | `Round
  4. | `Space
]
Sourceval repeat_kws : repeat list
Sourceval string_of_repeat : repeat -> string
Sourceval pp_repeat : Format.formatter -> repeat -> unit
Sourcetype background_repeat_kw = [
  1. | `Repeat_x
  2. | `Repeat_y
]
Sourceval background_repeat_kws : background_repeat_kw list
Sourcetype background_repeat_ = repeat * repeat
Sourcetype background_repeat = background_repeat_ list
Sourceval string_of_background_repeat : background_repeat -> string
Sourceval pp_background_repeat : Format.formatter -> background_repeat -> unit
Sourcetype background_size_kw = [
  1. | `Auto
  2. | `Contain
  3. | `Cover
]
Sourceval background_size_kws : background_size_kw list
Sourcetype background_size_ = [
  1. | background_size_kw
  2. | length_percentage
]
Sourceval string_of_background_size_ : background_size_ -> string
Sourcetype background_size = (background_size_ * background_size_) list
Sourceval string_of_background_size : background_size -> string
Sourceval pp_background_size : Format.formatter -> background_size -> unit
Sourcetype background_color = color
Sourceval string_of_background_color : color -> string
Sourceval pp_background_color : Format.formatter -> color -> unit
Sourcetype width = size
Sourceval string_of_width : size -> string
Sourceval pp_width : Format.formatter -> size -> unit
Sourcetype border_width_kw = [
  1. | `Thin
  2. | `Medium
  3. | `Thick
]
Sourceval border_width_kws : border_width_kw list
Sourcetype border_width = [
  1. | width
  2. | border_width_kw
]
Sourceval string_of_border_width : border_width -> string
Sourceval pp_border_width : Format.formatter -> border_width -> unit
Sourcetype display_outside = [
  1. | `Block
  2. | `Inline
  3. | `Run_in
]
Sourceval display_outside_kws : display_outside list
Sourcetype display_flow = [
  1. | `Flow
  2. | `Flow_root
]
Sourceval display_flow_kws : display_flow list
Sourcetype display_inside = [
  1. | display_flow
  2. | `Table
  3. | `Flex
  4. | `Grid
  5. | `Ruby
]
Sourceval display_inside_kws : display_inside list
Sourcetype display_listitem = display_outside * display_flow
Sourcetype display_listitem_kw = [
  1. | `List_item
]
Sourceval display_listitem_kws : display_listitem_kw list
Sourcetype display_internal = [
  1. | `Table_row_group
  2. | `Table_header_group
  3. | `Table_row
  4. | `Table_cell
  5. | `Table_column_group
  6. | `Table_column
  7. | `Table_caption
  8. | `Ruby_base
  9. | `Ruby_base_container
  10. | `Ruby_text
  11. | `Ruby_text_container
]
Sourceval display_internal_kws : display_internal list
Sourcetype display_box = [
  1. | `Contents
  2. | `None
]
Sourceval display_box_kws : display_box list
Sourcetype display_legacy = [
  1. | `Inline_block
  2. | `Inline_table
  3. | `Inline_flex
  4. | `Inline_grid
]
Sourceval display_legacy_kws : [> `Inline_block | `Inline_flex | `Inline_grid | `Inline_table ] list
Sourcetype display_out_in = display_outside * display_inside * [ `List_item ] option
Sourcetype display = [
  1. | `Out_in of display_out_in
  2. | display_internal
  3. | display_box
]
Sourceval string_of_display : display -> string
Sourceval pp_display : Format.formatter -> display -> unit
Sourcetype flex_basis_kw = [
  1. | `Content
]
Sourceval flex_basis_kws : flex_basis_kw list
Sourcetype flex_basis = [
  1. | flex_basis_kw
  2. | width
]
Sourceval string_of_flex_basis : flex_basis -> string
Sourceval pp_flex_basis : Format.formatter -> flex_basis -> unit
Sourcetype flex_direction_kw = [
  1. | `Column
  2. | `Column_reverse
  3. | `Row
  4. | `Row_reverse
]
Sourceval flex_direction_kws : flex_direction_kw list
Sourcetype flex_direction = flex_direction_kw
Sourceval string_of_flex_direction : flex_direction -> string
Sourceval pp_flex_direction : Format.formatter -> flex_direction -> unit
Sourcetype flex_wrap_kw = [
  1. | `Nowrap
  2. | `Wrap
  3. | `Wrap_reverse
]
Sourceval flex_wrap_kws : flex_wrap_kw list
Sourcetype flex_wrap = flex_wrap_kw
Sourceval string_of_flex_wrap : flex_wrap -> string
Sourceval pp_flex_wrap : Format.formatter -> flex_wrap -> unit
Sourcetype font_family_generic_kw = [
  1. | `Cursive
  2. | `Emoji
  3. | `Fantasy
  4. | `Fangsong
  5. | `Math
  6. | `Monospace
  7. | `Sans_serif
  8. | `Serif
  9. | `System_ui
  10. | `Ui_monospace
  11. | `Ui_rounded
  12. | `Ui_sans_serif
  13. | `Ui_serif
]
Sourceval font_family_generic_kws : font_family_generic_kw list
Sourcetype font_family_ = [
  1. | `Generic of font_family_generic_kw
  2. | `Family of string
]
Sourceval string_of_font_family_ : font_family_ -> string
Sourcetype font_family = font_family_ list
Sourceval string_of_font_family : font_family -> string
Sourceval pp_font_family : Format.formatter -> font_family -> unit
Sourcetype font_kerning = [
  1. | `Normal
  2. | `Auto
  3. | `None
]
Sourceval font_kerning_kws : font_kerning list
Sourceval string_of_font_kerning : font_kerning -> string
Sourceval pp_font_kerning : Format.formatter -> font_kerning -> unit
Sourcetype font_size_kw = [
  1. | `Large
  2. | `Larger
  3. | `Math
  4. | `Medium
  5. | `Small
  6. | `Smaller
  7. | `Xxx_large
  8. | `Xx_large
  9. | `Xx_small
  10. | `X_large
  11. | `X_small
]
Sourceval font_size_kws : font_size_kw list
Sourcetype font_size = [
  1. | font_size_kw
  2. | length_percentage
]
Sourceval string_of_font_size : font_size -> string
Sourceval pp_font_size : Format.formatter -> font_size -> unit
Sourcetype font_stretch_kw = [
  1. | `Normal
  2. | `Ultra_condensed
  3. | `Extra_condensed
  4. | `Semi_condensed
  5. | `Condensed
  6. | `Ultra_expanded
  7. | `Extra_expanded
  8. | `Semi_expanded
  9. | `Expanded
]
Sourceval font_stretch_kws : font_stretch_kw list
Sourcetype font_stretch = [
  1. | font_stretch_kw
  2. | percentage
]
Sourceval string_of_font_stretch : font_stretch -> string
Sourceval pp_font_stretch : Format.formatter -> font_stretch -> unit
Sourcetype font_style_kw = [
  1. | `Normal
  2. | `Italic
]
Sourceval font_style_kws : font_style_kw list
Sourcetype font_style = [
  1. | font_style_kw
  2. | `Oblique of angle option
]
Sourceval string_of_font_style : font_style -> string
Sourceval pp_font_style : Format.formatter -> font_style -> unit
Sourcetype font_variant_alt = [
  1. | `Historical_forms
  2. | `Stylistic of string
  3. | `Styleset of string list
  4. | `Character_variant of string list
  5. | `Swash of string
  6. | `Ornaments of string
  7. | `Annotation of string
]
Sourceval string_of_font_variant_alt : [< `Annotation of string | `Character_variant of string list | `Historical_forms | `Ornaments of string | `Styleset of string list | `Stylistic of string | `Swash of string ] -> string
Sourcetype font_variant_alternates = [
  1. | `Normal
  2. | `List of font_variant_alt list
]
Sourceval string_of_font_variant_alternates : font_variant_alternates -> string
Sourceval pp_font_variant_alternates : Format.formatter -> font_variant_alternates -> unit
Sourcetype font_variant_caps = [
  1. | `Normal
  2. | `Small_caps
  3. | `All_small_caps
  4. | `Petite_caps
  5. | `All_petite_caps
  6. | `Unicase
  7. | `Titling_caps
]
Sourceval font_variant_caps_kws : font_variant_caps list
Sourceval string_of_font_variant_caps : font_variant_caps -> string
Sourceval pp_font_variant_caps : Format.formatter -> font_variant_caps -> unit
Sourcetype font_variant_east_asian_kw = [
  1. | `Jis78
  2. | `Jis83
  3. | `Jis90
  4. | `Jis04
  5. | `Ruby
  6. | `Proportional_width
  7. | `Simplified
  8. | `Traditional
  9. | `Full_width
]
Sourceval font_variant_east_asian_kws : font_variant_east_asian_kw list
Sourcetype font_variant_east_asian = [
  1. | `Normal
  2. | `List of font_variant_east_asian_kw list
]
Sourceval string_of_font_variant_east_asian : font_variant_east_asian -> string
Sourceval pp_font_variant_east_asian : Format.formatter -> font_variant_east_asian -> unit
Sourcetype font_variant_emoji = [
  1. | `Normal
  2. | `Text
  3. | `Emoji
  4. | `Unicode
]
Sourceval font_variant_emoji_kws : font_variant_emoji list
Sourceval string_of_font_variant_emoji : font_variant_emoji -> string
Sourceval pp_font_variant_emoji : Format.formatter -> font_variant_emoji -> unit
Sourcetype font_variant_ligatures_kw = [
  1. | `Common_ligatures
  2. | `No_common_ligatures
  3. | `Contextual
  4. | `No_contextual
  5. | `Discretionary_ligatures
  6. | `No_discretionary_ligatures
  7. | `Historical_ligatures
  8. | `No_historical_ligatures
]
Sourceval font_variant_ligatures_kws : [> `Common_ligatures | `Contextual | `Discretionary_ligatures | `Historical_ligatures | `No_common_ligatures | `No_contextual | `No_discretionary_ligatures | `No_historical_ligatures ] list
Sourcetype font_variant_ligatures = [
  1. | `Normal
  2. | `None
  3. | `List of font_variant_ligatures_kw list
]
Sourceval string_of_font_variant_ligatures : font_variant_ligatures -> string
Sourceval pp_font_variant_ligatures : Format.formatter -> font_variant_ligatures -> unit
Sourcetype font_variant_numeric_kw = [
  1. | `Ordinal
  2. | `Slashed_zero
  3. | `Lining_nums
  4. | `Oldstyle_nums
  5. | `Proportional_nums
  6. | `Tabular_nums
  7. | `Diagonal_frations
  8. | `Stacked_fractions
]
Sourceval font_variant_numeric_kws : [> `Diagonal_frations | `Lining_nums | `Oldstyle_nums | `Ordinal | `Proportional_nums | `Slashed_zero | `Stacked_fractions | `Tabular_nums ] list
Sourcetype font_variant_numeric = [
  1. | `Normal
  2. | `List of font_variant_numeric_kw list
]
Sourceval string_of_font_variant_numeric : font_variant_numeric -> string
Sourceval pp_font_variant_numeric : Format.formatter -> font_variant_numeric -> unit
Sourcetype font_variant_position = [
  1. | `Normal
  2. | `Sub
  3. | `Super
]
Sourceval font_variant_position_kws : font_variant_position list
Sourceval string_of_font_variant_position : font_variant_position -> string
Sourceval pp_font_variant_position : Format.formatter -> font_variant_position -> unit
Sourcetype font_weight_kw = [
  1. | `Normal
  2. | `Bold
  3. | `Bolder
  4. | `Lighter
]
Sourceval font_weight_kws : [> `Bold | `Bolder | `Lighter | `Normal ] list
Sourcetype font_weight = [
  1. | font_weight_kw
  2. | `Weight of int
]
Sourceval string_of_font_weight : font_weight -> string
Sourceval pp_font_weight : Format.formatter -> font_weight -> unit
Sourcetype line_height_kw = [
  1. | `Normal
]
Sourceval line_height_kws : line_height_kw list
Sourcetype line_height = [
  1. | line_height_kw
  2. | `Number of number
  3. | length_percentage
]
Sourceval string_of_line_height : line_height -> string
Sourceval pp_line_height : Format.formatter -> line_height -> unit
Sourcetype system_font = {
  1. family : font_family_ list;
  2. size : font_size;
  3. stretch : font_stretch;
  4. style : font_style;
  5. variant_alternates : font_variant_alternates;
  6. variant_caps : font_variant_caps;
  7. variant_east_asian : font_variant_east_asian;
  8. variant_emoji : font_variant_emoji;
  9. variant_ligatures : font_variant_ligatures;
  10. variant_numeric : font_variant_numeric;
  11. variant_position : font_variant_position;
  12. weight : font_weight;
  13. line_height : line_height;
}
Sourceval system_font : ?stretch:font_stretch -> ?style:font_style -> ?variant_alternates:font_variant_alternates -> ?variant_caps:font_variant_caps -> ?variant_east_asian:font_variant_east_asian -> ?variant_emoji:font_variant_emoji -> ?variant_ligatures:font_variant_ligatures -> ?variant_numeric:font_variant_numeric -> ?variant_position:font_variant_position -> ?weight:font_weight -> ?line_height:line_height -> font_size -> font_family_ list -> system_font
Sourcetype system_font_name = [
  1. | `Caption
  2. | `Icon
  3. | `Menu
  4. | `Message_box
  5. | `Small_caption
  6. | `Status_bar
]
Sourceval system_font_names : system_font_name list
Sourcemodule Sys_font_map : sig ... end
Sourceval system_fonts_r : system_font Sys_font_map.t ref
Sourceval set_system_font : Sys_font_map.key -> system_font -> unit
Sourceval get_system_font : Sys_font_map.key -> system_font option
Sourceval font_variant_css2 : [> `Normal | `Small_caps ] list
Sourceval font_stretch_css3 : font_stretch_kw list
Sourcetype justify_content_kw = [
  1. | `Normal
]
Sourceval justify_content_kws : justify_content_kw list
Sourcetype justify_content = [
  1. | justify_content_kw
  2. | content_distribution
  3. | content_position_lr
  4. | `Safe_pos_lr of content_position_lr
  5. | `Unsafe_pos_lr of content_position_lr
]
Sourceval string_of_justify_content : justify_content -> string
Sourceval pp_justify_content : Format.formatter -> justify_content -> unit
Sourcetype height = size
Sourceval string_of_height : size -> string
Sourceval pp_height : Format.formatter -> size -> unit
Sourcetype justify_items_kw = [
  1. | `Normal
  2. | `Stretch
  3. | `Legacy
]
Sourceval justify_items_kws : justify_items_kw list
Sourcetype justify_items = [
  1. | baseline_position
  2. | self_position_lr
  3. | `Safe_self_pos_lr of self_position_lr
  4. | `Unsafe_self_pos_lr of self_position_lr
  5. | `Legacy_lcr of [ `Left | `Center | `Right ]
  6. | justify_items_kw
]
Sourceval string_of_justify_items : justify_items -> string
Sourceval pp_justify_items : Format.formatter -> justify_items -> unit
Sourcetype justify_self_kw = [
  1. | `Normal
  2. | `Stretch
  3. | `Auto
]
Sourceval justify_self_kws : justify_self_kw list
Sourcetype justify_self = [
  1. | baseline_position
  2. | self_position_lr
  3. | `Safe_self_pos_lr of self_position_lr
  4. | `Unsafe_self_pos_lr of self_position_lr
  5. | `Legacy_lcr of [ `Left | `Center | `Right ]
  6. | justify_self_kw
]
Sourceval string_of_justify_self : justify_self -> string
Sourceval pp_justify_self : Format.formatter -> justify_self -> unit
Sourcetype list_style_image_kw = [
  1. | `None
]
Sourceval list_style_image_kws : list_style_image_kw list
Sourcetype list_style_image = [
  1. | `Image of image
  2. | list_style_image_kw
]
Sourceval string_of_list_style_image : list_style_image -> string
Sourceval pp_list_style_image : Format.formatter -> list_style_image -> unit
Sourcetype list_style_position_kw = [
  1. | `Inside
  2. | `Outside
]
Sourceval list_style_position_kws : list_style_position_kw list
Sourcetype list_style_position = list_style_position_kw
Sourceval string_of_list_style_position : list_style_position -> string
Sourceval pp_list_style_position : Format.formatter -> list_style_position -> unit
Sourcetype list_style_type_kw = [
  1. | `None
]
Sourceval list_style_type_kws : list_style_type_kw list
Sourcetype list_style_type = [
  1. | list_style_type_kw
  2. | `Ident_ of string
  3. | `String_ of string
  4. | `Symbols_ of string
]
Sourceval string_of_list_style_type : list_style_type -> string
Sourceval pp_list_style_type : Format.formatter -> list_style_type -> unit
Sourcetype margin_kw = [
  1. | `Auto
]
Sourceval margin_kws : margin_kw list
Sourcetype margin = [
  1. | margin_kw
  2. | length_percentage
]
Sourceval string_of_margin : margin -> string
Sourceval pp_margin : Format.formatter -> margin -> unit
Sourceval string_of_padding : padding -> string
Sourceval pp_padding : Format.formatter -> padding -> unit
Sourcetype position_kw = [
  1. | `Static
  2. | `Relative
  3. | `Absolute
  4. | `Sticky
  5. | `Fixed
]
Sourceval position_kws : position_kw list
Sourcetype position = position_kw
Sourceval string_of_position : position -> string
Sourceval pp_position : Format.formatter -> position -> unit
Sourcetype text_align_kw = [
  1. | `Start
  2. | `End
  3. | `Left
  4. | `Right
  5. | `Center
  6. | `Justify
  7. | `Justify_all
  8. | `Match_parent
]
Sourceval text_align_kws : text_align_kw list
Sourcetype text_align = text_align_kw
Sourceval string_of_text_align : text_align -> string
Sourceval pp_text_align : Format.formatter -> text_align -> unit
Sourcetype text_align_last_kw = [
  1. | `Auto
  2. | `Start
  3. | `End
  4. | `Left
  5. | `Right
  6. | `Center
  7. | `Justify
  8. | `Match_parent
]
Sourceval text_align_last_kws : text_align_last_kw list
Sourcetype text_align_last = text_align_last_kw
Sourceval string_of_text_align_last : text_align_last -> string
Sourceval pp_text_align_last : Format.formatter -> text_align_last -> unit
Sourcetype vertical_align_kw = [
  1. | `Baseline
  2. | `Sub
  3. | `Super
  4. | `Top
  5. | `Text_top
  6. | `Middle
  7. | `Bottom
  8. | `Text_bottom
]
Sourceval vertical_align_kws : vertical_align_kw list
Sourcetype vertical_align = [
  1. | vertical_align_kw
  2. | length_percentage
]
Sourceval string_of_vertical_align : vertical_align -> string
Sourceval pp_vertical_align : Format.formatter -> vertical_align -> unit
Sourcetype visibility_kw = [
  1. | `Visible
  2. | `Hidden
  3. | `Collapse
]
Sourceval visibility_kws : visibility_kw list
Sourcetype visibility = visibility_kw
Sourceval string_of_visibility : visibility -> string
Sourceval pp_visibilty : Format.formatter -> visibility -> unit
Sourcetype white_space_kw = [
  1. | `Normal
  2. | `Nowrap
  3. | `Pre
  4. | `Pre_wrap
  5. | `Pre_line
  6. | `Break_spaces
]
Sourceval white_space_kws : white_space_kw list
Sourcetype white_space = white_space_kw
Sourceval string_of_white_space : white_space -> string
Sourceval pp_white_space : Format.formatter -> white_space -> unit
Sourcetype word_spacing_kw = [
  1. | `Normal
]
Sourceval word_spacing_kws : word_spacing_kw list
Sourcetype word_spacing = [
  1. | word_spacing_kw
  2. | `Length of number * length_unit
]
Sourceval string_of_word_spacing : word_spacing -> string
Sourceval pp_word_spacing : Format.formatter -> word_spacing -> unit
OCaml

Innovation. Community. Security.