Eclipse Remote Application Platform

org.eclipse.swt.graphics
Class LineAttributes

java.lang.Object
  extended by org.eclipse.swt.graphics.LineAttributes

public class LineAttributes
extends java.lang.Object

LineAttributes defines a set of line attributes that can be modified in a GC.

Application code does not need to explicitly release the resources managed by each instance when those instances are no longer required, and thus no dispose() method is provided.

Since:
1.3
See Also:
GC.getLineAttributes(), GC.setLineAttributes(LineAttributes), Sample code and further information

Field Summary
 int cap
          The line cap style.
 int join
          The line join style.
 float width
          The line width.
 
Constructor Summary
LineAttributes(float width)
          Create a new line attributes with the specified line width.
LineAttributes(float width, int cap, int join)
          Create a new line attributes with the specified line cap, join and width.
 
Method Summary
 boolean equals(java.lang.Object object)
          Compares the argument to the receiver, and returns true if they represent the same object using a class specific comparison.
 int hashCode()
          Returns an integer hash code for the receiver.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

width

public float width
The line width.


cap

public int cap
The line cap style.

See Also:
SWT.CAP_FLAT, SWT.CAP_ROUND, SWT.CAP_SQUARE

join

public int join
The line join style.

See Also:
SWT.JOIN_BEVEL, SWT.JOIN_MITER, SWT.JOIN_ROUND
Constructor Detail

LineAttributes

public LineAttributes(float width)
Create a new line attributes with the specified line width.

Parameters:
width - the line width

LineAttributes

public LineAttributes(float width,
                      int cap,
                      int join)
Create a new line attributes with the specified line cap, join and width.

Parameters:
width - the line width
cap - the line cap style
join - the line join style
Method Detail

equals

public boolean equals(java.lang.Object object)
Compares the argument to the receiver, and returns true if they represent the same object using a class specific comparison.

Overrides:
equals in class java.lang.Object
Parameters:
object - the object to compare with this object
Returns:
true if the object is the same as this object and false otherwise
Since:
1.4
See Also:
hashCode()

hashCode

public int hashCode()
Returns an integer hash code for the receiver. Any two objects that return true when passed to equals must return the same value for this method.

Overrides:
hashCode in class java.lang.Object
Returns:
the receiver's hash
Since:
1.4
See Also:
equals(Object)

Eclipse Remote Application Platform

Copyright (c) EclipseSource and others 2002, 2013. All rights reserved. This program and the accompanying materials are made available under the terms of the Eclipse Public License v1.0