Available Methods
- NONE
- BORDER
- V_SCROLL
- PUSH
- CHECK
- LEFT
- MULTI
- SINGLE
- READ_ONLY
- OK
- H_SCROLL
- FILL
- CENTER
- WRAP
- error ( )
- ICON_ERROR
- RIGHT
- NULL
- HORIZONTAL
- FULL_SELECTION
- BOLD
- SEPARATOR
- DEFAULT
- RADIO
- RESIZE
- FLAT
- VERTICAL
- TOP
- DROP_DOWN
- ITALIC
- NORMAL
- SAVE
- ICON_INFORMATION
- CTRL
- SHIFT
- NO_FOCUS
- APPLICATION_MODAL
- DIALOG_TRIM
- DOUBLE_BUFFERED
- OPEN
- CR
- ARROW_DOWN
- Selection ( )
- YES
- CANCEL
- BOTTOM
- NO_BACKGROUND
- NO
- CLOSE
- ICON_WARNING
- RIGHT_TO_LEFT
- LEFT_TO_RIGHT
- TOGGLE
- SHEET
- DOWN
- BEGINNING
- MAX
- ARROW_LEFT
- ARROW_RIGHT
- NO_TRIM
- END
- ON_TOP
- MIN
- ARROW_UP
- KeyDown ( )
- KeyUp ( )
- ICON_QUESTION
- Dispose ( )
- ALT
- CASCADE
- VIRTUAL
- SHADOW_ETCHED_IN
- PAGE_UP
- DEL
- FocusOut ( )
- Traverse ( )
- PASSWORD
- SHELL_TRIM
- ARROW
- Deactivate ( )
- BS
- FocusIn ( )
- ESC
- LEAD
- MouseUp ( )
- SMOOTH
- MouseDoubleClick ( )
- TRAVERSE_TAB_NEXT
- UP
- MouseDown ( )
- TITLE
- Paint ( )
- PAGE_DOWN
- Move ( )
- HOME
- SHADOW_IN
- TRAVERSE_TAB_PREVIOUS
- F2 ( )
- LINE_SOLID
- HIDE_SELECTION
- JOIN_BEVEL
- SHADOW_NONE
- Modify ( )
- BAR
- SEARCH
- COMMAND
- LINE_DASHDOT
- ICON_SEARCH
- TAB
- SHADOW_OUT
- LINE_DASH
- KEYPAD_CR
- LINE_DOT
- JOIN_ROUND
- MOD1 ( )
- TOOL
- MODIFIER_MASK
- CURSOR_ARROW
- IMAGE_GIF
- LF
- MouseEnter ( )
- MouseMove ( )
- TRAVERSE_ARROW_PREVIOUS
- UNDERLINE_LINK
- MODELESS
- CURSOR_HAND
- IMAGE_JPEG
- MouseHover ( )
- CURSOR_WAIT
- getPlatform ( )
- IMAGE_BMP
- PRIMARY_MODAL
- CAP_FLAT
- UNDERLINE_ERROR
- POP_UP
- CAP_ROUND
- SIMPLE
- DATE
- EraseItem ( )
- TRANSPARENT
- TIME
- CAP_SQUARE
- COLOR_DARK_GREEN
- FOREGROUND
- INHERIT_DEFAULT
- KEYPAD_SUBTRACT
- TRAVERSE_ARROW_NEXT
- Help ( )
- LINE_DASHDOTDOT
- TRAVERSE_ESCAPE
- MouseExit ( )
- JOIN_MITER
- NO_SCROLL
- Collapse ( )
- F9 ( )
- FILL_WINDING
- HIGH
- ERROR_NULL_ARGUMENT
- BORDER_DOT
- CAPS_LOCK
- ICON_CANCEL
- KEYPAD_4 ( )
- PATH_MOVE_TO
- MOD2 ( )
- INDETERMINATE
- NO_REDRAW_RESIZE
- INSERT
- DefaultSelection ( )
- SYSTEM_MODAL
- IMAGE_COPY
- CALENDAR
- BACKGROUND
- MOD4 ( )
Related Classes
- java.io.File
- org.eclipse.swt.widgets.Composite
- org.eclipse.swt.widgets.Display
- org.eclipse.swt.widgets.Button
- org.eclipse.swt.widgets.Label
- org.eclipse.swt.widgets.Shell
- org.eclipse.swt.layout.GridData
- org.eclipse.swt.widgets.Text
- org.eclipse.swt.layout.GridLayout
- org.eclipse.swt.events.SelectionEvent
- org.eclipse.swt.events.SelectionAdapter
- org.eclipse.swt.widgets.Control
- org.eclipse.swt.graphics.Image
- org.eclipse.swt.widgets.Group
- org.eclipse.swt.widgets.Event
- org.eclipse.swt.graphics.Point
- org.eclipse.swt.graphics.Color
- org.eclipse.ui.PlatformUI
- org.eclipse.swt.widgets.Listener
- org.eclipse.swt.events.SelectionListener
- org.eclipse.swt.events.ModifyListener
- org.eclipse.swt.widgets.Combo
- org.eclipse.swt.widgets.FileDialog
- org.eclipse.swt.events.ModifyEvent
- org.eclipse.jface.viewers.IStructuredSelection
Java Code Examples for org.eclipse.swt.SWT#COLOR_DARK_GREEN
The following examples show how to use
org.eclipse.swt.SWT#COLOR_DARK_GREEN .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: XpectConsole.java From n4js with Eclipse Public License 1.0 | 5 votes |
private MessageConsoleStream getNewMessageConsoleStream(int msgKind) { int swtColorId = SWT.COLOR_BLACK; switch (msgKind) { case MSG_LOG: swtColorId = SWT.COLOR_BLACK; break; case MSG_INFORMATION: swtColorId = SWT.COLOR_DARK_GRAY; break; case MSG_ERROR: swtColorId = SWT.COLOR_DARK_MAGENTA; break; case MSG_WARNING: swtColorId = SWT.COLOR_DARK_YELLOW; break; case MSG_SUCCESS: swtColorId = SWT.COLOR_DARK_GREEN; break; default: swtColorId = SWT.COLOR_BLACK; break; } MessageConsoleStream msgConsoleStream = messageConsole.newMessageStream(); msgConsoleStream.setColor(Display.getCurrent().getSystemColor(swtColorId)); return msgConsoleStream; }
Example 2
Source File: CubicCurveDeCasteljauExample.java From gef with Eclipse Public License 2.0 | 4 votes |
@Override protected ControllableShape[] getControllableShapes() { return new ControllableShape[] { new ControllableShape() { { /* * These are the control points used to construct the CubicCurve * later. */ addControlPoints(new Point(100, 200), new Point(200, 100), new Point(300, 300), new Point(400, 200)); } @Override public CubicCurve getShape() { /* * Constructs the CubicCurve of the defined control points. */ return new CubicCurve(getPoints()); } @Override public void onDraw(GC gc) { /* * Draws the CubicCurve and the de Casteljau construction for * the current parameter value. */ // Construct the CubicCurve from the defined control points. CubicCurve curve = getShape(); // Draw the CubicCurve as an SWT Path. gc.drawPath( new org.eclipse.swt.graphics.Path(Display.getCurrent(), Geometry2SWT.toSWTPathData(curve.toPath()))); /* * Retrieve control points to compute the linear interpolations * of the de Casteljau algorithm. */ Point[] points = getPoints(); /* * Define the colors for the intermediate lines. We have three * stages and therefore three different colors for a cubic * Bezier curve. This is the case, because the de Casteljau * algorithm reduces the number of control points in each * iteration until it reaches the actual point on the curve. */ int[] colors = new int[] { SWT.COLOR_DARK_GREEN, SWT.COLOR_BLUE, SWT.COLOR_DARK_RED }; for (int ci = 0; ci < colors.length; ci++) { for (int i = 0; i < 3 - ci; i++) { // set line color gc.setForeground(Display.getCurrent() .getSystemColor(colors[ci])); // draw line gc.drawLine((int) points[i].x, (int) points[i].y, (int) points[i + 1].x, (int) points[i + 1].y); // interpolate point for the next iteration points[i] = new Line(points[i], points[i + 1]) .get(parameterValue); // set color to black gc.setForeground(Display.getCurrent() .getSystemColor(SWT.COLOR_BLACK)); // draw point gc.drawOval((int) (points[i].x - 2), (int) (points[i].y - 2), 4, 4); } } } } }; }