Skip to Content.
Sympa Menu

texmacs-users - Re: [TeXmacs] Simple Macro

Subject: mailing-list for TeXmacs Users

List archive

Re: [TeXmacs] Simple Macro


Chronological Thread 
  • From: David Allouche <address@hidden>
  • To: address@hidden
  • Subject: Re: [TeXmacs] Simple Macro
  • Date: Thu, 5 Feb 2004 10:27:08 +0100

On Wed, Feb 04, 2004 at 04:05:55PM -0500, Jeremy Cowgar wrote:
> On Wed, 2004-02-04 at 14:33, Jeremy Cowgar wrote:
> > I just wish to add a couple of macros right now to my new style,
> > sermon.ts ... Can anyone give me a simple example of how to add a macro
> > to my new style? Say something like:
> >
> > \scripture<CR>
> > body of scripture<RIGHT-ARROW><CR>

Sorry, but I cannot make sense of what you ask.... maybe:

(assign "sermon"
(macro "x"
(concat (arg "x") (with "mode" "math" "<leftarrow>"))))

> Ok, I don't know if this means I should post sooner or later, but it
> seems that once I post I have breakthroughs.

That's probably because posting helps you clarify your thoughts and
formulate your problem. That's a well known process among programmers,
we call it "confessional debugging".

> Anyway, I finally got a style to appear on the menu, and I even got my
> package to appear on the menu. The problem I am experiencing now is
> that I cannot seem to figure out how to include the package into the
> style. My package works just fine if I select Use Package, Sermon,
> sermon-base but it does not work by just saying Document, Style,
> Sermon. Here is what I have:
[snip style files, visibly hand-edited]

First thing, _NEVER_ hand edit style files, unless you _REALLY_ know
what your are doing. You should edit files from inside TeXmacs in
preamble mode instead. Yes, it's a big unconvenient but it will save you
a lot of trouble in the end.

Though, so far your files seem correct (not tested here). My guess is
your are being bitten by the absence of style cache invalidation
mechanism in TeXmacs. Remove the ~/.TeXmacs/system/cache directory and
restart texmacs.

Optionally, you may want to write a patch to implement style cache
invalidation when at least one of the involved .ts files had its mdate
altered.

--
-- ddaa



Archive powered by MHonArc 2.6.19.

Top of Page