Button states - Basics and Tips

Intro

Recently I answered several questions about button states, which proved that some information is missing. For that reason I checked the official Captivate document, and indeed to me it is not at all complete especially for buttons which are the most used interactive objects. You can have a look:

Work with multi-state objects in Adobe Captivate

Some examples: the InBuilt state 'Visited' is not mentioned at all. I couldn't find any information about the lock of InBuilt states for buttons and how to circumvent it. The recent added button types - SVG and Bitmap images - are not even mentioned. What is the meaning of the blue and red selection rectangles in button state objects? Several years ago I published an extensive blog about the InBuilt states for Drag&Drop objects (Inbuilt D&D states) to fill in gaps in the Help document.  With this blog I will try to summarize tips and workarounds for InBuilt states for buttons. After a short recapitulation of typical features of Button states, you'll get some examples.

Typical features

InBuilt states

Buttons of any type have by default three InBuilt states: Normal, Rollover and Down. Those three states are part of the object styles for text buttons, image buttons, transparent buttons and shapes (because they can always be converted to shape buttons). However no object styles can be created for bitmap images and SVGs used as buttons, the most recent types added in version 11.5. 

Less known is the fourth InBuilt state: Visited, probably because you always need to create that state. It cannot be included in the object style for the four mentioned button types neither which is a pity. Audio can be attached to the Visited state and Normal state, while that is impossible for the Rollover and Down state

InBuilt states will appear in specific situations. Rollover when hovering over the button, Down while button is pressed, Visited after the button has been pressed and released. However the Visited state can also be set using the Change State action which is impossible for any other InBuilt state (for buttons and D&D objects). Like with custom states, you can add Audio to the InBuilt states. Here are two tips based on that knowledge:

Tip 1: The Down state will disappear when you release the button. If you want to keep the down state after release, use the Visited state, looking identical to the Down state. This is valid for both responsive and non-responsive projects.

Lock Size/position

The size and position of the button is the same for all InBuilt states, based on what you designed for the Normal state. That is the reason for the lock symbol which you see on the stage when Rollover, Down or Visited are selected. 
The Normal state defines the clickable area, hence the Lock symbol. For all buttons, except the SVG used as button, this will always be the bounding box of the button. You can always edit or replace the content in a state but that content will be rescaled to the bounding box defined in the Normal state. In the example screenshot that content was a SVG where the clickable area was kept to the bounding box. That vector image type always keeps its height/width ratio. If you want to use another SVG in the Rollover or Down state, which needs more space, be sure to create a bounding box which is bigger than what is needed in the Normal state. Here is an example, the SVG in the Rollover state is wider, so the bounding box in the Normal state has a larger width.
In this example a different SVG was used in all the states. You cannot replace a SVG by a bitmap image, each replacement needs to be of the same type.

Tip 2: (answer to this thread in the eLearning community: Word Search) to create a highlight appearing after a click, use a shape button with 2 (or 4, the Rollover and Down are not important) states, one is the Normal state and the shape has no fill nor outline, the second one is a custom state where the shape has an outline. Use the action 'Go to Next State....' for that button. First click will show the custom state (outline), second click will revert to the Normal state.

Extra objects

Contrary to audio which can only be added to the InBuilt states Normal and Visited, you can add extra objects to all InBuilt states. However this is only possible in non-responsive (Blank) projects and in static fluid boxes. Normal fluid boxes do not allow adding extra objects to a state (due to the stack prohibition). 

This aspect opens a lot of tweaking possibilities. Those extra objects are not locked, nor do they need to be of the same type. Contrary to the locked button states which have a blue outline marker, extra objects will have a red outline marker (see screenshot under Tip 3). There is no real limit to the number of objects you can add. Whereas audio cannot be added to Rollover or Down states, you can add extra objects to those states.

Tip 3: Create a tooltip for a button by adding a text (or other object) to the Rollover state.

Tip 4: Quick Click/Reveal workflow, using a button with a custom state derived from the Normal state but with the Reveal objects added to it. Use 'Go to Next State' for that button, and you have a toggle button, which will hide the revealed objects when clicking again. When using a variable as explained here, you have even more control.

Tip 5: Can you increase the size of a shape button in Rollover state, was another recent question? The forementioned trick with a bigger bounding box in the Normal state is not functional in that case. Here is another possibility:

  • In the Rollover state make the shape button invisible. Depending on its setup this means Alpha for Fill set to 0, border width set to 0 and eventually take out the text.
  • Add a bigger image of the shape button to the Rollover state and align it as wanted.

Of course you can this also apply on the Down state and/or with a smaller version of the button, see screenshot:

Tip 6: Starting with an invisible Normal state for a shape button (Alpha and stroke set to 0) and adding an object to that state within the bounding box of the shape button, allows you to create a rotating button. A full description of the workflow can be found in this blog post. Of course this means the clickable area will be greater than the image itself, but most learners will not detect that incongruity.


Conclusion

You'll for sure know about more examples to use button states in a creative way. Feel free to post your ideas in a comment, always appreciated.