[wxpython-users] wx.HtmlHelpController: How to show SPECIFIC help (language independent)?
by Norbert Klamann other posts by this author
Jun 5 2009 7:19AM messages near this date
|
Re: [wxpython-users] wx.HtmlHelpController: How to show SPECIFIC help (language independent)?
Hello all,
I want to give context-dependant help but I want to do it in a
language-independent an clean way.
The wx.html.HtmlHelpController.Display() function seems to work only
with the verbatim title of a help topic .
wx.html.HtmlHelpController.DisplayID() shows just the content.
Look at the followiing example
I create an HtmlhelpController and open some books :
in __init__ of the frame
self.Help = wx.html.HtmlHelpController()
_addBook("helpfiles/incredix_essential.hhp")
I have an event handler who gets a context and shall translate it into
something the the Helpcontroller understands. It look like so:
def PsOnHelp(self,topic, sequence, context, value=None):
print context
if context == 'CustomerForm':
#self.Help.DisplayID(1004)
#self.Help.Display('helpfiles/LP_implementation.htm')
self.Help.Display('Zweck') # this works
else:
self.Help.DisplayContents()
As you can see I tried the numeric Ids, the file names and what not. The
only thing that works is the text itself. There are a bunch of problems
with this:
* Every redactional change in the help text would break this.
* It is language dependant
* The headlines must be unique over all help books.
There must be a better way
--
Viele Gr��e / All the best
Norbert
Thread:
Norbert Klamann
Robin Dunn
Norbert Klamann
Robin Dunn
Norbert Klamann
|