[Interest] Painting fonts without GUI

Federico Buti fed.buti at gmail.com
Tue Jun 7 16:00:28 CEST 2016


Indeed.
I remember having issues such as black blocks in place of actual text while
the rest of the PDF was fine.

Anyhow, thanks for the datails.

Bests,
F.

On 7 June 2016 at 15:57, Jason H <jhihn at gmx.com> wrote:

> Yea, so I didn't read the stack overflow but it said what I said, though I
> take issue with "QPA won't work" assertion. QPA works just fine. I think
> what lead them to that was some package issues they were having. FWIW, I
> didn't have them.
>
>
>
>
> *Sent:* Tuesday, June 07, 2016 at 9:52 AM
> *From:* "Jason H" <jhihn at gmx.com>
> *To:* "Federico Buti" <fed.buti at gmail.com>
>
> *Cc:* "interest at qt-project.org" <Interest at qt-project.org>
> *Subject:* Re: [Interest] Painting fonts without GUI
> While true, that is not the complete truth.
>
> You can use a platform (-platform XXX) to specify an non-X server, and use
> that for rendering. That's how I generated PDFs on a headless server.
> "offscreen" is one, but there is a better one that escapes me at the
> moment.
>
>
>
> *Sent:* Tuesday, June 07, 2016 at 7:48 AM
> *From:* "Federico Buti" <fed.buti at gmail.com>
> *To:* "Etienne Sandré-Chardonnal" <etienne.sandre at m4x.org>
> *Cc:* "interest at qt-project.org" <Interest at qt-project.org>
> *Subject:* Re: [Interest] Painting fonts without GUI
> Hi,
>
> you need a QGuiApplication for that. See e.g. this stackoverflow question
> <http://stackoverflow.com/questions/26205461/qpainter-drawtext-sigsegv-segmentation-fault>
> .
>
> Cheers,
> F.
>
>
> On 7 June 2016 at 11:04, Etienne Sandré-Chardonnal <etienne.sandre at m4x.org
> > wrote:
>>
>> Hi,
>>
>> When I try painting text over a QImage in a console only application with
>> QPainter::drawText, the program crashes.
>>
>> Is there any way to enable font painting in a non GUI application? It
>> should work without any X server, so in that case Qt should have a fallback
>> font? This does not need to be pretty text.
>>
>> Thanks!
>>
>> _______________________________________________
>> Interest mailing list
>> Interest at qt-project.org
>> http://lists.qt-project.org/mailman/listinfo/interest
>>
>
> _______________________________________________ Interest mailing list
> Interest at qt-project.org
> http://lists.qt-project.org/mailman/listinfo/interest
> _______________________________________________ Interest mailing list
> Interest at qt-project.org
> http://lists.qt-project.org/mailman/listinfo/interest
>
> _______________________________________________
> 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/20160607/020dd0c2/attachment.html>


More information about the Interest mailing list