class Livetext::Functions

Find a better way to do this?

experimental…

Public Instance Methods

_var(name) click to toggle source
# File lib/liveblog.rb, line 709
def _var(name)
  ::Livetext::Vars[name] || "[:#{name} is undefined]"
end
br(n="1") click to toggle source
# File lib/liveblog.rb, line 682
def br(n="1")
  # Thought: Maybe make a way for functions to "simply" call the
  #   dot command of the same name?? Is this trivial??
  n = n.empty? ? 1 : n.to_i
  "<br>"*n
end
h1(param) click to toggle source
# File lib/liveblog.rb, line 689
def h1(param); "<h1>#{param}</h1>"; end
h2(param) click to toggle source
# File lib/liveblog.rb, line 690
def h2(param); "<h2>#{param}</h2>"; end
h3(param) click to toggle source
# File lib/liveblog.rb, line 691
def h3(param); "<h3>#{param}</h3>"; end
h4(param) click to toggle source
# File lib/liveblog.rb, line 692
def h4(param); "<h4>#{param}</h4>"; end
h5(param) click to toggle source
# File lib/liveblog.rb, line 693
def h5(param); "<h5>#{param}</h5>"; end
h6(param) click to toggle source
# File lib/liveblog.rb, line 694
def h6(param); "<h6>#{param}</h6>"; end
hr(param=nil) click to toggle source
# File lib/liveblog.rb, line 696
def hr(param=nil)
  $Dot.hr
end
image(param) click to toggle source
# File lib/liveblog.rb, line 700
def image(param)
  "<img src='#{param}'></img>"
end