mlreportgen.dom.ColSep class

Package: mlreportgen.dom
Superclasses:

Draw lines between table columns

Description

Draw lines between table columns.

Construction

colSepObj = ColSep() creates unspecified column separators.

colSepObj = ColSep(style) creates a column separator of the specified style.

colSepObj = ColSep(style,color) creates a column separator having the specified style and color.

colSepObj = ColSep(style,color,width) creates a column separator having the specified style, color, and width.

Input Arguments

expand all

Style of the table column separator, specified as one of these values.

ValueApplies To
DOCXHTML and PDF
'dashed'
'dashdotstroked' 
'dashsmallgap' 
'dotted'
'dotdash' 
'dotdotdash' 
'double'
'doublewave' 
'inset'
'none'
'outset'
'single' 
'solid' 
'thick' 
'thickthinlargegap' 
'thickthinmediumgap' 
'thickthinsmallgap' 
'thinthicklargegap' 
'thinthickmediumgap' 
'thinthicksmallgap' 
'thinthickthinlargegap' 
'thinthickthinmediumgap' 
'thinthickthinsmallgap' 
'threedemboss' 
'threedengrave' 
'triple' 
'wave' 

You can specify:

Color of the table column separator, in the format valueUnits. Units is an abbreviation for the units. Valid abbreviations are:

  • px — pixels (default)

  • cm — centimeters

  • in — inches

  • mm — millimeters

  • pc — picas

  • pt — points

Output Arguments

expand all

Column separator definition, represented by an mlreportgen.dom.ColSpec object.

Properties

expand all

You can specify:

ID for this document element, specified as a character vector or string scalar. The DOM generates a session-unique ID when it creates the document element. You can specify your own ID.

Array of format objects (such as Bold objects) that specify the format for the separator.

This property overrides corresponding formats defined by the style sheet style specified by the StyleName property.

Tag for this document element, specified as a character vector or string scalar.

The DOM generates a session-unique tag as part of the creation of this object. The generated tag has the form CLASS:ID, where CLASS is the object class and ID is the value of the Id property of the object. Specifying your own tag value can help you to identify where an issue occurred during document generation.

Separator width as a percentage, for example, '100%', or a number of units of measurement in the form valueUnits. Units is an abbreviation for the units. Use one of these abbreviations for the units of a width.

  • px — pixels (default)

  • cm — centimeters

  • in — inches

  • mm — millimeters

  • pc — picas

  • pt — points

Data Types: char

Examples

collapse all

This example creates table and sets the border, column separator, and row separator styles. The TableEntriesStyle property formats the table entries.

import mlreportgen.dom.*;
doctype = 'html';
d = Document('test',doctype);
t = Table(magic(5));

t.Style = { ...
    RowHeight('0.75in'), ...
    Border('solid','Green','6pt'), ...
    ColSep('double','DarkGreen','3pt'), ...
    RowSep('single','DarkGreen')};

t.TableEntriesStyle = { ...
    Width('0.75in'), ...
    InnerMargin('0'), ...
    OuterMargin('0'), ...
    HAlign('center'), ...
    VAlign('middle') };
    
append(d,t);
close(d);
rptview(d.OutputPath);