Re: [NTG-context] How to define an array of pens

2020-06-22 Thread Alan Braslau

On 22/06/20 01:17, Otared Kavian wrote:

for j = -1 step 1 until 1 :
MyPens[j] := pencircle scaled 2pt ; % I would like to say here 
(2+j) pt
endfor


MyPens[j] := pencircle scaled (2+j)*pt ;

pt is just a variable, and one can write 2pt implicitly implying the 
multiplication, but must explicitly write (2+j)*pt to parse correctly.


Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] LSP support

2020-06-27 Thread Alan Braslau

A start:

lua-lsp
A Language Server for Lua code, written in Lua.
Supports Lua 5.1-5.3 and Luajit

Alan

On 27/06/20 04:13, Saša Janiška wrote:

Hello,

yesterday while exploring features/plugins of Kakoune (https://kakoune.org/)
editor I, naturally, asked about ConTeXt/LaTeX support and was told about
TexLab project (https://github.com/latex-lsp/texlab) bringing LSP
(https://microsoft.github.io/language-server-protocol/) support for LaTeX.
Interestingly enough, by browsing through the tickets I've found the following
issue: "ConTeXt support" (https://github.com/latex-lsp/texlab/issues/166) where
one of the, afaict, main devs of the project replied with:

"ConTeXt support is definitely in scope of this project.
Our LaTeX parser does not rely on LaTeX specifics
but a lot of the features like code completion rely on LaTeX specifics.
Nevertheless, supporting ConTeXt is a lot of effort at the moment
as I have never used ConTeXt before.
Supporting the project structure of ConTeXt would probably be the first
step. "

Of course, I'm glad that TexLab project does provide LSP support and bringing
it to the Kakoune editor as well, but I'm sure that many of you know
that bringing ConTeXt support to TexLab would benefit users of **many**
other editors since these today many most popular editors (Atom, Emacs,
SublimeText, (neo)Vimn, VScode...) are having support for LSP.

Unfortuantely, I'm ConTeXt noob and not speaking Rust, but just want to bring
the information if there are people familiar with both about potential benefit
for ConTeXt to get LSP support.


Sincerely,
Saša



___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] Translation of ConTeXt interface

2020-06-27 Thread Alan Braslau

fonte ? (police)
principale ? (corps)
...

Alan

On 26/06/20 16:04, Garulfo wrote:



Math. I get the following error :

fonts  > preloading latin modern fonts (second stage)
fonts  > defining > font with asked name 'fichier' is not found using 
lookup 'file'

fonts  > defining > unknown font 'fichier', loading aborted

I suppose that due to the translation of "file" to "fichier".
It's OK when I switch back to
- setupstrings    cd:file ==> file
You can translate these string because they are only used in the 
command list to provide the texts which are shown in uppercase letter, 
e.g. NUMBER.

- variables file    ==> file
Constants (\c!...) and variables (\v!...) can be changed, only 
parameters which use the form \s!... have to be english in all cases 
(saves memory and improves performance).
How can I translate the variable "file" into fichier, without messing 
with fonts (and maybe other file related functions)
There shouldn't be a problem with fonts because they use \s!file or 
\s!name which aren't translated (unless you made the mistake and have 
\c!file in your typescripts). It's possible there is a bug somewhere 
but you have to provide a minimal example.


My understanding:

I translated \setupbodyfont into \configurerfonteprincipale.

But I didn't specify any font in the input file.

As soon as I specified \configurerfonteprincipale[pagella,10pt] in the 
input file, font messages "'fichier' is not found" disappear.


Is there an additionnal thing to do in order to enable the loading of a 
default math font, without any font specification, but still with 
translations of "file" into "fichier" ?


___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] Broken PDF with latest MkIV

2020-07-12 Thread Alan Braslau

On 12/07/20 03:48, Henning Hraban Ramm wrote:

Hi,
I just installed the latest ConTeXt MkIV (LuaTeX 2.06 20200706 + ConTeXt MkIV 
2020.07.09 14:51) to check if the CG journal will look the same as with my 
"old” installation (LuaTeX 1.11 7215 + ConTeXt MkIV 2020.01.30 14:13).

All looks well in Preview.app and PDF Studio 2019, but Adobe (Reader DC and 
Acrobat Pro 9) can’t open the new PDF.

I’ll try to cook up a MWE. Does anyone else experience problems with Adobe apps?

Hraban


Is this perhaps related to the thread:

[NTG-context] Minimum METAPOST code produces problematic PDF


Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


[NTG-context] \documentvariable (used in environment)

2020-07-22 Thread Alan Braslau

Hello,

I have put the following in an environment

\startenvironment MYENVIRONMENT

\setupdocument
  [metadata:title={\documentvariable{title}},
   metadata:subtitle={\documentvariable{subtitle}},
   metadata:author={\documentvariable{author}},
   metadata:keywords={\documentvariable{keywords}}]

\stopenvironment




and correct use would be

\environment MYENVIRONMENT

\startdocument [title={My title}]

\stopdocument


because, of course, the environment contains more than \setupdocument 
such as font loading that should be done before the \startdocument.


The metadata does not get set properly, having to do with expansion or 
other notions of TeX that I never seem to get right. What might be the 
proper way of handling this?


Thank you

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] \documentvariable (used in environment)

2020-07-24 Thread Alan Braslau

On 22/07/20 22:36, Wolfgang Schuster wrote:
What exactly doesn't work and do you get the same problems when you set 
the values in the following minimal example (everything has to be in the 
same file).


 begin example
\setupdocument
   [metadata:title={\documentvariable{title}},
    metadata:subtitle={\documentvariable{subtitle}},
    metadata:author={\documentvariable{author}},
    metadata:keywords={\documentvariable{keywords}}]

\startdocument [title={My title}]
\input knuth
\stopdocument
 end example

Wolfgang


Thank you, Wolfgang.

The above example does work. It fails to set the metadata if one moves 
the \setupdocument to an environment file. As you write, "everything has 
to be in the same file". This is my question, how to set these using an 
environment file, thus NOT the same file as the \startdocument in a 
project structure.


Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] \documentvariable (used in environment)

2020-07-25 Thread Alan Braslau

Thank you all.

No modes, no funniness in the environment file.

The test case works (Acroread/properties shows the Title, Author, 
Subject, and Keywords fields). However, my real case does get the other 
fields (Author, Subject, and Keywords) but contains in the Title field 
the filename (without the .tex extension) of the main file (and 
filename.tex under File).


I'll chase it down...

Alan

On 25/07/20 02:40, Henning Hraban Ramm wrote:



Am 25.07.2020 um 10:20 schrieb Wolfgang Schuster 
:

Alan Braslau schrieb am 25.07.2020 um 00:21:

On 22/07/20 22:36, Wolfgang Schuster wrote:

What exactly doesn't work and do you get the same problems when you set the 
values in the following minimal example (everything has to be in the same file).

 begin example
\setupdocument
[metadata:title={\documentvariable{title}},
 metadata:subtitle={\documentvariable{subtitle}},
 metadata:author={\documentvariable{author}},
 metadata:keywords={\documentvariable{keywords}}]

\startdocument [title={My title}]
\input knuth
\stopdocument
 end example

Wolfgang


Thank you, Wolfgang.

The above example does work. It fails to set the metadata if one moves the \setupdocument 
to an environment file. As you write, "everything has to be in the same file".

The requirement was only necessary for the example to check if the metadata end 
up in the PDF file. You could have a environment file for \setupdocument but 
the goal here was to check the resulting metadata in the PDF.

This is my question, how to set these using an environment file, thus NOT the 
same file as the \startdocument in a project structure.

The problem is something in your environment/style file which causes a problem 
with the \setupdocument setup. What you should do to find the sulprit is:

1. Make a copy of your document
2. Remove all text between \startdocument and \stopdocument and add some dummy 
text (like in my example) to ensure ConTeXt produces a PDF
3. Remove setups from your environment (but keep the \setupdocument setup) file 
until the metadata appears in the PDF


A typical case if something in an environment doesn’t work, but in a single 
file: Are there modes involved? Maybe your \setupdocument is within a 
\startmode ... \stopmode that doesn’t get activated.

Best, Hraban

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___



___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] BibTeX inproceedings entries not rendered correctly in APA style

2021-05-24 Thread Alan Braslau
On Mon, 24 May 2021 17:53:49 -0400
Rik Kabel  wrote:

> This is intended. Or rather, it is a side-effect of the intended
> behavior.
> 
> If you add an editor ("editor={Baz, Bar}") you will get something
> like:
> 
> Foo, B. (1983). Title of the paper. In B. Baz (Ed.), /Booktitle/.
> Author.
> 
> And if you then add a publisher ("publisher={Paymefirst}") you will
> get:
> 
> Foo, B. (1983). Title of the paper. In B. Bar (Ed.), Booktitle.
> Paymefirst.
> 
> The APA presumes that you have both an editor and a publisher for
> pieces contained in other works. It calls for the use of the author
> as publisher if no publisher is present. It is silent about what to
> do if you have no editor.

It looks like a missing editor field should be caught. What should the
rule be?

Actually, @inproceedings should not be used without an editor - makes
no sense. If the author of the paper happens to be the editor, then the
.bib data file should define this with an editor= field.

We can change the behavior if a clear case can be made as to what
fallback would make sense. Keep in mind the dictum: "garbage in/garbage
out"...

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] BibTeX inproceedings entries not rendered correctly in APA style

2021-05-25 Thread Alan Braslau
On Mon, 24 May 2021 23:10:34 -0400
Rik Kabel  wrote:

> 
> On 5/24/2021 22:12, Alan Braslau wrote:
> > On Mon, 24 May 2021 17:53:49 -0400
> > Rik Kabel  wrote:
> >
> >> This is intended. Or rather, it is a side-effect of the intended
> >> behavior.
> >>
> >> If you add an editor ("editor={Baz, Bar}") you will get something
> >> like:
> >>
> >>  Foo, B. (1983). Title of the paper. In B. Baz (Ed.),
> >> /Booktitle/. Author.
> >>
> >> And if you then add a publisher ("publisher={Paymefirst}") you will
> >> get:
> >>
> >>  Foo, B. (1983). Title of the paper. In B. Bar (Ed.),
> >> Booktitle. Paymefirst.
> >>
> >> The APA presumes that you have both an editor and a publisher for
> >> pieces contained in other works. It calls for the use of the author
> >> as publisher if no publisher is present. It is silent about what to
> >> do if you have no editor.
> > It looks like a missing editor field should be caught. What should
> > the rule be?
> >
> > Actually, @inproceedings should not be used without an editor -
> > makes no sense. If the author of the paper happens to be the
> > editor, then the .bib data file should define this with an editor=
> > field.
> >
> > We can change the behavior if a clear case can be made as to what
> > fallback would make sense. Keep in mind the dictum: "garbage
> > in/garbage out"...
> >
> > Alan
> 
> For the case of works within works (inproceedings, inbook,
> incollection, perhaps conference) I would think that the simplest
> solution is to simply drop it, so that in the example above one would
> simply get:
> 
> Foo, B. (1983). Title of the paper. In /Booktitle/. Paymefirst.
> 
> Although I do think that, at least for inproceedings, lack of an
> editor should at least be flagged. A simple compilation of works may
> have no named editor, of I see no reason to require it for inbook or 
> incollection. Cheap publishers regularly put out such collections of 
> out-of-copyright works.
> 
> The implicit assumption that a work with no documented publisher is a 
> self-published work is not especially to my liking -- publishers may 
> have good reason to not identify themselves (think of the publishers
> of the works of Spinoza and, in part, Voltaire) -- but I understand
> that the APA thinks it important. Of course, if you cannot document
> the publisher for an entry, you can explicitly list it as unknown or
> /sine nomine/, as appropriate, to avoid the infelicity of having the
> author's name just stuck in there.

I sent a simple fix to Hans that handles the missing editor, silently.
Someone who would want "Anonymous" or "unknown", or anything else can
always put editor="Anonymous", etc. in their .bib database.

Alan

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] BibTeX inproceedings entries not rendered correctly in APA style

2021-05-28 Thread Alan Braslau
On Thu, 27 May 2021 20:21:55 - (UTC)
Nicola  wrote:

> Thank you all for the precious comments.
> 
> The current LMTX appears to have almost fixed my issue, except that
> inproceedings entries without a publisher have the text "Author"
> instead of the publisher's name.
> 
> I must say that I have no requirement to use the APA style
> specifically; I do it only because it uses the format (Name, Year)
> for the citation. I guess that I could use another style (aps seems
> fine) and just customize the citation format. I have tried with
> 
> \usebtxdataset[main.bib]
> \setupbtx[default:cite][alternative=authoryear]
> \usebtxdefinitions[aps]
> 
> but it seems that the setup command has no effect: the citations still
> use numbers.

APS is an inherently numbered citation format.

If you have not defined a publisher, how should ANY format place the
undefined publisher's name?

I'm not sure what you want.

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] BibTeX inproceedings entries not rendered correctly in APA style

2021-05-28 Thread Alan Braslau
On Fri, 28 May 2021 13:02:10 -0400 (EDT)
Aditya Mahajan  wrote:

> > If you have not defined a publisher, how should ANY format place the
> > undefined publisher's name?  
> 
> Simply leave it blank?

If there is no publisher, then @unpublished is a better category. APA
explicitly, and for good reason, accounts for self-publishing,
indicating that the Author was the publisher. This is why it works that
way.

If a publisher does not exist, was it published?

If the publisher is unknown, then why not state that:
publisher="unknown publisher", or whatever?

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] BibTeX inproceedings entries not rendered correctly in APA style

2021-05-28 Thread Alan Braslau
On Fri, 28 May 2021 19:52:19 - (UTC)
Nicola  wrote:

