Class: Rust::Plots::Grid

Inherits:
Renderable show all
Defined in:
lib/rust-plots.rb

Instance Method Summary collapse

Methods inherited from Renderable

#[]=

Constructor Details

#initializeGrid

Returns a new instance of Grid.



370
371
372
373
374
375
# File 'lib/rust-plots.rb', line 370

def initialize
    super()
    
    @x = Float::NAN
    @y = Float::NAN
end

Instance Method Details

#_renderObject



413
414
415
416
417
418
419
420
421
422
423
# File 'lib/rust-plots.rb', line 413

def _render()
    function = Rust::Function.new("grid")
    
    function.arguments << @x
    function.arguments << @y
    function.options = @options
    
    function.call
    
    return self
end

#auto_xObject



389
390
391
392
393
# File 'lib/rust-plots.rb', line 389

def auto_x
    @x = nil
    
    return self
end

#auto_yObject



395
396
397
398
399
# File 'lib/rust-plots.rb', line 395

def auto_y
    @y = nil
    
    return self
end

#hide_xObject



401
402
403
404
405
# File 'lib/rust-plots.rb', line 401

def hide_x
    @x = Float::NAN
    
    return self
end

#hide_yObject



407
408
409
410
411
# File 'lib/rust-plots.rb', line 407

def hide_y
    @y = Float::NAN
    
    return self
end

#x(value) ⇒ Object



377
378
379
380
381
# File 'lib/rust-plots.rb', line 377

def x(value)
    @x = value
    
    return self
end

#y(value) ⇒ Object



383
384
385
386
387
# File 'lib/rust-plots.rb', line 383

def y(value)
    @y = value
    
    return self
end