emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: "Fraga, Eric" <e.fraga@ucl.ac.uk>
To: Emacs Org mode mailing list <emacs-orgmode@gnu.org>
Subject: problem interaction between jinx-mode and org mode
Date: Thu, 6 Apr 2023 11:29:29 +0000	[thread overview]
Message-ID: <875ya9l04o.fsf@ucl.ac.uk> (raw)

Hello all,

I have just posted an issue on the jinx spell checking package's github
site:

https://github.com/minad/jinx/issues/35

There seems to be a strange interaction between jinx and orgmode when
the buffer has lines of the form:

--8<---------------cut here---------------start------------->8---
┌ Debug: Placing hot node
│   node = n29
└ @ HeatExchangerNetworkDesign ~/s/research/julia/HeatExchangerNetworkDesign/src/HeatExchangerNetworkDesign.jl:1102
┌ Debug: Layout for node
│   node = n18
│   y = 6
└ @ HeatExchangerNetworkDesign 
--8<---------------cut here---------------end--------------->8---

lines which are the output of Julia's @debug macro, whose output uses
non-ASCII Unicode characters at the start of each line.  Emacs
essentially freezes for some seconds (10-20) every time I scroll (which
makes sense because jinx only spell-checks the visible part of the
buffer).

The profiler output for CPU:

--8<---------------cut here---------------start------------->8---
       47871  96%    - jinx--check-pending
       47869  96%     - jinx--check-region
       47861  96%      - jinx--flyspell-ignored-p
       47861  96%       - org-mode-flyspell-verify
       47837  96%        - org--flyspell-object-check-p
       47837  96%         - org-element-context
       46973  94%          - org-element--object-lex
       46022  92%           - org-element-code-parser
         340   0%            - org-element--parse-generic-emphasis
         328   0%             + rx-to-string
         859   1%           + org-element-italic-parser
--8<---------------cut here---------------end--------------->8---

and MEM:

--8<---------------cut here---------------start------------->8---
    326,775,960  96% - timer-event-handler
    326,674,976  96%  - apply
    325,996,129  96%   - jinx--timer-handler
    325,678,345  95%    - jinx--check-pending
    325,657,281  95%     - jinx--check-region
    325,636,601  95%      - jinx--flyspell-ignored-p
    325,636,601  95%       - org-mode-flyspell-verify
    325,072,246  95%        - org--flyspell-object-check-p
    325,072,246  95%         - org-element-context
    325,026,076  95%          - org-element--object-lex
    215,616,248  63%           - org-element-italic-parser
    211,670,968  62%            - org-element--parse-generic-emphasis
    211,670,968  62%             - rx-to-string
    186,054,064  54%              - rx--translate
    186,054,064  54%               - rx--translate-form
    181,758,312  53%                - rx--translate-seq
    155,393,544  45%                 - rx--translate
    155,393,544  45%                  - rx--translate-form
    107,261,576  31%                   - rx--translate-or
    100,408,048  29%                    - mapcan
     99,194,744  29%                     + #<subr F616e6f6e796d6f75732d6c616d626461_anonymous_lambda_2>
      2,524,984   0%                      rx--translate
     45,311,856  13%                   + rx--translate-not
      8,427,544   2%                 + rx--sequence
     10,559,024   3%              + rx--atomic-regexp
     83,089,056  24%           + org-element-code-parser
      4,458,332   1%           + org-element-verbatim-parser
        342,616   0%        + org-log-into-drawer
--8<---------------cut here---------------end--------------->8---

Turning off jinx-mode in the org buffer restores normal behaviour.

I've not yet tried with emacs -Q, however, so it could be something in
my configuration... However, I do wonder whether it is the file name use
of "~" that may be causing problems with the rx?

Thank you,
eric

-- 
: Eric S Fraga, with org release_9.6.1-341-g614b96 in Emacs 30.0.50

             reply	other threads:[~2023-04-06 11:35 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-04-06 11:29 Fraga, Eric [this message]
2023-04-06 12:04 ` problem interaction between jinx-mode and org mode Ihor Radchenko
2023-04-06 15:33   ` Fraga, Eric

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=875ya9l04o.fsf@ucl.ac.uk \
    --to=e.fraga@ucl.ac.uk \
    --cc=emacs-orgmode@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).