Exemplo n.º 1
0
class OleObject(Serialisable):

    tagname = "oleObject"

    objectPr = Typed(expected_type=ObjectPr, allow_none=True)
    progId = String(allow_none=True)
    dvAspect = Set(values=(['DVASPECT_CONTENT', 'DVASPECT_ICON']))
    link = String(allow_none=True)
    oleUpdate = Set(values=(['OLEUPDATE_ALWAYS', 'OLEUPDATE_ONCALL']))
    autoLoad = Bool(allow_none=True)
    shapeId = Integer()

    __elements__ = ('objectPr', )

    def __init__(
        self,
        objectPr=None,
        progId=None,
        dvAspect='DVASPECT_CONTENT',
        link=None,
        oleUpdate=None,
        autoLoad=False,
        shapeId=None,
    ):
        self.objectPr = objectPr
        self.progId = progId
        self.dvAspect = dvAspect
        self.link = link
        self.oleUpdate = oleUpdate
        self.autoLoad = autoLoad
        self.shapeId = shapeId
class Properties(Serialisable):

    locked = Bool(allow_none=True)
    defaultSize = Bool(allow_none=True)
    _print = Bool(allow_none=True)
    disabled = Bool(allow_none=True)
    uiObject = Bool(allow_none=True)
    autoFill = Bool(allow_none=True)
    autoLine = Bool(allow_none=True)
    altText = String(allow_none=True)
    textHAlign = Set(values=(['left', 'center', 'right', 'justify', 'distributed']))
    textVAlign = Set(values=(['top', 'center', 'bottom', 'justify', 'distributed']))
    lockText = Bool(allow_none=True)
    justLastX = Bool(allow_none=True)
    autoScale = Bool(allow_none=True)
    rowHidden = Bool(allow_none=True)
    colHidden = Bool(allow_none=True)
    #anchor = Typed(expected_type=ObjectAnchor, )

    __elements__ = ('anchor',)

    def __init__(self,
                 locked=None,
                 defaultSize=None,
                 _print=None,
                 disabled=None,
                 uiObject=None,
                 autoFill=None,
                 autoLine=None,
                 altText=None,
                 textHAlign=None,
                 textVAlign=None,
                 lockText=None,
                 justLastX=None,
                 autoScale=None,
                 rowHidden=None,
                 colHidden=None,
                 anchor=None,
                ):
        self.locked = locked
        self.defaultSize = defaultSize
        self._print = _print
        self.disabled = disabled
        self.uiObject = uiObject
        self.autoFill = autoFill
        self.autoLine = autoLine
        self.altText = altText
        self.textHAlign = textHAlign
        self.textVAlign = textVAlign
        self.lockText = lockText
        self.justLastX = justLastX
        self.autoScale = autoScale
        self.rowHidden = rowHidden
        self.colHidden = colHidden
        self.anchor = anchor
Exemplo n.º 3
0
class CustomChartsheetView(Serialisable):
    tagname = "customSheetView"

    guid = Guid()
    scale = Integer()
    state = Set(values=(['visible', 'hidden', 'veryHidden']))
    zoomToFit = Bool(allow_none=True)
    pageMargins = Typed(expected_type=PageMargins, allow_none=True)
    pageSetup = Typed(expected_type=PrintPageSetup, allow_none=True)
    headerFooter = Typed(expected_type=HeaderFooter, allow_none=True)

    __elements__ = ('pageMargins', 'pageSetup', 'headerFooter')

    def __init__(
        self,
        guid=None,
        scale=None,
        state='visible',
        zoomToFit=None,
        pageMargins=None,
        pageSetup=None,
        headerFooter=None,
    ):
        self.guid = guid
        self.scale = scale
        self.state = state
        self.zoomToFit = zoomToFit
        self.pageMargins = pageMargins
        self.pageSetup = pageSetup
        self.headerFooter = headerFooter
