Method

IdePtyInterceptinit

Declaration

gboolean
ide_pty_intercept_init (
  IdePtyIntercept* self,
  IdePtyFd fd,
  GMainContext* main_context
)

Description

Creates a enw IdePtyIntercept using the PTY consumer fd fd.

A new PTY producer is created that will communicate with fd. Additionally, a new PTY consumer is created that can communicate with another side, and will pass that information to fd after extracting any necessary information.

Parameters

fd

Type: IdePtyFd

The PTY consumer fd, possibly from a VtePty.

main_context

Type: GMainContext

A GMainContext or NULL for thread-default.

The argument can be NULL.
The data is owned by the caller of the method.

Return value

Type: gboolean

TRUE if successful; otherwise FALSE.