aboutsummaryrefslogtreecommitdiffstats
path: root/components/script/dom/document.rs
diff options
context:
space:
mode:
authorCorey Farwell <coreyf@rwell.org>2015-11-28 10:12:58 -0500
committerCorey Farwell <coreyf@rwell.org>2015-11-30 18:19:07 -0500
commit320263199fbcc3aa60587f11bb757d6237e0e0aa (patch)
tree72e0e88372da01ab725a1e9fd2f91e3a5eb8d3af /components/script/dom/document.rs
parent29c42a9f78a20ddeb5aa89b79d578a039c087967 (diff)
downloadservo-320263199fbcc3aa60587f11bb757d6237e0e0aa.tar.gz
servo-320263199fbcc3aa60587f11bb757d6237e0e0aa.zip
Implement attribute 'fgColor' on 'document'
The 'text' attribute was implemented on '<body>' in #7841
Diffstat (limited to 'components/script/dom/document.rs')
-rw-r--r--components/script/dom/document.rs10
1 files changed, 10 insertions, 0 deletions
diff --git a/components/script/dom/document.rs b/components/script/dom/document.rs
index 31f67f33801..11d38b37dd0 100644
--- a/components/script/dom/document.rs
+++ b/components/script/dom/document.rs
@@ -2281,6 +2281,16 @@ impl DocumentMethods for Document {
self.set_body_attribute(&atom!("bgcolor"), value)
}
+ // https://html.spec.whatwg.org/multipage/#dom-document-fgcolor
+ fn FgColor(&self) -> DOMString {
+ self.get_body_attribute(&atom!("text"))
+ }
+
+ // https://html.spec.whatwg.org/multipage/#dom-document-fgcolor
+ fn SetFgColor(&self, value: DOMString) {
+ self.set_body_attribute(&atom!("text"), value)
+ }
+
// https://html.spec.whatwg.org/multipage/#dom-tree-accessors:dom-document-nameditem-filter
fn NamedGetter(&self, _cx: *mut JSContext, name: DOMString, found: &mut bool) -> *mut JSObject {
#[derive(JSTraceable, HeapSizeOf)]