# NSBrowser

scottc@net-community.com
far@ix.netcom.com
wolff@cybercable.fr
mirko.viviani@rccr.cremona.it
FredKiefer@gmx.de
greg.casamento@gmail.com
Generated at 2026-06-27 19:09:52 +0000

Control to display and select from hierarchal lists

1996, 1997, 2002 Free Software Foundation, Inc.
Software documentation for the NSBrowser class
AppKit/NSBrowser.h
NSCoding
Description forthcoming.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
Warning the underscore at the start of the name of this instance variable indicates that, even though it is not technically private, it is intended for internal use within the package, and you should not use the variable in other code.
cellClass

Returns the NSBrowserCell class (regardless of whether a -setCellClass: message has been sent to a particular instance). This method is not meant to be used by applications.

See Also: -setCellClass:

removeSavedColumnsWithAutosaveName:
name
Description forthcoming.
acceptsArrowKeys

Returns whether the arrow keys are enabled. By default `YES`.

See Also: -setAcceptsArrowKeys:

addColumn

Adds a column to the right of the last column, adjusts subviews and scrolls to make the new column visible if needed.

allowsBranchSelection

Returns whether the user can select branch items when multiple selection is enabled. By default `YES`.

See Also: -setAllowsBranchSelection:

allowsEmptySelection

Returns whether there can be nothing selected. By default `YES`.

See Also: -setAllowsEmptySelection:

allowsMultipleSelection

Returns whether the user can select multiple items. By default `YES`.

See Also: -allowsMultipleSelection

allowsTypeSelect
Description forthcoming.
autohidesScroller
Description forthcoming.
backgroundColor
Description forthcoming.
canDragRowsWithIndexes:
rowIndexes
inColumn:
columnIndex
withEvent:
dragEvent
Description forthcoming.
cellPrototype

Returns the NSBrowser's prototype NSCell instance.

See Also: -setCellPrototype:

clickedColumn
Description forthcoming.
clickedRow
Description forthcoming.
columnContentWidthForColumnWidth:
columnWidth
Description forthcoming.
columnOfMatrix:
matrix

Returns the column number in which matrix is located. Returns -1 if matrix is not found.

columnResizingType
Description forthcoming.
columnWidthForColumnContentWidth:
columnContentWidth
Description forthcoming.
columnsAutosaveName
Description forthcoming.
delegate

Returns the NSBrowser's delegate.

See Also: -setDelegate:

displayAllColumns

Updates the NSBrowser to display all loaded columns.

See Also: -displayColumn: -tile

displayColumn:
column

Updates the NSBrowser to display the column with the given index.

doClick:
sender

Responds to (single) mouse clicks in a column of the NSBrowser.

See Also: -doDoubleClick:

doDoubleClick:
sender

Responds to double-clicks in a column of the NSBrowser.

See Also: -doClick: -sendAction:to:

doubleAction

Returns the NSBrowser's double-click action method.

See Also: -setDoubleAction:

drawTitle:
title
inRect:
aRect
ofColumn:
column
Draws the title for the column at index column within the rectangle defined by aRect.
drawTitleOfColumn:
column
inRect:
aRect
Description forthcoming.
firstVisibleColumn
Returns the index of the first visible column.
frameOfColumn:
column

Returns the rectangle containing the column at index column.

frameOfInsideOfColumn:
column
Returns the rectangle containing the column at index column,
hasHorizontalScroller

Returns whether an NSScroller is used to scroll horizontally. By default a NSBrowser has a horizontal scroller.

See Also: -setHasHorizontalScroller:

isLoaded
Returns whether column zero is loaded.
isTitled

Returns whether columns display titles. By default a NSBrowser displays titles.

See Also: -setTitled:

lastColumn

Returns the index of the last column loaded.

See Also: -setLastColumn:

lastVisibleColumn
Returns the index of the last visible column.
loadColumnZero
Loads column zero; unloads previously loaded columns.
loadedCellAtRow:
row
column:
column
Loads if necessary and returns the NSCell at row in column. if you change this code, you may want to look at the __performLoadOfColumn: method in which the following code is integrated (for speed)
matrixClass

Returns the class of NSMatrix used in the NSBrowser's columns.

See Also: -setMatrixClass:

matrixInColumn:
column

Returns the matrix located in the column identified by index column. Returns `nil` if the matrix does not exists

maxVisibleColumns

