473,395 Members | 1,595 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

Help System For Python Applications

I did some searching for this topic, but couldn't find anything. A
search of this list only turned up an old post from 2002.

I'd like to add a comprehesive help system to my Python Application. By
"comprehensive" I mean regular "read-like-a-book" help and context
sensitive help that can be launched from the application.

Is there an existing system in Python that would support this, or would
I need to start from scratch?

On a related note, is there a way to fire up Adobe's Acorbat Reader or
and Web Browser from Python and have the external application open a
specified PDF or HTML file? (For example, I want to open the file
"myhelp.pdf" in reader from Python code.)

Could you give me an example of the code that would do this?

Thanks for all the help on my help. :]

Scott Huey

May 16 '06 #1
8 1680

re****************@gmail.com wrote:
On a related note, is there a way to fire up Adobe's Acorbat Reader or
and Web Browser from Python and have the external application open a
specified PDF or HTML file? (For example, I want to open the file
"myhelp.pdf" in reader from Python code.)


The webbrowser module lets you open any page. HTML will open in the
user's default web browser; PDF opens in Acrobat (at least on my
Windows machine).
import webbrowser
webbrowser.open(r"C:\\helpfile.pdf")


May 16 '06 #2
I usually go for the webbrowser package that allows me to launch the
systems webbrowser and opens my html help files. It is really simple:
import webbrowser
webbrowser.open("file:///path_to/help.html#topic")


and thats all there is to do.

- harold -

May 16 '06 #3
re****************@gmail.com wrote:
I did some searching for this topic, but couldn't find anything. A
search of this list only turned up an old post from 2002.

I'd like to add a comprehesive help system to my Python Application. By
"comprehensive" I mean regular "read-like-a-book" help and context
sensitive help that can be launched from the application.

Is there an existing system in Python that would support this, or would
I need to start from scratch?
This depends on the system and UI, so their can be no one-size-fits-all
builtin solution. Hint : look at how other programs using the same
system and UI solved the problem.
On a related note, is there a way to fire up Adobe's Acorbat Reader or
and Web Browser from Python and have the external application open a
specified PDF or HTML file? (For example, I want to open the file
"myhelp.pdf" in reader from Python code.)


os.system() may be a good start.

HTH
--
bruno desthuilliers
python -c "print '@'.join(['.'.join([w[::-1] for w in p.split('.')]) for
p in 'o****@xiludom.gro'.split('@')])"
May 16 '06 #4
Thanks for the responses. I'll check out the web browser module, and
I'll make sure that I release any work ona help system to the
community.

Scott Huey

bruno at modulix wrote:
re****************@gmail.com wrote:
I did some searching for this topic, but couldn't find anything. A
search of this list only turned up an old post from 2002.

I'd like to add a comprehesive help system to my Python Application. By
"comprehensive" I mean regular "read-like-a-book" help and context
sensitive help that can be launched from the application.

Is there an existing system in Python that would support this, or would
I need to start from scratch?


This depends on the system and UI, so their can be no one-size-fits-all
builtin solution. Hint : look at how other programs using the same
system and UI solved the problem.
On a related note, is there a way to fire up Adobe's Acorbat Reader or
and Web Browser from Python and have the external application open a
specified PDF or HTML file? (For example, I want to open the file
"myhelp.pdf" in reader from Python code.)


os.system() may be a good start.

HTH
--
bruno desthuilliers
python -c "print '@'.join(['.'.join([w[::-1] for w in p.split('.')]) for
p in 'o****@xiludom.gro'.split('@')])"


May 16 '06 #5
bruno at modulix wrote:
re****************@gmail.com wrote:
On a related note, is there a way to fire up Adobe's Acorbat Reader or
and Web Browser from Python and have the external application open a
specified PDF or HTML file? (For example, I want to open the file
"myhelp.pdf" in reader from Python code.)


os.system() may be a good start.


Take a look at the desktop module for a partial solution:

http://www.python.org/pypi/desktop

An example:

import desktop
desktop.open("itools-0.9.0.pdf")

Apparently, os.startfile will expose (or already exposes) other
parameters which may specify that the file be printed, amongst other
things. I may well add such functionality to the desktop module, since
various non-Windows systems have supported such things for a while.

Paul

May 16 '06 #6
Thanks for the link Paul. It looks like you've done some good work on
that module.

I'll check it out.

Scott

Paul Boddie wrote:
bruno at modulix wrote:
re****************@gmail.com wrote:
On a related note, is there a way to fire up Adobe's Acorbat Reader or
and Web Browser from Python and have the external application open a
specified PDF or HTML file? (For example, I want to open the file
"myhelp.pdf" in reader from Python code.)


os.system() may be a good start.


Take a look at the desktop module for a partial solution:

http://www.python.org/pypi/desktop

An example:

import desktop
desktop.open("itools-0.9.0.pdf")

Apparently, os.startfile will expose (or already exposes) other
parameters which may specify that the file be printed, amongst other
things. I may well add such functionality to the desktop module, since
various non-Windows systems have supported such things for a while.

Paul


May 16 '06 #7
At the commandline, run:

pydoc -g

In the interpreter:

help("modulename")

or help ()

for interactive.

Are you on Windows? Using ActivePython? Or the Python.org download?

rd

May 17 '06 #8
BartlebyScrivener wrote:
At the commandline, run:

pydoc -g

In the interpreter:

help("modulename")

or help ()

for interactive.


This is developper doc. I think the OP's talking about end-user doc.

--
bruno desthuilliers
python -c "print '@'.join(['.'.join([w[::-1] for w in p.split('.')]) for
p in 'o****@xiludom.gro'.split('@')])"
May 17 '06 #9

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

9
by: limor | last post by:
Hi, I am considering using Python in a new testing tool application we intend to build for out product. I must get references before starting develope in this language , since although lots of...
19
by: Lad | last post by:
I used Py2exe to compile my script( I use XP). The compiled script works OK on my XP where Python is installed. But when I install the compiled exe to another computer, os.system causes the...
3
by: Pekka Niiranen | last post by:
Hi, Probing my system from Python 2.3.4 gives >>> import locale, sys >>> locale.getdefaultlocale() ('fi_FI', 'cp1252') >>> locale.getpreferredencoding() 'cp1252' >>>...
10
by: Robert | last post by:
Where can i find a free web- based VC++ course? (also i've to dowanload it) I'm interested also in VB and C++ thanks, Robert
217
by: gyromagnetic | last post by:
The following url points to an article written by Damian Conway entitled "Ten Essential Development Practices": http://www.perl.com/pub/a/2005/07/14/bestpractices.html Althought the article has...
12
by: Ray | last post by:
Hello, I've got the chance to determine the technology to use in creating a product similar to this: http://www.atomicisland.com/ Now the thing is that I need to sell this to the guy with...
4
by: Robin Haswell | last post by:
Okay I'm getting really frustrated with Python's Unicode handling, I'm trying everything I can think of an I can't escape Unicode(En|De)codeError no matter what I try. Could someone explain to...
31
by: Mark Dufour | last post by:
Hi all, I have recently released version 0.0.20 and 0.0.21 of Shed Skin, an optimizing Python-to-C++ compiler. Shed Skin allows for translation of pure (unmodified), implicitly statically typed...
2
by: ahmadoubay_20240 | last post by:
The assignment aims at enforcing the encryption and communication techniques. It helps the student in acquiring the necessary knowledge in developing client/server application and in securing...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.