Ejemplo n.º 1
0
class IStrandBase(interfaces.IRMLDirectiveSignature):

    strokeWidth = attr.Measurement(title='Stroke Width',
                                   description='The line width of the strand.',
                                   required=False)

    fillColor = attr.Color(title='Fill Color',
                           description='The fill color of the strand area.',
                           required=False)

    strokeColor = attr.Color(title='Stroke Color',
                             description='The color of the strand line.',
                             required=False)

    strokeDashArray = attr.Sequence(
        title='Stroke Dash Array',
        description='The dash array of the strand line.',
        value_type=attr.Float(),
        required=False)

    symbol = attr.Symbol(title='Symbol',
                         description='The symbol to use to mark the strand.',
                         required=False)

    symbolSize = attr.Measurement(title='Symbol Size',
                                  description='The size of the strand symbol.',
                                  required=False)
Ejemplo n.º 2
0
class ISpanStyle(interfaces.IRMLDirectiveSignature):
    """Defines a span style and gives it a name."""

    name = attr.String(title=u'Name',
                       description=u'The name of the style.',
                       required=True)

    alias = attr.String(
        title=u'Alias',
        description=u'An alias under which the style will also be known as.',
        required=False)

    parent = attr.Style(
        title=u'Parent',
        description=(u'The apragraph style that will be used as a base for '
                     u'this one.'),
        required=False)

    fontName = attr.String(title=u'Font Name',
                           description=u'The name of the font for the span.',
                           required=False)

    fontSize = attr.Measurement(
        title=u'Font Size',
        description=u'The font size for the text of the span.',
        required=False)

    textColor = attr.Color(
        title=u'Text Color',
        description=u'The color in which the text will appear.',
        required=False)

    backColor = attr.Color(title=u'Background Color',
                           description=u'The background color of the span.',
                           required=False)
Ejemplo n.º 3
0
class ISpoke(interfaces.IRMLDirectiveSignature):
    """A spoke in the spider diagram."""

    strokeWidth = attr.Measurement(
        title='Stroke Width',
        description="The width of the spoke's line.",
        required=False)

    fillColor = attr.Color(title='Fill Color',
                           description="The fill color of the spoke's area.",
                           required=False)

    strokeColor = attr.Color(title='Stroke Color',
                             description='The color of the spoke line.',
                             required=False)

    strokeDashArray = attr.Sequence(
        title='Stroke Dash Array',
        description='The dash array of the spoke line.',
        value_type=attr.Float(),
        required=False)

    labelRadius = attr.Measurement(
        title='Label Radius',
        description='The radius of the label arouns the spoke.',
        required=False)

    visible = attr.Boolean(title='Visible',
                           description='When true, the spoke line is drawn.',
                           required=False)
Ejemplo n.º 4
0
class IMarker(interfaces.IRMLDirectiveSignature):
    x = attr.Measurement()
    y = attr.Measurement()
    dx = attr.Measurement()
    dy = attr.Measurement()
    size = attr.Measurement()
    fillColor = attr.Color(acceptNone=True, required=False)
    strokeColor = attr.Color(acceptNone=True, required=False)
    strokeWidth = attr.Measurement(required=False)
    arrowBarDx = attr.Measurement(required=False)
    arrowHeight = attr.Measurement(required=False)
Ejemplo n.º 5
0
class ICropMarks(interfaces.IRMLDirectiveSignature):
    """Crop Marks specification"""

    name = attr.Text(title='Name',
                     description='The name of the index.',
                     default='index',
                     required=True)

    borderWidth = attr.Measurement(
        title='Border Width',
        description='The width of the crop mark border.',
        required=False)

    markColor = attr.Color(title='Mark Color',
                           description='The color of the crop marks.',
                           required=False)

    markWidth = attr.Measurement(
        title='Mark Width',
        description='The line width of the actual crop marks.',
        required=False)

    markLength = attr.Measurement(
        title='Mark Length',
        description='The length of the actual crop marks.',
        required=False)

    markLast = attr.Boolean(
        title='Mark Last',
        description='If set, marks are drawn after the content is rendered.',
        required=False)

    bleedWidth = attr.Measurement(title='Bleed Width',
                                  description=('The width of the page bleed.'),
                                  required=False)
