Aurore
A Switch-like interface for your app, on every screen
Loading...
Searching...
No Matches
cadran_frame.hpp
Go to the documentation of this file.
1// Cadran — Aurore's look, after PlayGuard's and PlayShelf's 2026 design
2// boards: the navy and cool-white palettes, an icon rail for a sidebar, the
3// app's mark and a status pill in the header, cards in place of lists, the
4// figures in Sora. These set up the frame every screen shares; an app's tabs
5// draw their own boards, cadran::List dresses the lists, cadran/ui/cadran_kit
6// and cadran/ui/cadran_modal hold the pieces.
7// Copyright (C) 2026 JigSawFr. GPLv3-or-later (see LICENSE.GPL).
8#pragma once
9
10#include <functional>
11#include <string>
12#include <aurore.hpp>
13
14namespace cadran
15{
22void style_header(aurore::AppletFrame* frame, const char* icon, const std::string& text, bool filled, bool with_date);
30void style_rail(aurore::View* tab_frame);
50enum class Tone
51{
52 OK,
53 WARN,
54 DANGER
55};
61{
62 std::string text;
63 std::string icon = "check";
65 std::function<void()> on_tap;
66};
67void set_pill(const std::string& text, const char* icon = "check", Tone tone = Tone::OK);
74aurore::View* make_glow(float cx, float cy, float radius, const char* color_key);
75}
Definition applet_frame.hpp:39
Definition view.hpp:232
Definition cadran.hpp:31
void style_rail(aurore::View *tab_frame)
void refresh_pill()
The pill again after a mode changed (ui::hooks' pill, read-only).
Tone
Definition cadran_frame.hpp:51
void style_header(aurore::AppletFrame *frame, const char *icon, const std::string &text, bool filled, bool with_date)
void style_frame(aurore::AppletFrame *frame, aurore::View *tab_frame)
Both, for the main screen.
bool is_standalone_screen(aurore::View *frame)
void install_theme()
void set_pill(const std::string &text, const char *icon="check", Tone tone=Tone::OK)
aurore::View * make_glow(float cx, float cy, float radius, const char *color_key)
void install_screens()
bool is_main_frame(aurore::View *frame)
void apply_rail()
Definition text.hpp:13
Definition cadran_frame.hpp:61
std::string text
Definition cadran_frame.hpp:62
std::function< void()> on_tap
Definition cadran_frame.hpp:65
Tone tone
Definition cadran_frame.hpp:64
std::string icon
Definition cadran_frame.hpp:63