Sha256: 4b8621b4d395f31a5145463ceca9dc734409bc79210c2c2e3c8db9f1eff84bdf

Contents?: true

Size: 523 Bytes

Versions: 3

Compression:

Stored size: 523 Bytes

Contents

class RecordingSurfaceTest < Test::Unit::TestCase
  include CairoTestUtils

  def setup
    only_surface("Recording")
  end

  def test_new
    only_not_windows
    only_cairo_version(1, 12, 0)
    surface = Cairo::RecordingSurface.new(10, 20, 300, 400)
    assert_equal([0.0, 0.0, 0.0, 0.0], surface.ink_extents)
    Cairo::Context.new(surface) do |context|
      context.move_to(15, 30)
      context.line_to(80, 100)
      context.stroke
    end
    assert_equal([10.0, 20.0, 61.0, 61.0], surface.ink_extents)
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
cairo-1.15.10-x86-mingw32 test/test_recording_surface.rb
cairo-1.15.10-x64-mingw32 test/test_recording_surface.rb
cairo-1.15.10 test/test_recording_surface.rb