summaryrefslogtreecommitdiffstats
path: root/src/ui/dialog/dialog-data.h
blob: 5f177232624b847bd6b0df6e285500272547157d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
// SPDX-License-Identifier: GPL-2.0-or-later

/** @file
 * @brief Basic dialog info.
 *
 * Authors: see git history
 *   Tavmjong Bah
 *
 * Copyright (c) 2021 Tavmjong Bah, Authors
 *
 * Released under GNU GPL v2+, read the file 'COPYING' for more information.
 */

#include <map>

#include <glibmm/i18n.h>
#include <glibmm/ustring.h>

enum class ScrollProvider {
    PROVIDE = 0,
    NOPROVIDE
};

class DialogData {
public:
    Glib::ustring label;
    Glib::ustring icon_name;
    enum Category { Basic = 0, Advanced, Settings, Diagnostics, Other, _num_categories };
    Category category;
    ScrollProvider provide_scroll;
};

// dialog categories (used to group them in a dialog submenu)
char const *const dialog_categories[DialogData::_num_categories] = {
    N_("Basic"),
    N_("Advanced"),
    N_("Settings"),
    N_("Diagnostic"),
    N_("Other")
};

/** Get the data about all existing dialogs. */
std::map<Glib::ustring, DialogData> const &get_dialog_data();

/*
  Local Variables:
  mode:c++
  c-file-style:"stroustrup"
  c-file-offsets:((innamespace . 0)(inline-open . 0)(case-label . +))
  indent-tabs-mode:nil
  fill-column:99
  End:
*/
// vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:fileencoding=utf-8:textwidth=99 :