Commit graph

6608 commits

Author SHA1 Message Date
Wolfgang Lux
8b3c88167f Do not attempt to open an untitled document upon launching a document
based application that does not define an editor type.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30535 72102866-910b-0410-8b05-ffd578937521
2010-06-01 21:36:51 +00:00
Quentin Mathe
bdd7d8d739 Removed unwanted ivar addition with r30523
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30524 72102866-910b-0410-8b05-ffd578937521
2010-06-01 11:10:13 +00:00
Quentin Mathe
9be1f4da8e Fixed many drawing issues (many ones being related to the flipping).
See bug report #27782

In particular, fixed -[NSImage drawXXX] and -[NSImage composite/dissolveXXX] 
methods to work exactly as Cocoa when the Cairo backend is used.
Added a new draw operator (in addition to composite) to the backend. Cairo is 
the only backend that implements it for now.
Eliminated as many flipping checks as possible.

Warning: Untested with the winlib backend. 
You must update, recompile and install both Back and Gui.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30523 72102866-910b-0410-8b05-ffd578937521
2010-06-01 11:04:36 +00:00
Wolfgang Lux
128a121bc8 Disable directory selection in open panels presented by
NSDocumentController, which is useless since document file packages
are shown as plain files in the panel.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30516 72102866-910b-0410-8b05-ffd578937521
2010-05-31 22:34:05 +00:00
Wolfgang Lux
1131d859de Fix NSAlert implementation so that buttons are assigned tags starting
with NSAlertFirstButtonReturn, except if the panel was created with
the backward compatibility method +alertWithMessageText:defaultButton:...
Also assign appropriate key equivalents to buttons in panels created
with the old OpenStep alert panel functions.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30515 72102866-910b-0410-8b05-ffd578937521
2010-05-31 22:20:38 +00:00
Fred Kiefer
84f54304e1 * Headers/AppKit/NSOutlineView.h,
* Source/NSOutlineView.m: Add -parentForItem: and -frameOfOutlineCellAtRow:. 
Use the later in -drawRow:clipRect:.
Change methods to use NSInteger and CGFloat.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30514 72102866-910b-0410-8b05-ffd578937521
2010-05-31 22:18:45 +00:00
Wolfgang Lux
b59b4e7e32 Avoid a race with some lame window managers, which could lead to a
crash when a window is closed and deallocated while a tool tip is
visible.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30513 72102866-910b-0410-8b05-ffd578937521
2010-05-31 21:55:33 +00:00
Wolfgang Lux
fc76fad1a0 Add support for document types with a wild card extension to
NSDocumentController and NSDocument.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30512 72102866-910b-0410-8b05-ffd578937521
2010-05-31 21:40:13 +00:00
Dave Wetzel
79ac03cdf1 new Files NSViewController.h and NSViewController.m. Fixes #29822
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30506 72102866-910b-0410-8b05-ffd578937521
2010-05-31 03:46:35 +00:00
Wolfgang Lux
d31f3c26d7 Avoid loading a window controller's nib prematurely if the document
edited status is changed.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30500 72102866-910b-0410-8b05-ffd578937521
2010-05-30 22:55:39 +00:00
Wolfgang Lux
6b7116a19a Fixed keyed decoding of NSFont to fall back to a standard font only if
the named font was not found.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30499 72102866-910b-0410-8b05-ffd578937521
2010-05-30 21:47:04 +00:00
Wolfgang Lux
36c6a1a4bb Select text restored by an undo in a NSTextView and set insertion
point to the end of the changed text after a redo.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30498 72102866-910b-0410-8b05-ffd578937521
2010-05-30 21:17:50 +00:00
Wolfgang Lux
cec8360d99 Really commit the NSTextContainer changes of r30491 and not only their
change log.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30497 72102866-910b-0410-8b05-ffd578937521
2010-05-30 20:57:01 +00:00
Wolfgang Lux
724a198f41 Ensure a more consistent initial setup of a new NSTextView and its
text container.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30495 72102866-910b-0410-8b05-ffd578937521
2010-05-30 18:25:17 +00:00
Wolfgang Lux
027baea2fa Replace a bogus workaround to set up the text network of a NSTextView
loaded from a .nib file with a clean solution and fix decoding and
encoding of a few text view flags, which did not match Cocoa.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30493 72102866-910b-0410-8b05-ffd578937521
2010-05-30 18:18:26 +00:00
Wolfgang Lux
a4896d797f Use more reasonable container size when initializing NSTextContainer
instances and fix incorrect decoding of NSTextContainer flags when
reading .nib files created with Apple's Interface Builder.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30491 72102866-910b-0410-8b05-ffd578937521
2010-05-30 18:02:33 +00:00
Wolfgang Lux
424440dd30 Make NSLayoutManager attributes and flags persistent when using a
keyed archiver, i.e., saving or loading a .nib file.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30490 72102866-910b-0410-8b05-ffd578937521
2010-05-30 17:51:29 +00:00
Gregory John Casamento
8f800dd3ed * Source/NSSplitView.m: In mouseDown: initialize p and op to
NSZeroPoint to prevent compiler warning.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30475 72102866-910b-0410-8b05-ffd578937521
2010-05-29 15:52:29 +00:00
Gregory John Casamento
513ebb1947 * Source/NSBitmapImageRep+PNG.m: Reverting change which removed
check for setjmp.  This was causing a compilation error.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30474 72102866-910b-0410-8b05-ffd578937521
2010-05-29 15:27:59 +00:00
Wolfgang Lux
a8e617e01f Correct serious nib loading bug on big endian machines.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30472 72102866-910b-0410-8b05-ffd578937521
2010-05-29 08:32:02 +00:00
Gregory John Casamento
c16d9fc03a Change to makefile for Xib change.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30469 72102866-910b-0410-8b05-ffd578937521
2010-05-29 05:30:38 +00:00
Gregory John Casamento
16e8d19fa0 * Source/GSXibLoader.m: Took out interface definitions and moved them.
* Headers/Additions/GNUstepGUI/GSXibLoading.h: New file 
	which contains the definitions for the new classes defined in 
	GSXibLoader.m.  This change will allow those classes to be used by
	applications such as Gorm.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30468 72102866-910b-0410-8b05-ffd578937521
