Module: Ruby2D::DSL

Defined in:
lib/ruby2d/dsl.rb

Overview

Ruby2D::DSL

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.windowObject



7
# File 'lib/ruby2d/dsl.rb', line 7

def self.window; @window end

.window=(w) ⇒ Object



8
# File 'lib/ruby2d/dsl.rb', line 8

def self.window=(w); @window = w end

Instance Method Details

#clearObject



34
35
36
# File 'lib/ruby2d/dsl.rb', line 34

def clear
  DSL.window.clear
end

#closeObject



42
43
44
# File 'lib/ruby2d/dsl.rb', line 42

def close
  DSL.window.close
end

#get(sym, opts = nil) ⇒ Object



10
11
12
# File 'lib/ruby2d/dsl.rb', line 10

def get(sym, opts = nil)
  DSL.window.get(sym, opts)
end

#off(event_descriptor) ⇒ Object



22
23
24
# File 'lib/ruby2d/dsl.rb', line 22

def off(event_descriptor)
  DSL.window.off(event_descriptor)
end

#on(event, &proc) ⇒ Object



18
19
20
# File 'lib/ruby2d/dsl.rb', line 18

def on(event, &proc)
  DSL.window.on(event, &proc)
end

#render(&proc) ⇒ Object



30
31
32
# File 'lib/ruby2d/dsl.rb', line 30

def render(&proc)
  DSL.window.render(&proc)
end

#set(opts) ⇒ Object



14
15
16
# File 'lib/ruby2d/dsl.rb', line 14

def set(opts)
  DSL.window.set(opts)
end

#showObject



38
39
40
# File 'lib/ruby2d/dsl.rb', line 38

def show
  DSL.window.show
end

#update(&proc) ⇒ Object



26
27
28
# File 'lib/ruby2d/dsl.rb', line 26

def update(&proc)
  DSL.window.update(&proc)
end