[scribus] setting basepoint in script

Gregory Pittman gregp_ky at yahoo.com
Mon Jul 13 15:17:07 CEST 2009


Owen wrote:
> On Sun, 12 Jul 2009 10:39:25 -0700
> Ralph Stirling <Ralph.Stirling at wallawalla.edu> wrote:
>
>   
>> I'm trying to build a script for creating yearbooks.
>> In positioning text in captions, I would like to
>> position some text frames (ones that are right-justified
>> text) based on the upper-right corner rather than
>> the upper left.  I cannot find a way to specify the
>> basepoint in a script, nor does it seem possible to
>> fit a text frame to content so I can calculate the UR
>> corner position relative to the UL position.
>>
>> Is there a technique I'm missing, or do I need to
>> submit a feature request for a scripting improvement?
>>     
>
>
>
> Hi,
>
> I took this out of the API in Help.
>
> =======================================================
> createText(...)
> createText(x, y, width, height, ["name"]) -> string 
> Creates a new text frame on the actual page and returns its name. The
> coordinates are given in the actual measurement unit of the document
> (see UNIT constants). "name" should be a unique identifier for the
> object because you need this name for further referencing of that
> object. If "name" is not given Scribus will create one for you. 
>
> May raise NameExistsError if you explicitly pass a name that's already
> used. 
> =======================================================
>   
>>
>> Owen
>>
>> _______________________________________________
>> scribus mailing list
>> scribus at lists.scribus.net
>> http://lists.scribus.net/mailman/listinfo/scribus
>>
>>     
> Is that what you were after?
>
>   
No, this isn't the basepoint. I can't find any command for that. I think 
the ability to do this may create confusion and problems. I think it 
would be better to have all frames referenced by the upper left, then 
use the dimensions of the frame to make needed relative calculations for 
the other corners.

Greg




More information about the scribus mailing list