2010-05-29 05:29:29 +00:00
Gregory John Casamento
dae9464580 Add Xib loading header so that the classes in the GSXibLoader can be used by applications.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30467 72102866-910b-0410-8b05-ffd578937521
2010-05-29 05:27:04 +00:00
Riccardo Mottola
80dd8c94d0 Skip libpng's check for setjmp. I hope we are indeed correct.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30453 72102866-910b-0410-8b05-ffd578937521
2010-05-25 11:00:03 +00:00
Fred Kiefer
be6dd7b23a Another small change for gcc 2.95
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30450 72102866-910b-0410-8b05-ffd578937521
2010-05-24 20:09:17 +00:00
Fred Kiefer
d9172838aa Small corrections to last commit.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30449 72102866-910b-0410-8b05-ffd578937521
2010-05-24 19:30:49 +00:00
Fred Kiefer
99e273a57d 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
Doug Simons
24fad47739 Make toolbar resizing behavior match the Cocoa behavior
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30440 72102866-910b-0410-8b05-ffd578937521
2010-05-21 15:01:45 +00:00
Gregory John Casamento
70ab53498d * Headers/Additions/GNUstepGUI/GSTheme.h: Added method
displayPopUpMenu:... to handle the display of the popup menus for
	themes.
	* Source/GSThemeMenu.m: Added default implementation.
	* Source/NSPopUpButtonCell.m: Call the displayPopUpMenu:... method
	in the method attachPopUpWithFrame:inView:.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30433 72102866-910b-0410-8b05-ffd578937521
2010-05-20 08:09:08 +00:00
Quentin Mathe
fe5c6189cf Removed Protocol.h import to eliminate potential return type conflicts, between
-(unsigned int)hash from Object and -(NSUInteger)hash from NSObject, when the 
receiver is of type (id).


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30429 72102866-910b-0410-8b05-ffd578937521
2010-05-19 15:54:06 +00:00
Gregory John Casamento
8d46a61c7d Spelling correction in ChangeLog.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30424 72102866-910b-0410-8b05-ffd578937521
2010-05-19 04:58:20 +00:00
Riccardo Mottola
0a65923993 changed header include to import
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30415 72102866-910b-0410-8b05-ffd578937521
2010-05-18 22:24:07 +00:00
Fred Kiefer
664d8a24c1 * Source/NSToolbarItem.m (-setView:): Only set the min/max size of
the toolbar item when it was zero.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30413 72102866-910b-0410-8b05-ffd578937521
2010-05-17 20:19:00 +00:00
Richard Frith-MacDonald
3ea29572c2 Add dependency on 'Version' and 'configure' to reconfigure if either changes
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30412 72102866-910b-0410-8b05-ffd578937521
2010-05-17 16:38:59 +00:00
Gregory John Casamento
3cdbf7591f * Source/NSApplication.m: Attempt to open files from the command
line, if possible in -finishLaunching.  This matches the behavior
	seen on OpenStep and on Mac OS X/Cocoa.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30407 72102866-910b-0410-8b05-ffd578937521
