beetlebug▾
/

ttk::panedwindow sashpos

Gives or sets the place of a sash.

PATHNAME sashpos INDEX ?POSITION?

Description

The sash INDEX is between the pane INDEX and the next pane. With no POSITION, gives the place of the sash in pixels from the left or the top edge. With POSITION, moves the sash there, kept between the sashes next to it, and gives the new place.

Returns

The place of the sash in pixels.

Examples

% ttk::panedwindow .tpwsp -orient horizontal
> foreach n {a b} {ttk::frame .tpwsp.$n -width 100 -height 50; .tpwsp add .tpwsp.$n}
> pack .tpwsp
> update
> .tpwsp sashpos 0 50
> .tpwsp sashpos 0
50

Errors

% ttk::panedwindow .tpwsp2; .tpwsp2 sashpos 5
sash index 5 out of range
-errorcode NONE

Facts

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

See also