To add a component, open the Perspective Components palette. Click on the component you want and drag it onto your View. In this example, we put a Label component under the Gauge component.
Using the mouse is the most common way to select components. Click on a component to select it, double-click on it to Deep Select it (more on that later).
You can also select components by clicking and dragging the mouse to draw a selection rectangle. If you drag the window left-to-right, it will select all components that are completely contained within the rectangle. If you drag the window right-to-left, it will select all components that the rectangle touches. Lastly, you can start dragging a window selection and then hold-down the Alt key to use touch selection. This will draw a line as you drag, and any components that the line touches will become selected. As you're using these techniques, components that are about to become selected will be given a yellow highlight border.
By selecting nodes in the Project Browser tree you can manipulate the current selection. This is a handy way to select the current view, the root for the container, and any components on the view. This is also the only way to select components that are invisible.
Perspective makes great use of its many containers to help create a layout and design to fit any scenario on any device. To accommodate this, components sometimes need to be nested within a series of containers, which are themselves nested in other types of containers. With this comes a true tree of components, and selecting components nested inside containers works differently than components on the root. Deep Selection allows you to select into a container and select a component within.
To deep select a component, double click on it. Three things happen to indicate that the component is deep selected:
This lets you know that you have deeply selected into the component and not just selected the component itself. Once inside this new deep selection space, you can then select a component much like before, either by clicking or dragging to select components, or by deep selecting into another container inside the original container.
To cancel the deep selection, click anywhere outside of the component. In the following example, the Temperature component is deep selected.
When working with components in the Designer, you can right click to get quick access to options.
The top portion of the menu is similar to an edit menu in that it provides much of the basic copy/paste functionality
Function | Icon | Description |
---|---|---|
Cut | Removes the selected component but keeps a copy on the clipboard. You can also use the Ctrl-X shortcut to quickly cut a component. | |
Copy | Copies the selected component to the clipboard. You can also use the Ctrl-C shortcut to quickly copy a component. | |
Paste | Pastes the current contents of the clipboard. You can also use the Ctrl-V shortcut to paste. | |
Duplicate | Duplicates the selected item (essentially a fast copy and paste action). Components can also be duplicated by dragging them and holding down the Ctrl key. You can also use the Ctrl-D shortcut to quickly duplicate a component in place. | |
Delete | Deletes the currently selected component. This can also be done using the delete key. |
The z-order is the order in which two-dimensional objects are stacked, for example shapes in a graphic that overlap each other. In Perspective, z-order defines relative order of components when they overlap. There are four z-order icons and actions that will reorder any selected components.
Icon | Action |
---|---|
Move the selected components to the back of the z-order. | |
Move the selected components backward in the z-order relative to any overlapping components. | |
Move the selected components forward in the z-order relative to any overlapping components. | |
Move the selected components to the front of the z-order. |
In the following example, we have an image component with a photo of a warehouse, an icon, and a label. We placed an icon (the truck) and a label "Local Delivery" on the view as well, and then set the z-order so the label is on top, the truck icon is in the middle, and the image in the background.
Manipulating components can be done with both the mouse and the keyboard. You can move components around, resize them, and rotate them.
To move the component, click on it once then drag it anywhere within the container's bounds.
When you click on the component you want to resize, you'll see eight handles displayed around the edge of the selection. When you click on a handle, the mouse cursor will change to a two-way arrow. Use the mouse to drag the handle and change the size of the component. You can also select multiple components and resize them together. To resize around the center of the current selection, hold down Shift.
You can also resize the current selection using the keyboard. To nudge the right or bottom edge of the selection in or out, use Shift combined with the arrow keys, which resizes by the nudge distance, which defaults to one pixel at a time. To nudge the top or left edge of the selection, use Ctrl-Shift combined with arrow keys.
New alignment tools are available in the Perspective Designer Toolbar. These tools allow easy alignment of selected components within a Coordinate Container including align top, bottom, left, right, as a row, and as a stack. Align as row, and align as stack include a normalize version, that adjusts the size of the selected components to match the component that was selected first. Rotated components being aligned will correctly align along the top-most, bottom-most, left-most, right-most point of the rotated component. If a rotated component is being normalized is within the group that is being aligned, normalizing the component will adjust the pre-rotated dimensions.
These tools can only be used with components in a Coordinate container. |
Icon | Function | Description |
---|---|---|
Align Left | Align the left edges of a group of components. | |
Align Right | Align the right edges of a group of components. | |
Align Top | Align the top edges of a group of components. | |
Align Bottom | Align the bottom edges of a group of components. | |
Align Centers Horizontal | Aligns all of the selected components horizontally on their centers. | |
Align Centers Vertical | Aligns all of the selected components vertically on their centers. | |
Align as Row | Aligns all of the components on their centers as a row, and will add padding between them that you can select. | |
Align as Row and Normalize | Aligns all of the components on their centers as a row, and changes the size of all of the components to the first selected component. If a rotated component is within the group that is being aligned, normalizing the component will adjust the pre-rotated dimensions. | |
Align as Stack | Aligns all of the components on their centers as a stack, and will add padding between them that you can select. | |
Align as Stack and Normalize | Aligns all of the components on their centers as a stack, and changes the size of all of the components to the first selected component. If a rotated component is within the group that is being aligned, normalizing the component will adjust the pre-rotated dimensions. | |
Center Horizontally | Centers the currently selected components horizontally. | |
Center Vertically | Centers the currently selected components vertically. |
In the following example, we have a stack of buttons that are various sizes. We want to align them, stack them with equal space in between them, and make them all the same size.
|
When you drag a component near another component in a Container, Alignment Guidelines appear to help you better align your elements.
The Designer also has Vertical and Horizontal guide that can be set up to help you align components. For more information, see Vertical and Horizontal Guides.
Alignment Guides ExampleIn the following example we've added a Label component beneath a Cylindrical Tank component. I want to align the label so that it is centered with the center line of the tank.
|
Components place on coordinate containers can be rotated. As of 8.0.6 the Rotate property has been moved to the Position Properties section of the Perspective Property Editor. For a definition of all the position properties, see Views and Containers in Perspective and the individual container pages. Rotated components being aligned to other components will correctly align along the top-most, bottom-most, left-most, right-most point of the rotated component.
There are two ways to rotate a component:
The rotation anchor sets the point of rotation around which the component will be rotated.
If a component is smaller than 28px by 28px, the rotation handle and anchor + symbol are not displayed. Use the property editor to set rotation and anchor properties in this case. |
Example 1The following example shows icon component at default (no rotation), at 18 degrees rotation, and then at 39deg rotation with the rotation anchor (point of rotation) placed over the earth image. In the latter, the icon has a better angle in relation to the earth graphic. Example 2If a rotated component is within the group that is being aligned, normalizing the component will adjust the pre-rotated dimensions. The component on the left of the following image are not aligned but were resized at some point. The components on the right show what they look like after align stack and normalize. |
Many components in Perspective contain a image.source
property, that allows you to show an image on the component. The property expects a URL to the image, which can either be on the internet or something that is stored on the Gateway. For example, here is a Button component with an image:
Simply enter the wed-address for the image you wish to display. Both raster images and SVGs can be displayed via this method.
Images stored in Image Management are available at http://{your gateway's IP address}:{your gateway's port}/system/images/{path to your image
}.
http://gatewayIpAddress:8088/system/images/Builtin/icons/24/lightbulb_on.png |
For additional information on using images in Perspective, see Images, SVGs, and Icons in Perspective.