Class: Hokusai::Commands::SVG
- Defined in:
- ui/src/hokusai/commands/image.rb
Instance Attribute Summary collapse
-
#color ⇒ Object
Returns the value of attribute color.
-
#height ⇒ Object
readonly
Returns the value of attribute height.
-
#source ⇒ Object
readonly
Returns the value of attribute source.
-
#width ⇒ Object
readonly
Returns the value of attribute width.
-
#x ⇒ Object
readonly
Returns the value of attribute x.
-
#y ⇒ Object
readonly
Returns the value of attribute y.
Instance Method Summary collapse
-
#initialize(source, x, y, width, height) ⇒ SVG
constructor
A new instance of SVG.
Methods inherited from Base
#after_draw, draw, #draw, on_draw
Constructor Details
#initialize(source, x, y, width, height) ⇒ SVG
Returns a new instance of SVG.
25 26 27 28 29 30 31 32 |
# File 'ui/src/hokusai/commands/image.rb', line 25 def initialize(source, x, y, width, height) @source = source @x = x @y = y @width = width @height = height @color = Color.new(255, 255, 255, 255) end |
Instance Attribute Details
#color ⇒ Object
Returns the value of attribute color.
23 24 25 |
# File 'ui/src/hokusai/commands/image.rb', line 23 def color @color end |
#height ⇒ Object (readonly)
Returns the value of attribute height.
23 24 25 |
# File 'ui/src/hokusai/commands/image.rb', line 23 def height @height end |
#source ⇒ Object (readonly)
Returns the value of attribute source.
23 24 25 |
# File 'ui/src/hokusai/commands/image.rb', line 23 def source @source end |
#width ⇒ Object (readonly)
Returns the value of attribute width.
23 24 25 |
# File 'ui/src/hokusai/commands/image.rb', line 23 def width @width end |
#x ⇒ Object (readonly)
Returns the value of attribute x.
23 24 25 |
# File 'ui/src/hokusai/commands/image.rb', line 23 def x @x end |
#y ⇒ Object (readonly)
Returns the value of attribute y.
23 24 25 |
# File 'ui/src/hokusai/commands/image.rb', line 23 def y @y end |