ABSTRACT
The zipper is a well known design pattern for providing a cursor-like interface to a data structure. However, the classic treatise by Huet (1) only scratches the surface of some of the potential applications of the zipper. In this work we have taken inspiration from Huet, and built a library suitable as an underpinning for a structured editor for programming languages. We consider a zipper structure that is suitable for traversing heterogeneous data types, encoding routes to other places in the tree (for bookmark or quick-jump functionality), expressing lexically bound information using contexts, and traversals for rendering a program indicating where the cursor is currently focused in the whole.
Supplemental Material
Available for Download
- Huet, G. The Zipper. Journal of Functional Programming, 7(5):549--554, 1997 Google Scholar
Digital Library
- Sulzmann, M. and Chakravarty, M. M. T. and Jones, S. P. and Donnelly, K. System F with Type Equality Coercions, in The Third ACM SIGPLAN Workshop on Types in Language Design and Implementation (TLDI'07), January 2007. Google Scholar
Digital Library
- Allwood, T. Clase library download and screenshots, (Online), 2008, http://www.zonetora.co.uk/NonBlog/toral/lib/.Google Scholar
- de Bruijn, N. G. Lambda calculus notation with nameless dummies. a tool for automatic formula manipulation with application to the Church-Rosser Theorem, in Indagationes Mathematicae (34) 381--392, 1972Google Scholar
- Manuel M. T. Chakravarty, Gabriele Keller, Simon Peyton Jones, and Simon Marlow. Associated types with class. In POPL '05: Proceedings of the 32nd ACM SIGPLAN-SIGACT symposium on Principles of Programming Languages, pages 1--13, 2005. ACM Press. Google Scholar
Digital Library
- Tim Sheard and Simon Peyton Jones. Template metaprogramming for Haskell. In ACM SIGPLAN Haskell Workshop 02. Pages 1--16, 2002. ACM Press. Google Scholar
Digital Library
- C. McBride. The derivative of a regular type is its type of one-hole contexts. Unpublished manuscript, 2001.Google Scholar
Index Terms
Clase: cursor library for a structured editor
Recommendations
Clase: cursor library for a structured editor
HASKELL '08The zipper is a well known design pattern for providing a cursor-like interface to a data structure. However, the classic treatise by Huet (1) only scratches the surface of some of the potential applications of the zipper. In this work we have taken ...
Strengthening the Zipper
The zipper is a well known design pattern for providing a cursor-like interface to a data structure. However, the classic treatise by Huet only scratches the surface of some of its potential applications. In this paper we take inspiration from Huet, and ...
One-Handed Interaction Technique for Single-Touch Gesture Input on Large Smartphones
SUI '19: Symposium on Spatial User InteractionWe propose a one-handed interaction technique using cursor based on touch pressure to enable users to perform various single-touch gestures such as a tap, swipe, drag, and double-tap on unreachable targets. In the proposed technique, cursor mode is ...







Comments