Back to index

lightning-sunbird  0.9+nobinonly
Public Member Functions | Public Attributes | Protected Attributes
nsStyleOutline Struct Reference

#include <nsStyleStruct.h>

Inheritance diagram for nsStyleOutline:
Inheritance graph
[legend]
Collaboration diagram for nsStyleOutline:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 nsStyleOutline (nsPresContext *aPresContext)
 nsStyleOutline (const nsStyleOutline &aOutline)
 ~nsStyleOutline (void)
voidoperator new (size_t sz, nsPresContext *aContext) CPP_THROW_NEW
void Destroy (nsPresContext *aContext)
void RecalcData (nsPresContext *aContext)
nsChangeHint CalcDifference (const nsStyleOutline &aOther) const
PRBool GetOutlineOffset (nscoord &aOffset) const
PRBool GetOutlineWidth (nscoord &aWidth) const
PRUint8 GetOutlineStyle (void) const
void SetOutlineStyle (PRUint8 aStyle)
PRBool GetOutlineColor (nscolor &aColor) const
void SetOutlineColor (nscolor aColor)
void SetOutlineInvert (void)
PRBool GetOutlineInvert (void) const

Public Attributes

nsStyleSides mOutlineRadius
nsStyleCoord mOutlineOffset
nsStyleCoord mOutlineWidth

Protected Attributes

nscoord mCachedOutlineWidth
nscolor mOutlineColor
PRPackedBool mHasCachedOutline
PRUint8 mOutlineStyle

Detailed Description

Definition at line 534 of file nsStyleStruct.h.


Constructor & Destructor Documentation

Definition at line 520 of file nsStyleStruct.cpp.

Here is the call graph for this function:

Definition at line 533 of file nsStyleStruct.cpp.

                                                         {
  memcpy((nsStyleOutline*)this, &aSrc, sizeof(nsStyleOutline));
}

Here is the call graph for this function:

Definition at line 537 of file nsStyleStruct.h.

{};

Here is the caller graph for this function:


Member Function Documentation

Definition at line 551 of file nsStyleStruct.cpp.

{
  PRBool outlineWasVisible =
    mCachedOutlineWidth > 0 && mOutlineStyle != NS_STYLE_BORDER_STYLE_NONE;
  PRBool outlineIsVisible = 
    aOther.mCachedOutlineWidth > 0 && aOther.mOutlineStyle != NS_STYLE_BORDER_STYLE_NONE;
  if (outlineWasVisible != outlineIsVisible ||
      (outlineIsVisible && (mOutlineOffset != aOther.mOutlineOffset ||
                            mOutlineWidth != aOther.mOutlineWidth))) {
    return NS_CombineHint(nsChangeHint_ReflowFrame, nsChangeHint_RepaintFrame);
  }
  if ((mOutlineStyle != aOther.mOutlineStyle) ||
      (mOutlineColor != aOther.mOutlineColor) ||
      (mOutlineRadius != aOther.mOutlineRadius)) {
    return nsChangeHint_RepaintFrame;
  }
  return NS_STYLE_HINT_NONE;
}

Here is the call graph for this function:

void nsStyleOutline::Destroy ( nsPresContext aContext) [inline]

Definition at line 544 of file nsStyleStruct.h.

                                        {
    this->~nsStyleOutline();
    aContext->FreeToShell(sizeof(nsStyleOutline), this);
  };

Here is the call graph for this function:

Here is the caller graph for this function:

PRBool nsStyleOutline::GetOutlineColor ( nscolor aColor) const [inline]

Definition at line 594 of file nsStyleStruct.h.

  {
    if ((mOutlineStyle & BORDER_COLOR_SPECIAL) == 0) {
      aColor = mOutlineColor;
      return PR_TRUE;
    }
    return PR_FALSE;
  }

Here is the caller graph for this function:

Definition at line 614 of file nsStyleStruct.h.

Here is the caller graph for this function:

PRBool nsStyleOutline::GetOutlineOffset ( nscoord aOffset) const [inline]

Definition at line 561 of file nsStyleStruct.h.

  {
    if (mOutlineOffset.GetUnit() == eStyleUnit_Coord) {
      aOffset = mOutlineOffset.GetCoordValue();
      return PR_TRUE;
    } else {
      NS_NOTYETIMPLEMENTED("GetOutlineOffset: eStyleUnit_Chars");
      aOffset = 0;
      return PR_FALSE;
    }
  }

Here is the call graph for this function:

Here is the caller graph for this function:

Definition at line 582 of file nsStyleStruct.h.

Here is the caller graph for this function:

PRBool nsStyleOutline::GetOutlineWidth ( nscoord aWidth) const [inline]

Definition at line 573 of file nsStyleStruct.h.

  {
    if (mHasCachedOutline) {
      aWidth = mCachedOutlineWidth;
      return PR_TRUE;
    }
    return PR_FALSE;
  }

Here is the caller graph for this function:

void* nsStyleOutline::operator new ( size_t  sz,
nsPresContext aContext 
) [inline]

Definition at line 541 of file nsStyleStruct.h.

                                                                       {
    return aContext->AllocateFromShell(sz);
  }

Definition at line 538 of file nsStyleStruct.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

Definition at line 603 of file nsStyleStruct.h.

Here is the caller graph for this function:

Definition at line 609 of file nsStyleStruct.h.

Here is the caller graph for this function:

Definition at line 587 of file nsStyleStruct.h.

Here is the caller graph for this function:


Member Data Documentation

Definition at line 620 of file nsStyleStruct.h.

Definition at line 624 of file nsStyleStruct.h.

Definition at line 622 of file nsStyleStruct.h.

Definition at line 558 of file nsStyleStruct.h.

Definition at line 555 of file nsStyleStruct.h.

Definition at line 625 of file nsStyleStruct.h.

Definition at line 559 of file nsStyleStruct.h.


The documentation for this struct was generated from the following files: