From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/68772 Path: news.gmane.org!not-for-mail From: Marco Newsgroups: gmane.comp.tex.context Subject: Re: checking mainlanguage setup Date: Fri, 27 May 2011 12:22:38 +0200 Message-ID: <20110527122238.4c709eb2@glyph> References: Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: dough.gmane.org 1306491795 4180 80.91.229.12 (27 May 2011 10:23:15 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Fri, 27 May 2011 10:23:15 +0000 (UTC) To: ntg-context@ntg.nl Original-X-From: ntg-context-bounces@ntg.nl Fri May 27 12:23:10 2011 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 1QPuCB-0000sD-Hm for gctc-ntg-context-518@m.gmane.org; Fri, 27 May 2011 12:23:07 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id DC227CAD7D; Fri, 27 May 2011 12:23:06 +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 cEtAFswYHHKs; Fri, 27 May 2011 12:23:04 +0200 (CEST) Original-Received: from balder.ntg.nl (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 6441BCAD63; Fri, 27 May 2011 12:23:04 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 6178ACAD63 for ; Fri, 27 May 2011 12:23:03 +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 r-o13lyw2L64 for ; Fri, 27 May 2011 12:22:52 +0200 (CEST) Original-Received: from filter4-nij.mf.surf.net (filter4-nij.mf.surf.net [195.169.124.155]) by balder.ntg.nl (Postfix) with ESMTP id 37342CAD4A for ; Fri, 27 May 2011 12:22:52 +0200 (CEST) Original-Received: from lo.gmane.org (lo.gmane.org [80.91.229.12]) by filter4-nij.mf.surf.net (8.14.3/8.14.3/Debian-5+lenny1) with ESMTP id p4RAMpOC012702 for ; Fri, 27 May 2011 12:22:51 +0200 Original-Received: from list by lo.gmane.org with local (Exim 4.69) (envelope-from ) id 1QPuBu-0000go-Hb for ntg-context@ntg.nl; Fri, 27 May 2011 12:22:50 +0200 Original-Received: from miun118-87.dynamic.miun.se ([193.10.118.87]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 27 May 2011 12:22:50 +0200 Original-Received: from netuse by miun118-87.dynamic.miun.se with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 27 May 2011 12:22:50 +0200 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 30 Original-X-Complaints-To: usenet@dough.gmane.org X-Gmane-NNTP-Posting-Host: miun118-87.dynamic.miun.se X-Newsreader: Claws Mail 3.7.6 (GTK+ 2.22.0; x86_64-pc-linux-gnu) X-Bayes-Prob: 0.0001 (Score 0, tokens from: @@RPTN) X-CanIt-Geo: ip=80.91.229.12; country=NO; latitude=62.0000; longitude=10.0000; http://maps.google.com/maps?q=62.0000,10.0000&z=6 X-CanItPRO-Stream: uu:ntg-context@ntg.nl (inherits from uu:default, base:default) X-Canit-Stats-ID: 04EMymP5p - deb6be2eaca4 - 20110527 X-Scanned-By: CanIt (www . roaringpenguin . com) on 195.169.124.155 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:68772 Archived-At: > I'd like to do the following type of setup. > > > if mainlanguage == kr then > > do something A > > elseif mainlanguage == en then > > do something B > > else > do something C > > endif \starttext \startluacode if languages.current() == "kr" then context("Something A") elseif languages.current() == "en" then context("Something B") else context("Something C") end \stopluacode \stoptext 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://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________