[reportlab-users] PythonPoint bullet fix

Tim Roberts reportlab-users@reportlab.com
Fri, 08 Nov 2002 17:00:01 -0800

Earlier in the week, I mentioned that all paragraphs in a Pythonpoint were 
being indented by one space.  The fix that was inserted in 1.16 does solve that 
problem, but as a side effect, it happens to eliminate ALL bullets.  I suspect 
that was unintentional.  Here's the new code, in start_para in stdparser.py:

        if bt == '':
            bt = None
        if self._curPara.style == 'Bullet' and bt == '':
            bt = '\267'  # Symbol Font bullet character, reasonable default

Note that the first two lines insure that the third line will NEVER match; bt 
will never be a null string.  I suggest replacing that snippet with this, which 
seems to solve BOTH issues:

        if bt == '':
            if self._curPara.style == 'Bullet':
                bt = '\267'  # Symbol Font bullet character, reasonable default
                bt = None

I'm adding code now to handle multiple page sizes; if the code allowed us to 
use negative numbers for coordinates, meaning "offset from right/top" instead 
of "offset from left/bottom", it would make things much more page size-

- Tim Roberts, timr@probo.com
  Providenza & Boekelheide, Inc.