Make invalid values return false from execCommand
authorAryeh Gregor <ayg@aryeh.name>
Sun, 20 May 2012 06:30:28 -0600
changeset 731 90017605b677
parent 730 727e691b1779
child 732 57abe6d3cb60
Make invalid values return false from execCommand

So it will work the same as if the command isn't enabled. This
partially matches Gecko, but mostly just makes sense to me. (At one
point we threw, but that's probably not compatible.)
conformancetest/data.js
editing.html
implementation.js
source.html
tests.js
--- a/conformancetest/data.js	Fri May 18 06:13:37 2012 -0600
+++ b/conformancetest/data.js	Sun May 20 06:30:28 2012 -0600
@@ -1637,7 +1637,7 @@
 ["foo[bar]baz",
 	[["createlink",""]],
 	"foo[bar]baz",
-	[true],
+	[false],
 	{"createlink":[false,false,"",false,false,""]}],
 ["foo[]bar",
 	[["delete",""]],
@@ -4992,17 +4992,17 @@
 ["foo[bar]baz",
 	[["fontsize","2em"]],
 	"foo[bar]baz",
-	[true],
+	[false],
 	{"fontsize":[false,false,"3",false,false,"3"]}],
 ["foo[bar]baz",
 	[["fontsize","20pt"]],
 	"foo[bar]baz",
-	[true],
+	[false],
 	{"fontsize":[false,false,"3",false,false,"3"]}],
 ["foo[bar]baz",
 	[["fontsize","xx-large"]],
 	"foo[bar]baz",
-	[true],
+	[false],
 	{"fontsize":[false,false,"3",false,false,"3"]}],
 ["foo[bar]baz",
 	[["stylewithcss","true"],["fontsize"," 1 "]],
@@ -5017,7 +5017,7 @@
 ["foo[bar]baz",
 	[["fontsize","1."]],
 	"foo[bar]baz",
-	[true],
+	[false],
 	{"fontsize":[false,false,"3",false,false,"3"]}],
 ["foo[bar]baz",
 	[["stylewithcss","true"],["fontsize","1.0"]],
@@ -5112,7 +5112,7 @@
 ["foo[bar]baz",
 	[["fontsize",""]],
 	"foo[bar]baz",
-	[true],
+	[false],
 	{"fontsize":[false,false,"3",false,false,"3"]}],
 ["<table><tbody><tr><td>foo<td>b[a]r<td>baz</table>",
 	[["stylewithcss","true"],["fontsize","4"]],
@@ -5882,7 +5882,7 @@
 ["foo[bar]baz",
 	[["forecolor","currentColor"]],
 	"foo[bar]baz",
-	[true],
+	[false],
 	{"forecolor":[false,false,"rgb(0, 0, 0)",false,false,"rgb(0, 0, 0)"]}],
 ["<table><tbody><tr><td>foo<td>b[a]r<td>baz</table>",
 	[["stylewithcss","true"],["forecolor","#0000FF"]],
@@ -7022,42 +7022,42 @@
 ["<blockquote>[foo]</blockquote><p>extra",
 	[["formatblock","<blockquote>"]],
 	"<blockquote>[foo]</blockquote><p>extra</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"",false,false,""]}],
 ["<blockquote><p>[foo]<p>bar</blockquote><p>extra",
 	[["formatblock","<blockquote>"]],
 	"<blockquote><p>[foo]</p><p>bar</p></blockquote><p>extra</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["[foo]<blockquote>bar</blockquote><p>extra",
 	[["formatblock","<blockquote>"]],
 	"[foo]<blockquote>bar</blockquote><p>extra</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"",false,false,""]}],
 ["<p>[foo<p>bar]<p>baz",
 	[["formatblock","<blockquote>"]],
 	"<p>[foo</p><p>bar]</p><p>baz</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<section>[foo]</section>",
 	[["formatblock","<blockquote>"]],
 	"<section>[foo]</section>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"",false,false,""]}],
 ["<section><p>[foo]</section>",
 	[["formatblock","<blockquote>"]],
 	"<section><p>[foo]</p></section>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<section><hgroup><h1>[foo]</h1><h2>bar</h2></hgroup><p>baz</section>",
 	[["formatblock","<blockquote>"]],
 	"<section><hgroup><h1>[foo]</h1><h2>bar</h2></hgroup><p>baz</p></section>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"h1",false,false,"h1"]}],
 ["<section>[foo]</section>",
 	[["formatblock","<article>"]],
 	"<section>[foo]</section>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"",false,false,""]}],
 ["<div>[foobar]</div>",
 	[["defaultparagraphseparator","div"],["formatblock","<address>"]],
@@ -7072,12 +7072,12 @@
 ["<div>[foobar]</div>",
 	[["formatblock","<article>"]],
 	"<div>[foobar]</div>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"div",false,false,"div"]}],
 ["<div>[foobar]</div>",
 	[["formatblock","<blockquote>"]],
 	"<div>[foobar]</div>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"div",false,false,"div"]}],
 ["<div>[foobar]</div>",
 	[["defaultparagraphseparator","div"],["formatblock","<dd>"]],
@@ -7092,12 +7092,12 @@
 ["<div>[foobar]</div>",
 	[["formatblock","<del>"]],
 	"<div>[foobar]</div>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"div",false,false,"div"]}],
 ["<div>[foobar]</div>",
 	[["formatblock","<dl>"]],
 	"<div>[foobar]</div>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"div",false,false,"div"]}],
 ["<div>[foobar]</div>",
 	[["defaultparagraphseparator","div"],["formatblock","<dt>"]],
@@ -7172,17 +7172,17 @@
 ["<div>[foobar]</div>",
 	[["formatblock","<ins>"]],
 	"<div>[foobar]</div>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"div",false,false,"div"]}],
 ["<div>[foobar]</div>",
 	[["formatblock","<li>"]],
 	"<div>[foobar]</div>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"div",false,false,"div"]}],
 ["<div>[foobar]</div>",
 	[["formatblock","<ol>"]],
 	"<div>[foobar]</div>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"div",false,false,"div"]}],
 ["<div>[foobar]</div>",
 	[["defaultparagraphseparator","div"],["formatblock","<p>"]],
@@ -7207,12 +7207,12 @@
 ["<div>[foobar]</div>",
 	[["formatblock","<ul>"]],
 	"<div>[foobar]</div>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"div",false,false,"div"]}],
 ["<div>[foobar]</div>",
 	[["formatblock","<quasit>"]],
 	"<div>[foobar]</div>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"div",false,false,"div"]}],
 ["<p>[foobar]</p>",
 	[["defaultparagraphseparator","div"],["formatblock","<address>"]],
@@ -7227,22 +7227,22 @@
 ["<p>[foobar]</p>",
 	[["formatblock","<article>"]],
 	"<p>[foobar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foobar]</p>",
 	[["formatblock","<aside>"]],
 	"<p>[foobar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foobar]</p>",
 	[["formatblock","<blockquote>"]],
 	"<p>[foobar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foobar]</p>",
 	[["formatblock","<body>"]],
 	"<p>[foobar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foobar]</p>",
 	[["defaultparagraphseparator","div"],["formatblock","<dd>"]],
@@ -7257,17 +7257,17 @@
 ["<p>[foobar]</p>",
 	[["formatblock","<del>"]],
 	"<p>[foobar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foobar]</p>",
 	[["formatblock","<details>"]],
 	"<p>[foobar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foobar]</p>",
 	[["formatblock","<dir>"]],
 	"<p>[foobar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foobar]</p>",
 	[["defaultparagraphseparator","div"],["formatblock","<div>"]],
@@ -7282,7 +7282,7 @@
 ["<p>[foobar]</p>",
 	[["formatblock","<dl>"]],
 	"<p>[foobar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foobar]</p>",
 	[["defaultparagraphseparator","div"],["formatblock","<dt>"]],
@@ -7297,27 +7297,27 @@
 ["<p>[foobar]</p>",
 	[["formatblock","<fieldset>"]],
 	"<p>[foobar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foobar]</p>",
 	[["formatblock","<figcaption>"]],
 	"<p>[foobar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foobar]</p>",
 	[["formatblock","<figure>"]],
 	"<p>[foobar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foobar]</p>",
 	[["formatblock","<footer>"]],
 	"<p>[foobar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foobar]</p>",
 	[["formatblock","<form>"]],
 	"<p>[foobar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foobar]</p>",
 	[["defaultparagraphseparator","div"],["formatblock","<h1>"]],
@@ -7382,57 +7382,57 @@
 ["<p>[foobar]</p>",
 	[["formatblock","<header>"]],
 	"<p>[foobar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foobar]</p>",
 	[["formatblock","<head>"]],
 	"<p>[foobar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foobar]</p>",
 	[["formatblock","<hgroup>"]],
 	"<p>[foobar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foobar]</p>",
 	[["formatblock","<hr>"]],
 	"<p>[foobar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foobar]</p>",
 	[["formatblock","<html>"]],
 	"<p>[foobar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foobar]</p>",
 	[["formatblock","<ins>"]],
 	"<p>[foobar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foobar]</p>",
 	[["formatblock","<li>"]],
 	"<p>[foobar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foobar]</p>",
 	[["formatblock","<listing>"]],
 	"<p>[foobar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foobar]</p>",
 	[["formatblock","<menu>"]],
 	"<p>[foobar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foobar]</p>",
 	[["formatblock","<nav>"]],
 	"<p>[foobar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foobar]</p>",
 	[["formatblock","<ol>"]],
 	"<p>[foobar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foobar]</p>",
 	[["formatblock","<p>"]],
@@ -7442,7 +7442,7 @@
 ["<p>[foobar]</p>",
 	[["formatblock","<plaintext>"]],
 	"<p>[foobar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foobar]</p>",
 	[["defaultparagraphseparator","div"],["formatblock","<pre>"]],
@@ -7457,22 +7457,22 @@
 ["<p>[foobar]</p>",
 	[["formatblock","<section>"]],
 	"<p>[foobar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foobar]</p>",
 	[["formatblock","<ul>"]],
 	"<p>[foobar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foobar]</p>",
 	[["formatblock","<xmp>"]],
 	"<p>[foobar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foobar]</p>",
 	[["formatblock","<quasit>"]],
 	"<p>[foobar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foo<p>bar]",
 	[["defaultparagraphseparator","div"],["formatblock","<address>"]],
@@ -7487,22 +7487,22 @@
 ["<p>[foo<p>bar]",
 	[["formatblock","<article>"]],
 	"<p>[foo</p><p>bar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foo<p>bar]",
 	[["formatblock","<aside>"]],
 	"<p>[foo</p><p>bar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foo<p>bar]",
 	[["formatblock","<blockquote>"]],
 	"<p>[foo</p><p>bar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foo<p>bar]",
 	[["formatblock","<body>"]],
 	"<p>[foo</p><p>bar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foo<p>bar]",
 	[["defaultparagraphseparator","div"],["formatblock","<dd>"]],
@@ -7517,17 +7517,17 @@
 ["<p>[foo<p>bar]",
 	[["formatblock","<del>"]],
 	"<p>[foo</p><p>bar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foo<p>bar]",
 	[["formatblock","<details>"]],
 	"<p>[foo</p><p>bar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foo<p>bar]",
 	[["formatblock","<dir>"]],
 	"<p>[foo</p><p>bar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foo<p>bar]",
 	[["defaultparagraphseparator","div"],["formatblock","<div>"]],
@@ -7542,7 +7542,7 @@
 ["<p>[foo<p>bar]",
 	[["formatblock","<dl>"]],
 	"<p>[foo</p><p>bar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foo<p>bar]",
 	[["defaultparagraphseparator","div"],["formatblock","<dt>"]],
@@ -7557,27 +7557,27 @@
 ["<p>[foo<p>bar]",
 	[["formatblock","<fieldset>"]],
 	"<p>[foo</p><p>bar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foo<p>bar]",
 	[["formatblock","<figcaption>"]],
 	"<p>[foo</p><p>bar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foo<p>bar]",
 	[["formatblock","<figure>"]],
 	"<p>[foo</p><p>bar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foo<p>bar]",
 	[["formatblock","<footer>"]],
 	"<p>[foo</p><p>bar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foo<p>bar]",
 	[["formatblock","<form>"]],
 	"<p>[foo</p><p>bar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foo<p>bar]",
 	[["defaultparagraphseparator","div"],["formatblock","<h1>"]],
@@ -7642,57 +7642,57 @@
 ["<p>[foo<p>bar]",
 	[["formatblock","<header>"]],
 	"<p>[foo</p><p>bar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foo<p>bar]",
 	[["formatblock","<head>"]],
 	"<p>[foo</p><p>bar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foo<p>bar]",
 	[["formatblock","<hgroup>"]],
 	"<p>[foo</p><p>bar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foo<p>bar]",
 	[["formatblock","<hr>"]],
 	"<p>[foo</p><p>bar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foo<p>bar]",
 	[["formatblock","<html>"]],
 	"<p>[foo</p><p>bar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foo<p>bar]",
 	[["formatblock","<ins>"]],
 	"<p>[foo</p><p>bar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foo<p>bar]",
 	[["formatblock","<li>"]],
 	"<p>[foo</p><p>bar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foo<p>bar]",
 	[["formatblock","<listing>"]],
 	"<p>[foo</p><p>bar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foo<p>bar]",
 	[["formatblock","<menu>"]],
 	"<p>[foo</p><p>bar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foo<p>bar]",
 	[["formatblock","<nav>"]],
 	"<p>[foo</p><p>bar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foo<p>bar]",
 	[["formatblock","<ol>"]],
 	"<p>[foo</p><p>bar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foo<p>bar]",
 	[["formatblock","<p>"]],
@@ -7702,7 +7702,7 @@
 ["<p>[foo<p>bar]",
 	[["formatblock","<plaintext>"]],
 	"<p>[foo</p><p>bar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foo<p>bar]",
 	[["defaultparagraphseparator","div"],["formatblock","<pre>"]],
@@ -7717,22 +7717,22 @@
 ["<p>[foo<p>bar]",
 	[["formatblock","<section>"]],
 	"<p>[foo</p><p>bar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foo<p>bar]",
 	[["formatblock","<ul>"]],
 	"<p>[foo</p><p>bar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foo<p>bar]",
 	[["formatblock","<xmp>"]],
 	"<p>[foo</p><p>bar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<p>[foo<p>bar]",
 	[["formatblock","<quasit>"]],
 	"<p>[foo</p><p>bar]</p>",
-	[true],
+	[false],
 	{"formatblock":[false,false,"p",false,false,"p"]}],
 ["<div>[foobar]</div>",
 	[["defaultparagraphseparator","div"],["formatblock","p"]],
@@ -12742,7 +12742,7 @@
 ["foo[bar]baz",
 	[["insertimage",""]],
 	"foo[bar]baz",
-	[true],
+	[false],
 	{"insertimage":[false,false,"",false,false,""]}],
 ["foo[bar]baz",
 	[["insertimage","/img/lion.svg"]],
@@ -27432,7 +27432,7 @@
 ["foo[bar]baz",
 	[["defaultparagraphseparator",""]],
 	"foo[bar]baz",
-	[true],
+	[false],
 	{"defaultparagraphseparator":[false,false,"p",false,false,"div"]}],
 ["foo[bar]baz",
 	[["defaultparagraphseparator","div"]],
@@ -27457,22 +27457,32 @@
 ["foo[bar]baz",
 	[["defaultparagraphseparator"," div "]],
 	"foo[bar]baz",
-	[true],
+	[false],
 	{"defaultparagraphseparator":[false,false,"p",false,false,"div"]}],
 ["foo[bar]baz",
 	[["defaultparagraphseparator"," p "]],
 	"foo[bar]baz",
-	[true],
+	[false],
+	{"defaultparagraphseparator":[false,false,"p",false,false,"div"]}],
+["foo[bar]baz",
+	[["defaultparagraphseparator","<div>"]],
+	"foo[bar]baz",
+	[false],
+	{"defaultparagraphseparator":[false,false,"p",false,false,"div"]}],
+["foo[bar]baz",
+	[["defaultparagraphseparator","<p>"]],
+	"foo[bar]baz",
+	[false],
 	{"defaultparagraphseparator":[false,false,"p",false,false,"div"]}],
 ["foo[bar]baz",
 	[["defaultparagraphseparator","li"]],
 	"foo[bar]baz",
-	[true],
+	[false],
 	{"defaultparagraphseparator":[false,false,"p",false,false,"div"]}],
 ["foo[bar]baz",
 	[["defaultparagraphseparator","blockquote"]],
 	"foo[bar]baz",
-	[true],
+	[false],
 	{"defaultparagraphseparator":[false,false,"p",false,false,"div"]}],
 ["foo[bar]baz",
 	[["selectall",""]],
--- a/editing.html	Fri May 18 06:13:37 2012 -0600
+++ b/editing.html	Sun May 20 06:30:28 2012 -0600
@@ -68,7 +68,7 @@
 <div class=head id=head>
 <p><a href=http://www.w3.org/><img alt=W3C height=48 src=http://www.w3.org/Icons/w3c_home width=72></a></p>
 <h1>HTML Editing APIs</h1>
-<h2 class="no-num no-toc" id=work-in-progress-&mdash;-last-update-17-may-2012>Work in Progress &mdash; Last Update 17 May 2012</h2>
+<h2 class="no-num no-toc" id=work-in-progress-&mdash;-last-update-20-may-2012>Work in Progress &mdash; Last Update 20 May 2012</h2>
 <dl>
  <dt>Editor
  <dd>Aryeh Gregor &lt;<a href=mailto:[email protected]>[email protected]</a>&gt;
@@ -1292,7 +1292,8 @@
   bold if the selection is already bold.  An editing toolbar might provide
   buttons that execute the <a href=#action>action</a> for a <a href=#command>command</a> if
   clicked, or a script might run an <a href=#action>action</a> without user
-  interaction to achieve some particular effect.
+  interaction to achieve some particular effect.  Actions return either true or
+  false, which can affect the return value of <code><a href=#execcommand()>execCommand()</a></code>.
 
   <li><dfn id=indeterminate>Indeterminate</dfn>: A boolean value returned by
   <code><a href=#querycommandindeterm()>queryCommandIndeterm()</a></code>, depending on the current state of the
@@ -1577,6 +1578,8 @@
   <li>Take the <a href=#action>action</a> for <var title="">command</var>, passing
   <var title="">value</var> to the instructions as an argument.
 
+  <li>If the previous step returned false, return false.
+
   <li>If <var title="">command</var> is not in the
   <a href=#miscellaneous-commands>Miscellaneous commands</a> section, then
   <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-event-dispatch title=concept-event-dispatch>dispatch</a> an <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-event title=concept-event>event</a> at <var title="">affected editing host</var> that uses the
@@ -3827,9 +3830,11 @@
   <li>If <var title="">value</var> is not a valid CSS color, prepend "#" to it.
 
   <li>If <var title="">value</var> is still not a valid CSS color, or if it is
-  currentColor, abort these steps and do nothing.
+  currentColor, return false.
 
   <li><a href="#set-the-selection's-value">Set the selection's value</a> to <var title="">value</var>.
+
+  <li>Return true.
 </ol>
 
 <p><a href=#standard-inline-value-command>Standard inline value command</a>
@@ -3852,7 +3857,7 @@
 
 <p><a href=#action>Action</a>: If <code title=queryCommandState()><a href=#querycommandstate()>queryCommandState("bold")</a></code> returns true,
 <a href="#set-the-selection's-value">set the selection's value</a> to "normal".  Otherwise <a href="#set-the-selection's-value">set the
-selection's value</a> to "bold".
+selection's value</a> to "bold".  Either way, return true.
 
 <div class=comments>
 <p>The cutoff of 600 matches Chrome 14 dev.  The cutoff used by IE9 and Firefox
@@ -3908,8 +3913,7 @@
   really want to, they can always specify "#" for the value, or the author can
   rewrite it, so it's not like this makes the API less useful.
 
-  <p>If <var title="">value</var> is the empty string, abort these steps and do
-  nothing.
+  <p>If <var title="">value</var> is the empty string, return false.
 
   <li>
   <div class=comments>
@@ -3942,6 +3946,8 @@
   <code class=external data-anolis-spec=html title=attr-hyperlink-href><a href=http://www.whatwg.org/specs/web-apps/current-work/multipage/links.html#attr-hyperlink-href>href</a></code> attribute to <var title="">value</var>.
 
   <li><a href="#set-the-selection's-value">Set the selection's value</a> to <var title="">value</var>.
+
+  <li>Return true.
 </ol>
 
 
@@ -3980,7 +3986,7 @@
 </div>
 
 <p><a href=#action>Action</a>: <a href="#set-the-selection's-value">Set the selection's value</a> to
-<var title="">value</var>.
+<var title="">value</var>, then return true.
 
 <div class=comments>
 <p>The value is complicated.
@@ -4067,7 +4073,7 @@
   <li>If <var title="">value</var> is not a <a class=external data-anolis-spec=html href=http://www.whatwg.org/specs/web-apps/current-work/multipage/common-microsyntaxes.html#valid-floating-point-number>valid floating
   point number</a>, and would not be a <a class=external data-anolis-spec=html href=http://www.whatwg.org/specs/web-apps/current-work/multipage/common-microsyntaxes.html#valid-floating-point-number>valid
   floating point number</a> if a single leading "+" character were stripped,
-  abort these steps and do nothing.
+  return false.
 
   <li>If the first character of <var title="">value</var> is "+", delete the character
   and let <var title="">mode</var> be "relative-plus".
@@ -4112,6 +4118,8 @@
   </ul>
 
   <li><a href="#set-the-selection's-value">Set the selection's value</a> to <var title="">value</var>.
+
+  <li>Return true.
 </ol>
 
 <p class=comments>This follows Firefox 6.0a2.  Chrome 14 dev always returns
@@ -4295,9 +4303,11 @@
   sizes.  It will confuse the algorithm, and doesn't seem very useful anyway.
 
   <p>If <var title="">value</var> is still not a valid CSS color, or if it is
-  currentColor, abort these steps and do nothing.
+  currentColor, return false.
 
   <li><a href="#set-the-selection's-value">Set the selection's value</a> to <var title="">value</var>.
+
+  <li>Return true.
 </ol>
 
 <div class=comments>
@@ -4362,9 +4372,11 @@
   confuse the algorithm, so ban it for now anyway.
 
   <p>If <var title="">value</var> is still not a valid CSS color, or if it is
-  currentColor, abort these steps and do nothing.
+  currentColor, return false.
 
   <li><a href="#set-the-selection's-value">Set the selection's value</a> to <var title="">value</var>.
+
+  <li>Return true.
 </ol>
 
 <p class=comments>For indeterminacy, this follows no one.  Firefox 6.0a2 and
@@ -4384,7 +4396,7 @@
 
 <p><a href=#action>Action</a>: If <code title=queryCommandState()><a href=#querycommandstate()>queryCommandState("italic")</a></code> returns true,
 <a href="#set-the-selection's-value">set the selection's value</a> to "normal".  Otherwise <a href="#set-the-selection's-value">set the
-selection's value</a> to "italic".
+selection's value</a> to "italic".  Either way, return true.
 
 <p><a href=#inline-command-activated-values>Inline command activated values</a>: "italic" or "oblique"
 
@@ -4534,6 +4546,8 @@
     <li>strikethrough
     <li>underline
   </ol>
+
+  <li>Return true.
 </ol>
 
 
@@ -4543,7 +4557,7 @@
 
 <p><a href=#action>Action</a>: If <code title=queryCommandState()><a href=#querycommandstate()>queryCommandState("strikethrough")</a></code> returns
 true, <a href="#set-the-selection's-value">set the selection's value</a> to null.  Otherwise <a href="#set-the-selection's-value">set the
-selection's value</a> to "line-through".
+selection's value</a> to "line-through".  Either way, return true.
 
 <p><a href=#inline-command-activated-values>Inline command activated values</a>: "line-through"
 
@@ -4560,6 +4574,8 @@
 
   <li>If <var title="">state</var> is false, <a href="#set-the-selection's-value">set the selection's value</a> to
   "subscript".
+
+  <li>Return true.
 </ol>
 
 <p><a href=#indeterminate>Indeterminate</a>: True if either among <a href=#formattable-node title="formattable
@@ -4596,6 +4612,8 @@
 
   <li>If <var title="">state</var> is false, <a href="#set-the-selection's-value">set the selection's value</a> to
   "superscript".
+
+  <li>Return true.
 </ol>
 
 <p><a href=#indeterminate>Indeterminate</a>: True if either among <a href=#formattable-node title="formattable
@@ -4660,7 +4678,7 @@
 
 <p><a href=#action>Action</a>: If <code title=queryCommandState()><a href=#querycommandstate()>queryCommandState("underline")</a></code> returns true,
 <a href="#set-the-selection's-value">set the selection's value</a> to null.  Otherwise <a href="#set-the-selection's-value">set the
-selection's value</a> to "underline".
+selection's value</a> to "underline".  Either way, return true.
 
 <p><a href=#inline-command-activated-values>Inline command activated values</a>: "underline"
 
@@ -4687,6 +4705,8 @@
   is an <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-tree-ancestor title=concept-tree-ancestor>ancestor</a> of one of its <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-range-bp title=concept-range-bp>boundary points</a>.
 
   <li><a href=#clear-the-value>Clear the value</a> of each member of <var title="">hyperlinks</var>.
+
+  <li>Return true.
 </ol>
 
 
@@ -7827,7 +7847,7 @@
 
 <ol>
   <li>If the <a href=#active-range>active range</a> is not <code class=external data-anolis-spec=dom title=dom-Range-collapsed><a href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#dom-range-collapsed>collapsed</a></code>, <a href=#delete-the-selection>delete
-  the selection</a> and abort these steps.
+  the selection</a> and return true.
 
   <li>
   <p class=comments>Needed so that if there are multiple consecutive spaces we
@@ -7878,7 +7898,7 @@
     <p>Otherwise, if <var title="">node</var> has a <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-tree-child title=concept-tree-child>child</a> with <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-tree-index title=concept-tree-index>index</a>
     <var title="">offset</var> &minus; 1 and that <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-tree-child title=concept-tree-child>child</a> is an <a href=#editable>editable</a>
     <code class=external data-anolis-spec=html title="the a element"><a href=http://www.whatwg.org/specs/web-apps/current-work/multipage/text-level-semantics.html#the-a-element>a</a></code>, remove that <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-tree-child title=concept-tree-child>child</a> from <var title="">node</var>, <a href=#preserving-its-descendants>preserving its
-    descendants</a>.  Then abort these steps.
+    descendants</a>.  Then return true.
 
     <li>Otherwise, if <var title="">node</var> has a <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-tree-child title=concept-tree-child>child</a> with <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-tree-index title=concept-tree-index>index</a>
     <var title="">offset</var> &minus; 1 and that <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-tree-child title=concept-tree-child>child</a> is not a <a href=#block-node>block
@@ -7930,14 +7950,14 @@
 
     <li><a href=#delete-the-selection>Delete the selection</a>.
 
-    <li>Abort these steps.
+    <li>Return true.
   </ol>
 
   <li>
   <p class=comments>At the time of this writing, this should be impossible.
   Just being safe.
 
-  <p>If <var title="">node</var> is an <a href=#inline-node>inline node</a>, abort these steps.
+  <p>If <var title="">node</var> is an <a href=#inline-node>inline node</a>, return true.
 
   <li>
   <p class=comments> If we're at the beginning of a list, we want to outdent
@@ -7978,7 +7998,7 @@
 
     <li><a href=#fix-disallowed-ancestors>Fix disallowed ancestors</a> of <var title="">node</var>.
 
-    <li>Abort these steps.
+    <li>Return true.
   </ol>
 
   <li>
@@ -8027,7 +8047,7 @@
 
     <li><a href=#outdent>Outdent</a> each <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-node title=concept-node>node</a> in <var title="">node list</var>.
 
-    <li>Abort these steps.
+    <li>Return true.
   </ol>
 
   <li>
@@ -8040,7 +8060,7 @@
   </div>
 
   <p>If the <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-tree-child title=concept-tree-child>child</a> of <var title="">start node</var> with <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-tree-index title=concept-tree-index>index</a> <var title="">start
-  offset</var> is a <code class=external data-anolis-spec=html title="the table element"><a href=http://www.whatwg.org/specs/web-apps/current-work/multipage/tabular-data.html#the-table-element>table</a></code>, abort these steps.
+  offset</var> is a <code class=external data-anolis-spec=html title="the table element"><a href=http://www.whatwg.org/specs/web-apps/current-work/multipage/tabular-data.html#the-table-element>table</a></code>, return true.
 
   <li>
   <p class=comments>If you try backspacing into a table, select it.  This
@@ -8058,7 +8078,7 @@
     <li>Call <code title=dom-Selection-extend><a href=#dom-selection-extend>extend(<var title="">start node</var>, <var title="">start offset</var>)</a></code> on the
     <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#context-object>context object</a>'s <a href=#concept-selection title=concept-selection>selection</a>.
 
-    <li>Abort these steps.
+    <li>Return true.
   </ol>
 
   <li>
@@ -8094,7 +8114,7 @@
     <li>Call <code title=dom-Selection-collapse><a href=#dom-selection-collapse>collapse(<var title="">node</var>, <var title="">offset</var>)</a></code> on the
     <a href=#concept-selection title=concept-selection>selection</a>.
 
-    <li>Abort these steps.
+    <li>Return true.
   </ol>
 
   <li>
@@ -8177,7 +8197,7 @@
     <li>Call <code title=dom-Selection-addRange><a href=#dom-selection-addrange>addRange(<var title="">original range</var>)</a></code> on the <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#context-object>context object</a>'s
     <a href=#concept-selection title=concept-selection>selection</a>.
 
-    <li>Abort these steps.
+    <li>Return true.
   </ol>
 
   <li>
@@ -8204,6 +8224,8 @@
   <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#context-object>context object</a>'s <a href=#concept-selection title=concept-selection>selection</a>.
 
   <li><a href=#delete-the-selection>Delete the selection</a>, with <var title="">direction</var> "backward".
+
+  <li>Return true.
 </ol>
 
 
@@ -8299,8 +8321,8 @@
   list discussion</a> on the subject.
   </div>
 
-  <p>If <var title="">value</var> is not a <a href=#formattable-block-name>formattable block name</a>, abort
-  these steps and do nothing.
+  <p>If <var title="">value</var> is not a <a href=#formattable-block-name>formattable block name</a>, return
+  false.
 
   <li><a href=#block-extend>Block-extend</a> the <a href=#active-range>active range</a>, and let <var title="">new
   range</var> be the result.
@@ -8438,6 +8460,8 @@
     <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#context-object>context object</a>.  Then <a href=#fix-disallowed-ancestors>fix disallowed ancestors</a> of the
     result.
   </ol>
+
+  <li>Return true.
 </ol>
 
 <p class=comments>Firefox 6.0a2 throws, Chrome 14 dev always returns false,
@@ -8564,7 +8588,7 @@
 
 <ol>
   <li>If the <a href=#active-range>active range</a> is not <code class=external data-anolis-spec=dom title=dom-Range-collapsed><a href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#dom-range-collapsed>collapsed</a></code>, <a href=#delete-the-selection>delete
-  the selection</a> and abort these steps.
+  the selection</a> and return true.
 
   <li><a href=#canonicalize-whitespace>Canonicalize whitespace</a> at the <a href=#active-range>active range</a>'s
   <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-range-start title=concept-range-start>start</a>.
@@ -8645,10 +8669,10 @@
 
     <li><a href=#delete-the-selection>Delete the selection</a>.
 
-    <li>Abort these steps.
-  </ol>
-
-  <li>If <var title="">node</var> is an <a href=#inline-node>inline node</a>, abort these steps.
+    <li>Return true.
+  </ol>
+
+  <li>If <var title="">node</var> is an <a href=#inline-node>inline node</a>, return true.
 
   <li>If <var title="">node</var> has a <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-tree-child title=concept-tree-child>child</a> with <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-tree-index title=concept-tree-index>index</a> <var title="">offset</var> and
   that <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-tree-child title=concept-tree-child>child</a> is a <code class=external data-anolis-spec=html title="the br element"><a href=http://www.whatwg.org/specs/web-apps/current-work/multipage/text-level-semantics.html#the-br-element>br</a></code> or <code class=external data-anolis-spec=html title="the hr element"><a href=http://www.whatwg.org/specs/web-apps/current-work/multipage/grouping-content.html#the-hr-element>hr</a></code> or <code class=external data-anolis-spec=html title="the img element"><a href=http://www.whatwg.org/specs/web-apps/current-work/multipage/embedded-content-1.html#the-img-element>img</a></code>, but is not a
@@ -8663,7 +8687,7 @@
 
     <li><a href=#delete-the-selection>Delete the selection</a>.
 
-    <li>Abort these steps.
+    <li>Return true.
   </ol>
 
   <li>
@@ -8696,7 +8720,7 @@
   here, unlike delete.
 
   <p>If the <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-tree-child title=concept-tree-child>child</a> of <var title="">end node</var> with <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-tree-index title=concept-tree-index>index</a> <var title="">end
-  offset</var> minus one is a <code class=external data-anolis-spec=html title="the table element"><a href=http://www.whatwg.org/specs/web-apps/current-work/multipage/tabular-data.html#the-table-element>table</a></code>, abort these steps.
+  offset</var> minus one is a <code class=external data-anolis-spec=html title="the table element"><a href=http://www.whatwg.org/specs/web-apps/current-work/multipage/tabular-data.html#the-table-element>table</a></code>, return true.
 
   <li>If the <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-tree-child title=concept-tree-child>child</a> of <var title="">end node</var> with <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-tree-index title=concept-tree-index>index</a> <var title="">end
   offset</var> is a <code class=external data-anolis-spec=html title="the table element"><a href=http://www.whatwg.org/specs/web-apps/current-work/multipage/tabular-data.html#the-table-element>table</a></code>:
@@ -8708,7 +8732,7 @@
     <li>Call <code title=dom-Selection-extend><a href=#dom-selection-extend>extend(<var title="">end node</var>, <var title="">end offset</var> + 1)</a></code> on the
     <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#context-object>context object</a>'s <a href=#concept-selection title=concept-selection>selection</a>.
 
-    <li>Abort these steps.
+    <li>Return true.
   </ol>
 
   <li>
@@ -8731,7 +8755,7 @@
     <li>Call <code title=dom-Selection-collapse><a href=#dom-selection-collapse>collapse(<var title="">node</var>, <var title="">offset</var>)</a></code> on the
     <a href=#concept-selection title=concept-selection>selection</a>.
 
-    <li>Abort these steps.
+    <li>Return true.
   </ol>
 
   <li>
@@ -8917,7 +8941,7 @@
   <li><a href=#delete-the-selection>Delete the selection</a>, with <var title="">block merging</var> false.
 
   <li>If the <a href=#active-range>active range</a>'s <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-range-start-node title=concept-range-start-node>start node</a> is neither
-  <a href=#editable>editable</a> nor an <a href=#editing-host>editing host</a>, abort these steps.
+  <a href=#editable>editable</a> nor an <a href=#editing-host>editing host</a>, return true.
 
   <li>
   <p class=comments>We don't want to call insertNode at the start or end of a
@@ -8955,6 +8979,8 @@
   <li>Run <code title=dom-Selection-collapse><a href=#dom-selection-collapse>collapse()</a></code> on the <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#context-object>context object</a>'s <a href=#concept-selection title=concept-selection>selection</a>, with first
   argument <var title="">hr</var>'s <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-tree-parent title=concept-tree-parent>parent</a> and the second argument equal to one plus
   <var title="">hr</var>'s <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-tree-index title=concept-tree-index>index</a>.
+
+  <li>Return true.
 </ol>
 
 
@@ -9014,7 +9040,7 @@
   <p><a href=#delete-the-selection>Delete the selection</a>.
 
   <li>If the <a href=#active-range>active range</a>'s <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-range-start-node title=concept-range-start-node>start node</a> is neither
-  <a href=#editable>editable</a> nor an <a href=#editing-host>editing host</a>, abort these steps.
+  <a href=#editable>editable</a> nor an <a href=#editing-host>editing host</a>, return true.
 
   <li>
   <p class=comments>TODO: This has some interesting consequences.  For
@@ -9032,7 +9058,7 @@
   <p class=comments>Firefox 5.0a2 also seems to not add empty elements like
   &lt;b&gt;&lt;/b&gt;, but Chrome 13 dev and Opera 11.11 do.
 
-  <p>If <var title="">last child</var> is null, abort these steps.
+  <p>If <var title="">last child</var> is null, return true.
 
   <li>Let <var title="">descendants</var> be all <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-tree-descendant title=concept-tree-descendant>descendants</a> of <var title="">frag</var>.
 
@@ -9095,6 +9121,8 @@
 
   <p><a href=#fix-disallowed-ancestors>Fix disallowed ancestors</a> of each member of
   <var title="">descendants</var>.
+
+  <li>Return true.
 </ol>
 
 
@@ -9113,8 +9141,7 @@
   nothing on an empty string, but the other three browsers I tested stick in
   the &lt;img&gt; anyway.
 
-  <p>If <var title="">value</var> is the empty string, abort these steps and do
-  nothing.
+  <p>If <var title="">value</var> is the empty string, return false.
 
   <li>
   <p class=comments>Firefox 7.0a2 seems to strip the wrapper or not depending
@@ -9130,7 +9157,7 @@
   <li>Let <var title="">range</var> be the <a href=#active-range>active range</a>.
 
   <li>If the <a href=#active-range>active range</a>'s <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-range-start-node title=concept-range-start-node>start node</a> is neither
-  <a href=#editable>editable</a> nor an <a href=#editing-host>editing host</a>, abort these steps.
+  <a href=#editable>editable</a> nor an <a href=#editing-host>editing host</a>, return true.
 
   <li>
   <p class=comments>Same logic as with insertHTML.
@@ -9162,6 +9189,8 @@
   <li>Run <code title=dom-Selection-collapse><a href=#dom-selection-collapse>collapse()</a></code> on <var title="">selection</var>, with first argument equal
   to the <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-tree-parent title=concept-tree-parent>parent</a> of <var title="">img</var> and the second argument equal to one plus
   the <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-tree-index title=concept-tree-index>index</a> of <var title="">img</var>.
+
+  <li>Return true.
 </ol>
 
 
@@ -9202,17 +9231,17 @@
   <p><a href=#delete-the-selection>Delete the selection</a>, with <var title="">strip wrappers</var> false.
 
   <li>If the <a href=#active-range>active range</a>'s <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-range-start-node title=concept-range-start-node>start node</a> is neither
-  <a href=#editable>editable</a> nor an <a href=#editing-host>editing host</a>, abort these steps.
+  <a href=#editable>editable</a> nor an <a href=#editing-host>editing host</a>, return true.
 
   <li>
   <p class=comments>script, xmp, table, . . .
 
   <p>If the <a href=#active-range>active range</a>'s <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-range-start-node title=concept-range-start-node>start node</a> is an <code class=external data-anolis-spec=dom><a href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#element>Element</a></code>, and
-  "br" is not an <a href=#allowed-child>allowed child</a> of it, abort these steps.
+  "br" is not an <a href=#allowed-child>allowed child</a> of it, return true.
 
   <li>If the <a href=#active-range>active range</a>'s <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-range-start-node title=concept-range-start-node>start node</a> is not an <code class=external data-anolis-spec=dom><a href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#element>Element</a></code>,
   and "br" is not an <a href=#allowed-child>allowed child</a> of the <a href=#active-range>active
-  range</a>'s <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-range-start-node title=concept-range-start-node>start node</a>'s <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-tree-parent title=concept-tree-parent>parent</a>, abort these steps.
+  range</a>'s <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-range-start-node title=concept-range-start-node>start node</a>'s <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-tree-parent title=concept-tree-parent>parent</a>, return true.
 
   <li>
   <p class=comments>We don't want to call insertNode at the start or end of a
@@ -9244,6 +9273,8 @@
   <code class=external data-anolis-spec=dom title=dom-Document-createElement><a href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#dom-document-createelement>createElement("br")</a></code> on the <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#context-object>context object</a> and let <var title="">extra br</var>
   be the result, then call <code class=external data-anolis-spec=dom title=dom-Range-insertNode><a href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#dom-range-insertnode>insertNode(<var title="">extra br</var>)</a></code> on the
   <a href=#active-range>active range</a>.
+
+  <li>Return true.
 </ol>
 
 
@@ -9252,7 +9283,7 @@
 <p><a href=#preserves-overrides>Preserves overrides</a>
 
 <p><a href=#action>Action</a>: <a href=#toggle-lists>Toggle lists</a> with <var title="">tag name</var>
-"ol".
+"ol", then return true.
 
 <p class=comments>Firefox 6.0a2 sort of supports this, but it throws exceptions
 most of the time.  It has the quirk that even if there are no ol's around, it
@@ -9334,7 +9365,7 @@
   <li><a href=#delete-the-selection>Delete the selection</a>.
 
   <li>If the <a href=#active-range>active range</a>'s <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-range-start-node title=concept-range-start-node>start node</a> is neither
-  <a href=#editable>editable</a> nor an <a href=#editing-host>editing host</a>, abort these steps.
+  <a href=#editable>editable</a> nor an <a href=#editing-host>editing host</a>, return true.
 
   <li>Let <var title="">node</var> and <var title="">offset</var> be the <a href=#active-range>active
   range</a>'s <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-range-start title=concept-range-start>start</a> <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-node title=concept-node>node</a> and <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-range-bp-offset title=concept-range-bp-offset>offset</a>.
@@ -9410,7 +9441,7 @@
       case where deleting can leave the cursor inside a &lt;tr&gt;.
 
       <p>If <var title="">tag</var> is not an <a href=#allowed-child>allowed child</a> of
-      the <a href=#active-range>active range</a>'s <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-range-start-node title=concept-range-start-node>start node</a>, abort these steps.
+      the <a href=#active-range>active range</a>'s <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-range-start-node title=concept-range-start-node>start node</a>, return true.
 
       <li>Set <var title="">container</var> to the result of calling
       <code class=external data-anolis-spec=dom title=dom-Document-createElement><a href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#dom-document-createelement>createElement(<var title="">tag</var>)</a></code> on the <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#context-object>context object</a>.
@@ -9424,7 +9455,7 @@
       <li>Call <code title=dom-Selection-collapse><a href=#dom-selection-collapse>collapse(<var title="">container</var>, 0)</a></code> on the
       <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#context-object>context object</a>'s <a href=#concept-selection title=concept-selection>selection</a>.
 
-      <li>Abort these steps.
+      <li>Return true.
     </ol>
 
     <li>
@@ -9486,7 +9517,7 @@
     <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#context-object>context object</a>, then call <code class=external data-anolis-spec=dom title=dom-Range-insertNode><a href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#dom-range-insertnode>insertNode(<var title="">br</var>)</a></code> on
     the <a href=#active-range>active range</a>.
 
-    <li>Abort these steps.
+    <li>Return true.
   </ol>
 
   <li>
@@ -9519,7 +9550,7 @@
 
     <li><a href=#fix-disallowed-ancestors>Fix disallowed ancestors</a> of <var title="">container</var>.
 
-    <li>Abort these steps.
+    <li>Return true.
   </ol>
 
   <li>Let <var title="">new line range</var> be a new <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-range title=concept-range>range</a> whose <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-range-start title=concept-range-start>start</a> is
@@ -9626,6 +9657,8 @@
 
   <li>Call <code title=dom-Selection-collapse><a href=#dom-selection-collapse>collapse(<var title="">new container</var>, 0)</a></code> on the
   <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#context-object>context object</a>'s <a href=#concept-selection title=concept-selection>selection</a>.
+
+  <li>Return true.
 </ol>
 
 
@@ -9769,7 +9802,7 @@
   <p><a href=#delete-the-selection>Delete the selection</a>, with <var title="">strip wrappers</var> false.
 
   <li>If the <a href=#active-range>active range</a>'s <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-range-start-node title=concept-range-start-node>start node</a> is neither
-  <a href=#editable>editable</a> nor an <a href=#editing-host>editing host</a>, abort these steps.
+  <a href=#editable>editable</a> nor an <a href=#editing-host>editing host</a>, return true.
 
   <li>If <var title="">value</var>'s <a href=http://es5.github.com/#x15.5.5.1>length</a> is greater than one:
 
@@ -9778,18 +9811,18 @@
     <a href=#action>action</a> for <a href=#the-inserttext-command>the <code title="">insertText</code>
     command</a>, with <var title="">value</var> equal to <var title="">el</var>.
 
-    <li>Abort these steps.
-  </ol>
-
-  <li>If <var title="">value</var> is the empty string, abort these steps.
+    <li>Return true.
+  </ol>
+
+  <li>If <var title="">value</var> is the empty string, return true.
 
   <li>
   <p class=comments>TODO: WebKit also does magic for tabs, wrapping them in a
   whitespace-preserving span.  Should we?
 
   <p>If <var title="">value</var> is a newline (U+00A0), take the <a href=#action>action</a>
-  for <a href=#the-insertparagraph-command>the <code title="">insertParagraph</code> command</a> and abort
-  these steps.
+  for <a href=#the-insertparagraph-command>the <code title="">insertParagraph</code> command</a> and return
+  true.
 
   <li>Let <var title="">node</var> and <var title="">offset</var> be the <a href=#active-range>active
   range</a>'s <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-range-start-node title=concept-range-start-node>start node</a> and <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-range-bp-offset title=concept-range-bp-offset>offset</a>.
@@ -9870,6 +9903,8 @@
   <a href=#active-range>active range</a>'s <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-range-start title=concept-range-start>start</a>.
 
   <li>Call <code title=dom-Selection-collapseToEnd><a href=#dom-selection-collapsetoend>collapseToEnd()</a></code> on the <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#context-object>context object</a>'s <a href=#concept-selection title=concept-selection>selection</a>.
+
+  <li>Return true.
 </ol>
 
 
@@ -9880,7 +9915,7 @@
 <p class=comments>See comments for <a href=#the-insertorderedlist-command>insertOrderedList</a>.
 
 <p><a href=#action>Action</a>: <a href=#toggle-lists>Toggle lists</a> with <var title="">tag name</var>
-"ul".
+"ul", then return true.
 
 <p><a href=#indeterminate>Indeterminate</a>: True if the <a href="#selection's-list-state">selection's list state</a>
 is "mixed" or "mixed ul", false otherwise.
@@ -9894,7 +9929,7 @@
 <p><a href=#preserves-overrides>Preserves overrides</a>
 
 <p><a href=#action>Action</a>: <a href=#justify-the-selection>Justify the selection</a> with
-<var title="">alignment</var> "center".
+<var title="">alignment</var> "center", then return true.
 
 <div class=comments>
 <p>This roughly matches Chrome 14 dev, although not exactly.  Firefox 6.0a2
@@ -9966,7 +10001,7 @@
 <p><a href=#preserves-overrides>Preserves overrides</a>
 
 <p><a href=#action>Action</a>: <a href=#justify-the-selection>Justify the selection</a> with
-<var title="">alignment</var> "justify".
+<var title="">alignment</var> "justify", then return true.
 
 <p><a href=#indeterminate>Indeterminate</a>: Return false if the <a href=#active-range>active range</a> is
 null.  Otherwise, <a href=#block-extend>block-extend</a> the <a href=#active-range>active range</a>.
@@ -9994,7 +10029,7 @@
 <p><a href=#preserves-overrides>Preserves overrides</a>
 
 <p><a href=#action>Action</a>: <a href=#justify-the-selection>Justify the selection</a> with
-<var title="">alignment</var> "left".
+<var title="">alignment</var> "left", then return true.
 
 <p><a href=#indeterminate>Indeterminate</a>: Return false if the <a href=#active-range>active range</a> is
 null.  Otherwise, <a href=#block-extend>block-extend</a> the <a href=#active-range>active range</a>.
@@ -10022,7 +10057,7 @@
 <p><a href=#preserves-overrides>Preserves overrides</a>
 
 <p><a href=#action>Action</a>: <a href=#justify-the-selection>Justify the selection</a> with
-<var title="">alignment</var> "right".
+<var title="">alignment</var> "right", then return true.
 
 <p><a href=#indeterminate>Indeterminate</a>: Return false if the <a href=#active-range>active range</a> is
 null.  Otherwise, <a href=#block-extend>block-extend</a> the <a href=#active-range>active range</a>.
@@ -10127,6 +10162,8 @@
 
     <li><a href=#restore-the-values>Restore the values</a> from <var title="">values</var>.
   </ol>
+
+  <li>Return true.
 </ol>
 
 
@@ -10196,8 +10233,8 @@
 <p><a href=#action>Action</a>: Let <var title="">value</var> be
 <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#converted-to-ascii-lowercase>converted to ASCII lowercase</a>.  If
 <var title="">value</var> is then equal to "p" or "div", set the <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#context-object>context object</a>'s
-<a href=#default-single-line-container-name>default single-line container name</a> to <var title="">value</var>.
-Otherwise, do nothing.
+<a href=#default-single-line-container-name>default single-line container name</a> to <var title="">value</var>, then
+return true.  Otherwise, return false.
 
 <p><a href=#value>Value</a>: Return the <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#context-object>context object</a>'s
 <a href=#default-single-line-container-name>default single-line container name</a>.
@@ -10285,6 +10322,8 @@
 
   <li>Otherwise, call <code title=dom-Document-getSelection><a href=#dom-document-getselection>getSelection()</a></code> on the <a class=external data-anolis-spec=dom href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#context-object>context object</a>, and call
   <code title=dom-Selection-selectAllChildren><a href=#dom-selection-selectallchildren>selectAllChildren(<var title="">target</var>)</a></code> on the result.
+
+  <li>Return true.
 </ol>
 
 
@@ -10310,7 +10349,7 @@
 
 <p><a href=#action>Action</a>: If <var title="">value</var> is an <a class=external data-anolis-spec=domcore href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#ascii-case-insensitive>ASCII case-insensitive</a> match for the string
 "false", set the <a href=#css-styling-flag>CSS styling flag</a> to false.  Otherwise, set the
-<a href=#css-styling-flag>CSS styling flag</a> to true.
+<a href=#css-styling-flag>CSS styling flag</a> to true.  Either way, return true.
 
 <p class=comments>This follows Chrome 13 dev.  Firefox 5.0a2 doesn't support
 queryCommandState() for styleWithCSS.
@@ -10340,7 +10379,7 @@
 
 <p><a href=#action>Action</a>: If <var title="">value</var> is an <a class=external data-anolis-spec=domcore href=http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#ascii-case-insensitive>ASCII case-insensitive</a> match for the string
 "false", set the <a href=#css-styling-flag>CSS styling flag</a> to true.  Otherwise, set the
-<a href=#css-styling-flag>CSS styling flag</a> to false.
+<a href=#css-styling-flag>CSS styling flag</a> to false.  Either way, return true.
 
 <p>Since the effect of this command is the opposite of what one would expect,
 user agents are encouraged to point authors to <code title="the stylewithcss
--- a/implementation.js	Fri May 18 06:13:37 2012 -0600
+++ b/implementation.js	Sun May 20 06:30:28 2012 -0600
@@ -543,7 +543,17 @@
 
 		// "Take the action for command, passing value to the instructions as an
 		// argument."
-		commands[command].action(value);
+		var ret = commands[command].action(value);
+
+		// Check for bugs
+		if (ret !== true && ret !== false) {
+			throw "execCommand() didn't return true or false: " + ret;
+		}
+
+		// "If the previous step returned false, return false."
+		if (ret === false) {
+			return false;
+		}
 
 		// "Return true."
 		return true;
@@ -3072,7 +3082,7 @@
 		// "If value is not a valid CSS color, prepend "#" to it."
 		//
 		// "If value is still not a valid CSS color, or if it is currentColor,
-		// abort these steps and do nothing."
+		// return false."
 		//
 		// Cheap hack for testing, no attempt to be comprehensive.
 		if (/^([0-9a-fA-F]{3}){1,2}$/.test(value)) {
@@ -3081,11 +3091,14 @@
 		if (!/^(rgba?|hsla?)\(.*\)$/.test(value)
 		&& !parseSimpleColor(value)
 		&& value.toLowerCase() != "transparent") {
-			return;
+			return false;
 		}
 
 		// "Set the selection's value to value."
 		setSelectionValue("backcolor", value);
+
+		// "Return true."
+		return true;
 	}, standardInlineValueCommand: true, relevantCssProperty: "backgroundColor",
 	equivalentValues: function(val1, val2) {
 		// "Either both strings are valid CSS colors and have the same red,
@@ -3101,12 +3114,14 @@
 commands.bold = {
 	action: function() {
 		// "If queryCommandState("bold") returns true, set the selection's
-		// value to "normal". Otherwise set the selection's value to "bold"."
+		// value to "normal". Otherwise set the selection's value to "bold".
+		// Either way, return true."
 		if (myQueryCommandState("bold")) {
 			setSelectionValue("bold", "normal");
 		} else {
 			setSelectionValue("bold", "bold");
 		}
+		return true;
 	}, inlineCommandActivatedValues: ["bold", "600", "700", "800", "900"],
 	relevantCssProperty: "fontWeight",
 	equivalentValues: function(val1, val2) {
@@ -3125,9 +3140,9 @@
 //@{
 commands.createlink = {
 	action: function(value) {
-		// "If value is the empty string, abort these steps and do nothing."
+		// "If value is the empty string, return false."
 		if (value === "") {
-			return;
+			return false;
 		}
 
 		// "For each editable a element that has an href attribute and is an
@@ -3148,6 +3163,9 @@
 
 		// "Set the selection's value to value."
 		setSelectionValue("createlink", value);
+
+		// "Return true."
+		return true;
 	}
 };
 
@@ -3156,8 +3174,9 @@
 //@{
 commands.fontname = {
 	action: function(value) {
-		// "Set the selection's value to value."
+		// "Set the selection's value to value, then return true."
 		setSelectionValue("fontname", value);
+		return true;
 	}, standardInlineValueCommand: true, relevantCssProperty: "fontFamily"
 };
 
@@ -3176,7 +3195,7 @@
 
 	// "If value is not a valid floating point number, and would not be a valid
 	// floating point number if a single leading "+" character were stripped,
-	// abort these steps and do nothing."
+	// return false."
 	if (!/^[-+]?[0-9]+(\.[0-9]+)?([eE][-+]?[0-9]+)?$/.test(value)) {
 		return null;
 	}
@@ -3242,11 +3261,14 @@
 	action: function(value) {
 		value = normalizeFontSize(value);
 		if (value === null) {
-			return;
+			return false;
 		}
 
 		// "Set the selection's value to value."
 		setSelectionValue("fontsize", value);
+
+		// "Return true."
+		return true;
 	}, indeterm: function() {
 		// "True if among formattable nodes that are effectively contained in
 		// the active range, there are two that have distinct effective command
@@ -3357,7 +3379,7 @@
 		// "If value is not a valid CSS color, prepend "#" to it."
 		//
 		// "If value is still not a valid CSS color, or if it is currentColor,
-		// abort these steps and do nothing."
+		// return false."
 		//
 		// Cheap hack for testing, no attempt to be comprehensive.
 		if (/^([0-9a-fA-F]{3}){1,2}$/.test(value)) {
@@ -3366,11 +3388,14 @@
 		if (!/^(rgba?|hsla?)\(.*\)$/.test(value)
 		&& !parseSimpleColor(value)
 		&& value.toLowerCase() != "transparent") {
-			return;
+			return false;
 		}
 
 		// "Set the selection's value to value."
 		setSelectionValue("forecolor", value);
+
+		// "Return true."
+		return true;
 	}, standardInlineValueCommand: true, relevantCssProperty: "color",
 	equivalentValues: function(val1, val2) {
 		// "Either both strings are valid CSS colors and have the same red,
@@ -3391,7 +3416,7 @@
 		// "If value is not a valid CSS color, prepend "#" to it."
 		//
 		// "If value is still not a valid CSS color, or if it is currentColor,
-		// abort these steps and do nothing."
+		// return false."
 		//
 		// Cheap hack for testing, no attempt to be comprehensive.
 		if (/^([0-9a-fA-F]{3}){1,2}$/.test(value)) {
@@ -3400,11 +3425,14 @@
 		if (!/^(rgba?|hsla?)\(.*\)$/.test(value)
 		&& !parseSimpleColor(value)
 		&& value.toLowerCase() != "transparent") {
-			return;
+			return false;
 		}
 
 		// "Set the selection's value to value."
 		setSelectionValue("hilitecolor", value);
+
+		// "Return true."
+		return true;
 	}, indeterm: function() {
 		// "True if among editable Text nodes that are effectively contained in
 		// the active range, there are two that have distinct effective command
@@ -3431,12 +3459,14 @@
 commands.italic = {
 	action: function() {
 		// "If queryCommandState("italic") returns true, set the selection's
-		// value to "normal". Otherwise set the selection's value to "italic"."
+		// value to "normal". Otherwise set the selection's value to "italic".
+		// Either way, return true."
 		if (myQueryCommandState("italic")) {
 			setSelectionValue("italic", "normal");
 		} else {
 			setSelectionValue("italic", "italic");
 		}
+		return true;
 	}, inlineCommandActivatedValues: ["italic", "oblique"],
 	relevantCssProperty: "fontStyle"
 };
@@ -3545,6 +3575,9 @@
 		].forEach(function(command) {
 			setSelectionValue(command, null);
 		});
+
+		// "Return true."
+		return true;
 	}
 };
 
@@ -3555,12 +3588,13 @@
 	action: function() {
 		// "If queryCommandState("strikethrough") returns true, set the
 		// selection's value to null. Otherwise set the selection's value to
-		// "line-through"."
+		// "line-through".  Either way, return true."
 		if (myQueryCommandState("strikethrough")) {
 			setSelectionValue("strikethrough", null);
 		} else {
 			setSelectionValue("strikethrough", "line-through");
 		}
+		return true;
 	}, inlineCommandActivatedValues: ["line-through"]
 };
 
@@ -3579,6 +3613,9 @@
 		if (!state) {
 			setSelectionValue("subscript", "subscript");
 		}
+
+		// "Return true."
+		return true;
 	}, indeterm: function() {
 		// "True if either among formattable nodes that are effectively
 		// contained in the active range, there is at least one with effective
@@ -3609,6 +3646,9 @@
 		if (!state) {
 			setSelectionValue("superscript", "superscript");
 		}
+
+		// "Return true."
+		return true;
 	}, indeterm: function() {
 		// "True if either among formattable nodes that are effectively
 		// contained in the active range, there is at least one with effective
@@ -3629,12 +3669,14 @@
 commands.underline = {
 	action: function() {
 		// "If queryCommandState("underline") returns true, set the selection's
-		// value to null. Otherwise set the selection's value to "underline"."
+		// value to null. Otherwise set the selection's value to "underline".
+		// Either way, return true."
 		if (myQueryCommandState("underline")) {
 			setSelectionValue("underline", null);
 		} else {
 			setSelectionValue("underline", "underline");
 		}
+		return true;
 	}, inlineCommandActivatedValues: ["underline"]
 };
 
@@ -3679,6 +3721,9 @@
 		for (var i = 0; i < hyperlinks.length; i++) {
 			clearValue(hyperlinks[i], "unlink");
 		}
+
+		// "Return true."
+		return true;
 	}
 };
 
@@ -6144,10 +6189,10 @@
 	preservesOverrides: true,
 	action: function() {
 		// "If the active range is not collapsed, delete the selection and
-		// abort these steps."
+		// return true."
 		if (!getActiveRange().collapsed) {
 			deleteSelection();
-			return;
+			return true;
 		}
 
 		// "Canonicalize whitespace at the active range's start."
@@ -6187,13 +6232,13 @@
 
 			// "Otherwise, if node has a child with index offset − 1 and that
 			// child is an editable a, remove that child from node, preserving
-			// its descendants. Then abort these steps."
+			// its descendants. Then return true."
 			} else if (0 <= offset - 1
 			&& offset - 1 < node.childNodes.length
 			&& isEditable(node.childNodes[offset - 1])
 			&& isHtmlElement(node.childNodes[offset - 1], "a")) {
 				removePreservingDescendants(node.childNodes[offset - 1]);
-				return;
+				return true;
 
 			// "Otherwise, if node has a child with index offset − 1 and that
 			// child is not a block node or a br or an img, set node to that
@@ -6232,13 +6277,13 @@
 			// "Delete the selection."
 			deleteSelection();
 
-			// "Abort these steps."
-			return;
-		}
-
-		// "If node is an inline node, abort these steps."
+			// "Return true."
+			return true;
+		}
+
+		// "If node is an inline node, return true."
 		if (isInlineNode(node)) {
-			return;
+			return true;
 		}
 
 		// "If node is an li or dt or dd and is the first child of its parent,
@@ -6286,8 +6331,8 @@
 			// "Fix disallowed ancestors of node."
 			fixDisallowedAncestors(node);
 
-			// "Abort these steps."
-			return;
+			// "Return true."
+			return true;
 		}
 
 		// "Let start node equal node and let start offset equal offset."
@@ -6348,14 +6393,14 @@
 				outdentNode(nodeList[i]);
 			}
 
-			// "Abort these steps."
-			return;
+			// "Return true."
+			return true;
 		}
 
 		// "If the child of start node with index start offset is a table,
-		// abort these steps."
+		// return true."
 		if (isHtmlElement(startNode.childNodes[startOffset], "table")) {
-			return;
+			return true;
 		}
 
 		// "If start node has a child with index start offset − 1, and that
@@ -6373,8 +6418,8 @@
 			getSelection().extend(startNode, startOffset);
 			getActiveRange().setEnd(startNode, startOffset);
 
-			// "Abort these steps."
-			return;
+			// "Return true."
+			return true;
 		}
 
 		// "If offset is zero; and either the child of start node with index
@@ -6408,8 +6453,8 @@
 			getActiveRange().setStart(node, offset);
 			getActiveRange().collapse(true);
 
-			// "Abort these steps."
-			return;
+			// "Return true."
+			return true;
 		}
 
 		// "If the child of start node with index start offset is an li or dt
@@ -6480,9 +6525,9 @@
 			getActiveRange().setStart(originalRange.startContainer, originalRange.startOffset);
 			getActiveRange().setEnd(originalRange.endContainer, originalRange.endOffset);
 
-			// "Abort these steps."
+			// "Return true."
 			extraRanges.pop();
-			return;
+			return true;
 		}
 
 		// "While start node has a child with index start offset minus one:"
@@ -6515,6 +6560,9 @@
 
 		// "Delete the selection, with direction "backward"."
 		deleteSelection({direction: "backward"});
+
+		// "Return true."
+		return true;
 	}
 };
 
@@ -6538,10 +6586,9 @@
 		// "Let value be converted to ASCII lowercase."
 		value = value.toLowerCase();
 
-		// "If value is not a formattable block name, abort these steps and do
-		// nothing."
+		// "If value is not a formattable block name, return false."
 		if (formattableBlockNames.indexOf(value) == -1) {
-			return;
+			return false;
 		}
 
 		// "Block-extend the active range, and let new range be the result."
@@ -6645,6 +6692,9 @@
 					: function() { return false },
 				function() { return document.createElement(value) }));
 		}
+
+		// "Return true."
+		return true;
 	}, indeterm: function() {
 		// "If the active range is null, return false."
 		if (!getActiveRange()) {
@@ -6761,10 +6811,10 @@
 	preservesOverrides: true,
 	action: function() {
 		// "If the active range is not collapsed, delete the selection and
-		// abort these steps."
+		// return true."
 		if (!getActiveRange().collapsed) {
 			deleteSelection();
-			return;
+			return true;
 		}
 
 		// "Canonicalize whitespace at the active range's start."
@@ -6847,13 +6897,13 @@
 			// "Delete the selection."
 			deleteSelection();
 
-			// "Abort these steps."
-			return;
-		}
-
-		// "If node is an inline node, abort these steps."
+			// "Return true."
+			return true;
+		}
+
+		// "If node is an inline node, return true."
 		if (isInlineNode(node)) {
-			return;
+			return true;
 		}
 
 		// "If node has a child with index offset and that child is a br or hr
@@ -6873,8 +6923,8 @@
 			// "Delete the selection."
 			deleteSelection();
 
-			// "Abort these steps."
-			return;
+			// "Return true."
+			return true;
 		}
 
 		// "Let end node equal node and let end offset equal offset."
@@ -6910,9 +6960,9 @@
 		}
 
 		// "If the child of end node with index end offset minus one is a
-		// table, abort these steps."
+		// table, return true."
 		if (isHtmlElement(endNode.childNodes[endOffset - 1], "table")) {
-			return;
+			return true;
 		}
 
 		// "If the child of end node with index end offset is a table:"
@@ -6927,8 +6977,8 @@
 			getSelection().extend(endNode, endOffset + 1);
 			getActiveRange().setEnd(endNode, endOffset + 1);
 
-			// "Abort these steps."
-			return;
+			// "Return true."
+			return true;
 		}
 
 		// "If offset is the length of node, and the child of end node with
@@ -6953,8 +7003,8 @@
 			getActiveRange().setStart(node, offset);
 			getActiveRange().collapse(true);
 
-			// "Abort these steps."
-			return;
+			// "Return true."
+			return true;
 		}
 
 		// "While end node has a child with index end offset:"
@@ -6984,6 +7034,9 @@
 
 		// "Delete the selection."
 		deleteSelection();
+
+		// "Return true."
+		return true;
 	}
 };
 
@@ -7073,6 +7126,9 @@
 			// "Indent sublist."
 			indentNodes(sublist);
 		}
+
+		// "Return true."
+		return true;
 	}
 };
 
@@ -7121,10 +7177,10 @@
 		deleteSelection({blockMerging: false});
 
 		// "If the active range's start node is neither editable nor an editing
-		// host, abort these steps."
+		// host, return true."
 		if (!isEditable(getActiveRange().startContainer)
 		&& !isEditingHost(getActiveRange().startContainer)) {
-			return;
+			return true;
 		}
 
 		// "If the active range's start node is a Text node and its start
@@ -7170,6 +7226,9 @@
 		getSelection().collapse(hr.parentNode, 1 + getNodeIndex(hr));
 		getActiveRange().setStart(hr.parentNode, 1 + getNodeIndex(hr));
 		getActiveRange().collapse(true);
+
+		// "Return true."
+		return true;
 	}
 };
 
@@ -7183,10 +7242,10 @@
 		deleteSelection();
 
 		// "If the active range's start node is neither editable nor an editing
-		// host, abort these steps."
+		// host, return true."
 		if (!isEditable(getActiveRange().startContainer)
 		&& !isEditingHost(getActiveRange().startContainer)) {
-			return;
+			return true;
 		}
 
 		// "Let frag be the result of calling createContextualFragment(value)
@@ -7196,9 +7255,9 @@
 		// "Let last child be the lastChild of frag."
 		var lastChild = frag.lastChild;
 
-		// "If last child is null, abort these steps."
+		// "If last child is null, return true."
 		if (!lastChild) {
-			return;
+			return true;
 		}
 
 		// "Let descendants be all descendants of frag."
@@ -7242,6 +7301,9 @@
 		for (var i = 0; i < descendants.length; i++) {
 			fixDisallowedAncestors(descendants[i]);
 		}
+
+		// "Return true."
+		return true;
 	}
 };
 
@@ -7251,9 +7313,9 @@
 commands.insertimage = {
 	preservesOverrides: true,
 	action: function(value) {
-		// "If value is the empty string, abort these steps and do nothing."
+		// "If value is the empty string, return false."
 		if (value === "") {
-			return;
+			return false;
 		}
 
 		// "Delete the selection, with strip wrappers false."
@@ -7263,10 +7325,10 @@
 		var range = getActiveRange();
 
 		// "If the active range's start node is neither editable nor an editing
-		// host, abort these steps."
+		// host, return true."
 		if (!isEditable(getActiveRange().startContainer)
 		&& !isEditingHost(getActiveRange().startContainer)) {
-			return;
+			return true;
 		}
 
 		// "If range's start node is a block node whose sole child is a br, and
@@ -7304,6 +7366,9 @@
 		// to actually do what the spec says.
 		img.removeAttribute("width");
 		img.removeAttribute("height");
+
+		// "Return true."
+		return true;
 	}
 };
 
@@ -7317,25 +7382,25 @@
 		deleteSelection({stripWrappers: false});
 
 		// "If the active range's start node is neither editable nor an editing
-		// host, abort these steps."
+		// host, return true."
 		if (!isEditable(getActiveRange().startContainer)
 		&& !isEditingHost(getActiveRange().startContainer)) {
-			return;
+			return true;
 		}
 
 		// "If the active range's start node is an Element, and "br" is not an
-		// allowed child of it, abort these steps."
+		// allowed child of it, return true."
 		if (getActiveRange().startContainer.nodeType == Node.ELEMENT_NODE
 		&& !isAllowedChild("br", getActiveRange().startContainer)) {
-			return;
+			return true;
 		}
 
 		// "If the active range's start node is not an Element, and "br" is not
-		// an allowed child of the active range's start node's parent, abort
-		// these steps."
+		// an allowed child of the active range's start node's parent, return
+		// true."
 		if (getActiveRange().startContainer.nodeType != Node.ELEMENT_NODE
 		&& !isAllowedChild("br", getActiveRange().startContainer.parentNode)) {
-			return;
+			return true;
 		}
 
 		// "If the active range's start node is a Text node and its start
@@ -7390,6 +7455,9 @@
 			getActiveRange().setStart(br.parentNode, 1 + getNodeIndex(br));
 			getActiveRange().setEnd(br.parentNode, 1 + getNodeIndex(br));
 		}
+
+		// "Return true."
+		return true;
 	}
 };
 
@@ -7398,8 +7466,8 @@
 //@{
 commands.insertorderedlist = {
 	preservesOverrides: true,
-	// "Toggle lists with tag name "ol"."
-	action: function() { toggleLists("ol") },
+	// "Toggle lists with tag name "ol", then return true."
+	action: function() { toggleLists("ol"); return true },
 	// "True if the selection's list state is "mixed" or "mixed ol", false
 	// otherwise."
 	indeterm: function() { return /^mixed( ol)?$/.test(getSelectionListState()) },
@@ -7417,10 +7485,10 @@
 		deleteSelection();
 
 		// "If the active range's start node is neither editable nor an editing
-		// host, abort these steps."
+		// host, return true."
 		if (!isEditable(getActiveRange().startContainer)
 		&& !isEditingHost(getActiveRange().startContainer)) {
-			return;
+			return true;
 		}
 
 		// "Let node and offset be the active range's start node and offset."
@@ -7514,9 +7582,9 @@
 			// "If node list is empty:"
 			if (!nodeList.length) {
 				// "If tag is not an allowed child of the active range's start
-				// node, abort these steps."
+				// node, return true."
 				if (!isAllowedChild(tag, getActiveRange().startContainer)) {
-					return;
+					return true;
 				}
 
 				// "Set container to the result of calling createElement(tag)
@@ -7536,8 +7604,8 @@
 				getActiveRange().setStart(container, 0);
 				getActiveRange().setEnd(container, 0);
 
-				// "Abort these steps."
-				return;
+				// "Return true."
+				return true;
 			}
 
 			// "While the nextSibling of the last member of node list is not
@@ -7586,8 +7654,8 @@
 				getActiveRange().setEnd(node, offset + 1);
 			}
 
-			// "Abort these steps."
-			return;
+			// "Return true."
+			return true;
 		}
 
 		// "If container's local name is "li", "dt", or "dd"; and either it has
@@ -7621,8 +7689,8 @@
 			// "Fix disallowed ancestors of container."
 			fixDisallowedAncestors(container);
 
-			// "Abort these steps."
-			return;
+			// "Return true."
+			return true;
 		}
 
 		// "Let new line range be a new range whose start is the same as
@@ -7746,6 +7814,9 @@
 		getSelection().collapse(newContainer, 0);
 		getActiveRange().setStart(newContainer, 0);
 		getActiveRange().setEnd(newContainer, 0);
+
+		// "Return true."
+		return true;
 	}
 };
 
@@ -7758,10 +7829,10 @@
 		deleteSelection({stripWrappers: false});
 
 		// "If the active range's start node is neither editable nor an editing
-		// host, abort these steps."
+		// host, return true."
 		if (!isEditable(getActiveRange().startContainer)
 		&& !isEditingHost(getActiveRange().startContainer)) {
-			return;
+			return true;
 		}
 
 		// "If value's length is greater than one:"
@@ -7772,20 +7843,20 @@
 				commands.inserttext.action(value[i]);
 			}
 
-			// "Abort these steps."
-			return;
-		}
-
-		// "If value is the empty string, abort these steps."
+			// "Return true."
+			return true;
+		}
+
+		// "If value is the empty string, return true."
 		if (value == "") {
-			return;
+			return true;
 		}
 
 		// "If value is a newline (U+00A0), take the action for the
-		// insertParagraph command and abort these steps."
+		// insertParagraph command and return true."
 		if (value == "\n") {
 			commands.insertparagraph.action();
-			return;
+			return true;
 		}
 
 		// "Let node and offset be the active range's start node and offset."
@@ -7893,6 +7964,9 @@
 		// throws, which we don't want.
 		try { getSelection().collapseToEnd(); } catch(e) {}
 		getActiveRange().collapse(false);
+
+		// "Return true."
+		return true;
 	}
 };
 
@@ -7901,8 +7975,8 @@
 //@{
 commands.insertunorderedlist = {
 	preservesOverrides: true,
-	// "Toggle lists with tag name "ul"."
-	action: function() { toggleLists("ul") },
+	// "Toggle lists with tag name "ul", then return true."
+	action: function() { toggleLists("ul"); return true },
 	// "True if the selection's list state is "mixed" or "mixed ul", false
 	// otherwise."
 	indeterm: function() { return /^mixed( ul)?$/.test(getSelectionListState()) },
@@ -7915,8 +7989,8 @@
 //@{
 commands.justifycenter = {
 	preservesOverrides: true,
-	// "Justify the selection with alignment "center"."
-	action: function() { justifySelection("center") },
+	// "Justify the selection with alignment "center", then return true."
+	action: function() { justifySelection("center"); return true },
 	indeterm: function() {
 		// "Return false if the active range is null.  Otherwise, block-extend
 		// the active range. Return true if among visible editable nodes that
@@ -7969,8 +8043,8 @@
 //@{
 commands.justifyfull = {
 	preservesOverrides: true,
-	// "Justify the selection with alignment "justify"."
-	action: function() { justifySelection("justify") },
+	// "Justify the selection with alignment "justify", then return true."
+	action: function() { justifySelection("justify"); return true },
 	indeterm: function() {
 		// "Return false if the active range is null.  Otherwise, block-extend
 		// the active range. Return true if among visible editable nodes that
@@ -8023,8 +8097,8 @@
 //@{
 commands.justifyleft = {
 	preservesOverrides: true,
-	// "Justify the selection with alignment "left"."
-	action: function() { justifySelection("left") },
+	// "Justify the selection with alignment "left", then return true."
+	action: function() { justifySelection("left"); return true },
 	indeterm: function() {
 		// "Return false if the active range is null.  Otherwise, block-extend
 		// the active range. Return true if among visible editable nodes that
@@ -8077,8 +8151,8 @@
 //@{
 commands.justifyright = {
 	preservesOverrides: true,
-	// "Justify the selection with alignment "right"."
-	action: function() { justifySelection("right") },
+	// "Justify the selection with alignment "right", then return true."
+	action: function() { justifySelection("right"); return true },
 	indeterm: function() {
 		// "Return false if the active range is null.  Otherwise, block-extend
 		// the active range. Return true if among visible editable nodes that
@@ -8223,6 +8297,9 @@
 			// "Restore the values from values."
 			restoreValues(values);
 		}
+
+		// "Return true."
+		return true;
 	}
 };
 
@@ -8238,11 +8315,13 @@
 	action: function(value) {
 		// "Let value be converted to ASCII lowercase. If value is then equal
 		// to "p" or "div", set the context object's default single-line
-		// container name to value. Otherwise, do nothing."
+		// container name to value and return true. Otherwise, return false."
 		value = value.toLowerCase();
 		if (value == "p" || value == "div") {
 			defaultSingleLineContainerName = value;
-		}
+			return true;
+		}
+		return false;
 	}, value: function() {
 		// "Return the context object's default single-line container name."
 		return defaultSingleLineContainerName;
@@ -8275,6 +8354,9 @@
 		} else {
 			getSelection().selectAllChildren(target);
 		}
+
+		// "Return true."
+		return true;
 	}
 };
 
@@ -8285,8 +8367,9 @@
 	action: function(value) {
 		// "If value is an ASCII case-insensitive match for the string
 		// "false", set the CSS styling flag to false. Otherwise, set the
-		// CSS styling flag to true."
+		// CSS styling flag to true.  Either way, return true."
 		cssStylingFlag = String(value).toLowerCase() != "false";
+		return true;
 	}, state: function() { return cssStylingFlag }
 };
 
@@ -8297,8 +8380,9 @@
 	action: function(value) {
 		// "If value is an ASCII case-insensitive match for the string "false",
 		// set the CSS styling flag to true. Otherwise, set the CSS styling
-		// flag to false."
+		// flag to false.  Either way, return true."
 		cssStylingFlag = String(value).toLowerCase() == "false";
+		return true;
 	}
 };
 //@}
@@ -8423,10 +8507,11 @@
 
 		commands[command].action = function(value) {
 			var overrides = recordCurrentOverrides();
-			oldAction(value);
+			var ret = oldAction(value);
 			if (getActiveRange().collapsed) {
 				restoreStatesAndValues(overrides);
 			}
+			return ret;
 		};
 	}
 });
--- a/source.html	Fri May 18 06:13:37 2012 -0600
+++ b/source.html	Sun May 20 06:30:28 2012 -0600
@@ -1253,7 +1253,8 @@
   bold if the selection is already bold.  An editing toolbar might provide
   buttons that execute the <span>action</span> for a <span>command</span> if
   clicked, or a script might run an <span>action</span> without user
-  interaction to achieve some particular effect.
+  interaction to achieve some particular effect.  Actions return either true or
+  false, which can affect the return value of <code>execCommand()</code>.
 
   <li><dfn>Indeterminate</dfn>: A boolean value returned by
   <code>queryCommandIndeterm()</code>, depending on the current state of the
@@ -1552,6 +1553,8 @@
   <li>Take the <span>action</span> for <var>command</var>, passing
   <var>value</var> to the instructions as an argument.
 
+  <li>If the previous step returned false, return false.
+
   <li>If <var>command</var> is not in the
   <a href=#miscellaneous-commands>Miscellaneous commands</a> section, then
   [[dispatch]] an [[event]] at <var>affected editing host</var> that uses the
@@ -3866,9 +3869,11 @@
   <li>If <var>value</var> is not a valid CSS color, prepend "#" to it.
 
   <li>If <var>value</var> is still not a valid CSS color, or if it is
-  currentColor, abort these steps and do nothing.
+  currentColor, return false.
 
   <li><span>Set the selection's value</span> to <var>value</var>.
+
+  <li>Return true.
 </ol>
 
 <p><span>Standard inline value command</span>
@@ -3892,7 +3897,7 @@
 <p><span>Action</span>: If <code
 title=queryCommandState()>queryCommandState("bold")</code> returns true,
 <span>set the selection's value</span> to "normal".  Otherwise <span>set the
-selection's value</span> to "bold".
+selection's value</span> to "bold".  Either way, return true.
 
 <div class=comments>
 <p>The cutoff of 600 matches Chrome 14 dev.  The cutoff used by IE9 and Firefox
@@ -3949,8 +3954,7 @@
   really want to, they can always specify "#" for the value, or the author can
   rewrite it, so it's not like this makes the API less useful.
 
-  <p>If <var>value</var> is the empty string, abort these steps and do
-  nothing.
+  <p>If <var>value</var> is the empty string, return false.
 
   <li>
   <div class=comments>
@@ -3983,6 +3987,8 @@
   [[href]] attribute to <var>value</var>.
 
   <li><span>Set the selection's value</span> to <var>value</var>.
+
+  <li>Return true.
 </ol>
 
 <!-- @} -->
@@ -4021,7 +4027,7 @@
 </div>
 
 <p><span>Action</span>: <span>Set the selection's value</span> to
-<var>value</var>.
+<var>value</var>, then return true.
 
 <div class=comments>
 <p>The value is complicated.
@@ -4109,7 +4115,7 @@
   <li>If <var>value</var> is not a <span data-anolis-spec=html>valid floating
   point number</span>, and would not be a <span data-anolis-spec=html>valid
   floating point number</span> if a single leading "+" character were stripped,
-  abort these steps and do nothing.
+  return false.
 
   <li>If the first character of <var>value</var> is "+", delete the character
   and let <var>mode</var> be "relative-plus".
@@ -4154,6 +4160,8 @@
   </ul>
 
   <li><span>Set the selection's value</span> to <var>value</var>.
+
+  <li>Return true.
 </ol>
 
 <p class=comments>This follows Firefox 6.0a2.  Chrome 14 dev always returns
@@ -4339,9 +4347,11 @@
   sizes.  It will confuse the algorithm, and doesn't seem very useful anyway.
 
   <p>If <var>value</var> is still not a valid CSS color, or if it is
-  currentColor, abort these steps and do nothing.
+  currentColor, return false.
 
   <li><span>Set the selection's value</span> to <var>value</var>.
+
+  <li>Return true.
 </ol>
 
 <div class=comments>
@@ -4406,9 +4416,11 @@
   confuse the algorithm, so ban it for now anyway.
 
   <p>If <var>value</var> is still not a valid CSS color, or if it is
-  currentColor, abort these steps and do nothing.
+  currentColor, return false.
 
   <li><span>Set the selection's value</span> to <var>value</var>.
+
+  <li>Return true.
 </ol>
 
 <p class=comments>For indeterminacy, this follows no one.  Firefox 6.0a2 and
@@ -4429,7 +4441,7 @@
 <p><span>Action</span>: If <code
 title=queryCommandState()>queryCommandState("italic")</code> returns true,
 <span>set the selection's value</span> to "normal".  Otherwise <span>set the
-selection's value</span> to "italic".
+selection's value</span> to "italic".  Either way, return true.
 
 <p><span>Inline command activated values</span>: "italic" or "oblique"
 
@@ -4579,6 +4591,8 @@
     <li>strikethrough
     <li>underline
   </ol>
+
+  <li>Return true.
 </ol>
 
 <!-- @} -->
@@ -4589,7 +4603,7 @@
 <p><span>Action</span>: If <code
 title=queryCommandState()>queryCommandState("strikethrough")</code> returns
 true, <span>set the selection's value</span> to null.  Otherwise <span>set the
-selection's value</span> to "line-through".
+selection's value</span> to "line-through".  Either way, return true.
 
 <p><span>Inline command activated values</span>: "line-through"
 
@@ -4607,6 +4621,8 @@
 
   <li>If <var>state</var> is false, <span>set the selection's value</span> to
   "subscript".
+
+  <li>Return true.
 </ol>
 
 <p><span>Indeterminate</span>: True if either among <span title="formattable
@@ -4644,6 +4660,8 @@
 
   <li>If <var>state</var> is false, <span>set the selection's value</span> to
   "superscript".
+
+  <li>Return true.
 </ol>
 
 <p><span>Indeterminate</span>: True if either among <span title="formattable
@@ -4711,7 +4729,7 @@
 <p><span>Action</span>: If <code
 title=queryCommandState()>queryCommandState("underline")</code> returns true,
 <span>set the selection's value</span> to null.  Otherwise <span>set the
-selection's value</span> to "underline".
+selection's value</span> to "underline".  Either way, return true.
 
 <p><span>Inline command activated values</span>: "underline"
 
@@ -4738,6 +4756,8 @@
   is an [[ancestor]] of one of its [[boundarypoints]].
 
   <li><span>Clear the value</span> of each member of <var>hyperlinks</var>.
+
+  <li>Return true.
 </ol>
 
 <!-- @} -->
