macros:example:parkselectedfixtures
This is an old revision of the document!
Table of Contents
Example
Patch - Park selected fixtures
by: | Gregory Haynes, August 2019 |
---|---|
published: | see http://forum.avolites.com/viewtopic.php?f=20&t=6207&p=22282 |
description: | Parks the currently selected fixtures |
functions
affected properties
The repatch menu does not actually use the PatchSelection, it has its own property Patch.Repatch.SelectedFixtureHandles.
Code
- ParkSelectedFixtures.xml
<?xml version="1.0" encoding="utf-8" ?> <avolites.macros xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="Avolites.Menus.xsd"> <macro id="Avolites.Macros.ParkSelectedFixtures" name="Park Selected Fixtures"> <description>Parks the currently selected fixtures.</description> <sequence> <step>Programmer.Editor.Selection.GetSelectedHandles("Windows.PatchView.Handles")</step> <step>Handles.SetSourceHandleRangeFromHandles(Windows.PatchView.Handles, true)</step> <step>Patch.Repatch.SetDmxAddressesFromSelectedFixture()</step> <step>Patch.Repatch.ParkSelectedFixtures()</step> <step>Handles.ClearSelection()</step> </sequence> </macro> </avolites.macros>
Explanation
This explains the functional steps within the sequence. For all the other XML details please refer to Formats and syntax
- The first line retrieves the current selection and stores it in a menu property, it is not important which one just that it is the correct type.
- From that we then set the source handle selection (this is the same selection that is used for copy, move, set legend etc.).
- The third line copies the source handle selection to the Repatch property (and initialises other properties used in the repatch menu).
- The forth line performs the Park operation and
- the last line clears the source handle selection once you are done.
How to use it
- When needed, select some fixtures and apply this macro in order to park these fixtures.
You could leave a comment if you were logged in.
macros/example/parkselectedfixtures.1565852958.txt.gz · Last modified: 2019/08/15 07:09 by icke_siegen