Changeset 218373 in webkit
- Timestamp:
- Jun 15, 2017, 6:39:31 PM (8 years ago)
- Location:
- trunk/Source/WebCore
- Files:
-
- 35 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebCore/ChangeLog
r218372 r218373 1 2017-06-15 Simon Fraser <simon.fraser@apple.com> 2 3 Use WTFLogAlways for debug logging so that it shows up in device system logs 4 https://bugs.webkit.org/show_bug.cgi?id=173450 5 6 Reviewed by Tim Horton. 7 8 If you want to showRenderTree() on-device, the result doesn't show in system log so you can't see it 9 Switch to WTFLogAlways to fix this, for all the debug logging in WebCore. 10 11 Also WKError () -> WKError() in the old WAK code, to allow for easier searching pending cleanup. 12 13 * Modules/webaudio/AudioContext.cpp: 14 (WebCore::AudioContext::~AudioContext): 15 * Modules/webaudio/AudioNode.cpp: 16 (WebCore::AudioNode::~AudioNode): 17 (WebCore::AudioNode::ref): 18 (WebCore::AudioNode::finishDeref): 19 (WebCore::AudioNode::printNodeCounts): 20 * bridge/objc/objc_instance.mm: 21 (ObjcInstance::invokeObjcMethod): 22 * bridge/objc/objc_utility.mm: 23 (JSC::Bindings::convertObjcValueToValue): 24 * css/StyleProperties.cpp: 25 (WebCore::StyleProperties::showStyle): 26 * dom/DocumentMarkerController.cpp: 27 (DocumentMarkerController::showMarkers): 28 * dom/Node.cpp: 29 (WebCore::Node::showNode): 30 (WebCore::Node::showNodePathForThis): 31 (WebCore::traverseTreeAndMark): 32 * dom/Position.cpp: 33 (WebCore::Position::debugPosition): 34 (WebCore::Position::showAnchorTypeAndOffset): 35 * dom/Range.cpp: 36 (showTree): 37 * editing/FrameSelection.cpp: 38 (WebCore::FrameSelection::debugRenderer): 39 * editing/VisiblePosition.cpp: 40 (WebCore::VisiblePosition::debugPosition): 41 * editing/VisibleSelection.cpp: 42 (WebCore::VisibleSelection::debugPosition): 43 * history/HistoryItem.cpp: 44 (WebCore::HistoryItem::showTreeWithIndent): 45 * html/parser/HTMLFormattingElementList.cpp: 46 (WebCore::HTMLFormattingElementList::show): 47 * inspector/DOMPatchSupport.cpp: 48 (WebCore::DOMPatchSupport::dumpMap): 49 * page/scrolling/ScrollingStateTree.cpp: 50 (showScrollingStateTree): 51 * platform/audio/ios/AudioDestinationIOS.cpp: 52 (WebCore::AudioDestinationIOS::frameSizeChangedProc): 53 * platform/graphics/GraphicsLayer.cpp: 54 (showGraphicsLayerTree): 55 * platform/graphics/displaylists/DisplayList.cpp: 56 (WebCore::DisplayList::DisplayList::dump): 57 * platform/ios/wak/WAKView.mm: 58 (+[WAKView _wrapperForViewRef:]): 59 (-[WAKView displayRect:]): 60 (-[WAKView displayRectIgnoringOpacity:inContext:]): 61 * platform/ios/wak/WKUtilities.c: 62 (WKRelease): 63 * platform/ios/wak/WKView.mm: 64 (_WKViewSetViewContext): 65 (WKViewGetBounds): 66 (WKViewGetFrame): 67 (_WKViewRecursivelyInvalidateGState): 68 (WKViewSetFrameOrigin): 69 (WKViewSetFrameSize): 70 (WKViewGetWindow): 71 (WKViewGetSubviews): 72 (WKViewAddSubview): 73 (WKViewRemoveFromSuperview): 74 (WKViewFirstChild): 75 (WKViewNextSibling): 76 (WKViewTraverseNext): 77 (WKViewGetVisibleRect): 78 (WKViewConvertRectToSuperview): 79 (WKViewConvertRectToBase): 80 (WKViewConvertPointToSuperview): 81 (WKViewConvertPointFromSuperview): 82 (WKViewConvertPointToBase): 83 (_WKViewGetAncestorViewsIncludingView): 84 (WKViewConvertPointFromBase): 85 (WKViewConvertRectFromSuperview): 86 (WKViewConvertRectFromBase): 87 (WKViewGetAutoresizingMask): 88 (WKViewSetAutoresizingMask): 89 * platform/text/TextEncodingRegistry.cpp: 90 (WebCore::dumpTextEncodingNameMap): 91 * rendering/CounterNode.cpp: 92 (WebCore::showTreeAndMark): 93 * rendering/InlineBox.cpp: 94 (WebCore::InlineBox::showLineBox): 95 * rendering/InlineTextBox.cpp: 96 (WebCore::InlineTextBox::showLineBox): 97 * rendering/RenderCounter.cpp: 98 (showCounterRendererTree): 99 * rendering/RenderLayer.cpp: 100 (WebCore::showLayerTree): 101 * rendering/RenderObject.cpp: 102 (WebCore::showRenderTreeLegend): 103 (WebCore::RenderObject::showRegionsInformation): 104 (WebCore::RenderObject::showRenderObject): 105 (WebCore::printRenderTreeForLiveDocuments): 106 (WebCore::printLayerTreeForLiveDocuments): 107 * rendering/SimpleLineLayoutFunctions.cpp: 108 (WebCore::SimpleLineLayout::printPrefix): 109 (WebCore::SimpleLineLayout::showLineLayoutForFlow): 110 * rendering/svg/SVGResources.cpp: 111 (WebCore::SVGResources::dump): 112 * rendering/svg/SVGResourcesCycleSolver.cpp: 113 (WebCore::SVGResourcesCycleSolver::resolveCycles): 114 * rendering/svg/SVGTextLayoutAttributes.cpp: 115 (WebCore::dumpSVGCharacterDataMapValue): 116 (WebCore::SVGTextLayoutAttributes::dump): 117 * rendering/svg/SVGTextLayoutEngine.cpp: 118 (WebCore::dumpTextBoxes): 119 (WebCore::SVGTextLayoutEngine::finishLayout): 120 1 121 2017-06-15 Myles C. Maxfield <mmaxfield@apple.com> 2 122 -
trunk/Source/WebCore/Modules/webaudio/AudioContext.cpp
r218016 r218373 191 191 { 192 192 #if DEBUG_AUDIONODE_REFERENCES 193 fprintf(stderr,"%p: AudioContext::~AudioContext()\n", this);193 WTFLogAlways("%p: AudioContext::~AudioContext()\n", this); 194 194 #endif 195 195 ASSERT(!m_isInitialized); -
trunk/Source/WebCore/Modules/webaudio/AudioNode.cpp
r214620 r218373 71 71 #if DEBUG_AUDIONODE_REFERENCES 72 72 --s_nodeCount[nodeType()]; 73 fprintf(stderr,"%p: %d: AudioNode::~AudioNode() %d %d\n", this, nodeType(), m_normalRefCount.load(), m_connectionRefCount);73 WTFLogAlways("%p: %d: AudioNode::~AudioNode() %d %d\n", this, nodeType(), m_normalRefCount.load(), m_connectionRefCount); 74 74 #endif 75 75 } … … 405 405 406 406 #if DEBUG_AUDIONODE_REFERENCES 407 fprintf(stderr,"%p: %d: AudioNode::ref(%d) %d %d\n", this, nodeType(), refType, m_normalRefCount, m_connectionRefCount);407 WTFLogAlways("%p: %d: AudioNode::ref(%d) %d %d\n", this, nodeType(), refType, m_normalRefCount, m_connectionRefCount); 408 408 #endif 409 409 … … 468 468 469 469 #if DEBUG_AUDIONODE_REFERENCES 470 fprintf(stderr,"%p: %d: AudioNode::deref(%d) %d %d\n", this, nodeType(), refType, m_normalRefCount, m_connectionRefCount);470 WTFLogAlways("%p: %d: AudioNode::deref(%d) %d %d\n", this, nodeType(), refType, m_normalRefCount, m_connectionRefCount); 471 471 #endif 472 472 … … 494 494 void AudioNode::printNodeCounts() 495 495 { 496 fprintf(stderr,"\n\n");497 fprintf(stderr,"===========================\n");498 fprintf(stderr,"AudioNode: reference counts\n");499 fprintf(stderr,"===========================\n");496 WTFLogAlways("\n\n"); 497 WTFLogAlways("===========================\n"); 498 WTFLogAlways("AudioNode: reference counts\n"); 499 WTFLogAlways("===========================\n"); 500 500 501 501 for (unsigned i = 0; i < NodeTypeEnd; ++i) 502 fprintf(stderr,"%d: %d\n", i, s_nodeCount[i]);503 504 fprintf(stderr,"===========================\n\n\n");502 WTFLogAlways("%d: %d\n", i, s_nodeCount[i]); 503 504 WTFLogAlways("===========================\n\n\n"); 505 505 } 506 506 -
trunk/Source/WebCore/bridge/objc/objc_instance.mm
r217108 r218373 42 42 #import <wtf/ThreadSpecific.h> 43 43 44 #ifdef NDEBUG45 #define OBJC_LOG(formatAndArgs...) ((void)0)46 #else47 #define OBJC_LOG(formatAndArgs...) { \48 fprintf (stderr, "%s:%d -- %s: ", __FILE__, __LINE__, __FUNCTION__); \49 fprintf(stderr, formatAndArgs); \50 }51 #endif52 53 44 using namespace JSC::Bindings; 54 45 using namespace JSC; … … 303 294 // the assert above should have fired in the impossible case 304 295 // of an invalid type anyway). 305 fprintf(stderr,"%s: invalid type (%d)\n", __PRETTY_FUNCTION__, (int)objcValueType);296 WTFLogAlways("%s: invalid type (%d)\n", __PRETTY_FUNCTION__, (int)objcValueType); 306 297 ASSERT_NOT_REACHED(); 307 298 } -
trunk/Source/WebCore/bridge/objc/objc_utility.mm
r205198 r218373 230 230 default: 231 231 // Should never get here. Argument types are filtered. 232 fprintf(stderr,"%s: invalid type (%d)\n", __PRETTY_FUNCTION__, (int)type);232 WTFLogAlways("%s: invalid type (%d)\n", __PRETTY_FUNCTION__, (int)type); 233 233 ASSERT_NOT_REACHED(); 234 234 } -
trunk/Source/WebCore/css/StyleProperties.cpp
r216829 r218373 1364 1364 void StyleProperties::showStyle() 1365 1365 { 1366 fprintf(stderr,"%s\n", asText().ascii().data());1366 WTFLogAlways("%s\n", asText().ascii().data()); 1367 1367 } 1368 1368 #endif -
trunk/Source/WebCore/dom/DocumentMarkerController.cpp
r216212 r218373 819 819 void DocumentMarkerController::showMarkers() const 820 820 { 821 fprintf(stderr,"%d nodes have markers:\n", m_markers.size());821 WTFLogAlways("%d nodes have markers:\n", m_markers.size()); 822 822 for (auto& marker : m_markers) { 823 823 Node* node = marker.key.get(); 824 fprintf(stderr,"%p", node);824 WTFLogAlways("%p", node); 825 825 for (auto& documentMarker : *marker.value) 826 fprintf(stderr," %d:[%d:%d](%d)", documentMarker.type(), documentMarker.startOffset(), documentMarker.endOffset(), documentMarker.isActiveMatch());827 828 fprintf(stderr,"\n");826 WTFLogAlways(" %d:[%d:%d](%d)", documentMarker.type(), documentMarker.startOffset(), documentMarker.endOffset(), documentMarker.isActiveMatch()); 827 828 WTFLogAlways("\n"); 829 829 } 830 830 } -
trunk/Source/WebCore/dom/Node.cpp
r218083 r218373 1730 1730 value.replaceWithLiteral('\\', "\\\\"); 1731 1731 value.replaceWithLiteral('\n', "\\n"); 1732 fprintf(stderr,"%s%s\t%p \"%s\"\n", prefix, nodeName().utf8().data(), this, value.utf8().data());1732 WTFLogAlways("%s%s\t%p \"%s\"\n", prefix, nodeName().utf8().data(), this, value.utf8().data()); 1733 1733 } else { 1734 1734 StringBuilder attrs; 1735 1735 appendAttributeDesc(this, attrs, classAttr, " CLASS="); 1736 1736 appendAttributeDesc(this, attrs, styleAttr, " STYLE="); 1737 fprintf(stderr,"%s%s\t%p (renderer %p) %s%s%s\n", prefix, nodeName().utf8().data(), this, renderer(), attrs.toString().utf8().data(), needsStyleRecalc() ? " (needs style recalc)" : "", childNeedsStyleRecalc() ? " (child needs style recalc)" : "");1737 WTFLogAlways("%s%s\t%p (renderer %p) %s%s%s\n", prefix, nodeName().utf8().data(), this, renderer(), attrs.toString().utf8().data(), needsStyleRecalc() ? " (needs style recalc)" : "", childNeedsStyleRecalc() ? " (child needs style recalc)" : ""); 1738 1738 } 1739 1739 } … … 1758 1758 for (const ShadowRoot* shadowRoot = downcast<ShadowRoot>(node); shadowRoot && shadowRoot != node; shadowRoot = shadowRoot->shadowRoot()) 1759 1759 ++count; 1760 fprintf(stderr,"/#shadow-root[%d]", count);1760 WTFLogAlways("/#shadow-root[%d]", count); 1761 1761 continue; 1762 1762 } … … 1764 1764 switch (node->nodeType()) { 1765 1765 case ELEMENT_NODE: { 1766 fprintf(stderr,"/%s", node->nodeName().utf8().data());1766 WTFLogAlways("/%s", node->nodeName().utf8().data()); 1767 1767 1768 1768 const Element& element = downcast<Element>(*node); … … 1775 1775 ++count; 1776 1776 if (hasIdAttr) 1777 fprintf(stderr,"[@id=\"%s\" and position()=%d]", idattr.string().utf8().data(), count);1777 WTFLogAlways("[@id=\"%s\" and position()=%d]", idattr.string().utf8().data(), count); 1778 1778 else 1779 fprintf(stderr,"[%d]", count);1779 WTFLogAlways("[%d]", count); 1780 1780 } else if (hasIdAttr) 1781 fprintf(stderr,"[@id=\"%s\"]", idattr.string().utf8().data());1781 WTFLogAlways("[@id=\"%s\"]", idattr.string().utf8().data()); 1782 1782 break; 1783 1783 } 1784 1784 case TEXT_NODE: 1785 fprintf(stderr,"/text()");1785 WTFLogAlways("/text()"); 1786 1786 break; 1787 1787 case ATTRIBUTE_NODE: 1788 fprintf(stderr,"/@%s", node->nodeName().utf8().data());1788 WTFLogAlways("/@%s", node->nodeName().utf8().data()); 1789 1789 break; 1790 1790 default: … … 1792 1792 } 1793 1793 } 1794 fprintf(stderr,"\n");1794 WTFLogAlways("\n"); 1795 1795 } 1796 1796 … … 1799 1799 for (const Node* node = rootNode; node; node = NodeTraversal::next(*node)) { 1800 1800 if (node == markedNode1) 1801 fprintf(stderr,"%s", markedLabel1);1801 WTFLogAlways("%s", markedLabel1); 1802 1802 if (node == markedNode2) 1803 fprintf(stderr,"%s", markedLabel2);1803 WTFLogAlways("%s", markedLabel2); 1804 1804 1805 1805 StringBuilder indent; … … 1807 1807 for (const Node* tmpNode = node; tmpNode && tmpNode != rootNode; tmpNode = tmpNode->parentOrShadowHostNode()) 1808 1808 indent.append('\t'); 1809 fprintf(stderr,"%s", indent.toString().utf8().data());1809 WTFLogAlways("%s", indent.toString().utf8().data()); 1810 1810 node->showNode(); 1811 1811 indent.append('\t'); -
trunk/Source/WebCore/dom/Position.cpp
r215094 r218373 1399 1399 { 1400 1400 if (isNull()) 1401 fprintf(stderr,"Position [%s]: null\n", msg);1401 WTFLogAlways("Position [%s]: null\n", msg); 1402 1402 else 1403 fprintf(stderr,"Position [%s]: %s [%p] at %d\n", msg, deprecatedNode()->nodeName().utf8().data(), deprecatedNode(), m_offset);1403 WTFLogAlways("Position [%s]: %s [%p] at %d\n", msg, deprecatedNode()->nodeName().utf8().data(), deprecatedNode(), m_offset); 1404 1404 } 1405 1405 … … 1443 1443 break; 1444 1444 } 1445 fprintf(stderr,", offset:%d\n", m_offset);1445 WTFLogAlways(", offset:%d\n", m_offset); 1446 1446 } 1447 1447 -
trunk/Source/WebCore/dom/Range.cpp
r217576 r218373 1838 1838 if (range && range->boundaryPointsValid()) { 1839 1839 range->startContainer().showTreeAndMark(&range->startContainer(), "S", &range->endContainer(), "E"); 1840 fprintf(stderr,"start offset: %d, end offset: %d\n", range->startOffset(), range->endOffset());1840 WTFLogAlways("start offset: %d, end offset: %d\n", range->startOffset(), range->endOffset()); 1841 1841 } 1842 1842 } -
trunk/Source/WebCore/editing/FrameSelection.cpp
r217439 r218373 1754 1754 if (is<Element>(*renderer->node())) { 1755 1755 Element& element = downcast<Element>(*renderer->node()); 1756 fprintf(stderr,"%s%s\n", selected ? "==> " : " ", element.localName().string().utf8().data());1756 WTFLogAlways("%s%s\n", selected ? "==> " : " ", element.localName().string().utf8().data()); 1757 1757 } else if (is<RenderText>(*renderer)) { 1758 1758 RenderText& textRenderer = downcast<RenderText>(*renderer); 1759 1759 if (!textRenderer.textLength() || !textRenderer.firstTextBox()) { 1760 fprintf(stderr,"%s#text (empty)\n", selected ? "==> " : " ");1760 WTFLogAlways("%s#text (empty)\n", selected ? "==> " : " "); 1761 1761 return; 1762 1762 } … … 1800 1800 show.replace('\n', ' '); 1801 1801 show.replace('\r', ' '); 1802 fprintf(stderr,"==> #text : \"%s\" at offset %d\n", show.utf8().data(), pos);1803 fprintf(stderr," ");1802 WTFLogAlways("==> #text : \"%s\" at offset %d\n", show.utf8().data(), pos); 1803 WTFLogAlways(" "); 1804 1804 for (int i = 0; i < caret; i++) 1805 fprintf(stderr," ");1806 fprintf(stderr,"^\n");1805 WTFLogAlways(" "); 1806 WTFLogAlways("^\n"); 1807 1807 } else { 1808 1808 if ((int)text.length() > max) … … 1810 1810 else 1811 1811 text = text.left(max); 1812 fprintf(stderr," #text : \"%s\"\n", text.utf8().data());1812 WTFLogAlways(" #text : \"%s\"\n", text.utf8().data()); 1813 1813 } 1814 1814 } -
trunk/Source/WebCore/editing/VisiblePosition.cpp
r213355 r218373 690 690 { 691 691 if (isNull()) 692 fprintf(stderr,"Position [%s]: null\n", msg);692 WTFLogAlways("Position [%s]: null\n", msg); 693 693 else { 694 fprintf(stderr,"Position [%s]: %s, ", msg, m_deepPosition.deprecatedNode()->nodeName().utf8().data());694 WTFLogAlways("Position [%s]: %s, ", msg, m_deepPosition.deprecatedNode()->nodeName().utf8().data()); 695 695 m_deepPosition.showAnchorTypeAndOffset(); 696 696 } -
trunk/Source/WebCore/editing/VisibleSelection.cpp
r213355 r218373 672 672 void VisibleSelection::debugPosition() const 673 673 { 674 fprintf(stderr,"VisibleSelection ===============\n");674 WTFLogAlways("VisibleSelection ===============\n"); 675 675 676 676 if (!m_start.anchorNode()) 677 677 fputs("pos: null", stderr); 678 678 else if (m_start == m_end) { 679 fprintf(stderr,"pos: %s ", m_start.anchorNode()->nodeName().utf8().data());679 WTFLogAlways("pos: %s ", m_start.anchorNode()->nodeName().utf8().data()); 680 680 m_start.showAnchorTypeAndOffset(); 681 681 } else { 682 fprintf(stderr,"start: %s ", m_start.anchorNode()->nodeName().utf8().data());682 WTFLogAlways("start: %s ", m_start.anchorNode()->nodeName().utf8().data()); 683 683 m_start.showAnchorTypeAndOffset(); 684 fprintf(stderr,"end: %s ", m_end.anchorNode()->nodeName().utf8().data());684 WTFLogAlways("end: %s ", m_end.anchorNode()->nodeName().utf8().data()); 685 685 m_end.showAnchorTypeAndOffset(); 686 686 } 687 687 688 fprintf(stderr,"================================\n");688 WTFLogAlways("================================\n"); 689 689 } 690 690 -
trunk/Source/WebCore/history/HistoryItem.cpp
r217867 r218373 495 495 prefix.append("\0", 1); 496 496 497 fprintf(stderr,"%s+-%s (%p)\n", prefix.data(), m_urlString.utf8().data(), this);497 WTFLogAlways("%s+-%s (%p)\n", prefix.data(), m_urlString.utf8().data(), this); 498 498 499 499 int totalSubItems = 0; -
trunk/Source/WebCore/html/parser/HTMLFormattingElementList.cpp
r200340 r218373 203 203 const Entry& entry = m_entries[m_entries.size() - i]; 204 204 if (entry.isMarker()) 205 fprintf(stderr,"marker\n");205 WTFLogAlways("marker\n"); 206 206 else 207 207 entry.element().showNode(); -
trunk/Source/WebCore/inspector/DOMPatchSupport.cpp
r216883 r218373 506 506 void DOMPatchSupport::dumpMap(const ResultMap& map, const String& name) 507 507 { 508 fprintf(stderr,"\n\n");508 WTFLogAlways("\n\n"); 509 509 for (size_t i = 0; i < map.size(); ++i) 510 fprintf(stderr,"%s[%lu]: %s (%p) - [%lu]\n", name.utf8().data(), i, map[i].first ? nodeName(map[i].first->m_node).utf8().data() : "", map[i].first, map[i].second);510 WTFLogAlways("%s[%lu]: %s (%p) - [%lu]\n", name.utf8().data(), i, map[i].first ? nodeName(map[i].first->m_node).utf8().data() : "", map[i].first, map[i].second); 511 511 } 512 512 -
trunk/Source/WebCore/page/scrolling/ScrollingStateTree.cpp
r216103 r218373 273 273 auto rootNode = tree->rootStateNode(); 274 274 if (!rootNode) { 275 fprintf(stderr,"Scrolling state tree %p with no root node\n", tree);275 WTFLogAlways("Scrolling state tree %p with no root node\n", tree); 276 276 return; 277 277 } 278 278 279 279 String output = rootNode->scrollingStateTreeAsText(WebCore::ScrollingStateTreeAsTextBehaviorDebug); 280 fprintf(stderr,"%s\n", output.utf8().data());280 WTFLogAlways("%s\n", output.utf8().data()); 281 281 } 282 282 -
trunk/Source/WebCore/platform/audio/ios/AudioDestinationIOS.cpp
r210697 r218373 269 269 UInt32 dataSize = sizeof(bufferSize); 270 270 AudioUnitGetProperty(audioOutput->m_outputUnit, kAudioUnitProperty_MaximumFramesPerSlice, kAudioUnitScope_Global, 0, (void*)&bufferSize, &dataSize); 271 fprintf(stderr,">>>> frameSizeChanged = %lu\n", static_cast<unsigned long>(bufferSize));271 WTFLogAlways(">>>> frameSizeChanged = %lu\n", static_cast<unsigned long>(bufferSize)); 272 272 } 273 273 -
trunk/Source/WebCore/platform/graphics/GraphicsLayer.cpp
r217696 r218373 971 971 972 972 String output = layer->layerTreeAsText(WebCore::LayerTreeAsTextDebug | WebCore::LayerTreeAsTextIncludeVisibleRects | WebCore::LayerTreeAsTextIncludeTileCaches | WebCore::LayerTreeAsTextIncludeContentLayers); 973 fprintf(stderr,"%s\n", output.utf8().data());974 } 975 #endif 973 WTFLogAlways("%s\n", output.utf8().data()); 974 } 975 #endif -
trunk/Source/WebCore/platform/graphics/displaylists/DisplayList.cpp
r208466 r218373 45 45 void DisplayList::dump() const 46 46 { 47 fprintf(stderr,"%s", description().data());47 WTFLogAlways("%s", description().data()); 48 48 } 49 49 #endif -
trunk/Source/WebCore/platform/ios/wak/WAKView.mm
r217296 r218373 212 212 if (_viewRef->isa.classInfo == &WKViewClassInfo) 213 213 return [[[WAKView alloc] _initWithViewRef:_viewRef] autorelease]; 214 WKError 214 WKError("unable to create wrapper for %s\n", _viewRef->isa.classInfo->name); 215 215 return nil; 216 216 } … … 543 543 CGContextRef context = WKGetCurrentGraphicsContext(); 544 544 if (!context) { 545 WKError 545 WKError("unable to get context for view"); 546 546 return; 547 547 } … … 558 558 { 559 559 if (!context) { 560 WKError 560 WKError("invalid parameter: context must not be NULL"); 561 561 return; 562 562 } -
trunk/Source/WebCore/platform/ios/wak/WKUtilities.c
r180243 r218373 60 60 61 61 if (object->referenceCount == 0) { 62 WKError 62 WKError("attempt to release invalid object"); 63 63 return; 64 64 } -
trunk/Source/WebCore/platform/ios/wak/WKView.mm
r185021 r218373 118 118 { 119 119 if (!view) { 120 WKError 120 WKError("invalid parameter"); 121 121 return; 122 122 } … … 127 127 { 128 128 if (!view) { 129 WKError 129 WKError("invalid parameter"); 130 130 return CGRectZero; 131 131 } … … 137 137 { 138 138 if (!view) { 139 WKError 139 WKError("invalid parameter"); 140 140 return CGRectZero; 141 141 } … … 157 157 { 158 158 if (!view) { 159 WKError 159 WKError("invalid parameter"); 160 160 return; 161 161 } … … 174 174 { 175 175 if (!view) { 176 WKError 176 WKError("invalid parameter"); 177 177 return; 178 178 } … … 323 323 { 324 324 if (!view) { 325 WKError 325 WKError("invalid parameter"); 326 326 return; 327 327 } … … 387 387 { 388 388 if (!view) { 389 WKError 389 WKError("invalid parameter"); 390 390 return 0; 391 391 } … … 397 397 { 398 398 if (!view) { 399 WKError 399 WKError("invalid parameter"); 400 400 return 0; 401 401 } … … 407 407 { 408 408 if (!view || !subview) { 409 WKError 409 WKError("invalid parameter"); 410 410 return; 411 411 } … … 424 424 { 425 425 if (!view) { 426 WKError 426 WKError("invalid parameter"); 427 427 return; 428 428 } … … 436 436 CFMutableArrayRef svs = view->superview->subviews; 437 437 if (!svs) { 438 WKError 438 WKError("superview has no subviews"); 439 439 return; 440 440 } … … 442 442 CFIndex index = WKArrayIndexOfValue (svs, view); 443 443 if (index < 0) { 444 WKError 444 WKError("view not in superview subviews"); 445 445 return; 446 446 } … … 456 456 { 457 457 if (!view) { 458 WKError 458 WKError("invalid parameter"); 459 459 return 0; 460 460 } … … 475 475 { 476 476 if (!view) { 477 WKError 477 WKError("invalid parameter"); 478 478 return 0; 479 479 } … … 488 488 CFIndex thisIndex = WKArrayIndexOfValue (svs, view); 489 489 if (thisIndex < 0) { 490 WKError 490 WKError("internal error, view is not present in superview subviews"); 491 491 return 0; 492 492 } … … 503 503 { 504 504 if (!view) { 505 WKError 505 WKError("invalid parameter"); 506 506 return 0; 507 507 } … … 539 539 { 540 540 if (!viewRef) { 541 WKError 541 WKError("invalid parameter"); 542 542 return CGRectZero; 543 543 } … … 565 565 { 566 566 if (!view) { 567 WKError 567 WKError("invalid parameter"); 568 568 return CGRectZero; 569 569 } … … 575 575 { 576 576 if (!view) { 577 WKError 577 WKError("invalid parameter"); 578 578 return CGRectZero; 579 579 } … … 592 592 { 593 593 if (!view) { 594 WKError 594 WKError("invalid parameter"); 595 595 return CGPointZero; 596 596 } … … 602 602 { 603 603 if (!view) { 604 WKError 604 WKError("invalid parameter"); 605 605 return CGPointZero; 606 606 } … … 613 613 { 614 614 if (!view) { 615 WKError 615 WKError("invalid parameter"); 616 616 return CGPointZero; 617 617 } … … 638 638 views[count++] = superview; 639 639 if (count >= maxViews) { 640 WKError 640 WKError("Exceeded maxViews, use malloc/realloc"); 641 641 *viewCount = 0; 642 642 return; … … 650 650 { 651 651 if (!view) { 652 WKError 652 WKError("invalid parameter"); 653 653 return CGPointZero; 654 654 } … … 673 673 { 674 674 if (!view) { 675 WKError 675 WKError("invalid parameter"); 676 676 return CGRectZero; 677 677 } … … 684 684 { 685 685 if (!view) { 686 WKError 686 WKError("invalid parameter"); 687 687 return CGRectZero; 688 688 } … … 731 731 { 732 732 if (!view) { 733 WKError 733 WKError("invalid parameter"); 734 734 return 0; 735 735 } … … 740 740 { 741 741 if (!view) { 742 WKError 742 WKError("invalid parameter"); 743 743 return; 744 744 } -
trunk/Source/WebCore/platform/text/TextEncodingRegistry.cpp
r217860 r218373 392 392 { 393 393 unsigned size = textEncodingNameMap->size(); 394 fprintf(stderr,"Dumping %u entries in WebCore::textEncodingNameMap...\n", size);394 WTFLogAlways("Dumping %u entries in WebCore::textEncodingNameMap...\n", size); 395 395 396 396 std::lock_guard<StaticLock> lock(encodingRegistryMutex); … … 399 399 TextEncodingNameMap::const_iterator end = textEncodingNameMap->end(); 400 400 for (; it != end; ++it) 401 fprintf(stderr,"'%s' => '%s'\n", it->key, it->value);401 WTFLogAlways("'%s' => '%s'\n", it->key, it->value); 402 402 } 403 403 #endif -
trunk/Source/WebCore/rendering/CounterNode.cpp
r214082 r218373 337 337 338 338 for (const CounterNode* current = root; current; current = current->nextInPreOrder()) { 339 fprintf(stderr,"%c", (current == node) ? '*' : ' ');339 WTFLogAlways("%c", (current == node) ? '*' : ' '); 340 340 for (const CounterNode* parent = current; parent && parent != root; parent = parent->parent()) 341 fprintf(stderr," ");342 fprintf(stderr,"%p %s: %d %d P:%p PS:%p NS:%p R:%p\n",341 WTFLogAlways(" "); 342 WTFLogAlways("%p %s: %d %d P:%p PS:%p NS:%p R:%p\n", 343 343 current, current->actsAsReset() ? "reset____" : "increment", current->value(), 344 344 current->countInParent(), current->parent(), current->previousSibling(), -
trunk/Source/WebCore/rendering/InlineBox.cpp
r217242 r218373 108 108 void InlineBox::showLineBox(bool mark, int depth) const 109 109 { 110 fprintf(stderr,"-------- %c-", isDirty() ? 'D' : '-');110 WTFLogAlways("-------- %c-", isDirty() ? 'D' : '-'); 111 111 int printedCharacters = 0; 112 112 if (mark) { 113 fprintf(stderr,"*");113 WTFLogAlways("*"); 114 114 ++printedCharacters; 115 115 } 116 116 while (++printedCharacters <= depth * 2) 117 117 fputc(' ', stderr); 118 fprintf(stderr,"%s (%.2f, %.2f) (%.2f, %.2f) (%p) renderer->(%p)\n", boxName(), x(), y(), width(), height(), this, &renderer());118 WTFLogAlways("%s (%.2f, %.2f) (%.2f, %.2f) (%p) renderer->(%p)\n", boxName(), x(), y(), width(), height(), this, &renderer()); 119 119 } 120 120 -
trunk/Source/WebCore/rendering/InlineTextBox.cpp
r216212 r218373 1126 1126 void InlineTextBox::showLineBox(bool mark, int depth) const 1127 1127 { 1128 fprintf(stderr,"-------- %c-", isDirty() ? 'D' : '-');1128 WTFLogAlways("-------- %c-", isDirty() ? 'D' : '-'); 1129 1129 1130 1130 int printedCharacters = 0; 1131 1131 if (mark) { 1132 fprintf(stderr,"*");1132 WTFLogAlways("*"); 1133 1133 ++printedCharacters; 1134 1134 } … … 1140 1140 value.replaceWithLiteral('\\', "\\\\"); 1141 1141 value.replaceWithLiteral('\n', "\\n"); 1142 fprintf(stderr,"%s (%.2f, %.2f) (%.2f, %.2f) (%p) renderer->(%p) run(%d, %d) \"%s\"\n", boxName(), x(), y(), width(), height(), this, &renderer(), start(), start() + len(), value.utf8().data());1142 WTFLogAlways("%s (%.2f, %.2f) (%.2f, %.2f) (%p) renderer->(%p) run(%d, %d) \"%s\"\n", boxName(), x(), y(), width(), height(), this, &renderer(), start(), start() + len(), value.utf8().data()); 1143 1143 } 1144 1144 -
trunk/Source/WebCore/rendering/RenderCounter.cpp
r214173 r218373 611 611 if (!is<WebCore::RenderElement>(*current)) 612 612 continue; 613 fprintf(stderr,"%c", (current == renderer) ? '*' : ' ');613 WTFLogAlways("%c", (current == renderer) ? '*' : ' '); 614 614 for (const WebCore::RenderObject* parent = current; parent && parent != root; parent = parent->parent()) 615 fprintf(stderr," ");616 fprintf(stderr,"%p N:%p P:%p PS:%p NS:%p C:%p\n",615 WTFLogAlways(" "); 616 WTFLogAlways("%p N:%p P:%p PS:%p NS:%p C:%p\n", 617 617 current, current->node(), current->parent(), current->previousSibling(), 618 618 current->nextSibling(), downcast<WebCore::RenderElement>(*current).hasCounterNodeMap() ? -
trunk/Source/WebCore/rendering/RenderLayer.cpp
r218300 r218373 7230 7230 7231 7231 WTF::String output = externalRepresentation(&layer->renderer().frame(), WebCore::RenderAsTextShowAllLayers | WebCore::RenderAsTextShowLayerNesting | WebCore::RenderAsTextShowCompositedLayers | WebCore::RenderAsTextShowAddresses | WebCore::RenderAsTextShowIDAndClass | WebCore::RenderAsTextDontUpdateLayout | WebCore::RenderAsTextShowLayoutState | WebCore::RenderAsTextShowOverflow | WebCore::RenderAsTextShowSVGGeometry | WebCore::RenderAsTextShowLayerFragments); 7232 fprintf(stderr,"\n%s\n", output.utf8().data());7232 WTFLogAlways("\n%s\n", output.utf8().data()); 7233 7233 } 7234 7234 -
trunk/Source/WebCore/rendering/RenderObject.cpp
r216902 r218373 1010 1010 static void showRenderTreeLegend() 1011 1011 { 1012 fprintf(stderr,"\n(B)lock/(I)nline/I(N)line-block, (A)bsolute/Fi(X)ed/(R)elative/Stic(K)y, (F)loating, (O)verflow clip, Anon(Y)mous, (G)enerated, has(L)ayer, (C)omposited, (+)Dirty style, (+)Dirty layout\n");1012 WTFLogAlways("\n(B)lock/(I)nline/I(N)line-block, (A)bsolute/Fi(X)ed/(R)elative/Stic(K)y, (F)loating, (O)verflow clip, Anon(Y)mous, (G)enerated, has(L)ayer, (C)omposited, (+)Dirty style, (+)Dirty layout\n"); 1013 1013 } 1014 1014 … … 1073 1073 RenderRegion* endRegion = nullptr; 1074 1074 ftcb->getRegionRangeForBox(downcast<RenderBox>(this), startRegion, endRegion); 1075 fprintf(stderr," [Rs:%p Re:%p]", startRegion, endRegion);1075 WTFLogAlways(" [Rs:%p Re:%p]", startRegion, endRegion); 1076 1076 } 1077 1077 … … 1143 1143 int printedCharacters = 0; 1144 1144 if (mark) { 1145 fprintf(stderr,"*");1145 WTFLogAlways("*"); 1146 1146 ++printedCharacters; 1147 1147 } … … 1151 1151 1152 1152 if (node()) 1153 fprintf(stderr,"%s ", node()->nodeName().utf8().data());1153 WTFLogAlways("%s ", node()->nodeName().utf8().data()); 1154 1154 1155 1155 String name = renderName(); … … 1157 1157 int pos = name.find('('); 1158 1158 if (pos > 0) 1159 fprintf(stderr,"%s", name.left(pos - 1).utf8().data());1159 WTFLogAlways("%s", name.left(pos - 1).utf8().data()); 1160 1160 else 1161 fprintf(stderr,"%s", name.utf8().data());1161 WTFLogAlways("%s", name.utf8().data()); 1162 1162 1163 1163 if (is<RenderBox>(*this)) { … … 1166 1166 if (renderBox.isInFlowPositioned()) 1167 1167 boxRect.move(renderBox.offsetForInFlowPosition()); 1168 fprintf(stderr," (%.2f, %.2f) (%.2f, %.2f)", boxRect.x(), boxRect.y(), boxRect.width(), boxRect.height());1168 WTFLogAlways(" (%.2f, %.2f) (%.2f, %.2f)", boxRect.x(), boxRect.y(), boxRect.width(), boxRect.height()); 1169 1169 } else if (is<RenderInline>(*this) && isInFlowPositioned()) { 1170 1170 FloatSize inlineOffset = downcast<RenderInline>(*this).offsetForInFlowPosition(); 1171 fprintf(stderr," (%.2f, %.2f)", inlineOffset.width(), inlineOffset.height());1172 } 1173 1174 fprintf(stderr," renderer->(%p)", this);1171 WTFLogAlways(" (%.2f, %.2f)", inlineOffset.width(), inlineOffset.height()); 1172 } 1173 1174 WTFLogAlways(" renderer->(%p)", this); 1175 1175 if (node()) { 1176 fprintf(stderr," node->(%p)", node());1176 WTFLogAlways(" node->(%p)", node()); 1177 1177 if (node()->isTextNode()) { 1178 1178 String value = node()->nodeValue(); 1179 fprintf(stderr," length->(%u)", value.length());1179 WTFLogAlways(" length->(%u)", value.length()); 1180 1180 1181 1181 value.replaceWithLiteral('\\', "\\\\"); … … 1185 1185 if (value.length() > maxPrintedLength) { 1186 1186 String substring = value.substring(0, maxPrintedLength); 1187 fprintf(stderr," \"%s\"...", substring.utf8().data());1187 WTFLogAlways(" \"%s\"...", substring.utf8().data()); 1188 1188 } else 1189 fprintf(stderr," \"%s\"", value.utf8().data());1189 WTFLogAlways(" \"%s\"", value.utf8().data()); 1190 1190 } 1191 1191 } … … 1193 1193 auto& renderer = downcast<RenderBoxModelObject>(*this); 1194 1194 if (renderer.hasContinuation()) 1195 fprintf(stderr," continuation->(%p)", renderer.continuation());1195 WTFLogAlways(" continuation->(%p)", renderer.continuation()); 1196 1196 } 1197 1197 showRegionsInformation(); 1198 1198 if (needsLayout()) { 1199 fprintf(stderr," layout->");1199 WTFLogAlways(" layout->"); 1200 1200 if (selfNeedsLayout()) 1201 fprintf(stderr,"[self]");1201 WTFLogAlways("[self]"); 1202 1202 if (normalChildNeedsLayout()) 1203 fprintf(stderr,"[normal child]");1203 WTFLogAlways("[normal child]"); 1204 1204 if (posChildNeedsLayout()) 1205 fprintf(stderr,"[positioned child]");1205 WTFLogAlways("[positioned child]"); 1206 1206 if (needsSimplifiedNormalFlowLayout()) 1207 fprintf(stderr,"[simplified]");1207 WTFLogAlways("[simplified]"); 1208 1208 if (needsPositionedMovementLayout()) 1209 fprintf(stderr,"[positioned movement]");1210 } 1211 fprintf(stderr,"\n");1209 WTFLogAlways("[positioned movement]"); 1210 } 1211 WTFLogAlways("\n"); 1212 1212 } 1213 1213 … … 2018 2018 continue; 2019 2019 if (document->frame() && document->frame()->isMainFrame()) 2020 fprintf(stderr,"----------------------main frame--------------------------\n");2021 fprintf(stderr,"%s", document->url().string().utf8().data());2020 WTFLogAlways("----------------------main frame--------------------------\n"); 2021 WTFLogAlways("%s", document->url().string().utf8().data()); 2022 2022 showRenderTree(document->renderView()); 2023 2023 } … … 2030 2030 continue; 2031 2031 if (document->frame() && document->frame()->isMainFrame()) 2032 fprintf(stderr,"----------------------main frame--------------------------\n");2033 fprintf(stderr,"%s", document->url().string().utf8().data());2032 WTFLogAlways("----------------------main frame--------------------------\n"); 2033 WTFLogAlways("%s", document->url().string().utf8().data()); 2034 2034 showLayerTree(document->renderView()); 2035 2035 } -
trunk/Source/WebCore/rendering/SimpleLineLayoutFunctions.cpp
r217019 r218373 264 264 static void printPrefix(int& printedCharacters, int depth) 265 265 { 266 fprintf(stderr,"-------- --");266 WTFLogAlways("-------- --"); 267 267 printedCharacters = 0; 268 268 while (++printedCharacters <= depth * 2) … … 275 275 printPrefix(printedCharacters, depth); 276 276 277 fprintf(stderr,"SimpleLineLayout (%u lines, %u runs) (%p)\n", layout.lineCount(), layout.runCount(), &layout);277 WTFLogAlways("SimpleLineLayout (%u lines, %u runs) (%p)\n", layout.lineCount(), layout.runCount(), &layout); 278 278 ++depth; 279 279 … … 282 282 printPrefix(printedCharacters, depth); 283 283 if (run.start() < run.end()) { 284 fprintf(stderr,"line %u run(%u, %u) (%.2f, %.2f) (%.2f, %.2f) \"%s\"\n", run.lineIndex(), run.start(), run.end(),284 WTFLogAlways("line %u run(%u, %u) (%.2f, %.2f) (%.2f, %.2f) \"%s\"\n", run.lineIndex(), run.start(), run.end(), 285 285 rect.x(), rect.y(), rect.width(), rect.height(), run.text().toStringWithoutCopying().utf8().data()); 286 286 } else { 287 287 ASSERT(run.start() == run.end()); 288 fprintf(stderr,"line break %u run(%u, %u) (%.2f, %.2f) (%.2f, %.2f)\n", run.lineIndex(), run.start(), run.end(), rect.x(), rect.y(), rect.width(), rect.height());288 WTFLogAlways("line break %u run(%u, %u) (%.2f, %.2f) (%.2f, %.2f)\n", run.lineIndex(), run.start(), run.end(), rect.x(), rect.y(), rect.width(), rect.height()); 289 289 } 290 290 } -
trunk/Source/WebCore/rendering/svg/SVGResources.cpp
r209777 r218373 657 657 ASSERT(object->node()); 658 658 659 fprintf(stderr,"-> this=%p, SVGResources(renderer=%p, node=%p)\n", this, object, object->node());660 fprintf(stderr," | DOM Tree:\n");659 WTFLogAlways("-> this=%p, SVGResources(renderer=%p, node=%p)\n", this, object, object->node()); 660 WTFLogAlways(" | DOM Tree:\n"); 661 661 object->node()->showTreeForThis(); 662 662 663 fprintf(stderr,"\n | List of resources:\n");663 WTFLogAlways("\n | List of resources:\n"); 664 664 if (m_clipperFilterMaskerData) { 665 665 if (RenderSVGResourceClipper* clipper = m_clipperFilterMaskerData->clipper) 666 fprintf(stderr," |-> Clipper : %p (node=%p)\n", clipper, &clipper->clipPathElement());666 WTFLogAlways(" |-> Clipper : %p (node=%p)\n", clipper, &clipper->clipPathElement()); 667 667 if (RenderSVGResourceFilter* filter = m_clipperFilterMaskerData->filter) 668 fprintf(stderr," |-> Filter : %p (node=%p)\n", filter, &filter->filterElement());668 WTFLogAlways(" |-> Filter : %p (node=%p)\n", filter, &filter->filterElement()); 669 669 if (RenderSVGResourceMasker* masker = m_clipperFilterMaskerData->masker) 670 fprintf(stderr," |-> Masker : %p (node=%p)\n", masker, &masker->maskElement());670 WTFLogAlways(" |-> Masker : %p (node=%p)\n", masker, &masker->maskElement()); 671 671 } 672 672 673 673 if (m_markerData) { 674 674 if (RenderSVGResourceMarker* markerStart = m_markerData->markerStart) 675 fprintf(stderr," |-> MarkerStart: %p (node=%p)\n", markerStart, &markerStart->markerElement());675 WTFLogAlways(" |-> MarkerStart: %p (node=%p)\n", markerStart, &markerStart->markerElement()); 676 676 if (RenderSVGResourceMarker* markerMid = m_markerData->markerMid) 677 fprintf(stderr," |-> MarkerMid : %p (node=%p)\n", markerMid, &markerMid->markerElement());677 WTFLogAlways(" |-> MarkerMid : %p (node=%p)\n", markerMid, &markerMid->markerElement()); 678 678 if (RenderSVGResourceMarker* markerEnd = m_markerData->markerEnd) 679 fprintf(stderr," |-> MarkerEnd : %p (node=%p)\n", markerEnd, &markerEnd->markerElement());679 WTFLogAlways(" |-> MarkerEnd : %p (node=%p)\n", markerEnd, &markerEnd->markerElement()); 680 680 } 681 681 682 682 if (m_fillStrokeData) { 683 683 if (RenderSVGResourceContainer* fill = m_fillStrokeData->fill) 684 fprintf(stderr," |-> Fill : %p (node=%p)\n", fill, &fill->element());684 WTFLogAlways(" |-> Fill : %p (node=%p)\n", fill, &fill->element()); 685 685 if (RenderSVGResourceContainer* stroke = m_fillStrokeData->stroke) 686 fprintf(stderr," |-> Stroke : %p (node=%p)\n", stroke, &stroke->element());686 WTFLogAlways(" |-> Stroke : %p (node=%p)\n", stroke, &stroke->element()); 687 687 } 688 688 689 689 if (m_linkedResource) 690 fprintf(stderr," |-> xlink:href : %p (node=%p)\n", m_linkedResource, &m_linkedResource->element());690 WTFLogAlways(" |-> xlink:href : %p (node=%p)\n", m_linkedResource, &m_linkedResource->element()); 691 691 } 692 692 #endif -
trunk/Source/WebCore/rendering/svg/SVGResourcesCycleSolver.cpp
r189954 r218373 143 143 LOG_DEBUG_CYCLE("|> %s : %p (node %p)\n", resource->renderName(), resource, resource->node()); 144 144 145 fprintf(stderr,"Parent resources:\n");145 WTFLogAlways("Parent resources:\n"); 146 146 for (RenderObject* resource : ancestorResources) 147 147 LOG_DEBUG_CYCLE("|> %s : %p (node %p)\n", resource->renderName(), resource, resource->node()); -
trunk/Source/WebCore/rendering/svg/SVGTextLayoutAttributes.cpp
r163440 r218373 46 46 { 47 47 if (value == SVGTextLayoutAttributes::emptyValue()) { 48 fprintf(stderr,"%s=x", identifier);48 WTFLogAlways("%s=x", identifier); 49 49 if (appendSpace) 50 fprintf(stderr," ");50 WTFLogAlways(" "); 51 51 return; 52 52 } 53 fprintf(stderr,"%s=%lf", identifier, value);53 WTFLogAlways("%s=%lf", identifier, value); 54 54 if (appendSpace) 55 fprintf(stderr," ");55 WTFLogAlways(" "); 56 56 } 57 57 58 58 void SVGTextLayoutAttributes::dump() const 59 59 { 60 fprintf(stderr,"context: %p\n", &m_context);60 WTFLogAlways("context: %p\n", &m_context); 61 61 const SVGCharacterDataMap::const_iterator end = m_characterDataMap.end(); 62 62 for (SVGCharacterDataMap::const_iterator it = m_characterDataMap.begin(); it != end; ++it) { 63 63 const SVGCharacterData& data = it->value; 64 fprintf(stderr," ---> pos=%i, data={", it->key);64 WTFLogAlways(" ---> pos=%i, data={", it->key); 65 65 dumpSVGCharacterDataMapValue("x", data.x); 66 66 dumpSVGCharacterDataMapValue("y", data.y); … … 68 68 dumpSVGCharacterDataMapValue("dy", data.dy); 69 69 dumpSVGCharacterDataMapValue("rotate", data.rotate, false); 70 fprintf(stderr,"}\n");70 WTFLogAlways("}\n"); 71 71 } 72 72 } -
trunk/Source/WebCore/rendering/svg/SVGTextLayoutEngine.cpp
r207757 r218373 236 236 { 237 237 unsigned boxCount = boxes.size(); 238 fprintf(stderr,"Dumping all text fragments in text sub tree, %i boxes\n", boxCount);238 WTFLogAlways("Dumping all text fragments in text sub tree, %i boxes\n", boxCount); 239 239 240 240 for (unsigned boxPosition = 0; boxPosition < boxCount; ++boxPosition) { 241 241 SVGInlineTextBox* textBox = boxes.at(boxPosition); 242 242 Vector<SVGTextFragment>& fragments = textBox->textFragments(); 243 fprintf(stderr,"-> Box %i: Dumping text fragments for SVGInlineTextBox, textBox=%p, textRenderer=%p\n", boxPosition, textBox, textBox->renderer());244 fprintf(stderr," textBox properties, start=%i, len=%i, box direction=%i\n", textBox->start(), textBox->len(), textBox->direction());245 fprintf(stderr," textRenderer properties, textLength=%i\n", textBox->renderer()->textLength());243 WTFLogAlways("-> Box %i: Dumping text fragments for SVGInlineTextBox, textBox=%p, textRenderer=%p\n", boxPosition, textBox, textBox->renderer()); 244 WTFLogAlways(" textBox properties, start=%i, len=%i, box direction=%i\n", textBox->start(), textBox->len(), textBox->direction()); 245 WTFLogAlways(" textRenderer properties, textLength=%i\n", textBox->renderer()->textLength()); 246 246 247 247 const UChar* characters = textBox->renderer()->characters(); … … 251 251 SVGTextFragment& fragment = fragments.at(i); 252 252 String fragmentString(characters + fragment.characterOffset, fragment.length); 253 fprintf(stderr," -> Fragment %i, x=%lf, y=%lf, width=%lf, height=%lf, characterOffset=%i, length=%i, characters='%s'\n"253 WTFLogAlways(" -> Fragment %i, x=%lf, y=%lf, width=%lf, height=%lf, characterOffset=%i, length=%i, characters='%s'\n" 254 254 , i, fragment.x, fragment.y, fragment.width, fragment.height, fragment.characterOffset, fragment.length, fragmentString.utf8().data()); 255 255 } … … 291 291 if (!m_lineLayoutBoxes.isEmpty()) { 292 292 #if DUMP_TEXT_FRAGMENTS > 0 293 fprintf(stderr,"Line layout: ");293 WTFLogAlways("Line layout: "); 294 294 dumpTextBoxes(m_lineLayoutBoxes); 295 295 #endif … … 300 300 if (!m_pathLayoutBoxes.isEmpty()) { 301 301 #if DUMP_TEXT_FRAGMENTS > 0 302 fprintf(stderr,"Path layout: ");302 WTFLogAlways("Path layout: "); 303 303 dumpTextBoxes(m_pathLayoutBoxes); 304 304 #endif
Note:
See TracChangeset
for help on using the changeset viewer.