@@ -7921,7 +7941,7 @@
 
 <ol>
   <li>If the <span>active range</span> is not [[rangecollapsed]], <span>delete
-  the selection</span> and abort these steps.
+  the selection</span> and return true.
 
   <li>
   <p class=comments>Needed so that if there are multiple consecutive spaces we
@@ -7972,7 +7992,7 @@
     <p>Otherwise, if <var>node</var> has a [[child]] with [[index]]
     <var>offset</var> &minus; 1 and that [[child]] is an <span>editable</span>
     [[a]], remove that [[child]] from <var>node</var>, <span>preserving its
-    descendants</span>.  Then abort these steps.
+    descendants</span>.  Then return true.
 
     <li>Otherwise, if <var>node</var> has a [[child]] with [[index]]
     <var>offset</var> &minus; 1 and that [[child]] is not a <span>block
@@ -8024,14 +8044,14 @@
 
     <li><span>Delete the selection</span>.
 
-    <li>Abort these steps.
+    <li>Return true.
   </ol>
 
   <li>
   <p class=comments>At the time of this writing, this should be impossible.
   Just being safe.
 
-  <p>If <var>node</var> is an <span>inline node</span>, abort these steps.
+  <p>If <var>node</var> is an <span>inline node</span>, return true.
 
   <li>
   <p class=comments> If we're at the beginning of a list, we want to outdent
