[Scribus] Adjust script (trait_de_coupe.py)

myyers latelate
Wed Oct 3 15:29:02 CEST 2007


as recommended in this mailing list I use the script trait_de_coupe.py 
to insert crop marks into a pdf. That's fine but I have to adjust the
position of the marks (which is no problem). I would like to change the
length of the crop marks either which is a problem.
The script looks like this:

--8<---------------cut here---------------start------------->8---
def main():
    userUnit = getUnit()
    x,y = getPosition()
    l,h = getSize()
    t1 = createLine(x, y-4, x, y-9)
    setLineWidth(0.6, t1)
    t2 = createLine(x+l, y-4, x+l, y-9)
    setLineWidth(0.6, t2)
    t3 = createLine(x, y+9+h, x, y+4+h)
    setLineWidth(0.6, t3)
    t4 = createLine(x+l, y+9+h, x+l, y+4+h)
    setLineWidth(0.6, t4)
    t5 = createLine(x-4, y, x-9, y)
    setLineWidth(0.6, t5)
    t6 = createLine(x-4, y+h, x-9, y+h)
    setLineWidth(0.6, t6)
    t7 = createLine(x+l+4, y+h, x+l+9, y+h)
    setLineWidth(0.6, t7)
    t7 = createLine(x+l+4, y, x+l+9, y)
    setLineWidth(0.6, t7)
--8<---------------cut here---------------end--------------->8---

Changing the value of the x,y coordinates changes the position of 
the marks, okay. I assumed inserting a new value for 'setLineWidth'
would define a new length for the marks but it changes nothing. 

Any hints?


More information about the scribus mailing list