Re: [NTG-context] Issues using publications subsystem for non-bibliographic database

2018-12-07 Thread Alan Braslau
On Fri, 7 Dec 2018 23:34:58 -0500
Rik Kabel  wrote:

> On 12/7/2018 22:51, Alan Braslau wrote:
> > You can place references rendered as you need, not necessarily in
> > one single bibliography list, but they must be rendered somewhere,
> > otherwise numbering and cross-referencing is meaningless. In the
> > case of footnote references, each footnote contains a rendering
> > (not a citation) of a fragment of the list.
> >
> > You are thinking too much in a standard frame, and I'm not sure what
> > you want to accomplish.
> >
> > One "other use" case that I make is a catalog of hundreds of
> > mesophases. I "cite" them and their various properties throughout
> > the text, an my "list rendering" has become an index.
> >
> > Alan
> >  
> I would like simply to prepare a paper structured like the one found
> at https://tannerlectures.utah.edu/Greenblatt%20Lecture.pdf. There is
> no biblography; there are bibliographic references in footnotes.
> There is no interaction. The only cross-references are the footnote
> indices.
> 
> If I could in addition pull in blocks of text from a secondary
> database, that is lagniappe. Neither function requires rendering in a
> separate list or lists.
> 
> Certainly ConTeXt's bibliographic subsystem should be capable of 
> supporting such a basic format as that, but I can see no way to get
> it to do so.
> 

As I wrote, "rendering" to footnotes as elements of a "list" can be
done, and your cross-reference *is* the footnote index. We have not
written setups that do this already as I have never needed this format
myself, although it is rather common in certain fields.

"Pulling-in" blocks of text in general (without a basis) is not the aim.
Again, the entire point is to associate fields to an entry, and the
notion of a "list" is more general than a traditional bibliography list.
___
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] Issues using publications subsystem for non-bibliographic database

2018-12-07 Thread Rik Kabel

On 12/7/2018 22:51, Alan Braslau wrote:

You can place references rendered as you need, not necessarily in one
single bibliography list, but they must be rendered somewhere,
otherwise numbering and cross-referencing is meaningless. In the case
of footnote references, each footnote contains a rendering (not a
citation) of a fragment of the list.

You are thinking too much in a standard frame, and I'm not sure what
you want to accomplish.

One "other use" case that I make is a catalog of hundreds of
mesophases. I "cite" them and their various properties throughout the
text, an my "list rendering" has become an index.

Alan

I would like simply to prepare a paper structured like the one found at 
https://tannerlectures.utah.edu/Greenblatt%20Lecture.pdf. There is no 
biblography; there are bibliographic references in footnotes. There is 
no interaction. The only cross-references are the footnote indices.


If I could in addition pull in blocks of text from a secondary database, 
that is lagniappe. Neither function requires rendering in a separate 
list or lists.


Certainly ConTeXt's bibliographic subsystem should be capable of 
supporting such a basic format as that, but I can see no way to get it 
to do so.


--
Rik

___
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] Issues using publications subsystem for non-bibliographic database

2018-12-07 Thread Alan Braslau
You can place references rendered as you need, not necessarily in one
single bibliography list, but they must be rendered somewhere,
otherwise numbering and cross-referencing is meaningless. In the case
of footnote references, each footnote contains a rendering (not a
citation) of a fragment of the list.

You are thinking too much in a standard frame, and I'm not sure what
you want to accomplish.

One "other use" case that I make is a catalog of hundreds of
mesophases. I "cite" them and their various properties throughout the
text, an my "list rendering" has become an index.

Alan


On Fri, 7 Dec 2018 22:36:02 -0500
Rik Kabel  wrote:

