HomefieldOfView | SPi-V dev

Legend

  • required
  • not yet implemented

Navigation

user

<uigroup>

Description

Multiple uielements can be grouped in a uigroup. This group of elements can be moved around the scene, hidden and revealed as well als enabled and disabled as a single entity.

It is not necessary to specify a root group; uielement nodes can reside directly in the scene node.

Syntax

<tour>
  <scene>
    <uigroup id="groupID"
      halign="center" valign="center" zorder="0" 
      visible="true" enabled="true" >
      <uielement />
      ...
    </uigroup>
    ...
    <uielement />
    ...
  </scene>
</tour>

Attributes

  • id
    Unique id to reference the group by.
  • src
    Optionally specifies an external XML file that describes this node. If src is specified, node attributes and any inline child elements are replaced by the child elements specified in the external file. The external file should be SPi-V XML file, and contain at least a single uigroup node.
  • width
    Horizontal dimension of the group. Child elements of the group are not scaled, but the width proprerty is used to place child uielements.
    Values: either pixel values or a percentage of the element's parent uigroup. If a negative value is specified, the width is calculated as the width of the parent group element less the specified amount.
  • height
    Vertical dimension of the group. Child elements of the group are not scaled, but the height proprerty is used to place child uielements.
    Values: either pixel values or a percentage of the element's parent uigroup. If a negative value is specified, the width is calculated as the width of the parent group element less the specified amount.
  • halign
    Specifies the horizontal alignment to the element's parent uigroup or viewer rectangle.
    Values: center, left, right, defaults to center.
  • valign
    Specifies the vertical alignment to the element's parent uigroup or viewer rectangle.
    Values: center, top, bottom, defaults to center.
  • hoffset
    Horizontal offset of the element. Depending on the halign value, the hoffset is calculated from the center, left or right edge of the image.
    Values: either pixel values or a percentage of the element's parent uigroup.
  • voffset
    Vertical offset of the element. Depending on the valign value, the voffset is calculated from the center, top or bottom edge of the image.
    Values: either pixel values or a percentage of the element's parent uigroup.
  • rotation
    Sets the rotation along the axis perpendicular to the screen.
    Values: -360 to 360, defaults to 0
  • zorder
    Sets the depth sort order of the group as a whole. The sort order of each of the children of the group are set individually using the children's zorder property.
    Values: 0 to 9, defaults to 0
  • visible
    Shows/hides all the child elements.
    Values: true/false, defaults to true
  • enabled
    Enables/disables all child elements (while remaining visible)
    Values: true/false, defaults to true

Events

  • enter
    Fires when the pointer is moved over an element in the group.
  • leave
    Fires when the pointer leaves the an element in the group.
  • press
    Fires when the user presses the mouse button while over an element in the group.
  • release
    Fires when the user releases the mouse button after the press event has fired for an element in the group.
  • ready
    Fires when all the elements in this group are done building.

Children

History

  • 04-Dec-07: Added missing rotation attribute
  • 22-Mar-07: Added events
  • 06-Jun-05: Updated zorder attribute
  • 13-Oct-04: Updated src attribute
  • 08-Jun-04: Added width and height, changed offset values to support percentages
  • 18-Apr-04: Initial version

relativeurl=""

In your toolbar scriptlet you use this atribute in the "uigroup" node: "relativeurl="#"", but I cant find any documentation on it?

Re: relativeurl=""

What does relativeurl="#" do, as used in toolbar.xml?
I can't get toolbar to run with uigroup src="toolbar.xml" in my.xml
Toolbar works when I put all the toolbar.xml code into my.xml, but not with the src call.
I thought maybe the relativeurl param could be the problem.
Here's a link if it helps
http://www.karpolaw.com/photos/showSpi-V.php?pano=mygallery_test1.xml&bg...

Thanks, Mark Karpo.

Re: relativeurl=""

relativeurl="#" makes all the paths to files specified in the scriptlet relative to the scriptlet file (as opposed to relative to the main XML file).

Re: relativeurl=""

I think your problem may be related to the fact that you have a 'global' node nested in a 'scene' node, which is not 'allowed'.