Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

stgettermwidth(3) [debian man page]

stuserio(3)						    ShapeTools Toolkit Library						       stuserio(3)

NAME
stLog, stQuietFlag, stShutupFlag, stProgramName, stMessage, stGetFromStdin, stAskConfirm, stGetTermWidth - user interaction SYNOPSIS
#include <config.h> #include <sttk.h.h> voidstLog (char *logMsg, int logType); int stQuietFlag; int stShutupFlag; char*stProgramName; charstMessage[]; char*stGetFromStdin (int termChar); int stAskConfirm (char *message, char *defaultAnswer); int stGetTermWidth (int fdes); DESCRIPTION
These functions do the dialogue with the user. stLog outputs a message to the user's terminal. The message text is given in the logMsg buf- fer. logType is one of ST_LOG_MSG Message to be sent to standard output. ST_LOG_MSGERR Message to be sent to standard error. ST_LOG_WARNING Warning message, preceded by the string `programName - warning:', going to standard error. ST_LOG_ERROR Error message, preceded by the string `programName - error:', going to standard error. Additionally, when the flag ST_LOG_NONL is ored to the message type (e.g. `ST_LOG_MSG | ST_LOG_NONL'), the message is printed without adding a newline character. Otherwise, a newline is always added. Whether a message really makes it's way to the user, depends on the variables stQuietFlag and stShutupFlag. When stQuietFlag is set to a non null value, all messages except error messages (ST_LOG_ERROR) will be suppressed. With the stShutupFlag set to a null value, all mes- sages will be suppressed. Initially, both flags are set to NULL. The stProgramName pointer should be set pointing to a buffer containing the name how the program was called. It is used for composing proper error messages and warnings (see above). stMessage is a buffer for constructing messages using sprintf(3). It is designed to be large enough to hold a file's pathname and an addi- tional short message. It's size is MAXPATHLEN+128. stGetFromStdin reads from stdin a text terminated by ^D or by the specified single character termChar at the beginning of a new line. If termChar is -1 text is terminated by ^D. stAskConfirm returns true if the answer is equivalent to defaultAnswer (assumption). stGetTermWidth returns the actual with of the user's termainal in columns. BUGS
stGetTermWidth will not work on all machines properly. In it's current implementation, it is quite SUN specific. sttk-1.7 Thu Jun 24 17:43:39 1993 stuserio(3)

Check Out this Related Man Page

sttk_intro(3)						    ShapeTools Toolkit Library						     sttk_intro(3)

NAME
sttk_intro - introduction to the ShapeTools Toolkit Library SYNOPSIS
#include <config.h> #include <sttk.h> char* stVersion (void); DESCRIPTION
The ShapeTools Toolkit library (sttk) is a set of functions to be used in various parts of the ShapeTools configuration management toolkit. Inclusion of config.h may be omitted when atfs.h is included. stVersion returns a version identification string for the ShapeTools Toolkit library. LIST OF FUNCTIONS AND VARIABLES
Name Appears on PageDescription stAbortThis sttransaction.3abort transaction stAskConfirm stuserio.3 ask user for confirmation stCallCmd stcall.3 call command stCallCmdErrno stcall.3error code returned by command (variable) stCallEditor stcall.3 call editor with default contents stCatchSigs stsignal.3 catch signals stCleanup stsignal.3 do cleanup (remove temporary files etc.) stConvertPattern ststring.3convert sh(1) pattern to regex pattern stExit stsignal.3 stop program execution stFindProgram stcall.3 check if file exists and is executable stGetFromStdin stuserio.3read text from standard input stGetTermWidth stuserio.3get current terminal width in columns stInterruptAction stsignal.3address of signal handler for SIGINT (variable) stLog stuserio.3 print message stMessage stuserio.3 buffer for constructing messages (variable) stMktime sttime.3 parse time string stParseArgs stparseargs.3 parse command line arguments stProgramName stuserio.3 name how program was called stQuietFlag stuserio.3 suppress normal messages (no error messages) (variable) stQuitAction stsignal.3 address of signal handler for SIGQUIT (variable) stRegisterFile sttmpfiles.3register file stRmRegisteredFiles sttmpfiles.3remove all registered files stShortUsage stparseargs.3 print usage string stShutupFlag stuserio.3 supress all messages (variable) stStrEnter ststring.3 enter string to string table stStrtok ststring.3 tokenize string stSubstituteString ststring.3replace parts of a string by new string stTermAction stsignal.3 address of signal handler for SIGTERM (variable) stThisTransaction sttransaction.3current transaction (variable) stTmpFile sttmpfiles.3 return unique name for temporary file stUnRegisterFile sttmpfiles.3unregister file stVersion sttkintro.3 print version identification string stWriteTime sttime.3 generate time string SEE ALSO
Andreas Lampen and Axel Mahler (Eds.) ShapeTools, Technical Report No. 92-14, Technische Universitat Berlin, May 1992 sttk-1.7 Thu Jun 24 17:43:28 1993 sttk_intro(3)
Man Page