@@ -8072,7 +8092,7 @@
 
     <li><span>Fix disallowed ancestors</span> of <var>node</var>.
 
-    <li>Abort these steps.
+    <li>Return true.
   </ol>
 
   <li>
@@ -8121,7 +8141,7 @@
 
     <li><span>Outdent</span> each [[node]] in <var>node list</var>.
 
-    <li>Abort these steps.
+    <li>Return true.
   </ol>
 
   <li>
@@ -8134,7 +8154,7 @@
   </div>
 
   <p>If the [[child]] of <var>start node</var> with [[index]] <var>start
-  offset</var> is a [[table]], abort these steps.
+  offset</var> is a [[table]], return true.
 
   <li>
   <p class=comments>If you try backspacing into a table, select it.  This
@@ -8152,7 +8172,7 @@
     <li>Call [[extend|<var>start node</var>, <var>start offset</var>]] on the
     [[contextobject]]'s [[selection]].
 
-    <li>Abort these steps.
+    <li>Return true.
   </ol>
 
   <li>
@@ -8190,7 +8210,7 @@
     <li>Call [[selcollapse|<var>node</var>, <var>offset</var>]] on the
     [[selection]].
 
-    <li>Abort these steps.
+    <li>Return true.
   </ol>
 
   <li>
@@ -8273,7 +8293,7 @@
     <li>Call [[addrange|<var>original range</var>]] on the [[contextobject]]'s
     [[selection]].
 