Ejemplo n.º 6
0
class ISlice3D(ISlice):
    """A 3-D slice of a 3-D pie chart."""

    fillColorShaded = attr.Color(
        title='Fill Color Shade',
        description='The shade used for the fill color.',
        required=False)
Ejemplo n.º 7
0
class IImage(interfaces.IRMLDirectiveSignature):
    """An image."""

    src = attr.Image(
        title=u'Image Source',
        description=u'The file that is used to extract the image data.',
        onlyOpen=True,
        required=True)

    width = attr.Measurement(title=u'Image Width',
                             description=u'The width of the image.',
                             required=False)

    height = attr.Measurement(title=u'Image Height',
                              description=u'The height the image.',
                              required=False)

    mask = attr.Color(title=u'Mask',
                      description=u'The color mask used to render the image.',
                      required=False)

    vAlign = attr.Choice(title=u'Vertical Alignment',
                         description=u'The vertical alignment of the image.',
                         choices=interfaces.VALIGN_TEXT_CHOICES,
                         required=False)
Ejemplo n.º 8
0
class IBlockTextColor(ITableStyleCommand):
    """Set the text color."""

    colorName = attr.Color(
        title=u'Color Name',
        description=u'The color in which the text will appear.',
        required=True)
Ejemplo n.º 9
0
class ILink(interfaces.IRMLDirectiveSignature):
    """Place an internal link around a set of flowables."""

    destination = attr.Text(
        title=u'Destination',
        description=u'The name of the destination to link to.',
        required=False)

    url = attr.Text(title=u'URL',
                    description=u'The URL to link to.',
                    required=False)

    boxStrokeWidth = attr.Measurement(
        title=u'Box Stroke Width',
        description=u'The width of the box border line.',
        required=False)

    boxStrokeDashArray = attr.Sequence(
        title=u'Box Stroke Dash Array',
        description=u'The dash array of the box border line.',
        value_type=attr.Float(),
        required=False)

    boxStrokeColor = attr.Color(
        title=u'Box Stroke Color',
        description=(u'The color in which the box border is drawn.'),
        required=False)
Ejemplo n.º 10
0
class ISlicePointer(interfaces.IRMLDirectiveSignature):
    """A pointer to a slice in a pie chart."""

    strokeColor = attr.Color(title='Stroke Color',
                             description='The color of the pointer line.',
                             required=False)

    strokeWidth = attr.Measurement(
        title='Stroke Width',
        description='The wodth of the pointer line.',
        required=False)

    elbowLength = attr.Measurement(
        title='Elbow Length',
        description='The length of the final segment of the pointer.',
        required=False)

    edgePad = attr.Measurement(
        title='Edge Padding',
        description='The padding between between the pointer label and box.',
        required=False)

    piePad = attr.Measurement(
        title='Pie Padding',
        description='The padding between between the pointer label and chart.',
        required=False)
Ejemplo n.º 11
0
class IBlockColBackground(ITableStyleCommand):
    """Define the background colors for columns."""

    colorNames = attr.Sequence(
        title=u'Colors By Row',
        description=u'A list of colors to be used circularly for rows.',
        value_type=attr.Color(),
        required=True)
Ejemplo n.º 12
0
class IColorDefinition(interfaces.IRMLDirectiveSignature):
    """Define a new color and give it a name to be known under."""

    id = attr.String(
        title=u'Id',
        description=(u'The id/name the color will be available under.'),
        required=True)

    RGB = attr.Color(
        title=u'RGB Color',
        description=(u'The color value that is represented.'),
        required=False)

    CMYK = attr.Color(
        title=u'CMYK Color',
        description=(u'The color value that is represented.'),
        required=False)

    value = attr.Color(
        title=u'Color',
        description=(u'The color value that is represented.'),
        required=False)

    spotName = attr.String(
        title=u'Spot Name',
        description=(u'The Spot Name of the CMYK color.'),
        required=False)

    density = attr.Float(
        title=u'Density',
        description=(u'The color density of the CMYK color.'),
        min=0.0,
        max=1.0,
        required=False)

    knockout = attr.String(
        title=u'Knockout',
        description=(u'The knockout of the CMYK color.'),
        required=False)

    alpha = attr.Float(
        title=u'Alpha',
        description=(u'The alpha channel of the color.'),
        min=0.0,
        max=1.0,
        required=False)
