mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-25 05:41:12 +00:00
Added methods to support justification
This commit is contained in:
parent
274d1bc566
commit
a6731c54fe
@ -1187,17 +1187,35 @@ nsFrame::FindTextRuns(nsLineLayout& aLineLayout)
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
NS_IMETHODIMP nsFrame::ContentChanged(nsIPresContext* aPresContext,
|
||||
nsIContent* aChild,
|
||||
nsISupports* aSubContent)
|
||||
NS_IMETHODIMP
|
||||
nsFrame::AdjustFrameSize(nscoord aExtraSpace, nscoord& aUsedSpace)
|
||||
{
|
||||
aUsedSpace = 0;
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
NS_IMETHODIMP
|
||||
nsFrame::TrimTrailingWhiteSpace(nsIPresContext& aPresContext,
|
||||
nsIRenderingContext& aRC,
|
||||
nscoord& aDeltaWidth)
|
||||
{
|
||||
aDeltaWidth = 0;
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
NS_IMETHODIMP
|
||||
nsFrame::ContentChanged(nsIPresContext* aPresContext,
|
||||
nsIContent* aChild,
|
||||
nsISupports* aSubContent)
|
||||
{
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
NS_IMETHODIMP nsFrame::AttributeChanged(nsIPresContext* aPresContext,
|
||||
nsIContent* aChild,
|
||||
nsIAtom* aAttribute,
|
||||
PRInt32 aHint)
|
||||
NS_IMETHODIMP
|
||||
nsFrame::AttributeChanged(nsIPresContext* aPresContext,
|
||||
nsIContent* aChild,
|
||||
nsIAtom* aAttribute,
|
||||
PRInt32 aHint)
|
||||
{
|
||||
return NS_OK;
|
||||
}
|
||||
|
@ -208,6 +208,12 @@ public:
|
||||
NS_IMETHOD GetReflowMetrics(nsIPresContext& aPresContext,
|
||||
nsHTMLReflowMetrics& aMetrics);
|
||||
NS_IMETHOD FindTextRuns(nsLineLayout& aLineLayout);
|
||||
|
||||
NS_IMETHOD AdjustFrameSize(nscoord aExtraSpace, nscoord& aUsedSpace);
|
||||
|
||||
NS_IMETHOD TrimTrailingWhiteSpace(nsIPresContext& aPresContext,
|
||||
nsIRenderingContext& aRC,
|
||||
nscoord& aDeltaWidth);
|
||||
//@}
|
||||
|
||||
// Selection Methods
|
||||
|
@ -1187,17 +1187,35 @@ nsFrame::FindTextRuns(nsLineLayout& aLineLayout)
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
NS_IMETHODIMP nsFrame::ContentChanged(nsIPresContext* aPresContext,
|
||||
nsIContent* aChild,
|
||||
nsISupports* aSubContent)
|
||||
NS_IMETHODIMP
|
||||
nsFrame::AdjustFrameSize(nscoord aExtraSpace, nscoord& aUsedSpace)
|
||||
{
|
||||
aUsedSpace = 0;
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
NS_IMETHODIMP
|
||||
nsFrame::TrimTrailingWhiteSpace(nsIPresContext& aPresContext,
|
||||
nsIRenderingContext& aRC,
|
||||
nscoord& aDeltaWidth)
|
||||
{
|
||||
aDeltaWidth = 0;
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
NS_IMETHODIMP
|
||||
nsFrame::ContentChanged(nsIPresContext* aPresContext,
|
||||
nsIContent* aChild,
|
||||
nsISupports* aSubContent)
|
||||
{
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
NS_IMETHODIMP nsFrame::AttributeChanged(nsIPresContext* aPresContext,
|
||||
nsIContent* aChild,
|
||||
nsIAtom* aAttribute,
|
||||
PRInt32 aHint)
|
||||
NS_IMETHODIMP
|
||||
nsFrame::AttributeChanged(nsIPresContext* aPresContext,
|
||||
nsIContent* aChild,
|
||||
nsIAtom* aAttribute,
|
||||
PRInt32 aHint)
|
||||
{
|
||||
return NS_OK;
|
||||
}
|
||||
|
@ -208,6 +208,12 @@ public:
|
||||
NS_IMETHOD GetReflowMetrics(nsIPresContext& aPresContext,
|
||||
nsHTMLReflowMetrics& aMetrics);
|
||||
NS_IMETHOD FindTextRuns(nsLineLayout& aLineLayout);
|
||||
|
||||
NS_IMETHOD AdjustFrameSize(nscoord aExtraSpace, nscoord& aUsedSpace);
|
||||
|
||||
NS_IMETHOD TrimTrailingWhiteSpace(nsIPresContext& aPresContext,
|
||||
nsIRenderingContext& aRC,
|
||||
nscoord& aDeltaWidth);
|
||||
//@}
|
||||
|
||||
// Selection Methods
|
||||
|
@ -282,6 +282,17 @@ public:
|
||||
// Helper method used by block reflow to identify runs of text so that
|
||||
// proper word-breaking can be done.
|
||||
NS_IMETHOD FindTextRuns(nsLineLayout& aLineLayout) = 0;
|
||||
|
||||
// Justification helper method used to distribute extra space in a
|
||||
// line to leaf frames. aUsedSpace is filled in with the amount of
|
||||
// space actually used.
|
||||
NS_IMETHOD AdjustFrameSize(nscoord aExtraSpace, nscoord& aUsedSpace) = 0;
|
||||
|
||||
// Justification helper method that is used to remove trailing
|
||||
// whitespace before justification.
|
||||
NS_IMETHOD TrimTrailingWhiteSpace(nsIPresContext& aPresContext,
|
||||
nsIRenderingContext& aRC,
|
||||
nscoord& aDeltaWidth) = 0;
|
||||
};
|
||||
|
||||
//----------------------------------------------------------------------
|
||||
|
Loading…
Reference in New Issue
Block a user