From 5ad60caa3c35f86c11545b53052acdb6b9f7a76f Mon Sep 17 00:00:00 2001 From: Emmanuele Bassi Date: Thu, 28 Aug 2014 12:50:49 +0100 Subject: css: Implement font-stretch The font-stretch CSS property is defined in the Level 3 CSS Fonts module, available at: http://dev.w3.org/csswg/css-fonts/#propdef-font-stretch It allows defining a normal, condensed, or expanded face to the font description. Pango already supports it, so this is literally just the CSS parser machinery needed to bridge our CSS to the FontDescription API. https://bugzilla.gnome.org/show_bug.cgi?id=735593 --- gtk/gtkcssprovider.c | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) (limited to 'gtk/gtkcssprovider.c') diff --git a/gtk/gtkcssprovider.c b/gtk/gtkcssprovider.c index 429713b363..8d6b216d19 100644 --- a/gtk/gtkcssprovider.c +++ b/gtk/gtkcssprovider.c @@ -766,7 +766,23 @@ * font-size: 12px; * ]| * - * ## font: [family] [style] [variant] [size]; + * ## font-stretch: [face] + * + * Selects a normal, condensed, or expanded face from a font family. + * + * Absolute keyword values have the following ordering, from narrowest to widest: + * + * - ultra-condensed + * - extra-condensed + * - condensed + * - semi-condensed + * - normal + * - semi-expanded + * - expanded + * - extra-expanded + * - ultra-expanded + * + * ## font: [family] [style] [variant] [stretch] [size]; * * A shorthand for setting a few font properties at once. * - Supports any format accepted by pango_font_description_from_string() -- cgit v1.2.1