org.eclipse.swt.widgets.TableColumn.getAlignment()方法的使用及代码示例

x33g5p2x  于2022-01-29 转载在 其他  
字(2.9k)|赞(0)|评价(0)|浏览(147)

本文整理了Java中org.eclipse.swt.widgets.TableColumn.getAlignment()方法的一些代码示例,展示了TableColumn.getAlignment()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。TableColumn.getAlignment()方法的具体详情如下:
包路径:org.eclipse.swt.widgets.TableColumn
类名称:TableColumn
方法名:getAlignment

TableColumn.getAlignment介绍

[英]Returns a value which describes the position of the text or image in the receiver. The value will be one of LEFT, RIGHT or CENTER.
[中]返回一个值,该值描述文本或图像在接收器中的位置。该值将是LEFTRIGHTCENTER中的一个。

代码示例

代码示例来源:origin: org.eclipse.rap/org.eclipse.rap.rwt

  1. private static String getAlignment( TableColumn column ) {
  2. int alignment = column.getAlignment();
  3. String result = "left";
  4. if( ( alignment & SWT.CENTER ) != 0 ) {
  5. result = "center";
  6. } else if( ( alignment & SWT.RIGHT ) != 0 ) {
  7. result = "right";
  8. }
  9. return result;
  10. }

代码示例来源:origin: org.eclipse.rap/org.eclipse.rap.rwt.q07

  1. public static boolean hasAlignmentChanged( final TableColumn column ) {
  2. return WidgetLCAUtil.hasChanged( column,
  3. PROP_ALIGNMENT,
  4. new Integer( column.getAlignment() ),
  5. DEFAULT_ALIGNMENT );
  6. }

代码示例来源:origin: org.eclipse.rap/org.eclipse.rap.rwt.q07

  1. public static void preserveAlignment( final TableColumn column ) {
  2. IWidgetAdapter adapter = WidgetUtil.getAdapter( column );
  3. adapter.preserve( PROP_ALIGNMENT, new Integer( column.getAlignment() ) );
  4. }

代码示例来源:origin: org.eclipse.rap/org.eclipse.rap.rwt.q07

  1. private static void writeAlignment( final TableColumn column )
  2. throws IOException
  3. {
  4. JSWriter writer = JSWriter.getWriterFor( column );
  5. if( TableLCAUtil.hasAlignmentChanged( column ) ) {
  6. Integer newValue = new Integer( column.getAlignment() );
  7. JSVar alignment = JSConst.QX_CONST_ALIGN_LEFT;
  8. if( newValue.intValue() == SWT.CENTER ) {
  9. alignment = JSConst.QX_CONST_ALIGN_CENTER;
  10. } else if( newValue.intValue() == SWT.RIGHT ) {
  11. alignment = JSConst.QX_CONST_ALIGN_RIGHT;
  12. }
  13. writer.set( "horizontalChildrenAlign", new Object[] { alignment } );
  14. }
  15. }

代码示例来源:origin: org.eclipse.scout.sdk.deps/org.eclipse.swt.win32.win32.x86

  1. x += 2;
  2. } else {
  3. int alignmnent = column.getAlignment();
  4. switch (alignmnent) {
  5. case SWT.LEFT:
  6. x += 5;
  7. } else {
  8. int alignmnent = column.getAlignment();
  9. switch (alignmnent) {
  10. case SWT.LEFT:

代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.aix.ppc

  1. x += 2;
  2. } else {
  3. int alignmnent = column.getAlignment();
  4. switch (alignmnent) {
  5. case SWT.LEFT:
  6. x += 5;
  7. } else {
  8. int alignmnent = column.getAlignment();
  9. switch (alignmnent) {
  10. case SWT.LEFT:

代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.linux.ppc

  1. x += 2;
  2. } else {
  3. int alignmnent = column.getAlignment();
  4. switch (alignmnent) {
  5. case SWT.LEFT:
  6. x += 5;
  7. } else {
  8. int alignmnent = column.getAlignment();
  9. switch (alignmnent) {
  10. case SWT.LEFT:

代码示例来源:origin: org.eclipse.swt.cocoa.macosx/x86_64

  1. x += 2;
  2. } else {
  3. int alignmnent = column.getAlignment();
  4. switch (alignmnent) {
  5. case SWT.LEFT:
  6. x += 5;
  7. } else {
  8. int alignmnent = column.getAlignment();
  9. switch (alignmnent) {
  10. case SWT.LEFT:

代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.linux.s390x

  1. x += 2;
  2. } else {
  3. int alignmnent = column.getAlignment();
  4. switch (alignmnent) {
  5. case SWT.LEFT:
  6. x += 5;
  7. } else {
  8. int alignmnent = column.getAlignment();
  9. switch (alignmnent) {
  10. case SWT.LEFT:

相关文章