[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Texmacs-dev] Math codes
From: |
Henri Lesourd |
Subject: |
Re: [Texmacs-dev] Math codes |
Date: |
Sun, 22 Apr 2007 01:44:13 +0200 |
User-agent: |
Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.4) Gecko/20030821 |
Todd Wilson wrote:
TeXmacs seems to make similar decisions about how to do spacing in
math mode, so I'd just like to create a "hook" into these algorithms
the way that TeX has.
Typically, the TeXmacs algorithms do not include hooks,
they try to hide as much as possible, in order to ease modifications
of the algorithm without breaking things people rely on (if there
is nothing to rely on in the 1st place, things are easier).
On the other hand, for things like the one we are discussing, there
should be a way to obtain more control. But I don't know if it exists
yet (ask Joris for exact details about this).
Anyway, as a workaround, how do I obtain exactly what I want? Do I
take a look at what TeXmacs produces and then add the right amount of
positive or negative space before and after the symbol to compensate?
Something like that could work. For example (my amount of negative space is
very approximate, but it shows the idea) :
[[
<assign|colon|<macro|x|y|<arg|x>:<space|-0.7mm><arg|y>>>
]]
, and then you do :
[[
<colon|a|b>
]]
Observe the difference with :
[[
<math|<colon|a|b>>
]]
You could then add some keyboard shortcuts to ease the input of such
macros (e.g. have a look at :
http://www.ags.uni-sb.de/~henri/texmacs/aTeXmacsTutorial.pdf
for a simple tutorial about macros, how to define kbs shortcuts, etc.).
This is not a perfect solution, but it is relatively useable.