[SCM] WebKit Debian packaging branch, debian/unstable, updated. debian/1.1.15-1-40151-g37bb677
sullivan
sullivan at 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Sat Sep 26 08:43:11 UTC 2009
The following commit has been merged in the debian/unstable branch:
commit c7c63dc7cb698752cd8b5e02c15861e14f1bd981
Author: sullivan <sullivan at 268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Wed Jun 2 00:09:08 2004 +0000
Reviewed by Trey.
Work on text-align API. Marked these bugs fixed:
<rdar://problem/3655380>: (Editing:�alignCenter:�ethod�nimplemented�WebKit�diting�PI))
<rdar://problem/3655381>: (Editing:�alignJustified:�ethod�nimplemented�WebKit�diting�PI))
<rdar://problem/3655383>: (Editing:�alignLeft:�ethod�nimplemented�WebKit�diting�PI))
<rdar://problem/3655384>: (Editing:�alignRight:�ethod�nimplemented�WebKit�diting�PI))
in favor of opening this bug:
<rdar://problem/3675191>: (Editing: -alignLeft: and friends mostly implemented but not
yet working (WebKit editing API))
* English.lproj/StringsNotToBeLocalized.txt:
updated for these changes
* WebView.subproj/WebHTMLView.m:
(-[WebHTMLView changeDocumentBackgroundColor:]):
added a FIXME about why this is still not quite right
(-[WebHTMLView _alignSelectionUsingCSSValue:]):
new method, bottleneck for the various values
(-[WebHTMLView alignCenter:]):
call _alignSelectionUsingCSSValue:@"center"
(-[WebHTMLView alignJustified:]):
call _alignSelectionUsingCSSValue:@"justify"
(-[WebHTMLView alignLeft:]):
call _alignSelectionUsingCSSValue:@"left"
(-[WebHTMLView alignRight:]):
call _alignSelectionUsingCSSValue:@"right"
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@6740 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/WebKit/ChangeLog b/WebKit/ChangeLog
index a4c0003..fb64a67 100644
--- a/WebKit/ChangeLog
+++ b/WebKit/ChangeLog
@@ -1,5 +1,36 @@
2004-06-01 John Sullivan <sullivan at apple.com>
+ Reviewed by Trey.
+
+ Work on text-align API. Marked these bugs fixed:
+ <rdar://problem/3655380>: (Editing:Ê-alignCenter:ÊmethodÊunimplementedÊ(WebKitÊeditingÊAPI))
+ <rdar://problem/3655381>: (Editing:Ê-alignJustified:ÊmethodÊunimplementedÊ(WebKitÊeditingÊAPI))
+ <rdar://problem/3655383>: (Editing:Ê-alignLeft:ÊmethodÊunimplementedÊ(WebKitÊeditingÊAPI))
+ <rdar://problem/3655384>: (Editing:Ê-alignRight:ÊmethodÊunimplementedÊ(WebKitÊeditingÊAPI))
+
+ in favor of opening this bug:
+ <rdar://problem/3675191>: (Editing: -alignLeft: and friends mostly implemented but not
+ yet working (WebKit editing API))
+
+ * English.lproj/StringsNotToBeLocalized.txt:
+ updated for these changes
+
+ * WebView.subproj/WebHTMLView.m:
+ (-[WebHTMLView changeDocumentBackgroundColor:]):
+ added a FIXME about why this is still not quite right
+ (-[WebHTMLView _alignSelectionUsingCSSValue:]):
+ new method, bottleneck for the various values
+ (-[WebHTMLView alignCenter:]):
+ call _alignSelectionUsingCSSValue:@"center"
+ (-[WebHTMLView alignJustified:]):
+ call _alignSelectionUsingCSSValue:@"justify"
+ (-[WebHTMLView alignLeft:]):
+ call _alignSelectionUsingCSSValue:@"left"
+ (-[WebHTMLView alignRight:]):
+ call _alignSelectionUsingCSSValue:@"right"
+
+2004-06-01 John Sullivan <sullivan at apple.com>
+
Reviewed by Ken.
- fixed <rdar://problem/3655378>: (Editing:Ê-changeDocumentBackgroundColor:Ê
diff --git a/WebKit/English.lproj/StringsNotToBeLocalized.txt b/WebKit/English.lproj/StringsNotToBeLocalized.txt
index 620eb75..94e3682 100644
--- a/WebKit/English.lproj/StringsNotToBeLocalized.txt
+++ b/WebKit/English.lproj/StringsNotToBeLocalized.txt
@@ -309,6 +309,7 @@
"mainFrameURL"
"nullplugin"
"pluginspage"
+"rgb(%.0f,%.0f,%.0f)"
"src"
"text/"
"text/calendar"
@@ -361,8 +362,12 @@ WebCoreSupport.subproj/WebTextRendererFactory.m:"Pashto"
WebCoreSupport.subproj/WebTextRendererFactory.m:"Urdu"
WebView.subproj/WebDataSource.m:"Refresh"
WebView.subproj/WebHTMLView.m:"bold"
+WebView.subproj/WebHTMLView.m:"center"
WebView.subproj/WebHTMLView.m:"italic"
+WebView.subproj/WebHTMLView.m:"justify"
+WebView.subproj/WebHTMLView.m:"left"
WebView.subproj/WebHTMLView.m:"normal"
+WebView.subproj/WebHTMLView.m:"right"
WebView.subproj/WebPreferences.m:"Identifier"
WebView.subproj/WebPreferences.m:"Values"
WebView.subproj/WebPreferences.m:"WebPreferences%d"
diff --git a/WebKit/WebView.subproj/WebHTMLView.m b/WebKit/WebView.subproj/WebHTMLView.m
index 36ba6a9..3498a23 100644
--- a/WebKit/WebView.subproj/WebHTMLView.m
+++ b/WebKit/WebView.subproj/WebHTMLView.m
@@ -2458,6 +2458,10 @@ static WebHTMLView *lastHitView = nil;
// FIXME: this actually has no effect when called, probably due to 3654850. _entireDOMRange seems
// to do the right thing because it works in startSpeaking:, and I know setBackgroundColor: does the
// right thing because I tested it with [[self _bridge] selectedDOMRange].
+ // FIXME: This won't actually apply the style to the entire range here, because it ends up calling
+ // [bridge applyStyle:], which operates on the current selection. To make this work right, we'll
+ // need to save off the selection, temporarily set it to the entire range, make the change, then
+ // restore the old selection.
[self _changeCSSColorUsingSelector:@selector(setBackgroundColor:) inRange:[self _entireDOMRange]];
}
@@ -2471,24 +2475,37 @@ static WebHTMLView *lastHitView = nil;
[self _changeCSSColorUsingSelector:@selector(setColor:) inRange:[[self _bridge] selectedDOMRange]];
}
+- (void)_alignSelectionUsingCSSValue:(NSString *)CSSAlignmentValue
+{
+ // FIXME 3675191: This doesn't work yet. Maybe it's blocked by 3654850, or maybe something other than
+ // just applyStyle: needs to be called for block-level attributes like this.
+ WebBridge *bridge = [self _bridge];
+ DOMCSSStyleDeclaration *style = [[bridge DOMDocument] createCSSStyleDeclaration];
+ [style setTextAlign:CSSAlignmentValue];
+ WebView *webView = [self _webView];
+ if ([[webView _editingDelegateForwarder] webView:webView shouldApplyStyle:style toElementsInDOMRange:[bridge selectedDOMRange]]) {
+ [[self _bridge] applyStyle:style];
+ }
+}
+
- (void)alignCenter:(id)sender
{
- ERROR("unimplemented");
+ [self _alignSelectionUsingCSSValue:@"center"];
}
- (void)alignJustified:(id)sender
{
- ERROR("unimplemented");
+ [self _alignSelectionUsingCSSValue:@"justify"];
}
- (void)alignLeft:(id)sender
{
- ERROR("unimplemented");
+ [self _alignSelectionUsingCSSValue:@"left"];
}
- (void)alignRight:(id)sender
{
- ERROR("unimplemented");
+ [self _alignSelectionUsingCSSValue:@"right"];
}
- (void)indent:(id)sender
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list