# File pango/test/test-layout.rb, line 4 def setup @context = Pango::Context.new @layout = Pango::Layout.new(@context) end
# File pango/test/test-layout.rb, line 31 def test_ellipsized? assert_false(@layout.ellipsized?) end
# File pango/test/test-layout.rb, line 21 def test_height assert_equal(-1, @layout.height) end
# File pango/test/test-layout.rb, line 9 def test_set_font_description assert_nil(@layout.font_description) @layout.font_description = "sans 14" assert_equal("sans 14", @layout.font_description.to_s) description = Pango::FontDescription.new("monospace") description.size = 10 * Pango::SCALE @layout.font_description = description assert_equal("monospace 10", @layout.font_description.to_s) end
# File pango/test/test-layout.rb, line 25 def test_set_height new_height = 29 * Pango::SCALE @layout.height = new_height assert_equal(new_height, @layout.height) end