Commit graph

81 commits

Author SHA1 Message Date
ericwa
41692e079d * Source/NSAttributedString.m
(-initWithData:options:documentAttributes:error:): Set
NSCharacterEncodingDocumentAttribute in the documentAttributes dict
when reading plain text.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@34987 72102866-910b-0410-8b05-ffd578937521
2012-03-23 03:16:40 +00:00
ericwa
01e2034c1c * Source/NSAttributedString.m
(-initWithData:options:documentAttributes:error:): Fixes for TextEdit.
If no type is provided, assume plain text. If no encoding is provided,
assume UTF-8 unless a UTF-16 BOM is detected.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@34985 72102866-910b-0410-8b05-ffd578937521
2012-03-23 01:40:11 +00:00
fredkiefer
7fec0a25f1 * Source/externs.m: Correct the strings for NSPrintPanel.
* Source/NSAttributedString.m (-setBaseWritingDirection:range:):
Add proper implementation for this method.
* Source/NSTextView_actions.m (-insertContainerBreak:,
-insertLineBreak): Add this methods.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@33254 72102866-910b-0410-8b05-ffd578937521
2011-06-06 11:33:40 +00:00
theraven
dbd4c1b77c Turn release messages sent to autorelease pools into drain messages. No
functionality change in non-GC mode, in GC mode it invokes a quick GC pass to
try to delete the short-lived objects.

Also deleted some [pool release] lines just before exit() or return-from-main
statements.  These cause objects to be swapped in and destructors to be run to
no benefit (the OS will reclaim this memory without requiring stuff to be
swapped in when the process exits).