> > If there is no publisher, then @unpublished is a better category.
> > APA explicitly, and for good reason, accounts for self-publishing,
> > indicating that the Author was the publisher.  
> 
> Ah ok, that explains the output I was obtaining. So, I am using the
> wrong bibliographic style for my purposes. In practice, at least in
> Computer Science, publishers (and also editors) are often omitted in
> references (it's more a "don't care", rather than a "don't know"
> thing, though).
> 
> > If a publisher does not exist, was it published?
> >
> > If the publisher is unknown, then why not state that:
> > publisher="unknown publisher", or whatever?  
> 
> Strictly speaking, your reasoning makes perfect sense, and I am all
> for enforcing constraints if a given bibliographic style requires
> them. But then, there might be alternatives for when one does not
> need to adhere to those styles. Does ConTeXt (LMTX) currently provide
> anything else besides apa and aps?
> 
> I have read the BibTeX manual looong time ago, but I remember that
> there were mandatory and optional fields for each reference type. My
> memory may fail me, but I think that Editor and Publisher were not
> mandatory fields for inproceedings and article (I think Publisher is
> mandatory for book). Is there a bibliographic style in ConTeXt that
> follows those rules?
> 
> Bibliography management is very sophisticated in ConTeXt (much more
> than LaTeX) and I have not grasped all of its details yet. It seems
> to me that it has also evolved quite a bit in recent years. So, the
> "ConTeXt way" of doing bibliographies still eludes me to some extent.

In writing the ConTeXt bibliography system, we tried to base this on
references, indeed following the original bibtex manual for its
definitions. The APA style follows the APA style guide as best as
possible.

The APS style is intended as a simple example of a numbered
bibliography minimalist style.

Multiple other styles exist out there, more or less well defined. The
problem is that most of them are not very rigorous, and they are
greatly abused. Many publishers follow their own (quirky) bibliography
styles.

The Context system started out as sort of a database handling
subsystem, useful in publishing. It is entirely tune-able, through
setups and parameters. However, the system is complex, so the
customization is not quite as easy as originally intended. Note that
the original bibtex system was conceived in order to have this
configurability, however few were those who mastered writing
bibliography styles, and even carefully crafted styles, for example as
implemented by the APS RevTeX, were buggy and had a number of known,
serious limitations requiring manual intervention.

We could, and have had the intention of, writing other bibliography
styles. But there must be a motivation as well as a clearly defined
specification, for otherwise we will be heading down a rabbit hole of
differing expectations and endless tweaking.

As to "don't care" concerning publishers, this is not very academic.
Indeed, many famous books have been published by various publishers, in
particular for different markets. It is important to say, for each one
might be slightly different, have different pagination for example, and
even certain edits of the text. One might also not pay attention to the
edition, but this too can lead to major differences (even, and
especially in computer science).


Thomas Schmitz, one of the originators of the bibliography project,
will tell you to take the APA style as a model, and then modify it as
you wish to your own needs. I further took this to heart, trying to
write the macros as somewhat standard definitions that one could modify
as needed without breaking the entire system.

And then there are clearly bugs that can be fixed. In the case of a
missing publisher, it is not simply left blank because the APA style
explicitly tells us to put "Author" when there is no defined publisher,
so this is a feature, not a bug.

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] upload / some new math stuff

2021-06-11 Thread Alan Braslau
On Thu, 10 Jun 2021 23:35:14 +0200
Hans Hagen  wrote:

> So, assuming that one installs these fonts:

It looks modern (and new). Why not include it in the lmtx distribution?

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


ntg-context@ntg.nl

2021-06-15 Thread Alan Braslau
On Tue, 15 Jun 2021 13:07:04 +0200
Hans Hagen  wrote:

> the windows mupdf viewer is somewhat crippled (no selection) but 
> searching for something shows the right bbox

I do not know about Windows ports, but mupdf and mupdf-gl differ, not
only in their rendering but also in their keystrokes and mouse bindings.

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


ntg-context@ntg.nl

2021-06-15 Thread Alan Braslau
On Tue, 15 Jun 2021 20:29:26 +0200
Hans Hagen  wrote:

> On 6/15/2021 7:53 PM, Alan Braslau wrote:
> > On Tue, 15 Jun 2021 13:07:04 +0200
> > Hans Hagen  wrote:
> >   
> >> the windows mupdf viewer is somewhat crippled (no selection) but
> >> searching for something shows the right bbox  
> > 
> > I do not know about Windows ports, but mupdf and mupdf-gl differ,
> > not only in their rendering but also in their keystrokes and mouse
> > bindings.  
> yes there are windows versions, but just as rudimentary and no text 
> selection (copy)

"The right mouse button selects a region and copies the marked text to
the clipboard."

Maybe this is broken (as Luigi suggests) or requires some special
setup/configuration?

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


ntg-context@ntg.nl

2021-06-15 Thread Alan Braslau
On Tue, 15 Jun 2021 20:57:09 +0200
Hans Hagen  wrote:

> On 6/15/2021 8:54 PM, Alan Braslau wrote:
> > On Tue, 15 Jun 2021 20:29:26 +0200
> > Hans Hagen  wrote:
> >   
> >> On 6/15/2021 7:53 PM, Alan Braslau wrote:  
> >>> On Tue, 15 Jun 2021 13:07:04 +0200
> >>> Hans Hagen  wrote:
> >>>  
> >>>> the windows mupdf viewer is somewhat crippled (no selection) but
> >>>> searching for something shows the right bbox  
> >>>
> >>> I do not know about Windows ports, but mupdf and mupdf-gl differ,
> >>> not only in their rendering but also in their keystrokes and mouse
> >>> bindings.  
> >> yes there are windows versions, but just as rudimentary and no text
> >> selection (copy)  
> > 
> > "The right mouse button selects a region and copies the marked text
> > to the clipboard."
> > 
> > Maybe this is broken (as Luigi suggests) or requires some special
> > setup/configuration?  
> I was refereing to a textual copy, not an image one. So one selects 
> 'abc' and gets 'abc' (with the right unicodes).

That is what I get using mupdf (x11).

I found this comment:
"Copy-paste will only work if mupdf-gl is built against the bundled copy
of FreeGLUT, which adds the functions glutSetClipboard and
glutGetClipboard."

And, for example:
https://github.com/NixOS/nixpkgs/issues/104017
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


ntg-context@ntg.nl

2021-06-16 Thread Alan Braslau
On Wed, 16 Jun 2021 17:14:22 +0200
luigi scarso  wrote:

> > Did you try this one?
> >
> > http://www.xpdfreader.com/download.html  
> 
> 
> I doesn't workunder ubuntu 20.04
> libicudata.so.56 => not found
> I have libicudata.so.66

The ubuntu package must be built incorrectly, for I have
/usr/local/lib/libicudata.so.69
and xpdf works fine (freebsd).

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] Install script not working

2021-06-27 Thread Alan Braslau
On Thu, 24 Jun 2021 23:30:00 +0200
Hans Hagen  wrote:

> -- on freebsd always (does anyone know an env var?)

On FreeBSD, there is `uname -m` but also `hostname`.
I find the environment variable $HOST to be set, but I am not sure that
this is done by default (for standard installations).

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] log: use \thinspace instead of \,

2021-06-29 Thread Alan Braslau
On Tue, 29 Jun 2021 14:06:02 +0200
Henning Hraban Ramm  wrote:

> Maybe, but in running text I use \, all the time e.\,g. in
> abbreviations or for numbers (10\,000). At least in German typography
> these “spatiums” are necessary.

In French typography as well.

Indeed,
American: 10,000.00
French:   10\,000,00
(and other languages).

This is quite readable, and much preferred to the use of any kind of
macro that might format numbers according to language.

I find that students often need such helpers when deciphering many
digits.

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] Different authorconversion for citation alternatives and bibliographic entries

2021-06-30 Thread Alan Braslau

On 30/06/21 02:20, Ágoston Volcz wrote:

2. Entries in the bibliography and fist time citations must have
'normal' authorconversion, while consequent citations must have
'normalshort'. For consequent citations I defined the 'authortitle'
alternative.
In the thesis I have:
```
\usebtxdataset[default][literature.bib]
\usebtxdefinitions[deu]
\setupbtx[deu]
```
A snippet from the publ-imp-deu.mkvi:
```
\definebtx
 [deu:list]
 [deu]
 [authorconversion=normal]

\definebtx
 [deu:cite]
 [deu]
 [authorconversion=normalshort,
  alternative=authortitle]

\startsetups btx:deu:list:book
{\sc \btxflush{author}}\btxcolon \btxflush{title}
\btxdoif{subtitle}{\btxperiod\btxflush{subtitle}}\btxperiod
\btxflush{address}\btxcolon \btxflush{publisher} \btxflush{year}
\btxdoif{series}{ (\btxflush{series} \btxflush{volume})}\btxperiod
\stopsetups

```
In the setup and definition, the fields I defined do get into the
citation correctly, but the authorconversion remains 'normal'. If I
comment out the lines which set up 'normal' authorconversion for the
list, everything, including the bibliography and 'entry' type
citations get 'normalshort'. Is that a bug or am I missing something?


I am not sure that I understand your snippet (a mwe would be useful).
However, it appears that your setup is for the "list" rendering of a 
book, and you do specify authorconversion=normal for lists.


Keep in mind that the bibliography system uses inheritance so it is 
important to set options in the right places. Once everything gets 
initialized, changing a higher-level parameter might not propagate to 
lower-level instances if they have already been defined, the inheritance 
taking place at definition time.


--
Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] hyphenate nothyphenated

2021-06-30 Thread Alan Braslau

On 29/06/21 05:52, Hans Hagen wrote:

well, you ask for nothyphenated; we could define

\permanent\protected\def\-%
   {\begingroup
    \hyphenationmode\explicithyphenationmodecode\explicitdiscretionary
    \endgroup}

i will ponder this


I believe that \- defines an *optional* hyphenation point.
Specifying nothyphenated should not hyphenate, even at optional points.
The author can otherwise use hyphenated and arrange to help the words 
get hyphenated at certain points.


Perhaps a new "optional" hyphenation point macro can be added that would 
have super-powers to override the align parameter. There would be no 
surprises using such a feature.


--
Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] hyphenate nothyphenated

2021-06-30 Thread Alan Braslau

On 30/06/21 12:25, Hans Hagen wrote:

On 6/30/2021 7:35 PM, Alan Braslau wrote:

On 29/06/21 05:52, Hans Hagen wrote:

well, you ask for nothyphenated; we could define

\permanent\protected\def\-%
   {\begingroup
    \hyphenationmode\explicithyphenationmodecode\explicitdiscretionary
    \endgroup}

i will ponder this


I believe that \- defines an *optional* hyphenation point.
Specifying nothyphenated should not hyphenate, even at optional points.
The author can otherwise use hyphenated and arrange to help the words 
get hyphenated at certain points.


Perhaps a new "optional" hyphenation point macro can be added that 
would have super-powers to override the align parameter. There would 
be no surprises using such a feature.

We can't use \= unless we drop the \= being macros (anyone using that?)

We can also use \+ which currently is just "+" because it needs some 
value (sometimes it gets a local meaning).


So here is something to ponder:

\pushoverloadmode \unprotect

     \permanent\protected\def\superexplicitdiscretionary
   {\begingroup
    \hyphenationmode\explicithyphenationmodecode\explicitdiscretionary
    \endgroup}

     \aliased\let\lang_explicit_discretionary_nop\explicitdiscretionary

     \permanent\protected\def\lang_explicit_discretionary_yes-%
   {\superexplicitdiscretionary}

     \permanent\protected\def\-%

{\doifelsenextcharcs-\lang_explicit_discretionary_yes\lang_explicit_discretionary_nop} 



     \protect \popoverloadmode

     \nohyphens \hsize 1mm

     test\-test \par test\--test

\stoptext


\= macron accent (bar) should not be changed.

\-- is a good suggestion, like insisting, and should not get confused 
with -- (en dash).



--
Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] Different authorconversion for citation alternatives and bibliographic entries

2021-06-30 Thread Alan Braslau

On 30/06/21 12:59, denis.ma...@unibe.ch wrote:

Hi,


-Ursprüngliche Nachricht-
Von: ntg-context  Im Auftrag von Ágoston Volcz
Gesendet: Mittwoch, 30. Juni 2021 10:20
An:ntg-context@ntg.nl
Betreff: [NTG-context] Different authorconversion for citation alternatives and
bibliographic entries

Hi there,

My university has special requirements for the theses I submit.
Layout, fonts etc. are pretty straightforward to set up in ConTeXt.
The one part I'm struggling with is citations / bibliography.
I have to use the german citation style with footnotes. Essentially the first 
time I
cite something, I have to put the full entry in a footnote. From the second time
on, I only have to put a shorter entry in the footnotes.

Is this first citation vs other citations thing currently possible with ConTeXt? I was 
thinking that there was no proper support for note style citations in ConTeXt? Has that 
changed? I remember reading the phrase "We may add additional citation styles if 
there demand and clear requirements exist." So what's the current state of affairs 
here?

Denis


Indeed (one can always use \footnote{} but that might not be a good 
substitute for a proper footnote citation style.


I do not use footnote citations as a general style (and personally 
dislike it, finding them somewhat distracting and sloppy). Yet these are 
popular in many fields and there is no reason not to support it.


--
Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] Different authorconversion for citation alternatives and bibliographic entries

2021-06-30 Thread Alan Braslau
On Wed, 30 Jun 2021 19:40:06 +
 wrote:

> > -Ursprüngliche Nachricht-
> > Von: Alan Braslau 
> > Gesendet: Mittwoch, 30. Juni 2021 21:11
> > An: mailing list for ConTeXt users ; Maier,
> > Denis Christian (UB) 
> > Betreff: Re: [NTG-context] Different authorconversion for citation
> > alternatives and bibliographic entries
> > 
> > On 30/06/21 12:59, denis.ma...@unibe.ch wrote:  
> > > Hi,
> > >  
> > >> -Ursprüngliche Nachricht-
> > >> Von: ntg-context  Im Auftrag von
> > >> Ágoston Volcz
> > >> Gesendet: Mittwoch, 30. Juni 2021 10:20 An:ntg-context@ntg.nl
> > >> Betreff: [NTG-context] Different authorconversion for citation
> > >> alternatives and bibliographic entries
> > >>
> > >> Hi there,
> > >>
> > >> My university has special requirements for the theses I submit.
> > >> Layout, fonts etc. are pretty straightforward to set up in
> > >> ConTeXt. The one part I'm struggling with is citations /
> > >> bibliography. I have to use the german citation style with
> > >> footnotes. Essentially the first time I cite something, I have
> > >> to put the full entry in a footnote. From the second time on, I
> > >> only have to put a shorter entry in the  
> > footnotes.  
> > > Is this first citation vs other citations thing currently
> > > possible with ConTeXt? I  
> > was thinking that there was no proper support for note style
> > citations in ConTeXt? Has that changed? I remember reading the
> > phrase "We may add additional citation styles if there demand and
> > clear requirements exist." So what's the current state of affairs
> > here?  
> > >
> > > Denis  
> > 
> > Indeed (one can always use \footnote{} but that might not be a good
> > substitute for a proper footnote citation style.
> > 
> > I do not use footnote citations as a general style (and personally
> > dislike it, finding them somewhat distracting and sloppy). Yet
> > these are popular in many fields and there is no reason not to
> > support it.  
> 
> So what would be needed to make add real support for it?

First of all, come to a consensus on a clear style guide to base this
on, so as not to run after ambiguous and perhaps contradictory
specifications. This would be distinct from the APA (author-year) model
as well as from the minimalist APS (numbered) style. Could this perhaps
be the Chicago style? (does that have a footnote specification?)

Secondly, identify users who would be willing to spend time testing and
giving feedback.

Thirdly, motivate Hans and myself to spend time on this (implementing
or helping implement), for neither of us use the footnote style.

So it can be done, and such a model is presently missing.

Alan

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] hyphenate nothyphenated

