Aurore
A Switch-like interface for your app, on every screen
Loading...
Searching...
No Matches
cell_detail.hpp
Go to the documentation of this file.
1/*
2 Copyright 2021 XITRIX
3
4 Licensed under the Apache License, Version 2.0 (the "License");
5 you may not use this file except in compliance with the License.
6 You may obtain a copy of the License at
7
8 http://www.apache.org/licenses/LICENSE-2.0
9
10 Unless required by applicable law or agreed to in writing, software
11 distributed under the License is distributed on an "AS IS" BASIS,
12 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 See the License for the specific language governing permissions and
14 limitations under the License.
15*/
16
17#pragma once
18
20#include <aurore/core/bind.hpp>
21#include <aurore/core/box.hpp>
23
24namespace aurore
25{
26
28{
29 public:
31
32 void setText(std::string title);
33 void setTextColor(NVGcolor color);
34 void setDetailText(std::string title);
35 void setDetailTextColor(NVGcolor color);
36
37 AURORE_BIND(Label, title, "aurore/rediocell/title");
38 AURORE_BIND(Label, detail, "aurore/rediocell/detail");
39
40 static View* create();
41
42 bool setBoundText(const std::string& text) override;
43
44 protected:
46 // Its title.
47 std::string getDefaultAccessibilityLabel() override;
48 // Its detail, and any other text shown in it (a state, a note).
49 std::string getDefaultAccessibilityValue() override;
50};
51
52} // namespace aurore
Definition cell_detail.hpp:28
bool setBoundText(const std::string &text) override
AURORE_BIND(Label, detail, "aurore/rediocell/detail")
static View * create()
AccessibilityRole getDefaultAccessibilityRole() override
Definition cell_detail.hpp:45
std::string getDefaultAccessibilityLabel() override
A focusable box says the texts shown in it (getAccessibilityText).
std::string getDefaultAccessibilityValue() override
void setTextColor(NVGcolor color)
void setDetailText(std::string title)
AURORE_BIND(Label, title, "aurore/rediocell/title")
void setText(std::string title)
void setDetailTextColor(NVGcolor color)
Definition label.hpp:65
Definition recycler.hpp:66
Definition view.hpp:232
Definition actions.hpp:25
AccessibilityRole
Definition view_style.hpp:78
Definition text.hpp:13