127
127
set gfxmode=${GRUB_GFXMODE}
134
case x${GRUB_TERMINAL_INPUT} in
136
# Just use the native terminal
140
if terminal_input ${GRUB_TERMINAL_INPUT} ; then true ; else
141
# For backward compatibility with versions of terminal.mod that don't
142
# understand terminal_input
143
terminal ${GRUB_TERMINAL_INPUT}
149
case x${GRUB_TERMINAL_OUTPUT} in
151
# Just use the native terminal
155
if terminal_output ${GRUB_TERMINAL_OUTPUT} ; then true ; else
156
# For backward compatibility with versions of terminal.mod that don't
157
# understand terminal_output
158
terminal ${GRUB_TERMINAL_OUTPUT}
164
if [ "x$gfxterm" = x1 ]; then
131
165
if [ "x$GRUB_THEME" != x ] && [ -f "$GRUB_THEME" ] \
132
166
&& is_path_readable_by_grub "$GRUB_THEME"; then
133
167
echo "Found theme: $GRUB_THEME" >&2
134
prepare_grub_to_access_device `${grub_probe} --target=device "$GRUB_THEME"` | sed -e "s/^/ /"
168
prepare_grub_to_access_device `${grub_probe} --target=device "$GRUB_THEME"`
138
172
themedir="`dirname "$GRUB_THEME"`"
139
173
for x in "$themedir"/*.pf2 "$themedir"/f/*.pf2; do
140
174
if [ -f "$x" ]; then
142
loadfont (\$root)`make_system_path_relative_to_its_root $x`
176
loadfont (\$root)`make_system_path_relative_to_its_root $x`
146
180
if [ x"`echo "$themedir"/*.jpg`" != x"$themedir/*.jpg" ] || [ x"`echo "$themedir"/*.jpeg`" != x"$themedir/*.jpeg" ]; then
151
185
if [ x"`echo "$themedir"/*.png`" != x"$themedir/*.png" ]; then
156
190
if [ x"`echo "$themedir"/*.tga`" != x"$themedir/*.tga" ]; then
163
set theme=(\$root)`make_system_path_relative_to_its_root $GRUB_THEME`
197
set theme=(\$root)`make_system_path_relative_to_its_root $GRUB_THEME`
165
199
elif [ "x$GRUB_BACKGROUND" != x ] && [ -f "$GRUB_BACKGROUND" ] \
166
200
&& is_path_readable_by_grub "$GRUB_BACKGROUND"; then
171
205
*.jpg|*.jpeg) reader=jpeg ;;
172
206
*) echo "Unsupported image format" >&2; exit 1 ;;
174
prepare_grub_to_access_device `${grub_probe} --target=device "$GRUB_BACKGROUND"` | sed -e "s/^/ /"
208
prepare_grub_to_access_device `${grub_probe} --target=device "$GRUB_BACKGROUND"`
177
background_image -m stretch `make_system_path_relative_to_its_root "$GRUB_BACKGROUND"`
211
background_image -m stretch `make_system_path_relative_to_its_root "$GRUB_BACKGROUND"`
185
case x${GRUB_TERMINAL_INPUT} in
187
# Just use the native terminal
191
if terminal_input ${GRUB_TERMINAL_INPUT} ; then true ; else
192
# For backward compatibility with versions of terminal.mod that don't
193
# understand terminal_input
194
terminal ${GRUB_TERMINAL_INPUT}
200
case x${GRUB_TERMINAL_OUTPUT} in
202
# Just use the native terminal
206
if terminal_output ${GRUB_TERMINAL_OUTPUT} ; then true ; else
207
# For backward compatibility with versions of terminal.mod that don't
208
# understand terminal_output
209
terminal ${GRUB_TERMINAL_OUTPUT}
215
216
# Gettext variables and module
216
217
if [ "x${LANG}" != "xC" ] && [ -d "${locale_dir}" ] ; then