# the next line restarts using wish \
exec wish "$0" "$@"
# ixset --
# A nice interface to "xset" to change X server settings
#
# History :
# 91/11/23 : pda@masi.ibp.fr, jt@ratp.fr : design
# 92/08/01 : pda@masi.ibp.fr : cleaning
#
# SCCS: @(#) ixset 1.7 96/02/16 10:49:19
#
# Button actions
#
destroy .
}
}
}
# apply is just "writesettings"
#
# Read current settings
#
{auto}
{
}
}
{bell}
{
}
{acceleration:}
{
}
{prefer}
{
}
{timeout:}
{
}
}
}
# puts stdout [format "Key REPEAT = %s\n" $kbdrep]
# puts stdout [format "Key CLICK = %s\n" $kbdcli]
# puts stdout [format "Bell VOLUME = %s\n" $bellvol]
# puts stdout [format "Bell PITCH = %s\n" $bellpit]
# puts stdout [format "Bell DURATION = %s\n" $belldur]
# puts stdout [format "Mouse ACCELERATION = %s\n" $mouseacc]
# puts stdout [format "Mouse THRESHOLD = %s\n" $mousethr]
# puts stdout [format "Screen BLANCK = %s\n" $screenbla]
# puts stdout [format "Screen TIMEOUT = %s\n" $screentim]
# puts stdout [format "Screen CYCLE = %s\n" $screencyc]
}
#
# Write settings into the X server
#
set bellpit [.bell.val.pit.entry get]
set belldur [.bell.val.dur.entry get]
set kbdcli [.kbd.val.cli get]
} else {
set kbdcli "off"
}
set mouseacc [.mouse.hor.acc.entry get]
set mousethr [.mouse.hor.thr.entry get]
exec xset \
c $kbdcli \
r $kbdrep \
s $screentim $screencyc \
}
#
# Sends all settings to the window
#
.bell.val.pit.entry delete 0 end
.bell.val.dur.entry delete 0 end
.kbd.val.cli set $kbdcli
.mouse.hor.acc.entry delete 0 end
.mouse.hor.thr.entry delete 0 end
}
#
# Create all windows, and pack them
#
}
#
# Buttons
#
#
# Bell settings
#
frame .bell -relief raised -borderwidth 2
label .bell.label -text "Bell Settings"
-from 0 -to 100 -length 200 -tickinterval 20 \
pack .bell.val.pit -side left -padx 5
pack .bell.val.dur -side right -padx 5
#
# Keyboard settings
#
frame .kbd -relief raised -borderwidth 2
label .kbd.label -text "Keyboard Repeat Settings"
-from 0 -to 100 -length 200 -tickinterval 20 \
#
# Mouse settings
#
frame .mouse -relief raised -borderwidth 2
label .mouse.label -text "Mouse Settings"
#
# Screen Saver settings
#
frame .screen -relief raised -borderwidth 2
label .screen.label -text "Screen-saver Settings"
pack .screen.val -side top -expand y
#
# Main window
#
#
# Let the user resize our window
#
}
##############################################################################
# Main program
#
# Listen what "xset" tells us...
#
#
# Create all windows
#
#
# Write xset parameters
#
#
# Now, wait for user actions...
#