Module: LiteRGSS::Fonts
- Defined in:
- LiteRGSS.rb.yard.rb,
scripts/00000 Dependencies/00001 LiteRGSS2/00009 Fonts.rb
Overview
Module that holds information about text fonts.
You can define fonts loaded from a ttf file, you have to associate a default size, fill color and outline color to the font
You can define outline color and fill_color without defining a font but do not create a text with a font_id using the id of these color, it could raise an error, use load_color instead.
Class Method Summary collapse
-
.define_fill_color(font_id, color) ⇒ self
Define the fill color of a font.
-
.define_outline_color(font_id, color) ⇒ self
Define the outline color of a font.
-
.define_shadow_color(font_id, color) ⇒ self
Define the shadow color of a font (WIP).
-
.get_default_size(font_id) ⇒ Integer
Retrieve the default size of a font.
-
.get_fill_color(font_id) ⇒ Color
Retrieve the fill color of a font.
-
.get_outline_color(font_id) ⇒ Color
Retrieve the outline color of a font.
-
.get_shadow_color(font_id) ⇒ Color
Retrieve the shadow color of a font.
-
.line_height(font_id) ⇒ Integer
Get the line height for a specific font.
-
.load_font(font_id, filename) ⇒ self
Load a ttf.
-
.load_line_height(font_id, line_height)
Load a line height for a specific font.
-
.set_default_size(font_id, size) ⇒ self
Define the default size of a font.
Class Method Details
.define_fill_color(font_id, color) ⇒ self
Define the fill color of a font
777 778 779 |
# File 'LiteRGSS.rb.yard.rb', line 777 def self.define_fill_color(font_id, color) end |
.define_outline_color(font_id, color) ⇒ self
Define the outline color of a font
784 785 786 |
# File 'LiteRGSS.rb.yard.rb', line 784 def self.define_outline_color(font_id, color) end |
.define_shadow_color(font_id, color) ⇒ self
Define the shadow color of a font (WIP)
791 792 793 |
# File 'LiteRGSS.rb.yard.rb', line 791 def self.define_shadow_color(font_id, color) end |
.get_default_size(font_id) ⇒ Integer
Retrieve the default size of a font
797 798 799 |
# File 'LiteRGSS.rb.yard.rb', line 797 def self.get_default_size(font_id) end |
.get_fill_color(font_id) ⇒ Color
Retrieve the fill color of a font
803 804 805 |
# File 'LiteRGSS.rb.yard.rb', line 803 def self.get_fill_color(font_id) end |
.get_outline_color(font_id) ⇒ Color
Retrieve the outline color of a font
809 810 811 |
# File 'LiteRGSS.rb.yard.rb', line 809 def self.get_outline_color(font_id) end |
.get_shadow_color(font_id) ⇒ Color
Retrieve the shadow color of a font
815 816 817 |
# File 'LiteRGSS.rb.yard.rb', line 815 def self.get_shadow_color(font_id) end |
.line_height(font_id) ⇒ Integer
Get the line height for a specific font
17 18 19 |
# File 'scripts/00000 Dependencies/00001 LiteRGSS2/00009 Fonts.rb', line 17 def line_height(font_id) @line_heights[font_id] || 16 end |
.load_font(font_id, filename) ⇒ self
Load a ttf
763 764 765 |
# File 'LiteRGSS.rb.yard.rb', line 763 def self.load_font(font_id, filename) end |
.load_line_height(font_id, line_height)
Load a line height for a specific font
10 11 12 |
# File 'scripts/00000 Dependencies/00001 LiteRGSS2/00009 Fonts.rb', line 10 def load_line_height(font_id, line_height) @line_heights[font_id] = line_height end |
.set_default_size(font_id, size) ⇒ self
Define the default size of a font
770 771 772 |
# File 'LiteRGSS.rb.yard.rb', line 770 def self.set_default_size(font_id, size) end |