Returns the maximum number of visible columns. By default a NSBrowser has 3 visible columns.

See Also: -setMaxVisibleColumns:

minColumnWidth

Returns the minimum column width in pixels.

See Also: -setMinColumnWidth:

numberOfVisibleColumns
Returns the number of columns visible.

See Also: -firstVisibleColumn -lastVisibleColumn

path

Returns the browser's current path.

See Also: -pathToColumn:

pathSeparator

Returns the path separator. The default is "/".

See Also: -setPathSeparator:

pathToColumn:
column

Returns a string representing the path from the first column up to, but not including, the column at index column.

See Also: -path

prefersAllColumnUserResizing
Description forthcoming.
reloadColumn:
column
Reloads column if it is loaded; sets it as the last column. Reselects previously selected cells, if they remain.
reusesColumns

Returns `YES` if NSMatrix objects aren't freed when their columns are unloaded. By default a NSBrowser does not reuses their columns.

See Also: -setReusesColumns: [NSMatrix -renewRows:columns:]

scrollColumnToVisible:
column

Scrolls to make the column at index column visible.

See Also: -scrollColumnsRightBy: -scrollColumnsLeftBy:

scrollColumnsLeftBy:
shiftAmount

Scrolls columns left by shiftAmount columns.

See Also: -scrollColumnsRightBy: -scrollColumnToVisible:

scrollColumnsRightBy:
shiftAmount

Scrolls columns right by shiftAmount columns.

See Also: -scrollColumnsLeftBy: -scrollColumnToVisible:

scrollRowToVisible:
row
inColumn:
column
Description forthcoming.
scrollViaScroller:
sender
Scrolls columns left or right based on an NSScroller.
selectAll:
sender

Selects all NSCells in the last column of the NSBrowser.

See Also: [NSMatrix -selectAll:]

selectRow:
row
inColumn:
column

Selects the cell at index row in the column identified by index column. If the delegate method -browser:selectRow:inColumn: is implemented, this is its responsability to select the cell. This method adds a NSBrowser column if needed and deselects other selections if the browser does not allows multiple selection.

See Also: -loadedCellAtRow:column: -browser:selectRow:inColumn: [NSMatrix -selectCellAtRow:column:]

selectedCell

Returns the last (rightmost and lowest) selected NSCell. Returns `nil` if no cell is selected

See Also: -selectedCells -selectedCellInColumn:

selectedCellInColumn:
column

Returns the last (lowest) NSCell that's selected in column. Returns `nil` if no cell is selected

See Also: -selectedCell -selectedCells

selectedCells

Returns a NSArray of selected cells in the rightmost column. Returns `nil` if no cell is selected.

See Also: -selectedCell -selectedCellInColumn: [NSMatrix selectedCells]

selectedColumn
Returns the index of the last column with a selected item.
selectedRowInColumn:
column

Returns the row index of the selected cell in the column specified by index column. Returns -1 if no cell is selected

See Also: -selectedCellInColumn: [NSMatrix -selectedRow]

selectionIndexPath
Returns the index path of the selected item, or `nil` if there is no selection.
selectionIndexPaths
Description forthcoming.
sendAction
Sends the action message to the target. Returns `YES` upon success, `NO` if no target for the message could be found.
sendsActionOnArrowKeys

Returns `NO` if pressing an arrow key only scrolls the browser, `YES` if it also sends the action message specified by [NSControl -setAction:] . By default `YES`.

See Also: -setSendsActionOnArrowKeys: -acceptsArrowKeys [NSControl -setAction:] [NSControl -action]

separatesColumns

Returns whether columns are separated by bezeled borders. By default a NSBrowser has separate columns.

See Also: -setSeparatesColumns:

setAcceptsArrowKeys:
flag

Enables or disables the arrow keys as used for navigating within and between browsers. By default `YES`.

See Also: -acceptsArrowKeys

setAllowsBranchSelection:
flag

Sets whether the user can select branch items when multiple selection is enabled. By default `YES`.

See Also: -allowsBranchSelection

setAllowsEmptySelection:
flag

Sets whether there can be nothing selected. By default `YES`.

See Also: -allowsEmptySelection

setAllowsMultipleSelection:
flag

Sets whether the user can select multiple items. By default `YES`.

See Also: -allowsMultipleSelection

