install xdotool (extras-devel, ususal warnings apply)
install shortcutd
open shortcutd settings, assign proximity sensor to custom shell command and add the following command
xdotool key space
now go to contacts and tap the proximity sensor. The search box will open, so you can click on it and use whatever virtual keyboard you have installed
Just remember that the proximity sensor in a while that I work with "shortcutd"
I've tested the camera button and it works.
The problem is that "shortcutd" only supports a custom command I'm using to switch between applications using the camera button to avoid having to go to "dashboard".
I have to find an alternative, the camera button I have it fully occupied.
maybe there is a way to do it, I remember there was an app to make custom buttons for the power button but I can't remember the name. If so it could be made to run this command