Dave Jarvis' Repositories

git clone https://repo.autonoma.ca/repo/keenwrite.git
M src/main/java/com/keenwrite/preview/HTMLPreviewPane.java
6464
public final class HTMLPreviewPane extends SwingNode {
6565
  /**
66
   * Used to scroll to the top of the preview pane.
67
   */
68
  private static final Point POINT_TOP = new Point( 0, 0 );
69
70
  /**
7166
   * Suppresses scrolling to the top on every key press.
7267
   */
...
261256
  }
262257
258
  /**
259
   * Scrolls to the location specified by the {@link Box} that corresponds
260
   * to a point somewhere in the preview pane. If there is no caret, then
261
   * this will not change the scroll position. Changing the scroll position
262
   * to the top if the {@link Box} instance is {@code null} will result in
263
   * jumping around a lot and inconsistent synchronization issues.
264
   *
265
   * @param box The rectangular region containing the caret, or {@code null}
266
   *            if the HTML does not have a caret.
267
   */
263268
  private void scrollTo( final Box box ) {
264
    scrollTo( box == null ? POINT_TOP : createPoint( box ) );
269
    if( box != null ) {
270
      scrollTo( createPoint( box ) );
271
    }
265272
  }
266273
267274
  private void scrollTo( final Point point ) {
268
    invokeLater( () -> mHtmlRenderer.scrollTo( point ) );
275
    mHtmlRenderer.scrollTo( point );
269276
  }
270277
...
300307
301308
  public void repaintScrollPane() {
302
    invokeLater( () -> getScrollPane().repaint() );
309
    getScrollPane().repaint();
303310
  }
304311
M src/main/java/com/keenwrite/processors/markdown/r/RExtension.java
3535
import com.vladsch.flexmark.parser.Parser;
3636
import com.vladsch.flexmark.parser.delimiter.DelimiterProcessor;
37
import com.vladsch.flexmark.parser.internal.CommonmarkInlineParser;
37
import com.vladsch.flexmark.parser.internal.InlineParserImpl;
3838
import com.vladsch.flexmark.parser.internal.LinkRefProcessorData;
3939
import com.vladsch.flexmark.util.data.DataHolder;
...
6767
   * </p>
6868
   */
69
  private static class RInlineParser extends CommonmarkInlineParser {
69
  private static class RInlineParser extends InlineParserImpl {
7070
    private RInlineParser(
7171
        final DataHolder options,