blob: 795660d9306217ab3f82c6575b0a4fd0791d6cd9 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
|
#!/bin/sh
as() {
user="$1"; shift
env -u HOME sudo -u "$user" dbus-launch --exit-with-session "$@"
unset user
}
# High-contrast GTK theme and icons
gsettings set org.gnome.desktop.interface gtk-theme HighContrast
gsettings set org.gnome.desktop.interface icon-theme HighContrast
gsettings set org.gnome.desktop.wm.preferences theme HighContrast
# Large text and cursor
gsettings set com.canonical.Unity.Interface text-scale-factor 1.25
gsettings set com.canonical.Unity.Interface cursor-scale-factor 2
touch ~/.Xresources
sed -i -e '/Xcursor.size:/d' ~/.Xresources
echo Xcursor.size:48 >> ~/.Xresources
# Legacy scrollbars
gsettings set com.canonical.desktop.interface scrollbar-mode normal
# High-contrast Unity greeter
# This looks absolutely awful, don't do this
#as lightdm gsettings set com.canonical.unity-greeter high-contrast true
#as lightdm gsettings set com.canonical.unity-greeter theme-name HighContrast
#as lightdm gsettings set com.canonical.unity-greeter icon-theme-name HighContrast
# Low vision terminal profile
gconftool --load gnome-terminal-low-vision.xml
PROFILE_LIST=/apps/gnome-terminal/global/profile_list
num_profiles=$(gconftool --get-list-size $PROFILE_LIST)
found=false
profile_list=""
for i in $(seq 0 $num_profiles | head -n $num_profiles); do
profile=$(gconftool --get-list-element $PROFILE_LIST $i)
if test LowVision = "$profile"; then
found=true
break
fi
if test -z "$profile_list"; then
profile_list="[$profile"
else
profile_list="$profile_list,$profile"
fi
done
if ! $found; then
gconftool --set --type=list --list-type=string $PROFILE_LIST \
"$profile_list,LowVision]"
fi
gconftool --set --type=string /apps/gnome-terminal/global/default_profile LowVision
|