congrats Icon
New! Tabnine Pro 14-day free trial
Start a free trial
Tabnine Logo
Font.equals
Code IndexAdd Tabnine to your IDE (free)

How to use
equals
method
in
org.eclipse.swt.graphics.Font

Best Java code snippets using org.eclipse.swt.graphics.Font.equals (Showing top 20 results out of 315)

origin: org.eclipse.scout.sdk.deps/org.eclipse.swt.win32.win32.x86

void updateFont (Font oldFont, Font newFont) {
  if (getFont ().equals (oldFont)) setFont (newFont);
}

origin: org.eclipse/org.eclipse.ui.console

/**
 * Sets the font used by this viewer.
 * 
 * @param font
 *            the font used by this viewer
 */
public void setFont(Font font) {
  StyledText styledText = getTextWidget();
  Font oldFont = styledText.getFont();
  if (oldFont == font) {
    return;
  }
  if (font == null || !(font.equals(oldFont))) {
    styledText.setFont(font);
  }
}
origin: org.eclipse.scout.sdk.deps/org.eclipse.ui.console

/**
 * Sets the font used by this viewer.
 *
 * @param font
 *            the font used by this viewer
 */
public void setFont(Font font) {
  StyledText styledText = getTextWidget();
  Font oldFont = styledText.getFont();
  if (oldFont == font) {
    return;
  }
  if (font == null || !(font.equals(oldFont))) {
    styledText.setFont(font);
  }
}
origin: org.eclipse.rap/org.eclipse.rap.rwt

@Override
void setFont( Font font ) {
 if( !this.font.equals( font ) ) {
  GCOperation operation = new SetProperty( cloneFontData( FontUtil.getData( font ) ) );
  addGCOperation( operation );
 }
 this.font = font;
}
origin: oyse/yedit

/**
 * Returns a height hint for a button control.
 * @deprecated
 * @see IDialogConstants#BUTTON_HEIGHT
 */     
@Deprecated
public static int getButtonHeigthHint(Button button) {
  if (button.getFont().equals(JFaceResources.getDefaultFont()))
    button.setFont(JFaceResources.getDialogFont());
  PixelConverter converter= new PixelConverter(button);
  return converter.convertVerticalDLUsToPixels(IDialogConstants.BUTTON_HEIGHT);
}   
origin: org.eclipse.scout.sdk.deps/org.eclipse.swt.win32.win32.x86

@Override
public void setFont(Font font) {
  checkWidget();
  if (font != null && font.equals(getFont())) return;
  super.setFont(font);
  oldFont = getFont();
  updateFolder(REDRAW);
}
@Override
origin: org.eclipse.pde/org.eclipse.pde.ui

/**
 * Returns a width hint for a button control.
 */
public static int getButtonWidthHint(Button button) {
  if (button.getFont().equals(JFaceResources.getDefaultFont()))
    button.setFont(JFaceResources.getDialogFont());
  PixelConverter converter = new PixelConverter(button);
  int widthHint = converter.convertHorizontalDLUsToPixels(IDialogConstants.BUTTON_WIDTH);
  return Math.max(widthHint, button.computeSize(SWT.DEFAULT, SWT.DEFAULT, true).x);
}
origin: org.eclipse.swt.cocoa.macosx/x86_64

