This is MOMatrix.h in view mode; [Download] [Up]
// MOMatrix.h // // by Mike Ferris // Part of MOKit // Copyright 1993, all rights reserved. // ABOUT MOKit // by Mike Ferris (mike@lorax.com) // // MOKit is a collection of useful and general objects. Permission is // granted by the author to use MOKit in your own programs in any way // you see fit. All other rights pertaining to the kit are reserved by the // author including the right to sell these objects as objects, as part // of a LIBRARY, or as SOURCE CODE. In plain English, I wish to retain // rights to these objects as objects, but allow the use of the objects // as pieces in a fully functional program. Permission is also granted to // redistribute the source code of MOKit for FREE as long as this copyright // notice is left intact and unchanged. NO WARRANTY is expressed or implied. // The author will under no circumstances be held responsible for ANY // consequences from the use of these objects. Since you don't have to pay // for them, and full source is provided, I think this is perfectly fair. // MOMatrix is a subclass of Matrix that allows independantly sizable // rows and columns. Each row can have a different height and each column // can have a different width. #import <appkit/appkit.h> typedef struct _ColumnSize_ { NXCoord x; NXCoord width; } ColumnSize; #define COLUMNSIZE_DESC "{ff}" typedef struct _RowSize_ { NXCoord y; NXCoord height; } RowSize; #define ROWSIZE_DESC "{ff}" @interface MOMatrix : Matrix { Storage *columnSizes, *rowSizes; } + initialize; - initFrame:(const NXRect *)frm mode:(int)aMode prototype:cellId numRows:(int)rowsHigh numCols:(int)colsWide; - initFrame:(const NXRect *)frm mode:(int)aMode cellClass:factoryId numRows:(int)rowsHigh numCols:(int)colsWide; - copyFromZone:(NXZone *)zone; - free; - setWidth:(NXCoord)newWidth ofCol:(int)col; - setHeight:(NXCoord)newHeight ofRow:(int)row; - sizeToCells; - renewRows:(int)newRows cols:(int)newCols; - addCol; - addRow; - insertColAt:(int)col; - insertRowAt:(int)row; - removeColAt:(int)col andFree:(BOOL)flag; - removeRowAt:(int)row andFree:(BOOL)flag; - drawSelf:(const NXRect *)rects :(int)rectCount; - getCellFrame:(NXRect *)theRect at:(int)row :(int)col; - getRow:(int *)row andCol:(int *)col forPoint:(const NXPoint *)aPoint; - setIntercell:(const NXSize *)aSize; - write:(NXTypedStream *)typedStream; - read:(NXTypedStream *)typedStream; @end @interface Storage(MOLastElementCategory) - (void *)MO_lastElement; @end
These are the contents of the former NiCE NeXT User Group NeXTSTEP/OpenStep software archive, currently hosted by Netfuture.ch.