git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@33146 72102866-910b-0410-8b05-ffd578937521
2011-05-27 12:42:37 +00:00
wlux
958681e979 Avoid potential illegal access violation introduced with the previous
commit.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30775 72102866-910b-0410-8b05-ffd578937521
2010-06-18 17:03:55 +00:00
wlux
cf66de78fc Attempt to auto detect the document type when initializing an
attributed string and the type wasn't specified by the caller.
Carefully add base URL to the document importing options only when it
is not nil.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30774 72102866-910b-0410-8b05-ffd578937521
2010-06-18 07:49:26 +00:00
fredkiefer
e64aca8bb2 few compiler warning fixes plus a lot of #import replacement.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30448 72102866-910b-0410-8b05-ffd578937521
2010-05-24 10:48:14 +00:00
wlux
e23c76d028 Change move word forwoard to move to the next end of a word rather
than the beginning of the next word so users can quickly navigate to
either end of words.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30056 72102866-910b-0410-8b05-ffd578937521
2010-03-27 21:51:33 +00:00
fredkiefer
ed8ede43f0 Make the signatures of methods consistent between headers and implementation files.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@29687 72102866-910b-0410-8b05-ffd578937521
2010-02-20 13:21:57 +00:00
wlux
414b85653e Fix a whole bunch of potential crashers in NSAttributedString.m and
NSDocument.m where the error return parameter was written to without a
null pointer check.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@29580 72102866-910b-0410-8b05-ffd578937521
2010-02-12 14:18:59 +00:00
fredkiefer
7a9c943bc4 Implementation of -rangeOfTextTable:atIndex: method on
NSAttributedString.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@29420 72102866-910b-0410-8b05-ffd578937521
2010-01-27 14:10:38 +00:00
fredkiefer
7efba8c5a4 Better handling of text attachtment. Fixes bug #28464
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@29260 72102866-910b-0410-8b05-ffd578937521
2010-01-11 12:32:27 +00:00
fredkiefer
e28685c8f8 Unify the text converter handling. Plus added a bit of implementation
for the new test block methods.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@28713 72102866-910b-0410-8b05-ffd578937521
2009-09-19 14:55:57 +00:00
rfm
f48b5d132e Small theme update, plus documentation fixes and tweaks to avoid warnings.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@28538 72102866-910b-0410-8b05-ffd578937521
2009-08-25 07:46:37 +00:00
fredkiefer
9d3c6e1abb Fix compiler warnings.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@28527 72102866-910b-0410-8b05-ffd578937521
2009-08-23 22:10:32 +00:00
fredkiefer
fcbcebd6da Improve localization.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@28014 72102866-910b-0410-8b05-ffd578937521
2009-03-01 17:42:46 +00:00
fredkiefer
a8bda5f526 Improvement of attributed string loading and attachment display in text
view.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@27705 72102866-910b-0410-8b05-ffd578937521
2009-01-27 19:16:04 +00:00
fredkiefer
0039705817 Basic implementation for NSAttributedString data save methods.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@27696 72102866-910b-0410-8b05-ffd578937521
2009-01-26 13:33:27 +00:00
fredkiefer
d0f3a643c4 Basic implementation of the initWithData:.. methods.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@27437 72102866-910b-0410-8b05-ffd578937521
2008-12-26 21:56:09 +00:00
wlux
6c32b0e7b6 Double clicking on a white space character also selects the
surrounding white space as on OS X.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@27131 72102866-910b-0410-8b05-ffd578937521
2008-11-25 21:46:23 +00:00
fedor
ce41d782c1 Revert library license version to 2 until applications can be converted
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@26619 72102866-910b-0410-8b05-ffd578937521
2008-06-10 04:01:49 +00:00
fredkiefer
3e0abcb588 Limit the amount of character sets cached by the font substitution code.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@26547 72102866-910b-0410-8b05-ffd578937521
2008-05-20 23:53:42 +00:00
fredkiefer
e25cceb710 Change all files to use GPL 3 and LGPL 3.
Prepare for next release.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@25536 72102866-910b-0410-8b05-ffd578937521
2007-10-29 21:16:17 +00:00
fredkiefer
6b8e1efd3e Ignore characters below 31 in font substitution.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@25404 72102866-910b-0410-8b05-ffd578937521
2007-08-21 09:04:52 +00:00
fredkiefer
cf7a64aef3 Let the font manager handle the font convertion for font subsitution.
Correct printing for the case where we know the page range.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@25386 72102866-910b-0410-8b05-ffd578937521
2007-08-12 20:12:19 +00:00
fredkiefer
4ad7e66022 First attempt at font attribute fixing.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@25384 72102866-910b-0410-8b05-ffd578937521
2007-08-09 09:39:50 +00:00
fredkiefer
0a607a5fbe Add new MacOSX methods. Code mostly by Nikolaus Schaller.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@25270 72102866-910b-0410-8b05-ffd578937521
2007-06-18 21:08:54 +00:00
rfm
d11b08e6c1 Add attributed string constants for Riccardo
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@24932 72102866-910b-0410-8b05-ffd578937521
2007-03-26 13:37:33 +00:00
fredkiefer
9a71af08ad Added MacOS 10.4 methods for NSDocument, NSDocumentController,
NSPrintOperation, NSResponder and NSCell.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@24378 72102866-910b-0410-8b05-ffd578937521
2007-01-17 12:09:41 +00:00
ratmice
d3895d8f14 * Source/NSTextView_actions.m: Change cursor movement implementations
when collapsing a selection.
        * Source/NSParagraphStyle.m (-setBaseWritingDirection:): Add comment.
        * Source/NSAttributedString: Add and remove characters in the word
        break character set.
        * KeyBindings/DefaultKeyBindings.dict: Change control-f and control-b
        to moveForward: and moveBackward:



