-----------------------
+2010-04-21 Richard heck <rgheck@comcast.net>
+ * Format incremented to 387: New options for XHTML math output.
+ New BufferParams: html_math_img_scale, html_latex_start,
+ html_latex_end.
+
2010-04-17 Richard heck <rgheck@comcast.net>
* Format incremented to 386: LyX version for InsetInfo:
new parameters: type "lyxinfo", arg "version".
i = i+1
+def revert_math_scale(document):
+ " Remove math scaling and LaTeX options "
+ i = find_token(document.header, '\\html_math_img_scale', 0)
+ if i != -1:
+ del document.header[i]
+ i = find_token(document.header, '\\html_latex_start', 0)
+ if i != -1:
+ del document.header[i]
+ i = find_token(document.header, '\\html_latex_end', 0)
+ if i != -1:
+ del document.header[i]
+
+
+
##
# Conversion hub
#
[383, []],
[384, []],
[385, []],
- [386, []]
- ]
+ [386, []],
+ [387, []],
+ ]
-revert = [[385, [revert_lyx_version]],
+revert = [[386, [revert_math_scale]],
+ [385, [revert_lyx_version]],
[384, [revert_shadedboxcolor]],
[383, [revert_fontcolor]],
[382, [revert_turkmen]],
// Do not remove the comment below, so we get merge conflict in
// independent branches. Instead add your own.
-int const LYX_FORMAT = 386; // rgh: LyX version for InsetInfo
+int const LYX_FORMAT = 387; // rgh: XHTML math options
typedef map<string, bool> DepClean;
typedef map<docstring, pair<InsetLabel const *, Buffer::References> > RefCache;
}
// default index
indiceslist().addDefault(B_("Index"));
- html_be_strict = true;
+ html_be_strict = false;
html_math_output = MathML;
+ html_math_img_scale = 1.0;
+ html_latex_start = "<span class='latex'>";
+ html_latex_end = "</span>";
}
html_math_output = static_cast<MathOutput>(temp);
} else if (token == "\\html_be_strict") {
lex >> html_be_strict;
+ } else if (token == "\\html_math_img_scale") {
+ lex >> html_math_img_scale;
+ } else if (token == "\\html_latex_start") {
+ lex >> html_latex_start;
+ } else if (token == "\\html_latex_end") {
+ lex >> html_latex_end;
} else {
lyxerr << "BufferParams::readToken(): Unknown token: " <<
token << endl;
}
}
- os << "\\tracking_changes " << convert<string>(trackChanges) << "\n"
- << "\\output_changes " << convert<string>(outputChanges) << "\n"
- << "\\html_math_output " << html_math_output << "\n"
- << "\\html_be_strict " << convert<string>(html_be_strict) << "\n";
+ os << "\\tracking_changes " << convert<string>(trackChanges) << '\n'
+ << "\\output_changes " << convert<string>(outputChanges) << '\n'
+ << "\\html_math_output " << html_math_output << '\n'
+ << "\\html_be_strict " << convert<string>(html_be_strict) << '\n'
+ << "\\html_math_img_scale " << convert<string>(html_math_img_scale) << '\n'
+ << "\\html_latex_start \"" << html_latex_start << "\"\n"
+ << "\\html_latex_end \"" << html_latex_end << "\"\n";
os << pimpl_->authorlist;
}
/// whether to attempt to be XHTML 1.1 compliant or instead be
/// a little more mellow
bool html_be_strict;
+ ///
+ double html_math_img_scale;
+ ///
+ std::string html_latex_start;
+ ///
+ std::string html_latex_end;
private:
///