[Interest] how to change thickness of text stroke in QML ?

Alexander Ivash elderorb at gmail.com
Thu Mar 5 12:29:31 CET 2015


Thank you, this looks like a good workaround!

2015-03-05 11:01 GMT+03:00 Gunnar Sletta <gunnar at sletta.org>:

>
> > On 05 Mar 2015, at 08:43, Alexander Ivash <elderorb at gmail.com> wrote:
> >
> > Thank you, but unfortunately such approach disallows changing stroke
> thickness independently of font itself. I'd like to keep font 'normal' and
> get 5 pixel stroke around it.
>
> You could use http://doc.qt.io/qt-5/qml-qtquick-text.html#style-prop
> which gives you a 1 pixel outline. If you want to expand the outline
> further, you need to resort to blurring.
> http://doc.qt.io/qt-5/qml-qtgraphicaleffects-glow.html will do the job
> for you.
>
> Keep in mind that blurring is very costly to perform at runtime though, so
> you want to keep the number of items with effects to a minimum and the area
> they span small to keep performance good.
>
> cheers,
> Gunnar
>
> >
> > 2015-03-04 18:54 GMT+03:00 Portale Alessandro <
> Alessandro.Portale at theqtcompany.com>:
> > font.weight
> >
> >
> > Von: interest-bounces+alessandro.portale=theqtcompany.com at qt-project.org
> <interest-bounces+alessandro.portale=theqtcompany.com at qt-project.org> im
> Auftrag von Alexander Ivash <elderorb at gmail.com>
> > Gesendet: Dienstag, 3. März 2015 19:45
> > An: interest at qt-project.org
> > Betreff: [Interest] how to change thickness of text stroke in QML ?
> >
> > subj
> >
> > _______________________________________________
> > Interest mailing list
> > Interest at qt-project.org
> > http://lists.qt-project.org/mailman/listinfo/interest
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20150305/4cf87c62/attachment.html>


More information about the Interest mailing list