Use default text alignment; setup opacity properly

This commit is contained in:
kipp 1998-05-28 02:01:19 +00:00
parent 13cab9bf52
commit 024ff28d3a
3 changed files with 9 additions and 3 deletions

View File

@ -85,9 +85,11 @@ void StyleColorImpl::ResetFrom(const nsStyleColor* aParent, nsIPresContext* aPre
{
if (nsnull != aParent) {
mColor = aParent->mColor;
mOpacity = aParent->mOpacity;
}
else {
mColor = NS_RGB(0, 0, 0);
mOpacity.SetPercentValue(1.0F);
}
mBackgroundAttachment = NS_STYLE_BG_ATTACHMENT_SCROLL;
@ -459,7 +461,7 @@ void StyleTextImpl::ResetFrom(const nsStyleText* aParent, nsIPresContext* aPresC
mWordSpacing = aParent->mWordSpacing;
}
else {
mTextAlign = NS_STYLE_TEXT_ALIGN_LEFT;
mTextAlign = NS_STYLE_TEXT_ALIGN_DEFAULT;
mTextTransform = NS_STYLE_TEXT_TRANSFORM_NONE;
mWhiteSpace = NS_STYLE_WHITESPACE_NORMAL;

View File

@ -85,9 +85,11 @@ void StyleColorImpl::ResetFrom(const nsStyleColor* aParent, nsIPresContext* aPre
{
if (nsnull != aParent) {
mColor = aParent->mColor;
mOpacity = aParent->mOpacity;
}
else {
mColor = NS_RGB(0, 0, 0);
mOpacity.SetPercentValue(1.0F);
}
mBackgroundAttachment = NS_STYLE_BG_ATTACHMENT_SCROLL;
@ -459,7 +461,7 @@ void StyleTextImpl::ResetFrom(const nsStyleText* aParent, nsIPresContext* aPresC
mWordSpacing = aParent->mWordSpacing;
}
else {
mTextAlign = NS_STYLE_TEXT_ALIGN_LEFT;
mTextAlign = NS_STYLE_TEXT_ALIGN_DEFAULT;
mTextTransform = NS_STYLE_TEXT_TRANSFORM_NONE;
mWhiteSpace = NS_STYLE_WHITESPACE_NORMAL;

View File

@ -85,9 +85,11 @@ void StyleColorImpl::ResetFrom(const nsStyleColor* aParent, nsIPresContext* aPre
{
if (nsnull != aParent) {
mColor = aParent->mColor;
mOpacity = aParent->mOpacity;
}
else {
mColor = NS_RGB(0, 0, 0);
mOpacity.SetPercentValue(1.0F);
}
mBackgroundAttachment = NS_STYLE_BG_ATTACHMENT_SCROLL;
@ -459,7 +461,7 @@ void StyleTextImpl::ResetFrom(const nsStyleText* aParent, nsIPresContext* aPresC
mWordSpacing = aParent->mWordSpacing;
}
else {
mTextAlign = NS_STYLE_TEXT_ALIGN_LEFT;
mTextAlign = NS_STYLE_TEXT_ALIGN_DEFAULT;
mTextTransform = NS_STYLE_TEXT_TRANSFORM_NONE;
mWhiteSpace = NS_STYLE_WHITESPACE_NORMAL;