From 72e3b59bb7eeb14956217e065e1aedfe401b764a Mon Sep 17 00:00:00 2001 From: Humza Shahid Date: Tue, 2 Sep 2025 02:18:14 +0100 Subject: [PATCH] because GLFW at this time has clipboard bugs on Wayland (setting clipboard string), we print out whenever the shell receives a 'yank' message indicating for GLFW to copy. This will let us test that the correct string is yanked. --- shell/gl-draw.sml | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/shell/gl-draw.sml b/shell/gl-draw.sml index f773145..59d0166 100644 --- a/shell/gl-draw.sml +++ b/shell/gl-draw.sml @@ -229,7 +229,15 @@ struct end fun yank (shellState: t, str) = - (Glfw.setClipboardString (#window shellState, str); shellState) + let + (* print when text is yanked *) + val msg = String.toCString str + val () = print msg + val () = print "\n" + val () = Glfw.setClipboardString (#window shellState, str) + in + shellState + end fun consumeDrawEvent (shellState, msg) = let