Commit Graph

34623 Commits

Author SHA1 Message Date
Alexander Larsson
43f1ac2b8f GtkBox: Add missing Since in docs 2013-04-23 05:58:08 +02:00
Alexander Larsson
ebbc7791dd GtkGrid: Add missing Since docs 2013-04-23 05:58:07 +02:00
Alexander Larsson
2b4c9983da Add tests/testbaseline 2013-04-23 05:58:07 +02:00
Alexander Larsson
f354cef61b GtkDialog: Baseline align buttons in action area 2013-04-23 05:58:07 +02:00
Alexander Larsson
8fbd6e2edc GtkEventBox: Support baseline alignment
This allows baselines to propagate from the child of the eventbox.
2013-04-23 05:58:07 +02:00
Alexander Larsson
e64c1f8929 GtkButtonBox: Support baseline alignment 2013-04-23 05:58:07 +02:00
Alexander Larsson
1df8d18ad2 GtkCheckButton and GtkRadioButton: Implement baseline alignment 2013-04-23 05:58:07 +02:00
Alexander Larsson
433c0c2134 GtkSpinButton: Support baseline alignment 2013-04-23 05:58:07 +02:00
Alexander Larsson
627685e2a2 GtkGrid: Support baseline alignment in GtkGrid
We support a local baseline in each row, as well as selecting
a specific row for the global baseline of the entire GtkGrid.
2013-04-23 05:58:07 +02:00
Alexander Larsson
72cd8b4dab GtkEntry: Support baselines 2013-04-23 05:58:06 +02:00
Alexander Larsson
d6684b5748 GtkButton: Add baseline align support 2013-04-23 05:58:06 +02:00
Alexander Larsson
7523b25942 GtkImage: Support baselines
This uses the current font metrics to guess the baseline of the image.
Without this any non-centered baseline in buttons with images look weird.
2013-04-23 05:50:38 +02:00
Alexander Larsson
6acc8c0817 GtkAlignment: Support baselines
We now report any baselines from the child, and allocate it.
Also, in the case of a baselign aligned child we ignore yscale/yalign
as that is not supportable.
2013-04-23 05:50:38 +02:00
Alexander Larsson
9a42942afb GtkBox: Add baseline alignment for horizontal boxes
Report a baseline based height and baseline whenever there
are children with ALIGN_BASELINE.

Assign baseline to childen in size_allocate. Either the one inherited
from the parent if set, or otherwise calculate one based on any
ALIGN_BASELINE children.
2013-04-23 05:50:38 +02:00
Alexander Larsson
1e1cf89e4f GtkLabel: Support baseline
Report the baseline in get_preferred_height_and_baseline_for_width().
2013-04-23 05:50:37 +02:00
Alexander Larsson
5ad618cb95 GtkSizeRequestCache: Don't store baselines in horizontal case
This saves memory for every widget (maximum 48 bytes per widget) at
a cost of a few duplicated codepaths in the size request cache.
2013-04-23 05:50:37 +02:00
Alexander Larsson
77e0f18eda Add GTK_DEBUG=baselines support
This draws red lines to show where the baselines are
2013-04-23 05:50:37 +02:00
Alexander Larsson
852cbb62b8 Initial support for baselines
This modifies the size machinery in order to allow baseline support.

We add a new widget vfunc get_preferred_height_and_baseline_for_width
which queries the normal height_for_width (or non-for-width if width
is -1) and additionally returns optional (-1 means "no baseline")
baselines for the minimal and natural heights.

We also add a new gtk_widget_size_allocate_with_baseline() which
baseline-aware containers can use to allocate children with a specific
baseline, either one inherited from the parent, or one introduced due
to requested baseline alignment in the container
itself. size_allocate_with_baseline() works just like a normal size
allocation, except the baseline gets recorded so that the child can
access it via gtk_widget_get_allocated_baseline() when it aligns
itself.

There are also adjust_baseline_request/allocation similar to the
allocation adjustment, and we extend the size request cache to also
store the baselines.
2013-04-23 05:50:37 +02:00
Alexander Larsson
f15bc7818e Add GTK_ALIGN_BASELINE to GtkAlign
Setting this means baseline aware containers should align the widget
according to the baseline. For other containers this behaves like
FILL.

In order to not suprise old code with a new enum value we always
return _FILL for _BASELINE unless you specifically request it via
gtk_widget_get_valign_with_baseline().
2013-04-23 05:47:31 +02:00
John Ralls
655c781b6e Fix automake warning about CFLAGS etc. being user variables 2013-04-22 15:48:35 -07:00
John Ralls
f0f07ad6d8 Remove get_atom_name and atom_intern
Completes aa9e974 for quartz
2013-04-22 15:48:35 -07:00
John Ralls
179004f0a7 Fix attempted inclusion of local headers with system brackets. 2013-04-22 15:48:34 -07:00
John Ralls
e58b19db04 gdk: Temporarily add -xobjective-c to CFLAGS
To enable compiling the quartz backend after a6a4428
2013-04-22 15:48:34 -07:00
Benjamin Otte
315261260c button: Implement height-for-width
https://bugzilla.gnome.org/show_bug.cgi?id=698433
2013-04-22 18:29:21 -04:00
Benjamin Otte
3450388ff0 sizerequest: Split out a common function 2013-04-22 18:29:01 -04:00
Cosimo Cecchi
009aadf378 window: remove unused code
We don't need to add these style classes.
2013-04-22 18:10:22 -04:00
Cosimo Cecchi
7bbbb01ff5 window: rework the CSD theming layer
Instead of having three different boxes and style classes, we can just
get away with the regular background box, plus a window-frame, which
contains the external frame, together with the window drop shadows.

