class Xlsxrb::ReturnedStyleBuilder
What style returns in the 0.2 series, in place of the definition it records. It forwards every public method to that definition, so changes still reach it, and warns on first use at the caller’s line.
@deprecated Configure a style with options or in the block given to style. In version
0.3.0, +style+ will return nil (ADR 0010).
Constants
- DEPRECATION_MESSAGE
Public Class Methods
(StyleBuilder definition) → void
Source
# File lib/xlsxrb/style_builder.rb, line 1319 def initialize(definition) # rubocop:disable Lint/MissingSuper @definition = definition @warned = false end
@api private
Public Instance Methods
() → (String | Symbol | nil)
Source
# File lib/xlsxrb/style_builder.rb, line 1498 def align_horizontal = definition_for_use.align_horizontal
(String | Symbol value) → (String | Symbol)
Source
# File lib/xlsxrb/style_builder.rb, line 1501 def align_horizontal=(value) definition_for_use.align_horizontal = value end
() → (String | Symbol | nil)
Source
# File lib/xlsxrb/style_builder.rb, line 1506 def align_vertical = definition_for_use.align_vertical
(String | Symbol value) → (String | Symbol)
Source
# File lib/xlsxrb/style_builder.rb, line 1509 def align_vertical=(value) definition_for_use.align_vertical = value end
(?horizontal: (String | Symbol)?, ?vertical: (String | Symbol)?, ?wrap_text: bool?, ?text_rotation: Integer?, ?indent: Integer?, ?shrink_to_fit: bool?, ?reading_order: Integer?, ?justify_last_line: bool?, ?relative_indent: Integer?) → void
Source
# File lib/xlsxrb/style_builder.rb, line 1490 def alignment(...) = definition_for_use.alignment(...)
(Hash[Symbol, untyped] opts) → Hash[Symbol, untyped]
Source
# File lib/xlsxrb/style_builder.rb, line 1493 def alignment=(opts) definition_for_use.alignment = opts end
(**untyped) → self
Source
# File lib/xlsxrb/style_builder.rb, line 1340 def apply_options!(**opts) definition_for_use.apply_options!(**opts) self end
(bool value) → bool
Source
# File lib/xlsxrb/style_builder.rb, line 1354 def bold=(value) definition_for_use.bold = value end
() → bool
Source
# File lib/xlsxrb/style_builder.rb, line 1359 def bold? = definition_for_use.bold?
(?all: Hash[Symbol, untyped]?, ?left: Hash[Symbol, untyped]?, ?right: Hash[Symbol, untyped]?, ?top: Hash[Symbol, untyped]?, ?bottom: Hash[Symbol, untyped]?, ?diagonal: Hash[Symbol, untyped]?) → void
Source
# File lib/xlsxrb/style_builder.rb, line 1464 def border(...) = definition_for_use.border(...)
(Hash[Symbol, untyped] opts) → Hash[Symbol, untyped]
Source
# File lib/xlsxrb/style_builder.rb, line 1467 def border=(opts) definition_for_use.border = opts end
(?style: String | Symbol | Integer, ?color: String | Symbol | nil) → void
Source
# File lib/xlsxrb/style_builder.rb, line 1472 def border_all(...) = definition_for_use.border_all(...)
(?style: String | Symbol | Integer, ?color: String | Symbol | nil) → void
Source
# File lib/xlsxrb/style_builder.rb, line 1484 def border_bottom(...) = definition_for_use.border_bottom(...)
(?style: String | Symbol | Integer, ?color: String | Symbol | nil, ?up: bool, ?down: bool) → void
Source
# File lib/xlsxrb/style_builder.rb, line 1487 def border_diagonal(...) = definition_for_use.border_diagonal(...)
(?style: String | Symbol | Integer, ?color: String | Symbol | nil) → void
Source
# File lib/xlsxrb/style_builder.rb, line 1475 def border_left(...) = definition_for_use.border_left(...)
() → Hash[Symbol, untyped]
Source
# File lib/xlsxrb/style_builder.rb, line 1334 def border_props = definition_for_use.border_props
(?style: String | Symbol | Integer, ?color: String | Symbol | nil) → void
Source
# File lib/xlsxrb/style_builder.rb, line 1478 def border_right(...) = definition_for_use.border_right(...)
(?style: String | Symbol | Integer, ?color: String | Symbol | nil) → void
Source
# File lib/xlsxrb/style_builder.rb, line 1481 def border_top(...) = definition_for_use.border_top(...)
(?pattern: untyped, ?fg_color: String | Symbol | nil, ?bg_color: String | Symbol | nil) → void
Source
# File lib/xlsxrb/style_builder.rb, line 1453 def fill(...) = definition_for_use.fill(...)
(untyped opts) → untyped
Source
# File lib/xlsxrb/style_builder.rb, line 1456 def fill=(opts) definition_for_use.fill = opts end
() → String?
Source
# File lib/xlsxrb/style_builder.rb, line 1445 def fill_color = definition_for_use.fill_color
(String | Symbol color) → (String | Symbol)
Source
# File lib/xlsxrb/style_builder.rb, line 1448 def fill_color=(color) definition_for_use.fill_color = color end
(?type: untyped, ?degree: Numeric | nil, ?stops: Array[untyped]?) → void
Source
# File lib/xlsxrb/style_builder.rb, line 1461 def fill_gradient(...) = definition_for_use.fill_gradient(...)
(?untyped pattern, ?fg_color: String | Symbol | nil, ?bg_color: String | Symbol | nil) → void
Source
# File lib/xlsxrb/style_builder.rb, line 1437 def fill_pattern(...) = definition_for_use.fill_pattern(...)
(untyped pattern) → untyped
Source
# File lib/xlsxrb/style_builder.rb, line 1440 def fill_pattern=(pattern) definition_for_use.fill_pattern = pattern end
() → Hash[Symbol, untyped]
Source
# File lib/xlsxrb/style_builder.rb, line 1331 def fill_props = definition_for_use.fill_props
(**untyped) → void
Source
# File lib/xlsxrb/style_builder.rb, line 1346 def font(**opts) = definition_for_use.font(**opts)
(Hash[Symbol, untyped] opts) → Hash[Symbol, untyped]
Source
# File lib/xlsxrb/style_builder.rb, line 1349 def font=(opts) definition_for_use.font = opts end
() → String?
Source
# File lib/xlsxrb/style_builder.rb, line 1386 def font_color = definition_for_use.font_color
(String | Symbol color) → (String | Symbol)
Source
# File lib/xlsxrb/style_builder.rb, line 1389 def font_color=(color) definition_for_use.font_color = color end
() → String?
Source
# File lib/xlsxrb/style_builder.rb, line 1378 def font_name = definition_for_use.font_name
(String name) → String
Source
# File lib/xlsxrb/style_builder.rb, line 1381 def font_name=(name) definition_for_use.font_name = name end
() → Hash[Symbol, untyped]
Source
# File lib/xlsxrb/style_builder.rb, line 1328 def font_props = definition_for_use.font_props
() → (Integer | Float | nil)
Source
# File lib/xlsxrb/style_builder.rb, line 1370 def font_size = definition_for_use.font_size
(Numeric size_value) → Numeric
Source
# File lib/xlsxrb/style_builder.rb, line 1373 def font_size=(size_value) definition_for_use.font_size = size_value end
() → (Integer | nil)
Source
# File lib/xlsxrb/style_builder.rb, line 1538 def indent = definition_for_use.indent
(Numeric value) → Numeric
Source
# File lib/xlsxrb/style_builder.rb, line 1541 def indent=(value) definition_for_use.indent = value end
(bool value) → bool
Source
# File lib/xlsxrb/style_builder.rb, line 1362 def italic=(value) definition_for_use.italic = value end
() → bool
Source
# File lib/xlsxrb/style_builder.rb, line 1367 def italic? = definition_for_use.italic?
(bool value) → bool
Source
# File lib/xlsxrb/style_builder.rb, line 1554 def locked=(value) definition_for_use.locked = value end
() → bool
Source
# File lib/xlsxrb/style_builder.rb, line 1559 def locked? = definition_for_use.locked?
() → (String | Symbol)?
Source
# File lib/xlsxrb/style_builder.rb, line 1325 def name = definition_for_use.name
() → (String | Integer | nil)
Source
# File lib/xlsxrb/style_builder.rb, line 1570 def number_format = definition_for_use.number_format
(String | Integer num_fmt_id) → (String | Integer)
Source
# File lib/xlsxrb/style_builder.rb, line 1573 def number_format=(num_fmt_id) definition_for_use.number_format = num_fmt_id end
(?locked: bool?, ?hidden: bool?) → void
Source
# File lib/xlsxrb/style_builder.rb, line 1546 def protection(...) = definition_for_use.protection(...)
(Hash[Symbol, untyped] opts) → Hash[Symbol, untyped]
Source
# File lib/xlsxrb/style_builder.rb, line 1549 def protection=(opts) definition_for_use.protection = opts end
(untyped writer) → Integer
Source
# File lib/xlsxrb/style_builder.rb, line 1578 def register_with(writer) = definition_for_use.register_with(writer)
(StyleBuilder other) → bool
Source
# File lib/xlsxrb/style_builder.rb, line 1581 def same_format?(other) = definition_for_use.same_format?(other)
(bool value) → bool
Source
# File lib/xlsxrb/style_builder.rb, line 1522 def shrink_to_fit=(value) definition_for_use.shrink_to_fit = value end
() → bool
Source
# File lib/xlsxrb/style_builder.rb, line 1527 def shrink_to_fit? = definition_for_use.shrink_to_fit?
(bool value) → bool
Source
# File lib/xlsxrb/style_builder.rb, line 1405 def strike=(value) definition_for_use.strike = value end
() → bool
Source
# File lib/xlsxrb/style_builder.rb, line 1410 def strike? = definition_for_use.strike?
(untyped val) → untyped
Source
# File lib/xlsxrb/style_builder.rb, line 1429 def subscript=(val) definition_for_use.subscript = val end
() → bool
Source
# File lib/xlsxrb/style_builder.rb, line 1434 def subscript? = definition_for_use.subscript?
(untyped val) → untyped
Source
# File lib/xlsxrb/style_builder.rb, line 1421 def superscript=(val) definition_for_use.superscript = val end
() → bool
Source
# File lib/xlsxrb/style_builder.rb, line 1426 def superscript? = definition_for_use.superscript?
() → (Numeric | nil)
Source
# File lib/xlsxrb/style_builder.rb, line 1530 def text_rotation = definition_for_use.text_rotation
(Numeric value) → Numeric
Source
# File lib/xlsxrb/style_builder.rb, line 1533 def text_rotation=(value) definition_for_use.text_rotation = value end
() → (String | Symbol | bool | nil)
Source
# File lib/xlsxrb/style_builder.rb, line 1394 def underline = definition_for_use.underline
(String | Symbol | bool val) → (String | Symbol | bool)
Source
# File lib/xlsxrb/style_builder.rb, line 1397 def underline=(val) definition_for_use.underline = val end
() → bool
Source
# File lib/xlsxrb/style_builder.rb, line 1402 def underline? = definition_for_use.underline?
() → String?
Source
# File lib/xlsxrb/style_builder.rb, line 1413 def vert_align = definition_for_use.vert_align
(untyped val) → untyped
Source
# File lib/xlsxrb/style_builder.rb, line 1416 def vert_align=(val) definition_for_use.vert_align = val end
(String name, String | Integer number_format) → StyleBuilder
Source
# File lib/xlsxrb/style_builder.rb, line 1337 def with_number_format(name, number_format) = definition_for_use.with_number_format(name, number_format)
(bool value) → bool
Source
# File lib/xlsxrb/style_builder.rb, line 1514 def wrap_text=(value) definition_for_use.wrap_text = value end
() → bool
Source
# File lib/xlsxrb/style_builder.rb, line 1519 def wrap_text? = definition_for_use.wrap_text?
Protected Instance Methods
() → Array[untyped]
Source
# File lib/xlsxrb/style_builder.rb, line 1587 def format_signature = @definition.format_signature
Lets StyleBuilder#same_format? compare with the definition without a warning.