tdf#173410 oox: only process corner cells if both row and col enabled
The table style definition allows for special definitions for the first and last rows and columns. That means that the corners are somewhat ambiguous, so each corner cell can also have a special definition. However, the corner cell definition only applies if both that row AND column have a special definition. Change-Id: Ia5a0ecc2f5cf5ecd0f63e83883a4b693669828e4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/210612 Tested-by: Jenkins Reviewed-by: Justin Luth <jluth@mail.com>
This commit is contained in:
@@ -412,7 +412,7 @@ void TableCell::pushToXCell( const ::oox::core::XmlFilterBase& rFilterBase, cons
|
||||
}
|
||||
}
|
||||
}
|
||||
if ( ( nRow == 0 ) && ( nColumn == 0 ) )
|
||||
if (rProperties.isFirstRow() && rProperties.isFirstCol() && nRow == 0 && nColumn == 0)
|
||||
{
|
||||
applyTableStylePart( rFilterBase, aFillProperties, aTextStyleProps,
|
||||
aLinePropertiesLeft,
|
||||
@@ -425,7 +425,7 @@ void TableCell::pushToXCell( const ::oox::core::XmlFilterBase& rFilterBase, cons
|
||||
aLinePropertiesBottomLeftToTopRight,
|
||||
rTable.getNwCell() );
|
||||
}
|
||||
if ( ( nRow == nMaxRow ) && ( nColumn == 0 ) )
|
||||
if (rProperties.isLastRow() && rProperties.isFirstCol() && nRow == nMaxRow && nColumn == 0)
|
||||
{
|
||||
applyTableStylePart( rFilterBase, aFillProperties, aTextStyleProps,
|
||||
aLinePropertiesLeft,
|
||||
@@ -438,7 +438,7 @@ void TableCell::pushToXCell( const ::oox::core::XmlFilterBase& rFilterBase, cons
|
||||
aLinePropertiesBottomLeftToTopRight,
|
||||
rTable.getSwCell() );
|
||||
}
|
||||
if ( ( nRow == 0 ) && ( nColumn == nMaxColumn ) )
|
||||
if (rProperties.isFirstRow() && rProperties.isLastCol() && nRow == 0 && nColumn == nMaxColumn)
|
||||
{
|
||||
applyTableStylePart( rFilterBase, aFillProperties, aTextStyleProps,
|
||||
aLinePropertiesLeft,
|
||||
@@ -451,7 +451,8 @@ void TableCell::pushToXCell( const ::oox::core::XmlFilterBase& rFilterBase, cons
|
||||
aLinePropertiesBottomLeftToTopRight,
|
||||
rTable.getNeCell() );
|
||||
}
|
||||
if ( ( nRow == nMaxRow ) && ( nColumn == nMaxColumn ) )
|
||||
if (rProperties.isLastRow() && rProperties.isLastCol() && nRow == nMaxRow
|
||||
&& nColumn == nMaxColumn)
|
||||
{
|
||||
applyTableStylePart( rFilterBase, aFillProperties, aTextStyleProps,
|
||||
aLinePropertiesLeft,
|
||||
|
||||
Reference in New Issue
Block a user