An approach that I have used in the past is to use widget systems such as konfabulator. konfabulator creates basic GUIs based on an xml file. A javascript like language then handles events and modifies the gui. An onload method then simply executes your perl script as a system command, adjusting the gui depending on the return of the script. Further events can be likewise directed to perl. It sounds cumbersome, but for small guis it is very effective and fits well with the command line approach of perl.