Exemplo n.º 4
0
class PresetShadowEffect(ColorChoice):

    prst = Set(values=(['shdw1', 'shdw2', 'shdw3', 'shdw4', 'shdw5', 'shdw6',
                        'shdw7', 'shdw8', 'shdw9', 'shdw10', 'shdw11', 'shdw12', 'shdw13',
                        'shdw14', 'shdw15', 'shdw16', 'shdw17', 'shdw18', 'shdw19', 'shdw20']))
    dist = Float()
    dir = Integer()
    # uses element group EG_ColorChoice
    scrgbClr = ColorChoice.scrgbClr
    srgbClr = ColorChoice.srgbClr
    hslClr = ColorChoice.hslClr
    sysClr = ColorChoice.sysClr
    schemeClr = ColorChoice.schemeClr
    prstClr = ColorChoice.prstClr

    __elements__ = ('scrgbClr', 'srgbClr', 'hslClr', 'sysClr', 'schemeClr', 'prstClr')

    def __init__(self,
                 prst=None,
                 dist=None,
                 dir=None,
                 **kw
                ):
        self.prst = prst
        self.dist = dist
        self.dir = dir
        super(PresetShadowEffect, self).__init__(**kw)
Exemplo n.º 5
0
class DynamicFilter(Serialisable):

    tagname = "dynamicFilter"

    type = Set(values=([
        'null', 'aboveAverage', 'belowAverage', 'tomorrow', 'today',
        'yesterday', 'nextWeek', 'thisWeek', 'lastWeek', 'nextMonth',
        'thisMonth', 'lastMonth', 'nextQuarter', 'thisQuarter', 'lastQuarter',
        'nextYear', 'thisYear', 'lastYear', 'yearToDate', 'Q1', 'Q2', 'Q3',
        'Q4', 'M1', 'M2', 'M3', 'M4', 'M5', 'M6', 'M7', 'M8', 'M9', 'M10',
        'M11', 'M12'
    ]))
    val = Float(allow_none=True)
    valIso = DateTime(allow_none=True)
    maxVal = Float(allow_none=True)
    maxValIso = DateTime(allow_none=True)

    def __init__(
        self,
        type=None,
        val=None,
        valIso=None,
        maxVal=None,
        maxValIso=None,
    ):
        self.type = type
        self.val = val
        self.valIso = valIso
        self.maxVal = maxVal
        self.maxValIso = maxValIso
Exemplo n.º 6
0
class TableStyleElement(Serialisable):

    tagname = "tableStyleElement"

    type = Set(values=([
        'wholeTable', 'headerRow', 'totalRow', 'firstColumn', 'lastColumn',
        'firstRowStripe', 'secondRowStripe', 'firstColumnStripe',
        'secondColumnStripe', 'firstHeaderCell', 'lastHeaderCell',
        'firstTotalCell', 'lastTotalCell', 'firstSubtotalColumn',
        'secondSubtotalColumn', 'thirdSubtotalColumn', 'firstSubtotalRow',
        'secondSubtotalRow', 'thirdSubtotalRow', 'blankRow',
        'firstColumnSubheading', 'secondColumnSubheading',
        'thirdColumnSubheading', 'firstRowSubheading', 'secondRowSubheading',
        'thirdRowSubheading', 'pageFieldLabels', 'pageFieldValues'
    ]))
    size = Integer(allow_none=True)
    dxfId = Integer(allow_none=True)

    def __init__(
        self,
        type=None,
        size=None,
        dxfId=None,
    ):
        self.type = type
        self.size = size
        self.dxfId = dxfId
Exemplo n.º 7
0
class DateGroupItem(Serialisable):

    tagname = "dateGroupItem"

    year = Integer()
    month = MinMax(min=1, max=12, allow_none=True)
    day = MinMax(min=1, max=31, allow_none=True)
    hour = MinMax(min=0, max=23, allow_none=True)
    minute = MinMax(min=0, max=59, allow_none=True)
    second = Integer(min=0, max=59, allow_none=True)
    dateTimeGrouping = Set(
        values=(['year', 'month', 'day', 'hour', 'minute', 'second']))

    def __init__(
        self,
        year=None,
        month=None,
        day=None,
        hour=None,
        minute=None,
        second=None,
        dateTimeGrouping=None,
    ):
        self.year = year
        self.month = month
        self.day = day
        self.hour = hour
        self.minute = minute
        self.second = second
        self.dateTimeGrouping = dateTimeGrouping
Exemplo n.º 8
0
class WebPublishItem(Serialisable):
    tagname = "webPublishItem"

    id = Integer()
    divId = String()
    sourceType = Set(values=([
        'sheet', 'printArea', 'autoFilter', 'range', 'chart', 'pivotTable',
        'query', 'label'
    ]))
    sourceRef = String()
    sourceObject = String(allow_none=True)
    destinationFile = String()
    title = String(allow_none=True)
    autoRepublish = Bool(allow_none=True)

    def __init__(
        self,
        id=None,
        divId=None,
        sourceType=None,
        sourceRef=None,
        sourceObject=None,
        destinationFile=None,
        title=None,
        autoRepublish=None,
    ):
        self.id = id
        self.divId = divId
        self.sourceType = sourceType
        self.sourceRef = sourceRef
        self.sourceObject = sourceObject
        self.destinationFile = destinationFile
        self.title = title
        self.autoRepublish = autoRepublish
