Lemur button: How to apply the button down effect on own style

I would like to ask another small lemur question, as I could not figure it out yet.

I applied an own style on button

  Attributes attrs = style.getSelector("button", "OSG");

... somewhere else

later I call the button like that

  ElementId id = new ElementId("button");    
  Button B1 = new Button((String) getState(Config_AppState.class).getconfiglang(),id);

If I click the button I cant see the down movement, that I can see with the glass style. Even if I add lines like

     B1.setShadowOffset(new com.jme3.math.Vector3f(2, -2, -1));
     B1.setBackground(new QuadBackgroundComponent( new ColorRGBA(0.5f, 0.75f, 0.85f, 0.5f) ));

that is showing a background layer I cant see the effect.

I have searched the lemur library (like button.java, glass-style etc.) and found things like that runEffect(EFFECT_CLICK); etc. but still I am not able to figure out where the buttonw down effect of glass style is located.

My questions are:

How can I apply or use the same effect as in button glass style ? (is it an animation/tween?)
Why/where is the button effect lost during the setting of my own style ?
I also made my own style (with the same name) for label and container! Does this have an influence on button (due to inheritance) ?

The default glass style sets some automatic button commands to do the pressed/unpressed movement. starting here:

And finally setting the commands here:

Hopefully it is straight forward to figure out how to adapt that to Java code (if necessary). Let me know if that’s not the case.

It seems that is exactly the code I was searching all the time!

In fact I may need to “copy” the command (source.move) and set it with

I will only come back, if I cant make it.

Thank you for the help.

Here is the solution that worked for me. I implement the desired behaviour as a style and not as commands to new buttons.

 Attributes attrs = style.getSelector("button", "mystyle");
 // the "moving" of the button
 Command<Button> pressedCommand = new Command<Button>() {
            public void execute( Button source ) {
                if( source.isPressed() ) {
                    source.move(1, -1, 0);
                } else {
                    source.move(-1, 1, 0);

// list of commands + we add the example command
  List<Command<Button>> commandlist = new ArrayList<>();

// Map of Buttonactions and commands, we add it for "button clicked/unclicked"
 Map<Button.ButtonAction,List<Command<Button>>> commandMap = new HashMap<>();

// finally we add it to the style