[reportlab-users] Newbie Reportlab Tests questions

pythorlh at nycap.rr.com pythorlh at nycap.rr.com
Fri Sep 29 10:29:00 EDT 2006


From: Robin Becker <robin at reportlab.com>
> > Since other tests had not problem with the directory either way, 
> I was 
> > wondering if this is considered a bug.
> > 
> 
> Probably we should fix the runAll.py script to ensure it starts in 
> the 
> right place; so it's a bug.
> 

Cool.  Should I place a bug report?  At this point I haven't figured 
out where to do that.

> 
> > I figured out that issue, and ran it again, from the test 
> directory.  In 
> > this case, two tests failed, both having to do with pulling an 
> image off 
> > the website.  Neither of these failed the first time, so I don't 
> know 
> > why they did the second.> 
> Have you installed the reportlab C extensions? Additionally one of 
> the 
> tests is indeed trying to fetch a remote image and can fail for 
> that 
> reason alone.

I did on the first machine.  I couldn't find the files when I was on my 
second machine last night.  Incidentally, I ran the tests again today 
on my first machine, with no failures.  Probably a netork issue 
yesterday.

> > 1:   In test_charts_textlabels.pdf, the text indicates that the 
> > direction indicators(nsew) should be in their correct positions. 
> In my 
> > pdfs, they are consistently backward.  n is the bottom, s is 
> top, w is 
> > right, e is left. 
> 
> This is a relativity issue. When setting the anchor the attachment 
> is at 
> the compass point of the standardized box in a normal position ie 
> text 
> pointing upwards. The xy position specified for the BOX is fixed 
> (at the 
> cross hairs in the example). A box labelled se is attached to the 
> crosshair at its se corner so it must be above the horizontal 
> crosshair 
> and to the left of the vertical.

OK, not a bug then.  Perhaps the text in that pdf could provide a 
better explanation, like the one you give here.  

> 
> > 2:   In test_graphics_charts.pdf, several charts have issues.  
> All of 
> > the "col" charts have what looks like setup code overlaid on them.
> 
> The charts are correctly drawn although badly laid out(or designed)

Really?  This was the most 'obvious' error to me.  The first one was 
nearly unreadable to me.  Is there a source of 'correct' test pdfs that 
I can reference?  Actually, now that all the tests have passed on my 
system, I suppose I can just save those files.

> > 
> > 3:    In test_paragraps.pdf, the text "Courier 3cm" overlays 
> several 
> > lines of previous text.  Is this correct, or should it be 
> justified down 
> > into its own space?
> ......
> We don't adjust the leading according to content; that is alleged 
> to be 
> a 'bad thing'. Putting 3cm characters inside a 10pt line is 
> 'discouraged'.

Indeed.  I thought this might be the case, but it's still quite ugly.  
Something to watch for in my own use.  In that sense, I'm glad that the 
test files show it, as I probably would have assumed the opposite.

Thank you for the quick response.  I look forward to using the library.

Lee



More information about the reportlab-users mailing list