Re: NSHelpManager

2014-04-29 Thread Jerry Krinock

On 2014 Apr 29, at 16:44, Tom Doan  wrote:

> The only problem now is that the [keyboard shortcut] command-? still goes to 
> the help search box.

First of all, understand that the search field, the first menu item under 
“Help”, gives two groups of results, “Menu Items” and “Help Topics”.  To see 
this in action, right now, in Mail.app, enter the word “Mailbox” in there.

Both groups should work normally, as your Mac users will expect.

> I don't see how to cut the stop at the search box out of the process.  

I don’t think you want to do that.  Maybe you’re thinking the the second group 
should be a “context-sensitive” search, filtering results for relevance to the 
current window, but that’s going to make very little difference in practice.  
Furthermore, users who are poking around in Help might be in the wrong window 
for what they want to do anyhow.

Unless I’m misunderstanding, you should just ship it :)



___

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-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Re: NSHelpManager

2014-04-29 Thread Tom Doan
Thanks for the tips. That *almost* works the way I want. I mapped 
the Help menu item to a doHelp sent to the (custom) application 
class rather than showHelp. The only problem now is that the 
command-? still goes to the help search box. If I then choose the 
"WinTD Help" item under the search box, it goes through my 
custom help handling and pops up the correct window. I don't see 
how to cut the stop at the search box out of the process---it doesn't 
*look* like the Help is a custom NSMenuItem, but it sure acts like 
one.

Best regards,

Tom Doan
Estima

> On 2014 Apr 25, at 10:38, Tom Doan  wrote:
> 
> > 1. NSHelpManager does not seem to have a way to open up a page based
> > upon the file name (just "anchors" and search strings), while the
> > older Apple Help did. Am I missing something there?
> 
> I don´t think so.  All my pages begin with, an  or  etc.,
> which have "id" attributes, which are good for anchors.
> 
> > user hits the help keys on a dialog ... opens up the help with the
> > specific page for that dialog
> 
> > 2. Under Windows, if you hit the F1 key, WM_HELP messages are 
> > sent up the chain, so I just have to process that at the desired
> > level. I was hoping that there would similarly be a showHelp in
> > NSResponder, but it appears that showHelp always goes straight to
> > the NSApplication. Is there any way to work get the type of behavior
> > I need?
> 
> Don´t use -[NSApplication showHelp:].  Define your own action method
> that you implement in various classes ("levels").  Then wire your
> button´s target to this method in First Responder.
> 
> By the way, although NSHelpManager is Cocoa,
> apple-help-author...@lists.apple.com is also a resource for this
> stuff.
> 
> 
> ___
> 
> 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-admins(at)lists.apple.com
> 
> Help/Unsubscribe/Update your Subscription:
> https://lists.apple.com/mailman/options/cocoa-dev/tomd%40estima.com
> 
> This email sent to t...@estima.com



___

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-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Re: NSHelpManager

2014-04-25 Thread Jerry Krinock

On 2014 Apr 25, at 10:38, Tom Doan  wrote:

> 1. NSHelpManager does not seem to have a way to open up a page 
> based upon the file name (just "anchors" and search strings), while 
> the older Apple Help did. Am I missing something there?

I don’t think so.  All my pages begin with, an  or  etc., which have 
“id” attributes, which are good for anchors.

> user hits the help keys on a dialog … opens up the help with the specific 
> page for that dialog

> 2. Under Windows, if you hit the F1 key, WM_HELP messages are 
> sent up the chain, so I just have to process that at the desired level. 
> I was hoping that there would similarly be a showHelp in 
> NSResponder, but it appears that showHelp always goes straight to 
> the NSApplication. Is there any way to work get the type of behavior 
> I need?

Don’t use -[NSApplication showHelp:].  Define your own action method that you 
implement in various classes (“levels”).  Then wire your button’s target to 
this method in First Responder.

By the way, although NSHelpManager is Cocoa, 
apple-help-author...@lists.apple.com is also a resource for this stuff.


___

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-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

NSHelpManager

2014-04-25 Thread Tom Doan
I'm trying to do something with help which I would have hoped 
would be straightforward, but it seems not be so.

I have several applications which are both Windows and Mac. I 
have a help tool (Windows based) which generates a .chm file for 
Windows and a collection of .html files for the Mac. I've been able to 
successfully compile the latter into a Help book. I'm now trying to set 
this up so that if the user hits the help keys on a dialog, it opens up 
the help with the specific page for that dialog. I have a couple of 
problems/questions with this:

1. NSHelpManager does not seem to have a way to open up a page 
based upon the file name (just "anchors" and search strings), while 
the older Apple Help did. Am I missing something there?

2. Under Windows, if you hit the F1 key, WM_HELP messages are 
sent up the chain, so I just have to process that at the desired level. 
I was hoping that there would similarly be a showHelp in 
NSResponder, but it appears that showHelp always goes straight to 
the NSApplication. Is there any way to work get the type of behavior 
I need?

Best regards,

Tom Doan
Estima

___

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-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com