]> git.tdb.fi Git - ext/sigc++-2.0.git/blob - sigc++/sigc++.h
Adjust the name of the library to match upstream
[ext/sigc++-2.0.git] / sigc++ / sigc++.h
1 /*
2  * Copyright 2003, The libsigc++ Development Team
3  *
4  *  This library is free software; you can redistribute it and/or
5  *  modify it under the terms of the GNU Lesser General Public
6  *  License as published by the Free Software Foundation; either
7  *  version 2.1 of the License, or (at your option) any later version.
8  *
9  *  This library is distributed in the hope that it will be useful,
10  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
11  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12  *  Lesser General Public License for more details.
13  *
14  *  You should have received a copy of the GNU Lesser General Public
15  *  License along with this library; if not, write to the Free Software
16  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17  *
18  */
19
20 #ifndef SIGCXX_SIGCXX_H
21 #define SIGCXX_SIGCXX_H
22
23 /** @mainpage libsigc++ Reference Manual
24  *
25  * @section description Description
26  *
27  * libsigc++ provides a typesafe (at compile time) callback system for standard 
28  * C++. It allows you to define signals and to connect those signals to any 
29  * callback function, either a global or a member function, regardless of whether 
30  * it is static or virtual. It also contains adaptor classes for connection of 
31  * dissimilar callbacks.
32  *
33  * For instance, see the @ref signal "Signals", @ref sigcfunctors "Functors", 
34  * @ref slot "Slots" and @ref adaptors "Adaptors".
35  *
36  * See also the 
37  * <a href="https://developer.gnome.org/libsigc++-tutorial/2.10/">libsigc++ tutorial</a>,
38  * the <a href="https://libsigcplusplus.github.io/libsigcplusplus/">libsigc++ website</a>, and
39  * the <a href="https://developer.gnome.org/gtkmm-tutorial/3.24/chapter-signals.html">Signals appendix of the Programming with gtkmm book</a>.
40  *
41  * @section features Features
42  *
43  * - Compile-time typesafe callbacks (also faster than run time checks)
44  * - Type-safety violations report the line number correctly with template names 
45  *   (no tracing template failures into headers)
46  * - No compiler extensions or meta compilers required
47  * - Proper handling of dynamic objects and signals (deleted objects will not
48  *   cause crashes)
49  * - Extendable API at any level: signal, slot, connection and trackable
50  * - Extensions do not require alteration of basic components
51  * - User-definable accumulators
52  * - A variety of adaptors to change the callback signature: bind, hide,
53  *   retype, and compose
54  *
55  * @section basics Basic Usage
56  *
57  * Include the libsigc++ header:
58  * @code
59  * #include <sigc++/sigc++.h>
60  * @endcode
61  * (You may include individual headers, such as @c sigc++/bind.h instead.)
62  *
63  * If your source file is @c program.cc, you can compile it with:
64  * @code
65  * g++ program.cc -o program `pkg-config --cflags --libs sigc++-2.0`
66  * @endcode
67  * If your version of g++ is not C++11-compliant by default,
68  * add the @c -std=c++11 option.
69  *
70  * @subsection meson Using Meson
71  *
72  * If using <a href="https://mesonbuild.com/">Meson</a>, include the following
73  * in @c meson.build:
74  * @code
75  * sigc_dep = dependency('sigc++-2.0')
76  * program_name = 'program'
77  * cpp_sources = [ 'program.cc' ]
78  * executable(program_name,
79  *   cpp_sources,
80  *   dependencies: sigc_dep
81  * )
82  * @endcode
83  *
84  * Your @c dependencies: keyword argument should also mention any other libraries
85  * that you need to use.
86  *
87  * @subsection autotools Using Autotools
88  *
89  * Alternatively, if using autoconf, use the following in @c configure.ac:
90  * @code
91  * PKG_CHECK_MODULES([DEPS], [sigc++-2.0])
92  * @endcode
93  * Then use the generated @c DEPS_CFLAGS and @c DEPS_LIBS variables
94  * in the project @c Makefile.am files. For example:
95  * @code
96  * yourprogram_CPPFLAGS = $(DEPS_CFLAGS)
97  * yourprogram_LDADD = $(DEPS_LIBS)
98  * @endcode
99  *
100  * Your @c PKG_CHECK_MODULES() call should also mention any other libraries that
101  * you need to use via pkg-config.
102  *
103  * @subsection cmake Using CMake
104  *
105  * If using CMake, use the following in @c CMakeList.txt:
106  * @code
107  * include(FindPkgConfig)
108  * pkg_check_modules(DEPS REQUIRED sigc++-2.0)
109  * include_directories(${DEPS_INCLUDE_DIRS})
110  * target_link_libraries(yourprogram ${DEPS_LIBRARIES})
111  * @endcode
112  *
113  * Your @c pkg_check_modules() call should also mention any other libraries that
114  * you need to use via pkg-config.
115  *
116  * @section scope Scope of Documentation
117  *
118  * libsigc++ contains many template functions and template classes/structs,
119  * some with many specializations. This reference manual does not show all
120  * specializations of those templates that hardly any user will use directly.
121  */
122
123 #include <sigc++/signal.h>
124 #include <sigc++/connection.h>
125 #include <sigc++/trackable.h>
126 #include <sigc++/adaptors/adaptors.h>
127 #include <sigc++/functors/functors.h>
128
129 #endif /* SIGCXX_SIGCXX_H */