Skip to content

Commit 13d2423

Browse files
committed
rename trait from colorscale to colormap
1 parent 01927ec commit 13d2423

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

plotters/src/style/colors/colormaps.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ use crate::style::{HSLColor,RGBAColor,RGBColor};
22

33
use num_traits::{Float,ToPrimitive,FromPrimitive};
44

5-
pub trait ColorScale<ColorType: crate::prelude::Color, FloatType=f32>
5+
pub trait ColorMap<ColorType: crate::prelude::Color, FloatType=f32>
66
where
77
FloatType: Float,
88
{
@@ -32,7 +32,7 @@ macro_rules! define_colors_from_list_of_values_or_directly{
3232

3333
macro_rules! implement_linear_interpolation_color_map{
3434
($color_scale_name:ident, $color_type:tt) => {
35-
impl<FloatType: std::fmt::Debug + Float + FromPrimitive + ToPrimitive> ColorScale<$color_type, FloatType> for $color_scale_name {
35+
impl<FloatType: std::fmt::Debug + Float + FromPrimitive + ToPrimitive> ColorMap<$color_type, FloatType> for $color_scale_name {
3636
fn get_color_normalized(&self, h: FloatType, min: FloatType, max: FloatType) -> $color_type {
3737
// Ensure that we do have a value in bounds
3838
let h = h.max(min).min(max);

0 commit comments

Comments
 (0)