Commit 9508b76b authored by Elliot Lee's avatar Elliot Lee

Initial revision

parents
*.lo
config.log
config.h
libtool
config.status
stamp-h
Makefile
gtk+.xconfig
config.cache
Peter Mattis (petm@xcf.berkeley.edu)
Spencer Kimball (spencer@xcf.berkeley.edu)
Josh MacDonald (jmacd@xcf.berkeley.edu)
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
## Process this file with automake to produce Makefile.in
SRC_SUBDIRS = glib gdk gtk
SUBDIRS = $(SRC_SUBDIRS) docs
EXTRA_DIST = gtk+.prj makecopyright TODO
.PHONY: files populate checkin release
files:
@files=`ls $(DISTFILES) 2> /dev/null `; for p in $$files; do \
echo $$p; \
done
@for subdir in $(SUBDIRS); do \
files=`cd $$subdir; $(MAKE) files | grep -v "make\[[1-9]\]"`; \
for file in $$files; do \
echo $$subdir/$$file; \
done; \
done
populate:
@echo "populating project"
@files=`$(MAKE) files | grep -v "make\[[1-9]\]"`; prcs populate -d gtk+.prj $$files
checkin: populate
@echo "checking in project"
@prcs checkin
release:
$(MAKE) dist distdir=$(PACKAGE)`date +"%y%m%d"`
The official ftp site is:
ftp://ftp.gimp.org/pub/gtk
Patches can be uploaded to:
ftp://ftp.gimp.org/incoming
Anonymous CVS access for gtk+ (as well as 'gimp', 'gimp-data', and
'gnome') is available via
CVSROOT=:pserver:anonymous@cvs.gnome.org:/home/cvs
with an empty password.
A mailing list is located at:
gtk-list@redhat.com
To subscribe: mail -s subscribe gtk-list-request@redhat.com < /dev/null
(Send mail to gtk-list-request@redhat.com with the subject "subscribe")
Now
---
3. Fix focus activation of list items. Does list item activation have to be
completely reorganized?
4. Lists should scroll to center the recently selected item if it isn't
visible.
The Future
----------
-Documentation
-Tree widget
-Text widget (needs to be finished)
-Widget redrawing when the window resizes sometimes messes up.
-Make sure a widget added to a list is a list item and a widget added
to a menu is a menu item, etc...
-More dialogs? Print, font, etc?
-Multiple document interface (MDI)?
-Support another widget style? Should be possible using GtkStyle's, but
there may be some work needed to remove any style dependencies in widget
code. Maybe GtkStyle's should have 'draw_push_button', 'draw_check_button',
etc, functions to draw the various widgets.
-OffiX drag and drop support
-Make all widget attributes configurable after the widget is created.
/* acconfig.h
This file is in the public domain.
Descriptive text for the C preprocessor macros that
the distributed Autoconf macros can define.
No software package will use all of them; autoheader copies the ones
your configure.in uses into your configuration header file templates.
The entries are in sort -df order: alphabetical, case insensitive,
ignoring punctuation (such as underscores). Although this order
can split up related entries, it makes it easier to check whether
a given entry is in the file.
Leave the following blank line there!! Autoheader needs it. */
/* Other stuff */
#undef HAVE_IPC_H
#undef HAVE_SHM_H
#undef HAVE_XPM
#undef HAVE_XSHM_H
#undef HAVE_SYS_SELECT_H
#undef IPC_RMID_DEFERRED_RELEASE
#undef NO_FD_SET
#undef RESOURCE_BASE
#undef XINPUT_NONE
#undef XINPUT_GXI
#undef XINPUT_XFREE
/* Define as the return type of signal handlers (int or void). */
#undef RETSIGTYPE
/* Most machines will be happy with int or void. IRIX requires '...' */
#undef SIGNAL_ARG_TYPE
/* #undef PACKAGE */
/* #undef VERSION */
/* Leave that blank line there!! Autoheader needs it.
If you're adding to this file, keep in mind:
The entries are in sort -df order: alphabetical, case insensitive,
ignoring punctuation (such as underscores). */
This diff is collapsed.
This diff is collapsed.
/* config.h.in. Generated automatically from configure.in by autoheader. */
/* Define to empty if the keyword does not work. */
#undef const
/* Define as the return type of signal handlers (int or void). */
#undef RETSIGTYPE
/* Define if you have the ANSI C header files. */
#undef STDC_HEADERS
/* Define if the X Window System is missing or not being used. */
#undef X_DISPLAY_MISSING
/* Other stuff */
#undef HAVE_IPC_H
#undef HAVE_SHM_H
#undef HAVE_XPM
#undef HAVE_XSHM_H
#undef HAVE_SYS_SELECT_H
#undef IPC_RMID_DEFERRED_RELEASE
#undef NO_FD_SET
#undef RESOURCE_BASE
#undef XINPUT_NONE
#undef XINPUT_GXI
#undef XINPUT_XFREE
/* Define as the return type of signal handlers (int or void). */
#undef RETSIGTYPE
/* #undef PACKAGE */
/* #undef VERSION */
This diff is collapsed.
# Process this file with autoconf to produce a configure script.
AC_INIT(gdk/gdktypes.h)
# Configure glib
AC_CONFIG_SUBDIRS(glib)
dnl Initialize automake stuff
AM_INIT_AUTOMAKE(gtk+, 971109)
# Specify a configuration file
AM_CONFIG_HEADER(config.h)
dnl Initialize libtool
AM_PROG_LIBTOOL
dnl Initialize maintainer mode
AM_MAINTAINER_MODE
AC_CANONICAL_HOST
AC_ARG_ENABLE(shm, [ --enable-shm support shared memory if available [default=yes]],
echo $enable_shm, enable_shm="yes")
AC_ARG_ENABLE(debug, [ --enable-debug turn on debugging [default=no]],
if eval "test x$enable_debug = xyes"; then
DEBUGFLAG="-g"
fi)
AC_ARG_ENABLE(ansi, [ --enable-ansi turn on strict ansi [default=no]],
, enable_ansi=no)
AC_ARG_WITH(xinput, [ --with-xinput[=no/gxi/xfree] support XInput ])
if test -n "$DEBUGFLAG"; then
CFLAGS="$DEBUGFLAG"
else
CFLAGS="$CFLAGS -DNDEBUG"
fi
# Build time sanity check...
AM_SANITY_CHECK
# Checks for programs.
AC_PROG_CC
AM_PROG_CC_STDC
AC_PROG_INSTALL
AC_PROG_MAKE_SET
if eval "test x$GCC = xyes"; then
test `echo "$CFLAGS" | grep "\-Wall" > /dev/null 2> /dev/null`
if test ! $?; then
CFLAGS="$CFLAGS -Wall"
fi
if eval "test x$enable_ansi = xyes"; then
test `echo "$CFLAGS" | grep "\-ansi" > /dev/null 2> /dev/null`
if test ! $?; then
CFLAGS="$CFLAGS -ansi"
fi
test `echo "$CFLAGS" | grep "\-pedantic" > /dev/null 2> /dev/null`
if test ! $?; then
CFLAGS="$CFLAGS -pedantic"
fi
fi
fi
# Find the X11 include and library directories
AC_PATH_X
AC_PATH_XTRA
if test "x$x_includes" = "x"; then
x_includes="/usr/include"
fi
saved_cflags="$CFLAGS"
saved_ldflags="$LDFLAGS"
CFLAGS="$X_CFLAGS"
LDFLAGS="$X_LDFLAGS $X_LIBS"
# Checks for libraries.
# Check for the X11 library
AC_CHECK_LIB(X11, XOpenDisplay, x_libs="-lX11 $X_EXTRA_LIBS", no_x11_lib=yes, $X_EXTRA_LIBS)
if eval "test x$enable_shm = xyes"; then
# Check for the Xext library (needed for XShm extention)
AC_CHECK_LIB(Xext, XShmAttach, x_libs="-lXext $x_libs", no_xext_lib=yes, $x_libs)
fi
x_cflags="$X_CFLAGS"
x_ldflags="$X_LDFLAGS $X_LIBS"
# set up things for XInput
if eval "test x$with_xinput = xgxi -o x$with_xinput = xyes"; then
AC_DEFINE(XINPUT_GXI)
xinput_progs=gxid
x_libs="-lXi $x_libs"
elif eval "test x$with_xinput = xxfree"; then
AC_DEFINE(XINPUT_XFREE)
x_libs="-lXi $x_libs"
else
AC_DEFINE(XINPUT_NONE)
fi
AC_SUBST(x_cflags)
AC_SUBST(x_includes)
AC_SUBST(x_ldflags)
AC_SUBST(x_libs)
AC_SUBST(xinput_progs)
CFLAGS="$saved_cflags"
LDFLAGS="$saved_ldflags"
if eval "test x$enable_shm = xyes"; then
# Check for shared memory
AC_CHECK_HEADER(sys/ipc.h, AC_DEFINE(HAVE_IPC_H), no_sys_ipc=yes)
AC_CHECK_HEADER(sys/shm.h, AC_DEFINE(HAVE_SHM_H), no_sys_shm=yes)
# Check whether shmctl IPC_RMID allowes subsequent attaches
if test "$ac_cv_header_sys_shm_h" = "yes"; then
AC_MSG_CHECKING(whether shmctl IPC_RMID allowes subsequent attaches)
AC_TRY_RUN([
#include <sys/types.h>
#include <sys/ipc.h>
#include <sys/shm.h>
int main()
{
int id;
char *shmaddr;
id = shmget (IPC_PRIVATE, 4, IPC_CREAT | 0777);
if (id == -1)
exit (2);
shmaddr = shmat (id, 0, 0);
shmctl (id, IPC_RMID, 0);
if ((char*) shmat (id, 0, 0) == (char*) -1)
{
shmdt (shmaddr);
exit (1);
}
shmdt (shmaddr);
shmdt (shmaddr);
exit (0);
}
],
AC_DEFINE(IPC_RMID_DEFERRED_RELEASE)
AC_MSG_RESULT(yes),
AC_MSG_RESULT(no),
AC_MSG_RESULT(assuming no))
fi
# Check for the X shared memory extension header file
AC_MSG_CHECKING(X11/extensions/XShm.h)
if eval "test x$no_ext_lib = xyes"; then
AC_MSG_RESULT(no)
no_xshm=yes
else
if eval "test -f $x_includes/X11/extensions/XShm.h"; then
AC_MSG_RESULT(yes)
AC_DEFINE(HAVE_XSHM_H)
else
AC_MSG_RESULT(no)
no_xshm=yes
fi
fi
fi
# Check for private display resource base variable
AC_MSG_CHECKING(resource base field in XDisplay)
AC_CACHE_VAL(gtk_cv_display_resource_base,
[AC_TRY_RUN([
#define XLIB_ILLEGAL_ACCESS
#include <X11/Xlib.h>
int
main ()
{
Display *display;
return 0;
display->resource_base;
}],
gtk_cv_display_resource_base="resource_base",
gtk_cv_display_resource_base="private3")])
AC_MSG_RESULT($gtk_cv_display_resource_base)
AC_DEFINE_UNQUOTED(RESOURCE_BASE, gdk_display->$gtk_cv_display_resource_base)
# Checks for header files.
AC_HEADER_STDC
# Checks for typedefs, structures, and compiler characteristics.
AC_C_CONST
# Checks for library functions.
AC_TYPE_SIGNAL
# Check for sys/select.h
AC_MSG_CHECKING([fd_set and sys/select])
AC_TRY_COMPILE([#include <sys/types.h>],
[fd_set readMask, writeMask;], gtk_ok=yes, gtk_ok=no)
if test $gtk_ok = no; then
AC_HEADER_EGREP(fd_mask, sys/select.h, gtk_ok=yes)
if test $gtk_ok = yes; then
AC_DEFINE(HAVE_SYS_SELECT_H)
fi
fi
AC_MSG_RESULT($gtk_ok)
if test $gtk_ok = no; then
AC_DEFINE(NO_FD_SET)
fi
AC_OUTPUT(Makefile gtk+.xconfig docs/Makefile gdk/Makefile gtk/Makefile)
## Process this file with automake to produce Makefile.in
info_TEXINFOS = gdk.texi gtk.texi
EXTRA_DIST = texinfo.tex macros.texi
files:
@files=`ls $(DISTFILES) 2> /dev/null `; for p in $$files; do \
echo $$p; \
done
This diff is collapsed.
This diff is collapsed.
@macro gtkstdmacros {p, q}
@deftypefun Gtk\p\* GTK_\q\ (gpointer @var{obj})
Cast a generic pointer to @code{Gtk\p\*}. @xref{Standard Macros}, for
more info.
@end deftypefun
@deftypefun Gtk\p\Class* GTK_\q\_CLASS (gpointer @var{class})
Cast a generic pointer to @code{Gtk\p\Class*}. @xref{Standard Macros},
for more info.
@end deftypefun
@deftypefun gint GTK_IS_\q\ (gpointer @var{obj})
Determine if a generic pointer refers to a @code{Gtk\p\}
object. @xref{Standard Macros}, for more info.
@end deftypefun
@end macro
This diff is collapsed.
*.lo
Makefile
.deps
_libs
libgdk.la
## Process this file with automake to produce Makefile.in
gdkincludedir = $(includedir)/gdk
lib_LTLIBRARIES = libgdk.la
libgdk_la_SOURCES = \
gdk.c \
gdkcolor.c \
gdkcursor.c \
gdkdraw.c \
gdkfont.c \
gdkgc.c \
gdkglobals.c \
gdkimage.c \
gdkinput.c \
gdkpixmap.c \
gdkproperty.c \
gdkrectangle.c \
gdkselection.c \
gdkvisual.c \
gdkwindow.c \
gdkxid.c \
gxid_lib.c
## this last one is ifdef'd out unless XINPUT_GXI is defined
## It's easier than trying to get automake to handle compiling
## it conditionally
gdkinclude_HEADERS = \
gdk.h \
gdkcursors.h \
gdkkeysyms.h \
gdkprivate.h \
gdktypes.h \
gdkinput.h \
gdkinputnone.h \
gdkinputcommon.h\
gdkinputgxi.h \
gdkinputxfree.h \
gxid_lib.h \
gxid_proto.h \
gdkx.h
libgdk_la_LDFLAGS = -version-info 1:0:0 \
@x_ldflags@ @x_libs@
INCLUDES = -I$(top_srcdir) -I$(top_srcdir)/glib @x_cflags@
EXTRA_PROGRAMS = gxid
bin_PROGRAMS = @xinput_progs@
gxid_SOURCES = gxid.c
gxid_LDADD = \
@x_ldflags@ \
@x_libs@ \
-lm
BUILT_SOURCES = gdkcursors.h gdkkeysyms.h
EXTRA_DIST = makecursors makecursors.sed makekeysyms makekeysyms.sed
gdkcursors.h:
$(srcdir)/makecursors @x_includes@/X11/cursorfont.h > $@
gdkkeysyms.h:
$(srcdir)/makekeysyms @x_includes@/X11/keysymdef.h > $@
.PHONY: files
files:
@files=`ls $(DISTFILES) 2> /dev/null `; for p in $$files; do \
echo $$p; \
done
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
/* GDK - The GIMP Drawing Kit
* Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald
*
* 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., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
#include <X11/Xlib.h>
#include <X11/cursorfont.h>
#include "gdk.h"
#include "gdkprivate.h"
GdkCursor*
gdk_cursor_new (GdkCursorType cursor_type)
{
GdkCursorPrivate *private;
GdkCursor *cursor;
Cursor xcursor;
xcursor = XCreateFontCursor (gdk_display, cursor_type);
private = g_new (GdkCursorPrivate, 1);
private->xdisplay = gdk_display;
private->xcursor = xcursor;
cursor = (GdkCursor*) private;
cursor->type = cursor_type;
return cursor;
}
void
gdk_cursor_destroy (GdkCursor *cursor)
{
GdkCursorPrivate *private;
g_return_if_fail (cursor != NULL);
private = (GdkCursorPrivate *) cursor;
XFreeCursor (private->xdisplay, private->xcursor);
g_free (private);
}
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
/* GDK - The GIMP Drawing Kit
* Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald
*
* 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., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
#include <stdio.h>
#include <X11/Xlib.h>
#include "gdktypes.h"
#include "gdkprivate.h"
gint gdk_debug_level = 0;
gint gdk_show_events = FALSE;
gint gdk_use_xshm = TRUE;
gchar *gdk_display_name = NULL;
Display *gdk_display = NULL;
gint gdk_screen;
Window gdk_root_window;
Window gdk_leader_window;
GdkWindowPrivate gdk_root_parent;
Atom gdk_wm_delete_window;
Atom gdk_wm_take_focus;
Atom gdk_wm_protocols;
Atom gdk_wm_window_protocols[2];
Atom gdk_selection_property;
GdkDndGlobals gdk_dnd = {None,None,None,
None,None,None,