A jQuery plugin that applies highlight and shadow effects to text in a control. If you find this plugin useful please vote for it on the jQuery site.
This page provides a documentation reference for working with the plugin v1.0.0. See a demonstration of the label effect plugin and download the code from there. Or see a minimal page that you could use as a basis for your own investigations.
A separate label effect instance is created for each targetted control:
$(selector).labeleffect();.
Each instance may have different settings, e.g.
$(selector).labeleffect({effect: 'echoed'});
Below are the options that may be applied to each label effect instance.
color | effect | hiBlend | hiColor | hiDir | hiFill | hiOffset | shadowBlend | shadowColor | shadowDir | shadowFill | shadowOffset
addEffect | change | destroy | getEffects | setDefaults
| Signature | Returns | Comments |
|---|---|---|
| $.labeleffect.setDefaults(settings) | LabelEffects | Update the default instance settings (see above) to use with all label effect instances. |
| $.labeleffect.addEffect(id, settings) | LabelEffects | Add a new named effect.id (string) is the name of the effectsettings (object) is the settings for this effect and should contain
color,
hiColor,
hiDir,
hiOffset,
hiFill,
hiBlend,
shadowColor,
shadowDir,
shadowOffset,
shadowFill,
and shadowBlend |
| $.labeleffect.getEffects() | object | Retrieve the list of named effects. The attributes of the returned object are the named effects and their values are the settings for that effect. |
| $(selector).labeleffect('change', settings) | jQuery object | Update the settings for the label effect instance(s) attached to the given control(s).settings (object) is the set of new
options. |
| $(selector).labeleffect('change', name, value) | jQuery object | Update one setting for the label effect instance(s) attached to the given control(s).name (string) is the property namevalue (any) is the property value |
| $(selector).labeleffect('destroy') | jQuery object | Remove the label effect functionality from the given control(s). |
Contact Keith Wood at kbwood{at}iinet.com.au with comments or suggestions.