#ifndef SVGTextLayoutEngineBaseline_h
#define SVGTextLayoutEngineBaseline_h
#include "core/rendering/style/SVGRenderStyleDefs.h"
#include "wtf/Noncopyable.h"
namespace WebCore {
class Font;
class RenderObject;
class SVGElement;
class SVGRenderStyle;
class SVGTextMetrics;
class SVGTextLayoutEngineBaseline {
WTF_MAKE_NONCOPYABLE(SVGTextLayoutEngineBaseline);
public:
SVGTextLayoutEngineBaseline(const Font&);
float calculateBaselineShift(const SVGRenderStyle*, SVGElement* lengthContext) const;
float calculateAlignmentBaselineShift(bool isVerticalText, const RenderObject* textRenderer) const;
float calculateGlyphOrientationAngle(bool isVerticalText, const SVGRenderStyle*, const UChar& character) const;
float calculateGlyphAdvanceAndOrientation(bool isVerticalText, SVGTextMetrics&, float angle, float& xOrientationShift, float& yOrientationShift) const;
private:
EAlignmentBaseline dominantBaselineToAlignmentBaseline(bool isVerticalText, const RenderObject* textRenderer) const;
const Font& m_font;
};
}
#endif