2010-05-17 08:29:55 +00:00
Quentin Mathe
06c9f9a37a Forgot to update the Change for my previous commit
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30399 72102866-910b-0410-8b05-ffd578937521
2010-05-16 13:57:19 +00:00
Quentin Mathe
5285361395 Moved the main Nib file loading from -finishLaunching to NSApplicationMain() in
order to match Cocoa behavior/documentation.

This makes easier to implement a custom AppKit main that works with both Cocoa 
and GNUstep.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30398 72102866-910b-0410-8b05-ffd578937521
2010-05-16 13:56:50 +00:00
Wolfgang Lux
b90707ed47 Fix bug where a window was ignoring its autosaved frame when loaded
from a .nib file.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30396 72102866-910b-0410-8b05-ffd578937521
2010-05-15 21:00:25 +00:00
Wolfgang Lux
6c2fb0bd9b Remove key equivalents from the font manager's default font menu that
conflict with standard key equivalents.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30395 72102866-910b-0410-8b05-ffd578937521
2010-05-15 20:52:29 +00:00
Wolfgang Lux
6029fc9d6c Propagate the change of NSWindow's designated initializer to all
affected subclasses.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30394 72102866-910b-0410-8b05-ffd578937521
2010-05-15 20:43:27 +00:00
Wolfgang Lux
525f1c40c4 Add support for a recent documents menu in .gorm files.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30390 72102866-910b-0410-8b05-ffd578937521
2010-05-14 19:20:45 +00:00
Wolfgang Lux
7f90afe7bc Give the application delegate a chance to open documents from the
recent documents menu. This makes the menu available to non-document
based applications as documented and implemented by Apple.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30386 72102866-910b-0410-8b05-ffd578937521
2010-05-14 07:42:34 +00:00
Fred Kiefer
0693cd9edc Toolbar resizing: If there are flexible items and flexible space the items will be expanded
first.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30381 72102866-910b-0410-8b05-ffd578937521
2010-05-13 16:29:38 +00:00
Fred Kiefer
4335c12ae4 Further improvement of toolbar resizing and missing changelog entry.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30380 72102866-910b-0410-8b05-ffd578937521
2010-05-13 14:25:54 +00:00
Wolfgang Lux
ccfd4b4fd5 Don't send -awakeFromNib to an NSApplication proxy in a .nib file (nor
any other proxy) and do not record it in the top level array either.
Identification of proxy objects is based on their object IDs.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30379 72102866-910b-0410-8b05-ffd578937521
2010-05-13 14:08:26 +00:00
Wolfgang Lux
809a378e24 Ensure proper order of actions when loading a .nib file and make sure
all objects are instantiated before establishing any connections. This
fixes an issue where, e.g., a generic shared document controller
instance is created before a custom instance defined in the nib file.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30376 72102866-910b-0410-8b05-ffd578937521
2010-05-13 13:01:44 +00:00
Fred Kiefer
ed30b6221a Clean up toolbar item resizing, this now allows for resizable item other than flexible space.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30371 72102866-910b-0410-8b05-ffd578937521
2010-05-12 23:06:02 +00:00
Gregory John Casamento
562f545bd3 * Headers/Additions/GNUstepGUI/GSTheme.h: Added method
rightMouseMenu:forEvent: to allow theming of transient and
	context menus.
	* Source/GSThemeMenu.m: Implementation of method 
	rightMouseMenu:forEvent: to allow theming of transient and
	context menus.
	* Source/NSMenu.m: use the theming code implemented above instead
	of rendering the menu directly.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30370 72102866-910b-0410-8b05-ffd578937521
2010-05-12 22:47:10 +00:00
Wolfgang Lux
fb7e725344 Fix a rather long standing incompatibility between GNUstep and Cocoa
and make -initWithContentRect:styleMask:backing:defer: the designated
initializer of NSWindow.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30368 72102866-910b-0410-8b05-ffd578937521
2010-05-12 14:47:10 +00:00
Wolfgang Lux
77eaadf3ae Next attempt at getting .nib file loading right. Make sure that
-nibInstantiate is sent to all loaded objects and also make sure that
-awakeFromNib is sent to the nib's owner.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30367 72102866-910b-0410-8b05-ffd578937521
2010-05-12 14:19:55 +00:00