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

Side by Side Diff: Source/core/css/CSSFontValue.cpp

Issue 199423003: Add plumbing for font-stretch (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 9 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 | Annotate | Revision Log
« no previous file with comments | « Source/core/css/CSSFontValue.h ('k') | Source/core/css/CSSPrimitiveValueMappings.h » ('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 * (C) 1999-2003 Lars Knoll (knoll@kde.org) 2 * (C) 1999-2003 Lars Knoll (knoll@kde.org)
3 * Copyright (C) 2004, 2005, 2006 Apple Computer, Inc. 3 * Copyright (C) 2004, 2005, 2006 Apple Computer, Inc.
4 * 4 *
5 * This library is free software; you can redistribute it and/or 5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Library General Public 6 * modify it under the terms of the GNU Library General Public
7 * License as published by the Free Software Foundation; either 7 * License as published by the Free Software Foundation; either
8 * version 2 of the License, or (at your option) any later version. 8 * version 2 of the License, or (at your option) any later version.
9 * 9 *
10 * This library is distributed in the hope that it will be useful, 10 * This library is distributed in the hope that it will be useful,
(...skipping 26 matching lines...) Expand all
37 if (variant) { 37 if (variant) {
38 if (!result.isEmpty()) 38 if (!result.isEmpty())
39 result.append(' '); 39 result.append(' ');
40 result.append(variant->cssText()); 40 result.append(variant->cssText());
41 } 41 }
42 if (weight) { 42 if (weight) {
43 if (!result.isEmpty()) 43 if (!result.isEmpty())
44 result.append(' '); 44 result.append(' ');
45 result.append(weight->cssText()); 45 result.append(weight->cssText());
46 } 46 }
47 if (stretch) {
48 if (!result.isEmpty())
49 result.append(' ');
50 result.append(stretch->cssText());
51 }
47 if (size) { 52 if (size) {
48 if (!result.isEmpty()) 53 if (!result.isEmpty())
49 result.append(' '); 54 result.append(' ');
50 result.append(size->cssText()); 55 result.append(size->cssText());
51 } 56 }
52 if (lineHeight) { 57 if (lineHeight) {
53 if (!size) 58 if (!size)
54 result.append(' '); 59 result.append(' ');
55 result.append('/'); 60 result.append('/');
56 result.append(lineHeight->cssText()); 61 result.append(lineHeight->cssText());
57 } 62 }
58 if (family) { 63 if (family) {
59 if (!result.isEmpty()) 64 if (!result.isEmpty())
60 result.append(' '); 65 result.append(' ');
61 result.append(family->cssText()); 66 result.append(family->cssText());
62 } 67 }
63 68
64 return result.toString(); 69 return result.toString();
65 } 70 }
66 71
67 bool CSSFontValue::equals(const CSSFontValue& other) const 72 bool CSSFontValue::equals(const CSSFontValue& other) const
68 { 73 {
69 return compareCSSValuePtr(style, other.style) 74 return compareCSSValuePtr(style, other.style)
70 && compareCSSValuePtr(variant, other.variant) 75 && compareCSSValuePtr(variant, other.variant)
71 && compareCSSValuePtr(weight, other.weight) 76 && compareCSSValuePtr(weight, other.weight)
77 && compareCSSValuePtr(stretch, other.stretch)
72 && compareCSSValuePtr(size, other.size) 78 && compareCSSValuePtr(size, other.size)
73 && compareCSSValuePtr(lineHeight, other.lineHeight) 79 && compareCSSValuePtr(lineHeight, other.lineHeight)
74 && compareCSSValuePtr(family, other.family); 80 && compareCSSValuePtr(family, other.family);
75 } 81 }
76 82
77 void CSSFontValue::traceAfterDispatch(Visitor* visitor) 83 void CSSFontValue::traceAfterDispatch(Visitor* visitor)
78 { 84 {
79
80 visitor->trace(style); 85 visitor->trace(style);
81 visitor->trace(variant); 86 visitor->trace(variant);
82 visitor->trace(weight); 87 visitor->trace(weight);
88 visitor->trace(stretch);
83 visitor->trace(size); 89 visitor->trace(size);
84 visitor->trace(lineHeight); 90 visitor->trace(lineHeight);
85 visitor->trace(family); 91 visitor->trace(family);
86 CSSValue::traceAfterDispatch(visitor); 92 CSSValue::traceAfterDispatch(visitor);
87 } 93 }
88 94
89 } 95 }
OLDNEW
« no previous file with comments | « Source/core/css/CSSFontValue.h ('k') | Source/core/css/CSSPrimitiveValueMappings.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698