Re: tm-define

Massimiliano Gubinelli <[email protected]>
Newsgroups gmane.editors.texmacs.devel
Message-ID <[email protected]>
Dear Giovanni,

 my understanding of Joris' intentions is the following: when you need functions accessible in a wide context (i.e. from C/C++, or from documents) or when you need to redefine basic mechanisms (like handling of keypresses, or other context-dependent actions, menus, etc... ) then you need to use tm-define. For all other procedures you want to define, then you can continue to use define or define-public (which exports functions out of modules). Procedures defined with define are only visible in the current module, and with define-public only visible if you import the specific module but they do not pollute the global environment.

Best
Max



> On 17. Mar 2021, at 20:18, Giovanni Piredda <[email protected]> wrote:
> 
> Dear Joris, dear all,
> 
> I am writing a post on external Scheme files for the blog. I would like to know whether the current status of tm-define is also the final one.
> 
> In detail: if I load module mod2 inside module mod1 with the :use form, and then I use mod1 in my document with the use-module macro, the functions defined with tm-define in mod2 appear also in the document (I checked this with 1.99.19).
> 
> Is this the final stand or do you have changes in mind? Thanks in advance for the information.
> 
> By the way this from my point of view has one good and one bad consequence: the good one is that I can load several modules at once in my document by collecting them with use: within a single module, the bad one is that supporting functions that I do not need to use from the document are available nevertheless (this might be just a matter of elegance ... or pickiness).
> 
> G.
> 
> 
> _______________________________________________
> Texmacs-dev mailing list
> [email protected]
> https://lists.gnu.org/mailman/listinfo/texmacs-dev


_______________________________________________
Texmacs-dev mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/texmacs-dev
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.