Hello,
It seems cuda formatter supply 4 formater as maximum namde A B C and D, could we add more formatter to it?
Also what's the main purpose for cross-lexer formatter, I didn't use it now because not very sure about the meaning.
Thanks!
plugin CudaFormatter + its formatters
CudaFormatter plugin issues
- Attachments
-
- 20231028122036.png (7.68 KiB) Viewed 7774 times
-
- Posts: 2323
- Joined: 25.08.2021 18:15
Re: about cudaformatter
1. I am not sure we really need >4 formatters per one lexer. give me example of 5 formatters for one lexer.
2. WIki has the info:
https://wiki.freepascal.org/CudaText_plugins
Formatter cross-lexer 1...4
Runs formatter for current editor file, which has cross-lexer label (1, 2, 3, 4). For example, when you have a formatter XY assigned to the label "2", the command "Formatter cross-lexer: 2" always runs XY, ignoring the current lexer.
2. WIki has the info:
https://wiki.freepascal.org/CudaText_plugins
Formatter cross-lexer 1...4
Runs formatter for current editor file, which has cross-lexer label (1, 2, 3, 4). For example, when you have a formatter XY assigned to the label "2", the command "Formatter cross-lexer: 2" always runs XY, ignoring the current lexer.
-
- Posts: 2323
- Joined: 25.08.2021 18:15
Re: about cudaformatter
'cross-lexer' formatter must be used only for special cases. when formatter is very general and/or can auto-detect the syntax/lexer.
Re: about cudaformatter
Thanks, Now I know that the formatter ABCD can used for each different lexer. I used to take the formatter A can just used for one certain lexer, that's why I want to add more.
-
- Posts: 2323
- Joined: 25.08.2021 18:15
Re: about cudaformatter
yes, for example, you can have formatter FF1 assigned to 'B' for JavaScript;
and formatter CC1 assigned to 'B' for C++.
they both are called by 'formatter per-lexer B'.
and formatter CC1 assigned to 'B' for C++.
they both are called by 'formatter per-lexer B'.