Exemplo n.º 9
0
class RowColItem(Serialisable):

    tagname = "i"

    t = Set(values=([
        'data', 'default', 'sum', 'countA', 'avg', 'max', 'min', 'product',
        'count', 'stdDev', 'stdDevP', 'var', 'varP', 'grand', 'blank'
    ]))
    r = Integer()
    i = Integer()
    x = NestedInteger(allow_none=True, attribute="v")

    __elements__ = ('x', )

    def __init__(
        self,
        t="data",
        r=0,
        i=0,
        x=None,
    ):
        self.t = t
        self.r = r
        self.i = i
        self.x = x
Exemplo n.º 10
0
class RangePr(Serialisable):

    tagname = "rangePr"

    autoStart = Bool(allow_none=True)
    autoEnd = Bool(allow_none=True)
    groupBy = Set(values=([
        'range', 'seconds', 'minutes', 'hours', 'days', 'months', 'quarters',
        'years'
    ]))
    startNum = Float(allow_none=True)
    endNum = Float(allow_none=True)
    startDate = DateTime(allow_none=True)
    endDate = DateTime(allow_none=True)
    groupInterval = Float(allow_none=True)

    def __init__(
        self,
        autoStart=True,
        autoEnd=True,
        groupBy=range,
        startNum=None,
        endNum=None,
        startDate=None,
        endDate=None,
        groupInterval=1,
    ):
        self.autoStart = autoStart
        self.autoEnd = autoEnd
        self.groupBy = groupBy
        self.startNum = startNum
        self.endNum = endNum
        self.startDate = startDate
        self.endDate = endDate
        self.groupInterval = groupInterval
Exemplo n.º 11
0
class CacheSource(Serialisable):

    tagname = "cacheSource"

    type = Set(values=(['worksheet', 'external', 'consolidation', 'scenario']))
    connectionId = Integer(allow_none=True)
    # some elements are choice
    worksheetSource = Typed(expected_type=WorksheetSource, allow_none=True)
    consolidation = Typed(expected_type=Consolidation, allow_none=True)
    extLst = Typed(expected_type=ExtensionList, allow_none=True)

    __elements__ = (
        'worksheetSource',
        'consolidation',
    )

    def __init__(
        self,
        type=None,
        connectionId=None,
        worksheetSource=None,
        consolidation=None,
        extLst=None,
    ):
        self.type = type
        self.connectionId = connectionId
        self.worksheetSource = worksheetSource
        self.consolidation = consolidation
Exemplo n.º 12
0
class ConditionalFormat(Serialisable):

    tagname = "conditionalFormat"

    scope = Set(values=(['selection', 'data', 'field']))
    type = NoneSet(values=(['all', 'row', 'column']))
    priority = Integer()
    pivotAreas = NestedSequence(expected_type=PivotArea)
    extLst = Typed(expected_type=ExtensionList, allow_none=True)

    __elements__ = ('pivotAreas', )

    def __init__(
            self,
            scope=None,
            type=None,
            priority=None,
            pivotAreas=(),
            extLst=None,
    ):
        self.scope = scope
        self.type = type
        self.priority = priority
        self.pivotAreas = pivotAreas
        self.extLst = extLst
Exemplo n.º 13
0
class AutonumberBullet(Serialisable):

    type = Set(values=([
        'alphaLcParenBoth', 'alphaUcParenBoth', 'alphaLcParenR',
        'alphaUcParenR', 'alphaLcPeriod', 'alphaUcPeriod', 'arabicParenBoth',
        'arabicParenR', 'arabicPeriod', 'arabicPlain', 'romanLcParenBoth',
        'romanUcParenBoth', 'romanLcParenR', 'romanUcParenR', 'romanLcPeriod',
        'romanUcPeriod', 'circleNumDbPlain', 'circleNumWdBlackPlain',
        'circleNumWdWhitePlain', 'arabicDbPeriod', 'arabicDbPlain',
        'ea1ChsPeriod', 'ea1ChsPlain', 'ea1ChtPeriod', 'ea1ChtPlain',
        'ea1JpnChsDbPeriod', 'ea1JpnKorPlain', 'ea1JpnKorPeriod',
        'arabic1Minus', 'arabic2Minus', 'hebrew2Minus', 'thaiAlphaPeriod',
        'thaiAlphaParenR', 'thaiAlphaParenBoth', 'thaiNumPeriod',
        'thaiNumParenR', 'thaiNumParenBoth', 'hindiAlphaPeriod',
        'hindiNumPeriod', 'hindiNumParenR', 'hindiAlpha1Period'
    ]))
    startAt = Integer()

    def __init__(
        self,
        type=None,
        startAt=None,
    ):
        self.type = type
        self.startAt = startAt
