#!/bin/bash
#
# This scripts is called from the "resetprog" line in TextConfig,
# when SVGATextMode has finished switching modes.
#
# This example only restarts selection, since that's all I need.
# 
# Adapt this script so it suits YOUR system setup. 
#
echo "Restarting selection"
/bin/killall -v selection
(/usr/bin/selection -t ms &)   # for MicroSoft mouse. Other mice need other option!

#
# Some programs need not be restarted, but just need a "SIGWINCH" signal sent to them.
# Emacs and gpm seem to be examples of this (according to Alessandro Rubini)
#
# killall -WINCH -v emacs       # this sends window change signal to all processes called "emacs"
#
# kill -WINCH `cat /var/run/gpmpid`     # gets pid from current gpm daemon, and send resize signal to it
