Module conrod::utils [] [src]

Various utility functions used throughout Conrod.

Functions

clamp

Clamp a value between some range.

map_range

Map a value from a given range to a new given range.

partial_max

Compare to PartialOrd values and return the min.

partial_min

Compare to PartialOrd values and return the min.

percentage

Get value percentage between max and min.

val_to_string

Get a suitable string from the value, its max and the pixel range.

value_from_perc

Adjust the value to the given percentage.