You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-12-01 16:38:31 +00:00
HarfBuzz: Update to version 8.2.2
This commit is contained in:
21
thirdparty/harfbuzz/src/hb-subset-input.cc
vendored
21
thirdparty/harfbuzz/src/hb-subset-input.cc
vendored
@@ -74,8 +74,6 @@ hb_subset_input_t::hb_subset_input_t ()
|
||||
HB_TAG ('p', 'r', 'e', 'p'),
|
||||
HB_TAG ('V', 'D', 'M', 'X'),
|
||||
HB_TAG ('D', 'S', 'I', 'G'),
|
||||
HB_TAG ('M', 'V', 'A', 'R'),
|
||||
HB_TAG ('c', 'v', 'a', 'r'),
|
||||
};
|
||||
sets.no_subset_tables->add_array (default_no_subset_tables,
|
||||
ARRAY_LENGTH (default_no_subset_tables));
|
||||
@@ -479,16 +477,21 @@ hb_subset_input_pin_axis_location (hb_subset_input_t *input,
|
||||
* @axis_tag: Tag of the axis
|
||||
* @axis_min_value: Minimum value of the axis variation range to set
|
||||
* @axis_max_value: Maximum value of the axis variation range to set
|
||||
* @axis_def_value: Default value of the axis variation range to set, in case of
|
||||
* null, it'll be determined automatically
|
||||
*
|
||||
* Restricting the range of variation on an axis in the given subset input object.
|
||||
* New min/max values will be clamped if they're not within the fvar axis range.
|
||||
* New min/default/max values will be clamped if they're not within the fvar axis range.
|
||||
* If the new default value is null:
|
||||
* If the fvar axis default value is within the new range, then new default
|
||||
* value is the same as original default value.
|
||||
* If the fvar axis default value is not within the new range, the new default
|
||||
* value will be changed to the new min or max value, whichever is closer to the fvar
|
||||
* axis default.
|
||||
*
|
||||
* Note: input min value can not be bigger than input max value
|
||||
* Note: currently this API does not support changing axis limits yet.It'd be only
|
||||
* used internally for setting axis limits in the internal data structures
|
||||
* Note: input min value can not be bigger than input max value. If the input
|
||||
* default value is not within the new min/max range, it'll be clamped.
|
||||
* Note: currently it supports gvar and cvar tables only.
|
||||
*
|
||||
* Return value: `true` if success, `false` otherwise
|
||||
*
|
||||
@@ -499,7 +502,8 @@ hb_subset_input_set_axis_range (hb_subset_input_t *input,
|
||||
hb_face_t *face,
|
||||
hb_tag_t axis_tag,
|
||||
float axis_min_value,
|
||||
float axis_max_value)
|
||||
float axis_max_value,
|
||||
float *axis_def_value /* IN, maybe NULL */)
|
||||
{
|
||||
if (axis_min_value > axis_max_value)
|
||||
return false;
|
||||
@@ -510,7 +514,8 @@ hb_subset_input_set_axis_range (hb_subset_input_t *input,
|
||||
|
||||
float new_min_val = hb_clamp(axis_min_value, axis_info.min_value, axis_info.max_value);
|
||||
float new_max_val = hb_clamp(axis_max_value, axis_info.min_value, axis_info.max_value);
|
||||
float new_default_val = hb_clamp(axis_info.default_value, new_min_val, new_max_val);
|
||||
float new_default_val = axis_def_value ? *axis_def_value : axis_info.default_value;
|
||||
new_default_val = hb_clamp(new_default_val, new_min_val, new_max_val);
|
||||
return input->axes_location.set (axis_tag, Triple (new_min_val, new_default_val, new_max_val));
|
||||
}
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user