Re: Pango cairo target surface size

Rob Kramer <[email protected]>
Newsgroups gmane.comp.lib.cairo
Message-ID <[email protected]>
On 03/24/2015 12:13 PM, Lawrence D'Oliveiro wrote:
> On Tue, 24 Mar 2015 12:06:39 +0800, Rob Kramer wrote:
>
>> On 03/24/2015 11:21 AM, Lawrence D'Oliveiro wrote:
>>
>>> On Tue, 24 Mar 2015 10:41:40 +0800, Rob Kramer wrote:
>>>
>>>> What I want to do is paint a string to a surface the same size as
>>>> the text's logical extents -- without doing the text layouting
>>>> twice
>>> Why is it important that it is not done twice?
>> Efficiency, elegance, etc. I'm just trying to find out if cairo pango
>> has a better way to do this..
> How do other graphics APIs do it?

My current implementation uses a helper library called SDL-pango, which 
just handles all Pango stuff and has full control over layouting etc. It 
can do all extent calculations, and then create a bitmap surface. The 
library is not maintained however, and doesn't deal with SDL2 textures 
-- which led me to investigate cairo-pango.

-- 
cairo mailing list
[email protected]
http://lists.cairographics.org/mailman/listinfo/cairo
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.