Ejemplo n.º 13
0
class IBar(interfaces.IRMLDirectiveSignature):
    """Define the look of a bar."""

    strokeColor = attr.Color(
        title='Stroke Color',
        description='The color in which the bar border is drawn.',
        required=False)

    strokeWidth = attr.Measurement(
        title='Stroke Width',
        description='The width of the bar border line.',
        required=False)

    fillColor = attr.Color(
        title='Fill Color',
        description='The color with which the bar is filled.',
        required=False)
Ejemplo n.º 14
0
class IMinimalListStyle(interfaces.IRMLDirectiveSignature):

    leftIndent = attr.Measurement(
        title=u'Left Indentation',
        description=u'General indentation on the left side.',
        required=False)

    rightIndent = attr.Measurement(
        title=u'Right Indentation',
        description=u'General indentation on the right side.',
        required=False)

    bulletColor = attr.Color(
        title=u'Bullet Color',
        description=u'The color in which the bullet will appear.',
        required=False)

    bulletFontName = attr.String(
        title=u'Bullet Font Name',
        description=u'The font in which the bullet character will be rendered.',
        required=False)

    bulletFontSize = attr.Measurement(
        title=u'Bullet Font Size',
        description=u'The font size of the bullet character.',
        required=False)

    bulletOffsetY = attr.Measurement(
        title=u'Bullet Y-Offset',
        description=u'The vertical offset of the bullet.',
        required=False)

    bulletDedent = attr.StringOrInt(
        title=u'Bullet Dedent',
        description=u'Either pixels of dedent or auto (default).',
        required=False)

    bulletDir = attr.Choice(
        title=u'Bullet Layout Direction',
        description=u'The layout direction of the bullet.',
        choices=('ltr', 'rtl'),
        required=False)

    bulletFormat = attr.String(
        title=u'Bullet Format',
        description=u'A formatting expression for the bullet text.',
        required=False)

    bulletType = attr.Choice(
        title=u'Bullet Type',
        description=u'The type of number to display.',
        choices=interfaces.ORDERED_LIST_TYPES + \
                interfaces.UNORDERED_BULLET_VALUES,
        doLower=False,
        required=False)
Ejemplo n.º 15
0
class IHorizontalRow(interfaces.IRMLDirectiveSignature):
    """Create a horizontal line on the page."""

    width = attr.Measurement(
        title=u'Width',
        description=u'The width of the line on the page.',
        allowPercentage=True,
        required=False)

    thickness = attr.Measurement(
        title=u'Thickness',
        description=u'Line Thickness',
        required=False)

    color = attr.Color(
        title=u'Color',
        description=u'The color of the line.',
        required=False)

    lineCap = attr.Choice(
        title=u'Cap',
        description=u'The cap at the end of the line.',
        choices=interfaces.CAP_CHOICES.keys(),
        required=False)

    spaceBefore = attr.Measurement(
        title=u'Space Before',
        description=u'The vertical space before the line.',
        required=False)

    spaceAfter = attr.Measurement(
        title=u'Space After',
        description=u'The vertical space after the line.',
        required=False)

    align = attr.Choice(
        title=u'Alignment',
        description=u'The alignment of the line within the frame.',
        choices=interfaces.ALIGN_TEXT_CHOICES,
        required=False)

    valign = attr.Choice(
        title=u'Vertical Alignment',
        description=u'The vertical alignment of the line.',
        choices=interfaces.VALIGN_TEXT_CHOICES,
        required=False)

    dash = attr.Sequence(
        title=u'Dash-Pattern',
        description=u'The dash-pattern of a line.',
        value_type=attr.Measurement(),
        default=None,
        required=False)