> On 12/7/2018 18:01, Alan Braslau wrote:
> > On Fri, 7 Dec 2018 17:19:35 -0500
> > Rik Kabel  wrote:
> >  
> >> As a followup, here is a close-to-minimal example which
> >> demonstrates the failure when \placebtxrendering is omitted.  
> > It is not a failure. The whole intent is to place an appropriate
> > rendering that you can tailor to your specific needs. There is
> > little sense in a cross-reference (link) or reference number if
> > there is not sort of list.
> >
> > Alan  
> 
> That makes absolutely no sense. That means that an informal paper
> that puts all references in footnotes and has no bibliography and
> does not need cross-referencing or reference numbering cannot take
> advantage of a bibliographic database. And in fact, that is the case
> shown below. The footnotes appear only when the comment line is
> uncommented.
> 
> (I also tried \nocite[*] together with
> \placebtxrendering[method=none] and also with
> \placebtxrendering[criterium=none] for the rendering, but that does
> not help. It seems that the entries only display when something gets
> added to the rendering list.)
> 
> \startbuffer[quotesources]
> @book{Schopenhauer1862v2,
>title   = {Parerga und Paralipomena},
>subtitle= {Kleine Philosophische Schriften},
>publisher   = {A. W. Hahn},
>year= {1862},
>volume  = {2},
>volumes = {2},
>author  = {Arthur Schopenhauer},
>editor  = {Julius Frauenstädt},
>address = {Berlin},
>language= {german},
> }
> @book{SchopenhauerPayne2000,
>title   = {Parerga and Paralipomena},
>subtitle= {Short Philosophical Essays},
>publisher   = {Oxford University Press Clarendon Press},
>address = {New York and Oxford},
>year= {2000},
>author  = {Arthur Schopenhauer},
>volumes = {2},
>origyear= {1974},
>origlanguage= {german},
>translator  = {Eric F. J. Payne},
> }
> \stopbuffer
> 
> \loadbtxdefinitionfile
>[apa]
> \usebtxdefinitions
>[apa]
> \usebtxdataset
>[quotesources.buffer]
> 
> \starttext
> 
>As Artie said:\footnote{\placecitation[Schopenhauer1862v2]}
> 
>Es wäre gut Bücher kaufen, wenn man die Zeit, sie zu
>lesen, mitkaufen könnte, aber man verweschelt meistens
>den Ankauf der Bücher mit dem Aneignen ihres Inhalts.
> 
>Payne translates this
> as:\footnote{\cite[entry][SchopenhauerPayne2000]}
> 
>Buying books would be a good thing if one could also
>buy the time to read them in: but as a rule the
>purchase of books is mistaken for the appropriation
>of their contents.
> 
> %  \placebtxrendering [method=dataset]
> \stoptext
> 
> I understood §5.4 of the manual to mean that rendering definitions 
> (created by \definebtxrendering and related setups) do not have an 
> effect on \placecitation (and \cite[field][tag]) commands. Rereading
> it, I wonder if the meaning is supposed to be more than that, and to
> cover this situation?
> 
> Surely this can be changed!
> 

___
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] Issues using publications subsystem for non-bibliographic database

2018-12-07 Thread Rik Kabel

On 12/7/2018 18:01, Alan Braslau wrote:

On Fri, 7 Dec 2018 17:19:35 -0500
Rik Kabel  wrote:


As a followup, here is a close-to-minimal example which demonstrates the
failure when \placebtxrendering is omitted.

It is not a failure. The whole intent is to place an appropriate rendering that 
you can tailor to your specific needs. There is little sense in a 
cross-reference (link) or reference number if there is not sort of list.

Alan


That makes absolutely no sense. That means that an informal paper that 
puts all references in footnotes and has no bibliography and does not 
need cross-referencing or reference numbering cannot take advantage of a 
bibliographic database. And in fact, that is the case shown below. The 
footnotes appear only when the comment line is uncommented.


(I also tried \nocite[*] together with \placebtxrendering[method=none] 
and also with \placebtxrendering[criterium=none] for the rendering, but 
that does not help. It seems that the entries only display when 
something gets added to the rendering list.)


   \startbuffer[quotesources]
   @book{Schopenhauer1862v2,
  title   = {Parerga und Paralipomena},
  subtitle= {Kleine Philosophische Schriften},
  publisher   = {A. W. Hahn},
  year= {1862},
  volume  = {2},
  volumes = {2},
  author  = {Arthur Schopenhauer},
  editor  = {Julius Frauenstädt},
  address = {Berlin},
  language= {german},
   }
   @book{SchopenhauerPayne2000,
  title   = {Parerga and Paralipomena},
  subtitle= {Short Philosophical Essays},
  publisher   = {Oxford University Press Clarendon Press},
  address = {New York and Oxford},
  year= {2000},
  author  = {Arthur Schopenhauer},
  volumes = {2},
  origyear= {1974},
  origlanguage= {german},
  translator  = {Eric F. J. Payne},
   }
   \stopbuffer

   \loadbtxdefinitionfile
  [apa]
   \usebtxdefinitions
  [apa]
   \usebtxdataset
  [quotesources.buffer]

   \starttext

  As Artie said:\footnote{\placecitation[Schopenhauer1862v2]}

  Es wäre gut Bücher kaufen, wenn man die Zeit, sie zu
  lesen, mitkaufen könnte, aber man verweschelt meistens
  den Ankauf der Bücher mit dem Aneignen ihres Inhalts.

  Payne translates this as:\footnote{\cite[entry][SchopenhauerPayne2000]}

  Buying books would be a good thing if one could also
  buy the time to read them in: but as a rule the
  purchase of books is mistaken for the appropriation
  of their contents.

   %  \placebtxrendering [method=dataset]
   \stoptext

