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

Side by Side Diff: Source/core/rendering/RenderObject.h

Issue 219633002: Proper support for multiple text decorations. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Fix jchaffraix' issues. Created 6 years, 7 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/core/rendering/InlineTextBox.cpp ('k') | Source/core/rendering/RenderObject.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) 2000 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 2000 Lars Knoll (knoll@kde.org)
3 * (C) 2000 Antti Koivisto (koivisto@kde.org) 3 * (C) 2000 Antti Koivisto (koivisto@kde.org)
4 * (C) 2000 Dirk Mueller (mueller@kde.org) 4 * (C) 2000 Dirk Mueller (mueller@kde.org)
5 * (C) 2004 Allan Sandfeld Jensen (kde@carewolf.com) 5 * (C) 2004 Allan Sandfeld Jensen (kde@carewolf.com)
6 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2012 Apple Inc. All r ights reserved. 6 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2012 Apple Inc. All r ights reserved.
7 * Copyright (C) 2009 Google Inc. All rights reserved. 7 * Copyright (C) 2009 Google Inc. All rights reserved.
8 * 8 *
9 * This library is free software; you can redistribute it and/or 9 * This library is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU Library General Public 10 * modify it under the terms of the GNU Library General Public
(...skipping 784 matching lines...) Expand 10 before | Expand all | Expand 10 after
795 // Used only by Element::pseudoStyleCacheIsInvalid to get a first line style based off of a 795 // Used only by Element::pseudoStyleCacheIsInvalid to get a first line style based off of a
796 // given new style, without accessing the cache. 796 // given new style, without accessing the cache.
797 PassRefPtr<RenderStyle> uncachedFirstLineStyle(RenderStyle*) const; 797 PassRefPtr<RenderStyle> uncachedFirstLineStyle(RenderStyle*) const;
798 798
799 // Anonymous blocks that are part of of a continuation chain will return the ir inline continuation's outline style instead. 799 // Anonymous blocks that are part of of a continuation chain will return the ir inline continuation's outline style instead.
800 // This is typically only relevant when repainting. 800 // This is typically only relevant when repainting.
801 virtual RenderStyle* outlineStyleForRepaint() const { return style(); } 801 virtual RenderStyle* outlineStyleForRepaint() const { return style(); }
802 802
803 virtual CursorDirective getCursor(const LayoutPoint&, Cursor&) const; 803 virtual CursorDirective getCursor(const LayoutPoint&, Cursor&) const;
804 804
805 struct AppliedTextDecoration { 805 struct ResolvedDecoration {
806 ResolvedDecoration();
807 ResolvedDecoration(const AppliedTextDecoration&, const Color&);
808
809 TextDecoration line;
810 TextDecorationStyle style;
806 Color color; 811 Color color;
807 TextDecorationStyle style;
808 AppliedTextDecoration() : color(Color::transparent), style(TextDecoratio nStyleSolid) { }
809 }; 812 };
810 813
811 void getTextDecorations(unsigned decorations, AppliedTextDecoration& underli ne, AppliedTextDecoration& overline, AppliedTextDecoration& linethrough, bool qu irksMode = false, bool firstlineStyle = false); 814 typedef Vector<ResolvedDecoration, 1> ResolvedDecorationVector;
815
816 void resolvedDecorations(bool firstlineStyle, const Vector<AppliedTextDecora tion>&, ResolvedDecorationVector&);
812 817
813 // Return the RenderLayerModelObject in the container chain which is respons ible for painting this object, or 0 818 // Return the RenderLayerModelObject in the container chain which is respons ible for painting this object, or 0
814 // if painting is root-relative. This is the container that should be passed to the 'forRepaint' 819 // if painting is root-relative. This is the container that should be passed to the 'forRepaint'
815 // methods. 820 // methods.
816 RenderLayerModelObject* containerForRepaint() const; 821 RenderLayerModelObject* containerForRepaint() const;
817 822
818 // Actually do the repaint of rect r for this object which has been computed in the coordinate space 823 // Actually do the repaint of rect r for this object which has been computed in the coordinate space
819 // of repaintContainer. If repaintContainer is 0, repaint via the view. 824 // of repaintContainer. If repaintContainer is 0, repaint via the view.
820 void repaintUsingContainer(const RenderLayerModelObject* repaintContainer, c onst IntRect&, InvalidationReason) const; 825 void repaintUsingContainer(const RenderLayerModelObject* repaintContainer, c onst IntRect&, InvalidationReason) const;
821 826
(...skipping 639 matching lines...) Expand 10 before | Expand all | Expand 10 after
1461 void showTree(const WebCore::RenderObject*); 1466 void showTree(const WebCore::RenderObject*);
1462 void showLineTree(const WebCore::RenderObject*); 1467 void showLineTree(const WebCore::RenderObject*);
1463 void showRenderTree(const WebCore::RenderObject* object1); 1468 void showRenderTree(const WebCore::RenderObject* object1);
1464 // We don't make object2 an optional parameter so that showRenderTree 1469 // We don't make object2 an optional parameter so that showRenderTree
1465 // can be called from gdb easily. 1470 // can be called from gdb easily.
1466 void showRenderTree(const WebCore::RenderObject* object1, const WebCore::RenderO bject* object2); 1471 void showRenderTree(const WebCore::RenderObject* object1, const WebCore::RenderO bject* object2);
1467 1472
1468 #endif 1473 #endif
1469 1474
1470 #endif // RenderObject_h 1475 #endif // RenderObject_h
OLDNEW
« no previous file with comments | « Source/core/rendering/InlineTextBox.cpp ('k') | Source/core/rendering/RenderObject.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698