Class: NumPlot::Font
- Inherits:
-
Object
- Object
- NumPlot::Font
- Defined in:
- lib/numplot.rb
Overview
The class representing a font in gnuplot.
Example:
Font["ariel"] # ariel font, default size
Font["ariel", 12] # ariel font, the size is 12 point
Class Method Summary collapse
-
.[](fontname, size = nil) ⇒ Font
Create a new Font object.
Instance Method Summary collapse
-
#initialize(fontname, size = nil) ⇒ Font
constructor
Create a new Font object.
Constructor Details
#initialize(fontname, size = nil) ⇒ Font
Create a new Font object.
135 136 137 |
# File 'lib/numplot.rb', line 135 def initialize(fontname, size=nil) @s = size ? "#{fontname},#{size}" : fontname end |
Class Method Details
.[](fontname, size = nil) ⇒ Font
Create a new Font object. See #initialize.
149 |
# File 'lib/numplot.rb', line 149 __yard_ignore_here{ alias [] new } |