Commit Graph

161 Commits

Author SHA1 Message Date
Paolo Borelli
4adc072952 Use gtk_window_close for gtk_dialog_close
We manually synthethized the delete event, but now we have the
corresponding method in GtkWindow
2014-01-17 19:24:27 +01:00
Jasper St. Pierre
baa471ec13 gtkdialog: Allow specifying response IDs by nick in <action-widgets>
This makes it a lot more convenient for developers, as they don't
have to look up the numeric value of response IDs.
2013-10-28 18:03:25 -04:00
Matthias Clasen
0b726a409e Revert "dialog: Fix docs for GtkDialog"
This reverts commit e4bb02f8ae.

Responses don't have to be negative.
2013-10-28 06:39:30 -04:00
Jasper St. Pierre
e4bb02f8ae dialog: Fix docs for GtkDialog
Responses need to be negative
2013-10-23 12:04:13 -04:00
Matthias Clasen
cda60c3c40 Another round of template binding api changes
We rename the gtk_widget_class_bind_template_child{_internal}
macros by appending a _private to their name. Otherwise, it
would be too magic to pass the 'public' names as arguments,
but affect a member of the Private struct. At the same time,

Add two new macros with the old names,
gtk_widget_class_bind_template_child{_internal} that operate
on members of the instance struct.
2013-07-26 16:29:12 -04:00
Emmanuele Bassi
89ae3524a3 Rename the widget template API
The macros and functions are inconsistently named, and are not tied to
the "template" concept - to the point that it seems plausible to use
them without setting the template.

The new naming scheme is as follows:

  gtk_widget_class_bind_template_child_full
  gtk_widget_class_bind_template_callback_full

With the convenience macros:

  gtk_widget_class_bind_template_child
  gtk_widget_class_bind_template_child_internal
  gtk_widget_class_bind_template_callback

https://bugzilla.gnome.org/show_bug.cgi?id=700898
https://bugzilla.gnome.org/show_bug.cgi?id=700896
2013-07-26 13:52:15 -04:00
Alexander Larsson
a8e84545d1 widget: Use a real offset in gtk_widget_class_automate_child
Using an offset from the struct means you can have children in
both the public and private (via G_PRIVATE_OFFSET) parts of the
instance. It also matches the new private macros nicer.

https://bugzilla.gnome.org/show_bug.cgi?id=702563

Signed-off-by: Emmanuele Bassi <ebassi@gnome.org>
2013-07-26 08:41:09 -04:00
Jehan
0e4d9b7793 gtkdialog - more informative warning when ordering unexisting response_id 2013-07-21 21:42:50 +09:00
Matthias Clasen
0aa57d26b5 Move wholly deprecated classes to gtk/deprecated/
We've recently a number of classes wholly. For these cases,
move the headers and sources to gtk/deprecated/ and adjust
Makefiles and includes accordingly.

Affected classes:
GtkAction
GtkActionGroup
GtkActivatable
GtkIconFactory
GtkImageMenuItem
GtkRadioAction
GtkRecentAction
GtkStock
GtkToggleAction
GtkUIManager
2013-07-19 21:39:47 -04:00
Emmanuele Bassi
0899ef7cc9 gtk: Use new macros for defining private data
https://bugzilla.gnome.org/show_bug.cgi?id=702996
2013-07-09 09:30:02 +01:00
William Jon McCann
d741b7b873 Deprecate the gtk stock functions 2013-06-27 17:51:38 -04:00
William Jon McCann
424e1d0059 Start deprecating some GtkStock API 2013-06-25 19:05:32 -04:00
William Jon McCann
02c793f24a Start migrating internals away from GtkStock 2013-06-24 22:20:49 -04:00
Alexander Larsson
f354cef61b GtkDialog: Baseline align buttons in action area 2013-04-23 05:58:07 +02:00
Tristan Van Berkom
33f6195d0e GtkDialog: Define children with a GtkBuilder template
As the first composite widget in GTK+, this patch also
adds some Makefile mechanics to list the ui files as
dependencies of the global GTK+ resources, and adds the
initial test case where composite classes should be tested.
2013-04-08 21:19:27 +09:00
Matthias Clasen
8d0e88bac7 gtk: Don't use GDK_THREADS_ENTER/LEAVE macros internally
These are just wrappers for the functions, and we want to
deprecate them. Stopping to use them internally is a good
first step.
2012-07-30 18:01:47 +02:00
Benjamin Otte
7844e8089c types: Clean up gtkwidget.h includes
In particular gtksettings.h and gtkstylecontext.h needed to be included
in lots of places now.

Also, I order the includes alphabetically in a bunch of headers.
2012-03-03 19:45:03 +01:00
Javier Jardón
9d0febc9a6 Change FSF Address 2012-02-27 17:06:11 +00:00
Javier Jardón
8985ce3b72 gtkbox: Move private functions to private header 2011-10-02 21:30:42 +01:00
Matthias Clasen
5ff8fe6971 Documentation fixes
Mostly making sure that return values and varargs don't loose
their docs.
2011-09-25 21:04:49 -04:00
Matthias Clasen
383127cd0b Clean up unneeded includes 2011-08-28 01:40:10 -04:00
Benjamin Otte
6379faaa90 dialog: Use gtk_widget_class_set_accessible_role() 2011-07-18 18:30:50 +02:00
Matthias Clasen
1743e18c87 GtkDialog: avoid underallocations
GtkDialog changes its size depending on style properties. If
we only do this in response to ::style-updated, it happens during
the initial realization of the dialog and leads to the dialog
'growing' between when we determine the initial window size and
when we allocate it that size. So, do this beforehand.
2011-06-09 20:43:02 -04:00
Matthias Clasen
ab3c63cc3a More include cleanups 2011-06-07 21:23:07 -04:00
Patricia Santana Cruz
49c48546c8 Removed incorrect description's sentence.
Description was wrong when it explained: "The two areas are separated
by a GtkHSeparator.". These separators are not used any more.

