I have a document window.
In the IDE I set maximise button = off, and fullscreen button = off
Yet when the app runs, the maximise button is there, and clicking it makes the app go full screen.
Whats up with that?
I have a document window.
In the IDE I set maximise button = off, and fullscreen button = off
Yet when the app runs, the maximise button is there, and clicking it makes the app go full screen.
Whats up with that?
From the AppKit release notes, emphasis mines:
Well that’s pants.
Explained, but for goodness sake, Apple…
Its making a mess of other modal windows with a handful of controls, which open in front and then immediately resize to the whole screen, looking ridiculous.
[quote=245875:@Jeff Tullin]Well that’s pants.
Explained, but for goodness sake, Apple…
Its making a mess of other modal windows with a handful of controls, which open in front and then immediately resize to the whole screen, looking ridiculous.[/quote]
Here’s an old forum post about the full screen behavior that might help.
I set the maxwidth and maxheight to 1600 x 1200 and that works fine on a high res screen.
But switching back to retina display, OSX sees that the max values are bigger than the screen, and allows full screen again.
The code in the referenced post does make a difference
[code]Declare Function collectionBehavior Lib “AppKit” Selector “collectionBehavior” ( obj As Integer ) As UInteger
Declare Sub setCollectionBehavior Lib “AppKit” Selector “setCollectionBehavior:” ( obj As Integer, value As UInteger )
Const NSWindowCollectionBehaviorFullScreenAuxiliary As UInteger = 256
Dim behavior As UInteger = collectionBehavior(self.Handle)
setCollectionBehavior(self.handle, behavior Or NSWindowCollectionBehaviorFullScreenAuxiliary)
[/code]
(Although for a while I thought it didnt… the Open event doesn’t fire, so I had to put this into Activate.)
No doubt thats another story
[quote=245913:@Jeff Tullin](Although for a while I thought it didnt… the Open event doesn’t fire, so I had to put this into Activate.)
[/quote]
That’s… odd.
It is but I’ve given up wondering. Ive seen this plenty of times over the years.
Every weirdness like this, I just add another layer of workaround.
[quote=245913:@Jeff Tullin](Although for a while I thought it didnt… the Open event doesn’t fire, so I had to put this into Activate.)
No doubt thats another story[/quote]
I have seen weirdness like that too. Several different versions of Answers have several different methods of setting positioning of the main window. This latest version seems to be most reliable, and most succinct; but pre 1.1 versions had some weird workarounds.
Do you have a toolbar assigned to the window? Assigning a toolbar auto enables the maximize button. <https://xojo.com/issue/28433>
However it enabling fullscreen is something I’ve not seen before. I often disable full screen for my own apps; as I quite frankly don’t really like Full Screen apps.
I’ve just tested it here, for a simple window, the toolbar does enable the maximize button, but not Full Screen. Have you tried restarting?
No. This is the stated resizable document window with a title that didnt have an upper size.
But the Appkit code above does solve the feature.