diff options
Diffstat (limited to 'test/macos-snapshots')
| -rw-r--r-- | test/macos-snapshots/opacity.golden | 29 | ||||
| -rw-r--r-- | test/macos-snapshots/opacity.snap | 34 |
2 files changed, 63 insertions, 0 deletions
diff --git a/test/macos-snapshots/opacity.golden b/test/macos-snapshots/opacity.golden new file mode 100644 index 00000000..b28c6e0c --- /dev/null +++ b/test/macos-snapshots/opacity.golden @@ -0,0 +1,29 @@ +== draw-opacity solid 680x396 alpha 255..255 +== snap translucent grid=80x24 cursor=4,3 +|Newcol Joincol Find Grep Help Changelog Tutor Dump NextColor Debug Kill +| New Tty Find Grep Joincol +|$ /private/tmp/pardes-macos-e2e/opacity/cwd Tty Save Del Mode Filter Collapse +| $ +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +== draw-opacity translucent 680x396 alpha 153..255 +== draw-opacity clear 680x396 alpha 0..255 +== draw-opacity restored 680x396 alpha 255..255 diff --git a/test/macos-snapshots/opacity.snap b/test/macos-snapshots/opacity.snap new file mode 100644 index 00000000..0f73cb17 --- /dev/null +++ b/test/macos-snapshots/opacity.snap @@ -0,0 +1,34 @@ +# WindowOpacity, end to end: the builtin the core only offers to a shell that +# declared the capability (src/builtins.zig), through pardes_window_opacity, +# to the alpha CoreGraphics actually left in the framebuffer. +# +# The contract is two-sided and shaders/ui.frag.glsl states it for the SDL +# shell: BACKGROUNDS take the percentage, glyph ink never does. `draw-opacity` +# records both ends of the range so a regression that made the whole window +# translucent — text included — reads as a changed maximum, not as a pass. +start 24 80 +wait 8000 Newcol Joincol +wait 8000 $ +stable 700 20000 + +# Opaque is the default, and an opaque view caches without an alpha channel +# at all. +draw-opacity solid + +# Backgrounds drop to 60%; the prompt and the chrome text stay at 255. +command WindowOpacity 60 +stable 700 20000 +snap translucent +draw-opacity translucent + +# 0 is the extreme the block cursor exists to survive: every background is +# gone and the ink is still there. +command WindowOpacity 0 +stable 700 20000 +draw-opacity clear + +# ...and back, which must restore an opaque view rather than leave a window +# that is merely painting 100% alpha into a transparent surface. +command WindowOpacity 100 +stable 700 20000 +draw-opacity restored |
