#!/bin/sh
# start unicode mode

# Based on console-tools 0.2.3.
# imz@altlinux.org, 10 March 2004.

##### Check correct invocation.
if [[ $# != 0 ]]; then
    printf $"Usage: %s" "$0" >&2
    exit 1
fi

##### This check doesn't seem to be useful, commented out:
# if vt-is-UTF8 --quiet ; then
#   echo "Already in UTF8 mode"
#   exit 0
# fi

kbd_mode -u

# console_codes(4): Select UTF-8
# Since 1.2.1 - for older kernels, use: echo -n -e '\033%8'
printf %b '\033%G'

# assume input characters are UTF-8 encoded
stty iutf8