Exemplo n.º 14
0
class FillOverlayEffect(Serialisable):

    blend = Set(values=(['over', 'mult', 'screen', 'darken', 'lighten']))

    def __init__(self,
                 blend=None,
                ):
        self.blend = blend
Exemplo n.º 15
0
class Pane(Serialisable):
    xSplit = Float(allow_none=True)
    ySplit = Float(allow_none=True)
    topLeftCell = String(allow_none=True)
    activePane = Set(values=("bottomRight", "topRight", "bottomLeft",
                             "topLeft"))
    state = Set(values=("split", "frozen", "frozenSplit"))

    def __init__(self,
                 xSplit=None,
                 ySplit=None,
                 topLeftCell=None,
                 activePane="topLeft",
                 state="split"):
        self.xSplit = xSplit
        self.ySplit = ySplit
        self.topLeftCell = topLeftCell
        self.activePane = activePane
        self.state = state
Exemplo n.º 16
0
class EffectContainer(Serialisable):

    type = Set(values=(['sib', 'tree']))
    name = String(allow_none=True)

    def __init__(self,
                 type=None,
                 name=None,
                ):
        self.type = type
        self.name = name
Exemplo n.º 17
0
class TabStop(Serialisable):

    pos = Typed(expected_type=Coordinate, allow_none=True)
    algn = Typed(expected_type=Set(values=(['l', 'ctr', 'r', 'dec'])))

    def __init__(
        self,
        pos=None,
        algn=None,
    ):
        self.pos = pos
        self.algn = algn
Exemplo n.º 18
0
class DataField(Serialisable):

    tagname = "dataField"

    name = String(allow_none=True)
    fld = Integer()
    subtotal = Set(values=([
        'average', 'count', 'countNums', 'max', 'min', 'product', 'stdDev',
        'stdDevp', 'sum', 'var', 'varp'
    ]))
    showDataAs = Set(values=([
        'normal', 'difference', 'percent', 'percentDiff', 'runTotal',
        'percentOfRow', 'percentOfCol', 'percentOfTotal', 'index'
    ]))
    baseField = Integer()
    baseItem = Integer()
    numFmtId = Integer(allow_none=True)
    extLst = Typed(expected_type=ExtensionList, allow_none=True)

    __elements__ = ()

    def __init__(
        self,
        name=None,
        fld=None,
        subtotal="sum",
        showDataAs="normal",
        baseField=-1,
        baseItem=1048832,
        numFmtId=None,
        extLst=None,
    ):
        self.name = name
        self.fld = fld
        self.subtotal = subtotal
        self.showDataAs = showDataAs
        self.baseField = baseField
        self.baseItem = baseItem
        self.numFmtId = numFmtId
        self.extLst = extLst
Exemplo n.º 19
0
class PathShadeProperties(Serialisable):

    tagname = "path"
    namespace = DRAWING_NS

    path = Set(values=(['shape', 'circle', 'rect']))
    fillToRect = Typed(expected_type=RelativeRect, allow_none=True)

    def __init__(self,
                 path=None,
                 fillToRect=None,
                ):
        self.path = path
        self.fillToRect = fillToRect
Exemplo n.º 20
0
class LightRig(Serialisable):

    tagname = "lightRig"

    rig = Set(values=[
        'legacyFlat1', 'legacyFlat2', 'legacyFlat3', 'legacyFlat4',
        'legacyNormal1', 'legacyNormal2', 'legacyNormal3', 'legacyNormal4',
        'legacyHarsh1', 'legacyHarsh2', 'legacyHarsh3', 'legacyHarsh4',
        'threePt', 'balanced', 'soft', 'harsh', 'flood', 'contrasting',
        'morning', 'sunrise', 'sunset', 'chilly', 'freezing', 'flat', 'twoPt',
        'glow', 'brightRoom'
    ])
    dir = Set(values=(['tl', 't', 'tr', 'l', 'r', 'bl', 'b', 'br']))
    rot = Typed(expected_type=SphereCoords, allow_none=True)

    def __init__(
        self,
        rig=None,
        dir=None,
        rot=None,
    ):
        self.rig = rig
        self.dir = dir
        self.rot = rot
