Specifying CSS layout with reference attribute grammars

Research output: Chapter in Book/Report/Conference proceedingConference proceeding contribution

Abstract

Layout for web documents is a complex process described by the lengthy prose Cascading Style Sheets (CSS) specification. It is difficult to ensure that implementations match this specification. We show how an implementation can more closely match the specification by using attribute grammars to define layout computations. Particularly, we show how high-level patterns encode the terminology of the specification, discriminating between elements using the same language as in the specification. We also present a new method of injecting artificial structure into an existing tree using reference attribute grammars. The result is a high-level executable specification for CSS layout that can form the basis for a full declarative implementation.
Original languageEnglish
Title of host publicationSPLASH Companion 2016
Subtitle of host publicationProceedings of the 2016 ACM SIGPLAN International Conference on Systems, Programming, Languages and Applications: Software for Humanity
EditorsEelco Visser
Place of PublicationNew York, NY
PublisherAssociation for Computing Machinery
Pages29-30
Number of pages2
ISBN (Electronic)9781450344371
DOIs
Publication statusPublished - 2016
EventACM SIGPLAN International Conference on Systems, Programming, Languages and Applications : Software for Humanity - Amsterdam, Netherlands
Duration: 30 Oct 20164 Nov 2016

Conference

ConferenceACM SIGPLAN International Conference on Systems, Programming, Languages and Applications : Software for Humanity
CityAmsterdam, Netherlands
Period30/10/164/11/16

Keywords

  • Cascading Style Sheets
  • attribute grammars
  • language specification

Fingerprint

Dive into the research topics of 'Specifying CSS layout with reference attribute grammars'. Together they form a unique fingerprint.

Cite this