IStyle areaStyle = root.getStyle( ); setOffsetX( getDimensionValue( areaStyle .getProperty( StyleConstants.STYLE_BORDER_LEFT_WIDTH ) ) + getDimensionValue( areaStyle .getProperty( StyleConstants.STYLE_PADDING_LEFT ) ) ); setOffsetY( isFirst ? ( getDimensionValue( areaStyle .getProperty( StyleConstants.STYLE_BORDER_TOP_WIDTH ) ) + getDimensionValue( areaStyle .getProperty( StyleConstants.STYLE_PADDING_TOP ) ) ) : 0 );
setOffsetX( root.getContentX( ) ); setOffsetY( isFirst? root.getContentY( ): 0 );
	protected void newContext( )	{		createRoot( );		// initialize offsetX and offsetY		IStyle areaStyle = root.getStyle( );		setOffsetX( getDimensionValue( areaStyle				.getProperty( StyleConstants.STYLE_BORDER_LEFT_WIDTH ) )				+ getDimensionValue( areaStyle						.getProperty( StyleConstants.STYLE_PADDING_LEFT ) ) );		setOffsetY( isFirst				? ( getDimensionValue( areaStyle						.getProperty( StyleConstants.STYLE_BORDER_TOP_WIDTH ) ) + getDimensionValue( areaStyle						.getProperty( StyleConstants.STYLE_PADDING_TOP ) ) )				: 0 );		if ( null != parent )		{			// support user defined width			int maxWidth = parent.getMaxAvaWidth( );			int leftWidth = maxWidth - parent.getCurrentIP( );			int specifiedWidth = 0;			int width = 0;			if ( content != null )			{				specifiedWidth = getDimensionValue( content.getWidth( ) );			}			if ( specifiedWidth > 0 )			{				width = Math.min( specifiedWidth, maxWidth );			}			else			{				if ( leftWidth > maxWidth / 4 )				{					width = leftWidth;				}				else				{					width = maxWidth;				}			}			root.setAllocatedWidth( width );			setMaxAvaWidth( root.getContentWidth( ) );			root.setAllocatedHeight( parent.getMaxAvaHeight( )					- parent.getCurrentBP( ) );			setMaxAvaHeight( root.getContentHeight( ) );		}		// can be removed?		setCurrentBP( 0 );		setCurrentIP( 0 );	}