git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@24136 72102866-910b-0410-8b05-ffd578937521
2006-11-20 16:20:15 +00:00
rfm
30182a3f19 documentation cleanups
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@24035 72102866-910b-0410-8b05-ffd578937521
2006-11-06 13:58:37 +00:00
fedor
db3c52eab8 Update FSF Address.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@21259 72102866-910b-0410-8b05-ffd578937521
2005-05-26 02:52:46 +00:00
alexm
116d860fa2 Add some missing void:s.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@19860 72102866-910b-0410-8b05-ffd578937521
2004-08-09 22:51:38 +00:00
FredKiefer
15de24ceb8 [readFromURL:options:documentAttributes:] corrected the handling
to type "text", where [NSString alloc] was missing.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@17595 72102866-910b-0410-8b05-ffd578937521
2003-09-01 18:14:47 +00:00
ayers
9732999fd8 Header reorganization - Please refer to ChangeLog
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@17408 72102866-910b-0410-8b05-ffd578937521
2003-07-31 23:52:10 +00:00
alexm
4d6166c0e2 (-fixParagraphStyleAttributeInRange:): Handle paragraphs with paragraph styles set for part of it correctly.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@17134 72102866-910b-0410-8b05-ffd578937521
2003-07-05 15:23:34 +00:00
fedor
fc402789db Include <> -> ""
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@16917 72102866-910b-0410-8b05-ffd578937521
2003-06-13 15:01:12 +00:00
alexm
68e87b286c (-fixAttachmentAttributesInRange:): Update end index when a character is deleted.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@15935 72102866-910b-0410-8b05-ffd578937521
2003-02-11 15:39:20 +00:00
FredKiefer
c71a9ff475 Implemented [textFileTypes], [textPasteboardTypes],
[textUnfilteredFileTypes], [textUnfilteredPasteboardTypes].


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@14414 72102866-910b-0410-8b05-ffd578937521
2002-09-06 23:38:57 +00:00
nico
ca4f9f5e36 When parsing RTF (or other formats) require the generated attributed
string to be of the appropriate class


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@13841 72102866-910b-0410-8b05-ffd578937521
2002-06-11 14:59:51 +00:00
nico
ddb3a8b91b Rewritten moving a word forward or backward
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@12428 72102866-910b-0410-8b05-ffd578937521
2002-02-08 01:53:18 +00:00
fedor
c51f4265da Markup for autogsdoc
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@11788 72102866-910b-0410-8b05-ffd578937521
2001-12-17 16:51:51 +00:00
nico
348f469ee4 Fixed problem when fixing up paragraph style attributes ... would get
into an infinite loop if no style was set at the beginning of paragraph


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@11596 72102866-910b-0410-8b05-ffd578937521
2001-12-02 11:12:52 +00:00
FredKiefer
4fbe4469d1 Protected all initXXX methods so that for empty input nil will be
returned.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@11098 72102866-910b-0410-8b05-ffd578937521
2001-10-06 22:30:54 +00:00
FredKiefer
3905d62a8f Implemented [readFromURL:options:documentAttributes:]. In
[applyFontTraits:range:] use [NSFontManager
convertFont:toHaveTrait:] instead of explicit font creation.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@10923 72102866-910b-0410-8b05-ffd578937521
2001-09-17 12:09:40 +00:00
fedor
60a7ef53c8 Moved text conversion classes to separate bundle
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@10755 72102866-910b-0410-8b05-ffd578937521
2001-08-21 14:52:00 +00:00
FredKiefer
d8b63f8de9 Include GSTextConverter.h. New function converter_class() to load
the class for a given text converter format. Use this function in
the RTF methods and use new protocol there.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@10720 72102866-910b-0410-8b05-ffd578937521
2001-08-18 22:03:17 +00:00
richard
d77897ddc3 Selection fixes
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@8450 72102866-910b-0410-8b05-ffd578937521
2000-12-27 06:28:29 +00:00
richard
f38731f7ca Handle apostrophes and hyphens within words.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@8415 72102866-910b-0410-8b05-ffd578937521
2000-12-23 07:10:27 +00:00
nico
fb8b620d44 Optimizations
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@8321 72102866-910b-0410-8b05-ffd578937521
2000-12-13 23:19:57 +00:00