// Copyright (C) 2026 Hector van der Aa // Copyright (C) 2026 Association Exergie // SPDX-License-Identifier: GPL-3.0-or-later import { Palette } from "../palette.slint"; export component WindowHeader { in property title; HorizontalLayout { horizontal-stretch: 1; Rectangle { border-top-left-radius: 8px; border-top-right-radius: 8px; background: Palette.border; HorizontalLayout { VerticalLayout { alignment: center; padding-left: 6px; Rectangle { vertical-stretch: 1; Text { text: title; color: Palette.text-primary; horizontal-alignment: center; font-size: 14px; } } } Rectangle { horizontal-stretch: 1; } HorizontalLayout { padding-right: 4px; padding-top: 4px; padding-bottom: 4px; Rectangle { width: 12px; height: 12px; background: Palette.warning; border-radius: self.width / 2; y: (parent.height - self.height) / 2; TouchArea { mouse-cursor: pointer; } } } HorizontalLayout { padding-right: 4px; padding-top: 4px; padding-bottom: 4px; Rectangle { width: 12px; height: 12px; background: Palette.error; border-radius: self.width / 2; y: (parent.height - self.height) / 2; TouchArea { mouse-cursor: pointer; } } } } } } }