Skip to Content.
Sympa Menu

texmacs-users - Re: [TeXmacs] Macro dependent on previous character

Subject: mailing-list for TeXmacs Users

List archive

Re: [TeXmacs] Macro dependent on previous character


Chronological Thread 
  • From: Joris van der Hoeven <address@hidden>
  • To: address@hidden
  • Subject: Re: [TeXmacs] Macro dependent on previous character
  • Date: Sat, 18 Jun 2005 09:21:36 +0200

On Fri, Jun 17, 2005 at 06:20:10PM +0200, Alvaro Tejero Cantero wrote:
> I ask indulgence for my lack of precision: I meant the character just
> before the first character of the macro when it's typed.

Sure, TeXmacs currently implements many primitives for
looking upwards into the structure from the current path.
These features should be documented within shortly.
If you are impatient, then look at a file like generic-edit.scm
in the CVS version to see what you can do.

> > Please tell us more precisely what you want and maybe the application
> > that you have in mind.
>
> Dirac notation for the inner product (the pointy brackets of quantum
> mechanics).
>
> Say I have a ket somewhere: |a>
>
> and a bra in another part of the formula: <b|
>
> If I paste them in succession, either the left delimiter of the ket has
> to be turned into a middle delimiter and the right of the bra dissapear,
> or reciprocally, in order to get:
>
> <b|a>
>
> (left angle, middle bar, right angle)

I assume that you wrote macros for bra and ket?
Otherwise, you might simply select "a>" and paste it behind "<b|".

Best wishes, Joris



Archive powered by MHonArc 2.6.19.

Top of Page