Exemplo n.º 21
0
class Camera(Serialisable):

    tagname = "camera"

    prst = Set(values=[
        'legacyObliqueTopLeft', 'legacyObliqueTop', 'legacyObliqueTopRight',
        'legacyObliqueLeft', 'legacyObliqueFront', 'legacyObliqueRight',
        'legacyObliqueBottomLeft', 'legacyObliqueBottom',
        'legacyObliqueBottomRight', 'legacyPerspectiveTopLeft',
        'legacyPerspectiveTop', 'legacyPerspectiveTopRight',
        'legacyPerspectiveLeft', 'legacyPerspectiveFront',
        'legacyPerspectiveRight', 'legacyPerspectiveBottomLeft',
        'legacyPerspectiveBottom', 'legacyPerspectiveBottomRight',
        'orthographicFront', 'isometricTopUp', 'isometricTopDown',
        'isometricBottomUp', 'isometricBottomDown', 'isometricLeftUp',
        'isometricLeftDown', 'isometricRightUp', 'isometricRightDown',
        'isometricOffAxis1Left', 'isometricOffAxis1Right',
        'isometricOffAxis1Top', 'isometricOffAxis2Left',
        'isometricOffAxis2Right', 'isometricOffAxis2Top',
        'isometricOffAxis3Left', 'isometricOffAxis3Right',
        'isometricOffAxis3Bottom', 'isometricOffAxis4Left',
        'isometricOffAxis4Right', 'isometricOffAxis4Bottom', 'obliqueTopLeft',
        'obliqueTop', 'obliqueTopRight', 'obliqueLeft', 'obliqueRight',
        'obliqueBottomLeft', 'obliqueBottom', 'obliqueBottomRight',
        'perspectiveFront', 'perspectiveLeft', 'perspectiveRight',
        'perspectiveAbove', 'perspectiveBelow', 'perspectiveAboveLeftFacing',
        'perspectiveAboveRightFacing', 'perspectiveContrastingLeftFacing',
        'perspectiveContrastingRightFacing', 'perspectiveHeroicLeftFacing',
        'perspectiveHeroicRightFacing', 'perspectiveHeroicExtremeLeftFacing',
        'perspectiveHeroicExtremeRightFacing', 'perspectiveRelaxed',
        'perspectiveRelaxedModerately'
    ])
    fov = Integer(allow_none=True)
    zoom = Typed(expected_type=Percentage, allow_none=True)
    rot = Typed(expected_type=SphereCoords, allow_none=True)

    def __init__(
        self,
        prst=None,
        fov=None,
        zoom=None,
        rot=None,
    ):
        self.prst = prst
        self.fov = fov
        self.zoom = zoom
        self.rot = rot
Exemplo n.º 22
0
class ReflectionEffect(Serialisable):

    blurRad = Float()
    stA = Integer()
    stPos = Integer()
    endA = Integer()
    endPos = Integer()
    dist = Float()
    dir = Integer()
    fadeDir = Integer()
    sx = Integer()
    sy = Integer()
    kx = Integer()
    ky = Integer()
    algn = Set(values=(['tl', 't', 'tr', 'l', 'ctr', 'r', 'bl', 'b', 'br']))
    rotWithShape = Bool(allow_none=True)

    def __init__(self,
                 blurRad=None,
                 stA=None,
                 stPos=None,
                 endA=None,
                 endPos=None,
                 dist=None,
                 dir=None,
                 fadeDir=None,
                 sx=None,
                 sy=None,
                 kx=None,
                 ky=None,
                 algn=None,
                 rotWithShape=None,
                ):
        self.blurRad = blurRad
        self.stA = stA
        self.stPos = stPos
        self.endA = endA
        self.endPos = endPos
        self.dist = dist
        self.dir = dir
        self.fadeDir = fadeDir
        self.sx = sx
        self.sy = sy
        self.kx = kx
        self.ky = ky
        self.algn = algn
        self.rotWithShape = rotWithShape
