Java Doc for CellData.java in  » IDE-Eclipse » ui-workbench » org » eclipse » ui » internal » layout » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » IDE Eclipse » ui workbench » org.eclipse.ui.internal.layout 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   org.eclipse.ui.internal.layout.CellData

CellData
final public class CellData (Code)
CellData is the layout data object associated with CellLayout. You can attach a CellData object to a control by using the setLayoutData method. CellData objects are optional. If you do not attach any layout data to a control, it will behave just like attaching a CellData created using its default constructor.
since:
   3.0


Field Summary
final public static  intMAXIMUM
     hintType flag (value = 3) indicating that the width of the control should be no more than widthHint (if provided) and the height of the control should be no more than heightHint (if provided).
final public static  intMINIMUM
     hintType(value = 2) indicating that the width of the control should be no less than widthHint (if provided) and the height of the control should be no less than heightHint (if provided).

This flag is useful for buttons.

final public static  intNONE
     hintType flag (value = 0) indicating that the control's computeSize method should be used to determine the control size.
final public static  intOVERRIDE
     hintType flag (value = 1) indicating that the widthHint and heightHint should be used as the control's size instead of the result of computeSize

This flag is useful for list boxes, text boxes, tree controls, and other controls whose contents can change dynamically.

public  intheightHint
     Height hint.
public  inthintType
     This flag controls how the width and height hints are to be treated.
public  inthorizontalAlignment
     Horizontal alignment of the control within the cell.
public  inthorizontalIndent
     Horizontal indentation (pixels).
public  inthorizontalSpan
    
public  intverticalAlignment
     Vertical alignment of the control within the cell.
public  intverticalIndent
     Vertical indentation (pixels).
public  intverticalSpan
    
public  intwidthHint
     Width hint.

Constructor Summary
public  CellData()
    
public  CellData(GridData data)
     Creates a new CellData that with properties that are as close as possible to the given GridData.
public  CellData(CellData newData)
    

Method Summary
public  CellDataalign(int horizontalAlignment, int verticalAlignment)
    
public  PointcomputeSize(SizeCache toCompute, int cellWidth, int cellHeight)
     Returns the preferred size of the given control, given the known dimensions of its cell.
public  CellDataindent(Point indent)
     Sets the indentation for this control.
public  CellDataindent(int horizontalIndent, int verticalIndent)
    
public  voidpositionControl(SizeCache cache, Rectangle cellBounds)
     Arranges the given control within the given rectangle using the criteria described by this CellData.
public  CellDatasetHint(int hintType, Point hint)
     Sets the size hint for this control.
public  CellDatasetHint(int hintType, int horizontal, int vertical)
     Sets the size hint for this control.
public  CellDataspan(int horizontalSpan, int verticalSpan)
     Sets the number of rows and columns spanned by this control.

Field Detail
MAXIMUM
final public static int MAXIMUM(Code)
hintType flag (value = 3) indicating that the width of the control should be no more than widthHint (if provided) and the height of the control should be no more than heightHint (if provided).

This flag is useful for wrapping text. For example, set heightHint to SWT.DEFAULT and set widthHint to the desired number of pixels after which text should wrap. This will cause the text to wrap after the given number of pixels, but will not allocate extra space in the column if the text widget does not fill an entire line.




MINIMUM
final public static int MINIMUM(Code)
hintType(value = 2) indicating that the width of the control should be no less than widthHint (if provided) and the height of the control should be no less than heightHint (if provided).

This flag is useful for buttons. For example, set the width and height hints to the default button size. This will use the default button size unless the button label is too large to fit on the button.




NONE
final public static int NONE(Code)
hintType flag (value = 0) indicating that the control's computeSize method should be used to determine the control size. If modifierType is set to NONE, then the widthHint and heightHint fields will be ignored.



OVERRIDE
final public static int OVERRIDE(Code)
hintType flag (value = 1) indicating that the widthHint and heightHint should be used as the control's size instead of the result of computeSize

This flag is useful for list boxes, text boxes, tree controls, and other controls whose contents can change dynamically. For example, create a tree control and set its width and height hints to the default size for that control. This will cause the hints to be used instead of the preferred size of the tree control.




heightHint
public int heightHint(Code)
Height hint. This modifies the height of the control, in pixels. If set to SWT.DEFAULT, this dimension will not be constrained. Depending on the value of modifierType, this will be a minimum size, a maximum size, or a replacement for the control's preferred size.



hintType
public int hintType(Code)
This flag controls how the width and height hints are to be treated. See the constants above.



horizontalAlignment
public int horizontalAlignment(Code)
Horizontal alignment of the control within the cell. May be one of SWT.LEFT, SWT.RIGHT, SWT.CENTER, or SWT.NORMAL. SWT.NORMAL indicates that the control should be made as wide as the cell.



horizontalIndent
public int horizontalIndent(Code)
Horizontal indentation (pixels). Positive values move the control to the right, negative to the left.