Ejemplo n.º 16
0
class IBlockBackground(ITableStyleCommand):
    """Define the background color of the cells.

    It also supports alternating colors.
    """

    colorName = attr.Color(
        title=u'Color Name',
        description=u'The color to use as the background for every cell.',
        required=False)

    colorsByRow = attr.Sequence(
        title=u'Colors By Row',
        description=u'A list of colors to be used circularly for rows.',
        value_type=attr.Color(acceptNone=True),
        required=False)

    colorsByCol = attr.Sequence(
        title=u'Colors By Column',
        description=u'A list of colors to be used circularly for columns.',
        value_type=attr.Color(acceptNone=True),
        required=False)
Ejemplo n.º 17
0
class ISliceBase(interfaces.IRMLDirectiveSignature):

    strokeWidth = attr.Measurement(title='Stroke Width',
                                   description='The wodth of the slice line.',
                                   required=False)

    fillColor = attr.Color(title='Fill Color',
                           description='The fill color of the slice.',
                           required=False)

    strokeColor = attr.Color(title='Stroke Color',
                             description='The color of the pointer line.',
                             required=False)

    strokeDashArray = attr.Sequence(
        title='Stroke Dash Array',
        description='Teh dash array of the slice borderline.',
        value_type=attr.Float(),
        required=False)

    popout = attr.Measurement(
        title='Popout',
        description='The distance of how much the slice should be popped out.',
        required=False)

    fontName = attr.Text(title='Font Name',
                         description='The font name of the label.',
                         required=False)

    fontSize = attr.Measurement(title='Font Size',
                                description='The font size of the label.',
                                required=False)

    labelRadius = attr.Measurement(
        title='Label Radius',
        description=('The radius at which the label should be placed around '
                     'the pie.'),
        required=False)
Ejemplo n.º 18
0
class ILineStyle(ITableStyleCommand):
    """Define the border line style of each cell."""

    kind = attr.Choice(
        title=u'Kind',
        description=u'The kind of line actions to be taken.',
        choices=('GRID', 'BOX', 'OUTLINE', 'INNERGRID',
                 'LINEBELOW', 'LINEABOVE', 'LINEBEFORE', 'LINEAFTER'),
        required=True)

    thickness = attr.Measurement(
        title=u'Thickness',
        description=u'Line Thickness',
        default=1,
        required=True)

    colorName = attr.Color(
        title=u'Color',
        description=u'The color of the border line.',
        default=None,
        required=True)

    cap = attr.Choice(
        title=u'Cap',
        description=u'The cap at the end of a border line.',
        choices=interfaces.CAP_CHOICES,
        default=1,
        required=True)

    dash = attr.Sequence(
        title=u'Dash-Pattern',
        description=u'The dash-pattern of a line.',
        value_type=attr.Measurement(),
        default=[],
        required=False)

    join = attr.Choice(
        title=u'Join',
        description=u'The way lines are joined together.',
        choices=interfaces.JOIN_CHOICES,
        default=1,
        required=False)

    count = attr.Integer(
        title=u'Count',
        description=(u'Describes whether the line is a single (1) or '
                     u'double (2) line.'),
        default=1,
        required=False)
Ejemplo n.º 19
0
class IImage(interfaces.IRMLDirectiveSignature):
    """Draws an external image on the canvas."""

    file = attr.Image(
        title='File',
        description=('Reference to the external file of the iamge.'),
        required=True)

    x = attr.Measurement(
        title='X-Coordinate',
        description=('The X-coordinate of the lower-left position of the '
                     'shape.'),
        required=True)

    y = attr.Measurement(
        title='Y-Coordinate',
        description=('The Y-coordinate of the lower-left position of the '
                     'shape.'),
        required=True)

    width = attr.Measurement(title='Width',
                             description='The width of the image.',
                             required=False)

    height = attr.Measurement(title='Height',
                              description='The height of the image.',
                              required=False)

    showBoundary = attr.Boolean(
        title='Show Boundary',
        description=('A flag determining whether a border should be drawn '
                     'around the image.'),
        default=False,
        required=False)

    preserveAspectRatio = attr.Boolean(
        title='Preserve Aspect Ratio',
        description=("A flag determining whether the image's aspect ration "
                     "should be conserved under any circumstances."),
        default=False,
        required=False)

    mask = attr.Color(
        title='Mask',
        description=
        'The color mask used to render the image, or "auto" to use the alpha channel if available.',
        default='auto',
        required=False,
        acceptAuto=True)
