1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-28 08:07:44 +00:00

AK+Everywhere: Stop including Vector.h from StringView.h

Preparation for using Error.h from Vector.h. This required moving some
things out of line.
This commit is contained in:
Andreas Kling 2021-11-10 11:05:21 +01:00
parent e52f987020
commit 5f7d008791
27 changed files with 88 additions and 51 deletions

View file

@ -242,29 +242,8 @@ public:
return Color(min(255, (int)((float)red() * amount)), min(255, (int)((float)green() * amount)), min(255, (int)((float)blue() * amount)), alpha());
}
Vector<Color> shades(u32 steps, float max = 1.f) const
{
float shade = 1.f;
float step = max / steps;
Vector<Color> shades;
for (u32 i = 0; i < steps; i++) {
shade -= step;
shades.append(this->darkened(shade));
}
return shades;
}
Vector<Color> tints(u32 steps, float max = 1.f) const
{
float shade = 1.f;
float step = max / steps;
Vector<Color> tints;
for (u32 i = 0; i < steps; i++) {
shade += step;
tints.append(this->lightened(shade));
}
return tints;
}
Vector<Color> shades(u32 steps, float max = 1.f) const;
Vector<Color> tints(u32 steps, float max = 1.f) const;
constexpr Color inverted() const
{