Tabnine Logo
Gutter.setLineNumbersEnabled
Code IndexAdd Tabnine to your IDE (free)

How to use
setLineNumbersEnabled
method
in
org.fife.ui.rtextarea.Gutter

Best Java code snippets using org.fife.ui.rtextarea.Gutter.setLineNumbersEnabled (Showing top 10 results out of 315)

origin: bobbylight/RSyntaxTextArea

/**
 * Toggles whether or not line numbers are visible.
 *
 * @param enabled Whether or not line numbers should be visible.
 * @see #getLineNumbersEnabled()
 */
public void setLineNumbersEnabled(boolean enabled) {
  gutter.setLineNumbersEnabled(enabled);
  checkGutterVisibility();
}
origin: bobbylight/RSyntaxTextArea

/**
 * Constructor.
 *
 * @param textArea The parent text area.
 */
public Gutter(RTextArea textArea) {
  listener = new TextAreaListener();
  lineNumberColor = Color.gray;
  lineNumberFont = RTextArea.getDefaultFont();
  lineNumberingStartIndex = 1;
  iconRowHeaderInheritsGutterBackground = false;
  setTextArea(textArea);
  setLayout(new BorderLayout());
  if (this.textArea!=null) {
    // Enable line numbers our first time through if they give us
    // a text area.
    setLineNumbersEnabled(true);
    if (this.textArea instanceof RSyntaxTextArea) {
      RSyntaxTextArea rsta = (RSyntaxTextArea)this.textArea;
      setFoldIndicatorEnabled(rsta.isCodeFoldingEnabled());
    }
  }
  setBorder(new GutterBorder(0, 0, 0, 1)); // Assume ltr
  Color bg = null;
  if (textArea!=null) {
    bg = textArea.getBackground(); // May return null if image bg
  }
  setBackground(bg!=null ? bg : Color.WHITE);
}
origin: bobbylight/RSyntaxTextArea

@Test
public void testGetLineNumbersEnabled() {
  RTextArea textArea = new RTextArea(PLAIN_TEXT);
  Gutter gutter = new Gutter(textArea);
  Assert.assertTrue(gutter.getLineNumbersEnabled());
  gutter.setLineNumbersEnabled(false);
  Assert.assertFalse(gutter.getLineNumbersEnabled());
}
origin: bobbylight/RSyntaxTextArea

@Test
public void testSetLineNumbersEnabled() {
  RTextArea textArea = new RTextArea(PLAIN_TEXT);
  Gutter gutter = new Gutter(textArea);
  Assert.assertTrue(gutter.getLineNumbersEnabled());
  gutter.setLineNumbersEnabled(true);
  Assert.assertTrue(gutter.getLineNumbersEnabled());
}
origin: com.fifesoft/rsyntaxtextarea

/**
 * Toggles whether or not line numbers are visible.
 *
 * @param enabled Whether or not line numbers should be visible.
 * @see #getLineNumbersEnabled()
 */
public void setLineNumbersEnabled(boolean enabled) {
  gutter.setLineNumbersEnabled(enabled);
  checkGutterVisibility();
}
origin: org.nuiton.thirdparty/rsyntaxtextarea

/**
 * Toggles whether or not line numbers are visible.
 *
 * @param enabled Whether or not line numbers should be visible.
 * @see #getLineNumbersEnabled()
 */
public void setLineNumbersEnabled(boolean enabled) {
  gutter.setLineNumbersEnabled(enabled);
  checkGutterVisibility();
}
origin: org.codehaus.jtstand/jtstand-editor

/**
 * Toggles whether or not line numbers are visible.
 *
 * @param enabled Whether or not line numbers should be visible.
 * @see #getLineNumbersEnabled()
 */
public void setLineNumbersEnabled(boolean enabled) {
  gutter.setLineNumbersEnabled(enabled);
  checkGutterVisibility();
}
origin: org.codehaus.jtstand/jtstand-editor

/**
 * Constructor.
 *
 * @param textArea The parent text area.
 */
