hypr-chrome v0.1

This commit is contained in:
2026-07-28 21:22:13 +02:00
commit a28a899874
18 changed files with 1227 additions and 0 deletions
+30
View File
@@ -0,0 +1,30 @@
#pragma once
#include <hyprland/src/render/pass/PassElement.hpp>
class ChromeDecoration;
// EK_CUSTOM render-pass element: blits the decoration's cairo-rendered
// border frame texture, plus a separate title-text texture positioned over
// the title bar plateau. Both textures are cached on ChromeDecoration.
class ChromePassElement : public IPassElement {
public:
struct SData {
ChromeDecoration* decoration = nullptr;
float alpha = 1.F;
};
ChromePassElement(const SData& data);
virtual ~ChromePassElement() = default;
virtual std::vector<UP<IPassElement>> draw() override;
virtual bool needsLiveBlur() override;
virtual bool needsPrecomputeBlur() override;
virtual std::optional<CBox> boundingBox() override;
virtual const char* passName() override { return "ChromePassElement"; }
virtual ePassElementType type() override { return EK_CUSTOM; }
private:
SData data;
};