Re: [code] [textadept] No Localization:context

From: cryo shock <axteffekt.att.gmail.com>
Date: Tue, 2 May 2017 19:52:57 +0200

2017-05-02 18:06 GMT+02:00 Mitchell <m.att.foicica.com>:

> Hi Sebastian,
>
> The default locale file with its messages is `core/locale.conf`. Try
> copy-pasting the left-hand key without the trailing space.

Thanks. The reason for No Localization:... was that I set the underbar
("_") incorrectly:
In the localize.conf file the string was:
_Insert Snippet...
In my menu.lua it was
Insert _Snippet...
That's quite obviously why TA couldn't find the correct string. So I only
had to reset the underbar position.

> Second:
>> How can I integrate this change to my init.lua? Or should I duplicate the
>> folder structure and menu.lua from the TA folder to my ~\.textadept
>> folder?
>>
>
> Are you talking about the context menu? If so, in a `events.INITIALIZED`
> handler, try:
>
> events.connect(events.INITIALIZED, function()
> local context_menu = textadept.menu.context_menu
> context_menu[#context_menu + 1] = {'label', function}
> end)
>
> (You can also use `table.insert()`, etc.)
>

Correct. I'd like to add the right-click context menu modification to my
init.lua, so that I don't have to re-edit menu.lua every time I update TA.
I will try your solution and I am pretty sure that it'll work, so thanks.

[...]

> No, those changes have to happen in Textadept's own file structure. Lua
> does not have access to those files and features.

I see; pity.

Cheers, Sebastian

>
> Cheers,
> Mitchell
> --
> You are subscribed to code.att.foicica.com.
> To change subscription settings, send an e-mail to code+help.att.foicica.com.
> To unsubscribe, send an e-mail to code+unsubscribe.att.foicica.com.
>
>

-- 
You are subscribed to code.att.foicica.com.
To change subscription settings, send an e-mail to code+help.att.foicica.com.
To unsubscribe, send an e-mail to code+unsubscribe.att.foicica.com.
Received on Tue 02 May 2017 - 13:52:57 EDT

This archive was generated by hypermail 2.2.0 : Wed 03 May 2017 - 06:32:43 EDT