On linux you have to edit the file "/etc/inittab" and change from
Qt Code:
  1. ca:12345:ctrlaltdel:/sbin/shutdown -t1 -a -r now
To copy to clipboard, switch view to plain text mode 
to
Qt Code:
  1. # ca:12345:ctrlaltdel:/sbin/shutdown -t1 -a -r now
To copy to clipboard, switch view to plain text mode 

After this you either boot the system or type on the console:
Qt Code:
  1. init q
To copy to clipboard, switch view to plain text mode 

This could also be done with QFile, QRegExp and QProcess

Best Regards
NoRulez