OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc.
All rights reserved. | 2 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc.
All rights reserved. |
3 * Copyright (C) 2008, 2010 Nokia Corporation and/or its subsidiary(-ies) | 3 * Copyright (C) 2008, 2010 Nokia Corporation and/or its subsidiary(-ies) |
4 * Copyright (C) 2007 Alp Toker <alp@atoker.com> | 4 * Copyright (C) 2007 Alp Toker <alp@atoker.com> |
5 * Copyright (C) 2008 Eric Seidel <eric@webkit.org> | 5 * Copyright (C) 2008 Eric Seidel <eric@webkit.org> |
6 * Copyright (C) 2008 Dirk Schulze <krit@webkit.org> | 6 * Copyright (C) 2008 Dirk Schulze <krit@webkit.org> |
7 * Copyright (C) 2010 Torch Mobile (Beijing) Co. Ltd. All rights reserved. | 7 * Copyright (C) 2010 Torch Mobile (Beijing) Co. Ltd. All rights reserved. |
8 * Copyright (C) 2012, 2013 Intel Corporation. All rights reserved. | 8 * Copyright (C) 2012, 2013 Intel Corporation. All rights reserved. |
9 * Copyright (C) 2013 Adobe Systems Incorporated. All rights reserved. | 9 * Copyright (C) 2013 Adobe Systems Incorporated. All rights reserved. |
10 * | 10 * |
(...skipping 2080 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2091 CSSPropertyValue(CSSPropertyFontSize, *parsedStyle), | 2091 CSSPropertyValue(CSSPropertyFontSize, *parsedStyle), |
2092 CSSPropertyValue(CSSPropertyLineHeight, *parsedStyle), | 2092 CSSPropertyValue(CSSPropertyLineHeight, *parsedStyle), |
2093 }; | 2093 }; |
2094 | 2094 |
2095 StyleResolver* styleResolver = canvas()->styleResolver(); | 2095 StyleResolver* styleResolver = canvas()->styleResolver(); |
2096 styleResolver->applyPropertiesToStyle(properties, WTF_ARRAY_LENGTH(propertie
s), newStyle.get()); | 2096 styleResolver->applyPropertiesToStyle(properties, WTF_ARRAY_LENGTH(propertie
s), newStyle.get()); |
2097 | 2097 |
2098 if (state().m_realizedFont) | 2098 if (state().m_realizedFont) |
2099 state().m_font.fontSelector()->unregisterForInvalidationCallbacks(&modif
iableState()); | 2099 state().m_font.fontSelector()->unregisterForInvalidationCallbacks(&modif
iableState()); |
2100 modifiableState().m_font = newStyle->font(); | 2100 modifiableState().m_font = newStyle->font(); |
2101 modifiableState().m_font.update(styleResolver->fontSelector()); | 2101 modifiableState().m_font.update(canvas()->document().fontSelector()); |
2102 modifiableState().m_realizedFont = true; | 2102 modifiableState().m_realizedFont = true; |
2103 styleResolver->fontSelector()->registerForInvalidationCallbacks(&modifiableS
tate()); | 2103 canvas()->document().fontSelector()->registerForInvalidationCallbacks(&modif
iableState()); |
2104 } | 2104 } |
2105 | 2105 |
2106 String CanvasRenderingContext2D::textAlign() const | 2106 String CanvasRenderingContext2D::textAlign() const |
2107 { | 2107 { |
2108 return textAlignName(state().m_textAlign); | 2108 return textAlignName(state().m_textAlign); |
2109 } | 2109 } |
2110 | 2110 |
2111 void CanvasRenderingContext2D::setTextAlign(const String& s) | 2111 void CanvasRenderingContext2D::setTextAlign(const String& s) |
2112 { | 2112 { |
2113 TextAlign align; | 2113 TextAlign align; |
(...skipping 313 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2427 const int focusRingWidth = 5; | 2427 const int focusRingWidth = 5; |
2428 const int focusRingOutline = 0; | 2428 const int focusRingOutline = 0; |
2429 c->drawFocusRing(path, focusRingWidth, focusRingOutline, focusRingColor); | 2429 c->drawFocusRing(path, focusRingWidth, focusRingOutline, focusRingColor); |
2430 | 2430 |
2431 c->restore(); | 2431 c->restore(); |
2432 | 2432 |
2433 didDraw(dirtyRect); | 2433 didDraw(dirtyRect); |
2434 } | 2434 } |
2435 | 2435 |
2436 } // namespace WebCore | 2436 } // namespace WebCore |
OLD | NEW |