path: root/layout.mdwn
diff options
Diffstat (limited to 'layout.mdwn')
1 files changed, 34 insertions, 0 deletions
diff --git a/layout.mdwn b/layout.mdwn
new file mode 100644
index 0000000..ba97b22
--- /dev/null
+++ b/layout.mdwn
@@ -0,0 +1,34 @@
+[[!meta title="Layout"]]
+[[!meta author="Tlsa"]]
+[[!meta date="2010-04-17T21:17:08Z"]]
+[[!toc]] This page is for planning
+the new layout engine [[scheduled for NetSurf 4.0|development_plan]].
+### Overview
+At the moment NetSurf can only run layout on the whole box tree. This
+happens every time the window width is changed, to let NetSurf reflow
+the content. There are some optimisations where the layout code knows if
+bits of the layout are fixed-width and won't be affected by a reflow.
+Currently we don't handle partial layouts of sections of the box tree.
+For example, if a scroll:auto; is laid out to available width, and the
+contained content exceeds a specified height, a scrollbar needs to be
+inserted. This should cause the descendants to the scroll:auto; to be
+laid out to available width - scrollbar width.
+Things that require the layout engine to be able to run on parts of an
+already-laid-out page are:
+- New image fetched and it has width/height not specified in HTML or
+- Overflow scrollbar insertion affects available width
+- Frame scrollbar insertion affects available width
+- Dynamic CSS pseudo classes
+- JavaScript changing stuff or adding stuff
+Working out which bits of the page are affected by any given change may
+not be easy.