Add h1 adn h2, h2 seems not to work jet, menu immage have to be drawn

This commit is contained in:
Nils Rokita 2011-12-10 14:36:21 +01:00
parent d9686c7646
commit 2726634200
5 changed files with 27 additions and 3 deletions

View file

@ -27,7 +27,9 @@ linestylefilter.ATTRIB_CLASSES = {
'bold': 'tag:b',
'italic': 'tag:i',
'underline': 'tag:u',
'strikethrough': 'tag:s'
'strikethrough': 'tag:s',
'heading1': 'tag:h1',
'heading2': 'tag:h2'
};
linestylefilter.getAuthorClassName = function(author)

View file

@ -25,7 +25,9 @@ linestylefilter.ATTRIB_CLASSES = {
'bold': 'tag:b',
'italic': 'tag:i',
'underline': 'tag:u',
'strikethrough': 'tag:s'
'strikethrough': 'tag:s',
'heading1': 'tag:h1',
'heading2': 'tag:h2'
};
linestylefilter.getAuthorClassName = function(author)

View file

@ -118,6 +118,7 @@ var padeditbar = (function()
padeditor.ace.callWithAce(function(ace)
{
if (cmd == 'bold' || cmd == 'italic' || cmd == 'underline' || cmd == 'strikethrough') ace.ace_toggleAttributeOnSelection(cmd);
else if (cmd == 'heading1' || cmd == 'heading2') ace.ace_toggleAttributeOnSelection(cmd);
else if (cmd == 'undo' || cmd == 'redo') ace.ace_doUndoRedo(cmd);
else if (cmd == 'insertunorderedlist') ace.ace_doInsertUnorderedList();
else if (cmd == 'indent')