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

x33g5p2x  于2022-01-18 转载在 其他  
字(6.1k)|赞(0)|评价(0)|浏览(135)

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

Canvas.isVisible介绍

暂无

代码示例

代码示例来源:origin: BiglySoftware/BiglyBT

@Override
  public void handleEvent(Event e) {
    if (refreshInfoCanvasQueued || !peerInfoCanvas.isVisible()) {
      return;
    }
    // wrap in asyncexec because sc.setMinWidth (called later) doesn't work
    // too well inside a resize (the canvas won't size isn't always updated)
    Utils.execSWTThreadLater(100, new AERunnable() {
      @Override
      public void runSupport() {
        if (refreshInfoCanvasQueued) {
          return;
        }
        refreshInfoCanvasQueued = true;
        if (img != null) {
          int iOldColCount = img.getBounds().width / BLOCK_SIZE;
          int iNewColCount = peerInfoCanvas.getClientArea().width / BLOCK_SIZE;
          if (iOldColCount != iNewColCount)
            refreshInfoCanvas();
        }
      }
    });
  }
});

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

/**
 * Returns <code>true</code> if the receiver is visible and all
 * of the receiver's ancestors are visible and <code>false</code>
 * otherwise.
 *
 * @return the receiver's visibility state
 *
 * @exception SWTException <ul>
 *    <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li>
 *    <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li>
 * </ul>
 *
 * @see #getVisible
 */
public boolean isVisible () {
  checkWidget();
  return isVisible && parent.isVisible () && parent.hasFocus ();
}

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

/**
 * Returns <code>true</code> if the receiver is visible and all
 * of the receiver's ancestors are visible and <code>false</code>
 * otherwise.
 *
 * @return the receiver's visibility state
 *
 * @exception SWTException <ul>
 *    <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li>
 *    <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li>
 * </ul>
 *
 * @see #getVisible
 */
public boolean isVisible () {
  checkWidget();
  return isVisible && parent.isVisible () && parent.hasFocus ();
}

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

/**
 * Returns <code>true</code> if the receiver is visible and all
 * of the receiver's ancestors are visible and <code>false</code>
 * otherwise.
 *
 * @return the receiver's visibility state
 *
 * @exception SWTException <ul>
 *    <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li>
 *    <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li>
 * </ul>
 *
 * @see #getVisible
 */
public boolean isVisible () {
  checkWidget();
  return isVisible && parent.isVisible () && hasFocus ();
}

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

/**
 * Returns <code>true</code> if the receiver is visible and all
 * of the receiver's ancestors are visible and <code>false</code>
 * otherwise.
 *
 * @return the receiver's visibility state
 *
 * @exception SWTException <ul>
 *    <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li>
 *    <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li>
 * </ul>
 *
 * @see #getVisible
 */
public boolean isVisible () {
  checkWidget();
  return isVisible && parent.isVisible () && parent.hasFocus ();
}

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

/**
 * Returns <code>true</code> if the receiver is visible and all
 * of the receiver's ancestors are visible and <code>false</code>
 * otherwise.
 *
 * @return the receiver's visibility state
 *
 * @exception SWTException <ul>
 *    <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li>
 *    <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li>
 * </ul>
 *
 * @see #getVisible
 */
public boolean isVisible () {
  checkWidget();
  return isVisible && parent.isVisible () && parent.hasFocus ();
}

代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.examples

horizontalOffset = selection;
redraw ();
if (header.isVisible () && drawCount <= 0) header.redraw ();

代码示例来源:origin: BiglySoftware/BiglyBT

boolean sizeChanged)
if ( drawCanvas == null || drawCanvas.isDisposed() || !drawCanvas.isVisible()){

代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.examples

void onScrollHorizontal (Event event) {
  ScrollBar hBar = getHorizontalBar ();
  if (hBar == null) return;
  int newSelection = hBar.getSelection ();
  update ();
  if (itemsCount > 0) {
    GC gc = new GC (this);
    gc.copyArea (
      0, 0,
      clientArea.width, clientArea.height,
      horizontalOffset - newSelection, 0);
    gc.dispose ();
  } else {
    redraw ();    /* ensure that static focus rectangle updates properly */
  }

  if (drawCount <= 0 && header.isVisible ()) {
    header.update ();
    Rectangle headerClientArea = header.getClientArea ();
    GC gc = new GC (header);
    gc.copyArea (
      0, 0,
      headerClientArea.width, headerClientArea.height,
      horizontalOffset - newSelection, 0);
    gc.dispose ();
  }
  horizontalOffset = newSelection;
}
void onScrollVertical (Event event) {

代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.examples

if (hBar != null) hBar.setSelection (horizontalOffset);
redraw ();
if (drawCount <= 0 && header.isVisible ()) header.redraw ();

代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.examples

if (drawCount <= 0 && header.isVisible ()) header.redraw ();

代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.examples

if (drawCount <= 0 && header.isVisible ()) header.redraw ();

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

if (!isVisible ()) return;
boolean isFocus = caret != null && caret.isFocusCaret ();
if (isFocus) caret.killFocus ();

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

if (!isVisible ()) return;
boolean isFocus = caret != null && caret.isFocusCaret ();
if (isFocus) caret.killFocus ();

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

if (!isVisible ()) return;
boolean isFocus = caret != null && caret.isFocusCaret ();
if (isFocus) caret.killFocus ();

代码示例来源:origin: BiglySoftware/BiglyBT

protected void drawScale(boolean sizeChanged) {
 if(drawCanvas == null || drawCanvas.isDisposed() || !drawCanvas.isVisible())
  return;

代码示例来源:origin: BiglySoftware/BiglyBT

protected void drawChart(boolean sizeChanged) {
   if (drawCanvas == null || drawCanvas.isDisposed() || !drawCanvas.isVisible())

代码示例来源:origin: BiglySoftware/BiglyBT

|| !pieceInfoCanvas.isVisible()) {
return( result );

相关文章

Canvas类方法