From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 32582 invoked by alias); 9 May 2003 06:33:14 -0000 Mailing-List: contact guile-gtk-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: guile-gtk-owner@sources.redhat.com Received: (qmail 32506 invoked from network); 9 May 2003 06:33:13 -0000 Received: from unknown (HELO lumo.pacujo.net) (209.77.185.85) by sources.redhat.com with SMTP; 9 May 2003 06:33:13 -0000 Received: (from marko@localhost) by lumo.pacujo.net (8.11.6/8.11.6/SuSE Linux 0.5) id h496P8u31772; Thu, 8 May 2003 23:25:08 -0700 To: guile-gtk@sources.redhat.com Subject: Fixed memory leaks in gdk-1.2.defs From: Marko Rauhamaa Date: Fri, 09 May 2003 06:33:00 -0000 Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-SW-Source: 2003-q2/txt/msg00039.txt.bz2 Summary: Fixed memory leaks in gdk-1.2.defs. Details: - build-guile-gtk-1.2, guile-gtk.c: GDK and GTK differ in the reference count policy. While GTK returns the widgets with a reference count 0, GDK returns them with a reference count 1. That means that gdk-1.2.defs should not increment the reference count -- but it was doing that. It turns out that the different GDK types don't need a copy option (= "method") at all whether they have reference counts or not. I made the copy option optional (previously the omission of the copy option caused a runtime crash). - gdk-1.2.defs: Added GdkFontType. Added it to GdkFont. - gdk-1.2.defs: Moved GdkFillRule among other enums. - gdk-1.2.defs: Removed copy options (previously: gdk_..._ref, gtk_no_copy, gtk_fake_copy, gdk_..._copy). - gdk-1.2.defs: Removed now redundant (copy #f) options from return values. - gdk-1.2.defs: Removed redundant conversion option from GdkFont. - gdk-1.2.defs: Changed GdkWChar from uint to uint32 (since it is now available). - gdk-1.2.defs: Removed useless size options -- but left it with gtimer, since define-struct still requires a dummy size. - gdk-1.2.defs: Indicated that gdk_font_intern and gdk_color_intern are now deprecated. (I don't think anybody used them anyway.) - gdk-1.2.defs, gdk-support.c, guile-gtk.h: Changed the signature of pixel-from-rgb from (visual red green blue) to (visual rgb) for consistency's sake. - gdk-support.c, gtk-compat.c: Now that copying is no longer done, needed to explicitly copy the return values of gdk-color-new, gdk-color-parse and gtk-style-get-white. - gdk-support.c, guile-gtk.h: Removed sgtk_gdk_drag_context_ref as no longer needed. Marko -- Marko Rauhamaa mailto:marko@pacujo.net http://pacujo.net/marko/