mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-12-22 13:18:28 +00:00
Don't enclose in braces minted languages
This is because the braces would be part of the language name.
This commit is contained in:
parent
7b5d33a707
commit
0e90aeea90
@ -1050,7 +1050,8 @@ void InsetListingsParams::addParam(string const & key,
|
|||||||
if (key.empty())
|
if (key.empty())
|
||||||
return;
|
return;
|
||||||
|
|
||||||
string const value = (minted() && key == "language" && !val.empty())
|
bool const is_minted_language = minted() && key == "language";
|
||||||
|
string const value = (is_minted_language && !val.empty())
|
||||||
? languageonly(val) : val;
|
? languageonly(val) : val;
|
||||||
// duplicate parameters!
|
// duplicate parameters!
|
||||||
string keyname = key;
|
string keyname = key;
|
||||||
@ -1076,7 +1077,7 @@ void InsetListingsParams::addParam(string const & key,
|
|||||||
has_special_char = true;
|
has_special_char = true;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
if (has_special_char)
|
if (has_special_char && !is_minted_language)
|
||||||
params_.push_back(make_pair(keyname, "{" + value + "}"));
|
params_.push_back(make_pair(keyname, "{" + value + "}"));
|
||||||
else
|
else
|
||||||
params_.push_back(make_pair(keyname, value));
|
params_.push_back(make_pair(keyname, value));
|
||||||
|
Loading…
Reference in New Issue
Block a user