From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/75337 Path: news.gmane.org!not-for-mail From: Wolfgang Schuster Newsgroups: gmane.comp.tex.context Subject: Re: how can I use framewidth in calculations Date: Sat, 24 Mar 2012 12:23:38 +0100 Message-ID: <91D41280-0A20-41B6-93A1-A25B7F11AB9F@googlemail.com> References: <4F6CFF5C.7040604@uni-bonn.de> Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 (Apple Message framework v1257) Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: dough.gmane.org 1332588249 10315 80.91.229.3 (24 Mar 2012 11:24:09 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Sat, 24 Mar 2012 11:24:09 +0000 (UTC) To: mailing list for ConTeXt users Original-X-From: ntg-context-bounces@ntg.nl Sat Mar 24 12:24:08 2012 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from balder.ntg.nl ([195.12.62.10]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1SBP4p-0006wq-6I for gctc-ntg-context-518@m.gmane.org; Sat, 24 Mar 2012 12:24:07 +0100 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id E56D6101E7; Sat, 24 Mar 2012 12:24:05 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (localhost [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 7lt+A52iFs9i; Sat, 24 Mar 2012 12:24:05 +0100 (CET) Original-Received: from [127.0.0.1] (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 4BA66101DF; Sat, 24 Mar 2012 12:24:04 +0100 (CET) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 53FCC101DF for ; Sat, 24 Mar 2012 12:24:02 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (localhost [127.0.0.1]) (amavisd-new, port 10024) with LMTP id I8jYcQ61tyxq for ; Sat, 24 Mar 2012 12:24:01 +0100 (CET) Original-Received: from filter1-ams.mf.surf.net (filter1-ams.mf.surf.net [192.87.102.69]) by balder.ntg.nl (Postfix) with ESMTP id 85B3610194 for ; Sat, 24 Mar 2012 12:24:01 +0100 (CET) Original-Received: from mail-we0-f169.google.com (mail-we0-f169.google.com [74.125.82.169]) by filter1-ams.mf.surf.net (8.14.3/8.14.3/Debian-9.4) with ESMTP id q2OBO04N008483 for ; Sat, 24 Mar 2012 12:24:00 +0100 Original-Received: by werj55 with SMTP id j55so4335192wer.14 for ; Sat, 24 Mar 2012 04:24:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=20120113; h=content-type:mime-version:subject:from:in-reply-to:date :content-transfer-encoding:message-id:references:to:x-mailer; bh=TuHgDXZ4d2DgU49gUiJgSQfIvFow7StNzkcKscXYXZc=; b=UEWOtV2InmfzgGPfbelz6gTDKxUmwBT0fskdwInNb3KiYN26hLtyTeo3onSt/Z5IfR pd8aOYTP9qy6mRyyUiQKlgUcVyPwKATsh5CsFSbKaPTeL0v8JhaZWMnYVD6smTcFJq+J eqB/dFcX8Pa6G91Vtfex0htwjMAmgWnD2oBXQ+5GbxT46BeyU/zVTwNiQ7GD5K8QsgoJ jGBOY3HOODuv4o3t/dVthvW7DKq3cNWAuHkhQuxb8mFu1Tp0OBHaAjmYDrXl3gg6Usea qMuTTNo3Q4ULFOEHZEJow3txrQX5MYpzMV1IRMXHf0LAv2dgP1CdJc24DxfBsJ1KUnVS MlaQ== Original-Received: by 10.180.107.164 with SMTP id hd4mr4283841wib.18.1332588240165; Sat, 24 Mar 2012 04:24:00 -0700 (PDT) Original-Received: from [192.168.2.36] (p57AFB53C.dip.t-dialin.net. [87.175.181.60]) by mx.google.com with ESMTPS id ff2sm36300244wib.9.2012.03.24.04.23.54 (version=TLSv1/SSLv3 cipher=OTHER); Sat, 24 Mar 2012 04:23:59 -0700 (PDT) In-Reply-To: <4F6CFF5C.7040604@uni-bonn.de> X-Mailer: Apple Mail (2.1257) X-Bayes-Prob: 0.0001 (Score 0, tokens from: @@RPTN) X-CanIt-Geo: ip=74.125.82.169; country=US; latitude=38.0000; longitude=-97.0000; http://maps.google.com/maps?q=38.0000,-97.0000&z=6 X-CanItPRO-Stream: uu:ntg-context@ntg.nl (inherits from uu:default, base:default) X-Canit-Stats-ID: 0NGNno0Bo - 52a9bea879f4 - 20120324 (trained as not-spam) X-Scanned-By: CanIt (www . roaringpenguin . com) on 192.87.102.69 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:75337 Archived-At: Am 23.03.2012 um 23:55 schrieb Thomas A. Schmitz: > Hi all, > > maybe I'm overlooking something obvious, but...: when I have a figure, I can calculate its width dependent on the page width, and it will adapt: > > \starttext > > \externalfigure[cow][width=0.6\textwidth] > > \stoptext > > But is there a method for similar calculations inside a frame? Here's what I tried, but it doesn't give the expected result (the image is much smaller than expected): > > \starttext > > \framed[width=7cm]{\externalfigure[cow][width=\the\dimexpr0.9\framedparameter{width}\relax]} > > \stoptext When you set a value for the align-key the \framed command uses a \vbox for the content and you can use \hsize for the width. \starttext \framed[width=7cm,align=middle]{\externalfigure[cow][width=0.9\hsize]} \stoptext 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://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________