discuss-gnustep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Hang in font panel with certain fonts


From: Fred Kiefer
Subject: Re: Hang in font panel with certain fonts
Date: Thu, 08 Jan 2015 21:22:29 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.3.0

Hi Riccardo,

could you please explain what you mean by "hang"?
And did you get the same stack trace after continuing your application
for some time and then stopping it again?
The line your reported stack trace is in looks rather harmless:


    CGFloat f_ascender = [f ascender], f_descender = -[f descender];


Sorry for being of no help here,
Fred

Am 07.01.2015 um 13:29 schrieb Riccardo Mottola:
> Hi,
> 
> while playing with fonts for Johannes' problem I was able to hang Ink
> consistently.
> 
> I just need to select the font "Terminal" and the whole app freezes. I'm
> using the cairo backend.
> 
> I reproduced this in gdb and report some debugging info:
> 
> #0  0xbb18db9d in objc_msgSend_fpret ()
>    from /System/Library/Libraries/libobjc.so.4.6
> #1  0xbba131b8 in -[GSHorizontalTypesetter layoutLineNewParagraph:] (
>     self=0xb8399088, _cmd=0x0, newParagraph=1 '\001')
>     at GSHorizontalTypesetter.m:709
> #2  0xbba1492b in -[GSHorizontalTypesetter
> layoutGlyphsInLayoutManager:inTextContainer:startingAtGlyphIndex:previousLineFragmentRect:nextGlyphIndex:numberOfLineFragments:]
> (self=0x0, _cmd=0xbbba52c0, layoutManager=<optimized out>,
>     textContainer=<optimized out>, glyphIndex=<optimized out>,
>     previousLineFragRect=..., nextGlyphIndex=<optimized out>,
>     howMany=<optimized out>) at GSHorizontalTypesetter.m:1281
> #3  0xbba0e812 in -[GSLayoutManager(LayoutHelpers) _doLayoutToContainer:] (
>     self=0xb8399088, _cmd=0xb8028498, cindex=<optimized out>)
>     at GSLayoutManager.m:2000
> #4  0xbba0fa6a in -[GSLayoutManager(layout) usedRectForTextContainer:] (
>     self=0xb803c608, _cmd=0xbbb6fd98, container=<optimized out>)
>     at GSLayoutManager.m:2627
> #5  0xbb9723ec in cache_lookup (hasSize=<optimized out>,
>     useScreenFonts=<optimized out>, size=<optimized out>)
>     at NSStringDrawing.m:317
> #6  0xbb972614 in -[NSAttributedString(NSStringDrawing)
> drawWithRect:options:]
>     (self=<optimized out>, _cmd=0xa, rect=..., options=3086229288)
>     at NSStringDrawing.m:430
> #7  0xbb97247c in -[NSAttributedString(NSStringDrawing) drawInRect:] (
>     self=0xb7f68468, _cmd=0xbbb7b018, rect=...) at NSStringDrawing.m:407
> #8  0xbb99451d in -[NSTextFieldCell drawInteriorWithFrame:inView:] (
>     self=<optimized out>, _cmd=0x40400000, cellFrame=...,
>     controlView=<optimized out>) at NSTextFieldCell.m:241
> #9  0xbb897d06 in -[NSCell drawWithFrame:inView:] (self=0xb7f41f28,
>     _cmd=0xbbb06e88, cellFrame=..., controlView=<optimized out>)
>     at NSCell.m:2114
> #10 0xbb84b79d in -[NSActionCell drawWithFrame:inView:] (self=<optimized
> out>,
>     _cmd=0xb8dc9ef8, cellFrame=..., controlView=<optimized out>)
>     at NSActionCell.m:344
> #11 0xbb8ba468 in -[NSControl drawCell:] (self=<optimized out>,
>     _cmd=0xbbb27e00, aCell=0xb7f41f28) at NSControl.m:685
> #12 0xbb8ba3f9 in -[NSControl drawRect:] (self=0xb8dc9ef8, _cmd=0xbbb89e60,
>     aRect=...) at NSControl.m:675
> #13 0xbb9c4a0d in -[NSView displayRectIgnoringOpacity:inContext:] (
>     self=0xb8dc9ef8, _cmd=0xbbb8865c, aRect=..., context=0xb825e6a8)
>     at NSView.m:2570
> #14 0xbb9c430c in -[NSView displayRectIgnoringOpacity:] (self=0xb8dc9ef8,
>     _cmd=0xbbb89f40, aRect=...) at NSView.m:2519
> #15 0xbb9c3e02 in -[NSView displayIfNeededInRectIgnoringOpacity:] (
>     self=0xb8dc9ef8, _cmd=0x0, aRect=...) at NSView.m:2450
> #16 0xbb9c4117 in -[NSView displayIfNeededInRectIgnoringOpacity:] (
> 
> in # I get:
> $1 = (struct NSFont *) 0xb7ca3c88
> (gdb) p *f
> $2 = {<> = {isa = 0xbbb31f40}, fontName = 0xbbb31f40, matrix = {
>     -0.00546637177, -2.94079218e-05, 12, 0, 0, 12},
>   matrixExplicitlySet = 64 '@', screenFont = 64 '@', fontInfo = 0xbbb31f40,
>   _fontRef = 0xbbb31f40, role = -1145888960, cachedScreenFont = 0xbbb31f40,
>   cachedFlippedFont = 0xbbb31f40}
> 
> (gdb) po f
> <NSFont: 0xb7ca3c88> Terminal 12.000 0.000 0.000 12.000 0.000 0.000 S 0
> 
> but in #2, why is self 0x0 ?
> 
> I checked in xfontsel and the font is a typical bitmap font for terminal
> display, what is strange is that there size "0" is listed, could that
> confuse gnustep/cairo?
> I can use this Terminal font in other apps, e.g. Emacs, without troubles.
> 
> Riccardo




reply via email to

[Prev in Thread] Current Thread [Next in Thread]