Opened 13 years ago

Closed 13 years ago

Last modified 13 years ago

#747 closed defect (fixed)

"right" directive not working when generating osgeo-live docs using sphinx

Reported by: camerons Owned by: live-demo@…
Priority: normal Milestone:
Component: OSGeoLive Keywords: 5.0
Cc:

Description

On ubuntu 11.04 (which is what osgeo-live 5.0 is based upon), the image ":align: right" directive doesn't seem to be getting recognized, as images are displayed in the center of display instead of on the right, as they should be. This text was rendered correctly for osgeo-live 4.5 on ubuntu 10.04.

An example of RST text is here:

.. image:: ../../images/screenshots/800x600/openlayers-basic.png
  :scale: 100 %
  :alt: screenshot
  :align: right

Attached to this ticket are 3 different screen shots:

  • ubuntu11.04.png: This is an example of the image being displayed in the center of the display instead of the right.
  • live.osgeo.org.png: This image is what is displayed for release 4.5, and is the way the rendering should look
  • adhoc.osgeo.org.osuosl.org.png is an image of the nightly build. This has a different problem in the relative size of images is not being respected.

Attachments (3)

ubuntu11.04.png (99.6 KB ) - added by camerons 13 years ago.
issue in ubuntu 11.04 (osgeo-live 5.0)
live.osgeo.org.png (126.3 KB ) - added by camerons 13 years ago.
previously correct rendering in osgeo4.5 and ubuntu 10.04
adhoc.osgeo.osuosl.org.png (130.1 KB ) - added by camerons 13 years ago.
view in nightly build on adhoc

Download all attachments as: .zip

Change History (11)

by camerons, 13 years ago

Attachment: ubuntu11.04.png added

issue in ubuntu 11.04 (osgeo-live 5.0)

by camerons, 13 years ago

Attachment: live.osgeo.org.png added

previously correct rendering in osgeo4.5 and ubuntu 10.04

by camerons, 13 years ago

Attachment: adhoc.osgeo.osuosl.org.png added

view in nightly build on adhoc

comment:1 by fgdrf, 13 years ago

Properly it's a version problem with python / sphinx. I guess if the easy_install is used without specify a version the latest will be installed. Question is:

  • is the Version of Python is equal, isn't it?
  • Is the Version of sphinx is equal, isn't it?

comment:2 by hamish, 13 years ago

don't use the adhoc server to compare against. it uses an unreleased custom hacked version of sphinx. concentrate on ubu 11.04 VMs and the sphinx bug trac'er ticket list.

Hamish

comment:3 by hamish, 13 years ago

oh, I should note that one of my custom hack to the adhoc version was to fix the image alignment. maybe it is the same bug? IIRC it had to do with the docbook version too.

see https://bitbucket.org/birkenfeld/sphinx/issue/557/floating-images-are-broken-with-docutils

Hamish

ps- if at all possible ALWAYS use the packaged version, not a custom installed version

comment:4 by camerons, 13 years ago

I notice that the generated HTML contains a class tag in it, which can probably be picked up by our CSS:

<img alt="project logo" class="align-right" src="../../_images/logo_52North_160.png" style="width: 200.0px; height: 68.0px;" /></a> <div class="section" id="north-sos">

I assume our CSS is one of the files in here: https://svn.osgeo.org/osgeo/livedvd/gisvm/trunk/doc/themes/howto/static

comment:5 by hamish, 13 years ago

try manually applying the patch provided in issue 557 from the sphinx bug trac'er as mentioned in comment:3:

https://bitbucket.org/birkenfeld/sphinx/changeset/ba15e411a042

from the look of your screenshot the scaling is also broken, as it is on the adhoc server, presumably for similar reasons with a similar fix.

if the patch fixes it we can apply it as part of our build process.

Hamish

comment:6 by camerons, 13 years ago

Resolution: fixed
Status: newclosed

Fixed as suggested by Hamish, by updating the doc/themes/overview/static/overview.css in revision 6817.

comment:7 by hamish, 13 years ago

does the image scaling work?

comment:8 by camerons, 13 years ago

Yes, scaling seems to be working.

Note: See TracTickets for help on using tickets.