<div dir="ltr">We d<br><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Jul 17, 2015 at 3:37 PM, Lubomir I. Ivanov <span dir="ltr"><<a href="mailto:neolit123@gmail.com" target="_blank">neolit123@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">On 17 July 2015 at 21:13, Gehad Elrobey <<a href="mailto:gehadelrobey@gmail.com">gehadelrobey@gmail.com</a>> wrote:<br>
<span class="">><br>
><br>
> On Fri, Jul 17, 2015 at 8:08 PM, Lubomir I. Ivanov <<a href="mailto:neolit123@gmail.com">neolit123@gmail.com</a>><br>
> wrote:<br>
>><br>
>> hello Gehad,<br>
>><br>
>> without looking at the code, the greyscale mode works as expected, but<br>
>> both the Preview and actual Print now razterize everything on Windows<br>
>> (profile and table). we want them in vector graphics on all OSes and<br>
>> Qt versions where possible.<br>
>><br>
>> perhaps, that's something you've overlooked?<br>
><br>
><br>
> I am forces to render the dive profile on a QImage so that I can convert it<br>
> to grayscale image and then render it on top of the QWebview, Do you think<br>
> there is a way to convert the vector graphics to grayscale?<br>
><br>
<br>
</span>i see...<br>
well bummer, i can't find if Qt has shaders, custom color palettes,<br>
"color delegates" and such for QPicture/QPainter. which means that to<br>
convert something to greyscale it needs to be rasterized first. Tomaz,<br>
if you have any idea, do say.<br>
<br>
i guess for now you can only *rasterize* the profile if greyscale is enabled.<br>
but this isn't a pretty solution...we may have to attempt to use the<br>
custom color tables for the profile after all (i.e. what Tomaz brought<br>
back). :(<br>
<br>
but why are the tables raster - are you rasterizing the whole page?<br>
shouldn't the CSS greyscale filter preserve the vector?<br></blockquote><div><br></div><div>Just found out: <br><a href="http://doc.qt.io/qt-5/qcolormap.html">http://doc.qt.io/qt-5/qcolormap.html</a><br> <br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<br>
lubomir<br>
--<br>
</blockquote></div><br></div></div>