/* * Help functions for sc * R. Bond, 1988 * J. Buhrt 1990 * $Revision: 6.21 $ */ #ifdef QREF #include char *header = " Quick Reference"; char *revision = "$Revision: 6.21 $"; #else #include #include "sc.h" #endif /* QREF */ char *intro[] = { " ", #if defined(QREF) && defined(TROFF) ".SH", #endif " Overview:", " ", #if defined(QREF) && defined(TROFF) ".Lp", #endif " A: This overview", " B: Toggle Options", " C: Set Options", " D: Cursor movement commands", " E: Cell entry and editing commands", " F: Line Editing", " G: File commands", " H: Row and column commands", " I: Range commands", " J: Miscellaneous commands", " K: Variable names/Expressions", " L: Range functions", " M: Numeric functions", " N: String functions", " O: Financial functions", " P: Time and date functions", " ", " Q: Return to main spreadsheet", (char *)0 }; char *toggleoptions[] = { " ", #if defined(QREF) && defined(TROFF) ".SH", #endif " B: Toggle Options", " ", #if defined(QREF) && defined(TROFF) ".Lp", #endif " ^To Toggle options. Toggle one option selected by o:", " a Recalculate automatically or on ``@'' commands.", " c Current cell highlighting enable/disable.", " e External function execution enable/disable.", " l Autolabeling defined cells enable/disable.", " n If enabled, a digit starts a numeric value.", " t Top line display enable/disable.", #if !defined(VMS) && !defined(MSDOS) && defined(CRYPT_PATH) " x Encrypt/decrypt database and listing files.", #else " x Encrypt/decrypt database and listing files (Not available).", #endif " $ Dollar prescale. If enabled, all numeric constants", " (not expressions) entered are multipled by 0.01.", " r Newline action. Toggle between no action, move down", " after entry and move right after entry.", " z Set the newline action limits to the current row and column", " (for r && z see also set rowlimit=n, collimit=n)", (char *)0 }; char *setoptions[] = { " ", #if defined(QREF) && defined(TROFF) ".SH", #endif " C: Set Options", " ", #if defined(QREF) && defined(TROFF) ".Lp", #endif " S Set options. Options include:", " byrows Recalculate in row order. (default)", " bycols Recalculate in column order.", " iterations=n Set the number of iterations allowed. (10)", " tblstyle=xx Set ``T'' output style to:", " 0 (none), tex, latex, slatex, or tbl.", " rndinfinity Round to infinity (round .5 up vs to nearest even).", " rowlimit=n Set the remembered row limit for newline action.", " collimit=n Set the remembered column limit for newline action.", " (rowlimit and collimit can both be set by ^Tz)", (char *)0 }; char *cursor[] = { " ", #if defined(QREF) && defined(TROFF) ".SH", #endif " D: Cell cursor movement (always OK):", " ", #if defined(QREF) && defined(TROFF) ".Lp", #endif " ^N ^P ^B ^F Down, up, back, forward", " ^Ed Go to end of range. Follow ^E by a direction indicator", " such as ^P or j.", " Arrow keys (if the terminal and termcap support them.)", " ", " Cell cursor movement if no prompt active:", " j,k,l,h Down, up, right, left", " J,K,L,H Down, up, right, left by 1/2 pages", " SPACE Forward", " ^H Back", " TAB Forward, otherwise starts/ends a range", " ^ Up to row 0 of the current column.", " # Down to the last valid row of the current column.", " 0 Back to column A. Preface with ^U if numeric mode.", " $ Forward to the last valid column of the current row.", " b Back then up to the previous valid cell.", " w Forward then down to the next valid cell.", " g Go to a cell. Cell name, range name, quoted string,", " a number, 'error', or 'invalid' to specify which cell.", (char *)0 }; char *cell[] = { " ", #if defined(QREF) && defined(TROFF) ".SH", #endif " E: Cell entry and editing commands:", " ", #if defined(QREF) && defined(TROFF) ".Lp", #endif " = Enter a numeric constant or expression.", " < Enter a left justified string or string expression.", " \" Enter a centered label.", " > Enter a right justified string or string expression.", " e Edit the current cell's numeric value.", " E Edit the current cell's string part.", " F Assign a format to the current cell's numeric value.", " x Clear the current cell.", " c Copy the last marked cell to the current cell.", " m Mark a cell to be used as the source for ``c''", " + Increment numeric part", " - Decrement numeric part", " RETURN Enter insert mode if the input line was empty (ESC to edit)", " ", " In numeric mode, a decimal digit, ``+'', ``-'', and ``.'' all start", " a new numeric constant or expression.", (char *)0 }; char *vi[] = { " ", #if defined(QREF) && defined(TROFF) ".SH", #endif " F: Line Editor", " ", #if defined(QREF) && defined(TROFF) ".Lp", #endif " Hitting the ESC key while entering any command on the top line", " will start a one-line vi-style editor. Supported commands:", " ", " ESC q Abort command entry.", " h l Move cursor forward, backward.", " 0 $ Move cursor to the beginning, end of the line.", " b w Move cursor forward/back one word.", " fc Move cursor to character c.", " tc Move the cursor the the character before c.", " i a Enter insert mode before/after the cursor.", " I A Move to column 0/end of line and enter insert mode.", " x X Delete the character under/before the cursor.", " rc Replace the character under the cursor with c.", " cm Change - m = b,f,h,l,t or w.", " dm Delete - m = b,f,h,l,t or w.", " R Enter replace (overstrike) mode.", " + j - k / Forward/backward/search the command history.", " n Repeat last history search.", " . u Repeat/undo the last command.", (char *)0 }; char *file[] = { " ", #if defined(QREF) && defined(TROFF) ".SH", #endif " G: File commands:", " ", #if defined(QREF) && defined(TROFF) ".Lp", #endif " G Get a new database from a file. ", " M Merge a new file into the current database.", " P Put the current database into a file.", " W Write a listing of the current database into a file in", " a form that matches its appearance on the screen.", " T Write a listing of the current database to a file, but", " put delimiters between each pair of fields.", " Optionally brackets output with control lines for ``tbl'',", " ``LaTeX'', ``SLaTex'', or ``TeX''.", " ", #if !defined(VMS) && !defined(MSDOS) && defined(CRYPT_PATH) " If encryption mode is set, file I/O will be encrypted/decrypted.", " ``\"| program\"'' for a file name will pipe (unencrypted) output to", #else " ``\"| program\"'' for a file name will pipe output to", #endif " a program for Put, Write and Table. If a cell name is used", " as the file name, the cell's string part will be used as the", " file name.", (char *)0 }; char *row[] = { " ", #if defined(QREF) && defined(TROFF) ".SH", #endif " H: Row and column commands:", " ", #if defined(QREF) && defined(TROFF) ".Lp", #endif " ir, ic Insert a new, empty row (column)", " ar, ac Append a new copy of the current row (column)", " dr, dc Delete the current row (column)", " pr, pc, pm Pull deleted cells back into the spreadsheet", " Insert rows, columns or merge the cells.", " vr, vc Remove expressions from the affected rows (columns),", " leaving only the values.", " zr, zc Hide (``zap'') the current row (column)", " sr, sc Show hidden rows (columns)", " f Set the output format to be used with the values of", " each cell in this column. Enter field width and", " number of fractional digits. A preceding count can be", " used to change more than one column.", " ", " Commands which move or copy cells also modify the row and column ", " references in the new cell expressions. Use ``fixed'' or the", " ``$'' style cell reference to supress the change.", " ", " @myrow, @mycol return the row or column of the current cell", (char *)0 }; char *range[] = { " ", #if defined(QREF) && defined(TROFF) ".SH", #endif " I: Range commands:", #if defined(QREF) && defined(TROFF) ".Lp", #endif " /x Clear a range. ", " /v Remove the expressions from a range of cells, leaving ", " just the values.", " /c Copy a source range to a destination range.", " /f Fill a range with constant values starting with a given", " value and increasing by a given increment.", " /d Assign a name to a cell or a range of cells. Give the", " the name, surrounded by quotes, and either a cell name such", " as ``A10'' or a range such as ``a1:b20''.", " /l Locks a cell or a range of cells, i.e makes it unchangeable.", " /U Unlocks a locked cell, i.e makes it changeable.", " /s Shows the currently defined range names. Pipe output to", " sort, then to less.", " /u Use this command to undefine a previously defined range name.", " /F Assign a format string to a range of cells.", " ", " Range operations affect a rectangular region on the screen", " defined by the upper left and lower right cells in the region.", " A range is specified by giving the cell names separated by ``:'',", " such as ``a20:k52''. Another way to refer to a range is to use", " a name previously defined using ``/d''.", (char *)0 }; char *misc[] = { " ", #if defined(QREF) && defined(TROFF) ".SH", #endif " J: Miscellaneous commands:", " ", #if defined(QREF) && defined(TROFF) ".Lp", #endif " Q q ^C Exit from the program.", " ^G ESC Abort entry of the current command.", " ? Help", " ! Shell escape. Enter a command to run. ``!!'' repeats", " the last command. Just ``!'' starts an interactive shell.", " ^L Redraw the screen.", " ^R Redraw the screen. Highlight cells with values but no", " expressions.", " ^X Redraw the screen. Show formulas, not values.", " @ Recalculate the spreadsheet.", " ^V Type, in the command line, the name of the current cell.", " ^W Type, in the command line, the current cell's expression.", " ^A Type, in the command line, the current cell's numeric value.", " TAB When the character cursor is on the top line TAB can be used", " to start or stop the display of the default range.", (char *)0 }; char *var[] = { " ", #if defined(QREF) && defined(TROFF) ".SH", #endif " K: Variable names:", " ", #if defined(QREF) && defined(TROFF) ".Lp", #endif " K20 Row and column can vary on copies.", " $K$20 Row and column stay fixed on copies.", " $K20 Row can vary; column stays fixed on copies.", " K$20 Row stays fixed; column can vary on copies.", " fixed holds following expession fixed on copies.", " Cells and ranges can be given a symbolic name via ``/d''.", " ", " Expressions:", " -e Negation e<=e Less than or equal", " e+e Addition e=e Equal", " e-e Subtraction e!=e Not Equal", " e*e Multiplication e>=e Greater than or equal", " e/e Division e>e Greater than", " e%e Modulo e