Resizable

Version 7 by Ken Fyten
on Nov 13, 2014 12:23.


compared with
Current by Arturo Zambrano
on Dec 11, 2014 04:14.


 
Key
These lines were removed. This word was removed.
These lines were added. This word was added.

View page history


There are 2 changes. View first change.

 h2. Overview
 _Since 3.0_
  
 The {{<ace:resizable>}} component is used to give another component the capability of being resized.
  
 {tip}See the ICEfaces Showcase [Live Demo|http://icefaces-showcase.icesoft.org/showcase.jsf?grp=aceMenu&exp=resizableBean] of this component, complete with source code.{tip}
  
 h2. Getting Started
  
 The component we want to make resizable is specified as the value of the {{for}} attribute.
  
 {panel}
 {code:xml|borderStyle=dashed}
 <h:panelGroup id="panel">
 </h:panelGroup>
  
 <ace:resizable for="panel" />
 {code}
 {panel}
  
 Alernatively, the {{for}} value can be omitted, and the parent component will be made resizable.
  
 {panel}
 {code:xml|borderStyle=dashed}
 <h:panelGroup id="panel">
  <ace:resizable />
 </h:panelGroup>
 {code}
 {panel}
  
 h2. Attributes
 {tip:title=TagLib Documentation}This section covers attributes involved in the typical use-cases for this component. For reference, the complete taglib documentation for this component is available [here|http://www.icefaces.org/docs/v4_latest/ace/tld/ace/resizable.html].{tip}
 {panel}
 *for* Specifies the id of the component to make resizable..
 {panel}
 {panel}
 *handles* Comma-separated list of handles to use. Possible values are n, e, s, w, ne, se, sw, nw. Default value is "e, s, se".
 {panel}
 {panel}
 *ghost* Boolean value to specify whether a semi-transparent helper element is shown for resizing
 {panel}
 {panel}
 *containment* Boolean value to specify whether the resizable element should be restricted to its parent's boundaries.
 {panel}
 {panel}
 *aspectRatio* Boolean value to specifies whether the aspect ratio of the element should be maintained when resizing.
 {panel}
  
 h2. Event Listeners
  
 | resizeListener | Listener for the end of resize event. |
  
 h2. Client Behavior Events
  
 | resize | Fired at the end of a resize operation (default event). |
  
 h2. JavaScript APIs
  
 Javascript callbacks can be supplied in the {{onStart}}, {{onError}}, {{onSuccess}}, and {{onComplete}} attributes of the {{<ace:ajax />}} tag for the {{resize}} event. The {{onStart}} callback must explicitly return true if the ajax event is to continue.
  h4. ICEfaces 3.x
  
 The client side component object is exposed through the global variable name specified in the *widgetVar* attribute.
  
 h4. ICEfaces 4+
  
 The "widgetVar" attribute on the ACE components has been removed in ICEfaces 4 and in its place a new "ice.ace.instance()" client JavaScript object lookup API has been introduced. The reason for this change is to enable lazy-initialization of the ACE component JavaScript objects to improve runtime performance and reduce browser memory use.
  
 {code}var widget = ice.ace.instance('frm:componentId);{code}
  
 {tip}The _ice.ace.instance_ function requires the _full_ client id of the component to be specified, such as "j_idt77:componentId" instead of just "componentId". To reduce the complexity of working with complete IDs with this function it may be preferable in some cases to use {{prependId="false"}} in the enclosing form (e.g. _<h:form prependId="false">_).{tip}
  
 {info}This component doesn't have a client-side API made specifically to be used by application developers. However, the component's internal methods and variables can be accessed in this way, including the underlying jQuery object and objects from underlying Javascript libraries (if applicable), and can be used for whatever purpose a developer might have in mind.
 {info}
  
 {tip}Javascript callbacks can be supplied in the {{onStart}}, {{onError}}, {{onSuccess}}, and {{onComplete}} attributes of the {{<ace:ajax />}} tag for the {{resize}} event. The {{onStart}} callback must explicitly return true if the ajax event is to continue.{tip}
  
 h2. Keyboard and ARIA support
  
 There is no keyboard and ARIA support.
  
 h2. CSS Classes
  
 This component adds one or more of the following nodes to a container, serving as handles to resize it.
  
 {code:xml}
 <div class="ui-resizable-handle ui-resizable-n" style="z-index: 1000;"></div>
 <div class="ui-resizable-handle ui-resizable-e" style="z-index: 1000;"></div>
 <div class="ui-resizable-handle ui-resizable-s" style="z-index: 1000;"></div>
 <div class="ui-resizable-handle ui-resizable-w" style="z-index: 1000;"></div>
 <div class="ui-resizable-handle ui-resizable-se ui-icon ui-icon-gripsmall-diagonal-se" style="z-index: 1000;"></div>
 <div class="ui-resizable-handle ui-resizable-sw" style="z-index: 1000;"></div>
 <div class="ui-resizable-handle ui-resizable-ne" style="z-index: 1000;"></div>
 <div class="ui-resizable-handle ui-resizable-nw" style="z-index: 1000;"></div>
 {code}
  
 h2. Known Issues
  
 None, at the moment.
  
 h2. Other Resources
  
 ICEfaces Showcase application, ace:resizable demo.

© Copyright 2018 ICEsoft Technologies Canada Corp.