summaryrefslogtreecommitdiff
path: root/core/fpdfapi/page/cpdf_textobject.h
diff options
context:
space:
mode:
authorDan Sinclair <dsinclair@chromium.org>2017-10-04 15:10:04 -0400
committerChromium commit bot <commit-bot@chromium.org>2017-10-04 19:21:26 +0000
commit985e86f297e8319dbf3fd37247613f66e9f11216 (patch)
tree87a75673476fbf846a9eab9096e003638d8ea862 /core/fpdfapi/page/cpdf_textobject.h
parent75a205f03fb755f4766ea674e470ff8de5d905b7 (diff)
downloadpdfium-985e86f297e8319dbf3fd37247613f66e9f11216.tar.xz
Remove friends from CPDF_TextObjectchromium/3233
This CL removes the friends from CPDF_TextObject and adds accessor methods as needed. Change-Id: I68d18297640b46113df79f58bea50b77dac89d39 Reviewed-on: https://pdfium-review.googlesource.com/15455 Reviewed-by: Henrique Nakashima <hnakashima@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org>
Diffstat (limited to 'core/fpdfapi/page/cpdf_textobject.h')
-rw-r--r--core/fpdfapi/page/cpdf_textobject.h10
1 files changed, 4 insertions, 6 deletions
diff --git a/core/fpdfapi/page/cpdf_textobject.h b/core/fpdfapi/page/cpdf_textobject.h
index 5cffbd1434..02653dc2aa 100644
--- a/core/fpdfapi/page/cpdf_textobject.h
+++ b/core/fpdfapi/page/cpdf_textobject.h
@@ -48,20 +48,18 @@ class CPDF_TextObject : public CPDF_PageObject {
float GetFontSize() const;
void SetText(const ByteString& text);
+ void SetPosition(CFX_PointF pos) { m_Pos = pos; }
void SetPosition(float x, float y);
void RecalcPositionData();
- private:
- friend class CPDF_RenderStatus;
- friend class CPDF_StreamContentParser;
- friend class CPDF_TextRenderer;
- friend class CPDF_PageContentGenerator;
+ const std::vector<uint32_t>& GetCharCodes() const { return m_CharCodes; }
+ const std::vector<float>& GetCharPositions() const { return m_CharPos; }
void SetSegments(const ByteString* pStrs, const float* pKerning, int nSegs);
-
CFX_PointF CalcPositionData(float horz_scale);
+ private:
CFX_PointF m_Pos;
std::vector<uint32_t> m_CharCodes;
std::vector<float> m_CharPos;