function isInlineNode(node) {
        return dom.isCharacterDataNode(node) ||
                (node.nodeType == 1 && inlineDisplayRegex.test(getComputedStyleProperty(node, "display")));
    }
"An inline node is either a Text node, or an Element whose 'display'
property computes to 'inline', 'inline-block', or 'inline-table'."