Ah, me idiot. on_key is a function call without the use of (), right? No wonder i didn't get it to work. I expected a () for a function call ...

Okay, got the syntax error sorted too. Gave me an error because toggle is reserved by the engine (grr, everything you need is always reserved, and so you cannot use for what you really need it). Using another word like toggl solved it

So i have two working ways now. Thanks for your help

EDIT: Wow, lots of pitfalls here. on_f11 overrides the default.c f11 functions. And so the default values and the wire doesn't show anymore. So i have to use the if (key_f11) for my case here.