mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-12-22 05:16:21 +00:00
Consider darkmode when inserting new branch
This commit is contained in:
parent
4062cbd278
commit
81c19502c1
@ -2943,8 +2943,10 @@ void Buffer::dispatch(FuncRequest const & func, DispatchResult & dr)
|
||||
string const bcolor = branch->color();
|
||||
if (bcolor.size() == 7 && bcolor[0] == '#')
|
||||
x11hexname = bcolor;
|
||||
else
|
||||
x11hexname = lcolor.getX11HexName(lcolor.getFromLyXName(bcolor));
|
||||
else {
|
||||
bool const darkmode = theApp() ? theApp()->isInDarkMode() : false;
|
||||
x11hexname = lcolor.getX11HexName(lcolor.getFromLyXName(bcolor), darkmode);
|
||||
}
|
||||
docstring const str = branch_name + ' ' + from_ascii(x11hexname);
|
||||
lyx::dispatch(FuncRequest(LFUN_SET_COLOR, str));
|
||||
dr.setError(false);
|
||||
|
Loading…
Reference in New Issue
Block a user