-    <li>Abort these steps.
+    <li>Return true.
   </ol>
 
   <li>
@@ -8300,6 +8320,8 @@
   [[contextobject]]'s [[selection]].
 
   <li><span>Delete the selection</span>, with <var>direction</var> "backward".
+
+  <li>Return true.
 </ol>
 
 <!-- @} -->
@@ -8396,8 +8418,8 @@
   list discussion</a> on the subject.
   </div>
 
-  <p>If <var>value</var> is not a <span>formattable block name</span>, abort
-  these steps and do nothing.
+  <p>If <var>value</var> is not a <span>formattable block name</span>, return
+  false.
 
   <li><span>Block-extend</span> the <span>active range</span>, and let <var>new
   range</var> be the result.
@@ -8535,6 +8557,8 @@
     [[contextobject]].  Then <span>fix disallowed ancestors</span> of the
     result.
   </ol>
+
+  <li>Return true.
 </ol>
 
 <p class=comments>Firefox 6.0a2 throws, Chrome 14 dev always returns false,
@@ -8663,7 +8687,7 @@
 
 <ol>
   <li>If the <span>active range</span> is not [[rangecollapsed]], <span>delete
-  the selection</span> and abort these steps.
+  the selection</span> and return true.
 
   <li><span>Canonicalize whitespace</span> at the <span>active range</span>'s
   [[rangestart]].
