Several enhancements for the handling of the new labels and hints:

- Hints are now shown for ControlLinks
- The standard theme uses an better symbol
- Hints and new style labels now work for DHTMLEditors, and widgets Date, Time and DateTime


git-svn-id: https://svn.libreccm.org/ccm/trunk@2755 8810af33-2d31-482b-a856-94f89814c4df
master
jensp 2014-07-11 18:38:38 +00:00
parent 112910e484
commit c510e1566a
12 changed files with 531 additions and 479 deletions

View File

@ -23,7 +23,6 @@ import com.arsdigita.bebop.parameters.ParameterModel;
import com.arsdigita.bebop.parameters.StringParameter;
import com.arsdigita.cms.ContentSection;
/**
*
*

View File

@ -281,6 +281,7 @@ public class DHTMLEditor extends TextArea {
Element editor = parent.newChildElement(getElementTag(), BEBOP_XML_NS);
editor.addAttribute("name", getName());
generateDescriptionXML(state, editor);
// Set the needed config params so they don't have to be hardcoded in the theme
editor.addAttribute("editor_url", Web.getWebappContextPath().concat(getEditorURL()));

View File

@ -324,6 +324,7 @@ public class Date extends Widget implements BebopConstants {
date.addAttribute("label", (String) getLabel().localize(ps.getRequest()));
}
exportAttributes(date);
generateDescriptionXML(ps, date);
generateLocalizedWidget(ps, date);
// If Element could be null insert an extra widget to clear entry

View File

@ -112,6 +112,8 @@ public class DateTime extends Widget implements BebopConstants {
m_date.generateLocalizedWidget(ps, datetime);
m_time.generateLocalizedWidget(ps, datetime);
generateDescriptionXML(ps, datetime);
// If Element could be null insert a extra widget to clear entry
if (!hasValidationListener(new NotNullValidationListener())) {
datetime.newChildElement("NoDateTime");

View File

@ -18,7 +18,6 @@
*/
package com.arsdigita.bebop.form;
import com.arsdigita.xml.Element;
import com.arsdigita.bebop.PageState;
@ -28,8 +27,6 @@ import com.arsdigita.bebop.parameters.ParameterModel;
// in a constant which is used when generating XML
import com.arsdigita.bebop.util.BebopConstants;
/**
* A class representing a textarea field in an HTML form.
*
@ -68,13 +65,9 @@ public class TextArea extends Widget implements BebopConstants {
// -------------------------------------
// * * * Fields * * *
// -------------------------------------
// -------------------------------------
// * * * Methods * * *
// -------------------------------------
public TextArea(String name) {
super(name);
}
@ -149,6 +142,7 @@ public class TextArea extends Widget implements BebopConstants {
/**
* Set the default value (text)
*
* @deprecated [since 17Aug2001] use {@link Widget#setDefaultValue(Object)}
*/
public void setValue(String text) {
@ -157,33 +151,35 @@ public class TextArea extends Widget implements BebopConstants {
/**
* Is this a compound widget?
*
* @return false
*/
public boolean isCompound() {
return false;
}
/** The XML tag.
* @return The tag to be used for the top level DOM element
* generated for this type of Widget. */
/**
* The XML tag.
*
* @return The tag to be used for the top level DOM element generated for this type of Widget.
*/
protected String getElementTag() {
return BEBOP_TEXTAREA;
}
/**
* Generates the DOM for the textarea widget.
* <p>Generates DOM fragment:
* <p><code>&lt;bebop:textarea name=... value=... [onXXX=...]/>
* <p>
* Generates DOM fragment:
* <p>
* <code>&lt;bebop:textarea name=... value=... [onXXX=...]/>
* </code>
*/
public void generateWidget(PageState state, Element parent) {
Element textarea = parent.newChildElement(getElementTag(), BEBOP_XML_NS);
textarea.addAttribute("name", getName());
if (getLabel() != null)
textarea.addAttribute("label",
(String)getLabel().localize(state.getRequest()));
generateDescriptionXML(state, textarea);
ParameterData pData = getParameterData(state);
if (null != pData) {
String value = pData.marshal();

View File

@ -21,7 +21,13 @@ package com.arsdigita.bebop.form;
import com.arsdigita.bebop.Form;
import com.arsdigita.bebop.FormData;
import com.arsdigita.bebop.PageState;
import com.arsdigita.bebop.parameters.*;
import com.arsdigita.bebop.parameters.DateTimeParameter;
import com.arsdigita.bebop.parameters.NotNullValidationListener;
import com.arsdigita.bebop.parameters.NumberInRangeValidationListener;
import com.arsdigita.bebop.parameters.ParameterData;
import com.arsdigita.bebop.parameters.ParameterModel;
import com.arsdigita.bebop.parameters.TimeParameter;
import com.arsdigita.bebop.util.BebopConstants;
import com.arsdigita.globalization.GlobalizationHelper;
import com.arsdigita.util.Assert;
@ -258,6 +264,7 @@ public class Time extends Widget implements BebopConstants {
Element time = parent.newChildElement(getElementTag(), BEBOP_XML_NS);
time.addAttribute("name", getParameterModel().getName());
generateDescriptionXML(ps, time);
generateLocalizedWidget(ps, time);
// If Element could be null insert a extra widget to clear entry

View File

@ -52,18 +52,16 @@ import com.arsdigita.xml.Element;
* </p>
*
* <p>
* A widget may correspond to a standard HTML form element, or to a more
* specific element or set of elements, such as a date widget that allows
* input of month, day and year (and possibly time as well).</p>
* A widget may correspond to a standard HTML form element, or to a more specific element or set of
* elements, such as a date widget that allows input of month, day and year (and possibly time as
* well).</p>
*
* <p>
* This class and its subclasses provide methods to set all element attributes
* except for <code>VALUE</code>, which is typically dependent on the request.
* At the time of a request, a widget object merges a dynamically specified
* value or set of values with its own set of persistent attributes to render
* the final HTML for the widget. Other dynamic attributes may be associated
* with the form component via a <code>WidgetPeer</code> associated with the
* widget.</p>
* This class and its subclasses provide methods to set all element attributes except for
* <code>VALUE</code>, which is typically dependent on the request. At the time of a request, a
* widget object merges a dynamically specified value or set of values with its own set of
* persistent attributes to render the final HTML for the widget. Other dynamic attributes may be
* associated with the form component via a <code>WidgetPeer</code> associated with the widget.</p>
*
* @author Karl Goldstein
* @author Uday Mathur
@ -80,7 +78,9 @@ public abstract class Widget extends DescriptiveComponent
private ParameterListener m_forwardParameter = null;
private PrintListener m_printListener;
private Form m_form;
/** The optional (localized) label (or title) of this widget. */
/**
* The optional (localized) label (or title) of this widget.
*/
// Use parent's class' instead
// private GlobalizedMessage m_label;
@ -96,7 +96,6 @@ public abstract class Widget extends DescriptiveComponent
static final String ON_CHANGE = "onChange";
static final String ON_KEY_UP = "onKeyUp";
/**
* Constructor, creates a new widget.
*
@ -110,8 +109,8 @@ public abstract class Widget extends DescriptiveComponent
* Constructor, creates a new widget.
*
* <p>
* Each new widget is associated with a ParameterModel describing the
* data object(s) submitted from the widget.
* Each new widget is associated with a ParameterModel describing the data object(s) submitted
* from the widget.
*
* @param model
*/
@ -121,7 +120,6 @@ public abstract class Widget extends DescriptiveComponent
m_parameterModel = model;
}
/**
* Returns true if the widget consists of multiple HTML elements.
*
@ -130,8 +128,7 @@ public abstract class Widget extends DescriptiveComponent
public abstract boolean isCompound();
/**
* Returns a string naming the type of this widget. Must be implemented by
* subclasses!
* Returns a string naming the type of this widget. Must be implemented by subclasses!
*
* @return
*/
@ -143,11 +140,13 @@ public abstract class Widget extends DescriptiveComponent
*/
protected ParameterListener createParameterListener() {
return new ParameterListener() {
@Override
public void validate(ParameterEvent evt)
throws FormProcessException {
fireValidation(new ParameterEvent(Widget.this, evt.getParameterData()));
}
};
}
@ -198,6 +197,7 @@ public abstract class Widget extends DescriptiveComponent
* Test for existens of a particular type of ValidationListener
*
* @param listener Subtype of ParameterListern which is tested for
*
* @return true if subtype is in the list
*/
public boolean hasValidationListener(ParameterListener listener) {
@ -208,11 +208,12 @@ public abstract class Widget extends DescriptiveComponent
}
/**
* Adds a print listener for this widget. Only one print listener can
* be set for a widget, since the <code>PrintListener</code> is expected
* to modify the target of the <code>PrintEvent</code>.
* Adds a print listener for this widget. Only one print listener can be set for a widget, since
* the <code>PrintListener</code> is expected to modify the target of the
* <code>PrintEvent</code>.
*
* @param listener the print listener
*
* @throws IllegalArgumentException <code>listener</code> is null
* @throws TooManyListenersException a print listener has previously been added
* @pre listener != null
@ -229,12 +230,12 @@ public abstract class Widget extends DescriptiveComponent
}
/**
* Set the print listener for this widget. Since there can only be one
* print listener for a widget, this lets you just set it and avoid
* writing a try/catch block for "TooManyListenersException". Any existing
* listener will be overwritten.
* Set the print listener for this widget. Since there can only be one print listener for a
* widget, this lets you just set it and avoid writing a try/catch block for
* "TooManyListenersException". Any existing listener will be overwritten.
*
* @param listener the print listener
*
* @throws IllegalArgumentException <code>listener</code> is null
* @pre listener != null
*/
@ -247,15 +248,14 @@ public abstract class Widget extends DescriptiveComponent
}
/**
* Remove a previously added print listener.
* If <code>listener</code> is not the listener that has been added with
* {@link #addPrintListener addPrintListener}, an IllegalArgumentException
* Remove a previously added print listener. If <code>listener</code> is not the listener that
* has been added with {@link #addPrintListener addPrintListener}, an IllegalArgumentException
* will be thrown.
*
* @param listener the listener that had been added with
* <code>addPrintListener</code>
* @throws IllegalArgumentException <code>listener</code> is not the
* currently registered print listener or is <code>null</code>.
* @param listener the listener that had been added with <code>addPrintListener</code>
*
* @throws IllegalArgumentException <code>listener</code> is not the currently registered print
* listener or is <code>null</code>.
* @pre listener != null
*/
public void removePrintListener(PrintListener listener)
@ -270,9 +270,8 @@ public abstract class Widget extends DescriptiveComponent
}
/**
* Registers the ParameterModel of this Widget with the containing Form.
* This method is used by the Bebop framework and should not be used by
* application developers.
* Registers the ParameterModel of this Widget with the containing Form. This method is used by
* the Bebop framework and should not be used by application developers.
*
* @param form
* @param model
@ -285,12 +284,12 @@ public abstract class Widget extends DescriptiveComponent
}
/**
* Sets the Form Object for this Widget.
* This method will throw an exception if the _form pointer is already set.
* To explicity change the m_form pointer the developer must first call
* Sets the Form Object for this Widget. This method will throw an exception if the _form
* pointer is already set. To explicity change the m_form pointer the developer must first call
* setForm(null)
*
* @param form The <code>Form</code> Object for this Widget
*
* @exception IllegalStateException if form already set.
*/
public void setForm(final Form form) {
@ -304,10 +303,11 @@ public abstract class Widget extends DescriptiveComponent
}
/**
* Gets the Form Object for this Widget.
* Throws an exception if the Widget doesn't belong to a form.
* Gets the Form Object for this Widget. Throws an exception if the Widget doesn't belong to a
* form.
*
* @return the {@link Form} Object for this Widget.
*
* @post return != null
*/
public Form getForm() throws RuntimeException {
@ -320,8 +320,7 @@ public abstract class Widget extends DescriptiveComponent
}
/**
* Sets the <tt>ONFOCUS</tt> attribute for the HTML tags that compose
* this element.
* Sets the <tt>ONFOCUS</tt> attribute for the HTML tags that compose this element.
*
* @param javascriptCode
*/
@ -330,8 +329,7 @@ public abstract class Widget extends DescriptiveComponent
}
/**
* Sets the <tt>ONBLUR</tt> attribute for the HTML tags that compose
* this element.
* Sets the <tt>ONBLUR</tt> attribute for the HTML tags that compose this element.
*
* @param javascriptCode
*/
@ -340,8 +338,7 @@ public abstract class Widget extends DescriptiveComponent
}
/**
* Sets the <tt>ONSELECT</tt> attribute for the HTML tags that compose
* this element.
* Sets the <tt>ONSELECT</tt> attribute for the HTML tags that compose this element.
*
* @param javascriptCode
*/
@ -350,8 +347,7 @@ public abstract class Widget extends DescriptiveComponent
}
/**
* Sets the <tt>ONCHANGE</tt> attribute for the HTML tags that compose
* this element.
* Sets the <tt>ONCHANGE</tt> attribute for the HTML tags that compose this element.
*
* @param javascriptCode
*/
@ -360,8 +356,7 @@ public abstract class Widget extends DescriptiveComponent
}
/**
* Sets the <tt>ON_KEY_UP</tt> attribute for the HTML tags that compose
* this element.
* Sets the <tt>ON_KEY_UP</tt> attribute for the HTML tags that compose this element.
*
* @param javascriptCode
*/
@ -370,9 +365,8 @@ public abstract class Widget extends DescriptiveComponent
}
/**
* Sets the default value in the parameter model for this element.
* This is a static property and this method should not be invoked
* at request time (not even in a PrintListener).
* Sets the default value in the parameter model for this element. This is a static property and
* this method should not be invoked at request time (not even in a PrintListener).
*
* @param value
*/
@ -381,9 +375,8 @@ public abstract class Widget extends DescriptiveComponent
}
/**
* Marks this widget as readonly, which has the effect of preventing the
* user from modifying the widget's contents.
* This method can only be called on unlocked widgets.
* Marks this widget as readonly, which has the effect of preventing the user from modifying the
* widget's contents. This method can only be called on unlocked widgets.
*/
public void setReadOnly() {
Assert.isUnlocked(this);
@ -391,9 +384,8 @@ public abstract class Widget extends DescriptiveComponent
}
/**
* Marks this widget as disabled, which has the effect of preventing the
* widget's value being submitted with the form, and will typically cause
* the widget to be 'grayed out' on the form.
* Marks this widget as disabled, which has the effect of preventing the widget's value being
* submitted with the form, and will typically cause the widget to be 'grayed out' on the form.
* This method can only be called on unlocked widgets.
*/
public void setDisabled() {
@ -405,8 +397,9 @@ public abstract class Widget extends DescriptiveComponent
* Sets a popup hint for the widget.
*
* @param hint
* @deprecated refactor to use a GlobalizedMessage instead and use
* setHint(GlobalizedMessage hint)
*
* @deprecated refactor to use a GlobalizedMessage instead and use setHint(GlobalizedMessage
* hint)
*/
public void setHint(String hint) {
Assert.isUnlocked(this);
@ -424,7 +417,6 @@ public abstract class Widget extends DescriptiveComponent
// Assert.isUnlocked(this);
// setAttribute("hint", (String) hint.localize());
// }
/**
* Sets a Label for the widget.
*
@ -434,7 +426,6 @@ public abstract class Widget extends DescriptiveComponent
// public void setLabel(GlobalizedMessage label) {
// m_label = label;
// }
/**
* Sets a Label for the widget.
*
@ -444,7 +435,6 @@ public abstract class Widget extends DescriptiveComponent
// public GlobalizedMessage getLabel() {
// return m_label;
// }
/**
* Gets the default value in the parameter model for this element.
*
@ -463,30 +453,28 @@ public abstract class Widget extends DescriptiveComponent
}
/**
* The "pass in" property determines whether the value for this parameter
* is generally passed in from the outside.
* If this property is <code>true</code>, the model always tries to get the
* parameter value from the request, no matter whether the request is the
* initial request or a submission of the form to which the widget belongs.
* The "pass in" property determines whether the value for this parameter is generally passed in
* from the outside. If this property is <code>true</code>, the model always tries to get the
* parameter value from the request, no matter whether the request is the initial request or a
* submission of the form to which the widget belongs.
*
* <p>
* If this property is <code>false</code>, the parameter value is only read
* from the request if it is a submission of the form containing the widget.
* If this property is <code>false</code>, the parameter value is only read from the request if
* it is a submission of the form containing the widget.
*
* <p>
* By default, this property is <code>false</code>.
*
* @return <code>true</code> if an attempt should always be made to
* retrieve the parameter value from the request.
* @return <code>true</code> if an attempt should always be made to retrieve the parameter value
* from the request.
*/
public final boolean isPassIn() {
return getParameterModel().isPassIn();
}
/**
* Set whether this parameter should be treated as a "pass in" parameter.
* This is a static property of the ParameterModel and this method should
* not be invoked at request-time.
* Set whether this parameter should be treated as a "pass in" parameter. This is a static
* property of the ParameterModel and this method should not be invoked at request-time.
*
* @see #isPassIn
* @param v <code>true</code> if this parameter is a pass in parameter.
@ -497,10 +485,8 @@ public abstract class Widget extends DescriptiveComponent
}
/**
* The ParameterModel is normally set via the constructors.
* This method is only rarely needed.
* Please note that the previous ParameterModel and all its listeners
* will be lost.
* The ParameterModel is normally set via the constructors. This method is only rarely needed.
* Please note that the previous ParameterModel and all its listeners will be lost.
*
* @param parameterModel
*/
@ -510,11 +496,10 @@ public abstract class Widget extends DescriptiveComponent
}
/**
* Allows access to underlying parameterModel. The ParameterModel contains
* static (request-independent) properties of a Widget such as its name,
* default value and its listeners. The ParameterModel can not be modified
* once Page.lock() has been invoked (not even in a PrintListener).
* This is done after the Page has been built, normally at server startup.
* Allows access to underlying parameterModel. The ParameterModel contains static
* (request-independent) properties of a Widget such as its name, default value and its
* listeners. The ParameterModel can not be modified once Page.lock() has been invoked (not even
* in a PrintListener). This is done after the Page has been built, normally at server startup.
*
* @return
*/
@ -524,15 +509,14 @@ public abstract class Widget extends DescriptiveComponent
/**
* <p>
* This method creates the DOM for the widget. The method is called by the
* Bebop framework and should not be invoked by application developers.
* This method creates the DOM for the widget. The method is called by the Bebop framework and
* should not be invoked by application developers.
* </p>
*
* <p>
* The method first fires the print event allowing application developers
* to set certain properties of the Widget at request time in a
* PrintListener. The methods generateWidget and generateErrors will then
* be invoked to generate either of the following
* The method first fires the print event allowing application developers to set certain
* properties of the Widget at request time in a PrintListener. The methods generateWidget and
* generateErrors will then be invoked to generate either of the following
* </p>
*
* <p>
@ -580,8 +564,7 @@ public abstract class Widget extends DescriptiveComponent
/**
* The XML tag.
*
* @return The tag to be used for the top level DOM element generated for
* this type of Widget.
* @return The tag to be used for the top level DOM element generated for this type of Widget.
*/
protected String getElementTag() {
return BEBOP_FORMWIDGET;
@ -625,8 +608,7 @@ public abstract class Widget extends DescriptiveComponent
/**
* Generates the XML for the given widget.
* <p>
* Generates XML fragment:
* <code>&lt;bebop:formErrors message=... id=name>
* Generates XML fragment: <code>&lt;bebop:formErrors message=... id=name>
* &lt;/bebop:formErrors></code>
* </p>
*
@ -646,15 +628,15 @@ public abstract class Widget extends DescriptiveComponent
}
/**
* Get the value associated with this widget in the request described by
* <code>ps</code>.
* The type of the returned object depends on the <code>ParameterModel</code>
* underlying this widget. This method is typically called in a
* FormProcessListener to access the value that was submitted for a Widget
* in the Form.
* Get the value associated with this widget in the request described by <code>ps</code>. The
* type of the returned object depends on the <code>ParameterModel</code> underlying this
* widget. This method is typically called in a FormProcessListener to access the value that was
* submitted for a Widget in the Form.
*
* @param ps describes the request currently being processed
*
* @return
*
* @pre ps != null
* @post may return null
*/
@ -676,19 +658,19 @@ public abstract class Widget extends DescriptiveComponent
}
/**
* Set the value of the parameter associated with this widget to a new value.
* The exact type of <code>value</code> depends on the
* <code>ParameterModel</code> underlying the widget. This method is typically
* called in a FormInitListener to initialize the value of a Widget in the
* Set the value of the parameter associated with this widget to a new value. The exact type of
* <code>value</code> depends on the <code>ParameterModel</code> underlying the widget. This
* method is typically called in a FormInitListener to initialize the value of a Widget in the
* Form at request time.
*
* @param ps
* @param value
*
* @pre ps != null
* @post value == getValue(ps)
*
* @throws IllegalStateException the form to which the widget belongs has
* not been processed yet.
* @throws IllegalStateException the form to which the widget belongs has not been processed
* yet.
*/
public void setValue(PageState ps, Object value)
throws IllegalStateException {
@ -724,7 +706,9 @@ public abstract class Widget extends DescriptiveComponent
/**
*
* @param ps
*
* @return the parameter value for this widget
*
* @post returns null if the FormData are missing
*/
protected ParameterData getParameterData(PageState ps) {
@ -737,11 +721,10 @@ public abstract class Widget extends DescriptiveComponent
}
/**
* Respond to an incoming request by calling <code>respond</code> on the
* form to which the widget belongs. This method is called by the Bebop
* framework and should not be invoked by application developers. It is
* somewhat questionable that this method should ever be called, rather
* than having {@link Form#respond Form.respond()} called directly.
* Respond to an incoming request by calling <code>respond</code> on the form to which the
* widget belongs. This method is called by the Bebop framework and should not be invoked by
* application developers. It is somewhat questionable that this method should ever be called,
* rather than having {@link Form#respond Form.respond()} called directly.
*
* @throws javax.servlet.ServletException
* @pre state != null
@ -759,8 +742,8 @@ public abstract class Widget extends DescriptiveComponent
}
/**
* Specify a Widget. ValidationGuard implementation to use to determine if
* this widget should run its validation listeners.
* Specify a Widget. ValidationGuard implementation to use to determine if this widget should
* run its validation listeners.
*
* @param guard the Widget.ValidationGuard.
*/
@ -770,12 +753,13 @@ public abstract class Widget extends DescriptiveComponent
}
/**
* Inner interface used to determine if the validation listeners should be
* run for this widget or not.
* Inner interface used to determine if the validation listeners should be run for this widget
* or not.
*/
public interface ValidationGuard {
boolean shouldValidate(PageState ps);
}
/**
@ -792,6 +776,7 @@ public abstract class Widget extends DescriptiveComponent
* Adds an error to be displayed with this parameter.
*
* @param error A string showing the error to the user.
*
* @deprecated refactor to use addError(GlobalizedMessage) instead.
*/
public void addError(String error) {
@ -802,4 +787,5 @@ public abstract class Widget extends DescriptiveComponent
public String toString() {
return super.toString() + " [" + getName() + "]";
}
}

View File

@ -1482,9 +1482,11 @@ input#draft_search:active {
#content form fieldset {
border: none;
margin: 0.5em 0em 1em 0.3em;
border-top: 1px dotted #0776A0;
border-bottom: 1px dotted #0776A0;
padding: 0.3em 0em;
/*border-top: 1px dotted #0776A0; */
/*border-bottom: 1px dotted #0776A0; */
border: 1px dotted #0776A0;
/*padding: 0.3em 0em;*/
padding: 1em;
color: #0776A0;
font-weight: bold;
}
@ -1570,6 +1572,10 @@ div.bebopGridPanel{
margin-top: 15px;
}
.hint {
font-size: 1.6em;
}
.hint:hover:after {
position: absolute;
box-shadow: 0 0 5px #4a4a4a;
@ -1579,7 +1585,9 @@ div.bebopGridPanel{
top: auto;
right: auto;
width: 30%;
background-image: inear-gradient(top, #eeeeee, #cccccc);
font-size: 0.63em;
z-index: 65535;
background-image: linear-gradient(top, #eeeeee, #cccccc);
background-image: -webkit-gradient(linear,left top,left bottom,color-stop(0, #eeeeee),color-stop(1, #cccccc));
background-image: -webkit-linear-gradient(top, #eeeeee, #cccccc);
background-image: -moz-linear-gradient(top, #eeeeee, #cccccc);

View File

@ -171,6 +171,9 @@
-->
</xsl:if>
<xsl:call-template name="processLabel">
<xsl:with-param name="widget" select="."/>
</xsl:call-template>
<div style="width:560px; border:1px outset #666;">
<textarea id="ta_{@name}" name="{@name}" rows="{@rows}" cols="{@cols}" wrap="{@wrap}" style="width:100%">
<xsl:value-of disable-output-escaping="no" select="text()"/>
@ -245,6 +248,9 @@
</xsl:if>
<!-- EN End of FCKeditor setup -->
<xsl:call-template name="processLabel">
<xsl:with-param name="widget" select="."/>
</xsl:call-template>
<textarea id="ta_{@name}" name="{@name}" style="width:100%" rows="{@rows}" cols="{@cols}" wrap="{@wrap}">
<xsl:value-of disable-output-escaping="no" select="text()"/>
</textarea>
@ -305,6 +311,9 @@
</xsl:if>
<xsl:call-template name="processLabel">
<xsl:with-param name="widget" select="."/>
</xsl:call-template>
<textarea id="ta_{@name}" name="{@name}" rows="{@rows}" cols="{@cols}" wrap="{@wrap}" style="width:100%">
<xsl:value-of disable-output-escaping="no" select="text()"/>
</textarea>

View File

@ -112,6 +112,18 @@
<img alt="{$alt}" title="{$title}" src="{$src}"/>
</xsl:if>
<xsl:apply-templates/>
<xsl:if test="string-length(./@hint) &gt; 0">
<span class="hint">
<xsl:attribute name="content">
<xsl:value-of select="@hint"/>
</xsl:attribute>
<xsl:call-template name="mandalay:getSetting">
<xsl:with-param name="module" select="'bebop'"/>
<xsl:with-param name="setting" select="'hintSymbol'"/>
<xsl:with-param name="default" select="'(?)'"/>
</xsl:call-template>
</span>
</xsl:if>
</a>
</xsl:template>

View File

@ -208,15 +208,45 @@
<fieldset class="date">
<legend>
<xsl:value-of select="@label"/>
<xsl:if test="string-length(./@hint) &gt; 0">
<span class="hint">
<xsl:attribute name="content">
<xsl:value-of select="@hint"/>
</xsl:attribute>
<xsl:call-template name="mandalay:getSetting">
<xsl:with-param name="module" select="'bebop'"/>
<xsl:with-param name="setting" select="'hintSymbol'"/>
<xsl:with-param name="default" select="'(?)'"/>
</xsl:call-template>
</span>
</xsl:if>
</legend>
<xsl:apply-templates/>
</fieldset>
</xsl:template>
<xsl:template match="bebop:time">
<span class="time">
<!--<span class="time">
<xsl:apply-templates/>
</span>-->
<fieldset>
<legend>
<xsl:value-of select="@label"/>
<xsl:if test="string-length(./@hint) &gt; 0">
<span class="hint">
<xsl:attribute name="content">
<xsl:value-of select="@hint"/>
</xsl:attribute>
<xsl:call-template name="mandalay:getSetting">
<xsl:with-param name="module" select="'bebop'"/>
<xsl:with-param name="setting" select="'hintSymbol'"/>
<xsl:with-param name="default" select="'(?)'"/>
</xsl:call-template>
</span>
</xsl:if>
</legend>
<xsl:apply-templates/>
</fieldset>
</xsl:template>
<xsl:template match="bebop:fieldset">

View File

@ -24,8 +24,9 @@
<setting id="padding/showPadding">false</setting>
<setting id="padding/borderColor">cccccc</setting>
<!--<setting id="hintSymbol">(?)</setting>-->
<!--<setting id="hintSymbol">&#x2753;</setting>-->
<setting id="hintSymbol">(?)</setting>
<setting id="hintSymbol">&#x24d8;</setting>
<setting id="table/setImage/checkboxChecked">/images/bebop/checkBoxChecked.gif</setting>
<setting id="table/setImage/checkboxUnchecked">/images/bebop/checkBoxUnchecked.gif</setting>