You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@royale.apache.org by ca...@apache.org on 2020/08/13 12:18:12 UTC
[royale-asjs] branch develop updated: jewel: more docs for Group
and Container
This is an automated email from the ASF dual-hosted git repository.
carlosrovira pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/royale-asjs.git
The following commit(s) were added to refs/heads/develop by this push:
new 0dd6385 jewel: more docs for Group and Container
0dd6385 is described below
commit 0dd6385fc44b66b6a3c8ef401c52c463be749f02
Author: Carlos Rovira <ca...@apache.org>
AuthorDate: Thu Aug 13 14:17:54 2020 +0200
jewel: more docs for Group and Container
---
.../royale/org/apache/royale/jewel/Container.as | 42 +++++++++++-----------
.../main/royale/org/apache/royale/jewel/Group.as | 8 +++--
2 files changed, 27 insertions(+), 23 deletions(-)
diff --git a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/Container.as b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/Container.as
index 0225651..7584535 100644
--- a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/Container.as
+++ b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/Container.as
@@ -31,36 +31,36 @@ package org.apache.royale.jewel
[DefaultProperty("mxmlContent")]
/**
- * The Container class implements a basic container for
- * other controls and containers. The position and size
- * of the children are determined by a layout while the size of
- * a Container can either be determined by its children or by
- * specifying an exact size in pixels or as a percentage of the
- * parent element.
+ * The Jewel Container class is a container that adds up to the features
+ * already provided by Jewel Group.
+ *
+ * The position and size of the children are determined by BasicLayout
+ * while the size of a Container can either be determined by its children or by
+ * specifying an exact size in pixels or as a percentage of the parent element.
+ * You can swap the layout for any other one available making children arrange
+ * in different ways (i.e: horizontal, vertical,...)
*
- * This Container does not have a built-in scroll bar or clipping of
- * its content should the content exceed the Container's boundaries. To
- * have scroll bars and clipping, add the ScrollingView bead.
- *
+ * Container clip content by default thanks to its Viewport bead. This bead can
+ * also manage clipping trough `clipContent` property. To add scrolling functionality
+ * Viewport bead can be changed by ScrollingViewport.
+ *
+ * Other Group feature are "View States" to provide state management to show diferent
+ * parts to the user.
+ *
+ * Finally Container can add elements directly to the strand (throught `strandChildren`
+ * property) instead to its view content unlike the `addElement()` APIs which place
+ * children into the contentView.
+ *
* While the container is relatively lightweight, it should
* generally not be used as the base class for other controls,
* even if those controls are composed of children. That's
* because the fundamental API of Container is to support
* an arbitrary set of children, and most controls only
* support a specific set of children.
- *
- * And that's one of the advantages of beads: that functionality
- * used in a Container can also be used in a Control as long
- * as that bead doesn't assume that its strand is a Container.
- *
- * For example, even though you can use a Panel to create the
- * equivalent of an Alert control, the Alert is a
- * control and not a Container because the Alert does not
- * support an arbitrary set of children.
*
- * @toplevel
+ * @toplevel
* @see org.apache.royale.jewel.beads.layout
- * @see org.apache.royale.jewel.supportClasses.scrollbar.ScrollingViewport
+ * @see org.apache.royale.jewel.supportClasses.Viewport
* @langversion 3.0
* @playerversion Flash 10.2
* @playerversion AIR 2.6
diff --git a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/Group.as b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/Group.as
index de5b2e1..af4ef97 100644
--- a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/Group.as
+++ b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/Group.as
@@ -34,10 +34,14 @@ package org.apache.royale.jewel
* The Jewel Group class provides a light-weight container for visual elements.
*
* By default Group have a Basiclayout, allowing its children to be positioned using absolute
- * values (Notice Basic version doesn't provide any layout at all).
+ * values (Notice Basic version doesn't provide any layout at all). You can swap the layout
+ * for any other one available making children arrange in different ways (i.e: horizontal, vertical,...)
*
* Group doesn't clip content so elements inside the group aren't hidden far beyond group boundaries.
- * Also, no scrolling support is built in Group.
+ * Also, no scrolling support is built in Group. Group doesn't have any chrome or visuals just
+ * position inner childs.
+ *
+ * Other Group feature are "View States" to provide state management to show diferent parts to the user
*
* For scrolling and clipping you can use Jewel Container
*