# Additional settings / "coding" tab ([Setup] menu)

## Ambiguous Characters width

Select 1 Cell or 2 Cell.

## Override Emoji Characters width

When checked, Overrides characters width from East_Asian_Width.

- Emoji with U+1F000 and above are 2Cell (full-width).
- Emoji less than U+1F000:
  selected 2call
    2Cell(full-width)
  selected 1call
    1Cell(half-width)

## DEC Special Graphics

Select display method for DEC Special Graphics

Mapping Unicode to DEC Special Grahpics
  Unicode is converted to DEC Special Graphic, displays with "Tera Special" font.
  Character width of DEC Special Graphic is 1 cell (half-width).
  Select character type to be converted. See Mapping of Unicode to DEC special character
  Line drawing characters(U+2500-U+257F)
  Punctuation, Block Elements, Shade
  Middle dots(U+00B7,U+2024,U+2219)
Mapping DEC Special Grahpics to Unicode
  DEC Special Graphic is converted to Unicode, displays with VT Window font. The character width displayed in Unicode differs for each character. It changes depending on Ambiguous Characters width setting.

## Easy to setup

Use with Chinese, Japanese, and Korean (CJK)
  Select coding with "Japanese/" etc. such as Japanese/UTF-8
  - Ambiguous Characters Width = 2Cell
  - Override Emoji Characters Width is checkd, width = 2Cell

## About displayed characters

test text in Tera Term repository can be displayed and checked.

- Kanji width
  "wget https://ja.osdn.net/projects/ttssh2/scm/svn/blobs/head/trunk/tests/unicodebuf-east_asian_width.txt?export=raw -O -"
- Emoji width
  "wget https://ja.osdn.net/projects/ttssh2/scm/svn/blobs/head/trunk/tests/unicodebuf-text-emoji.txt?export=raw -O -"

Please note the following:

- Font is displayed unchanged or resized.
  See Font setting.
- Character width handled by Tera Term and intended by host may differ.
  Programs, library examples
  - Text editor(vim,emacs,nano etc)
  - viewer(more,less,lv etc)
  - readline library linked to bash, etc.
  - curses library linked to aptitude, etc.
- Character to be displayed may not be stored in font file.
  - If the character to be displayed (glyph) does not exist,
    a black dot will be drawn by OS. Depending on the version of OS, other character may be used.
  - Some OS versions automatically draw using other fonts.
    This feature is called font linking.

## East_Asian_Width and width (cells)

Each characters are assigned East_Asian_Width property.

5 types exsit, each types are defined character width.

In addition, there are two types of interpretation of character width

1. In an East Asian context
2. in a non-East Asian context

The following table

    cells(2=full/1=half)
    |              | East Asian | non-East Asian |
    | property     | context    | context        |
    | F(Fullwidth) | 2          | 2              |
    | H(Halfwidth) | 1          | 1              |
    | W(Wide)      | 2          | 2              |
    | Na(Narrow)   | 1          | 1              |
    | A(Ambiguous) | 2          | 1              |
    | N(Neutral)   | 1          | 1              |

In a CJK environment, it is more natural to set the Ambiguous character width to 2Cell.
In addition, most Japanese fonts are designed in 2Cell.

Neutral contains Emoji, that Emoji is unnatural in Japan when rendered in 1cell. Emoji's width can be changed to make them appear more natural.

Example
  U+263A WHITE SMILING FACE
  U+2764 HEAVY BLACK HEART
  Unicode Miscellaneous Symbols (Wikipedia JA)

Attributes are determined based on the following data
http://www.unicode.org/Public/UCD/latest/ucd/EastAsianWidth.txt

## About Emoji

Emoji property is other propery from East Asian Width property.

In the CJK environment, as with the East_Asian_Width property, Characters that are not 1-byte in non-Unicode character codes, 2-cell is more natural.

In non-CJK environments, many characters handling 1cell is natural, because 2cell characters did not exist in traditional character codes. Emoji with code points U+1F000 or higher that did not exist before Unicode, so they may be handled as 2-cell characters.

The following information is used to determine Emoji.
https://www.unicode.org/Public/emoji/12.1/emoji-data.txt
However, code points less than U+0080 are not treated as Emoji