Subject: mailing-list for TeXmacs Users
List archive
From : Michael Lachmann <address@hidden>- To: texmacs-users <address@hidden>
- Subject: [TeXmacs] Re: "around" that allows line breaks
- Date: Sat, 27 Oct 2012 22:29:59 +0200
OK, answering a bit of my own questions.
I'm not sure, but I think "around" doesn't really have one place where
it is defined. It seems to be defined over many places, called
"AROUND".
And, I noticed that <next-line> does work inside arounds. This means
that we can have really nice bracket-matching in TeXmacs.
The only thing that is still puzzling is that when you insert a
<next-line> (e.g. by pressing cmd-enter on my computer, or
Format->Hyphenation->new line), the cursor shows up on the previous
line, even though text entered appears on the next line.
Is this on purpose? Can it be changed?
I attached a sample file. Move around with the cursor, and see how
nicely bracketed areas light up. It is easy to see which bracket
matches what.
But move the cursor to the line below the "print(i-50)", and then
slowly move it to the right. As you pass the curly bracket, the right
area lights up (i.e. the whole block after the "for(i in 1:100)".
Move one more to the right. The cursor is still on the same line, but
now no area is lit up. If you now press a letter, it shows up on the
next line (where it should). But the cursor is never on the first
column on the next line...
Michael
--
Michael Lachmann, Max Planck Institute for Evolutionary Anthropology
Deutscher Platz 6, 04107 Leipzig, Germany.
On 27 October 2012 17:56, Michael Lachmann <address@hidden> wrote:
> Hi,
> In an effort to make code editing easy within TeXmacs, I wanted to
> have some kind of line matching.
> But since TeXmacs supports trees, we can do better...
> Then I discovered the "around" (macro?), which has everything one needs:
> when you are inside the brackets, you can easily see where the block
> starts and ends, when you are just before
> the closing braket, and press ')', you are automatically moved beyond
> the bracket, etc, etc. Really cool.
> The problem is that <around| open | body | close > does not allow
> new-line within the body.
> Though, when the text wraps, there is no problem...
>
> I haven't been able to find the code for "around", though, so I can't
> find what the problem is.
>
> So, my questions are:
> 1. Is there some version of "around" that allows line breaks?
> 2. Where is the source code of around?
>
> Michael
Attachment:
bracket_test.tm
Description: Binary data
- [TeXmacs] "around" that allows line breaks, Michael Lachmann, 10/27/2012
- [TeXmacs] Re: "around" that allows line breaks, Michael Lachmann, 10/27/2012
- Message not available
- [TeXmacs] Re: "around" that allows line breaks, Michael Lachmann, 10/28/2012
- Re: [TeXmacs] Re: "around" that allows line breaks, Miguel de Benito Delgado, 10/29/2012
- Re: [TeXmacs] Re: "around" that allows line breaks, Michael Lachmann, 10/29/2012
- Re: [TeXmacs] Re: "around" that allows line breaks, Michael Lachmann, 10/29/2012
- Re: [TeXmacs] Re: "around" that allows line breaks, Massimiliano Gubinelli, 10/29/2012
- Re: [TeXmacs] Re: "around" that allows line breaks, Miguel de Benito Delgado, 10/29/2012
- Re: [TeXmacs] Re: "around" that allows line breaks, Michael Lachmann, 10/29/2012
- Re: [TeXmacs] Re: "around" that allows line breaks, Michael Lachmann, 10/29/2012
- Re: [TeXmacs] Re: "around" that allows line breaks, Miguel de Benito Delgado, 10/29/2012
- [TeXmacs] Re: "around" that allows line breaks, Michael Lachmann, 10/28/2012
- Message not available
- [TeXmacs] Re: "around" that allows line breaks, Michael Lachmann, 10/27/2012
Archive powered by MHonArc 2.6.19.