spacedeck_formatting.js 467 B

1234567891011121314151617181920
  1. /*
  2. SpacedeckFormatting
  3. This module contains functions dealing with Rich Text Formatting.
  4. */
  5. var SpacedeckFormatting = {
  6. apply_formatting: function(section, cmd, arg1, arg2) {
  7. console.log("apply_formatting: ",section,cmd);
  8. var scribe = _scribe_handle_for_object[section._id];
  9. var command = scribe.getCommand(cmd);
  10. if (cmd == 'createLink') {
  11. arg1 = prompt("Link URL?");
  12. }
  13. scribe.el.focus();
  14. command.execute(arg1,arg2);
  15. }
  16. }