GtkWindow now has special code to ensure the backing actual window is
allocated big enough to accomodate the shadows (using the shadow size
calculations introduced in the previous commit). We also use the margin
value to determine the size of the invisible borders (which can then be
different than the shadow).
2013-04-22 18:10:22 -04:00
Cosimo Cecchi
a44d6816d3 cssshadow: add a method to get the size of a shadows value
The method returns the size of each side of a GtkCssShadowsValue.
2013-04-22 18:10:21 -04:00
Cosimo Cecchi
7846bedebd window: factor out a gtk_window_get_maximized() function
Simplify code that does this same check over and over.
2013-04-22 18:10:21 -04:00
Cosimo Cecchi
87922575d3 window: remove title_border
We don't actually need this additional title border.
2013-04-22 18:10:21 -04:00
Federico Mena Quintero
0c1423d962 Remove GtkPlacesSidebar from our private Glade catalog
Now, Glade already knows about GtkPlacesSidebar AND MY MAD ICONS.
2013-04-22 17:00:08 -04:00
Ryan Lortie
ca0a18918c GtkModelMenuItem: add support for 'icon' attribute
Add support for icons on a GMenuModel.

https://bugzilla.gnome.org/show_bug.cgi?id=688820
2013-04-22 15:55:08 -04:00
Federico Mena Quintero
5322420145 Use friendlier property names for Glade 2013-04-22 15:46:59 -04:00
Piotr Drąg
66007d0ab6 Updated POTFILES.in and POTFILES.skip 2013-04-22 20:51:32 +02:00
Matthias Clasen
15bba87e9a Add new symbols
Add the GtkRevealer functions to gtk.symbols
2013-04-22 12:42:39 -04:00
Matthias Clasen
8ff96b3bb2 Do rtl flipping for GtkRevealer transitions 2013-04-22 12:42:39 -04:00
Matthias Clasen
86688c6fde Add a revealer example to gtk-demo
I tried to make a 'revealer ballet'. Judge for yourself if
I succeeded.
2013-04-22 12:42:39 -04:00
Matthias Clasen
aec62e1c10 Add docs for GtkRevealer 2013-04-22 12:42:38 -04:00
Matthias Clasen
d7f43c30a3 GtkRevealer: Add a fading animation
Using a container for this is not necessarily the most
elegant solution, but it lets us reuse the animation
machinery in GtkRevealer.
2013-04-22 12:42:38 -04:00
Matthias Clasen
0bd173e3d8 Forgotten file 2013-04-22 12:42:37 -04:00
Matthias Clasen
443459b52e Add GtkRevealer
This is a widget that can hide or show (ie reveal) its child
in an animated fashion.

This widget was initially developed in libgd.
2013-04-22 12:42:37 -04:00
Cosimo Cecchi
d82257e1c8 stack: fix a typo in docs 2013-04-22 11:20:06 -04:00
Matthias Clasen
b88c0d7387 Typo fix in GtkStack docs 2013-04-22 10:25:30 -04:00
Matthias Clasen
6d77bf66ac Typo fix in GtkStackSwitcher docs 2013-04-22 10:25:30 -04:00
Benjamin Otte
b8e4adfff9 Revert "Revert "gtkbin: Remove the silliest code on earth""
This reverts commit b164df7450.
2013-04-22 08:23:08 -04:00
Victor Ibragimov
361754b063 Tajik translation updated 2013-04-22 13:17:42 +05:00
Rafael Ferreira
b5912e61fd Updated Brazilian translation for UI and PO-Prop. 2013-04-22 05:00:18 -03:00
Tristan Van Berkom
e5b384f537 Updated private widget catalog to remove the reference to the shortcuts model
This model seems to be removed since Federico's places-sidebar work.
2013-04-22 15:55:20 +09:00
Tristan Van Berkom
b164df7450 Revert "gtkbin: Remove the silliest code on earth"
This reverts commit f4438a1ffc.

The calculation of the delta between parent and child widget
is required in order to automate height-for-width and width-for-height
requests for various GtkBin widgets.

GtkButton, GtkCheckButton, GtkRadioButton, etc, all have different
requests for space around the content which can not be satisfied
with a simple calculation of GtkContainer border-width.
2013-04-22 15:20:51 +09:00
Matthias Clasen
6186429f5f GtkStack: shorten a few parameter names
Looks better in the docs.
2013-04-21 23:13:16 -04:00