Win32-2.14.2.2: A binding to Windows Win32 API.
Copyright(c) University of Glasgow 2006
LicenseBSD-style (see the file LICENSE)
MaintainerEsa Ilari Vuokko <ei@vuokko.info>
Stabilityprovisional
Portabilityportable
Safe HaskellTrustworthy
LanguageHaskell2010

System.Win32.Console

Description

A collection of FFI declarations for interfacing with Win32 Console API

Synopsis

Console mode

Console code pages

Ctrl events

Command line

commandLineToArgv :: String -> IO [String] Source #

This function can be used to parse command line arguments and return the split up arguments as elements in a list.

getArgs :: IO [String] Source #

Based on GetCommandLineW. This behaves slightly different than getArgs. See the online documentation: https://learn.microsoft.com/en-us/windows/win32/api/processenv/nf-processenv-getcommandlinew

Screen buffer

data CONSOLE_SCREEN_BUFFER_INFO Source #

data CONSOLE_SCREEN_BUFFER_INFOEX Source #

Constructors

CONSOLE_SCREEN_BUFFER_INFOEX 

Fields

data COORD Source #

Constructors

COORD 

Fields

Instances

Instances details
Eq COORD Source # 
Instance details

Defined in System.Win32.Console.Internal

Methods

(==) :: COORD -> COORD -> Bool Source #

(/=) :: COORD -> COORD -> Bool Source #

Storable COORD Source # 
Instance details

Defined in System.Win32.Console.Internal

Show COORD Source # 
Instance details

Defined in System.Win32.Console.Internal

Env

Console I/O

newtype WINDOW_BUFFER_SIZE_RECORD Source #

This type represents a window size change event. The structure is documented here: https://learn.microsoft.com/en-us/windows/console/window-buffer-size-record-str

readConsoleInput :: HANDLE -> Int -> Ptr INPUT_RECORD -> IO Int Source #

Reads all available input records up to the amount specified by the len parameter.