Andreas Kling
a565121793
LibWeb: Move HTML object model stuff into LibWeb/HTML/
...
Take a hint from SVG and more all the HTML classes into HTML instead of
mixing them with the DOM classes.
2020-07-26 17:51:00 +02:00
Andreas Kling
440b4ece22
LibWeb: Move border width and color into LayoutStyle
...
To make this possible, I also had to give each LayoutNode a Document&
so it can resolve document-specific colors correctly. There's probably
ways to avoid having this extra member by resolving colors later, but
this works for now.
2020-06-24 19:43:27 +02:00
Andreas Kling
bc178ee743
LibWeb: Add CSS::Display enum and StyleProperties::display()
...
The display property is not interesting after we've built the layout
tree, so we don't have to move it into LayoutStyle.
2020-06-24 18:06:21 +02:00
Maciej Sobaczewski
a4fbc78f25
LibWeb: Respect display:none on <input> elements
2020-06-21 09:59:06 +02:00
Andreas Kling
fdfda6dec2
AK: Make string-to-number conversion helpers return Optional
...
Get rid of the weird old signature:
- int StringType::to_int(bool& ok) const
And replace it with sensible new signature:
- Optional<int> StringType::to_int() const
2020-06-12 21:28:55 +02:00
Andreas Kling
92392398a2
LibWeb: Add Page abstraction between PageView and main Frame
...
* A PageView is a view onto a Page object.
* A Page always has a main Frame (root of Frame tree.)
* Page has a PageClient. PageView is a PageClient.
The goal here is to allow building another kind of view onto
a Page while keeping the rest of LibWeb intact.
2020-06-08 21:12:20 +02:00
Andreas Kling
896db187e5
LibWeb: Move Frame.{cpp,h} into a new Frame/ directory
2020-06-07 10:14:41 +02:00
Andreas Kling
2149820260
LibWeb: Use HTML::AttributeNames::foo instead of FlyString("foo")
...
To avoid the costly instantiation of FlyStrings whenever we're looking
up attributes, use the premade HTML::AttributeNames globals. :^)
2020-06-03 21:53:00 +02:00
Andreas Kling
e1e9fb8290
LibWeb: Turn <input type=button> into an actual button :^)
2020-05-30 11:59:10 +02:00
Andreas Kling
42243d2e06
LibWeb: Rename Web::HtmlView => Web::PageView
...
This widget doesn't just view HTML, it views a web page. :^)
2020-05-28 18:22:54 +02:00
Andreas Kling
977863ea07
LibGUI: Include keyboard modifier state with button on_click calls
...
This will allow you us to implement special behavior when Ctrl+clicking
a button.
2020-05-12 20:31:16 +02:00
Shadowfacts
7f538ea7eb
LibWeb: When creating form action URL, only include value for the submit
...
that was used to submit the form
2020-05-05 11:19:38 +02:00
Andreas Kling
9df71afdb3
LibWeb: Respect the <input size> attribute a bit more :^)
...
We now use the size attribute to determine the width of a text input.
2020-05-04 22:43:00 +02:00
Andreas Kling
6886c6efa6
LibWeb: Don't generate a layout node for <input type="hidden">
2020-05-04 22:33:49 +02:00
Andreas Kling
7309642ca8
LibWeb: Use FlyString for Element tag names
...
This makes selector matching a lot more efficient, and also reduces the
number of strings on the heap.
2020-03-22 19:12:10 +01:00
Andreas Kling
830a57c6b2
LibWeb: Rename directory LibHTML => LibWeb
...
Let's rename this to LibWeb since it aims to provide more parts of the
web platform than just HTML. :^)
2020-03-07 10:32:51 +01:00