Mega Code Archive

 
Categories / Java Tutorial / SWT
 

Creating a StyledText Widget

StyledText(Composite parent,  int style) StyledText Styles ConstantDescription SWT.BORDERDraws a border around the StyledText. SWT.SINGLECreates a single-line StyledText. SWT.MULTICreates a multiline StyledText. This is the default. SWT.H_SCROLLEnables horizontal scrolling. SWT.V_SCROLLEnables vertical scrolling. SWT.WRAPTurns on word wrapping, trumping the horizontal scrolling style. SWT.READ_ONLYMakes the StyledText read-only. SWT.FULL_SELECTIONCauses redrawing operations to redraw the full line instead of only the invalidated portion.