@@ -8744,10 +8768,10 @@
 
     <li><span>Delete the selection</span>.
 
-    <li>Abort these steps.
-  </ol>
-
-  <li>If <var>node</var> is an <span>inline node</span>, abort these steps.
+    <li>Return true.
+  </ol>
+
+  <li>If <var>node</var> is an <span>inline node</span>, return true.
 
   <li>If <var>node</var> has a [[child]] with [[index]] <var>offset</var> and
   that [[child]] is a [[br]] or [[hr]] or [[img]], but is not a
@@ -8762,7 +8786,7 @@
 
     <li><span>Delete the selection</span>.
 
-    <li>Abort these steps.
+    <li>Return true.
   </ol>
 
   <li>
@@ -8795,7 +8819,7 @@
   here, unlike delete.
 
   <p>If the [[child]] of <var>end node</var> with [[index]] <var>end
-  offset</var> minus one is a [[table]], abort these steps.
+  offset</var> minus one is a [[table]], return true.
 
   <li>If the [[child]] of <var>end node</var> with [[index]] <var>end
   offset</var> is a [[table]]:
@@ -8807,7 +8831,7 @@
     <li>Call [[extend|<var>end node</var>, <var>end offset</var> + 1]] on the
     [[contextobject]]'s [[selection]].
 
