Class: IsoDoc::JIS::HtmlConvert
- Inherits:
-
Iso::HtmlConvert
- Object
- Iso::HtmlConvert
- IsoDoc::JIS::HtmlConvert
show all
- Includes:
- BaseConvert, Init
- Defined in:
- lib/isodoc/jis/html_convert.rb
Instance Method Summary
collapse
Methods included from Init
#i18n_init, #metadata_init, #omit_docid_prefix, #std_docid_semantic, #xref_init
#admonition_name_parse, #annex, #commentary, #full_row, #make_tr_attr, #table_cols_count, #table_name, #table_parse, #table_thead_pt, #termnote_parse
Constructor Details
#initialize(options) ⇒ HtmlConvert
Returns a new instance of HtmlConvert.
9
10
11
12
|
# File 'lib/isodoc/jis/html_convert.rb', line 9
def initialize(options)
super
@libdir = File.dirname(__FILE__)
end
|
Instance Method Details
#convert1(docxml, filename, dir) ⇒ Object
14
15
16
17
|
# File 'lib/isodoc/jis/html_convert.rb', line 14
def convert1(docxml, filename, dir)
@options.merge!(default_fonts({})) super
end
|
#default_file_locations(_options) ⇒ Object
29
30
31
32
33
34
35
36
|
# File 'lib/isodoc/jis/html_convert.rb', line 29
def default_file_locations(_options)
@libdir = File.dirname(__FILE__)
{
htmlstylesheet: html_doc_path("style-iso.scss"),
htmlcoverpage: html_doc_path("html_jis_titlepage.html"),
htmlintropage: html_doc_path("html_jis_intro.html"),
}
end
|
#default_fonts(_options) ⇒ Object
19
20
21
22
23
24
25
26
27
|
# File 'lib/isodoc/jis/html_convert.rb', line 19
def default_fonts(_options)
{
bodyfont: (@script == "Jpan" ? '"MS Mincho",serif' : '"Times New Roman",serif'),
headerfont: (@script == "Jpan" ? '"MS Gothic",sans-serif' : '"Arial",sans-serif'),
monospacefont: '"Courier New",monospace',
monospacefontsize: "1.0em",
footnotefontsize: "0.9em",
}
end
|
38
39
40
41
42
43
44
45
46
47
|
# File 'lib/isodoc/jis/html_convert.rb', line 38
def (out, fnid, fnref)
attrs = { id: fnid, class: "TableFootnoteRef" }
out.span do |s|
s << @i18n.
out.span **attrs do |a|
a << "#{fnref})"
end
insert_tab(s, 1)
end
end
|