The screen command manages display areas and windows. Layout is persisted only on the device, never in the cloud — query it with list when needed. The old oper key has been renamed to action (see this book's home page).
Layout Operations
actionSampleNotes
add{"screen":{"action":"add","area":"a5","position":[0,0,960,540]}}Add an area; omitting area auto-names it (fills gaps from a1); position may carry a 5th layer value. Reply carries the assigned name and position
update{"screen":{"action":"update","area":"a5","position":[0,0,1280,720,2]}}Change position/size (including layer)
rename{"screen":{"action":"rename","area":"a5","name":"a6"}}Rename (letters+digits, unique, never "default"; renaming the default area moves the default along)
remove{"screen":{"action":"remove","area":"a5"}}Remove the area; the last area cannot be removed (error)
default{"screen":{"action":"default","area":"a5"}}Make it the default display area
default{"screen":{"action":"default"}}Query the current default area → {"default":"a1"}
list{"screen":{"action":"list"}}Query all areas → {"a5":[t,l,w,h,layer],...} (pixels)
display{"screen":{"action":"display"}}Query physical monitor composition (virtual coordinates, origin = top-left of the bounding box) → [[t,l,w,h],...]
info{"screen":{"action":"info","area":"a6"}}Query one area → [t,l,w,h,layer] (pixels); {"screen":{"area":"a6"}} is a shorthand (both forms supported); without area it equals list
Window Operations (three states)

Every display area is in one of three states: closed / open-visible / open-hidden. A command takes effect only on a legal transition; illegal transitions answer {"ret":"error","msg":"invalid state"}. The old keys minimize/restore are deprecated (no compatibility).

actionSampleNotes
clear{"screen":{"action":"clear","area":"a5"}}Any state: clear the area's content (back to placeholder, keeps the area); without area, clears all
open{"screen":{"action":"open","area":"a5"}}Only from closed: open the window; restores the previous content when "Restore on launch" is enabled
close{"screen":{"action":"close","area":"a5"}}Only from open (visible or hidden): destroy the window but keep the content record (Android single-window: clears the window, keeps the record)
hide{"screen":{"action":"hide","area":"a5"}}Only from open-visible: hide the window without destroying it — content stays loaded (Android: hidden)
show{"screen":{"action":"show","area":"a5"}}Only from open-hidden: make the window visible again; no content restore involved

Without an area the command applies to all areas (executed on each legal target).

Notes
  • On first launch the player auto-creates area a1 covering the whole monitor and makes it the default; at least one area must exist
  • On desktop each area is an independent window instance; Android is single-window (close-all = clear content, hide = hide)
  • An area without content shows a grey translucent placeholder (name, resolution, position)
  • Validation: names are letters+digits and unique; areas stay in bounds (0~1 after conversion). Failures answer {"ret":"error","msg":...}
  • Either side (on-device editor or cloud command) changing the layout makes the device emit a change event (data is [] on removal)