sect->text = NULL;
sect->type = INDEX;
sect->parent = topsect;
+ sect->contents_depth = 0;
html_file_section(&conf, &files, sect, 0); /* peer of chapters */
sect->fragment = utoa_dup(conf.index_text, CS_ASCII);
sect->fragment = html_sanitise_fragment(&files, sect->file,
if (conf.head_end)
html_raw(&ho, conf.head_end);
+ /*
+ * Add any <head> data defined in specific sections
+ * that go in this file. (This is mostly to allow <meta
+ * name="AppleTitle"> tags for Mac online help.)
+ */
+ for (s = sects.head; s; s = s->next) {
+ if (s->file == f && s->text) {
+ for (p = s->text;
+ p && (p == s->text || p->type == para_Title ||
+ !is_heading_type(p->type));
+ p = p->next) {
+ if (p->type == para_Config) {
+ if (!ustricmp(p->keyword, L"html-local-head")) {
+ html_raw(&ho, adv(p->origkeyword));
+ }
+ }
+ }
+ }
+ }
+
element_close(&ho, "head");
html_nl(&ho);
case word_LowerXref:
if (flags & LINKS) {
keyword *kwl = kw_lookup(keywords, w->text);
- paragraph *p = kwl->para;
- htmlsect *s = (htmlsect *)p->private_data;
+ paragraph *p;
+ htmlsect *s;
+
+ assert(kwl);
+ p = kwl->para;
+ s = (htmlsect *)p->private_data;
assert(s);