What is emacs canvas and how does it work?
Emacs Canvas (patch) on reddit
From my understanding of how programs draw to screens, it seems that Emacs canvas provides a video buffer to external graphics programs or libraries so that instead of drawing to the regular screen, they draw inside a video buffer created and displayed within Emacs.
The equivalent I can think of is the case of VNC or Xpra where a program uses a $DISPLAY which is rendered remotely on the client.
Would that mean that getting a program to run in a canvas would be along the lines:
(emacs-create-canvas height width buffer-name "/usr/bin/random-gui-program -param 1 -param -2")?
I suppose there would be some additional parameters relating to passing key strokes, controlling window movement and size etc.