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