File tag/Matrix


class tag.MatrixDelegate

Inherits

Behaviour supers
tom.All

instance tag.MatrixDelegate

methods

void
           matrix Matrix matrix
  willDisplayCell Cell cell
               at (int, int) (row, column);
Be informed that the matrix is about to display the cell at position (row, column).

void
         matrix Matrix matrix
  didStartCycle Cell cell;
Be informed of the start of another mouse event cycle by the cell of the matrix.


class tag.Matrix

Inherits

State supers
Control, Action

methods

void
  load tom.Array arguments;
Set the cell_class to ActionCell.

instance tag.Matrix

variables

tom.MutableArray cells;
The cells.
public int num_rows;
The number of rows in the matrix.
public int num_columns;
The number of columns in the matrix.
float cell_width;
The size of each cell.
float cell_height;
float intercell_width;
The size of the space between the cells.
float intercell_height;
public Cell selected_cell;
In case only one cell is selected, this is the selected cell.
int selected_row;
The coordinates of the selected cell.
int selected_column;
public mutable Cell prototype;
The prototype cell.
class (Cell) this_cell_class;
The factory cell class.
public mutable MatrixDelegate delegate;
The delegate of this matrix.
public mutable Color background_color;
The color for the space between the cells.
public mutable Color cell_background_color;
The background color of cells.
public mutable selector double_action;
The action upon a double-click.
int selection_mode;
The selection mode of this matrix.
public mutable boolean allows_empty_selection;
public mutable boolean autosizes_cells;

methods

boolean
  acceptsFirstMouse;
Return YES iff the selection_mode is not MATRIX_MODE_LIST.

void
  addColumn;
Undocumented.

void
  addColumnWithCells tom.Indexed new_cells;
Undocumented.

void
  addRow;
Undocumented.

void
  addRowWithCells tom.Indexed new_cells
pre
  [new_cells length] >= num_columns;
Undocumented.

class (Cell)
  cell_class;
Return the this_cell_class of this matrix.

Cell
  cellAt (int, int) (row, column)
pre
  row >= 0 && column >= 0 && row < num_rows && column < num_columns;
Undocumented.

(float, float, float, float)
  cellFrameAt (int, int) (row, column)
pre
  row >= 0 && column >= 0;
Undocumented.

(float, float)
  cellSize;
Undocumented.

Cell
  cellWithTag int some_tag;
Undocumented.

tom.Indexed
  cells;
Undocumented.

void
  deselectAllCells;
Undocumented.

void
  deselectSelectedCell;
Undocumented.

protected boolean
  deselectSelectedCell;
Deselect the selected cell or cells, if allowed, and return whether the matrix has changed and needs to be redisplayed.

void
  drawCellAt (int, int) (row, column);
Undocumented.

boolean
  drawsBackground;
Return TRUE if this matrix has a background_color.

boolean
  drawsCellBackground;
Return TRUE if this matrix has a cell_background_color.

void
  drawSelf (float, float, float, float) (x, y, w, h);
Draw that part of the matrix that intersects with the indicated rectangle.

(int, int) (rows, columns)
  getDimensions;
Undocumented.

(boolean, int, int) (within_cell, row, column)
  getCellCoordinates (float, float) (x, y);
Check the cell at the point (x, y) in the receiving Matrix. If within_cell is returned FALSE, no cell is hit. Otherwise, row and column identify the cell that is hit.

(int, int) (row, column)
  getCellCoordinates Cell c
pre
  [cells indexOfIdentical c] >= 0;
Undocumented.

id
  init;
Undocumented.

id
  initFrame (float, float, float, float) (x, y, w, h);
Undocumented.

id
   initFrame (float, float, float, float) (x, y, w, h)
        mode int sel_mode
   cellClass class (Cell) cell_factory
  dimensions (int, int) (n_rows, n_cols);
Undocumented.

id
   initFrame (float, float, float, float) (x, y, w, h)
        mode int sel_mode
   prototype Cell cell_proto
  dimensions (int, int) (n_rows, n_cols);
Undocumented.

protected id
   initFrame (float, float, float, float) (x, y, w, h)
        mode int sel_mode
  dimensions (int, int) (n_rows, n_cols);
Undocumented.

(float, float) (width, height)
  intercellSpacing;
Undocumented.

Cell (new_cell)
  makeCellAt (int, int) (row, column)
pre
  row >= 0 && column >= 0 && row < num_rows && column < num_columns;
Create a new cell at the specified position.

void
  set_cell_class class (Cell) new_cell_class;
Set the this_cell_class of this matrix.

void
  setIntercellSpacing (float, float) (width, height);
Adjust intercell_width and intercell_height. The frame is not modified, no redisplaying is done.

void
  sizeTo (float, float) (w, h);
Adjust the cell_width and cell_height.

void
  sizeToCells;
Adjust the frame of the Matrix to accomodate all the cells.

void
  sizeToFit;
Resize the matrix to fit all cells, without affecting the size of the cells or the intercell spacing.

Target/Action

selector
  action;
Forward to Action.

_builtin_.Any
  target;
Undocumented.

void
  setTarget tom.All t;
Undocumented.

void
  setAction selector a;
Undocumented.

Event Handling

void
  mouseDown MouseEvent event;
Set the cell to be the cell getting the hit, and let it handle this event.

void
  mouseUp MouseEvent event;
Undocumented.

void
  sendAction selector a
          to tom.All t;
Substitute the action and/or target of the receiving Matrix, if the provided arguments, a and t are default selector, or nil, respectively.

void
  encodeUsingCoder tom.Encoder coder;

Archiving

void
  initWithCoder tom.Decoder coder;
Undocumented.


Generated by tm 1.01.