I understood §5.4 of the manual to mean that rendering definitions 
(created by \definebtxrendering and related setups) do not have an 
effect on \placecitation (and \cite[field][tag]) commands. Rereading it, 
I wonder if the meaning is supposed to be more than that, and to cover 
this situation?


Surely this can be changed!

--
Rik


___
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] Issues using publications subsystem for non-bibliographic database

2018-12-07 Thread Alan Braslau
On Fri, 7 Dec 2018 17:19:35 -0500
Rik Kabel  wrote:

> As a followup, here is a close-to-minimal example which demonstrates the 
> failure when \placebtxrendering is omitted.

It is not a failure. The whole intent is to place an appropriate rendering that 
you can tailor to your specific needs. There is little sense in a 
cross-reference (link) or reference number if there is not sort of list.

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] issue with optical bounds (OpenType)

2018-12-07 Thread Hans Hagen

On 12/7/2018 9:14 PM, Pablo Rodriguez wrote:

On 12/7/18 8:15 PM, Hans Hagen wrote:

On 12/7/2018 7:54 PM, Pablo Rodriguez wrote:

Shouldn’t be the output from both methods be exactly the same?


maybe you need to choose a script and/or language


Many thanks for your reply, Hans.

I modified the font myself and the Greek script is required and selected
(with the Latin script, that OT opbd property doesn’t work at all).

The issue is that, although opbd values are used, that results from opbd
and from single placement in addfeature are different (although LuaTeX
reports the same values for lfbd).
because you implement it as kerning and not as opbd (protrusion is not 
kerning) ... you can try to change the name to "lfbd" (if you would 
enable lfbd as feature for sure you would get funny kerning so opbd 
picks up from those instead)



Hans

-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
   tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
-
___
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] Issues using publications subsystem for non-bibliographic database

2018-12-07 Thread Rik Kabel

List,

As a followup, here is a close-to-minimal example which demonstrates the 
failure when \placebtxrendering is omitted.


When run as given, the extract field content is not displayed. When the 
commented line is uncommented, the result includes the content.


   \startbuffer[quotedatabase]
   @quote{qSchopA02,
  extract = {Es wäre gut Bücher kaufen, wenn man die Zeit, sie zu
 lesen, mitkaufen könnte, aber man verweschelt meistens
 den Ankauf der Bücher mit dem Aneignen ihres Inhalts.},
  author  = {Schopenhauer, Arthur},
   }
   \stopbuffer
   \usebtxdataset
  [quotedb]
  [quotedatabase.buffer]
   \definebtxrendering
  [quotedb]
  [dataset=quotedb]
   \setupbtx
  [dataset=quotedb]

   \starttext

  Extract:\par
  \cite[extract][qSchopA02]

  Rendering:\par
   %  \placebtxrendering [quotedb][method=dataset]

  Completeness:\par
  \showbtxdatasetcompleteness[dataset=quotedb]
   \stoptext

The log does not indicate any issues.

Is this expected? Is \placebtxrendering required?

--
Rik

___
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] issue with optical bounds (OpenType)

2018-12-07 Thread Pablo Rodriguez
On 12/7/18 8:15 PM, Hans Hagen wrote:
> On 12/7/2018 7:54 PM, Pablo Rodriguez wrote:
>> Shouldn’t be the output from both methods be exactly the same?
> 
> maybe you need to choose a script and/or language

Many thanks for your reply, Hans.

I modified the font myself and the Greek script is required and selected
(with the Latin script, that OT opbd property doesn’t work at all).

