moo.sdk.output.open_editor

moo.sdk.output.open_editor(obj, initial_content, callback_verb, *args, content_type='text', title=None)

Request the connected SSH client to open a full-screen text editor. When the user saves, the edited text is passed to callback_verb as args[0], followed by any extra positional arguments supplied here. If the user cancels, the callback is not invoked.

Parameters:
  • obj – the player Object whose client should open the editor

  • initial_content (str) – text to pre-populate the editor buffer

  • callback_verb – Verb to invoke with the edited text as args[0]

  • args – additional arguments forwarded to the callback verb as args[1:]

  • content_type (str) – “python”, “json”, or “text” (default); controls syntax highlighting