Ejemplo n.º 20
0
class IImageAndFlowables(interfaces.IRMLDirectiveSignature):
    """An image with flowables around it."""

    imageName = attr.Image(
        title=u'Image',
        description=u'The file that is used to extract the image data.',
        onlyOpen=True,
        required=True)

    imageWidth = attr.Measurement(
        title=u'Image Width',
        description=u'The width of the image.',
        required=False)

    imageHeight = attr.Measurement(
        title=u'Image Height',
        description=u'The height the image.',
        required=False)

    imageMask = attr.Color(
        title=u'Mask',
        description=u'The height the image.',
        required=False)

    imageLeftPadding = attr.Measurement(
        title=u'Image Left Padding',
        description=u'The padding on the left side of the image.',
        required=False)

    imageRightPadding = attr.Measurement(
        title=u'Image Right Padding',
        description=u'The padding on the right side of the image.',
        required=False)

    imageTopPadding = attr.Measurement(
        title=u'Image Top Padding',
        description=u'The padding on the top of the image.',
        required=False)

    imageBottomPadding = attr.Measurement(
        title=u'Image Bottom Padding',
        description=u'The padding on the bottom of the image.',
        required=False)

    imageSide = attr.Choice(
        title=u'Image Side',
        description=u'The side at which the image will be placed.',
        choices=('left', 'right'),
        required=False)
Ejemplo n.º 21
0
class IColorDefinition(interfaces.IRMLDirectiveSignature):
    """Define a new color and give it a name to be known under."""

    id = attr.String(
        title=u'Id',
        description=(u'The id/name the color will be available under.'),
        required=True)

    value = attr.Color(
        title=u'Color',
        description=(u'The color value that is represented.'),
        required=True)
    attr.deprecated(
        'RGB', value,
        (u'Ensures compatibility with ReportLab RML. Please use '
         u'the "value" attribute.'))
Ejemplo n.º 22
0
class IImage(interfaces.IRMLDirectiveSignature):
    """An image."""

    src = attr.Image(
        title=u'Image Source',
        description=u'The file that is used to extract the image data.',
        onlyOpen=True,
        required=True)

    width = attr.Measurement(
        title=u'Image Width',
        description=u'The width of the image.',
        required=False)

    height = attr.Measurement(
        title=u'Image Height',
        description=u'The height the image.',
        required=False)

    preserveAspectRatio = attr.Boolean(
        title=u'Preserve Aspect Ratio',
        description=(u'If set, the aspect ratio of the image is kept. When '
                     u'both, width and height, are specified, the image '
                     u'will be fitted into that bounding box.'),
        default=False,
        required=False)

    mask = attr.Color(
        title=u'Mask',
        description=u'The color mask used to render the image.',
        required=False)

    align = attr.Choice(
        title=u'Alignment',
        description=u'The alignment of the image within the frame.',
        choices=interfaces.ALIGN_TEXT_CHOICES,
        required=False)

    vAlign = attr.Choice(
        title=u'Vertical Alignment',
        description=u'The vertical alignment of the image.',
        choices=interfaces.VALIGN_TEXT_CHOICES,
        required=False)
Ejemplo n.º 23
0
class IText(interfaces.IRMLDirectiveSignature):
    """Draw a text on the chart."""

    x = attr.Measurement(
        title='X-Coordinate',
        description=('The X-coordinate of the lower-left position of the '
                     'text.'),
        required=True)

    y = attr.Measurement(
        title='Y-Coordinate',
        description=('The Y-coordinate of the lower-left position of the '
                     'text.'),
        required=True)

    angle = attr.Float(
        title='Rotation Angle',
        description=('The angle about which the text will be rotated.'),
        required=False)

    text = attr.TextNode(title='Text',
                         description='The text to be printed.',
                         required=True)

    fontName = attr.Text(title='Font Name',
                         description='The name of the font.',
                         required=False)

    fontSize = attr.Measurement(title='Font Size',
                                description='The font size for the text.',
                                required=False)

    fillColor = attr.Color(
        title='Fill Color',
        description='The color in which the text will appear.',
        required=False)

    textAnchor = attr.Choice(
        title='Text Anchor',
        description='The position in the text to which the coordinates refer.',
        choices=('start', 'middle', 'end', 'boxauto'),
        required=False)
