Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Platform - User Assistance (UA) » Is there a more correct command to use for menu Help/Welcome
Is there a more correct command to use for menu Help/Welcome [message #474244] Sat, 23 August 2008 18:56 Go to next message
Eclipse UserFriend
Originally posted by: nospam_kowalskilee.gmail.com

Hi,

I'm adding newsgroup eclipse.platform.ua to this, as that newsgroup
deals with questions about Welcome/Intro and the help system also.

Trevor asks if there is a more correct command to use, other than the
deprecated one he mentions below.

Original question:
What I wish to do is add Help/Welcome menu option like the IDE so user
can reshow the Welcome if they wish, but cannot find commandId / Action
combination to enable this when using the CustomizableIntoPart and
declaritive menus.

I have an Intro displaying on application startup using
CustomizableIntoPart using org.eclipse.ui.intro and
org.eclipse.ui.intro.config extension points in plugin.xml.

I am also using declaritive menus in the plugin.xml as per
http://wiki.eclipse.org/index.php/Menu_Contributions. So to show
Help/Contents, for example I am using
<menu
id="help"
label="Help"
mnemonic="H">
<command
commandId="org.eclipse.ui.help.helpContents"
label="Help Contents"
mnemonic="H">
</command>
.......
</menu>
and registering the action in my ApplicationActionBarrAdvisor as
IWorkbenchAction helpContents = ActionFactory.HELP_CONTENTS.create(window);
register(helpContents);



Trevor Campbell wrote:
> Trevor Campbell wrote:
>
> Using a combination of
> <command
> commandId="org.eclipse.ui.help.quickStartAction"
> label="Welcome"
> mnemonic="W">
> </command>
> in plugin.xml and
> IWorkbenchAction helpIntro = ActionFactory.INTRO.create(window);
> register(helpIntro);
> in the my ApplicationActionBarAdvisor seems to work even if marked as
> deprecated.
>
> Is there a more correct way?
>

Thanks!
Lee Anne
Re: Is there a more correct command to use for menu Help/Welcome [message #474250 is a reply to message #474244] Tue, 26 August 2008 17:14 Go to previous message
Chris Goldthorpe is currently offline Chris GoldthorpeFriend
Messages: 815
Registered: July 2009
Senior Member
It looks as though org.eclipse.ui.actions.ActionFactory.INTRO is the way
to create an action using public API. I don't think it's necessary to
use any deprecated API when using this to get the action to show up in
your application.

Lee Anne wrote:
> Hi,
>
> I'm adding newsgroup eclipse.platform.ua to this, as that newsgroup
> deals with questions about Welcome/Intro and the help system also.
>
> Trevor asks if there is a more correct command to use, other than the
> deprecated one he mentions below.
>
> Original question:
> What I wish to do is add Help/Welcome menu option like the IDE so user
> can reshow the Welcome if they wish, but cannot find commandId / Action
> combination to enable this when using the CustomizableIntoPart and
> declaritive menus.
>
> I have an Intro displaying on application startup using
> CustomizableIntoPart using org.eclipse.ui.intro and
> org.eclipse.ui.intro.config extension points in plugin.xml.
>
> I am also using declaritive menus in the plugin.xml as per
> http://wiki.eclipse.org/index.php/Menu_Contributions. So to show
> Help/Contents, for example I am using
> <menu
> id="help"
> label="Help"
> mnemonic="H">
> <command
> commandId="org.eclipse.ui.help.helpContents"
> label="Help Contents"
> mnemonic="H">
> </command>
> .......
> </menu>
> and registering the action in my ApplicationActionBarrAdvisor as
> IWorkbenchAction helpContents = ActionFactory.HELP_CONTENTS.create(window);
> register(helpContents);
>
>
>
> Trevor Campbell wrote:
>> Trevor Campbell wrote:
>>
>> Using a combination of
>> <command
>> commandId="org.eclipse.ui.help.quickStartAction"
>> label="Welcome"
>> mnemonic="W">
>> </command>
>> in plugin.xml and
>> IWorkbenchAction helpIntro = ActionFactory.INTRO.create(window);
>> register(helpIntro);
>> in the my ApplicationActionBarAdvisor seems to work even if marked as
>> deprecated.
>>
>> Is there a more correct way?
>>
>
> Thanks!
> Lee Anne
Re: Is there a more correct command to use for menu Help/Welcome [message #619399 is a reply to message #474244] Tue, 26 August 2008 17:14 Go to previous message
Chris Goldthorpe is currently offline Chris GoldthorpeFriend
Messages: 815
Registered: July 2009
Senior Member
It looks as though org.eclipse.ui.actions.ActionFactory.INTRO is the way
to create an action using public API. I don't think it's necessary to
use any deprecated API when using this to get the action to show up in
your application.

Lee Anne wrote:
> Hi,
>
> I'm adding newsgroup eclipse.platform.ua to this, as that newsgroup
> deals with questions about Welcome/Intro and the help system also.
>
> Trevor asks if there is a more correct command to use, other than the
> deprecated one he mentions below.
>
> Original question:
> What I wish to do is add Help/Welcome menu option like the IDE so user
> can reshow the Welcome if they wish, but cannot find commandId / Action
> combination to enable this when using the CustomizableIntoPart and
> declaritive menus.
>
> I have an Intro displaying on application startup using
> CustomizableIntoPart using org.eclipse.ui.intro and
> org.eclipse.ui.intro.config extension points in plugin.xml.
>
> I am also using declaritive menus in the plugin.xml as per
> http://wiki.eclipse.org/index.php/Menu_Contributions So to show
> Help/Contents, for example I am using
> <menu
> id="help"
> label="Help"
> mnemonic="H">
> <command
> commandId="org.eclipse.ui.help.helpContents"
> label="Help Contents"
> mnemonic="H">
> </command>
> .......
> </menu>
> and registering the action in my ApplicationActionBarrAdvisor as
> IWorkbenchAction helpContents = ActionFactory.HELP_CONTENTS.create(window);
> register(helpContents);
>
>
>
> Trevor Campbell wrote:
>> Trevor Campbell wrote:
>>
>> Using a combination of
>> <command
>> commandId="org.eclipse.ui.help.quickStartAction"
>> label="Welcome"
>> mnemonic="W">
>> </command>
>> in plugin.xml and
>> IWorkbenchAction helpIntro = ActionFactory.INTRO.create(window);
>> register(helpIntro);
>> in the my ApplicationActionBarAdvisor seems to work even if marked as
>> deprecated.
>>
>> Is there a more correct way?
>>
>
> Thanks!
> Lee Anne
Previous Topic:What could limiting help search.
Next Topic:Help contents error
Goto Forum:
  


Current Time: Thu Nov 14 16:50:01 GMT 2024

Powered by FUDForum. Page generated in 0.02694 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top