com.aspose.words
Class ShapeLineStyle

java.lang.Object
    extended by com.aspose.words.ShapeLineStyle

public class ShapeLineStyle 
extends java.lang.Object

Utility class containing constants. Specifies the compound line style of a Shape.

Example:

Shows how change stroke properties.
Document doc = new Document();
DocumentBuilder builder = new DocumentBuilder(doc);

Shape shape = builder.insertShape(ShapeType.RECTANGLE, RelativeHorizontalPosition.LEFT_MARGIN, 100.0,
        RelativeVerticalPosition.TOP_MARGIN, 100.0, 200.0, 200.0, WrapType.NONE);

// Basic shapes, such as the rectangle, have two visible parts.
// 1 -  The fill, which applies to the area within the outline of the shape:
shape.getFill().setForeColor(Color.WHITE);

// 2 -  The stroke, which marks the outline of the shape:
// Modify various properties of this shape's stroke.
Stroke stroke = shape.getStroke();
stroke.setOn(true);
stroke.setWeight(5.0);
stroke.setColor(Color.RED);
stroke.setDashStyle(DashStyle.SHORT_DASH_DOT_DOT);
stroke.setJoinStyle(JoinStyle.MITER);
stroke.setEndCap(EndCap.SQUARE);
stroke.setLineStyle(ShapeLineStyle.TRIPLE);

doc.save(getArtifactsDir() + "Shape.Stroke.docx");
See Also:
Stroke.LineStyle

Field Summary
static final intSINGLE = 0
           Single line.
static final intDOUBLE = 1
           Double lines of equal width.
static final intTHICK_THIN = 2
           Double lines, one thick, one thin.
static final intTHIN_THICK = 3
           Double lines, one thin, one thick.
static final intTRIPLE = 4
           Three lines, thin, thick, thin.
static final intDEFAULT = 0
           Default value is SINGLE.
 

Field Detail

SINGLE = 0

public static final int SINGLE
Single line.

DOUBLE = 1

public static final int DOUBLE
Double lines of equal width.

THICK_THIN = 2

public static final int THICK_THIN
Double lines, one thick, one thin.

THIN_THICK = 3

public static final int THIN_THICK
Double lines, one thin, one thick.

TRIPLE = 4

public static final int TRIPLE
Three lines, thin, thick, thin.

DEFAULT = 0

public static final int DEFAULT
Default value is SINGLE.

See Also:
          Aspose.Words Documentation - the home page for the Aspose.Words Product Documentation.
          Aspose.Words Support Forum - our preferred method of support.