View Issue Details

IDProjectCategoryView StatusLast Update
0011286ScribusScripterpublic2016-12-08 22:04
Reportervasco Assigned Tojainbasil  
PrioritynormalSeverityfeatureReproducibilityalways
Status assignedResolutionopen 
Product Version1.4.1 
Target Version1.5.4 
Summary0011286: Allow keyword arguments in scripter
DescriptionMany scripter functions do not accept keywordt arguments. If i want to make a new document i have to type something like:

newDocument((297,210), (14.111,14.111,14.111,14.111), oPORTRAIT, 1, UNIT_MILLIMETERS, PAGE_1, 0, 1)

Code gets more readable is you can type:
newDocument(size=(297,210), margins=(14.111,14.111,14.111,14.111), orientation=PORTRAIT, firstPageNumber=1, unit=UNIT_MILLIMETERS, pagesType=PAGE_1, firstPageOrder=0, numPages=1)


Maybe a seperate python wrapper module could be generated, with something like:
import Scribus

def newDocument(size=(297,210), margins=(14.111,14.111,14.111,14.111), orientation=Scribus.PORTRAIT, firstPageNumber=1, unit=Scribus.UNIT_MILLIMETERS, pagesType=Scribus.PAGE_1, firstPageOrder=0, numPages=1):
    """ Add documentation here """
    return Scribus.newDocument(size, margins, orientation, firstPageNumber, unit, pagesType, firstPageOrder, numPages)
TagsNo tags attached.
Patch

Activities

There are no notes attached to this issue.

Issue History

Date Modified Username Field Change
2012-12-23 09:28 vasco New Issue
2012-12-24 05:46 christoph_s Assigned To => jainbasil
2012-12-24 05:46 christoph_s Status new => assigned
2012-12-24 05:46 christoph_s Target Version => 1.5.1
2016-01-23 17:17 cbradney Target Version 1.5.1 => 1.5.3
2016-12-08 22:04 Kunda Target Version 1.5.3 => 1.5.4