00001 /* @(#)root/clib:$Id: Getline.h 20882 2007-11-19 11:31:26Z rdm $ */ 00002 /* Author: */ 00003 00004 /************************************************************************* 00005 * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. * 00006 * All rights reserved. * 00007 * * 00008 * For the licensing terms see $ROOTSYS/LICENSE. * 00009 * For the list of contributors see $ROOTSYS/README/CREDITS. * 00010 *************************************************************************/ 00011 00012 #ifndef ROOT_Getline 00013 #define ROOT_Getline 00014 00015 #ifndef ROOT_DllImport 00016 #include "DllImport.h" 00017 #endif 00018 00019 #ifndef __CINT__ 00020 #ifdef __cplusplus 00021 extern "C" { 00022 #endif 00023 #endif 00024 00025 typedef enum { kInit = -1, kLine1, kOneChar, kCleanUp } EGetLineMode; 00026 00027 char *Getline(const char *prompt); 00028 char *Getlinem(EGetLineMode mode, const char *prompt); 00029 void Gl_config(const char *which, int value); 00030 void Gl_setwidth(int width); 00031 void Gl_windowchanged(); 00032 void Gl_histsize(int size, int save); 00033 void Gl_histinit(char *file); 00034 void Gl_histadd(char *buf); 00035 int Gl_eof(); 00036 00037 R__EXTERN int (*Gl_in_hook)(char *buf); 00038 R__EXTERN int (*Gl_out_hook)(char *buf); 00039 R__EXTERN int (*Gl_tab_hook)(char *buf, int prompt_width, int *cursor_loc); 00040 R__EXTERN int (*Gl_beep_hook)(); 00041 R__EXTERN int (*Gl_in_key)(int key); 00042 00043 #ifndef __CINT__ 00044 #ifdef __cplusplus 00045 } 00046 #endif 00047 #endif 00048 00049 #endif