Method: PostRunner::ViewFrame#initialize

Defined in:
lib/postrunner/ViewFrame.rb

#initialize(title, width = 600, content = nil, &block) ⇒ ViewFrame

Create a ViewFrame object.

Parameters:

  • title (String)

    Title/heading of the framed box

  • width (Fixnum or nil) (defaults to: 600)

    Width of the frame. Use nil to set no width.

  • content (Any object that respons to to_html) (defaults to: nil)

    Object to frame

  • &block (HTMLBuilder actions)


24
25
26
27
28
29
# File 'lib/postrunner/ViewFrame.rb', line 24

def initialize(title, width = 600, content = nil, &block)
  @title = title
  @content = content
  @block = block
  @width = width
end