Fixes https://bugzilla.gnome.org/show_bug.cgi?id=643496
2011-02-28 17:36:05 +00:00
Matthias Clasen
beb8c290d1 Always chain up in ::style-updated
This was not handled consistently, but the default handler
does useful things, so we should always chain up.
2011-02-07 07:30:37 -05:00
Christian Dywan
205ee834ec State that _add_button functions return a "#GtkButton widget"
Fixes: https://bugzilla.gnome.org/show_bug.cgi?id=586635
2011-01-26 10:33:49 +01:00
Pavel Holejsovsky
2fb1c06402 [GI] Add missing (out) and (array) annotations 2011-01-20 13:57:20 +01:00
Steve Frécinaux
3f0d330a65 [GI] Fix transfer annotation on gtk_dialog_add_button()
The transfer annotation was (transfer full) but the caller actually
doesn't own a reference of the object. This made the pygobject test suite
crash because pygobject was trying to unref the returned GtkButton
instance.

https://bugzilla.gnome.org/show_bug.cgi?id=639949
2011-01-20 11:55:38 +01:00
Pavel Holejsovsky
a1c297a310 [GI] Cosmetic cleanups of annotations and doc comments
This change does not introduce any functionality change, mostly
cosmtic cleanups, like re-linebreak when introduced annotations messed
up indentation or whitespace errors fixes.
2011-01-18 17:31:59 +01:00
Matthias Clasen
c009149670 Move GtkDialog docs inline
Based on a patch by Garrett Regier.

https://bugzilla.gnome.org/show_bug.cgi?id=617312
2011-01-04 12:54:47 -05:00
Matthias Clasen
b5c6904c2f Drop explicit includes of gdkkeysyms.h
These are no longer needed. At the same time, port gtkimcontextsimpleseqs.h
to use the new GDK_KEY_ symbols.
2011-01-04 12:21:41 -05:00
Carlos Garnacho
be0ebc9f5a Make GtkDialog use ::style-updated 2011-01-04 03:06:18 +01:00
Javier Jardón
abb98246ff docs: Update URL of some documentation links
http://developer.gnome.org -> http://library.gnome.org
2010-11-16 16:20:46 +09:00
Murray Cumming
131da8507b gtk_dialog_get_content_area(): Fix the docs.
This returns a GtkBox now, not a GtkVBox.
Language bindings may need to adjust their APIs accordingly.
2010-11-13 15:23:32 +09:00
Murray Cumming
233afbdab1 gtkdialog.c: Remove trailing whitespace 2010-11-13 15:23:32 +09:00
Michael Natterer
260ccdfebe gtk: remove "gboolean homogeneous" from gtk_box_new()
Because it's FALSE in virtually all use cases.
2010-11-02 12:04:35 +09:00
Javier Jardón
c15ef6405c Use gtk_box_new() instead gtk_[v|h]box_new() 2010-10-30 17:37:03 +09:00
Javier Jardón
2615ebf37e Use gtk_button_box_new() instead gtk_[v|h]_button_box_new() 2010-10-30 17:37:02 +09:00
=Christian Persch
d3f1745493 Use g_ascii_strto[u]ll instead of strto[u]l
We don't want GtkBuilder input to be locale-dependent.

Bug #632503
2010-10-25 12:22:20 -04:00
Matthias Clasen
35e0ad72e4 Another fix for the initial focus heuristic
We were trying to avoid selecting a label initially, but the code
was sometimes leaving labels selected when the focus eventually
ended up on a button instead.
2010-09-19 00:54:50 -04:00
Colin Walters
913cdf3be7 GDK: Prefix key names with KEY_
The keysyms create a lot of potential namespace conflicts for
C, and are especially problematic for introspection, where we take
constants into the namespace, so GDK_Display conflicts with GdkDisplay.

For C application compatiblity, add gdkkeysyms-compat.h which uses
the old names.

Just one user in GTK+ continues to use gdkkeysyms-compat.h, which is
the gtkimcontextsimple.c, since porting that requires porting more
custom Perl code.
2010-09-08 18:51:44 -04:00
John (J5) Palmieri
c78a23bdca add annotations for tranfer and scope so that methods are exported by GI 2010-09-07 13:50:40 -04:00
Matthias Clasen
d433a60611 Remove separators from dialogs
It seems more reasonable to remove this feature than to keep fighting
off every separator that pops up by accident in a dialog.
2010-09-02 09:14:20 -04:00
Javier Jardón
1e5d7c0225 Use GtkFooPrivate instead GtkFooPriv 2010-08-27 04:48:23 +02:00
Matthias Clasen
586bbc9b13 Make the initial focus in dialogs work as intended
We had code that tried to prevent selecting the text in the label
if we end up focusing a label, but it didn't take effect, because
we were moving the focus into the label again afterwards.
2010-08-25 00:43:16 -04:00
Javier Jardón
014fc1f73a gtk/gtkdialog.c: Use accessor functions to access GtkWindow 2010-08-23 20:18:10 +02:00
Javier Jardón
4def73b386 gtk/gtkdialog.c: use accessor functions to access GtkWidget 2010-08-22 22:56:13 +02:00
Javier Jardón
a8014e6fec gtkdialog: Move public members to private structure 2010-07-13 19:40:47 +02:00
Javier Jardón
0a07e9733b gtk/: fully remove gtkalias hacks
https://bugzilla.gnome.org/show_bug.cgi?id=623845
2010-07-10 02:51:26 +02:00