Module: Sevgi::Graphics::Mixtures::Symbols
- Defined in:
- lib/sevgi/graphics/mixtures/symbols.rb
Overview
DSL helpers for expanding callable modules into SVG symbols.
Instance Method Summary collapse
-
#Symbols(mod, *args, attributes: {}, ids: nil, **kwargs) { ... } ⇒ Sevgi::Graphics::Element
Renders module callables as symbols under defs.
Instance Method Details
#Symbols(mod, *args, attributes: {}, ids: nil, **kwargs) { ... } ⇒ Sevgi::Graphics::Element
Renders module callables as symbols under defs. Named modules default the defs id to their final constant name; anonymous modules omit the id unless supplied. Base blocks run once in the defs element before symbols are created. Positional arguments, keyword arguments, and the block are forwarded to each callable.
89 90 91 |
# File 'lib/sevgi/graphics/mixtures/symbols.rb', line 89 def Symbols(mod, *args, attributes: {}, ids: nil, **kwargs, &block) Expansion.new(self, mod).call(*args, attributes:, ids:, **kwargs, &block) end |