Exemplo n.º 23
0
class OuterShadow(ColorChoice):

    tagname = "outerShdw"

    blurRad = Float(allow_none=True)
    dist = Float(allow_none=True)
    dir = Integer(allow_none=True)
    sx = Integer(allow_none=True)
    sy = Integer(allow_none=True)
    kx = Integer(allow_none=True)
    ky = Integer(allow_none=True)
    algn = Set(values=['tl', 't', 'tr', 'l', 'ctr', 'r', 'bl', 'b', 'br'])
    rotWithShape = Bool(allow_none=True)
    # uses element group EG_ColorChoice
    scrgbClr = ColorChoice.scrgbClr
    srgbClr = ColorChoice.srgbClr
    hslClr = ColorChoice.hslClr
    sysClr = ColorChoice.sysClr
    schemeClr = ColorChoice.schemeClr
    prstClr = ColorChoice.prstClr

    __elements__ = ('scrgbClr', 'srgbClr', 'hslClr', 'sysClr', 'schemeClr', 'prstClr')

    def __init__(self,
                 blurRad=None,
                 dist=None,
                 dir=None,
                 sx=None,
                 sy=None,
                 kx=None,
                 ky=None,
                 algn=None,
                 rotWithShape=None,
                 **kw
                ):
        self.blurRad = blurRad
        self.dist = dist
        self.dir = dir
        self.sx = sx
        self.sy = sy
        self.kx = kx
        self.ky = ky
        self.algn = algn
        self.rotWithShape = rotWithShape
        super(OuterShadow, self).__init__(**kw)
Exemplo n.º 24
0
class FieldItem(Serialisable):

    tagname = "item"

    n = String(allow_none=True)
    t = Set(values=([
        'data', 'default', 'sum', 'countA', 'avg', 'max', 'min', 'product',
        'count', 'stdDev', 'stdDevP', 'var', 'varP', 'grand', 'blank'
    ]))
    h = Bool(allow_none=True)
    s = Bool(allow_none=True)
    sd = Bool(allow_none=True)
    f = Bool(allow_none=True)
    m = Bool(allow_none=True)
    c = Bool(allow_none=True)
    x = Integer(allow_none=True)
    d = Bool(allow_none=True)
    e = Bool(allow_none=True)

    def __init__(
        self,
        n=None,
        t="data",
        h=None,
        s=None,
        sd=True,
        f=None,
        m=None,
        c=None,
        x=None,
        d=None,
        e=None,
    ):
        self.n = n
        self.t = t
        self.h = h
        self.s = s
        self.sd = sd
        self.f = f
        self.m = m
        self.c = c
        self.x = x
        self.d = d
        self.e = e
Exemplo n.º 25
0
class IconFilter(Serialisable):

    tagname = "iconFilter"

    iconSet = Set(values=([
        '3Arrows', '3ArrowsGray', '3Flags', '3TrafficLights1',
        '3TrafficLights2', '3Signs', '3Symbols', '3Symbols2', '4Arrows',
        '4ArrowsGray', '4RedToBlack', '4Rating', '4TrafficLights', '5Arrows',
        '5ArrowsGray', '5Rating', '5Quarters'
    ]))
    iconId = Integer(allow_none=True)

    def __init__(
        self,
        iconSet=None,
        iconId=None,
    ):
        self.iconSet = iconSet
        self.iconId = iconId
Exemplo n.º 26
0
class FormatObject(Serialisable):

    tagname = "cfvo"

    type = Set(values=(['num', 'percent', 'max', 'min', 'formula', 'percentile']))
    val = ValueDescriptor(allow_none=True)
    gte = Bool(allow_none=True)
    extLst = Typed(expected_type=ExtensionList, allow_none=True)

    __elements__ = ()

    def __init__(self,
                 type,
                 val=None,
                 gte=None,
                 extLst=None,
                ):
        self.type = type
        self.val = val
        self.gte = gte
Exemplo n.º 27
0
class TileInfoProperties(Serialisable):

    tx = Integer(allow_none=True)
    ty = Integer(allow_none=True)
    sx = Integer(allow_none=True)
    sy = Integer(allow_none=True)
    flip = NoneSet(values=(['x', 'y', 'xy']))
    algn = Set(values=(['tl', 't', 'tr', 'l', 'ctr', 'r', 'bl', 'b', 'br']))

    def __init__(self,
                 tx=None,
                 ty=None,
                 sx=None,
                 sy=None,
                 flip=None,
                 algn=None,
                ):
        self.tx = tx
        self.ty = ty
        self.sx = sx
        self.sy = sy
        self.flip = flip
        self.algn = algn
