Copyright | Will Thompson, Iñaki García Etxebarria and Jonas Platte |
---|---|
License | LGPL-2.1 |
Maintainer | Iñaki García Etxebarria (garetxe@gmail.com) |
Safe Haskell | None |
Language | Haskell2010 |
GI.Vte.Objects.Pty
Contents
Description
- newtype Pty = Pty (ManagedPtr Pty)
- class GObject o => IsPty o
- toPty :: IsPty o => o -> IO Pty
- noPty :: Maybe Pty
- data PtyChildSetupMethodInfo
- ptyChildSetup :: (HasCallStack, MonadIO m, IsPty a) => a -> m ()
- data PtyCloseMethodInfo
- ptyClose :: (HasCallStack, MonadIO m, IsPty a) => a -> m ()
- data PtyGetFdMethodInfo
- ptyGetFd :: (HasCallStack, MonadIO m, IsPty a) => a -> m Int32
- data PtyGetSizeMethodInfo
- ptyGetSize :: (HasCallStack, MonadIO m, IsPty a) => a -> m (Int32, Int32)
- ptyNewForeignSync :: (HasCallStack, MonadIO m, IsCancellable a) => Int32 -> Maybe a -> m Pty
- ptyNewSync :: (HasCallStack, MonadIO m, IsCancellable a) => [PtyFlags] -> Maybe a -> m Pty
- data PtySetSizeMethodInfo
- ptySetSize :: (HasCallStack, MonadIO m, IsPty a) => a -> Int32 -> Int32 -> m ()
- data PtySetUtf8MethodInfo
- ptySetUtf8 :: (HasCallStack, MonadIO m, IsPty a) => a -> Bool -> m ()
- data PtyFdPropertyInfo
- constructPtyFd :: IsPty o => Int32 -> IO (GValueConstruct o)
- getPtyFd :: (MonadIO m, IsPty o) => o -> m Int32
- ptyFd :: AttrLabelProxy "fd"
- data PtyFlagsPropertyInfo
- constructPtyFlags :: IsPty o => [PtyFlags] -> IO (GValueConstruct o)
- getPtyFlags :: (MonadIO m, IsPty o) => o -> m [PtyFlags]
- ptyFlags :: AttrLabelProxy "flags"
Exported types
Constructors
Pty (ManagedPtr Pty) |
Instances
GObject Pty Source # | |
IsInitable Pty Source # | |
IsObject Pty Source # | |
IsPty Pty Source # | |
((~) * info (ResolvePtyMethod t Pty), MethodInfo * info Pty p) => IsLabel t (Pty -> p) Source # | |
((~) * info (ResolvePtyMethod t Pty), MethodInfo * info Pty p) => IsLabelProxy t (Pty -> p) Source # | |
HasAttributeList * Pty Source # | |
type AttributeList Pty Source # | |
type SignalList Pty Source # | |
Methods
childSetup
data PtyChildSetupMethodInfo Source #
Instances
((~) * signature (m ()), MonadIO m, IsPty a) => MethodInfo * PtyChildSetupMethodInfo a signature Source # | |
Arguments
:: (HasCallStack, MonadIO m, IsPty a) | |
=> a |
|
-> m () |
FIXMEchpe
close
data PtyCloseMethodInfo Source #
Instances
((~) * signature (m ()), MonadIO m, IsPty a) => MethodInfo * PtyCloseMethodInfo a signature Source # | |
Arguments
:: (HasCallStack, MonadIO m, IsPty a) | |
=> a |
|
-> m () |
Deprecated: (Since version 0.42)
Since 0.42 this is a no-op.
getFd
data PtyGetFdMethodInfo Source #
Instances
((~) * signature (m Int32), MonadIO m, IsPty a) => MethodInfo * PtyGetFdMethodInfo a signature Source # | |
Arguments
:: (HasCallStack, MonadIO m, IsPty a) | |
=> a |
|
-> m Int32 | Returns: the file descriptor of the PTY master in |
No description available in the introspection data.
getSize
data PtyGetSizeMethodInfo Source #
Instances
((~) * signature (m (Int32, Int32)), MonadIO m, IsPty a) => MethodInfo * PtyGetSizeMethodInfo a signature Source # | |
Reads the pseudo terminal's window size.
If getting the window size failed, error
will be set to a IOError
.
newForeignSync
Arguments
:: (HasCallStack, MonadIO m, IsCancellable a) | |
=> Int32 |
|
-> Maybe a |
|
-> m Pty | Returns: a new |
newSync
Arguments
:: (HasCallStack, MonadIO m, IsCancellable a) | |
=> [PtyFlags] |
|
-> Maybe a |
|
-> m Pty | Returns: a new |
Allocates a new pseudo-terminal.
You can later use fork()
or the spawnAsync
family of functions
to start a process on the PTY.
If using fork()
, you MUST call ptyChildSetup
in the child.
If using spawnAsync
and friends, you MUST either use
ptyChildSetup
directly as the child setup function, or call
ptyChildSetup
from your own child setup function supplied.
When using terminalSpawnSync
with a custom child setup
function, ptyChildSetup
will be called before the supplied
function; you must not call it again.
Also, you MUST pass the SpawnFlagsDoNotReapChild
flag.
setSize
data PtySetSizeMethodInfo Source #
Instances
((~) * signature (Int32 -> Int32 -> m ()), MonadIO m, IsPty a) => MethodInfo * PtySetSizeMethodInfo a signature Source # | |
Arguments
:: (HasCallStack, MonadIO m, IsPty a) | |
=> a |
|
-> Int32 |
|
-> Int32 |
|
-> m () | (Can throw |
Attempts to resize the pseudo terminal's window size. If successful, the
OS kernel will send SIGWINCH
to the child process group.
If setting the window size failed, error
will be set to a IOError
.
setUtf8
data PtySetUtf8MethodInfo Source #
Instances
((~) * signature (Bool -> m ()), MonadIO m, IsPty a) => MethodInfo * PtySetUtf8MethodInfo a signature Source # | |
Arguments
:: (HasCallStack, MonadIO m, IsPty a) | |
=> a |
|
-> Bool |
|
-> m () | (Can throw |
Tells the kernel whether the terminal is UTF-8 or not, in case it can make use of the info. Linux 2.6.5 or so defines IUTF8 to make the line discipline do multibyte backspace correctly.
Properties
fd
data PtyFdPropertyInfo Source #
Instances
constructPtyFd :: IsPty o => Int32 -> IO (GValueConstruct o) Source #
ptyFd :: AttrLabelProxy "fd" Source #
flags
data PtyFlagsPropertyInfo Source #
Instances
constructPtyFlags :: IsPty o => [PtyFlags] -> IO (GValueConstruct o) Source #
ptyFlags :: AttrLabelProxy "flags" Source #