summaryrefslogtreecommitdiff
path: root/gtk/gtkcssnumbervalueprivate.h
diff options
context:
space:
mode:
authorBenjamin Otte <otte@redhat.com>2016-02-12 04:40:35 +0100
committerBenjamin Otte <otte@redhat.com>2016-02-13 04:49:07 +0100
commite2d966eda52ed8833ebdafdc7d6d43284a503453 (patch)
tree4aa0b17ebc0bb016d20f7273898a33e3c46c2ec2 /gtk/gtkcssnumbervalueprivate.h
parent7b301fcece6a9f2a18afc2e5e2169da9b6545bbf (diff)
downloadgtk+-e2d966eda52ed8833ebdafdc7d6d43284a503453.tar.gz
cssnumbervalue: Remove gtk_css_number_value_get_unit()
This is in preparation for calc(), as calc(50% - 5px) is valid CSS but has 2 units. Instead, add a function to query a value's dimension (so we can differentiate lengths from numbers) and add a function to query if the value contains percentages.
Diffstat (limited to 'gtk/gtkcssnumbervalueprivate.h')
-rw-r--r--gtk/gtkcssnumbervalueprivate.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/gtk/gtkcssnumbervalueprivate.h b/gtk/gtkcssnumbervalueprivate.h
index b9bb6994e6..454374bffe 100644
--- a/gtk/gtkcssnumbervalueprivate.h
+++ b/gtk/gtkcssnumbervalueprivate.h
@@ -42,7 +42,9 @@ GtkCssValue * _gtk_css_number_value_new (double val
GtkCssValue * _gtk_css_number_value_parse (GtkCssParser *parser,
GtkCssNumberParseFlags flags);
-GtkCssUnit _gtk_css_number_value_get_unit (const GtkCssValue *value);
+GtkCssDimension gtk_css_number_value_get_dimension (const GtkCssValue *value);
+gboolean gtk_css_number_value_has_percent (const GtkCssValue *value);
+
double _gtk_css_number_value_get (const GtkCssValue *number,
double one_hundred_percent);