Exemplo n.º 28
0
class PresetTextShape(Serialisable):

    prst = Typed(expected_type=Set(values=([
        'textNoShape', 'textPlain', 'textStop', 'textTriangle',
        'textTriangleInverted', 'textChevron', 'textChevronInverted',
        'textRingInside', 'textRingOutside', 'textArchUp', 'textArchDown',
        'textCircle', 'textButton', 'textArchUpPour', 'textArchDownPour',
        'textCirclePour', 'textButtonPour', 'textCurveUp', 'textCurveDown',
        'textCanUp', 'textCanDown', 'textWave1', 'textWave2',
        'textDoubleWave1', 'textWave4', 'textInflate', 'textDeflate',
        'textInflateBottom', 'textDeflateBottom', 'textInflateTop',
        'textDeflateTop', 'textDeflateInflate', 'textDeflateInflateDeflate',
        'textFadeRight', 'textFadeLeft', 'textFadeUp', 'textFadeDown',
        'textSlantUp', 'textSlantDown', 'textCascadeUp', 'textCascadeDown'
    ])))
    avLst = Typed(expected_type=GeomGuideList, allow_none=True)

    def __init__(
        self,
        prst=None,
        avLst=None,
    ):
        self.prst = prst
        self.avLst = avLst
Exemplo n.º 29
0
class Rule(Serialisable):

    tagname = "cfRule"

    type = Set(values=(['expression', 'cellIs', 'colorScale', 'dataBar',
                        'iconSet', 'top10', 'uniqueValues', 'duplicateValues', 'containsText',
                        'notContainsText', 'beginsWith', 'endsWith', 'containsBlanks',
                        'notContainsBlanks', 'containsErrors', 'notContainsErrors', 'timePeriod',
                        'aboveAverage']))
    dxfId = Integer(allow_none=True)
    priority = Integer()
    stopIfTrue = Bool(allow_none=True)
    aboveAverage = Bool(allow_none=True)
    percent = Bool(allow_none=True)
    bottom = Bool(allow_none=True)
    operator = NoneSet(values=(['lessThan', 'lessThanOrEqual', 'equal',
                            'notEqual', 'greaterThanOrEqual', 'greaterThan', 'between', 'notBetween',
                            'containsText', 'notContains', 'beginsWith', 'endsWith']))
    text = String(allow_none=True)
    timePeriod = NoneSet(values=(['today', 'yesterday', 'tomorrow', 'last7Days',
                              'thisMonth', 'lastMonth', 'nextMonth', 'thisWeek', 'lastWeek',
                              'nextWeek']))
    rank = Integer(allow_none=True)
    stdDev = Integer(allow_none=True)
    equalAverage = Bool(allow_none=True)
    formula = Sequence(expected_type=unicode)
    colorScale = Typed(expected_type=ColorScale, allow_none=True)
    dataBar = Typed(expected_type=DataBar, allow_none=True)
    iconSet = Typed(expected_type=IconSet, allow_none=True)
    extLst = Typed(expected_type=ExtensionList, allow_none=True)
    dxf = Typed(expected_type=DifferentialStyle, allow_none=True)

    __elements__ = ('colorScale', 'dataBar', 'iconSet', 'formula')
    __attrs__ = ('type', 'rank', 'priority', 'equalAverage', 'operator',
                 'aboveAverage', 'dxfId', 'stdDev', 'stopIfTrue', 'timePeriod', 'text',
                 'percent', 'bottom')


    def __init__(self,
                 type,
                 dxfId=None,
                 priority=0,
                 stopIfTrue=None,
                 aboveAverage=None,
                 percent=None,
                 bottom=None,
                 operator=None,
                 text=None,
                 timePeriod=None,
                 rank=None,
                 stdDev=None,
                 equalAverage=None,
                 formula=(),
                 colorScale=None,
                 dataBar=None,
                 iconSet=None,
                 extLst=None,
                 dxf=None,
                ):
        self.type = type
        self.dxfId = dxfId
        self.priority = priority
        self.stopIfTrue = stopIfTrue
        self.aboveAverage = aboveAverage
        self.percent = percent
        self.bottom = bottom
        self.operator = operator
        self.text = text
        self.timePeriod = timePeriod
        self.rank = rank
        self.stdDev = stdDev
        self.equalAverage = equalAverage
        self.formula = formula
        self.colorScale = colorScale
        self.dataBar = dataBar
        self.iconSet = iconSet
        self.dxf = dxf
