samples/text/_text.rb in squib-0.9.0 vs samples/text/_text.rb in squib-0.10.0

- old
+ new

@@ -1,14 +1,15 @@ require 'squib' require 'squib/sample_helpers' -Squib::Deck.new(width: 1000, height: 2000) do +Squib::Deck.new(width: 1000, height: 1250) do draw_graph_paper width, height - sample 'Font strings are quite expressive. Specify family, modifiers, then size. Font names with spaces in them should also have a backup afterward to help with parsing.' do |x, y| + sample 'Font strings are quite expressive. Specify family, modifiers, then size. Font names with spaces in them should end with a comma to help with parsing.' do |x, y| text font: 'Arial bold italic 32', str: 'Bold and italic!', x: x, y: y - 50 text font: 'Arial weight=300 32', str: 'Light bold!', x: x, y: y - text font: 'Times New Roman,Arial 32', str: 'Times New Roman', x: x, y: y + 50 + text font: 'Times New Roman, 32', str: 'Times New Roman', x: x, y: y + 50 + text font: 'NoSuchFont,Arial 32', str: 'Arial Backup', x: x, y: y + 100 end sample 'Specify width and height to see a text box. Also: set "hint" to see the extents of your text box' do |x, y| text str: 'This has fixed width and height.', x: x, y: y, hint: :red, width: 300, height: 100, font: 'Serif bold 24'