mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-22 18:08:10 +00:00
Fix bug 12459
When checking for branch color, take into account that some branches are defined in the master document only, some only in the child.
This commit is contained in:
parent
2764ed20c2
commit
942538c02d
@ -136,9 +136,11 @@ ColorCode InsetBranch::backgroundColor(PainterInfo const & pi) const
|
||||
{
|
||||
if (params_.branch.empty())
|
||||
return Inset::backgroundColor(pi);
|
||||
string const branch_id = (buffer().masterParams().branchlist().find(params_.branch))
|
||||
? convert<string>(buffer().masterParams().branchlist().id())
|
||||
: convert<string>(buffer().params().branchlist().id());
|
||||
// FIXME UNICODE
|
||||
string const branchcol = "branch" + convert<string>(buffer().params().branchlist().id())
|
||||
+ to_utf8(params_.branch);
|
||||
string const branchcol = "branch" + branch_id + to_utf8(params_.branch);
|
||||
ColorCode c = lcolor.getFromLyXName(branchcol);
|
||||
if (c == Color_none)
|
||||
c = Color_error;
|
||||
|
Loading…
Reference in New Issue
Block a user