From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/61159 Path: news.gmane.org!not-for-mail From: Taco Hoekwater Newsgroups: gmane.comp.tex.context Subject: Re: ConTeXt meeting Lua tutorials Date: Mon, 23 Aug 2010 20:22:19 +0200 Message-ID: <4C72BC5B.80107@elvenkind.com> References: <4C6FBCFE.4030904@elvenkind.com> Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; Format="flowed" Content-Transfer-Encoding: 7bit X-Trace: dough.gmane.org 1282587754 20779 80.91.229.12 (23 Aug 2010 18:22:34 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Mon, 23 Aug 2010 18:22:34 +0000 (UTC) To: mailing list for ConTeXt users Original-X-From: ntg-context-bounces@ntg.nl Mon Aug 23 20:22:30 2010 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from balder.ntg.nl ([195.12.62.10]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1OnbfB-0007FX-Mx for gctc-ntg-context-518@m.gmane.org; Mon, 23 Aug 2010 20:22:29 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id D1FD9CA592; Mon, 23 Aug 2010 20:22:27 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id CGuZuOpq5YOd; Mon, 23 Aug 2010 20:22:25 +0200 (CEST) Original-Received: from balder.ntg.nl (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 0A39CCA59E; Mon, 23 Aug 2010 20:22:25 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 2EC3DCA59E for ; Mon, 23 Aug 2010 20:22:23 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id U1Ukz7NpPxYI for ; Mon, 23 Aug 2010 20:22:20 +0200 (CEST) Original-Received: from filter3-til.mf.surf.net (filter3-til.mf.surf.net [194.171.167.219]) by balder.ntg.nl (Postfix) with ESMTP id 86C7DCA592 for ; Mon, 23 Aug 2010 20:22:20 +0200 (CEST) Original-Received: from smtp-vbr15.xs4all.nl (smtp-vbr15.xs4all.nl [194.109.24.35]) by filter3-til.mf.surf.net (8.14.3/8.14.3/Debian-5+lenny1) with ESMTP id o7NIMJCk006577 for ; Mon, 23 Aug 2010 20:22:20 +0200 Original-Received: from boo.fritz.box (boo.demon.nl [83.163.247.99]) (authenticated bits=0) by smtp-vbr15.xs4all.nl (8.13.8/8.13.8) with ESMTP id o7NIMJ7L012181 for ; Mon, 23 Aug 2010 20:22:19 +0200 (CEST) (envelope-from taco@elvenkind.com) User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.8) Gecko/20100809 Mandriva/3.1.2-3mdv2011.0 (2011.0) Thunderbird/3.1.2 In-Reply-To: X-Virus-Scanned: by XS4ALL Virus Scanner X-Bayes-Prob: 0.0001 (Score 0, tokens from: @@RPTN) X-CanIt-Geo: ip=194.109.24.35; country=NL; region=07; city=Amsterdam; latitude=52.3500; longitude=4.9167; http://maps.google.com/maps?q=52.3500,4.9167&z=6 X-CanItPRO-Stream: uu:ntg-context@ntg.nl (inherits from uu:default, base:default) X-Canit-Stats-ID: 0eCVSmjTK - e998e004b4e7 - 20100823 X-Scanned-By: CanIt (www . roaringpenguin . com) on 194.171.167.219 X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.12 Precedence: list List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: ntg-context-bounces@ntg.nl Errors-To: ntg-context-bounces@ntg.nl Xref: news.gmane.org gmane.comp.tex.context:61159 Archived-At: On 08/23/2010 06:37 PM, Mojca Miklavec wrote: > [the following is just some brainstorming] > > > For fonts, agreed with Luigi, it would be nice to see some lua code that > a) takes a bunch of fonts as input (like: > regular/italic/bold/bolditalic/script) and writes some simple sentence > with all variants; switching options on and off (after thinking a bit, > this can just as well be done in almost-plain-TeX in LuaTeX, so maybe > it's not such a good idea) This teaches nothing that really needs the lua font interface, so I do not think that is such a good idea either. > b) takes a font as input and makes a really nice graphical representation: > - font name (under different OS systems?), file name, ... > - available features > - glyph repertoire (index/Unicode point/name/big drawing) > - alternatives of the same glyph (under small caps or when alternative > styles play some role), ... [i know it's incomplete] > - ... > - takes some input string and writes out that sentence under different > permutations of available features (with some user's help) This sounds interesting (and, also important, doable up to a reasonable point within the available time). > c) shows some OpenType math tricks (visually?) or even does the same > as showttf/poin b, but for math (challenge :) :) :) OpenType Math really uses next to no lua code, it is almost all coded in the executable proper, so it would be hard to do something illustrative that is not overly complex on purpose at the same time. As a beginner's tutorial, that is probably a step too far. Myself, I was thinking of how to create a virtual font on the fly. but b) definitely sounds interesting. > One of possible ideas for an advanced example (just brainstorming; you > need to judge whether it makes sense or not; it might be too long& > complicated, but it would be instructive to see both parsing and > drawing at the same time): > - parse some very simple text input > - draw the image with mplib > For example, one could try to parse: > http://www.daylight.com/dayhtml/doc/theory/theory.smiles.html > (but with some strict restrictions, like: no cycles allowed, no > reactions, ... only element names, =, # and parenthesis with at most > one branch; no nested ones) > and then try to draw a full circle for every element and connect the > circles with single/double/triple lines (no attempt for optimal > placement and nothing complicated). Should be ok, if I cheat a bit on the creation of metapost macros. I had a somewhat similar idea myself, for parsing turtle graphics, but that needed quite a bit of lpeg for which we may not have enough time, so I had almost given up on parsing stuff. this chemistry stuff is doable within the time constraints, I think. 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 : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________