-    <li>Abort these steps.
+    <li>Return true.
   </ol>
 
   <li>
@@ -8830,7 +8854,7 @@
     <li>Call [[selcollapse|<var>node</var>, <var>offset</var>]] on the
     [[selection]].
 
-    <li>Abort these steps.
+    <li>Return true.
   </ol>
 
   <li>
@@ -9016,7 +9040,7 @@
   <li><span>Delete the selection</span>, with <var>block merging</var> false.
 
   <li>If the <span>active range</span>'s [[startnode]] is neither
-  <span>editable</span> nor an <span>editing host</span>, abort these steps.
+  <span>editable</span> nor an <span>editing host</span>, return true.
 
   <li>
   <p class=comments>We don't want to call insertNode at the start or end of a
@@ -9054,6 +9078,8 @@
   <li>Run [[selcollapse|]] on the [[contextobject]]'s [[selection]], with first
   argument <var>hr</var>'s [[parent]] and the second argument equal to one plus
   <var>hr</var>'s [[index]].
+
+  <li>Return true.
 </ol>
 
 <!-- @} -->
@@ -9113,7 +9139,7 @@
   <p><span>Delete the selection</span>.
 
   <li>If the <span>active range</span>'s [[startnode]] is neither
-  <span>editable</span> nor an <span>editing host</span>, abort these steps.
+  <span>editable</span> nor an <span>editing host</span>, return true.
 
   <li>
   <p class=comments>TODO: This has some interesting consequences.  For