Ejemplo n.º 24
0
class ILineBase(interfaces.IRMLDirectiveSignature):

    strokeWidth = attr.Measurement(title='Stroke Width',
                                   description='The width of the plot line.',
                                   required=False)

    strokeColor = attr.Color(title='Stroke Color',
                             description='The color of the plot line.',
                             required=False)

    strokeDashArray = attr.Sequence(
        title='Stroke Dash Array',
        description='The dash array of the plot line.',
        value_type=attr.Float(),
        required=False)

    symbol = attr.Symbol(
        title='Symbol',
        description='The symbol to be used for every data point in the plot.',
        required=False)
Ejemplo n.º 25
0
class IFill(interfaces.IRMLDirectiveSignature):
    """Set the fill color."""

    color = attr.Color(title='Color',
                       description=('The color value to be set.'),
                       required=True)
Ejemplo n.º 26
0
class ISlices3D(ISliceBase):
    """The collection of all 3-D slice descriptions."""
    occurence.containing(occurence.OneOrMore('slice', ISlice3D), )

    fillColorShaded = attr.Color(required=False)
Ejemplo n.º 27
0
class ILabelBase(interfaces.IRMLDirectiveSignature):

    dx = attr.Measurement(title='Horizontal Extension',
                          description=('The width of the label.'),
                          required=False)

    dy = attr.Measurement(title='Vertical Extension',
                          description=('The height of the label.'),
                          required=False)

    angle = attr.Float(title='Angle',
                       description=('The angle to rotate the label.'),
                       required=False)

    boxAnchor = attr.Choice(
        title='Box Anchor',
        description=('The position relative to the label.'),
        choices=('nw', 'n', 'ne', 'w', 'c', 'e', 'sw', 's', 'se', 'autox',
                 'autoy'),
        required=False)

    boxStrokeColor = attr.Color(
        title='Box Stroke Color',
        description=('The color of the box border line.'),
        required=False)

    boxStrokeWidth = attr.Measurement(
        title='Box Stroke Width',
        description='The width of the box border line.',
        required=False)

    boxFillColor = attr.Color(
        title='Box Fill Color',
        description=('The color in which the box is filled.'),
        required=False)

    boxTarget = attr.Text(title='Box Target',
                          description='The box target.',
                          required=False)

    fillColor = attr.Color(
        title='Fill Color',
        description=('The color in which the label is filled.'),
        required=False)

    strokeColor = attr.Color(title='Stroke Color',
                             description=('The color of the label.'),
                             required=False)

    strokeWidth = attr.Measurement(title='Stroke Width',
                                   description='The width of the label line.',
                                   required=False)

    fontName = attr.Text(title='Font Name',
                         description='The font used to print the value.',
                         required=False)

    fontSize = attr.Measurement(title='Font Size',
                                description='The size of the value text.',
                                required=False)

    leading = attr.Measurement(
        title='Leading',
        description=('The height of a single text line. It includes '
                     'character height.'),
        required=False)

    width = attr.Measurement(title='Width',
                             description='The width the label.',
                             required=False)

    maxWidth = attr.Measurement(title='Maximum Width',
                                description='The maximum width the label.',
                                required=False)

    height = attr.Measurement(title='Height',
                              description='The height the label.',
                              required=False)

    textAnchor = attr.Choice(
        title='Text Anchor',
        description='The position in the text to which the coordinates refer.',
        choices=('start', 'middle', 'end', 'boxauto'),
        required=False)

    visible = attr.Boolean(title='Visible',
                           description='A flag making the label text visible.',
                           required=False)

    leftPadding = attr.Measurement(
        title='Left Padding',
        description='The size of the padding on the left side.',
        required=False)

    rightPadding = attr.Measurement(
        title='Right Padding',
        description='The size of the padding on the right side.',
        required=False)

    topPadding = attr.Measurement(
        title='Top Padding',
        description='The size of the padding on the top.',
        required=False)

    bottomPadding = attr.Measurement(
        title='Bottom Padding',
        description='The size of the padding on the bottom.',
        required=False)
