From: Yuan Fu <casouri@gmail.com>
To: Vincenzo Pupillo <v.pupillo@gmail.com>
Cc: Eli Zaretskii <eliz@gnu.org>, 74610@debbugs.gnu.org
Subject: bug#74610: 31.0.50; Submitting mhtml-ts-mode, treesitter alternative to mhtml-mode
Date: Tue, 24 Dec 2024 14:18:39 -0800 [thread overview]
Message-ID: <D06621B4-736C-4729-A8E4-3D5885F498F4@gmail.com> (raw)
In-Reply-To: <018B485B-8F4D-4472-BD21-384C7EC9E31C@gmail.com>
> On Dec 24, 2024, at 12:37 AM, Yuan Fu <casouri@gmail.com> wrote:
>
>
>
>> On Dec 14, 2024, at 2:37 AM, Vincenzo Pupillo <v.pupillo@gmail.com> wrote:
>>
>> In data mercoledì 11 dicembre 2024 05:54:09 Ora standard dell’Europa centrale,
>> Yuan Fu ha scritto:
>>>> On Dec 3, 2024, at 6:29 AM, Vincenzo Pupillo <v.pupillo@gmail.com> wrote:
>>>>
>>>> In data domenica 1 dicembre 2024 07:01:21 Ora standard dell’Europa
>>>> centrale,>
>>>> Yuan Fu ha scritto:
>>>>> It's not uncommon to see different indent offset for CSS and
>>>>> Javascript, so it's a good idea to have separate control for them.
>>>>
>>>> Is the behavior the same as mhtml-mode, or would you like something like
>>>> this?>
>>>> <style>
>>>>
>>>> z {
>>>>
>>>> color: red;
>>>>
>>>> }
>>>>
>>>> </style>
>>>> <script>
>>>>
>>>> function myFunction(p1, p2) {
>>>>
>>>> return p1 * p2;
>>>>
>>>> }
>>>>
>>>> </script>
>>>>
>>>> The mhtml-ts-mode-js-css-indent-offset variable controls only the
>>>> indentation relative to the <style> and <script> tags.
>>>
>>> Ah, I see, it’s the offset from the enclosing tag. In that case it should be
>>> fine to use a common variable.
>>>
>>> Yuan
>> Thank you Yuan.
>> Attached is the revised patch following your previous comments.
>> As I already wrote to Dmitry, I am doing some tests to see if html-ts-mode can
>> be extended and if there is a way to integrate one multi-language mode into
>> another multi-language mode.
>>
>> Vincenzo
>> <0001-Add-mhtml-ts-mode.patch>
>
> Btw, mhtml-ts-mode--defun-name seems to contain some debugging code? And also I think you should use treesit-node-language.
>
> Yuan
I just added treesit-aggregated-simple-imenu-settings to master. This variable will allow you to setup Imenu for multiple languages. Please give it a try. I tested locally with mhtml-ts-mode and works well.
Yuan
next prev parent reply other threads:[~2024-12-24 22:18 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-11-29 21:57 bug#74610: 31.0.50; Submitting mhtml-ts-mode, treesitter alternative to mhtml-mode Vincenzo Pupillo
2024-12-01 6:01 ` Yuan Fu
2024-12-01 8:00 ` Eli Zaretskii
2024-12-01 8:18 ` Yuan Fu
2024-12-03 14:29 ` Vincenzo Pupillo
2024-12-11 4:54 ` Yuan Fu
2024-12-14 10:37 ` Vincenzo Pupillo
2024-12-16 17:37 ` Juri Linkov
2024-12-17 21:25 ` Vincenzo Pupillo
2024-12-24 8:37 ` Yuan Fu
2024-12-24 22:18 ` Yuan Fu [this message]
2024-12-04 1:27 ` Dmitry Gutov
2024-12-04 10:47 ` Vincenzo Pupillo
2024-12-05 16:51 ` Dmitry Gutov
2024-12-06 13:39 ` Vincenzo Pupillo
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.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=D06621B4-736C-4729-A8E4-3D5885F498F4@gmail.com \
--to=casouri@gmail.com \
--cc=74610@debbugs.gnu.org \
--cc=eliz@gnu.org \
--cc=v.pupillo@gmail.com \
/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.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).