smaller_equal#

static Parse.smaller_equal(value: float, limit: float) float[source]#

Ensures that the value is smaller or equal a upper limit.

Parameters:
  • value (float) – Used value.

  • limit (float) – Maximum value returned.

Returns:

Clamped value.

Return type:

float