- From: Miguel de Benito Delgado <address@hidden>
- To: Alexandre Dezotti <address@hidden>
- Cc: "address@hidden" <address@hidden>
- Subject: Re: [TeXmacs] Macro not handling big operators
- Date: Sun, 20 Jul 2014 20:17:31 +0200
Hi,
instead of defining an environment variable:
<assign|uni|<big|cup>>
what you need to do is define a macro:
<assign|uni|<\macro>
<big|cup>
</macro>>
Notice the way the macro is written: it expands to a document tag (hidden in
the default view mode for source code (try setting the preferences in
Document->Source->Preferences… to show “raw”). This is necessary.
Now use the macro typing \uni.
Of course you can define keyboard shortcuts:
(kbd-map
(:mode in-math?)
("C-u" (make 'uni)))
Also, no need to go to source mode at all! Don’t inflict unnecessary pain on
yourself: To insert below / above, select the symbol then hit C-b or C-a. ;)
Cheers,
--
Miguel de Benito.
On 20 de julio de 2014 at 09:58:18, Alexandre Dezotti (address@hidden) wrote:
>
Hi,
>
>
For the compilation, I do have Guile 2.0, and tried to override this
>
problem despite me not knowing what I was doing at all. Hence the
>
error message about Qt.
>
>
I have just tried the static binaries, it works fine. I had just to
>
figure out how to use the \below command (which is straightforward in
>
source mode).
>
>
Indeed, \below\above are just fine!
>
>
>
Now there is a small display issue. I have the following in the body
>
of my document:
>
>
>
>
>
\;
>
>
|\>|i=0>>
>
|i=0>|\>>
>
>
|\>|i=0>>
>
|i=0>|\>>
>
>
\;
>
>
\;
>
>
Compared to the two fist versions, the last ones does not seem to be
>
centred, as if there were a space just after the cup symbol (screen
>
shot: http://i.imgur.com/LD4kf6q.png).
>
>
>
>
Thank you very much !
>
>
2014-07-19 12:37 GMT+02:00 Miguel de Benito Delgado :
>
> Hi,
>
>
>
> (reposting to the list)
>
>
>
> On Fri, Jul 18, 2014 at 1:24 PM, Alexandre Dezotti
>
> wrote:
>
>
>
>> * The keyboard works just fine until I insert script above/bellow
>
>> through the menu, I can see in source mode that the below/above
>
>> commands are inserted in the source text.
>
>>
>
>> * The shortcuts displayed in the menu are Alt+B for bellow, and Alt+A for
>
>> above.
>
>>
>
>> *
>
>> $ uname -r
>
>> 3.15.5-1-ARCH
>
>> $ gnome-shell --version
>
>> GNOME Shell 3.12.2
>
>> $ texmacs --version
>
>> TeXmacs version 1.0.7.21
>
>> (c) 1999-2013 by Joris van der Hoeven and others
>
>>
>
>> I have just learned this version of Texmacs was 1 year old, though it
>
>> is still the official version for my distribution.
>
>> I have also tried to get the source from the web and compile it, but
>
>> it failed. I have probably to set up Qt correctly, which I don't have
>
>> time to do this.
>
>
>
>
>
> Compilation should work out of the box. You only need to be sure that the
>
> version of guile you have is 1.8 and NOT 2.0
>
>
>
>> * I see xmodmap is used to translate keyboard inputs, maybe it could
>
>>
>
>> work. If I understand well, it would require to type differently than
>
>> what is expected and displayed on the actual keyboard. I feel it is a
>
>> bit overkill for this. My solution will be to wait for a new release
>
>> from Archlinux.
>
>
>
>
>
> Have you tried the static binaries?
>
>
>
> http://www.texmacs.org/Download/ftp/tmftp/generic/TeXmacs-1.99.2-i386-pc-linux-gnu-B.tar.gz
>
>
>
>
>
> or if you have an older glibc:
>
>
>
> http://www.texmacs.org/Download/ftp/tmftp/generic/TeXmacs-1.99.2-i386-pc-linux-gnu-A.tar.gz
>
>
>
>
>
> --
>
> Miguel de Benito.
>
>>
>
>> 2014-07-18 12:49 GMT+02:00 Miguel de Benito Delgado
>
>> :
>
>> > Hi,
>
>> >
>
>> > * The scripts above/below *do* work, but then you have problems with
>
>> > the
>
>> > keyboard, right?
>
>> > * What's the shortcut displayed next to Script->script above/below?
>
>> > * What is your TeXmacs version and system?
>
>> > * If you are running Linux, couldn't you use Xmodmap to avoid this
>
>> > conflict?
>
>> >
>
>> > Best,
>
>> >
>
>> > --
>
>> > Miguel de Benito.
>
>> >
>
>> >
>
>> > On Fri, Jul 18, 2014 at 9:45 AM, Alexandre Dezotti
>
>> > wrote:
>
>> >>
>
>> >> Hi,
>
>> >>
>
>> >> Thank you for your answer. Unfortunately, this does not work.
>
>> >> When I use Insert->script->script bellow (or above), and then stroke
>
>> >> "\" it produces a lower script. It does this every time I stroke
>
>> >> backslash in any mathematical context. Thus I cannot enter command any
>
>> >> more.
>
>> >> In normal context (text) the backlash is interpreted as "_". This is
>
>> >> probably related to the fact that backslash, on my keyboard is
>
>> >> produced by hitting "alt gr" and "_" as the same time.
>
>> >> I have to restart texmacs to have normal behaviour again.
>
>> >>
>
>> >> Best regards,
>
>> >> Alexandre.
>
>> >>
>
>> >> 2014-07-17 17:41 GMT+02:00 Miguel de Benito Delgado
>
>> >> :
>
>> >> > On Thu, Jul 17, 2014 at 2:03 PM, Alexandre Dezotti
>
>> >> > wrote:
>
>> >> >>
>
>> >> >> The subscript and superscript won't go under and above the symbol.
>
>> >> >>
>
>> >> >> Is there a way to make this work?
>
>> >> >
>
>> >> >
>
>> >> > I don't know, but there has to be since superscripts for some
>
>> >> > symbols
>
>> >> > are
>
>> >> > interpreted as "script above".
>
>> >> >
>
>> >> > In any case, this motivates the workaround, which should provide
>
>> >> > reasonably
>
>> >> > good results in your case (union/intersection/etc), of using
>
>> >> > Insert->Script->Script above (or the corresponding shortcut, ctrl+A
>
>> >> > in
>
>> >> > my
>
>> >> > setup).
>
>> >> >
>
>> >> > Best,
>
>> >> > --
>
>> >> > Miguel de Benito.
>
>> >> >
>
>> >
>
>> >
>
>
>
>
>
Archive powered by MHonArc 2.6.19.