Ejemplo n.º 28
0
class IAxis(interfaces.IRMLDirectiveSignature):
    occurence.containing(occurence.ZeroOrMore('labels', ILabels))

    visible = attr.Boolean(
        title='Visible',
        description='When true, draw the entire axis with all details.',
        required=False)

    visibleAxis = attr.Boolean(title='Visible Axis',
                               description='When true, draw the axis line.',
                               required=False)

    visibleTicks = attr.Boolean(
        title='Visible Ticks',
        description='When true, draw the axis ticks on the line.',
        required=False)

    visibleLabels = attr.Boolean(
        title='Visible Labels',
        description='When true, draw the axis labels.',
        required=False)

    visibleGrid = attr.Boolean(
        title='Visible Grid',
        description='When true, draw the grid lines for the axis.',
        required=False)

    strokeWidth = attr.Measurement(
        title='Stroke Width',
        description='The width of axis line and ticks.',
        required=False)

    strokeColor = attr.Color(
        title='Stroke Color',
        description='The color in which the axis line and ticks are drawn.',
        required=False)

    strokeDashArray = attr.Sequence(
        title='Stroke Dash Array',
        description='The dash array that is used for the axis line and ticks.',
        value_type=attr.Float(),
        required=False)

    gridStrokeWidth = attr.Measurement(
        title='Grid Stroke Width',
        description='The width of the grid lines.',
        required=False)

    gridStrokeColor = attr.Color(
        title='Grid Stroke Color',
        description='The color in which the grid lines are drawn.',
        required=False)

    gridStrokeDashArray = attr.Sequence(
        title='Grid Stroke Dash Array',
        description='The dash array that is used for the grid lines.',
        value_type=attr.Float(),
        required=False)

    gridStart = attr.Measurement(
        title='Grid Start',
        description=('The start of the grid lines with respect to the '
                     'axis origin.'),
        required=False)

    gridEnd = attr.Measurement(
        title='Grid End',
        description=('The end of the grid lines with respect to the '
                     'axis origin.'),
        required=False)

    style = attr.Choice(title='Style',
                        description='The plot style of the common categories.',
                        choices=('parallel', 'stacked', 'parallel_3d'),
                        required=False)
Ejemplo n.º 29
0
class IStroke(interfaces.IRMLDirectiveSignature):
    """Set the stroke/line color."""

    color = attr.Color(title=u'Color',
                       description=(u'The color value to be set.'),
                       required=True)
Ejemplo n.º 30
0
class IChart(interfaces.IRMLDirectiveSignature):
    occurence.containing(occurence.ZeroOrOne('texts', ITexts), )

    # Drawing Options

    dx = attr.Measurement(
        title='Drawing X-Position',
        description='The x-position of the entire drawing on the canvas.',
        required=False)

    dy = attr.Measurement(
        title='Drawing Y-Position',
        description='The y-position of the entire drawing on the canvas.',
        required=False)

    dwidth = attr.Measurement(title='Drawing Width',
                              description='The width of the entire drawing',
                              required=False)

    dheight = attr.Measurement(title='Drawing Height',
                               description='The height of the entire drawing',
                               required=False)

    angle = attr.Float(
        title='Angle',
        description='The orientation of the drawing as an angle in degrees.',
        required=False)

    # Plot Area Options

    x = attr.Measurement(
        title='Chart X-Position',
        description='The x-position of the chart within the drawing.',
        required=False)

    y = attr.Measurement(
        title='Chart Y-Position',
        description='The y-position of the chart within the drawing.',
        required=False)

    width = attr.Measurement(title='Chart Width',
                             description='The width of the chart.',
                             required=False)

    height = attr.Measurement(title='Chart Height',
                              description='The height of the chart.',
                              required=False)

    strokeColor = attr.Color(title='Stroke Color',
                             description='Color of the chart border.',
                             required=False)

    strokeWidth = attr.Measurement(title='Stroke Width',
                                   description='Width of the chart border.',
                                   required=False)

    fillColor = attr.Color(title='Fill Color',
                           description='Color of the chart interior.',
                           required=False)

    debug = attr.Boolean(
        title='Debugging',
        description='A flag that when set to True turns on debug messages.',
        required=False)