Exemplo n.º 30
0
class SystemColor(Serialisable):

    tagname = "sysClr"
    namespace = DRAWING_NS

    # color transform options
    tint = NestedInteger(allow_none=True)
    shade = NestedInteger(allow_none=True)
    comp = Typed(expected_type=Transform, allow_none=True)
    inv = Typed(expected_type=Transform, allow_none=True)
    gray = Typed(expected_type=Transform, allow_none=True)
    alpha = NestedInteger(allow_none=True)
    alphaOff = NestedInteger(allow_none=True)
    alphaMod = NestedInteger(allow_none=True)
    hue = NestedInteger(allow_none=True)
    hueOff = NestedInteger(allow_none=True)
    hueMod = NestedInteger(allow_none=True)
    sat = NestedInteger(allow_none=True)
    satOff = NestedInteger(allow_none=True)
    satMod = NestedInteger(allow_none=True)
    lum = NestedInteger(allow_none=True)
    lumOff = NestedInteger(allow_none=True)
    lumMod = NestedInteger(allow_none=True)
    red = NestedInteger(allow_none=True)
    redOff = NestedInteger(allow_none=True)
    redMod = NestedInteger(allow_none=True)
    green = NestedInteger(allow_none=True)
    greenOff = NestedInteger(allow_none=True)
    greenMod = NestedInteger(allow_none=True)
    blue = NestedInteger(allow_none=True)
    blueOff = NestedInteger(allow_none=True)
    blueMod = NestedInteger(allow_none=True)
    gamma = Typed(expected_type=Transform, allow_none=True)
    invGamma = Typed(expected_type=Transform, allow_none=True)

    val = Set(values=( ['scrollBar', 'background', 'activeCaption',
                        'inactiveCaption', 'menu', 'window', 'windowFrame', 'menuText',
                        'windowText', 'captionText', 'activeBorder', 'inactiveBorder',
                        'appWorkspace', 'highlight', 'highlightText', 'btnFace', 'btnShadow',
                        'grayText', 'btnText', 'inactiveCaptionText', 'btnHighlight',
                        '3dDkShadow', '3dLight', 'infoText', 'infoBk', 'hotLight',
                        'gradientActiveCaption', 'gradientInactiveCaption', 'menuHighlight',
                        'menuBar'] )
              )
    lastClr = RGB(allow_none=True)

    __elements__ = ('tint', 'shade', 'comp', 'inv', 'gray', "alpha",
                    "alphaOff", "alphaMod", "hue", "hueOff", "hueMod", "hueOff", "sat",
                    "satOff", "satMod", "lum", "lumOff", "lumMod", "red", "redOff", "redMod",
                    "green", "greenOff", "greenMod", "blue", "blueOff", "blueMod", "gamma",
                    "invGamma")

    def __init__(self,
                 val="windowText",
                 lastClr=None,
                 tint=None,
                 shade=None,
                 comp=None,
                 inv=None,
                 gray=None,
                 alpha=None,
                 alphaOff=None,
                 alphaMod=None,
                 hue=None,
                 hueOff=None,
                 hueMod=None,
                 sat=None,
                 satOff=None,
                 satMod=None,
                 lum=None,
                 lumOff=None,
                 lumMod=None,
                 red=None,
                 redOff=None,
                 redMod=None,
                 green=None,
                 greenOff=None,
                 greenMod=None,
                 blue=None,
                 blueOff=None,
                 blueMod=None,
                 gamma=None,
                 invGamma=None
                ):
        self.val = val
        self.lastClr = lastClr
        self.tint = tint
        self.shade = shade
        self.comp = comp
        self.inv = inv
        self.gray = gray
        self.alpha = alpha
        self.alphaOff = alphaOff
        self.alphaMod = alphaMod
        self.hue = hue
        self.hueOff = hueOff
        self.hueMod = hueMod
        self.sat = sat
        self.satOff = satOff
        self.satMod = satMod
        self.lum = lum
        self.lumOff = lumOff
        self.lumMod = lumMod
        self.red = red
        self.redOff = redOff
        self.redMod = redMod
        self.green = green
        self.greenOff = greenOff
        self.greenMod = greenMod
        self.blue = blue
        self.blueOff = blueOff
        self.blueMod = blueMod
        self.gamma = gamma
        self.invGamma = invGamma