~ubuntu-branches/ubuntu/saucy/ubuntu-docs/saucy

« back to all changes in this revision

Viewing changes to collect-screenshots-with-mouse.sh

  • Committer: Package Import Robot
  • Author(s): Matthew East
  • Date: 2012-05-07 20:57:02 UTC
  • Revision ID: package-import@ubuntu.com-20120507205702-gy8hqfqxurw5jfvj
Tags: 12.10.1
No-change upload from precise, bump version number only

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#!/bin/bash
 
2
 
 
3
# Prerequisites
 
4
# Do -without-mouse first (just to make sure everything's setup)
 
5
# Open Shutter and make sure "Include cursor" is checked
 
6
 
 
7
lang=$(basename $LANG .UTF-8)
 
8
echo "lang: $lang"
 
9
dir=$HOME/.ubuntu-help/$lang/figures
 
10
downdir=$HOME/.downloads
 
11
echo "dir: $dir"
 
12
mkdir -p $dir
 
13
mkdir -p $downdir
 
14
 
 
15
long_pause="sleep 5"
 
16
mid_pause="sleep 3"
 
17
short_pause="$short_pause"
 
18
 
 
19
# Set the screen resolution
 
20
xrandr -s 1024x768
 
21
$mid_pause
 
22
 
 
23
# Change the time to match the version number
 
24
# This needs to be updated for different locales
 
25
gsettings set com.canonical.indicator.datetime time-format "custom"
 
26
gsettings set com.canonical.indicator.datetime custom-time-format "12:04 %p"
 
27
gsettings set org.gnome.Evince.Default show-sidebar false # This doesn't seem to work?
 
28
gsettings set com.canonical.Unity form-factor "Netbook" 
 
29
 
 
30
gsettings set com.canonical.Unity.Launcher favorites "['ubuntu-software-center.desktop',
 
31
 'ubuntuone-installer.desktop', 'gnome-control-center.desktop']"
 
32
evince $downdir/standard-tube-map.pdf &
 
33
$long_pause
 
34
xdotool getactivewindow windowsize 600 500
 
35
xdotool getactivewindow windowmove 55 208
 
36
xdotool key Down Down Down Down
 
37
xdotool key Down Down Down Down
 
38
xdotool key Right Right Right Right Right Right
 
39
sol -v Klondike &
 
40
$mid_pause
 
41
xdotool getactivewindow windowmove 240 340
 
42
xdotool mousemove --sync 300 510
 
43
xdotool click 1
 
44
xdotool mousemove --sync 53 413
 
45
$short_pause
 
46
shutter -f -e -o $dir/unity-workspace-intro.png
 
47
$mid_pause
 
48
convert $dir/unity-workspace-intro.png -crop 375x300+0+202 +repage $dir/unity-workspace-intro.png
 
49
$short_pause
 
50
convert $dir/unity-workspace-intro.png -resize 250x200 $dir/unity-workspace-intro.png
 
51
pkill evince
 
52
pkill sol
 
53
gsettings reset com.canonical.Unity.Launcher favorites
 
54
 
 
55
xdotool key Ctrl+Alt+Down Ctrl+Alt+Right
 
56
software-center &
 
57
$long_pause
 
58
$long_pause
 
59
xdotool key Ctrl+Alt+Up
 
60
$mid_pause
 
61
evince $downdir/EmblemDivide.pdf &
 
62
$mid_pause
 
63
xdotool key Down Down Down Down Down Down
 
64
xdotool getactivewindow windowsize --sync 580 520
 
65
xdotool getactivewindow windowmove --sync 270 150
 
66
xdotool key Ctrl+Alt+Left
 
67
xdg-open "http://www.ubuntu.com"
 
68
$long_pause
 
69
$mid_pause
 
70
xdotool mousemove --sync 53 650
 
71
$short_pause
 
72
xdotool click 1
 
73
shutter -f -e -o $dir/unity-windows.png
 
74
convert $dir/unity-windows.png -resize 400x300 $dir/unity-windows.png
 
75
xdotool click 1
 
76
pkill software-center
 
77
pkill evince
 
78
 
 
79
xdotool key Ctrl+Super+Right
 
80
xdotool key Alt+F1
 
81
$short_pause
 
82
xdotool key Down
 
83
$short_pause
 
84
xdotool key Down
 
85
$short_pause
 
86
xdotool key Right
 
87
$short_pause
 
88
xdotool key Down
 
89
$short_pause
 
90
xdotool mousemove --sync 80 205
 
91
shutter -f -e -o $dir/unity-launcher-intro.png
 
92
convert $dir/unity-launcher-intro.png -crop 300x240+0+83 +repage $dir/unity-launcher-intro.png
 
93
$short_pause
 
94
convert $dir/unity-launcher-intro.png -resize 250x200 $dir/unity-launcher-intro.png
 
95
xdotool key Escape
 
96
xdotool key Ctrl+Super+Up
 
97
xdotool key Ctrl+W
 
98
 
 
99
xdg-open $downdir/Echoes\ In\ Time.mp3
 
100
sleep 25
 
101
xdotool key Alt+F4
 
102
$short_pause
 
103
xdotool key Alt+F10
 
104
$short_pause
 
105
xdotool key Left
 
106
$short_pause
 
107
xdotool key Left
 
108
$short_pause
 
109
xdotool key Left
 
110
$short_pause
 
111
xdotool key Left
 
112
$short_pause
 
113
xdotool key Down
 
114
$short_pause
 
115
xdotool key Down
 
116
$short_pause
 
117
xdotool key Down
 
118
$short_pause
 
119
xdotool mousemove --sync 900 165
 
120
shutter -f -e -o $dir/unity-appmenu-intro.png
 
121
pkill rhythmbox
 
122
convert $dir/unity-appmenu-intro.png -crop 375x300+650+0 +repage $dir/unity-appmenu-intro.png
 
123
convert $dir/unity-appmenu-intro.png -resize 250x200 $dir/unity-appmenu-intro.png
 
124
 
 
125
xdotool key Right
 
126
$short_pause
 
127
xdotool key Right
 
128
$short_pause
 
129
xdotool key Right
 
130
$short_pause
 
131
xdotool key Up
 
132
$short_pause
 
133
xdotool key Up
 
134
$short_pause
 
135
xdotool key Up
 
136
$short_pause
 
137
xdotool mousemove --sync 900 225
 
138
shutter -f -e -o $dir/unity-exit.png
 
139
convert $dir/unity-exit.png -crop 375x300+650+0 +repage $dir/unity-exit.png
 
140
$short_pause
 
141
convert $dir/unity-exit.png -resize 250x200 $dir/unity-exit.png
 
142
xdotool key Escape
 
143
 
 
144
 
 
145
# Change things back to normal
 
146
gsettings reset com.canonical.indicator.datetime time-format
 
147
gsettings reset com.canonical.indicator.datetime custom-time-format
 
148
gsettings reset com.canonical.Unity form-factor
 
149
 
 
150
# This is supposed to set a laptop's screen resolution back to default
 
151
xrandr --output LVDS1 --auto