beetlebug▾
/

listbox bbox

Gives the box of the text of the item at INDEX.

PATHNAME bbox INDEX

Description

Gives four integers: the x and the y of the top left corner of the text of the item, its width, and its height, in pixels from the corner of the listbox. An item out of the view, or an index with no item, gives an empty list.

Returns

A list of four integers, or an empty list.

Examples

# The listbox has no item.
% listbox .bb
> .bb bbox 0

Errors

% listbox .bb2; .bb2 bbox
wrong # args: should be ".bb2 bbox index"
-errorcode NONE

Facts

Capability
None.
Tcl release
Tcl 9.1 and 8.6.
Since
ztk 1.0.0-beta.1

See also