Compare commits
247 Commits
client-sid
...
2.90.5
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
9a812edff8 | ||
|
|
4f3d5e3655 | ||
|
|
b81d141a26 | ||
|
|
d20ac9715e | ||
|
|
7cf895257f | ||
|
|
3604c279ff | ||
|
|
66e85255aa | ||
|
|
78bde3c4c0 | ||
|
|
99ee143a71 | ||
|
|
f73115b6a0 | ||
|
|
ef5e6c1057 | ||
|
|
0df65779bb | ||
|
|
a9cf42ea42 | ||
|
|
59504f58d9 | ||
|
|
eaab96c066 | ||
|
|
bcbb976d91 | ||
|
|
ab6927e4fa | ||
|
|
813bee6f0a | ||
|
|
0a07e9733b | ||
|
|
404e7d0e00 | ||
|
|
7cabad6b77 | ||
|
|
e4e477161a | ||
|
|
7e9d384fc0 | ||
|
|
ae16b31038 | ||
|
|
f8f3b635a6 | ||
|
|
c4f12b95cb | ||
|
|
b74ee87b17 | ||
|
|
b5f878dec8 | ||
|
|
15646b6e74 | ||
|
|
424842e3a9 | ||
|
|
0b51abbfdf | ||
|
|
c4832a9d0e | ||
|
|
675b05f91d | ||
|
|
dd1f0c46b3 | ||
|
|
2ed1bab6bf | ||
|
|
c609c4e807 | ||
|
|
74b3875ab2 | ||
|
|
aff8fb2ea2 | ||
|
|
337e53f62e | ||
|
|
12560cece2 | ||
|
|
f50d06baea | ||
|
|
90cd7f44f1 | ||
|
|
34e8bd9dba | ||
|
|
1ac5011873 | ||
|
|
ef44de1392 | ||
|
|
533ea97c67 | ||
|
|
1a03a65e36 | ||
|
|
1f38a7ac10 | ||
|
|
1cfe57530e | ||
|
|
1e1c5e3ca1 | ||
|
|
6adb034cb7 | ||
|
|
eae60c34d2 | ||
|
|
85e3f22c19 | ||
|
|
0cfb94cdd4 | ||
|
|
319d2bb4f1 | ||
|
|
df106318f8 | ||
|
|
f40fea1317 | ||
|
|
be27fba3f3 | ||
|
|
43f4398dbd | ||
|
|
fa752d156b | ||
|
|
1564d8922a | ||
|
|
53fbf2a30a | ||
|
|
03a313d2a9 | ||
|
|
95a1c31c18 | ||
|
|
5a02283fbf | ||
|
|
6c5dffd1a3 | ||
|
|
300e6b84cd | ||
|
|
3e96cfe8fc | ||
|
|
52200eee01 | ||
|
|
78018767ba | ||
|
|
b6cc7dbd21 | ||
|
|
6aae994a66 | ||
|
|
b4ed51fd93 | ||
|
|
06e48c50a1 | ||
|
|
655dcff096 | ||
|
|
34573b53f3 | ||
|
|
c1affa4f3c | ||
|
|
c3987f9ee2 | ||
|
|
418d84f311 | ||
|
|
18132ecae5 | ||
|
|
905f988166 | ||
|
|
17f8b5e581 | ||
|
|
eebb16eb1a | ||
|
|
289f3b1b2b | ||
|
|
42abeadbb8 | ||
|
|
cd266cb8de | ||
|
|
14e0cbe2d3 | ||
|
|
7ad08f19aa | ||
|
|
9928158d41 | ||
|
|
680c1d26e3 | ||
|
|
e545ed58ed | ||
|
|
f0e24348a0 | ||
|
|
4aa75fcf43 | ||
|
|
d7ceebda3f | ||
|
|
804effba99 | ||
|
|
d78cee6791 | ||
|
|
1c14997df2 | ||
|
|
5789ea35cc | ||
|
|
7f2e4c38a9 | ||
|
|
64f11c366a | ||
|
|
98d47b57bf | ||
|
|
019ccc686d | ||
|
|
88cae1769b | ||
|
|
18b233fe2a | ||
|
|
2326d76efa | ||
|
|
92efbf2302 | ||
|
|
45f6bbb56f | ||
|
|
12cdd1e33b | ||
|
|
48a5b4ee97 | ||
|
|
0ef0b9c68b | ||
|
|
ac18bc7cb1 | ||
|
|
75b9f68338 | ||
|
|
8a590711da | ||
|
|
89e67b8ec2 | ||
|
|
23a61525f6 | ||
|
|
e73a2e5654 | ||
|
|
53796b7f1f | ||
|
|
67cd929267 | ||
|
|
4601ad2352 | ||
|
|
5aaec9d7e0 | ||
|
|
cc5500ad85 | ||
|
|
16ecf55832 | ||
|
|
d722adb76a | ||
|
|
ef25dba303 | ||
|
|
17516dc83c | ||
|
|
d986066cb5 | ||
|
|
947cde30d9 | ||
|
|
92befe0c06 | ||
|
|
d35e4848a2 | ||
|
|
71e69e4701 | ||
|
|
9bf7f99a17 | ||
|
|
f010eeb7d3 | ||
|
|
7e3e2bf29a | ||
|
|
998459afb7 | ||
|
|
686294cb3b | ||
|
|
32925cd579 | ||
|
|
604beadbcd | ||
|
|
882fdfab78 | ||
|
|
9c4657fb73 | ||
|
|
928e2a5780 | ||
|
|
6cde835acd | ||
|
|
009e26f32f | ||
|
|
1569f722cd | ||
|
|
dcfdbc4ca6 | ||
|
|
a7041e9c40 | ||
|
|
c6650bfa01 | ||
|
|
7ea1556cd0 | ||
|
|
79350fcd8a | ||
|
|
208c82c809 | ||
|
|
55f8b4742f | ||
|
|
d17fbd06cb | ||
|
|
d33d31446e | ||
|
|
eb1913d145 | ||
|
|
0124dd0b8f | ||
|
|
cb21d4473e | ||
|
|
626240b0fe | ||
|
|
a681c37604 | ||
|
|
1801a65a84 | ||
|
|
3c46d9acbc | ||
|
|
adf1bbe28a | ||
|
|
9b9bb4c6e8 | ||
|
|
abfc6f8f07 | ||
|
|
078da34a26 | ||
|
|
d927df0c3d | ||
|
|
a090f331b9 | ||
|
|
d47e63856b | ||
|
|
f96be1ab10 | ||
|
|
d5d7fd9f51 | ||
|
|
349f8c561d | ||
|
|
3c8a54b2f7 | ||
|
|
ca046f0cfb | ||
|
|
0de0914021 | ||
|
|
4cf4470fcd | ||
|
|
2a2843c041 | ||
|
|
32dd5882a0 | ||
|
|
91268713a0 | ||
|
|
b98667d41e | ||
|
|
2755b93913 | ||
|
|
3e1b82336c | ||
|
|
5f4309be96 | ||
|
|
4e23171803 | ||
|
|
edd57602b8 | ||
|
|
cf75457faa | ||
|
|
aab1a96d46 | ||
|
|
9d0b941da6 | ||
|
|
a14c820aa9 | ||
|
|
9eef134efb | ||
|
|
d581c619db | ||
|
|
4f357dbf95 | ||
|
|
b74fb44c11 | ||
|
|
2747f9d84d | ||
|
|
318fa1e179 | ||
|
|
36c669aaca | ||
|
|
972e75e8b0 | ||
|
|
bdaefd7efe | ||
|
|
c5a4bd0578 | ||
|
|
404f4c5d40 | ||
|
|
dfc9c87a46 | ||
|
|
4c3a829bb6 | ||
|
|
cd76d995eb | ||
|
|
385f83ff4a | ||
|
|
8c957ef3ef | ||
|
|
ed3198146c | ||
|
|
07b1a2e081 | ||
|
|
1b2e9124f0 | ||
|
|
b238c0124a | ||
|
|
f62e000be4 | ||
|
|
2e4ba929ba | ||
|
|
294f810021 | ||
|
|
e19c50b538 | ||
|
|
e9fc660d7e | ||
|
|
d53b0c200d | ||
|
|
213994b565 | ||
|
|
6c71da01cc | ||
|
|
cf14d4f368 | ||
|
|
ef6ef84221 | ||
|
|
e044efdbd2 | ||
|
|
d4bccb7029 | ||
|
|
86940de734 | ||
|
|
230f47224b | ||
|
|
4696e94138 | ||
|
|
76db7d69f1 | ||
|
|
4467145e43 | ||
|
|
61aa2af23d | ||
|
|
71c501d895 | ||
|
|
785027751a | ||
|
|
09fe6e7d44 | ||
|
|
e902786017 | ||
|
|
4f66b8e37c | ||
|
|
9b2ffc4b80 | ||
|
|
f772f3a1bb | ||
|
|
707535434c | ||
|
|
eb1233d11b | ||
|
|
cd23f1e080 | ||
|
|
b618ca8923 | ||
|
|
5e0dfed135 | ||
|
|
882660e13d | ||
|
|
9ad9c193ea | ||
|
|
ee483ec328 | ||
|
|
9399114802 | ||
|
|
897cf634c3 | ||
|
|
e17b9f282f | ||
|
|
8147019930 | ||
|
|
59108b5d98 | ||
|
|
4bf5a171e2 | ||
|
|
34deb14eff | ||
|
|
bffd85c2b7 |
16
INSTALL.in
16
INSTALL.in
@@ -3,22 +3,12 @@ Prerequisites
|
||||
|
||||
GTK+ requires the following packages:
|
||||
|
||||
- The GLib, Pango, ATK and cairo libraries, available at the same
|
||||
location as GTK+. GTK+ @GTK_VERSION@ requires at least GLib 2.23.6,
|
||||
Pango 1.20, ATK 1.29.2 and cairo 1.6.0.
|
||||
- The GLib, Pango, GdkPixbuf, ATK and cairo libraries, available at
|
||||
the same location as GTK+. GTK+ @GTK_VERSION@ requires at least
|
||||
GLib 2.23.6, Pango 1.20, GdkPixbuf 2.21.0 ATK 1.29.2 and cairo 1.6.0.
|
||||
|
||||
- gobject-introspection 0.6.7 or newer.
|
||||
|
||||
- The TIFF, PNG, and JPEG image loading libraries. You most
|
||||
likely have these installed on your system already. If not
|
||||
these libraries are available from:
|
||||
|
||||
http://www.libtiff.org/
|
||||
http://www.libpng.org/
|
||||
http://www.ijg.org/
|
||||
|
||||
libtiff must be version 3.6.0 or higher.
|
||||
|
||||
Simple install procedure
|
||||
========================
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
## Makefile.am for GTK+
|
||||
include $(top_srcdir)/Makefile.decl
|
||||
|
||||
SRC_SUBDIRS = gdk-pixbuf gdk gtk modules demos tests perf contrib
|
||||
SRC_SUBDIRS = gdk gtk modules demos tests perf
|
||||
SUBDIRS = po po-properties $(SRC_SUBDIRS) docs m4macros build
|
||||
|
||||
ACLOCAL_AMFLAGS = -I m4 ${ACLOCAL_FLAGS}
|
||||
@@ -147,7 +147,7 @@ gdk-$(GDKTARGET)-3.0-uninstalled.pc: gdk-3.0-uninstalled.pc
|
||||
cp gdk-3.0-uninstalled.pc gdk-$(GDKTARGET)-3.0-uninstalled.pc
|
||||
|
||||
pkgconfigdir = $(libdir)/pkgconfig
|
||||
pkgconfig_DATA = gdk-pixbuf-3.0.pc gdk-$(GDKTARGET)-3.0.pc gtk+-$(GDKTARGET)-3.0.pc gail-3.0.pc
|
||||
pkgconfig_DATA = gdk-$(GDKTARGET)-3.0.pc gtk+-$(GDKTARGET)-3.0.pc gail-3.0.pc
|
||||
|
||||
if OS_UNIX
|
||||
pkgconfig_DATA += gtk+-unix-print-3.0.pc
|
||||
|
||||
147
NEWS
147
NEWS
@@ -1,3 +1,150 @@
|
||||
Overview of Changes from GTK+ 2.90.4 to 2.90.5
|
||||
==============================================
|
||||
|
||||
* Support NOCONFIGURE in autogen.sh to avoid running configure
|
||||
|
||||
* The cairo dependency has been bumped to 1.9.10
|
||||
|
||||
* Drop aliasing hacks instead use -Bsymbolic-funtions.
|
||||
|
||||
* Bugs:
|
||||
589904 Certain drawing in some widgets does not pass on...
|
||||
610346 Confusion between GtkWindow:allow-grow and GtkWindow:resizable
|
||||
613284 Replace GdkRegion with cairo_region_t
|
||||
617386 Migrate API docs from templates to source files (GtkButton)
|
||||
617389 Migrate API docs from templates to source files (GtkCalendar)
|
||||
617392 Migrate API docs from templates to source files (GtkCellEditable)
|
||||
621414 Can't select file on file browser popup after choosing to sort...
|
||||
622677 Remove GdkWindowObject public structure
|
||||
623239 also show num-lock warning
|
||||
623307 Annotate gdk_display_manager_list_displays return value
|
||||
623389 [iconview] Fix segfault when using rubberband selection
|
||||
623476 [windows] gdk fails to compile
|
||||
623520 gtk+ 3 fails to build from outside git source tree
|
||||
623845 Use -Bsymbolic
|
||||
461618 use GSlice for gtkrequisition
|
||||
|
||||
* Deprecations and cleanups:
|
||||
- GdkRegion has been removed, and region-using code has been ported
|
||||
to cairo_region_t and cairo_rectangle_int_t.
|
||||
- The deprecated GdkFont has been removed, together with vestigial
|
||||
uses in GTK+, including the GdkFontSel::font property and a GdkFont
|
||||
member in GtkStyle.
|
||||
- The GdkWindowObject structure has been removed from public headers.
|
||||
- The GdkWindow::allow-grow and ::allow-shrink properties have been removed.
|
||||
|
||||
* Quartz:
|
||||
- Misc fixed to clipping and color handling
|
||||
- Update the DND code for GdkDevice changes
|
||||
|
||||
* Translation updates:
|
||||
Breton
|
||||
Czech
|
||||
Estonian
|
||||
Galician
|
||||
Hebrew
|
||||
Kazakh
|
||||
Norwegian bokmål
|
||||
Slovenian
|
||||
Simplified Chinese
|
||||
Spanish
|
||||
|
||||
|
||||
Overview of Changes from GTK+ 2.90.3 to 2.90.4
|
||||
==============================================
|
||||
|
||||
* GSEAL is now enabled by default
|
||||
|
||||
* gdk-pixbuf has been moved into a separate module
|
||||
|
||||
* The GtkExtendedLayout interface has been renamed to
|
||||
GtkSizeRequest
|
||||
|
||||
* gtk_init warns if it detects GTK2.x and GTK3 being used
|
||||
in the same process
|
||||
|
||||
* Misc new API:
|
||||
gtk_accessible_set_widget
|
||||
gtk_message_dialog_get_message_area
|
||||
gtk_font_selection_dialog_get_font_selection
|
||||
gtk_window_group_get_current_grab
|
||||
gtk_table_get_size
|
||||
gtk_button_get_event_window
|
||||
gdk_device_manager_get_client_pointer
|
||||
gdk_image_get_pixels
|
||||
|
||||
* Bugs fixed:
|
||||
522756 gnome-appearance-properties crashed with SIGSEGV...
|
||||
620832 make _gtk_window_group_get_current_grab() public
|
||||
621250 Missing accessors for GtkRange has_stepper_X
|
||||
621685 Add gdk_device_manager_get_client_pointer() ...
|
||||
621690 Enable per-device events on gtk_widget_realize()
|
||||
621927 Bug in gtk/Makefile.in: affects gtktypefuncs.c
|
||||
622011 Don't handle "connecting-to-device" state reason
|
||||
622581 [GSEAL] GtkButton has no accessor for event_window
|
||||
622765 Duplicate symbols in Gdk on OSX
|
||||
622827 test/testapplication.c doesn't build in quartz
|
||||
|
||||
* Translation updates:
|
||||
Arabic
|
||||
Armenian
|
||||
Galician
|
||||
Slovenian
|
||||
Spanish
|
||||
|
||||
|
||||
Overview of Changes from GTK+ 2.90.2 to 2.90.3
|
||||
==============================================
|
||||
|
||||
* GtkProgress has been removed. It was entirely deprecated for
|
||||
a long time
|
||||
|
||||
* GtkApplication has been updated to match the GApplication API
|
||||
as of GLib 2.25.9
|
||||
|
||||
* XI2:
|
||||
- Device grabs now take precedence over GTK+ grabs
|
||||
- Various other bug fixes
|
||||
|
||||
* Extended Layout:
|
||||
- Prevent negative allocations (as seen in emacs and gedit)
|
||||
|
||||
* Win32: XP theming is back !
|
||||
|
||||
* Misc new API:
|
||||
- Add an accessor for GtkViewport->view_window
|
||||
- Add an accessor for GdkDragContext->source_window
|
||||
- gtk_icon_theme_load_symbolic_for_style a variant of
|
||||
gtk_icon_theme_load_symbolic taking a GtkStyle
|
||||
|
||||
* Introspection:
|
||||
- Misc annotation fixes
|
||||
|
||||
* Cleanups:
|
||||
- GTK_OBJECT_FLAGS and GtkObjectFlags have been depreated
|
||||
|
||||
* Bugs fixed:
|
||||
620618 get rid of GtkProgress
|
||||
615666 GTK_OBJECT_FLAGS() should be deprecated
|
||||
617444 GNU emacs warnings with extended layout GTK+
|
||||
621631 Non-consistent style in GtkUIManager docs
|
||||
621136 GtkCalendar: Some functions always return TRUE
|
||||
621003 GtkApplication] Update for GApplication API changes
|
||||
621683 gtk_menu_attach_to_widget() should emit an "attach-widget"...
|
||||
621479 typo in GTK docs on library.gnome.org
|
||||
621081 GtkViewport missing accessor for view_window.
|
||||
620440 Combo-boxes loose focus
|
||||
621775 Space symbol missed in Resources chapter
|
||||
621578 Symbolic color cut-and-paste mess
|
||||
621111 gtk_init_with_args()'s GOptionEntry argument should be const
|
||||
602289 gdk_spawn_on_screen(_with_pipes) uses gint for pid
|
||||
|
||||
* Updated translations:
|
||||
Galician
|
||||
Norwegian bokmål
|
||||
Spanish
|
||||
|
||||
|
||||
Overview of Changes from GTK+ 2.90.1 to 2.90.2
|
||||
==============================================
|
||||
|
||||
|
||||
@@ -72,7 +72,12 @@ test $TEST_TYPE $FILE || {
|
||||
exit 1
|
||||
}
|
||||
|
||||
if test -z "$AUTOGEN_SUBDIR_MODE"; then
|
||||
# NOCONFIGURE is used by gnome-common; support both
|
||||
if ! test -z "$AUTOGEN_SUBDIR_MODE"; then
|
||||
NOCONFIGURE=1
|
||||
fi
|
||||
|
||||
if test -z "$NOCONFIGURE"; then
|
||||
if test -z "$*"; then
|
||||
echo "I am going to run ./configure with no arguments - if you wish "
|
||||
echo "to pass any to it, please specify them on the $0 command line."
|
||||
@@ -116,7 +121,7 @@ $AUTOMAKE --add-missing || exit $?
|
||||
autoconf || exit $?
|
||||
cd $ORIGDIR || exit $?
|
||||
|
||||
if test -z "$AUTOGEN_SUBDIR_MODE"; then
|
||||
if test -z "$NOCONFIGURE"; then
|
||||
$srcdir/configure --enable-maintainer-mode $AUTOGEN_CONFIGURE_ARGS "$@" || exit $?
|
||||
|
||||
echo
|
||||
|
||||
518
configure.ac
518
configure.ac
@@ -12,7 +12,7 @@ AC_PREREQ([2.62])
|
||||
|
||||
m4_define([gtk_major_version], [2])
|
||||
m4_define([gtk_minor_version], [90])
|
||||
m4_define([gtk_micro_version], [2])
|
||||
m4_define([gtk_micro_version], [5])
|
||||
m4_define([gtk_interface_age], [0])
|
||||
m4_define([gtk_binary_age],
|
||||
[m4_eval(100 * gtk_minor_version + gtk_micro_version)])
|
||||
@@ -31,10 +31,11 @@ m4_define([gtk_api_version], [3.0])
|
||||
m4_define([gtk_binary_version], [3.0.0])
|
||||
|
||||
# required versions of other packages
|
||||
m4_define([glib_required_version], [2.25.8])
|
||||
m4_define([glib_required_version], [2.25.9])
|
||||
m4_define([pango_required_version], [1.20])
|
||||
m4_define([atk_required_version], [1.29.2])
|
||||
m4_define([cairo_required_version], [1.6])
|
||||
m4_define([cairo_required_version], [1.9.10])
|
||||
m4_define([gdk_pixbuf_required_version], [2.21.0])
|
||||
|
||||
|
||||
AC_INIT([gtk+], [gtk_version],
|
||||
@@ -107,19 +108,6 @@ m4_define([gail_lt_current_minus_age],[m4_eval(gail_lt_current - gail_lt_age)])
|
||||
AC_SUBST([GAIL_LT_VERSION_INFO],[gail_lt_version_info])
|
||||
AC_SUBST([GAIL_LT_CURRENT_MINUS_AGE],[gail_lt_current_minus_age])
|
||||
|
||||
#
|
||||
# gdk-pixbuf gets versioned separately, and for now, using standard
|
||||
# libtool versioning, not GTK+-style versioning
|
||||
#
|
||||
GDK_PIXBUF_MAJOR=gtk_major_version
|
||||
GDK_PIXBUF_MINOR=gtk_minor_version
|
||||
GDK_PIXBUF_MICRO=gtk_micro_version
|
||||
GDK_PIXBUF_VERSION="${GDK_PIXBUF_MAJOR}.${GDK_PIXBUF_MINOR}.${GDK_PIXBUF_MICRO}"
|
||||
AC_SUBST(GDK_PIXBUF_MAJOR)
|
||||
AC_SUBST(GDK_PIXBUF_MINOR)
|
||||
AC_SUBST(GDK_PIXBUF_MICRO)
|
||||
AC_SUBST(GDK_PIXBUF_VERSION)
|
||||
|
||||
# Checks for programs.
|
||||
AC_PROG_CC
|
||||
AC_PROG_CC_C_O
|
||||
@@ -376,7 +364,8 @@ PKG_CHECK_MODULES(BASE_DEPENDENCIES,
|
||||
[glib-2.0 >= glib_required_version dnl
|
||||
atk >= atk_required_version dnl
|
||||
pango >= pango_required_version dnl
|
||||
cairo >= cairo_required_version])
|
||||
cairo >= cairo_required_version dnl
|
||||
gdk-pixbuf-2.0 >= gdk_pixbuf_required_version])
|
||||
|
||||
## In addition to checking that cairo is present, we also need to
|
||||
## check that the correct cairo backend is there. E.g. if the GDK
|
||||
@@ -396,7 +385,7 @@ if test "$os_win32" != yes; then
|
||||
# right now, symbols starting with _ are not exported
|
||||
LIBTOOL_EXPORT_OPTIONS='-export-symbols-regex "^[[^_]].*"'
|
||||
else
|
||||
# We currently use .def files on Windows (for gdk-pixbuf, gdk and gtk)
|
||||
# We currently use .def files on Windows (for gdk and gtk)
|
||||
LIBTOOL_EXPORT_OPTIONS=
|
||||
fi
|
||||
AC_SUBST(LIBTOOL_EXPORT_OPTIONS)
|
||||
@@ -605,7 +594,7 @@ AC_TRY_COMPILE([#include <dirent.h>], [DIR *dir;],
|
||||
# Run AM_PATH_GLIB_2_0 to make sure that GLib is installed and working
|
||||
#
|
||||
|
||||
GLIB_PACKAGES="gobject-2.0 gmodule-no-export-2.0"
|
||||
GLIB_PACKAGES="gobject-2.0 gio-2.0 gmodule-no-export-2.0"
|
||||
|
||||
AM_PATH_GLIB_2_0(glib_required_version, :,
|
||||
AC_MSG_ERROR([
|
||||
@@ -751,27 +740,7 @@ AC_MSG_RESULT($gtk_uxtheme_h)
|
||||
AC_CHECK_HEADERS(crt_externs.h)
|
||||
AC_CHECK_FUNCS(_NSGetEnviron)
|
||||
|
||||
|
||||
##################################################
|
||||
# Checks for gdk-pixbuf
|
||||
##################################################
|
||||
|
||||
dnl ********************************************************
|
||||
dnl * See whether we need to load our modules as .la files *
|
||||
dnl ********************************************************
|
||||
|
||||
use_la_modules=false
|
||||
case $host in
|
||||
*-aix*) use_la_modules=true
|
||||
esac
|
||||
|
||||
if $use_la_modules ; then
|
||||
AC_DEFINE(USE_LA_MODULES, 1,
|
||||
[Whether to load modules via .la files rather than directly])
|
||||
fi
|
||||
|
||||
|
||||
AC_MSG_CHECKING(whether to build gmodulized gdk-pixbuf)
|
||||
AC_MSG_CHECKING(whether to build dynamic modules)
|
||||
|
||||
AC_ARG_ENABLE(modules,
|
||||
[AC_HELP_STRING([--disable-modules],
|
||||
@@ -793,13 +762,13 @@ else
|
||||
dnl Now we check to see if our libtool supports shared lib deps
|
||||
dnl (in a rather ugly way even)
|
||||
if $dynworks; then
|
||||
pixbuf_libtool_config="${CONFIG_SHELL-/bin/sh} ./libtool --config"
|
||||
pixbuf_deplibs_check=`$pixbuf_libtool_config | \
|
||||
module_libtool_config="${CONFIG_SHELL-/bin/sh} ./libtool --config"
|
||||
module_deplibs_check=`$module_libtool_config | \
|
||||
grep '^[[a-z_]]*check[[a-z_]]*_method=[['\''"]]' | \
|
||||
sed 's/.*[['\''"]]\(.*\)[['\''"]]$/\1/'`
|
||||
if test "x$pixbuf_deplibs_check" = "xnone" || \
|
||||
test "x$pixbuf_deplibs_check" = "xunknown" || \
|
||||
test "x$pixbuf_deplibs_check" = "x"; then
|
||||
if test "x$module_deplibs_check" = "xnone" || \
|
||||
test "x$module_deplibs_check" = "xunknown" || \
|
||||
test "x$module_deplibs_check" = "x"; then
|
||||
dynworks=false
|
||||
fi
|
||||
fi
|
||||
@@ -813,298 +782,8 @@ else
|
||||
fi
|
||||
fi
|
||||
|
||||
dnl We allow people to disable image loaders explicitely, but if they don't we error
|
||||
dnl out so that people don't accidentally build without them.
|
||||
|
||||
AC_ARG_WITH(libpng,
|
||||
[AC_HELP_STRING([--without-libpng],
|
||||
[disable PNG loader for gdk-pixbuf])])
|
||||
AC_ARG_WITH(libjpeg,
|
||||
[AC_HELP_STRING([--without-libjpeg],
|
||||
[disable JPEG loader for gdk-pixbuf])])
|
||||
AC_ARG_WITH(libtiff,
|
||||
[AC_HELP_STRING([--without-libtiff],
|
||||
[disable TIFF loader for gdk-pixbuf])])
|
||||
AC_ARG_WITH(libjasper,
|
||||
[AC_HELP_STRING([--with-libjasper],
|
||||
[enable JPEG2000 loader for gdk-pixbuf])])
|
||||
|
||||
AC_ARG_ENABLE(gdiplus,
|
||||
[AC_HELP_STRING([--enable-gdiplus],
|
||||
[enble GDI+ loaders for gdk-pixbuf (currently known to be broken)])],,
|
||||
[enable_gdiplus=no])
|
||||
|
||||
AM_CONDITIONAL(BUILD_GDIPLUS_LOADERS, [ test x$os_win32 = xyes && test x$enable_gdiplus != xno ])
|
||||
|
||||
dnl Test for libtiff
|
||||
if test x$os_win32 = xno || test x$enable_gdiplus = xno; then
|
||||
if test x$with_libtiff != xno && test -z "$LIBTIFF"; then
|
||||
AC_CHECK_LIB(tiff, TIFFReadRGBAImageOriented,
|
||||
[AC_CHECK_HEADER(tiffio.h,
|
||||
TIFF='tiff'; LIBTIFF='-ltiff',
|
||||
AC_MSG_WARN(*** TIFF loader will not be built (TIFF header files not found) ***))],
|
||||
[AC_CHECK_LIB(tiff, TIFFWriteScanline,
|
||||
[AC_CHECK_HEADER(tiffio.h,
|
||||
TIFF='tiff'; LIBTIFF='-ltiff -ljpeg -lz',
|
||||
AC_MSG_WARN(*** TIFF loader will not be built (TIFF header files not found) ***))],
|
||||
[AC_CHECK_LIB(tiff34, TIFFFlushData,
|
||||
[AC_CHECK_HEADER(tiffio.h,
|
||||
TIFF='tiff'; LIBTIFF='-ltiff34 -ljpeg -lz',
|
||||
AC_MSG_WARN(*** TIFF loader will not be built (TIFF header files not found) ***))],
|
||||
AC_MSG_WARN(*** TIFF loader will not be built (TIFF library not found) ***), -ljpeg -lz -lm)], -ljpeg -lz -lm)], -lm)
|
||||
fi
|
||||
|
||||
if test x$with_libtiff != xno && test -z "$LIBTIFF"; then
|
||||
AC_MSG_ERROR([
|
||||
*** Checks for TIFF loader failed. You can build without it by passing
|
||||
*** --without-libtiff to configure but some programs using GTK+ may
|
||||
*** not work properly])
|
||||
fi
|
||||
fi
|
||||
|
||||
dnl Test for libjpeg
|
||||
if test x$os_win32 = xno || test x$enable_gdiplus = xno; then
|
||||
if test x$with_libjpeg != xno && test -z "$LIBJPEG"; then
|
||||
AC_CHECK_LIB(jpeg, jpeg_destroy_decompress,
|
||||
jpeg_ok=yes,
|
||||
jpeg_ok=no
|
||||
AC_MSG_WARN(*** JPEG loader will not be built (JPEG library not found) ***))
|
||||
if test "$jpeg_ok" = yes; then
|
||||
AC_MSG_CHECKING([for jpeglib.h])
|
||||
AC_TRY_CPP(
|
||||
[#include <stdio.h>
|
||||
#undef PACKAGE
|
||||
#undef VERSION
|
||||
#undef HAVE_STDLIB_H
|
||||
#include <jpeglib.h>],
|
||||
jpeg_ok=yes,
|
||||
jpeg_ok=no)
|
||||
AC_MSG_RESULT($jpeg_ok)
|
||||
if test "$jpeg_ok" = yes; then
|
||||
LIBJPEG='-ljpeg'
|
||||
AC_CHECK_LIB(jpeg, jpeg_simple_progression,
|
||||
AC_DEFINE(HAVE_PROGRESSIVE_JPEG, 1,
|
||||
[Define to 1 is libjpeg supports progressive JPEG]),
|
||||
AC_MSG_WARN(JPEG library does not support progressive saving.))
|
||||
else
|
||||
AC_MSG_WARN(*** JPEG loader will not be built (JPEG header file not found) ***)
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
if test x$with_libjpeg != xno && test -z "$LIBJPEG"; then
|
||||
AC_MSG_ERROR([
|
||||
*** Checks for JPEG loader failed. You can build without it by passing
|
||||
*** --without-libjpeg to configure but some programs using GTK+ may
|
||||
*** not work properly])
|
||||
fi
|
||||
fi
|
||||
|
||||
dnl Test for libpng
|
||||
if test x$with_libpng != xno && test -z "$LIBPNG"; then
|
||||
AC_MSG_CHECKING(for libpng12)
|
||||
if $PKG_CONFIG --exists libpng12 ; then
|
||||
AC_MSG_RESULT(yes)
|
||||
PNG='png'
|
||||
PNG_DEP_CFLAGS_PACKAGES=libpng12
|
||||
LIBPNG=`$PKG_CONFIG --libs libpng12`
|
||||
else
|
||||
AC_MSG_RESULT(no)
|
||||
AC_CHECK_LIB(png, png_read_info,
|
||||
[AC_CHECK_HEADER(png.h,
|
||||
png_ok=yes,
|
||||
png_ok=no)],
|
||||
AC_MSG_WARN(*** PNG loader will not be built (PNG library not found) ***), -lz -lm)
|
||||
if test "$png_ok" = yes; then
|
||||
AC_MSG_CHECKING([for png_structp in png.h])
|
||||
AC_TRY_COMPILE([#include <png.h>],
|
||||
[png_structp pp; png_infop info; png_colorp cmap; png_create_read_struct;],
|
||||
png_ok=yes,
|
||||
png_ok=no)
|
||||
AC_MSG_RESULT($png_ok)
|
||||
if test "$png_ok" = yes; then
|
||||
PNG='png'; LIBPNG='-lpng -lz'
|
||||
else
|
||||
AC_MSG_WARN(*** PNG loader will not be built (PNG library is too old) ***)
|
||||
fi
|
||||
else
|
||||
AC_MSG_WARN(*** PNG loader will not be built (PNG header file not found) ***)
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
if test x$with_libpng != xno && test -z "$LIBPNG"; then
|
||||
AC_MSG_ERROR([
|
||||
*** Checks for PNG loader failed. You can build without it by passing
|
||||
*** --without-libpng to configure but many programs using GTK+ will
|
||||
*** not work properly. The PNG loader is also needed if you are compiling
|
||||
*** from CVS.])
|
||||
fi
|
||||
|
||||
dnl Test for libjasper
|
||||
if test x$with_libjasper = xyes && test -z "$LIBJASPER"; then
|
||||
AC_CHECK_LIB(jasper, jas_init, LIBJASPER=-ljasper, [], -ljpeg -lm)
|
||||
fi
|
||||
|
||||
if test x$with_libjasper = xyes && test -z "$LIBJASPER"; then
|
||||
AC_MSG_ERROR([
|
||||
*** Checks for JPEG2000 loader failed. You can build without it by passing
|
||||
*** --without-libjasper to configure])
|
||||
fi
|
||||
|
||||
AC_SUBST(LIBTIFF)
|
||||
AC_SUBST(LIBJPEG)
|
||||
AC_SUBST(LIBPNG)
|
||||
AC_SUBST(LIBJASPER)
|
||||
|
||||
AM_CONDITIONAL(BUILD_DYNAMIC_MODULES, $dynworks)
|
||||
|
||||
#
|
||||
# Allow building some or all gdk-pixbuf loaders included
|
||||
#
|
||||
AC_MSG_CHECKING(pixbuf loaders to build)
|
||||
|
||||
dnl due to an autoconf bug, commas in the first arg to
|
||||
dnl AC_HELP_STRING cause problems.
|
||||
dnl AC_HELP_STRING([--with-included-loaders=LOADER1 LOADER2 ...],
|
||||
dnl [build the specified loaders into gdk-pixbuf])
|
||||
AC_ARG_WITH(included_loaders,
|
||||
[ --with-included-loaders=LOADER1,LOADER2,...
|
||||
build the specified loaders into gdk-pixbuf])
|
||||
|
||||
if $dynworks; then
|
||||
:
|
||||
else
|
||||
## if the option was specified, leave it; otherwise disable included loaders
|
||||
if test x$with_included_loaders = xno; then
|
||||
with_included_loaders=yes
|
||||
fi
|
||||
fi
|
||||
|
||||
# Use the traditional png loader instead of the GDI+ one on Windows,
|
||||
# because some important apps like GIMP need to read and write
|
||||
# arbitrary tEXt chunks which doesn't seem to be possible through GDI+
|
||||
|
||||
all_loaders="ani,icns,pcx,ras,tga,png,pnm,wbmp,xbm,xpm,qtif"
|
||||
if test x$with_libjasper != xno; then
|
||||
all_loaders="$all_loaders,jasper"
|
||||
fi
|
||||
if test x$os_win32 = xyes && test x$enable_gdiplus != xno; then
|
||||
# Skip PNG, see comment above
|
||||
gdip_formats="bmp emf gif ico jpeg tiff wmf"
|
||||
for f in $gdip_formats; do
|
||||
all_loaders="$all_loaders,gdip-$f"
|
||||
done
|
||||
else
|
||||
all_loaders="$all_loaders,bmp,gif,ico,jpeg,tiff"
|
||||
fi
|
||||
included_loaders=""
|
||||
# If no loaders specified, include all
|
||||
if test "x$with_included_loaders" = xyes ; then
|
||||
included_loaders="$all_loaders"
|
||||
else
|
||||
included_loaders="$with_included_loaders"
|
||||
fi
|
||||
|
||||
AC_MSG_RESULT($included_loaders)
|
||||
|
||||
INCLUDED_LOADER_OBJ=
|
||||
INCLUDED_LOADER_DEFINE=
|
||||
|
||||
IFS="${IFS= }"; gtk_save_ifs="$IFS"; IFS=","
|
||||
for loader in $included_loaders; do
|
||||
if echo "$all_loaders" | egrep "(^|,)$loader(\$|,)" > /dev/null; then
|
||||
:
|
||||
else
|
||||
AC_MSG_ERROR([the specified loader $loader does not exist])
|
||||
fi
|
||||
|
||||
loader_underscores=`echo $loader | sed -e 's/-/_/g'`
|
||||
INCLUDED_LOADER_OBJ="$INCLUDED_LOADER_OBJ libstatic-pixbufloader-$loader.la"
|
||||
|
||||
# Don't bother defining separate -DINCLUDE_gdip_foo for each gdip-foo loader
|
||||
case $loader in
|
||||
gdip-*) ;;
|
||||
*) INCLUDED_LOADER_DEFINE="$INCLUDED_LOADER_DEFINE -DINCLUDE_$loader_underscores";;
|
||||
esac
|
||||
eval INCLUDE_$loader_underscores=yes
|
||||
done
|
||||
|
||||
# Just define one -DINCLUDE_gdiplus for all the gdip-foo loaders
|
||||
# (except gdip-png, which isn't built at all)
|
||||
if test x"$INCLUDE_gdip_ico" = xyes; then
|
||||
INCLUDED_LOADER_DEFINE="$INCLUDED_LOADER_DEFINE -DINCLUDE_gdiplus"
|
||||
fi
|
||||
|
||||
IFS="$gtk_save_ifs"
|
||||
AC_SUBST(INCLUDED_LOADER_OBJ)
|
||||
AC_SUBST(INCLUDED_LOADER_DEFINE)
|
||||
|
||||
AM_CONDITIONAL(INCLUDE_PNG, [test x"$INCLUDE_png" = xyes])
|
||||
AM_CONDITIONAL(INCLUDE_BMP, [test x"$INCLUDE_bmp" = xyes])
|
||||
AM_CONDITIONAL(INCLUDE_WBMP, [test x"$INCLUDE_wbmp" = xyes])
|
||||
AM_CONDITIONAL(INCLUDE_GIF, [test x"$INCLUDE_gif" = xyes])
|
||||
AM_CONDITIONAL(INCLUDE_ICO, [test x"$INCLUDE_ico" = xyes])
|
||||
AM_CONDITIONAL(INCLUDE_ANI, [test x"$INCLUDE_ani" = xyes])
|
||||
AM_CONDITIONAL(INCLUDE_JPEG, [test x"$INCLUDE_jpeg" = xyes])
|
||||
AM_CONDITIONAL(INCLUDE_PNM, [test x"$INCLUDE_pnm" = xyes])
|
||||
AM_CONDITIONAL(INCLUDE_RAS, [test x"$INCLUDE_ras" = xyes])
|
||||
AM_CONDITIONAL(INCLUDE_TIFF, [test x"$INCLUDE_tiff" = xyes])
|
||||
AM_CONDITIONAL(INCLUDE_XPM, [test x"$INCLUDE_xpm" = xyes])
|
||||
AM_CONDITIONAL(INCLUDE_XBM, [test x"$INCLUDE_xbm" = xyes])
|
||||
AM_CONDITIONAL(INCLUDE_TGA, [test x"$INCLUDE_tga" = xyes])
|
||||
AM_CONDITIONAL(INCLUDE_PCX, [test x"$INCLUDE_pcx" = xyes])
|
||||
AM_CONDITIONAL(INCLUDE_ICNS, [test x"$INCLUDE_icns" = xyes])
|
||||
AM_CONDITIONAL(INCLUDE_JASPER, [test x"$INCLUDE_jasper" = xyes])
|
||||
AM_CONDITIONAL(INCLUDE_QTIF, [test x"$INCLUDE_qtif" = xyes])
|
||||
# As all GDI+ loaders are either built-in or not, arbitrarily just
|
||||
# check one of the variables here
|
||||
AM_CONDITIONAL(INCLUDE_GDIPLUS, [test x"$INCLUDE_gdip_ico" = xyes])
|
||||
|
||||
if test x$gio_can_sniff = x; then
|
||||
AC_MSG_CHECKING([if gio can sniff png])
|
||||
gtk_save_LIBS="$LIBS"
|
||||
gtk_save_CFLAGS="$CFLAGS"
|
||||
LIBS="`$PKG_CONFIG --libs gio-2.0`"
|
||||
CFLAGS="`$PKG_CONFIG --cflags gio-2.0`"
|
||||
AC_RUN_IFELSE([AC_LANG_SOURCE([[
|
||||
#include <gio/gio.h>
|
||||
static const gsize data_size = 159;
|
||||
static const guint8 data[] =
|
||||
{
|
||||
0x89, 0x50, 0x4e, 0x47, 0x0d, 0x0a, 0x1a, 0x0a, 0x00, 0x00, 0x00, 0x0d,
|
||||
0x49, 0x48, 0x44, 0x52, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x01,
|
||||
0x08, 0x02, 0x00, 0x00, 0x00, 0x90, 0x77, 0x53, 0xde, 0x00, 0x00, 0x00,
|
||||
0x01, 0x73, 0x52, 0x47, 0x42, 0x00, 0xae, 0xce, 0x1c, 0xe9, 0x00, 0x00,
|
||||
0x00, 0x09, 0x70, 0x48, 0x59, 0x73, 0x00, 0x00, 0x0b, 0x13, 0x00, 0x00,
|
||||
0x0b, 0x13, 0x01, 0x00, 0x9a, 0x9c, 0x18, 0x00, 0x00, 0x00, 0x07, 0x74,
|
||||
0x49, 0x4d, 0x45, 0x07, 0xd8, 0x07, 0x0f, 0x10, 0x08, 0x15, 0x61, 0xd8,
|
||||
0x35, 0x37, 0x00, 0x00, 0x00, 0x19, 0x74, 0x45, 0x58, 0x74, 0x43, 0x6f,
|
||||
0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x00, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65,
|
||||
0x64, 0x20, 0x77, 0x69, 0x74, 0x68, 0x20, 0x47, 0x49, 0x4d, 0x50, 0x57,
|
||||
0x81, 0x0e, 0x17, 0x00, 0x00, 0x00, 0x0c, 0x49, 0x44, 0x41, 0x54, 0x08,
|
||||
0xd7, 0x63, 0xf8, 0xff, 0xff, 0x3f, 0x00, 0x05, 0xfe, 0x02, 0xfe, 0xdc,
|
||||
0xcc, 0x59, 0xe7, 0x00, 0x00, 0x00, 0x00, 0x49, 0x45, 0x4e, 0x44, 0xae,
|
||||
0x42, 0x60, 0x82
|
||||
};
|
||||
int
|
||||
main (int argc, char **argv)
|
||||
{
|
||||
char *content_type;
|
||||
char *image_png;
|
||||
g_type_init ();
|
||||
content_type = g_content_type_guess (NULL, data, data_size, NULL);
|
||||
image_png = g_content_type_from_mime_type ("image/png");
|
||||
return !!g_strcmp0 (content_type, image_png);
|
||||
}]])],
|
||||
[gio_can_sniff=yes
|
||||
AC_DEFINE(GDK_PIXBUF_USE_GIO_MIME, 1, [Define if gio can sniff image data])],
|
||||
[gio_can_sniff=no])
|
||||
AC_MSG_RESULT($gio_can_sniff)
|
||||
LIBS="$gtk_save_LIBS"
|
||||
CFLAGS="$gtk_save_CFLAGS"
|
||||
fi
|
||||
|
||||
#
|
||||
# Allow building some or all immodules included
|
||||
#
|
||||
@@ -1184,29 +863,6 @@ AC_HEADER_SYS_WAIT
|
||||
|
||||
AC_TYPE_SIGNAL
|
||||
|
||||
AM_CONDITIONAL(HAVE_TIFF, test "x$LIBTIFF" != x)
|
||||
AM_CONDITIONAL(HAVE_PNG, test "x$LIBPNG" != x)
|
||||
AM_CONDITIONAL(HAVE_JPEG, test "x$LIBJPEG" != x)
|
||||
AM_CONDITIONAL(HAVE_JASPER, test "x$LIBJASPER" != x)
|
||||
|
||||
if $dynworks ; then
|
||||
STATIC_LIB_DEPS=
|
||||
if echo "$included_loaders" | egrep '(^|,)tiff($|,)' > /dev/null; then
|
||||
STATIC_LIB_DEPS="$STATIC_LIB_DEPS $LIBTIFF"
|
||||
fi
|
||||
if echo "$included_loaders" | egrep '(^|,)jpeg($|,)' > /dev/null; then
|
||||
STATIC_LIB_DEPS="$STATIC_LIB_DEPS $LIBJPEG"
|
||||
fi
|
||||
if echo "$included_loaders" | egrep '(^|,)png($|,)' > /dev/null; then
|
||||
STATIC_LIB_DEPS="$STATIC_LIB_DEPS $LIBPNG"
|
||||
fi
|
||||
if echo "$included_loaders" | egrep '(^|,)jasper($|,)' > /dev/null; then
|
||||
STATIC_LIB_DEPS="$STATIC_LIB_DEPS $LIBJASPER"
|
||||
fi
|
||||
else
|
||||
STATIC_LIB_DEPS="$LIBTIFF $LIBJPEG $LIBPNG $LIBJASPER"
|
||||
fi
|
||||
|
||||
# Checks to see whether we should include mediaLib
|
||||
# support.
|
||||
#
|
||||
@@ -1239,64 +895,19 @@ fi
|
||||
AM_CONDITIONAL(USE_MEDIALIB, test $use_mlib = yes)
|
||||
AM_CONDITIONAL(USE_MEDIALIB25, test $use_mlib25 = yes)
|
||||
|
||||
# Checks to see if we should compile in MMX support (there will be
|
||||
# a runtime test when the code is actually run to see if it should
|
||||
# be used - this just checks if we can compile it.)
|
||||
#
|
||||
# This code is partially taken from Mesa
|
||||
#
|
||||
AC_MSG_CHECKING(for x86 platform)
|
||||
case $host_cpu in
|
||||
i386|i486|i586|i686|i786|k6|k7)
|
||||
use_x86_asm=yes
|
||||
;;
|
||||
*)
|
||||
use_x86_asm=no
|
||||
esac
|
||||
AC_MSG_RESULT($use_x86_asm)
|
||||
|
||||
use_mmx_asm=no
|
||||
if test $use_x86_asm = yes; then
|
||||
save_ac_ext=$ac_ext
|
||||
ac_ext=S
|
||||
|
||||
AC_MSG_CHECKING(compiler support for MMX)
|
||||
cp $srcdir/gdk-pixbuf/pixops/scale_line_22_33_mmx.S conftest.S
|
||||
if AC_TRY_EVAL(ac_compile); then
|
||||
use_mmx_asm=yes
|
||||
fi
|
||||
|
||||
rm -rf conftest*
|
||||
|
||||
ac_ext=$save_ac_ext
|
||||
if test $use_mmx_asm = yes; then
|
||||
AC_DEFINE(USE_MMX, 1,
|
||||
[Define to 1 if XXM is available and should be used])
|
||||
AC_MSG_RESULT(yes)
|
||||
else
|
||||
AC_MSG_RESULT(no)
|
||||
fi
|
||||
fi
|
||||
|
||||
AM_CONDITIONAL(USE_MMX, test x$use_mmx_asm = xyes)
|
||||
|
||||
REBUILD_PNGS=
|
||||
if test -z "$LIBPNG" && test x"$os_win32" = xno -o x$enable_gdiplus = xno; then
|
||||
REBUILD_PNGS=#
|
||||
fi
|
||||
|
||||
dnl Look for a host system's gdk-pixbuf-csource if we are cross-compiling
|
||||
|
||||
AM_CONDITIONAL(CROSS_COMPILING, test $cross_compiling = yes)
|
||||
|
||||
if test $cross_compiling = yes; then
|
||||
AC_PATH_PROG(GDK_PIXBUF_CSOURCE, gdk-pixbuf-csource, no)
|
||||
AC_PATH_PROG(GTK_UPDATE_ICON_CACHE, gtk-update-icon-cache, no)
|
||||
if test x$GTK_UPDATE_ICON_CACHE = xno; then
|
||||
REBUILD_PNGS=#
|
||||
fi
|
||||
fi
|
||||
|
||||
AC_PATH_PROG(GDK_PIXBUF_CSOURCE, gdk-pixbuf-csource, no)
|
||||
|
||||
if test ! -f $srcdir/gtk/gtkbuiltincache.h &&
|
||||
test "x$REBUILD_PNGS" = "x#" ; then
|
||||
AC_MSG_ERROR([
|
||||
@@ -1305,22 +916,10 @@ if test ! -f $srcdir/gtk/gtkbuiltincache.h &&
|
||||
*** don't have a prebuilt gtk-update-icon-cache on the build system.])
|
||||
fi
|
||||
|
||||
AC_SUBST(REBUILD_PNGS)
|
||||
|
||||
GDK_PIXBUF_PACKAGES="gmodule-no-export-2.0 gobject-2.0 gio-2.0"
|
||||
GDK_PIXBUF_EXTRA_LIBS="$STATIC_LIB_DEPS $MATH_LIB $MEDIA_LIB"
|
||||
GDK_PIXBUF_EXTRA_CFLAGS=
|
||||
GDK_PIXBUF_DEP_LIBS="`$PKG_CONFIG --libs $GDK_PIXBUF_PACKAGES` $GDK_PIXBUF_EXTRA_LIBS"
|
||||
GDK_PIXBUF_DEP_CFLAGS="`$PKG_CONFIG --cflags gthread-2.0 $GDK_PIXBUF_PACKAGES $PNG_DEP_CFLAGS_PACKAGES` $GDK_PIXBUF_EXTRA_CFLAGS"
|
||||
|
||||
########################################
|
||||
# Windowing system checks
|
||||
########################################
|
||||
|
||||
GDK_PIXBUF_XLIB_PACKAGES=
|
||||
GDK_PIXBUF_XLIB_EXTRA_CFLAGS=
|
||||
GDK_PIXBUF_XLIB_EXTRA_LIBS=
|
||||
|
||||
GDK_EXTRA_LIBS="$GDK_WLIBS"
|
||||
GDK_EXTRA_CFLAGS=
|
||||
|
||||
@@ -1359,7 +958,6 @@ if test "x$gdktarget" = "xx11"; then
|
||||
esac
|
||||
done
|
||||
|
||||
GDK_PIXBUF_XLIB_PACKAGES="x11"
|
||||
GTK_PACKAGES_FOR_X="x11"
|
||||
else
|
||||
have_base_x_pc=false
|
||||
@@ -1371,8 +969,6 @@ if test "x$gdktarget" = "xx11"; then
|
||||
x_cflags="$X_CFLAGS"
|
||||
x_libs_for_checks="$X_LIBS -lXext -lXrender -lX11 $X_EXTRA_LIBS"
|
||||
|
||||
GDK_PIXBUF_XLIB_EXTRA_CFLAGS="$x_cflags"
|
||||
GDK_PIXBUF_XLIB_EXTRA_LIBS="$X_LIBS -lX11 $X_EXTRA_LIBS"
|
||||
GTK_DEP_LIBS_FOR_X="$X_LIBS -lXrender -lX11 $X_EXTRA_LIBS"
|
||||
fi
|
||||
|
||||
@@ -1562,6 +1158,8 @@ if test "x$gdktarget" = "xx11"; then
|
||||
|
||||
# set up things for XInput
|
||||
if test "x$with_xinput" != "xno" && $PKG_CONFIG --exists "xi" ; then
|
||||
have_xinput=yes
|
||||
|
||||
AC_DEFINE(XINPUT_XFREE, 1,
|
||||
[Define to 1 if XFree XInput should be used])
|
||||
|
||||
@@ -1574,8 +1172,7 @@ if test "x$gdktarget" = "xx11"; then
|
||||
[Define to 1 if no XInput should be used])
|
||||
fi
|
||||
|
||||
AM_CONDITIONAL(XINPUT_NONE, test "x$with_xinput" = "xno")
|
||||
AM_CONDITIONAL(XINPUT_XFREE, test "x$with_xinput" != "xno")
|
||||
AM_CONDITIONAL(XINPUT_XFREE, test "x$have_xinput" = "xyes")
|
||||
AM_CONDITIONAL(XINPUT_2, test "x$have_xinput2" = "xyes")
|
||||
|
||||
# Check for the RANDR extension
|
||||
@@ -1653,15 +1250,6 @@ else
|
||||
AM_CONDITIONAL(USE_QUARTZ, false)
|
||||
fi
|
||||
|
||||
GDK_PIXBUF_XLIB_DEP_LIBS="`$PKG_CONFIG --libs $GDK_PIXBUF_PACKAGES $GDK_PIXBUF_XLIB_PACKAGES` $GDK_PIXBUF_XLIB_EXTRA_LIBS $GDK_PIXBUF_EXTRA_LIBS"
|
||||
GDK_PIXBUF_XLIB_DEP_CFLAGS="`$PKG_CONFIG --cflags gthread-2.0 $GDK_PIXBUF_PACKAGES $GDK_PIXBUF_XLIB_PACKAGES` $GDK_PIXBUF_EXTRA_CFLAGS $GDK_PIXBUF_XLIB_EXTRA_CFLAGS"
|
||||
|
||||
AC_SUBST(GDK_PIXBUF_XLIB_PACKAGES)
|
||||
AC_SUBST(GDK_PIXBUF_XLIB_EXTRA_LIBS)
|
||||
AC_SUBST(GDK_PIXBUF_XLIB_EXTRA_CFLAGS)
|
||||
AC_SUBST(GDK_PIXBUF_XLIB_DEP_LIBS)
|
||||
AC_SUBST(GDK_PIXBUF_XLIB_DEP_CFLAGS)
|
||||
|
||||
if test "x$gdktarget" = "xdirectfb"; then
|
||||
DIRECTFB_REQUIRED_VERSION=1.0.0
|
||||
AC_MSG_CHECKING(for DirectFB)
|
||||
@@ -1712,19 +1300,19 @@ LDFLAGS="$saved_ldflags"
|
||||
|
||||
# Pull in gio-unix for GDesktopAppInfo usage, see at least gdkapplaunchcontext-x11.c
|
||||
if test "x$gdktarget" = "xx11"; then
|
||||
GDK_PACKAGES="$PANGO_PACKAGES gio-unix-2.0 $X_PACKAGES cairo-$cairo_backend"
|
||||
GDK_PACKAGES="$PANGO_PACKAGES gio-unix-2.0 $X_PACKAGES gdk-pixbuf-2.0 cairo-$cairo_backend"
|
||||
else
|
||||
GDK_PACKAGES="$PANGO_PACKAGES $X_PACKAGES cairo-$cairo_backend"
|
||||
GDK_PACKAGES="$PANGO_PACKAGES gio-2.0 gdk-pixbuf-2.0 cairo-$cairo_backend"
|
||||
fi
|
||||
|
||||
GDK_DEP_LIBS="$GDK_EXTRA_LIBS `$PKG_CONFIG --libs $GDK_PIXBUF_PACKAGES $GDK_PACKAGES` $GDK_PIXBUF_EXTRA_LIBS"
|
||||
GDK_DEP_CFLAGS="`$PKG_CONFIG --cflags gthread-2.0 $GDK_PIXBUF_PACKAGES $GDK_PACKAGES` $GDK_PIXBUF_EXTRA_CFLAGS $GDK_EXTRA_CFLAGS"
|
||||
GDK_DEP_LIBS="$GDK_EXTRA_LIBS `$PKG_CONFIG --libs $GDK_PACKAGES`"
|
||||
GDK_DEP_CFLAGS="`$PKG_CONFIG --cflags gthread-2.0 $GDK_PACKAGES` $GDK_EXTRA_CFLAGS"
|
||||
#
|
||||
# If we aren't writing explicit dependencies, then don't put the extra libraries we need
|
||||
# into the pkg-config files
|
||||
#
|
||||
if test $enable_explicit_deps != yes ; then
|
||||
GDK_PACKAGES="$PANGO_PACKAGES"
|
||||
GDK_PACKAGES="$PANGO_PACKAGES gdk-pixbuf-2.0"
|
||||
GDK_EXTRA_LIBS=
|
||||
fi
|
||||
|
||||
@@ -1764,14 +1352,14 @@ else
|
||||
LIBS="$gtk_save_LIBS"
|
||||
fi
|
||||
|
||||
GTK_PACKAGES="atk cairo gio-2.0"
|
||||
GTK_PACKAGES="atk cairo gdk-pixbuf-2.0 gio-2.0"
|
||||
if test "x$gdktarget" = "xx11"; then
|
||||
GTK_PACKAGES="$GTK_PACKAGES pangoft2"
|
||||
fi
|
||||
GTK_EXTRA_LIBS=
|
||||
GTK_EXTRA_CFLAGS=
|
||||
GTK_DEP_LIBS="$GDK_EXTRA_LIBS $GTK_DEP_LIBS_FOR_X `$PKG_CONFIG --libs $GDK_PIXBUF_PACKAGES $PANGO_PACKAGES $GTK_PACKAGES_FOR_X $GTK_PACKAGES` $GTK_EXTRA_LIBS $GDK_PIXBUF_EXTRA_LIBS"
|
||||
GTK_DEP_CFLAGS="`$PKG_CONFIG --cflags gthread-2.0 $GDK_PIXBUF_PACKAGES $GDK_PACKAGES $GTK_PACKAGES` $GDK_PIXBUF_EXTRA_CFLAGS $GDK_EXTRA_CFLAGS $GTK_EXTRA_CFLAGS"
|
||||
GTK_DEP_LIBS="$GDK_EXTRA_LIBS $GTK_DEP_LIBS_FOR_X `$PKG_CONFIG --libs $PANGO_PACKAGES $GTK_PACKAGES_FOR_X $GTK_PACKAGES` $GTK_EXTRA_LIBS"
|
||||
GTK_DEP_CFLAGS="`$PKG_CONFIG --cflags gthread-2.0 $GDK_PACKAGES $GTK_PACKAGES` $GDK_EXTRA_CFLAGS $GTK_EXTRA_CFLAGS"
|
||||
|
||||
if test x"$os_win32" = xyes; then
|
||||
GTK_EXTRA_CFLAGS="$msnative_struct"
|
||||
@@ -1782,16 +1370,6 @@ ATK_PREFIX="`$PKG_CONFIG --variable=prefix atk`"
|
||||
PANGO_PREFIX="`$PKG_CONFIG --variable=prefix pango`"
|
||||
CAIRO_PREFIX="`$PKG_CONFIG --variable=prefix cairo`"
|
||||
|
||||
if test $enable_explicit_deps != yes ; then
|
||||
GDK_PIXBUF_EXTRA_LIBS=
|
||||
fi
|
||||
|
||||
AC_SUBST(GDK_PIXBUF_PACKAGES)
|
||||
AC_SUBST(GDK_PIXBUF_EXTRA_LIBS)
|
||||
AC_SUBST(GDK_PIXBUF_EXTRA_CFLAGS)
|
||||
AC_SUBST(GDK_PIXBUF_DEP_LIBS)
|
||||
AC_SUBST(GDK_PIXBUF_DEP_CFLAGS)
|
||||
|
||||
AC_SUBST(GTK_PACKAGES)
|
||||
AC_SUBST(GTK_EXTRA_LIBS)
|
||||
AC_SUBST(GTK_EXTRA_CFLAGS)
|
||||
@@ -1806,6 +1384,9 @@ AC_SUBST(CAIRO_PREFIX)
|
||||
AC_SUBST(GTK_DEBUG_FLAGS)
|
||||
AC_SUBST(GTK_XIM_FLAGS)
|
||||
|
||||
GDK_PIXBUF_LIBS=`$PKG_CONFIG --libs gdk-pixbuf-2.0`
|
||||
AC_SUBST(GDK_PIXBUF_LIBS)
|
||||
|
||||
########################
|
||||
# Checks needed for gail
|
||||
########################
|
||||
@@ -1967,8 +1548,6 @@ AM_CONDITIONAL(TEST_PRINT_BACKEND, test "x$enable_test_print_backend" != "xno")
|
||||
export SED
|
||||
export_dynamic=`(./libtool --config; echo eval echo \\$export_dynamic_flag_spec) | sh`
|
||||
if test -n "$export_dynamic"; then
|
||||
GDK_PIXBUF_DEP_LIBS=`echo $GDK_PIXBUF_DEP_LIBS | sed -e "s/$export_dynamic//"`
|
||||
GDK_PIXBUF_XLIB_DEP_LIBS=`echo $GDK_PIXBUF_XLIB_DEP_LIBS | sed -e "s/$export_dynamic//"`
|
||||
GDK_DEP_LIBS=`echo $GDK_DEP_LIBS | sed -e "s/$export_dynamic//"`
|
||||
GTK_DEP_LIBS=`echo $GTK_DEP_LIBS | sed -e "s/$export_dynamic//"`
|
||||
fi
|
||||
@@ -1977,7 +1556,7 @@ fi
|
||||
# GObject introspection
|
||||
##################################################
|
||||
|
||||
GOBJECT_INTROSPECTION_CHECK([0.6.14])
|
||||
GOBJECT_INTROSPECTION_CHECK([0.9.0])
|
||||
|
||||
##################################################
|
||||
# Checks for gtk-doc and docbook-tools
|
||||
@@ -2092,20 +1671,38 @@ if test x$gdk_working_wctype = xno; then
|
||||
gdk_wc="\$gdk_wc
|
||||
#define GDK_HAVE_BROKEN_WCTYPE 1"
|
||||
fi
|
||||
|
||||
|
||||
])
|
||||
|
||||
dnl
|
||||
dnl Check for -Bsymbolic-functions linker flag used to avoid
|
||||
dnl intra-library PLT jumps, if available.
|
||||
dnl
|
||||
AC_ARG_ENABLE(Bsymbolic,
|
||||
[AC_HELP_STRING([--disable-Bsymbolic],
|
||||
[avoid linking with -Bsymbolic])],,
|
||||
[SAVED_LDFLAGS="${LDFLAGS}"
|
||||
AC_MSG_CHECKING([for -Bsymbolic-functions linker flag])
|
||||
LDFLAGS=-Wl,-Bsymbolic-functions
|
||||
AC_TRY_LINK([], [int main (void) { return 0; }],
|
||||
AC_MSG_RESULT(yes)
|
||||
enable_Bsymbolic=yes,
|
||||
AC_MSG_RESULT(no)
|
||||
enable_Bsymbolic=no)
|
||||
LDFLAGS="${SAVED_LDFLAGS}"])
|
||||
|
||||
if test "x${enable_Bsymbolic}" == "xyes"; then
|
||||
GTK_LINK_FLAGS=-Wl,-Bsymbolic-functions
|
||||
fi
|
||||
AC_SUBST(GTK_LINK_FLAGS)
|
||||
|
||||
AC_CONFIG_FILES([
|
||||
config.h.win32
|
||||
gtk-zip.sh
|
||||
Makefile
|
||||
gdk-pixbuf-3.0.pc
|
||||
gdk-3.0.pc
|
||||
gtk+-3.0.pc
|
||||
gtk+-unix-print-3.0.pc
|
||||
gail-3.0.pc
|
||||
gdk-pixbuf-3.0-uninstalled.pc
|
||||
gdk-3.0-uninstalled.pc
|
||||
gtk+-3.0-uninstalled.pc
|
||||
gail-3.0-uninstalled.pc
|
||||
@@ -2118,8 +1715,6 @@ demos/gtk-demo/geninclude.pl
|
||||
tests/Makefile
|
||||
docs/Makefile
|
||||
docs/reference/Makefile
|
||||
docs/reference/gdk-pixbuf/Makefile
|
||||
docs/reference/gdk-pixbuf/version.xml
|
||||
docs/reference/gdk/Makefile
|
||||
docs/reference/gdk/version.xml
|
||||
docs/reference/gtk/Makefile
|
||||
@@ -2131,10 +1726,6 @@ docs/tutorial/Makefile
|
||||
build/Makefile
|
||||
build/win32/Makefile
|
||||
build/win32/vs9/Makefile
|
||||
gdk-pixbuf/Makefile
|
||||
gdk-pixbuf/gdk_pixbuf.rc
|
||||
gdk-pixbuf/gdk-pixbuf-features.h
|
||||
gdk-pixbuf/pixops/Makefile
|
||||
gdk/Makefile
|
||||
gdk/x11/Makefile
|
||||
gdk/win32/Makefile
|
||||
@@ -2167,9 +1758,6 @@ modules/printbackends/file/Makefile
|
||||
modules/printbackends/papi/Makefile
|
||||
modules/printbackends/test/Makefile
|
||||
perf/Makefile
|
||||
contrib/Makefile
|
||||
contrib/gdk-pixbuf-xlib/Makefile
|
||||
contrib/gdk-pixbuf-xlib/gdk-pixbuf-xlib-3.0.pc
|
||||
])
|
||||
|
||||
AC_OUTPUT
|
||||
|
||||
@@ -1,8 +0,0 @@
|
||||
include $(top_srcdir)/Makefile.decl
|
||||
|
||||
SUBDIRS =
|
||||
if USE_X11
|
||||
SUBDIRS += gdk-pixbuf-xlib
|
||||
endif
|
||||
|
||||
-include $(top_srcdir)/git.mk
|
||||
@@ -1,354 +0,0 @@
|
||||
=== ChangeLog discontinued ===
|
||||
|
||||
With the move to git, GTK+ is switching from a ChangeLog file
|
||||
to relying on commit messages to provide change history. Please
|
||||
see README.commits for guidance on the expected message format.
|
||||
|
||||
2009-03-13 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.16.0 ===
|
||||
|
||||
2009-03-02 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.15.5 ===
|
||||
|
||||
2009-02-17 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.15.4 ===
|
||||
|
||||
2009-02-02 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.15.3 ===
|
||||
|
||||
2009-01-27 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.15.2 ===
|
||||
|
||||
2009-01-23 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.15.1 ===
|
||||
|
||||
2009-01-01 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.15.0 ===
|
||||
|
||||
2008-09-17 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.14.2 ===
|
||||
|
||||
2008-09-04 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.14.1 ===
|
||||
|
||||
2008-09-04 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.14.0 ===
|
||||
|
||||
2008-08-18 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* ==== Released 2.13.7 ===
|
||||
|
||||
2008-08-05 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.13.6 ===
|
||||
|
||||
2008-07-21 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.13.5 ===
|
||||
|
||||
2008-07-05 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.13.4 ===
|
||||
|
||||
2008-06-13 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.13.3 ===
|
||||
|
||||
2008-06-03 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.13.2 ===
|
||||
|
||||
2008-05-29 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.13.1 ===
|
||||
|
||||
2008-05-26 Michael Natterer <mitch@imendio.com>
|
||||
|
||||
* gdk-pixbuf-xlib.h
|
||||
* gdk-pixbuf-xlibrgb.h: use G_BEGIN/END_DECLS.
|
||||
|
||||
2008-02-16 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.13.0 ===
|
||||
|
||||
2007-10-16 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.12.1 ===
|
||||
|
||||
2007-09-13 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.12.0 ===
|
||||
|
||||
2007-07-21 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.11.6 ===
|
||||
|
||||
2007-07-02 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.11.5 ===
|
||||
|
||||
2007-06-19 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.11.4 ===
|
||||
|
||||
2007-06-15 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.11.3 ===
|
||||
|
||||
2007-06-06 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.11.2 ===
|
||||
|
||||
2007-06-04 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.11.1 ===
|
||||
|
||||
2007-05-24 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.11.0 ===
|
||||
|
||||
2006-10-08 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* gdk-pixbuf-xlib.c: Apply a cleanup patch by
|
||||
Kjartan Maraas (#341812)
|
||||
|
||||
2006-08-17 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.10.2 ===
|
||||
|
||||
2006-07-23 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.10.1 ===
|
||||
|
||||
2006-07-02 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.10.0 ===
|
||||
|
||||
2006-06-21 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.9.4 ===
|
||||
|
||||
2006-06-12 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.9.3 ===
|
||||
|
||||
2006-06-05 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.9.2 ===
|
||||
|
||||
2006-05-16 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.9.1 ====
|
||||
|
||||
2006-05-04 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.9.0 ===
|
||||
|
||||
2005-11-17 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* gdk-pixbuf-xlib-drawable.c:
|
||||
* gdk-pixbuf-xlibrgb.c: const correctness fixes
|
||||
found by Arjan van de Ven and gcc.
|
||||
|
||||
2005-10-05 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* gdk-pixbuf-xlib-2.0.pc.in (Requires): Require
|
||||
gmodule-no-export-2.0 instead of gmodule-2.0
|
||||
|
||||
2005-08-24 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.8.2 ===
|
||||
|
||||
* === Released 2.8.1 ===
|
||||
|
||||
2005-08-13 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.8.0 ===
|
||||
|
||||
2005-08-02 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.7.5 ===
|
||||
|
||||
2005-07-22 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.7.4 ===
|
||||
|
||||
2005-07-15 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.7.3 ===
|
||||
|
||||
2005-07-08 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.7.2 ===
|
||||
|
||||
2005-07-01 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.7.1 ===
|
||||
|
||||
2005-06-20 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.7.0 ===
|
||||
|
||||
2005-01-08 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.6.1 ===
|
||||
|
||||
2004-12-16 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.6.0 ===
|
||||
|
||||
2004-12-02 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.5.6 ===
|
||||
|
||||
2004-11-12 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.5.5 ===
|
||||
|
||||
2004-10-27 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.5.4 ===
|
||||
|
||||
2004-09-19 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.5.3 ===
|
||||
|
||||
2004-08-25 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.5.2 ===
|
||||
|
||||
2004-08-01 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* === Released 2.5.1 ===
|
||||
|
||||
Tue Jul 20 23:26:10 2004 Matthias Clasen <maclas@gmx.de>
|
||||
|
||||
* gdk-pixbuf-xlibrgb.c: Include config.h first. (#148034)
|
||||
|
||||
Sun Jul 18 20:17:41 2004 Soeren Sandmann <sandmann@daimi.au.dk>
|
||||
|
||||
* === released 2.5.0 ==
|
||||
|
||||
Tue Mar 9 09:33:54 2004 Owen Taylor <otaylor@redhat.com>
|
||||
|
||||
* === Released 2.3.6 ===
|
||||
|
||||
Wed Mar 3 15:50:28 2004 Owen Taylor <otaylor@redhat.com>
|
||||
|
||||
* Makefile.am (libgdk_pixbuf_xlib_2_0_la_LIBADD): Add
|
||||
a shared library dependency on libgdk-pixbuf (#124687)
|
||||
|
||||
Tue Feb 24 14:45:03 2004 Owen Taylor <otaylor@redhat.com>
|
||||
|
||||
* === Released 2.3.3 ===
|
||||
|
||||
Fri Feb 13 10:32:09 2004 Owen Taylor <otaylor@redhat.com>
|
||||
|
||||
* gdk-pixbuf-xlibrgb.h: Remove a couple of unneeded
|
||||
#includes. Isn't unsupported code fun?
|
||||
(133833, Gregory Merchan)
|
||||
|
||||
Tue Oct 7 23:30:00 2003 Matthias Clasen <maclas@gmx.de>
|
||||
|
||||
* gdk-pixbuf-xlib.h: Add C++ guards. (123955, Harring Figueiredo)
|
||||
|
||||
2002-08-06 jacob berkman <jacob@ximian.com>
|
||||
|
||||
* Makefile.am (lib_LTLIBRARIES): link against xlibs
|
||||
|
||||
2002-01-25 Federico Mena Quintero <federico@ximian.com>
|
||||
|
||||
Merge from gdk-pixbuf stable.
|
||||
|
||||
* gdk-pixbuf-xlib-drawable.c (rgb565msb): Fixed the endianness
|
||||
conversion --- swap the individual 16 bit values instead of taking
|
||||
everying as a 32 bit value.
|
||||
(rgb565lsb): Likewise.
|
||||
(rgb555lsb): Likewise.
|
||||
(rgb555msb): Likewise.
|
||||
|
||||
2001-11-26 Akira TAGOH <tagoh@redhat.com>
|
||||
|
||||
* Makefile.am (libgdk_pixbuf_xlib_1_3_la_LDFLAGS):
|
||||
Added -version-info.
|
||||
|
||||
2001-05-19 Havoc Pennington <hp@pobox.com>
|
||||
|
||||
* gdk-pixbuf-xlibrgb.c: docs
|
||||
|
||||
2001-06-04 Havoc Pennington <hp@redhat.com>
|
||||
|
||||
* gdk-pixbuf-xlibrgb.c (xlib_rgb_init): remove C++ comment,
|
||||
reported by Dan McNichol
|
||||
|
||||
Mon Jan 8 11:41:41 2001 Owen Taylor <otaylor@redhat.com>
|
||||
|
||||
* Makefile.am (INCLUDES): Add @x_cflags@ (#36310)
|
||||
|
||||
2001-01-02 Havoc Pennington <hp@redhat.com>
|
||||
|
||||
* gdk-pixbuf-xlib-2.0.pc.in (Description): fix up description a bit.
|
||||
|
||||
2000-10-06 Havoc Pennington <hp@redhat.com>
|
||||
|
||||
* gdk-pixbuf-xlib.c: Put display/screen here, instead of in
|
||||
the main gdk-pixbuf library as it was in 1.0; since the io-xpm
|
||||
loader doesn't use these variables anymore it should be OK
|
||||
|
||||
2000-09-26 Federico Mena Quintero <federico@helixcode.com>
|
||||
|
||||
* gdk-pixbuf/gdk-pixbuf-xlib-drawable.c
|
||||
(gdk_pixbuf_xlib_get_from_drawable): Do not use
|
||||
gdk_screen_{width,height}(). Thanks to John Harper for pointing
|
||||
this out.
|
||||
|
||||
2000-08-26 Federico Mena Quintero <federico@helixcode.com>
|
||||
|
||||
* gdk-pixbuf/gdk-pixbuf-xlibrgb.c: Added API reference docs.
|
||||
|
||||
2000-08-25 Federico Mena Quintero <federico@helixcode.com>
|
||||
|
||||
* gdk-pixbuf/gdk-pixbuf-xlib-drawable.c (handle_x_error): Return
|
||||
0.
|
||||
(xlib_window_is_viewable): Return FALSE in the last case.
|
||||
|
||||
* gdk-pixbuf/gdk-pixbuf-xlib-render.c: Updated the inline docs.
|
||||
|
||||
* gdk-pixbuf/gdk-pixbuf-xlib.c: Added API docs.
|
||||
|
||||
2000-08-25 John Harper <john@dcs.warwick.ac.uk>
|
||||
|
||||
Work to create an Xlib version of gdk-pixbuf (with the Xlib
|
||||
port of GdkRGB for rendering):
|
||||
|
||||
* configure.in: check for X libraries, set and substitute
|
||||
GDK_PIXBUF_XLIB_{LIBDIR,INCLUDEDIR,LIBS} variables
|
||||
|
||||
* gdk_pixbuf_xlibConf.sh.in: new file -- gnome-config details
|
||||
for the gdk-pixbuf-xlib library
|
||||
* Makefile.am: build and install gdk_pixbuf_xlibConf.sh
|
||||
|
||||
* gdk-pixbuf/gdk-pixbuf-xlib-render.c,
|
||||
gdk-pixbuf/gdk-pixbuf-xlib.c, gdk-pixbuf/gdk-pixbuf-xlib.h,
|
||||
gdk-pixbuf/gdk-pixbuf-xlib-private.h,
|
||||
gdk-pixbuf/gdk-pixbuf-xlib-drawable.c: new files, ported the
|
||||
GDK dependent parts of gdk-pixbuf to use Xlib. Functions that
|
||||
were called gdk_pixbuf_FOO are now gdk_pixbuf_xlib_FOO
|
||||
|
||||
* gdk-pixbuf/gdk-pixbuf-xlibrgb.c,
|
||||
gdk-pixbuf/gdk-pixbuf-xlibrgb.h: added Chris Blizzard's Xlib
|
||||
port of GdkRGB (from Mozilla CVS)
|
||||
|
||||
* gdk-pixbuf/Makefile.am: build a library libgdk_pixbuf_xlib.la
|
||||
including the non-GDK dependent objects from libgdk_pixbuf.la
|
||||
plus the Xlib ports and xlibrgb
|
||||
@@ -1,42 +0,0 @@
|
||||
include $(top_srcdir)/Makefile.decl
|
||||
|
||||
if PLATFORM_WIN32
|
||||
no_undefined = -no-undefined
|
||||
endif
|
||||
|
||||
lib_LTLIBRARIES=libgdk_pixbuf_xlib-3.0.la
|
||||
|
||||
INCLUDES = \
|
||||
-I$(top_srcdir) -I$(top_builddir) \
|
||||
-I$(top_srcdir)/gdk-pixbuf \
|
||||
-I$(top_srcdir)/contrib \
|
||||
$(GDK_PIXBUF_XLIB_DEP_CFLAGS)
|
||||
|
||||
libgdk_pixbuf_xlib_3_0_la_LDFLAGS = \
|
||||
-export-dynamic \
|
||||
$(no_undefined) \
|
||||
-version-info $(LT_VERSION_INFO)
|
||||
|
||||
libgdk_pixbuf_xlib_3_0_la_LIBADD = \
|
||||
$(top_builddir)/gdk-pixbuf/libgdk_pixbuf-$(GTK_API_VERSION).la \
|
||||
$(GDK_PIXBUF_XLIB_DEP_LIBS)
|
||||
|
||||
libgdk_pixbuf_xlib_3_0_la_SOURCES = \
|
||||
gdk-pixbuf-xlib-private.h \
|
||||
gdk-pixbuf-xlib.c \
|
||||
gdk-pixbuf-xlib-render.c \
|
||||
gdk-pixbuf-xlib-drawable.c \
|
||||
gdk-pixbuf-xlibrgb.c
|
||||
|
||||
libgdk_pixbuf_xlibincludedir=$(includedir)/gtk-3.0/gdk-pixbuf-xlib
|
||||
|
||||
libgdk_pixbuf_xlibinclude_HEADERS = \
|
||||
gdk-pixbuf-xlib.h \
|
||||
gdk-pixbuf-xlibrgb.h
|
||||
|
||||
pkgconfigdir = $(libdir)/pkgconfig
|
||||
pkgconfig_DATA = gdk-pixbuf-xlib-3.0.pc
|
||||
|
||||
EXTRA_DIST += gdk-pixbuf-xlib-3.0.pc.in
|
||||
|
||||
-include $(top_srcdir)/git.mk
|
||||
@@ -1,11 +0,0 @@
|
||||
prefix=@prefix@
|
||||
exec_prefix=@exec_prefix@
|
||||
libdir=@libdir@
|
||||
includedir=@includedir@
|
||||
|
||||
Name: GdkPixbuf Xlib
|
||||
Description: GdkPixbuf rendering for Xlib
|
||||
Version: @VERSION@
|
||||
Requires: gobject-2.0,gmodule-no-export-2.0,gdk-pixbuf-3.0
|
||||
Libs: -L${libdir} -lgdk_pixbuf_xlib-@GTK_API_VERSION@
|
||||
Cflags: -I${includedir}
|
||||
File diff suppressed because it is too large
Load Diff
@@ -1,30 +0,0 @@
|
||||
/* GdkPixbuf library - Xlib header file
|
||||
*
|
||||
* Authors: John Harper <john@dcs.warwick.ac.uk>
|
||||
*
|
||||
* This library is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU Library General Public
|
||||
* License as published by the Free Software Foundation; either
|
||||
* version 2 of the License, or (at your option) any later version.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* Library General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU Library General Public
|
||||
* License along with this library; if not, write to the
|
||||
* Free Software Foundation, Inc., 59 Temple Place - Suite 330,
|
||||
* Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
|
||||
#ifndef GDK_PIXBUF_XLIB_PRIVATE_H
|
||||
#define GDK_PIXBUF_XLIB_PRIVATE_H
|
||||
|
||||
#include "gdk-pixbuf-xlib.h"
|
||||
#include <X11/Xlib.h>
|
||||
|
||||
extern Display *gdk_pixbuf_dpy;
|
||||
extern int gdk_pixbuf_screen;
|
||||
|
||||
#endif
|
||||
@@ -1,398 +0,0 @@
|
||||
/* GdkPixbuf library - Rendering functions
|
||||
*
|
||||
* Copyright (C) 1999 The Free Software Foundation
|
||||
*
|
||||
* Author: Federico Mena-Quintero <federico@gimp.org>
|
||||
*
|
||||
* This library is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU Library General Public
|
||||
* License as published by the Free Software Foundation; either
|
||||
* version 2 of the License, or (at your option) any later version.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* Library General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU Library General Public
|
||||
* License along with this library; if not, write to the
|
||||
* Free Software Foundation, Inc., 59 Temple Place - Suite 330,
|
||||
* Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
|
||||
/* Trivially ported to Xlib(RGB) by John Harper. */
|
||||
|
||||
#include "config.h"
|
||||
#include "gdk-pixbuf-private.h"
|
||||
#include "gdk-pixbuf-xlib-private.h"
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* gdk_pixbuf_xlib_render_threshold_alpha:
|
||||
* @pixbuf: A pixbuf.
|
||||
* @bitmap: Bitmap where the bilevel mask will be painted to.
|
||||
* @src_x: Source X coordinate.
|
||||
* @src_y: source Y coordinate.
|
||||
* @dest_x: Destination X coordinate.
|
||||
* @dest_y: Destination Y coordinate.
|
||||
* @width: Width of region to threshold.
|
||||
* @height: Height of region to threshold.
|
||||
* @alpha_threshold: Opacity values below this will be painted as zero; all
|
||||
* other values will be painted as one.
|
||||
*
|
||||
* Takes the opacity values in a rectangular portion of a pixbuf and thresholds
|
||||
* them to produce a bi-level alpha mask that can be used as a clipping mask for
|
||||
* a drawable.
|
||||
*
|
||||
**/
|
||||
void
|
||||
gdk_pixbuf_xlib_render_threshold_alpha (GdkPixbuf *pixbuf, Pixmap bitmap,
|
||||
int src_x, int src_y,
|
||||
int dest_x, int dest_y,
|
||||
int width, int height,
|
||||
int alpha_threshold)
|
||||
{
|
||||
GC gc;
|
||||
XColor color;
|
||||
int x, y;
|
||||
guchar *p;
|
||||
int start, start_status;
|
||||
int status;
|
||||
XGCValues gcv;
|
||||
|
||||
g_return_if_fail (pixbuf != NULL);
|
||||
g_return_if_fail (pixbuf->colorspace == GDK_COLORSPACE_RGB);
|
||||
g_return_if_fail (pixbuf->n_channels == 3 || pixbuf->n_channels == 4);
|
||||
g_return_if_fail (pixbuf->bits_per_sample == 8);
|
||||
|
||||
g_return_if_fail (bitmap != 0);
|
||||
g_return_if_fail (width >= 0 && height >= 0);
|
||||
g_return_if_fail (src_x >= 0 && src_x + width <= pixbuf->width);
|
||||
g_return_if_fail (src_y >= 0 && src_y + height <= pixbuf->height);
|
||||
|
||||
g_return_if_fail (alpha_threshold >= 0 && alpha_threshold <= 255);
|
||||
|
||||
if (width == 0 || height == 0)
|
||||
return;
|
||||
|
||||
gc = XCreateGC (gdk_pixbuf_dpy, bitmap, 0, &gcv);
|
||||
|
||||
if (!pixbuf->has_alpha) {
|
||||
color.pixel = (alpha_threshold == 255) ? 0 : 1;
|
||||
XSetForeground (gdk_pixbuf_dpy, gc, color.pixel);
|
||||
XFillRectangle (gdk_pixbuf_dpy, bitmap, gc,
|
||||
dest_x, dest_y, width, height);
|
||||
XFreeGC (gdk_pixbuf_dpy, gc);
|
||||
return;
|
||||
}
|
||||
|
||||
color.pixel = 0;
|
||||
XSetForeground (gdk_pixbuf_dpy, gc, color.pixel);
|
||||
XFillRectangle (gdk_pixbuf_dpy, bitmap, gc,
|
||||
dest_x, dest_y, width, height);
|
||||
|
||||
color.pixel = 1;
|
||||
XSetForeground (gdk_pixbuf_dpy, gc, color.pixel);
|
||||
|
||||
for (y = 0; y < height; y++) {
|
||||
p = (pixbuf->pixels + (y + src_y) * pixbuf->rowstride + src_x * pixbuf->n_channels
|
||||
+ pixbuf->n_channels - 1);
|
||||
|
||||
start = 0;
|
||||
start_status = *p < alpha_threshold;
|
||||
|
||||
for (x = 0; x < width; x++) {
|
||||
status = *p < alpha_threshold;
|
||||
|
||||
if (status != start_status) {
|
||||
if (!start_status)
|
||||
XDrawLine (gdk_pixbuf_dpy, bitmap, gc,
|
||||
start + dest_x, y + dest_y,
|
||||
x - 1 + dest_x, y + dest_y);
|
||||
|
||||
start = x;
|
||||
start_status = status;
|
||||
}
|
||||
|
||||
p += pixbuf->n_channels;
|
||||
}
|
||||
|
||||
if (!start_status)
|
||||
XDrawLine (gdk_pixbuf_dpy, bitmap, gc,
|
||||
start + dest_x, y + dest_y,
|
||||
x - 1 + dest_x, y + dest_y);
|
||||
}
|
||||
|
||||
XFreeGC (gdk_pixbuf_dpy, gc);
|
||||
}
|
||||
|
||||
|
||||
|
||||
/* Creates a buffer by stripping the alpha channel of a pixbuf */
|
||||
static guchar *
|
||||
remove_alpha (GdkPixbuf *pixbuf, int x, int y, int width, int height, int *rowstride)
|
||||
{
|
||||
guchar *buf;
|
||||
int xx, yy;
|
||||
guchar *src, *dest;
|
||||
|
||||
g_assert (pixbuf->n_channels == 4);
|
||||
g_assert (pixbuf->has_alpha);
|
||||
g_assert (width > 0 && height > 0);
|
||||
g_assert (x >= 0 && x + width <= pixbuf->width);
|
||||
g_assert (y >= 0 && y + height <= pixbuf->height);
|
||||
|
||||
*rowstride = 4 * ((width * 3 + 3) / 4);
|
||||
|
||||
buf = g_new (guchar, *rowstride * height);
|
||||
|
||||
for (yy = 0; yy < height; yy++) {
|
||||
src = pixbuf->pixels + pixbuf->rowstride * (yy + y) + x * pixbuf->n_channels;
|
||||
dest = buf + *rowstride * yy;
|
||||
|
||||
for (xx = 0; xx < width; xx++) {
|
||||
*dest++ = *src++;
|
||||
*dest++ = *src++;
|
||||
*dest++ = *src++;
|
||||
src++;
|
||||
}
|
||||
}
|
||||
|
||||
return buf;
|
||||
}
|
||||
|
||||
/**
|
||||
* gdk_pixbuf_xlib_render_to_drawable:
|
||||
* @pixbuf: A pixbuf.
|
||||
* @drawable: Destination drawable.
|
||||
* @gc: GC used for rendering.
|
||||
* @src_x: Source X coordinate within pixbuf.
|
||||
* @src_y: Source Y coordinate within pixbuf.
|
||||
* @dest_x: Destination X coordinate within drawable.
|
||||
* @dest_y: Destination Y coordinate within drawable.
|
||||
* @width: Width of region to render, in pixels.
|
||||
* @height: Height of region to render, in pixels.
|
||||
* @dither: Dithering mode for XlibRGB.
|
||||
* @x_dither: X offset for dither.
|
||||
* @y_dither: Y offset for dither.
|
||||
*
|
||||
* Renders a rectangular portion of a pixbuf to a drawable while using the
|
||||
* specified GC. This is done using XlibRGB, so the specified drawable must
|
||||
* have the XlibRGB visual and colormap. Note that this function will ignore
|
||||
* the opacity information for images with an alpha channel; the GC must already
|
||||
* have the clipping mask set if you want transparent regions to show through.
|
||||
*
|
||||
* For an explanation of dither offsets, see the XlibRGB documentation. In
|
||||
* brief, the dither offset is important when re-rendering partial regions of an
|
||||
* image to a rendered version of the full image, or for when the offsets to a
|
||||
* base position change, as in scrolling. The dither matrix has to be shifted
|
||||
* for consistent visual results. If you do not have any of these cases, the
|
||||
* dither offsets can be both zero.
|
||||
**/
|
||||
void
|
||||
gdk_pixbuf_xlib_render_to_drawable (GdkPixbuf *pixbuf,
|
||||
Drawable drawable, GC gc,
|
||||
int src_x, int src_y,
|
||||
int dest_x, int dest_y,
|
||||
int width, int height,
|
||||
XlibRgbDither dither,
|
||||
int x_dither, int y_dither)
|
||||
{
|
||||
guchar *buf;
|
||||
int rowstride;
|
||||
|
||||
g_return_if_fail (pixbuf != NULL);
|
||||
g_return_if_fail (pixbuf->colorspace == GDK_COLORSPACE_RGB);
|
||||
g_return_if_fail (pixbuf->n_channels == 3 || pixbuf->n_channels == 4);
|
||||
g_return_if_fail (pixbuf->bits_per_sample == 8);
|
||||
|
||||
g_return_if_fail (drawable != 0);
|
||||
g_return_if_fail (gc != 0);
|
||||
|
||||
g_return_if_fail (width >= 0 && height >= 0);
|
||||
g_return_if_fail (src_x >= 0 && src_x + width <= pixbuf->width);
|
||||
g_return_if_fail (src_y >= 0 && src_y + height <= pixbuf->height);
|
||||
|
||||
if (width == 0 || height == 0)
|
||||
return;
|
||||
|
||||
/* This will have to be modified once we support other image types.
|
||||
* Also, GdkRGB does not have gdk_draw_rgb_32_image_dithalign(), so we
|
||||
* have to pack the buffer first. Sigh.
|
||||
*/
|
||||
|
||||
if (pixbuf->has_alpha)
|
||||
buf = remove_alpha (pixbuf, src_x, src_y, width, height, &rowstride);
|
||||
else {
|
||||
buf = pixbuf->pixels + src_y * pixbuf->rowstride + src_x * 3;
|
||||
rowstride = pixbuf->rowstride;
|
||||
}
|
||||
|
||||
xlib_draw_rgb_image_dithalign (drawable, gc,
|
||||
dest_x, dest_y,
|
||||
width, height,
|
||||
dither,
|
||||
buf, rowstride,
|
||||
x_dither, y_dither);
|
||||
|
||||
if (pixbuf->has_alpha)
|
||||
g_free (buf);
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* gdk_pixbuf_xlib_render_to_drawable_alpha:
|
||||
* @pixbuf: A pixbuf.
|
||||
* @drawable: Destination drawable.
|
||||
* @src_x: Source X coordinate within pixbuf.
|
||||
* @src_y: Source Y coordinates within pixbuf.
|
||||
* @dest_x: Destination X coordinate within drawable.
|
||||
* @dest_y: Destination Y coordinate within drawable.
|
||||
* @width: Width of region to render, in pixels.
|
||||
* @height: Height of region to render, in pixels.
|
||||
* @alpha_mode: If the image does not have opacity information, this is ignored.
|
||||
* Otherwise, specifies how to handle transparency when rendering.
|
||||
* @alpha_threshold: If the image does have opacity information and @alpha_mode
|
||||
* is GDK_PIXBUF_ALPHA_BILEVEL, specifies the threshold value for opacity
|
||||
* values.
|
||||
* @dither: Dithering mode for XlibRGB.
|
||||
* @x_dither: X offset for dither.
|
||||
* @y_dither: Y offset for dither.
|
||||
*
|
||||
* Renders a rectangular portion of a pixbuf to a drawable. This is done using
|
||||
* XlibRGB, so the specified drawable must have the XlibRGB visual and colormap.
|
||||
*
|
||||
* When used with #GDK_PIXBUF_ALPHA_BILEVEL, this function has to create a bitmap
|
||||
* out of the thresholded alpha channel of the image and, it has to set this
|
||||
* bitmap as the clipping mask for the GC used for drawing. This can be a
|
||||
* significant performance penalty depending on the size and the complexity of
|
||||
* the alpha channel of the image. If performance is crucial, consider handling
|
||||
* the alpha channel yourself (possibly by caching it in your application) and
|
||||
* using gdk_pixbuf_xlib_render_to_drawable() or GdkRGB directly instead.
|
||||
**/
|
||||
void
|
||||
gdk_pixbuf_xlib_render_to_drawable_alpha (GdkPixbuf *pixbuf, Drawable drawable,
|
||||
int src_x, int src_y,
|
||||
int dest_x, int dest_y,
|
||||
int width, int height,
|
||||
GdkPixbufAlphaMode alpha_mode,
|
||||
int alpha_threshold,
|
||||
XlibRgbDither dither,
|
||||
int x_dither, int y_dither)
|
||||
{
|
||||
Pixmap bitmap = 0;
|
||||
GC gc;
|
||||
XGCValues gcv;
|
||||
|
||||
g_return_if_fail (pixbuf != NULL);
|
||||
g_return_if_fail (pixbuf->colorspace == GDK_COLORSPACE_RGB);
|
||||
g_return_if_fail (pixbuf->n_channels == 3 || pixbuf->n_channels == 4);
|
||||
g_return_if_fail (pixbuf->bits_per_sample == 8);
|
||||
|
||||
g_return_if_fail (drawable != 0);
|
||||
g_return_if_fail (width >= 0 && height >= 0);
|
||||
g_return_if_fail (src_x >= 0 && src_x + width <= pixbuf->width);
|
||||
g_return_if_fail (src_y >= 0 && src_y + height <= pixbuf->height);
|
||||
|
||||
if (width == 0 || height == 0)
|
||||
return;
|
||||
|
||||
gc = XCreateGC (gdk_pixbuf_dpy, drawable, 0, &gcv);
|
||||
|
||||
if (pixbuf->has_alpha) {
|
||||
/* Right now we only support GDK_PIXBUF_ALPHA_BILEVEL, so we
|
||||
* unconditionally create the clipping mask.
|
||||
*/
|
||||
|
||||
bitmap = XCreatePixmap (gdk_pixbuf_dpy,
|
||||
RootWindow (gdk_pixbuf_dpy,
|
||||
gdk_pixbuf_screen),
|
||||
width, height, 1);
|
||||
gdk_pixbuf_xlib_render_threshold_alpha (pixbuf, bitmap,
|
||||
src_x, src_y,
|
||||
0, 0,
|
||||
width, height,
|
||||
alpha_threshold);
|
||||
|
||||
XSetClipMask (gdk_pixbuf_dpy, gc, bitmap);
|
||||
XSetClipOrigin (gdk_pixbuf_dpy, gc, dest_x, dest_y);
|
||||
}
|
||||
|
||||
gdk_pixbuf_xlib_render_to_drawable (pixbuf, drawable, gc,
|
||||
src_x, src_y,
|
||||
dest_x, dest_y,
|
||||
width, height,
|
||||
dither,
|
||||
x_dither, y_dither);
|
||||
|
||||
if (bitmap)
|
||||
XFreePixmap (gdk_pixbuf_dpy, bitmap);
|
||||
|
||||
XFreeGC (gdk_pixbuf_dpy, gc);
|
||||
}
|
||||
|
||||
/**
|
||||
* gdk_pixbuf_xlib_render_pixmap_and_mask:
|
||||
* @pixbuf: A pixbuf.
|
||||
* @pixmap_return: Return value for the created pixmap.
|
||||
* @mask_return: Return value for the created mask.
|
||||
* @alpha_threshold: Threshold value for opacity values.
|
||||
*
|
||||
* Creates a pixmap and a mask bitmap which are returned in the @pixmap_return
|
||||
* and @mask_return arguments, respectively, and renders a pixbuf and its
|
||||
* corresponding tresholded alpha mask to them. This is merely a convenience
|
||||
* function; applications that need to render pixbufs with dither offsets or to
|
||||
* given drawables should use gdk_pixbuf_xlib_render_to_drawable_alpha() or
|
||||
* gdk_pixbuf_xlib_render_to_drawable(), and
|
||||
* gdk_pixbuf_xlib_render_threshold_alpha().
|
||||
*
|
||||
* If the pixbuf does not have an alpha channel, then *@mask_return will be set
|
||||
* to None.
|
||||
**/
|
||||
void
|
||||
gdk_pixbuf_xlib_render_pixmap_and_mask (GdkPixbuf *pixbuf,
|
||||
Pixmap *pixmap_return,
|
||||
Pixmap *mask_return,
|
||||
int alpha_threshold)
|
||||
{
|
||||
g_return_if_fail (pixbuf != NULL);
|
||||
|
||||
if (pixmap_return) {
|
||||
GC gc;
|
||||
XGCValues gcv;
|
||||
|
||||
*pixmap_return = XCreatePixmap (gdk_pixbuf_dpy,
|
||||
RootWindow (gdk_pixbuf_dpy,
|
||||
gdk_pixbuf_screen),
|
||||
pixbuf->width,
|
||||
pixbuf->height,
|
||||
xlib_rgb_get_depth ());
|
||||
gc = XCreateGC (gdk_pixbuf_dpy, *pixmap_return, 0, &gcv);
|
||||
gdk_pixbuf_xlib_render_to_drawable (pixbuf, *pixmap_return, gc,
|
||||
0, 0, 0, 0,
|
||||
pixbuf->width,
|
||||
pixbuf->height,
|
||||
XLIB_RGB_DITHER_NORMAL,
|
||||
0, 0);
|
||||
XFreeGC (gdk_pixbuf_dpy, gc);
|
||||
}
|
||||
|
||||
if (mask_return) {
|
||||
if (pixbuf->has_alpha) {
|
||||
*mask_return = XCreatePixmap (gdk_pixbuf_dpy,
|
||||
RootWindow (gdk_pixbuf_dpy,
|
||||
gdk_pixbuf_screen),
|
||||
pixbuf->width,
|
||||
pixbuf->height, 1);
|
||||
gdk_pixbuf_xlib_render_threshold_alpha (pixbuf,
|
||||
*mask_return,
|
||||
0, 0, 0, 0,
|
||||
pixbuf->width,
|
||||
pixbuf->height,
|
||||
alpha_threshold);
|
||||
} else
|
||||
*mask_return = 0;
|
||||
}
|
||||
}
|
||||
@@ -1,63 +0,0 @@
|
||||
/* GdkPixbuf library - Initialization functions
|
||||
*
|
||||
* Author: John Harper <john@dcs.warwick.ac.uk>
|
||||
*
|
||||
* This library is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU Library General Public
|
||||
* License as published by the Free Software Foundation; either
|
||||
* version 2 of the License, or (at your option) any later version.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* Library General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU Library General Public
|
||||
* License along with this library; if not, write to the
|
||||
* Free Software Foundation, Inc., 59 Temple Place - Suite 330,
|
||||
* Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
|
||||
#include "config.h"
|
||||
#include <X11/Xlib.h>
|
||||
#include <gdk-pixbuf/gdk-pixbuf-private.h>
|
||||
#include "gdk-pixbuf-xlib-private.h"
|
||||
|
||||
Display *gdk_pixbuf_dpy = NULL;
|
||||
int gdk_pixbuf_screen = -1;
|
||||
|
||||
/**
|
||||
* gdk_pixbuf_xlib_init:
|
||||
* @display: X display to use.
|
||||
* @screen_num: Screen number.
|
||||
*
|
||||
* Initializes the gdk-pixbuf Xlib machinery by calling xlib_rgb_init(). This
|
||||
* function should be called near the beginning of your program, or before using
|
||||
* any of the gdk-pixbuf-xlib functions.
|
||||
**/
|
||||
void
|
||||
gdk_pixbuf_xlib_init (Display *display, int screen_num)
|
||||
{
|
||||
xlib_rgb_init (display, ScreenOfDisplay (display, screen_num));
|
||||
gdk_pixbuf_dpy = display;
|
||||
gdk_pixbuf_screen = screen_num;
|
||||
}
|
||||
|
||||
/**
|
||||
* gdk_pixbuf_xlib_init_with_depth:
|
||||
* @display: X display to use.
|
||||
* @screen_num: Screen number.
|
||||
* @prefDepth: Preferred depth for XlibRGB.
|
||||
*
|
||||
* Similar to gdk_pixbuf_xlib_init(), but also lets you specify the preferred
|
||||
* depth for XlibRGB if you do not want it to use the default depth it picks.
|
||||
**/
|
||||
void
|
||||
gdk_pixbuf_xlib_init_with_depth (Display *display,
|
||||
int screen_num, int prefDepth)
|
||||
{
|
||||
xlib_rgb_init_with_depth (display, ScreenOfDisplay (display, screen_num),
|
||||
prefDepth);
|
||||
gdk_pixbuf_dpy = display;
|
||||
gdk_pixbuf_screen = screen_num;
|
||||
}
|
||||
@@ -1,87 +0,0 @@
|
||||
/* GdkPixbuf library - Xlib header file
|
||||
*
|
||||
* Authors: John Harper <john@dcs.warwick.ac.uk>
|
||||
*
|
||||
* This library is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU Library General Public
|
||||
* License as published by the Free Software Foundation; either
|
||||
* version 2 of the License, or (at your option) any later version.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* Library General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU Library General Public
|
||||
* License along with this library; if not, write to the
|
||||
* Free Software Foundation, Inc., 59 Temple Place - Suite 330,
|
||||
* Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
|
||||
#ifndef GDK_PIXBUF_XLIB_H
|
||||
#define GDK_PIXBUF_XLIB_H
|
||||
|
||||
#include <gdk-pixbuf/gdk-pixbuf.h>
|
||||
#include <gdk-pixbuf-xlib/gdk-pixbuf-xlibrgb.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#include <X11/Xlib.h>
|
||||
|
||||
|
||||
|
||||
/* init */
|
||||
|
||||
void gdk_pixbuf_xlib_init (Display *display, int screen_num);
|
||||
|
||||
void gdk_pixbuf_xlib_init_with_depth (Display *display, int screen_num,
|
||||
int prefDepth);
|
||||
|
||||
|
||||
|
||||
/* render */
|
||||
|
||||
void gdk_pixbuf_xlib_render_threshold_alpha (GdkPixbuf *pixbuf, Pixmap bitmap,
|
||||
int src_x, int src_y,
|
||||
int dest_x, int dest_y,
|
||||
int width, int height,
|
||||
int alpha_threshold);
|
||||
|
||||
void gdk_pixbuf_xlib_render_to_drawable (GdkPixbuf *pixbuf,
|
||||
Drawable drawable, GC gc,
|
||||
int src_x, int src_y,
|
||||
int dest_x, int dest_y,
|
||||
int width, int height,
|
||||
XlibRgbDither dither,
|
||||
int x_dither, int y_dither);
|
||||
|
||||
|
||||
void gdk_pixbuf_xlib_render_to_drawable_alpha (GdkPixbuf *pixbuf,
|
||||
Drawable drawable,
|
||||
int src_x, int src_y,
|
||||
int dest_x, int dest_y,
|
||||
int width, int height,
|
||||
GdkPixbufAlphaMode alpha_mode,
|
||||
int alpha_threshold,
|
||||
XlibRgbDither dither,
|
||||
int x_dither, int y_dither);
|
||||
|
||||
void gdk_pixbuf_xlib_render_pixmap_and_mask (GdkPixbuf *pixbuf,
|
||||
Pixmap *pixmap_return,
|
||||
Pixmap *mask_return,
|
||||
int alpha_threshold);
|
||||
|
||||
|
||||
|
||||
/* drawable */
|
||||
|
||||
GdkPixbuf *gdk_pixbuf_xlib_get_from_drawable (GdkPixbuf *dest,
|
||||
Drawable src,
|
||||
Colormap cmap, Visual *visual,
|
||||
int src_x, int src_y,
|
||||
int dest_x, int dest_y,
|
||||
int width, int height);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* GDK_PIXBUF_XLIB_H */
|
||||
File diff suppressed because it is too large
Load Diff
@@ -1,188 +0,0 @@
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-
|
||||
*
|
||||
* The contents of this file are subject to the Mozilla Public License
|
||||
* Version 1.1 (the "MPL"); you may not use this file except in
|
||||
* compliance with the MPL. You may obtain a copy of the MPL at
|
||||
* http://www.mozilla.org/MPL/
|
||||
*
|
||||
* Software distributed under the MPL is distributed on an "AS IS" basis,
|
||||
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the MPL
|
||||
* for the specific language governing rights and limitations under the
|
||||
* MPL.
|
||||
*
|
||||
* Alternatively, the contents of this file may be used under the
|
||||
* terms of the GNU Library General Public License (the "LGPL"), in
|
||||
* which case the provisions of the LGPL are applicable instead of
|
||||
* those above. If you wish to allow use of your version of this file
|
||||
* only under the terms of the LGPL and not to allow others to use
|
||||
* your version of this file under the MPL, indicate your decision by
|
||||
* deleting the provisions above and replace them with the notice and
|
||||
* other provisions required by the LGPL. If you do not delete the
|
||||
* provisions above, a recipient may use your version of this file
|
||||
* under either the MPL or the LGPL.
|
||||
*/
|
||||
|
||||
/*
|
||||
* This code is derived from GdkRgb.
|
||||
* For more information on GdkRgb, see http://www.levien.com/gdkrgb/
|
||||
* Raph Levien <raph@acm.org>
|
||||
*/
|
||||
|
||||
/* Ported by Christopher Blizzard to Xlib. With permission from the
|
||||
* original authors of this file, the contents of this file are also
|
||||
* redistributable under the terms of the Mozilla Public license. For
|
||||
* information about the Mozilla Public License, please see the
|
||||
* license information at http://www.mozilla.org/MPL/
|
||||
*/
|
||||
|
||||
/* This code is copyright the following authors:
|
||||
* Raph Levien <raph@acm.org>
|
||||
* Manish Singh <manish@gtk.org>
|
||||
* Tim Janik <timj@gtk.org>
|
||||
* Peter Mattis <petm@xcf.berkeley.edu>
|
||||
* Spencer Kimball <spencer@xcf.berkeley.edu>
|
||||
* Josh MacDonald <jmacd@xcf.berkeley.edu>
|
||||
* Christopher Blizzard <blizzard@redhat.com>
|
||||
* Owen Taylor <otaylor@redhat.com>
|
||||
* Shawn T. Amundson <amundson@gtk.org>
|
||||
*/
|
||||
|
||||
|
||||
#ifndef __XLIB_RGB_H__
|
||||
#define __XLIB_RGB_H__
|
||||
|
||||
#include <glib.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#include <X11/Xlib.h>
|
||||
#include <X11/Xutil.h>
|
||||
|
||||
typedef struct _XlibRgbCmap XlibRgbCmap;
|
||||
|
||||
struct _XlibRgbCmap {
|
||||
unsigned int colors[256];
|
||||
unsigned char lut[256]; /* for 8-bit modes */
|
||||
};
|
||||
|
||||
void
|
||||
xlib_rgb_init (Display *display, Screen *screen);
|
||||
void
|
||||
xlib_rgb_init_with_depth (Display *display, Screen *screen, int prefDepth);
|
||||
|
||||
unsigned long
|
||||
xlib_rgb_xpixel_from_rgb (guint32 rgb);
|
||||
|
||||
void
|
||||
xlib_rgb_gc_set_foreground (GC gc, guint32 rgb);
|
||||
|
||||
void
|
||||
xlib_rgb_gc_set_background (GC gc, guint32 rgb);
|
||||
|
||||
typedef enum
|
||||
{
|
||||
XLIB_RGB_DITHER_NONE,
|
||||
XLIB_RGB_DITHER_NORMAL,
|
||||
XLIB_RGB_DITHER_MAX
|
||||
} XlibRgbDither;
|
||||
|
||||
void
|
||||
xlib_draw_rgb_image (Drawable drawable,
|
||||
GC gc,
|
||||
int x,
|
||||
int y,
|
||||
int width,
|
||||
int height,
|
||||
XlibRgbDither dith,
|
||||
unsigned char *rgb_buf,
|
||||
int rowstride);
|
||||
|
||||
void
|
||||
xlib_draw_rgb_image_dithalign (Drawable drawable,
|
||||
GC gc,
|
||||
int x,
|
||||
int y,
|
||||
int width,
|
||||
int height,
|
||||
XlibRgbDither dith,
|
||||
unsigned char *rgb_buf,
|
||||
int rowstride,
|
||||
int xdith,
|
||||
int ydith);
|
||||
|
||||
void
|
||||
xlib_draw_rgb_32_image (Drawable drawable,
|
||||
GC gc,
|
||||
int x,
|
||||
int y,
|
||||
int width,
|
||||
int height,
|
||||
XlibRgbDither dith,
|
||||
unsigned char *buf,
|
||||
int rowstride);
|
||||
|
||||
void
|
||||
xlib_draw_gray_image (Drawable drawable,
|
||||
GC gc,
|
||||
int x,
|
||||
int y,
|
||||
int width,
|
||||
int height,
|
||||
XlibRgbDither dith,
|
||||
unsigned char *buf,
|
||||
int rowstride);
|
||||
|
||||
XlibRgbCmap *
|
||||
xlib_rgb_cmap_new (guint32 *colors, int n_colors);
|
||||
|
||||
void
|
||||
xlib_rgb_cmap_free (XlibRgbCmap *cmap);
|
||||
|
||||
void
|
||||
xlib_draw_indexed_image (Drawable drawable,
|
||||
GC gc,
|
||||
int x,
|
||||
int y,
|
||||
int width,
|
||||
int height,
|
||||
XlibRgbDither dith,
|
||||
unsigned char *buf,
|
||||
int rowstride,
|
||||
XlibRgbCmap *cmap);
|
||||
|
||||
/* Below are some functions which are primarily useful for debugging
|
||||
and experimentation. */
|
||||
Bool
|
||||
xlib_rgb_ditherable (void);
|
||||
|
||||
void
|
||||
xlib_rgb_set_verbose (Bool verbose);
|
||||
|
||||
/* experimental colormap stuff */
|
||||
void
|
||||
xlib_rgb_set_install (Bool install);
|
||||
|
||||
void
|
||||
xlib_rgb_set_min_colors (int min_colors);
|
||||
|
||||
Colormap
|
||||
xlib_rgb_get_cmap (void);
|
||||
|
||||
Visual *
|
||||
xlib_rgb_get_visual (void);
|
||||
|
||||
XVisualInfo *
|
||||
xlib_rgb_get_visual_info (void);
|
||||
|
||||
int
|
||||
xlib_rgb_get_depth (void);
|
||||
|
||||
Display *
|
||||
xlib_rgb_get_display (void);
|
||||
|
||||
Screen *
|
||||
xlib_rgb_get_screen (void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __XLIB_RGB_H__ */
|
||||
@@ -12,12 +12,10 @@ INCLUDES = \
|
||||
$(GTK_DEP_CFLAGS)
|
||||
|
||||
DEPS = \
|
||||
$(top_builddir)/gdk-pixbuf/libgdk_pixbuf-$(GTK_API_VERSION).la \
|
||||
$(top_builddir)/gdk/$(gdktargetlib) \
|
||||
$(top_builddir)/gtk/$(gtktargetlib)
|
||||
|
||||
LDADDS = \
|
||||
$(top_builddir)/gdk-pixbuf/libgdk_pixbuf-$(GTK_API_VERSION).la \
|
||||
$(top_builddir)/gdk/$(gdktargetlib) \
|
||||
$(top_builddir)/gtk/$(gtktargetlib) \
|
||||
$(GTK_DEP_LIBS) \
|
||||
@@ -32,21 +30,11 @@ noinst_PROGRAMS = \
|
||||
pixbuf-demo
|
||||
|
||||
# Need to build test-inline-pixbufs.h for testpixbuf
|
||||
if HAVE_PNG
|
||||
noinst_PROGRAMS += testpixbuf
|
||||
BUILT_SOURCES = test-inline-pixbufs.h
|
||||
endif
|
||||
|
||||
if CROSS_COMPILING
|
||||
pixbuf_csource=$(GDK_PIXBUF_CSOURCE)
|
||||
pixbuf_csource_deps=
|
||||
else
|
||||
pixbuf_csource=GDK_PIXBUF_MODULE_FILE=$(top_builddir)/gdk-pixbuf/loaders.cache $(top_builddir)/gdk-pixbuf/gdk-pixbuf-csource-3.0
|
||||
pixbuf_csource_deps=$(top_builddir)/gdk-pixbuf/gdk-pixbuf-csource-3.0 $(top_builddir)/gdk-pixbuf/loaders.cache
|
||||
endif
|
||||
|
||||
test-inline-pixbufs.h: $(pixbuf_csource_deps) apple-red.png gnome-foot.png
|
||||
$(pixbuf_csource) --raw --build-list \
|
||||
test-inline-pixbufs.h: apple-red.png gnome-foot.png
|
||||
$(GDK_PIXBUF_CSOURCE) --raw --build-list \
|
||||
apple_red $(srcdir)/apple-red.png \
|
||||
gnome_foot $(srcdir)/gnome-foot.png \
|
||||
> test-inline-pixbufs.h \
|
||||
|
||||
@@ -55,15 +55,14 @@ INCLUDES = \
|
||||
$(GTK_DEP_CFLAGS)
|
||||
|
||||
DEPS = \
|
||||
$(top_builddir)/gdk-pixbuf/libgdk_pixbuf-$(GTK_API_VERSION).la \
|
||||
$(top_builddir)/gdk/$(gdktargetlib) \
|
||||
$(top_builddir)/gtk/$(gtktargetlib)
|
||||
|
||||
LDADDS = \
|
||||
$(top_builddir)/gdk-pixbuf/libgdk_pixbuf-$(GTK_API_VERSION).la \
|
||||
$(top_builddir)/gdk/$(gdktargetlib) \
|
||||
$(top_builddir)/gtk/$(gtktargetlib) \
|
||||
$(GTK_DEP_LIBS)
|
||||
$(GTK_DEP_LIBS) \
|
||||
-lm
|
||||
|
||||
bin_PROGRAMS = gtk3-demo
|
||||
|
||||
|
||||
@@ -26,16 +26,21 @@ Make sure that gtk-doc is the latest released version.
|
||||
committers, etc. Anybody who is mentioned in ChangeLog gets
|
||||
credits, but only real names, not email addresses or nicknames.
|
||||
|
||||
3) In particular, if this is a major, stable, release, verify that
|
||||
3) Update the pot files and commit the changes:
|
||||
|
||||
make -C po gtk30.pot
|
||||
make -C po-properties gtk30-properties.pot
|
||||
|
||||
4) In particular, if this is a major, stable, release, verify that
|
||||
README.in contains the relevant release notes and that the
|
||||
required versions of dependencies in INSTALL.in are in sync
|
||||
with configure.ac.
|
||||
|
||||
4) Verify that the version in configure.ac has been bumped after the last
|
||||
5) Verify that the version in configure.ac has been bumped after the last
|
||||
release. (Note that this is critical, a slip-up here will cause the
|
||||
soname to change).
|
||||
|
||||
5) Make sure that make check is happy (If you don't do it here, make distcheck
|
||||
6) Make sure that make check is happy (If you don't do it here, make distcheck
|
||||
will also catch it, but it is kind of disheartening to see make distcheck
|
||||
fail due to an extraneous symbol after watching it build the docs for an
|
||||
hour...).
|
||||
@@ -49,7 +54,7 @@ Make sure that gtk-doc is the latest released version.
|
||||
using a function from a different library, which is not yet allowed
|
||||
by the filter in pltcheck.sh
|
||||
|
||||
6) If this is a devel release, make sure that the docs for new symbols
|
||||
7) If this is a devel release, make sure that the docs for new symbols
|
||||
are in good shape. Look at the -unused.txt files and add stuff found
|
||||
there to the corresponding -sections.txt file. Look at the
|
||||
-undocumented.txt files and see if there is anything in there that
|
||||
@@ -58,12 +63,12 @@ Make sure that gtk-doc is the latest released version.
|
||||
Since: tags, and that there is an index in the main -docs.sgml for
|
||||
the next stable version.
|
||||
|
||||
7) make distcheck
|
||||
8) make distcheck
|
||||
|
||||
8) Fix broken stuff found by 7), repeat
|
||||
9) Fix broken stuff found by 8), commit changes: git commit -a, repeat.
|
||||
|
||||
9) Commit all changes: git commit -a. You will have a bunch of po file
|
||||
changes, NEWS and maybe some doc changes too
|
||||
10) Once distcheck succeeds, verify that the tree is clean: git diff should
|
||||
come up empty.
|
||||
|
||||
10) Now you've got the tarball. Check that the tarball size looks
|
||||
reasonable compared to previous releases. If the size goes down
|
||||
|
||||
@@ -17,6 +17,8 @@ pdf:
|
||||
(cd $(srcdir); db2pdf gtk-faq.sgml); \
|
||||
fi
|
||||
|
||||
all-local: html
|
||||
|
||||
dist-hook: html
|
||||
cp -Rp $(srcdir)/html $(distdir)
|
||||
else
|
||||
|
||||
@@ -789,7 +789,7 @@ disgrace to the widget set will gladly be included.</para>
|
||||
<para>The new widgets that get added to GTK+ are generally either
|
||||
replacements for existing widgets that are no longer
|
||||
deemed to be adequate, or have been developed externally to GTK+ but
|
||||
have been widely tested.
|
||||
have been widely tested.</para>
|
||||
|
||||
<para>Before you spend months of your valuable time implementing your
|
||||
revolutionary widget, it is highly recommended that you get some
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
## Process this file with automake to produce Makefile.in
|
||||
include $(top_srcdir)/Makefile.decl
|
||||
|
||||
SUBDIRS = gdk-pixbuf gdk gtk libgail-util
|
||||
SUBDIRS = gdk gtk libgail-util
|
||||
|
||||
GITIGNOREFILES = */*.1
|
||||
|
||||
|
||||
@@ -1,116 +0,0 @@
|
||||
## Process this file with automake to produce Makefile.in
|
||||
include $(top_srcdir)/Makefile.decl
|
||||
|
||||
AUTOMAKE_OPTIONS = 1.6
|
||||
|
||||
# The name of the module.
|
||||
DOC_MODULE=gdk-pixbuf3
|
||||
|
||||
# The top-level SGML file.
|
||||
DOC_MAIN_SGML_FILE=gdk-pixbuf.sgml
|
||||
|
||||
# Extra options to supply to gtkdoc-scan
|
||||
SCAN_OPTIONS=--source-dir=../../../contrib/gdk-pixbuf-xlib --deprecated-guards="GDK_PIXBUF_ENABLE_BROKEN|GDK_PIXBUF_DISABLE_DEPRECATED"
|
||||
|
||||
# The directory containing the source code. Relative to $(srcdir)
|
||||
DOC_SOURCE_DIR=../../../gdk-pixbuf
|
||||
|
||||
# Used for dependencies
|
||||
HFILE_GLOB=$(top_srcdir)/gdk-pixbuf/*.h $(top_srcdir)/contrib/gdk-pixbuf-xlib/*.h
|
||||
CFILE_GLOB=$(top_srcdir)/gdk-pixbuf/*.c $(top_srcdir)/contrib/gdk-pixbuf-xlib/*.c
|
||||
|
||||
# Header files to ignore when scanning
|
||||
IGNORE_HFILES= \
|
||||
pixops \
|
||||
gdk-pixbuf-alias.h \
|
||||
gdk-pixbuf-marshal.h \
|
||||
gdk-pixbuf-xlib-private.h \
|
||||
gdk-pixbuf-i18n.h \
|
||||
gdk-pixbuf-private.h \
|
||||
io-gif-animation.h \
|
||||
io-ani-animation.h \
|
||||
xpm-color-table.h \
|
||||
test-images.h
|
||||
|
||||
INCLUDES = \
|
||||
-I$(top_srcdir) \
|
||||
-I$(top_builddir) \
|
||||
-I$(top_builddir)/gdk \
|
||||
$(GTK_DEBUG_FLAGS) \
|
||||
$(GTK_DEP_CFLAGS)
|
||||
|
||||
GTKDOC_LIBS = \
|
||||
$(top_builddir)/gdk-pixbuf/libgdk_pixbuf-$(GTK_API_VERSION).la \
|
||||
$(top_builddir)/gdk/$(gdktargetlib) \
|
||||
$(top_builddir)/gtk/$(gtktargetlib) \
|
||||
$(GTK_DEP_LIBS)
|
||||
|
||||
|
||||
# Extra options to supply to gtkdoc-mkdb
|
||||
MKDB_OPTIONS=--main-sgml-file=$(DOC_MAIN_SGML_FILE) --sgml-mode --source-dir=../../../contrib/gdk-pixbuf-xlib --output-format=xml --name-space=gdk_pixbuf
|
||||
|
||||
# Extra SGML files that are included by DOC_MAIN_SGML_FILE
|
||||
content_files = \
|
||||
version.xml \
|
||||
gdk-pixbuf-from-drawables.sgml \
|
||||
gdk-pixbuf-rendering.sgml \
|
||||
gdk-pixbuf.sgml \
|
||||
porting-from-imlib.sgml \
|
||||
gdk-pixbuf-csource-3.0.xml \
|
||||
gdk-pixbuf-query-loaders-3.0.xml
|
||||
|
||||
# Images to copy into HTML directory
|
||||
HTML_IMAGES = composite.png
|
||||
|
||||
# Extra options to supply to gtkdoc-fixref
|
||||
FIXXREF_OPTIONS= --extra-dir=$(GLIB_PREFIX)/share/gtk-doc/html/gobject \
|
||||
--extra-dir=$(GLIB_PREFIX)/share/gtk-doc/html/glib
|
||||
|
||||
|
||||
include $(top_srcdir)/gtk-doc.make
|
||||
|
||||
# Other files to distribute
|
||||
EXTRA_DIST += version.xml.in \
|
||||
composite.png \
|
||||
composite.dia \
|
||||
apple-red-1a.png \
|
||||
apple-red-2c.png \
|
||||
gnome-gmush-1.png
|
||||
|
||||
########################################################################
|
||||
|
||||
man_MANS = \
|
||||
gdk-pixbuf-csource-3.0.1 \
|
||||
gdk-pixbuf-query-loaders-3.0.1
|
||||
|
||||
if ENABLE_MAN
|
||||
|
||||
.xml.1:
|
||||
@XSLTPROC@ -nonet http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl $<
|
||||
|
||||
dist-local-check-mans-enabled:
|
||||
if grep "Man generation disabled" $(man_MANS) >/dev/null; then $(RM) $(man_MANS); fi
|
||||
|
||||
else
|
||||
|
||||
$(man_MANS):
|
||||
echo Man generation disabled. Creating dummy $@. Configure with --enable-man to enable it.
|
||||
echo Man generation disabled. Remove this file, configure with --enable-man, and rebuild > $@
|
||||
|
||||
|
||||
dist-local-check-mans-enabled:
|
||||
echo "*** --enable-man must be used in order to make dist"
|
||||
false
|
||||
|
||||
endif
|
||||
|
||||
MAINTAINERCLEANFILES = $(man_MANS) $(BUILT_SOURCES)
|
||||
|
||||
EXTRA_DIST += $(man_MANS)
|
||||
|
||||
dist-hook-local: dist-local-check-mans-enabled gtk-docs-clean all-local
|
||||
|
||||
gtk-docs-clean: clean
|
||||
cd $(srcdir) && rm -rf xml html
|
||||
|
||||
-include $(top_srcdir)/git.mk
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 29 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 19 KiB |
Binary file not shown.
Binary file not shown.
|
Before Width: | Height: | Size: 104 KiB |
@@ -1,177 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
|
||||
"http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd" [
|
||||
]>
|
||||
<refentry id="gdk-pixbuf-csource">
|
||||
|
||||
<refmeta>
|
||||
<refentrytitle>gdk-pixbuf-csource-3.0</refentrytitle>
|
||||
<manvolnum>1</manvolnum>
|
||||
</refmeta>
|
||||
|
||||
<refnamediv>
|
||||
<refname>gdk-pixbuf-csource-3.0</refname>
|
||||
<refpurpose>C code generation utility for GdkPixbuf images</refpurpose>
|
||||
</refnamediv>
|
||||
|
||||
<refsynopsisdiv>
|
||||
<cmdsynopsis>
|
||||
<command>gdk-pixbuf-csource-3.0</command>
|
||||
<arg choice="opt">options</arg>
|
||||
<arg choice="opt">image</arg>
|
||||
</cmdsynopsis>
|
||||
<cmdsynopsis>
|
||||
<command>gdk-pixbuf-csource-3.0</command>
|
||||
<arg choice="opt">options</arg>
|
||||
<arg choice="plain">--build-list</arg>
|
||||
<arg rep="repeat">
|
||||
<arg>name</arg>
|
||||
<arg>image</arg>
|
||||
</arg>
|
||||
</cmdsynopsis>
|
||||
</refsynopsisdiv>
|
||||
|
||||
<refsect1><title>Description</title>
|
||||
<para>
|
||||
<command>gdk-pixbuf-csource-3.0</command> is a small utility that generates
|
||||
C code containing images, useful for compiling images directly into programs.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
<refsect1><title>Invocation</title>
|
||||
<para>
|
||||
<command>gdk-pixbuf-csource-3.0</command> either takes as input one image file
|
||||
name to generate code for, or, using the <option>--build-list</option> option,
|
||||
a list of (<replaceable>name</replaceable>, <replaceable>image</replaceable>)
|
||||
pairs to generate code for a list of images into named variables.
|
||||
</para>
|
||||
<refsect2><title>Options</title>
|
||||
<variablelist>
|
||||
|
||||
<varlistentry>
|
||||
<term><option>--stream</option></term>
|
||||
<listitem><para>
|
||||
Generate pixbuf data stream (a single string containing a serialized
|
||||
<structname>GdkPixdata</structname> structure in network byte order).
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><option>--struct</option></term>
|
||||
<listitem><para>
|
||||
Generate GdkPixdata structure (needs the <structname>GdkPixdata</structname>
|
||||
structure definition from <filename>gdk-pixdata.h</filename>).
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><option>--macros</option></term>
|
||||
<listitem><para>
|
||||
Generate *_ROWSTRIDE, *_WIDTH, *_HEIGHT, *_BYTES_PER_PIXEL and
|
||||
*_RLE_PIXEL_DATA or *_PIXEL_DATA macro definitions for the image.
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><option>--rle</option></term>
|
||||
<listitem><para>
|
||||
Enables run-length encoding for the generated pixel data (default).
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><option>--raw</option></term>
|
||||
<listitem><para>
|
||||
Disables run-length encoding for the generated pixel data.
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><option>--extern</option></term>
|
||||
<listitem><para>
|
||||
Generate extern symbols.
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><option>--static</option></term>
|
||||
<listitem><para>
|
||||
Generate static symbols (default).
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><option>--decoder</option></term>
|
||||
<listitem><para>
|
||||
Provide a *_RUN_LENGTH_DECODE(image_buf, rle_data, size, bpp) macro definition
|
||||
to decode run-length encoded image data.
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><option>--name=identifier</option></term>
|
||||
<listitem><para>
|
||||
Specifies the identifier name (prefix) for the generated variables or
|
||||
macros (useful only if <option>--build-list</option> was not specified).
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><option>--build-list</option></term>
|
||||
<listitem><para>
|
||||
Enables (<replaceable>name</replaceable>, <replaceable>image</replaceable>)
|
||||
pair parsing mode.
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><option>-h</option>, <option>--help</option></term>
|
||||
<listitem><para>
|
||||
Print brief help and exit.
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><option>-v</option>, <option>--version</option></term>
|
||||
<listitem><para>
|
||||
Print version and exit.
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><option>--g-fatal-warnings</option></term>
|
||||
<listitem><para>
|
||||
Make warnings fatal (causes the program to abort).
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
</variablelist>
|
||||
</refsect2>
|
||||
</refsect1>
|
||||
|
||||
<refsect1><title>See also</title>
|
||||
<para>
|
||||
The <structname>GdkPixbuf</structname> documentation, shipped with the
|
||||
Gtk+ distribution, available from <ulink url="http://www.gtk.org">www.gtk.org</ulink>.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
<refsect1><title>Bugs</title>
|
||||
<para>
|
||||
The runlength encoder gets out of sync with the pixel boundaries, since
|
||||
it includes the rowstride padding in the encoded stream. Furthermore, it
|
||||
generates pixbufs with suboptimal rowstride in some cases.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
<refsect1><title>Author</title>
|
||||
<para>
|
||||
<command>gdk-pixbuf-csource-3.0</command> was written by Tim Janik
|
||||
<email>timj@gtk.org</email>.
|
||||
</para>
|
||||
<para>
|
||||
This manual page was provided by Tim Janik <email>timj@gtk.org</email>.
|
||||
</para>
|
||||
</refsect1>
|
||||
</refentry>
|
||||
|
||||
@@ -1,29 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
|
||||
"http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd" [
|
||||
]>
|
||||
<refentry id="gdk-pixbuf-gdk-pixbuf-from-drawables">
|
||||
<refmeta>
|
||||
<refentrytitle>Drawables to Pixbufs</refentrytitle>
|
||||
<manvolnum>3</manvolnum>
|
||||
<refmiscinfo>GDK-PIXBUF Library</refmiscinfo>
|
||||
</refmeta>
|
||||
|
||||
<refnamediv>
|
||||
<refname>Drawables to Pixbufs</refname><refpurpose>Getting parts of a GDK drawable's image data into a pixbuf.</refpurpose>
|
||||
</refnamediv>
|
||||
|
||||
<refsect1>
|
||||
<title>Description</title>
|
||||
<para>
|
||||
The functions to take the image data from a GDK drawable and dump it
|
||||
into a pixbuf are contained in GDK, see the
|
||||
<link linkend="gdk-Pixbufs">Pixbufs</link> section of the GDK
|
||||
documentation.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
||||
|
||||
|
||||
</refentry>
|
||||
@@ -1,74 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
|
||||
"http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd" [
|
||||
]>
|
||||
<refentry id="gdk-pixbuf-query-loaders">
|
||||
|
||||
<refmeta>
|
||||
<refentrytitle>gdk-pixbuf-query-loaders-3.0</refentrytitle>
|
||||
<manvolnum>1</manvolnum>
|
||||
</refmeta>
|
||||
|
||||
<refnamediv>
|
||||
<refname>gdk-pixbuf-query-loaders-3.0</refname>
|
||||
<refpurpose>GdkPixbuf loader registration utility</refpurpose>
|
||||
</refnamediv>
|
||||
|
||||
<refsynopsisdiv>
|
||||
<cmdsynopsis>
|
||||
<command>gdk-pixbuf-query-loaders-3.0</command>
|
||||
<arg choice="opt">--update-cache</arg>
|
||||
<arg choice="opt" rep="repeat">module</arg>
|
||||
</cmdsynopsis>
|
||||
</refsynopsisdiv>
|
||||
|
||||
<refsect1><title>Description</title>
|
||||
<para>
|
||||
<command>gdk-pixbuf-query-loaders-3.0</command> collects information about
|
||||
loadable modules for <application>gdk-pixbuf</application> and writes it to
|
||||
the default cache file location, or to <filename>stdout</filename>.
|
||||
</para>
|
||||
<para>
|
||||
If called without arguments, it looks for modules in the
|
||||
<application>gdk-pixbuf</application> loader directory.
|
||||
</para>
|
||||
<para>
|
||||
If called with arguments, it looks for the specified modules. The arguments
|
||||
may be absolute or relative paths.
|
||||
</para>
|
||||
<para>
|
||||
Normally, the output of <command>gdk-pixbuf-queryloaders-3.0</command> is written
|
||||
to <filename><replaceable>libdir</replaceable>gtk-3.0/3.0.0/loaders.cache</filename>, where <application>gdk-pixbuf</application> looks for it by default. If it is written to some other
|
||||
location, the environment variable <link linkend="GDK_PIXBUF_MODULE_FILE"><envar>GDK_PIXBUF_MODULE_FILE</envar></link>
|
||||
can be set to point <application>gdk-pixbuf</application> at the file.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
<refsect1><title>Options</title>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<term>--update-cache</term>
|
||||
<listitem><para>Write the output to the default cache location instead of
|
||||
<filename>stdout</filename></para></listitem>
|
||||
</varlistentry>
|
||||
</variablelist>
|
||||
</refsect1>
|
||||
|
||||
<refsect1><title>Environment</title>
|
||||
<para>
|
||||
The environment variable <envar>GDK_PIXBUF_MODULEDIR</envar> can be used
|
||||
to specify a different loader directory. The default
|
||||
<application>gdk-pixbuf</application> loader
|
||||
directory is <filename><replaceable>libdir</replaceable>/gtk-3.0/<replaceable>version</replaceable>/loaders</filename>.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
<refsect1><title>Bugs</title>
|
||||
<para>
|
||||
None known yet.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
</refentry>
|
||||
|
||||
|
||||
@@ -1,32 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
|
||||
"http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd" [
|
||||
]>
|
||||
<refentry id="gdk-pixbuf-gdk-pixbuf-rendering">
|
||||
<refmeta>
|
||||
<refentrytitle>Rendering</refentrytitle>
|
||||
<manvolnum>3</manvolnum>
|
||||
<refmiscinfo>GDK-PIXBUF Library</refmiscinfo>
|
||||
</refmeta>
|
||||
|
||||
<refnamediv>
|
||||
<refname>Rendering</refname><refpurpose>Rendering a pixbuf to a GDK drawable.</refpurpose>
|
||||
</refnamediv>
|
||||
|
||||
|
||||
<refsect1>
|
||||
<title>Description</title>
|
||||
<para>
|
||||
The functions to render pixbufs to GDK drawables are contained in
|
||||
GDK, see the <link linkend="gdk-Pixbufs">Pixbufs</link> section
|
||||
of the GDK documentation.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
||||
|
||||
|
||||
</refentry>
|
||||
|
||||
|
||||
|
||||
@@ -1,192 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
|
||||
"http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd" [
|
||||
<!ENTITY % local.common.attrib "xmlns:xi CDATA #FIXED 'http://www.w3.org/2003/XInclude'">
|
||||
<!ENTITY version SYSTEM "version.xml">
|
||||
|
||||
<!ENTITY gdk-pixbuf "<application>gdk-pixbuf</application>">
|
||||
<!ENTITY Imlib "<application>Imlib</application>">
|
||||
]>
|
||||
<book id="index" xmlns:xi="http://www.w3.org/2003/XInclude">
|
||||
<bookinfo>
|
||||
<title>GDK-PixBuf Reference Manual</title>
|
||||
<releaseinfo>
|
||||
Version &version;
|
||||
The latest version of this documentation can be found on-line at
|
||||
<ulink role="online-location" url="http://library.gnome.org/devel/gdk-pixbuf/unstable/">http://library.gnome.org/devel/gdk-pixbuf/unstable/</ulink>.
|
||||
</releaseinfo>
|
||||
<authorgroup>
|
||||
<author>
|
||||
<firstname>Federico</firstname>
|
||||
<surname>Mena Quintero</surname>
|
||||
<affiliation>
|
||||
<address>
|
||||
<email>federico@gimp.org</email>
|
||||
</address>
|
||||
</affiliation>
|
||||
</author>
|
||||
</authorgroup>
|
||||
|
||||
<copyright>
|
||||
<year>2000</year>
|
||||
<holder>The Free Software Foundation</holder>
|
||||
</copyright>
|
||||
|
||||
<legalnotice>
|
||||
<para>
|
||||
Permission is granted to copy, distribute and/or modify this
|
||||
document under the terms of the <citetitle>GNU Free
|
||||
Documentation License</citetitle>, Version 1.1 or any later
|
||||
version published by the Free Software Foundation with no
|
||||
Invariant Sections, no Front-Cover Texts, and no Back-Cover
|
||||
Texts. You may obtain a copy of the <citetitle>GNU Free
|
||||
Documentation License</citetitle> from the Free Software
|
||||
Foundation by visiting <ulink type="http"
|
||||
url="http://www.fsf.org">their Web site</ulink> or by writing
|
||||
to:
|
||||
|
||||
<address>
|
||||
The Free Software Foundation, Inc.,
|
||||
<street>59 Temple Place</street> - Suite 330,
|
||||
<city>Boston</city>, <state>MA</state> <postcode>02111-1307</postcode>,
|
||||
<country>USA</country>
|
||||
</address>
|
||||
</para>
|
||||
|
||||
<para>
|
||||
Many of the names used by companies to distinguish their
|
||||
products and services are claimed as trademarks. Where those
|
||||
names appear in any GNOME documentation, and those trademarks
|
||||
are made aware to the members of the GNOME Documentation
|
||||
Project, the names have been printed in caps or initial caps.
|
||||
</para>
|
||||
</legalnotice>
|
||||
</bookinfo>
|
||||
|
||||
<reference>
|
||||
<title>API Reference</title>
|
||||
|
||||
<partintro>
|
||||
<para>
|
||||
This part presents the class and function reference for the
|
||||
&gdk-pixbuf; library. Classes are described together with
|
||||
their methods; individual functions are grouped by functional
|
||||
group.
|
||||
</para>
|
||||
</partintro>
|
||||
|
||||
<xi:include href="xml/initialization_versions.xml" />
|
||||
|
||||
<xi:include href="xml/gdk-pixbuf.xml" />
|
||||
<xi:include href="xml/refcounting.xml" />
|
||||
<xi:include href="xml/file-loading.xml" />
|
||||
<xi:include href="xml/file-saving.xml" />
|
||||
<xi:include href="xml/creating.xml" />
|
||||
<xi:include href="xml/inline.xml" />
|
||||
<xi:include href="xml/scaling.xml" />
|
||||
<xi:include href="gdk-pixbuf-rendering.sgml" />
|
||||
<xi:include href="gdk-pixbuf-from-drawables.sgml" />
|
||||
<xi:include href="xml/util.xml" />
|
||||
<xi:include href="xml/animation.xml" />
|
||||
|
||||
<xi:include href="xml/gdk-pixbuf-loader.xml" />
|
||||
<xi:include href="xml/module_interface.xml" />
|
||||
|
||||
<xi:include href="xml/gdk-pixbuf-xlib-init.xml" />
|
||||
<xi:include href="xml/gdk-pixbuf-xlib-rendering.xml" />
|
||||
<xi:include href="xml/gdk-pixbuf-xlib-from-drawables.xml" />
|
||||
<xi:include href="xml/gdk-pixbuf-xlib-rgb.xml" />
|
||||
</reference>
|
||||
|
||||
<reference>
|
||||
<title>Tools Reference</title>
|
||||
|
||||
<partintro>
|
||||
<para>
|
||||
This part presents the tools which are shipped with the
|
||||
&gdk-pixbuf; library.
|
||||
</para>
|
||||
</partintro>
|
||||
|
||||
<xi:include href="gdk-pixbuf-csource-3.0.xml" />
|
||||
<xi:include href="gdk-pixbuf-query-loaders-3.0.xml" />
|
||||
</reference>
|
||||
|
||||
<index id="api-index-full">
|
||||
<title>Index of all symbols</title>
|
||||
<xi:include href="xml/api-index-full.xml"><xi:fallback /></xi:include>
|
||||
</index>
|
||||
<index id="api-index-deprecated" role="deprecated">
|
||||
<title>Index of deprecated symbols</title>
|
||||
<xi:include href="xml/api-index-deprecated.xml"><xi:fallback /></xi:include>
|
||||
</index>
|
||||
<index id="api-index-2-2" role="2.2">
|
||||
<title>Index of new symbols in 2.2</title>
|
||||
<xi:include href="xml/api-index-2.2.xml"><xi:fallback /></xi:include>
|
||||
</index>
|
||||
<index id="api-index-2-4" role="2.4">
|
||||
<title>Index of new symbols in 2.4</title>
|
||||
<xi:include href="xml/api-index-2.4.xml"><xi:fallback /></xi:include>
|
||||
</index>
|
||||
<index id="api-index-2-6" role="2.6">
|
||||
<title>Index of new symbols in 2.6</title>
|
||||
<xi:include href="xml/api-index-2.6.xml"><xi:fallback /></xi:include>
|
||||
</index>
|
||||
<index id="api-index-2-8" role="2.8">
|
||||
<title>Index of new symbols in 2.8</title>
|
||||
<xi:include href="xml/api-index-2.8.xml"><xi:fallback /></xi:include>
|
||||
</index>
|
||||
<index id="api-index-2-10" role="2.10">
|
||||
<title>Index of new symbols in 2.10</title>
|
||||
<xi:include href="xml/api-index-2.10.xml"><xi:fallback /></xi:include>
|
||||
</index>
|
||||
<index id="api-index-2-12" role="2.12">
|
||||
<title>Index of new symbols in 2.12</title>
|
||||
<xi:include href="xml/api-index-2.12.xml"><xi:fallback /></xi:include>
|
||||
</index>
|
||||
<index id="api-index-2-14" role="2.14">
|
||||
<title>Index of new symbols in 2.14</title>
|
||||
<xi:include href="xml/api-index-2.14.xml"><xi:fallback /></xi:include>
|
||||
</index>
|
||||
|
||||
<xi:include href="porting-from-imlib.sgml" />
|
||||
|
||||
<!-- License -->
|
||||
|
||||
<appendix id="license">
|
||||
<title>License</title>
|
||||
|
||||
<para>
|
||||
This library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the <citetitle>GNU Library General
|
||||
Public License</citetitle> as published by the Free Software
|
||||
Foundation; either version 2 of the License, or (at your option)
|
||||
any later version.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
This library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
<citetitle>GNU Library General Public License</citetitle> for
|
||||
more details.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
You may obtain a copy of the <citetitle>GNU Library General
|
||||
Public License</citetitle> from the Free Software Foundation by
|
||||
visiting <ulink type="http" url="http://www.fsf.org">their Web
|
||||
site</ulink> or by writing to:
|
||||
|
||||
<address>
|
||||
Free Software Foundation, Inc.
|
||||
<street>59 Temple Place</street> - Suite 330
|
||||
<city>Boston</city>, <state>MA</state> <postcode>02111-1307</postcode>
|
||||
<country>USA</country>
|
||||
</address>
|
||||
</para>
|
||||
</appendix>
|
||||
|
||||
<xi:include href="xml/annotation-glossary.xml"><xi:fallback /></xi:include>
|
||||
|
||||
</book>
|
||||
@@ -1,298 +0,0 @@
|
||||
<INCLUDE>gdk-pixbuf/gdk-pixbuf.h</INCLUDE>
|
||||
|
||||
<SECTION>
|
||||
<TITLE>Versioning</TITLE>
|
||||
<FILE>initialization_versions</FILE>
|
||||
|
||||
<SUBSECTION>
|
||||
gdk_pixbuf_version
|
||||
gdk_pixbuf_major_version
|
||||
gdk_pixbuf_minor_version
|
||||
gdk_pixbuf_micro_version
|
||||
GDK_PIXBUF_VERSION
|
||||
GDK_PIXBUF_MAJOR
|
||||
GDK_PIXBUF_MINOR
|
||||
GDK_PIXBUF_MICRO
|
||||
|
||||
<SUBSECTION Private>
|
||||
GDK_PIXBUF_VAR
|
||||
</SECTION>
|
||||
|
||||
<SECTION>
|
||||
<FILE>gdk-pixbuf</FILE>
|
||||
GdkPixbufError
|
||||
GDK_PIXBUF_ERROR
|
||||
GdkColorspace
|
||||
GdkPixbufAlphaMode
|
||||
GdkPixbuf
|
||||
gdk_pixbuf_get_colorspace
|
||||
gdk_pixbuf_get_n_channels
|
||||
gdk_pixbuf_get_has_alpha
|
||||
gdk_pixbuf_get_bits_per_sample
|
||||
gdk_pixbuf_get_pixels
|
||||
gdk_pixbuf_get_width
|
||||
gdk_pixbuf_get_height
|
||||
gdk_pixbuf_get_rowstride
|
||||
gdk_pixbuf_get_option
|
||||
|
||||
<SUBSECTION Standard>
|
||||
GDK_TYPE_PIXBUF_ERROR
|
||||
GDK_TYPE_COLORSPACE
|
||||
GDK_TYPE_PIXBUF_ALPHA_MODE
|
||||
GDK_PIXBUF
|
||||
GDK_TYPE_PIXBUF
|
||||
GDK_IS_PIXBUF
|
||||
|
||||
|
||||
<SUBSECTION Private>
|
||||
gdk_pixbuf_get_type
|
||||
gdk_pixbuf_error_quark
|
||||
gdk_colorspace_get_type
|
||||
gdk_pixbuf_alpha_mode_get_type
|
||||
gdk_pixbuf_error_get_type
|
||||
</SECTION>
|
||||
|
||||
<SECTION>
|
||||
<FILE>refcounting</FILE>
|
||||
GdkPixbufDestroyNotify
|
||||
</SECTION>
|
||||
|
||||
<SECTION>
|
||||
<FILE>file-loading</FILE>
|
||||
gdk_pixbuf_new_from_file
|
||||
gdk_pixbuf_new_from_file_at_size
|
||||
gdk_pixbuf_new_from_file_at_scale
|
||||
gdk_pixbuf_get_file_info
|
||||
gdk_pixbuf_new_from_stream
|
||||
gdk_pixbuf_new_from_stream_at_scale
|
||||
</SECTION>
|
||||
|
||||
<SECTION>
|
||||
<FILE>file-saving</FILE>
|
||||
gdk_pixbuf_savev
|
||||
gdk_pixbuf_save
|
||||
GdkPixbufSaveFunc
|
||||
gdk_pixbuf_save_to_callback
|
||||
gdk_pixbuf_save_to_callbackv
|
||||
gdk_pixbuf_save_to_buffer
|
||||
gdk_pixbuf_save_to_bufferv
|
||||
gdk_pixbuf_save_to_stream
|
||||
</SECTION>
|
||||
|
||||
<SECTION>
|
||||
<FILE>creating</FILE>
|
||||
gdk_pixbuf_new
|
||||
gdk_pixbuf_new_from_data
|
||||
gdk_pixbuf_new_from_xpm_data
|
||||
gdk_pixbuf_new_from_inline
|
||||
gdk_pixbuf_new_subpixbuf
|
||||
gdk_pixbuf_copy
|
||||
</SECTION>
|
||||
|
||||
<SECTION>
|
||||
<INCLUDE>gdk-pixbuf/gdk-pixdata.h</INCLUDE>
|
||||
<FILE>inline</FILE>
|
||||
GdkPixdata
|
||||
GdkPixdataType
|
||||
GdkPixdataDumpType
|
||||
GDK_PIXBUF_MAGIC_NUMBER
|
||||
GDK_PIXDATA_HEADER_LENGTH
|
||||
gdk_pixdata_from_pixbuf
|
||||
gdk_pixbuf_from_pixdata
|
||||
gdk_pixdata_serialize
|
||||
gdk_pixdata_deserialize
|
||||
gdk_pixdata_to_csource
|
||||
</SECTION>
|
||||
|
||||
<SECTION>
|
||||
<FILE>util</FILE>
|
||||
gdk_pixbuf_add_alpha
|
||||
gdk_pixbuf_copy_area
|
||||
gdk_pixbuf_saturate_and_pixelate
|
||||
gdk_pixbuf_apply_embedded_orientation
|
||||
gdk_pixbuf_fill
|
||||
</SECTION>
|
||||
|
||||
<SECTION>
|
||||
<FILE>animation</FILE>
|
||||
GdkPixbufAnimation
|
||||
GdkPixbufAnimationIter
|
||||
gdk_pixbuf_animation_new_from_file
|
||||
gdk_pixbuf_animation_get_width
|
||||
gdk_pixbuf_animation_get_height
|
||||
gdk_pixbuf_animation_get_iter
|
||||
gdk_pixbuf_animation_is_static_image
|
||||
gdk_pixbuf_animation_get_static_image
|
||||
gdk_pixbuf_animation_iter_advance
|
||||
gdk_pixbuf_animation_iter_get_delay_time
|
||||
gdk_pixbuf_animation_iter_on_currently_loading_frame
|
||||
gdk_pixbuf_animation_iter_get_pixbuf
|
||||
|
||||
<SUBSECTION>
|
||||
GdkPixbufSimpleAnim
|
||||
gdk_pixbuf_simple_anim_new
|
||||
gdk_pixbuf_simple_anim_add_frame
|
||||
gdk_pixbuf_simple_anim_set_loop
|
||||
gdk_pixbuf_simple_anim_get_loop
|
||||
|
||||
<SUBSECTION Standard>
|
||||
GDK_PIXBUF_ANIMATION
|
||||
GDK_TYPE_PIXBUF_ANIMATION
|
||||
GDK_IS_PIXBUF_ANIMATION
|
||||
GDK_IS_PIXBUF_ANIMATION_ITER
|
||||
GDK_PIXBUF_ANIMATION_ITER
|
||||
GDK_TYPE_PIXBUF_ANIMATION_ITER
|
||||
|
||||
GDK_PIXBUF_SIMPLE_ANIM_GET_CLASS
|
||||
GDK_IS_PIXBUF_SIMPLE_ANIM
|
||||
GDK_PIXBUF_SIMPLE_ANIM_CLASS
|
||||
GDK_IS_PIXBUF_SIMPLE_ANIM_CLASS
|
||||
GDK_TYPE_PIXBUF_SIMPLE_ANIM
|
||||
GDK_PIXBUF_SIMPLE_ANIM
|
||||
GDK_TYPE_PIXBUF_SCALED_ANIM
|
||||
GDK_TYPE_PIXBUF_SCALED_ANIM_ITER
|
||||
<SUBSECTION Private>
|
||||
gdk_pixbuf_non_anim_new
|
||||
|
||||
gdk_pixbuf_animation_get_type
|
||||
gdk_pixbuf_animation_iter_get_type
|
||||
|
||||
gdk_pixbuf_simple_anim_get_type
|
||||
gdk_pixbuf_simple_anim_iter_get_type
|
||||
GdkPixbufSimpleAnimClass
|
||||
gdk_pixbuf_scaled_anim_get_type
|
||||
gdk_pixbuf_scaled_anim_iter_get_type
|
||||
GdkPixbufScaledAnimClass
|
||||
GdkPixbufScaledAnim
|
||||
</SECTION>
|
||||
|
||||
<SECTION>
|
||||
<FILE>scaling</FILE>
|
||||
GdkInterpType
|
||||
gdk_pixbuf_scale_simple
|
||||
gdk_pixbuf_scale
|
||||
gdk_pixbuf_composite_color_simple
|
||||
gdk_pixbuf_composite
|
||||
gdk_pixbuf_composite_color
|
||||
GdkPixbufRotation
|
||||
gdk_pixbuf_rotate_simple
|
||||
gdk_pixbuf_flip
|
||||
|
||||
<SUBSECTION Standard>
|
||||
GDK_TYPE_INTERP_TYPE
|
||||
GDK_TYPE_PIXBUF_ROTATION
|
||||
|
||||
<SUBSECTION Private>
|
||||
gdk_interp_type_get_type
|
||||
gdk_pixbuf_rotation_get_type
|
||||
</SECTION>
|
||||
|
||||
<SECTION>
|
||||
<FILE>gdk-pixbuf-loader</FILE>
|
||||
<TITLE>GdkPixbufLoader</TITLE>
|
||||
GdkPixbufLoader
|
||||
gdk_pixbuf_loader_new
|
||||
gdk_pixbuf_loader_new_with_type
|
||||
gdk_pixbuf_loader_new_with_mime_type
|
||||
gdk_pixbuf_loader_get_format
|
||||
gdk_pixbuf_loader_write
|
||||
gdk_pixbuf_loader_set_size
|
||||
gdk_pixbuf_loader_get_pixbuf
|
||||
gdk_pixbuf_loader_get_animation
|
||||
gdk_pixbuf_loader_close
|
||||
<SUBSECTION Standard>
|
||||
GDK_PIXBUF_LOADER
|
||||
GDK_PIXBUF_LOADER_GET_CLASS
|
||||
GDK_TYPE_PIXBUF_LOADER
|
||||
GDK_IS_PIXBUF_LOADER
|
||||
GDK_PIXBUF_LOADER_CLASS
|
||||
GDK_IS_PIXBUF_LOADER_CLASS
|
||||
<SUBSECTION Private>
|
||||
GdkPixbufLoaderClass
|
||||
gdk_pixbuf_loader_get_type
|
||||
</SECTION>
|
||||
|
||||
<SECTION>
|
||||
<TITLE>Module Interface</TITLE>
|
||||
<FILE>module_interface</FILE>
|
||||
gdk_pixbuf_set_option
|
||||
gdk_pixbuf_get_formats
|
||||
gdk_pixbuf_format_get_name
|
||||
gdk_pixbuf_format_get_description
|
||||
gdk_pixbuf_format_get_mime_types
|
||||
gdk_pixbuf_format_get_extensions
|
||||
gdk_pixbuf_format_is_writable
|
||||
gdk_pixbuf_format_is_scalable
|
||||
gdk_pixbuf_format_is_disabled
|
||||
gdk_pixbuf_format_set_disabled
|
||||
gdk_pixbuf_format_get_license
|
||||
GdkPixbufFormat
|
||||
GdkPixbufFormatFlags
|
||||
GdkPixbufModulePattern
|
||||
GdkPixbufModuleFillVtableFunc
|
||||
GdkPixbufModuleFillInfoFunc
|
||||
GdkPixbufModuleSizeFunc
|
||||
GdkPixbufModulePreparedFunc
|
||||
GdkPixbufModuleUpdatedFunc
|
||||
GdkPixbufModule
|
||||
|
||||
<SUBSECTION Animation>
|
||||
GdkPixbufAnimationClass
|
||||
GdkPixbufAnimationIterClass
|
||||
|
||||
<SUBSECTION Standard>
|
||||
GDK_PIXBUF_ANIMATION_GET_CLASS
|
||||
GDK_IS_PIXBUF_ANIMATION_ITER_CLASS
|
||||
GDK_PIXBUF_ANIMATION_ITER_CLASS
|
||||
GDK_IS_PIXBUF_ANIMATION_CLASS
|
||||
GDK_PIXBUF_ANIMATION_ITER_GET_CLASS
|
||||
GDK_PIXBUF_ANIMATION_CLASS
|
||||
</SECTION>
|
||||
|
||||
<SECTION>
|
||||
<FILE>gdk-pixbuf-xlib-init</FILE>
|
||||
gdk_pixbuf_xlib_init
|
||||
gdk_pixbuf_xlib_init_with_depth
|
||||
</SECTION>
|
||||
|
||||
<SECTION>
|
||||
<FILE>gdk-pixbuf-xlib-rendering</FILE>
|
||||
gdk_pixbuf_xlib_render_threshold_alpha
|
||||
gdk_pixbuf_xlib_render_to_drawable
|
||||
gdk_pixbuf_xlib_render_to_drawable_alpha
|
||||
gdk_pixbuf_xlib_render_pixmap_and_mask
|
||||
</SECTION>
|
||||
|
||||
<SECTION>
|
||||
<FILE>gdk-pixbuf-xlib-from-drawables</FILE>
|
||||
gdk_pixbuf_xlib_get_from_drawable
|
||||
</SECTION>
|
||||
|
||||
<SECTION>
|
||||
<FILE>gdk-pixbuf-xlib-rgb</FILE>
|
||||
XlibRgbCmap
|
||||
XlibRgbDither
|
||||
xlib_rgb_init
|
||||
xlib_rgb_init_with_depth
|
||||
xlib_rgb_xpixel_from_rgb
|
||||
xlib_rgb_gc_set_foreground
|
||||
xlib_rgb_gc_set_background
|
||||
xlib_draw_rgb_image
|
||||
xlib_draw_rgb_image_dithalign
|
||||
xlib_draw_rgb_32_image
|
||||
xlib_draw_gray_image
|
||||
xlib_rgb_cmap_new
|
||||
xlib_rgb_cmap_free
|
||||
xlib_draw_indexed_image
|
||||
xlib_rgb_ditherable
|
||||
xlib_rgb_set_verbose
|
||||
xlib_rgb_set_install
|
||||
xlib_rgb_set_min_colors
|
||||
xlib_rgb_get_cmap
|
||||
xlib_rgb_get_visual
|
||||
xlib_rgb_get_visual_info
|
||||
xlib_rgb_get_depth
|
||||
xlib_rgb_get_display
|
||||
xlib_rgb_get_screen
|
||||
</SECTION>
|
||||
|
||||
@@ -1,8 +0,0 @@
|
||||
#include <gdk-pixbuf/gdk-pixbuf.h>
|
||||
|
||||
gdk_pixbuf_get_type
|
||||
gdk_pixbuf_loader_get_type
|
||||
gdk_pixbuf_animation_get_type
|
||||
gdk_pixbuf_animation_iter_get_type
|
||||
gdk_pixbuf_simple_anim_get_type
|
||||
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 23 KiB |
@@ -1,358 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
<!DOCTYPE appendix PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
|
||||
"http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd" [
|
||||
<!ENTITY gdk-pixbuf "<application>gdk-pixbuf</application>">
|
||||
<!ENTITY Imlib "<application>Imlib</application>">
|
||||
]>
|
||||
<appendix>
|
||||
<title>Porting applications from &Imlib; to &gdk-pixbuf;</title>
|
||||
|
||||
<para>
|
||||
This appendix contains the basic steps needed to port an
|
||||
application that uses the &Imlib; library to use &gdk-pixbuf;
|
||||
instead.
|
||||
</para>
|
||||
|
||||
<note>
|
||||
<para>
|
||||
This appendix refers to version 1 of the &Imlib; library; this
|
||||
discussion is not relevant to Imlib 2. Also, we discuss the
|
||||
gdk_imlib API instead of the Xlib-based API.
|
||||
</para>
|
||||
</note>
|
||||
|
||||
<!-- Introduction -->
|
||||
|
||||
<sect1>
|
||||
<title>Introduction</title>
|
||||
|
||||
<para>
|
||||
Prior to the GNOME 1.2 platform, the &Imlib; library was the
|
||||
preferred way of loading and rendering images in GNOME
|
||||
applications. Unfortunately, &Imlib; has important design
|
||||
limitations that make it hard to write efficient and highly
|
||||
modular applications.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
The &gdk-pixbuf; library was designed as a solution to
|
||||
&Imlib;'s shortcomings. It provides a simple, orthogonal API
|
||||
and convenience functions for the most common operations. In
|
||||
addition, it supports full transparency information for
|
||||
images, or alpha channel. More importantly, it has
|
||||
well-defined semantics for memory management through the use
|
||||
of reference counting; &Imlib; has an intractably complex
|
||||
memory management mechanism and cache that will make your head
|
||||
spin.
|
||||
</para>
|
||||
</sect1>
|
||||
|
||||
<!-- Differences between Imlib and gdk-pixbuf -->
|
||||
|
||||
<sect1>
|
||||
<title>Differences between &Imlib; and &gdk-pixbuf;</title>
|
||||
|
||||
<para>
|
||||
Generally, applications that use &Imlib; do not have to be
|
||||
changed extensively to use &gdk-pixbuf;; its simple and
|
||||
flexible API makes things easy. This section describes the
|
||||
differences between &Imlib; and &gdk-pixbuf;; you should take
|
||||
these into account when modifying your applications to use
|
||||
&gdk-pixbuf;.
|
||||
</para>
|
||||
|
||||
<!-- Initialization -->
|
||||
|
||||
<sect2>
|
||||
<title>Initialization</title>
|
||||
|
||||
<para>
|
||||
The &gdk-pixbuf; library does not need to be initialized.
|
||||
</para>
|
||||
|
||||
<note>
|
||||
<para>
|
||||
In GNOME applications you normally don't need to
|
||||
initialize &Imlib;, as <function>gnome_init()</function>
|
||||
calls <function>gdk_imlib_init()</function> automatically.
|
||||
</para>
|
||||
</note>
|
||||
</sect2>
|
||||
|
||||
<!-- Memory management -->
|
||||
|
||||
<sect2>
|
||||
<title>Memory management</title>
|
||||
|
||||
<para>
|
||||
The &gdk-pixbuf; library provides a simple, well-defined
|
||||
memory management mechanism for images in the form of
|
||||
reference counting. This makes it very convenient to use
|
||||
for large-scale applications that need to share images
|
||||
between different parts of the program. In stark contrast,
|
||||
&Imlib; has a terribly complex mechanism of an image and
|
||||
pixmap cache which makes it very hard for applications to
|
||||
share image structures between different parts of the
|
||||
program. Unfortunately this mechanism makes things very
|
||||
prone to memory leaks and tricky bugs.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
The basic principle in &gdk-pixbuf; is that when you obtain
|
||||
a new <link linkend="GdkPixbuf">GdkPixbuf</link> structure,
|
||||
it is created with an initial reference count of 1. When
|
||||
another part of the program wants to keep a reference to the
|
||||
pixbuf, it should call <function>g_object_ref()</function>;
|
||||
this will increase the reference count by 1. When some part
|
||||
of the program does not need to keep a reference to a pixbuf
|
||||
anymore and wants to release the pixbuf, it should call
|
||||
<function>g_object_unref()</function>; this will decrease
|
||||
the reference count by 1. When the reference count drops to
|
||||
zero, the pixbuf gets destroyed or
|
||||
<emphasis>finalized</emphasis> and its memory is freed.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
For applications that need to implement a cache of loaded
|
||||
images, &gdk-pixbuf; provides a way to hook to the last
|
||||
unreference operation of a pixbuf; instead of finalizing the
|
||||
pixbuf, the user-installed hook can decide to keep it around
|
||||
in a cache instead.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
Finally, &gdk-pixbuf; does not provide a cache of rendered
|
||||
pixmaps. This is unnecessary for most applications, since
|
||||
the scaling and rendering functions are quite fast and
|
||||
applications may need to use subtly different values each
|
||||
time they call these functions, for example, to take into
|
||||
account dithering and zooming offsets.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
Most applications will simply need to call
|
||||
<function>g_object_ref()</function> when they want to keep
|
||||
an extra reference to a pixbuf, and then
|
||||
<function>g_object_unref()</function> when they are done
|
||||
with it.
|
||||
</para>
|
||||
</sect2>
|
||||
|
||||
<!-- The Rendering Process -->
|
||||
|
||||
<sect2>
|
||||
<title>The Rendering Process</title>
|
||||
|
||||
<para>
|
||||
The &gdk-pixbuf; library has the policy of always rendering
|
||||
pixbufs to GDK drawables you provide; it will not create
|
||||
them for you. This is in general more flexible than
|
||||
&Imlib;'s policy of always creating a pixmap and making you
|
||||
use that instead.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
The disadvantage of always having a pixmap created for you
|
||||
is that it wastes memory in the X server if you intend to
|
||||
copy that rendered data onto another drawable, for example,
|
||||
the final destination window or a temporary pixmap for
|
||||
drawing. This is the most common case, unfortunately, so
|
||||
the &Imlib; policy introduces unnecessary copying.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
Also, &Imlib; can only render pixmaps that are the whole
|
||||
size of the source image; you cannot render just a subset
|
||||
region of the image. This is inconvenient for applications
|
||||
that need to render small portions at a time, such as
|
||||
applications that do scrolling. Since the whole image must
|
||||
be rendered at a time, this can lead to performance and
|
||||
memory usage problems.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
The &gdk-pixbuf; library lets you render any rectangular
|
||||
region from an image onto any drawable that you provide.
|
||||
This lets the application have fine control the way images
|
||||
are rendered.
|
||||
</para>
|
||||
</sect2>
|
||||
</sect1>
|
||||
|
||||
<!-- Converting Applications to gdk-pixbuf -->
|
||||
|
||||
<sect1>
|
||||
<title>Converting Applications to &gdk-pixbuf;</title>
|
||||
|
||||
<para>
|
||||
This sections describes the actual changes you need to make in
|
||||
an &Imlib; program to make it use &gdk-pixbuf; instead.
|
||||
</para>
|
||||
|
||||
<!-- Image loading and creation -->
|
||||
|
||||
<sect2>
|
||||
<title>Image loading and creation</title>
|
||||
|
||||
<para>
|
||||
The &gdk-pixbuf; library can load image files synchronously
|
||||
(i.e. with a single function call), create images from RGB
|
||||
data in memory, and as a convenience, it can also create
|
||||
images from inline XPM data.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
To load an image file in a single function call, simply use
|
||||
<function>gdk_pixbuf_new_from_file()</function>. Note that
|
||||
this will make the program block until the whole file has
|
||||
been read. This function effectively replaces
|
||||
<function>gdk_imlib_load_image()</function>.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
If you have RGB data in memory, you can use
|
||||
<function>gdk_pixbuf_new_from_data()</function> to create a
|
||||
pixbuf out of it; this is a replacement for
|
||||
<function>gdk_imlib_create_image_from_data()</function>.
|
||||
&gdk-pixbuf; does not copy the image data; it is up to you
|
||||
to define the ownership policy by providing a destroy
|
||||
notification function that will be called when the image
|
||||
data needs to be freed. The function you provide can then
|
||||
free the data or do something else, as appropriate.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
As a convenience, you can use the
|
||||
<function>gdk_pixbuf_new_from_xpm_data()</function> function
|
||||
to create a pixbuf out of inline XPM data that was compiled
|
||||
into your C program. This is a replacement for
|
||||
<function>gdk_imlib_create_image_from_xpm_data()</function>.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
After you have created a pixbuf, you can manipulate it in
|
||||
any way you please and then finally call
|
||||
<function>g_object_unref()</function> when you are done
|
||||
with it. This can be thought of as a replacement for
|
||||
<function>gdk_imlib_destroy_image()</function> but with much
|
||||
cleaner semantics.
|
||||
</para>
|
||||
</sect2>
|
||||
|
||||
<!-- Rendering Images -->
|
||||
|
||||
<sect2>
|
||||
<title>Rendering Images</title>
|
||||
|
||||
<para>
|
||||
Applications that use &Imlib; must first call
|
||||
<function>gdk_imlib_render()</function> to render the whole
|
||||
image data onto a pixmap that &Imlib; creates. Then they
|
||||
must copy that pixmap's data into the final destination for
|
||||
the image.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
In contrast, &gdk-pixbuf; provides convenience functions to
|
||||
render arbitrary rectangular regions of an image onto a
|
||||
drawable that your application provides. You can use
|
||||
<function>gdk_draw_pixbuf()</function> to do this; having
|
||||
your application provide the destination drawable and
|
||||
specify an arbitrary region means your application has
|
||||
complete control over the way images are rendered.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
As a convenience, &gdk-pixbuf; also provides the
|
||||
<function>gdk_pixbuf_render_pixmap_and_mask()</function>
|
||||
function; this will create new pixmap and mask drawables for
|
||||
a whole pixbuf and render the image data onto them. Only
|
||||
trivially simple applications should find a use for this
|
||||
function, since usually you want finer control of how things
|
||||
are rendered.
|
||||
</para>
|
||||
</sect2>
|
||||
|
||||
<!-- Scaling Images -->
|
||||
|
||||
<sect2>
|
||||
<title>Scaling Images</title>
|
||||
|
||||
<para>
|
||||
&Imlib; lets you render scaled image data at the time you
|
||||
call <function>gdk_imlib_render()</function>. Again, this
|
||||
unfortunately scales and renders the whole image onto a new
|
||||
pixmap.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
&gdk-pixbuf; provides a number of functions that do scaling
|
||||
of arbitrary regions of a source pixbuf onto a destination
|
||||
one. These functions can also perform compositing
|
||||
operations against the data in the destination pixbuf or
|
||||
against a solid color or a colored checkerboard.
|
||||
<footnote>
|
||||
<para>
|
||||
You can use a colored checkerboard as the background for
|
||||
compositing when you want to provide a visual indication
|
||||
that the image has partially opaque areas. This is
|
||||
normally used in image editing and viewing programs.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
Compositing against a single solid color is actually a
|
||||
special case of a checkerboard; it simply uses checks of
|
||||
the same color.
|
||||
</para>
|
||||
</footnote>
|
||||
</para>
|
||||
|
||||
<para>
|
||||
Very simple applications may find it sufficient to use
|
||||
<function>gdk_pixbuf_scale_simple()</function> or
|
||||
<function>gdk_pixbuf_composite_color_simple()</function>.
|
||||
These functions scale the whole source image at a time and
|
||||
create a new pixbuf with the result.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
More sophisticated applications will need to use
|
||||
<function>gdk_pixbuf_scale()</function>,
|
||||
<function>gdk_pixbuf_composite()</function>, or
|
||||
<function>gdk_pixbuf_composite_color()</function> instead.
|
||||
These functions let you scale and composite an arbitrary
|
||||
region of the source pixbuf onto a destination pixbuf that
|
||||
you provide.
|
||||
</para>
|
||||
</sect2>
|
||||
|
||||
<!-- Getting Image Data from a Drawable -->
|
||||
|
||||
<sect2>
|
||||
<title>Getting Image Data from a Drawable</title>
|
||||
|
||||
<para>
|
||||
&Imlib; lets you create an image by fetching a drawable's
|
||||
contents from the X server and converting those into RGB
|
||||
data. This is done with the
|
||||
<function>gdk_imlib_create_image_from_drawable()</function>
|
||||
function.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
&gdk-pixbuf; provides the
|
||||
<function>gdk_pixbuf_get_from_drawable()</function> function
|
||||
instead. It lets you specify a destination pixbuf instead
|
||||
of always creating a new one for you.
|
||||
</para>
|
||||
</sect2>
|
||||
</sect1>
|
||||
</appendix>
|
||||
|
||||
<!--
|
||||
Local variables:
|
||||
mode: sgml
|
||||
sgml-parent-document: ("gdk-pixbuf.sgml" "book" "book" "")
|
||||
End:
|
||||
-->
|
||||
|
||||
@@ -1,183 +0,0 @@
|
||||
<!-- ##### SECTION Title ##### -->
|
||||
Animations
|
||||
|
||||
<!-- ##### SECTION Short_Description ##### -->
|
||||
Animated images.
|
||||
|
||||
<!-- ##### SECTION Long_Description ##### -->
|
||||
<para>
|
||||
The &gdk-pixbuf; library provides a simple mechanism to load and represent
|
||||
animations. An animation is conceptually a series of frames to be displayed
|
||||
over time. Each frame is the same size. The animation may not be represented
|
||||
as a series of frames internally; for example, it may be stored as a
|
||||
sprite and instructions for moving the sprite around a background. To display
|
||||
an animation you don't need to understand its representation, however; you just
|
||||
ask &gdk-pixbuf; what should be displayed at a given point in time.
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION See_Also ##### -->
|
||||
<para>
|
||||
#GdkPixbufLoader
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION Stability_Level ##### -->
|
||||
|
||||
|
||||
<!-- ##### SECTION Image ##### -->
|
||||
|
||||
|
||||
<!-- ##### STRUCT GdkPixbufAnimation ##### -->
|
||||
<para>
|
||||
An opaque struct representing an animation.
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### STRUCT GdkPixbufAnimationIter ##### -->
|
||||
<para>
|
||||
An opaque struct representing an iterator which points to a
|
||||
certain position in an animation.
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_animation_new_from_file ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@filename:
|
||||
@error:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_animation_get_width ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@animation:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_animation_get_height ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@animation:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_animation_get_iter ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@animation:
|
||||
@start_time:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_animation_is_static_image ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@animation:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_animation_get_static_image ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@animation:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_animation_iter_advance ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@iter:
|
||||
@current_time:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_animation_iter_get_delay_time ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@iter:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_animation_iter_on_currently_loading_frame ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@iter:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_animation_iter_get_pixbuf ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@iter:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### STRUCT GdkPixbufSimpleAnim ##### -->
|
||||
<para>
|
||||
An opaque struct representing a simple animation.
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### ARG GdkPixbufSimpleAnim:loop ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_simple_anim_new ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@width:
|
||||
@height:
|
||||
@rate:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_simple_anim_add_frame ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@animation:
|
||||
@pixbuf:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_simple_anim_set_loop ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@animation:
|
||||
@loop:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_simple_anim_get_loop ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@animation:
|
||||
@Returns:
|
||||
|
||||
|
||||
@@ -1,129 +0,0 @@
|
||||
<!-- ##### SECTION Title ##### -->
|
||||
Image Data in Memory
|
||||
|
||||
<!-- ##### SECTION Short_Description ##### -->
|
||||
Creating a pixbuf from image data that is already in memory.
|
||||
|
||||
<!-- ##### SECTION Long_Description ##### -->
|
||||
<para>
|
||||
The most basic way to create a pixbuf is to wrap an existing pixel
|
||||
buffer with a #GdkPixbuf structure. You can use the
|
||||
gdk_pixbuf_new_from_data() function to do this You need to specify
|
||||
the destroy notification function that will be called when the
|
||||
data buffer needs to be freed; this will happen when a #GdkPixbuf
|
||||
is finalized by the reference counting functions If you have a
|
||||
chunk of static data compiled into your application, you can pass
|
||||
in %NULL as the destroy notification function so that the data
|
||||
will not be freed.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
The gdk_pixbuf_new() function can be used as a convenience to
|
||||
create a pixbuf with an empty buffer. This is equivalent to
|
||||
allocating a data buffer using <function>malloc()</function> and
|
||||
then wrapping it with gdk_pixbuf_new_from_data(). The gdk_pixbuf_new()
|
||||
function will compute an optimal rowstride so that rendering can be
|
||||
performed with an efficient algorithm.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
As a special case, you can use the gdk_pixbuf_new_from_xpm_data()
|
||||
function to create a pixbuf from inline XPM image data.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
You can also copy an existing pixbuf with the gdk_pixbuf_copy()
|
||||
function. This is not the same as just doing a g_object_ref()
|
||||
on the old pixbuf; the copy function will actually duplicate the
|
||||
pixel data in memory and create a new #GdkPixbuf structure for it.
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION See_Also ##### -->
|
||||
<para>
|
||||
gdk_pixbuf_finalize().
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION Stability_Level ##### -->
|
||||
|
||||
|
||||
<!-- ##### SECTION Image ##### -->
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_new ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@colorspace:
|
||||
@has_alpha:
|
||||
@bits_per_sample:
|
||||
@width:
|
||||
@height:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_new_from_data ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@data:
|
||||
@colorspace:
|
||||
@has_alpha:
|
||||
@bits_per_sample:
|
||||
@width:
|
||||
@height:
|
||||
@rowstride:
|
||||
@destroy_fn:
|
||||
@destroy_fn_data:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_new_from_xpm_data ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@data:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_new_from_inline ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@data_length:
|
||||
@data:
|
||||
@copy_pixels:
|
||||
@error:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_new_subpixbuf ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@src_pixbuf:
|
||||
@src_x:
|
||||
@src_y:
|
||||
@width:
|
||||
@height:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_copy ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pixbuf:
|
||||
@Returns: <!--
|
||||
Local variables:
|
||||
mode: sgml
|
||||
sgml-parent-document: ("../gdk-pixbuf.sgml" "book" "refsect2" "")
|
||||
End:
|
||||
-->
|
||||
|
||||
|
||||
@@ -1,109 +0,0 @@
|
||||
<!-- ##### SECTION Title ##### -->
|
||||
File Loading
|
||||
|
||||
<!-- ##### SECTION Short_Description ##### -->
|
||||
Loading a pixbuf from a file.
|
||||
|
||||
<!-- ##### SECTION Long_Description ##### -->
|
||||
<para>
|
||||
The &gdk-pixbuf; library provides a simple mechanism for loading
|
||||
an image from a file in synchronous fashion. This means that the
|
||||
library takes control of the application while the file is being
|
||||
loaded; from the user's point of view, the application will block
|
||||
until the image is done loading.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
This interface can be used by applications in which blocking is
|
||||
acceptable while an image is being loaded. It can also be used to
|
||||
load small images in general. Applications that need progressive
|
||||
loading can use the #GdkPixbufLoader functionality instead.
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION See_Also ##### -->
|
||||
<para>
|
||||
#GdkPixbufLoader.
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION Stability_Level ##### -->
|
||||
|
||||
|
||||
<!-- ##### SECTION Image ##### -->
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_new_from_file ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@filename:
|
||||
@error:
|
||||
@Returns: <!--
|
||||
Local variables:
|
||||
mode: sgml
|
||||
sgml-parent-document: ("../gdk-pixbuf.sgml" "book" "refsect2" "")
|
||||
End:
|
||||
-->
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_new_from_file_at_size ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@filename:
|
||||
@width:
|
||||
@height:
|
||||
@error:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_new_from_file_at_scale ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@filename:
|
||||
@width:
|
||||
@height:
|
||||
@preserve_aspect_ratio:
|
||||
@error:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_get_file_info ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@filename:
|
||||
@width:
|
||||
@height:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_new_from_stream ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@stream:
|
||||
@cancellable:
|
||||
@error:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_new_from_stream_at_scale ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@stream:
|
||||
@width:
|
||||
@height:
|
||||
@preserve_aspect_ratio:
|
||||
@cancellable:
|
||||
@error:
|
||||
@Returns:
|
||||
|
||||
|
||||
@@ -1,143 +0,0 @@
|
||||
<!-- ##### SECTION Title ##### -->
|
||||
File saving
|
||||
|
||||
<!-- ##### SECTION Short_Description ##### -->
|
||||
Saving a pixbuf to a file.
|
||||
|
||||
<!-- ##### SECTION Long_Description ##### -->
|
||||
<para>
|
||||
These functions allow to save a #GdkPixbuf in a number of
|
||||
file formats. The formatted data can be written to a file
|
||||
or to a memory buffer. &gdk-pixbuf; can also call a user-defined
|
||||
callback on the data, which allows to e.g. write the image
|
||||
to a socket or store it in a database.
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION See_Also ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION Stability_Level ##### -->
|
||||
|
||||
|
||||
<!-- ##### SECTION Image ##### -->
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_savev ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pixbuf:
|
||||
@filename:
|
||||
@type:
|
||||
@option_keys:
|
||||
@option_values:
|
||||
@error:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_save ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pixbuf:
|
||||
@filename:
|
||||
@type:
|
||||
@error:
|
||||
@Varargs:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### USER_FUNCTION GdkPixbufSaveFunc ##### -->
|
||||
<para>
|
||||
Specifies the type of the function passed to
|
||||
gdk_pixbuf_save_to_callback(). It is called once for each block of
|
||||
bytes that is "written" by gdk_pixbuf_save_to_callback(). If
|
||||
successful it should return %TRUE. If an error occurs it should set
|
||||
@error and return %FALSE, in which case gdk_pixbuf_save_to_callback()
|
||||
will fail with the same error.
|
||||
</para>
|
||||
|
||||
@buf: bytes to be written.
|
||||
@count: number of bytes in @buf.
|
||||
@error: A location to return an error.
|
||||
@data: user data passed to gdk_pixbuf_save_to_callback().
|
||||
@Returns: %TRUE if successful, %FALSE (with @error set) if failed.
|
||||
@Since: 2.4
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_save_to_callback ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pixbuf:
|
||||
@save_func:
|
||||
@user_data:
|
||||
@type:
|
||||
@error:
|
||||
@Varargs:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_save_to_callbackv ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pixbuf:
|
||||
@save_func:
|
||||
@user_data:
|
||||
@type:
|
||||
@option_keys:
|
||||
@option_values:
|
||||
@error:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_save_to_buffer ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pixbuf:
|
||||
@buffer:
|
||||
@buffer_size:
|
||||
@type:
|
||||
@error:
|
||||
@Varargs:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_save_to_bufferv ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pixbuf:
|
||||
@buffer:
|
||||
@buffer_size:
|
||||
@type:
|
||||
@option_keys:
|
||||
@option_values:
|
||||
@error:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_save_to_stream ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pixbuf:
|
||||
@stream:
|
||||
@type:
|
||||
@cancellable:
|
||||
@error:
|
||||
@Varargs:
|
||||
@Returns:
|
||||
|
||||
|
||||
@@ -1,209 +0,0 @@
|
||||
<!-- ##### SECTION Title ##### -->
|
||||
GdkPixbufLoader
|
||||
|
||||
<!-- ##### SECTION Short_Description ##### -->
|
||||
Application-driven progressive image loading.
|
||||
|
||||
<!-- ##### SECTION Long_Description ##### -->
|
||||
<para>
|
||||
#GdkPixbufLoader provides a way for applications to drive the
|
||||
process of loading an image, by letting them send the image data
|
||||
directly to the loader instead of having the loader read the data
|
||||
from a file. Applications can use this functionality instead of
|
||||
gdk_pixbuf_new_from_file() or gdk_pixbuf_animation_new_from_file()
|
||||
when they need to parse image data in
|
||||
small chunks. For example, it should be used when reading an
|
||||
image from a (potentially) slow network connection, or when
|
||||
loading an extremely large file.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
To use #GdkPixbufLoader to load an image, just create a new one,
|
||||
and call gdk_pixbuf_loader_write() to send the data to it. When
|
||||
done, gdk_pixbuf_loader_close() should be called to end the stream
|
||||
and finalize everything. The loader will emit three important
|
||||
signals throughout the process. The first, "<link
|
||||
linkend="GdkPixbufLoader-size-prepared">size_prepared</link>",
|
||||
will be called as soon as the image has enough information to
|
||||
determine the size of the image to be used. If you want to scale
|
||||
the image while loading it, you can call gdk_pixbuf_loader_set_size()
|
||||
in response to this signal.
|
||||
</para>
|
||||
|
||||
<para>The second signal, "<link
|
||||
linkend="GdkPixbufLoader-area-prepared">area_prepared</link>",
|
||||
will be called as soon as the pixbuf of the desired has been
|
||||
allocated. You can obtain it by calling gdk_pixbuf_loader_get_pixbuf().
|
||||
If you want to use it, simply ref it.
|
||||
In addition, no actual information will be passed in yet, so the
|
||||
pixbuf can be safely filled with any temporary graphics (or an
|
||||
initial color) as needed. You can also call
|
||||
gdk_pixbuf_loader_get_pixbuf() later and get the same pixbuf.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
The last signal, "<link
|
||||
linkend="GdkPixbufLoader-area-updated">area_updated</link>" gets
|
||||
called every time a region is updated. This way you can update a
|
||||
partially completed image. Note that you do not know anything
|
||||
about the completeness of an image from the area updated. For
|
||||
example, in an interlaced image, you need to make several passes
|
||||
before the image is done loading.
|
||||
</para>
|
||||
|
||||
<refsect2>
|
||||
<title>Loading an animation</title>
|
||||
|
||||
<para>
|
||||
Loading an animation is almost as easy as loading an
|
||||
image. Once the first "<link
|
||||
linkend="GdkPixbufLoader-area-prepared">area_prepared</link>" signal
|
||||
has been emitted, you can call gdk_pixbuf_loader_get_animation()
|
||||
to get the #GdkPixbufAnimation struct and gdk_pixbuf_animation_get_iter()
|
||||
to get an #GdkPixbufAnimationIter for displaying it.
|
||||
</para>
|
||||
</refsect2>
|
||||
|
||||
<!-- ##### SECTION See_Also ##### -->
|
||||
<para>
|
||||
gdk_pixbuf_new_from_file(), gdk_pixbuf_animation_new_from_file()
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION Stability_Level ##### -->
|
||||
|
||||
|
||||
<!-- ##### SECTION Image ##### -->
|
||||
|
||||
|
||||
<!-- ##### STRUCT GdkPixbufLoader ##### -->
|
||||
<para>
|
||||
The <structname>GdkPixbufLoader</structname> struct contains only private
|
||||
fields.
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### SIGNAL GdkPixbufLoader::area-prepared ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@gdkpixbufloader:
|
||||
|
||||
<!-- ##### SIGNAL GdkPixbufLoader::area-updated ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@gdkpixbufloader:
|
||||
@arg1:
|
||||
@arg2:
|
||||
@arg3:
|
||||
@arg4:
|
||||
|
||||
<!-- ##### SIGNAL GdkPixbufLoader::closed ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@gdkpixbufloader:
|
||||
|
||||
<!-- ##### SIGNAL GdkPixbufLoader::size-prepared ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@gdkpixbufloader:
|
||||
@arg1:
|
||||
@arg2:
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_loader_new ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@void:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_loader_new_with_type ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@image_type:
|
||||
@error:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_loader_new_with_mime_type ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@mime_type:
|
||||
@error:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_loader_get_format ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@loader:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_loader_write ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@loader:
|
||||
@buf:
|
||||
@count:
|
||||
@error:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_loader_set_size ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@loader:
|
||||
@width:
|
||||
@height:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_loader_get_pixbuf ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@loader:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_loader_get_animation ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@loader:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_loader_close ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@loader:
|
||||
@error:
|
||||
@Returns:
|
||||
|
||||
<!--
|
||||
Local variables:
|
||||
mode: sgml
|
||||
sgml-parent-document: ("../gdk-pixbuf.sgml" "book" "refsect2" "")
|
||||
End:
|
||||
-->
|
||||
|
||||
|
||||
@@ -1,585 +0,0 @@
|
||||
<!-- ##### SECTION ./tmpl/from-drawables.sgml:Long_Description ##### -->
|
||||
<para>
|
||||
The functions in this section allow you to take the image data
|
||||
from a GDK drawable and dump it into a #GdkPixbuf. This can be
|
||||
used for screenshots and other special effects. Note that these
|
||||
operations can be expensive, since the image data has to be
|
||||
transferred from the X server to the client program and converted.
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### SECTION ./tmpl/from-drawables.sgml:Short_Description ##### -->
|
||||
Getting parts of a drawable's image data into a pixbuf.
|
||||
|
||||
|
||||
<!-- ##### SECTION ./tmpl/from-drawables.sgml:Title ##### -->
|
||||
Drawables to Pixbufs
|
||||
|
||||
|
||||
<!-- ##### SECTION ./tmpl/gnome-canvas-pixbuf.sgml:Long_Description ##### -->
|
||||
<para>
|
||||
This canvas item displays #GdkPixbuf images. It handles full
|
||||
affine transformations in both GDK and antialiased modes, and also
|
||||
supports the <ulink url="http://www.w3.org">W3C</ulink>'s <ulink
|
||||
url="http://www.w3.org/Graphics/SVG/">SVG</ulink>-like scaling and
|
||||
translation semantics for absolute pixel values.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
#GdkPixbuf structures may be shared among different pixbuf canvas
|
||||
items; the pixbuf item uses #GdkPixbuf's reference counting
|
||||
functions for this.
|
||||
</para>
|
||||
|
||||
<refsect2>
|
||||
<title>Custom Scaling and Translation</title>
|
||||
|
||||
<para>
|
||||
In addition to the normal affine transformations supported by
|
||||
canvas items, the #GnomeCanvasPixbuf item supports independent
|
||||
object arguments for scaling and translation. This is useful
|
||||
for explicitly setting a size to which the pixbuf's image will
|
||||
be scaled, and for specifying translation offsets that take
|
||||
place in the item's local coordinate system.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
By default, the pixbuf canvas item will attain the size in units
|
||||
of the #GdkPixbuf it contains. If a #GnomeCanvasPixbuf is
|
||||
configured to use a #GdkPixbuf that has a size of 300 by 200
|
||||
pixels, then the pixbuf item will automatically obtain a size of
|
||||
300 by 200 units in the item's local coordinate system. If the
|
||||
item is transformed with a scaling transformation of (0.5, 2.0),
|
||||
then the final image size will be of 150 by 400 pixels.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
To set custom width and height values, you must set the <link
|
||||
linkend="GnomeCanvasPixbuf--width-set">width_set</link> or <link
|
||||
linkend="GnomeCanvasPixbuf--height-set">height_set</link>
|
||||
arguments to %TRUE, and then set the <link
|
||||
linkend="GnomeCanvasPixbuf--width">width</link> or <link
|
||||
linkend="GnomeCanvasPixbuf--height">height</link> arguments to
|
||||
the desired values. The former two arguments control whether
|
||||
the latter two are used when computing the final image's size;
|
||||
they are both %FALSE by default so that the pixbuf item will
|
||||
attain a size in units equal to the size in pixels of the
|
||||
#GdkPixbuf that the item contains.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
The custom translation offsets are controlled by the <link
|
||||
linkend="GnomeCanvasPixbuf--x">x</link> and <link
|
||||
linkend="GnomeCanvasPixbuf--y">y</link> arguments. The logical
|
||||
upper-left vertex of the image will be translated by the
|
||||
specified distance, aligned with the item's local coordinate
|
||||
system.
|
||||
</para>
|
||||
</refsect2>
|
||||
|
||||
<refsect2>
|
||||
<title>Absolute Pixel Scaling and Translation</title>
|
||||
|
||||
<para>
|
||||
The <ulink url="http://www.w3.org/Graphics/SVG/">Scalable Vector
|
||||
Graphics</ulink> specification (SVG) of the <ulink
|
||||
url="http://www.w3.org">World Wide Web Consortium</ulink> also
|
||||
allows images to be translated and scaled by absolute pixel
|
||||
values that are independent of an item's normal affine
|
||||
transformation.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
Normally, the pixbuf item's translation and scaling arguments
|
||||
are interpreted in units, so they will be modified by the item's
|
||||
affine transformation. The <link
|
||||
linkend="GnomeCanvasPixbuf--width-in-pixels">width_in_pixels</link>,
|
||||
<link
|
||||
linkend="GnomeCanvasPixbuf--height-in-pixels">height_in_pixels</link>,
|
||||
<link
|
||||
linkend="GnomeCanvasPixbuf--x-in-pixels">x_in_pixels</link>, and
|
||||
<link
|
||||
linkend="GnomeCanvasPixbuf--y-in-pixels">y_in_pixels</link>
|
||||
object arguments can be used to modify this behavior. If one of
|
||||
these arguments is %TRUE, then the corresponding scaling or
|
||||
translation value will not be affected lengthwise by the pixbuf
|
||||
item's affine transformation.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
For example, consider a pixbuf item whose size is (300, 200).
|
||||
If the item is modified with a scaling transformation of (0.5,
|
||||
2.0) but the <link
|
||||
linkend="GnomeCanvasPixbuf--width-in-pixels">width_in_pixels</link>
|
||||
is set to %TRUE, then the item will appear to be (300, 400)
|
||||
pixels in size. This means that in this case the item's affine
|
||||
transformation only applies to the height value, while the width
|
||||
value is kept in absolute pixels.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
Likewise, consider a pixbuf item whose (<link
|
||||
linkend="GnomeCanvasPixbuf--x">x</link>, <link
|
||||
linkend="GnomeCanvasPixbuf--y">y</link>) arguments are set to
|
||||
(30, 40). If the item is then modified by the same scaling
|
||||
transformation of (0.5, 2.0) but the <link
|
||||
linkend="GnomeCanvasPixbuf--y-in-pixels">y_in_pixels</link>
|
||||
argument is set to %TRUE, then the image's upper-left corner
|
||||
will appear to be at position (15, 40). In this case, the
|
||||
affine transformation is applied only to the x offset, while the
|
||||
y offset is kept in absolute pixels.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
In short, these arguments control whether a particular dimension
|
||||
of a pixbuf item is scaled or not in the normal way by the
|
||||
item's affine transformation.
|
||||
</para>
|
||||
</refsect2>
|
||||
|
||||
<refsect2>
|
||||
<title>Resource Management</title>
|
||||
|
||||
<para>
|
||||
When you set the #GdkPixbuf structure that a #GnomeCanvasPixbuf
|
||||
item will use by setting the <link
|
||||
linkend="GnomeCanvasPixbuf--pixbuf">pixbuf</link> argument, a
|
||||
reference count will be added to that #GdkPixbuf structure.
|
||||
When the pixbuf item no longer needs the #GdkPixbuf structure,
|
||||
such as when the item is destroyed or when a new pixbuf
|
||||
structure is passed to it, then the old #GdkPixbuf structure
|
||||
will be automatically unreferenced.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
This means that if an application just needs to load a pixbuf
|
||||
image and set it into a pixbuf canvas item, it can do the
|
||||
following to ‘forget’ about the pixbuf structure:
|
||||
|
||||
<programlisting>
|
||||
GdkPixbuf *pixbuf;
|
||||
GnomeCanvasItem *item;
|
||||
|
||||
pixbuf = gdk_pixbuf_new_from_file ("foo.png");
|
||||
g_assert (pixbuf != NULL);
|
||||
|
||||
item = gnome_canvas_item_new (gnome_canvas_root (my_canvas),
|
||||
gnome_canvas_pixbuf_get_type (),
|
||||
"pixbuf", pixbuf,
|
||||
NULL);
|
||||
gdk_pixbuf_unref (pixbuf);
|
||||
</programlisting>
|
||||
</para>
|
||||
|
||||
<para>
|
||||
After this happens, the reference count of the pixbuf structure
|
||||
will be 1: the gdk_pixbuf_new_from_file() function creates it
|
||||
with a reference count of 1, then setting the <link
|
||||
linkend="GnomeCanvasPixbuf--pixbuf">pixbuf</link> argument of
|
||||
the #GnomeCanvasPixbuf item increases it to 2, and then it is
|
||||
decremented to 1 by the call to gdk_pixbuf_unref(). When the
|
||||
canvas item is destroyed, it will automatically unreference the
|
||||
pixbuf structure again, causing its reference count to drop to
|
||||
zero and thus be freed.
|
||||
</para>
|
||||
</refsect2>
|
||||
|
||||
|
||||
<!-- ##### SECTION ./tmpl/gnome-canvas-pixbuf.sgml:See_Also ##### -->
|
||||
<para>
|
||||
#GnomeCanvas, #GdkPixbuf
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### SECTION ./tmpl/gnome-canvas-pixbuf.sgml:Short_Description ##### -->
|
||||
Canvas item to display #GdkPixbuf images.
|
||||
|
||||
|
||||
<!-- ##### SECTION ./tmpl/gnome-canvas-pixbuf.sgml:Title ##### -->
|
||||
GnomeCanvasPixbuf
|
||||
|
||||
|
||||
<!-- ##### SECTION ./tmpl/rendering.sgml:Long_Description ##### -->
|
||||
<para>
|
||||
The &gdk-pixbuf; library provides several convenience functions to
|
||||
render pixbufs to GDK drawables. It uses the GdkRGB to render the
|
||||
image data.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
At this point there is not a standard alpha channel extension for
|
||||
the X Window System, so it is not possible to use full opacity
|
||||
information when painting images to arbitrary drawables. The
|
||||
&gdk-pixbuf; convenience functions will threshold the opacity
|
||||
information to create a bi-level clipping mask (black and white),
|
||||
and use that to draw the image onto a drawable.
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### SECTION ./tmpl/rendering.sgml:See_Also ##### -->
|
||||
<para>
|
||||
GdkRGB
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### SECTION ./tmpl/rendering.sgml:Short_Description ##### -->
|
||||
Rendering a pixbuf to a GDK drawable.
|
||||
|
||||
|
||||
<!-- ##### SECTION ./tmpl/rendering.sgml:Title ##### -->
|
||||
Rendering
|
||||
|
||||
|
||||
<!-- ##### SECTION ./tmpl/xlib-from-drawables.sgml:Long_Description ##### -->
|
||||
<para>
|
||||
The functions in this section allow you to take the image data
|
||||
from an X drawable and dump it into a #GdkPixbuf. This can be
|
||||
used for screenshots and other special effects. Note that these
|
||||
operations can be expensive, since the image data has to be
|
||||
transferred from the X server to the client program and converted.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
These functions are analogous to those for the Gdk version of
|
||||
&gdk-pixbuf;.
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### SECTION ./tmpl/xlib-from-drawables.sgml:See_Also ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### SECTION ./tmpl/xlib-from-drawables.sgml:Short_Description ##### -->
|
||||
Getting parts of an X drawable's image data into a pixbuf.
|
||||
|
||||
|
||||
<!-- ##### SECTION ./tmpl/xlib-from-drawables.sgml:Title ##### -->
|
||||
X Drawables to Pixbufs
|
||||
|
||||
|
||||
<!-- ##### SECTION ./tmpl/xlib-init.sgml:Long_Description ##### -->
|
||||
<para>
|
||||
In addition to the normal Gdk-specific functions, the &gdk-pixbuf;
|
||||
package provides a small library that lets Xlib-only applications
|
||||
use #GdkPixbuf structures and render them to X drawables. The
|
||||
functions in this section are used to initialize the &gdk-pixbuf;
|
||||
Xlib library. This library must be initialized near the beginning
|
||||
or the program or before calling any of the other &gdk-pixbuf;
|
||||
Xlib functions; it cannot be initialized automatically since
|
||||
Xlib-only applications do not call gdk_rgb_init() like GNOME
|
||||
applications do.
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### SECTION ./tmpl/xlib-init.sgml:See_Also ##### -->
|
||||
<para>
|
||||
XlibRGB
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### SECTION ./tmpl/xlib-init.sgml:Short_Description ##### -->
|
||||
Initializing the &gdk-pixbuf; Xlib library.
|
||||
|
||||
|
||||
<!-- ##### SECTION ./tmpl/xlib-init.sgml:Title ##### -->
|
||||
&gdk-pixbuf; Xlib initialization
|
||||
|
||||
|
||||
<!-- ##### SECTION ./tmpl/xlib-rendering.sgml:Long_Description ##### -->
|
||||
<para>
|
||||
The &gdk-pixbuf; Xlib library provides several convenience
|
||||
functions to render pixbufs to X drawables. It uses XlibRGB to
|
||||
render the image data.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
These functions are analogous to those for the Gdk version of
|
||||
&gdk-pixbuf;.
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### SECTION ./tmpl/xlib-rendering.sgml:See_Also ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### SECTION ./tmpl/xlib-rendering.sgml:Short_Description ##### -->
|
||||
Rendering a pixbuf to an X drawable.
|
||||
|
||||
|
||||
<!-- ##### SECTION ./tmpl/xlib-rendering.sgml:Title ##### -->
|
||||
Xlib Rendering
|
||||
|
||||
|
||||
<!-- ##### SECTION ./tmpl/xlib-rgb.sgml:Long_Description ##### -->
|
||||
<para>
|
||||
The XlibRGB set of functions is a port of the GdkRGB library to
|
||||
use plain Xlib and X drawables. You can use these functions to
|
||||
render RGB buffers into drawables very quickly with high-quality
|
||||
dithering.
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### SECTION ./tmpl/xlib-rgb.sgml:See_Also ##### -->
|
||||
<para>
|
||||
GdkRGB
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### SECTION ./tmpl/xlib-rgb.sgml:Short_Description ##### -->
|
||||
Functions for rendering RGB buffers to X drawables.
|
||||
|
||||
|
||||
<!-- ##### SECTION ./tmpl/xlib-rgb.sgml:Title ##### -->
|
||||
XlibRGB
|
||||
|
||||
|
||||
<!-- ##### MACRO GDK_PIXBUF_LOADER ##### -->
|
||||
<para>
|
||||
Casts a #GtkObject to a #GdkPixbufLoader.
|
||||
</para>
|
||||
|
||||
@obj: A GTK+ object.
|
||||
|
||||
<!-- ##### MACRO GNOME_CANVAS_PIXBUF ##### -->
|
||||
<para>
|
||||
Casts a #GtkOjbect to a #GnomeCanvasPixbuf.
|
||||
</para>
|
||||
|
||||
@obj: A GTK+ object.
|
||||
|
||||
<!-- ##### STRUCT GdkPixbufFrame ##### -->
|
||||
<para>
|
||||
This object describes an individual frame of an animation.
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### ENUM GdkPixbufFrameAction ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@GDK_PIXBUF_FRAME_RETAIN:
|
||||
@GDK_PIXBUF_FRAME_DISPOSE:
|
||||
@GDK_PIXBUF_FRAME_REVERT:
|
||||
|
||||
<!-- ##### USER_FUNCTION GdkPixbufLastUnref ##### -->
|
||||
<para>
|
||||
A function of this type can be used to override the default
|
||||
operation when a pixbuf loses its last reference, i.e. when
|
||||
gdk_pixbuf_unref() is called on a #GdkPixbuf structure that has a
|
||||
reference count of 1. This function should determine whether to
|
||||
finalize the pixbuf by calling gdk_pixbuf_finalize(), or whether
|
||||
to just resume normal execution. The last unref handler for a
|
||||
#GdkPixbuf can be set using the
|
||||
gdk_pixbuf_set_last_unref_handler() function. By default, pixbufs
|
||||
will be finalized automatically if no last unref handler has been
|
||||
defined.
|
||||
</para>
|
||||
|
||||
@pixbuf: The pixbuf that is losing its last reference.
|
||||
@data: User closure data.
|
||||
|
||||
<!-- ##### ARG GnomeCanvasPixbuf:height ##### -->
|
||||
<para>
|
||||
Indicates the height the pixbuf will be scaled to. This argument
|
||||
will only be used if the <link
|
||||
linkend="GnomeCanvasPixbuf--height-set">height_set</link> argument
|
||||
is %TRUE. Works in the same way as the <link
|
||||
linkend="GnomeCanvasPixbuf--width">width</link> argument.
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### ARG GnomeCanvasPixbuf:height-in-pixels ##### -->
|
||||
<para>
|
||||
Works in the same way as the <link
|
||||
linkend="GnomeCanvasPixbuf--width-in-pixels">width_in_pixels</link>
|
||||
argument. The default is %FALSE.
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### ARG GnomeCanvasPixbuf:height-pixels ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### ARG GnomeCanvasPixbuf:height-set ##### -->
|
||||
<para>
|
||||
Determines whether the <link
|
||||
linkend="GnomeCanvasPixbuf--height">height</link> argument is
|
||||
taken into account when scaling the pixbuf item. Works in the
|
||||
same way as the <link
|
||||
linkend="GnomeCanvasPixbuf--width-set">width_set</link> argument.
|
||||
The default is %FALSE.
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### ARG GnomeCanvasPixbuf:pixbuf ##### -->
|
||||
<para>
|
||||
Contains a pointer to a #GdkPixbuf structure that will be used by
|
||||
the pixbuf canvas item as an image source. When a pixbuf is set
|
||||
its reference count is incremented; if the pixbuf item kept a
|
||||
pointer to another #GdkPixbuf structure, the reference count of
|
||||
this structure will be decremented. Also, the GdkPixbuf's
|
||||
reference count will automatically be decremented when the
|
||||
#GnomeCanvasPixbuf item is destroyed. When a pixbuf is queried, a
|
||||
reference count will not be added to the return value; you must do
|
||||
this yourself if you intend to keep the pixbuf structure around.
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### ARG GnomeCanvasPixbuf:width ##### -->
|
||||
<para>
|
||||
Indicates the width the pixbuf will be scaled to. This argument
|
||||
will only be used if the <link
|
||||
linkend="GnomeCanvasPixbuf--width-set">width_set</link> argument
|
||||
is %TRUE. If the <link
|
||||
linkend="GnomeCanvasPixbuf--width-in-pixels">width_in_pixels</link>
|
||||
argument is %FALSE, the width will be taken to be in canvas units,
|
||||
and thus will be scaled along with the canvas item's affine
|
||||
transformation. If width_in_pixels is %TRUE, the width will be
|
||||
taken to be in pixels, and will visually remain a constant size
|
||||
even if the item's affine transformation changes.
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### ARG GnomeCanvasPixbuf:width-in-pixels ##### -->
|
||||
<para>
|
||||
If this argument is %TRUE, then the width of the pixbuf will be
|
||||
considered to be in pixels, that is, it will not be visually
|
||||
scaled even if the item's affine transformation changes. If this
|
||||
is %FALSE, then the width of the pixbuf will be considered to be
|
||||
in canvas units, and so will be scaled normally by affine
|
||||
transformations. The default is %FALSE.
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### ARG GnomeCanvasPixbuf:width-pixels ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### ARG GnomeCanvasPixbuf:width-set ##### -->
|
||||
<para>
|
||||
Determines whether the <link
|
||||
linkend="GnomeCanvasPixbuf--width">width</link> argument is taken
|
||||
into account when scaling the pixbuf item. If this argument is
|
||||
%FALSE, then the width value of the pixbuf will be used instead.
|
||||
This argument is %FALSE by default.
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### ARG GnomeCanvasPixbuf:x ##### -->
|
||||
<para>
|
||||
Indicates the horizontal translation offset of the pixbuf item's
|
||||
image. This offset may not actually appear horizontal, since it
|
||||
will be affected by the item's affine transformation. The default
|
||||
is 0.0.
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### ARG GnomeCanvasPixbuf:x-in-pixels ##### -->
|
||||
<para>
|
||||
If this argument is %TRUE, the pixbuf's translation with respect
|
||||
to its logical origin in item-relative coordinates will be in
|
||||
pixels, that is, the visible offset will not change even if the
|
||||
item's affine transformation changes. If it is %FALSE, the
|
||||
pixbuf's translation will be taken to be in canvas units, and thus
|
||||
will change along with the item's affine transformation. The
|
||||
default is %FALSE.
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### ARG GnomeCanvasPixbuf:x-pixels ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### ARG GnomeCanvasPixbuf:x-set ##### -->
|
||||
<para>
|
||||
Determines whether the <link
|
||||
linkend="GnomeCanvasPixbuf--x">x</link> argument is used to
|
||||
translate the pixbuf from its logical origin in item-relative
|
||||
coordinates.
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### ARG GnomeCanvasPixbuf:y ##### -->
|
||||
<para>
|
||||
Indicates the vertical translation offset of the pixbuf item's
|
||||
image. Works in the same way as the <link
|
||||
linkend="GnomeCanvasPixbuf--x">x</link> argument. The default is
|
||||
0.0.
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### ARG GnomeCanvasPixbuf:y-in-pixels ##### -->
|
||||
<para>
|
||||
Works in the same way as the <link
|
||||
linkend="GnomeCanvasPixbuf--x-in-pixels">x_in_pixels</link>
|
||||
argument, but controls whether the <link
|
||||
linkend="GnomeCanvasPixbuf--y">y</link> translation offset is
|
||||
scaled or not. The default is %FALSE.
|
||||
</para>
|
||||
|
||||
<!--
|
||||
Local variables:
|
||||
mode: sgml
|
||||
sgml-parent-document: ("../gdk-pixbuf.sgml" "book" "refsect2" "")
|
||||
End:
|
||||
-->
|
||||
|
||||
|
||||
<!-- ##### ARG GnomeCanvasPixbuf:y-pixels ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### ARG GnomeCanvasPixbuf:y-set ##### -->
|
||||
<para>
|
||||
Determines whether the <link
|
||||
linkend="GnomeCanvasPixbuf--y">y</link> argument is used to
|
||||
translate the pixbuf from its logical origin in item-relative
|
||||
coordinates. Works in the same way as the <link
|
||||
linkend="GnomeCanvasPixbuf--x-set">x_set</link> argument. The
|
||||
default is %FALSE.
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_animation_ref ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@animation:
|
||||
@Returns:
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_animation_unref ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@animation:
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_ref ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pixbuf:
|
||||
@Returns:
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_unref ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pixbuf:
|
||||
|
||||
@@ -1,54 +0,0 @@
|
||||
<!-- ##### SECTION Title ##### -->
|
||||
X Drawables to Pixbufs
|
||||
|
||||
<!-- ##### SECTION Short_Description ##### -->
|
||||
Getting parts of an X drawable's image data into a pixbuf.
|
||||
|
||||
<!-- ##### SECTION Long_Description ##### -->
|
||||
<para>
|
||||
The functions in this section allow you to take the image data
|
||||
from an X drawable and dump it into a #GdkPixbuf. This can be
|
||||
used for screenshots and other special effects. Note that these
|
||||
operations can be expensive, since the image data has to be
|
||||
transferred from the X server to the client program and converted.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
These functions are analogous to those for the GDK version of
|
||||
&gdk-pixbuf;.
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION See_Also ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION Stability_Level ##### -->
|
||||
|
||||
|
||||
<!-- ##### SECTION Image ##### -->
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_xlib_get_from_drawable ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@dest:
|
||||
@src:
|
||||
@cmap:
|
||||
@visual:
|
||||
@src_x:
|
||||
@src_y:
|
||||
@dest_x:
|
||||
@dest_y:
|
||||
@width:
|
||||
@height:
|
||||
@Returns: <!--
|
||||
Local variables:
|
||||
mode: sgml
|
||||
sgml-parent-document: ("../gdk-pixbuf.sgml" "book" "refsect2" "")
|
||||
End:
|
||||
-->
|
||||
|
||||
|
||||
@@ -1,52 +0,0 @@
|
||||
<!-- ##### SECTION Title ##### -->
|
||||
&gdk-pixbuf; Xlib initialization
|
||||
|
||||
<!-- ##### SECTION Short_Description ##### -->
|
||||
Initializing the &gdk-pixbuf; Xlib library.
|
||||
|
||||
<!-- ##### SECTION Long_Description ##### -->
|
||||
<para>
|
||||
In addition to the normal Gdk-specific functions, the &gdk-pixbuf;
|
||||
package provides a small library that lets Xlib-only applications
|
||||
use #GdkPixbuf structures and render them to X drawables. The
|
||||
functions in this section are used to initialize the &gdk-pixbuf;
|
||||
Xlib library. This library must be initialized near the beginning
|
||||
of the program or before calling any of the other &gdk-pixbuf;
|
||||
Xlib functions.
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION See_Also ##### -->
|
||||
<para>
|
||||
XlibRGB
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION Stability_Level ##### -->
|
||||
|
||||
|
||||
<!-- ##### SECTION Image ##### -->
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_xlib_init ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@display:
|
||||
@screen_num:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_xlib_init_with_depth ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@display:
|
||||
@screen_num:
|
||||
@prefDepth: <!--
|
||||
Local variables:
|
||||
mode: sgml
|
||||
sgml-parent-document: ("../gdk-pixbuf.sgml" "book" "refsect2" "")
|
||||
End:
|
||||
-->
|
||||
|
||||
|
||||
@@ -1,100 +0,0 @@
|
||||
<!-- ##### SECTION Title ##### -->
|
||||
Xlib Rendering
|
||||
|
||||
<!-- ##### SECTION Short_Description ##### -->
|
||||
Rendering a pixbuf to an X drawable.
|
||||
|
||||
<!-- ##### SECTION Long_Description ##### -->
|
||||
<para>
|
||||
The &gdk-pixbuf; Xlib library provides several convenience
|
||||
functions to render pixbufs to X drawables. It uses XlibRGB to
|
||||
render the image data.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
These functions are analogous to those for the GDK version of
|
||||
&gdk-pixbuf;.
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION See_Also ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION Stability_Level ##### -->
|
||||
|
||||
|
||||
<!-- ##### SECTION Image ##### -->
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_xlib_render_threshold_alpha ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pixbuf:
|
||||
@bitmap:
|
||||
@src_x:
|
||||
@src_y:
|
||||
@dest_x:
|
||||
@dest_y:
|
||||
@width:
|
||||
@height:
|
||||
@alpha_threshold:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_xlib_render_to_drawable ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pixbuf:
|
||||
@drawable:
|
||||
@gc:
|
||||
@src_x:
|
||||
@src_y:
|
||||
@dest_x:
|
||||
@dest_y:
|
||||
@width:
|
||||
@height:
|
||||
@dither:
|
||||
@x_dither:
|
||||
@y_dither:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_xlib_render_to_drawable_alpha ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pixbuf:
|
||||
@drawable:
|
||||
@src_x:
|
||||
@src_y:
|
||||
@dest_x:
|
||||
@dest_y:
|
||||
@width:
|
||||
@height:
|
||||
@alpha_mode:
|
||||
@alpha_threshold:
|
||||
@dither:
|
||||
@x_dither:
|
||||
@y_dither:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_xlib_render_pixmap_and_mask ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pixbuf:
|
||||
@pixmap_return:
|
||||
@mask_return:
|
||||
@alpha_threshold: <!--
|
||||
Local variables:
|
||||
Kode: sgml
|
||||
sgml-parent-document: ("../gdk-pixbuf.sgml" "book" "refsect2" "")
|
||||
End:
|
||||
-->
|
||||
|
||||
|
||||
@@ -1,290 +0,0 @@
|
||||
<!-- ##### SECTION Title ##### -->
|
||||
XlibRGB
|
||||
|
||||
<!-- ##### SECTION Short_Description ##### -->
|
||||
Rendering RGB buffers to X drawables.
|
||||
|
||||
<!-- ##### SECTION Long_Description ##### -->
|
||||
<para>
|
||||
The XlibRGB set of functions is a port of the #GdkRGB library to
|
||||
use plain Xlib and X drawables. You can use these functions to
|
||||
render RGB buffers into drawables very quickly with high-quality
|
||||
dithering.
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION See_Also ##### -->
|
||||
<para>
|
||||
GdkRGB
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION Stability_Level ##### -->
|
||||
|
||||
|
||||
<!-- ##### SECTION Image ##### -->
|
||||
|
||||
|
||||
<!-- ##### STRUCT XlibRgbCmap ##### -->
|
||||
<para>
|
||||
FIXME: Describe this.
|
||||
</para>
|
||||
|
||||
@colors: FIXME.
|
||||
@lut: FIXME.
|
||||
|
||||
<!-- ##### ENUM XlibRgbDither ##### -->
|
||||
<para>
|
||||
These values are used to specify which dithering method should be
|
||||
used. <symbol>XLIB_RGB_DITHER_NONE</symbol> will use no dithering
|
||||
and simply map the colors in an RGB buffer to the closest colors
|
||||
that the display can provide.
|
||||
<symbol>XLIB_RGB_DITHER_NORMAL</symbol> will provide dithering
|
||||
only on pseudocolor displays.
|
||||
<symbol>XLIB_RGB_DITHER_MAX</symbol> will provide dithering on
|
||||
pseudocolor and 16-bit truecolor or “high color”
|
||||
displays.
|
||||
</para>
|
||||
|
||||
@XLIB_RGB_DITHER_NONE: Specifies no dithering.
|
||||
@XLIB_RGB_DITHER_NORMAL: Specifies dithering only on pseudocolor
|
||||
displays.
|
||||
@XLIB_RGB_DITHER_MAX: Specifies dithering on high color displays.
|
||||
|
||||
<!-- ##### FUNCTION xlib_rgb_init ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@display:
|
||||
@screen:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION xlib_rgb_init_with_depth ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@display:
|
||||
@screen:
|
||||
@prefDepth:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION xlib_rgb_xpixel_from_rgb ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@rgb:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION xlib_rgb_gc_set_foreground ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@gc:
|
||||
@rgb:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION xlib_rgb_gc_set_background ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@gc:
|
||||
@rgb:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION xlib_draw_rgb_image ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@drawable:
|
||||
@gc:
|
||||
@x:
|
||||
@y:
|
||||
@width:
|
||||
@height:
|
||||
@dith:
|
||||
@rgb_buf:
|
||||
@rowstride:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION xlib_draw_rgb_image_dithalign ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@drawable:
|
||||
@gc:
|
||||
@x:
|
||||
@y:
|
||||
@width:
|
||||
@height:
|
||||
@dith:
|
||||
@rgb_buf:
|
||||
@rowstride:
|
||||
@xdith:
|
||||
@ydith:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION xlib_draw_rgb_32_image ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@drawable:
|
||||
@gc:
|
||||
@x:
|
||||
@y:
|
||||
@width:
|
||||
@height:
|
||||
@dith:
|
||||
@buf:
|
||||
@rowstride:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION xlib_draw_gray_image ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@drawable:
|
||||
@gc:
|
||||
@x:
|
||||
@y:
|
||||
@width:
|
||||
@height:
|
||||
@dith:
|
||||
@buf:
|
||||
@rowstride:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION xlib_rgb_cmap_new ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@colors:
|
||||
@n_colors:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION xlib_rgb_cmap_free ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@cmap:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION xlib_draw_indexed_image ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@drawable:
|
||||
@gc:
|
||||
@x:
|
||||
@y:
|
||||
@width:
|
||||
@height:
|
||||
@dith:
|
||||
@buf:
|
||||
@rowstride:
|
||||
@cmap:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION xlib_rgb_ditherable ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@void:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION xlib_rgb_set_verbose ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@verbose:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION xlib_rgb_set_install ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@install:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION xlib_rgb_set_min_colors ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@min_colors:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION xlib_rgb_get_cmap ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@void:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION xlib_rgb_get_visual ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@void:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION xlib_rgb_get_visual_info ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@void:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION xlib_rgb_get_depth ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@void:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION xlib_rgb_get_display ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@void:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION xlib_rgb_get_screen ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@void:
|
||||
@Returns: <!--
|
||||
Local variables:
|
||||
mode: sgml
|
||||
sgml-parent-document: ("../gdk-pixbuf.sgml" "book" "refsect2" "")
|
||||
End:
|
||||
-->
|
||||
|
||||
|
||||
@@ -1,292 +0,0 @@
|
||||
<!-- ##### SECTION Title ##### -->
|
||||
The GdkPixbuf Structure
|
||||
|
||||
<!-- ##### SECTION Short_Description ##### -->
|
||||
Information that describes an image.
|
||||
|
||||
<!-- ##### SECTION Long_Description ##### -->
|
||||
|
||||
<para>
|
||||
The <structname>GdkPixbuf</structname> structure contains
|
||||
information that describes an image in memory.
|
||||
</para>
|
||||
|
||||
<section id="image-data">
|
||||
<title>Image Data</title>
|
||||
|
||||
<para>
|
||||
Image data in a pixbuf is stored in memory in uncompressed,
|
||||
packed format. Rows in the image are stored top to bottom, and
|
||||
in each row pixels are stored from left to right. There may be
|
||||
padding at the end of a row. The "rowstride" value of a pixbuf,
|
||||
as returned by gdk_pixbuf_get_rowstride(), indicates the number
|
||||
of bytes between rows.
|
||||
</para>
|
||||
|
||||
<example id="put-pixel">
|
||||
<title>put_pixel(<!-- -->) example</title>
|
||||
|
||||
<para>
|
||||
The following code illustrates a simple put_pixel(<!-- -->)
|
||||
function for RGB pixbufs with 8 bits per channel with an alpha
|
||||
channel. It is not included in the gdk-pixbuf library for
|
||||
performance reasons; rather than making several function calls
|
||||
for each pixel, your own code can take shortcuts.
|
||||
</para>
|
||||
|
||||
<programlisting>
|
||||
static void
|
||||
put_pixel (GdkPixbuf *pixbuf, int x, int y, guchar red, guchar green, guchar blue, guchar alpha)
|
||||
{
|
||||
int width, height, rowstride, n_channels;
|
||||
guchar *pixels, *p;
|
||||
|
||||
n_channels = gdk_pixbuf_get_n_channels (pixbuf);
|
||||
|
||||
g_assert (gdk_pixbuf_get_colorspace (pixbuf) == GDK_COLORSPACE_RGB);
|
||||
g_assert (gdk_pixbuf_get_bits_per_sample (pixbuf) == 8);
|
||||
g_assert (gdk_pixbuf_get_has_alpha (pixbuf));
|
||||
g_assert (n_channels == 4);
|
||||
|
||||
width = gdk_pixbuf_get_width (pixbuf);
|
||||
height = gdk_pixbuf_get_height (pixbuf);
|
||||
|
||||
g_assert (x >= 0 && x < width);
|
||||
g_assert (y >= 0 && y < height);
|
||||
|
||||
rowstride = gdk_pixbuf_get_rowstride (pixbuf);
|
||||
pixels = gdk_pixbuf_get_pixels (pixbuf);
|
||||
|
||||
p = pixels + y * rowstride + x * n_channels;
|
||||
p[0] = red;
|
||||
p[1] = green;
|
||||
p[2] = blue;
|
||||
p[3] = alpha;
|
||||
}
|
||||
</programlisting>
|
||||
|
||||
<para>
|
||||
This function will not work for pixbufs with images that are
|
||||
other than 8 bits per sample or channel, but it will work for
|
||||
most of the pixbufs that GTK+ uses.
|
||||
</para>
|
||||
</example>
|
||||
|
||||
<note>
|
||||
<para>
|
||||
If you are doing memcpy() of raw pixbuf data, note that the
|
||||
last row in the pixbuf may not be as wide as the full
|
||||
rowstride, but rather just as wide as the pixel data needs to
|
||||
be. That is, it is unsafe to do <literal>memcpy (dest,
|
||||
pixels, rowstride * height)</literal> to copy a whole pixbuf.
|
||||
Use gdk_pixbuf_copy() instead, or compute the width in bytes
|
||||
of the last row as <literal>width * ((n_channels *
|
||||
bits_per_sample + 7) / 8)</literal>.
|
||||
</para>
|
||||
</note>
|
||||
</section>
|
||||
|
||||
<!-- ##### SECTION See_Also ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION Stability_Level ##### -->
|
||||
|
||||
|
||||
<!-- ##### SECTION Image ##### -->
|
||||
|
||||
|
||||
<!-- ##### ENUM GdkPixbufError ##### -->
|
||||
<para>
|
||||
An error code in the #GDK_PIXBUF_ERROR domain. Many &gdk-pixbuf;
|
||||
operations can cause errors in this domain, or in the #G_FILE_ERROR
|
||||
domain.
|
||||
</para>
|
||||
|
||||
@GDK_PIXBUF_ERROR_CORRUPT_IMAGE: An image file was broken somehow.
|
||||
@GDK_PIXBUF_ERROR_INSUFFICIENT_MEMORY: Not enough memory.
|
||||
@GDK_PIXBUF_ERROR_BAD_OPTION: A bad option was passed to a pixbuf save module.
|
||||
@GDK_PIXBUF_ERROR_UNKNOWN_TYPE: Unknown image type.
|
||||
@GDK_PIXBUF_ERROR_UNSUPPORTED_OPERATION: Don't know how to perform the
|
||||
given operation on the type of image at hand.
|
||||
@GDK_PIXBUF_ERROR_FAILED: Generic failure code, something went wrong.
|
||||
|
||||
<!-- ##### MACRO GDK_PIXBUF_ERROR ##### -->
|
||||
<para>
|
||||
Error domain used for pixbuf operations. Indicates that the error code
|
||||
will be in the #GdkPixbufError enumeration. See #GError for
|
||||
information on error domains and error codes.
|
||||
</para>
|
||||
|
||||
|
||||
|
||||
<!-- ##### ENUM GdkColorspace ##### -->
|
||||
<para>
|
||||
This enumeration defines the color spaces that are supported by
|
||||
the &gdk-pixbuf; library. Currently only RGB is supported.
|
||||
</para>
|
||||
|
||||
@GDK_COLORSPACE_RGB: Indicates a red/green/blue additive color space.
|
||||
|
||||
<!-- ##### ENUM GdkPixbufAlphaMode ##### -->
|
||||
<para>
|
||||
This function can create a
|
||||
bilevel clipping mask (black and white) and use it while painting
|
||||
the image. In the future, when the X Window System gets an alpha
|
||||
channel extension, it will be possible to do full alpha
|
||||
compositing onto arbitrary drawables. For now both cases fall
|
||||
back to a bilevel clipping mask.
|
||||
</para>
|
||||
|
||||
@GDK_PIXBUF_ALPHA_BILEVEL: A bilevel clipping mask (black and white)
|
||||
will be created and used to draw the image. Pixels below 0.5 opacity
|
||||
will be considered fully transparent, and all others will be
|
||||
considered fully opaque.
|
||||
@GDK_PIXBUF_ALPHA_FULL: For now falls back to #GDK_PIXBUF_ALPHA_BILEVEL.
|
||||
In the future it will do full alpha compositing.
|
||||
|
||||
<!-- ##### STRUCT GdkPixbuf ##### -->
|
||||
<para>
|
||||
This is the main structure in the &gdk-pixbuf; library. It is
|
||||
used to represent images. It contains information about the
|
||||
image's pixel data, its color space, bits per sample, width and
|
||||
height, and the rowstride (the number of bytes between the start of
|
||||
one row and the start of the next).
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### ARG GdkPixbuf:bits-per-sample ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GdkPixbuf:colorspace ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GdkPixbuf:has-alpha ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GdkPixbuf:height ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GdkPixbuf:n-channels ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GdkPixbuf:pixels ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GdkPixbuf:rowstride ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GdkPixbuf:width ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_get_colorspace ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pixbuf:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_get_n_channels ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pixbuf:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_get_has_alpha ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pixbuf:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_get_bits_per_sample ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pixbuf:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_get_pixels ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pixbuf:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_get_width ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pixbuf:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_get_height ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pixbuf:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_get_rowstride ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pixbuf:
|
||||
@Returns: <!--
|
||||
Local variables:
|
||||
mode: sgml
|
||||
sgml-parent-document: ("../gdk-pixbuf.sgml" "book" "refsect2" "")
|
||||
End:
|
||||
-->
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_get_option ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pixbuf:
|
||||
@key:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!--
|
||||
Local variables:
|
||||
mode: sgml
|
||||
sgml-parent-document: ("../gdk-pixbuf.sgml" "book" "refsect2")
|
||||
End:
|
||||
-->
|
||||
|
||||
|
||||
@@ -1,106 +0,0 @@
|
||||
<!-- ##### SECTION Title ##### -->
|
||||
Initialization and Versions
|
||||
|
||||
<!-- ##### SECTION Short_Description ##### -->
|
||||
|
||||
Library version numbers.
|
||||
|
||||
<!-- ##### SECTION Long_Description ##### -->
|
||||
<para>
|
||||
These macros and variables let you check the version of &gdk-pixbuf;
|
||||
you're linking against.
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION See_Also ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION Stability_Level ##### -->
|
||||
|
||||
|
||||
<!-- ##### SECTION Image ##### -->
|
||||
|
||||
|
||||
<!-- ##### VARIABLE gdk_pixbuf_version ##### -->
|
||||
<para>
|
||||
Contains the full version of the &gdk-pixbuf; library as a string.
|
||||
This is the version currently in use by a running program.
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### VARIABLE gdk_pixbuf_major_version ##### -->
|
||||
<para>
|
||||
The major version number of the &gdk-pixbuf; library. (e.g. in
|
||||
&gdk-pixbuf; version 1.2.5 this is 1.)
|
||||
</para>
|
||||
|
||||
<para>
|
||||
This variable is in the library, so represents the
|
||||
&gdk-pixbuf; library you have linked against. Contrast with the
|
||||
#GDK_PIXBUF_MAJOR macro, which represents the major version of the
|
||||
&gdk-pixbuf; headers you have included.
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### VARIABLE gdk_pixbuf_minor_version ##### -->
|
||||
<para>
|
||||
The minor version number of the &gdk-pixbuf; library. (e.g. in
|
||||
&gdk-pixbuf; version 1.2.5 this is 2.)
|
||||
</para>
|
||||
|
||||
<para>
|
||||
This variable is in the library, so represents the
|
||||
&gdk-pixbuf; library you have linked against. Contrast with the
|
||||
#GDK_PIXBUF_MINOR macro, which represents the minor version of the
|
||||
&gdk-pixbuf; headers you have included.
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### VARIABLE gdk_pixbuf_micro_version ##### -->
|
||||
<para>
|
||||
The micro version number of the &gdk-pixbuf; library. (e.g. in
|
||||
&gdk-pixbuf; version 1.2.5 this is 5.)
|
||||
</para>
|
||||
|
||||
<para>
|
||||
This variable is in the library, so represents the
|
||||
&gdk-pixbuf; library you have linked against. Contrast with the
|
||||
#GDK_PIXBUF_MICRO macro, which represents the micro version of the
|
||||
&gdk-pixbuf; headers you have included.
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### MACRO GDK_PIXBUF_VERSION ##### -->
|
||||
<para>
|
||||
Contains the full version of the &gdk-pixbuf; header as a string.
|
||||
This is the version being compiled against; contrast with
|
||||
#gdk_pixbuf_version.
|
||||
</para>
|
||||
|
||||
|
||||
|
||||
<!-- ##### MACRO GDK_PIXBUF_MAJOR ##### -->
|
||||
<para>
|
||||
Major version of &gdk-pixbuf; library, that is the first "0" in
|
||||
"0.8.0" for example.
|
||||
</para>
|
||||
|
||||
|
||||
|
||||
<!-- ##### MACRO GDK_PIXBUF_MINOR ##### -->
|
||||
<para>
|
||||
Minor version of &gdk-pixbuf; library, that is the "8" in
|
||||
"0.8.0" for example.
|
||||
</para>
|
||||
|
||||
|
||||
|
||||
<!-- ##### MACRO GDK_PIXBUF_MICRO ##### -->
|
||||
<para>
|
||||
Micro version of &gdk-pixbuf; library, that is the last "0" in
|
||||
"0.8.0" for example.
|
||||
</para>
|
||||
|
||||
|
||||
|
||||
@@ -1,137 +0,0 @@
|
||||
<!-- ##### SECTION Title ##### -->
|
||||
Inline data
|
||||
|
||||
<!-- ##### SECTION Short_Description ##### -->
|
||||
Functions for inlined pixbuf handling.
|
||||
|
||||
<!-- ##### SECTION Long_Description ##### -->
|
||||
<para>
|
||||
Using #GdkPixdata, images can be compiled into an application,
|
||||
making it unnecessary to refer to external image files at runtime.
|
||||
&gdk-pixbuf; includes a utility named gdk-pixbuf-csource, which
|
||||
can be used to convert image files into #GdkPixdata structures suitable
|
||||
for inclusion in C sources. To convert the #GdkPixdata structures back
|
||||
into #GdkPixbuf<!-- -->s, use gdk_pixbuf_from_pixdata.
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION See_Also ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION Stability_Level ##### -->
|
||||
|
||||
|
||||
<!-- ##### SECTION Image ##### -->
|
||||
|
||||
|
||||
<!-- ##### STRUCT GdkPixdata ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@magic:
|
||||
@length:
|
||||
@pixdata_type:
|
||||
@rowstride:
|
||||
@width:
|
||||
@height:
|
||||
@pixel_data:
|
||||
|
||||
<!-- ##### ENUM GdkPixdataType ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@GDK_PIXDATA_COLOR_TYPE_RGB:
|
||||
@GDK_PIXDATA_COLOR_TYPE_RGBA:
|
||||
@GDK_PIXDATA_COLOR_TYPE_MASK:
|
||||
@GDK_PIXDATA_SAMPLE_WIDTH_8:
|
||||
@GDK_PIXDATA_SAMPLE_WIDTH_MASK:
|
||||
@GDK_PIXDATA_ENCODING_RAW:
|
||||
@GDK_PIXDATA_ENCODING_RLE:
|
||||
@GDK_PIXDATA_ENCODING_MASK:
|
||||
|
||||
<!-- ##### ENUM GdkPixdataDumpType ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@GDK_PIXDATA_DUMP_PIXDATA_STREAM:
|
||||
@GDK_PIXDATA_DUMP_PIXDATA_STRUCT:
|
||||
@GDK_PIXDATA_DUMP_MACROS:
|
||||
@GDK_PIXDATA_DUMP_GTYPES:
|
||||
@GDK_PIXDATA_DUMP_CTYPES:
|
||||
@GDK_PIXDATA_DUMP_STATIC:
|
||||
@GDK_PIXDATA_DUMP_CONST:
|
||||
@GDK_PIXDATA_DUMP_RLE_DECODER:
|
||||
|
||||
<!-- ##### MACRO GDK_PIXBUF_MAGIC_NUMBER ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
|
||||
|
||||
<!-- ##### MACRO GDK_PIXDATA_HEADER_LENGTH ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixdata_from_pixbuf ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pixdata:
|
||||
@pixbuf:
|
||||
@use_rle:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_from_pixdata ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pixdata:
|
||||
@copy_pixels:
|
||||
@error:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixdata_serialize ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pixdata:
|
||||
@stream_length_p:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixdata_deserialize ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pixdata:
|
||||
@stream_length:
|
||||
@stream:
|
||||
@error:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixdata_to_csource ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pixdata:
|
||||
@name:
|
||||
@dump_type:
|
||||
@Returns:
|
||||
|
||||
|
||||
@@ -1,382 +0,0 @@
|
||||
<!-- ##### SECTION Title ##### -->
|
||||
Module Interface
|
||||
|
||||
<!-- ##### SECTION Short_Description ##### -->
|
||||
Extending &gdk-pixbuf;
|
||||
|
||||
<!-- ##### SECTION Long_Description ##### -->
|
||||
<para>
|
||||
If &gdk-pixbuf; has been compiled with GModule support, it can be extended by
|
||||
modules which can load (and perhaps also save) new image and animation
|
||||
formats. Each loadable module must export a
|
||||
#GdkPixbufModuleFillInfoFunc function named <function>fill_info</function> and
|
||||
a #GdkPixbufModuleFillVtableFunc function named
|
||||
<function>fill_vtable</function>.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
In order to make format-checking work before actually loading the modules
|
||||
(which may require dlopening image libraries), modules export their
|
||||
signatures (and other information) via the <function>fill_info</function>
|
||||
function. An external utility, <command>gdk-pixbuf-query-loaders-3.0</command>,
|
||||
uses this to create a text file containing a list of all available loaders and
|
||||
their signatures. This file is then read at runtime by &gdk-pixbuf; to obtain
|
||||
the list of available loaders and their signatures.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
Modules may only implement a subset of the functionality available via
|
||||
#GdkPixbufModule. If a particular functionality is not implemented, the
|
||||
<function>fill_vtable</function> function will simply not set the corresponding
|
||||
function pointers of the #GdkPixbufModule structure. If a module supports
|
||||
incremental loading (i.e. provides #begin_load, #stop_load and
|
||||
#load_increment), it doesn't have to implement #load, since &gdk-pixbuf; can
|
||||
supply a generic #load implementation wrapping the incremental loading.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
Installing a module is a two-step process:
|
||||
<itemizedlist>
|
||||
<listitem><para>copy the module file(s) to the loader directory (normally
|
||||
<filename><replaceable>libdir</replaceable>/gtk-3.0/<replaceable>version</replaceable>/loaders</filename>,
|
||||
unless overridden by the environment variable
|
||||
<envar>GDK_PIXBUF_MODULEDIR</envar>)
|
||||
</para></listitem>
|
||||
<listitem><para>call <command>gdk-pixbuf-query-loaders-3.0</command> to update the
|
||||
module file (normally
|
||||
<filename><replaceable>libdir</replaceable>/gtk-3.0/<replaceable>version</replaceable>/loaders.cache</filename>,
|
||||
unless overridden by the environment variable
|
||||
<envar>GDK_PIXBUF_MODULE_FILE</envar>)
|
||||
</para></listitem>
|
||||
</itemizedlist>
|
||||
</para>
|
||||
|
||||
<para>
|
||||
The &gdk-pixbuf; interfaces needed for implementing modules are contained in
|
||||
<filename>gdk-pixbuf-io.h</filename> (and
|
||||
<filename>gdk-pixbuf-animation.h</filename> if the module supports animations).
|
||||
They are not covered by the same stability guarantees as the regular
|
||||
&gdk-pixbuf; API. To underline this fact, they are protected by
|
||||
<literal>#ifdef GDK_PIXBUF_ENABLE_BACKEND</literal>.
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION See_Also ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION Stability_Level ##### -->
|
||||
|
||||
|
||||
<!-- ##### SECTION Image ##### -->
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_set_option ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pixbuf:
|
||||
@key:
|
||||
@value:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_get_formats ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@void:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_format_get_name ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@format:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_format_get_description ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@format:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_format_get_mime_types ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@format:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_format_get_extensions ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@format:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_format_is_writable ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@format:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_format_is_scalable ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@format:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_format_is_disabled ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@format:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_format_set_disabled ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@format:
|
||||
@disabled:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_format_get_license ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@format:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### STRUCT GdkPixbufFormat ##### -->
|
||||
<para>
|
||||
A #GdkPixbufFormat contains information about the image format accepted by a
|
||||
module. Only modules should access the fields directly, applications should
|
||||
use the <function>gdk_pixbuf_format_*</function> functions.
|
||||
</para>
|
||||
|
||||
@name: the name of the image format.
|
||||
@signature: the signature of the module.
|
||||
@domain: the message domain for the @description.
|
||||
@description: a description of the image format.
|
||||
@mime_types: a %NULL-terminated array of MIME types for the image format.
|
||||
@extensions: a %NULL-terminated array of typical filename extensions for the
|
||||
image format.
|
||||
@flags: a combination of #GdkPixbufFormatFlags.
|
||||
@disabled: a boolean determining whether the loader is disabled.
|
||||
@license: a string containing license information, typically set to
|
||||
shorthands like "GPL", "LGPL", etc.
|
||||
@Since: 2.2
|
||||
|
||||
<!-- ##### ENUM GdkPixbufFormatFlags ##### -->
|
||||
<para>
|
||||
Flags which allow a module to specify further details about the supported
|
||||
operations.
|
||||
</para>
|
||||
|
||||
@GDK_PIXBUF_FORMAT_WRITABLE: the module can write out images in the format.
|
||||
@GDK_PIXBUF_FORMAT_SCALABLE: the image format is scalable
|
||||
@GDK_PIXBUF_FORMAT_THREADSAFE: the module is threadsafe. If this flag is not
|
||||
set, &gdk-pixbuf; will use a lock to prevent multiple threads from using
|
||||
this module at the same time. (Since 2.6)
|
||||
@Since: 2.2
|
||||
|
||||
<!-- ##### STRUCT GdkPixbufModulePattern ##### -->
|
||||
<para>
|
||||
The signature of a module is a set of prefixes. Prefixes are encoded as
|
||||
pairs of ordinary strings, where the second string, called the mask, if
|
||||
not %NULL, must be of the same length as the first one and may contain
|
||||
' ', '!', 'x', 'z', and 'n' to indicate bytes that must be matched,
|
||||
not matched, "don't-care"-bytes, zeros and non-zeros.
|
||||
Each prefix has an associated integer that describes the relevance of
|
||||
the prefix, with 0 meaning a mismatch and 100 a "perfect match".
|
||||
</para>
|
||||
<para>
|
||||
Starting with &gdk-pixbuf; 2.8, the first byte of the mask may be '*',
|
||||
indicating an unanchored pattern that matches not only at the beginning,
|
||||
but also in the middle. Versions prior to 2.8 will interpret the '*'
|
||||
like an 'x'.
|
||||
</para>
|
||||
<para>
|
||||
The signature of a module is stored as an array of
|
||||
#GdkPixbufModulePattern<!-- -->s. The array is terminated by a pattern
|
||||
where the @prefix is %NULL.
|
||||
</para>
|
||||
|
||||
<informalexample><programlisting>
|
||||
GdkPixbufModulePattern *signature[] = {
|
||||
{ "abcdx", " !x z", 100 },
|
||||
{ "bla", NULL, 90 },
|
||||
{ NULL, NULL, 0 }
|
||||
};
|
||||
</programlisting>
|
||||
The example matches e.g. "auud\0" with relevance 100, and "blau" with
|
||||
relevance 90.</informalexample>
|
||||
|
||||
@prefix: the prefix for this pattern
|
||||
@mask: mask containing bytes which modify how the prefix is matched against
|
||||
test data
|
||||
@relevance: relevance of this pattern
|
||||
@Since: 2.2
|
||||
|
||||
<!-- ##### USER_FUNCTION GdkPixbufModuleFillVtableFunc ##### -->
|
||||
<para>
|
||||
Defines the type of the function used to set the vtable of a
|
||||
#GdkPixbufModule when it is loaded.
|
||||
</para>
|
||||
|
||||
@module: a #GdkPixbufModule.
|
||||
@Since: 2.2
|
||||
|
||||
|
||||
<!-- ##### USER_FUNCTION GdkPixbufModuleFillInfoFunc ##### -->
|
||||
<para>
|
||||
Defines the type of the function used to fill a
|
||||
#GdkPixbufFormat structure with information about a module.
|
||||
</para>
|
||||
|
||||
@info: a #GdkPixbufFormat.
|
||||
@Since: 2.2
|
||||
|
||||
|
||||
<!-- ##### USER_FUNCTION GdkPixbufModuleSizeFunc ##### -->
|
||||
<para>
|
||||
Defines the type of the function that gets called once the size
|
||||
of the loaded image is known.
|
||||
</para>
|
||||
<para>
|
||||
The function is expected to set @width and @height to the desired
|
||||
size to which the image should be scaled. If a module has no efficient
|
||||
way to achieve the desired scaling during the loading of the image, it may
|
||||
either ignore the size request, or only approximate it -- &gdk-pixbuf; will
|
||||
then perform the required scaling on the completely loaded image.
|
||||
</para>
|
||||
<para>
|
||||
If the function sets @width or @height to zero, the module should interpret
|
||||
this as a hint that it will be closed soon and shouldn't allocate further
|
||||
resources. This convention is used to implement gdk_pixbuf_get_file_info()
|
||||
efficiently.
|
||||
</para>
|
||||
|
||||
@width: pointer to a location containing the current image width
|
||||
@height: pointer to a location containing the current image height
|
||||
@user_data: the loader.
|
||||
@Since: 2.2
|
||||
|
||||
|
||||
<!-- ##### USER_FUNCTION GdkPixbufModulePreparedFunc ##### -->
|
||||
<para>
|
||||
Defines the type of the function that gets called once the initial
|
||||
setup of @pixbuf is done.
|
||||
</para>
|
||||
<para>
|
||||
#GdkPixbufLoader uses a function of this type to emit the
|
||||
"<link linkend="GdkPixbufLoader-area-prepared">area_prepared</link>"
|
||||
signal.
|
||||
</para>
|
||||
|
||||
@pixbuf: the #GdkPixbuf that is currently being loaded.
|
||||
@anim: if an animation is being loaded, the #GdkPixbufAnimation, else %NULL.
|
||||
@user_data: the loader.
|
||||
@Since: 2.2
|
||||
|
||||
|
||||
<!-- ##### USER_FUNCTION GdkPixbufModuleUpdatedFunc ##### -->
|
||||
<para>
|
||||
Defines the type of the function that gets called every time a region
|
||||
of @pixbuf is updated.
|
||||
</para>
|
||||
<para>
|
||||
#GdkPixbufLoader uses a function of this type to emit the
|
||||
"<link linkend="GdkPixbufLoader-area-updated">area_updated</link>"
|
||||
signal.
|
||||
</para>
|
||||
|
||||
@pixbuf: the #GdkPixbuf that is currently being loaded.
|
||||
@x: the X origin of the updated area.
|
||||
@y: the Y origin of the updated area.
|
||||
@width: the width of the updated area.
|
||||
@height: the height of the updated area.
|
||||
@user_data: the loader.
|
||||
@Since: 2.2
|
||||
|
||||
|
||||
<!-- ##### STRUCT GdkPixbufModule ##### -->
|
||||
<para>
|
||||
A #GdkPixbufModule contains the necessary functions to load and save
|
||||
images in a certain file format.
|
||||
</para>
|
||||
<para>
|
||||
A #GdkPixbufModule can be loaded dynamically from a #GModule.
|
||||
Each loadable module must contain a #GdkPixbufModuleFillVtableFunc function
|
||||
named <function>fill_vtable</function>, which will get called when the module
|
||||
is loaded and must set the function pointers of the #GdkPixbufModule.
|
||||
</para>
|
||||
|
||||
@module_name: the name of the module, usually the same as the
|
||||
usual file extension for images of this type, eg. "xpm", "jpeg" or "png".
|
||||
@module_path: the path from which the module is loaded.
|
||||
@module: the loaded #GModule.
|
||||
@info: a #GdkPixbufFormat holding information about the module.
|
||||
@load: loads an image from a file.
|
||||
@load_xpm_data: loads an image from data in memory.
|
||||
@begin_load: begins an incremental load.
|
||||
@stop_load: stops an incremental load.
|
||||
@load_increment: continues an incremental load.
|
||||
@load_animation: loads an animation from a file.
|
||||
@save: saves a #GdkPixbuf to a file.
|
||||
@save_to_callback: saves a #GdkPixbuf by calling the given #GdkPixbufSaveFunc.
|
||||
|
||||
<!-- ##### STRUCT GdkPixbufAnimationClass ##### -->
|
||||
<para>
|
||||
Modules supporting animations must derive a type from
|
||||
#GdkPixbufAnimation, providing suitable implementations of the
|
||||
virtual functions.
|
||||
</para>
|
||||
|
||||
@parent_class: the parent class
|
||||
@is_static_image: returns whether the given animation is just a static image.
|
||||
@get_static_image: returns a static image representing the given animation.
|
||||
@get_size: fills @width and @height with the frame size of the animation.
|
||||
@get_iter: returns an iterator for the given animation.
|
||||
|
||||
<!-- ##### STRUCT GdkPixbufAnimationIterClass ##### -->
|
||||
<para>
|
||||
Modules supporting animations must derive a type from
|
||||
#GdkPixbufAnimationIter, providing suitable implementations of the
|
||||
virtual functions.
|
||||
</para>
|
||||
|
||||
@parent_class: the parent class
|
||||
@get_delay_time: returns the time in milliseconds that the current frame
|
||||
should be shown.
|
||||
@get_pixbuf: returns the current frame.
|
||||
@on_currently_loading_frame: returns whether the current frame of @iter is
|
||||
being loaded.
|
||||
@advance: advances the iterator to @current_time, possibly changing the
|
||||
current frame.
|
||||
|
||||
@@ -1,67 +0,0 @@
|
||||
<!-- ##### SECTION Title ##### -->
|
||||
Reference Counting and Memory Mangement
|
||||
|
||||
<!-- ##### SECTION Short_Description ##### -->
|
||||
|
||||
Functions for reference counting and memory management on pixbufs.
|
||||
|
||||
<!-- ##### SECTION Long_Description ##### -->
|
||||
<para>
|
||||
#GdkPixbuf structures are reference counted. This means that an
|
||||
application can share a single pixbuf among many parts of the
|
||||
code. When a piece of the program needs to keep a pointer to a
|
||||
pixbuf, it should add a reference to it by calling g_object_ref().
|
||||
When it no longer needs the pixbuf, it should subtract a reference
|
||||
by calling g_object_unref(). The pixbuf will be destroyed when
|
||||
its reference count drops to zero. Newly-created #GdkPixbuf
|
||||
structures start with a reference count of one.
|
||||
</para>
|
||||
|
||||
<note>
|
||||
<para>
|
||||
As #GdkPixbuf is derived from #GObject now, gdk_pixbuf_ref() and
|
||||
gdk_pixbuf_unref() are deprecated in favour of g_object_ref()
|
||||
and g_object_unref () resp.
|
||||
</para>
|
||||
</note>
|
||||
|
||||
<para>
|
||||
<emphasis>Finalizing</emphasis> a pixbuf means to free its pixel
|
||||
data and to free the #GdkPixbuf structure itself. Most of the
|
||||
library functions that create #GdkPixbuf structures create the
|
||||
pixel data by themselves and define the way it should be freed;
|
||||
you do not need to worry about those. The only function that lets
|
||||
you specify how to free the pixel data is
|
||||
gdk_pixbuf_new_from_data(). Since you pass it a pre-allocated
|
||||
pixel buffer, you must also specify a way to free that data. This
|
||||
is done with a function of type #GdkPixbufDestroyNotify. When a
|
||||
pixbuf created with gdk_pixbuf_new_from_data() is finalized, your
|
||||
destroy notification function will be called, and it is its
|
||||
responsibility to free the pixel array.
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION See_Also ##### -->
|
||||
<para>
|
||||
#GdkPixbuf, gdk_pixbuf_new_from_data().
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION Stability_Level ##### -->
|
||||
|
||||
|
||||
<!-- ##### SECTION Image ##### -->
|
||||
|
||||
|
||||
<!-- ##### USER_FUNCTION GdkPixbufDestroyNotify ##### -->
|
||||
<para>
|
||||
A function of this type is responsible for freeing the pixel array
|
||||
of a pixbuf. The gdk_pixbuf_new_from_data() function lets you
|
||||
pass in a pre-allocated pixel array so that a pixbuf can be
|
||||
created from it; in this case you will need to pass in a function
|
||||
of #GdkPixbufDestroyNotify so that the pixel data can be freed
|
||||
when the pixbuf is finalized.
|
||||
</para>
|
||||
|
||||
@pixels: The pixel array of the pixbuf that is being finalized.
|
||||
@data: User closure data.
|
||||
|
||||
|
||||
@@ -1,246 +0,0 @@
|
||||
<!-- ##### SECTION Title ##### -->
|
||||
Scaling
|
||||
|
||||
<!-- ##### SECTION Short_Description ##### -->
|
||||
Scaling pixbufs and scaling and compositing pixbufs
|
||||
|
||||
<!-- ##### SECTION Long_Description ##### -->
|
||||
<para>
|
||||
The &gdk-pixbuf; contains functions to scale pixbufs, to scale
|
||||
pixbufs and composite against an existing image, and to scale
|
||||
pixbufs and composite against a solid color or checkerboard.
|
||||
Compositing a checkerboard is a common way to show an image with
|
||||
an alpha channel in image-viewing and editing software.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
Since the full-featured functions (gdk_pixbuf_scale(),
|
||||
gdk_pixbuf_composite(), and gdk_pixbuf_composite_color()) are
|
||||
rather complex to use and have many arguments, two simple
|
||||
convenience functions are provided, gdk_pixbuf_scale_simple() and
|
||||
gdk_pixbuf_composite_color_simple() which create a new pixbuf of a
|
||||
given size, scale an original image to fit, and then return the
|
||||
new pixbuf.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
Scaling and compositing functions take advantage of MMX hardware
|
||||
acceleration on systems where MMX is supported. If gdk-pixbuf is built
|
||||
with the Sun mediaLib library, these functions are instead accelerated
|
||||
using mediaLib, which provides hardware acceleration on Intel, AMD,
|
||||
and Sparc chipsets. If desired, mediaLib support can be turned off by
|
||||
setting the GDK_DISABLE_MEDIALIB environment variable.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
The following example demonstrates handling an expose event by
|
||||
rendering the appropriate area of a source image (which is scaled
|
||||
to fit the widget) onto the widget's window. The source image is
|
||||
rendered against a checkerboard, which provides a visual
|
||||
representation of the alpha channel if the image has one. If the
|
||||
image doesn't have an alpha channel, calling
|
||||
gdk_pixbuf_composite_color() function has exactly the same effect
|
||||
as calling gdk_pixbuf_scale().
|
||||
</para>
|
||||
|
||||
<example>
|
||||
<title>Handling an expose event.</title>
|
||||
<programlisting>
|
||||
gboolean
|
||||
expose_cb (GtkWidget *widget, GdkEventExpose *event, gpointer data)
|
||||
{
|
||||
GdkPixbuf *dest;
|
||||
|
||||
dest = gdk_pixbuf_new (GDK_COLORSPACE_RGB, FALSE, 8, event->area.width, event->area.height);
|
||||
|
||||
gdk_pixbuf_composite_color (pixbuf, dest,
|
||||
0, 0, event->area.width, event->area.height,
|
||||
-event->area.x, -event->area.y,
|
||||
(double) widget->allocation.width / gdk_pixbuf_get_width (pixbuf),
|
||||
(double) widget->allocation.height / gdk_pixbuf_get_height (pixbuf),
|
||||
GDK_INTERP_BILINEAR, 255,
|
||||
event->area.x, event->area.y, 16, 0xaaaaaa, 0x555555);
|
||||
|
||||
gdk_draw_pixbuf (widget->window, widget->style->fg_gc[GTK_STATE_NORMAL], dest,
|
||||
0, 0, event->area.x, event->area.y,
|
||||
event->area.width, event->area.height,
|
||||
GDK_RGB_DITHER_NORMAL, event->area.x, event->area.y);
|
||||
|
||||
gdk_pixbuf_unref (dest);
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
</programlisting>
|
||||
</example>
|
||||
|
||||
<!-- ##### SECTION See_Also ##### -->
|
||||
<para>
|
||||
<link linkend="gdk-GdkRGB">GdkRGB</link>.
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION Stability_Level ##### -->
|
||||
|
||||
|
||||
<!-- ##### SECTION Image ##### -->
|
||||
|
||||
|
||||
<!-- ##### ENUM GdkInterpType ##### -->
|
||||
<para>
|
||||
This enumeration describes the different interpolation modes that
|
||||
can be used with the scaling functions. @GDK_INTERP_NEAREST is
|
||||
the fastest scaling method, but has horrible quality when
|
||||
scaling down. @GDK_INTERP_BILINEAR is the best choice if you
|
||||
aren't sure what to choose, it has a good speed/quality balance.
|
||||
|
||||
<note>
|
||||
<para>
|
||||
Cubic filtering is missing from the list; hyperbolic
|
||||
interpolation is just as fast and results in higher quality.
|
||||
</para>
|
||||
</note>
|
||||
</para>
|
||||
|
||||
@GDK_INTERP_NEAREST: Nearest neighbor sampling; this is the fastest
|
||||
and lowest quality mode. Quality is normally unacceptable when scaling
|
||||
down, but may be OK when scaling up.
|
||||
@GDK_INTERP_TILES: This is an accurate simulation of the PostScript
|
||||
image operator without any interpolation enabled. Each pixel is
|
||||
rendered as a tiny parallelogram of solid color, the edges of which
|
||||
are implemented with antialiasing. It resembles nearest neighbor for
|
||||
enlargement, and bilinear for reduction.
|
||||
@GDK_INTERP_BILINEAR: Best quality/speed balance; use this mode by
|
||||
default. Bilinear interpolation. For enlargement, it is
|
||||
equivalent to point-sampling the ideal bilinear-interpolated image.
|
||||
For reduction, it is equivalent to laying down small tiles and
|
||||
integrating over the coverage area.
|
||||
@GDK_INTERP_HYPER: This is the slowest and highest quality
|
||||
reconstruction function. It is derived from the hyperbolic filters in
|
||||
Wolberg's "Digital Image Warping", and is formally defined as the
|
||||
hyperbolic-filter sampling the ideal hyperbolic-filter interpolated
|
||||
image (the filter is designed to be idempotent for 1:1 pixel mapping).
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_scale_simple ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@src:
|
||||
@dest_width:
|
||||
@dest_height:
|
||||
@interp_type:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_scale ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@src:
|
||||
@dest:
|
||||
@dest_x:
|
||||
@dest_y:
|
||||
@dest_width:
|
||||
@dest_height:
|
||||
@offset_x:
|
||||
@offset_y:
|
||||
@scale_x:
|
||||
@scale_y:
|
||||
@interp_type:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_composite_color_simple ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@src:
|
||||
@dest_width:
|
||||
@dest_height:
|
||||
@interp_type:
|
||||
@overall_alpha:
|
||||
@check_size:
|
||||
@color1:
|
||||
@color2:
|
||||
@Returns: <!--
|
||||
Local variables:
|
||||
mode: sgml
|
||||
sgml-parent-document: ("../gdk-pixbuf.sgml" "book" "refsect2" "")
|
||||
End:
|
||||
-->
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_composite ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@src:
|
||||
@dest:
|
||||
@dest_x:
|
||||
@dest_y:
|
||||
@dest_width:
|
||||
@dest_height:
|
||||
@offset_x:
|
||||
@offset_y:
|
||||
@scale_x:
|
||||
@scale_y:
|
||||
@interp_type:
|
||||
@overall_alpha:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_composite_color ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@src:
|
||||
@dest:
|
||||
@dest_x:
|
||||
@dest_y:
|
||||
@dest_width:
|
||||
@dest_height:
|
||||
@offset_x:
|
||||
@offset_y:
|
||||
@scale_x:
|
||||
@scale_y:
|
||||
@interp_type:
|
||||
@overall_alpha:
|
||||
@check_x:
|
||||
@check_y:
|
||||
@check_size:
|
||||
@color1:
|
||||
@color2:
|
||||
|
||||
|
||||
<!-- ##### ENUM GdkPixbufRotation ##### -->
|
||||
<para>
|
||||
The possible rotations which can be passed to gdk_pixbuf_rotate_simple().
|
||||
To make them easier to use, their numerical values are the actual degrees.
|
||||
</para>
|
||||
|
||||
@GDK_PIXBUF_ROTATE_NONE: No rotation.
|
||||
@GDK_PIXBUF_ROTATE_COUNTERCLOCKWISE: Rotate by 90 degrees.
|
||||
@GDK_PIXBUF_ROTATE_UPSIDEDOWN: Rotate by 180 degrees.
|
||||
@GDK_PIXBUF_ROTATE_CLOCKWISE: Rotate by 270 degrees.
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_rotate_simple ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@src:
|
||||
@angle:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_flip ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@src:
|
||||
@horizontal:
|
||||
@Returns:
|
||||
|
||||
|
||||
@@ -1,87 +0,0 @@
|
||||
<!-- ##### SECTION Title ##### -->
|
||||
Utilities
|
||||
|
||||
<!-- ##### SECTION Short_Description ##### -->
|
||||
Utility and miscellaneous convenience functions.
|
||||
|
||||
<!-- ##### SECTION Long_Description ##### -->
|
||||
<para>
|
||||
These functions provide miscellaneous utilities for manipulating
|
||||
pixbufs. The pixel data in pixbufs may of course be manipulated
|
||||
directly by applications, but several common operations can be
|
||||
performed by these functions instead.
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION See_Also ##### -->
|
||||
<para>
|
||||
#GdkPixbuf
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION Stability_Level ##### -->
|
||||
|
||||
|
||||
<!-- ##### SECTION Image ##### -->
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_add_alpha ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pixbuf:
|
||||
@substitute_color:
|
||||
@r:
|
||||
@g:
|
||||
@b:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_copy_area ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@src_pixbuf:
|
||||
@src_x:
|
||||
@src_y:
|
||||
@width:
|
||||
@height:
|
||||
@dest_pixbuf:
|
||||
@dest_x:
|
||||
@dest_y: <!--
|
||||
Local variables:
|
||||
mode: sgml
|
||||
sgml-parent-document: ("../gdk-pixbuf.sgml" "book" "refsect2" "")
|
||||
End:
|
||||
-->
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_saturate_and_pixelate ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@src:
|
||||
@dest:
|
||||
@saturation:
|
||||
@pixelate:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_apply_embedded_orientation ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@src:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_pixbuf_fill ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pixbuf:
|
||||
@pixel:
|
||||
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
@GTK_VERSION@
|
||||
@@ -21,14 +21,12 @@ CFILE_GLOB=$(top_srcdir)/gdk/*.c
|
||||
|
||||
# Header files to ignore when scanning
|
||||
IGNORE_HFILES= \
|
||||
gdkalias.h \
|
||||
gdkintl.h \
|
||||
gdkmarshalers.h \
|
||||
gdkkeysyms.h \
|
||||
gdkinternals.h \
|
||||
gdkprivate.h \
|
||||
gdkpoly-generic.h \
|
||||
gdkregion-generic.h \
|
||||
keyname-table.h \
|
||||
win32 \
|
||||
directfb \
|
||||
@@ -142,7 +140,7 @@ HTML_IMAGES = \
|
||||
images/xterm.png
|
||||
|
||||
# Extra options to supply to gtkdoc-fixref
|
||||
FIXXREF_OPTIONS=--extra-dir=../gdk-pixbuf/html \
|
||||
FIXXREF_OPTIONS= \
|
||||
--extra-dir=$(GLIB_PREFIX)/share/gtk-doc/html/gobject \
|
||||
--extra-dir=$(GLIB_PREFIX)/share/gtk-doc/html/glib \
|
||||
--extra-dir=$(CAIRO_PREFIX)/share/gtk-doc/html/cairo
|
||||
|
||||
@@ -74,14 +74,12 @@ gdk_extension_mode_get_type
|
||||
gdk_fill_get_type
|
||||
gdk_fill_rule_get_type
|
||||
gdk_filter_return_get_type
|
||||
gdk_font_type_get_type
|
||||
gdk_function_get_type
|
||||
gdk_gc_values_mask_get_type
|
||||
gdk_grab_ownership_get_type
|
||||
gdk_grab_status_get_type
|
||||
gdk_gravity_get_type
|
||||
gdk_image_type_get_type
|
||||
gdk_input_condition_get_type
|
||||
gdk_input_mode_get_type
|
||||
gdk_input_source_get_type
|
||||
gdk_join_style_get_type
|
||||
@@ -296,6 +294,7 @@ gdk_image_get_height
|
||||
gdk_image_get_image_type
|
||||
gdk_image_get_visual
|
||||
gdk_image_get_width
|
||||
gdk_image_get_pixels
|
||||
|
||||
<SUBSECTION>
|
||||
gdk_image_put_pixel
|
||||
@@ -394,60 +393,10 @@ gdk_colormap_get_type
|
||||
gdk_color_get_type
|
||||
</SECTION>
|
||||
|
||||
<SECTION>
|
||||
<TITLE>Fonts</TITLE>
|
||||
<FILE>fonts</FILE>
|
||||
GdkFont
|
||||
GdkFontType
|
||||
gdk_font_load
|
||||
gdk_font_load_for_display
|
||||
gdk_fontset_load
|
||||
gdk_fontset_load_for_display
|
||||
gdk_font_from_description
|
||||
gdk_font_from_description_for_display
|
||||
gdk_font_get_display
|
||||
gdk_font_ref
|
||||
gdk_font_unref
|
||||
gdk_font_id
|
||||
gdk_font_equal
|
||||
|
||||
<SUBSECTION>
|
||||
gdk_string_extents
|
||||
gdk_text_extents
|
||||
gdk_text_extents_wc
|
||||
gdk_string_width
|
||||
gdk_text_width
|
||||
gdk_text_width_wc
|
||||
gdk_char_width
|
||||
gdk_char_width_wc
|
||||
gdk_string_measure
|
||||
gdk_text_measure
|
||||
gdk_char_measure
|
||||
gdk_string_height
|
||||
gdk_text_height
|
||||
gdk_char_height
|
||||
|
||||
<SUBSECTION>
|
||||
GdkWChar
|
||||
gdk_wcstombs
|
||||
gdk_mbstowcs
|
||||
|
||||
<SUBSECTION Standard>
|
||||
GDK_TYPE_FONT
|
||||
GDK_TYPE_FONT_TYPE
|
||||
|
||||
<SUBSECTION Private>
|
||||
gdk_font_get_type
|
||||
</SECTION>
|
||||
|
||||
<SECTION>
|
||||
<TITLE>Drawing Primitives</TITLE>
|
||||
<FILE>drawing</FILE>
|
||||
GdkDrawable
|
||||
gdk_drawable_ref
|
||||
gdk_drawable_unref
|
||||
gdk_drawable_set_data
|
||||
gdk_drawable_get_data
|
||||
gdk_drawable_get_display
|
||||
gdk_drawable_get_screen
|
||||
gdk_drawable_get_visual
|
||||
@@ -477,13 +426,8 @@ gdk_draw_layout_line
|
||||
gdk_draw_layout_line_with_colors
|
||||
gdk_draw_layout
|
||||
gdk_draw_layout_with_colors
|
||||
<SUBSECTION>
|
||||
gdk_draw_string
|
||||
gdk_draw_text
|
||||
gdk_draw_text_wc
|
||||
|
||||
<SUBSECTION>
|
||||
gdk_draw_pixmap
|
||||
gdk_draw_drawable
|
||||
gdk_draw_image
|
||||
gdk_drawable_get_image
|
||||
@@ -499,7 +443,6 @@ GDK_IS_DRAWABLE_CLASS
|
||||
|
||||
<SUBSECTION Private>
|
||||
GdkDrawableClass
|
||||
gdk_draw_bitmap
|
||||
</SECTION>
|
||||
|
||||
<SECTION>
|
||||
@@ -652,6 +595,7 @@ gdk_window_move_resize
|
||||
gdk_window_scroll
|
||||
gdk_window_move_region
|
||||
gdk_window_flush
|
||||
gdk_window_has_native
|
||||
gdk_window_ensure_native
|
||||
gdk_window_reparent
|
||||
gdk_window_clear
|
||||
@@ -782,7 +726,6 @@ gdk_window_get_effective_toplevel
|
||||
<SUBSECTION Standard>
|
||||
GDK_WINDOW
|
||||
GDK_WINDOW_GET_CLASS
|
||||
GDK_WINDOW_OBJECT
|
||||
GDK_TYPE_WINDOW
|
||||
GDK_IS_WINDOW
|
||||
GDK_WINDOW_CLASS
|
||||
@@ -927,43 +870,6 @@ GdkRectangle
|
||||
gdk_rectangle_intersect
|
||||
gdk_rectangle_union
|
||||
|
||||
<SUBSECTION>
|
||||
GdkRegion
|
||||
gdk_region_new
|
||||
gdk_region_polygon
|
||||
GdkFillRule
|
||||
gdk_region_copy
|
||||
gdk_region_rectangle
|
||||
gdk_region_destroy
|
||||
|
||||
<SUBSECTION>
|
||||
gdk_region_get_clipbox
|
||||
gdk_region_get_rectangles
|
||||
gdk_region_empty
|
||||
gdk_region_equal
|
||||
gdk_region_rect_equal
|
||||
gdk_region_point_in
|
||||
gdk_region_rect_in
|
||||
GdkOverlapType
|
||||
|
||||
<SUBSECTION>
|
||||
gdk_region_offset
|
||||
gdk_region_shrink
|
||||
gdk_region_union_with_rect
|
||||
gdk_region_intersect
|
||||
gdk_region_union
|
||||
gdk_region_subtract
|
||||
gdk_region_xor
|
||||
|
||||
<SUBSECTION>
|
||||
GdkSpan
|
||||
GdkSpanFunc
|
||||
gdk_region_spans_intersect_foreach
|
||||
|
||||
<SUBSECTION Standard>
|
||||
GDK_TYPE_OVERLAP_TYPE
|
||||
GDK_TYPE_RECTANGLE
|
||||
|
||||
<SUBSECTION Private>
|
||||
gdk_rectangle_get_type
|
||||
</SECTION>
|
||||
@@ -1004,6 +910,7 @@ gdk_keymap_get_entries_for_keycode
|
||||
gdk_keymap_get_direction
|
||||
gdk_keymap_have_bidi_layouts
|
||||
gdk_keymap_get_caps_lock_state
|
||||
gdk_keymap_get_num_lock_state
|
||||
gdk_keymap_add_virtual_modifiers
|
||||
gdk_keymap_map_virtual_modifiers
|
||||
|
||||
@@ -1050,6 +957,7 @@ GdkGrabOwnership
|
||||
gdk_enable_multidevice
|
||||
gdk_device_manager_get_display
|
||||
gdk_device_manager_list_devices
|
||||
gdk_device_manager_get_client_pointer
|
||||
|
||||
<SUBSECTION>
|
||||
gdk_device_get_name
|
||||
@@ -1250,18 +1158,6 @@ GDK_TYPE_CURSOR
|
||||
gdk_cursor_get_type
|
||||
</SECTION>
|
||||
|
||||
<SECTION>
|
||||
<TITLE>Input</TITLE>
|
||||
<FILE>input</FILE>
|
||||
gdk_input_add_full
|
||||
GdkInputCondition
|
||||
GdkInputFunction
|
||||
gdk_input_add
|
||||
gdk_input_remove
|
||||
|
||||
<SUBSECTION Standard>
|
||||
GDK_TYPE_INPUT_CONDITION
|
||||
</SECTION>
|
||||
|
||||
<SECTION>
|
||||
<TITLE>Drag and Drop</TITLE>
|
||||
@@ -1273,6 +1169,7 @@ gdk_drag_context_new
|
||||
gdk_drag_drop
|
||||
gdk_drag_find_window
|
||||
gdk_drag_find_window_for_screen
|
||||
gdk_drag_context_get_source_window
|
||||
gdk_drag_begin
|
||||
gdk_drag_motion
|
||||
gdk_drop_finish
|
||||
@@ -1283,9 +1180,9 @@ GdkDragContext
|
||||
GdkDragAction
|
||||
gdk_drag_status
|
||||
gdk_drag_drop_succeeded
|
||||
gdk_drag_context_get_action
|
||||
gdk_drag_context_get_actions
|
||||
gdk_drag_context_get_suggested_action
|
||||
gdk_drag_context_get_selected_action
|
||||
gdk_drag_context_list_targets
|
||||
gdk_drag_context_get_device
|
||||
gdk_drag_context_set_device
|
||||
@@ -1327,8 +1224,6 @@ GDK_SCREEN_XDISPLAY
|
||||
GDK_SCREEN_XNUMBER
|
||||
GDK_SCREEN_XSCREEN
|
||||
GDK_VISUAL_XVISUAL
|
||||
GDK_FONT_XDISPLAY
|
||||
GDK_FONT_XFONT
|
||||
GDK_CURSOR_XCURSOR
|
||||
GDK_CURSOR_XDISPLAY
|
||||
GDK_GC_XGC
|
||||
@@ -1346,8 +1241,6 @@ gdk_window_lookup
|
||||
gdk_window_lookup_for_display
|
||||
gdk_pixmap_lookup
|
||||
gdk_pixmap_lookup_for_display
|
||||
gdk_font_lookup
|
||||
gdk_font_lookup_for_display
|
||||
gdk_x11_lookup_xdisplay
|
||||
gdk_x11_get_server_time
|
||||
gdk_net_wm_supports
|
||||
@@ -1372,9 +1265,6 @@ gdk_x11_display_set_cursor_theme
|
||||
gdk_x11_register_standard_event_type
|
||||
gdk_x11_drawable_get_xdisplay
|
||||
gdk_x11_drawable_get_xid
|
||||
gdk_x11_font_get_name
|
||||
gdk_x11_font_get_xdisplay
|
||||
gdk_x11_font_get_xfont
|
||||
gdk_x11_gc_get_xdisplay
|
||||
gdk_x11_gc_get_xgc
|
||||
gdk_x11_get_default_root_xwindow
|
||||
|
||||
1
docs/reference/gdk/tmpl/.gitignore
vendored
1
docs/reference/gdk/tmpl/.gitignore
vendored
@@ -1 +1,2 @@
|
||||
dnd.sgml
|
||||
windows.sgml
|
||||
|
||||
@@ -1,261 +0,0 @@
|
||||
<!-- ##### SECTION Title ##### -->
|
||||
Drag and Drop
|
||||
|
||||
<!-- ##### SECTION Short_Description ##### -->
|
||||
Functions for controlling drag and drop handling
|
||||
|
||||
<!-- ##### SECTION Long_Description ##### -->
|
||||
<para>
|
||||
These functions provide a low level interface for drag and drop.
|
||||
The X backend of GDK supports both the Xdnd and Motif drag and drop protocols
|
||||
transparently, the Win32 backend supports the WM_DROPFILES protocol.
|
||||
</para>
|
||||
<para>
|
||||
GTK+ provides a higher level abstraction based on top of these functions,
|
||||
and so they are not normally needed in GTK+ applications.
|
||||
See the <link linkend="gtk-Drag-and-Drop">Drag and Drop</link> section of
|
||||
the GTK+ documentation for more information.
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION See_Also ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION Stability_Level ##### -->
|
||||
|
||||
|
||||
<!-- ##### SECTION Image ##### -->
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_drag_get_selection ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@context:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_drag_abort ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@context:
|
||||
@time_:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_drop_reply ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@context:
|
||||
@ok:
|
||||
@time_:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_drag_context_new ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@void:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_drag_drop ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@context:
|
||||
@time_:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_drag_find_window ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@context:
|
||||
@drag_window:
|
||||
@x_root:
|
||||
@y_root:
|
||||
@dest_window:
|
||||
@protocol:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_drag_find_window_for_screen ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@context:
|
||||
@drag_window:
|
||||
@screen:
|
||||
@x_root:
|
||||
@y_root:
|
||||
@dest_window:
|
||||
@protocol:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_drag_begin ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@window:
|
||||
@targets:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_drag_motion ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@context:
|
||||
@dest_window:
|
||||
@protocol:
|
||||
@x_root:
|
||||
@y_root:
|
||||
@suggested_action:
|
||||
@possible_actions:
|
||||
@time_:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_drop_finish ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@context:
|
||||
@success:
|
||||
@time_:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_drag_get_protocol ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@xid:
|
||||
@protocol:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_drag_get_protocol_for_display ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@display:
|
||||
@xid:
|
||||
@protocol:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### ENUM GdkDragProtocol ##### -->
|
||||
<para>
|
||||
Used in #GdkDragContext to indicate the protocol according to
|
||||
which DND is done.
|
||||
</para>
|
||||
|
||||
@GDK_DRAG_PROTO_MOTIF: The Motif DND protocol.
|
||||
@GDK_DRAG_PROTO_XDND: The Xdnd protocol.
|
||||
@GDK_DRAG_PROTO_ROOTWIN: An extension to the Xdnd protocol for
|
||||
unclaimed root window drops.
|
||||
@GDK_DRAG_PROTO_NONE: no protocol.
|
||||
@GDK_DRAG_PROTO_WIN32_DROPFILES: The simple WM_DROPFILES protocol.
|
||||
@GDK_DRAG_PROTO_OLE2: The complex OLE2 DND protocol (not implemented).
|
||||
@GDK_DRAG_PROTO_LOCAL: Intra-application DND.
|
||||
|
||||
<!-- ##### STRUCT GdkDragContext ##### -->
|
||||
<para>
|
||||
A <structname>GdkDragContext</structname> holds information about a
|
||||
drag in progress. It is used on both source and destination sides.
|
||||
</para>
|
||||
|
||||
@parent_instance: the parent instance
|
||||
|
||||
<!-- ##### ENUM GdkDragAction ##### -->
|
||||
<para>
|
||||
Used in #GdkDragContext to indicate what the destination
|
||||
should do with the dropped data.
|
||||
</para>
|
||||
|
||||
@GDK_ACTION_DEFAULT: Means nothing, and should not be used.
|
||||
@GDK_ACTION_COPY: Copy the data.
|
||||
@GDK_ACTION_MOVE: Move the data, i.e. first copy it, then delete
|
||||
it from the source using the DELETE target of the X selection protocol.
|
||||
@GDK_ACTION_LINK: Add a link to the data. Note that this is only
|
||||
useful if source and destination agree on what it means.
|
||||
@GDK_ACTION_PRIVATE: Special action which tells the source that the
|
||||
destination will do something that the source doesn't understand.
|
||||
@GDK_ACTION_ASK: Ask the user what to do with the data.
|
||||
|
||||
<!-- ##### FUNCTION gdk_drag_status ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@context:
|
||||
@action:
|
||||
@time_:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_drag_drop_succeeded ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@context:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_drag_context_get_action ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@context:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_drag_context_get_actions ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@context:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_drag_context_get_suggested_action ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@context:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_drag_context_list_targets ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@context:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_drag_context_get_device ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@context:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_drag_context_set_device ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@context:
|
||||
@device:
|
||||
|
||||
|
||||
@@ -45,44 +45,6 @@ or a #GdkWindow.
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_drawable_ref ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@drawable:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_drawable_unref ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@drawable:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_drawable_set_data ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@drawable:
|
||||
@key:
|
||||
@data:
|
||||
@destroy_func:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_drawable_get_data ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@drawable:
|
||||
@key:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_drawable_get_display ##### -->
|
||||
<para>
|
||||
|
||||
@@ -395,52 +357,6 @@ bottom edges.
|
||||
@background:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_draw_string ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@drawable:
|
||||
@font:
|
||||
@gc:
|
||||
@x:
|
||||
@y:
|
||||
@string:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_draw_text ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@drawable:
|
||||
@font:
|
||||
@gc:
|
||||
@x:
|
||||
@y:
|
||||
@text:
|
||||
@text_length:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_draw_text_wc ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@drawable:
|
||||
@font:
|
||||
@gc:
|
||||
@x:
|
||||
@y:
|
||||
@text:
|
||||
@text_length:
|
||||
|
||||
|
||||
<!-- ##### MACRO gdk_draw_pixmap ##### -->
|
||||
<para>
|
||||
Draws a pixmap, or a part of a pixmap, onto another drawable.
|
||||
</para>
|
||||
|
||||
@Deprecated: Use gdk_draw_drawable() instead.
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_draw_drawable ##### -->
|
||||
<para>
|
||||
|
||||
|
||||
@@ -1,586 +0,0 @@
|
||||
<!-- ##### SECTION Title ##### -->
|
||||
Fonts
|
||||
|
||||
<!-- ##### SECTION Short_Description ##### -->
|
||||
Loading and manipulating fonts
|
||||
|
||||
<!-- ##### SECTION Long_Description ##### -->
|
||||
<para>
|
||||
The #GdkFont data type represents a font for drawing on
|
||||
the screen. These functions provide support for
|
||||
loading fonts, and also for determining the dimensions
|
||||
of characters and strings when drawn with a particular
|
||||
font.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
Fonts in X are specified by a
|
||||
<firstterm>X Logical Font Description</firstterm>.
|
||||
The following description is considerably simplified.
|
||||
For definitive information about XLFD's see the
|
||||
X reference documentation. A X Logical Font Description (XLFD)
|
||||
consists of a sequence of fields separated (and surrounded by) '-'
|
||||
characters. For example, Adobe Helvetica Bold 12 pt, has the
|
||||
full description:
|
||||
<informalexample><programlisting>
|
||||
"-adobe-helvetica-bold-r-normal--12-120-75-75-p-70-iso8859-1"
|
||||
</programlisting></informalexample>
|
||||
</para>
|
||||
|
||||
<para>
|
||||
The fields in the XLFD are:
|
||||
|
||||
<informaltable pgwide="1" frame="none">
|
||||
<tgroup cols="2"><colspec colwidth="2*"/><colspec colwidth="8*"/>
|
||||
<tbody>
|
||||
|
||||
<row>
|
||||
<entry>Foundry</entry>
|
||||
<entry>the company or organization where the font originated.</entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry>Family</entry>
|
||||
<entry>the font family (a group of related font designs).</entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry>Weight</entry>
|
||||
<entry>A name for the font's typographic weight
|
||||
For example, 'bold' or 'medium').</entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry>Slant</entry>
|
||||
<entry>The slant of the font. Common values are 'R' for Roman,
|
||||
'I' for italoc, and 'O' for oblique.</entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry>Set Width</entry>
|
||||
<entry>A name for the width of the font. For example,
|
||||
'normal' or 'condensed'.</entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry>Add Style</entry>
|
||||
<entry>Additional information to distinguish a font from
|
||||
other fonts of the same family.</entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry>Pixel Size</entry>
|
||||
<entry>The body size of the font in pixels.</entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry>Point Size</entry>
|
||||
<entry>The body size of the font in 10ths of a point.
|
||||
(A <firstterm>point</firstterm> is 1/72.27 inch) </entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry>Resolution X</entry>
|
||||
<entry>The horizontal resolution that the font was designed for.</entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry>Resolution Y</entry>
|
||||
<entry>The vertical resolution that the font was designed for .</entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry>Spacing</entry>
|
||||
<entry>The type of spacing for the font - can be 'p' for proportional,
|
||||
'm' for monospaced or 'c' for charcell.</entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry>Average Width</entry>
|
||||
<entry>The average width of a glyph in the font. For monospaced
|
||||
and charcell fonts, all glyphs in the font have this width</entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry>Charset Registry</entry>
|
||||
<entry>The registration authority that owns the encoding for
|
||||
the font. Together with the Charset Encoding field, this
|
||||
defines the character set for the font.</entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry>Charset Encoding</entry>
|
||||
<entry>An identifier for the particular character set encoding.</entry>
|
||||
</row>
|
||||
|
||||
</tbody></tgroup></informaltable>
|
||||
</para>
|
||||
|
||||
<para>
|
||||
When specifying a font via a X logical Font Description,
|
||||
'*' can be used as a wildcard to match any portion of
|
||||
the XLFD. For instance, the above example could
|
||||
also be specified as
|
||||
<informalexample><programlisting>
|
||||
"-*-helvetica-bold-r-normal--*-120-*-*-*-*-iso8859-1"
|
||||
</programlisting></informalexample>
|
||||
|
||||
It is generally a good idea to use wildcards for any
|
||||
portion of the XLFD that your program does not care
|
||||
about specifically, since that will improve the
|
||||
chances of finding a matching font.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
A <firstterm>fontset</firstterm> is a list of fonts
|
||||
that is used for drawing international text that may
|
||||
contain characters from a number of different character
|
||||
sets. It is represented by a list of XLFD's.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
The font for a given character set is determined by going
|
||||
through the list of XLFD's in order. For each one, if
|
||||
the registry and and encoding fields match the desired
|
||||
character set, then that font is used, otherwise if
|
||||
the XLFD contains wild-cards for the registry and encoding
|
||||
fields, the registry and encoding for the desired character
|
||||
set are substituted in and a lookup is done. If a match is found
|
||||
that font is used. Otherwise, processing continues
|
||||
on to the next font in the list.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
The functions for determining the metrics of a string
|
||||
come in several varieties that can take a number
|
||||
of forms of string input:
|
||||
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<term>8-bit string</term>
|
||||
<listitem><para>
|
||||
When using functions like gdk_string_width() that
|
||||
take a <type>gchar *</type>, if the font is of type
|
||||
%GDK_FONT_FONT and is an 8-bit font, then each
|
||||
<type>gchar</type> indexes the glyphs in the font directly.
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
<varlistentry>
|
||||
<term>16-bit string</term>
|
||||
<listitem><para>
|
||||
For functions taking a <type>gchar *</type>, if the
|
||||
font is of type %GDK_FONT_FONT, and is a 16-bit
|
||||
font, then the <type>gchar *</type> argument is
|
||||
interpreted as a <type>guint16 *</type> cast to
|
||||
a <type>gchar *</type> and each <type>guint16</type>
|
||||
indexes the glyphs in the font directly.
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
<varlistentry>
|
||||
<term>Multibyte string</term>
|
||||
<listitem><para>
|
||||
For functions taking a <type>gchar *</type>, if the
|
||||
font is of type %GDK_FONT_FONTSET, then the input
|
||||
string is interpreted as a <firstterm>multibyte</firstterm>
|
||||
encoded according to the current locale. (A multibyte
|
||||
string is one in which each character may consist
|
||||
of one or more bytes, with different lengths for different
|
||||
characters in the string). They can be converted to and
|
||||
from wide character strings (see below) using
|
||||
gdk_wcstombs() and gdk_mbstowcs().) The string will
|
||||
be rendered using one or more different fonts from
|
||||
the fontset.
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
<varlistentry>
|
||||
<term>Wide character string</term>
|
||||
<listitem><para>
|
||||
For a number of the text-measuring functions, GDK
|
||||
provides a variant (such as gdk_text_width_wc()) which
|
||||
takes a <type>GdkWChar *</type> instead of a
|
||||
<type>gchar *</type>. The input is then taken to
|
||||
be a wide character string in the encoding of the
|
||||
current locale. (A wide character string is a string
|
||||
in which each character consists of several bytes,
|
||||
and the width of each character in the string is
|
||||
constant.)
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
</variablelist>
|
||||
</para>
|
||||
|
||||
<para>
|
||||
GDK provides functions to determine a number of different
|
||||
measurements (metrics) for a given string. (Need diagram
|
||||
here).
|
||||
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<term>ascent</term>
|
||||
<listitem><para>
|
||||
The vertical distance from the origin of the drawing
|
||||
opereration to the top of the drawn character.
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
<varlistentry>
|
||||
<term>descent</term>
|
||||
<listitem><para>
|
||||
The vertical distance from the origin of the drawing
|
||||
opereration to the bottom of the drawn character.
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
<varlistentry>
|
||||
<term>left bearing</term>
|
||||
<listitem><para>
|
||||
The horizontal distance from the origin of the drawing
|
||||
operation to the left-most part of the drawn character.
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
<varlistentry>
|
||||
<term>right bearing</term>
|
||||
<listitem><para>
|
||||
The horizontal distance from the origin of the drawing
|
||||
operation to the right-most part of the drawn character.
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
<varlistentry>
|
||||
<term>width bearing</term>
|
||||
<listitem><para>
|
||||
The horizontal distance from the origin of the drawing
|
||||
operation to the correct origin for drawing another
|
||||
string to follow the current one. Depending on the
|
||||
font, this could be greater than or less than the
|
||||
right bearing.
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
</variablelist>
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION See_Also ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION Stability_Level ##### -->
|
||||
|
||||
|
||||
<!-- ##### SECTION Image ##### -->
|
||||
|
||||
|
||||
<!-- ##### STRUCT GdkFont ##### -->
|
||||
<para>
|
||||
The <structname>GdkFont</structname> structure represents a font or fontset. It
|
||||
contains the following public fields. A new <structname>GdkFont</structname>
|
||||
structure is returned by gdk_font_load() or gdk_fontset_load(),
|
||||
and is reference counted with gdk_font_ref() and gdk_font_unref()
|
||||
</para>
|
||||
|
||||
@type: a value of type #GdkFontType which indicates
|
||||
whether this font is a single font or a fontset.
|
||||
@ascent: the maximum distance that the font, when drawn,
|
||||
ascends above the baseline.
|
||||
@descent: the maximum distance that the font, when drawn,
|
||||
descends below the baseline.
|
||||
|
||||
<!-- ##### ENUM GdkFontType ##### -->
|
||||
<para>
|
||||
Indicates the type of a font. The possible values
|
||||
are currently:
|
||||
</para>
|
||||
|
||||
@GDK_FONT_FONT: the font is a single font.
|
||||
@GDK_FONT_FONTSET: the font is a fontset.
|
||||
|
||||
<!-- ##### FUNCTION gdk_font_load ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@font_name:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_font_load_for_display ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@display:
|
||||
@font_name:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_fontset_load ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@fontset_name:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_fontset_load_for_display ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@display:
|
||||
@fontset_name:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_font_from_description ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@font_desc:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_font_from_description_for_display ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@display:
|
||||
@font_desc:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_font_get_display ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@font:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_font_ref ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@font:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_font_unref ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@font:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_font_id ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@font:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_font_equal ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@fonta:
|
||||
@fontb:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_string_extents ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@font:
|
||||
@string:
|
||||
@lbearing:
|
||||
@rbearing:
|
||||
@width:
|
||||
@ascent:
|
||||
@descent:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_text_extents ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@font:
|
||||
@text:
|
||||
@text_length:
|
||||
@lbearing:
|
||||
@rbearing:
|
||||
@width:
|
||||
@ascent:
|
||||
@descent:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_text_extents_wc ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@font:
|
||||
@text:
|
||||
@text_length:
|
||||
@lbearing:
|
||||
@rbearing:
|
||||
@width:
|
||||
@ascent:
|
||||
@descent:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_string_width ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@font:
|
||||
@string:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_text_width ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@font:
|
||||
@text:
|
||||
@text_length:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_text_width_wc ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@font:
|
||||
@text:
|
||||
@text_length:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_char_width ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@font:
|
||||
@character:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_char_width_wc ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@font:
|
||||
@character:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_string_measure ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@font:
|
||||
@string:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_text_measure ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@font:
|
||||
@text:
|
||||
@text_length:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_char_measure ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@font:
|
||||
@character:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_string_height ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@font:
|
||||
@string:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_text_height ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@font:
|
||||
@text:
|
||||
@text_length:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_char_height ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@font:
|
||||
@character:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### TYPEDEF GdkWChar ##### -->
|
||||
<para>
|
||||
Specifies a wide character type, used to represent character codes.
|
||||
This is needed since some native languages have character sets which have
|
||||
more than 256 characters (Japanese and Chinese, for example).
|
||||
</para>
|
||||
<para>
|
||||
Wide character values between 0 and 127 are always identical in meaning to
|
||||
the ASCII character codes. The wide character value 0 is often used to
|
||||
terminate strings of wide characters in a similar way to normal strings
|
||||
using the char type.
|
||||
</para>
|
||||
<para>
|
||||
An alternative to wide characters is multi-byte characters, which extend
|
||||
normal char strings to cope with larger character sets. As the name suggests,
|
||||
multi-byte characters use a different number of bytes to store different
|
||||
character codes. For example codes 0-127 (i.e. the ASCII codes) often
|
||||
use just one byte of memory, while other codes may use 2, 3 or even 4 bytes.
|
||||
Multi-byte characters have the advantage that they can often be used in an
|
||||
application with little change, since strings are still represented as arrays
|
||||
of char values. However multi-byte strings are much easier to manipulate since
|
||||
the character are all of the same size.
|
||||
</para>
|
||||
<para>
|
||||
Applications typically use wide characters to represent character codes
|
||||
internally, and multi-byte strings when saving the characters to a file.
|
||||
The gdk_wcstombs() and gdk_mbstowcs() functions can be used to convert from
|
||||
one representation to the other.
|
||||
</para>
|
||||
<para>
|
||||
See the 'Extended Characters' section of the GNU C Library Reference Manual
|
||||
for more detailed information on wide and multi-byte characters.
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_wcstombs ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@src:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_mbstowcs ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@dest:
|
||||
@src:
|
||||
@dest_max:
|
||||
@Returns:
|
||||
|
||||
|
||||
@@ -79,7 +79,6 @@ A set of bit flags used to indicate which fields
|
||||
|
||||
@GDK_GC_FOREGROUND: the @foreground is set.
|
||||
@GDK_GC_BACKGROUND: the @background is set.
|
||||
@GDK_GC_FONT: the @font is set.
|
||||
@GDK_GC_FUNCTION: the @function is set.
|
||||
@GDK_GC_FILL: the @fill is set.
|
||||
@GDK_GC_TILE: the @tile is set.
|
||||
|
||||
@@ -195,6 +195,15 @@ and if that fails then %GDK_IMAGE_NORMAL will be used.
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_image_get_pixels ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@image:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_image_put_pixel ##### -->
|
||||
<para>
|
||||
Sets a pixel in a #GdkImage to a given pixel value.
|
||||
|
||||
@@ -1,96 +0,0 @@
|
||||
<!-- ##### SECTION Title ##### -->
|
||||
Input
|
||||
|
||||
<!-- ##### SECTION Short_Description ##### -->
|
||||
Callbacks on file descriptors
|
||||
|
||||
<!-- ##### SECTION Long_Description ##### -->
|
||||
<para>
|
||||
The functions in this section are used to establish
|
||||
callbacks when some condition becomes true for
|
||||
a file descriptor. They are currently just wrappers around
|
||||
the <link linkend="glib-IO-Channels">IO Channel</link>
|
||||
facility.
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION See_Also ##### -->
|
||||
<para>
|
||||
<variablelist>
|
||||
|
||||
<varlistentry>
|
||||
<term><link linkend="glib-The-Main-Event-Loop">GLib Main Loop</link></term>
|
||||
<listitem><para>The main loop in which input callbacks run.</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><link linkend="glib-IO-Channels">IO Channels</link></term>
|
||||
<listitem><para>A newer and more flexible way of doing IO
|
||||
callbacks.</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
</variablelist>
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION Stability_Level ##### -->
|
||||
|
||||
|
||||
<!-- ##### SECTION Image ##### -->
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_input_add_full ##### -->
|
||||
|
||||
|
||||
@source:
|
||||
@condition:
|
||||
@function:
|
||||
@data:
|
||||
@destroy:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### ENUM GdkInputCondition ##### -->
|
||||
<para>
|
||||
A set of bit flags used to specify conditions for which
|
||||
an input callback will be triggered. The three members
|
||||
of this enumeration correspond to the @readfds,
|
||||
@writefds, and @exceptfds arguments to the
|
||||
<function>select</function> system call.
|
||||
</para>
|
||||
|
||||
@GDK_INPUT_READ: the file descriptor has become available for reading.
|
||||
(Or, as is standard in Unix, a socket or pipe was closed
|
||||
at the other end; this is the case if a subsequent read
|
||||
on the file descriptor returns a count of zero.)
|
||||
@GDK_INPUT_WRITE: the file descriptor has become available for writing.
|
||||
@GDK_INPUT_EXCEPTION: an exception was raised on the file descriptor.
|
||||
|
||||
<!-- ##### USER_FUNCTION GdkInputFunction ##### -->
|
||||
<para>
|
||||
A callback function that will be called when some condition
|
||||
occurs.
|
||||
</para>
|
||||
|
||||
@data: the user data passed to gdk_input_add() or gdk_input_add_full().
|
||||
@source: the source where the condition occurred.
|
||||
@condition: the triggering condition.
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_input_add ##### -->
|
||||
|
||||
|
||||
@source:
|
||||
@condition:
|
||||
@function:
|
||||
@data:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_input_remove ##### -->
|
||||
<para>
|
||||
Remove a callback added with gdk_input_add() or
|
||||
gdk_input_add_full().
|
||||
</para>
|
||||
|
||||
@tag: the tag returned when the callback was set up.
|
||||
|
||||
|
||||
@@ -8,7 +8,7 @@ Offscreen drawables
|
||||
<para>
|
||||
Pixmaps are offscreen drawables. They can be drawn upon with the
|
||||
standard drawing primitives, then copied to another drawable (such as
|
||||
a #GdkWindow) with gdk_pixmap_draw(). The depth of a pixmap
|
||||
a #GdkWindow) with gdk_draw_drawable(). The depth of a pixmap
|
||||
is the number of bits per pixels. Bitmaps are simply pixmaps
|
||||
with a depth of 1. (That is, they are monochrome bitmaps - each
|
||||
pixel can be either on or off).
|
||||
|
||||
@@ -1,13 +1,14 @@
|
||||
<!-- ##### SECTION Title ##### -->
|
||||
Points, Rectangles and Regions
|
||||
Points and Rectangles
|
||||
|
||||
<!-- ##### SECTION Short_Description ##### -->
|
||||
Simple graphical data types
|
||||
|
||||
<!-- ##### SECTION Long_Description ##### -->
|
||||
<para>
|
||||
GDK provides the #GdkPoint, #GdkRectangle, #GdkRegion and #GdkSpan data types
|
||||
for representing pixels and sets of pixels on the screen.
|
||||
GDK provides the #GdkPoint and #GdkRectangle data types for representing pixels
|
||||
and sets of pixels on the screen. Together with Cairo's #cairo_region_t data
|
||||
type, they make up the central types for representing graphical data.
|
||||
</para>
|
||||
<para>
|
||||
#GdkPoint is a simple structure containing an x and y coordinate of a point.
|
||||
@@ -19,13 +20,7 @@ gdk_rectangle_intersect(). To find the union of two rectangles use
|
||||
gdk_rectangle_union().
|
||||
</para>
|
||||
<para>
|
||||
#GdkRegion is an opaque data type holding a set of arbitrary pixels, and is
|
||||
usually used for clipping graphical operations (see gdk_gc_set_clip_region()).
|
||||
</para>
|
||||
<para>
|
||||
#GdkSpan is a structure holding a spanline. A spanline is a horizontal line that
|
||||
is one pixel wide. It is mainly used when rasterizing other graphics primitives.
|
||||
It can be intersected to regions by using gdk_region_spans_intersect_foreach().
|
||||
#cairo_region_t is usually used for managing clipping of graphical operations.
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION See_Also ##### -->
|
||||
@@ -47,15 +42,12 @@ Defines the x and y coordinates of a point.
|
||||
@x: the x coordinate of the point.
|
||||
@y: the y coordinate of the point.
|
||||
|
||||
<!-- ##### STRUCT GdkRectangle ##### -->
|
||||
<!-- ##### TYPEDEF GdkRectangle ##### -->
|
||||
<para>
|
||||
Defines the position and size of a rectangle.
|
||||
Defines the position and size of a rectangle. It is identical to
|
||||
#cairo_rectangle_int_t.
|
||||
</para>
|
||||
|
||||
@x: the x coordinate of the left edge of the rectangle.
|
||||
@y: the y coordinate of the top of the rectangle.
|
||||
@width: the width of the rectangle.
|
||||
@height: the height of the rectangle.
|
||||
|
||||
<!-- ##### FUNCTION gdk_rectangle_intersect ##### -->
|
||||
<para>
|
||||
@@ -78,239 +70,3 @@ Defines the position and size of a rectangle.
|
||||
@dest:
|
||||
|
||||
|
||||
<!-- ##### STRUCT GdkRegion ##### -->
|
||||
<para>
|
||||
A GdkRegion represents a set of pixels on the screen.
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_region_new ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@void:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_region_polygon ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@points:
|
||||
@n_points:
|
||||
@fill_rule:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### ENUM GdkFillRule ##### -->
|
||||
<para>
|
||||
The method for determining which pixels are included in a region, when
|
||||
creating a #GdkRegion from a polygon.
|
||||
The fill rule is only relevant for polygons which overlap themselves.
|
||||
</para>
|
||||
|
||||
@GDK_EVEN_ODD_RULE: areas which are overlapped an odd number of times are
|
||||
included in the region, while areas overlapped an even number of times are not.
|
||||
@GDK_WINDING_RULE: overlapping areas are always included.
|
||||
|
||||
<!-- ##### FUNCTION gdk_region_copy ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@region:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_region_rectangle ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@rectangle:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_region_destroy ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@region:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_region_get_clipbox ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@region:
|
||||
@rectangle:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_region_get_rectangles ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@region:
|
||||
@rectangles:
|
||||
@n_rectangles:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_region_empty ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@region:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_region_equal ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@region1:
|
||||
@region2:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_region_rect_equal ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@region:
|
||||
@rectangle:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_region_point_in ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@region:
|
||||
@x:
|
||||
@y:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_region_rect_in ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@region:
|
||||
@rectangle:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### ENUM GdkOverlapType ##### -->
|
||||
<para>
|
||||
Specifies the possible values returned by gdk_region_rect_in().
|
||||
</para>
|
||||
|
||||
@GDK_OVERLAP_RECTANGLE_IN: if the rectangle is inside the #GdkRegion.
|
||||
@GDK_OVERLAP_RECTANGLE_OUT: if the rectangle is outside the #GdkRegion.
|
||||
@GDK_OVERLAP_RECTANGLE_PART: if the rectangle is partly inside the #GdkRegion.
|
||||
|
||||
<!-- ##### FUNCTION gdk_region_offset ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@region:
|
||||
@dx:
|
||||
@dy:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_region_shrink ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@region:
|
||||
@dx:
|
||||
@dy:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_region_union_with_rect ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@region:
|
||||
@rect:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_region_intersect ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@source1:
|
||||
@source2:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_region_union ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@source1:
|
||||
@source2:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_region_subtract ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@source1:
|
||||
@source2:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_region_xor ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@source1:
|
||||
@source2:
|
||||
|
||||
|
||||
<!-- ##### STRUCT GdkSpan ##### -->
|
||||
<para>
|
||||
A GdkSpan represents a horizontal line of pixels starting
|
||||
at the pixel with coordinates @x, @y and ending before @x + @width, @y.
|
||||
</para>
|
||||
|
||||
@x: x coordinate of the first pixel.
|
||||
@y: y coordinate of the first pixel.
|
||||
@width: number of pixels in the span.
|
||||
|
||||
<!-- ##### USER_FUNCTION GdkSpanFunc ##### -->
|
||||
<para>
|
||||
This defines the type of the function passed to
|
||||
gdk_region_spans_intersect_foreach().
|
||||
</para>
|
||||
|
||||
@span: a #GdkSpan.
|
||||
@data: the user data passed to gdk_region_spans_intersect_foreach().
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_region_spans_intersect_foreach ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@region:
|
||||
@spans:
|
||||
@n_spans:
|
||||
@sorted:
|
||||
@function:
|
||||
@data:
|
||||
|
||||
|
||||
|
||||
@@ -179,24 +179,6 @@ Returns the X visual belonging to a #GdkVisual.
|
||||
@Returns: an Xlib <type>Visual*</type>.
|
||||
|
||||
|
||||
<!-- ##### MACRO GDK_FONT_XDISPLAY ##### -->
|
||||
<para>
|
||||
Returns the display of a #GdkFont.
|
||||
</para>
|
||||
|
||||
@font: a #GdkFont.
|
||||
@Returns: an Xlib <type>Display*</type>.
|
||||
|
||||
|
||||
<!-- ##### MACRO GDK_FONT_XFONT ##### -->
|
||||
<para>
|
||||
Returns the X font belonging to a #GdkFont.
|
||||
</para>
|
||||
|
||||
@font: a #GdkFont.
|
||||
@Returns: an Xlib <type>XFontStruct*</type> or an <type>XFontSet</type>.
|
||||
|
||||
|
||||
<!-- ##### MACRO GDK_CURSOR_XCURSOR ##### -->
|
||||
<para>
|
||||
Returns the X cursor belonging to a #GdkCursor.
|
||||
@@ -355,26 +337,6 @@ Another name for GDK_DRAWABLE_XID().
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### MACRO gdk_font_lookup ##### -->
|
||||
<para>
|
||||
Obtains the #GdkFont for the given Xlib font ID, or %NULL if no #GdkFont has
|
||||
been created for @xid.
|
||||
</para>
|
||||
|
||||
@xid: an Xlib font ID
|
||||
|
||||
|
||||
<!-- ##### MACRO gdk_font_lookup_for_display ##### -->
|
||||
<para>
|
||||
Obtains the #GdkFont for the given Xlib font ID on @display, or %NULL if no
|
||||
#GdkFont has been created for @xid.
|
||||
</para>
|
||||
|
||||
@display: a #GdkDisplay
|
||||
@xid: an Xlib font ID
|
||||
Since: 2.2
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_x11_lookup_xdisplay ##### -->
|
||||
<para>
|
||||
|
||||
@@ -595,33 +557,6 @@ Since: 2.2
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_x11_font_get_name ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@font:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_x11_font_get_xdisplay ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@font:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_x11_font_get_xfont ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@font:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gdk_x11_gc_get_xdisplay ##### -->
|
||||
<para>
|
||||
|
||||
|
||||
@@ -21,9 +21,7 @@ CFILE_GLOB=$(top_srcdir)/gtk/*.c
|
||||
|
||||
# Header files to ignore when scanning
|
||||
IGNORE_HFILES= \
|
||||
gtkalias.h \
|
||||
fnmatch.h \
|
||||
gdk-pixbuf-loader.h \
|
||||
gtkdebug.h \
|
||||
gtkbuilderprivate.h \
|
||||
gtkdndcursors.h \
|
||||
@@ -107,7 +105,6 @@ CPPFLAGS += \
|
||||
-UGTK_DISABLE_SINGLE_INCLUDES
|
||||
|
||||
GTKDOC_LIBS = \
|
||||
$(top_builddir)/gdk-pixbuf/libgdk_pixbuf-$(GTK_API_VERSION).la \
|
||||
$(top_builddir)/gdk/$(gdktargetlib) \
|
||||
$(top_builddir)/gtk/$(gtktargetlib)
|
||||
|
||||
@@ -144,20 +141,6 @@ expand_content_files = \
|
||||
glossary.xml \
|
||||
migrating-2to3.xml \
|
||||
migrating-checklist.sgml \
|
||||
migrating-ClientSideWindows.sgml \
|
||||
migrating-GtkAction.sgml \
|
||||
migrating-GtkComboBox.sgml \
|
||||
migrating-GtkEntry-icons.sgml \
|
||||
migrating-GtkFileChooser.sgml \
|
||||
migrating-GtkIconView.sgml \
|
||||
migrating-GtkAboutDialog.sgml \
|
||||
migrating-GtkColorButton.sgml \
|
||||
migrating-GtkAssistant.sgml \
|
||||
migrating-GtkRecentChooser.sgml \
|
||||
migrating-GtkLabel-links.sgml \
|
||||
migrating-GtkLinkButton.sgml \
|
||||
migrating-GtkBuilder.sgml \
|
||||
migrating-GtkTooltip.sgml \
|
||||
tree_widget.sgml \
|
||||
text_widget.sgml \
|
||||
question_index.sgml
|
||||
@@ -337,7 +320,7 @@ HTML_IMAGES = \
|
||||
$(srcdir)/images/layout-tbrl.png
|
||||
|
||||
# Extra options to supply to gtkdoc-fixref
|
||||
FIXXREF_OPTIONS=--extra-dir=../gdk-pixbuf/html --extra-dir=../gdk/html \
|
||||
FIXXREF_OPTIONS=--extra-dir=../gdk/html \
|
||||
--extra-dir=$(GLIB_PREFIX)/share/gtk-doc/html/gobject \
|
||||
--extra-dir=$(GLIB_PREFIX)/share/gtk-doc/html/glib \
|
||||
--extra-dir=$(ATK_PREFIX)/share/gtk-doc/html/atk \
|
||||
|
||||
@@ -160,9 +160,9 @@ How to compile GTK+ itself
|
||||
</listitem>
|
||||
</itemizedlist>
|
||||
<para>
|
||||
Three of the libraries that GTK+ depends on are maintained by
|
||||
by the GTK+ team: GLib, Pango, and ATK. Other libraries are
|
||||
maintained separately.
|
||||
Some of the libraries that GTK+ depends on are maintained by
|
||||
by the GTK+ team: GLib, GdkPixbuf, Pango, and ATK. Other libraries
|
||||
are maintained separately.
|
||||
</para>
|
||||
<itemizedlist>
|
||||
<listitem>
|
||||
@@ -323,9 +323,6 @@ How to compile GTK+ itself
|
||||
<arg>--disable-modules</arg>
|
||||
<arg>--enable-modules</arg>
|
||||
</group>
|
||||
<group>
|
||||
<arg>--with-included-loaders==LOADER1,LOADER2,...</arg>
|
||||
</group>
|
||||
<group>
|
||||
<arg>--with-included-immodules=MODULE1,MODULE2,...</arg>
|
||||
</group>
|
||||
@@ -385,8 +382,8 @@ How to compile GTK+ itself
|
||||
<systemitem>--enable-modules</systemitem></title>
|
||||
|
||||
<para>
|
||||
Normally GTK+ will try to build the GdkPixbuf image file
|
||||
format loaders as little shared libraries that are loaded on
|
||||
Normally GTK+ will try to build the input method modules
|
||||
as little shared libraries that are loaded on
|
||||
demand. The <systemitem>--disable-modules</systemitem>
|
||||
argument indicates that they should all be built statically
|
||||
into the GTK+ library instead. This is useful for
|
||||
@@ -398,16 +395,6 @@ How to compile GTK+ itself
|
||||
</para>
|
||||
</formalpara>
|
||||
|
||||
<formalpara>
|
||||
<title><systemitem>--with-included-loaders</systemitem></title>
|
||||
|
||||
<para>
|
||||
This option allows you to specify which image loaders you
|
||||
want to include; for example, you might include only the PNG
|
||||
loader to create a smaller GdkPixbuf binary.
|
||||
</para>
|
||||
</formalpara>
|
||||
|
||||
<formalpara>
|
||||
<title><systemitem>--with-included-immodules</systemitem></title>
|
||||
|
||||
|
||||
@@ -318,7 +318,7 @@ that is, GUI components such as #GtkButton or #GtkTextView.
|
||||
<xi:include href="xml/gtktable.xml" />
|
||||
<xi:include href="xml/gtkexpander.xml" />
|
||||
<xi:include href="xml/gtkorientable.xml" />
|
||||
<xi:include href="xml/gtkextendedlayout.xml" />
|
||||
<xi:include href="xml/gtksizerequest.xml" />
|
||||
</chapter>
|
||||
|
||||
<chapter id="Ornaments">
|
||||
|
||||
@@ -153,6 +153,7 @@ gtk_accel_label_get_type
|
||||
GtkAccessible
|
||||
gtk_accessible_connect_widget_destroyed
|
||||
gtk_accessible_get_widget
|
||||
gtk_accessible_set_widget
|
||||
|
||||
<SUBSECTION Standard>
|
||||
GTK_ACCESSIBLE
|
||||
@@ -566,6 +567,7 @@ gtk_button_set_image
|
||||
gtk_button_get_image
|
||||
gtk_button_set_image_position
|
||||
gtk_button_get_image_position
|
||||
gtk_button_get_event_window
|
||||
|
||||
<SUBSECTION Standard>
|
||||
GTK_BUTTON
|
||||
@@ -1411,6 +1413,7 @@ gtk_font_selection_dialog_get_preview_text
|
||||
gtk_font_selection_dialog_set_preview_text
|
||||
gtk_font_selection_dialog_get_cancel_button
|
||||
gtk_font_selection_dialog_get_ok_button
|
||||
gtk_font_selection_dialog_get_font_selection
|
||||
|
||||
<SUBSECTION Standard>
|
||||
GTK_FONT_SELECTION_DIALOG
|
||||
@@ -2132,6 +2135,7 @@ gtk_message_dialog_set_image
|
||||
gtk_message_dialog_get_image
|
||||
gtk_message_dialog_format_secondary_text
|
||||
gtk_message_dialog_format_secondary_markup
|
||||
gtk_message_dialog_get_message_area
|
||||
<SUBSECTION Standard>
|
||||
GTK_MESSAGE_DIALOG
|
||||
GTK_IS_MESSAGE_DIALOG
|
||||
@@ -2220,11 +2224,9 @@ gtk_notebook_get_menu_label
|
||||
gtk_notebook_get_nth_page
|
||||
gtk_notebook_get_n_pages
|
||||
gtk_notebook_get_tab_label
|
||||
gtk_notebook_query_tab_label_packing
|
||||
gtk_notebook_set_menu_label
|
||||
gtk_notebook_set_menu_label_text
|
||||
gtk_notebook_set_tab_label
|
||||
gtk_notebook_set_tab_label_packing
|
||||
gtk_notebook_set_tab_label_text
|
||||
gtk_notebook_set_tab_reorderable
|
||||
gtk_notebook_set_tab_detachable
|
||||
@@ -2344,52 +2346,25 @@ GTK_PLUG_GET_CLASS
|
||||
gtk_plug_get_type
|
||||
</SECTION>
|
||||
|
||||
<SECTION>
|
||||
<FILE>gtkprogress</FILE>
|
||||
<TITLE>GtkProgress</TITLE>
|
||||
GtkProgress
|
||||
gtk_progress_set_show_text
|
||||
gtk_progress_set_text_alignment
|
||||
gtk_progress_set_format_string
|
||||
gtk_progress_set_adjustment
|
||||
gtk_progress_set_percentage
|
||||
gtk_progress_set_value
|
||||
gtk_progress_get_value
|
||||
gtk_progress_set_activity_mode
|
||||
gtk_progress_get_current_text
|
||||
gtk_progress_get_text_from_value
|
||||
gtk_progress_get_current_percentage
|
||||
gtk_progress_get_percentage_from_value
|
||||
gtk_progress_configure
|
||||
<SUBSECTION Standard>
|
||||
GTK_PROGRESS
|
||||
GTK_IS_PROGRESS
|
||||
GTK_TYPE_PROGRESS
|
||||
GTK_PROGRESS_CLASS
|
||||
GTK_IS_PROGRESS_CLASS
|
||||
GTK_PROGRESS_GET_CLASS
|
||||
<SUBSECTION Private>
|
||||
gtk_progress_get_type
|
||||
</SECTION>
|
||||
|
||||
<SECTION>
|
||||
<FILE>gtkprogressbar</FILE>
|
||||
<TITLE>GtkProgressBar</TITLE>
|
||||
GtkProgressBar
|
||||
gtk_progress_bar_new
|
||||
gtk_progress_bar_pulse
|
||||
gtk_progress_bar_set_text
|
||||
gtk_progress_bar_set_fraction
|
||||
gtk_progress_bar_set_pulse_step
|
||||
gtk_progress_bar_set_orientation
|
||||
gtk_progress_bar_set_ellipsize
|
||||
GtkProgressBarOrientation
|
||||
gtk_progress_bar_get_text
|
||||
gtk_progress_bar_get_fraction
|
||||
gtk_progress_bar_get_pulse_step
|
||||
GtkProgressBarOrientation
|
||||
gtk_progress_bar_set_orientation
|
||||
gtk_progress_bar_get_orientation
|
||||
gtk_progress_bar_set_show_text
|
||||
gtk_progress_bar_get_show_text
|
||||
gtk_progress_bar_set_text
|
||||
gtk_progress_bar_get_text
|
||||
gtk_progress_bar_set_ellipsize
|
||||
gtk_progress_bar_get_ellipsize
|
||||
GtkProgressBarStyle
|
||||
gtk_progress_bar_set_pulse_step
|
||||
gtk_progress_bar_get_pulse_step
|
||||
<SUBSECTION Standard>
|
||||
GTK_PROGRESS_BAR
|
||||
GTK_IS_PROGRESS_BAR
|
||||
@@ -3108,6 +3083,7 @@ gtk_status_icon_get_type
|
||||
GtkTable
|
||||
gtk_table_new
|
||||
gtk_table_resize
|
||||
gtk_table_get_size
|
||||
gtk_table_attach
|
||||
gtk_table_attach_defaults
|
||||
gtk_table_set_row_spacing
|
||||
@@ -4662,6 +4638,7 @@ gtk_viewport_set_vadjustment
|
||||
gtk_viewport_set_shadow_type
|
||||
gtk_viewport_get_shadow_type
|
||||
gtk_viewport_get_bin_window
|
||||
gtk_viewport_get_view_window
|
||||
<SUBSECTION Standard>
|
||||
GTK_VIEWPORT
|
||||
GTK_IS_VIEWPORT
|
||||
@@ -4965,6 +4942,7 @@ gtk_widget_get_requisition
|
||||
gtk_widget_device_is_shadowed
|
||||
|
||||
<SUBSECTION>
|
||||
gtk_requisition_new
|
||||
gtk_requisition_copy
|
||||
gtk_requisition_free
|
||||
|
||||
@@ -5112,6 +5090,7 @@ gtk_window_group_new
|
||||
gtk_window_group_add_window
|
||||
gtk_window_group_remove_window
|
||||
gtk_window_group_list_windows
|
||||
gtk_window_group_get_current_grab
|
||||
gtk_window_group_get_current_device_grab
|
||||
<SUBSECTION Standard>
|
||||
GTK_IS_WINDOW_GROUP
|
||||
@@ -5705,6 +5684,7 @@ gtk_icon_info_get_filename
|
||||
gtk_icon_info_get_builtin_pixbuf
|
||||
gtk_icon_info_load_icon
|
||||
gtk_icon_info_load_symbolic
|
||||
gtk_icon_info_load_symbolic_for_style
|
||||
gtk_icon_info_set_raw_coordinates
|
||||
gtk_icon_info_get_embedded_rect
|
||||
gtk_icon_info_get_attach_points
|
||||
@@ -6319,26 +6299,27 @@ gtk_orientable_get_type
|
||||
</SECTION>
|
||||
|
||||
<SECTION>
|
||||
<FILE>gtkextendedlayout</FILE>
|
||||
<TITLE>GtkExtendedLayout</TITLE>
|
||||
GtkExtendedLayout
|
||||
GtkExtendedLayoutIface
|
||||
gtk_extended_layout_get_desired_height
|
||||
gtk_extended_layout_get_desired_size
|
||||
gtk_extended_layout_get_desired_width
|
||||
gtk_extended_layout_get_height_for_width
|
||||
gtk_extended_layout_get_width_for_height
|
||||
gtk_extended_layout_is_height_for_width
|
||||
<FILE>gtksizerequest</FILE>
|
||||
<TITLE>GtkSizeRequest</TITLE>
|
||||
GtkSizeRequest
|
||||
GtkSizeRequestIface
|
||||
GtkSizeRequestMode
|
||||
gtk_size_request_get_height
|
||||
gtk_size_request_get_width
|
||||
gtk_size_request_get_height_for_width
|
||||
gtk_size_request_get_width_for_height
|
||||
gtk_size_request_get_request_mode
|
||||
gtk_size_request_get_size
|
||||
|
||||
<SUBSECTION Standard>
|
||||
GTK_EXTENDED_LAYOUT
|
||||
GTK_EXTENDED_LAYOUT_CLASS
|
||||
GTK_EXTENDED_LAYOUT_GET_IFACE
|
||||
GTK_IS_EXTENDED_LAYOUT
|
||||
GTK_TYPE_EXTENDED_LAYOUT
|
||||
GTK_SIZE_REQUEST
|
||||
GTK_SIZE_REQUEST_CLASS
|
||||
GTK_SIZE_REQUEST_GET_IFACE
|
||||
GTK_IS_SIZE_REQUEST
|
||||
GTK_TYPE_SIZE_REQUEST
|
||||
|
||||
<SUBSECTION Private>
|
||||
gtk_extended_layout_get_type
|
||||
gtk_size_request_get_type
|
||||
</SECTION>
|
||||
|
||||
<SECTION>
|
||||
@@ -6352,6 +6333,7 @@ gtk_application_quit
|
||||
gtk_application_set_action_group
|
||||
gtk_application_get_window
|
||||
gtk_application_add_window
|
||||
gtk_application_create_window
|
||||
|
||||
<SUBSECTION Standard>
|
||||
GtkApplicationClass
|
||||
|
||||
@@ -51,7 +51,6 @@ gtk_entry_completion_get_type
|
||||
gtk_entry_get_type
|
||||
gtk_event_box_get_type
|
||||
gtk_expander_get_type
|
||||
gtk_extended_layout_get_type
|
||||
gtk_file_chooser_button_get_type
|
||||
gtk_file_chooser_dialog_get_type
|
||||
gtk_file_chooser_get_type
|
||||
@@ -111,7 +110,6 @@ gtk_print_operation_preview_get_type
|
||||
gtk_print_settings_get_type
|
||||
gtk_print_unix_dialog_get_type
|
||||
gtk_progress_bar_get_type
|
||||
gtk_progress_get_type
|
||||
gtk_radio_action_get_type
|
||||
gtk_radio_button_get_type
|
||||
gtk_radio_menu_item_get_type
|
||||
@@ -134,6 +132,7 @@ gtk_separator_menu_item_get_type
|
||||
gtk_separator_tool_item_get_type
|
||||
gtk_settings_get_type
|
||||
gtk_size_group_get_type
|
||||
gtk_size_request_get_type
|
||||
gtk_socket_get_type
|
||||
gtk_spin_button_get_type
|
||||
gtk_spinner_get_type
|
||||
|
||||
@@ -43,6 +43,7 @@
|
||||
<programlisting>
|
||||
make CFLAGS+="-DGSEAL_ENABLE"
|
||||
</programlisting>
|
||||
Starting with 2.90.4, GTK+'s .pc files turn on GSEAL_ENABLE by default.
|
||||
</para>
|
||||
</section>
|
||||
|
||||
|
||||
6
docs/reference/gtk/tmpl/.gitignore
vendored
6
docs/reference/gtk/tmpl/.gitignore
vendored
@@ -1,7 +1,11 @@
|
||||
gtkbbox.sgml
|
||||
gtkbox.sgml
|
||||
gtkbuilder.sgml
|
||||
gtkbutton.sgml
|
||||
gtkcalendar.sgml
|
||||
gtkcelleditable.sgml
|
||||
gtkhbox.sgml
|
||||
gtkiconview.sgml
|
||||
gtkmessagedialog.sgml
|
||||
gtkobject.sgml
|
||||
gtkorientable.sgml
|
||||
@@ -19,9 +23,11 @@ gtkscalebutton.sgml
|
||||
gtkseparator.sgml
|
||||
gtkseparatormenuitem.sgml
|
||||
gtkseparatortoolitem.sgml
|
||||
gtkstatusbar.sgml
|
||||
gtkstyle.sgml
|
||||
gtktesting.sgml
|
||||
gtktextiter.sgml
|
||||
gtktoggleaction.sgml
|
||||
gtktoolitem.sgml
|
||||
gtktreednd.sgml
|
||||
gtkwindow.sgml
|
||||
|
||||
@@ -1,389 +0,0 @@
|
||||
<!-- ##### SECTION Title ##### -->
|
||||
GtkButton
|
||||
|
||||
<!-- ##### SECTION Short_Description ##### -->
|
||||
A widget that creates a signal when clicked on
|
||||
|
||||
<!-- ##### SECTION Long_Description ##### -->
|
||||
<para>
|
||||
The #GtkButton widget is generally used to attach a function to that
|
||||
is called when the button is pressed. The various signals and how to use
|
||||
them are outlined below.
|
||||
</para>
|
||||
<para>
|
||||
The #GtkButton widget can hold any valid child widget. That is it can
|
||||
hold most any other standard #GtkWidget. The most commonly used child is
|
||||
the #GtkLabel.
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION See_Also ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION Stability_Level ##### -->
|
||||
|
||||
|
||||
<!-- ##### SECTION Image ##### -->
|
||||
|
||||
|
||||
<!-- ##### STRUCT GtkButton ##### -->
|
||||
<para>
|
||||
This should not be accessed directly. Use the accessor functions below.
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### SIGNAL GtkButton::activate ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@button: the object which received the signal.
|
||||
|
||||
<!-- ##### SIGNAL GtkButton::clicked ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@button:
|
||||
|
||||
<!-- ##### SIGNAL GtkButton::enter ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@button:
|
||||
|
||||
<!-- ##### SIGNAL GtkButton::leave ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@button:
|
||||
|
||||
<!-- ##### SIGNAL GtkButton::pressed ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@button:
|
||||
|
||||
<!-- ##### SIGNAL GtkButton::released ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@button:
|
||||
|
||||
<!-- ##### ARG GtkButton:focus-on-click ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkButton:image ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkButton:image-position ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkButton:label ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkButton:relief ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkButton:use-stock ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkButton:use-underline ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkButton:xalign ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkButton:yalign ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkButton:child-displacement-x ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkButton:child-displacement-y ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkButton:default-border ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkButton:default-outside-border ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkButton:displace-focus ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkButton:image-spacing ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkButton:inner-border ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### FUNCTION gtk_button_new ##### -->
|
||||
<para>
|
||||
Creates a new #GtkButton widget. To add a child widget to the button,
|
||||
use gtk_container_add().
|
||||
</para>
|
||||
|
||||
@void:
|
||||
@Returns: The newly created #GtkButton widget.
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_button_new_with_label ##### -->
|
||||
<para>
|
||||
Creates a #GtkButton widget with a #GtkLabel child containing the given
|
||||
text.
|
||||
</para>
|
||||
|
||||
@label: The text you want the #GtkLabel to hold.
|
||||
@Returns: The newly created #GtkButton widget.
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_button_new_with_mnemonic ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@label:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_button_new_from_stock ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@stock_id:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_button_pressed ##### -->
|
||||
<para>
|
||||
Emits a #GtkButton::pressed signal to the given #GtkButton.
|
||||
</para>
|
||||
|
||||
@button: The #GtkButton you want to send the signal to.
|
||||
@Deprecated: 2.20: Use the #GtkWidget::button-press-event signal.
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_button_released ##### -->
|
||||
<para>
|
||||
Emits a #GtkButton::released signal to the given #GtkButton.
|
||||
</para>
|
||||
|
||||
@button: The #GtkButton you want to send the signal to.
|
||||
@Deprecated: 2.20: Use the #GtkWidget::button-release-event signal.
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_button_clicked ##### -->
|
||||
<para>
|
||||
Emits a #GtkButton::clicked signal to the given #GtkButton.
|
||||
</para>
|
||||
|
||||
@button: The #GtkButton you want to send the signal to.
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_button_enter ##### -->
|
||||
<para>
|
||||
Emits a #GtkButton::enter signal to the given #GtkButton.
|
||||
</para>
|
||||
|
||||
@button: The #GtkButton you want to send the signal to.
|
||||
@Deprecated: 2.20: Use the #GtkWidget::enter-notify-event signal.
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_button_leave ##### -->
|
||||
<para>
|
||||
Emits a #GtkButton::leave signal to the given #GtkButton.
|
||||
</para>
|
||||
|
||||
@button: The #GtkButton you want to send the signal to.
|
||||
@Deprecated: 2.20: Use the #GtkWidget::leave-notify-event signal.
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_button_set_relief ##### -->
|
||||
<para>
|
||||
Sets the relief style of the edges of the given #GtkButton widget.
|
||||
Three styles exist, GTK_RELIEF_NORMAL, GTK_RELIEF_HALF, GTK_RELIEF_NONE.
|
||||
The default style is, as one can guess, GTK_RELIEF_NORMAL.
|
||||
|
||||
<!-- FIXME: put pictures of each style -->
|
||||
</para>
|
||||
|
||||
@button: The #GtkButton you want to set relief styles of.
|
||||
@newstyle: The GtkReliefStyle as described above.
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_button_get_relief ##### -->
|
||||
<para>
|
||||
Returns the current relief style of the given #GtkButton.
|
||||
</para>
|
||||
|
||||
@button: The #GtkButton you want the #GtkReliefStyle from.
|
||||
@Returns: The current #GtkReliefStyle
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_button_get_label ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@button:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_button_set_label ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@button:
|
||||
@label:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_button_get_use_stock ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@button:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_button_set_use_stock ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@button:
|
||||
@use_stock:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_button_get_use_underline ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@button:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_button_set_use_underline ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@button:
|
||||
@use_underline:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_button_set_focus_on_click ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@button:
|
||||
@focus_on_click:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_button_get_focus_on_click ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@button:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_button_set_alignment ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@button:
|
||||
@xalign:
|
||||
@yalign:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_button_get_alignment ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@button:
|
||||
@xalign:
|
||||
@yalign:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_button_set_image ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@button:
|
||||
@image:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_button_get_image ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@button:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_button_set_image_position ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@button:
|
||||
@position:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_button_get_image_position ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@button:
|
||||
@Returns:
|
||||
|
||||
|
||||
@@ -1,318 +0,0 @@
|
||||
<!-- ##### SECTION Title ##### -->
|
||||
GtkCalendar
|
||||
|
||||
<!-- ##### SECTION Short_Description ##### -->
|
||||
Displays a calendar and allows the user to select a date
|
||||
|
||||
<!-- ##### SECTION Long_Description ##### -->
|
||||
<para>
|
||||
#GtkCalendar is a widget that displays a calendar, one month at a time.
|
||||
It can be created with gtk_calendar_new().
|
||||
</para>
|
||||
<para>
|
||||
The month and year currently displayed can be altered with
|
||||
gtk_calendar_select_month(). The exact day can be selected from the displayed
|
||||
month using gtk_calendar_select_day().
|
||||
</para>
|
||||
<para>
|
||||
To place a visual marker on a particular day, use gtk_calendar_mark_day()
|
||||
and to remove the marker, gtk_calendar_unmark_day().
|
||||
Alternative, all marks can be cleared with gtk_calendar_clear_marks().
|
||||
</para>
|
||||
<para>
|
||||
The way in which the calendar itself is displayed can be altered using
|
||||
gtk_calendar_set_display_options().
|
||||
</para>
|
||||
<para>
|
||||
The selected date can be retrieved from a #GtkCalendar using
|
||||
gtk_calendar_get_date().
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION See_Also ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION Stability_Level ##### -->
|
||||
|
||||
|
||||
<!-- ##### SECTION Image ##### -->
|
||||
|
||||
|
||||
<!-- ##### STRUCT GtkCalendar ##### -->
|
||||
<para>
|
||||
<structfield>num_marked_dates</structfield> is an integer containing the
|
||||
number of days that have a mark over them.
|
||||
</para>
|
||||
<para>
|
||||
<structfield>marked_date</structfield> is an array containing the day numbers
|
||||
that currently have a mark over them.
|
||||
</para>
|
||||
<para>
|
||||
<structfield>month</structfield>, <structfield>year</structfield>, and
|
||||
<structfield>selected_day</structfield> contain the currently visible month,
|
||||
year, and selected day respectively.
|
||||
</para>
|
||||
<para>
|
||||
All of these fields should be considered read only, and everything in this
|
||||
struct should only be modified using the functions provided below.
|
||||
</para>
|
||||
<note>
|
||||
<para>
|
||||
Note that <structfield>month</structfield> is zero-based (i.e it allowed values
|
||||
are 0-11) while <structfield>selected_day</structfield> is one-based
|
||||
(i.e. allowed values are 1-31).
|
||||
</para>
|
||||
</note>
|
||||
|
||||
|
||||
<!-- ##### SIGNAL GtkCalendar::day-selected ##### -->
|
||||
<para>
|
||||
Emitted when the user selects a day.
|
||||
</para>
|
||||
|
||||
@calendar: the object which received the signal.
|
||||
|
||||
<!-- ##### SIGNAL GtkCalendar::day-selected-double-click ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@calendar: the object which received the signal.
|
||||
|
||||
<!-- ##### SIGNAL GtkCalendar::month-changed ##### -->
|
||||
<para>
|
||||
Emitted when the user clicks a button to change the selected month on a
|
||||
calendar.
|
||||
</para>
|
||||
|
||||
@calendar: the object which received the signal.
|
||||
|
||||
<!-- ##### SIGNAL GtkCalendar::next-month ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@calendar: the object which received the signal.
|
||||
|
||||
<!-- ##### SIGNAL GtkCalendar::next-year ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@calendar: the object which received the signal.
|
||||
|
||||
<!-- ##### SIGNAL GtkCalendar::prev-month ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@calendar: the object which received the signal.
|
||||
|
||||
<!-- ##### SIGNAL GtkCalendar::prev-year ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@calendar: the object which received the signal.
|
||||
|
||||
<!-- ##### ARG GtkCalendar:day ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkCalendar:detail-height-rows ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkCalendar:detail-width-chars ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkCalendar:month ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkCalendar:no-month-change ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkCalendar:show-day-names ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkCalendar:show-details ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkCalendar:show-heading ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkCalendar:show-week-numbers ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkCalendar:year ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### USER_FUNCTION GtkCalendarDetailFunc ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@calendar:
|
||||
@year:
|
||||
@month:
|
||||
@day:
|
||||
@user_data:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### ENUM GtkCalendarDisplayOptions ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@GTK_CALENDAR_SHOW_HEADING:
|
||||
@GTK_CALENDAR_SHOW_DAY_NAMES:
|
||||
@GTK_CALENDAR_NO_MONTH_CHANGE:
|
||||
@GTK_CALENDAR_SHOW_WEEK_NUMBERS:
|
||||
@GTK_CALENDAR_WEEK_START_MONDAY:
|
||||
@GTK_CALENDAR_SHOW_DETAILS:
|
||||
|
||||
<!-- ##### FUNCTION gtk_calendar_new ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@void:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_calendar_select_month ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@calendar:
|
||||
@month:
|
||||
@year:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_calendar_select_day ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@calendar:
|
||||
@day:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_calendar_mark_day ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@calendar:
|
||||
@day:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_calendar_unmark_day ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@calendar:
|
||||
@day:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_calendar_clear_marks ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@calendar:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_calendar_get_display_options ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@calendar:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_calendar_set_display_options ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@calendar:
|
||||
@flags:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_calendar_get_date ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@calendar:
|
||||
@year:
|
||||
@month:
|
||||
@day:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_calendar_set_detail_func ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@calendar:
|
||||
@func:
|
||||
@data:
|
||||
@destroy:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_calendar_get_detail_width_chars ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@calendar:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_calendar_set_detail_width_chars ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@calendar:
|
||||
@chars:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_calendar_get_detail_height_rows ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@calendar:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_calendar_set_detail_height_rows ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@calendar:
|
||||
@rows:
|
||||
|
||||
|
||||
@@ -1,83 +0,0 @@
|
||||
<!-- ##### SECTION Title ##### -->
|
||||
GtkCellEditable
|
||||
|
||||
<!-- ##### SECTION Short_Description ##### -->
|
||||
Interface for widgets which can are used for editing cells
|
||||
|
||||
<!-- ##### SECTION Long_Description ##### -->
|
||||
<para>
|
||||
The #GtkCellEditable interface must be implemented for widgets
|
||||
to be usable when editing the contents of a #GtkTreeView cell.
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION See_Also ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION Stability_Level ##### -->
|
||||
|
||||
|
||||
<!-- ##### SECTION Image ##### -->
|
||||
|
||||
|
||||
<!-- ##### STRUCT GtkCellEditable ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### SIGNAL GtkCellEditable::editing-done ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@celleditable: the object which received the signal.
|
||||
|
||||
<!-- ##### SIGNAL GtkCellEditable::remove-widget ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@celleditable: the object which received the signal.
|
||||
|
||||
<!-- ##### ARG GtkCellEditable:editing-canceled ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### STRUCT GtkCellEditableIface ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@g_iface:
|
||||
@editing_done:
|
||||
@remove_widget:
|
||||
@start_editing:
|
||||
|
||||
<!-- ##### FUNCTION gtk_cell_editable_start_editing ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@cell_editable:
|
||||
@event:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_cell_editable_editing_done ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@cell_editable:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_cell_editable_remove_widget ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@cell_editable:
|
||||
|
||||
|
||||
@@ -785,6 +785,7 @@ Specifies the side of the entry at which an icon is placed.
|
||||
|
||||
@GTK_ENTRY_ICON_PRIMARY: At the beginning of the entry (depending on the text direction).
|
||||
@GTK_ENTRY_ICON_SECONDARY: At the end of the entry (depending on the text direction).
|
||||
@Since: 2.16
|
||||
|
||||
<!-- ##### FUNCTION gtk_entry_set_icon_from_pixbuf ##### -->
|
||||
<para>
|
||||
|
||||
@@ -118,3 +118,12 @@ fonts.</para></listitem>
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_font_selection_dialog_get_font_selection ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@fsd:
|
||||
@Returns:
|
||||
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@ their icons, but more additional application themes can be
|
||||
installed as operating system vendors and users choose.
|
||||
</para>
|
||||
<para>
|
||||
Named icons are similar to the <xref linkend="gtk-Themeable-Stock-Images"/>
|
||||
Named icons are similar to the <xref linkend="gtk3-Themeable-Stock-Images"/>
|
||||
facility, and the distinction between the two may be a bit confusing.
|
||||
A few things to keep in mind:
|
||||
</para>
|
||||
@@ -27,7 +27,7 @@ A few things to keep in mind:
|
||||
<listitem>
|
||||
<para>
|
||||
Stock images usually are used in conjunction with
|
||||
<xref linkend="gtk-Stock-Items"/>., such as %GTK_STOCK_OK or
|
||||
<xref linkend="gtk3-Stock-Items"/>., such as %GTK_STOCK_OK or
|
||||
%GTK_STOCK_OPEN. Named icons are easier to set up and therefore
|
||||
are more useful for new icons that an application wants to
|
||||
add, such as application icons or window icons.
|
||||
@@ -436,6 +436,19 @@ The #GQuark used for #GtkIconThemeError errors.
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_info_load_symbolic_for_style ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_info:
|
||||
@style:
|
||||
@state:
|
||||
@was_symbolic:
|
||||
@error:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_info_set_raw_coordinates ##### -->
|
||||
<para>
|
||||
|
||||
|
||||
@@ -1,771 +0,0 @@
|
||||
<!-- ##### SECTION Title ##### -->
|
||||
GtkIconView
|
||||
|
||||
<!-- ##### SECTION Short_Description ##### -->
|
||||
A widget which displays a list of icons in a grid
|
||||
|
||||
<!-- ##### SECTION Long_Description ##### -->
|
||||
<para>
|
||||
#GtkIconView provides an alternative view on a list model.
|
||||
It displays the model as a grid of icons with labels. Like
|
||||
#GtkTreeView, it allows to select one or multiple items
|
||||
(depending on the selection mode, see gtk_icon_view_set_selection_mode()).
|
||||
In addition to selection with the arrow keys, #GtkIconView supports
|
||||
rubberband selection, which is controlled by dragging the pointer.
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION See_Also ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION Stability_Level ##### -->
|
||||
|
||||
|
||||
<!-- ##### SECTION Image ##### -->
|
||||
|
||||
|
||||
<!-- ##### STRUCT GtkIconView ##### -->
|
||||
<para>
|
||||
The <structname>GtkIconView</structname> struct contains only
|
||||
private fields and should not be directly accessed.
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### SIGNAL GtkIconView::activate-cursor-item ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@iconview: the object which received the signal.
|
||||
@Returns:
|
||||
|
||||
<!-- ##### SIGNAL GtkIconView::item-activated ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@iconview: the object which received the signal.
|
||||
@arg1:
|
||||
|
||||
<!-- ##### SIGNAL GtkIconView::move-cursor ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@iconview: the object which received the signal.
|
||||
@arg1:
|
||||
@arg2:
|
||||
@Returns:
|
||||
|
||||
<!-- ##### SIGNAL GtkIconView::select-all ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@iconview: the object which received the signal.
|
||||
|
||||
<!-- ##### SIGNAL GtkIconView::select-cursor-item ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@iconview: the object which received the signal.
|
||||
|
||||
<!-- ##### SIGNAL GtkIconView::selection-changed ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@iconview: the object which received the signal.
|
||||
|
||||
<!-- ##### SIGNAL GtkIconView::set-scroll-adjustments ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@iconview: the object which received the signal.
|
||||
@arg1:
|
||||
@arg2:
|
||||
|
||||
<!-- ##### SIGNAL GtkIconView::toggle-cursor-item ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@iconview: the object which received the signal.
|
||||
|
||||
<!-- ##### SIGNAL GtkIconView::unselect-all ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@iconview: the object which received the signal.
|
||||
|
||||
<!-- ##### ARG GtkIconView:column-spacing ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkIconView:columns ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkIconView:item-padding ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkIconView:item-width ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkIconView:margin ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkIconView:markup-column ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkIconView:model ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkIconView:orientation ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkIconView:pixbuf-column ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkIconView:reorderable ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkIconView:row-spacing ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkIconView:selection-mode ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkIconView:spacing ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkIconView:text-column ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkIconView:tooltip-column ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkIconView:selection-box-alpha ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkIconView:selection-box-color ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### USER_FUNCTION GtkIconViewForeachFunc ##### -->
|
||||
<para>
|
||||
A function used by gtk_icon_view_selected_foreach() to map all
|
||||
selected rows. It will be called on every selected row in the view.
|
||||
</para>
|
||||
|
||||
@icon_view: a #GtkIconView
|
||||
@path: The #GtkTreePath of a selected row
|
||||
@data: user data
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_new ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@void:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_new_with_model ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@model:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_set_model ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@model:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_get_model ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_set_text_column ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@column:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_get_text_column ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_set_markup_column ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@column:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_get_markup_column ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_set_pixbuf_column ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@column:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_get_pixbuf_column ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_get_path_at_pos ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@x:
|
||||
@y:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_get_item_at_pos ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@x:
|
||||
@y:
|
||||
@path:
|
||||
@cell:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_convert_widget_to_bin_window_coords ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@wx:
|
||||
@wy:
|
||||
@bx:
|
||||
@by:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_set_cursor ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@path:
|
||||
@cell:
|
||||
@start_editing:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_get_cursor ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@path:
|
||||
@cell:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_selected_foreach ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@func:
|
||||
@data:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_set_selection_mode ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@mode:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_get_selection_mode ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_set_orientation ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@orientation:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_get_orientation ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_set_columns ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@columns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_get_columns ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_set_item_width ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@item_width:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_get_item_width ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_set_spacing ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@spacing:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_get_spacing ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_set_row_spacing ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@row_spacing:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_get_row_spacing ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_set_column_spacing ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@column_spacing:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_get_column_spacing ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_set_margin ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@margin:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_get_margin ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_set_item_padding ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@item_padding:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_get_item_padding ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_select_path ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@path:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_unselect_path ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@path:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_path_is_selected ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@path:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_get_selected_items ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_select_all ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_unselect_all ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_item_activated ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@path:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_scroll_to_path ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@path:
|
||||
@use_align:
|
||||
@row_align:
|
||||
@col_align:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_get_visible_range ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@start_path:
|
||||
@end_path:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_set_tooltip_item ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@tooltip:
|
||||
@path:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_set_tooltip_cell ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@tooltip:
|
||||
@path:
|
||||
@cell:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_get_tooltip_context ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@x:
|
||||
@y:
|
||||
@keyboard_tip:
|
||||
@model:
|
||||
@path:
|
||||
@iter:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_set_tooltip_column ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@column:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_get_tooltip_column ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### ENUM GtkIconViewDropPosition ##### -->
|
||||
<para>
|
||||
An enum for determining where a dropped item goes.
|
||||
</para>
|
||||
|
||||
@GTK_ICON_VIEW_NO_DROP: no drop possible
|
||||
@GTK_ICON_VIEW_DROP_INTO: dropped item replaces the item
|
||||
@GTK_ICON_VIEW_DROP_LEFT: droppped item is inserted to the left
|
||||
@GTK_ICON_VIEW_DROP_RIGHT: dropped item is inserted to the right
|
||||
@GTK_ICON_VIEW_DROP_ABOVE: dropped item is inserted above
|
||||
@GTK_ICON_VIEW_DROP_BELOW: dropped item is inserted below
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_enable_model_drag_source ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@start_button_mask:
|
||||
@targets:
|
||||
@n_targets:
|
||||
@actions:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_enable_model_drag_dest ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@targets:
|
||||
@n_targets:
|
||||
@actions:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_unset_model_drag_source ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_unset_model_drag_dest ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_set_reorderable ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@reorderable:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_get_reorderable ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_set_drag_dest_item ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@path:
|
||||
@pos:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_get_drag_dest_item ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@path:
|
||||
@pos:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_get_dest_item_at_pos ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@drag_x:
|
||||
@drag_y:
|
||||
@path:
|
||||
@pos:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_icon_view_create_drag_icon ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@icon_view:
|
||||
@path:
|
||||
@Returns:
|
||||
|
||||
|
||||
@@ -487,17 +487,6 @@ The #GtkNotebookPage is an opaque implementation detail of #GtkNotebook.
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_notebook_query_tab_label_packing ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@notebook:
|
||||
@child:
|
||||
@expand:
|
||||
@fill:
|
||||
@pack_type:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_notebook_set_menu_label ##### -->
|
||||
<para>
|
||||
</para>
|
||||
@@ -525,17 +514,6 @@ The #GtkNotebookPage is an opaque implementation detail of #GtkNotebook.
|
||||
@tab_label:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_notebook_set_tab_label_packing ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@notebook:
|
||||
@child:
|
||||
@expand:
|
||||
@fill:
|
||||
@pack_type:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_notebook_set_tab_label_text ##### -->
|
||||
<para>
|
||||
</para>
|
||||
|
||||
@@ -54,7 +54,7 @@ GtkWidget *frame2 = gtk_frame_new (NULL);
|
||||
gtk_frame_set_shadow_type (GTK_FRAME (frame1), GTK_SHADOW_IN);
|
||||
gtk_frame_set_shadow_type (GTK_FRAME (frame2), GTK_SHADOW_IN);
|
||||
|
||||
gtk_widget_set_size_request (hpaned, 200 + GTK_PANED (hpaned)->gutter_size, -1);
|
||||
gtk_widget_set_size_request (hpaned, 200, -1);
|
||||
|
||||
gtk_paned_pack1 (GTK_PANED (hpaned), frame1, TRUE, FALSE);
|
||||
gtk_widget_set_size_request (frame1, 50, -1);
|
||||
|
||||
@@ -89,6 +89,11 @@ and should be accessed using the functions below.
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkProgressBar:show-text ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkProgressBar:text ##### -->
|
||||
<para>
|
||||
|
||||
@@ -141,15 +146,6 @@ Creates a new #GtkProgressBar.
|
||||
@pbar:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_progress_bar_set_text ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pbar:
|
||||
@text:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_progress_bar_set_fraction ##### -->
|
||||
<para>
|
||||
|
||||
@@ -159,31 +155,13 @@ Creates a new #GtkProgressBar.
|
||||
@fraction:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_progress_bar_set_pulse_step ##### -->
|
||||
<!-- ##### FUNCTION gtk_progress_bar_get_fraction ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pbar:
|
||||
@fraction:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_progress_bar_set_orientation ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pbar:
|
||||
@orientation:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_progress_bar_set_ellipsize ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pbar:
|
||||
@mode:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### ENUM GtkProgressBarOrientation ##### -->
|
||||
@@ -197,31 +175,13 @@ directions for the visible progress bar.
|
||||
@GTK_PROGRESS_BOTTOM_TO_TOP: A vertical progress bar growing from bottom to top.
|
||||
@GTK_PROGRESS_TOP_TO_BOTTOM: A vertical progress bar growing from top to bottom.
|
||||
|
||||
<!-- ##### FUNCTION gtk_progress_bar_get_text ##### -->
|
||||
<!-- ##### FUNCTION gtk_progress_bar_set_orientation ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pbar:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_progress_bar_get_fraction ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pbar:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_progress_bar_get_pulse_step ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pbar:
|
||||
@Returns:
|
||||
@orientation:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_progress_bar_get_orientation ##### -->
|
||||
@@ -233,6 +193,51 @@ directions for the visible progress bar.
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_progress_bar_set_show_text ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pbar:
|
||||
@show_text:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_progress_bar_get_show_text ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pbar:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_progress_bar_set_text ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pbar:
|
||||
@text:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_progress_bar_get_text ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pbar:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_progress_bar_set_ellipsize ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pbar:
|
||||
@mode:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_progress_bar_get_ellipsize ##### -->
|
||||
<para>
|
||||
|
||||
@@ -242,11 +247,21 @@ directions for the visible progress bar.
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### ENUM GtkProgressBarStyle ##### -->
|
||||
<!-- ##### FUNCTION gtk_progress_bar_set_pulse_step ##### -->
|
||||
<para>
|
||||
An enumeration representing the styles for drawing the progress bar.
|
||||
|
||||
</para>
|
||||
|
||||
@GTK_PROGRESS_CONTINUOUS: The progress bar grows in a smooth, continuous manner.
|
||||
@GTK_PROGRESS_DISCRETE: The progress bar grows in discrete, visible blocks.
|
||||
@pbar:
|
||||
@fraction:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_progress_bar_get_pulse_step ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@pbar:
|
||||
@Returns:
|
||||
|
||||
|
||||
|
||||
@@ -77,7 +77,7 @@ the class name of the widget, while for the class path, the class name is
|
||||
always used.
|
||||
</para>
|
||||
<para>
|
||||
Since GTK+ 2.10,<literal>widget_class</literal> paths can also contain
|
||||
Since GTK+ 2.10, <literal>widget_class</literal> paths can also contain
|
||||
<literal><classname></literal> substrings, which are matching
|
||||
the class with the given name and any derived classes. For instance,
|
||||
<informalexample><programlisting>
|
||||
|
||||
@@ -1,165 +0,0 @@
|
||||
<!-- ##### SECTION Title ##### -->
|
||||
GtkStatusbar
|
||||
|
||||
<!-- ##### SECTION Short_Description ##### -->
|
||||
Report messages of minor importance to the user
|
||||
|
||||
<!-- ##### SECTION Long_Description ##### -->
|
||||
<para>
|
||||
A #GtkStatusbar is usually placed along the bottom of an application's main
|
||||
#GtkWindow. It may provide a regular commentary of the application's status
|
||||
(as is usually the case in a web browser, for example), or may be used to
|
||||
simply output a message when the status changes, (when an upload is complete
|
||||
in an FTP client, for example).
|
||||
It may also have a resize grip (a triangular area in the lower right corner)
|
||||
which can be clicked on to resize the window containing the statusbar.
|
||||
</para>
|
||||
<para>
|
||||
Status bars in GTK+ maintain a stack of messages. The message at
|
||||
the top of the each bar's stack is the one that will currently be displayed.
|
||||
</para>
|
||||
<para>
|
||||
Any messages added to a statusbar's stack must specify a <emphasis>context
|
||||
id</emphasis> that is used to uniquely identify the source of a message.
|
||||
This context id can be generated by gtk_statusbar_get_context_id(), given a
|
||||
message and the statusbar that it will be added to. Note that messages are
|
||||
stored in a stack, and when choosing which message to display, the stack
|
||||
structure is adhered to, regardless of the context identifier of a message.
|
||||
</para>
|
||||
<para>
|
||||
One could say that a statusbar maintains one stack of messages for display
|
||||
purposes, but allows multiple message producers to maintain sub-stacks of
|
||||
the messages they produced (via context ids).
|
||||
</para>
|
||||
<para>
|
||||
Status bars are created using gtk_statusbar_new().
|
||||
</para>
|
||||
<para>
|
||||
Messages are added to the bar's stack with gtk_statusbar_push().
|
||||
</para>
|
||||
<para>
|
||||
The message at the top of the stack can be removed using gtk_statusbar_pop().
|
||||
A message can be removed from anywhere in the stack if its message_id was
|
||||
recorded at the time it was added. This is done using gtk_statusbar_remove().
|
||||
</para>
|
||||
|
||||
<!-- ##### SECTION See_Also ##### -->
|
||||
|
||||
|
||||
<!-- ##### SECTION Stability_Level ##### -->
|
||||
|
||||
|
||||
<!-- ##### SECTION Image ##### -->
|
||||
|
||||
|
||||
<!-- ##### STRUCT GtkStatusbar ##### -->
|
||||
<para>
|
||||
Contains private data that should be modified with the functions described
|
||||
below.
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### SIGNAL GtkStatusbar::text-popped ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@statusbar:
|
||||
@context_id:
|
||||
@text:
|
||||
|
||||
<!-- ##### SIGNAL GtkStatusbar::text-pushed ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@statusbar:
|
||||
@context_id:
|
||||
@text:
|
||||
|
||||
<!-- ##### ARG GtkStatusbar:has-resize-grip ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GtkStatusbar:shadow-type ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### FUNCTION gtk_statusbar_new ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@void:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_statusbar_get_context_id ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@statusbar:
|
||||
@context_description:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_statusbar_push ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@statusbar:
|
||||
@context_id:
|
||||
@text:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_statusbar_pop ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@statusbar:
|
||||
@context_id:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_statusbar_remove ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@statusbar:
|
||||
@context_id:
|
||||
@message_id:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_statusbar_set_has_resize_grip ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@statusbar:
|
||||
@setting:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_statusbar_get_has_resize_grip ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@statusbar:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_statusbar_get_message_area ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@statusbar:
|
||||
@Returns:
|
||||
|
||||
|
||||
@@ -131,7 +131,8 @@ The <structname>GtkTable</structname> structure holds the data for the actual ta
|
||||
Used to create a new table widget. An initial size must be given by
|
||||
specifying how many rows and columns the table should have, although
|
||||
this can be changed later with gtk_table_resize(). @rows and @columns
|
||||
must both be in the range 0 .. 65535.
|
||||
must both be in the range 1 .. 65535. For historical reasons, 0 is accepted
|
||||
as well and is silently interpreted as 1.
|
||||
</para>
|
||||
|
||||
@rows: The number of rows the new table should have.
|
||||
@@ -151,6 +152,16 @@ If you need to change a table's size <emphasis>after</emphasis> it has been crea
|
||||
@columns: The new number of columns.
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_table_get_size ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@table:
|
||||
@rows:
|
||||
@columns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_table_attach ##### -->
|
||||
<para>
|
||||
Adds a widget to a table. The number of 'cells' that a widget will occupy is
|
||||
|
||||
@@ -46,7 +46,8 @@ former you can use gtk_tree_view_convert_widget_to_bin_window_coords()
|
||||
<title>GtkTreeView as GtkBuildable</title>
|
||||
<para>
|
||||
The GtkTreeView implementation of the GtkBuildable interface accepts
|
||||
GtkTreeViewColumn objects as <child> elements in UI definitions.
|
||||
GtkTreeViewColumn objects as <child> elements and exposes the
|
||||
internal GtkTreeSelection in UI definitions.
|
||||
</para>
|
||||
<example>
|
||||
<title>A UI definition fragment with GtkTreeView</title>
|
||||
@@ -64,6 +65,11 @@ GtkTreeViewColumn objects as <child> elements in UI definitions.
|
||||
</child>
|
||||
</object>
|
||||
</child>
|
||||
<child internal-child="selection">
|
||||
<object class="GtkTreeSelection" id="selection">
|
||||
<signal name="changed" handler="on_treeview_selection_changed"/>
|
||||
</object>
|
||||
</child>
|
||||
</object>
|
||||
]]></programlisting>
|
||||
</example>
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -62,6 +62,15 @@ Limit the effect of grabs
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_window_group_get_current_grab ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@window_group:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gtk_window_group_get_current_device_grab ##### -->
|
||||
<para>
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
include $(top_srcdir)/Makefile.decl
|
||||
|
||||
INCLUDES = \
|
||||
-I$(top_srcdir) \
|
||||
-I$(top_srcdir) \
|
||||
-I$(top_builddir)/gdk \
|
||||
-I$(top_srcdir)/gdk \
|
||||
-I$(top_srcdir)/gdk/x11 \
|
||||
@@ -9,16 +9,15 @@ INCLUDES = \
|
||||
$(GTK_DEP_CFLAGS)
|
||||
|
||||
DEPS = \
|
||||
$(top_builddir)/gdk-pixbuf/libgdk_pixbuf-$(GTK_API_VERSION).la \
|
||||
$(top_builddir)/gdk/$(gdktargetlib) \
|
||||
$(top_builddir)/gdk/$(gdktargetlib) \
|
||||
$(top_builddir)/gtk/$(gtktargetlib)
|
||||
|
||||
LDADDS = \
|
||||
$(top_builddir)/gdk-pixbuf/libgdk_pixbuf-$(GTK_API_VERSION).la \
|
||||
$(top_builddir)/gdk/$(gdktargetlib) \
|
||||
$(top_builddir)/gdk/$(gdktargetlib) \
|
||||
$(top_builddir)/gtk/$(gtktargetlib) \
|
||||
$(GTK_DEP_LIBS) \
|
||||
$(GDK_DEP_LIBS)
|
||||
$(GTK_DEP_LIBS) \
|
||||
$(GDK_DEP_LIBS) \
|
||||
-lm
|
||||
|
||||
if USE_X11
|
||||
noinst_PROGRAMS = \
|
||||
|
||||
@@ -37,7 +37,7 @@ EXTRA_DIST += \
|
||||
images/tictactoe.png
|
||||
|
||||
if HAVE_DOCBOOK
|
||||
html:
|
||||
html: gtk-tut.sgml
|
||||
if test -w $(srcdir); then \
|
||||
(cd $(srcdir); \
|
||||
db2html gtk-tut.sgml; \
|
||||
@@ -47,11 +47,13 @@ html:
|
||||
cp images/*.png html/images); \
|
||||
fi
|
||||
|
||||
pdf:
|
||||
pdf: gtk-tut.sgml
|
||||
if test -w $(srcdir); then \
|
||||
(cd $(srcdir); db2pdf gtk-tut.sgml); \
|
||||
fi
|
||||
|
||||
all-local: html
|
||||
|
||||
dist-hook: html
|
||||
cp -Rp $(srcdir)/html $(distdir)
|
||||
else
|
||||
|
||||
@@ -12799,8 +12799,6 @@ gdk_draw_line ()
|
||||
gdk_draw_rectangle ()
|
||||
gdk_draw_arc ()
|
||||
gdk_draw_polygon ()
|
||||
gdk_draw_pixmap ()
|
||||
gdk_draw_bitmap ()
|
||||
gdk_draw_image ()
|
||||
gdk_draw_points ()
|
||||
gdk_draw_segments ()
|
||||
|
||||
@@ -45,7 +45,7 @@ static gboolean
|
||||
window_expose_event (GtkWidget *widget,
|
||||
GdkEventExpose *event)
|
||||
{
|
||||
GdkRegion *region;
|
||||
cairo_region_t *region;
|
||||
GtkWidget *child;
|
||||
cairo_t *cr;
|
||||
|
||||
@@ -61,10 +61,11 @@ window_expose_event (GtkWidget *widget,
|
||||
child->allocation.y);
|
||||
|
||||
/* draw no more than our expose event intersects our child */
|
||||
region = gdk_region_rectangle (&child->allocation);
|
||||
gdk_region_intersect (region, event->region);
|
||||
region = cairo_region_create_rectangle (&child->allocation);
|
||||
cairo_region_intersect (region, region, event->region);
|
||||
gdk_cairo_region (cr, region);
|
||||
cairo_clip (cr);
|
||||
cairo_region_destroy (region);
|
||||
|
||||
/* composite, with a 50% opacity */
|
||||
cairo_set_operator (cr, CAIRO_OPERATOR_OVER);
|
||||
|
||||
@@ -7,6 +7,6 @@ target=@gdktarget@
|
||||
Name: GDK
|
||||
Description: GTK+ Drawing Kit (${target} target)
|
||||
Version: @VERSION@
|
||||
Requires: gdk-pixbuf-@GTK_API_VERSION@ @GDK_PACKAGES@
|
||||
Requires: @GDK_PACKAGES@
|
||||
Libs: -L${libdir} -lgdk-${target}-@GTK_API_VERSION@ @GDK_EXTRA_LIBS@
|
||||
Cflags: -I${includedir}/gtk-@GTK_API_VERSION@ -I${libdir}/gtk-@GTK_API_VERSION@/include @GDK_EXTRA_CFLAGS@
|
||||
Cflags: -I${includedir}/gtk-@GTK_API_VERSION@ -I${libdir}/gtk-@GTK_API_VERSION@/include @GDK_EXTRA_CFLAGS@ -DGSEAL_ENABLE
|
||||
|
||||
@@ -1,9 +0,0 @@
|
||||
Name: GdkPixbuf Uninstalled
|
||||
Description: Image loading and scaling, Not Installed
|
||||
Version: @VERSION@
|
||||
Requires: gobject-2.0,gmodule-2.0
|
||||
Libs: ${pc_top_builddir}/${pcfiledir}/gdk-pixbuf/libgdk_pixbuf-@GTK_API_VERSION@.la @GDK_PIXBUF_EXTRA_LIBS@
|
||||
Cflags: -I${pc_top_builddir}/${pcfiledir}/@srcdir@ -I${pc_top_builddir}/${pcfiledir} @GDK_PIXBUF_EXTRA_CFLAGS@
|
||||
|
||||
|
||||
|
||||
@@ -1,12 +0,0 @@
|
||||
prefix=@prefix@
|
||||
exec_prefix=@exec_prefix@
|
||||
libdir=@libdir@
|
||||
includedir=@includedir@
|
||||
|
||||
Name: GdkPixbuf
|
||||
Description: Image loading and scaling
|
||||
Version: @VERSION@
|
||||
Requires: gobject-2.0,gmodule-no-export-2.0
|
||||
Libs: -L${libdir} -lgdk_pixbuf-@GTK_API_VERSION@ @GDK_PIXBUF_EXTRA_LIBS@
|
||||
Cflags: -I${includedir}/gtk-@GTK_API_VERSION@ @GDK_PIXBUF_EXTRA_CFLAGS@
|
||||
|
||||
6289
gdk-pixbuf/ChangeLog
6289
gdk-pixbuf/ChangeLog
File diff suppressed because it is too large
Load Diff
@@ -1,748 +0,0 @@
|
||||
include $(top_srcdir)/Makefile.decl
|
||||
-include $(INTROSPECTION_MAKEFILE)
|
||||
|
||||
INTROSPECTION_GIRS =
|
||||
|
||||
SUBDIRS = pixops
|
||||
|
||||
if PLATFORM_WIN32
|
||||
no_undefined = -no-undefined
|
||||
endif
|
||||
|
||||
if OS_WIN32
|
||||
gdk_pixbuf_def = gdk_pixbuf.def
|
||||
gdk_pixbuf_symbols = -export-symbols $(srcdir)/gdk_pixbuf.def
|
||||
|
||||
gdk_pixbuf_win32_res = gdk_pixbuf-win32-res.o
|
||||
gdk_pixbuf_win32_res_ldflag = -Wl,gdk_pixbuf-win32-res.o
|
||||
|
||||
libole32 = -lole32
|
||||
|
||||
gdk_pixbuf-win32-res.o : gdk_pixbuf.rc
|
||||
$(WINDRES) gdk_pixbuf.rc $@
|
||||
|
||||
install-def-file:
|
||||
$(INSTALL) $(srcdir)/gdk_pixbuf.def $(DESTDIR)$(libdir)/gdk_pixbuf-$(GTK_API_VERSION).def
|
||||
uninstall-def-file:
|
||||
-rm $(DESTDIR)$(libdir)/gdk_pixbuf-$(GTK_API_VERSION).def
|
||||
else
|
||||
install-def-file:
|
||||
uninstall-def-file:
|
||||
endif
|
||||
|
||||
if MS_LIB_AVAILABLE
|
||||
noinst_DATA = gdk_pixbuf-$(GTK_API_VERSION).lib
|
||||
|
||||
gdk_pixbuf-$(GTK_API_VERSION).lib: libgdk_pixbuf-$(GTK_API_VERSION).la gdk_pixbuf.def
|
||||
lib -machine:@LIB_EXE_MACHINE_FLAG@ -name:libgdk_pixbuf-$(GTK_API_VERSION)-@LT_CURRENT_MINUS_AGE@.dll -def:gdk_pixbuf.def -out:$@
|
||||
|
||||
install-ms-lib:
|
||||
$(INSTALL) gdk_pixbuf-$(GTK_API_VERSION).lib $(DESTDIR)$(libdir)
|
||||
|
||||
uninstall-ms-lib:
|
||||
-rm $(DESTDIR)$(libdir)/gdk_pixbuf-$(GTK_API_VERSION).lib
|
||||
else
|
||||
install-ms-lib:
|
||||
uninstall-ms-lib:
|
||||
endif
|
||||
|
||||
# This places the generated .def file in srcdir, since it is expected to be there.
|
||||
# (The one from a tarball is)
|
||||
gdk_pixbuf.def: gdk-pixbuf.symbols
|
||||
(echo -e EXPORTS; $(CPP) -P -DINCLUDE_VARIABLES -DG_OS_WIN32 -DALL_FILES - <$(srcdir)/gdk-pixbuf.symbols | sed -e '/^$$/d' -e 's/^/ /' -e 's/G_GNUC_[^ ]*//g') > $(srcdir)/gdk_pixbuf.def
|
||||
|
||||
gdk-pixbuf-alias.h: gdk-pixbuf.symbols
|
||||
$(PERL) $(srcdir)/makegdkpixbufalias.pl < $(srcdir)/gdk-pixbuf.symbols > gdk-pixbuf-alias.h
|
||||
|
||||
gdk-pixbuf-aliasdef.c: gdk-pixbuf.symbols
|
||||
$(PERL) $(srcdir)/makegdkpixbufalias.pl -def < $(srcdir)/gdk-pixbuf.symbols > gdk-pixbuf-aliasdef.c
|
||||
|
||||
if OS_LINUX
|
||||
TESTS = abicheck.sh pltcheck.sh
|
||||
endif
|
||||
|
||||
lib_LTLIBRARIES = \
|
||||
libgdk_pixbuf-3.0.la
|
||||
|
||||
loaderdir = $(libdir)/gtk-3.0/$(GTK_BINARY_VERSION)/loaders
|
||||
|
||||
module_libs = libgdk_pixbuf-$(GTK_API_VERSION).la $(GDK_PIXBUF_DEP_LIBS)
|
||||
|
||||
#
|
||||
# The PNG loader
|
||||
#
|
||||
libstatic_pixbufloader_png_la_SOURCES = io-png.c
|
||||
libpixbufloader_png_la_SOURCES = io-png.c
|
||||
libpixbufloader_png_la_LDFLAGS = -avoid-version -module $(no_undefined)
|
||||
libpixbufloader_png_la_LIBADD = $(LIBPNG) $(module_libs)
|
||||
|
||||
#
|
||||
# The BMP loader
|
||||
#
|
||||
libstatic_pixbufloader_bmp_la_SOURCES = io-bmp.c
|
||||
libpixbufloader_bmp_la_SOURCES = io-bmp.c
|
||||
libpixbufloader_bmp_la_LDFLAGS = -avoid-version -module $(no_undefined)
|
||||
libpixbufloader_bmp_la_LIBADD = $(module_libs)
|
||||
|
||||
#
|
||||
# The WBMP loader
|
||||
#
|
||||
libstatic_pixbufloader_wbmp_la_SOURCES = io-wbmp.c
|
||||
libpixbufloader_wbmp_la_SOURCES = io-wbmp.c
|
||||
libpixbufloader_wbmp_la_LDFLAGS = -avoid-version -module $(no_undefined)
|
||||
libpixbufloader_wbmp_la_LIBADD = $(module_libs)
|
||||
|
||||
#
|
||||
# The GIF loader
|
||||
#
|
||||
libstatic_pixbufloader_gif_la_SOURCES = io-gif.c io-gif-animation.c io-gif-animation.h
|
||||
libpixbufloader_gif_la_SOURCES = io-gif.c io-gif-animation.c io-gif-animation.h
|
||||
libpixbufloader_gif_la_LDFLAGS = -avoid-version -module $(no_undefined)
|
||||
libpixbufloader_gif_la_LIBADD = $(module_libs)
|
||||
|
||||
#
|
||||
# The ICO loader
|
||||
#
|
||||
libstatic_pixbufloader_ico_la_SOURCES = io-ico.c
|
||||
libpixbufloader_ico_la_SOURCES = io-ico.c
|
||||
libpixbufloader_ico_la_LDFLAGS = -avoid-version -module $(no_undefined)
|
||||
libpixbufloader_ico_la_LIBADD = $(module_libs)
|
||||
|
||||
#
|
||||
# The ANI loader
|
||||
#
|
||||
libstatic_pixbufloader_ani_la_SOURCES = io-ani.c io-ani-animation.c io-ani-animation.h
|
||||
libpixbufloader_ani_la_SOURCES = io-ani.c io-ani-animation.c io-ani-animation.h
|
||||
libpixbufloader_ani_la_LDFLAGS = -avoid-version -module $(no_undefined)
|
||||
libpixbufloader_ani_la_LIBADD = $(module_libs)
|
||||
|
||||
#
|
||||
# The JPEG loader
|
||||
#
|
||||
libstatic_pixbufloader_jpeg_la_SOURCES = io-jpeg.c
|
||||
libpixbufloader_jpeg_la_SOURCES = io-jpeg.c
|
||||
libpixbufloader_jpeg_la_LDFLAGS = -avoid-version -module $(no_undefined)
|
||||
libpixbufloader_jpeg_la_LIBADD = $(LIBJPEG) $(module_libs)
|
||||
|
||||
#
|
||||
# The PNM loader
|
||||
#
|
||||
libstatic_pixbufloader_pnm_la_SOURCES = io-pnm.c
|
||||
libpixbufloader_pnm_la_SOURCES = io-pnm.c
|
||||
libpixbufloader_pnm_la_LDFLAGS = -avoid-version -module $(no_undefined)
|
||||
libpixbufloader_pnm_la_LIBADD = $(module_libs)
|
||||
|
||||
#
|
||||
# The RAS loader
|
||||
#
|
||||
libstatic_pixbufloader_ras_la_SOURCES = io-ras.c
|
||||
libpixbufloader_ras_la_SOURCES = io-ras.c
|
||||
libpixbufloader_ras_la_LDFLAGS = -avoid-version -module $(no_undefined)
|
||||
libpixbufloader_ras_la_LIBADD = $(module_libs)
|
||||
|
||||
#
|
||||
# The TIFF loader
|
||||
#
|
||||
libstatic_pixbufloader_tiff_la_SOURCES = io-tiff.c
|
||||
libpixbufloader_tiff_la_SOURCES = io-tiff.c
|
||||
libpixbufloader_tiff_la_LDFLAGS = -avoid-version -module $(no_undefined)
|
||||
libpixbufloader_tiff_la_LIBADD = $(LIBTIFF) $(module_libs)
|
||||
|
||||
#
|
||||
# The XPM loader
|
||||
#
|
||||
libstatic_pixbufloader_xpm_la_SOURCES = io-xpm.c
|
||||
libpixbufloader_xpm_la_SOURCES = io-xpm.c
|
||||
libpixbufloader_xpm_la_LDFLAGS = -avoid-version -module $(no_undefined)
|
||||
libpixbufloader_xpm_la_LIBADD = $(module_libs)
|
||||
|
||||
#
|
||||
# The XBM loader
|
||||
#
|
||||
libstatic_pixbufloader_xbm_la_SOURCES = io-xbm.c
|
||||
libpixbufloader_xbm_la_SOURCES = io-xbm.c
|
||||
libpixbufloader_xbm_la_LDFLAGS = -avoid-version -module $(no_undefined)
|
||||
libpixbufloader_xbm_la_LIBADD = $(module_libs)
|
||||
|
||||
#
|
||||
# The TGA loader
|
||||
#
|
||||
libstatic_pixbufloader_tga_la_SOURCES = io-tga.c
|
||||
libpixbufloader_tga_la_SOURCES = io-tga.c
|
||||
libpixbufloader_tga_la_LDFLAGS = -avoid-version -module $(no_undefined)
|
||||
libpixbufloader_tga_la_LIBADD = $(module_libs)
|
||||
|
||||
#
|
||||
# The .icns loader
|
||||
#
|
||||
libstatic_pixbufloader_icns_la_SOURCES = io-icns.c
|
||||
libpixbufloader_icns_la_SOURCES = io-icns.c
|
||||
libpixbufloader_icns_la_LDFLAGS = -avoid-version -module $(no_undefined)
|
||||
libpixbufloader_icns_la_LIBADD = $(module_libs)
|
||||
|
||||
#
|
||||
# The PCX loader
|
||||
#
|
||||
libstatic_pixbufloader_pcx_la_SOURCES = io-pcx.c
|
||||
libpixbufloader_pcx_la_SOURCES = io-pcx.c
|
||||
libpixbufloader_pcx_la_LDFLAGS = -avoid-version -module $(no_undefined)
|
||||
libpixbufloader_pcx_la_LIBADD = $(module_libs)
|
||||
|
||||
#
|
||||
# The JPEG2000 loader
|
||||
#
|
||||
libstatic_pixbufloader_jasper_la_SOURCES = io-jasper.c
|
||||
libpixbufloader_jasper_la_SOURCES = io-jasper.c
|
||||
libpixbufloader_jasper_la_LDFLAGS = -avoid-version -module $(no_undefined)
|
||||
libpixbufloader_jasper_la_LIBADD = $(LIBJASPER) $(module_libs)
|
||||
|
||||
#
|
||||
# The QTIF loader
|
||||
#
|
||||
libstatic_pixbufloader_qtif_la_SOURCES = io-qtif.c
|
||||
libpixbufloader_qtif_la_SOURCES = io-qtif.c
|
||||
libpixbufloader_qtif_la_LDFLAGS = -avoid-version -module $(no_undefined)
|
||||
libpixbufloader_qtif_la_LIBADD = $(module_libs)
|
||||
|
||||
if BUILD_GDIPLUS_LOADERS
|
||||
|
||||
if INCLUDE_GDIPLUS
|
||||
|
||||
# When building the GDI+ loader statically, we put the "common" objects
|
||||
# only in one of the archives to avoid duplicate definitions
|
||||
|
||||
STATIC_GDIPLUS_LIBS = \
|
||||
libstatic-pixbufloader-gdip-ico.la \
|
||||
libstatic-pixbufloader-gdip-wmf.la \
|
||||
libstatic-pixbufloader-gdip-emf.la \
|
||||
libstatic-pixbufloader-gdip-bmp.la \
|
||||
libstatic-pixbufloader-gdip-gif.la \
|
||||
libstatic-pixbufloader-gdip-jpeg.la \
|
||||
libstatic-pixbufloader-gdip-tiff.la
|
||||
|
||||
libstatic_pixbufloader_gdip_ico_la_SOURCES = \
|
||||
io-gdip-native.h \
|
||||
io-gdip-propertytags.h \
|
||||
io-gdip-utils.h \
|
||||
io-gdip-utils.c \
|
||||
io-gdip-animation.c \
|
||||
io-gdip-animation.h \
|
||||
io-gdip-ico.c
|
||||
|
||||
libstatic_pixbufloader_gdip_wmf_la_SOURCES = \
|
||||
io-gdip-wmf.c
|
||||
|
||||
libstatic_pixbufloader_gdip_emf_la_SOURCES = \
|
||||
io-gdip-emf.c
|
||||
|
||||
libstatic_pixbufloader_gdip_bmp_la_SOURCES = \
|
||||
io-gdip-bmp.c
|
||||
|
||||
libstatic_pixbufloader_gdip_gif_la_SOURCES = \
|
||||
io-gdip-gif.c
|
||||
|
||||
libstatic_pixbufloader_gdip_jpeg_la_SOURCES = \
|
||||
io-gdip-jpeg.c
|
||||
|
||||
libstatic_pixbufloader_gdip_tiff_la_SOURCES = \
|
||||
io-gdip-tiff.c
|
||||
|
||||
else
|
||||
|
||||
GDIPLUS_LIBS = \
|
||||
libpixbufloader-gdip-ico.la \
|
||||
libpixbufloader-gdip-wmf.la \
|
||||
libpixbufloader-gdip-emf.la \
|
||||
libpixbufloader-gdip-bmp.la \
|
||||
libpixbufloader-gdip-gif.la \
|
||||
libpixbufloader-gdip-jpeg.la \
|
||||
libpixbufloader-gdip-tiff.la
|
||||
|
||||
libpixbufloader_gdip_ico_la_LDFLAGS = -avoid-version -module -no-undefined
|
||||
libpixbufloader_gdip_ico_la_SOURCES = \
|
||||
io-gdip-native.h \
|
||||
io-gdip-propertytags.h \
|
||||
io-gdip-utils.h \
|
||||
io-gdip-utils.c \
|
||||
io-gdip-animation.c \
|
||||
io-gdip-animation.h \
|
||||
io-gdip-ico.c
|
||||
libpixbufloader_gdip_ico_la_LIBADD = $(module_libs) $(libole32)
|
||||
|
||||
libpixbufloader_gdip_wmf_la_LDFLAGS = -avoid-version -module -no-undefined
|
||||
libpixbufloader_gdip_wmf_la_SOURCES = \
|
||||
io-gdip-native.h \
|
||||
io-gdip-propertytags.h \
|
||||
io-gdip-utils.h \
|
||||
io-gdip-utils.c \
|
||||
io-gdip-animation.c \
|
||||
io-gdip-animation.h \
|
||||
io-gdip-wmf.c
|
||||
libpixbufloader_gdip_wmf_la_LIBADD = $(module_libs) $(libole32)
|
||||
|
||||
libpixbufloader_gdip_emf_la_LDFLAGS = -avoid-version -module -no-undefined
|
||||
libpixbufloader_gdip_emf_la_SOURCES = \
|
||||
io-gdip-native.h \
|
||||
io-gdip-propertytags.h \
|
||||
io-gdip-utils.h \
|
||||
io-gdip-utils.c \
|
||||
io-gdip-animation.c \
|
||||
io-gdip-animation.h \
|
||||
io-gdip-emf.c
|
||||
libpixbufloader_gdip_emf_la_LIBADD = $(module_libs) $(libole32)
|
||||
|
||||
libpixbufloader_gdip_bmp_la_LDFLAGS = -avoid-version -module -no-undefined
|
||||
libpixbufloader_gdip_bmp_la_SOURCES = \
|
||||
io-gdip-native.h \
|
||||
io-gdip-propertytags.h \
|
||||
io-gdip-utils.h \
|
||||
io-gdip-utils.c \
|
||||
io-gdip-animation.c \
|
||||
io-gdip-animation.h \
|
||||
io-gdip-bmp.c
|
||||
libpixbufloader_gdip_bmp_la_LIBADD = $(module_libs) $(libole32)
|
||||
|
||||
libpixbufloader_gdip_gif_la_LDFLAGS = -avoid-version -module -no-undefined
|
||||
libpixbufloader_gdip_gif_la_SOURCES = \
|
||||
io-gdip-native.h \
|
||||
io-gdip-propertytags.h \
|
||||
io-gdip-utils.h \
|
||||
io-gdip-utils.c \
|
||||
io-gdip-animation.c \
|
||||
io-gdip-animation.h \
|
||||
io-gdip-gif.c
|
||||
libpixbufloader_gdip_gif_la_LIBADD = $(module_libs) $(libole32)
|
||||
|
||||
libpixbufloader_gdip_jpeg_la_LDFLAGS = -avoid-version -module -no-undefined
|
||||
libpixbufloader_gdip_jpeg_la_SOURCES = \
|
||||
io-gdip-native.h \
|
||||
io-gdip-propertytags.h \
|
||||
io-gdip-utils.h \
|
||||
io-gdip-utils.c \
|
||||
io-gdip-animation.c \
|
||||
io-gdip-animation.h \
|
||||
io-gdip-jpeg.c
|
||||
libpixbufloader_gdip_jpeg_la_LIBADD = $(module_libs) $(libole32)
|
||||
|
||||
libpixbufloader_gdip_tiff_la_LDFLAGS = -avoid-version -module -no-undefined
|
||||
libpixbufloader_gdip_tiff_la_SOURCES = \
|
||||
io-gdip-native.h \
|
||||
io-gdip-propertytags.h \
|
||||
io-gdip-utils.h \
|
||||
io-gdip-utils.c \
|
||||
io-gdip-animation.c \
|
||||
io-gdip-animation.h \
|
||||
io-gdip-tiff.c
|
||||
libpixbufloader_gdip_tiff_la_LIBADD = $(module_libs) $(libole32)
|
||||
|
||||
endif
|
||||
|
||||
else
|
||||
|
||||
# Loaders that aren't built if we build the GDI+ loader
|
||||
|
||||
if INCLUDE_BMP
|
||||
STATIC_BMP_LIB = libstatic-pixbufloader-bmp.la
|
||||
else
|
||||
BMP_LIB = libpixbufloader-bmp.la
|
||||
endif
|
||||
|
||||
if INCLUDE_GIF
|
||||
STATIC_GIF_LIB = libstatic-pixbufloader-gif.la
|
||||
else
|
||||
GIF_LIB = libpixbufloader-gif.la
|
||||
endif
|
||||
|
||||
if INCLUDE_ICO
|
||||
STATIC_ICO_LIB = libstatic-pixbufloader-ico.la
|
||||
else
|
||||
ICO_LIB = libpixbufloader-ico.la
|
||||
endif
|
||||
|
||||
if HAVE_JPEG
|
||||
if INCLUDE_JPEG
|
||||
STATIC_JPEG_LIB = libstatic-pixbufloader-jpeg.la
|
||||
else
|
||||
JPEG_LIB = libpixbufloader-jpeg.la
|
||||
endif
|
||||
endif
|
||||
|
||||
if HAVE_TIFF
|
||||
if INCLUDE_TIFF
|
||||
STATIC_TIFF_LIB = libstatic-pixbufloader-tiff.la
|
||||
else
|
||||
TIFF_LIB = libpixbufloader-tiff.la
|
||||
endif
|
||||
endif
|
||||
|
||||
# End of loaders not built if building GDI+ loader
|
||||
endif
|
||||
|
||||
if HAVE_PNG
|
||||
if INCLUDE_PNG
|
||||
STATIC_PNG_LIB = libstatic-pixbufloader-png.la
|
||||
else
|
||||
PNG_LIB = libpixbufloader-png.la
|
||||
endif
|
||||
endif
|
||||
|
||||
if INCLUDE_WBMP
|
||||
STATIC_WBMP_LIB = libstatic-pixbufloader-wbmp.la
|
||||
else
|
||||
WBMP_LIB = libpixbufloader-wbmp.la
|
||||
endif
|
||||
|
||||
if INCLUDE_ANI
|
||||
STATIC_ANI_LIB = libstatic-pixbufloader-ani.la
|
||||
else
|
||||
ANI_LIB = libpixbufloader-ani.la
|
||||
endif
|
||||
|
||||
if INCLUDE_PNM
|
||||
STATIC_PNM_LIB = libstatic-pixbufloader-pnm.la
|
||||
else
|
||||
PNM_LIB = libpixbufloader-pnm.la
|
||||
endif
|
||||
|
||||
if INCLUDE_RAS
|
||||
STATIC_RAS_LIB = libstatic-pixbufloader-ras.la
|
||||
else
|
||||
RAS_LIB = libpixbufloader-ras.la
|
||||
endif
|
||||
|
||||
if INCLUDE_XPM
|
||||
STATIC_XPM_LIB = libstatic-pixbufloader-xpm.la
|
||||
else
|
||||
XPM_LIB = libpixbufloader-xpm.la
|
||||
endif
|
||||
|
||||
if INCLUDE_XBM
|
||||
STATIC_XBM_LIB = libstatic-pixbufloader-xbm.la
|
||||
else
|
||||
XBM_LIB = libpixbufloader-xbm.la
|
||||
endif
|
||||
|
||||
if INCLUDE_TGA
|
||||
STATIC_TGA_LIB = libstatic-pixbufloader-tga.la
|
||||
else
|
||||
TGA_LIB = libpixbufloader-tga.la
|
||||
endif
|
||||
|
||||
if INCLUDE_PCX
|
||||
STATIC_PCX_LIB = libstatic-pixbufloader-pcx.la
|
||||
else
|
||||
PCX_LIB = libpixbufloader-pcx.la
|
||||
endif
|
||||
|
||||
if INCLUDE_ICNS
|
||||
STATIC_ICNS_LIB = libstatic-pixbufloader-icns.la
|
||||
else
|
||||
ICNS_LIB = libpixbufloader-icns.la
|
||||
endif
|
||||
|
||||
if HAVE_JASPER
|
||||
if INCLUDE_JASPER
|
||||
STATIC_JASPER_LIB = libstatic-pixbufloader-jasper.la
|
||||
else
|
||||
JASPER_LIB = libpixbufloader-jasper.la
|
||||
endif
|
||||
endif
|
||||
|
||||
if INCLUDE_QTIF
|
||||
STATIC_QTIF_LIB = libstatic-pixbufloader-qtif.la
|
||||
else
|
||||
QTIF_LIB = libpixbufloader-qtif.la
|
||||
endif
|
||||
|
||||
if BUILD_DYNAMIC_MODULES
|
||||
|
||||
loader_LTLIBRARIES = \
|
||||
$(PNG_LIB) \
|
||||
$(BMP_LIB) \
|
||||
$(WBMP_LIB) \
|
||||
$(GIF_LIB) \
|
||||
$(ICO_LIB) \
|
||||
$(ANI_LIB) \
|
||||
$(JPEG_LIB) \
|
||||
$(PNM_LIB) \
|
||||
$(RAS_LIB) \
|
||||
$(TIFF_LIB) \
|
||||
$(XPM_LIB) \
|
||||
$(XBM_LIB) \
|
||||
$(TGA_LIB) \
|
||||
$(ICNS_LIB) \
|
||||
$(PCX_LIB) \
|
||||
$(JASPER_LIB) \
|
||||
$(QTIF_LIB) \
|
||||
$(GDIPLUS_LIBS)
|
||||
|
||||
|
||||
endif
|
||||
|
||||
noinst_LTLIBRARIES = \
|
||||
$(STATIC_PNG_LIB) \
|
||||
$(STATIC_BMP_LIB) \
|
||||
$(STATIC_WBMP_LIB) \
|
||||
$(STATIC_GIF_LIB) \
|
||||
$(STATIC_ICO_LIB) \
|
||||
$(STATIC_ANI_LIB) \
|
||||
$(STATIC_JPEG_LIB) \
|
||||
$(STATIC_PNM_LIB) \
|
||||
$(STATIC_RAS_LIB) \
|
||||
$(STATIC_TIFF_LIB) \
|
||||
$(STATIC_XPM_LIB) \
|
||||
$(STATIC_XBM_LIB) \
|
||||
$(STATIC_TGA_LIB) \
|
||||
$(STATIC_ICNS_LIB) \
|
||||
$(STATIC_PCX_LIB) \
|
||||
$(STATIC_JASPER_LIB) \
|
||||
$(STATIC_QTIF_LIB) \
|
||||
$(STATIC_GDIPLUS_LIBS)
|
||||
|
||||
builtin_objs = @INCLUDED_LOADER_OBJ@
|
||||
|
||||
|
||||
DEPS = libgdk_pixbuf-$(GTK_API_VERSION).la
|
||||
INCLUDES = \
|
||||
-DG_LOG_DOMAIN=\"GdkPixbuf\" \
|
||||
-DGDK_PIXBUF_COMPILATION \
|
||||
-I$(top_srcdir) -I$(top_builddir) \
|
||||
-I$(top_srcdir)/gdk-pixbuf \
|
||||
-I$(top_builddir)/gdk-pixbuf \
|
||||
-DGTK_LIBDIR=\"$(libdir)\" \
|
||||
-DGTK_VERSION=\"$(GTK_VERSION)\" \
|
||||
-DGTK_BINARY_VERSION=\"$(GTK_BINARY_VERSION)\" \
|
||||
-DGTK_PREFIX=\"$(prefix)\" \
|
||||
$(INCLUDED_LOADER_DEFINE) \
|
||||
$(GTK_DEBUG_FLAGS) \
|
||||
$(GDK_PIXBUF_DEP_CFLAGS) \
|
||||
-DGDK_PIXBUF_ENABLE_BACKEND
|
||||
|
||||
AM_CPPFLAGS = "-DPIXBUF_LIBDIR=\"$(loaderdir)\"" "-DBUILT_MODULES_DIR=\"$(srcdir)/.libs\""
|
||||
LDADDS = libgdk_pixbuf-$(GTK_API_VERSION).la $(GDK_PIXBUF_DEP_LIBS)
|
||||
|
||||
noinst_PROGRAMS = test-gdk-pixbuf
|
||||
test_gdk_pixbuf_LDADD = $(LDADDS)
|
||||
|
||||
bin_PROGRAMS = gdk-pixbuf-csource-3.0 gdk-pixbuf-query-loaders-3.0
|
||||
gdk_pixbuf_csource_3_0_SOURCES = gdk-pixbuf-csource.c
|
||||
gdk_pixbuf_csource_3_0_LDADD = $(LDADDS)
|
||||
|
||||
gdk_pixbuf_query_loaders_3_0_DEPENDENCIES = $(DEPS)
|
||||
gdk_pixbuf_query_loaders_3_0_LDADD = $(LDADDS)
|
||||
|
||||
gdk_pixbuf_query_loaders_3_0_SOURCES = queryloaders.c
|
||||
|
||||
|
||||
#
|
||||
# The GdkPixBuf library
|
||||
#
|
||||
libgdk_pixbufincludedir = $(includedir)/gtk-3.0/gdk-pixbuf
|
||||
libgdk_pixbuf_3_0_la_SOURCES = \
|
||||
gdk-pixbuf-i18n.h \
|
||||
gdk-pixbuf.c \
|
||||
gdk-pixbuf-animation.c \
|
||||
gdk-pixbuf-data.c \
|
||||
gdk-pixbuf-io.c \
|
||||
gdk-pixbuf-loader.c \
|
||||
gdk-pixbuf-scale.c \
|
||||
gdk-pixbuf-simple-anim.c \
|
||||
gdk-pixbuf-scaled-anim.c \
|
||||
gdk-pixbuf-util.c \
|
||||
gdk-pixdata.c \
|
||||
gdk-pixbuf-enum-types.c
|
||||
|
||||
libgdk_pixbuf_3_0_la_LDFLAGS = \
|
||||
$(gdk_pixbuf_win32_res_ldflag) \
|
||||
-version-info $(LT_VERSION_INFO) \
|
||||
$(LIBTOOL_EXPORT_OPTIONS) \
|
||||
$(no_undefined) \
|
||||
$(gdk_pixbuf_symbols)
|
||||
|
||||
|
||||
libgdk_pixbuf_3_0_la_LIBADD = pixops/libpixops.la $(builtin_objs) $(GDK_PIXBUF_DEP_LIBS) $(libole32)
|
||||
libgdk_pixbuf_3_0_la_DEPENDENCIES = pixops/libpixops.la $(builtin_objs) $(gdk_pixbuf_def) $(gdk_pixbuf_win32_res)
|
||||
|
||||
gdk_pixbuf_headers = \
|
||||
gdk-pixbuf.h \
|
||||
gdk-pixbuf-core.h \
|
||||
gdk-pixbuf-transform.h \
|
||||
gdk-pixbuf-io.h \
|
||||
gdk-pixbuf-animation.h \
|
||||
gdk-pixbuf-simple-anim.h \
|
||||
gdk-pixbuf-loader.h
|
||||
|
||||
libgdk_pixbufinclude_HEADERS = \
|
||||
$(gdk_pixbuf_headers) \
|
||||
gdk-pixbuf-enum-types.h \
|
||||
gdk-pixbuf-marshal.h \
|
||||
gdk-pixbuf-features.h \
|
||||
gdk-pixdata.h
|
||||
|
||||
noinst_HEADERS = \
|
||||
gdk-pixbuf-alias.h \
|
||||
gdk-pixbuf-private.h \
|
||||
gdk-pixbuf-scaled-anim.h \
|
||||
xpm-color-table.h
|
||||
|
||||
BUILT_SOURCES = \
|
||||
gdk-pixbuf-alias.h \
|
||||
gdk-pixbuf-aliasdef.c \
|
||||
gdk-pixbuf-enum-types.h \
|
||||
gdk-pixbuf-enum-types.c \
|
||||
gdk-pixbuf-marshal.h \
|
||||
gdk-pixbuf-marshal.c \
|
||||
gdk-pixbuf-features.h
|
||||
|
||||
CLEANFILES =
|
||||
MAINTAINERCLEANFILES = \
|
||||
gdk-pixbuf-aliasdef.c \
|
||||
gdk-pixbuf-enum-types.h \
|
||||
gdk-pixbuf-enum-types.c \
|
||||
gdk-pixbuf-marshal.h \
|
||||
gdk-pixbuf-marshal.c \
|
||||
loaders.cache
|
||||
|
||||
#
|
||||
# gdk-pixbuf-enum-types.h
|
||||
#
|
||||
gdk-pixbuf-enum-types.h: s-enum-types-h
|
||||
@true
|
||||
|
||||
s-enum-types-h: @REBUILD@ $(gdk_pixbuf_headers) gdk-pixbuf-enum-types.h.template
|
||||
( cd $(srcdir) && $(GLIB_MKENUMS) --template gdk-pixbuf-enum-types.h.template \
|
||||
$(gdk_pixbuf_headers) ) > tmp-gdk-pixbuf-enum-types.h \
|
||||
&& (cmp -s tmp-gdk-pixbuf-enum-types.h gdk-pixbuf-enum-types.h || cp tmp-gdk-pixbuf-enum-types.h gdk-pixbuf-enum-types.h ) \
|
||||
&& rm -f tmp-gdk-pixbuf-enum-types.h \
|
||||
&& echo timestamp > $(@F)
|
||||
|
||||
CLEANFILES += tmp-gdk-pixbuf-enum-types.h
|
||||
MAINTAINERCLEANFILES += s-enum-types-h
|
||||
|
||||
#
|
||||
# gdk-pixbuf-enum-types.c
|
||||
#
|
||||
gdk-pixbuf-enum-types.c: @REBUILD@ $(gdk_pixbuf_headers) gdk-pixbuf-enum-types.c.template
|
||||
(cd $(srcdir) && $(GLIB_MKENUMS) --template gdk-pixbuf-enum-types.c.template \
|
||||
$(gdk_pixbuf_headers)) > gdk-pixbuf-enum-types.c
|
||||
|
||||
#
|
||||
# gdk-pixbuf-marshal.h
|
||||
#
|
||||
gdk-pixbuf-marshal.h: @REBUILD@ stamp-gdk-pixbuf-marshal.h
|
||||
@true
|
||||
|
||||
stamp-gdk-pixbuf-marshal.h: @REBUILD@ $(srcdir)/gdk-pixbuf-marshal.list
|
||||
echo "#if !defined(GDK_PIXBUF_DISABLE_DEPRECATED) || defined(GDK_PIXBUF_COMPILATION)" > xgen-gmh \
|
||||
&& $(GLIB_GENMARSHAL) --prefix=_gdk_pixbuf_marshal $(srcdir)/gdk-pixbuf-marshal.list --header >> xgen-gmh \
|
||||
&& echo "#endif /* !GDK_PIXBUF_DISABLE_DEPRECATED || GDK_PIXBUF_COMPILATION */" >> xgen-gmh \
|
||||
&& (cmp -s xgen-gmh gdk-pixbuf-marshal.h || cp xgen-gmh gdk-pixbuf-marshal.h) \
|
||||
&& rm -f xgen-gmh xgen-gmh~ \
|
||||
&& echo timestamp > $(@F)
|
||||
|
||||
CLEANFILES += xgen-gmh
|
||||
MAINTAINERCLEANFILES += stamp-gdk-pixbuf-marshal.h
|
||||
|
||||
#
|
||||
# gdk-pixbuf-marshal.c
|
||||
#
|
||||
$(srcdir)/gdk-pixbuf-marshal.c: @REBUILD@ $(srcdir)/gdk-pixbuf-marshal.list
|
||||
(echo -e "#include <gdk-pixbuf/gdk-pixbuf.h>\n#include \"gdk-pixbuf-alias.h\"" | $(GLIB_GENMARSHAL) --prefix=_gdk_pixbuf_marshal $(srcdir)/gdk-pixbuf-marshal.list --body ) >> xgen-gmc \
|
||||
&& cp xgen-gmc gdk-pixbuf-marshal.c \
|
||||
&& rm -f xgen-gmc xgen-gmc~
|
||||
|
||||
CLEANFILES += xgen-gmc
|
||||
|
||||
# if srcdir!=builddir, clean out maintainer-clean files from builddir
|
||||
# this allows dist to pass.
|
||||
distclean-local:
|
||||
if test $(srcdir) != .; then \
|
||||
rm -f $(MAINTAINERCLEANFILES); \
|
||||
fi
|
||||
|
||||
EXTRA_DIST += \
|
||||
gdk-pixbuf-csource.1 \
|
||||
makefile.msc \
|
||||
gdk-pixbuf.symbols \
|
||||
makegdkpixbufalias.pl \
|
||||
abicheck.sh \
|
||||
pltcheck.sh \
|
||||
gdk_pixbuf.def \
|
||||
gdk_pixbuf.rc \
|
||||
gdk-pixbuf-marshal.c \
|
||||
gdk-pixbuf-marshal.list \
|
||||
gdk-pixbuf-enum-types.c.template \
|
||||
gdk-pixbuf-enum-types.h.template \
|
||||
gen-color-table.pl
|
||||
|
||||
if HAVE_INTROSPECTION
|
||||
|
||||
GdkPixbuf-3.0.gir: libgdk_pixbuf-3.0.la Makefile
|
||||
GdkPixbuf_3_0_gir_SCANNERFLAGS = --strip-prefix=Gdk
|
||||
GdkPixbuf_3_0_gir_INCLUDES = GModule-2.0 Gio-2.0
|
||||
GdkPixbuf_3_0_gir_LIBS = libgdk_pixbuf-3.0.la
|
||||
GdkPixbuf_3_0_gir_CFLAGS = $(INCLUDES)
|
||||
GdkPixbuf_3_0_gir_FILES = \
|
||||
$(addprefix $(srcdir)/,$(libgdk_pixbufinclude_HEADERS)) \
|
||||
$(addprefix $(srcdir)/,$(libgdk_pixbuf_3_0_la_SOURCES))
|
||||
INTROSPECTION_GIRS += GdkPixbuf-3.0.gir
|
||||
|
||||
girdir = $(datadir)/gir-1.0
|
||||
dist_gir_DATA = $(INTROSPECTION_GIRS)
|
||||
|
||||
typelibsdir = $(libdir)/girepository-1.0
|
||||
typelibs_DATA = $(INTROSPECTION_GIRS:.gir=.typelib)
|
||||
|
||||
CLEANFILES += $(dist_gir_DATA) $(typelibs_DATA)
|
||||
endif
|
||||
|
||||
if CROSS_COMPILING
|
||||
RUN_QUERY_LOADER_TEST=false
|
||||
else
|
||||
RUN_QUERY_LOADER_TEST=test -z "$(DESTDIR)"
|
||||
endif
|
||||
|
||||
# Running this if cross compiling or if DESTDIR is set is going to
|
||||
# not work at all, so skip it
|
||||
# We use install-data-hook here to workaround a bug in automake and/or libtool
|
||||
# that makes the install target for the loader libraries a dependency on
|
||||
# install-data-am, and not install-exec-am. We need to ensure this gets run
|
||||
# after the libraries are installed in their final locations.
|
||||
install-data-hook: install-ms-lib install-def-file
|
||||
@if $(RUN_QUERY_LOADER_TEST) ; then \
|
||||
$(mkinstalldirs) $(DESTDIR)$(libdir)/gtk-3.0/3.0.0 ; \
|
||||
$(top_builddir)/gdk-pixbuf/gdk-pixbuf-query-loaders-3.0 > $(DESTDIR)$(libdir)/gtk-3.0/3.0.0/loaders.cache ; \
|
||||
else \
|
||||
echo "***" ; \
|
||||
echo "*** Warning: loaders.cache not built" ; \
|
||||
echo "***" ; \
|
||||
echo "*** Generate this file manually on host" ; \
|
||||
echo "*** system using gdk-pixbuf-query-loaders-3.0" ; \
|
||||
echo "***" ; \
|
||||
fi
|
||||
|
||||
uninstall-local: uninstall-ms-lib uninstall-def-file
|
||||
rm -f $(DESTDIR)$(libdir)/gtk-3.0/3.0.0/loaders.cache
|
||||
|
||||
if CROSS_COMPILING
|
||||
else
|
||||
all-local: loaders.cache
|
||||
endif
|
||||
|
||||
if BUILD_DYNAMIC_MODULES
|
||||
loaders.cache: $(loader_LTLIBRARIES) gdk-pixbuf-query-loaders-3.0$(EXEEXT)
|
||||
LOADERS=`echo libpixbufloader-*.la` ; \
|
||||
if test "x$$LOADERS" != 'xlibpixbufloader-*.la' ; then \
|
||||
echo "Writing a loaders.cache file to use when running examples before installing gdk-pixbuf."; \
|
||||
$(top_builddir)/gdk-pixbuf/gdk-pixbuf-query-loaders-3.0 $$LOADERS > ./loaders.cache ;\
|
||||
else \
|
||||
echo "No dynamic modules found; will use only static modules for uninstalled example programs."; \
|
||||
touch loaders.cache; \
|
||||
fi
|
||||
else
|
||||
loaders.cache:
|
||||
echo "No dynamic modules found; will use only static modules for uninstalled example programs."; \
|
||||
touch loaders.cache;
|
||||
endif
|
||||
|
||||
-include $(top_srcdir)/git.mk
|
||||
@@ -1,5 +0,0 @@
|
||||
#! /bin/sh
|
||||
|
||||
cpp -DINCLUDE_VARIABLES -P -DALL_FILES ${srcdir:-.}/gdk-pixbuf.symbols | sed -e '/^$/d' -e 's/ G_GNUC.*$//' -e 's/ PRIVATE$//' | sort > expected-abi
|
||||
nm -D -g --defined-only .libs/libgdk_pixbuf-3.0.so | cut -d ' ' -f 3 | egrep -v '^(__bss_start|_edata|_end)' | sort > actual-abi
|
||||
diff -u expected-abi actual-abi && rm -f expected-abi actual-abi
|
||||
@@ -1,704 +0,0 @@
|
||||
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- */
|
||||
/* GdkPixbuf library - Simple animation support
|
||||
*
|
||||
* Copyright (C) 1999 The Free Software Foundation
|
||||
*
|
||||
* Authors: Jonathan Blandford <jrb@redhat.com>
|
||||
* Havoc Pennington <hp@redhat.com>
|
||||
*
|
||||
* This library is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU Lesser General Public
|
||||
* License as published by the Free Software Foundation; either
|
||||
* version 2 of the License, or (at your option) any later version.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* Lesser General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU Lesser General Public
|
||||
* License along with this library; if not, write to the
|
||||
* Free Software Foundation, Inc., 59 Temple Place - Suite 330,
|
||||
* Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
|
||||
#include "config.h"
|
||||
#include <errno.h>
|
||||
#include "gdk-pixbuf-private.h"
|
||||
#include "gdk-pixbuf-io.h"
|
||||
#include "gdk-pixbuf-i18n.h"
|
||||
#include "gdk-pixbuf-animation.h"
|
||||
#include "gdk-pixbuf-alias.h"
|
||||
|
||||
#include <glib/gstdio.h>
|
||||
|
||||
typedef struct _GdkPixbufNonAnim GdkPixbufNonAnim;
|
||||
typedef struct _GdkPixbufNonAnimClass GdkPixbufNonAnimClass;
|
||||
|
||||
#define GDK_TYPE_PIXBUF_NON_ANIM (gdk_pixbuf_non_anim_get_type ())
|
||||
#define GDK_PIXBUF_NON_ANIM(object) (G_TYPE_CHECK_INSTANCE_CAST ((object), GDK_TYPE_PIXBUF_NON_ANIM, GdkPixbufNonAnim))
|
||||
#define GDK_IS_PIXBUF_NON_ANIM(object) (G_TYPE_CHECK_INSTANCE_TYPE ((object), GDK_TYPE_PIXBUF_NON_ANIM))
|
||||
|
||||
#define GDK_PIXBUF_NON_ANIM_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GDK_TYPE_PIXBUF_NON_ANIM, GdkPixbufNonAnimClass))
|
||||
#define GDK_IS_PIXBUF_NON_ANIM_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GDK_TYPE_PIXBUF_NON_ANIM))
|
||||
#define GDK_PIXBUF_NON_ANIM_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GDK_TYPE_PIXBUF_NON_ANIM, GdkPixbufNonAnimClass))
|
||||
|
||||
/* Private part of the GdkPixbufNonAnim structure */
|
||||
struct _GdkPixbufNonAnim {
|
||||
GdkPixbufAnimation parent_instance;
|
||||
|
||||
GdkPixbuf *pixbuf;
|
||||
};
|
||||
|
||||
struct _GdkPixbufNonAnimClass {
|
||||
GdkPixbufAnimationClass parent_class;
|
||||
|
||||
};
|
||||
|
||||
|
||||
typedef struct _GdkPixbufNonAnimIter GdkPixbufNonAnimIter;
|
||||
typedef struct _GdkPixbufNonAnimIterClass GdkPixbufNonAnimIterClass;
|
||||
|
||||
|
||||
#define GDK_TYPE_PIXBUF_NON_ANIM_ITER (gdk_pixbuf_non_anim_iter_get_type ())
|
||||
#define GDK_PIXBUF_NON_ANIM_ITER(object) (G_TYPE_CHECK_INSTANCE_CAST ((object), GDK_TYPE_PIXBUF_NON_ANIM_ITER, GdkPixbufNonAnimIter))
|
||||
#define GDK_IS_PIXBUF_NON_ANIM_ITER(object) (G_TYPE_CHECK_INSTANCE_TYPE ((object), GDK_TYPE_PIXBUF_NON_ANIM_ITER))
|
||||
|
||||
#define GDK_PIXBUF_NON_ANIM_ITER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GDK_TYPE_PIXBUF_NON_ANIM_ITER, GdkPixbufNonAnimIterClass))
|
||||
#define GDK_IS_PIXBUF_NON_ANIM_ITER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GDK_TYPE_PIXBUF_NON_ANIM_ITER))
|
||||
#define GDK_PIXBUF_NON_ANIM_ITER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GDK_TYPE_PIXBUF_NON_ANIM_ITER, GdkPixbufNonAnimIterClass))
|
||||
|
||||
struct _GdkPixbufNonAnimIter {
|
||||
GdkPixbufAnimationIter parent_instance;
|
||||
|
||||
GdkPixbufNonAnim *non_anim;
|
||||
};
|
||||
|
||||
struct _GdkPixbufNonAnimIterClass {
|
||||
GdkPixbufAnimationIterClass parent_class;
|
||||
|
||||
};
|
||||
|
||||
static GType gdk_pixbuf_non_anim_iter_get_type (void) G_GNUC_CONST;
|
||||
|
||||
G_DEFINE_TYPE (GdkPixbufAnimation, gdk_pixbuf_animation, G_TYPE_OBJECT);
|
||||
|
||||
static void
|
||||
gdk_pixbuf_animation_class_init (GdkPixbufAnimationClass *klass)
|
||||
{
|
||||
}
|
||||
|
||||
static void
|
||||
gdk_pixbuf_animation_init (GdkPixbufAnimation *animation)
|
||||
{
|
||||
}
|
||||
|
||||
/**
|
||||
* gdk_pixbuf_animation_new_from_file:
|
||||
* @filename: Name of file to load, in the GLib file name encoding
|
||||
* @error: return location for error
|
||||
*
|
||||
* Creates a new animation by loading it from a file. The file format is
|
||||
* detected automatically. If the file's format does not support multi-frame
|
||||
* images, then an animation with a single frame will be created. Possible errors
|
||||
* are in the #GDK_PIXBUF_ERROR and #G_FILE_ERROR domains.
|
||||
*
|
||||
* Return value: A newly-created animation with a reference count of 1, or %NULL
|
||||
* if any of several error conditions ocurred: the file could not be opened,
|
||||
* there was no loader for the file's format, there was not enough memory to
|
||||
* allocate the image buffer, or the image file contained invalid data.
|
||||
**/
|
||||
GdkPixbufAnimation *
|
||||
gdk_pixbuf_animation_new_from_file (const char *filename,
|
||||
GError **error)
|
||||
{
|
||||
GdkPixbufAnimation *animation;
|
||||
int size;
|
||||
FILE *f;
|
||||
guchar buffer [1024];
|
||||
GdkPixbufModule *image_module;
|
||||
gchar *display_name;
|
||||
gboolean locked = FALSE;
|
||||
|
||||
g_return_val_if_fail (filename != NULL, NULL);
|
||||
g_return_val_if_fail (error == NULL || *error == NULL, NULL);
|
||||
|
||||
display_name = g_filename_display_name (filename);
|
||||
f = g_fopen (filename, "rb");
|
||||
if (!f) {
|
||||
gint save_errno = errno;
|
||||
g_set_error (error,
|
||||
G_FILE_ERROR,
|
||||
g_file_error_from_errno (save_errno),
|
||||
_("Failed to open file '%s': %s"),
|
||||
display_name,
|
||||
g_strerror (save_errno));
|
||||
g_free (display_name);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
size = fread (&buffer, 1, sizeof (buffer), f);
|
||||
|
||||
if (size == 0) {
|
||||
g_set_error (error,
|
||||
GDK_PIXBUF_ERROR,
|
||||
GDK_PIXBUF_ERROR_CORRUPT_IMAGE,
|
||||
_("Image file '%s' contains no data"),
|
||||
display_name);
|
||||
g_free (display_name);
|
||||
fclose (f);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
image_module = _gdk_pixbuf_get_module (buffer, size, filename, error);
|
||||
if (!image_module) {
|
||||
g_free (display_name);
|
||||
fclose (f);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
if (image_module->module == NULL)
|
||||
if (!_gdk_pixbuf_load_module (image_module, error)) {
|
||||
g_free (display_name);
|
||||
fclose (f);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
if (image_module->load_animation == NULL) {
|
||||
GdkPixbuf *pixbuf;
|
||||
|
||||
/* Keep this logic in sync with gdk_pixbuf_new_from_file() */
|
||||
|
||||
fseek (f, 0, SEEK_SET);
|
||||
pixbuf = _gdk_pixbuf_generic_image_load (image_module, f, error);
|
||||
fclose (f);
|
||||
|
||||
if (pixbuf == NULL && error != NULL && *error == NULL) {
|
||||
/* I don't trust these crufty longjmp()'ing image libs
|
||||
* to maintain proper error invariants, and I don't
|
||||
* want user code to segfault as a result. We need to maintain
|
||||
* the invariant that error gets set if NULL is returned.
|
||||
*/
|
||||
|
||||
g_warning ("Bug! gdk-pixbuf loader '%s' didn't set an error on failure.",
|
||||
image_module->module_name);
|
||||
g_set_error (error,
|
||||
GDK_PIXBUF_ERROR,
|
||||
GDK_PIXBUF_ERROR_FAILED,
|
||||
_("Failed to load image '%s': reason not known, probably a corrupt image file"),
|
||||
display_name);
|
||||
}
|
||||
|
||||
if (pixbuf == NULL) {
|
||||
g_free (display_name);
|
||||
animation = NULL;
|
||||
goto out_unlock;
|
||||
}
|
||||
|
||||
animation = gdk_pixbuf_non_anim_new (pixbuf);
|
||||
|
||||
g_object_unref (pixbuf);
|
||||
} else {
|
||||
locked = _gdk_pixbuf_lock (image_module);
|
||||
|
||||
fseek (f, 0, SEEK_SET);
|
||||
animation = (* image_module->load_animation) (f, error);
|
||||
|
||||
if (animation == NULL && error != NULL && *error == NULL) {
|
||||
/* I don't trust these crufty longjmp()'ing
|
||||
* image libs to maintain proper error
|
||||
* invariants, and I don't want user code to
|
||||
* segfault as a result. We need to maintain
|
||||
* the invariant that error gets set if NULL
|
||||
* is returned.
|
||||
*/
|
||||
|
||||
g_warning ("Bug! gdk-pixbuf loader '%s' didn't set an error on failure.",
|
||||
image_module->module_name);
|
||||
g_set_error (error,
|
||||
GDK_PIXBUF_ERROR,
|
||||
GDK_PIXBUF_ERROR_FAILED,
|
||||
_("Failed to load animation '%s': reason not known, probably a corrupt animation file"),
|
||||
display_name);
|
||||
}
|
||||
|
||||
fclose (f);
|
||||
}
|
||||
|
||||
g_free (display_name);
|
||||
|
||||
out_unlock:
|
||||
if (locked)
|
||||
_gdk_pixbuf_unlock (image_module);
|
||||
return animation;
|
||||
}
|
||||
|
||||
#ifdef G_OS_WIN32
|
||||
|
||||
#undef gdk_pixbuf_animation_new_from_file
|
||||
|
||||
GdkPixbufAnimation *
|
||||
gdk_pixbuf_animation_new_from_file (const char *filename,
|
||||
GError **error)
|
||||
{
|
||||
gchar *utf8_filename =
|
||||
g_locale_to_utf8 (filename, -1, NULL, NULL, error);
|
||||
GdkPixbufAnimation *retval;
|
||||
|
||||
if (utf8_filename == NULL)
|
||||
return NULL;
|
||||
|
||||
retval = gdk_pixbuf_animation_new_from_file_utf8 (utf8_filename, error);
|
||||
|
||||
g_free (utf8_filename);
|
||||
|
||||
return retval;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
/**
|
||||
* gdk_pixbuf_animation_is_static_image:
|
||||
* @animation: a #GdkPixbufAnimation
|
||||
*
|
||||
* If you load a file with gdk_pixbuf_animation_new_from_file() and it turns
|
||||
* out to be a plain, unanimated image, then this function will return
|
||||
* %TRUE. Use gdk_pixbuf_animation_get_static_image() to retrieve
|
||||
* the image.
|
||||
*
|
||||
* Return value: %TRUE if the "animation" was really just an image
|
||||
**/
|
||||
gboolean
|
||||
gdk_pixbuf_animation_is_static_image (GdkPixbufAnimation *animation)
|
||||
{
|
||||
g_return_val_if_fail (GDK_IS_PIXBUF_ANIMATION (animation), FALSE);
|
||||
|
||||
return GDK_PIXBUF_ANIMATION_GET_CLASS (animation)->is_static_image (animation);
|
||||
}
|
||||
|
||||
/**
|
||||
* gdk_pixbuf_animation_get_static_image:
|
||||
* @animation: a #GdkPixbufAnimation
|
||||
*
|
||||
* If an animation is really just a plain image (has only one frame),
|
||||
* this function returns that image. If the animation is an animation,
|
||||
* this function returns a reasonable thing to display as a static
|
||||
* unanimated image, which might be the first frame, or something more
|
||||
* sophisticated. If an animation hasn't loaded any frames yet, this
|
||||
* function will return %NULL.
|
||||
*
|
||||
* Return value: unanimated image representing the animation
|
||||
**/
|
||||
GdkPixbuf*
|
||||
gdk_pixbuf_animation_get_static_image (GdkPixbufAnimation *animation)
|
||||
{
|
||||
g_return_val_if_fail (GDK_IS_PIXBUF_ANIMATION (animation), NULL);
|
||||
|
||||
return GDK_PIXBUF_ANIMATION_GET_CLASS (animation)->get_static_image (animation);
|
||||
}
|
||||
|
||||
/**
|
||||
* gdk_pixbuf_animation_get_width:
|
||||
* @animation: An animation.
|
||||
*
|
||||
* Queries the width of the bounding box of a pixbuf animation.
|
||||
*
|
||||
* Return value: Width of the bounding box of the animation.
|
||||
**/
|
||||
int
|
||||
gdk_pixbuf_animation_get_width (GdkPixbufAnimation *animation)
|
||||
{
|
||||
int width;
|
||||
|
||||
g_return_val_if_fail (GDK_IS_PIXBUF_ANIMATION (animation), 0);
|
||||
|
||||
width = 0;
|
||||
GDK_PIXBUF_ANIMATION_GET_CLASS (animation)->get_size (animation,
|
||||
&width, NULL);
|
||||
|
||||
|
||||
return width;
|
||||
}
|
||||
|
||||
/**
|
||||
* gdk_pixbuf_animation_get_height:
|
||||
* @animation: An animation.
|
||||
*
|
||||
* Queries the height of the bounding box of a pixbuf animation.
|
||||
*
|
||||
* Return value: Height of the bounding box of the animation.
|
||||
**/
|
||||
int
|
||||
gdk_pixbuf_animation_get_height (GdkPixbufAnimation *animation)
|
||||
{
|
||||
int height;
|
||||
|
||||
g_return_val_if_fail (GDK_IS_PIXBUF_ANIMATION (animation), 0);
|
||||
|
||||
height = 0;
|
||||
GDK_PIXBUF_ANIMATION_GET_CLASS (animation)->get_size (animation,
|
||||
NULL, &height);
|
||||
|
||||
|
||||
return height;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* gdk_pixbuf_animation_get_iter:
|
||||
* @animation: a #GdkPixbufAnimation
|
||||
* @start_time: time when the animation starts playing
|
||||
*
|
||||
* Get an iterator for displaying an animation. The iterator provides
|
||||
* the frames that should be displayed at a given time.
|
||||
* It should be freed after use with g_object_unref().
|
||||
*
|
||||
* @start_time would normally come from g_get_current_time(), and
|
||||
* marks the beginning of animation playback. After creating an
|
||||
* iterator, you should immediately display the pixbuf returned by
|
||||
* gdk_pixbuf_animation_iter_get_pixbuf(). Then, you should install a
|
||||
* timeout (with g_timeout_add()) or by some other mechanism ensure
|
||||
* that you'll update the image after
|
||||
* gdk_pixbuf_animation_iter_get_delay_time() milliseconds. Each time
|
||||
* the image is updated, you should reinstall the timeout with the new,
|
||||
* possibly-changed delay time.
|
||||
*
|
||||
* As a shortcut, if @start_time is %NULL, the result of
|
||||
* g_get_current_time() will be used automatically.
|
||||
*
|
||||
* To update the image (i.e. possibly change the result of
|
||||
* gdk_pixbuf_animation_iter_get_pixbuf() to a new frame of the animation),
|
||||
* call gdk_pixbuf_animation_iter_advance().
|
||||
*
|
||||
* If you're using #GdkPixbufLoader, in addition to updating the image
|
||||
* after the delay time, you should also update it whenever you
|
||||
* receive the area_updated signal and
|
||||
* gdk_pixbuf_animation_iter_on_currently_loading_frame() returns
|
||||
* %TRUE. In this case, the frame currently being fed into the loader
|
||||
* has received new data, so needs to be refreshed. The delay time for
|
||||
* a frame may also be modified after an area_updated signal, for
|
||||
* example if the delay time for a frame is encoded in the data after
|
||||
* the frame itself. So your timeout should be reinstalled after any
|
||||
* area_updated signal.
|
||||
*
|
||||
* A delay time of -1 is possible, indicating "infinite."
|
||||
*
|
||||
* Return value: an iterator to move over the animation
|
||||
**/
|
||||
GdkPixbufAnimationIter*
|
||||
gdk_pixbuf_animation_get_iter (GdkPixbufAnimation *animation,
|
||||
const GTimeVal *start_time)
|
||||
{
|
||||
GTimeVal val;
|
||||
|
||||
g_return_val_if_fail (GDK_IS_PIXBUF_ANIMATION (animation), NULL);
|
||||
|
||||
|
||||
if (start_time)
|
||||
val = *start_time;
|
||||
else
|
||||
g_get_current_time (&val);
|
||||
|
||||
return GDK_PIXBUF_ANIMATION_GET_CLASS (animation)->get_iter (animation, &val);
|
||||
}
|
||||
|
||||
G_DEFINE_TYPE (GdkPixbufAnimationIter, gdk_pixbuf_animation_iter, G_TYPE_OBJECT);
|
||||
|
||||
static void
|
||||
gdk_pixbuf_animation_iter_class_init (GdkPixbufAnimationIterClass *klass)
|
||||
{
|
||||
}
|
||||
|
||||
static void
|
||||
gdk_pixbuf_animation_iter_init (GdkPixbufAnimationIter *iter)
|
||||
{
|
||||
}
|
||||
|
||||
/**
|
||||
* gdk_pixbuf_animation_iter_get_delay_time:
|
||||
* @iter: an animation iterator
|
||||
*
|
||||
* Gets the number of milliseconds the current pixbuf should be displayed,
|
||||
* or -1 if the current pixbuf should be displayed forever. g_timeout_add()
|
||||
* conveniently takes a timeout in milliseconds, so you can use a timeout
|
||||
* to schedule the next update.
|
||||
*
|
||||
* Return value: delay time in milliseconds (thousandths of a second)
|
||||
**/
|
||||
int
|
||||
gdk_pixbuf_animation_iter_get_delay_time (GdkPixbufAnimationIter *iter)
|
||||
{
|
||||
g_return_val_if_fail (GDK_IS_PIXBUF_ANIMATION_ITER (iter), -1);
|
||||
g_return_val_if_fail (GDK_PIXBUF_ANIMATION_ITER_GET_CLASS (iter)->get_delay_time, -1);
|
||||
|
||||
return GDK_PIXBUF_ANIMATION_ITER_GET_CLASS (iter)->get_delay_time (iter);
|
||||
}
|
||||
|
||||
/**
|
||||
* gdk_pixbuf_animation_iter_get_pixbuf:
|
||||
* @iter: an animation iterator
|
||||
*
|
||||
* Gets the current pixbuf which should be displayed; the pixbuf will
|
||||
* be the same size as the animation itself
|
||||
* (gdk_pixbuf_animation_get_width(), gdk_pixbuf_animation_get_height()).
|
||||
* This pixbuf should be displayed for
|
||||
* gdk_pixbuf_animation_iter_get_delay_time() milliseconds. The caller
|
||||
* of this function does not own a reference to the returned pixbuf;
|
||||
* the returned pixbuf will become invalid when the iterator advances
|
||||
* to the next frame, which may happen anytime you call
|
||||
* gdk_pixbuf_animation_iter_advance(). Copy the pixbuf to keep it
|
||||
* (don't just add a reference), as it may get recycled as you advance
|
||||
* the iterator.
|
||||
*
|
||||
* Return value: the pixbuf to be displayed
|
||||
**/
|
||||
GdkPixbuf*
|
||||
gdk_pixbuf_animation_iter_get_pixbuf (GdkPixbufAnimationIter *iter)
|
||||
{
|
||||
g_return_val_if_fail (GDK_IS_PIXBUF_ANIMATION_ITER (iter), NULL);
|
||||
g_return_val_if_fail (GDK_PIXBUF_ANIMATION_ITER_GET_CLASS (iter)->get_pixbuf, NULL);
|
||||
|
||||
return GDK_PIXBUF_ANIMATION_ITER_GET_CLASS (iter)->get_pixbuf (iter);
|
||||
}
|
||||
|
||||
/**
|
||||
* gdk_pixbuf_animation_iter_on_currently_loading_frame:
|
||||
* @iter: a #GdkPixbufAnimationIter
|
||||
*
|
||||
* Used to determine how to respond to the area_updated signal on
|
||||
* #GdkPixbufLoader when loading an animation. area_updated is emitted
|
||||
* for an area of the frame currently streaming in to the loader. So if
|
||||
* you're on the currently loading frame, you need to redraw the screen for
|
||||
* the updated area.
|
||||
*
|
||||
* Return value: %TRUE if the frame we're on is partially loaded, or the last frame
|
||||
**/
|
||||
gboolean
|
||||
gdk_pixbuf_animation_iter_on_currently_loading_frame (GdkPixbufAnimationIter *iter)
|
||||
{
|
||||
g_return_val_if_fail (GDK_IS_PIXBUF_ANIMATION_ITER (iter), FALSE);
|
||||
g_return_val_if_fail (GDK_PIXBUF_ANIMATION_ITER_GET_CLASS (iter)->on_currently_loading_frame, FALSE);
|
||||
|
||||
return GDK_PIXBUF_ANIMATION_ITER_GET_CLASS (iter)->on_currently_loading_frame (iter);
|
||||
}
|
||||
|
||||
/**
|
||||
* gdk_pixbuf_animation_iter_advance:
|
||||
* @iter: a #GdkPixbufAnimationIter
|
||||
* @current_time: current time
|
||||
*
|
||||
* Possibly advances an animation to a new frame. Chooses the frame based
|
||||
* on the start time passed to gdk_pixbuf_animation_get_iter().
|
||||
*
|
||||
* @current_time would normally come from g_get_current_time(), and
|
||||
* must be greater than or equal to the time passed to
|
||||
* gdk_pixbuf_animation_get_iter(), and must increase or remain
|
||||
* unchanged each time gdk_pixbuf_animation_iter_get_pixbuf() is
|
||||
* called. That is, you can't go backward in time; animations only
|
||||
* play forward.
|
||||
*
|
||||
* As a shortcut, pass %NULL for the current time and g_get_current_time()
|
||||
* will be invoked on your behalf. So you only need to explicitly pass
|
||||
* @current_time if you're doing something odd like playing the animation
|
||||
* at double speed.
|
||||
*
|
||||
* If this function returns %FALSE, there's no need to update the animation
|
||||
* display, assuming the display had been rendered prior to advancing;
|
||||
* if %TRUE, you need to call gdk_animation_iter_get_pixbuf() and update the
|
||||
* display with the new pixbuf.
|
||||
*
|
||||
* Returns: %TRUE if the image may need updating
|
||||
*
|
||||
**/
|
||||
gboolean
|
||||
gdk_pixbuf_animation_iter_advance (GdkPixbufAnimationIter *iter,
|
||||
const GTimeVal *current_time)
|
||||
{
|
||||
GTimeVal val;
|
||||
|
||||
g_return_val_if_fail (GDK_IS_PIXBUF_ANIMATION_ITER (iter), FALSE);
|
||||
g_return_val_if_fail (GDK_PIXBUF_ANIMATION_ITER_GET_CLASS (iter)->advance, FALSE);
|
||||
|
||||
if (current_time)
|
||||
val = *current_time;
|
||||
else
|
||||
g_get_current_time (&val);
|
||||
|
||||
return GDK_PIXBUF_ANIMATION_ITER_GET_CLASS (iter)->advance (iter, &val);
|
||||
}
|
||||
|
||||
static void gdk_pixbuf_non_anim_finalize (GObject *object);
|
||||
static gboolean gdk_pixbuf_non_anim_is_static_image (GdkPixbufAnimation *animation);
|
||||
static GdkPixbuf* gdk_pixbuf_non_anim_get_static_image (GdkPixbufAnimation *animation);
|
||||
static void gdk_pixbuf_non_anim_get_size (GdkPixbufAnimation *anim,
|
||||
int *width,
|
||||
int *height);
|
||||
static GdkPixbufAnimationIter* gdk_pixbuf_non_anim_get_iter (GdkPixbufAnimation *anim,
|
||||
const GTimeVal *start_time);
|
||||
|
||||
G_DEFINE_TYPE (GdkPixbufNonAnim, gdk_pixbuf_non_anim, GDK_TYPE_PIXBUF_ANIMATION);
|
||||
|
||||
static void
|
||||
gdk_pixbuf_non_anim_class_init (GdkPixbufNonAnimClass *klass)
|
||||
{
|
||||
GObjectClass *object_class = G_OBJECT_CLASS (klass);
|
||||
GdkPixbufAnimationClass *anim_class = GDK_PIXBUF_ANIMATION_CLASS (klass);
|
||||
|
||||
object_class->finalize = gdk_pixbuf_non_anim_finalize;
|
||||
|
||||
anim_class->is_static_image = gdk_pixbuf_non_anim_is_static_image;
|
||||
anim_class->get_static_image = gdk_pixbuf_non_anim_get_static_image;
|
||||
anim_class->get_size = gdk_pixbuf_non_anim_get_size;
|
||||
anim_class->get_iter = gdk_pixbuf_non_anim_get_iter;
|
||||
}
|
||||
|
||||
static void
|
||||
gdk_pixbuf_non_anim_init (GdkPixbufNonAnim *non_anim)
|
||||
{
|
||||
}
|
||||
|
||||
static void
|
||||
gdk_pixbuf_non_anim_finalize (GObject *object)
|
||||
{
|
||||
GdkPixbufNonAnim *non_anim = GDK_PIXBUF_NON_ANIM (object);
|
||||
|
||||
if (non_anim->pixbuf)
|
||||
g_object_unref (non_anim->pixbuf);
|
||||
|
||||
G_OBJECT_CLASS (gdk_pixbuf_non_anim_parent_class)->finalize (object);
|
||||
}
|
||||
|
||||
GdkPixbufAnimation*
|
||||
gdk_pixbuf_non_anim_new (GdkPixbuf *pixbuf)
|
||||
{
|
||||
GdkPixbufNonAnim *non_anim;
|
||||
|
||||
non_anim = g_object_new (GDK_TYPE_PIXBUF_NON_ANIM, NULL);
|
||||
|
||||
non_anim->pixbuf = pixbuf;
|
||||
|
||||
if (pixbuf)
|
||||
g_object_ref (pixbuf);
|
||||
|
||||
return GDK_PIXBUF_ANIMATION (non_anim);
|
||||
}
|
||||
|
||||
static gboolean
|
||||
gdk_pixbuf_non_anim_is_static_image (GdkPixbufAnimation *animation)
|
||||
{
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
static GdkPixbuf*
|
||||
gdk_pixbuf_non_anim_get_static_image (GdkPixbufAnimation *animation)
|
||||
{
|
||||
GdkPixbufNonAnim *non_anim;
|
||||
|
||||
non_anim = GDK_PIXBUF_NON_ANIM (animation);
|
||||
|
||||
return non_anim->pixbuf;
|
||||
}
|
||||
|
||||
static void
|
||||
gdk_pixbuf_non_anim_get_size (GdkPixbufAnimation *anim,
|
||||
int *width,
|
||||
int *height)
|
||||
{
|
||||
GdkPixbufNonAnim *non_anim;
|
||||
|
||||
non_anim = GDK_PIXBUF_NON_ANIM (anim);
|
||||
|
||||
if (width)
|
||||
*width = gdk_pixbuf_get_width (non_anim->pixbuf);
|
||||
|
||||
if (height)
|
||||
*height = gdk_pixbuf_get_height (non_anim->pixbuf);
|
||||
}
|
||||
|
||||
static GdkPixbufAnimationIter*
|
||||
gdk_pixbuf_non_anim_get_iter (GdkPixbufAnimation *anim,
|
||||
const GTimeVal *start_time)
|
||||
{
|
||||
GdkPixbufNonAnimIter *iter;
|
||||
|
||||
iter = g_object_new (GDK_TYPE_PIXBUF_NON_ANIM_ITER, NULL);
|
||||
|
||||
iter->non_anim = GDK_PIXBUF_NON_ANIM (anim);
|
||||
|
||||
g_object_ref (iter->non_anim);
|
||||
|
||||
return GDK_PIXBUF_ANIMATION_ITER (iter);
|
||||
}
|
||||
|
||||
static void gdk_pixbuf_non_anim_iter_finalize (GObject *object);
|
||||
static int gdk_pixbuf_non_anim_iter_get_delay_time (GdkPixbufAnimationIter *iter);
|
||||
static GdkPixbuf* gdk_pixbuf_non_anim_iter_get_pixbuf (GdkPixbufAnimationIter *iter);
|
||||
static gboolean gdk_pixbuf_non_anim_iter_on_currently_loading_frame (GdkPixbufAnimationIter *iter);
|
||||
static gboolean gdk_pixbuf_non_anim_iter_advance (GdkPixbufAnimationIter *iter,
|
||||
const GTimeVal *current_time);
|
||||
|
||||
G_DEFINE_TYPE (GdkPixbufNonAnimIter,
|
||||
gdk_pixbuf_non_anim_iter,
|
||||
GDK_TYPE_PIXBUF_ANIMATION_ITER);
|
||||
|
||||
static void
|
||||
gdk_pixbuf_non_anim_iter_class_init (GdkPixbufNonAnimIterClass *klass)
|
||||
{
|
||||
GObjectClass *object_class = G_OBJECT_CLASS (klass);
|
||||
GdkPixbufAnimationIterClass *anim_iter_class =
|
||||
GDK_PIXBUF_ANIMATION_ITER_CLASS (klass);
|
||||
|
||||
object_class->finalize = gdk_pixbuf_non_anim_iter_finalize;
|
||||
|
||||
anim_iter_class->get_delay_time = gdk_pixbuf_non_anim_iter_get_delay_time;
|
||||
anim_iter_class->get_pixbuf = gdk_pixbuf_non_anim_iter_get_pixbuf;
|
||||
anim_iter_class->on_currently_loading_frame = gdk_pixbuf_non_anim_iter_on_currently_loading_frame;
|
||||
anim_iter_class->advance = gdk_pixbuf_non_anim_iter_advance;
|
||||
}
|
||||
|
||||
static void
|
||||
gdk_pixbuf_non_anim_iter_init (GdkPixbufNonAnimIter *non_iter)
|
||||
{
|
||||
}
|
||||
|
||||
static void
|
||||
gdk_pixbuf_non_anim_iter_finalize (GObject *object)
|
||||
{
|
||||
GdkPixbufNonAnimIter *iter = GDK_PIXBUF_NON_ANIM_ITER (object);
|
||||
|
||||
g_object_unref (iter->non_anim);
|
||||
|
||||
G_OBJECT_CLASS (gdk_pixbuf_non_anim_iter_parent_class)->finalize (object);
|
||||
}
|
||||
|
||||
static int
|
||||
gdk_pixbuf_non_anim_iter_get_delay_time (GdkPixbufAnimationIter *iter)
|
||||
{
|
||||
return -1; /* show only frame forever */
|
||||
}
|
||||
|
||||
static GdkPixbuf*
|
||||
gdk_pixbuf_non_anim_iter_get_pixbuf (GdkPixbufAnimationIter *iter)
|
||||
{
|
||||
return GDK_PIXBUF_NON_ANIM_ITER (iter)->non_anim->pixbuf;
|
||||
}
|
||||
|
||||
|
||||
static gboolean
|
||||
gdk_pixbuf_non_anim_iter_on_currently_loading_frame (GdkPixbufAnimationIter *iter)
|
||||
{
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
static gboolean
|
||||
gdk_pixbuf_non_anim_iter_advance (GdkPixbufAnimationIter *iter,
|
||||
const GTimeVal *current_time)
|
||||
{
|
||||
|
||||
/* Advancing never requires a refresh */
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
#define __GDK_PIXBUF_ANIMATION_C__
|
||||
#include "gdk-pixbuf-aliasdef.c"
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user