Reaching the chapter "buttons" when starting with Godot (and I'm still a beginner!), I tried the built-in buttons (everything aimimg for touch-devices), wasn't satisfied and therefor attempted to build my own ones with Area2D, CollisionShapes and some code.
I wanted several behaviours like auto-cancelling when holding down for some time (so no release) and sliding the finger off the button to cancel as well while a neighbouring button should not react when sliding on at the same time, things like that. And in the end I succeeded with all kinds of hacky things like
func _on_Button1Area_input_event(_viewport, _event, _shape_idx):
if Input.is_action_just_pressed("mousebuttonclick"):
ignore_release = false
ignore_tap = false
ignore_slide
if Input.is_action_just_released("mousebuttonclick"):
ignore_tap = true
func _on_Button1Area_mouse_exited():
...
func _on_Button1Area_mouse_entered():
ignore_release = true
ignore_tap = true
ignore_slide = true
return
but first and foremost setting up input_pickable = true
or = false
all over the place...
Until I realized that one majour thing coming up next wouldn't work with that setup: placing my button behind a "stop-input" label to have it not react when tapped worked fine, but it turned out that my buttons (so my CollisionShapes) in front of the label didn't recognize input as well in that case - which rendered the whole thing useless for me.
But: the bulit-in buttons actually do react as they should, so I basically went back to formula and started hacking these on-board buttons like I did my own before.
I'm not sure if all this is helpful for you, but somehow I was able to tweak the button-control nodes to my liking using this kind of functions-variables-setup. I'm still building my own "pretty" butons on top of the "real" ones, and I didn't stumble over any problematic situation since.
Good luck with your project!