/*\
title: js/macros/edit.js
\*/
(function(){
/*jslint node: true, browser: true */
"use strict";
var Tiddler = require("../Tiddler.js").Tiddler,
Renderer = require("../Renderer.js").Renderer,
Dependencies = require("../Dependencies.js").Dependencies,
utils = require("../Utils.js");
function getText(text,node) {
if(node.nodeType === window.Node.TEXT_NODE) {
text.push(node.data);
} else if(node.nodeType === window.Node.ELEMENT_NODE && node.nodeName.toLowerCase() === "br") {
// Firefox has `
` tags instead of line feeds
text.push("\n");
}
if(node.hasChildNodes && node.hasChildNodes()) {
for(var t=0; t