From 81b02d9b8f7643923823c4b7014a0e3fd4c923fa Mon Sep 17 00:00:00 2001 From: Johannes Hofmann Date: Thu, 13 Nov 2008 17:02:53 +0100 Subject: move CssLength stuff to css.hh --- src/cssparser.hh | 29 ----------------------------- 1 file changed, 29 deletions(-) (limited to 'src/cssparser.hh') diff --git a/src/cssparser.hh b/src/cssparser.hh index fc9cbccd..5089d9bb 100644 --- a/src/cssparser.hh +++ b/src/cssparser.hh @@ -49,35 +49,6 @@ typedef struct { } CssPropertyInfo; -/* - * Lengths are represented as int in the following way: - * - * +---+ - - - +---+---+- - - - - -+---+---+---+---+ - * | integer part | decimal fraction | type | - * +---+ - - - +---+---+- - - - - -+---+---+---+---+ - * n-1 19 18 3 2 1 0 - * - * | <------ fixed point value ------> | - * - * where type is one of the CSS_LENGTH_TYPE_* values. - */ - -typedef int CssLength; - -enum { - CSS_LENGTH_TYPE_PX, - CSS_LENGTH_TYPE_MM, /* "cm", "in", "pt" and "pc" are converted into - millimeters. */ - CSS_LENGTH_TYPE_EM, - CSS_LENGTH_TYPE_EX, - CSS_LENGTH_TYPE_PERCENTAGE, - CSS_LENGTH_TYPE_AUTO /* This can be used as a simple value. */ -}; - -#define CSS_CREATE_LENGTH(v, t) ( ( (int)((v) * (1 << 19)) & ~7 ) | (t) ) -#define CSS_LENGTH_VALUE(l) ( ( (float)((l) & ~7) ) / (1 << 19) ) -#define CSS_LENGTH_TYPE(l) ((l) & 7) - void a_Css_init (void); void a_Css_freeall (void); -- cgit v1.2.3