Contents

AutoHelp

AutoHelp

__AutoHelp_init

Syntax

void __AutoHelp_init(__AutoHelp_t* VPtr, __AutoHelpEntry_t* Rules, int NRules,
		     LabelProc_t DispProc, void* DispProcData)

Description

Fills in the structure.

__AutoHelp_load

Syntax

int __AutoHelp_load(const char *Path, __AutoHelpEntry_t**Rules, size_t* NRules)

Description

Opens the specified file and reads in the table of help information

Return Value

-1 on error, 0 on success

ssize_t _screen_write (void* SPtr, const char* anchor, size_t Size)

Description

Screen write redirector. We user this to support almost all of the VT100 terminal codes, including colorization. The ANSI escape sequences into calls to macro functions (possibly curses) which change text attributes. A non-zero value is then returned to the caller to signal that the output has been handled.

The buffer pointed to by anchor must be zero terminated.

Return Value

-1 on error, >= 0 is the number of bytes processed.

__AutoHelp_text

Syntax

void __AutoHelp_text(__AutoHelp_t* VPtr, const char* Text)

Description

Given the text, finds a matching helpful hint and displays it (if possible).


Author: Randall Maastop