1 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* vim: set ts=2 et sw=2 tw=80: */
3 /* This Source Code is subject to the terms of the Mozilla Public License
4 * version 2.0 (the "License"). You can obtain a copy of the License at
5 * http://mozilla.org/MPL/2.0/. */
7 /* rendering object for CSS "display: ruby-text" */
9 #ifndef nsRubyTextFrame_h___
10 #define nsRubyTextFrame_h___
12 #include "nsContainerFrame.h"
16 * @return a newly allocated nsRubyTextFrame (infallible)
18 nsContainerFrame
* NS_NewRubyTextFrame(nsIPresShell
* aPresShell
,
19 nsStyleContext
* aContext
);
21 class nsRubyTextFrame MOZ_FINAL
: public nsContainerFrame
24 NS_DECL_FRAMEARENA_HELPERS
25 NS_DECL_QUERYFRAME_TARGET(nsRubyTextFrame
)
29 virtual nsIAtom
* GetType() const MOZ_OVERRIDE
;
30 virtual void Reflow(nsPresContext
* aPresContext
,
31 nsHTMLReflowMetrics
& aDesiredSize
,
32 const nsHTMLReflowState
& aReflowState
,
33 nsReflowStatus
& aStatus
) MOZ_OVERRIDE
;
34 virtual bool IsFrameOfType(uint32_t aFlags
) const MOZ_OVERRIDE
;
35 virtual void AddInlineMinISize(nsRenderingContext
*aRenderingContext
,
36 InlineMinISizeData
*aData
) MOZ_OVERRIDE
;
37 virtual void AddInlinePrefISize(nsRenderingContext
*aRenderingContext
,
38 InlinePrefISizeData
*aData
) MOZ_OVERRIDE
;
39 virtual nscoord
GetMinISize(nsRenderingContext
*aRenderingContext
) MOZ_OVERRIDE
;
40 virtual nscoord
GetPrefISize(nsRenderingContext
*aRenderingContext
) MOZ_OVERRIDE
;
41 virtual nscoord
GetLogicalBaseline(mozilla::WritingMode aWritingMode
)
44 #ifdef DEBUG_FRAME_DUMP
45 virtual nsresult
GetFrameName(nsAString
& aResult
) const MOZ_OVERRIDE
;
49 friend nsContainerFrame
* NS_NewRubyTextFrame(nsIPresShell
* aPresShell
,
50 nsStyleContext
* aContext
);
51 explicit nsRubyTextFrame(nsStyleContext
* aContext
) : nsContainerFrame(aContext
) {}
55 #endif /* nsRubyTextFrame_h___ */