setAllowsTypeSelect:
allowsTypeSelection
Description forthcoming.
setAutohidesScroller:
flag
Description forthcoming.
setBackgroundColor:
backgroundColor
Description forthcoming.
setCellClass:
classId

Sets the class of NSCell used in the columns of the NSBrowser.

See Also: -setCellPrototype: -cellPrototype +cellClass

setCellPrototype:
aCell

Sets the NSCell instance copied to display items in the columns of NSBrowser.

See Also: -cellPrototype

setColumnResizingType:
type
Description forthcoming.
setColumnsAutosaveName:
name
Description forthcoming.
setDelegate:
anObject

Sets the delegate of the receiver. If not `nil`, the delegate must either be passive and respond to [NSObject -browser:numberOfRowsInColumn:] or be active and respond to [NSObject -browser:createRowsForColumn:inMatrix:] but not both. If the delegate is active it must also respond to [NSObject -browser:willDisplayCell:atRow:column:]. If the delegate is not `nil` but does not meet these conditions, an NSBrowserIllegalDelegateException will be raised.

See Also: -delegate

setDoubleAction:
aSelector

Sets the NSBrowser's double-click action to aSelector.

See Also: -doubleAction

setHasHorizontalScroller:
flag

Sets whether an NSScroller is used to scroll horizontally. This method add the horizontal scroller, adjust the various subviews of the NSBrowser scroller and marks self for display.By default a NSBrowser has a horizontal scroller.

See Also: -hasHorizontalScroller -tile

setLastColumn:
column

Sets the last column to column .

See Also: -lastColumn

setMatrixClass:
classId

Sets the matrix class (NSMatrix or an NSMatrix subclass) used in the NSBrowser's columns.

See Also: -matrixClass

setMaxVisibleColumns:
columnCount

Sets the maximum number of columns displayed and adjusts the various subviews. By default a NSBrowser has 3 visible columns.

See Also: -maxVisibleColumns

setMinColumnWidth:
columnWidth

Sets the minimum column width in pixels and adjusts subviews.

See Also: -minColumnWidth

setPath:
path

Parses path and selects corresponding items in the NSBrowser columns.

