Welcome, guest | Sign In | My Account | Store | Cart

Notice! PyPM is being replaced with the ActiveState Platform, which enhances PyPM’s build and deploy capabilities. Create your free Platform account to download ActivePython or customize Python with the packages you require and get automatic updates.

Download
ActivePython
INSTALL>
pypm install sphinx-wxoptimize

How to install sphinx_wxoptimize

  1. Download and install ActivePython
  2. Open Command Prompt
  3. Type pypm install sphinx-wxoptimize
 Python 2.7Python 3.2Python 3.3
Windows (32-bit)
1.2 Available View build log
Windows (64-bit)
1.2 Available View build log
Mac OS X (10.5+)
1.2 Available View build log
Linux (32-bit)
1.2 Available View build log
Linux (64-bit)
1.2 Available View build log
 
Links
Author
License
GPL
Dependencies
Lastest release
version 1.2 on Jan 5th, 2011

The sphinx document processor generates HTML that uses more advanced syntax than the HtmlHelp browser in wxPython and wxWidgets can render. This program uses the htmlhelp files generated by sphinx as input and attempts to remove elements that confuse the wxHtmlHelp system while adding or modifying elements in an attempt to allow the wxHtmlHelp to render the HTML as closely as possible to the HTML as viewed by a modern browser.

This package provides a script sphinx-wxoptimize that is designed to be integrated into your make htmlhelp target that will automatically reprocess the sphinx-generated htmlhelp files and convert them to be better rendered in the wxPython or wxWidgets wxHtmlHelpController.

Features

Currently converts the following to be better rendered in wxHtmlHelpController:

  • fixes anchor links
  • removes extra linebreaks caused by div tags
  • adds a line break after center-aligned images
  • fixes left margin issues of mulitple paragraphs in definition lists
  • removes unnecessary CSS and JavaScript
  • removes the search link from the index page

Example

For an example of the output of sphinx-wxoptimize, visit the Peppy User Manual.

Automatic Integration with Sphinx

In your sphinx Makefile, change the htmlhelp target from:

System Message: WARNING/2 (<string>, line 39)

Literal block expected; none found.

htmlhelp: $(SPHINXBUILD) -b htmlhelp $(ALLSPHINXOPTS) $(BUILDDIR)/htmlhelp

to:

System Message: WARNING/2 (<string>, line 44)

Literal block expected; none found.

htmlhelp: $(SPHINXBUILD) -b htmlhelp $(ALLSPHINXOPTS) $(BUILDDIR)/htmlhelp sphinx-wxoptimize $(BUILDDIR)/htmlhelp

Installation

Installation is through the usual python packaging commands, either by downloading the source archive and installing manually:

System Message: WARNING/2 (<string>, line 55)

Literal block expected; none found.

python setup.py install

or using easy_install:

System Message: WARNING/2 (<string>, line 59)

Literal block expected; none found.

easy_install sphinx-wxoptimize

Using easy_install will automatically install the prerequisite BeautifulSoup library.

Development

Please use the Google Code site to report any bugs, add any feature requests, or check out the subversion source code repository.

ChangeLog

1.2
  • Fixed bug in single paragraph definition lists including inline markup

System Message: WARNING/2 (<string>, line 82)

Bullet list ends without a blank line; unexpected unindent.

(italics, bold, etc.)

1.1
  • Now removes unnecessary CSS and JavaScript files from _static directory to

System Message: WARNING/2 (<string>, line 88)

Bullet list ends without a blank line; unexpected unindent.

reduce the size of the distributed HtmlHelp. The wxHtmlHelpController can't use the CSS and JavaScript anyway, so there's no need to include it.

1.0
  • Initial release

Subscribe to package updates

Last updated Jan 5th, 2011

Download Stats

Last month:2

What does the lock icon mean?

Builds marked with a lock icon are only available via PyPM to users with a current ActivePython Business Edition subscription.

Need custom builds or support?

ActivePython Enterprise Edition guarantees priority access to technical support, indemnification, expert consulting and quality-assured language builds.

Plan on re-distributing ActivePython?

Get re-distribution rights and eliminate legal risks with ActivePython OEM Edition.