File: encoding-rule.bfdoc

package info (click to toggle)
ruby-bluefeather 0.41-2
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 632 kB
  • ctags: 167
  • sloc: ruby: 4,195; makefile: 7
file content (44 lines) | stat: -rw-r--r-- 1,209 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
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.