Sha256: 2a97ea2babb173be70ede25a17bfd4f0847508d9375f5ea4f6d7ce641a858e9a
Contents?: true
Size: 1.09 KB
Versions: 3
Compression:
Stored size: 1.09 KB
Contents
@default_headline_line_color ||= "#ff9933" match(Slide) do |slides| slides.each do |slide| slide.margin_set(@margin_top, @margin_right, @margin_bottom, @margin_left) end end match(Slide, HeadLine) do |headlines| name = "head-line" delete_post_draw_proc_by_name(name) space = @space / 2.0 margin_with(:bottom => space * 3) add_post_draw_proc(name) do |text, canvas, x, y, w, h, simulation| unless simulation canvas.draw_line(x, y + space, x + w, y + space, @default_headline_line_color) end [x, y, w, h] end headlines.each do |headline| slide = headline.slide headline.hide if slide.hide_title? color = slide["headline-color"] headline.prop_set("foreground", color) if color shadow_color = slide["headline-shadow-color"] headline["shadow-color"] = shadow_color if shadow_color end end match(Slide, Body) do |bodies| bodies.each do |body| unless body.elements.any? {|element| element.is_a?(Image)} body.margin_with(:left => @body_margin_left, :right => @body_margin_right) end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
rabbit-0.9.1 | lib/rabbit/theme/default-slide/default-slide.rb |
rabbit-0.9.0 | lib/rabbit/theme/default-slide/default-slide.rb |
rabbit-0.6.4 | lib/rabbit/theme/default-slide/default-slide.rb |