From 00f3646d463af6e44df2a225f5d38225eee16727 Mon Sep 17 00:00:00 2001 From: megacz Date: Fri, 30 Jan 2004 07:39:27 +0000 Subject: [PATCH] 2003/10/16 10:20:37 darcs-hash:20040130073927-2ba56-89d3526bcf97e9d6b0b48d5792a508abce20c825.gz --- src/org/xwt/Box.java.pp | 61 ++++++++++++++++++++++++++++++++++++++--------- 1 file changed, 50 insertions(+), 11 deletions(-) diff --git a/src/org/xwt/Box.java.pp b/src/org/xwt/Box.java.pp index e6c7201..283fe45 100644 --- a/src/org/xwt/Box.java.pp +++ b/src/org/xwt/Box.java.pp @@ -84,15 +84,20 @@ public final class Box extends JS.Scope { // Flags /////////////////////////////////////////////////////////////////////////////// short flags = 0; - static int MOUSEINSIDE_FLAG = 0x00000001; - static int INVISIBLE_FLAG = 0x00000002; - static int NOTPACKED_FLAG = 0x00000004; - static int HSHRINK_FLAG = 0x00000008; - static int VSHRINK_FLAG = 0x00000010; - static int TILE_FLAG = 0x00000020; - static int FONT_CHANGED_FLAG = 0x00000040; // set when font changes, cleared during repack - static int ISROOT_FLAG = 0x00000080; - static int NOCLIP_FLAG = 0x00000100; + static final int MOUSEINSIDE_FLAG = 0x00000001; + static final int INVISIBLE_FLAG = 0x00000002; + static final int NOTPACKED_FLAG = 0x00000004; + static final int HSHRINK_FLAG = 0x00000008; + static final int VSHRINK_FLAG = 0x00000010; + static final int TILE_FLAG = 0x00000020; + static final int FONT_CHANGED_FLAG = 0x00000040; // set when font changes, cleared during repack + static final int ISROOT_FLAG = 0x00000080; + static final int NOCLIP_FLAG = 0x00000100; + static final int ALIGN_TOP_FLAG = 0x00001000; + static final int ALIGN_BOTTOM_FLAG = 0x00002000; + static final int ALIGN_LEFT_FLAG = 0x00004000; + static final int ALIGN_RIGHT_FLAG = 0x00008000; + static final int ALIGN_FLAGS = 0x0000f000; // Geometry //////////////////////////////////////////////////////////////////////////// @@ -403,10 +408,13 @@ public final class Box extends JS.Scope { child_height = ((child.flags & VSHRINK_FLAG) != 0) ? child.contentheight : min(child.maxheight, height - child.y); } else { int diff; - //#repeat x/y y/x width/height col/row cols/rows colspan/rowspan colWidth/rowHeight maxwidth/maxheight minwidth/minheight contentwidth/contentheight colMaxWidth/rowMaxHeight HSHRINK_FLAG/VSHRINK_FLAG marginWidth/marginHeight child_x/child_y child_width/child_height + //#repeat x/y y/x width/height col/row cols/rows colspan/rowspan colWidth/rowHeight maxwidth/maxheight minwidth/minheight contentwidth/contentheight colMaxWidth/rowMaxHeight HSHRINK_FLAG/VSHRINK_FLAG marginWidth/marginHeight child_x/child_y child_width/child_height ALIGN_LEFT_FLAG/ALIGN_TOP_FLAG ALIGN_RIGHT_FLAG/ALIGN_BOTTOM_FLAG child_width = 0; for(int i=child.col; i