Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1811)

Side by Side Diff: Source/WebCore/rendering/TextAutosizer.h

Issue 12310107: Merge 143356 (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/1410/
Patch Set: Created 7 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « Source/WebCore/page/Settings.cpp ('k') | Source/WebCore/rendering/TextAutosizer.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2012 Google Inc. All rights reserved. 2 * Copyright (C) 2012 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
43 43
44 class TextAutosizer { 44 class TextAutosizer {
45 WTF_MAKE_NONCOPYABLE(TextAutosizer); 45 WTF_MAKE_NONCOPYABLE(TextAutosizer);
46 46
47 public: 47 public:
48 static PassOwnPtr<TextAutosizer> create(Document* document) { return adoptPt r(new TextAutosizer(document)); } 48 static PassOwnPtr<TextAutosizer> create(Document* document) { return adoptPt r(new TextAutosizer(document)); }
49 49
50 virtual ~TextAutosizer(); 50 virtual ~TextAutosizer();
51 51
52 bool processSubtree(RenderObject* layoutRoot); 52 bool processSubtree(RenderObject* layoutRoot);
53 void recalculateMultipliers();
53 54
54 static float computeAutosizedFontSize(float specifiedSize, float multiplier) ; 55 static float computeAutosizedFontSize(float specifiedSize, float multiplier) ;
55 56
56 private: 57 private:
57 enum TraversalDirection { 58 enum TraversalDirection {
58 FirstToLast, 59 FirstToLast,
59 LastToFirst 60 LastToFirst
60 }; 61 };
61 62
62 explicit TextAutosizer(Document*); 63 explicit TextAutosizer(Document*);
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
97 static void getNarrowDescendantsGroupedByWidth(const TextAutosizingClusterIn fo& parentClusterInfo, Vector<Vector<TextAutosizingClusterInfo> >&); 98 static void getNarrowDescendantsGroupedByWidth(const TextAutosizingClusterIn fo& parentClusterInfo, Vector<Vector<TextAutosizingClusterInfo> >&);
98 99
99 Document* m_document; 100 Document* m_document;
100 }; 101 };
101 102
102 } // namespace WebCore 103 } // namespace WebCore
103 104
104 #endif // ENABLE(TEXT_AUTOSIZING) 105 #endif // ENABLE(TEXT_AUTOSIZING)
105 106
106 #endif // TextAutosizer_h 107 #endif // TextAutosizer_h
OLDNEW
« no previous file with comments | « Source/WebCore/page/Settings.cpp ('k') | Source/WebCore/rendering/TextAutosizer.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698