ClanLib
2.3.7
Main Page
Modules
Namespaces
Classes
Files
File List
File Members
Sources
API
GUI
Components
listview_header.h
Go to the documentation of this file.
1
/*
2
** ClanLib SDK
3
** Copyright (c) 1997-2011 The ClanLib Team
4
**
5
** This software is provided 'as-is', without any express or implied
6
** warranty. In no event will the authors be held liable for any damages
7
** arising from the use of this software.
8
**
9
** Permission is granted to anyone to use this software for any purpose,
10
** including commercial applications, and to alter it and redistribute it
11
** freely, subject to the following restrictions:
12
**
13
** 1. The origin of this software must not be misrepresented; you must not
14
** claim that you wrote the original software. If you use this software
15
** in a product, an acknowledgment in the product documentation would be
16
** appreciated but is not required.
17
** 2. Altered source versions must be plainly marked as such, and must not be
18
** misrepresented as being the original software.
19
** 3. This notice may not be removed or altered from any source distribution.
20
**
21
** Note: Some of the libraries ClanLib may link to may have additional
22
** requirements or restrictions.
23
**
24
** File Author(s):
25
**
26
** Magnus Norddahl
27
** Harry Storbacka
28
*/
29
32
33
#pragma once
34
35
#include "../api_gui.h"
36
#include "../gui_component.h"
37
#include "../../Core/Signals/callback_v0.h"
38
#include "../../Core/Signals/callback_v1.h"
39
#include "
listview.h
"
40
41
class
CL_ListViewColumnHeader
;
42
class
CL_ListViewHeader_Impl;
43
47
class
CL_API_GUI
CL_ListViewHeader
:
public
CL_GUIComponent
48
{
51
52
public
:
53
57
CL_ListViewHeader
(
CL_GUIComponent
*parent);
58
59
~
CL_ListViewHeader
();
60
64
65
public
:
66
70
CL_ListViewColumnHeader
get_first_column();
71
77
CL_ListViewColumnHeader
get_column(
const
CL_StringRef
&column_id);
78
82
bool
get_visible()
const
;
83
87
virtual
CL_Size
get_preferred_size
()
const
;
88
92
93
public
:
94
101
CL_ListViewColumnHeader
create_column(
const
CL_StringRef
&column_id,
const
CL_StringRef
&caption);
102
108
CL_ListViewColumnHeader
append(
CL_ListViewColumnHeader
column);
109
115
CL_ListViewColumnHeader
remove
(
const
CL_StringRef
&column_id);
116
123
CL_ListViewColumnHeader
insert_after(
const
CL_StringRef
&column_id,
CL_ListViewColumnHeader
new_column);
124
131
CL_ListViewColumnHeader
insert_before(
const
CL_StringRef
&column_id,
CL_ListViewColumnHeader
new_column);
132
136
void
set_visible
(
bool
visible);
137
141
void
set_display_mode(
CL_ListViewDisplayMode
mode);
142
146
147
public
:
148
CL_Callback_v1<CL_ListViewColumnHeader>
&func_column_added();
149
150
CL_Callback_v1<CL_ListViewColumnHeader>
&func_column_removed();
151
152
CL_Callback_v1<CL_ListViewColumnHeader>
&func_column_size_changed();
153
157
158
private
:
159
164
CL_ListViewHeader
(
const
CL_Rect
&geometry,
CL_GUIComponent
*parent);
165
169
void
update_geometry(
const
CL_Rect
&parent_content_rect);
170
171
CL_SharedPtr<CL_ListViewHeader_Impl> impl;
172
173
friend
class
CL_ListView_Impl;
175
};
176
Generated on Fri Jun 14 2013 13:05:45 for ClanLib by
1.8.4