Solved Re: [wxpython-users] wx.HtmlHelpController: How to show SPECIFIC help (language independent)?
by Norbert Klamann other posts by this author
Jun 5 2009 7:56AM messages near this date
Re: [wxpython-users] wx.HtmlHelpController: How to show SPECIFIC help (language independent)?
|
[wxpython-users] Indentation in PyCrust/PyShell
Hello all,
sorry for being trigger-happy. The wxWidgets documentation led me on the
right track. It works to use the html-filename of the topic, but
*without* the path part. That is the point wehre the documentation is
misleading.
DisplayID seems not to work and this makes sense in a way. The .hpp File
which is read by the controller does not contan the numeric IDs at all.
Norbert
Norbert Klamann schrieb:
> 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
>
> _______________________________________________
> wxpython-users mailing list
> wxpython-users@[...].org
> http://lists.wxwidgets.org/mailman/listinfo/wxpython-users
Thread:
Norbert Klamann
Robin Dunn
Norbert Klamann
Robin Dunn
Norbert Klamann
|