From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/31036 Path: news.gmane.org!not-for-mail From: Peter Rolf Newsgroups: gmane.comp.tex.context Subject: Re: calculations Date: Tue, 26 Sep 2006 22:14:16 +0200 Message-ID: <45198A18.2050407@gmx.net> References: <93F3046C-F059-4C5D-AC7F-73DFD5A4AAD6@fiee.net> <0DE942E8-4FE2-41E2-8C04-6D2DD127172D@fiee.net> <4512E411.2070504@gmx.net> <181E3AED-683E-4B2C-9D7B-5AE966E621E5@fiee.net> <4517A56C.5020704@gmx.net> <5563EF4F-4088-42F3-A0C9-B33540FFA3A5@fiee.net> <4518CE66.4080703@elvenkind.com> Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1159301793 13293 80.91.229.2 (26 Sep 2006 20:16:33 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Tue, 26 Sep 2006 20:16:33 +0000 (UTC) Original-X-From: ntg-context-bounces@ntg.nl Tue Sep 26 22:16:25 2006 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from ronja.vet.uu.nl ([131.211.172.88] helo=ronja.ntg.nl) by ciao.gmane.org with esmtp (Exim 4.43) id 1GSJK3-00065X-02 for gctc-ntg-context-518@m.gmane.org; Tue, 26 Sep 2006 22:14:31 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id A87561FF73; Tue, 26 Sep 2006 22:14:30 +0200 (CEST) Original-Received: from ronja.ntg.nl ([127.0.0.1]) by localhost (smtp.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 05377-06-11; Tue, 26 Sep 2006 22:14:25 +0200 (CEST) Original-Received: from ronja.vet.uu.nl (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 4AC901FF48; Tue, 26 Sep 2006 22:14:25 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 88F901FF6E for ; Tue, 26 Sep 2006 22:14:23 +0200 (CEST) Original-Received: from ronja.ntg.nl ([127.0.0.1]) by localhost (smtp.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 05377-06-10 for ; Tue, 26 Sep 2006 22:14:16 +0200 (CEST) Original-Received: from mail.gmx.net (mail.gmx.de [213.165.64.20]) by ronja.ntg.nl (Postfix) with SMTP id 099C71FF48 for ; Tue, 26 Sep 2006 22:14:15 +0200 (CEST) Original-Received: (qmail invoked by alias); 26 Sep 2006 20:14:13 -0000 Original-Received: from i577B9176.versanet.de (EHLO [192.168.1.3]) [87.123.145.118] by mail.gmx.net (mp012) with SMTP; 26 Sep 2006 22:14:13 +0200 X-Authenticated: #24293357 User-Agent: Thunderbird 1.5.0.7 (Windows/20060909) Original-To: mailing list for ConTeXt users In-Reply-To: X-Enigmail-Version: 0.94.0.0 X-Y-GMX-Trusted: 0 X-Virus-Scanned: amavisd-new at ntg.nl X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.7 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 X-Virus-Scanned: amavisd-new at ntg.nl Xref: news.gmane.org gmane.comp.tex.context:31036 Archived-At: Hi Hraban, Henning Hraban Ramm wrote: > Am 2006-09-26 um 08:53 schrieb Taco Hoekwater: > >>> I think I tried everything but didn't get it to work. >>> For the moment I use: >>> \def\LPscale{0.6315789} % downscale the image >>> \def\LPkscale{632} >>> % doesn't work: \def\LPkscale{\numexpr1000\LPscale\relax} >> Missed this thread so far, but how about this? >> \edef\LPkscale{\the\numexpr1000\LPscale\relax} > > Thank you. > That doesn't run on an error, but scales way too much. > With > \def\LPscale{0.6315789} > the command should have the same effect as > \def\LPkscale{632} > > But > \edef\LPkscale{\the\numexpr1000\LPscale\relax} > seems to scale about 100 times too much. > maybe \numexpr1000\dimexpr\LPscale\relax\relax I have a good feeling about it ;) > I simply(?!?) want to multiply some floating point value with 1000 to > set the "scale" parameter of \externalfigure. > Why ist this so difficult? > Because there is no normal float type in TeX like in common programming languages. Also all calculation is limited by \maxdimen. > Is there a book or tutorial on TeX as a programming language somewhere? > I like 'Tex by Topic' alot. Don't know if that fits your needs. http://archive.contextgarden.net/message/20060901.140544.1fe86b32.en.html Greetings, Peter > > > Greetlings from Lake Constance! > Hraban > --- > http://www.fiee.net/texnique/ > http://contextgarden.net > http://www.cacert.org (I'm an assurer) > > _______________________________________________ > ntg-context mailing list > ntg-context@ntg.nl > http://www.ntg.nl/mailman/listinfo/ntg-context > >