/** @return true, if element <code>node</code> has border. */
private static boolean hasBorder(FONode node) {
while (node != null) {
CommonBorderPaddingBackground commonBorderPaddingBackground = null;
if (node instanceof Block) {
Block block = (Block) node;
commonBorderPaddingBackground = block.getCommonBorderPaddingBackground();
} else if (node instanceof BlockContainer) {
BlockContainer container = (BlockContainer) node;
commonBorderPaddingBackground = container.getCommonBorderPaddingBackground();
}