File: table-view-column.hpp

package info (click to toggle)
ares 126-3
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 32,600 kB
  • sloc: cpp: 356,508; ansic: 20,394; makefile: 16; sh: 2
file content (53 lines) | stat: -rw-r--r-- 1,794 bytes parent folder | download | duplicates (4)
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
#if defined(Hiro_TableView)
struct mTableViewColumn : mObject {
  Declare(TableViewColumn)

  auto active() const -> bool;
  auto alignment() const -> Alignment;
  auto backgroundColor() const -> Color;
  auto editable() const -> bool;
  auto expandable() const -> bool;
  auto foregroundColor() const -> Color;
  auto horizontalAlignment() const -> f32;
  auto icon() const -> multiFactorImage;
  auto remove() -> type& override;
  auto resizable() const -> bool;
  auto setActive() -> type&;
  auto setAlignment(Alignment alignment = {}) -> type&;
  auto setBackgroundColor(Color color = {}) -> type&;
  auto setEditable(bool editable = true) -> type&;
  auto setExpandable(bool expandable = true) -> type&;
  auto setForegroundColor(Color color = {}) -> type&;
  auto setHorizontalAlignment(f32 alignment = 0.0) -> type&;
  auto setIcon(const multiFactorImage& icon = {}) -> type&;
  auto setResizable(bool resizable = true) -> type&;
  auto setSorting(Sort sorting = Sort::None) -> type&;
  auto setText(const string& text = "") -> type&;
  auto setVerticalAlignment(f32 alignment = 0.5) -> type&;
  auto setVisible(bool visible = true) -> type& override;
  auto setWidth(f32 width = 0) -> type&;
  auto sort(Sort sorting) -> type&;
  auto sorting() const -> Sort;
  auto text() const -> string;
  auto verticalAlignment() const -> f32;
  auto width() const -> f32;

//private:
  struct State {
    bool active = false;
    Alignment alignment;
    Color backgroundColor;
    bool editable = false;
    bool expandable = false;
    Color foregroundColor;
    f32 horizontalAlignment = 0.0;
    multiFactorImage icon;
    bool resizable = true;
    Sort sorting = Sort::None;
    string text;
    f32 verticalAlignment = 0.5;
    bool visible = true;
    f32 width = 0;
  } state;
};
#endif