ladybird/Userland/Libraries/LibWeb/CSS
Andreas Kling 23a08fd35a LibWeb: Start absolutizing lengths after performing the CSS cascade
Once we've performed the cascade on a set of values for an element,
we should have enough information to resolve/absolutize some lengths.

Basically, any CSS length that isn't "auto" or a percentage can be
turned into an absolute length (in pixels) as long as we have the
following information:

- The viewport rect
- The parent element's font
- The document element's font
- The element's own font

To ensure that we can absolutize lengths relative to the element's own
font, we now do a separate first pass where font-related properties are
defaulted (in the cascade spec sense of the word) and become usable.

There's a lot more work to do here, but this should open up a lot of
simplification in layout code, since it will no longer need to care
about relative lengths. Layout still needs to resolve percentages, since
we can't do that for some properties until the containing block
dimensions are known.
2021-09-24 15:01:49 +02:00
..
Parser LibWeb: Replace last couple of StyleValue casts with as_foo() 2021-09-24 15:01:43 +02:00
.gitignore Libraries: Move to Userland/Libraries/ 2021-01-12 12:17:46 +01:00
ComputedValues.h LibWeb: Add transform property to the system 2021-09-18 21:53:37 +02:00
CSSImportRule.cpp LibWeb: Add the Web::URL namespace and move URLEncoder to it 2021-09-13 01:43:10 +02:00
CSSImportRule.h LibWeb: Add the Web::URL namespace and move URLEncoder to it 2021-09-13 01:43:10 +02:00
CSSRule.cpp Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
CSSRule.h Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
CSSStyleDeclaration.cpp LibWeb: Implement CSSStyleDeclaration.getPropertyValue(property) 2021-09-12 20:44:50 +02:00
CSSStyleDeclaration.h LibWeb: Implement CSSStyleDeclaration.getPropertyValue(property) 2021-09-12 20:44:50 +02:00
CSSStyleDeclaration.idl LibWeb: Implement CSSStyleDeclaration.getPropertyValue(property) 2021-09-12 20:44:50 +02:00
CSSStyleRule.cpp LibWeb: Make CSS::Selector reference counted 2021-07-14 13:31:00 +02:00
CSSStyleRule.h LibWeb: Make CSS::Selector reference counted 2021-07-14 13:31:00 +02:00
CSSStyleSheet.cpp Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
CSSStyleSheet.h AK: Rename downcast<T> => verify_cast<T> 2021-06-24 19:57:01 +02:00
CSSStyleSheet.idl LibWeb: Start exposing CSS style sheets to JavaScript :^) 2021-03-08 11:50:36 +01:00
Default.css LibWeb: Use -libweb-palette-base-text for text color in default CSS 2021-05-19 23:23:48 +01:00
Identifiers.json LibWeb: Add several CSS identifiers to the list 2021-09-23 17:47:40 +02:00
Length.cpp LibWeb: Start absolutizing lengths after performing the CSS cascade 2021-09-24 15:01:49 +02:00
Length.h LibWeb: Start absolutizing lengths after performing the CSS cascade 2021-09-24 15:01:49 +02:00
LengthBox.h Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
MediaQueryList.cpp LibWeb: Implement MediaQueryList.{addListener,removeListener} 2021-09-13 01:43:03 +02:00
MediaQueryList.h LibWeb: Implement MediaQueryList.{addListener,removeListener} 2021-09-13 01:43:03 +02:00
MediaQueryList.idl LibWeb: Implement MediaQueryList.{addListener,removeListener} 2021-09-13 01:43:03 +02:00
Properties.json LibWeb: Add range-checking to property_accepts_value() 2021-09-23 17:47:40 +02:00
QuirksMode.css Libraries: Move to Userland/Libraries/ 2021-01-12 12:17:46 +01:00
ResolvedCSSStyleDeclaration.cpp LibWeb: Rename "Computed" CSSStyleDeclaration => "Resolved" 2021-09-24 15:01:49 +02:00
ResolvedCSSStyleDeclaration.h LibWeb: Rename "Computed" CSSStyleDeclaration => "Resolved" 2021-09-24 15:01:49 +02:00
Screen.cpp LibWeb: Add DOM::Window::page() 2021-09-09 21:25:10 +02:00
Screen.h AK: Rename adopt() to adopt_ref() 2021-04-23 16:46:57 +02:00
Screen.idl LibWeb: Implement the Screen interface 2021-04-04 00:37:54 +02:00
Selector.cpp AK: Move FormatParser definition from header to implementation file 2021-08-19 23:49:25 +02:00
Selector.h Everywhere: Use my shiny new serenityos.org email :^) 2021-09-03 12:22:36 +02:00
SelectorEngine.cpp Everywhere: Use my shiny new serenityos.org email :^) 2021-09-03 12:22:36 +02:00
SelectorEngine.h LibWeb: Convert CSS Dump, Selector, & SelectorEngine to east const 2021-07-14 13:31:00 +02:00
StyleInvalidator.cpp Everywhere: Use linusg@serenityos.org for my copyright headers 2021-04-22 22:51:19 +02:00
StyleInvalidator.h Everywhere: Use linusg@serenityos.org for my copyright headers 2021-04-22 22:51:19 +02:00
StyleProperties.cpp LibWeb: Start absolutizing lengths after performing the CSS cascade 2021-09-24 15:01:49 +02:00
StyleProperties.h LibWeb: Start absolutizing lengths after performing the CSS cascade 2021-09-24 15:01:49 +02:00
StyleResolver.cpp LibWeb: Start absolutizing lengths after performing the CSS cascade 2021-09-24 15:01:49 +02:00
StyleResolver.h LibWeb: Start absolutizing lengths after performing the CSS cascade 2021-09-24 15:01:49 +02:00
StyleSheet.cpp Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
StyleSheet.h Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
StyleSheet.idl LibWeb: Implement StyleSheet.type 2021-03-08 16:16:28 +01:00
StyleSheetList.cpp Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
StyleSheetList.h AK: Rename adopt() to adopt_ref() 2021-04-23 16:46:57 +02:00
StyleSheetList.idl LibWeb: Start exposing CSS style sheets to JavaScript :^) 2021-03-08 11:50:36 +01:00
StyleValue.cpp LibWeb: Clarify StyleValue API with new naming scheme 2021-09-24 15:01:43 +02:00
StyleValue.h LibWeb: Clarify StyleValue API with new naming scheme 2021-09-24 15:01:43 +02:00