2006-05-13 Mitz Pettel <opendarwin.org@mitzpettel.com>
[WebKit-https.git] / WebCore / ChangeLog
1 2006-05-13  Mitz Pettel  <opendarwin.org@mitzpettel.com>
2
3         Reviewed by Darin, landed by ap.
4
5         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=8485
6           iExploder(#11705): Freeze in RenderBlock::layout()
7
8         Test: fast/text/midword-break-hang.html
9
10         * rendering/bidi.cpp:
11         (WebCore::RenderBlock::findNextLineBreak): If this is a mid-word break,
12         ignore breakOnlyAfterWhiteSpace.
13
14 2006-05-13  Alexey Proskuryakov  <ap@nypop.com>
15
16         Fix release build.
17
18         * rendering/RenderBox.cpp:
19         (WebCore::RenderBox::calcAbsoluteHorizontalValues): Initialize leftValue. 
20         This value will never be used, because 'left' and 'right' cannot both be 'auto'.
21         (WebCore::RenderBox::calcAbsoluteVerticalValues): Initialize topValue. 
22         (WebCore::RenderBox::calcAbsoluteVerticalReplaced): Same changes as above. 
23
24 2006-05-13  Alexey Proskuryakov  <ap@nypop.com>
25
26         Re-applied the fix for bug 8835 (REGRESSION: Line moves but selection
27         highlight stays behind) to a correct file; removed the stale one.
28
29         * rendering/RootInlineBox.cpp:
30         (WebCore::RootInlineBox::adjustPosition): Adjust m_selectionTop
31         and m_selectionBottom.
32         * rendering/render_line.cpp: Removed.
33
34 2006-05-13  Rob Buis  <buis@kde.org>
35
36         Reviewed by Darin, landed by ap.
37
38         Fix for http://bugzilla.opendarwin.org/show_bug.cgi?id=8132
39         CSS parser sometimes accepts real number as integer
40
41         Add a boolean variable per css value to catch whether values
42         are specified as floats or integers.
43
44         Test: fast/css/rgb-float.html
45
46         * css/CSSGrammar.y:
47         * css/cssparser.cpp:
48         (WebCore::CSSParser::validUnit):
49         (WebCore::CSSParser::lex):
50         * css/cssparser.h:
51         * css/tokenizer.flex:
52
53 2006-05-13  Sam Weinig  <sam.weinig@gmail.com>
54
55         Reviewed by Hyatt, landed by ap.
56
57         Patch for http://bugzilla.opendarwin.org/show_bug.cgi?id=7604
58         calcAbsoluteHorizontalValues() is being getting passed arguments
59         in the wrong order in calcAbsoluteHorizontal()
60
61         Cleans up the RenderBox code for absolutely positioned elements
62         and adds new functions for replaced absolutely positioned 
63         elements. Now uses Length so that magic number -666666 for 
64         auto lengths is no longer used.
65
66         * rendering/RenderBox.cpp:
67         (WebCore::RenderBox::calcAbsoluteHorizontal):
68         (WebCore::RenderBox::calcAbsoluteHorizontalValues):
69         (WebCore::RenderBox::calcAbsoluteVertical):
70         (WebCore::RenderBox::calcAbsoluteVerticalValues): 
71         (WebCore::RenderBox::calcAbsoluteHorizontalReplaced): Handle replaced
72         case separately.
73         (WebCore::RenderBox::calcAbsoluteVerticalReplaced): ditto.
74         * rendering/RenderBox.h:
75
76 2006-05-12  David Hyatt  <hyatt@apple.com>
77
78         Bug 8880, remove the remaining drawing/hit testing code from
79         FontData.
80
81         Reviewed by tim h
82
83         * platform/Font.cpp:
84         (WebCore::m_finalRoundingWidth):
85         (WebCore::WidthIterator::advanceOneCharacter):
86         (WebCore::Font::selectionRectForText):
87         (WebCore::Font::selectionRectForSimpleText):
88         (WebCore::Font::offsetForPosition):
89         (WebCore::Font::offsetForPositionForSimpleText):
90         * platform/Font.h:
91         (WebCore::TextRun::makeComplete):
92         * platform/FontData.h:
93         * platform/GlyphBuffer.h:
94         (WebCore::GlyphBuffer::clear):
95         * platform/mac/FontData.mm:
96         * platform/mac/FontMac.mm:
97         (WebCore::Font::selectionRectForComplexText):
98         (WebCore::Font::offsetForPositionForComplexText):
99
100 2006-05-12  Kevin M. Ollivier  <kevino@theolliviers.com>
101
102         Reviewed by Maciej.
103
104         Add missing include.
105         
106         * dom/Node.h: Add missing include for DeprecatedString.
107
108 2006-05-12  Mitz Pettel  <opendarwin.org@mitzpettel.com>
109
110         Reviewed by Darin.
111
112         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=8835
113           REGRESSION: Line moves but selection highlight stays behind
114
115         Test: fast/dynamic/selection-highlight-adjust.html
116
117         * rendering/render_line.cpp:
118         (WebCore::RootInlineBox::adjustPosition): Adjust m_selectionTop
119         and m_selectionBottom.
120
121 2006-05-12  Timothy Hatcher  <timothy@apple.com>
122
123         Reviewed by Darin.
124
125         http://bugzilla.opendarwin.org/show_bug.cgi?id=7156
126         Bug 7156: TinyMCE: Links are actually activated in editable area, not editable.
127         
128         Links in editable areas will not activate or perform a navigation
129         change (on par with WinIE and Firefox.) To visit the link
130         you can shift-click. Manual test added.
131
132         * css/cssstyleselector.cpp:
133         (WebCore::CSSStyleSelector::adjustRenderStyle):
134         * html/HTMLAnchorElement.cpp:
135         (WebCore::HTMLAnchorElement::defaultEventHandler):
136         (WebCore::HTMLAnchorElement::setActive):
137         * html/HTMLAnchorElement.h:
138         * manual-tests/contenteditable-link.html: Added.
139         * page/FrameView.cpp:
140         (WebCore::selectCursor):
141
142 2006-05-12  Eric Seidel  <eseidel@apple.com>
143
144         Reviewed by timo.
145
146         Split out html_inlineimpl.* into separate files (one per class).
147
148         * WebCore.xcodeproj/project.pbxproj:
149         * bindings/js/kjs_html.cpp:
150         * bindings/objc/DOMHTML.mm:
151         * editing/CreateLinkCommand.cpp:
152         * editing/UnlinkCommand.cpp:
153         * html/HTMLAnchorElement.cpp: Added.
154         (WebCore::HTMLAnchorElement::HTMLAnchorElement):
155         * html/HTMLAnchorElement.h: Added.
156         * html/HTMLBRElement.cpp: Added.
157         * html/HTMLBRElement.h: Added.
158         * html/HTMLElementFactory.cpp:
159         * html/HTMLFontElement.cpp: Added.
160         (WebCore::HTMLFontElement::HTMLFontElement):
161         (WebCore::HTMLFontElement::setColor):
162         (WebCore::HTMLFontElement::setFace):
163         (WebCore::HTMLFontElement::setSize):
164         * html/HTMLFontElement.h: Added.
165         * html/HTMLModElement.cpp: Added.
166         (WebCore::HTMLModElement::setCite):
167         (WebCore::HTMLModElement::setDateTime):
168         * html/HTMLModElement.h: Added.
169         * html/HTMLQuoteElement.cpp: Added.
170         * html/HTMLQuoteElement.h: Added.
171         * html/html_imageimpl.h:
172         * html/html_inlineimpl.cpp: Removed.
173         * html/html_inlineimpl.h: Removed.
174         * page/FrameView.cpp:
175
176 2006-05-12  Eric Seidel  <eseidel@apple.com>
177
178         Reviewed by beth.
179
180         Fix build error.
181
182         * rendering/InlineFlowBox.cpp:
183         * rendering/RootInlineBox.cpp:
184
185 2006-05-12  Eric Seidel  <eseidel@apple.com>
186
187         Reviewed by beth.
188
189         Split out render_line.* into separate files (one per class).
190
191         * WebCore.xcodeproj/project.pbxproj:
192         * dom/ContainerNode.cpp:
193         * rendering/EllipsisBox.cpp: Added.
194         * rendering/EllipsisBox.h: Added.
195         (WebCore::EllipsisBox::EllipsisBox):
196         * rendering/InlineBox.cpp: Added.
197         * rendering/InlineBox.h: Added.
198         (WebCore::InlineBox::InlineBox):
199         (WebCore::InlineBox::~InlineBox):
200         (WebCore::InlineBox::bottomOverflow):
201         (WebCore::InlineBox::rightOverflow):
202         * rendering/InlineFlowBox.cpp: Added.
203         (WebCore::InlineFlowBox::placeBoxesHorizontally):
204         * rendering/InlineFlowBox.h: Added.
205         * rendering/InlineRunBox.h: Added.
206         (WebCore::InlineRunBox::InlineRunBox):
207         (WebCore::InlineRunBox::paintBackgroundAndBorder):
208         (WebCore::InlineRunBox::paintDecorations):
209         * rendering/InlineTextBox.h:
210         * rendering/RenderBlock.h:
211         * rendering/RenderFlow.h:
212         * rendering/RenderReplaced.cpp:
213         * rendering/RootInlineBox.cpp: Added.
214         * rendering/RootInlineBox.h: Added.
215         (WebCore::RootInlineBox::RootInlineBox):
216         * rendering/render_line.h: Removed.
217
218 2006-05-12  Eric Seidel  <eseidel@apple.com>
219
220         Reviewed by hyatt.
221
222         Split out table_layout.* into separate files (one per class).
223         Search replace instance variables "foo" with "m_foo" to comply with modern style.
224
225         * WebCore.xcodeproj/project.pbxproj:
226         * rendering/AutoTableLayout.cpp: Added.
227         (WebCore::AutoTableLayout::AutoTableLayout):
228         (WebCore::AutoTableLayout::recalcColumn):
229         (WebCore::AutoTableLayout::fullRecalc):
230         (WebCore::AutoTableLayout::calcMinMaxWidth):
231         (WebCore::AutoTableLayout::calcEffectiveWidth):
232         (WebCore::AutoTableLayout::insertSpanCell):
233         (WebCore::AutoTableLayout::layout):
234         (WebCore::AutoTableLayout::calcPercentages):
235         * rendering/AutoTableLayout.h: Added.
236         (WebCore::AutoTableLayout::totalPercent):
237         (WebCore::AutoTableLayout::Layout::Layout):
238         * rendering/FixedTableLayout.cpp: Added.
239         (WebCore::FixedTableLayout::FixedTableLayout):
240         (WebCore::FixedTableLayout::calcWidthArray):
241         (WebCore::FixedTableLayout::calcMinMaxWidth):
242         (WebCore::FixedTableLayout::layout):
243         * rendering/FixedTableLayout.h: Added.
244         * rendering/RenderTable.cpp:
245         * rendering/TableLayout.h: Added.
246         (WebCore::TableLayout::TableLayout):
247         * rendering/table_layout.cpp: Removed.
248         * rendering/table_layout.h: Removed.
249
250 2006-05-12  David Hyatt  <hyatt@apple.com>
251
252         Bug 8877.  Change form controls and the bridge entry points from the
253         Safari UI to use Font instead of FontData.
254
255         Reviewed by mjs
256
257         * bridge/mac/WebCoreStringTruncator.mm:
258         (stringWidth):
259         (truncateString):
260         (+[WebCoreStringTruncator widthOfString:font:]):
261         (+[WebCoreStringTruncator clear]):
262         * kwq/KWQComboBox.mm:
263         (QComboBox::sizeHint):
264         * kwq/KWQLineEdit.mm:
265         (QLineEdit::sizeForCharacterWidth):
266         * kwq/KWQListBox.mm:
267         (itemTextRenderer):
268         (groupLabelTextRenderer):
269         (QListBox::sizeForNumberOfLines):
270         (QListBox::clearCachedTextRenderers):
271         (-[KWQTableView drawRow:clipRect:]):
272         * platform/Font.cpp:
273         (WebCore::Font::drawSimpleText):
274         (WebCore::Font::drawText):
275         * platform/Font.h:
276         (WebCore::TextStyle::disableRoundingHacks):
277         (WebCore::TextStyle::setRTL):
278         * platform/FontData.h:
279         * platform/FontFallbackList.h:
280         * platform/FontPlatformData.h:
281         (WebCore::FontPlatformData::syntheticOblique):
282         * platform/Pen.h:
283         * platform/mac/FontData.mm:
284         (WebCore::FontData::smallCapsFontData):
285         (WebCore::findSubstituteRenderer):
286         * platform/mac/FontMac.mm:
287         (WebCore::FontFallbackList::setPlatformFont):
288         (WebCore::m_wordSpacing):
289         (WebCore::Font::drawComplexText):
290         * platform/mac/WebCoreTextRenderer.mm:
291         (WebCoreDrawTextAtPoint):
292         (WebCoreTextFloatWidth):
293         * platform/win/FontWin.cpp:
294         (WebCore::Font::drawText):
295         * rendering/InlineTextBox.cpp:
296         (WebCore::InlineTextBox::positionForOffset):
297
298 2006-05-12  Eric Seidel  <eseidel@apple.com>
299
300         Reviewed by kevin.
301
302         Move render_button to RenderButton.
303         Various small style cleanup.
304
305         * WebCore.xcodeproj/project.pbxproj:
306         * html/HTMLButtonElement.cpp:
307         * html/HTMLElement.cpp:
308         * html/HTMLGenericFormElement.cpp:
309         * html/HTMLInputElement.cpp:
310         * platform/mac/WebCoreTextArea.mm:
311         * rendering/RenderApplet.h:
312         * rendering/RenderBox.cpp:
313         * rendering/RenderButton.cpp: Added.
314         (WebCore::RenderButton::RenderButton):
315         (WebCore::RenderButton::addChild):
316         (WebCore::RenderButton::removeChild):
317         * rendering/RenderButton.h: Added.
318         * rendering/RenderEmptyApplet.h:
319         * rendering/RenderHTMLCanvas.h:
320         * rendering/RenderTreeAsText.cpp:
321         * rendering/render_button.cpp: Removed.
322         * rendering/render_button.h: Removed.
323         * rendering/table_layout.cpp:
324         (WebCore::FixedTableLayout::FixedTableLayout):
325         (WebCore::FixedTableLayout::calcWidthArray):
326         (WebCore::FixedTableLayout::calcMinMaxWidth):
327         (WebCore::FixedTableLayout::layout):
328         (WebCore::AutoTableLayout::AutoTableLayout):
329         (WebCore::AutoTableLayout::recalcColumn):
330         (WebCore::AutoTableLayout::fullRecalc):
331         (WebCore::AutoTableLayout::calcMinMaxWidth):
332         (WebCore::AutoTableLayout::calcEffectiveWidth):
333         (WebCore::AutoTableLayout::insertSpanCell):
334         (WebCore::AutoTableLayout::layout):
335         * rendering/table_layout.h:
336         (WebCore::TableLayout::TableLayout):
337         (WebCore::AutoTableLayout::totalPercent):
338         (WebCore::AutoTableLayout::Layout::Layout):
339
340 2006-05-12  Eric Seidel  <eseidel@apple.com>
341
342         Reviewed by mjs.
343
344         Split render_frames.* render_replaced.* and html_baseimpl.* into separate files (one class per file).
345         http://bugzilla.opendarwin.org/show_bug.cgi?id=8878
346
347         * WebCore.xcodeproj/project.pbxproj:
348         * bindings/js/kjs_html.cpp:
349         (KJS::JSHTMLDocumentProtoFunc::callAsFunction):
350         (KJS::JSHTMLDocument::namedItemGetter):
351         (KJS::JSHTMLDocument::getValueProperty):
352         (KJS::JSHTMLDocument::getOwnPropertySlot):
353         (KJS::JSHTMLDocument::putValueProperty):
354         (KJS::JSHTMLElement::formIndexGetter):
355         (KJS::JSHTMLElement::formNameGetter):
356         (KJS::JSHTMLElement::selectIndexGetter):
357         (KJS::JSHTMLElement::framesetNameGetter):
358         (KJS::JSHTMLElement::runtimeObjectGetter):
359         (KJS::JSHTMLElement::runtimeObjectPropertyGetter):
360         (KJS::JSHTMLElement::getOwnPropertySlot):
361         (KJS::JSHTMLElement::implementsCall):
362         (KJS::JSHTMLElement::callAsFunction):
363         (KJS::JSHTMLElement::getValueProperty):
364         (KJS::JSHTMLElement::toString):
365         (KJS::getForm):
366         (KJS::JSHTMLElement::pushEventHandlerScope):
367         (KJS::HTMLElementFunction::callAsFunction):
368         (KJS::JSHTMLElement::put):
369         (KJS::JSHTMLElement::selectSetter):
370         (KJS::JSHTMLElement::putValueProperty):
371         (KJS::toHTMLElement):
372         (KJS::toHTMLTableCaptionElement):
373         (KJS::toHTMLTableSectionElement):
374         (KJS::JSHTMLCollection::lengthGetter):
375         (KJS::JSHTMLCollection::indexGetter):
376         (KJS::JSHTMLCollection::nameGetter):
377         (KJS::JSHTMLCollection::getOwnPropertySlot):
378         (KJS::HTMLCollectionProtoFunc::callAsFunction):
379         (KJS::JSHTMLSelectCollection::selectedIndexGetter):
380         (KJS::JSHTMLSelectCollection::put):
381         (KJS::OptionConstructorImp::construct):
382         (KJS::getSelectHTMLCollection):
383         * bindings/objc/DOMHTML.mm:
384         * bridge/mac/FrameMac.mm:
385         (WebCore::FrameMac::createFrame):
386         * bridge/mac/WebCoreFrameBridge.mm:
387         (-[WebCoreFrameBridge copyRenderNode:copier:]):
388         * dom/Document.cpp:
389         (WebCore::widgetForNode):
390         * html/HTMLBodyElement.cpp: Added.
391         (WebCore::HTMLBodyElement::HTMLBodyElement):
392         (WebCore::HTMLBodyElement::parseMappedAttribute):
393         * html/HTMLBodyElement.h: Added.
394         * html/HTMLDocument.cpp:
395         * html/HTMLElementFactory.cpp:
396         * html/HTMLEmbedElement.cpp:
397         * html/HTMLFrameElement.cpp: Added.
398         (WebCore::HTMLFrameElement::isURLAllowed):
399         (WebCore::HTMLFrameElement::parseMappedAttribute):
400         (WebCore::HTMLFrameElement::setLocation):
401         * html/HTMLFrameElement.h: Added.
402         * html/HTMLFrameSetElement.cpp: Added.
403         (WebCore::HTMLFrameSetElement::HTMLFrameSetElement):
404         (WebCore::HTMLFrameSetElement::parseMappedAttribute):
405         (WebCore::HTMLFrameSetElement::attach):
406         (WebCore::HTMLFrameSetElement::defaultEventHandler):
407         (WebCore::HTMLFrameSetElement::recalcStyle):
408         * html/HTMLFrameSetElement.h: Added.
409         * html/HTMLHeadElement.cpp: Added.
410         (WebCore::HTMLHeadElement::HTMLHeadElement):
411         * html/HTMLHeadElement.h: Added.
412         * html/HTMLHtmlElement.cpp: Added.
413         (WebCore::HTMLHtmlElement::HTMLHtmlElement):
414         * html/HTMLHtmlElement.h: Added.
415         * html/HTMLIFrameElement.cpp: Added.
416         (WebCore::HTMLIFrameElement::HTMLIFrameElement):
417         * html/HTMLIFrameElement.h: Added.
418         * html/HTMLObjectElement.cpp:
419         * html/HTMLParser.cpp:
420         * html/html_baseimpl.cpp: Removed.
421         * html/html_baseimpl.h: Removed.
422         * kwq/WebCoreAXObject.mm:
423         * page/Frame.cpp:
424         (WebCore::isFrameElement):
425         (WebCore::Frame::applyEditingStyleToBodyElement):
426         (WebCore::Frame::removeEditingStyleFromBodyElement):
427         (WebCore::Frame::applyEditingStyleToElement):
428         (WebCore::Frame::removeEditingStyleFromElement):
429         (WebCore::Frame::selectionRect):
430         (WebCore::Frame::isFrameSet):
431         (WebCore::scanForForm):
432         (WebCore::Frame::currentForm):
433         (WebCore::Frame::nodeInfoAtPoint):
434         (WebCore::Frame::adjustPageHeight):
435         (WebCore::Frame::frameForWidget):
436         (WebCore::Frame::forceLayoutWithPageWidthRange):
437         (WebCore::Frame::passWidgetMouseDownEventToWidget):
438         * page/FrameView.cpp:
439         * rendering/RenderFrame.cpp: Added.
440         (WebCore::RenderFrame::viewCleared):
441         * rendering/RenderFrame.h: Added.
442         * rendering/RenderFrameSet.cpp: Added.
443         (WebCore::RenderFrameSet::RenderFrameSet):
444         (WebCore::RenderFrameSet::~RenderFrameSet):
445         (WebCore::RenderFrameSet::layout):
446         (WebCore::RenderFrameSet::positionFrames):
447         (WebCore::RenderFrameSet::userResize):
448         (WebCore::RenderFrameSet::canResize):
449         (WebCore::RenderFrameSet::dump):
450         * rendering/RenderFrameSet.h: Added.
451         * rendering/RenderImage.h:
452         * rendering/RenderPart.cpp: Added.
453         (WebCore::RenderPart::RenderPart):
454         * rendering/RenderPart.h: Added.
455         * rendering/RenderPartObject.cpp: Added.
456         (WebCore::isURLAllowed):
457         (WebCore::RenderPartObject::updateWidget):
458         (WebCore::RenderPartObject::viewCleared):
459         * rendering/RenderPartObject.h: Added.
460         * rendering/RenderReplaced.cpp: Added.
461         (WebCore::RenderReplaced::selectionColor):
462         * rendering/RenderReplaced.h: Added.
463         * rendering/RenderWidget.cpp: Added.
464         (WebCore::RenderWidget::deleteWidget):
465         * rendering/RenderWidget.h: Added.
466         * rendering/render_form.h:
467         * rendering/render_frames.cpp: Removed.
468         * rendering/render_frames.h: Removed.
469         * rendering/render_replaced.cpp: Removed.
470         * rendering/render_replaced.h: Removed.
471
472 2006-05-12  Eric Seidel  <eseidel@apple.com>
473
474         Reviewed by beth.
475
476         Split html_headimpl.* into separate files (one per class)
477         http://bugzilla.opendarwin.org/show_bug.cgi?id=8875
478
479         * WebCore.xcodeproj/project.pbxproj:
480         * bindings/js/kjs_css.cpp:
481         * bindings/js/kjs_html.cpp:
482         (KJS::JSHTMLElement::headGetter):
483         (KJS::JSHTMLElement::linkGetter):
484         * bindings/objc/DOMCSS.mm:
485         (+[DOMCounter _counterWith:]):
486         (-[DOMCounter finalize]):
487         (-[DOMCounter _DOMStyleSheet]):
488         (-[DOMStyleSheet _initWithStyleSheet:]):
489         (-[DOMStyleSheetList dealloc]):
490         (-[DOMStyleSheetList finalize]):
491         (-[DOMStyleSheetList _styleSheetList]):
492         (-[DOMStyleSheetList _initWithStyleSheetList:]):
493         (-[DOMCSSStyleSheet _CSSStyleSheet]):
494         (-[DOMMediaList dealloc]):
495         (-[DOMMediaList finalize]):
496         (-[DOMMediaList _mediaList]):
497         (-[DOMMediaList _initWithMediaList:]):
498         (-[DOMCSSRuleList dealloc]):
499         (-[DOMCSSRuleList finalize]):
500         (-[DOMCSSRuleList _ruleList]):
501         (-[DOMCSSRuleList _initWithRuleList:]):
502         (-[DOMCSSRule dealloc]):
503         (-[DOMCSSRule finalize]):
504         (-[DOMCSSRule _rule]):
505         (-[DOMCSSRule _initWithRule:]):
506         (-[DOMCSSStyleRule _styleRule]):
507         (-[DOMCSSMediaRule _mediaRule]):
508         (-[DOMCSSFontFaceRule _fontFaceRule]):
509         (-[DOMCSSPageRule _pageRule]):
510         (-[DOMCSSImportRule _importRule]):
511         (-[DOMCSSCharsetRule _importRule]):
512         (-[DOMCSSStyleDeclaration dealloc]):
513         (-[DOMCSSStyleDeclaration finalize]):
514         (-[DOMCSSStyleDeclaration _initWithStyleDeclaration:]):
515         (-[DOMCSSStyleDeclaration _styleDeclaration]):
516         (-[DOMCSSValue dealloc]):
517         (-[DOMCSSValue finalize]):
518         (-[DOMCSSValue _value]):
519         (-[DOMCSSValue _initWithValue:]):
520         (-[DOMCSSPrimitiveValue _primitiveValue]):
521         (-[DOMCSSValueList _valueList]):
522         (getWrapperForRGB):
523         (setWrapperForRGB):
524         (removeWrapperForRGB):
525         (-[DOMRGBColor _initWithRGB:]):
526         (-[DOMRect dealloc]):
527         (-[DOMRect finalize]):
528         (-[DOMRect _rect]):
529         (-[DOMRect _initWithRect:]):
530         (-[DOMCounter dealloc]):
531         (-[DOMCounter _counter]):
532         (-[DOMCounter _initWithCounter:]):
533         (-[DOMObject sheet]):
534         * bindings/objc/DOMHTML.mm:
535         (-[DOMHTMLCollection dealloc]):
536         (-[DOMHTMLCollection finalize]):
537         (-[DOMHTMLCollection _collection]):
538         (-[DOMHTMLCollection _initWithCollection:]):
539         (-[DOMHTMLOptionsCollection dealloc]):
540         (-[DOMHTMLOptionsCollection finalize]):
541         (-[DOMHTMLOptionsCollection _initWithOptionsCollection:]):
542         (-[DOMHTMLOptionsCollection _optionsCollection]):
543         (+[DOMHTMLElement _elementWith:]):
544         (-[DOMHTMLElement _HTMLElement]):
545         (-[DOMHTMLDocument _HTMLDocument]):
546         (-[DOMHTMLHtmlElement _HTMLHtmlElement]):
547         (-[DOMHTMLHeadElement _headElement]):
548         (-[DOMHTMLLinkElement _linkElement]):
549         (-[DOMHTMLTitleElement _titleElement]):
550         (-[DOMHTMLMetaElement _metaElement]):
551         (-[DOMHTMLBaseElement _baseElement]):
552         (-[DOMHTMLStyleElement _styleElement]):
553         (-[DOMHTMLBodyElement _bodyElement]):
554         (-[DOMHTMLFormElement _formElement]):
555         (+[DOMHTMLFormElement _formElementWith:]):
556         (-[DOMHTMLIsIndexElement _isIndexElement]):
557         (-[DOMHTMLSelectElement _selectElement]):
558         (-[DOMHTMLOptGroupElement _optGroupElement]):
559         (-[DOMHTMLOptionElement _optionElement]):
560         (-[DOMHTMLInputElement _inputElement]):
561         (-[DOMHTMLTextAreaElement _textAreaElement]):
562         (-[DOMHTMLButtonElement _buttonElement]):
563         (-[DOMHTMLLabelElement _labelElement]):
564         (-[DOMHTMLLabelElement form]):
565         (-[DOMHTMLFieldSetElement _fieldSetElement]):
566         (-[DOMHTMLLegendElement _legendElement]):
567         (-[DOMHTMLUListElement _uListElement]):
568         (-[DOMHTMLOListElement _oListElement]):
569         (-[DOMHTMLDListElement _dListElement]):
570         (-[DOMHTMLDirectoryElement _directoryListElement]):
571         (-[DOMHTMLMenuElement _menuListElement]):
572         (-[DOMHTMLLIElement _liElement]):
573         (-[DOMHTMLQuoteElement _quoteElement]):
574         (-[DOMHTMLDivElement _divElement]):
575         (-[DOMHTMLParagraphElement _paragraphElement]):
576         (-[DOMHTMLHeadingElement _headingElement]):
577         (-[DOMHTMLPreElement _preElement]):
578         (-[DOMHTMLBRElement _BRElement]):
579         (-[DOMHTMLBaseFontElement _baseFontElement]):
580         (-[DOMHTMLFontElement _fontElement]):
581         (-[DOMHTMLHRElement _HRElement]):
582         (-[DOMHTMLModElement _modElement]):
583         (-[DOMHTMLAnchorElement _anchorElement]):
584         (-[DOMHTMLImageElement _imageElement]):
585         (-[DOMHTMLObjectElement _objectElement]):
586         (-[DOMHTMLParamElement _paramElement]):
587         (-[DOMHTMLMapElement _mapElement]):
588         (-[DOMHTMLAreaElement _areaElement]):
589         (-[DOMHTMLScriptElement _scriptElement]):
590         (+[DOMHTMLTableCaptionElement _tableCaptionElementWith:]):
591         (-[DOMHTMLTableCaptionElement _tableCaptionElement]):
592         (+[DOMHTMLTableSectionElement _tableSectionElementWith:]):
593         (-[DOMHTMLTableSectionElement _tableSectionElement]):
594         (-[DOMHTMLTableElement createTHead]):
595         (-[DOMHTMLTableElement createTFoot]):
596         (-[DOMHTMLTableElement createCaption]):
597         (-[DOMHTMLTableElement insertRow:]):
598         (+[DOMHTMLTableElement _tableElementWith:]):
599         (-[DOMHTMLTableElement _tableElement]):
600         (-[DOMHTMLTableColElement _tableColElement]):
601         (-[DOMHTMLTableRowElement _tableRowElement]):
602         (-[DOMHTMLTableRowElement insertCell:]):
603         (+[DOMHTMLTableCellElement _tableCellElementWith:]):
604         (-[DOMHTMLTableCellElement _tableCellElement]):
605         (-[DOMHTMLFrameSetElement _frameSetElement]):
606         (-[DOMHTMLFrameElement _frameElement]):
607         (-[DOMHTMLIFrameElement _IFrameElement]):
608         (-[DOMHTMLEmbedElement _embedElement]):
609         (viewForElement):
610         * bridge/mac/FrameMac.mm:
611         (WebCore::FrameMac::searchForLabelsAboveCell):
612         (WebCore::FrameMac::searchForLabelsBeforeElement):
613         (WebCore::FrameMac::createFrame):
614         (WebCore::FrameMac::passMouseDownEventToWidget):
615         (WebCore::FrameMac::passSubframeEventToSubframe):
616         (WebCore::FrameMac::passWheelEventToChildWidget):
617         (WebCore::FrameMac::fileWrapperForElement):
618         (WebCore::listParent):
619         (WebCore::FrameMac::attributedString):
620         (WebCore::FrameMac::shouldBeginEditing):
621         (WebCore::FrameMac::shouldEndEditing):
622         (WebCore::FrameMac::setMarkedTextRange):
623         * dom/Document.cpp:
624         * dom/xml_tokenizer.cpp:
625         * html/HTMLBaseElement.cpp: Added.
626         (WebCore::HTMLBaseElement::removedFromDocument):
627         (WebCore::HTMLBaseElement::process):
628         * html/HTMLBaseElement.h: Added.
629         * html/HTMLDocument.cpp:
630         * html/HTMLElementFactory.cpp:
631         * html/HTMLLinkElement.cpp: Added.
632         (WebCore::HTMLLinkElement::HTMLLinkElement):
633         (WebCore::HTMLLinkElement::process):
634         * html/HTMLLinkElement.h: Added.
635         * html/HTMLMetaElement.cpp: Added.
636         (WebCore::HTMLMetaElement::HTMLMetaElement):
637         (WebCore::HTMLMetaElement::parseMappedAttribute):
638         (WebCore::HTMLMetaElement::process):
639         (WebCore::HTMLMetaElement::setContent):
640         (WebCore::HTMLMetaElement::setHttpEquiv):
641         (WebCore::HTMLMetaElement::setName):
642         * html/HTMLMetaElement.h: Added.
643         * html/HTMLParser.cpp:
644         * html/HTMLScriptElement.cpp: Added.
645         (WebCore::HTMLScriptElement::HTMLScriptElement):
646         (WebCore::HTMLScriptElement::parseMappedAttribute):
647         (WebCore::HTMLScriptElement::evaluateScript):
648         * html/HTMLScriptElement.h: Added.
649         * html/HTMLStyleElement.cpp: Added.
650         (WebCore::HTMLStyleElement::HTMLStyleElement):
651         * html/HTMLStyleElement.h: Added.
652         * html/HTMLTitleElement.cpp: Added.
653         (WebCore::HTMLTitleElement::HTMLTitleElement):
654         (WebCore::HTMLTitleElement::text):
655         (WebCore::HTMLTitleElement::setText):
656         * html/HTMLTitleElement.h: Added.
657         * html/html_headimpl.cpp: Removed.
658         * html/html_headimpl.h: Removed.
659         * loader/CachedCSSStyleSheet.h:
660         * rendering/RenderTableCell.cpp:
661         (WebCore::RenderTableCell::updateFromElement):
662         * rendering/RenderTableCol.cpp:
663         (WebCore::RenderTableCol::updateFromElement):
664
665 2006-05-12  Eric Seidel  <eseidel@apple.com>
666
667         Reviewed by beth.
668
669         Split out html_tableimpl.* into multiple files (one per class)
670         http://bugzilla.opendarwin.org/show_bug.cgi?id=8873
671
672         * WebCore.xcodeproj/project.pbxproj:
673         * html/HTMLTableCaptionElement.cpp: Added.
674         (WebCore::HTMLTableCaptionElement::HTMLTableCaptionElement):
675         * html/HTMLTableCaptionElement.h: Added.
676         * html/HTMLTableCellElement.cpp: Added.
677         (WebCore::HTMLTableCellElement::HTMLTableCellElement):
678         * html/HTMLTableCellElement.h: Added.
679         * html/HTMLTableColElement.cpp: Added.
680         (WebCore::HTMLTableColElement::HTMLTableColElement):
681         (WebCore::HTMLTableColElement::endTagRequirement):
682         (WebCore::HTMLTableColElement::tagPriority):
683         (WebCore::HTMLTableColElement::checkDTD):
684         * html/HTMLTableColElement.h: Added.
685         * html/HTMLTableElement.cpp: Added.
686         (WebCore::HTMLTableElement::HTMLTableElement):
687         (WebCore::HTMLTableElement::setCaption):
688         (WebCore::HTMLTableElement::setTHead):
689         (WebCore::HTMLTableElement::setTFoot):
690         (WebCore::HTMLTableElement::setTBody):
691         (WebCore::HTMLTableElement::createTHead):
692         (WebCore::HTMLTableElement::deleteTHead):
693         (WebCore::HTMLTableElement::createTFoot):
694         (WebCore::HTMLTableElement::deleteTFoot):
695         (WebCore::HTMLTableElement::createCaption):
696         (WebCore::HTMLTableElement::deleteCaption):
697         (WebCore::HTMLTableElement::insertRow):
698         (WebCore::HTMLTableElement::deleteRow):
699         (WebCore::HTMLTableElement::addChild):
700         (WebCore::HTMLTableElement::parseMappedAttribute):
701         (WebCore::HTMLTableElement::attach):
702         * html/HTMLTableElement.h: Added.
703         * html/HTMLTablePartElement.cpp: Added.
704         (WebCore::HTMLTablePartElement::parseMappedAttribute):
705         * html/HTMLTablePartElement.h: Added.
706         * html/HTMLTableRowElement.cpp: Added.
707         (WebCore::HTMLTableRowElement::HTMLTableRowElement):
708         (WebCore::HTMLTableRowElement::rowIndex):
709         * html/HTMLTableRowElement.h: Added.
710         * html/HTMLTableSectionElement.cpp: Added.
711         (WebCore::HTMLTableSectionElement::insertRow):
712         * html/HTMLTableSectionElement.h: Added.
713         * html/html_tableimpl.cpp: Removed.
714         * html/html_tableimpl.h: Removed.
715
716 2006-05-10  Eric Seidel  <eseidel@apple.com>
717
718         Reviewed by mjs & adele.
719
720         Split html_objectimpl.* into multiple files (one per class)
721         http://bugzilla.opendarwin.org/show_bug.cgi?id=8836
722
723         * WebCore.xcodeproj/project.pbxproj:
724         * bindings/js/kjs_dom.cpp:
725         (KJS::DOMNamedNodeMap::lengthGetter):
726         (KJS::DOMNamedNodeMap::indexGetter):
727         (KJS::DOMNamedNodeMap::nameGetter):
728         (KJS::DOMNamedNodeMapProtoFunc::callAsFunction):
729         (KJS::getRuntimeObject):
730         * bindings/js/kjs_html.cpp:
731         * html/HTMLAppletElement.cpp: Added.
732         * html/HTMLAppletElement.h: Added.
733         * html/HTMLElementFactory.cpp:
734         * html/HTMLEmbedElement.cpp: Added.
735         (WebCore::HTMLEmbedElement::HTMLEmbedElement):
736         (WebCore::HTMLEmbedElement::getInstance):
737         (WebCore::HTMLEmbedElement::parseMappedAttribute):
738         * html/HTMLEmbedElement.h: Added.
739         * html/HTMLNameCollection.cpp:
740         (WebCore::HTMLNameCollection::traverseNextItem):
741         * html/HTMLObjectElement.cpp: Added.
742         (WebCore::HTMLObjectElement::getInstance):
743         (WebCore::HTMLObjectElement::form):
744         (WebCore::HTMLObjectElement::parseMappedAttribute):
745         (WebCore::HTMLObjectElement::updateDocNamedItem):
746         * html/HTMLObjectElement.h: Added.
747         * html/HTMLParamElement.cpp: Added.
748         * html/HTMLParamElement.h: Added.
749         * html/HTMLParser.cpp:
750         * html/HTMLPlugInElement.cpp: Added.
751         * html/HTMLPlugInElement.h: Added.
752         * html/html_objectimpl.cpp: Removed.
753         * html/html_objectimpl.h: Removed.
754         * page/Frame.cpp:
755         (WebCore::Frame::handleFallbackContent):
756         * rendering/RenderApplet.cpp:
757         * rendering/render_frames.cpp:
758         (WebCore::RenderPartObject::updateWidget):
759
760 2006-05-12  Darin Adler  <darin@apple.com>
761
762         Reviewed by Adele.
763
764         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=8521
765           crash bringing up context menu with CSS generated content
766
767         * bridge/mac/FrameMac.mm: (WebCore::FrameMac::sendContextMenuEvent):
768         Added a null check.
769
770         * manual-tests/context-click-generated-content.html: Added.
771
772 2006-05-12  Darin Adler  <darin@apple.com>
773
774         Reviewed by Adele.
775
776         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=8715
777           REGRESSION: Caret to the right of an image is a big black rectangle.
778
779         * rendering/RenderBox.cpp: (WebCore::RenderBox::caretRect): Move caret to the
780         right side of the rect when the offset is non-zero, rather than expanding it.
781
782         * manual-tests/caret-image.html: Added.
783
784 2006-05-12  Mitz Pettel  <opendarwin.org@mitzpettel.com>
785
786         Reviewed and landed by Anders.
787         
788         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=8866
789           REGRESSION: Incorrect caret position in RTL text
790
791         Test: fast/text/international/rtl-caret.html
792
793         * rendering/InlineTextBox.cpp:
794         (WebCore::InlineTextBox::positionForOffset): Added missing m_toAdd argument.
795
796 2006-05-12  David Hyatt  <hyatt@apple.com>
797
798         Bug 8864. Lift WebCoreTextStyle up into the API (as TextStyle).
799
800         Reviewed by mjs
801
802         * platform/Font.cpp:
803         (WebCore::m_finalRoundingWidth):
804         (WebCore::WidthIterator::advance):
805         (WebCore::Font::width):
806         (WebCore::Font::drawSimpleText):
807         (WebCore::Font::drawText):
808         (WebCore::Font::floatWidth):
809         (WebCore::Font::floatWidthForSimpleText):
810         * platform/Font.h:
811         (WebCore::TextStyle::m_attemptFontSubstitution):
812         (WebCore::TextStyle::tabWidth):
813         (WebCore::TextStyle::xPos):
814         (WebCore::TextStyle::padding):
815         (WebCore::TextStyle::rtl):
816         (WebCore::TextStyle::ltr):
817         (WebCore::TextStyle::directionalOverride):
818         (WebCore::TextStyle::applyRunRounding):
819         (WebCore::TextStyle::applyWordRounding):
820         (WebCore::TextStyle::attemptFontSubstitution):
821         (WebCore::Font::operator==):
822         * platform/GraphicsContext.cpp:
823         (WebCore::GraphicsContext::drawText):
824         (WebCore::GraphicsContext::drawHighlightForText):
825         * platform/GraphicsContext.h:
826         * platform/mac/FontMac.mm:
827         (WebCore::overrideLayoutOperation):
828         (WebCore::ATSULayoutParameters::initialize):
829         (WebCore::Font::selectionRectForText):
830         (WebCore::Font::drawComplexText):
831         (WebCore::Font::floatWidthForComplexText):
832         (WebCore::Font::offsetForPosition):
833         * rendering/InlineTextBox.cpp:
834         (WebCore::InlineTextBox::selectionRect):
835         (WebCore::InlineTextBox::paint):
836         (WebCore::InlineTextBox::paintSelection):
837         (WebCore::InlineTextBox::paintMarkedTextBackground):
838         (WebCore::InlineTextBox::paintTextMatchMarker):
839         (WebCore::InlineTextBox::offsetForPosition):
840         (WebCore::InlineTextBox::positionForOffset):
841         * rendering/RenderText.cpp:
842         (WebCore::RenderText::widthFromCache):
843         (WebCore::RenderText::calcMinMaxWidth):
844         (WebCore::RenderText::width):
845         * rendering/RenderTextField.cpp:
846         (WebCore::RenderTextField::calcMinMaxWidth):
847         * rendering/render_line.cpp:
848         (WebCore::EllipsisBox::paint):
849
850 2006-05-11  Alexey Proskuryakov  <ap@nypop.com>
851
852         Reviewed by Darin.
853
854         - http://bugzilla.opendarwin.org/show_bug.cgi?id=8770
855           XMLHttpRequest should strip CR/LF characters from the URL
856
857         Test: fast/loader/url-strip-cr-lf-tab.html
858
859         * platform/KURL.cpp:
860         (appendEscapingBadChars): Strip CR, LF and TAB, as Firefox and IE do.
861
862 2006-05-11  David Hyatt  <hyatt@apple.com>
863
864         Remove the misspelling drawing code from Font and FontData.  Implement it
865         natively in GraphicContext instead.
866
867         Reviewed by maciej
868
869         * platform/FontData.h:
870         * platform/GraphicsContext.cpp:
871         * platform/GraphicsContext.h:
872         * platform/cairo/GraphicsContextCairo.cpp:
873         (WebCore::GraphicsContext::drawLineForMisspelling):
874         * platform/mac/FontData.mm:
875         * platform/mac/FontMac.mm:
876         * platform/mac/GraphicsContextMac.mm:
877         (WebCore::GraphicsContext::drawLineForMisspelling):
878         * platform/win/FontWin.cpp:
879         * rendering/InlineTextBox.cpp:
880         (WebCore::InlineTextBox::paintSpellingMarker):
881
882 2006-05-11  David Hyatt  <hyatt@apple.com>
883
884         Remove drawLineForText from the Font API.  Implement it natively in
885         the two GraphicsContexts (CG and Cairo) instead.
886
887         Reviewed by maciej
888
889         * platform/Font.h:
890         * platform/FontData.h:
891         * platform/GraphicsContext.cpp:
892         * platform/GraphicsContext.h:
893         * platform/cairo/GraphicsContextCairo.cpp:
894         (WebCore::GraphicsContext::drawLineForText):
895         * platform/cg/GraphicsContextCG.cpp:
896         (WebCore::GraphicsContext::drawLineForText):
897         * platform/mac/FontData.mm:
898         * platform/mac/FontMac.mm:
899         * platform/win/FontWin.cpp:
900         (WebCore::Font::drawLineForText):
901         * rendering/InlineTextBox.cpp:
902         (WebCore::InlineTextBox::paintDecoration):
903         (WebCore::InlineTextBox::paintMarkedTextUnderline):
904         * rendering/render_line.cpp:
905         (WebCore::InlineFlowBox::paintDecorations):
906
907 2006-05-11  Steve Falkenburg  <sfalken@apple.com>
908
909         Reviewed by eric.
910
911         Fix last fix.
912
913         * dom/QualifiedName.h:
914         (WebCore::QualifiedName::QualifiedName):
915
916 2006-05-11  Steve Falkenburg  <sfalken@apple.com>
917
918         Reviewed by eric.
919
920         Fix crash on static constructors builds at exit due to qualified name default constructor not
921         initializing m_impl.
922
923         * dom/QualifiedName.cpp:
924         (WebCore::QualifiedName::deref):
925
926 2006-05-11  Mitz Pettel  <opendarwin.org@mitzpettel.com>
927
928         Reviewed by hyatt
929
930         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=8851
931           REGRESSION: RTL text shifted to the right
932
933         Already covered by several tests in fast/text
934
935         * platform/Font.h:
936         (WebCore::TextRun::TextRun): Added length parameter.
937         * rendering/InlineTextBox.cpp: Pass the length to the TextRun constructor.
938         (WebCore::InlineTextBox::selectionRect):
939         (WebCore::InlineTextBox::paint):
940         (WebCore::InlineTextBox::paintSelection):
941         (WebCore::InlineTextBox::paintMarkedTextBackground):
942         (WebCore::InlineTextBox::paintTextMatchMarker):
943         (WebCore::InlineTextBox::offsetForPosition):
944         (WebCore::InlineTextBox::positionForOffset):
945         * rendering/RenderText.cpp:
946         (WebCore::RenderText::widthFromCache): Pass length and from instead of from and to
947         to the TextRun constructor.
948         (WebCore::RenderText::width): Ditto.
949
950 2006-05-11  David Hyatt  <hyatt@apple.com>
951
952         Fix a regression from the TextRun landing.  Delete the characters in
953         the adjustedRun, not the ones in the original run!
954
955         Reviewed by beth
956
957         * platform/mac/FontMac.mm:
958         (WebCore::Font::drawComplexText):
959
960 2006-05-10  Justin Garcia  <justin.garcia@apple.com>
961
962         Reviewed by thatcher, levi
963
964         * editing/ReplaceSelectionCommand.cpp:
965         (WebCore::ReplaceSelectionCommand::doApply):
966         Removed a use fragment.hasMoreThanOneBlock to decide if the paragraph containing the
967         position pasted into must be split to avoid block nesting.  We now split unnecessarily
968         some times, but the end merge cleans up for us.
969
970 2006-05-11  David Hyatt  <hyatt@apple.com>
971
972         This patch makes drawHighlightForText a completely cross-platform method
973         implemented by the GraphicsContext.  The platform-specific implementations
974         of the method in the Font class have been eliminated.
975
976         Reviewed by andersca
977
978         * platform/Font.h:
979         * platform/FontData.h:
980         Remove the drawHighlight methods.  Change the selectionRect method in
981         Font to return a FloatRect so that the GraphicsContext can do an accurate
982         fill.
983
984         * platform/GraphicsContext.cpp:
985         (WebCore::GraphicsContext::drawHighlightForText):
986         Implement the drawHighlightFunction in terms of the cross-platform
987         Font selectionRect functions and a new float-based fillRect graphics context
988         function.
989
990         * platform/GraphicsContext.h:
991         * platform/cairo/GraphicsContextCairo.cpp:
992         (WebCore::GraphicsContext::fillRect):
993         * platform/cg/GraphicsContextCG.cpp:
994         (WebCore::GraphicsContext::fillRect):
995         Add the new float-based fillRect function for Cairo and CG.
996
997         * platform/mac/FontData.mm:
998         (WebCore::CG_draw):
999         (WebCore::ATSU_draw):
1000         Removed the CG and ATSU drawHighlight methods.  Remove the drawing of
1001         the background from the deprecated draw methods (they'll be removed
1002         soon).
1003
1004         * platform/mac/FontMac.mm:
1005         (WebCore::Font::selectionRectForText):
1006         * platform/win/FontWin.cpp:
1007         (WebCore::Font::selectionRectForText):
1008         Change selectionRectForText to return a FloatRect instead of an IntRect,
1009         so that the GraphicsContext can do a precise fill.
1010
1011         * rendering/InlineTextBox.cpp:
1012         (WebCore::InlineTextBox::selectionRect):
1013         (WebCore::InlineTextBox::positionForOffset):
1014         Modify the callers who expect an int-based selection rect so that they call
1015         enclosingIntRect.
1016
1017 2006-05-11  Darin Adler  <darin@apple.com>
1018
1019         Reviewed by Adele.
1020
1021         - http://bugzilla.opendarwin.org/show_bug.cgi?id=8743
1022           REGRESSION: focus() on input field selects all text within it
1023           (was: cannot select cities on British Rail reservation site)
1024
1025         Test: fast/forms/double-focus.html
1026
1027         * html/HTMLInputElement.cpp: (WebCore::HTMLInputElement::focus):
1028         Changed to only call setFocusNode, select, and revealSelection
1029         if the element is not already focused. Also changed to use return
1030         a bit more rather than else.
1031
1032 2006-05-11  Darin Adler  <darin@apple.com>
1033
1034         Reviewed by Tim Hatcher (earlier version).
1035
1036         - http://bugzilla.opendarwin.org/show_bug.cgi?id=8821
1037           use the preprocessor for IDL files
1038
1039         * bindings/scripts/IDLParser.pm: Invoke the preprocessor via the "gcc"
1040         driver script, passing "-E" so we only preprocess, "-P" so we don't get
1041         "#line" directives, and "-x c++" so we handle both C and C++ comments.
1042         Removed the code to eliminate comments since the preprocessor handles that.
1043         * css/make-css-file-arrays.pl: This already invoked the preprocessor, but
1044         updated it to do the same way as above.
1045
1046 2006-05-11  Anders Carlsson  <acarlsson@apple.com>
1047
1048         Reviewed by Darin.
1049
1050         http://bugzilla.opendarwin.org/show_bug.cgi?id=7838
1051         Add support for mozilla-style node constructors as properties of the window object
1052         
1053         * DerivedSources.make:
1054         * WebCore.xcodeproj/project.pbxproj:
1055         Add new generated files.
1056         
1057         * bindings/js/JSCanvasRenderingContext2DBase.cpp:
1058         (WebCore::JSCanvasRenderingContext2DBaseProtoFunc::callAsFunction):
1059         * bindings/js/JSHTMLElementWrapperFactory.cpp:
1060         (WebCore::createJSWrapper):
1061         Specify the KJS namespace for JSHTMLElmement.
1062                 
1063         * bindings/js/kjs_dom.cpp:
1064         (KJS::toJS):
1065         Create a WebCore::JSHTMLDocument for document nodes. Also, create
1066         JSDocumentFragments for document fragments (instead of plain node objects).
1067         
1068         * bindings/js/kjs_html.cpp:
1069         (KJS::JSHTMLDocumentProtoFunc::callAsFunction):
1070         (KJS::JSHTMLDocument::JSHTMLDocument):
1071         (KJS::JSHTMLDocument::getOwnPropertySlot):
1072         Add a prototype for JSHTMLDocument and move all functions there.
1073         
1074         (KJS::JSHTMLElement::JSHTMLElement):
1075         (KJS::JSHTMLElement::getOwnPropertySlot):
1076         Update since JSHTMLElement now inherits from WebCore::JSHTMLElement.
1077         
1078         (KJS::JSHTMLElement::getValueProperty):
1079         (KJS::JSHTMLElement::putValueProperty):
1080         Remove title setter and getter. Those are autogenerated now.
1081         
1082         * bindings/js/kjs_html.h:
1083         (KJS::JSHTMLElement::):
1084         Inherit from WebCore::JSHTMLElement. Clarify the inheritance chain.
1085         
1086         * bindings/scripts/CodeGeneratorJS.pm:
1087         Always generate a prototype object, regardless of whether the object has any functions or
1088         constants.
1089         
1090         Use the type of generator attributes to determine what constructor to use. This is useful for
1091         the XMLDocument property in DOMWindow.idl, since that's just an alias for the Document constructor.
1092         
1093         * dom/DocumentFragment.idl: Added.        
1094         * html/HTMLDocument.idl: Added.
1095         * html/HTMLElement.idl: Added.
1096         
1097         * page/DOMWindow.idl:
1098         Add constructors for DocumentFragment, HTMLElement, HTMLDocument and XMLDocument. XMLDocument is just
1099         an alias for the Document constructor.
1100         
1101 2006-05-11  David Hyatt  <hyatt@apple.com>
1102
1103         Bug 8845.  Define a TextRun (similar to the old WebCoreTextRun) and
1104         make it the new API for Font and GraphicsContext when drawing/measuring
1105         text.
1106
1107         Reviewed by andersca
1108
1109         * platform/Font.cpp:
1110         (WebCore::m_finalRoundingWidth):
1111         (WebCore::WidthIterator::advance):
1112         (WebCore::WidthIterator::normalizeVoicingMarks):
1113         (WebCore::Font::width):
1114         (WebCore::Font::canUseGlyphCache):
1115         (WebCore::Font::drawSimpleText):
1116         (WebCore::Font::drawText):
1117         (WebCore::Font::floatWidth):
1118         (WebCore::Font::floatWidthForSimpleText):
1119         * platform/Font.h:
1120         (WebCore::TextRun::m_to):
1121         (WebCore::TextRun::operator[]):
1122         (WebCore::TextRun::data):
1123         (WebCore::TextRun::adjustFrom):
1124         (WebCore::TextRun::adjustTo):
1125         (WebCore::TextRun::characters):
1126         (WebCore::TextRun::length):
1127         (WebCore::TextRun::from):
1128         (WebCore::TextRun::to):
1129         * platform/GraphicsContext.cpp:
1130         (WebCore::GraphicsContext::drawText):
1131         (WebCore::GraphicsContext::drawHighlightForText):
1132         * platform/GraphicsContext.h:
1133         * platform/mac/FontMac.mm:
1134         (WebCore::addDirectionalOverride):
1135         (WebCore::overrideLayoutOperation):
1136         (WebCore::ATSULayoutParameters::initialize):
1137         (WebCore::Font::selectionRectForText):
1138         (WebCore::Font::drawComplexText):
1139         (WebCore::Font::drawHighlightForText):
1140         (WebCore::Font::floatWidthForComplexText):
1141         (WebCore::Font::checkSelectionPoint):
1142         * platform/win/FontWin.cpp:
1143         (WebCore::hackishExtentForString):
1144         (WebCore::Font::floatWidth):
1145         (WebCore::Font::drawText):
1146         (WebCore::Font::drawHighlightForText):
1147         (WebCore::Font::selectionRectForText):
1148         (WebCore::Font::checkSelectionPoint):
1149         * rendering/InlineTextBox.cpp:
1150         (WebCore::InlineTextBox::selectionRect):
1151         (WebCore::InlineTextBox::paint):
1152         (WebCore::InlineTextBox::paintSelection):
1153         (WebCore::InlineTextBox::paintMarkedTextBackground):
1154         (WebCore::InlineTextBox::paintTextMatchMarker):
1155         (WebCore::InlineTextBox::offsetForPosition):
1156         (WebCore::InlineTextBox::positionForOffset):
1157         * rendering/RenderBlock.cpp:
1158         (WebCore::stripTrailingSpace):
1159         * rendering/RenderFlexibleBox.cpp:
1160         (WebCore::RenderFlexibleBox::layoutVerticalBox):
1161         * rendering/RenderImage.cpp:
1162         (WebCore::RenderImage::imageChanged):
1163         (WebCore::RenderImage::paint):
1164         * rendering/RenderText.cpp:
1165         (WebCore::RenderText::cacheWidths):
1166         (WebCore::RenderText::widthFromCache):
1167         (WebCore::RenderText::trimmedMinMaxWidth):
1168         (WebCore::RenderText::calcMinMaxWidth):
1169         (WebCore::RenderText::width):
1170         * rendering/RenderTextField.cpp:
1171         (WebCore::RenderTextField::calcMinMaxWidth):
1172         * rendering/bidi.cpp:
1173         (WebCore::RenderBlock::tabWidth):
1174         (WebCore::RenderBlock::checkLinesForTextOverflow):
1175         * rendering/render_line.cpp:
1176         (WebCore::EllipsisBox::paint):
1177         * rendering/render_list.cpp:
1178         (WebCore::RenderListMarker::paint):
1179         (WebCore::RenderListMarker::calcMinMaxWidth):
1180         (WebCore::RenderListMarker::getRelativeMarkerRect):
1181
1182 2006-05-10  Justin Garcia  <justin.garcia@apple.com>
1183
1184         Reviewed by darin
1185
1186         * editing/ReplaceSelectionCommand.cpp:
1187         (WebCore::ReplaceSelectionCommand::doApply):
1188         Removed the code to find out if we must later add smart replace whitespace.  We can 
1189         wait until we've done the insertion to figure it out, and the position sampled (startPos)
1190         to make the decision about trailing whitespace was wrong.
1191         Changed the order that work is done during a paste: 1) Insert everything 2) Do one of
1192         the following: a) handle a trailing interchange newline, b) uncollapse the last incoming
1193         br if it has been collapsed because of quirks mode, c) do an end merge 3) Add smart replace
1194         whitespace (2 and 3 were reversed because the end merge must happen before we can know
1195         whether or not we need to add a trailing space).
1196         Don't do an end merge if the last node inserted was a br because the end merge will 
1197         clobber it.
1198         
1199         (WebCore::ReplaceSelectionCommand::removeEndBRIfNeeded):
1200         brs where [br, 0] is at the end of a block and not at the start of a paragraph
1201         are the ones that are collapsed because of quirks mode.
1202
1203 2006-05-10  David Hyatt  <hyatt@apple.com>
1204
1205         Rename isSpace to treatAsSpace.  Move it and the rounding hack function into
1206         Font and make them static methods (inlined in the header).  Make the rounding
1207         hack character table a static member as well.  Remove the redundant space/rounding
1208         functions from FontData.mm.
1209
1210         Reviewed by darin
1211
1212         * platform/Font.cpp:
1213         (WebCore::):
1214         (WebCore::m_finalRoundingWidth):
1215         (WebCore::WidthIterator::advance):
1216         * platform/Font.h:
1217         (WebCore::Font::treatAsSpace):
1218         (WebCore::Font::isRoundingHackCharacter):
1219         * platform/mac/FontData.mm:
1220         (WebCore::overrideLayoutOperation):
1221         (WebCore::createATSULayoutParameters):
1222         (WebCore::initializeWidthIterator):
1223         (WebCore::advanceWidthIterator):
1224         * platform/mac/FontMac.mm:
1225         (WebCore::overrideLayoutOperation):
1226         (WebCore::ATSULayoutParameters::initialize):
1227
1228 2006-05-10  Darin Adler  <darin@apple.com>
1229
1230         * WebCore: Removed an extra WebCore subtree that somehow got checked in.
1231
1232 2006-05-10  David Carson <dacarson@gmail.com>
1233
1234         - Fix for bug 8833. Removed inline keyword from functions declared
1235         in .mm and .cpp files. inline function code needs to reside in the
1236         header file for the linker to find the code. 
1237         http://www.parashift.com/c++-faq-lite/inline-functions.html#faq-9.7
1238
1239         Reviewed by Darin, landed by Timothy.
1240
1241         * platform/Font.cpp:
1242         (WebCore::isSpace):
1243         * platform/mac/FontData.mm:
1244         (WebCore::widthForGlyph):
1245         (WebCore::isRoundingHackCharacter):
1246         (WebCore::glyphForCharacter):
1247
1248 2006-05-10  Mitz Pettel  <opendarwin.org@mitzpettel.com>
1249
1250         Reviewed and landed by Anders.
1251
1252         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=8830
1253           REGRESSION: Words render on top of each other when fallback font is used
1254
1255         Already covered by several pixel tests in fast/text
1256
1257         * platform/Font.cpp:
1258         (WebCore::Font::drawSimpleText):
1259
1260 2006-05-10  David Hyatt  <hyatt@apple.com>
1261
1262         Fix for bug 8809, lift the Mac-specific WebTextRenderer code for
1263         drawing and measuring of runs up into the Font class.  The fast code
1264         path is in Font.cpp and is designed to be mostly cross-platform.  The
1265         slow code path is in FontMac.cpp and is Mac-specific.
1266
1267         Reviewed by darin
1268
1269         * WebCore.xcodeproj/project.pbxproj:
1270         * platform/Font.cpp:
1271         (WebCore::isSpace):
1272         (WebCore::):
1273         (WebCore::isRoundingHackCharacter):
1274         (WebCore::m_finalRoundingWidth):
1275         (WebCore::WidthIterator::advance):
1276         (WebCore::WidthIterator::normalizeVoicingMarks):
1277         (WebCore::Font::primaryFont):
1278         (WebCore::Font::setAlwaysUseComplexPath):
1279         (WebCore::Font::canUseGlyphCache):
1280         (WebCore::Font::drawSimpleText):
1281         (WebCore::Font::drawText):
1282         (WebCore::Font::floatWidth):
1283         (WebCore::Font::floatWidthForSimpleText):
1284         * platform/Font.h:
1285         * platform/FontData.h:
1286         (WebCore::FontData::platformData):
1287         * platform/GlyphBuffer.h: Added.
1288         (WebCore::GlyphBuffer::GlyphBuffer):
1289         (WebCore::GlyphBuffer::isEmpty):
1290         (WebCore::GlyphBuffer::size):
1291         (WebCore::GlyphBuffer::glyphs):
1292         (WebCore::GlyphBuffer::advances):
1293         (WebCore::GlyphBuffer::fontDataAt):
1294         (WebCore::GlyphBuffer::swap):
1295         (WebCore::GlyphBuffer::glyphAt):
1296         (WebCore::GlyphBuffer::advanceAt):
1297         (WebCore::GlyphBuffer::add):
1298         * platform/mac/FontData.mm:
1299         (WebCore::isSpace):
1300         (WebCore::isRoundingHackCharacter):
1301         (WebCore::FontData::widthForGlyph):
1302         (WebCore::m_ATSUMirrors):
1303         (WebCore::FontData::xHeight):
1304         (WebCore::FontData::smallCapsFontData):
1305         (WebCore::findSubstituteFont):
1306         (WebCore::rendererForAlternateFont):
1307         (WebCore::findSubstituteRenderer):
1308         (WebCore::FontData::findSubstituteFontData):
1309         (WebCore::computeWidthForSpace):
1310         (WebCore::FontData::updateGlyphMapEntry):
1311         (WebCore::extendGlyphMap):
1312         (WebCore::extendWidthMap):
1313         (WebCore::createATSULayoutParameters):
1314         (WebCore::FontData::glyphForCharacter):
1315         (WebCore::advanceWidthIterator):
1316         (WebCore::shouldUseATSU):
1317         * platform/mac/FontMac.mm:
1318         (WebCore::ATSULayoutParameters::m_padPerSpace):
1319         (WebCore::addDirectionalOverride):
1320         (WebCore::initializeATSUStyle):
1321         (WebCore::overrideLayoutOperation):
1322         (WebCore::ATSULayoutParameters::initialize):
1323         (WebCore::disposeATSULayoutParameters):
1324         (WebCore::Font::drawComplexText):
1325         (WebCore::Font::floatWidthForComplexText):
1326         (WebCore::Font::drawGlyphs):
1327         * platform/mac/WebCoreTextRenderer.mm:
1328         (WebCoreSetAlwaysUseATSU):
1329
1330 2006-05-10  Darin Adler  <darin@apple.com>
1331
1332         - another try at fixing the Windows build
1333
1334         * platform/win/FontWin.cpp: (WebCore::getFontData): Use characters()
1335         instead of unicode().
1336
1337 == Rolled over to ChangeLog-2006-05-10 ==