|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectinfo.magnolia.cms.gui.dialog.DialogControlImpl
info.magnolia.cms.gui.dialog.DialogBox
info.magnolia.cms.gui.dialog.DialogEditCode
public class DialogEditCode
Turns a textarea into a basic code editor using CodeMirror. If no language
option is explicitly configured, it will try to guess
the correct syntax highlighter by either looking at the resource extension or the mgnl:template
metadata property. Defaults to a generic
syntax parser which
will highlight html, javascript and css.
Configuration options are:
true
. If set as false
, falls back to a plain textarea.
generic
.
false
.
true
.
Field Summary | |
---|---|
static Map<String,String> |
availableParsers
Valid values are js, javascript, processedJs, css, processedCss, html, freemarker, ftl, groovy, generic . |
Fields inherited from class info.magnolia.cms.gui.dialog.DialogBox |
---|
BOXTYPE_1COL, BOXTYPE_2COLS |
Fields inherited from class info.magnolia.cms.gui.dialog.DialogControlImpl |
---|
DEFAULT_VALUE_PROPERTY, SESSION_ATTRIBUTENAME_DIALOGOBJECT, SESSION_ATTRIBUTENAME_DIALOGOBJECT_REMOVE, VALIDATION_PATTERN_PROPERTY, value |
Constructor Summary | |
---|---|
DialogEditCode()
|
Method Summary | |
---|---|
void |
drawHtml(Writer out)
Actually draw the dialog content. |
Methods inherited from class info.magnolia.cms.gui.dialog.DialogBox |
---|
drawHtmlPost, drawHtmlPre, getBoxType, getHtmlDescription, setBoxType |
Methods inherited from class info.magnolia.cms.gui.dialog.DialogControlImpl |
---|
addOption, addSub, clearWebsiteNode, drawHtmlPostSubs, drawHtmlPreSubs, drawSubs, getConfigValue, getConfigValue, getDescription, getId, getLabel, getMessage, getMessage, getMessages, getName, getOptions, getParent, getRequest, getResponse, getStorageNode, getSub, getSubs, getTopParent, getValidationPattern, getValue, getValues, getWebsiteNode, init, isRequired, readValue, readValues, removeSessionAttribute, setConfig, setConfig, setConfig, setDescription, setLabel, setName, setOptions, setRequired, setSaveInfo, setSessionAttribute, setTopParent, setValidationMessage, setValue, validate |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final Map<String,String> availableParsers
js, javascript, processedJs, css, processedCss, html, freemarker, ftl, groovy, generic
.
Constructor Detail |
---|
public DialogEditCode()
Method Detail |
---|
public void drawHtml(Writer out) throws IOException
DialogControl
drawHtml
in interface DialogControl
drawHtml
in class DialogControlImpl
out
- Writer
IOException
- exceptions thrown when writing to the Writer can be safely rethrown by the dialogDialogControl.drawHtml(Writer)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |