Re: NSSavePanel runModal isn't working in sandbox?

2012-06-06 Thread Mike Abdullah
What entitlements do you have? On 6 Jun 2012, at 04:41, Samuel Williams wrote: > Hi, > > I'm having trouble with NSSavePanel runModal in a sandbox: > > NSSavePanel * savePanel = [NSSavePanel savePanel]; > savePanel.title = @"Document Migration"; > savePanel.directoryURL = url; > savePanel.nameF

Re: How to know if a file has been opened before?

2012-06-06 Thread Antonio Nunes
On 5 Jun 2012, at 14:45, Stephen J. Butler wrote: > On Tue, Jun 5, 2012 at 3:14 AM, Antonio Nunes > wrote: >> On 5 Jun 2012, at 00:09, Stephen J. Butler wrote: >> >>> You can use extended attributes to attach information to a file. Maybe >>> serialize your session state as a plist and use setxa

Animating subView moving from one superview to another (MacOS)

2012-06-06 Thread Motti Shneor
Hello everyone. I need to add a certain animation to our application. I have two NSSplitViews in my window, each holding several "panels" (NSView hierarchies). I need to SWAP two panels in separate splitViews with each other. e.g. Child view index:2 of FirstSplitView will move to become child-v

Fixed font width

2012-06-06 Thread Rajendran P
How do i specify fixed font width for an nsattributedstring (used to set string to nstextfield) ? Thanks in Advance   P.Rajendran or Raju   (for further details contact me )     ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com

Re: Fixed font width

2012-06-06 Thread Ken Thomases
On Jun 6, 2012, at 9:25 AM, Rajendran P wrote: > How do i specify fixed font width for an nsattributedstring (used to set > string to nstextfield) ? First, perhaps you just want to use a fixed-width font instead of setting a fixed width on a non-fixed-width font. Anyway, I think you use the fo

sending html file to safari for printing

2012-06-06 Thread Amy Gibbs
I've got an app I've written for myself, it's mac core data based. I need to be able to output a printout of some data, it would basically be a table with some images and data. I think the easiest thing to do may be to create an HTML page that can then be opened in Safari. I can manage cr

Re: can't hide scrollbar on NSTableView

2012-06-06 Thread Corbin Dunn
On Jun 5, 2012, at 4:44 PM, Koen van der Drift wrote: > > On Jun 5, 2012, at 7:16 PM, Corbin Dunn wrote: > >> >> On Jun 4, 2012, at 11:48 AM, Koen van der Drift >> wrote: >> >>> Ok, I'm stumped here. I have a few scrollable views in my window, two >>> NSTableViews, and an NSTextView. I'd

Data encryption

2012-06-06 Thread Charlie Dickman
Can someone direct me to some documentation on how to do data encryption in Cocoa/Objective C/C? Charlie Dickman 3tothe...@comcast.net ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments t

Re: can't hide scrollbar on NSTableView

2012-06-06 Thread Koen van der Drift
On Wed, Jun 6, 2012 at 12:42 PM, Corbin Dunn wrote: > It has a scroller there because it has scrollable area. Yes, but it should hide when I am not scrolling (as was the case when taking the screenshot). > All I can guess is that something has some scrollable area or the property is > reset so

Re: Fixed font width

2012-06-06 Thread Jens Alfke
On Jun 6, 2012, at 7:46 AM, Ken Thomases wrote: > First, perhaps you just want to use a fixed-width font instead of setting a > fixed width on a non-fixed-width font. That's almost always the best way to go. Forcing a proportional font to use fixed character widths generally looks really ugly.

Re: sending html file to safari for printing

2012-06-06 Thread Jens Alfke
On Jun 6, 2012, at 9:08 AM, Amy Gibbs wrote: > I can manage creating and saving the HTML file, how do I automatically open > it up in Safari (or the default browser it doesn't matter) so I can print it > out? Tell NSWorkspace to open the file. —Jens ___

Re: Data encryption

2012-06-06 Thread Mikkel Islay
Charles, Cryptographic services is a good place to start: https://developer.apple.com/library/mac/#documentation/Security/Conceptual/Security_Overview/CryptographicServices/CryptographicServices.html#//apple_ref/doc/uid/TP3976-CH3-SW1 Mikkel On 6 Jun 2012, at 18:51, Charlie Dickman wrote: >

Preventing NSSavePanel from alerting file overwrite

2012-06-06 Thread Gordon Apple
Is there a way to block NSSavePanel from alerting a file overwrite? I¹m using it simply to establish a URL and later alert about overwrite when a record command is issued. I would prefer to not have the user see this twice. ___ Cocoa-dev mailing list

Re: Data encryption

2012-06-06 Thread Charlie Dickman
Thanks Mike. I need to be able to use commoncrypto to do what I need to do. Is there a single source with reliable sample code? On Jun 6, 2012, at 1:02 PM, Mikkel Islay wrote: > Charles, > > Cryptographic services is a good place to start: > https://developer.apple.com/library/mac/#documentatio

Re: Data encryption

2012-06-06 Thread Jens Alfke
On Jun 6, 2012, at 9:51 AM, Charlie Dickman wrote: > Can someone direct me to some documentation on how to do data encryption in > Cocoa/Objective C/C? That's a pretty broad question! What type of encryption — symmetric or asymmetric (aka public key)? Any particular algorithm? Are you implemen

Re: NSSavePanel runModal isn't working in sandbox?

2012-06-06 Thread Rainer Brockerhoff
On Jun 6, 2012, at 13:08 , cocoa-dev-requ...@lists.apple.com wrote: > Date: Wed, 06 Jun 2012 14:50:17 +1000 > From: Graham Cox > To: Samuel Williams > Message-ID: > > Are you aware that this class is riddled with severe bugs under the current > sandbox implementation? > > The dev forums will

Re: Data encryption

2012-06-06 Thread Conrad Shultz
This is a very broad question and the actual approach to be taken will vary with the details of what you intend to do (e.g. real-time or not? Files or just individual data? For local consumption or for sharing?) To get started, take a look at the Cryptographic Services Guide: https://developer.

Re: Data encryption

2012-06-06 Thread Charlie Dickman
Jens, Thanks for your reply. I have an application on OS X, not IOS, that contains some sensitive data that I want to withhold from those not licensed to use it. I wish to use RSA encryption/decryption in block mode (I think). I want to encrypt both the public and the private key and I think I

Re: Data encryption

2012-06-06 Thread Jens Alfke
On Jun 6, 2012, at 10:24 AM, Charlie Dickman wrote: > I have an application on OS X, not IOS, that contains some sensitive data > that I want to withhold from those not licensed to use it. I wish to use RSA > encryption/decryption in block mode (I think). It sounds like the data is hardcoded i

Re: Preventing NSSavePanel from alerting file overwrite

2012-06-06 Thread Lee Ann Rucker
On Jun 6, 2012, at 10:04 AM, Gordon Apple wrote: > Is there a way to block NSSavePanel from alerting a file overwrite? I¹m > using it simply to establish a URL and later alert about overwrite when a > record command is issued. I would prefer to not have the user see this > twice. Implement "pa

Re: Preventing NSSavePanel from alerting file overwrite

2012-06-06 Thread Mike Abdullah
Use an NSOpenPanel instead? On 6 Jun 2012, at 18:04, Gordon Apple wrote: > Is there a way to block NSSavePanel from alerting a file overwrite? I¹m > using it simply to establish a URL and later alert about overwrite when a > record command is issued. I would prefer to not have the user see this

Re: sending html file to safari for printing

2012-06-06 Thread Frédéric Testuz
Le 6 juin 2012 à 18:08, Amy Gibbs a écrit : > I've got an app I've written for myself, it's mac core data based. > > I need to be able to output a printout of some data, it would basically be a > table with some images and data. I think the easiest thing to do may be to > create an HTML page th

Re: Preventing NSSavePanel from alerting file overwrite

2012-06-06 Thread Fritz Anderson
On 6 Jun 2012, at 1:03 PM, Lee Ann Rucker wrote: > Implement "panel:userEnteredFilename:confirmed:". Mine returns "nil" because > I put up my own dialog, but that also causes the panel to stay up so the user > has to enter something else. > > I haven't tried but I'd guess returning a placeholde

Re: can't hide scrollbar on NSTableView

2012-06-06 Thread Corbin Dunn
On Jun 6, 2012, at 9:54 AM, Koen van der Drift wrote: > On Wed, Jun 6, 2012 at 12:42 PM, Corbin Dunn wrote: > >> It has a scroller there because it has scrollable area. > > Yes, but it should hide when I am not scrolling (as was the case when > taking the screenshot). Okay; we are talking a

Re: Preventing NSSavePanel from alerting file overwrite

2012-06-06 Thread Corbin Dunn
On Jun 6, 2012, at 10:04 AM, Gordon Apple wrote: > Is there a way to block NSSavePanel from alerting a file overwrite? I¹m > using it simply to establish a URL and later alert about overwrite when a > record command is issued. I would prefer to not have the user see this > twice. No, you can'

Method Call

2012-06-06 Thread koko
Is it possible to call a method in an app that is not running causing it to load? -koko ___ 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 cocoa-dev-ad

Re: Method Call

2012-06-06 Thread Erik Stainsby
I think the approach you would use is to employ -[NSWorkspace] to launch the other app on your behalf. Sent from my iPad On 2012-06-06, at 1:58 PM, koko wrote: > Is it possible to call a method in an app that is not running causing it to > load? > > -koko > > _

Re: Method Call

2012-06-06 Thread koko
On Jun 6, 2012, at 3:25 PM, Erik Stainsby wrote: > I think the approach you would use is to employ -[NSWorkspace] to launch the > other app on your behalf. I was looking at that. Not sure how to determine if the app was launched that way and not by a user. Any suggestions? -koko

Re: Method Call

2012-06-06 Thread Conrad Shultz
On 6/6/12 2:34 PM, koko wrote: > On Jun 6, 2012, at 3:25 PM, Erik Stainsby wrote: > >> I think the approach you would use is to employ -[NSWorkspace] to launch the >> other app on your behalf. > > I was looking at that. Not sure how to determine if the app was launched that > way and not by a u

Re: can't hide scrollbar on NSTableView

2012-06-06 Thread Koen van der Drift
On Jun 6, 2012, at 4:51 PM, Corbin Dunn wrote: > Just call setScrollerStyle to NSScrollerStyleOverlay to force it on. > NSScrollView decides if it can be on or off by default using a special > algorithm; you might be tripping it up by having a view that intersects with > the scroll area, so yo

Re: can't hide scrollbar on NSTableView

2012-06-06 Thread Koen van der Drift
On Jun 6, 2012, at 4:51 PM, Corbin Dunn wrote: > you might be tripping it up by having a view that intersects with the scroll > area This turned out to be a good suggestion; I made the scrollview a few pixels less wide, and I now get the expected scroll bar behavior, even without calling setS

Re: Preventing NSSavePanel from alerting file overwrite

2012-06-06 Thread Gordon Apple
So far, I haven¹t been able to get what I want with NSOpenPane. I will file an enhancement request. I want the user to specify the record file URL, either new or select one existing. Later, if he decides to actually record, it will simply start recording if the file does not already exist. Othe

NSTextView

2012-06-06 Thread koko
On an NSTextView I call -selectAll: and then -insertText: This scrolls the view to the end of the text. How would I scroll the view to the top of the text? -koko ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests

Re: NSTextView

2012-06-06 Thread Graham Cox
On 07/06/2012, at 1:47 PM, koko wrote: > How would I scroll the view to the top of the text? [NSView scrollToPoint:]; --Graham ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the

Re: NSTextView

2012-06-06 Thread koko
Got it … [m_clipView scrollToPoint:m_origin]; [m_scrollView reflectScrolledClipView:m_clipView]; -koko On Jun 6, 2012, at 9:47 PM, koko wrote: > On an NSTextView I call -selectAll: and then -insertText: > > This scrolls the view to the end of the text. > > How would I scroll the view

Re: NSTextView

2012-06-06 Thread Graham Cox
On 07/06/2012, at 2:00 PM, koko wrote: > Got it … > >[m_clipView scrollToPoint:m_origin]; >[m_scrollView reflectScrolledClipView:m_clipView]; No you haven't. Look at what NSTextView inherits. Actually, there is a method in NSText which is more direct - [NSText scrollRangeToVisib