Sha256: 0e57aa7f40141f55f304f34884a2b139225251233a9664e872a5e0a0932cdc1a

Contents?: true

Size: 749 Bytes

Versions: 68

Compression:

Stored size: 749 Bytes

Contents

# frozen_string_literal: true


c = circle({ height: 400, width: 200, top: 100, left:99, top: 79 })
b = c.box({ width: 200, height: 100, left: 280, top: 190, id: :my_box })
i= image(:red_planet)
c.touch(true) do
  c.fit({ value: 100, axis: :x })
end

puts '------'
puts "b.compute  left return the position on the screen of the item : #{b.compute({reference: c.id, particle: :left, metrics: :pixel})}"
puts "b.compute left : #{b.compute({ particle: :left })[:value]}, c left : #{b.left}"
puts "b.compute top :#{b.compute({ particle: :top })[:value]}, c top: #{b.top}"
puts  "i.compute width :#{i.compute({ particle: :width })[:value]}, i width: #{i.width}"
puts "i.compute height :#{i.compute({ particle: :height })[:value]}, i height: #{i.height}"

Version data entries

68 entries across 68 versions & 1 rubygems

Version Path
atome-0.5.7.0.7 vendor/assets/application/examples/compute.rb
atome-0.5.7.0.5 vendor/assets/application/examples/compute.rb
atome-0.5.7.0.4 vendor/assets/application/examples/compute.rb
atome-0.5.7.0.3 vendor/assets/application/examples/compute.rb
atome-0.5.7.0.2 vendor/assets/application/examples/compute.rb
atome-0.5.6.8.7 vendor/assets/application/examples/compute.rb
atome-0.5.6.8.6 vendor/assets/application/examples/compute.rb
atome-0.5.6.8.5 vendor/assets/application/examples/compute.rb
atome-0.5.6.8.3 vendor/assets/application/examples/compute.rb
atome-0.5.6.7.8 vendor/assets/application/examples/compute.rb
atome-0.5.6.7.7 vendor/assets/application/examples/compute.rb
atome-0.5.6.7.6 vendor/assets/application/examples/compute.rb
atome-0.5.6.7.5 vendor/assets/application/examples/compute.rb
atome-0.5.6.7.4 vendor/assets/application/examples/compute.rb
atome-0.5.6.7.3 vendor/assets/application/examples/compute.rb
atome-0.5.6.6.9 vendor/assets/application/examples/compute.rb
atome-0.5.6.6.7 vendor/assets/application/examples/compute.rb
atome-0.5.6.6.5 vendor/assets/application/examples/compute.rb
atome-0.5.6.6.1 vendor/assets/application/examples/compute.rb
atome-0.5.6.6.0 vendor/assets/application/examples/compute.rb