public void setFont(Font font) {
  checkWidget();
  if (font != null && font.equals(getFont())) return;
  super.setFont(font);
  oldFont = getFont();
  updateFolder(REDRAW);
}
public void setForeground (Color color) {
origin: org.eclipse.platform/org.eclipse.swt.gtk.linux.s390x

@Override
public void setFont(Font font) {
  checkWidget();
  if (font != null && font.equals(getFont())) return;
  super.setFont(font);
  oldFont = getFont();
  updateFolder(REDRAW);
}
@Override
origin: org.eclipse.platform/org.eclipse.swt.gtk.linux.ppc

@Override
public void setFont(Font font) {
  checkWidget();
  if (font != null && font.equals(getFont())) return;
  super.setFont(font);
  oldFont = getFont();
  updateFolder(REDRAW);
}
@Override
origin: org.eclipse.platform/org.eclipse.swt.gtk.aix.ppc

@Override
public void setFont(Font font) {
  checkWidget();
  if (font != null && font.equals(getFont())) return;
  super.setFont(font);
  oldFont = getFont();
  updateFolder(REDRAW);
}
@Override
origin: oyse/yedit

/**
 * Returns a width hint for a button control.
 */
public static int getButtonWidthHint(Button button) {
  if (button.getFont().equals(JFaceResources.getDefaultFont()))
    button.setFont(JFaceResources.getDialogFont());
  PixelConverter converter= new PixelConverter(button);
  int widthHint= converter.convertHorizontalDLUsToPixels(IDialogConstants.BUTTON_WIDTH);
  return Math.max(widthHint, button.computeSize(SWT.DEFAULT, SWT.DEFAULT, true).x);
}
origin: org.eclipse.xtext/ui

public static int getTableHeightHint(Table table, int rows) {
  if (table.getFont().equals(JFaceResources.getDefaultFont()))
    table.setFont(JFaceResources.getDialogFont());
  int result = table.getItemHeight() * rows + table.getHeaderHeight();
  if (table.getLinesVisible())
    result += table.getGridLineWidth() * (rows - 1);
  return result;
}
origin: org.eclipse.scout.sdk.deps/org.eclipse.jdt.ui

public static int getTableHeightHint(Table table, int rows) {
  if (table.getFont().equals(JFaceResources.getDefaultFont()))
    table.setFont(JFaceResources.getDialogFont());
  int result= table.getItemHeight() * rows + table.getHeaderHeight();
  if (table.getLinesVisible())
    result+= table.getGridLineWidth() * (rows - 1);
  return result;
}
origin: org.eclipse.jdt/org.eclipse.jdt.ui

public static int getTableHeightHint(Table table, int rows) {
  if (table.getFont().equals(JFaceResources.getDefaultFont()))
    table.setFont(JFaceResources.getDialogFont());
  int result= table.getItemHeight() * rows + table.getHeaderHeight();
  if (table.getLinesVisible())
    result+= table.getGridLineWidth() * (rows - 1);
  return result;
}
origin: org.eclipse/org.eclipse.jdt.ui

public static int getTableHeightHint(Table table, int rows) {
  if (table.getFont().equals(JFaceResources.getDefaultFont()))
    table.setFont(JFaceResources.getDialogFont());
  int result= table.getItemHeight() * rows + table.getHeaderHeight();
  if (table.getLinesVisible())
    result+= table.getGridLineWidth() * (rows - 1);
  return result;		
}

origin: org.eclipse/org.eclipse.search

public static int getTableHeightHint(Table table, int rows) {
  if (table.getFont().equals(JFaceResources.getDefaultFont()))
    table.setFont(JFaceResources.getDialogFont());
  int result= table.getItemHeight() * rows + table.getHeaderHeight();
  if (table.getLinesVisible())
    result+= table.getGridLineWidth() * (rows - 1);
  return result;		
}

origin: org.eclipse.platform/org.eclipse.search

public static int getTableHeightHint(Table table, int rows) {
  if (table.getFont().equals(JFaceResources.getDefaultFont()))
    table.setFont(JFaceResources.getDialogFont());
  int result= table.getItemHeight() * rows + table.getHeaderHeight();
  if (table.getLinesVisible())
    result+= table.getGridLineWidth() * (rows - 1);
  return result;
}
origin: oyse/yedit

public static int getTableHeightHint(Table table, int rows) {
  if (table.getFont().equals(JFaceResources.getDefaultFont()))
    table.setFont(JFaceResources.getDialogFont());
  int result= table.getItemHeight() * rows + table.getHeaderHeight();
  if (table.getLinesVisible())
    result+= table.getGridLineWidth() * (rows - 1);
  return result;      
}

origin: org.eclipse/org.eclipse.datatools.sqltools.common.ui

public static int getTableHeightHint(Table table, int rows)
{
  if (table.getFont().equals(JFaceResources.getDefaultFont()))
  {
    table.setFont(JFaceResources.getDialogFont());
  }
  int result = table.getItemHeight() * rows + table.getHeaderHeight();
  if (table.getLinesVisible())
  {
    result += table.getGridLineWidth() * (rows - 1);
  }
  return result;
}
 
org.eclipse.swt.graphicsFontequals

Javadoc

Compares the argument to the receiver, and returns true if they represent the same object using a class specific comparison.

Popular methods of Font

  • getFontData
    Returns an array of FontDatas representing the receiver. On Windows, only one FontData will be retur
  • <init>
  • dispose
  • isDisposed
    Returns true if the font has been disposed, and false otherwise. This method gets the dispose state
  • getDevice
  • hashCode
    Returns an integer hash code for the receiver. Any two objects that return true when passed toequal
  • init
  • gtk_new
    Invokes platform specific functionality to allocate a new font.IMPORTANT: This method is not part of
  • addTraits
  • checkDevice
  • cocoa_new
    Invokes platform specific functionality to allocate a new font.IMPORTANT: This method is not part of
  • findFontData
  • cocoa_new,
  • findFontData,
  • win32_new

Popular in Java

  • Running tasks concurrently on multiple threads
  • getSupportFragmentManager (FragmentActivity)
  • scheduleAtFixedRate (Timer)
  • startActivity (Activity)
  • HttpServer (com.sun.net.httpserver)
    This class implements a simple HTTP server. A HttpServer is bound to an IP address and port number a
  • SecureRandom (java.security)
    This class generates cryptographically secure pseudo-random numbers. It is best to invoke SecureRand
  • DateFormat (java.text)
    Formats or parses dates and times.This class provides factories for obtaining instances configured f
  • SimpleDateFormat (java.text)
    Formats and parses dates in a locale-sensitive manner. Formatting turns a Date into a String, and pa
  • Reference (javax.naming)
  • SAXParseException (org.xml.sax)
    Encapsulate an XML parse error or warning.> This module, both source code and documentation, is in t
  • Top 17 PhpStorm Plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyStudentsTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now