The issue is that, although opbd values are used, that results from opbd
and from single placement in addfeature are different (although LuaTeX
reports the same values for lfbd).

Just in case it helps,

Pablo
-- 
http://www.ousia.tk
___
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] issue with optical bounds (OpenType)

2018-12-07 Thread Hans Hagen

On 12/7/2018 7:54 PM, Pablo Rodriguez wrote:


Shouldn’t be the output from both methods be exactly the same?

maybe you need to choose a script and/or language

Hans

-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
   tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
-
___
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] issue with optical bounds (OpenType)

2018-12-07 Thread Pablo Rodriguez
Dear list,

I’m experiencing a weird issue with optical bounds in OpenType.

Here you have the mandatory sample (font avaiable at
https://gitlab.com/ousia/greek-lfbd/raw/master/TypographicaOStandard-Regular.otf):

\startluacode
fonts.handlers.otf.addfeature {
name = "leftbounds",
type = "single",
data = {
Ἀ = { -32, 0, -32, 0 },
Ἁ = { -32, 0, -32, 0 },
Ἂ = { -70, 0, -70, 0 },
Ἃ = { -70, 0, -70, 0 },
Ἄ = { -50, 0, -50, 0 },
Ἅ = { -50, 0, -50, 0 },
Ἇ = { -42, 0, -42, 0 },
Ἆ = { -42, 0, -42, 0 },
Ἠ = { -212, 0, -212, 0 },
Ἡ = { -212, 0, -212, 0 },
Ἢ = { -258, 0, -258, 0 },
Ἣ = { -258, 0, -258, 0 },
Ἥ = { -286, 0, -286, 0 },
Ἤ = { -286, 0, -286, 0 },
Ἦ = { -246, 0, -246, 0 },
Ἧ = { -246, 0, -246, 0 },
Ὧ = { -196, 0, -196, 0 },
}
}
\stopluacode
\enabletrackers[fonts.protrusion]
\definefontfeature[default][default]
[script=greek, protrusion=quality, opbd=yes]
\definefontfeature[leftbounds][leftbounds=yes]
\showframe
\setuplayout[page]
\definefontfamily[mainface][rm][Typographica Old Standard]
\definefontfamily[mainface][tt][Latin Modern Mono]
\setupbodyfont[mainface, 300pt]
\setupalign[hanging]
\startbuffer
\ifnum\pagenumber=1{\ttxx opbd}\else{\ttxx -opbd}\fi\page
Ω\\
Ὧ\\
Α\\Ἀ\\Α\\Ἁ\\Α\\Ἂ\\Α\\Ἃ\\Α\\Ἄ\\Α\\Ἅ\\Α\\Ἆ\\Α\\Ἇ\\
Ἠ\\Η\\Ἡ\\Η\\Ἢ\\Η\\Ἣ\\Η\\Ἤ\\Η\\Ἥ\\Η\\Ἦ\\Η\\Ἧ\\Η
\stopbuffer
\starttext
\getbuffer

\setupalign[nothanging]
\feature[+][leftbounds]
\getbuffer
\stoptext

OpenType optical bounds are read from the font right:

fonts   > protrusions > left factor 1, right factor 1
fonts   > protrusions > setting left using lfbd
fonts   > protrusions > lfbd -> 0.032 Ἀ (U+01F08)
fonts   > protrusions > lfbd -> 0.032 Ἁ (U+01F09)
fonts   > protrusions > lfbd -> 0.070 Ἂ (U+01F0A)
fonts   > protrusions > lfbd -> 0.070 Ἃ (U+01F0B)
fonts   > protrusions > lfbd -> 0.050 Ἄ (U+01F0C)
fonts   > protrusions > lfbd -> 0.050 Ἅ (U+01F0D)
fonts   > protrusions > lfbd -> 0.042 Ἆ (U+01F0E)
fonts   > protrusions > lfbd -> 0.042 Ἇ (U+01F0F)
fonts   > protrusions > lfbd -> 0.196 Ὧ (U+01F6F)
fonts   > protrusions > lfbd -> 0.246 Ἧ (U+01F2F)
fonts   > protrusions > lfbd -> 0.286 Ἦ (U+01F2E)
fonts   > protrusions > lfbd -> 0.246 Ἥ (U+01F2D)
fonts   > protrusions > lfbd -> 0.258 Ἤ (U+01F2C)
fonts   > protrusions > lfbd -> 0.286 Ἣ (U+01F2B)
fonts   > protrusions > lfbd -> 0.258 Ἢ (U+01F2A)
fonts   > protrusions > lfbd -> 0.212 Ἡ (U+01F29)
fonts   > protrusions > lfbd -> 0.212 Ἠ (U+01F28)

I’m afraid that they aren’t applied accurately.

The same values are used with the property "leftbounds" and they are
perfect in that feature.

Shouldn’t be the output from both methods be exactly the same?

In all glyph pairs, both accented and unaccented glyphs should end in
exactly the same point.

I think this may be a bug, although I may be missing something.

Many thanks for your help,

Pablo
-- 
http://www.ousia.tk


___
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] graphics

