Re: NSScrollView showing part of view with white space above

2019-10-13 Thread Aandi Inston via Cocoa-dev
underlying (scrolled) NSView must be correct because it always was correct when shown without the NSScrollView. (The NSScrollView was added only if the window layout would not fit on screen). But, the window was created from coordinates that are top down (origin top left). This has been managed before

Re: NSScrollView showing part of view with white space above

2019-10-13 Thread Quincey Morris via Cocoa-dev
On Oct 13, 2019, at 06:30 , Aandi Inston via Cocoa-dev wrote: > > If the NSScrollView is scrolled upwards, the content in the window moves down > (as normal). What we now see is a large white space at the top of the > NSScrollView, and below that the same view portion we first saw

NSScrollView showing part of view with white space above

2019-10-13 Thread Aandi Inston via Cocoa-dev
I have having a problem working with NSScrollView. The code is in pieces all over the desk at the moment, but I'm asking in case someone recognises the symptoms, before I reduce this to a simple test case. An NSScrollView is made from an NSView containing various NSControls. The NSView is fine

Re: Resizing NSScrollView/NSClipView to fit NSTableView width

2016-08-19 Thread Quincey Morris
On Aug 16, 2016, at 01:13 , studfed studfed wrote: > > The problem is that table view is clipped by scroll view (what I mean is that > last several columns are visible only if you scroll to the right, but I would > like to have these last columns be visible without scrollers

Re: Resizing NSScrollView/NSClipView to fit NSTableView width

2016-08-15 Thread Quincey Morris
On Aug 15, 2016, at 10:22 , studfed studfed wrote: > > I am not sure if it is the right way to prevent table clipping. > Are there any other options to accomplish this or this one is correct also > ? No, this is not really the right way. You should not be setting frames

Resizing NSScrollView/NSClipView to fit NSTableView width

2016-08-15 Thread studfed studfed
MyView NSScrollView ClipView TableView The problem is that as soon as columns count grows, table becomes clipped. The only way to set scrollview/clipview to fit table width, was to set

Re: How to Truncate lines in NSScrollView/NSClipView/NSTextView Combo

2016-04-27 Thread Dave
> On 27 Apr 2016, at 09:01, Martin Wierschin wrote: > > This code is never going to work: > >> [[myTextView textStorage] addAttribute:NSParagraphStyleAttributeName >> value:[NSNumber numberWithInt:NSLineBreakByTruncatingTail] range:myRange]; >> >> But this results in

Re: How to Truncate lines in NSScrollView/NSClipView/NSTextView Combo

2016-04-27 Thread Martin Wierschin
This code is never going to work: > [[myTextView textStorage] addAttribute:NSParagraphStyleAttributeName > value:[NSNumber numberWithInt:NSLineBreakByTruncatingTail] range:myRange]; > > But this results in nothing being displayed in the ScrollView/TextView. In fact, using that code probably

Re: How to Truncate lines in NSScrollView/NSClipView/NSTextView Combo

2016-04-26 Thread Graham Cox
> On 27 Apr 2016, at 9:29 AM, Graham Cox wrote: > > [[theTextView textContainer] setContainerSize:NSMakeSize(contentSize.width, > FLT_MAX)]; Oops, that should be: [[theTextView textContainer] setContainerSize:NSMakeSize(FLT_MAX, contentSize.height)]; G.

Re: How to Truncate lines in NSScrollView/NSClipView/NSTextView Combo

2016-04-26 Thread Graham Cox
> On 26 Apr 2016, at 8:25 PM, Dave <d...@looktowindward.com> wrote: > > maybe its just impossible using an NSScrollView/NSTextView. In fact, since > there isn’t a handy-dandy method or property on any of the classes in > question to just do it, I’m beginning to

Re: How to Truncate lines in NSScrollView/NSClipView/NSTextView Combo

2016-04-26 Thread Dave
Hi, I did do quite a few searches but I didn’t find that - I’m not that good at formulating the correct search string, I think was trying things like "NSScrollView Truncate Text”. Anyway, I managed to piece together something that would and I created a Category method on NSScrollView

Re: How to Truncate lines in NSScrollView/NSClipView/NSTextView Combo

2016-04-26 Thread Gary L. Wade
to-Layout, maybe its just impossible using an > NSScrollView/NSTextView. In fact, since there isn’t a handy-dandy method or > property on any of the classes in question to just do it, I’m beginning to > think that’s the case. > > Apple’s documentation is so bad that I can’t find anyt

Re: How to Truncate lines in NSScrollView/NSClipView/NSTextView Combo

2016-04-26 Thread Dave
Hi, I’ve tried loads of different way of doing it but none of them work. Maybe its because I’m not using Auto-Layout, maybe its just impossible using an NSScrollView/NSTextView. In fact, since there isn’t a handy-dandy method or property on any of the classes in question to just do it, I’m

Re: How to Truncate lines in NSScrollView/NSClipView/NSTextView Combo

2016-04-26 Thread Bill Cheeseman
Graham Cox is right. I realized overnight that I was misinterpreting your question. I happen to be working on truncation of text myself, and I was focused on the usual meaning of "truncation" in the attributed string context. It means placing three periods at the end or in the middle of

Re: How to Truncate lines in NSScrollView/NSClipView/NSTextView Combo

2016-04-25 Thread Graham Cox
> On 26 Apr 2016, at 2:08 AM, Dave wrote: > > If anyone knows the secret please let me know! Set the associated text container to an extremely wide width. The text won’t wrap unless there’s a line break. —Graham ___

Re: How to Truncate lines in NSScrollView/NSClipView/NSTextView Combo

2016-04-25 Thread Dave
I tried the following: myTextView = [self documentView]; [[[myTextView textStorage] mutableString] appendString:theString]; myRange = NSMakeRange(0,[[[myTextView textStorage] mutableString] length] - 1); [[myTextView textStorage] addAttribute:NSParagraphStyleAttributeName value:[NSNumber

Re: How to Truncate lines in NSScrollView/NSClipView/NSTextView Combo

2016-04-25 Thread Dave
Hi Bill, I’m familiar with NSAttributedString and friends. I had thought that there was a higher level interface to it as it seems like a common thing to want to do. Basically my ScrollView is just a scrolling line log similar to XCode’s NSLog window. I’m just appending an NSString to the

Re: How to Truncate lines in NSScrollView/NSClipView/NSTextView Combo

2016-04-25 Thread Bill Cheeseman
> On Apr 25, 2016, at 6:48 AM, Dave wrote: > > I can’t believe its this hard to set wrapping or not and I can’t find real > info on this from searching either. For your purposes, the key point is that NSTextStorage is a subclass of NSMutableAttributedString, which

Re: How to Truncate lines in NSScrollView/NSClipView/NSTextView Combo

2016-04-25 Thread Dave
I’ve found the Text Storage like this: NSTextStorage* myTextStorage; myTextStorage = [[self.pLogScrollView documentView] textStorage]; > You can control trucation behavior in an NSTextView by using NSTextStorage, > which is a subclass of NSMutableAttributedString. The truncation

Re: How to Truncate lines in NSScrollView/NSClipView/NSTextView Combo

2016-04-24 Thread Bill Cheeseman
> On Apr 24, 2016, at 1:13 PM, Dave wrote: > > I’ve got the Text View Selected in XCode/IB and I can’t find any option for > “Layout” in any of the property tabs? Auto-layout is off at the moment for > this window, it wouldn’t have anything to do with that would it?

Re: How to Truncate lines in NSScrollView/NSClipView/NSTextView Combo

2016-04-24 Thread Dave
Hi, > On 24 Apr 2016, at 17:29, Bill Cheeseman <wjcheese...@gmail.com> wrote: > > >> On Apr 24, 2016, at 12:04 PM, Dave <d...@looktowindward.com >> <mailto:d...@looktowindward.com>> wrote: >> >> I’m not sure what you mean? Is this a m

Re: How to Truncate lines in NSScrollView/NSClipView/NSTextView Combo

2016-04-24 Thread Bill Cheeseman
> On Apr 24, 2016, at 12:04 PM, Dave <d...@looktowindward.com> wrote: > > I’m not sure what you mean? Is this a method or property on NSScrollView or > NSTextView? > > I can’t see it in the XIB file? In an NSTextField, IB shows you the "Layout" pop-up menu,

Re: How to Truncate lines in NSScrollView/NSClipView/NSTextView Combo

2016-04-24 Thread Dave
Hi, I’m not sure what you mean? Is this a method or property on NSScrollView or NSTextView? I can’t see it in the XIB file? Cheers Davw > On 24 Apr 2016, at 16:58, Andreas Mayer <andr...@harmless.de> wrote: > > >> Am 24.04.2016 um 17:15 schrieb Dave <d...@looktowind

Re: How to Truncate lines in NSScrollView/NSClipView/NSTextView Combo

2016-04-24 Thread Andreas Mayer
> Am 24.04.2016 um 17:15 schrieb Dave <d...@looktowindward.com>: > > I have an NSTextView inside an NSScrollView. At present the Text Lines is > wrapped if they are longer than the Scroll View, I'd them to truncate. I had > thought I’d seen some properties somewhere for d

How to Truncate lines in NSScrollView/NSClipView/NSTextView Combo

2016-04-24 Thread Dave
Hi All, I know this has been covered before but I can’t for the life of me find it by searching. I have an NSTextView inside an NSScrollView. At present the Text Lines is wrapped if they are longer than the Scroll View, I'd them to truncate. I had thought I’d seen some properties somewhere

Re: Smooth adjustScroll of NSScrollView

2015-10-29 Thread Nick
Thanks Jens, Charles! 2015-10-28 6:59 GMT+02:00 Charles Constant : > I don't know if this information can solve your issue directly, but I used > it to fix my issue last week. I have a custom NSScroller that had jerky > scrolling. I didn't realize that views have an

Re: Smooth adjustScroll of NSScrollView

2015-10-27 Thread Nick
Let me explain what I am trying to achieve. Here's my application with an NSScrollView, and it's documentView (which is an NSView subclass) implements a method -(NSRect)adjustScroll:(NSRect)newVisible { NSRect modifiedRect = newVisible; modifiedRect.origin.y = (int

Re: Smooth adjustScroll of NSScrollView

2015-10-27 Thread Jens Alfke
I’m guessing they wait for the scrolling to finish [not sure how, maybe just polling the scroll position], then use Core Animation to set the scroll position to the nearest grid-line. —Jens ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Re: Smooth adjustScroll of NSScrollView

2015-10-27 Thread Charles Constant
I don't know if this information can solve your issue directly, but I used it to fix my issue last week. I have a custom NSScroller that had jerky scrolling. I didn't realize that views have an ".animator()" proxy that you can use instead. NSAnimationContext.beginGrouping()

Smooth adjustScroll of NSScrollView

2015-10-26 Thread Nick
Hi I am developing an application that looks similar to the OS X's Calendar.app. One of the nice features it has is the "gravity effect" to the grid lines, when the user performs vertical scrolling - if you scroll the calendar so that half-row is clipped by the Clip View, it automatically scrolls

Setting the position of a NSScrollView

2015-09-09 Thread Dave
Also tried: NSPoint myScrollPosition; myScrollPosition = NSMakePoint(0,0); [[self.pValidationIssueScrollView documentView] scrollPoint:myScrollPosition]; This is being called in windowDidLoad but I’ve also tried calling it in awakeFromLib

Setting the position of a NSScrollView

2015-09-09 Thread Dave
of the NSScrollView is Flipped, does this make a difference? Also there is an NSStackView inside the Clip View. Any ideas why this is not working? Thanks a lot for any help, Dave ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post

Setting the position of a NSScrollView

2015-09-09 Thread Dave
Found it! -(void) scrollToTopOfScrollView:(NSScrollView*) theScrollView { NSPoint myScrollPosition; if ([[theScrollView documentView] isFlipped] == YES) myScrollPosition = NSMakePoint(0.0,0.0); else myScrollPosition=NSMakePoint(0.0,NSMaxY([[theScrollView

Re: Auto Layout, NSScrollView and NSStackView - Adding View to StackView

2015-09-08 Thread Dave
eed to tweak things in the LTWDetailView in order to make it Stretch/Shrink in the X direction? After thinking about what I am trying to do here, I’m wondering if it’s possible using a NSScrollView/NSStackView combo - call it the “ScrollingStackView” to save my fingers. Here’s the way I way

Re: Auto Layout, NSScrollView and NSStackView - Adding View to StackView

2015-09-08 Thread Dave
I’ve put a snapshot of my Test Project in a drop box: https://dl.dropboxusercontent.com/u/207696951/LTWALTest1.zip If anyone is interested. All the Best Dave ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests

Re: Auto Layout, NSScrollView and NSStackView - Adding View to StackView

2015-09-08 Thread Dave
The Window Screen Shot is at: https://dl.dropboxusercontent.com/u/207696951/dump1.png ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at

Re: Auto Layout, NSScrollView and NSStackView - Adding View to StackView

2015-09-07 Thread Dave
Made a mistake, should be; Horizontal Space StackView.Trailing Equal FlippedClipView.Trailing-1, 1000, 1*Constant = -1 Vertical Space StackView.TopEqual FlippedClipView.top 0, 1000, 1 Horizontal Space StackView.Leading Equal

Re: Auto Layout, NSScrollView and NSStackView - Adding View to StackView

2015-09-07 Thread Ken Thomases
On Sep 7, 2015, at 3:14 PM, Dave wrote: > Thanks a lot for this. You're welcome. >> You should set leading and trailing constraints between the stack view and >> the clip view so that the stack view is as wide as the clip view. > > I’ve got the following constraints

Re: Auto Layout, NSScrollView and NSStackView - Adding View to StackView

2015-09-07 Thread Ken Thomases
views being stretched, depending. > If so, I’m assuming I need to add the constraint to myDetailView? If so which > View do I constrain it to? NSScrollView, the FlippedClipView inside > NSScrollView or the StackView or none of the above? It should not be necessary to add a constraint t

Re: Auto Layout, NSScrollView and NSStackView - Adding View to StackView

2015-09-07 Thread Dave
Hi Ken, Thanks a lot for this. > You should set leading and trailing constraints between the stack view and > the clip view so that the stack view is as wide as the clip view. I’ve got the following constraints on the StackView: Horizontal Space StackView.Trailing Equal

Auto Layout, NSScrollView and NSStackView - Adding View to StackView

2015-09-07 Thread Dave
Hi, I almost have the desired effect for the Auto Layout, NSScrollView and NSStackView combination with everything setup in a NIB. There is one thing left I need to do - please see following code: -(void) awakeFromNib { LTWDetailXView* myDetailView; NSInteger

Re: NSScrollView and NSTrackingArea woes [SOLVED]

2015-07-19 Thread João Varela
because this is a side project, and I am not working on it all the time. For those who did not follow this thread from the beginning, the problem (bug) that I was hitting is that setting up NSTrackingArea objects in the document view of an NSScrollView works as expected except when the user begins

Re: NSScrollView and NSTrackingArea woes

2015-07-16 Thread Quincey Morris
On Jul 16, 2015, at 18:19 , João Varela joaocvar...@gmail.com wrote: The options I am using are the following: NSTrackingAreaOptions options = NSTrackingMouseEnteredAndExited | NSTrackingMouseMoved| NSTrackingActiveInActiveApp; Apart from the things Ken said, I’m struck by the

Re: NSScrollView and NSTrackingArea woes

2015-07-16 Thread Ken Thomases
On Jul 16, 2015, at 8:19 PM, João Varela joaocvar...@gmail.com wrote: I’m passing [self bounds]. And no, I am not using NSTrackingInVisibleRect Why aren't you using that? That seems like the most obvious way to get correct behavior. The only reason you wouldn't use it is if you were adding

Re: NSScrollView and NSTrackingArea woes

2015-07-16 Thread João Varela
On Friday, July 17, 2015, Ken Thomases k...@codeweavers.com wrote: On Jul 16, 2015, at 8:19 PM, João Varela joaocvar...@gmail.com javascript:; wrote: I’m passing [self bounds]. And no, I am not using NSTrackingInVisibleRect Why aren't you using that? That seems like the most obvious way

Re: NSScrollView and NSTrackingArea woes

2015-07-16 Thread dangerwillrobinsondanger
Why not just observe bounds change notifications from the clipview? Then handle those with the update call. Sent from my iPhone On Jul 17, 2015, at 10:58 AM, João Varela joaocvar...@gmail.com wrote: On Friday, July 17, 2015, Ken Thomases k...@codeweavers.com wrote: On Jul 16, 2015, at

Re: NSScrollView and NSTrackingArea woes

2015-07-16 Thread João Varela
On 15 Jul 2015, at 18:28, Quincey Morris quinceymor...@rivergatesoftware.com wrote: On Jul 15, 2015, at 03:08 , João Varela joaocvar...@gmail.com mailto:joaocvar...@gmail.com wrote: However, none of this happens when the user only scrolls (up or down) a little and does not reach the

Re: NSScrollView and NSTrackingArea woes

2015-07-16 Thread João Varela
On 15 Jul 2015, at 11:44, Muthulingam Ammaiappan muthulinga...@gmail.com wrote: Hi J.Varela, i too faced the same problem... and i found that inertial scrolling has the reason for this misbehaviour. so disable the inertia scrolling will solve this problem. just add the

NSScrollView and NSTrackingArea woes

2015-07-15 Thread João Varela
Hi, I am implementing two custom classes, one of them is the document view inside an NSScrollView and the other is a subview of the document view. I need to create two NSTrackingArea’s to display the appropriate cursor when the mouse hovers over specific areas of the subviews. As instructed

Re: NSScrollView and NSTrackingArea woes

2015-07-15 Thread Quincey Morris
On Jul 15, 2015, at 03:08 , João Varela joaocvar...@gmail.com wrote: However, none of this happens when the user only scrolls (up or down) a little and does not reach the top or bottom of the document view. In this case, not only the -updateTrackingAreas method of the subview is not called,

Re: NSScrollView and NSTrackingArea woes

2015-07-15 Thread Muthulingam Ammaiappan
forKey:@AppleMomentumScrollSupported];//disable the inertia scrolling * Thanks Regards, Muthu On Wed, Jul 15, 2015 at 3:38 PM, João Varela joaocvar...@gmail.com wrote: Hi, I am implementing two custom classes, one of them is the document view inside an NSScrollView and the other

Re: Sizing NSScrollView width to exactly fit NSTableView

2015-07-08 Thread Jonathan Mitchell
addConstraints:vConstraints]; HTH Jonathan On 7 Jul 2015, at 16:07, Matthew LeRoy mle...@minitab.com wrote: Hi, I’m trying to figure out how to correctly calculate the required width of an NSScrollView such that it will exactly fit the NSTableView inside, with no horizontal scroller

Sizing NSScrollView width to exactly fit NSTableView

2015-07-07 Thread Matthew LeRoy
Hi, I’m trying to figure out how to correctly calculate the required width of an NSScrollView such that it will exactly fit the NSTableView inside, with no horizontal scroller and no “filler column” to the right of the last column in the table. The number of columns in the table changes based

Re: Help: NSScrollView is resizing its documentView down to (0, 0)

2015-05-07 Thread Jens Alfke
On May 6, 2015, at 9:10 PM, Luther Baker lutherba...@gmail.com wrote: I'm probably missing something ... but fundamentally, the whole point of constraints between the scrollview and its children is so that the scrollview knows how big to make its contentSize. It sounds like you've got

Re: Help: NSScrollView is resizing its documentView down to (0, 0)

2015-05-07 Thread Kyle Sluder
for that?' Yes, NSScrollView has supported using constraints between the document view and the clip view to specify the contentSize since 10.8. https://developer.apple.com/library/mac/releasenotes/AppKit/RN-AppKitOlderNotes/ (section Auto Layout NSSplitView Improvements) --Kyle Sluder

Re: Help: NSScrollView is resizing its documentView down to (0, 0)

2015-05-07 Thread Ken Thomases
When using auto layout with a scroll view, you would want at least constraints to fix the position of the document view within the clip view. Usually, you fix it to the top-left. If the document view should re-flow its content to fit the width of the clip view, like a text view or collection

Re: Help: NSScrollView is resizing its documentView down to (0, 0)

2015-05-06 Thread Jens Alfke
On May 6, 2015, at 8:36 AM, Uli Kusterer witness.of.teacht...@gmx.net wrote: So you're not setting a constraint on the *document* view? How do you expect it to know how to constrain that view otherwise? The size of the document view is fundamentally unrelated to the size of the clip or

Re: Help: NSScrollView is resizing its documentView down to (0, 0)

2015-05-06 Thread Luther Baker
On Wed, May 6, 2015 at 11:54 AM, Jens Alfke j...@mooseyard.com wrote: On May 6, 2015, at 8:36 AM, Uli Kusterer witness.of.teacht...@gmx.net wrote: So you're not setting a constraint on the *document* view? How do you expect it to know how to constrain that view otherwise? The size of

Re: Help: NSScrollView is resizing its documentView down to (0, 0)

2015-05-06 Thread Uli Kusterer
on the content it needs to display. So all I did was create a new window in IB, add an instance of my view, embed it in an NSScrollView, and set up default constraints for the scroll view so it'll track the window size. So you're not setting a constraint on the *document* view? How do you expect

Re: Help: NSScrollView is resizing its documentView down to (0, 0)

2015-05-06 Thread Uli Kusterer
On 06 May 2015, at 03:21, Jens Alfke j...@mooseyard.com wrote: Constrain your view to the top, right and left of the clipview but not the bottom. I have never had to do this. What are you trying to fix with this? ___ Cocoa-dev mailing list

Re: Help: NSScrollView is resizing its documentView down to (0, 0)

2015-05-06 Thread Roland King
On 6 May 2015, at 23:39, Uli Kusterer witness.of.teacht...@gmx.net wrote: On 06 May 2015, at 03:21, Jens Alfke j...@mooseyard.com mailto:j...@mooseyard.com wrote: Constrain your view to the top, right and left of the clipview but not the bottom. I have never had to do this. What are

Re: Help: NSScrollView is resizing its documentView down to (0, 0)

2015-05-06 Thread Uli Kusterer
On 06 May 2015, at 17:41, Roland King r...@rols.org wrote: On 6 May 2015, at 23:39, Uli Kusterer witness.of.teacht...@gmx.net wrote: On 06 May 2015, at 03:21, Jens Alfke j...@mooseyard.com mailto:j...@mooseyard.com wrote: Constrain your view to the top, right and left of the clipview

Re: Help: NSScrollView is resizing its documentView down to (0, 0)

2015-05-05 Thread Jens Alfke
On May 5, 2015, at 5:54 PM, Roland King r...@rols.org wrote: Constrain the scrollview to something above it if it needs it, if it’s the whole window, probably doesn’t. Constrain the clipview to all 4 sides of the scrollview. Constrain your view to the top, right and left of the clipview

Re: Help: NSScrollView is resizing its documentView down to (0, 0)

2015-05-05 Thread Jens Alfke
On May 5, 2015, at 4:26 PM, Graham Cox graham@bigpond.com wrote: I don’t know, but I also find setting up simple constraints baffling. Even the most straightforward cases seem to be really hard to get right. Glad to know I'm not the only one. It wouldn't be so bad if there were some

Re: Help: NSScrollView is resizing its documentView down to (0, 0)

2015-05-05 Thread Roland King
We did this a few months ago When you embed in a scrollview you end up with NSScrollView NSClipView Your View Constrain the scrollview to something above it if it needs it, if it’s the whole window, probably doesn’t. Constrain the clipview to all 4 sides of the scrollview

Re: Help: NSScrollView is resizing its documentView down to (0, 0)

2015-05-05 Thread Luther Baker
Not exactly the same but I found this doc helpful. https://developer.apple.com/library/ios/technotes/tn2154/_index.html Luther On May 5, 2015, at 7:58 PM, dangerwillrobinsondan...@gmail.com wrote: If you have AutoLayout on in a window it's actually on for all views. NSScrollView and its

Re: Help: NSScrollView is resizing its documentView down to (0, 0)

2015-05-05 Thread Jens Alfke
, but UIScrollView is different from NSScrollView in the details of how it works (IIRC there's no clipView) so I figured the technote would just get me more confused. —Jens ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin

Re: Help: NSScrollView is resizing its documentView down to (0, 0)

2015-05-05 Thread Graham Cox
On 6 May 2015, at 2:26 am, Jens Alfke j...@mooseyard.com wrote: (although the view is pinned to the bottom of the window instead of the top for some reason.) In the pre-autolayout days, this was always the case unless your embedded view returned YES for -isFlipped. Never made much

Re: Help: NSScrollView is resizing its documentView down to (0, 0)

2015-05-05 Thread dangerwillrobinsondanger
If you have AutoLayout on in a window it's actually on for all views. NSScrollView and its hierarchy are a bit weird though. Thing to do is create height and width constraints for the document view and outlets for them so you can configure them. If you're using 10.10+ you can make them

Re: Help: NSScrollView is resizing its documentView down to (0, 0)

2015-05-05 Thread dangerwillrobinsondanger
Sent from my iPhone On 2015/05/06, at 9:58, dangerwillrobinsondan...@gmail.com wrote: If you have AutoLayout on in a window it's actually on for all views. NSScrollView and its hierarchy are a bit weird though. Thing to do is create height and width constraints for the document view

Re: Help: NSScrollView is resizing its documentView down to (0, 0)

2015-05-05 Thread dangerwillrobinsondanger
Sent from my iPhone On 2015/05/06, at 14:14, Roland King r...@rols.org wrote: One of the things you ‘pick up’ as you learn autolayout is that when frame sizes disappear to {0,0} that often means you have an ambiguous layout and you need more constraints. More precisely it means a view

Re: Help: NSScrollView is resizing its documentView down to (0, 0)

2015-05-05 Thread Roland King
On 6 May 2015, at 09:21, Jens Alfke j...@mooseyard.com wrote: On May 5, 2015, at 5:54 PM, Roland King r...@rols.org mailto:r...@rols.org wrote: Constrain the scrollview to something above it if it needs it, if it’s the whole window, probably doesn’t. Constrain the clipview to all 4

Help: NSScrollView is resizing its documentView down to (0, 0)

2015-05-05 Thread Jens Alfke
in IB, add an instance of my view, embed it in an NSScrollView, and set up default constraints for the scroll view so it'll track the window size. It sort of works as long as the window is bigger than my custom view (although the view is pinned to the bottom of the window instead of the top

NSScrollview general question

2015-03-04 Thread Graham Cox
Just a general question I'm putting out there... Now that NSScrollView always hides its scrollbars even when -setAutohidesScrollers: is NO if you have a trackpad, how does a user grab the thumb to drag it using a mouse? You can't see the thumb unless the bar is visible, and if it's

Re: NSScrollview general question

2015-03-04 Thread Steve Mills
On Mar 4, 2015, at 20:55, Graham Cox graham@bigpond.com wrote: Just a general question I'm putting out there... Now that NSScrollView always hides its scrollbars even when -setAutohidesScrollers: is NO if you have a trackpad, how does a user grab the thumb to drag it using a mouse

Re: NSScrollview general question

2015-03-04 Thread Kyle Sluder
On Wed, Mar 4, 2015, at 08:55 PM, Graham Cox wrote: You can't see the thumb unless the bar is visible, and if it's not visible you can't click it. To make it visible you have to scroll which shows the bars, but only for a short time ( 0.5 second). This means that your only option is to use a

Re: NSScrollview general question

2015-03-04 Thread Graham Cox
On 5 Mar 2015, at 2:28 pm, Graham Cox graham@bigpond.com wrote: Certainly, setting it to always does address the issue A further thought on this - which relates to NSScrollview specifically. There should be a way to override the system preference programmatically for specific views

Re: NSScrollview general question

2015-03-04 Thread Graham Cox
On 5 Mar 2015, at 2:04 pm, Kyle Sluder k...@ksluder.com wrote: By default, if you have a mouse plugged in, the scroll bars are visible. That setting can be toggled in System Preferences General Show Scroll Bars… H... Well, I have that set to automatic. In that case, it

Re: NSScrollview general question

2015-03-04 Thread Kyle Sluder
it. Or else there should be an additional setting in NSScrollView, -setAutohidesScrollersAndThisTimeIReallyMeanIt:NO Subclass NSScroller and override +isCompatibleWithOverlayScrollers to return NO. Then assign an instance of this subclass via -setHorizontalScroller:. --Kyle Sluder

Re: NSScrollview general question

2015-03-04 Thread dangerwillrobinsondanger
graham@bigpond.com wrote: On 5 Mar 2015, at 2:28 pm, Graham Cox graham@bigpond.com wrote: Certainly, setting it to always does address the issue A further thought on this - which relates to NSScrollview specifically. There should be a way to override the system preference

Re: NSScrollview general question

2015-03-04 Thread Graham Cox
On 5 Mar 2015, at 2:59 pm, Kyle Sluder k...@ksluder.com wrote: Subclass NSScroller and override +isCompatibleWithOverlayScrollers to return NO. Then assign an instance of this subclass via -setHorizontalScroller:. OK, somewhat long-winded, but I'll give it a go. However, I can see

Re: NSScrollview general question

2015-03-04 Thread Alex Kac
I’ve personally set it to Always for now - I just got tired of having to first do a quick two finger scroll on my MBPr to get to the thumb to drag it and half the time having it fade out before I got to it. I lived with scrollers on my screen since the 1980s - I think I will live with it :)

Re: NSScrollview general question

2015-03-04 Thread Quincey Morris
On Mar 4, 2015, at 18:55 , Graham Cox graham@bigpond.com wrote: You can't see the thumb unless the bar is visible, and if it's not visible you can't click it. To make it visible you have to scroll which shows the bars, but only for a short time ( 0.5 second). This means that your only

Re: NSScrollview general question

2015-03-04 Thread dangerwillrobinsondanger
There is a WWDC video that covers it in detail. There's not a way to get nontransient overlay scrollers. The thoughtful thing is that the NSScrollView api provides methods that give you the right sizes to work with independent of what the user's preference is. The overlay rationale was one

Re: NSScrollView autolayout (10.10)

2015-01-08 Thread Roland King
an NSStackView into a window. Then, I chose Editor Embed In Scroll View. That resulted in: +- NSScrollview +- NSClipView +- NSStackView Then I selected Reset to Suggested Constraints for the whole window. That added leading, trailing, top, and bottom constraints

Re: NSScrollView autolayout (10.10)

2015-01-07 Thread Ken Thomases
On Jan 7, 2015, at 6:26 AM, Roland King r...@rols.org wrote: I want an NSStackView which can be scrolled. I dragged an NSScrollView out in IB, that gives me a scrollview, the scrollers, a clip view and a child NSView of the clip view, which IB doesn’t want you to delete. I dragged my

NSScrollView autolayout (10.10)

2015-01-07 Thread Roland King
I want an NSStackView which can be scrolled. I dragged an NSScrollView out in IB, that gives me a scrollview, the scrollers, a clip view and a child NSView of the clip view, which IB doesn’t want you to delete. I dragged my NSStackView out and made it a child of that view +- NSScrollview

NSScrollView with Custom View Not Working...

2014-08-28 Thread Peters, Brandon
Devs, I created a custom NSView that I have embedded within a NSScrollView via Interface Builder (Embed - Scroll View). Everything seems to get called that should on initialization (using NSLog’s to call out). But, nothing shows up on screen. If I put the custom view on the window without

Re: NSScrollView with Custom View Not Working...

2014-08-28 Thread Graham Cox
On 29 Aug 2014, at 11:22 am, Peters, Brandon bap...@my.fsu.edu wrote: I created a custom NSView that I have embedded within a NSScrollView via Interface Builder (Embed - Scroll View). Everything seems to get called that should on initialization (using NSLog’s to call out). But, nothing

Re: Any examples of -[NSScrollView addFloatingSubview:]? SOLVED

2014-06-19 Thread Bill Cheeseman
On Jun 14, 2014, at 3:18 PM, Bill Cheeseman wjcheese...@gmail.com wrote: The -[NSScrollView addFloatingSubview:] method was added in OS X 10.9 Mavericks. I can't find any usage examples, and the Mavericks release notes and the reference document are not helpful to me. Playing around

NSScrollView skips rendering pages

2014-06-16 Thread Sanjay Arora
Hi, My app uses NSScrollView to render a document having complex algorithms to render images. The image rendering operation is quite cpu intensive and takes time. When I scroll the document having multiple pages, using scroll pad or mouse scroll, there happens some jerks in scrolling while

Re: NSScrollView skips rendering pages

2014-06-16 Thread Uli Kusterer
On 16 Jun 2014, at 16:05, Sanjay Arora saar...@quark.com wrote: My app uses NSScrollView to render a document having complex algorithms to render images. The image rendering operation is quite cpu intensive and takes time. When I scroll the document having multiple pages, using scroll pad

Any examples of -[NSScrollView addFloatingSubview:]?

2014-06-14 Thread Bill Cheeseman
The -[NSScrollView addFloatingSubview:] method was added in OS X 10.9 Mavericks. I can't find any usage examples, and the Mavericks release notes and the reference document are not helpful to me. Playing around with it for a few minutes has gotten me nowhere. Has anybody figured out how to use

Re: Question on NSScrollView

2014-05-04 Thread Varun Chandramohan
Hi Quincey, You are right, the code is taken from the link you posted. Actually I understand that group rows were demonstrated in that code. Actually when I remove group code I get desired result. I was trying to include group rows so that in future should I need that feature, I need not revisit

Re: Question on NSScrollView

2014-05-03 Thread dangerwillrobinsondanger
On 2014/05/03, at 6:06, Lee Ann Rucker lruc...@vmware.com wrote: You might find it useful to get one of the Apple sample apps, like TableViewPlayground, and experiment with that - it's easier to figure out what's happening when you have a fully-implemented example than it is to start

Re: Question on NSScrollView

2014-05-02 Thread Varun Chandramohan
...@rivergatesoftware.com Date: Friday, 2 May 2014 3:12 pm To: Development varun.chandramo...@wontok.commailto:varun.chandramo...@wontok.com Cc: Cocoa dev Cocoa-dev@lists.apple.commailto:Cocoa-dev@lists.apple.com Subject: Re: Question on NSScrollView On May 1, 2014, at 17:25 , Varun Chandramohan varun.chandramo

Re: Question on NSScrollView

2014-05-02 Thread Quincey Morris
On May 1, 2014, at 23:03 , Varun Chandramohan varun.chandramo...@wontok.com wrote: I ran ‘tableView:viewForTableColumn and it is always tableColumn == nil as I have just 1 column. No. ‘tableColumn == nil’ means that you’re being asked for a view for a *group row*. A group row: (a) spans

Re: Question on NSScrollView

2014-05-02 Thread Lee Ann Rucker
functionality without the need to have buttons to manipulate the list. Can someone tell me if NSScrollView can be extended to work like that? Any suggestions? Regards, Varun ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do

Re: Question on NSScrollView

2014-05-02 Thread Quincey Morris
On May 2, 2014, at 14:06 , Lee Ann Rucker lruc...@vmware.com wrote: You might find it useful to get one of the Apple sample apps, like TableViewPlayground, and experiment with that - it's easier to figure out what's happening when you have a fully-implemented example than it is to start

Re: Question on NSScrollView

2014-05-01 Thread Varun Chandramohan
why this is happening and how to get rid of this? Regards, Varun On 30/04/2014 12:40 pm, Graham Cox graham@bigpond.com wrote: On 30 Apr 2014, at 12:20 pm, Varun Chandramohan varun.chandramo...@wontok.com wrote: Can someone tell me if NSScrollView can be extended to work like that? Any

  1   2   3   4   5   >