mailing-list for TeXmacs Users

Text archives Help


Re: create tables from external data


Chronological Thread 
  • From: David Allouche <address@hidden>
  • To: address@hidden
  • Subject: Re: create tables from external data
  • Date: Thu, 1 Aug 2002 10:41:47 +0200

On Wed, Jul 31, 2002 at 11:16:56PM +0200, Nicolas Girard wrote:
> Hi all, I'm new to this mailing-list.

Welcome.


> a ; b ; c ; d
>
> and printed out to the standard output
>
> a & b & c & d \\
>
> Now I'd like to achieve the similar result with TeXmacs. That is, to
> call within a macro an external script which prints, in the appropriate
> conditions:
>
> <row|<\cell>a</cell><\cell>b</cell><\cell>c</cell><\cell>d</cell>>\
>
> Is there a way to interact with a program or a shell script like this ?
> Sessions are a way of interacting which is well documented, but this is
> not the same kind of interaction i need here.

Well, maybe session is indeed what you want.

Some user has been working an interface to integrate graphiz with
TeXmacs. That interface essentially allows a programatic description
to be translated in an included picture. You should be able to look
for it on the user contribution sections of the Wiki, but I cannot be
more precise since the Wike seems to be down right now.

I think that is near to what you want: given the name of the raw data
file, you get the table.

> I considered using the following operators:
> - hybrid
> - specific
> - action

Hybrid is not what you want. I documented it on the Wiki...
Essentially it is a container used by the editor when typing backslash
shortcuts.

Specific is not what you want either. It allows you to include some
code wich is only used when exporting to a specific file format. It is
what is closest to the LyX "red text" in TeXmacs. But it is *really*
seldom used.

Action might be remotely related to what you want to do. It can be
used to associate a piece of text to some GUILE code. When the piece
of text is double-clicked, the scheme code is evaluated. But,
actually, I have never seen a real-world use of this.

> Anyway this kind of interaction would be of the highest interest for
> many other uses, such as collaborative documents

What is on your mind?

We are thinking a lot about collaborative documents. Well not quite
right now, because we are thinking a lot about GUI issues, but
collaborative work is an important planned feature.

> Could you show me a starting point ?

After I saw your posts on address@hidden, I think the best way to do
what you want would be along the following lines:

Use some tool to generate a TeXmacs document in Scheme format
containing your table. You may use an external Perl script or an
embedded guile script (there must be some regex module in your guile
distribution).

Then "File->Import->Scheme" to open the document, copy the table,
close the document, paste the table, remove the document.

Maybe even all of this could be automated in GUILE and use the "get
file" dialog of TeXmacs.

Hope this helps.

--

-- David --




Archive powered by MHonArc 2.6.19.

Top of page