From 1bf1084f2b10c3b47fd1a588d85d21ed0eb41d0c Mon Sep 17 00:00:00 2001 From: Lorry Tar Creator Date: Tue, 27 Jun 2017 06:07:23 +0000 Subject: webkitgtk-2.16.5 --- Source/WebCore/rendering/svg/SVGTextChunkBuilder.h | 25 +++++++--------------- 1 file changed, 8 insertions(+), 17 deletions(-) (limited to 'Source/WebCore/rendering/svg/SVGTextChunkBuilder.h') diff --git a/Source/WebCore/rendering/svg/SVGTextChunkBuilder.h b/Source/WebCore/rendering/svg/SVGTextChunkBuilder.h index 321f3915f..7a7880a87 100644 --- a/Source/WebCore/rendering/svg/SVGTextChunkBuilder.h +++ b/Source/WebCore/rendering/svg/SVGTextChunkBuilder.h @@ -1,5 +1,6 @@ /* * Copyright (C) Research In Motion Limited 2010. All rights reserved. + * Copyright (C) 2015 Apple Inc. All rights reserved. * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Library General Public @@ -17,10 +18,8 @@ * Boston, MA 02110-1301, USA. */ -#ifndef SVGTextChunkBuilder_h -#define SVGTextChunkBuilder_h +#pragma once -#if ENABLE(SVG) #include "SVGTextChunk.h" #include @@ -41,18 +40,13 @@ public: SVGTextChunkBuilder(); const Vector& textChunks() const { return m_textChunks; } - void transformationForTextBox(SVGInlineTextBox*, AffineTransform&) const; + unsigned totalCharacters() const; + float totalLength() const; + float totalAnchorShift() const; + AffineTransform transformationForTextBox(SVGInlineTextBox*) const; - void buildTextChunks(Vector& lineLayoutBoxes); - void layoutTextChunks(Vector& lineLayoutBoxes); - -private: - void addTextChunk(Vector& lineLayoutBoxes, unsigned boxPosition, unsigned boxCount); - void processTextChunk(const SVGTextChunk&); - - void processTextLengthSpacingCorrection(bool isVerticalText, float textLengthShift, Vector&, unsigned& atCharacter); - void processTextAnchorCorrection(bool isVerticalText, float textAnchorShift, Vector&); - void buildSpacingAndGlyphsTransform(bool isVerticalText, float scale, const SVGTextFragment&, AffineTransform&); + void buildTextChunks(const Vector& lineLayoutBoxes); + void layoutTextChunks(const Vector& lineLayoutBoxes); private: Vector m_textChunks; @@ -60,6 +54,3 @@ private: }; } // namespace WebCore - -#endif // ENABLE(SVG) -#endif -- cgit v1.2.1