@@ -9132,7 +9158,7 @@
   <p class=comments>Firefox 5.0a2 also seems to not add empty elements like
   &lt;b>&lt;/b>, but Chrome 13 dev and Opera 11.11 do.
 
-  <p>If <var>last child</var> is null, abort these steps.
+  <p>If <var>last child</var> is null, return true.
 
   <li>Let <var>descendants</var> be all [[descendants]] of <var>frag</var>.
 
@@ -9196,6 +9222,8 @@
 
   <p><span>Fix disallowed ancestors</span> of each member of
   <var>descendants</var>.
+
+  <li>Return true.
 </ol>
 
 <!-- @} -->
@@ -9214,8 +9242,7 @@
   nothing on an empty string, but the other three browsers I tested stick in
   the &lt;img> anyway.
 
-  <p>If <var>value</var> is the empty string, abort these steps and do
-  nothing.
+  <p>If <var>value</var> is the empty string, return false.
 
   <li>
   <p class=comments>Firefox 7.0a2 seems to strip the wrapper or not depending
@@ -9231,7 +9258,7 @@
   <li>Let <var>range</var> be the <span>active range</span>.
 
   <li>If the <span>active range</span>'s [[startnode]] is neither
-  <span>editable</span> nor an <span>editing host</span>, abort these steps.
+  <span>editable</span> nor an <span>editing host</span>, return true.
 
   <li>
   <p class=comments>Same logic as with insertHTML.
