OLD | NEW |
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 283 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
294 | 294 |
295 void showRenderObject() const; | 295 void showRenderObject() const; |
296 // We don't make printedCharacters an optional parameter so that | 296 // We don't make printedCharacters an optional parameter so that |
297 // showRenderObject can be called from gdb easily. | 297 // showRenderObject can be called from gdb easily. |
298 void showRenderObject(int printedCharacters) const; | 298 void showRenderObject(int printedCharacters) const; |
299 void showRenderTreeAndMark(const RenderObject* markedObject1 = 0, const char
* markedLabel1 = 0, const RenderObject* markedObject2 = 0, const char* markedLab
el2 = 0, int depth = 0) const; | 299 void showRenderTreeAndMark(const RenderObject* markedObject1 = 0, const char
* markedLabel1 = 0, const RenderObject* markedObject2 = 0, const char* markedLab
el2 = 0, int depth = 0) const; |
300 #endif | 300 #endif |
301 | 301 |
302 static RenderObject* createObject(Element*, RenderStyle*); | 302 static RenderObject* createObject(Element*, RenderStyle*); |
303 | 303 |
304 // Overloaded new operator. Derived classes must override operator new | 304 // RenderObjects are allocated out of the rendering partition. |
305 // in order to allocate out of the RenderArena. | 305 void* operator new(size_t); |
306 void* operator new(size_t, RenderArena*); | 306 void operator delete(void*); |
307 | |
308 // Overridden to prevent the normal delete from being called. | |
309 void operator delete(void*, size_t); | |
310 | |
311 private: | |
312 // The normal operator new is disallowed on all render objects. | |
313 void* operator new(size_t) throw(); | |
314 | 307 |
315 public: | 308 public: |
316 RenderArena* renderArena() const { return document()->renderArena(); } | |
317 | |
318 bool isPseudoElement() const { return node() && node()->isPseudoElement(); } | 309 bool isPseudoElement() const { return node() && node()->isPseudoElement(); } |
319 | 310 |
320 virtual bool isBR() const { return false; } | 311 virtual bool isBR() const { return false; } |
321 virtual bool isBlockFlow() const { return false; } | 312 virtual bool isBlockFlow() const { return false; } |
322 virtual bool isBoxModelObject() const { return false; } | 313 virtual bool isBoxModelObject() const { return false; } |
323 virtual bool isCounter() const { return false; } | 314 virtual bool isCounter() const { return false; } |
324 virtual bool isDialog() const { return false; } | 315 virtual bool isDialog() const { return false; } |
325 virtual bool isQuote() const { return false; } | 316 virtual bool isQuote() const { return false; } |
326 | 317 |
327 virtual bool isDetailsMarker() const { return false; } | 318 virtual bool isDetailsMarker() const { return false; } |
(...skipping 684 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1012 void paintFocusRing(PaintInfo&, const LayoutPoint&, RenderStyle*); | 1003 void paintFocusRing(PaintInfo&, const LayoutPoint&, RenderStyle*); |
1013 void paintOutline(PaintInfo&, const LayoutRect&); | 1004 void paintOutline(PaintInfo&, const LayoutRect&); |
1014 void addPDFURLRect(GraphicsContext*, const LayoutRect&); | 1005 void addPDFURLRect(GraphicsContext*, const LayoutRect&); |
1015 | 1006 |
1016 virtual LayoutRect viewRect() const; | 1007 virtual LayoutRect viewRect() const; |
1017 | 1008 |
1018 void adjustRectForOutlineAndShadow(LayoutRect&) const; | 1009 void adjustRectForOutlineAndShadow(LayoutRect&) const; |
1019 | 1010 |
1020 void clearLayoutRootIfNeeded() const; | 1011 void clearLayoutRootIfNeeded() const; |
1021 virtual void willBeDestroyed(); | 1012 virtual void willBeDestroyed(); |
1022 void arenaDelete(RenderArena*, void* objectBase); | 1013 void postDestroy(); |
1023 | 1014 |
1024 virtual bool canBeReplacedWithInlineRunIn() const; | 1015 virtual bool canBeReplacedWithInlineRunIn() const; |
1025 | 1016 |
1026 virtual void insertedIntoTree(); | 1017 virtual void insertedIntoTree(); |
1027 virtual void willBeRemovedFromTree(); | 1018 virtual void willBeRemovedFromTree(); |
1028 | 1019 |
1029 void setDocumentForAnonymous(Document* document) { ASSERT(isAnonymous()); m_
node = document; } | 1020 void setDocumentForAnonymous(Document* document) { ASSERT(isAnonymous()); m_
node = document; } |
1030 | 1021 |
1031 // Add hit-test rects for the render tree rooted at this node to the provide
d collection on a | 1022 // Add hit-test rects for the render tree rooted at this node to the provide
d collection on a |
1032 // per-RenderLayer basis. CurrentLayer must be the enclosing layer, | 1023 // per-RenderLayer basis. CurrentLayer must be the enclosing layer, |
(...skipping 366 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1399 // Outside the WebCore namespace for ease of invocation from gdb. | 1390 // Outside the WebCore namespace for ease of invocation from gdb. |
1400 void showTree(const WebCore::RenderObject*); | 1391 void showTree(const WebCore::RenderObject*); |
1401 void showLineTree(const WebCore::RenderObject*); | 1392 void showLineTree(const WebCore::RenderObject*); |
1402 void showRenderTree(const WebCore::RenderObject* object1); | 1393 void showRenderTree(const WebCore::RenderObject* object1); |
1403 // We don't make object2 an optional parameter so that showRenderTree | 1394 // We don't make object2 an optional parameter so that showRenderTree |
1404 // can be called from gdb easily. | 1395 // can be called from gdb easily. |
1405 void showRenderTree(const WebCore::RenderObject* object1, const WebCore::RenderO
bject* object2); | 1396 void showRenderTree(const WebCore::RenderObject* object1, const WebCore::RenderO
bject* object2); |
1406 #endif | 1397 #endif |
1407 | 1398 |
1408 #endif // RenderObject_h | 1399 #endif // RenderObject_h |
OLD | NEW |