ASPN ActiveState Programmer Network
ActiveState
/ Home / Perl / PHP / Python / Tcl / XSLT /
/ Safari / My ASPN /
Cookbooks | Documentation | Mailing Lists | Modules | News Feeds | Products | User Groups


Recent Messages
List Archives
About the List
List Leaders
Subscription Options

View Subscriptions
Help

View by Topic
ActiveState
.NET Framework
Open Source
Perl
PHP
Python
Tcl
Web Services
XML & XSLT

View by Category
Database
General
SOAP
System Administration
Tools
User Interfaces
Web Programming
XML Programming


MyASPN >> Mail Archive >> wxpython-users
wxpython-users
[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

Privacy Policy | Email Opt-out | Feedback | Syndication
© ActiveState Software Inc. All rights reserved