On Sun, Feb 15, 2009 at 12:26 AM, Aki Inoue wrote:
> The most simple logic for getting the default line height can be accessible
> via -[NSLayoutManager defaultLineHeightForFont:].
> AppKit puts descent + leading below the baseline, so you should be able to
> calculate the line spacing delta on to
On Sat, Feb 14, 2009 at 9:58 PM, Aki Inoue wrote:
The Text System encapsulates the logic to determine the ideal
layout. It's
not just queried from a font instance. It requires the context of
an entire
line.
What if the line is rendered with a single font? Which font attributes
are invo
On Sat, Feb 14, 2009 at 9:58 PM, Aki Inoue wrote:
> The Text System encapsulates the logic to determine the ideal layout. It's
> not just queried from a font instance. It requires the context of an entire
> line.
What if the line is rendered with a single font? Which font attributes
are involve
Slava,
Calculating an optimal vertical layout is pretty involved. At least,
the Cocoa Text System has sophisticated logic to determine the ideal
layout because of the numerous and varying design target for different
fonts.
For example, as you found out, many fonts designed in 80s have pr
Is there a way to compute what the default leading would be for a
font? This is for a Mac OS backend of a cross-platform GUI toolkit, so
I can't really just use NSTextView here.
Slava
On Fri, Feb 13, 2009 at 9:16 PM, Graham Cox wrote:
> Line spacing (or to be more precise, leading) is an attribu
On 14 Feb 2009, at 1:15 pm, Slava Pestov wrote:
Hi all,
Can someone enlighten me, how does NSTextView compute line spacing?
When I display a piece of text in stickies, with Helvetica 12 (or any
other font, really), and the same piece of text in my application,
stickies adds another 2 pixels o
Hi all,
Can someone enlighten me, how does NSTextView compute line spacing?
When I display a piece of text in stickies, with Helvetica 12 (or any
other font, really), and the same piece of text in my application,
stickies adds another 2 pixels of spacing between every line, and the
result looks m