menu_button icon indicating copy to clipboard operation
menu_button copied to clipboard

Transparent toggledChild, vertical offset for the menu, border in opened state

Open plavunov opened this issue 3 years ago • 1 comments

Hi! This is what I am trying to achieve: desired

I was able to make the title child look the way I need: current-closed

But then, I ran into trouble. I was trying to make the toggledChild transparent by all possible means, but it either keeps instantiating it as a white box, or just removes it (which shifts the menu in an undesired way). current-opened

Also, it would be especially useful if there was a way to provide a vertical offset for the menu, in order to achieve the desired menu look (because the initial title child needs to stay in place)

Finally, do you think it's possible to provide a border that would only be visible when the menu is opened?

Thanks!

plavunov avatar Mar 11 '21 21:03 plavunov

Hi,

By using the following properties you should have a transparent background for the whole menu button.

itemBackgroundColor: Colors.transparent,
menuButtonBackgroundColor: Colors.transparent,

Now about the border you should have a way with decoration property with a custom border ;)

For instance:

decoration: BoxDecoration(
    border: Border.all(
    color: Colors.black,
        width: 1,
    ),
),

huextrat avatar Mar 23 '21 13:03 huextrat