User Tools

Site Tools


macros:example:changemacrospage

Example

Pages - Change Macros Page

by: Sebastian Beutel, Sep. 2015
published: not really published but discussed with O.Waits and P.Budd
description: Macros to change page of the Macros keys
remarks: To my mind, such macros would be useful in particular on Tiger Touch. However, They do not fully work as Avolites never intended these buttons to be paged.

This was literally the first macro I wrote: there were these macros to change page for the static playbacks, and I was curious to see if I could make other use of this. I found the appropriate functions (Handles.Macros.PreviousPage() and Handles.Macros.NextPage()) simply by try and error. [S.Beutel]

Current state

  • “Static Macros Page -1” ( Handles.Macros.PreviousPage() ) decrements as expected – but you can go down to page 0 which probably isn't intended
  • “Static Macros Page +1” ( Handles.Macros.NextPage() ) doesn’t increment, but always goes to page 1 – which is wrong

functions

Code

ChangeMacrosPage.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 Buttons Page Change -->
  <macro id="Avolites.Macros.ChangeToMacrosPage1" name="Static Macros Page 1">
    <description>Changes the macros page to page 1.</description>
    <sequence>
      <step>Handles.Macros.ChangePage(0)</step>
    </sequence>
  </macro>
 
  <macro id="Avolites.Macros.ChangeToMacrosPage2" name="Static Macros Page 2">
    <description>Changes the macros page to page 2.</description>
    <sequence>
      <step>Handles.Macros.ChangePage(1)</step>
    </sequence>
  </macro>
 
  <macro id="Avolites.Macros.ChangeToMacrosPage3" name="Static Macros Page 3">
    <description>Changes the macros page to page 3.</description>
    <sequence>
      <step>Handles.Macros.ChangePage(2)</step>
    </sequence>
  </macro>
 
  <macro id="Avolites.Macros.ChangeToMacrosPage4" name="Static Macros Page 4">
    <description>Changes the macros page to page 4.</description>
    <sequence>
      <step>Handles.Macros.ChangePage(3)</step>
    </sequence>
  </macro>
 
  <macro id="Avolites.Macros.PreviousMacrosPage" name="Static Macros Page -1">
    <description>Goes to the previous macros page.</description>
    <sequence>
      <step>Handles.Macros.PreviousPage()</step>
    </sequence>
  </macro>
 
  <macro id="Avolites.Macros.NextMacrosPage" name="Static Macros Page +1">
    <description>Goes to the next macros page.</description>
    <sequence>
      <step>Handles.Macros.NextPage()</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

Each macro simply calls a specific ChangePage() function with the index of the designated page.

How to use it

  1. If you copy this macro to a hardware macro button this will vanish when changing its page. Consider setting its properties to Handle Paging Locked in playback options.
You could leave a comment if you were logged in.
macros/example/changemacrospage.txt · Last modified: 2019/04/27 21:27 by sideshowbond