icp["key"] = from_utf8(arg);
if (!opt1.empty())
icp["before"] = from_utf8(opt1);
+ icp["literal"] =
+ from_ascii(InsetCitation::last_literal ? "true" : "false");
string icstr = InsetCommand::params2string(icp);
FuncRequest fr(LFUN_INSET_INSERT, icstr);
lyx::dispatch(fr);
#include "TextClass.h"
#include "FuncRequest.h"
+#include "insets/InsetCitation.h"
#include "insets/InsetCommand.h"
#include "support/debug.h"
GuiCitation::GuiCitation(GuiView & lv)
: DialogView(lv, "citation", qt_("Citation")),
- style_(QString()), literal_(false), params_(insetCode("citation"))
+ style_(QString()), params_(insetCode("citation"))
{
setupUi(this);
void GuiCitation::on_literalCB_clicked()
{
- literal_ = literalCB->isChecked();
+ InsetCitation::last_literal = literalCB->isChecked();
changed();
}
// if this is a new citation, we set the literal checkbox
// to its last set value.
if (cited_keys_.isEmpty())
- literalCB->setChecked(literal_);
+ literalCB->setChecked(InsetCitation::last_literal);
else
literalCB->setChecked(params_["literal"] == "true");
settings.setValue(
sessionKey() + "/citestyle", style_);
settings.setValue(
- sessionKey() + "/literal", literal_);
+ sessionKey() + "/literal", InsetCitation::last_literal);
}
casesense_->setChecked(settings.value(sessionKey() + "/casesensitive").toBool());
instant_->setChecked(settings.value(sessionKey() + "/autofind", true).toBool());
style_ = settings.value(sessionKey() + "/citestyle").toString();
- literal_ = settings.value(sessionKey() + "/literal", false).toBool();
+ InsetCitation::last_literal =
+ settings.value(sessionKey() + "/literal", false).toBool();
updateFilterHint();
}
}
+// May well be over-ridden when session settings are loaded
+// in GuiCitation. Unfortunately, that will not happen until
+// such a dialog is created.
+bool InsetCitation::last_literal = true;
+
+
ParamInfo const & InsetCitation::findInfo(string const & /* cmdName */)
{
// standard cite does only take one argument, but biblatex, jurabib
- Handle properly top/bottom of inset with mac-like cursor movement
(bug 10701).
+- Respect the last setting of the 'literal' checkbox when adding citations
+ via the LyX server (e.g., from JabRef).
+
- Allow unification of graphic groups inside marked block via context
menu.