Show TOC Welcome to the QLIB 1.0 Online Reference
QLIB 

QBoxRes


Requires:
<script language="JavaScript" src="js/qlib/boxres.js"></script>

Description

Box resource chart Framed box is a resizable window control that has frame border around the client area. Its resource stores the frame dimensions and keeps offscreen images of all elements of the frame. Additionally this resource can define window effects (as described in QWindow) and initial opacity.

The frame around the client area is made up from pieces (as it's shown on the picture), each piece has its double-character code. Pieces in the corners have fixed size and are known as "corner images" (TL, TR, BL, BR). Elements TC, MR, BC, ML get tiled when the box is stretched.

Implementation Notes

"Effects" property is basically a browser specific feature. MS IE family browsers on WIN32 platform provide the most comprehensive support for effects. Netscape 6 and 7 (including Mozilla 1.0) both support opacity filter and a few transition effects (emulated by the script). Opera ignores window effects so far. For more details on cross-browser support refer to Implementaion Notes to QWndCtrl class.

See Also

QBox, QMessageBox, QWndCtrl, QWindow, Windowing.

Constructor

QBoxRes(t, r, b, l, tc, tr, mr, br, bc, bl, ml, tl, bgcoloropt, bgtileopt, effectsopt, opacityopt)
Creates new instance of box resource.
Parameters
t - Height of the top border (in pixels).
r - Width of the right border (in pixels).
b - Height of the bottom border (in pixels).
l - Width of the left border (in pixels).
tc - URL of the top-center tile (image).
tr - URL of the top-right corner image.
mr - URL of the middle-right tile (image).
br - URL of the bottom-right corner image.
bc - URL of the bottom-center tile (image).
bl - URL of the bottom-left corner image.
ml - URL of the middle-left tile (image).
tl - URL of the top-left corner image.
bgcolor - Optional. Defines background color of the client area (white by default).
bgtile - Optional. Defines image for the client area tiling (has no default value).
effects - Optional. Defines effects mask (uses defaults from QWindow if missed).
opacity - Optional. Defines initial opacity (uses defaults from QWindow if missed).

Properties

PropertyAccessDescription
effectsREffects mask (if defined, null otherwise).
opacityRInitial opacity of the box (if defined, null otherwise).
bgcolorRColor of the box client area.
bgtileRImage for tiling of the client area (if defined, null otherwise).
TRHeight of the top border (in pixels).
RRWidth of the right border (in pixels).
BRHeight of the bottom border (in pixels).
LRWidth of the left border (in pixels).
TCRRefers to Image object that keeps picture of top-center tile.
TRRRefers to Image object that keeps picture of top-right corner.
MRRRefers to Image object that keeps picture of middle-right tile.
BRRRefers to Image object that keeps picture of bottom-right corner.
BCRRefers to Image object that keeps picture of bottom-center tile.
BLRRefers to Image object that keeps picture of mottom-left corner.
MLRRefers to Image object that keeps picture of middle-left tile.
TLRRefers to Image object that keeps picture of top-left corner.