2018-12-07 Thread Alan Braslau
On Fri, 7 Dec 2018 09:06:03 +0100
"Mikael P. Sundqvist"  wrote:

> 2) Support for transforming images in a more general way. With the
> zscaled, slanted, ... we are able to transform any object in an affine
> way. It would be nice to be able to transform any object in a more
> general way (i.e. by a mapping defined by the user). The example code
> below shows what happens in the complex plane with a grid and a curve
> when the mapping z to z^2 is applied.

I have generalized my rewrite of the MP graph macros to handle any
arbitrary mapping from data space to drawing (2D) space. At present, I
have only considered the simple functions of log (and sqrt) scales as
well as polar coordinates (x,y) = f(theta,r) with f(theta,r) = (r sin
theta, r cos theta) as I have real use cases for these.

I also consider a simple 3D->2D mapping.

It would be very easy to transform z = a+ib to z^2 for example, as you
show, 


The approach transforms a picture, applying to all stroked and
filled paths, as well as to the *position* of text objects. I have not
looked into somehow transforming a bitmap image.

> Perhaps I am missing something,
> but I'm not able to apply this to a piece of text for example, or to
> apply it directly to a picture. Instead, I have to loop over all
> separate paths. I think the ideal would be to have a "ftransformed"
> (or with some other name), and then just define a function (as fun in
> the example below), and then be able to do "draw X ftransformed fun;",
> where X is some(any?) general object. Is that doable?

for i within pic :
  ...
endfor

So, yes, easy to write a primary (but I don't like the name
"ftransformed"). Using lua helpers can make this efficient.


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] graphics

2018-12-07 Thread luigi scarso
On Fri, Dec 7, 2018 at 9:06 AM Mikael P. Sundqvist  wrote:

> On Tue, Dec 4, 2018 at 6:03 PM Hans Hagen  wrote:
> >
> > Hi,
> >
> > As most mechanism are reasonable okay now we can look into what future
> > versions of ConteXt should provide in terms of functionality. The
> > (luatex) engine is also more of less finished or at least stable in
> > terms of functionality.
> >
> > One possible area of further development is graphics so I'd like to know
> > if there are (reasonable) demands for more graphics support using
> > metapost. Alan and I are on-and-off working on some extensions and one
> > of the things we discuss is visualization of data. The question is of
> > course what should be done in the lua/mp/tex combination and what
> > externally but the combination has some advantages. There has been
> > presentations and discussions at the last meeting and graphics is always
> > a nice topic, and also kind of rewarding in terms of development.
> >
> > Of course other demands can be formulated too, but these then need to
> > come with well defined descriptions (or mockup examples).
> >
> > Hans
> >
> > -
> >Hans Hagen | PRAGMA ADE
> >Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
> > tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
> > -
> >
> ___
> > 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
> >
> ___
>
> Hi,
>
> I don't know if what I describe below is along the lines you ask for,
> but here comes two wishes:
>
> 1) Full support for drawing implicit curve plots. For some curves,
> like a lemniscate
> (https://en.wikipedia.org/wiki/Lemniscate_of_Bernoulli) one can easily
> succeed by using a parametrisation, but sometimes one end up with
> equations and to find a parametrisation might be difficult (not to say
> impossible).

sure, see  eg
https://math.stackexchange.com/questions/904782/is-there-a-general-way-to-parameterize-all-implicit-functions


-- 
luigi
___
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] Framed mathematics

2018-12-07 Thread Wolfgang Schuster

Mathias Schickel schrieb am 07.12.18 um 12:09:

Dear list,

