This is Calculator.h in view mode; [Download] [Up]
/***(Calculator.h)************************************************************* *H* Input processing logic for Calculator V0.0, 09-FEB-91 * *C* V0.0 09-FEB-91 Initial version --MDM * ******************************************************************************/ #import <objc/Object.h> #import "OperatorStack.h" /* Calculator OperatorStack Class Definition */ #import "ValueStack.h" /* Calculator ValueStack Class Definition */ @interface Calculator:Object { long OVcalcAcceptMode; /* What kinds of input are acceptable */ int OVcalcBase; /* Current number base of calculator */ id OVcalcBitwiseMtx; /*(Outlet)Bitwise operator button matrix object */ int OVcalcCEIndex; /* Display string Clear Entry index */ id OVcalcDigitMtx; /*(Outlet)Main digit button matrix object */ id OVcalcDigitPBtn; /*(Outlet)Decimal point push button */ id OVcalcDisplay; /*(Outlet)Calculator's simulated LCD display */ char OVcalcDspStr[256]; /* string of values & operators to be displayed */ BOOL OVcalcEqualized; /* Has expression just been equaled */ BOOL OVcalcFrozen; /* flag to freeze calculator on error */ BOOL OVcalcFunctionMode; /* Current method of function operation */ BOOL OVcalcHyperbolic; /* Interpret Trig funcs in Hyperbolic mode */ BOOL OVcalcInverse; /* Interpret Trig funcs in Inverse mode */ int OVcalcMaxDigits; /* Maximum allowable digits in operand */ char OVcalcMemDspStr[80]; /* Formated value in memory */ id OVcalcMemCellLabel; /*(Outlet) Active memory label */ int OVcalcMemoryCell; /* Index of currently active memory cell */ id OVcalcMemoryDsp; /*(Outlet)Calculators memory LCD display */ double OVcalcMemoryVal[26]; /* Binary value in memory cell */ int OVcalcMetric; /* Current trignometric unit metric */ int OVcalcParenBalance; /* Current number of open parenthesis */ id OVcalcPrecsnDsp; /*(Outlet)Text field for displaying current precision */ id OVcalcPrecsnSldr; /*(Outlet)Slider for setting current precision */ int OVcalcPrecsnVal; /* Current output precision value */ int OVcalcUnit; /* Bytes per operand value in Bin/Hex/Oct */ id OVcalcUnitMatrix; /*(Outlet)Unit radio button matrix id */ char OVcalcValStr[80]; /* string of digits of current input value */ id OVcalcWindow; /*(Outlet)Main window in which calculator is drawn */ OperatorStack *OVopStack; /* stack of unprocessed operators */ ValueStack *OVvalStack; /* stack of unprocessed values */ int OVtag; /* to impersonate a Control object */ } + KeyBoardEquivalent:(NXEvent *)event; + PasteExpression:(char*)expString Length:(int)expLength; - init; - AdjustPrecision; - AllClear:sender; - BitwiseAnd:sender; - BitwiseLsh:sender; - BitwiseNot:sender; - BitwiseOr:sender; - BitwiseRsh:sender; - BitwiseXor:sender; - ChangeBase:sender; - ChangeFunctionMode:sender; - ChangeHyperbolic:sender; - ChangeInverse:sender; - ChangeMetric:sender; - ChangePrecision:sender; - ChangeSign:sender; - ChangeUnit:sender; - ClearEntry:sender; - CloseParen:sender; - Cosine:sender; - Digit:sender; - Divide:sender; - EnterPi:sender; - Equals:sender; - Exponential:sender; - Factorial:sender; - FormatValue:(double)operand :(char*)fmtstr; - Integer:sender; - MemoryClear:sender; - MemoryRecall:sender; - MemorySelect:sender; - MemoryStore:sender; - Minus:sender; - Modify:sender; - Multiply:sender; - OpenParen:sender; - Plus:sender; - ProcessDigit:(char) dgtchr; - ProcessFunction: (int) opcode: (char *) symbol; - (double) ProcessOpcode :(int)opcode :(double)operand1 :(double)operand2; - ProcessOperator: (int) opcode: (char *) symbol; - Reciprocal:sender; - ReduceExpression: (int) curopr; - ScanValue:(char*)fmtstr :(double*) operand; - Sine:sender; - SyntaxError: (int) opcode: (char *) symbol; - Tangent:sender; - TenToTheX:sender; - ValueEntered; - XSquared:sender; - XToTheY:sender; - setTag:(int)anInt; - (int) selectedTag; @end
These are the contents of the former NiCE NeXT User Group NeXTSTEP/OpenStep software archive, currently hosted by Netfuture.ch.