2021-07-01 Thread Alan Braslau
On Thu, 1 Jul 2021 00:12:40 +0200
Hans Hagen  wrote:

> >> \= macron accent (bar) should not be changed.
> >>
> >> \-- is a good suggestion, like insisting, and should not get
> >> confused with -- (en dash).  
> > 
> > Is there some problem to make it just another option.
> > 
> > \enabledirectives[hyphenators.discretionary=hyphenated|nothyphenated]
> >  
> or maybe some key is \setuplanguages (what key)

Why not, but this would be somewhat obscure for the average user who
would have to identify and then set this option in all documents...

The \-- extension is kind-of nice, obscure in its own way but good
functionally. The risk is of users confusing this with the en ligature,
something that unicode users avoid...

Maybe implement both solutions (setup affecting \- as well as \--) in
Context?

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] hyphenate nothyphenated

2021-07-01 Thread Alan Braslau
On Thu, 1 Jul 2021 17:57:28 +0200
Steffen Wolfrum  wrote:

> > Am 01.07.2021 um 17:54 schrieb Alan Braslau
> > :
> > 
> > On Thu, 1 Jul 2021 00:12:40 +0200
> > Hans Hagen  wrote:
> >   
> >>>> \= macron accent (bar) should not be changed.
> >>>> 
> >>>> \-- is a good suggestion, like insisting, and should not get
> >>>> confused with -- (en dash).
> >>> 
> >>> Is there some problem to make it just another option.
> >>> 
> >>> \enabledirectives[hyphenators.discretionary=hyphenated|nothyphenated]
> >>>   
> >> or maybe some key is \setuplanguages (what key)  
> > 
> > Why not, but this would be somewhat obscure for the average user who
> > would have to identify and then set this option in all documents...
> > 
> > The \-- extension is kind-of nice, obscure in its own way but good
> > functionally. The risk is of users confusing this with the en
> > ligature, something that unicode users avoid...
> > 
> > Maybe implement both solutions (setup affecting \- as well as \--)
> > in Context?  
> 
> 
> And what about \– (U+2013)?

Now THAT gets confusing!

Why not U+2010 (HYPHEN), the anti-U+2011 (NON BREAKING HYPHEN)
vs. U+002D (HYPHEN-MINUS). What a can of worms...

(which is why I like the \-- syntax)


Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] LMTX: different output if dots are used in the file name

2021-07-07 Thread Alan Braslau
Windows, I believe, does not take kindly to filenames containing
multiple dots.

Therefore, Hans never uses such filenames and does not expect them,
either, so I am not surprised that this yields unpredictable results.

An unfortunate side-effect of dealing with Windows.

Alan


On Tue, 6 Jul 2021 20:08:22 -0400
"T. Kurt Bond"  wrote:

> This is something that has caused me problems in the past, too.
> 
> On Tue, Jul 6, 2021 at 4:51 PM Marco Patzer 
> wrote:
> 
> > On Thu, 28 May 2020 18:18:51 +0200
> > Hans Hagen  wrote:
> >  
> > > > LMTX:
> > > > 10.10.10.tex → 10.10 (not even a PDF suffix)
> > > > 10.10.11.tex → 10.10 (file 10.10 is over-written)
> > > > 11.10.11.tex → 11.10 (no suffix)  
> >
> > I've checked again with 2021.07.06 18:49 LMTX
> >
> >   10.10.10.tex → 10.10.pdf + 10.log
> >   10.10.11.tex → 10.10.pdf (file 10.10.pdf and 10.log are
> > over-written) 11.10.11.tex → 11.10.pdf
> >  
> > > > MkIV is way more predictable and consistent in that regard.  
> > > I'll look at it but not today ... first I need to play with some
> > > other (neat) stuff and run tests.  
> >
> > A gentle reminder.
> >
> > As by my tests, something has changed in the last months, but the
> > behaviour is still weird (e.g. log files differ from pdf file or
> > 10.10.10.tex results in 10.10.pdf).
> >
> > Is there a chance you can look at that at some point?
> >
> > Marco
> >
> > ___
> > If your question is of interest to others as well, please add an
> > entry to the Wiki!
> >
> > maillist : ntg-context@ntg.nl /
> > http://www.ntg.nl/mailman/listinfo/ntg-context
> > webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
> > archive  : https://bitbucket.org/phg/context-mirror/commits/
> > wiki : http://contextgarden.net
> >
> > ___
> >  
> 
> 

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] LMTX: different output if dots are used in the file name

2021-07-08 Thread Alan Braslau
On Wed, 7 Jul 2021 21:57:27 +0200
Ulrike Fischer  wrote:

> Am Wed, 7 Jul 2021 12:25:29 -0600 schrieb Alan Braslau:
> 
> > Windows, I believe, does not take kindly to filenames containing
> > multiple dots.
> > 
> > Therefore, Hans never uses such filenames and does not expect them,
> > either, so I am not surprised that this yields unpredictable
> > results.
> > 
> > An unfortunate side-effect of dealing with Windows.  
> 
> Sorry but this is nonsense. I have seen many files with lots of dots
> in windows and it works fine.

Not nonsense: some MS/Windows filesystems couldn't deal with multiple
dots in the filename. That my *now* be history, but wasn't.

What is clear is that (perhaps due to this legacy), many programs and
packages do not expect to find filenames having many dots. Indeed,
*some* filesystem specifications even use "." to delimit file system
hierarchy (similarly like / and \). Lua also uses this in table
specifications, as does MetaPost for token separation, not mentioning
structures in C (and C++). The bottom line is that using "." in a
filename is best to be avoided, as are spaces in order to avoid
surprises.

As to "nonsense" and "Windows bashing", give me a break!

(and for Hans, the VMS ";" version specification is a different
feature).

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] Extract bib entries used in a document

2021-07-15 Thread Alan Braslau

On 15/07/21 21:53, Benjamin Buchmuller wrote:

I was wondering if there is a way to get the internal bibliography manager to 
write out a .bib (or XML or Lua table) containing only the entries used in a 
document?

Somewhat similar to BibTeX 
(https://tex.stackexchange.com/questions/41821/creating-bib-file-containing-only-the-cited-references-of-a-bigger-bib-file).

I guess it must be internally created, but I don't see, at least from the 
manual, a command like 
\exportbtxdataset[default][way=bytext][used_references.bib].

Two use cases:

(1) Sharing a clean bib file with someone.

(2) Merging bib files from different sources based on the document. (Or even by 
chapter.)

Thanks for your reply.


Benjamin


\savebtxdataset [my.bib] [criterium=chapter]

for example.
--
Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] Harvard bibliography style

2021-07-16 Thread Alan Braslau

On 16/07/21 20:05, Jorge Manuel wrote:

Dear Sirs

Is there a way to set my bibliography style to Harvard specifications?

Tanks four your support

Have a nice day


Jorge Magalhães


There is no Harvard bibliography specification, but the system is 
designed to be totally configurable.


What is exactly the specification? The best way to proceed is to start 
from an existing specification such as APA for an author-years system 
and adapt it to your specific needs. I can help you with this.


--
Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] mp-geo Metapost package with ConTeXt

2021-07-16 Thread Alan Braslau

On 16/07/21 21:51, Hans Hagen wrote:

On 7/16/2021 4:53 PM, Gavin Polhemus wrote:

P.S. I marked the location of our local ConTeXt users group on the 
map, in case any of you want to visit.
1/3rd of your user group fled the country and is way closer by where i 
live now,


And in the same time zone!

--
Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] Problem getting lmtx version up

2021-07-16 Thread Alan Braslau

On 16/07/21 21:47, Hans Hagen wrote:


would be a pitty because i like the ubuntu interface that we have on it 
more than the rather ugly default rpi one (an ubuntu install is also 
more comfortable) ... when we go headless we might give opensuse a try 
(actually we had debian first but it was a pain with the ssd on usb so 
we gave up on that and harald made it work with ubuntu)


wondering: does the 32 bit run on 64 boit with some extra libs installed?

of courese someone can send us a bunch of rpi's .. one can even build a 
simple rack setup, or maybe we can install some vm on the rpi ... 
(reminds me to consider windows 11 on the pi for testing windows arm)


Freebsd on arm64 is now a Tier 1 architecture. ;-)

--
Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


[NTG-context] 16-bit png

2008-02-14 Thread Alan BRASLAU
Hello,

I am having problems including 16-bit png files in ConTeXt. In the following 
example, red.png is a 800x600 image of red pixels. The resulting test.pdf 
shows a BLACK rectangle. (The same problem exists with real images.)

However, I can produce the desired result with my installation under 
pdflatex...

$ cat test.tex
\starttext
\externalfigure[red][width=\textwidth]
\stoptext
$ file red.png
red.png: PNG image data, 800 x 600, 16-bit/color RGB, non-interlaced
$ texexec test

$ cat test2.tex
\documentclass{article}
\usepackage{graphicx}
\begin{document}
\includegraphics[width=\textwidth]{red}
\end{document}
$ pdflatex test2

My distribution (debian + texlive) uses
This is pdfTeXk, Version 3.141592-1.40.3 (Web2C 7.5.6)
in both cases.

Does this have something to do with \pdfimagehicolor?

Thank you
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] 16-bit png

2008-02-15 Thread Alan BRASLAU
On Friday 15 February 2008 09:23:12 Taco Hoekwater wrote:
> Alan BRASLAU wrote:
> > $ cat test.tex
>
>\starttext
>\pdfimagehicolor=1
>\externalfigure[red][width=\textwidth]
>\stoptext
>
> There, fixed that.
>
> That setting could go into the context core, though.
>
> > Does this have something to do with \pdfimagehicolor?
>
> I am always surprised how many people ask a question,
> guess the correct answer themselves, but don't actually
> attempt to see if it works :-)
>
> Best wishes,
> Taco

Thanks for the very rapid answer.
However, no, neither of the proposed solutions work.
1. Of course, I tried "\pdfimagehicolor=1" without results before posting the 
question. (I would NEVER think about asking for help without trying different 
possibilities myself...)
2. "\setupcolors[state=start]" was also in my original file, but did not seem 
to make a difference, so I posted a most simplified example.

What to do? I would think that there is something wrong with my configuration 
(debian/unstable), however pdflatex works just fine.

Alan

(P.S. Why would one need to specify \pdfimagehicolor in any case; From a 
user's point of view, shouldn't it just work transparently?) 
--- Begin Message ---
Alan BRASLAU wrote:
> 
> $ cat test.tex

   \starttext
   \pdfimagehicolor=1
   \externalfigure[red][width=\textwidth]
   \stoptext

There, fixed that.

That setting could go into the context core, though.

> Does this have something to do with \pdfimagehicolor?

I am always surprised how many people ask a question,
guess the correct answer themselves, but don't actually
attempt to see if it works :-)

Best wishes,
Taco
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___
--- End Message ---
--- Begin Message ---
Hi

Does adding \setupcolors[state=start] at the top of the context file help?

Hans, how about enabling colors by default in mkiv?

Aditya

On Thu, 14 Feb 2008, Alan BRASLAU wrote:

> Hello,
>
> I am having problems including 16-bit png files in ConTeXt. In the following
> example, red.png is a 800x600 image of red pixels. The resulting test.pdf
> shows a BLACK rectangle. (The same problem exists with real images.)
>
> However, I can produce the desired result with my installation under
> pdflatex...
>
> $ cat test.tex
> \starttext
> \externalfigure[red][width=\textwidth]
> \stoptext
> $ file red.png
> red.png: PNG image data, 800 x 600, 16-bit/color RGB, non-interlaced
> $ texexec test
>
> $ cat test2.tex
> \documentclass{article}
> \usepackage{graphicx}
> \begin{document}
> \includegraphics[width=\textwidth]{red}
> \end{document}
> $ pdflatex test2
>
> My distribution (debian + texlive) uses
> This is pdfTeXk, Version 3.141592-1.40.3 (Web2C 7.5.6)
> in both cases.
>
> Does this have something to do with \pdfimagehicolor?
>
> Thank you
> ___
> If your question is of interest to others as well, please add an entry to the 
> Wiki!
>
> maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
> archive  : https://foundry.supelec.fr/projects/contextrev/
> wiki : http://contextgarden.net
> ___
>
>
>
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___
--- End Message ---
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] 16-bit png

2008-02-15 Thread Alan BRASLAU
On Friday 15 February 2008 10:36:02 Taco Hoekwater wrote:
> xpdf (and its derivatives) does not support 16-bit color.
> No warning, the pdf is just displayed incorrectly.
>
> It 'works' in pdflatex in xpdf because the file does not contain a
> 16-bit image at all, it is automatically downgraded.
>
> If you want that same effect in context, set
>\pdfminorversion=4 % or some other low number
>
> You document will be loosing functionality, and gaining portability.
>
> Best wishes,
> Taco

I am posting this to the mailing list to share the answer/solution.
\externalfigure[16-bit.png]
indeed works correctly. However, xpdf/kpdf/etc. do not handle 16-bit color, 
unlike acroread and ghostview. Note also that pdflatex automatically 
downgrades 16-bit color images to 8-bit.

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] colors in pgf within context

2008-02-19 Thread Alan BRASLAU
Hello,

Another problem with PGF+ConTeXt is the handling of cmyk colors:

