News:

The new Release 25.03 is out! You can download binaries for Windows and many major Linux distros here .

Main Menu

Howto: Setup Help Plugin with chm-files and $(keyword)

Started by raph, January 22, 2007, 06:53:12 PM

Previous topic - Next topic

raph

Hi guys

Being able to get help about the keyword under the cursor with just one keystroke makes developing much more easilier. Since I just found out how to do this (under WinXP) for chm-Helpfiles I decided to write this little tutorial.

Here are the steps:

1.) Get helpfile.
eg. if you are using wxWidgets, get wxWidgets-2.8.0-CHM.zip from here.

2.) Get and install keyhh.exe
KeyHH allows you to open up a chm file and jump to a topic.
Get it here (original website) or here (non installer version).

3.) Setup Codeblocks
Open up Codeblocks, choose "Settings"->"Environment"->scroll down to "Help files".
click "Add" and type in a name for the helpfile.

click "OK", answer question

with "Yes", and choose your .chm file.
Now (back to the "Environment settings" dialog), change the input field showing the path of the helpfile as following:
Quotekeyhh -#klink $(keyword) path_to_helpfile
Make sure, that "This line represents a full command to be executed" is checked and (if you want) "This is the default help file (shortcut: F1)":


Now you should be able to open up the helpfile, by rightclicking a keyword and choosing "Locate in" or (if you checked "This is the default help file (shortcut: F1)") by simply pressing F1:





Hopefully someone will find this usefull.
Happy coding

raph

jpaterso

That's awesome! I wasn't aware of that feature. Thanks!

Joseph.

David Perfors

OS: winXP
Compiler: mingw
IDE: Code::Blocks SVN WX: 2.8.4 Wish list: faster code completion, easier debugging, refactoring

raph

because there is no other way to open up a chm file and jump directly to a chapter (here $(keyword))

David Perfors

Strange, when I do the steps ypu describe (step on wxString and F1) I just get the page I want...
OS: winXP
Compiler: mingw
IDE: Code::Blocks SVN WX: 2.8.4 Wish list: faster code completion, easier debugging, refactoring

Ceniza

It should work just fine if you select a chm file. The plugin has special code for hlp and chm files under Windows.

Jan van den Borst

Is there a way to associate "Locate in..." to a key f.e. control-F1?

raph

Quote from: Ceniza on January 23, 2007, 04:10:28 AM
It should work just fine if you select a chm file. The plugin has special code for hlp and chm files under Windows.
Wow you are right, realy impressive, that would have saved me a lot of work  :lol:

Pecan

Quote from: Jan van den Borst on January 23, 2007, 09:57:54 AM
Is there a way to associate "Locate in..." to a key f.e. control-F1?

There are two ways:

1) use Keyboard Shortcuts (keybinder) to add the Ctrl-F1 key to the Help (F1) entry on the menu. Menu->Editor->Keyboard Shortcuts.

2) use the KeyMacs plugin to define a macro such as {MENU}L{ENTER} and give it a command key of Ctrl-F1.

http://wiki.codeblocks.org/index.php?title=KeyMacs_plugin