Novis\Spreadsheet\Style
A set of style fields for a cell, a row, a column or a header row. Make one with Style::of. A cell uses each field from its own style first, then from its row, then from its column.
Members
2 members.
| Member | Signature |
|---|---|
constructor | constructor(Record $fields, string $key): void |
of | of(Fields $fields): Style |
Enums
Line { Thin, Medium, Thick, Dashed, Dotted, Double }The kind of line a border has.Underline { Single, Double }One or two lines under the text.Align { Left, Center, Right, Fill, Justify }Where the text of a cell is placed from left to right. WithFill, Excel repeats the text until the cell is full. WithJustify, Excel spreads the words of a text with several lines across the full width of the cell.Valign { Top, Center, Bottom }Where the text sits from top to bottom in its cell.
Types
Lines
Fields
type Fields = { font?: string, size?: float, bold?: bool, italic?: bool, strike?: bool, underline?: bool | string, color?: string, fill?: string, border?: string | Lines, borderColor?: string, align?: string, valign?: string, wrap?: bool, rotate?: int, indent?: uint, format?: string, locked?: bool, hideFormula?: bool,};Record
type Record = { font: ?string, size: ?float, bold: ?bool, italic: ?bool, strike: ?bool, underline: ?Underline, color: ?string, fill: ?string, border: ?{ top: ?Line, right: ?Line, bottom: ?Line, left: ?Line }, borderColor: ?string, align: ?Align, valign: ?Valign, wrap: ?bool, rotate: ?int, indent: ?uint, format: ?string, locked: ?bool, hideFormula: ?bool,};Properties
$style->fieldsRecordthe style fields, withnullfor each field the style does not set$style->keystringa text made from the fields. Two styles with equal fields have the samekey.
