conio.h

conio.h

conio.h is a C header file used in old MS-DOS compilers to create text user interfaces. It is not described in The C Programming Language book, and it is not part of the C standard library, ISO C nor is it required by POSIX.

This header declares several useful library functions for performing "console input and output" from a program. Most C compilers that target DOS, Windows 3.x, Phar Lap, DOSX, OS/2, or Win32[1] have this header and supply the associated library functions in the default C library. Most C compilers that target UNIX and Linux do not have this header and do not supply the library functions. Some embedded systems are using a conio-compatible library [2].

The library functions declared by conio.h vary somewhat from compiler to compiler. As originally implemented in Lattice C, the various functions mapped directly to the first few DOS int 21h functions. But the library supplied with Borland's Turbo C did not use the DOS API but instead accessed video RAM directly for output and used BIOS interrupt calls; they also have additional functions inspired on the successful Turbo Pascal library.

Compilers that targeted non-DOS operating systems, such as Linux[citation needed], Win32 and OS/2, provided different implementations of these functions.[citation needed] The version done by DJ Delorie for the GO32 extender is particularly extensive[3]. Another example is SyncTERM's ciolib.

lpc

int kbhit(void) Determines if a keyboard key was pressed.
int getch(void) Reads a character directly from the console without buffer, and without echo.
int getche(void) Reads a character directly from the console without buffer, but with echo.
int ungetch(int c) Puts the character c back into the keyboard buffer.
char *cgets(char *buffer) Reads a string directly from the console.
int cscanf(char *format, arg0,... argn) Reads formatted values directly from the console.
int putch(int c) Writes a character directly to the console.
int cputs(const char *string) Writes a string directly to the console.
int cprintf(const char *format, arg0,... argn) Formats values and writes them directly to the console.


Compilers provided later than 1989 have prepended an _ to the names, to comply with the requisites of the ANSI C Standard.

References

External links


Wikimedia Foundation. 2010.

Игры ⚽ Нужна курсовая?

Look at other dictionaries:

  • Conio.h — is a header file used in old MS DOS compilers to create text user interfaces, however, it is not part of the C programming language, the C standard library, ISO C or required by POSIX.This header declares several useful library functions for… …   Wikipedia

  • Conio.h — (от англ. console input output  консольный ввод вывод)  заголовочный файл, используемый в старых компиляторах, работающих в операционных системах MS DOS, для создания текстового интерфейса пользователя. Тем не менее, он не является… …   Википедия

  • conio.h — (от англ. console input output  консольный ввод вывод)  заголовочный файл, используемый в старых компиляторах, работающих в операционных системах MS DOS, для создания текстового интерфейса пользователя. Тем не менее, он не является …   Википедия

  • conio — Element prim de compunere savantă cu semnificaţia praf , în legătură cu praful , de (la) praf . [pron. ni o , var. coni . / < fr. conio , cf. gr. konis – praf]. Trimis de LauraGellner, 18.01.2005. Sursa: DN …   Dicționar Român

  • Conio... — Conio... (v. gr. Konia, Staub), Staub …   Pierer's Universal-Lexikon

  • conio — / kɔnjo/ s.m. [lat. cŭneus ]. 1. a. [utensile per stampare monete o medaglie] ▶◀ punzone. ⇑ stampo. b. [operazione ed effetto del coniare, anche fig.] ▶◀ battitura, coniatura, coniazione. 2. (fig., spreg.) …   Enciclopedia Italiana

  • conio — 1cò·nio s.m. CO 1a. stampo in acciaio a forma di punzone su cui vengono incisi disegni, figure o iscrizioni che si vogliono imprimere in rilievo su monete o medaglie; l impronta che ne risulta: riconoscere una moneta dal conio 1b. l operazione… …   Dizionario italiano

  • conio — s. m. 1. punzone, torsello 2. (est.) impronta, stampo 3. cuneo, zeppa 4. coniazione, coniatura FRASEOLOGIA fior di conio, moneta che non ha mai circolato □ nu …   Sinonimi e Contrari. Terza edizione

  • conio — {{hw}}{{conio}}{{/hw}}s. m. 1 Operazione del coniare. 2 Pezzo di acciaio su cui è inciso il tipo che si vuole riprodurre sulla moneta o medaglia | Impronta fatta col conio | Fior di –c, di moneta che non ha mai circolato | Nuovo di –c, nuovissimo …   Enciclopedia di italiano

  • conio — pl.m. coni …   Dizionario dei sinonimi e contrari

Share the article and excerpts

Direct link
Do a right-click on the link above
and select “Copy Link”