(Answering my own question based on a similar question I found when I posted mine...)
The guys in this Q&A thread were on an interesting track. It just used a different format than I was looking for. Modifying their code, I was able to do the following:
<h3><a href="#" id="btnRange">Display Range</a> |
<a href="#" id="btnMark">Mark Range</a></h3>
<div contenteditable="true" id="editor">
This is sample text. You should be able to type in this box or select anywhere in this div and then click the link at the top to get the selected range.
</div>
<script type="text/javascript">
var btnDisplay = $("#btnRange"),
btnMark = $("#btnMark");
btnDisplay.click(function() {
alert(window.getSelection().getRangeAt(0));
return false;
});
btnMark.click(function() {
var range = window.getSelection().getRangeAt(0);
var newNode = document.createElement("mark");
range.surroundContents(newNode);
return false;
});
I could further abstract the code in the btnMark.click() function to accept a tag name and then create a row of buttons to markup the code with mark, pre, blockquote.
A working solution can be found here: http://jsfiddle.net/3tvSL/