Class: Google::Apis::SlidesV1::WeightedFontFamily
- Inherits:
-
Object
- Object
- Google::Apis::SlidesV1::WeightedFontFamily
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/slides_v1/classes.rb,
lib/google/apis/slides_v1/representations.rb,
lib/google/apis/slides_v1/representations.rb
Overview
Represents a font family and weight used to style a TextRun.
Instance Attribute Summary collapse
-
#font_family ⇒ String
The font family of the text.
-
#weight ⇒ Fixnum
The rendered weight of the text.
Instance Method Summary collapse
-
#initialize(**args) ⇒ WeightedFontFamily
constructor
A new instance of WeightedFontFamily.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ WeightedFontFamily
Returns a new instance of WeightedFontFamily.
5205 5206 5207 |
# File 'lib/google/apis/slides_v1/classes.rb', line 5205 def initialize(**args) update!(**args) end |
Instance Attribute Details
#font_family ⇒ String
The font family of the text. The font family can be any font from the Font
menu in Slides or from Google Fonts. If the font
name is unrecognized, the text is rendered in Arial
.
Corresponds to the JSON property fontFamily
5193 5194 5195 |
# File 'lib/google/apis/slides_v1/classes.rb', line 5193 def font_family @font_family end |
#weight ⇒ Fixnum
The rendered weight of the text. This field can have any value that is a
multiple of 100
between 100
and 900
, inclusive. This range corresponds
to the numerical values described in the CSS 2.1 Specification, section 15.6, with non-numerical
values disallowed. Weights greater than or equal to 700
are considered bold,
and weights less than 700
are not bold. The default value is 400
("normal").
Corresponds to the JSON property weight
5203 5204 5205 |
# File 'lib/google/apis/slides_v1/classes.rb', line 5203 def weight @weight end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
5210 5211 5212 5213 |
# File 'lib/google/apis/slides_v1/classes.rb', line 5210 def update!(**args) @font_family = args[:font_family] if args.key?(:font_family) @weight = args[:weight] if args.key?(:weight) end |