custom button

Not certain if I'm creating a custom button correctly. I don't see an option to create a custom button, so I create a standard button and replace the states with my own images. The button appears to "function", but I don't get a selection border when I click on it, and the size dimensions appear to retain the original button size in the button properties.

4 Replies
Jesse Spinella

You don't necessarily need to insert a button for a "custom button." You can turn any object into a button simply by adding a trigger that says "do x when user clicks."

You can add any amount of your own states to an object. So, if you want a shape to "hover" create a new state, change the shape fill, the outline, etc. and it'll act just like a hover. Since "hover" is a built in state on any object, you don't need to set up a trigger for the "hover effect." Just preview the project and roll your mouse over the object. It'll hover automatically.

Your other button commands like visited, selected, etc are built in states. As long as you name the object's state like a normal button's state, you can set up your own buttons with a trigger command.

Jesse Spinella

Sure, no problem.

I just make sure to name the shape's states the same as what's in the standard buttons if I don't want to make a trigger to call up a custom function of the button. (Like execute java script, adjust variable, etc.).

That allows you to not have to create a trigger for built in states to behave the same as a standard button.