public Gutter(RTextArea textArea) {
  listener = new TextAreaListener();
  setTextArea(textArea);
  setLayout(new BorderLayout());
  if (this.textArea!=null) {
    // Enable line numbers our first time through if they give us
    // a text area.
    setLineNumbersEnabled(true);
  }
  setBorder(new GutterBorder(0, 0, 0, 1)); // Assume ltr
}
origin: org.nuiton.thirdparty/rsyntaxtextarea

/**
 * Constructor.
 *
 * @param textArea The parent text area.
 */
public Gutter(RTextArea textArea) {
  listener = new TextAreaListener();
  setTextArea(textArea);
  setLayout(new BorderLayout());
  if (this.textArea!=null) {
    // Enable line numbers our first time through if they give us
    // a text area.
    setLineNumbersEnabled(true);
  }
  setBorder(new GutterBorder(0, 0, 0, 1)); // Assume ltr
  Color bg = null;
  if (textArea!=null) {
    bg = textArea.getBackground(); // May return null if image bg
  }
  setBackground(bg!=null ? bg : Color.WHITE);
}
origin: com.fifesoft/rsyntaxtextarea

/**
 * Constructor.
 *
 * @param textArea The parent text area.
 */
public Gutter(RTextArea textArea) {
  listener = new TextAreaListener();
  lineNumberColor = Color.gray;
  lineNumberFont = RTextArea.getDefaultFont();
  lineNumberingStartIndex = 1;
  iconRowHeaderInheritsGutterBackground = false;
  setTextArea(textArea);
  setLayout(new BorderLayout());
  if (this.textArea!=null) {
    // Enable line numbers our first time through if they give us
    // a text area.
    setLineNumbersEnabled(true);
    if (this.textArea instanceof RSyntaxTextArea) {
      RSyntaxTextArea rsta = (RSyntaxTextArea)this.textArea;
      setFoldIndicatorEnabled(rsta.isCodeFoldingEnabled());
    }
  }
  setBorder(new GutterBorder(0, 0, 0, 1)); // Assume ltr
  Color bg = null;
  if (textArea!=null) {
    bg = textArea.getBackground(); // May return null if image bg
  }
  setBackground(bg!=null ? bg : Color.WHITE);
}
org.fife.ui.rtextareaGuttersetLineNumbersEnabled

Javadoc

Toggles whether or not line numbers are visible.

Popular methods of Gutter

  • setLineNumberColor
    Sets the color to use to paint line numbers.
  • setBackground
  • <init>
    Constructor.
  • addLineTrackingIcon
    Adds an icon that tracks an offset in the document, and is displayed adjacent to the line numbers. T
  • addOffsetTrackingIcon
    Adds an icon that tracks an offset in the document, and is displayed adjacent to the line numbers. T
  • getBookmarks
    Returns the bookmarks known to this gutter.
  • getLineNumbersEnabled
    Returns true if the line numbers are enabled and visible.
  • isIconRowHeaderEnabled
    Returns whether the icon row header is enabled.
  • setBorderColor
    Sets the color for the "border" line.
  • setIconRowHeaderEnabled
    Toggles whether the icon row header (used for breakpoints, bookmarks, etc.) is enabled.
  • setLineNumberFont
    Sets the font used for line numbers.
  • toggleBookmark
    Programatically toggles whether there is a bookmark for the specified line. If bookmarking is not en
  • setLineNumberFont,
  • toggleBookmark,
  • add,
  • getBackground,
  • getBorder,
  • getComponent,
  • getComponentCount,
  • remove,
  • repaint

Popular in Java

  • Reading from database using SQL prepared statement
  • scheduleAtFixedRate (Timer)
  • orElseThrow (Optional)
    Return the contained value, if present, otherwise throw an exception to be created by the provided s
  • runOnUiThread (Activity)
  • Point (java.awt)
    A point representing a location in (x,y) coordinate space, specified in integer precision.
  • Hashtable (java.util)
    A plug-in replacement for JDK1.5 java.util.Hashtable. This version is based on org.cliffc.high_scale
  • Collectors (java.util.stream)
  • Runner (org.openjdk.jmh.runner)
  • Reflections (org.reflections)
    Reflections one-stop-shop objectReflections scans your classpath, indexes the metadata, allows you t
  • LoggerFactory (org.slf4j)
    The LoggerFactory is a utility class producing Loggers for various logging APIs, most notably for lo
  • Best IntelliJ plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

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