This is the primary mechanism for programmatically updating the selection of a browser. It should result in the browser cells corresponding to the components being selected, and the browser columns up to the end of path (and just beyond if the last selected cell's [NSBrowserCell -isLeaf] returns `YES`).
It does not result in the browsers action being sent to its target, just in a change to the browser selection and display.

If path begins with the -pathSeparator then it is taken to be absolute and the first component in it is expected to denote a cell in column zero. Otherwise it is taken to be relative to the currently selected column.

Empty components (ie where a -pathSeparator occurs immediately after another or at the end of path) are simply ignored.

The receivers delegate is asked to select each cell in turn using the -browser:selectCellWithString:inColumn: method (if it implements it). If this call to the delegate returns `NO` then the attempt to set the path fails.
If the delegate does not implement the method, the browser attempts to locate and select the cell itself, and the method fails if it is unable to locate the cell by matching its [NSCell -stringValue] with the component of the path.

The method returns `YES` if path contains no components or if a cell corresponding to the path was found. Otherwise it returns `NO`.

setPathSeparator:
aString

Sets the path separator to newString. The default is "/".

See Also: -pathSeparator

setPrefersAllColumnUserResizing:
flag
Description forthcoming.
setReusesColumns:
flag

If flag is `YES`, prevents NSMatrix objects from being freed when their columns are unloaded, so they can be reused. By default a NSBrowser does not reuses their columns.

See Also: -reusesColumns [NSMatrix -renewRows:columns:]

setSelectionIndexPath:
path
Description forthcoming.
setSelectionIndexPaths:
paths
Description forthcoming.
setSendsActionOnArrowKeys:
flag

Sets whether pressing an arrow key will cause the action message to be sent (in addition to causing scrolling). By default `YES`.

See Also: -sendsActionOnArrowKeys -setAcceptsArrowKeys: [NSControl -setAction:] [NSControl -action]

setSeparatesColumns:
flag

Sets whether to separate columns with bezeled borders and marks self for display. Does nothing if the NSBrowser is titled. By default a NSBrowser has separate columns.

See Also: -separatesColumns -isTitled

setTakesTitleFromPreviousColumn:
flag

Sets whether the title of a column is set to the string value of the selected NSCell in the previous column and marks self for display. By default `YES`

See Also: -takesTitleFromPreviousColumn -selectedCellInColumn:

setTitle:
aString
ofColumn:
column

Sets the title of the column at index column to aString and marks the title for dispaly if the NSBrowser can diplay titles or if the column column is visible.

See Also: -isTitled -titleFrameOfColumn: -titleHeight

setTitled:
flag

Sets whether columns display titles and marks self for display. Does nothing if the NSBrowser hasn't separates columns. By default a NSBrowser displays titles.

See Also: -isTitled -separatesColumns

setWidth:
columnWidth
ofColumn:
columnIndex
Description forthcoming.
takesTitleFromPreviousColumn

Returns `YES` if the title of a column is set to the string value of the selected NSCell in the previous column. By default `YES`

See Also: -setTakesTitleFromPreviousColumn: -selectedCellInColumn:

tile
Adjusts the various subviews of NSBrowser-scrollers, columns, titles, and so on-without redrawing. Your code shouldn't send this message. It's invoked any time the appearance of the NSBrowser changes.
Horizontall expand the scroller by GSScrollerKnobOvershoot on the left
titleFrameOfColumn:
column

Returns the bounds of the title frame for the column at index column. Returns NSZeroRect if the NSBrowser does not display its titles

See Also: -isTitled

titleHeight

Returns the height of column titles. The Nextish look returns 21.

titleOfColumn:
column
Returns the title displayed for the column at index column.
updateScroller
Updates the horizontal scroller to reflect column positions.
validateVisibleColumns
Invokes delegate method -browser:isColumnValid: for visible columns.
widthOfColumn:
column
Description forthcoming.
Software documentation for the NSBrowser(GNUstepExtensions) category
AppKit/NSBrowser.h
Description forthcoming.
acceptsAlphaNumericalKeys
Returns `YES` if the alphanumerical keys are enabled.
sendsActionOnAlphaNumericalKeys
Returns `NO` if pressing an arrow key only scrolls the browser, `YES` if it also sends the action message specified by setAction:.
setAcceptsAlphaNumericalKeys:
flag
Enables or disables the arrow keys as used for navigating within and between browsers.
setSendsActionOnAlphaNumericalKeys:
flag
Sets whether pressing an arrow key will cause the action message to be sent (in addition to causing scrolling).
Software documentation for the NSObject(NSBrowserDelegate) informal protocol
AppKit/NSBrowser.h
Description forthcoming.
browser:
browser
canDragRowsWithIndexes:
rowIndexes
inColumn:
column
withEvent:
event
Description forthcoming.
browser:
browser
child:
index
ofItem:
item
Description forthcoming.
browser:
sender
createRowsForColumn:
column
inMatrix:
matrix
Description forthcoming.
browser:
browser
didChangeLastColumn:
oldLastColumn
toColumn:
column
Description forthcoming.
browser:
browser
headerViewControllerForItem:
item
Description forthcoming.
browser:
sender
isColumnValid:
column
Returns `YES` iff
browser:
browser
isLeafItem:
item
Description forthcoming.
browser:
browser
numberOfChildrenOfItem:
item
Description forthcoming.
browser:
sender
numberOfRowsInColumn:
column
Description forthcoming.
browser:
browser
objectValueForItem:
item
Description forthcoming.
browser:
browser
previewViewControllerForLeafItem:
item
Description forthcoming.
browser:
sender
selectCellWithString:
title
inColumn:
column
Description forthcoming.
browser:
sender
selectRow:
row
inColumn:
column
Description forthcoming.
browser:
browser
setObjectValue:
object
forItem:
item
Description forthcoming.
browser:
browser
shouldEditItem:
item
Description forthcoming.
browser:
browser
shouldSizeColumn:
column
forUserResize:
flag
toWidth:
width
Description forthcoming.
browser:
browser
sizeToFitWidthOfColumn:
column
Description forthcoming.
browser:
sender
titleOfColumn:
column
Description forthcoming.
browser:
sender
willDisplayCell:
cell
atRow:
row
column:
column
Description forthcoming.
browserColumnConfigurationDidChange:
notification
Description forthcoming.
browserDidScroll:
sender
Description forthcoming.
browserWillScroll:
sender
Description forthcoming.
rootItemForBrowser:
browser
Description forthcoming.
Software documentation for the NSBrowserDelegate protocol
AppKit/NSBrowser.h
NSObject
Description forthcoming.