@@ -9263,6 +9290,8 @@
   <li>Run [[selcollapse|]] on <var>selection</var>, with first argument equal
   to the [[parent]] of <var>img</var> and the second argument equal to one plus
   the [[index]] of <var>img</var>.
+
+  <li>Return true.
 </ol>
 
 <!-- @} -->
@@ -9304,17 +9333,17 @@
   <p><span>Delete the selection</span>, with <var>strip wrappers</var> false.
 
   <li>If the <span>active range</span>'s [[startnode]] is neither
-  <span>editable</span> nor an <span>editing host</span>, abort these steps.
+  <span>editable</span> nor an <span>editing host</span>, return true.
 
   <li>
   <p class=comments>script, xmp, table, . . .
 
   <p>If the <span>active range</span>'s [[startnode]] is an [[element]], and
-  "br" is not an <span>allowed child</span> of it, abort these steps.
+  "br" is not an <span>allowed child</span> of it, return true.
 
   <li>If the <span>active range</span>'s [[startnode]] is not an [[element]],
   and "br" is not an <span>allowed child</span> of the <span>active
-  range</span>'s [[startnode]]'s [[parent]], abort these steps.
+  range</span>'s [[startnode]]'s [[parent]], return true.
 
   <li>
   <p class=comments>We don't want to call insertNode at the start or end of a
@@ -9346,6 +9375,8 @@
   [[createelement|"br"]] on the [[contextobject]] and let <var>extra br</var>
   be the result, then call [[insertnode|<var>extra br</var>]] on the
   <span>active range</span>.
+
+  <li>Return true.
 </ol>
 
 <!-- @} -->
@@ -9354,7 +9385,7 @@
 <p><span>Preserves overrides</span>
 
 <p><span>Action</span>: <span>Toggle lists</span> with <var>tag name</var>
-"ol".
+"ol", then return true.
 
 <p class=comments>Firefox 6.0a2 sort of supports this, but it throws exceptions
 most of the time.  It has the quirk that even if there are no ol's around, it
@@ -9438,7 +9469,7 @@
   <li><span>Delete the selection</span>.
 
   <li>If the <span>active range</span>'s [[startnode]] is neither
-  <span>editable</span> nor an <span>editing host</span>, abort these steps.
+  <span>editable</span> nor an <span>editing host</span>, return true.
 
   <li>Let <var>node</var> and <var>offset</var> be the <span>active
   range</span>'s [[rangestart]] [[node]] and [[bpoffset]].
@@ -9515,7 +9546,7 @@
       case where deleting can leave the cursor inside a &lt;tr>.
 
       <p>If <var>tag</var> is not an <span>allowed child</span> of
-      the <span>active range</span>'s [[startnode]], abort these steps.
+      the <span>active range</span>'s [[startnode]], return true.
 
       <li>Set <var>container</var> to the result of calling
       [[createelement|<var>tag</var>]] on the [[contextobject]].
@@ -9529,7 +9560,7 @@
       <li>Call [[selcollapse|<var>container</var>, 0]] on the
       [[contextobject]]'s [[selection]].
 
-      <li>Abort these steps.
+      <li>Return true.
     </ol>
 
     <li>
@@ -9591,7 +9622,7 @@
     [[contextobject]], then call [[insertnode|<var>br</var>]] on
     the <span>active range</span>.
 
-    <li>Abort these steps.
+    <li>Return true.
   </ol>
 
   <li>
@@ -9624,7 +9655,7 @@
 
     <li><span>Fix disallowed ancestors</span> of <var>container</var>.
 
-    <li>Abort these steps.
+    <li>Return true.
   </ol>
 
   <li>Let <var>new line range</var> be a new [[range]] whose [[rangestart]] is
@@ -9731,6 +9762,8 @@
 
   <li>Call [[selcollapse|<var>new container</var>, 0]] on the
   [[contextobject]]'s [[selection]].
+
+  <li>Return true.
 </ol>
 
 <!-- @} -->
@@ -9876,7 +9909,7 @@
   <p><span>Delete the selection</span>, with <var>strip wrappers</var> false.
 
   <li>If the <span>active range</span>'s [[startnode]] is neither
-  <span>editable</span> nor an <span>editing host</span>, abort these steps.
+  <span>editable</span> nor an <span>editing host</span>, return true.
 
   <li>If <var>value</var>'s [[strlen]] is greater than one:
 
@@ -9885,18 +9918,18 @@
     <span>action</span> for <span>the <code title>insertText</code>
     command</span>, with <var>value</var> equal to <var>el</var>.
 
-    <li>Abort these steps.
-  </ol>
-
-  <li>If <var>value</var> is the empty string, abort these steps.
+    <li>Return true.
+  </ol>
+
+  <li>If <var>value</var> is the empty string, return true.
 
   <li>
   <p class=comments>TODO: WebKit also does magic for tabs, wrapping them in a
   whitespace-preserving span.  Should we?
 
   <p>If <var>value</var> is a newline (U+00A0), take the <span>action</span>
-  for <span>the <code title>insertParagraph</code> command</span> and abort
-  these steps.
+  for <span>the <code title>insertParagraph</code> command</span> and return
+  true.
 
   <li>Let <var>node</var> and <var>offset</var> be the <span>active
   range</span>'s [[startnode]] and [[bpoffset]].
@@ -9977,6 +10010,8 @@
   <span>active range</span>'s [[rangestart]].
 
   <li>Call [[collapsetoend]] on the [[contextobject]]'s [[selection]].
+
+  <li>Return true.
 </ol>
 
 <!-- @} -->
@@ -9988,7 +10023,7 @@
 href=#the-insertorderedlist-command>insertOrderedList</a>.
 
 <p><span>Action</span>: <span>Toggle lists</span> with <var>tag name</var>
-"ul".
+"ul", then return true.
 
 <p><span>Indeterminate</span>: True if the <span>selection's list state</span>
 is "mixed" or "mixed ul", false otherwise.
@@ -10002,7 +10037,7 @@
 <p><span>Preserves overrides</span>
 
 <p><span>Action</span>: <span>Justify the selection</span> with
-<var>alignment</var> "center".
+<var>alignment</var> "center", then return true.
 
 <div class=comments>
 <p>This roughly matches Chrome 14 dev, although not exactly.  Firefox 6.0a2
@@ -10074,7 +10109,7 @@
 <p><span>Preserves overrides</span>
 
 <p><span>Action</span>: <span>Justify the selection</span> with
-<var>alignment</var> "justify".
+<var>alignment</var> "justify", then return true.
 
 <p><span>Indeterminate</span>: Return false if the <span>active range</span> is
 null.  Otherwise, <span>block-extend</span> the <span>active range</span>.
@@ -10102,7 +10137,7 @@
 <p><span>Preserves overrides</span>
 
 <p><span>Action</span>: <span>Justify the selection</span> with
-<var>alignment</var> "left".
+<var>alignment</var> "left", then return true.
 
 <p><span>Indeterminate</span>: Return false if the <span>active range</span> is
 null.  Otherwise, <span>block-extend</span> the <span>active range</span>.
@@ -10130,7 +10165,7 @@
 <p><span>Preserves overrides</span>
 
 <p><span>Action</span>: <span>Justify the selection</span> with
-<var>alignment</var> "right".
+<var>alignment</var> "right", then return true.
 
 <p><span>Indeterminate</span>: Return false if the <span>active range</span> is
 null.  Otherwise, <span>block-extend</span> the <span>active range</span>.
@@ -10235,6 +10270,8 @@
 
     <li><span>Restore the values</span> from <var>values</var>.
   </ol>
+
+  <li>Return true.
 </ol>
 <!-- @} -->
 
@@ -10308,8 +10345,8 @@
 <p><span>Action</span>: Let <var>value</var> be
 <span data-anolis-spec=dom>converted to ASCII lowercase</span>.  If
 <var>value</var> is then equal to "p" or "div", set the [[contextobject]]'s
-<span>default single-line container name</span> to <var>value</var>.
-Otherwise, do nothing.
+<span>default single-line container name</span> to <var>value</var>, then
+return true.  Otherwise, return false.
 
 <p><span>Value</span>: Return the [[contextobject]]'s
 <span>default single-line container name</span>.
@@ -10403,6 +10440,8 @@
 
   <li>Otherwise, call [[getselection]] on the [[contextobject]], and call
   [[selectallchildren|<var>target</var>]] on the result.
+
+  <li>Return true.
 </ol>
 
 <!-- @} -->
@@ -10429,7 +10468,7 @@
 <p><span>Action</span>: If <var>value</var> is an <span
 data-anolis-spec=domcore>ASCII case-insensitive</span> match for the string
 "false", set the <span>CSS styling flag</span> to false.  Otherwise, set the
-<span>CSS styling flag</span> to true.
+<span>CSS styling flag</span> to true.  Either way, return true.
 
 <p class=comments>This follows Chrome 13 dev.  Firefox 5.0a2 doesn't support
 queryCommandState() for styleWithCSS.
@@ -10462,7 +10501,7 @@
 <p><span>Action</span>: If <var>value</var> is an <span
 data-anolis-spec=domcore>ASCII case-insensitive</span> match for the string
 "false", set the <span>CSS styling flag</span> to true.  Otherwise, set the
-<span>CSS styling flag</span> to false.
+<span>CSS styling flag</span> to false.  Either way, return true.
 
 <p>Since the effect of this command is the opposite of what one would expect,
 user agents are encouraged to point authors to <code title="the stylewithcss
--- a/tests.js	Fri May 18 06:13:37 2012 -0600
+++ b/tests.js	Sun May 20 06:30:28 2012 -0600
@@ -4031,6 +4031,8 @@
 		['P', 'foo[bar]baz'],
 		[' div ', 'foo[bar]baz'],
 		[' p ', 'foo[bar]baz'],
+		['<div>', 'foo[bar]baz'],
+		['<p>', 'foo[bar]baz'],
 		['li', 'foo[bar]baz'],
 		['blockquote', 'foo[bar]baz'],
 	],