horizontalSpan
public int horizontalSpan(Code)
Number of columns spanned by this cell (default = 1)



verticalAlignment
public int verticalAlignment(Code)
Vertical alignment of the control within the cell. May be one of SWT.TOP, SWT.BOTTOM, SWT.CENTER, or SWT.NORMAL. SWT.NORMAL indicates that the control should be made as wide as the cell.



verticalIndent
public int verticalIndent(Code)
Vertical indentation (pixels). Positive values move the control down, negative values move the control up.



verticalSpan
public int verticalSpan(Code)
Number of rows spanned by this cell (default = 1)



widthHint
public int widthHint(Code)
Width hint. This modifies the width of the control, in pixels. If set to SWT.DEFAULT, this dimension will not be constrained. Depending on the value of modifierType, this may be a minimum size, a maximum size, or simply replace the preferred control size.




Constructor Detail
CellData
public CellData()(Code)
Constructs a CellData with default properties



CellData
public CellData(GridData data)(Code)
Creates a new CellData that with properties that are as close as possible to the given GridData. This is used for converting GridLayouts into CellLayouts.
Parameters:
  data -



CellData
public CellData(CellData newData)(Code)
Copies the given CellData
Parameters:
  newData -




Method Detail
align
public CellData align(int horizontalAlignment, int verticalAlignment)(Code)
Sets the alignment for this control
Parameters:
  horizontalAlignment - one of SWT.LEFT, SWT.RIGHT, SWT.FILL, or SWT.CENTER
Parameters:
  verticalAlignment - one of SWT.TOP, SWT.BOTTOM, SWT.FILL, or SWT.CENTER this



computeSize
public Point computeSize(SizeCache toCompute, int cellWidth, int cellHeight)(Code)
Returns the preferred size of the given control, given the known dimensions of its cell.
Parameters:
  toCompute - the control whose size is to be computed
Parameters:
  cellWidth - width of the cell, in pixels (or SWT.DEFAULT if unknown)
Parameters:
  cellHeight - height of the cell, in pixels (or SWT.DEFAULT if unknown) the preferred size of the given control, in pixels



indent
public CellData indent(Point indent)(Code)
Sets the indentation for this control. The indentation is added to the control's position within the cell. For example, indentation of (10,4) will move the control right by 10 pixels and down by 4 pixels.
Parameters:
  indent - indentation (pixels) this



indent
public CellData indent(int horizontalIndent, int verticalIndent)(Code)
Sets the indentation for this cell
Parameters:
  horizontalIndent - distance (pixels) to move the control to the right
Parameters:
  verticalIndent - distance (pixels) to move the control down this



positionControl
public void positionControl(SizeCache cache, Rectangle cellBounds)(Code)
Arranges the given control within the given rectangle using the criteria described by this CellData.
Parameters:
  control -
Parameters:
  cellBounds -
since:
   3.0



setHint
public CellData setHint(int hintType, Point hint)(Code)
Sets the size hint for this control. This is used to modify the control's preferred size. If one dimension should remain unmodified, that hint can be set to SWT.DEFAULT. Using a size hint of CellData.MINIMUM ensures that the preferred control size is larger than the hint. Using a size hint of CellData.MAXIMUM ensures that the preferred size is smaller than the hint. Using a size hint of CellData.OVERRIDE ensures that the preferred size is always equal to the hint.
Parameters:
  hintType - one of CellData.MINIMUM, CellData.MAXIMUM, or CellData.OVERRIDE
Parameters:
  hint - size hint (in pixels). If either dimension is set to SWT.DEFAULT, thehint will not affect that dimension this



setHint
public CellData setHint(int hintType, int horizontal, int vertical)(Code)
Sets the size hint for this control. This is used to modify the control's preferred size. If one dimension should remain unmodified, that hint can be set to SWT.DEFAULT. Using a size hint of CellData.MINIMUM ensures that the preferred control size is larger than the hint. Using a size hint of CellData.MAXIMUM ensures that the preferred size is smaller than the hint. Using a size hint of CellData.OVERRIDE ensures that the preferred size is always equal to the hint. If both hints are equal to SWT.DEFAULT, then the control's preferred size is unmodified.
Parameters:
  hintType - one of CellData.MINIMUM, CellData.MAXIMUM, or CellData.OVERRIDE
Parameters:
  horizontal - horizontal hint (pixels). A value of SWT.DEFAULT will leave the resultof the control's computeSize method unmodified.
Parameters:
  vertical - vertical hint (pixels). A value of SWT.DEFAULT will leave the result of the control's computeSize method unmodified. this



span
public CellData span(int horizontalSpan, int verticalSpan)(Code)
Sets the number of rows and columns spanned by this control.
Parameters:
  horizontalSpan - number of columns spanned by the control (> 0)
Parameters:
  verticalSpan - number of rows spanned by the control (> 0) this



Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.