App: Prepare for clang-format

This commit is contained in:
wmayer
2024-06-03 10:34:17 +02:00
committed by wwmayer
parent fd7f6039b6
commit 6fb7c51c18
15 changed files with 55 additions and 11 deletions

View File

@@ -129,12 +129,14 @@ void Color::setPackedARGB(uint32_t argb)
std::string Color::asHexString() const
{
// clang-format off
std::stringstream ss;
ss << "#" << std::hex << std::uppercase << std::setfill('0')
<< std::setw(2) << int(std::lround(r * 255.0F))
<< std::setw(2) << int(std::lround(g * 255.0F))
<< std::setw(2) << int(std::lround(b * 255.0F));
return ss.str();
// clang-format on
}
bool Color::fromHexString(const std::string& hex)