You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@netbeans.apache.org by Ian Utley <ut...@gmail.com> on 2019/08/21 14:57:17 UTC
Implement toolbar Comment/Uncomment actions
Hi,
I have created and registered a new File Type inside Netbeans 11.
However the comment/uncomment buttons in the editor toolbar do not do
anything (as expected). How do I implement these actions, do I need to also
create an EditorKit, or is that deprecated?
Regards
Ian.
Re: Implement toolbar Comment/Uncomment actions
Posted by Geertjan Wielenga <ge...@apache.org>.
Great. What’s the language you’re providing support for?
Gj
On Wed, 21 Aug 2019 at 20:42, Ian Utley <ut...@gmail.com> wrote:
> Solved it. FYI. I had been following the tutorial at
> https://platform.netbeans.org/tutorials/nbm-javacc-lexer.html and the
> tutorial code doesn't override the getCommentHandler() method of the
> LanguageRegistration class which extended DefaultLanguageConfig. Adding a
> suitable CommentHandler.DefaultCommentHandler fixed the issue.
>
> On Wed, Aug 21, 2019 at 3:57 PM Ian Utley <ut...@gmail.com> wrote:
>
>> Hi,
>> I have created and registered a new File Type inside Netbeans 11.
>> However the comment/uncomment buttons in the editor toolbar do not do
>> anything (as expected). How do I implement these actions, do I need to also
>> create an EditorKit, or is that deprecated?
>>
>> Regards
>> Ian.
>>
>
Re: Implement toolbar Comment/Uncomment actions
Posted by Ian Utley <ut...@gmail.com>.
Solved it. FYI. I had been following the tutorial at
https://platform.netbeans.org/tutorials/nbm-javacc-lexer.html and the
tutorial code doesn't override the getCommentHandler() method of the
LanguageRegistration class which extended DefaultLanguageConfig. Adding a
suitable CommentHandler.DefaultCommentHandler fixed the issue.
On Wed, Aug 21, 2019 at 3:57 PM Ian Utley <ut...@gmail.com> wrote:
> Hi,
> I have created and registered a new File Type inside Netbeans 11.
> However the comment/uncomment buttons in the editor toolbar do not do
> anything (as expected). How do I implement these actions, do I need to also
> create an EditorKit, or is that deprecated?
>
> Regards
> Ian.
>