Usability improvements: When setting the cursor to the beginning of a

line, set the typing attributes to the attributes of the first character
of that line rather than the preceding newline. When deleting text, set
the typing attributes to those of the first deleted character rather
than those of the character preceding the deleted range.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30055 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
wlux 2010-03-27 21:41:29 +00:00
parent 21b251d643
commit d0a7bfda42
3 changed files with 25 additions and 1 deletions

View file

@ -3597,7 +3597,9 @@ afterString in order over charRange.
{
NSDictionary *dict;
if (charRange.location > 0)
if (charRange.location > 0 &&
[[_textStorage string] characterAtIndex:
(charRange.location - 1)] != '\n')
{
/* If the insertion point is after a bold word, for
example, we need to use bold for further