Encoding: ascii
Title: Encoding Rule - BlueFeather Manual
CSS: black.css

<div class="back"><a href="index.html">BlueFeather Manual</a></div>

Encoding Rule
====


{toc}


1. Converting to html part
----
(converting *.bftext files, parsing by `parse_text` or others.)

BlueFeather doesn't specially treat.
If ruby 1.8.x ealier, it is based on $KCODE value then.
Else if ruby 1.9.x later, it is based on encoding which String object has.

When you use `bluefeather` command, it is based on -e (--encoding) option. Default is UTF-8.



2. Converting to html document
----
(converting *.bfdoc files, parsing by `parse_document` or others.)

BlueFeather uses the following order.

1. Encoding header of document metadata (PRIMARY)
2. Specified encoding at convert
3. UTF-8


If you want to know about encoding header, see the [Metadata reference](metadata-reference.html).

You can specify encoding.
If you use `bluefeather` command, you must use -e (--encoding) option for it.
If you use with [`parse_document`](class-reference.html#parse_document) or [`parse_document_file`](class-reference.html#parse_document), you must use 2nd argument of these methods for it.



