| 1 |
wakaba |
1.1 |
#?SuikaWikiConfig/2.0 |
| 2 |
|
|
|
| 3 |
|
|
Plugin: |
| 4 |
|
|
@Name: HTML |
| 5 |
|
|
@Description: |
| 6 |
|
|
@@@: Hypertext Markup Language support |
| 7 |
|
|
@@lang:en |
| 8 |
|
|
@License: %%GPL%% |
| 9 |
|
|
@Author: |
| 10 |
|
|
@@Name: |
| 11 |
|
|
@@@@: Wakaba |
| 12 |
|
|
@@@lang:ja |
| 13 |
|
|
@@@script:Latn |
| 14 |
|
|
@@Mail[list]: w@suika.fam.cx |
| 15 |
|
|
@Date.RCS: $Date:$ |
| 16 |
|
|
|
| 17 |
|
|
PluginConst: |
| 18 |
|
|
@NS_XHTML1: |
| 19 |
|
|
http://www.w3.org/1999/xhtml |
| 20 |
|
|
@NS_XHTML2: |
| 21 |
|
|
http://www.w3.org/2002/06/xhtml2 |
| 22 |
|
|
|
| 23 |
|
|
FormattingRule: |
| 24 |
|
|
@Category[list]: view |
| 25 |
|
|
@Name: html-document |
| 26 |
|
|
@Description: |
| 27 |
|
|
@@@: |
| 28 |
|
|
A HTML document |
| 29 |
|
|
@@lang: en |
| 30 |
|
|
@Parameter: |
| 31 |
|
|
@@Name: content |
| 32 |
|
|
@@Type: text |
| 33 |
|
|
@@Default: "" |
| 34 |
|
|
@@Description: |
| 35 |
|
|
@@@@: Content of the documente (in the BODY element) |
| 36 |
|
|
@@@lang:en |
| 37 |
|
|
@Parameter: |
| 38 |
|
|
@@Name: link-meta |
| 39 |
|
|
@@Type: node |
| 40 |
|
|
@@Default: (none) |
| 41 |
|
|
@@Description: |
| 42 |
|
|
@@@@: |
| 43 |
|
|
Metainformation that should be included as part of HEAD element |
| 44 |
|
|
@@@lang:en |
| 45 |
|
|
@Parameter: |
| 46 |
|
|
@@Name: profile |
| 47 |
|
|
@@Type: |
| 48 |
|
|
html:uris |
| 49 |
|
|
@@Default: "http://suika.fam.cx/~wakaba/-temp/wiki/wiki?WikiHTMLMetaProfile" |
| 50 |
|
|
@@Description: |
| 51 |
|
|
Profile URIs of metainformation (xhtml1:head/@profile or |
| 52 |
|
|
xhtml2:html/@profile) |
| 53 |
|
|
@Parameter: |
| 54 |
|
|
@@Name: title |
| 55 |
|
|
@@Type: text |
| 56 |
|
|
@@Default: (none) |
| 57 |
|
|
@@Description: |
| 58 |
|
|
@@@@: Title (heading) text of the document |
| 59 |
|
|
@@@lang:en |
| 60 |
|
|
@Formatting: |
| 61 |
|
|
$r = Message::Markup::XML->new (type => '#document'); |
| 62 |
|
|
my $H = $r->append_new_node (namespace_uri => $NS_XHTML1, local_name => 'html'); |
| 63 |
|
|
# $H->set_attribute (class => join ' ', keys %{$o->{-header}->{class}}) |
| 64 |
|
|
# if ref $o->{-header}->{class}; |
| 65 |
|
|
$H->append_text ("\n "); |
| 66 |
|
|
my $h = $H->append_new_node (namespace_uri => $NS_XHTML1, local_name => 'head'); |
| 67 |
|
|
$h->set_attribute (profile => ($p->{profile} || q(http://suika.fam.cx/~wakaba/-temp/wiki/wiki?WikiHTMLMetaProfile))); |
| 68 |
|
|
$h->append_text ("\n "); |
| 69 |
|
|
# $h->append_node ($o->{-header}->{additional_html_element}) |
| 70 |
|
|
# if ref $o->{-header}->{additional_html_element}; |
| 71 |
|
|
$h->append_new_node (namespace_uri => $NS_XHTML1, local_name => 'title') |
| 72 |
|
|
->append_node ($p->{title}, node_or_text => 1); |
| 73 |
|
|
$h->append_text ("\n "); |
| 74 |
|
|
$h->append_node ($p->{link_meta}, node_or_text => 1); |
| 75 |
|
|
$H->append_node ($p->{content}, node_or_text => 1); |
| 76 |
|
|
|
| 77 |
|
|
FormattingRule: |
| 78 |
|
|
@Category[list]: view |
| 79 |
|
|
@Name: html-meta |
| 80 |
|
|
@Description: |
| 81 |
|
|
@@@: |
| 82 |
|
|
name/val pair of metainformation (META element) |
| 83 |
|
|
@@lang: en |
| 84 |
|
|
@Parameter: |
| 85 |
|
|
@@Name: content |
| 86 |
|
|
@@Type: text |
| 87 |
|
|
@@Default: "" |
| 88 |
|
|
@@Description: |
| 89 |
|
|
@@@@: Value (meta/@content) |
| 90 |
|
|
@@@lang:en |
| 91 |
|
|
@Parameter: |
| 92 |
|
|
@@Name: name |
| 93 |
|
|
@@Type: text |
| 94 |
|
|
@@Default: "" |
| 95 |
|
|
@@Description: |
| 96 |
|
|
@@@@: Name (meta/@name) |
| 97 |
|
|
@@@lang:en |
| 98 |
|
|
@Formatting: |
| 99 |
|
|
$r = Message::Markup::XML->new (type => '#element', |
| 100 |
|
|
namespace_uri => $NS_XHTML1, |
| 101 |
|
|
local_name => 'meta'); |
| 102 |
|
|
$r->option (use_EmptyElemTag => 1); |
| 103 |
|
|
for my $attr (qw/name content/) { |
| 104 |
|
|
$r->set_attribute ($attr => $p->{$attr}) if defined $p->{$attr}; |
| 105 |
|
|
} |