\usemodule[tikz]
\setupcolors[state=start]
\definecolor[my_yellow][c=0,m=0.3,y=0.94,k=0]
\starttext
\startcolor[my_yellow]
Yellow text.
\stopcolor
\starttikzpicture
\fill[my_yellow] (0,0) circle(1);
\stoptikzpicture
\stoptext

CMYK colors work in ConTeXt but do not get passed correctly to PGF/TikZ.
A work-around is to transform to rgb :
\definecolor[my_yellow][r=0.98,g=0.698,b=0.09] % 250,178,23 #FAB217

This seems to be a documented bug; Perhaps it will be fixed someday...

Alan

On Tuesday 19 February 2008 04:47:35 Aditya Mahajan wrote:
> On Mon, 18 Feb 2008, Jesse Alama wrote:
> > Hi Aditya,
> >
> > Thanks for the help -- I think I now see why there is such trouble with
> > colors in pgf and context.  It looks like one can systematically
> > transform LaTeX-like PGF examples of \color into ConTeXt examples.
> >
> > The reason why this came up is that I'm trying to go through Till
> > Tantau's "Example for Karl's Students" tutorial in the PGF/TikZ manual.
> > Has anyone managed to ConTeXt-ify that example?
>
> I did that some time back while testing tikz. I will send that file as a
> reply to this email, since I am not sure if it will go through the mailing
> list because of its size.
>
> > The example features some \definecolor's which I just did away with
> > (sadly) by simply substituting their defining values for their
> > occurences.  (This is unfortunate, but perhaps necessary until some
> > other mechanism is produced.)  The problem is that the text box to the
> > right of the picture is supposed to be colored, and with rounded
> > corners.  But the box is missing.  Look at p. 20 of
>
> The TikZ manual make a lot of uses of the xcolor syntax (e.g.
> \color{red!20}). There is no equivalent ConTeXt syntax. You need to define
> a color, say lightred, as follows
>
> \definecolor[lightred][r=0.2]
>
> For tikz key-value options, pgf works behind the scene to define
> appropriate colors, so xcolor syntax works for them. So
> \fill[fillcolor=red!20] will work as expected. However, when using \color
> inside any box, you need to follow ConTeXt syntax. So \color[red!20] will
> not work, you need to define a context color and then use that.
>
> Hope that this clarifies some things.
>
> Aditya
> ___
> If your question is of interest to others as well, please add an
> entry to the Wiki!
>
> maillist : ntg-context@ntg.nl /
> http://www.ntg.nl/mailman/listinfo/ntg-context webpage  :
> http://www.pragma-ade.nl / http://tex.aanhet.net
> archive  : https://foundry.supelec.fr/projects/contextrev/
> wiki : http://contextgarden.net
> ___
>



-- 
Alan Braslau
CEA DSM-IRAMIS-SPEC
CNRS URA 2464
Orme des Merisiers
91191 Gif-sur-Yvette cedex FRANCE
tel: +33 1 69 08 73 15
fax: +33 1 69 08 87 86
mailto:[EMAIL PROTECTED]

http://www-dna2006.cea.fr/

 .''`.
: :'  :
`. `'`
  `-
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] How could a typesetting system be today?

2008-05-30 Thread Alan BRASLAU
On Friday 30 May 2008 16:15:08 Steffen Wolfrum wrote:
> Am 30.05.2008 um 14:24 schrieb Yue Wang:
> > On 5/30/08, Steffen Wolfrum <[EMAIL PROTECTED]> wrote:
> >> Am 30.05.2008 um 09:12 schrieb Yue Wang:
> >>> advanced software, like InDesign
> >>
> >> well ...  ...
> >
> > There is no denying that many advanced features in InDesign are
> > missing in TeX(like) related software. What's more, the
> > internationalization of InDesign is better.
>
> ;o)
>
> ... you can buy a czech version or a polish version, for working with
> hebrew you may buy a hebrew or a middle eastern version ... and wasn't
> there also an arabic version to buy?
>
> With TeX you only have one piece for all ... and you can't even buy it.
>
>
> Steffen
> ___
> If your question is of interest to others as well, please add an
> entry to the Wiki!
>
> maillist : ntg-context@ntg.nl /
> http://www.ntg.nl/mailman/listinfo/ntg-context webpage  :
> http://www.pragma-ade.nl / http://tex.aanhet.net
> archive  : https://foundry.supelec.fr/projects/contextrev/
> wiki : http://contextgarden.net
> ___
>

You are also free to purchase future new versions of InDesign, Illustrator, 
and the like, not to mention that of the operating system that it runs under!

-- 
Alan Braslau
CEA DSM-IRAMIS-SPEC
CNRS URA 2464
Orme des Merisiers
91191 Gif-sur-Yvette cedex FRANCE
tel: +33 1 69 08 73 15
fax: +33 1 69 08 87 86
mailto:[EMAIL PROTECTED]

http://www-dna2006.cea.fr/

 .''`.
: :'  :
`. `'`
  `-
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Fwd: (scientific) poster

2008-06-13 Thread Alan BRASLAU
> > I have to say that for poster stuff where you have to control
> > visually the layout a GUI is not that bad.
> > So now I'm using ConTeXt for text-based projects (documents, books)
> > and Nodebox for visual related things (posters, presentations).

I am extremely happy using ConTeXt and TikZ/pgf
both for A0 posters as well as for video presentations.

-- 
Alan Braslau


___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


[NTG-context] \bTABLE and \chemical

2008-09-08 Thread Alan BRASLAU
I have not understood how tables and \chemical interact.
The second case in the minimal example below
demonstrates unexpected/incorrect centering
when using \chemical and \bTABLE.
Am I missing something?

Thanks.

Alan

\starttext
\usemodule[chemic]
\setupchemical[size=small,scale=200,width=fit,frame=off]

\starttable[|c|]
\HL
\VL chemical formula \VL\AR
\HL
\VL
\startchemical
\chemical[SIX,B,C,R,RZ][R,R,R,R,R,R]
\stopchemical
\VL\LR
\HL
\stoptable
\blank[line]

\setupTABLE[c][1][align={middle,lohi}]
\bTABLE
\bTR
\bTD
chemical formula
\eTD
\eTR
\bTR
\bTD
\startchemical
\chemical[SIX,B,C,R,RZ][R,R,R,R,R,R]
\stopchemical
\eTD
\eTR
\eTABLE

\stoptext
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] \bTABLE and \chemical

2008-09-09 Thread Alan BRASLAU
On Tuesday 09 September 2008 08:33:19 Wolfgang Schuster wrote:
> \dontleavehmode\startchemical

Thank you. This works, of course.
I suppose that it is a subtlety why this is
necessary with \bTable but not with \starttable...

Should this perhaps be included in \startchemical
or would that wreak havoc elsewhere?

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


[NTG-context] span ROWS in \starttables?

2008-09-11 Thread Alan BRASLAU
Hello,

Is there any mechanism to span ROWS in (\start)tables
similar to column spanning through \use{3}{}?
The aim is to produce a multi-row column entry
as can be done via \bTD[nr=3] in \bTABLE.

Thanks

Alan

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] span ROWS in \starttables?

2008-09-12 Thread Alan BRASLAU
On Friday 12 September 2008 08:34:15 Wolfgang Schuster wrote:
> On Fri, Sep 12, 2008 at 8:13 AM, Alan BRASLAU <[EMAIL PROTECTED]> wrote:
> >
> > Is there any mechanism to span ROWS in (\start)tables
> > similar to column spanning through \use{3}{}?
> > The aim is to produce a multi-row column entry
> > as can be done via \bTD[nr=3] in \bTABLE.
>
> \NC \use{3} ... \NC ...
>
> or
>
> \NC \THREE ... \NC ...
>
> You can find more information on the wiki page:
> http://wiki.contextgarden.net/Table
>
> Wolfgang

This mechanism spans COLUMNS not rows.

I would like to produce
-
|| b |
||---|
| A | c |
||---|
|| d |
-
using \starttables,
as can be done with:
\setupTABLE[c][1][align=lohi]
\bTABLE
\bTR \bTC[nr=3]  A \eTC\bTC b \eTC \eTR
\bTR \bTC c \eTC \eTR
\bTR \bTC d \eTC \eTR
\eTABLE

Note that:
\starttables[|c|c|]
 \HL
 \VL \VL b \VL\AR
 \DC \DL \DR
 \VL A \VL c \VL\AR
 \DC \DL \DR
 \VL \VL d \VL\LR
 \HL
\stoptables
does not quite do the job,
since the aim is to put a tall object
"A" spanning the three rows.

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] span ROWS in \starttables?

2008-09-12 Thread Alan BRASLAU
On Friday 12 September 2008 10:51:58 Wolfgang Schuster wrote:
>  \VL \smash{\vcenter{\hbox{\definedfont[Serif at 70pt]A}}} \VL c \VL\AR

Ah, TeX magic!
Indeed, I never learned about \smash. Thank you
(added a line to http://wiki.contextgarden.net/Table#Column_Spans)

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Indexing macros

2008-09-15 Thread Alan BRASLAU
On Tuesday 3 December 2002 17:57:00 Hans Hagen wrote:
> Copied from the manual source: 
...
> \index {form::entry}

The following minimal example works as expected:
\setupregister[index][au][textstyle=\sc]
\def\Index#1{\index{#1}#1}
\def\Author#1{\index{au::#1}#1}
\starttext
The \index[TeX]{\TeX}\TeX \Index{typesetting} system (\Author{Knuth})
\page
\completeindex
\stoptext

Within a large project using the above definitions, author entries in the index 
are typeset normally, not in \sc.
However, if I use
\setupregister[index][au][textstyle=boldslanted]
I do get bold-slanted entries in my large project. Have I misunderstood the 
use of setupregister, or is this a bug?
Thank you, in advance.

Alan

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Labelling figures

2008-09-16 Thread Alan BRASLAU
On Tuesday 16 September 2008 16:28:45 Hans Hagen wrote:
> >> what is the best method to add labels to a figure; I want them not only
> >> on the figure but their position should be relative to the figure size.
>
> how about just using a layer ...

You might also try pgf/tikz, according to your taste:

\usemodule[tikz]
\starttikzpicture[scale=]
\pgftext{\externalfigure[kuh][width=1cm]};
\draw (x,y) node {label};
\stoptikzpicture
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


[NTG-context] lang-ita.tex (see=)

2008-09-18 Thread Alan BRASLAU
Missing from lang-ita.tex:
\setuplabeltext[\s!fr][\v!see=voir ]

(indeed, this label needs to be set for
all of the variants fr es ca it la pt ro)

Thanks, Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Interaction and accented letters

2008-09-19 Thread Alan BRASLAU
On Friday 19 September 2008 19:00:42 Flavien Lambert wrote:
> Dear all, is there a way to put accented letters in the interaction command
> ? I tried
> \setupinteraction[state=start,
>   author={Flavien Lambert},
>   title={Optique géométrique},
>   date={Septembre 2008}]
>
> and
>
> \setupinteraction[state=start,
>   author={Flavien Lambert},
>   title={Optique g\'eom\'etrique},
>   date={Septembre 2008}]
>
> but both trials led to strange things in Acrobat Reader and Evince.

\enableregime[utf]
\mainlanguage[fr]
% before \placebookmarks :
\input spec-tst % to prevent turning accented characters
% into their unaccented counterparts
\placebookmarks[chapter,section,subsection][chapter,section]
\setupinteraction[state=start, % make hyperlinks active, etc.
option=bookmark,
title={Titre accentué},
subtitle={etc...},
author={moi-même},
keyword={français}]

Works with acroread and okular...

The "\input spec-tst" trick is somewhere in the documentation or wiki...


___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


[NTG-context] ppchtex rotation

2008-09-22 Thread Alan BRASLAU
Hello,

I am having trouble drawing rotated molecules using ppchtex.
In the example below, I would like to draw the molecule shown in (a)
rotated as shown in (b).
I would appreciate any suggestions. Thanks.

Alan

\usemodule[chemic]
\setupchemical[width=fit]

\starttext
 \startcombination[2*1]
  {\startchemical
   \chemical[SIX,B,C,MOV2,B,C,R234,RZ234,MOV5,MOV6,B,C,R561,RZ561]
[R,R,R,R,R,R]
  \stopchemical}
  {(a)}
  {\startchemical
   
\chemical[SIX,ROT2,B,C,R234,RZ234,ADJ1,ADJ1,ADJ2,B,C,ADJ1,ADJ1,ADJ4,B,C,R156,RZ156]
[R,R,R,R,R,R]
  \stopchemical}
  {(b)}
 \stopcombination
\stoptext

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


[NTG-context] luatex run: edit (E) on syntax error

2008-09-24 Thread Alan BRASLAU
Hello,

(Learning to use mkIV under Debian)

Under luatex (texexec --lua)
it seems that choosing to edit (E)
the source file upon detection of a
syntax error echos
"You want to edit file ./filename.tex at line 68"
and then continues without launching
the editor.

Has anyone else seen this?
(of course, NOBODY other than
myself makes syntax errors!)

Thanks,

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Has anybody used asymptote without LaTeX?

2008-09-28 Thread Alan BRASLAU
On 2008-09-28 04:35 Zhichu Chen wrote:
> It is said that Asymptote has supported PRC format 3D file: 
> http://asymptote.sourceforge.net/gallery/3D%20graphs/ 
> 
> I really wanna give it a try, but once I was building from the svn 
> source, I was told that I don't have LaTeX in my $PATH. I haven't 
> really been using LaTeX for a long time, and I prefer I don't need 
> to install a bunch of LaTeX programs and packages just for a 
> drawing program which, IMHO, only use LaTeX to make nice 
> labels. 
> 
> Is there any workarounds? And how to embed .prc files into 
> the .pdf document? 
>  -- 
> Best Regards
> Chen

This doesn't really answer your question
but may be of some related interest to the mailing list.

I am quite fond of pfg/tikz as a drawing package
that works rather well with plain tex, latex and context.
Asymptote is a similar tool, but it seems to be less portable.
However, it appears on the other hand to be much more powerful for 3D.
Neverless, I am sharing with this context list an impressive tikz example





-- 
Alan Braslau
CEA DSM-IRAMIS-SPEC
CNRS URA 2464
Orme des Merisiers
91191 Gif-sur-Yvette cedex FRANCE
tel: +33 1 69 08 73 15
fax: +33 1 69 08 87 86
mailto:[EMAIL PROTECTED]

http://www-dna2006.cea.fr/

 .''`.
