The markerline now supports a fully styled brush rather than just reading the color
and enforcing a gradient.
In order to get the same look as before, we adapt the stylesheets we ship and also write
out an appropriate gradient definition in settings.qss.
Note that, as always in QSS, the gradient is normalized between (0,0) and (1,1).
// Custom ChatView Colors
ChatView { background: #00004b; }
// Custom ChatView Colors
ChatView { background: #00004b; }
-Palette { marker-line: #ff0000; }
+Palette { marker-line: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1, stop:0 #ff0000, stop: 0.1 transparent); }
+
ChatLine[label="highlight"] { foreground: #f0f5ff; background: #00008b; }
ChatLine[label="highlight"] { foreground: #f0f5ff; background: #00008b; }
foreground: palette(link);
}
foreground: palette(link);
}
+// Markerline gets a nice (and hardly visible) gradient
+ marker-line: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1, stop:0 red, stop: 0.1 transparent);
// Copyright (C) Jussi Schultink 2009
// Custom ChatView Colors
// Copyright (C) Jussi Schultink 2009
// Custom ChatView Colors
-Palette { marker-line: #ff0000; }
+Palette { marker-line: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1, stop:0 #ff0000, stop: 0.1 transparent); }
+
ChatView { background: #131313; }
ChatLine[label="highlight"] {
ChatView { background: #131313; }
ChatLine[label="highlight"] {
ChatLine::sender[label="highlight"] {
background: #d7d7d7;
font-weight:bold;
ChatLine::sender[label="highlight"] {
background: #d7d7d7;
font-weight:bold;
}
ChatLine[label="selected"] {
}
ChatLine[label="selected"] {
ChatLine::timestamp[sender="self"] { foreground: #707c70; }
ChatLine::timestamp[label="highlight"] { foreground: #707c70; }
ChatLine::timestamp[sender="self"] { foreground: #707c70; }
ChatLine::timestamp[label="highlight"] { foreground: #707c70; }
-Palette { marker-line: #ff0000; }
+Palette { marker-line: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1, stop:0 #ff0000, stop: 0.1 transparent); }
ChatLine::url { foreground: #0000aa; }
ChatLine::url[sender="self"] { foreground: #0000aa; }
ChatLine::url { foreground: #0000aa; }
ChatLine::url[sender="self"] { foreground: #0000aa; }
if(s.value("UseChatViewColors").toBool()) {
out << "\n// Custom ChatView Colors\n"
if(s.value("UseChatViewColors").toBool()) {
out << "\n// Custom ChatView Colors\n"
- << "Palette { marker-line: " << color("MarkerLine", s) << "; }\n"
+ // markerline is special in that it always used to use a gradient, so we keep this behavior even with the new implementation
+ << "Palette { marker-line: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 " << color("MarkerLine", s) << ", stop: 0.1 transparent); }\n"
<< "ChatView { background: " << color("ChatViewBackground", s) << "; }\n\n"
<< "ChatLine[label=\"highlight\"] {\n"
<< " foreground: " << color("Highlight",s) << ";\n"
<< "ChatView { background: " << color("ChatViewBackground", s) << "; }\n\n"
<< "ChatLine[label=\"highlight\"] {\n"
<< " foreground: " << color("Highlight",s) << ";\n"