Navigation  without Java Scripts

Functionality

Geometry

The split window is a window split into an N times M grid of child windows.

The figure above demonstrates several things about the geometry of the split window. It's a splitwindow with a 3 times 2 grid where the panes are numbered (0,0) to (2,1). All the resize bars have the same size [rbWidth]. There is a margin [mWidth].

Visual elements

Panes

The panes are child windows of the split window and the visual appearance of these are their own responsibility.

Margins

The margins are meant to look like half a resize bar. This is only of importance if a 3D look is used for the resize bars. The margins are drawn together with the resize bars. [see properties: marginWidth]

Resize bars

The resize bars are either flat or 3D. [see properties: resizebarWidth, resizeBarColor]

Active resize bar

The active resize bar is a line the same size as the resize bar going across the window. It is drawn when the user clicks on a resize bar and follows the cursor when the user drags the mouse. [Example] look in Word or Outlook.

Resize cursor

When the cursor is above one of the resize bars it changes to a resize cursor. The look of the resize cursor depends on what the resize bar callback predicate returns. Typically it will depend on whether the cursor is above a horizontal resize bar, a vertical resize bar or one of the crosses.

Behaviour

Resizing using the resize bars

  1. We aim at a model of the split window where the split bars can be thought of as sticks. So when you grab a resize bare and move it only that resize bar moves changing the size of the two windows adjacent to the resize bar.
  2. If the resizing is greater than the width (or height) of the pane the next pane is resized as well.
  3. The resize bars are always visible even when the adjacent panes have a width or height of zero.

Visual feedback on resizing

If resizing is allowed (the splitwin_resize_cb doesn't fail) a resize cursor is drawn. When the mouse is pressed an active resize bar is drawn which follows the cursor, but stays inside the allowable resize area.

Resizing the window

  1. We treat resizing of the window as if the right and the bottom part of the window was an extra resize bar. The fact that the top or the left side of the window is use to resize the window doesn't change this it will always be the rightmost column and the bottom row that is resized.
  2. What happens if the window gets smaller than the administrative space? The administrative space is the space taken by the resize bars and the margins. We just cut of from the right and the bottom. This is the standard behaviour of windows so no special treatment is needed.