: :'  :
`. `'`
  `-
that I have adapted to context. (I have put the author on copy.)

Basically, the only changes to the latex source are
\usepackage{preview} -> \startTEXpage \stopTEXpage
\begin{tikzpicture} -> \starttikzpicture
and a few other minor syntax adaptations...)

Alan

% What is it
% ==
%
% Examples inspired by the thread at comp.text.tex about how to convert some 
hand 
% drawn pictures into programmatic 3D sketches:
% 
http://groups.google.com/group/comp.text.tex/browse_thread/thread/a03baf5d6fa64865/f7e7b903f1d87a6a
% The sketches present stereographic and cylindrical map projections and they 
% pose some interesting challenges for doing them with a 2D drawing package 
PGF/TikZ. 
%
% The main idea is to draw in selected 3D planes and then project onto the 
canvas 
% coordinate system with an appriopriate transformation. Some highlights:
% [*] usage of pgf math engine for calculation of projection transformations 
and 
% transitions points from visible (solid lines) to invisible (dashed 
lines) on 
% meridians and latitude circles
% [*] definition of 3D plane transformation with expanded styles so that they 
are robust 
% against redefinition of macros used in their construction
% [*] usage of named coordinates (nodes) for definition of characteristic 
points in 
% local coordinate systems so that they are accessible outside of their 
plane of 
% definition
% [*] calculation of intersections points with TikZ intersection coordinate 
system
% [*] usage of 'to' path operation instead of 'arc' for marking angles to 
allow for 
% easy positioning of text labels on the curve
% [*] 3D lighting effects with shading
%
%
% Who's done it
% =
%
% Tomasz M. Trzeciak
%
%
% Distribution and use
% 
%
% Use as you see fit. Consider giving a proper attribution to the author.
%
%
% Change log
% ==
%
% 2008/08/07  posted to latex-community.org
% 2008/08/08  fixed some typos, added note about 'to' path operation to the 
description,
% fixed positioning issue of nodes and 'to' path operation as 
suggested 
% by Kjell, removed some dead code from KART picture
% 2008/09/28  adapted as an example to ConTeXt

\usemodule[tikz] 
\usetikzlibrary[calc,fadings,decorations.pathreplacing]

%% helper macros

\def\pgfmathsinandcos#1#2#3{% 
  \pgfmathsetmacro#1{sin(#3)}% 
  \pgfmathsetmacro#2{cos(#3)}% 
} 
\def\LongitudePlane#1#2#3{%
  \pgfmathsinandcos\sinEl\cosEl{#2} % elevation
  \pgfmathsinandcos\sint\cost{#3} % azimuth
  \tikzset{#1/.estyle={cm={\cost,\sint*\sinEl,0,\cosEl,(0,0)}}}
}
\def\LatitudePlane#1#2#3{%
  \pgfmathsinandcos\sinEl\cosEl{#2} % elevation
  \pgfmathsinandcos\sint\cost{#3} % latitude
  \pgfmathsetmacro\yshift{\cosEl*\sint}
  \tikzset{#1/.estyle={cm={\cost,0,0,\cost*\sinEl,(0,\yshift)}}} % 
}
\def\DrawLongitudeCircle#1#2{
  \LongitudePlane{current plane}{\angEl}{#2}
  \tikzset{current plane/.prefix style={scale=#1}}
   % angle of "visibility" 
  \pgfmathsetmacro\angVis{atan(sin(#2)*cos(\angEl)/sin(\angEl))} %
  \draw[current plane] (\angVis:1) arc (\angVis:\angVis+180:1); 
  \draw[current plane,dashed] (\angVis-180:1) arc (\angVis-180:\angVis:1); 
}
\def\DrawLatitudeCircle#1#2{
  \LatitudePlane{current plane}{\angEl}{#2}
  \tikzset{current plane/.prefix style={scale=#1}}
  \pgfmathsetmacro\sinVis{sin(#2)/cos(#2)*sin(\angEl)/cos(\angEl)} 
  % angle of "visibility"
  \pgfmathsetmacro\angVis{asin(min(1,max(\sinVis,-1)))}  
  \draw[current plane] (\angVis:1) arc (\angVis:-\angVis-180:1); 
  \draw[current plane,dashed] (180-\angVi

Re: [NTG-context] Texlive2008 and updating context

2008-09-29 Thread Alan BRASLAU
Yes, please, it is confusing.
On the Wiki different instructions appear
in several places (mkIV, minimals, TeXlive, debian...).
It would be quite nice if somebody who understands
this all could clean-up the instructions, in particular,
structure the information in a clearer fashion.
Thanks.

Alan


On Monday 29 September 2008 12:49:24 Mojca Miklavec wrote:
> I just forgot to add: the situation with updates is a bit confusing at
> the moment, but that's not your fault. Hopefully it will improve soon.
>
> Mojca
>
> On Mon, Sep 29, 2008 at 12:47 PM, Mojca Miklavec
>
> <[EMAIL PROTECTED]> wrote:
> > On Mon, Sep 29, 2008 at 9:38 AM, Mehdi Omidali wrote:
> >> Hi everyone,
> >> I have followed any thread about updating context (on Texlive2008 on
> >> ubuntu) and no success yet. After running
> >> sudo ctxtools --updatecontext
> >
> > This command doesn't necessary do what you always desire: it puts
> > ConTeXt to texmf-local. This means that any further updates that you
> > might try to make with tlmgr (TeX Live manager) will be shielded by
> > your local copy. That's OK, but you need to be aware that you then
> > have two copies of ConTeXt on your computer, and the one in
> > texmf-local will be used.
> >
> > And there is something that might bite you with this as well. TeX Live
> > is currently configured so that luatools & mtxrun binaries are taken
> > from texmf-dist/scripts. If the rest of files comes from texmf-local,
> > you might end in troubles/incompatibilities between the two versions.
> > You probably need to fix symlinks of luatools and mtxrun manually.
> >
> >> and
> >> luatools --generate
> >> everything went smooth. But after
> >>
> >> texexec --make --luatex en
> >>
> >> I got the following
> >>
> >> Should I create the cache path /home/mehdi? [yes|no] [no]
> >>
> >> and after pressing Enter I got
> >>
> >> fatal error: there is no valid (writable) cache path defined
> >
> > You need to update LuaTeX binary as well. See
> > http://wiki.contextgarden.net/Running_Mark_IV. But there are still
> > some issues. Namely, you need to fix symlinks of luatools and mtxrun
> > to point to the proper file. And you might need to remove files in
> > texmf-local that belong to ConTeXt as a result of "ctxtools
> > --updatecontext" (it's up to you which tree you want to use; I
> > overwrite files in texmf-dist with some care).
> >
> > Mojca
>
> ___
> If your question is of interest to others as well, please add an
> entry to the Wiki!
>
> maillist : ntg-context@ntg.nl /
> http://www.ntg.nl/mailman/listinfo/ntg-context webpage  :
> http://www.pragma-ade.nl / http://tex.aanhet.net
> archive  : https://foundry.supelec.fr/projects/contextrev/
> wiki : http://contextgarden.net
> ___
>


___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Thick border of one side of TR/TD

2016-05-17 Thread Alan BRASLAU
On Tue, 17 May 2016 23:09:16 +0200
Wolfgang Schuster  wrote:

> How to achieve this? 
> https://mailman.ntg.nl/pipermail/ntg-context/2016/084481.html

In case Wolfgang's answer was not clear: use "extreme" tables
(\startxtable) rather than "natural" tables (\bTABLE). This mechanism
uses 'framed' and is more flexible.

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] Overlays as background in textbackground

2016-05-18 Thread Alan BRASLAU
Here is a trick (due to Hans, of course) to produce a watermark image.
You can play with the idea in order to produce your own effect.

\definecolor [percent] [s=1,a=1,t=.9]
\externalfigure [cow] [background={foreground,color},backgroundcolor=percent]

Alan

On Wed, 18 May 2016 11:55:11 +
"Meer, Hans van der"  wrote:

> This code from three years back ia a reply to a question of placing
> an overlay background. Because the cow is very black I am curious if
> the \externalfigure can have a paramter to change the alpha of the
> cow, making it more transparent. By the way, it is not out of
> curiosity only. If possible it would forego the need to make separate
> pictures of different transparency beforehand.
> 
> > On 15 Jul 2013, at 11:22, Hans Hagen  wrote:
> > 
> > \definetextbackground [mybackgroundOverlay]
> > [mp=mpos:region:whatever]
> > 
> > \startuseMPgraphic{mpos:region:whatever}
> >for i=1 upto nofmultipars :
> >draw textext("\externalfigure[cow.pdf]") rotated 10 shifted
> > center multipars[i] ; endfor ;
> > \stopuseMPgraphic
> > 
> > \starttext
> > 
> >  \startmybackgroundOverlay
> >\dorecurse{10}{\input knuth \par}
> >  \stopmybackgroundOverlay
> > 
> > \stoptext
> 
> Hans van der Meer
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] command reference not searchable

2016-05-19 Thread Alan BRASLAU
I can search this document using any and all pdf tools to which I have
access on my system.

Alan

On Thu, 19 May 2016 16:49:31 +
"Meer, Hans van der"  wrote:

> Checked again also on a MacBook, definitely not searchable here.
> I am running El Capitan, and the command reference version is the one
> from May 17, 2016, found in one of the latest contextbeta
> distributions.
> 
> > On 19 May 2016, at 18:02, Hans Åberg  wrote:
> > 
> >   
> >> On 19 May 2016, at 17:00, Meer, Hans van der 
> >> wrote:
> >> 
> >> The command reference in file i-context.pdf is highly useful, but
> >> that document is not searchable, neither with Preview nor Adobe
> >> Reader.   
> > 
> > Searches work for me in Preview.

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] win64 : luatex is not recognize as an internal command

2016-05-24 Thread Alan BRASLAU
On Tue, 24 May 2016 18:56:44 +0200
Hans Hagen  wrote:

> or is your console slow (if you 
> run a lot from the console it makes sense to use 'conemu' as consoles
> - on any os - take some runtime due to the way tex flushes)

On any OS??

I believe that conemu is a Windows-specific terminal emulator.

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] Simple font size changes command

2016-06-12 Thread Alan BRASLAU
On Thu, 9 Jun 2016 21:47:07 +
 wrote:

> Dear all,
> 
> 
> In a simple document using only 1 font but with different sizes what
> are the easiest switch commands to change font size locally ? I am
> aware of \tfa, \tfx etc …. but they do not seem to size in absolute
> size but rather relatively to current font size. In the following
> MWE :
> 
> 
> \starttext
> 
> 
> {\tfd Foo {\tfx Bar1}} {\tfx Bar2} Baz.
> 
> 
> \stoptext
> 
> 
> 
> Bar1 is typeset much larger than Bar2.
> 
> 
> I’d look to write something like but don’t know who to get \BigSize
> and \SmallSize defined (and have Bar1 and Bar2 of same size) :
> 
> 
> {\BigSize Foo {\SmallSize Bar1}} {\SmallSize Bar2} Baz. 
> 
> 
> Many thanks for any hint.

Perhaps (untested):

\definealternativestyle [BigFont] [{\setbodyfont [12pt]}]
\definealternativestyle [SmallFont] [{\setbodyfont [8pt]}]
\definehighlight [BigSize] [style=BigFont]
\definehighlight [SmallSize] [style=SmallFont]

\BigSize{Foo \SmallSize{Bar1}} \SmallSize{Bar2} Baz.

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] Simple font size changes command

2016-06-12 Thread Alan BRASLAU
On Sun, 12 Jun 2016 16:57:26 +
 wrote:

> I was also a bit surprised with \tf behaviour when used inside
> a scope of another one leading to 2 different sizes in output, as in
> 
> {\tfd Foo {\tfx Bar1}} {\tfx Bar2} Baz.
> 
> For the sake of knowledge I would be interested in knowing if this is
> expected eventually.

Yes, and this appears to me to be the most logical behavior.

By the way, the use of such "low-level" font changes is not very good
style in any case, and should be limited to special cases. In
particular, this will not export well in tagged output to xml, for
example, which is why I suggest the use of styles and "highlight".

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] Citations and links

2016-06-13 Thread Alan BRASLAU
On Mon, 13 Jun 2016 12:38:39 +0200
Nicola  wrote:

> When I use \cite[Author:2016], the (Author, 2016) in the output is
> hyperlinked to the reference. But when I use
> \cite[Author1:2016,Author2:2015], the resulting
> (Author1, 2016 and Author2, 2015) is not hyperlinked. Is it possible
> to get hyperlinks in the latter case, too?

I get multiple hyperlinks for equivalent use.

You need to send a MWE.
In the case of bibliographies, a MWE can include the .bib dataset in a
buffer, as follows:

\setupinteraction [state=start]
\usebtxdefinitions [apa]

\startbuffer [bib]
@article{Author1:2016,
  author={Author1},
  year=2016,
}
@article{Author2:2015,
  author={Author2},
  year=2015,
}
\stopbuffer
\usebtxdataset [bib.buffer]

\starttext

\cite[Author1:2016,Author2:2015]

\page

\placelistofpublications

\stoptext


Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] Citations and links

2016-06-13 Thread Alan BRASLAU
Hello,

You were/are using the old (mkii) bibliography system that depends on
bibtex. It has been replaced in mkiv by a new system no-longer using
the bibtex binary and does everything in lua. The wiki is outdated on
this subject and the new manual is almost/essentially finished.

Alan


On Mon, 13 Jun 2016 18:18:36 +0200
Nicola  wrote:

> On 2016-06-13 14:29:37 +0000, Alan BRASLAU said:
> 
> > On Mon, 13 Jun 2016 12:38:39 +0200
> > Nicola  wrote:
> >   
> >> When I use \cite[Author:2016], the (Author, 2016) in the output is
> >> hyperlinked to the reference. But when I use
> >> \cite[Author1:2016,Author2:2015], the resulting
> >> (Author1, 2016 and Author2, 2015) is not hyperlinked. Is it
> >> possible to get hyperlinks in the latter case, too?  
> > 
> > I get multiple hyperlinks for equivalent use.  
> 
> This is your example adapted to reproduce my problem (I do not
> know how to use the buffer in this case, so you have to move the
> references into main.bib):
> 
> \setupinteraction [state=start]
> \setupbibtex[database={main}]
> \setuppublications[alternative=apa]
> 
> \starttext
> \cite[Author1:2016,Author2:2015]
> \cite[Author1:2016]
> \page
> \placepublications[criterium=text]
> \stoptext 
> 
> Amyway, your example works for me (actually, the layout of the
> references turns out even better), so I will switch to using the
> commands you have suggested.
> 
> Btw, I cannot find any documentation about them in the wiki.
> 
> Thanks,
> Nicola
> 
> > You need to send a MWE.
> > In the case of bibliographies, a MWE can include the .bib dataset
> > in a buffer, as follows:
> > 
> > \setupinteraction [state=start]
> > \usebtxdefinitions [apa]
> > 
> > \startbuffer [bib]
> > @article{Author1:2016,
> >   author={Author1},
> >   year=2016,
> > }
> > @article{Author2:2015,
> >   author={Author2},
> >   year=2015,
> > }
> > \stopbuffer
> > \usebtxdataset [bib.buffer]
> > 
> > \starttext
> > 
> > \cite[Author1:2016,Author2:2015]
> > 
> > \page
> > 
> > \placelistofpublications
> > 
> > \stoptext
> > 
> > 
> > Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] Latin setupmathematics

2016-06-16 Thread Alan BRASLAU
On Fri, 17 Jun 2016 01:02:48 +0200
Hans Åberg  wrote:

> The idea is avoiding clashes between variables and constants, like
> this:
> 
> \starttext
> 
> \setupmathematics[default=normal]
> 
> $𝑒 = ∑_{𝑖=1}^∞ e^{i-𝑖}$
> 
> \setupmathematics[default=italic]
> 
> $𝑒 = ∑_{𝑖=1}^∞ e^{i-𝑖}$

Very, very poor mathematical style...

If you really want to use a variable "e", this would call for the use
of the function \exp() to be readable.

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] Flushleft formula

2016-06-16 Thread Alan BRASLAU
On Thu, 16 Jun 2016 18:18:58 -0400
Aditya Mahajan  wrote:

> And some stage, it will be nice to discuss the possiblility of adding 
> background to formulas, especially aligned formulas.

something like a

\setupformula
  [before={\startframedtext[background=color,backgroundcolor=lightblue]},
   after={\stopframedtext}]

?

("untested")

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] Equivalent of extras option in new bibliography system?

2016-07-01 Thread Alan Braslau
On Fri, 1 Jul 2016 19:13:26 +0200
Nicola  wrote:

> It does not seem to work with my example. The output of the MWE below
> is:
> 
> (Author, 2016 XXX) (Author, 2016)
> The comma seems the culprit.

Yes. Consider:

\cite[righttext={{, p.~24},{, p.~xx}}] [Author:2016,Author2:2015]

The comma gets parsed (as always) to separate multiple right texts,
assigned here to each citation reference.

The solution to your problem is:

\cite[righttext={{, p.~24}}][Author:2016]

Alternately (if you find the {{ }} strange), you can type
\cite[righttext={\btxcomma p.~24}] [Author:2016]

The macro \btxcomma also takes care of spacing.

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] ppchTeX

2016-07-07 Thread Alan BRASLAU
On Wed, 6 Jul 2016 18:23:57 +0200
Henri Menke  wrote:

> Dear list,
> 
> I just wanted to check whether chemical structures typeset in ConTeXt
> can be exported as XML.  Therefore I wanted to setup a simple example
> with ppchTeX.  I copied example 3.1 from the manual [1]
> 
> > \usemodule[chemic]
> > \starttext
> > 
> > \startchemical[height=4500,bottom=2500]
> >   \bottext{$\beta$-D-Fructopyranose}
> >   \chemical[SIX,FRONT,BB1236,+SB4,-SB5,Z5][O]
> >   \chemical[SIX,FRONT,+R12346,+RZ12346][\SR{HO},H,H,H,OH]
> >   \chemical[SIX,FRONT,-R12346,-RZ12346][H,OH,\SR{HO},H,CH_2OH]
> > \stopchemical
> > 
> > \stoptext  
> 
> Unfortunately, typesetting with MkIV distributed with TL 2016 produces
> something really weird (see attached).
> 
> Is the module `chemic` compatible with MkIV or am I doing something
> wrong?
> 
> Cheers,
> Henri
> 
> [1] http://www.pragma-ade.nl/general/manuals/mp-ch-en.pdf


\usemodule[chemic] is MKII. It has been replace with core MKIV commands.

The syntax has been somewhat rationalized and many bugs corrected.

The example can be reproduced as follows:


\starttext

\startchemical [height=4500,bottom=2500]
  \bottext{$\beta$-D-Fructopyranose}
  \chemical[SIXFRONT,BB123,B4,+SB5,-SB6,Z6] [O]
  \chemical[+LR12345,LRZ12345] [OH,\SR{HO},H,H,H]
  \chemical[+RR12345,RRZ12345] [CH_2OH,H,\SL{OH},\SR{HO},H]
\stopchemical

\stoptext 



Unfortunately, the revised manual still has some errors that I need to
fix...

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] Product-component structure

2016-07-11 Thread Alan BRASLAU
On Mon, 11 Jul 2016 13:01:58 +0200
Procházka Lukáš Ing.  wrote:

> - Single components can be compiled successfully, too; sections here
> are NOT NUMBERED as in the final document.

A nagging question that I have always had about structure is that it
would be rather nice if compiling a component that is part of a product
could use the .tuc information from an earlier compiling of the entire
product (if present) for numbering. Of course, modifying a component
(such as a chapter) might or would have an effect on all other
components of the product, but such is life.

In a large book product, working on a single chapter would be useful,
and getting the numbering at least close to correct is desirable.

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] replacement for \getcitedata

2016-07-12 Thread Alan BRASLAU
On Tue, 12 Jul 2016 10:51:06 +0200
Michael Eidenbenz  wrote:

> is there a way to extract data from the bib database to use it in a
> macro?
> 
> something like a replacement for the old \getcitedata

\cite[title] [Eidenbenz2016]

(Any field can be obtained with this mechanism.)

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] Different colors in LaTeX and ConTeXt

2016-07-12 Thread Alan BRASLAU
What is the fuss?

\starttext

\startMPcode
  draw origin--right scaled 1cm
withpen pencircle scaled 1pt
withcolor gray  ;
\stopMPcode

\stoptext

works just fine... :-)

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] replacement for \getcitedata

2016-07-12 Thread Alan BRASLAU
On Tue, 12 Jul 2016 20:39:27 +0200
Michael Eidenbenz  wrote:

> but i'm encountering my old problem:
> 
> \externalfigure[\cite[file][Eidenbenz2016]]
> 
> gives me an error.

This is not the right approach, as explained earlier.

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] (again) PDF info fields

2016-07-17 Thread Alan BRASLAU
Try,


\setupdocument
  [metadata:title={\documentvariable{title}},
   metadata:subtitle={\documentvariable{subtitle}},
   metadata:author={\documentvariable{author}},
   metadata:address={\documentvariable{address}},
   metadata:doi={doi:\documentvariable{doi}},
   metadata:keywords={\documentvariable{keywords}}]

\startdocument
  [title={Your title},
   subtitle={your subtitle},
   author={your name},
   address={your address},
   keywords={your keywords},
   abstract={The abstract goes here.\par
 The Abstract and the keywords have to fit in this page.},
year={2016},
   doi={}]

...

\stopdocument


On Sun, 17 Jul 2016 21:29:38 +0200
Pablo Rodriguez  wrote:

> Hans,
> 
> sorry for insisting in this issue. I may be missing consecuences or
> requirements that make impossible its implementation.
> 
> I see two inconsistencies in the following output:
> 
>   \def\BookTitle{{\itd A \ConTeXt\ Book}}
>   \def\BookAuthor{{\sc The Author}}
>   \setupinteraction[state=start, title=\BookTitle, author=\BookAuthor]
>   \enabledirectives[references.bookmarks.preroll]
>   \placebookmarks[chapter,section,subsection]
> 
>   \starttext
>   \chapter{\BookTitle}
> 
>   \section{\BookAuthor}
> 
>   \subsection{\ConTeXt\ is \TeX, but not \LaTeX}
>   \stoptext
> 
> Would it be possible that PDF info fields can have their contents
> prerolled as it happens with bookmarks?
> 
> In the bookmarks, \ConTeXt\ is rendered as ConTEXT. Since “The
> TeXbook” only mentions \TeX and no \TEX, would it be possible to
> preroll \TeX, \ConTeXt and \LaTeX as TeX, ConTeXt and LaTeX?
> 
> Many thanks for your help,
> 
> Pablo



-- 
Alan Braslau
CEA DSM-IRAMIS-SPEC
CNRS UMR 3680
Orme des Merisiers
91191 Gif-sur-Yvette cedex FRANCE
tel: +33 1 69 08 73 15
fax: +33 1 69 08 87 86
mailto:alan.bras...@cea.fr
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] How to extend btx rendering?

2016-07-18 Thread Alan BRASLAU
On Mon, 18 Jul 2016 15:06:06 +0200
Henri Menke  wrote:

> But I don't want to edit any system files, because this is not
> portable. Also I don't want to have a copy of this file in my project
> directory, because this is just redundant.
> 
> How can I add the two fields `eprint` and `archivePrefix` to
> `categories.article.optional` from the document level?

Hi Henri,

eprint and archivePrefix are in no ways standard to bibtex.

But really, an eprint is NOT an *article* until it gets published, and
then it should be cited as an article and not as a preprint.


What you are looking for is a way to attach a label "arXiv:1607.04624"
to the url = {http://arxiv.org/abs/1607.04624}, similarly to how a doi
is handled.

I can easily add the field arxiv to the "aps" rendering as it is
well-defined.

I can also add the field eprint (to be combined with the url field) as
in
  eprint = {arxiv:1607.04624},
  url = {http://arxiv.org/abs/1607.04624},
as this use can be pretty general. But I do *not* like the
archivePrefix use of biblatex as it is a good example of bloat and
feature creep.

So I will modify the aps specifications to be used as

@unpublished{Kudryashov2016,
title = {Normal State of the Metallic Hydrogen Sulfide},
author = {Kudryashov, Nikolay A. and Kutukov, Alexander A. and
Mazur, Evgeny A.},
year = {2016},
eprint = {arxiv:1607.04624},
url = {http://arxiv.org/abs/1607.04624},
}




Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] Ka-Pow comic book effect?

2016-07-18 Thread Alan BRASLAU
On Mon, 18 Jul 2016 11:59:42 -0400
Pavneet Arora  wrote:

> Would anyone have a template on how to create a comic book “Ka-Pow”
> effect (or something similar) as per:
> 
> http://thumb101.shutterstock.com/display_pic_with_logo/752857/180152483/stock-vector-ka-pow-comic-speech-bubble-cartoon-180152483.jpg
> 
> I would like to use it for one of my slides for my talk at TUG 2016.


\startreusableMPgraphic{star}
  fill dir(90)--dir(-60)--dir(150)--dir(30)--dir(-120)--cycle
xscaled \overlaywidth yscaled \overlayheight
scaled 3/4
withcolor \MPcolor{\overlaycolor} ;
\stopreusableMPgraphic

\defineoverlay [star] [\reuseMPgraphic{star}]

\starttext

\startframed
[frame=off,background=star,backgroundcolor=lightgray,align=text] Wow\\
a star!
\stopframed

\stoptext


You get the idea... (but keep in mind Edward Tufte's Phluff factor).

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] Wrong alignment in natural tables?

2016-07-18 Thread Alan BRASLAU
On Mon, 18 Jul 2016 18:45:30 +0200
cryo shock  wrote:

> Can you verify that it's working like expected? Because when I
> compile it with latest beta i have the opposite alignment.

I assume that you want align=flushleft and align=flushright,
rather than (ragged)left and (ragged)right.

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] How to extend btx rendering?

2016-07-18 Thread Alan BRASLAU
On Mon, 18 Jul 2016 20:05:52 +0200
Henri Menke  wrote:

> I think it would be advantageous to also have the eprint/howpublished
> field available for @article such that I can link the arXiv even
> though an article has been published.  This way people without
> subscription to a specific journal can readily access the preprint
> (open-access philosophy).  Do you consider this a viable option?

Actually, correct usage *requires* you to give the published reference
and doi. The APS, for example, will accept manuscripts that have been
put on a preprint database, but the author *must* subsequently modify
the entry on the preprint database to give the published reference.

The howpublished field would be inappropriate for a published
@article{}.

An author can always choose to add a note, as in
  note={preprint available as arxiv:1607.04624},
but this will not get hyperlinked to the url using the aps
bibliography specifications.

My suggestion would be to keep your (@electronic) entry in the .bib
file and to add the published version as a new @article entry. Then one
has two choices:
  \cite[article,electronic]
that will generate two references, or
  \cite[article+electronic] 
that will generate a single reference. Note that (often?) the year
might differ (depending on when in the year and how long it took to get
published)!

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] alignment problem in a table

2016-07-19 Thread Alan BRASLAU
On Tue, 19 Jul 2016 15:19:11 +0200
Fabrice Couvreur  wrote:

> The third column of matrix is not centered vertically and
> horizontally.

You should note that it is NECESSARY to present a MINIMAL Working
Example, that is stripped-down to ONLY the minimum necessary to show a
problem, if you want anyone to look at it. This sometimes takes a bit of
work, but the process can also be revealing of errors that one might
make and not see in a more complicated example.

I am pointing this out as I have seen many non-minimal questions posted.

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] Something got wrong here

2016-07-28 Thread Alan BRASLAU
On Thu, 28 Jul 2016 19:52:41 +0200
Henri Menke  wrote:

> \footnote{\cite[righttext={; p.~1}][Berlant2011]}

Several comments:

1. \setupbtx [default:cite:righttext] [left={; }]
allows you to drop the semicolon+space in your righttext values, if
this is what you desire; [left=\btxsemicolon] can also be used.

2. \footnote{\cite[alternative=entry,after={ p.~1}][Berlant2011]}
allows you to include the full citation in the footnote, if desired.
This is the same as \footnote{\placecitation[Berlant2011]}.
(Note that this still requires the use of \placelistofcitations
somewhere in the text.)
The difference between "righttext=" and "after=" in a \cite is that the
first one adds the page reference to the citation reference and the
second adds the page reference to the end of the citation rendering.

3. The default style is extremely basic. One can setup the citation
reference numbers to be placed high like footnote references, if
desired.

Alan



-- 
Alan Braslau
CEA DSM-IRAMIS-SPEC
CNRS UMR 3680
Orme des Merisiers
91191 Gif-sur-Yvette cedex FRANCE
tel: +33 1 69 08 73 15
fax: +33 1 69 08 87 86
mailto:alan.bras...@cea.fr
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] APA formatting and reference questions

2016-08-24 Thread Alan BRASLAU
On Wed, 24 Aug 2016 17:43:03 -0600
Todd DeVries  wrote:

> In this excerpt, the following APA style formatting
> errors occur:
> 
> 1. The first reference is cited as “Hartley, M.T. (2013).” There is
> usually a space separating these initials. Between the M. and T. in
> this reference.

Yes, there should be spaces between initials. There were spaces before,
and I will see why they disappeared and fix it.


> 2. The word “and” is appearing in both parenthetical and in-text
> citations. When a reference is completely within parentheses, the last
> author should be separated by the & (Ampersand) character.

Yes, authoryears should use "and" and authoryear should use "&". I'll
fix it.

However, the APA style goes even further:

"Precede the final name in a multiple-author citation in running text by
the word and. In parenthetical material, in tables and captions, and in
the reference list, join the names by an ampersand (&)"

How far should we go in dealing with tables and captions???


> 3. The last reference has 3 authors and should be written as Koch et
> al (2014) instead, it replicates the entire list of authors previously
> cited.

Formally:

"Invert all authors’ names; give surnames and initials for up to and
including seven authors (e.g., Author, A. A., Author, B. B., & Author,
C. C.). When authors number eight or more, include the first six
authors’ names, then insert three ellipsis points, and add the last
author’s name (see Chapter 7, Example 2). In text, follow the citation
guidelines in section 6.12."

"6.12
When a work has two authors, cite both names every time the reference
occurs in text. When a work has three, four, or five authors, cite all
authors the first time the reference occurs; in subsequent citations,
include only the surname of the first author followed by et al. (not
italicized and with a period after al) and the year if it is the first
citation of the reference within a paragraph."

So, indeed, the second citation should have Koch et al., but...
Hans and I discussed this. It is a particularity of the APA style and
can get really tricky to program if we are to respect the following
part of section 6.12:

"Exception: If two references of more than three surnames with the same
year shorten to the same form (e.g., both Ireys, Chernoff, DeVet, &
Kim, 2001, and Ireys, Chernoff, Stein, DeVet, & Silver, 2001, shorten
to Ireys et al., 2001), cite the surnames of the first authors and of
as many of the subsequent authors as necessary to distinguish the two
references, followed by a comma and et al."

It becomes messy:

"When a work has six or more authors, cite only the surname of the first
author followed by et al. (not italicized and with a period after al)
and the year for the first and subsequent citations. (See section 6.27
and Example 2 in Chapter 7 for how to cite works with more than six
authors in the reference list.) If two references with six or more
authors shorten to the same form, cite the surnames of the first
authors and of as many of the subsequent authors as necessary to
distinguish the two references, followed by a comma and et al."

So we set the etallimit to 5 and etaldisplay to 1 in citations and
etallimit to 7 and etaldisplay to 6 in the bibligraphy list. If, by
poor chance two references shorten to the same form, than you are out
of luck for now!

Alan

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] [NTG-Context] Problem with \usemodule[graph] and El Capitan (mac OS)

2016-09-01 Thread Alan Braslau
No, this is a feature, not a bug!

According to the original graph macros, the data files are kept open, and thus 
subsequent reads will pick up successive data sets in a single file. This is 
explicitly stated in the documentation.

A consequence for us in ConTeXt mkiv, where the metapost code is called in 
multiple passes, is that one must explicitly close the data file if one does 
not want this feature. This, too, I documented. So don't break John Hobby's 
code by removing the saved.

Alan



> On Sep 1, 2016, at 04:28, Hans Hagen  wrote:
> 
> On 9/1/2016 11:43 AM, Taco Hoekwater wrote:
>> Hi,
>> 
>> I am on El Capitan as well (10.11.6).
>> 
>> ConTeXt  ver: 2016.08.29 22:53 MKIV beta
>> 
>> Attached is an altered input file that works for me. No idea how much of the 
>> problem
>> is actually related to El Capitan, but:
>> 
>> * \usemodule[graph] defines a special MP instance called ‘graph’. You need to
>>  use that because otherwise the metapost graph macros will not load (that is 
>> why
>>  I added the “graph::” prefix twice)
>> 
>> * Something is wrong with the file closing, so I added an extra definition 
>> for
>>  'graph_close_file' (no idea why it does not work out of the box. Sorry to 
>> you and Hans).
> 
> there are save's in mp-grap ... i'll remove them

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] Overfull boxes in bibliography

2016-09-28 Thread Alan Braslau
Hello,

It turns out that "alignment" of the bibliography lists does not take the 
document global settings, but rather, like in other cases such as a framed 
environment, alignment is reset to the default value: strict alignment does not 
give the best results for the bibliography list rendering, so I have now set 
this is the various style specifications to be "{verytolerant,stretch}".

Awaiting that this correction be propagated, one can add

\setupbtxlist
  [aps] % for example
  [align={normal,verytolerant,stretch}]

in your setup. There should then be no need for overfill boxes.

Alan

> On Aug 30, 2016, at 00:23, Henri Menke  wrote:
> 
> Dear list,
> 
> I noticed, that even though I set \version[temporary] to make overfull boxes 
> visible, they were not marked with an overfullrule in the bibliography.  
> Below you find a minimal example which reproduces the problem on TL 2016.  
> First I typeset the entry by hand where the black rectangle shows up in the 
> margin, then I format it automatically using \placelistofpublications where 
> no box is shown.
> 
> How can I have overfull boxes highlighted in the bibliography?
> 
> Many thanks, Henri
> 
> ---
> 
> \startbuffer[biblio]
> @article{Heisenberg1926,
>  author = {Heisenberg, W.},
>  title = {Mehrk\"orperproblem und Resonanz in der Quantenmechanik},
>  journal = {Zeitschrift f\"ur Physik},
>  year = {1926},
>  volume = {38},
>  number = {6},
>  pages = {411--426},
>  issn = {0044-3328},
>  doi = {10.1007/BF01397160},
>  url = {http://dx.doi.org/10.1007/BF01397160}
> }
> \stopbuffer
> 
> \version[temporary]
> \setuppapersize[A5][A5]
> 
> \usebtxdataset[biblio.buffer]
> \usebtxdefinitions[aps]
> 
> \starttext
> 
> \showframe
> 
> \setupitemize[left={[},right={]},width=3em,stopper=]
> \startitemize[n]
> \item W. Heisenberg, Mehrkörperproblem und Resonanz in der
>  Quantenmechanik, {\em Zeitschrift für Physik} {\bf 38}(6), 411--426 (1926).
> \stopitemize
> 
> \nocite[Heisenberg1926]
> \placelistofpublications
> 
> \stoptext
> ___
> If your question is of interest to others as well, please add an entry to the 
> Wiki!
> 
> maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
> archive  : http://foundry.supelec.fr/projects/contextrev/
> wiki : http://contextgarden.net
> ___

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] How do I compile a "flat" pdf?

2016-10-08 Thread Alan Braslau
Also pdftk

But, it is naive to believe that a pdf can be "protected" from copying or 
extracting, isn't it?

Alan

> On Oct 7, 2016, at 09:08, Hans Hagen  wrote:
> 
> On 10/7/2016 4:50 PM, Henning Hraban Ramm wrote:
> 
>> The only way to "protect" contents from editing are the password settings. 
>> There are free tools to set them, but AFAIK no open source tools except 
>> maybe libraries.
> 
> qpdf and mutools

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] Communative diagrams with TikZ & ConTeXt

2016-10-11 Thread Alan Braslau
Hello,

I wrote some very simple MetaPost helpers to create commutative diagrams:




natural.pdf
Description: Adobe PDF document



Alan


> On Oct 6, 2016, at 15:45, Hans Åberg  wrote:
> 
> 
>> On 6 Oct 2016, at 15:52, Mojca Miklavec  
>> wrote:
>> 
>> I don't have the file tikzlibrarycommute.code.tex on my machine
>> either. Anywhere. Not in the ConTeXt distribution nor in TeX Live.
>> That file was only posted to the mailing list by Idris and apparently
>> nobody ever looked at it or added it anywhere.
> 
> There is a tikz-cd package at CTAN:
>  https://www.ctan.org/tex-archive/graphics/pgf/contrib/tikz-cd?lang=en
> 
> One makes sure to have the file tikzlibrarycd.code.tex, and follows the 
> translation rules in the manual for ConTeXt. In addition to that, one seems 
> to have to replace the apostrophe with "below".
> 
> The first few examples in the manual, which compiled with latest ConTeXt:
> 
> \usemodule[tikz]
> \usetikzlibrary[cd]
> 
> 
> \starttext
> 
> \starttikzcd
>  A \arrow{rd} \arrow{r}{𝜑} \NC B \NR
> \NC C
> \stoptikzcd
> 
> \starttikzcd
>  A \arrow[r, "\phi"] \arrow[d, red]
>\NC B \arrow[d, "\psi" red] \NR
>  C \arrow[r, red, "\eta" blue]
>  \NC D
> \stoptikzcd
> 
> \starttikzcd
>  A \arrow[r, "\phi" near start, "\psi" below, "\eta" near end] \NC B
> \stoptikzcd
> 
> \starttikzcd
>  T
>  \arrow[drr, bend left, "x"]
>  \arrow[ddr, bend right, "y"]
>  \arrow[dr, dotted, "{(x,y)}" description] \NC \NC \NR
>\NC X \times_Z Y \arrow[r, "p"] \arrow[d, "q"]
>\NC X \arrow[d, "f"] \NR
>  \NC Y \arrow[r, "g"] \NC Z
> \stoptikzcd
> 
> \starttikzcd[column sep=tiny]
>  \NC \pi_1(U_1) \ar[dr] \ar[drr, "j_1", bend left=20]
>\NC
>  \NC[1.5em] \NR
>  \pi_1(U_1\cap U_2) \ar[ur, "i_1"] \ar[dr, "i_2" below]
>\NC
>  \NC \pi_1(U_1) \ast_{ \pi_1(U_1\cap U_2)} \pi_1(U_2) \ar[r, dashed, 
> "\simeq"]
>\NC \pi_1(X) \NR
>  \NC \pi_1(U_2) \ar[ur]\ar[urr, "j_2" below, bend right=20]
>\NC
>  \NC
> \stoptikzcd
> 
> \stoptext
> 
> 
> ___
> If your question is of interest to others as well, please add an entry to the 
> Wiki!
> 
> maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
> archive  : http://foundry.supelec.fr/projects/contextrev/
> wiki : http://contextgarden.net
> ___

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] Parsing ConTeXt errors

2016-10-11 Thread Alan Braslau
Of course, I *never* make MetaPost errors... ;-)

However, you can search the log file for
metapost> error: 


Alan


> On Oct 11, 2016, at 07:27, Nicola  wrote:
> 
> Hello,
> 
> I'm trying to parse ConTeXt errors. TeX and Lua errors seem easy to parse
> (search for 'tex error' and 'lua error', respectively), but I have a couple of
> problems with MetaPost messages.
> 
> First, when there are MetaPost errors, context/mtxrun exits with a zero exit
> code. Is that intentional?
> 
> Second, as far as I see, there is no way to locate the error in the source
> from the log. I can only retrieve the file causing the error (by searching for
> an 'open source' line - very useful, btw), but no line number.
> 
> Am I missing something? I think it would be very useful to have at least an
> approximate indication of the position of a MetaPost error.
> 
> Nicola
> 
> 
> 
> ___
> If your question is of interest to others as well, please add an entry to the 
> Wiki!
> 
> maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
> archive  : http://foundry.supelec.fr/projects/contextrev/
> wiki : http://contextgarden.net
> ___

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] Asciidoc --> ConTeXt for presentations

2016-10-16 Thread Alan BRASLAU
On Sun, 16 Oct 2016 12:25:39 +0200
Saša Janiška  wrote:

> > then start making your own ... such styles are rather simple and not
> > much coding in the document source is needed .. just develop your
> > own look and feel after a while  
> 
> It’s clear you’re not into JS-powered hype for presentations. ;)

Pfluff (Tufte, 2004) is best left to PowerPointers.

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] FreeBSD binaries - was: Systemwide installation does not work

2016-10-18 Thread Alan Braslau
Mailing list:

There was some fluctuation in the FreeBSD binaries being distributed on 
contextgarden.net.

With the recent introduction of FreeBSD 11.0, the GPL3-tainted GNU libstdc++ 
has been dropped in favor of a new, clean libc++. This follows on the switch 
from gcc to clang that took place with the introduction of FreeBSD 10.0. As a 
result, the new binaries compiled on FreeBSD 11.0 failed to work on older 
systems, i.e. FreeBSD 9.3 (still in production/supported). We now take care to 
provide binaries compiled under FreeBSD 9.3 on the garden, at least until this 
version gets phased-out at the end of the year.

https://wiki.freebsd.org/NewC++Stack

Mac users should note that MacOS closely follows similar developments as 
FreeBSD.


(TEXLive, being even more conservative, distributes binaries compiled under 
FreeBSD 7.3.)

Alan


P.S. The present thread started as the FreeBSD binaries got crushed by new 
OpenBSD binaries that will soon be available on the garden, helping us also 
understand the above new shared-library issue.

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] PDF/A generation

2016-10-19 Thread Alan Braslau
Hello,

You can very easily download the beta/standalone installation that can very 
happily coexist with TL release. All that is needed to choose the standalone 
version is to modify your PATH appropriately (by sourcing the setuptex script).

In fact, we recommend even downloading an installation by project. This can 
guarantee stability for a particular project way into the future.

Alan 

> On Oct 18, 2016, at 07:44, Henri Menke  wrote:
> 
> thanks for the update.  Can you maybe tell what exactly has changed to fix 
> it?  I'm on the TL 2016 release and cannot update because I fear regressions 
> for my important document.

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] Text editors

2016-10-25 Thread Alan Braslau
Hi,

You forgot my favorite editor:

cat > file.tex

;-)


More seriously, the SciTe syntax highlighting depends on a lpeg DLL that 
presently is only available on Windows - unless someone has succeeded in 
compiling the shared library on another system.

Alan


> On Oct 24, 2016, at 05:41, Henning Hraban Ramm  wrote:
> 
> Hi all,
> 
> I just edited http://wiki.contextgarden.net/Text_Editors,
> reordered, updated, killed some discontinued programs etc.
> 
> I didn’t delete wiki pages of outdated apps, though.
> 
> There’s still a lot of room for enhancement, e.g. the feature columns make no 
> sense this way.
> 
> I’d like to know:
> - What editor(s) do you use for ConTeXt?
> - Are there any other editors with ConTeXt (not only LaTeX) support?
> 
> How about including the vim support files in the distribution (like the SciTE 
> support files)?
> 
> I recently discovered Textadept, a relative of SciTe’s, also available for 
> OSX - did anyone try to adapt SciTE ConTeXt support for that?
> 
> 
> Greetlings, Hraban
> ---
> http://www.fiee.net
> http://wiki.contextgarden.net
> https://www.cacert.org (I'm an assurer)
> GPG Key ID 1C9B22FD
> 
> ___
> If your question is of interest to others as well, please add an entry to the 
> Wiki!
> 
> maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
> archive  : https://bitbucket.org/phg/context-mirror/commits/
> wiki : http://contextgarden.net
> ___

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] A question about \startcombination[3*1] \stopcombination (again)

2016-10-25 Thread Alan Braslau
Try

\startcombination [nx=3,ny=1]

Alan

> On Oct 25, 2016, at 08:14, Fabrice Couvreur  
> wrote:
> 
> I can not make three columns and one row. But three rows and one column

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] Text editors

2016-10-28 Thread Alan Braslau
I used to be very proficient at writing in machine code and reading punch tape 
output, too...

Alan

> On 25 Oct 2016, at 10:19, Nicola  wrote:
> 
> > cat > file.tex
> 
> Mandatory xkcd at this point: https://www.xkcd.com/378/

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] Vim wiki page updated

2016-11-05 Thread Alan Braslau
Hans, Nicola,

Being a vim user (and not presently taking much advantage of the syntax 
highlighting), and a MP fan, I will take care of this (in coordination with 
Hans, eventually).

Alan


> On 3 Nov 2016, at 08:37, Nicola  wrote:
> 
> On 03/11/2016 12:28, Hans Hagen wrote:
> 
 if you need a command list .. there are scripts for that (no vim yet,
 but for scite we ship simple lists of commands)
>>> 
>>> Are these scripts available somewhere?
>> 
>> what kind of datafile do you need?
> 
> I need the list of all macros, vardefs, internals, and global variables
> from all MetaFun files. The format should be Vim's syntax format:
> 
> https://github.com/vim/vim/blob/master/runtime/syntax/mp.vim
> 
> Nicola

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] Framedtext in a float

2016-11-05 Thread Alan Braslau
Sounds something like how PowerPoint works (but adjusting point size to fit a 
frame...).

Alan

> On 1 Nov 2016, at 04:17, Piotr Kopszak  wrote:
> 
> You mean, you effectively want ConTeXt to choose best proportions for
> the framed text on its own? I guess very few designers would agree for
> that, if any.

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] Chemical reaction...

2016-11-10 Thread Alan BRASLAU
\startplacechemical
  \startchemicalformula
 ...
  \stopchemicalformula
\stopplacechemical


Alan

On Tue, 8 Nov 2016 20:06:27 +0100
Willi Egger  wrote:

> I am busy to edit an older article in which there are a couple of
> chemical fromulas and reactions.
> 
> However, I am stuck because the following throws me an error when
> uncommenting the line with “\chemical{2H^\oplus}{~waterstof
> (zuur)}” (something with $ inserted…)
> 
> Another aspect is, that the {DEZ} does not appear. Further the
> {zinkion} and {ethan} appear not as text under the formula but as
> text next to it.
> 
> \starttext 
> \placeformula 
>   \startformula 
> \chemical{(C_2H_5)_2Zn}{DEZ} 
> \chemical{PLUS} 
> % \chemical{2H^\oplus} {waterstof (zuur)} 
> \chemical{GIVES}
> \chemical{Zn^{2\oplus}}{zinkion} 
> \chemical{PLUS} 
> \chemical{2(C_2H_6)}{ethan} 
>   \stopformula 
> \stoptext
> 
> Thank you for hints, what I am missing here…
> 
> Kind regards
> 
> Willi

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] Asymptote or Metapost and ConTeXt parameters.

2016-12-20 Thread Alan Braslau
On Mon, 19 Dec 2016 08:19:25 -0800
Aditya Mahajan  wrote:

> The ability to pass parameters to metapost has been around since the 
> beginning. See the metafun manual for details (search for MPvar).

Hans has developed tools making it quite easy to pass data back and
forth between MetaPost and lua. This is quite efficient, and it is
being used more and more in the development of macro functionality.

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] integral symbol

2016-12-28 Thread Alan Braslau
Hi Hans, Hi list,

This is similar to what we have discussed earlier on this list and
elsewhere regarding \over vs. \frac. (I agree with Knuth that {a \over
b} is *much* more readable in running source code than \frac{a}{b} but
have resigned myself to use \frac{}{}, as this can be made better
behaved and gives a much better result.)

Other traditional TeX constructs like \int^a_b have their charm (and
need to remain supported, just like is \over), but I support
introducing and encouraging the use of new constructs like your example
below. An alternative syntax (that could co-exist) would be admitting
$\left\int ... \right.$, but I do not know what limitations there might
be with both the (luatex) engine and with ConTeXt.

The problem with extensions, like always, in straying from traditional
TeX is interchangeability of code, or, more importantly, in the
learning curve obstacles that this introduces to traditional TeX (and
LaTeX) thinking. I know that at some level we do not care, for we often
make (good) design choices that improve the syntax of ConTeXt.

Perhaps we can use this thread to discuss other cases (like \sum, ...)
that present difficulties and then decide on good solutions.

Just a suggestion.

Alan



On Wed, 28 Dec 2016 17:42:39 +0100
Hans Hagen  wrote:

> The problem with integrals is that they don't adapt because they are
> not wrapped as delimiters (like left/right stuff). If \int were a
> command taking an argument it would be easier. As in:
> 
> 
> \starttext
> 
> \setupmathextensible[integral][rightoffset=-3mu,exact=yes,factor=2]
> 
> \startlines
> \ruledhbox{$\integral   f\frac{1}{2}$}
> \ruledhbox{$\integral[factor=1] f\frac{1}{2}$}
> \ruledhbox{$\integral[factor=3] f\frac{1}{2}$}
> \stoplines
> 
> \startformula
>  a =
>  \autointegral{t}{b}1 +
>  \autointegral{t}{b}{\frac{\frac{3}{4}}{\frac{1}{2}}} +
>  \autointegral{t}{b}{\frac{\frac{\frac{\frac{1}{2}}{2}}{2}}{2}}
> \stopformula
> 
> \stoptext


-- 
Alan Braslau
CEA DSM-IRAMIS-SPEC
CNRS UMR 3680
Orme des Merisiers
91191 Gif-sur-Yvette cedex FRANCE
tel: +33 1 69 08 73 15
fax: +33 1 69 08 87 86
mailto:alan.bras...@cea.fr
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] rotating some pages of a pdf

2017-01-06 Thread Alan Braslau
On Thu, 5 Jan 2017 23:47:00 -0500
Cesar Romani  wrote:

> The quality of the rotated pdfs, which are images, drops off a little.
> For example, some characters are not so sharp as in the original pdf.
> 
> If I use GraphicsMagick I would remedy this with the parameter
> -density as in:
> gm convert -density 300x300 original.pdf -rotate 45 rotated.pdf

From the web:

"A PDF file does not have a density anyway. IM will apply a default
interpretation of 72dpi unless you override it (e.g. -density 300x300
-units pixelsperinch)."


Testing:

convert original.tif -rotate 45 rotated.png

keeps the original density.

1) original.tif was 6000x6000; rotated.png is 8488x8488 (2400dpi)
2) converting to rotated.tif fails
convert: TIFF: negative image positions unsupported rotated.tif @ 
error/tiff.c/WriteTIFFImage/3609.
3) converting to rotated.pdf does produce a much reduced resolution image.

Indeed, PDF is container, not the best format for manipulating bitmap images.
I take two approaches to this:
1) I manipulate/modify the images explicitly "upstream" before including them 
in ConTeXt,
   using any of my favorite tools; or
2) I manipulate/modify the images using MetaPost, within ConTeXt.
   This gives very satisfactory results and does not rely on ImageMagik.

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] Bug: \textext inside \*MPinclusions causes error

2017-01-12 Thread Alan Braslau
On Thu, 12 Jan 2017 10:06:09 +0100
Hans Hagen  wrote:

> you can use
> 
> \startMPinitializations
> \stopMPinitializations
> 
> as these are expanded each graphic run
> 
> action   pass 1  pass 2
> 
> definitions  yes
> extensions   yes
> inclus figure yes
> initializations  yes yes
> metapost codeyes yes
> end figure   yes yes

One needs to remember that MPlib goes through several runs, and many
standard MP code examples are written for a single, mpost run. This
means that code can fail if variables, for example, are not properly
initialized (or re-initialized). Another example is reading from files
in MP, as the file descriptors are kept open by default, reading on from
where one stopped in a previous run.

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] index(register) from an XML source

2017-01-14 Thread Alan Braslau
On Sat, 14 Jan 2017 15:52:25 +0100
MF  wrote:

> Now an alternative approach I thought, because the index I'm working
> on is a biographical index, I mean a index of cited people, with a
> biographical profile.

One can create an index with the publications module as follows:

\defineregister
  [indexofauthors]

\definebtrxregister
  [authors]
  [field=author,
   register=indexofauthors,
   method=always,
   dataset=default,
   alternative=invertedshort]

...

\placeregister [indexofauthors] [compress=yes]

This will create an index of all \cited authors. Note that one can index
any field, for example title or keywords would be useful. I have not
thought about how to add a biographical profile.

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] Using key as numbering in \placepublications

2017-01-19 Thread Alan Braslau
On Thu, 19 Jan 2017 08:19:03 +0100
Antoine Cailliau  wrote:

> How can I adjust the publication list to display [Kup03a] instead of
> [2] ? The numbering option does not offer "key" apparently.

Using the mkiv publications mechanism, you can get short \cite keys
by default using

\setupbtx[alternative=short]

Individually, you can use \cite[short][yourkey]


Then you will also have to modify the bibliography list rendering to
display the short key. This is slightly more complicated, as presently
only the APA and APS styles have been predefined, the first being an
"authoryear" scheme and the second being a "num" scheme.

Starting with the APS style:

\usebtxdefinitions[aps]

\definebtxrendering
  [mystyle]
  [aps] % inherits from "aps"
  [sorttype=short,
   numbering=short]


\cite[...]

...

\placelistofpublications[mystyle]


However, you really want to define a complete style for your rendering.

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] nested colors problem

2017-01-20 Thread Alan Braslau
On Fri, 20 Jan 2017 21:42:16 +0100
Peter Rolf  wrote:

> Maybe intended behaviour, maybe a bug. Donno.

Not a bug: color and transparency are not the same thing.

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] A better \definesymbol sought

2017-01-20 Thread Alan Braslau
On Fri, 20 Jan 2017 22:33:40 -0500
Rik Kabel  wrote:

> Can anyone suggest a better way to compose such symbols than using
> the raw TeX commands used here? Is there a more ConTeXt-ish way to do
> this? Is it possible to get options to center the glyphs from which
> the symbol is assembled (separate horizontal and vertical, with the
> ability to offset them)?
> 
> Is there a ConTeXt way other than \definesymbol to create such
> combined symbols?

MetaPost (with textext())?
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] A better \definesymbol sought

2017-01-22 Thread Alan Braslau
On Sun, 22 Jan 2017 22:39:53 -0500
Rik Kabel  wrote:

> So, how can I make the inner glyph (‘?’ in the example below)
> transparent, so that the background shows through along with anything
> else that lives on a lower layer? I’ve seen a method for constructed
> shapes, but nothing that I can apply to text glyphs. Undraw doesn’t
> do it.

Undraw is simply draw using the background color.

Transparency is a MetaFun extension to MetaPost (so part of ConTeXt).

draw q withtransparency (1,0.5) ; % (method,transparency)

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] URL styling in btx bibliography

2017-02-04 Thread Alan Braslau
On Fri, 3 Feb 2017 17:26:35 -0500
Rik Kabel  wrote:

> Is there a user-level control for the styling of urls in the new 
> bibliography system? I use
> 
> \setupurl[style=\addff{f:ns}\ss]
> 
> (where f:ns is a fontfeature definition for lining/new style
> numerals) for the rest of the document. The bibliography honors this
> formatting for urls present in bibtex note entries, but persists in
> serif and oldstyle (the document defaults) for urls provided by
> bibtex url entries.

The bibliography specifications use the command \hyphenatedurl{} to
flush the url (or doi) field.

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] URL styling in btx bibliography

2017-02-04 Thread Alan Braslau
On Sat, 4 Feb 2017 09:10:33 -0700
Alan Braslau  wrote:

> On Fri, 3 Feb 2017 17:26:35 -0500
> Rik Kabel  wrote:
> 
> > Is there a user-level control for the styling of urls in the new 
> > bibliography system? I use
> > 
> > \setupurl[style=\addff{f:ns}\ss]
> > 
> > (where f:ns is a fontfeature definition for lining/new style
> > numerals) for the rest of the document. The bibliography honors this
> > formatting for urls present in bibtex note entries, but persists in
> > serif and oldstyle (the document defaults) for urls provided by
> > bibtex url entries.
> 
> The bibliography specifications use the command \hyphenatedurl{} to
> flush the url (or doi) field.
> 
> Alan

Hans,

This should probably be replaced by \url[]?

Alan

\unexpanded\def\url[#label]% move \hyphenatedurl to lua end (is already lua)
{\dontleavehmode
   \begingroup
   \useurlstyleandcolor\c!style\c!color
   \hyphenatedurl{\clf_geturl{#label}}%
   \endgroup}
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

  1   2   3   4   5   6   7   8   9   10   >