it seems that \mframed does not align properly. Compare the example 
fount at https://www.contextgarden.net/Framed#Location_parameter to 
the compiled example attached.


What can I do to get a correctly aligned framed formula?

\inmframed{...}

Wolfgang

___
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] Framed mathematics

2018-12-07 Thread Mathias Schickel
Dear list,it seems that \mframed does not align properly. Compare the example fount at https://www.contextgarden.net/Framed#Location_parameter to the compiled example attached.What can I do to get a correctly aligned framed formula?Many thanks for you help,Mathias

mframed.tex
Description: TeX document


mframed.pdf
Description: Adobe PDF 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] graphics

2018-12-07 Thread Mikael P. Sundqvist
On Tue, Dec 4, 2018 at 6:03 PM Hans Hagen  wrote:
>
> Hi,
>
> As most mechanism are reasonable okay now we can look into what future
> versions of ConteXt should provide in terms of functionality. The
> (luatex) engine is also more of less finished or at least stable in
> terms of functionality.
>
> One possible area of further development is graphics so I'd like to know
> if there are (reasonable) demands for more graphics support using
> metapost. Alan and I are on-and-off working on some extensions and one
> of the things we discuss is visualization of data. The question is of
> course what should be done in the lua/mp/tex combination and what
> externally but the combination has some advantages. There has been
> presentations and discussions at the last meeting and graphics is always
> a nice topic, and also kind of rewarding in terms of development.
>
> Of course other demands can be formulated too, but these then need to
> come with well defined descriptions (or mockup examples).
>
> Hans
>
> -
>Hans Hagen | PRAGMA ADE
>Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
> tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
> -
> ___
> 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
> ___

Hi,

I don't know if what I describe below is along the lines you ask for,
but here comes two wishes:

1) Full support for drawing implicit curve plots. For some curves,
like a lemniscate
(https://en.wikipedia.org/wiki/Lemniscate_of_Bernoulli) one can easily
succeed by using a parametrisation, but sometimes one end up with
equations and to find a parametrisation might be difficult (not to say
impossible). I asked about this a while ago and got a simple solution
working for that curve, but I think a general working solution would
be neat. I think the bernoulli lemniscate could be a good test curve,
since it intersect itself.

2) Support for transforming images in a more general way. With the
zscaled, slanted, ... we are able to transform any object in an affine
way. It would be nice to be able to transform any object in a more
general way (i.e. by a mapping defined by the user). The example code
below shows what happens in the complex plane with a grid and a curve
when the mapping z to z^2 is applied. Perhaps I am missing something,
but I'm not able to apply this to a piece of text for example, or to
apply it directly to a picture. Instead, I have to loop over all
separate paths. I think the ideal would be to have a "ftransformed"
(or with some other name), and then just define a function (as fun in
the example below), and then be able to do "draw X ftransformed fun;",
where X is some(any?) general object. Is that doable?

/Mikael

%%% Example code
\starttext
\startMPpage[offset=3bp]
u:=3cm;

def fun(expr x,y) = (x**2-y**2,2*x*y) enddef;

def sq(expr kv,s) =
fun(xpart point 0 along kv,ypart point 0 along kv)
  for i=s step s until 1: -- fun(xpart point i along kv,ypart point i
along kv) endfor
enddef;

path rp;
rp = (0,-0.8)..(0.7,-0.2)..(0.7,0.6){dir
150}..(-0.7,0.4)..(-0.4,-0.5){dir 0}..cycle;


% Draw the original grid and the path
for i = -1 step 1/10 until 1+eps:
 for j = -1 step 1/10 until 1+eps:
  draw ((i,-1)--(i,1)) scaled u;
  draw ((-1,j)--(1,j)) scaled u;
 endfor;
endfor;

draw rp scaled u withcolor darkred withpen pencircle scaled 2bp;

% Draw the grid and curve after map z->z^2
draw image(
for i = -1 step 1/10 until 1+eps:
 for j = 0 step 1/10 until 1+eps:
  draw (sq(((i,0)--(i,1)),1/100)) scaled u;
  draw (sq(((-1,j)--(1,j)),1/100)) scaled u;
 endfor;
endfor;
draw (sq(rp,1/100)) scaled u withcolor darkred withpen pencircle scaled 2bp;
) xshifted 2.5u;

\stopMPpage
\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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___