Codota Logo
Gutter.setBookmarkingEnabled
Code IndexAdd Codota to your IDE (free)

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

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

  • Common ways to obtain Gutter
private void myMethod () {
Gutter g =
  • Codota IconRTextArea textArea;new Gutter(textArea)
  • Codota IconRTextScrollPane rTextScrollPane;rTextScrollPane.getGutter()
  • Codota IconRTextArea textArea;RSyntaxUtilities.getGutter(textArea)
  • Smart code suggestions by Codota
}
origin: bobbylight/RSyntaxTextArea

  DemoRootPane() {
    textArea = createTextArea();
    setText("JavaExample.txt");
    textArea.setSyntaxEditingStyle(SYNTAX_STYLE_JAVA);

    scrollPane = new RTextScrollPane(textArea, true);
    Gutter gutter = scrollPane.getGutter();
    gutter.setBookmarkingEnabled(true);
    URL url = getClass().getResource("bookmark.png");
    gutter.setBookmarkIcon(new ImageIcon(url));
    getContentPane().add(scrollPane);
    ErrorStrip errorStrip = new ErrorStrip(textArea);
//errorStrip.setBackground(java.awt.Color.blue);
    getContentPane().add(errorStrip, BorderLayout.LINE_END);
    setJMenuBar(createMenuBar());
  }

origin: bobbylight/RSyntaxTextArea

@Test
public void getBookmarks_SomeBookmarks_NoIcon() throws Exception {
  RTextArea textArea = new RTextArea(PLAIN_TEXT);
  Gutter gutter = new Gutter(textArea);
  gutter.setBookmarkingEnabled(true);
  // Both enabled state and icon are reuqired
  Assert.assertEquals(0, gutter.getBookmarks().length); // Non-null
}
origin: bobbylight/RSyntaxTextArea

@Test
public void testIsBookmarkingEnabled() {
  RTextArea textArea = new RTextArea(PLAIN_TEXT);
  Gutter gutter = new Gutter(textArea);
  Assert.assertFalse(gutter.isBookmarkingEnabled());
  gutter.setBookmarkingEnabled(true);
  Assert.assertTrue(gutter.isBookmarkingEnabled());
}
origin: bobbylight/RSyntaxTextArea

@Test
public void testSetBookmarkingEnabled() {
  RTextArea textArea = new RTextArea(PLAIN_TEXT);
  Gutter gutter = new Gutter(textArea);
  Assert.assertFalse(gutter.isBookmarkingEnabled());
  gutter.setBookmarkingEnabled(true);
  Assert.assertTrue(gutter.isBookmarkingEnabled());
}
origin: bobbylight/RSyntaxTextArea

@Test
public void testToggleBookmark() throws Exception {
  RTextArea textArea = new RTextArea(PLAIN_TEXT);
  Gutter gutter = new Gutter(textArea);
  gutter.setBookmarkingEnabled(true);
  gutter.setBookmarkIcon(new TestIcon());
  Assert.assertTrue(gutter.toggleBookmark(1));
  Assert.assertFalse(gutter.toggleBookmark(1));
  Assert.assertTrue(gutter.toggleBookmark(1));
}
origin: bobbylight/RSyntaxTextArea

@Test
public void getBookmarks_SomeBookmarks() throws Exception {
  RTextArea textArea = new RTextArea(PLAIN_TEXT);
  Gutter gutter = new Gutter(textArea);
  gutter.setBookmarkingEnabled(true);
  gutter.setBookmarkIcon(new TestIcon());
  Assert.assertTrue(gutter.toggleBookmark(1));
  Assert.assertTrue(gutter.toggleBookmark(2));
  Assert.assertEquals(2, gutter.getBookmarks().length); // Non-null
}
origin: com.fifesoft/languagesupport

RTextScrollPane scrollPane = new RTextScrollPane(textArea, true);
scrollPane.setIconRowHeaderEnabled(true);
scrollPane.getGutter().setBookmarkingEnabled(true);
org.fife.ui.rtextareaGuttersetBookmarkingEnabled

Javadoc

Sets whether bookmarking is enabled. Note that a bookmarking icon must be set via #setBookmarkIcon(Icon) before bookmarks are truly enabled.

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.
  • setLineNumbersEnabled
    Toggles whether or not line numbers are visible.
  • setLineNumberFont,
  • setLineNumbersEnabled,
  • toggleBookmark,
  • add,
  • getBackground,
  • getBorder,
  • getComponent,
  • getComponentCount,
  • remove,
  • repaint

Popular in Java

  • Reading from database using SQL prepared statement
  • getOriginalFilename (MultipartFile)
    Return the original filename in the client's filesystem.This may contain path information depending
  • onRequestPermissionsResult (Fragment)
  • orElseThrow (Optional)
  • BufferedInputStream (java.io)
    Wraps an existing InputStream and buffers the input. Expensive interaction with the underlying input
  • ByteBuffer (java.nio)
    A buffer for bytes. A byte buffer can be created in either one of the following ways: * #allocate(i
  • Charset (java.nio.charset)
    A charset is a named mapping between Unicode characters and byte sequences. Every Charset can decode
  • Properties (java.util)
    The Properties class represents a persistent set of properties. The Properties can be saved to a st
  • JFrame (javax.swing)
  • Logger (org.apache.log4j)
    This is the central class in the log4j package. Most logging operations, except configuration, are d
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now