From Tokens to Structure: Investigating Visual Attention in Progressive Code Rendering
Xiaotian Su, Jan Brasser, David Robert Reich, Lena A. Jäger, April Yi Wang
Abstract
AI coding interfaces present generated code either all at once or token-by-token. These rendering strategies reflect model generation rather than how programmers actually read code: selectively, non-linearly, and guided by the structure. We argue that code rendering is a first-class interaction primitive that shapes how programmers read and understand code. To explore this design space, we introduce structured rendering, a technique that reveals code in semantically meaningful chunks derived from its syntactic hierarchy, exposing high-level structure before low-level details. To isolate rendering effects on visual attention, we conducted an eye-tracking study with 53 participants comparing static, character-based, and structured rendering. Our findings show that rendering alters visual attention and reading behavior: dynamic rendering induces fewer but longer fixations and more sustained focus, while structured rendering further guides attention toward semantically meaningful units and supports high-level understanding. We release the anonymized dataset with an interactive demo (https://codegaze.vercel.app/) to support future research.
Create a lesson
Related papers
AtoMix: Fostering Structured Visual Ideation for Remote Groups through Atomic Composition and Cross-Pollination
Shared title terminologycs.HCHeeji Jolie Kim, Anam Ahmad Khan, SeungHui Huh et al.
Beyond Average Gains: Probing the Equity--Vulnerability Tension in Structured Visual AI for Learning
Shared title terminologycs.HCMingyuan Li, Duan Wang, Erick Purwanto et al.
Beyond Heatmaps: Evaluating More Effective Feature Interaction Visualizations for Generalized Additive Models
Shared title terminologycs.HCNico Hambauer, Julian Rosenberger, Maximilian Veitl et al.
AI Coding Agents and Web Accessibility: Keyboard and Screen-Reader Access to Public-Benefit Forms
Shared title terminologycs.HCShirshak Jung Thapa
FITVis: Shareable Fitness Intensity over Time Visualization
Shared title terminologycs.HCMara Solen, Thomas James Davidson, Emily Wall et al.
Deviations From the Norm: Provoking Epistemological Clashes through Alternatively-Designed Museum Visual Fingerprints
Shared title terminologycs.HCMara Solen, Paul H. Bucci, Tamara Munzner