![]() |
| jit.cellblock | Two-dimensional storage and viewing |
| Attributes: |
| Name | Type | Description |
| border | int | Cellblock border flag (default = 1) When the flag is set, a border will be displayed around the cellblock. When a border is added or removed, the existing cells shift by one pixel to compensate for the size of the border. |
| colhead | int | Column header flag (default = 1) When the flag is set, a row of column headers will be displayed (all cells are in row 0). A column header is a normal cell with an alternative coloring scheme. |
| cols | int | The number of columns in the cellblock (default = 5) |
| colwidth | int | The width of the columns, in pixels (default = 45) |
| grid | int | Cellblock grid flag (default = 1) When the flag is set, a border will be displayed around the cells in the cellblock. |
| hscroll | int | Horizontal scroll bar flag (default = 1) When the flag is set, a horizontal scroll bar will be displayed. |
| just | int |
Default text justification setting (default = 0 (left)) 0 = left justified 1 = centered 2 = right justified |
| precision | int | the amount of precision displayed on the cellblock (default = 4) This attribute does not alter the value stored in the cell, only how it is displayed. |
| readonly | int | Read only flag (default = 0) When the flag is set, the jit.cellblock object is in read-only mode, and will disallow any changes made to any cell values. |
| rowhead | int | Row header flag (default = 1) When the flag is set, a column of row headers will be displayed (all cells are in column 0). A row header is a normal cell with an alternative coloring scheme. |
| rowheight | int | The height of the rows, in pixels (default = 17) |
| rows | int | The number of rows (default = 10) |
| size | int list[2] | The horizontal and vertical size of the jit.cellblock object, in pixels (default = 118 118) |
| vscroll | int | Vertical scroll bar flag (default = 1) When the flag is set, a vertical scroll bar will be displayed. |
| Messages: |
| append [data-to-append (list)] |
| Adds the specified valid Max data to the contents of the currently selected cell. |
| bang |
| Sends the contents out the object’s left outlet, and sends a message through the third outlet of the form set value-list. |
| brgb [red (int)] [green (int)] [blue (int)] |
| Specifies the default background color of the object text in RGB format. (default = 255 255 255) Color values should be in the range 0-255. |
| cell [col-number (int)] [row-number (int)] [command (symbol)] [parameters (list)] |
|
The cell message allows you to control the appearance of a single cell within the cellblock.
Using the cell message will override changes for both row and col messages.
A list in the form cell col-number row-number label text sets a text label for the selected cell. The label will always be displayed, but does not replace any data stored for the cell. If col-number and row-number are omitted from the list, the currently selected cell is changed. A list in the form cell col-number row-number frgb red green blue sets the foreground color of the currently selected cell (i.e. the last cell that was clicked upon). All values should be in the range 0-255. If col-number and row-number are omitted from the list, the currently selected cell is changed. If no color values are provided, the cell override will be eliminated and the color returned to the default setting. A list in the form cell col-number row-number brgb red green blue sets the background color of the currently selected cell (i.e. the last cell that was clicked upon). All values should be in the range 0-255. If col-number and row-number are omitted from the list, the currently selected cell is changed. If no color values are provided, the cell override will be eliminated and the color returned to the default setting.
A list in the form cell col-number row-number just justification-value
sets the justification for the cell. Justification values are:
A list in the form cell col-number row-number precision precision-value
sets the displayed floating-point precision for the cell. Precision values are:
A list in the form cell col-number row-number readonly readonly-value
sets the read-only setting for the cell. Readonly values are: Using cell messages without explicitly specifying column or row locations is Not recommended when using selmode 2, or selmode 3, or selmode 4. |
| clear ( { all } / { [col-number (int)] [row-number (int)] [command (symbol)] } ) |
|
Removes data from the cellblock.
The message clear col-number row-number clears the contents of the specified cell. The message clear all will clear the entire contents of the cellblock. The message clear current will clear the contents of the currently selected cells. The message clear with no arguments is equivalent to the message clear current. |
| col [col-number (int)] [command (symbol)] [parameters (list)] |
|
The col message allows you to control the appearance of a
single column within the cellblock.
Using the col message to override color settings will override
any color changes made with the row message.
Using the cell message will override color changes for col and row messages.
A list in the form col col-number frgb red green blue sets the foreground color of the column. All values should be in the range 0-255. If col-number is omitted from the list, the currently selected column is changed. If no color values are provided, the column override will be eliminated and the color returned to the default setting. A list in the form col col-number brgb red green blue sets the background color of the column. All values should be in the range 0-255. If col-number is omitted from the list, the currently selected column is changed. If no color values are provided, the column override will be eliminated and the color returned to the default setting.
A list in the form cell col-number just justification-value
sets the justification for the cell. Justification values are:
A list in the form cell col-number precision precision-value
sets the displayed floating-point precision for the column. Precision values are:
A list in the form cell col-number readonly readonly-value
sets the read-only setting for the column. Readonly values are: A list in the form cell col-number width width sets the width of the column, in pixels. If col-number is omitted from the list, the currently selected column is changed. |
| color [color-index (int)] |
| Replaces the background color with the selected color from the Max color palette. Color index values should be in the range 0-16. |
| deref |
| Disconnects a jit.cellblock object from any attached jit.matrix objects. |
| dump |
| Sends a listing of the contents of all non-empty cells out the object’s left outlet, one line per cell. Each output line takes the form col-number row-number cell-contents. |
| frgb [red (int)] [green (int)] [blue (int)] |
| Specifies the default foreground color of the object text in RGB format. (default = 0 0 0) Color values should be in the range 0-255. |
| jit_deref |
| Disconnects a jit.cellblock object from any attached jit.matrix objects. |
| jit_matrix [matrix-name (symbol)] |
| Displays the contents of the named jit.matrix object’s cells in the cellblock. The plane used for display may be set via the plane message. The jit_matrix message generally comes from attached jit.matrix objects. When a jit_matrix message is received (along with the jit.matrix identifier), the current contents of the jit.matrix is displayed in the jit.cellblock object. If the jit.cellblock object’s mode is set for in-place editing, the contents of the jit.matrix can be directly edited within the jit.cellblock object. |
| list [col-number (int)] [row-number (int)] |
|
Selects a cell from the cellblock.
The message list col-number row-number is equivalent to the message select col-number row-number. |
| mode [command (symbol)] [parameters (list)] |
|
The mode message sets the operational modes of the cellblock.
mode selmode 0/1/2/3/4/5 specifies the selection function of the cellblock. The
selection mode settings are: mode saveatoms [0/1] toggles whether or not the cell contents will be saved with the patcher. (default = 0) mode sync horizontal-sync-flag vertical-sync-flag select-flag sets the sync modes. The sync modes determine if sync messages received in the rightmost inlet are accepted or ignored. mode sync 1 1 1 would accept all sync commands, while mode sync 0 0 0 would ignore all sync commands. Sync allows multiple jit.cellblock objects to display "connected" information.
mode outmode 0/1/2 specifies how cellblock output is formatted. Options are: |
| plane [plane-number (int)] |
| When connected to a two-dimensional multi-plane jit.matrix object, the plane message allows the cellblock to select any one of the planes for display and editing. In addition, the command plane -1 will display all planes in each cell, allowing access for multiplane editing |
| prepend [data-to-prepend (list)] |
| Adds the specified valid Max data to the beginning of the contents of the currently selected cell. |
| read { [filename (symbol)] } |
| Opens and reads the contents of a cellblock file from disk if a filename is specified. No attempts to are made to verify the contents. If no filename is specified, a file dialog box will be displayed to allow selection of a saved cellblock file. |
| refer [coll-object (symbol)] |
|
Displays the contents of the named coll object’s internal list in the cellblock.
Note: Due to the differences between the internal storage mechanisms for the coll and jit.cellblock objects, data can only be viewed (and not edited) for an attached coll. The jit.cellblock object allows for editing of a coll object’s contents. The only limitation is structural -- the jit.cellblock object cannot be used to add or delete rows or columns. This must be done outside of the jit.cellblock (typically through commands sent directly to the coll object). |
| rgb1 [red (int)] [green (int)] [blue (int)] |
| Specifies the default color of the color of the grid lines in RGB format. (default = 0 0 0) Color values should be in the range 0-255. |
| rgb2 [red (int)] [green (int)] [blue (int)] |
| Specifies the default color of the color of the cellblock border in RGB format. (default = 0 0 0) Color values should be in the range 0-255. |
| rgb3 [red (int)] [green (int)] [blue (int)] |
| Specifies the default column/row header background color in RGB format. (default = 191 191 191) Color values should be in the range 0-255. |
| rgb4 [red (int)] [green (int)] [blue (int)] |
| Specifies the default column/row header foreground color in RGB format. (default = 0 0 0) Color values should be in the range 0-255. |
| rgb5 [red (int)] [green (int)] [blue (int)] |
| Specifies the default background color of selected cells in RGB format. (default = 215 215 240) Color values should be in the range 0-255. |
| rowblend [foreground-blend-percentage (int)] [background-blend-percentage (int)] |
| In cases where there are both column and row foreground and/or background color overrides, the rowblend message will allow you to "blend" the colors using column transparency. Column colors have a higher priority than row colors; if you have a row and column color that affect a cell, only the column color will be displayed. The rowblend message allows you to make the column color transparent using a percentage value, thereby allowing the row color to be displayed. The rowblend message applies the color transparancy to all column colors without discrimination. Blend percentage values are both in the range 0 - 100, and specify the percentage of blend. |
| row [row-number (int)] [command (symbol)] [parameters (list)] |
|
The row message allows you to control the appearance of a
single row within the cellblock.
Using the col message to override color settings will override
any color changes made with the row message, and using the cell message will override color changes for both row and col messages.
A list in the form row row-number frgb red green blue overrides the current foreground color of the row. All values should be in the range 0-255. If row-number is omitted from the list, the currently selected row is changed. If no color values are provided, the row override will be eliminated and the color returned to the default setting. A list in the form row row-number brgb red green blue overrides the background color of the row. All values should be in the range 0-255. If col-number is omitted from the list, the currently selected row is changed. If no color values are provided, the column override will be eliminated and the color returned to the default setting.
A list in the form row row-number just justification-value
sets the justification for the cell. Justification values are:
A list in the form cell row-number precision precision-value
sets the displayed floating-point precision for the row. Precision values are:
A list in the form cell row-number readonly readonly-value
sets the read-only setting for the row. Readonly values are: A list in the form row row-number width width sets the width of the row, in pixels. If row-number is omitted from the list, the currently selected row returns to the default width. |
| select [col-number (int)] [row-number (int)] |
| Selects the requested cell using the selmode mode to optionally select a row or column and sends the contents out the object’s left outlet and outputs the contents through the third outlet as the list set value. |
| send [receive-object (symbol)] ( { all } / { [col-number (int)] [row-number (int)] } ) |
|
The send message is used to transmit cellblock values without using connected patch
cords; it is the equivalent of sending the output through a send object.
send receive-object sends the contents of the currently specified cell to the specified receive object as the list cell-data-type value. send receive-object col-number row-number sends the contents of the specified cell to the specified receive object as the list cell-data-type value. send receive-object all sends all non-empty cell contents to the specified receive object as a series of the lists in the form cell-data-type value. |
| set ( { current } / { [col-number (int)] [row-number (int)] } ) [values (int)] |
|
Replaces a cell’s data with the data specified by values with no data output.
set current values replaces the currently selected cell’s contents. set col-number row-number values replaces the specified cell’s contents. |
| sync |
| Receives input in the jit.cellblock object’s right inlet from another jit.cellblock object, so that two cellblocks can maintain location and selection synchronization. Synchronization allows for multiple jit.cellblock objects to share display and selection information, thereby allowing multiple jit.cellblock objects to display "connected" information. One use of syncronization is used to force external jit.cellblock objects to act as header rows and columns for a main jit.cellblock object. Other uses would be to allow four jit.cellblock objects to independently display the four layers of a jit.matrix object, but cooperate in the selection and scrolling of the content. For more information on setting synchronization, see the mode message. |
| text [values (symbol/list)] |
| Replaces the value of the currently selected cell with the incoming text values. This is provided as a convenient way of receiving the output of a textedit object. |
| writeagain |
| If a file has been written to, the writeagain message will allow it to be rewritten without further user interaction. |
| write { [filename (symbol)] } |
| Opens a file and writes the contents of a cellblock file to disk if a filename is specified. If no filename is specified, a file dialog box will be displayed to allow selection of a pathname and file. |
| Inspector: |
|
The behavior of a jit.cellblock object is displayed and can be edited using its Inspector.
If you have enabled the floating inspector by choosing Show Floating Inspector
from the Windows menu, selecting any jit.cellblock object displays the jit.cellblock Inspector
in the floating window. Selecting an object and choosing Get Info.... from the
Object menu also displays the Inspector.
The Size parameters set the Horizontal and Vertical size of the cellblock’s frame. The Columns, Rows, Column Width, and Row Height number boxes are used to set the dimensions and size, in pixels, of the cellblock.
Checking the Draw Border box will display a border around the cellblock.
Checking Read-only sets the object to read-only mode, and will disallow any changes made to any cell values. The Selection Mode pop-up menu is used to set the selection behavior of the cellblock. The options are No Selection, Select One Cell, Column Select, Row Select, Header Select, and In-place Edit The Output Mode pop-up menu is used to set the output behavior of the cellblock on selection of a cell, row, or column. The options are Individual Cells, Output One List, and Output One Symbol The Text Justification pop-up menu controls how text is displayed in a cell a cell. The options are Left, Center, and Right. The Sync Mode checkboxes allow you to select any combination of Column, Row, and Selection Sync. For more information, see the sync message description. The Color options let you use a swatch color picker or RGB values to select the colors used to display the jit.cellblock text and its background.
Foreground menu item sets the color for the message text
displayed (default = 0 0 0), and Background sets the color for the message area
in which the text appears (default = 255 255 255). The Revert button undoes all changes you’ve made to an object’s settings since you opened the Inspector. You can also revert to the state of an object before you opened the Inspector window by choosing Undo Inspector Changes from the Edit menu while the Inspector is open. |
| Example: |

| See Also: |
| coll, jit.matrix |