From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/104858 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Jon Wong Newsgroups: gmane.comp.tex.context Subject: Re: startnarrower and framed? Date: Wed, 21 Aug 2019 21:37:19 +0800 Message-ID: <051AF450-F973-469F-8ED6-1A8C96BCBC0D@gmail.com> References: <33F569F6-26DD-479E-A63A-642E6EC9FBC2@gmail.com> <160C9373-1C56-4A1A-9017-AB02D89CB125@gmail.com> Reply-To: mailing list for ConTeXt users Mime-Version: 1.0 (Mac OS X Mail 12.4 \(3445.104.11\)) Content-Type: multipart/mixed; boundary="===============3578633504792560463==" Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="170901"; mail-complaints-to="usenet@blaine.gmane.org" To: mailing list for ConTeXt users Original-X-From: ntg-context-bounces@ntg.nl Wed Aug 21 15:37:53 2019 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from zapf.boekplan.nl ([5.39.185.232] helo=zapf.ntg.nl) by blaine.gmane.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1i0QoD-000iME-Ax for gctc-ntg-context-518@m.gmane.org; Wed, 21 Aug 2019 15:37:53 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by zapf.ntg.nl (Postfix) with ESMTP id CE6F515381E; Wed, 21 Aug 2019 15:37:27 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at zapf.boekplan.nl Original-Received: from zapf.ntg.nl ([127.0.0.1]) by localhost (zapf.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id fgV4r9hifdTt; Wed, 21 Aug 2019 15:37:26 +0200 (CEST) Original-Received: from zapf.ntg.nl (localhost [127.0.0.1]) by zapf.ntg.nl (Postfix) with ESMTP id E9DA615382C; Wed, 21 Aug 2019 15:37:26 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by zapf.ntg.nl (Postfix) with ESMTP id E3C56153827 for ; Wed, 21 Aug 2019 15:37:25 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at zapf.boekplan.nl Original-Received: from zapf.ntg.nl ([127.0.0.1]) by localhost (zapf.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id eCrLHXtJOqGP for ; Wed, 21 Aug 2019 15:37:25 +0200 (CEST) Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=209.85.210.177; helo=mail-pf1-f177.google.com; envelope-from=jhannwong@gmail.com; receiver= Original-Received: from mail-pf1-f177.google.com (mail-pf1-f177.google.com [209.85.210.177]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by zapf.ntg.nl (Postfix) with ESMTPS id C990C15381E for ; Wed, 21 Aug 2019 15:37:24 +0200 (CEST) Original-Received: by mail-pf1-f177.google.com with SMTP id w26so1442686pfq.12 for ; Wed, 21 Aug 2019 06:37:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:mime-version:subject:date:references:to:in-reply-to:message-id; bh=ZzSwJkEqgA6YyxkEK2SltR7CZQp6f2eOL56ccwgRMvU=; b=mDJ8mjuXYvr6JI/qqM34JM6a5vZKW9hZcBpr5OXrYIcgvOsxHyHyBLCVMN744X2Uo4 aPcoMJmF/PTrIYxxGljvVLGds+teltrEPR0o6uhjVeTzUpZQcEWFSYtgRjcnleMxEuQT fX1gsGthLsMb07wvziPpswVOOT3+94KEHg7Vlz7DFAu3Rlsc5c/cuVr7k2QSo3IU06s6 uhFP53YHq6PUZQy370QkSW0KOn5wXpaywTUuT2SrsSCjg8Vh/597VlY1NhlObGyKVkqx KhIwwixOzWX75Jmp96eY+56doYk3gL6Ccv1dZlVKP/3VGwnRtUyJ71PH4k5wYiFb7LJ2 QZsQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:mime-version:subject:date:references:to :in-reply-to:message-id; bh=ZzSwJkEqgA6YyxkEK2SltR7CZQp6f2eOL56ccwgRMvU=; b=t75tNvyF2WigAlVRM1X2hF1IlC6nOhCaxwVG1qJphhHP1BrGX9aqDw4M+Popuojsdb YhQtngZZIy0m6SrEt9fcExBxdiT3e/pP8fVkUmkR/kwe6EkCv6YCZApzjDukjgzsa4MW aO7cEv/+TnPkIv6j/NS8tLba0l9EZrpuasWcki8+Qp3IAeXaoIdBJC9doecQKKxbK7dg l8eS8fVc/8P5qIQN1cfllMRBMmVTmRVQwBdEFAqthZ12blDuI6jFPdwjdnfqpsJYFBCi tUQ3cF30XPetPu7Z+0fUZUVlxQNfmA1Yur+3zYqXeh1BlPuHQeKIjfiIJSctg/m96dlp WUqQ== X-Gm-Message-State: APjAAAX8ZRYQvoxX+/EGrRNnFnROy+s3pnfec9jwNMnQqriR1sL9FgRG SjcAfvxOFMH+R+eM5XVAtUQQ6I1YF/Q= X-Google-Smtp-Source: APXvYqx4FZD/TD1v9djQp44REsn+8A6NBFqjyZY820JaaN+d6UKGOrO0pd7wp7fj4hXGcLua7DLKIw== X-Received: by 2002:a17:90a:21eb:: with SMTP id q98mr35364pjc.23.1566394643299; Wed, 21 Aug 2019 06:37:23 -0700 (PDT) Original-Received: from [192.168.0.182] ([202.133.194.192]) by smtp.gmail.com with ESMTPSA id 5sm21091360pgh.93.2019.08.21.06.37.22 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 21 Aug 2019 06:37:22 -0700 (PDT) In-Reply-To: X-Mailer: Apple Mail (2.3445.104.11) X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.26 Precedence: list List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: ntg-context-bounces@ntg.nl Original-Sender: "ntg-context" Xref: news.gmane.org gmane.comp.tex.context:104858 Archived-At: --===============3578633504792560463== Content-Type: multipart/alternative; boundary="Apple-Mail=_F4AACF03-4FB8-4524-A3A7-91116C8BC5A2" --Apple-Mail=_F4AACF03-4FB8-4524-A3A7-91116C8BC5A2 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 Hi all, Ah, found the solution in TextBackground. At here: = https://www.contextgarden.net/TextBackground = Can I have a 2-segment (2 vboxes) TextBackground (presumably with 2 = TextBackgrounds, zero vspace between them)? For the top segment, I want rounded corners only for top corners = (corner=3D03 with \framed). Seems I really should dig into MetaFun and TextBackground. Looks really = fun and useful. Sorry for the noise. Am a little carried away exploring the Garden. :-P Regards Jon > On Aug 21, 2019, at 9:25 PM, Jon Wong wrote: >=20 > Hi all, >=20 > Sorry, my solution didn=E2=80=99t work. >=20 > My purpose of using \startnarrower is to have some paragraphs of text = inside the \framed. Unfortunately, it seems \framed doesn=E2=80=99t take = paragraphs. >=20 > \startframedtext doesn=E2=80=99t have as many border options as = \framed. >=20 > Should I use overlays? Or layers? It seems layers require absolutely = positioning, and can=E2=80=99t be logically contained inside a = \startnarrower? >=20 > Regards > Jon >=20 >=20 >> On Aug 21, 2019, at 8:53 PM, Jon Wong wrote: >>=20 >> Hi all, >>=20 >> I got some progress! >>=20 >> \setupnarrower[left=3D2cm, right=3D2cm] % what does middle do, = actually? >> \startnarrower >> \dontleavehmode\framed[width=3Dlocal]{testing} >>=20 >> Since this works for left offset: \framed[width=3Dlocal]{testing} >> \endnarrower >>=20 >> So, how do I do a gradient background? Yeah, I know I have to dive = into MetaPost and MetaFun some time. Is that where the solution is? >>=20 >> Regards >> Jon >>=20 >>> On Aug 21, 2019, at 8:14 PM, Jon Wong wrote: >>>=20 >>> Hi all, >>>=20 >>> I want to have a \startnarrower effect. But I also want that segment = to have a border (hopefully a gradient background color too!). >>>=20 >>> I tried: >>>=20 >>> \startnarrower >>> \framed{testing} >>>=20 >>> Seems framed doesn=E2=80=99t observe startnarrower commands. >>> \endnarrower >>>=20 >>> How do I achieve that? >>>=20 >>> Regards >>> Jon >>=20 >=20 --Apple-Mail=_F4AACF03-4FB8-4524-A3A7-91116C8BC5A2 Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset=utf-8 Hi = all,

Ah, found the = solution in TextBackground. At here: https://www.contextgarden.net/TextBackground

Can I have a 2-segment = (2 vboxes) TextBackground (presumably with 2 TextBackgrounds, zero = vspace between them)?

For the top segment, I want rounded corners only for top = corners (corner=3D03 with \framed).

Seems I really should dig into MetaFun = and TextBackground. Looks really fun and useful.

Sorry for the noise. Am a little = carried away exploring the Garden. :-P

Regards
Jon


On Aug = 21, 2019, at 9:25 PM, Jon Wong <jhannwong@gmail.com> wrote:

Hi = all,

Sorry, my solution didn=E2=80=99t = work.

My purpose of using \startnarrower is = to have some paragraphs of text inside the \framed. Unfortunately, it = seems \framed doesn=E2=80=99t take paragraphs.

\startframedtext doesn=E2=80=99t have as many border options = as \framed.

Should I use overlays? Or = layers? It seems layers require absolutely positioning, and can=E2=80=99t = be logically contained inside a \startnarrower?

Regards
Jon


On Aug 21, 2019, at 8:53 = PM, Jon Wong <jhannwong@gmail.com> wrote:

Hi all,

I got some progress!

\setupnarrower[left=3D2cm, right=3D2cm] % what = does middle do, actually?
\startnarrower
= \dontleavehmode\framed[width=3Dlocal]{testing}

Since this works for left offset: = \framed[width=3Dlocal]{testing}
\endnarrower

So, how do I do a gradient background? Yeah, I = know I have to dive into MetaPost and MetaFun some time. Is that where = the solution is?

Regards
Jon
On Aug = 21, 2019, at 8:14 PM, Jon Wong <jhannwong@gmail.com> wrote:

Hi all,

I want to have a = \startnarrower effect. But I also want that segment to have a border = (hopefully a gradient background color too!).

I tried:

\startnarrower
\framed{testing}

Seems framed = doesn=E2=80=99t observe startnarrower commands.
\endnarrower

How do I achieve = that?

Regards
Jon



= --Apple-Mail=_F4AACF03-4FB8-4524-A3A7-91116C8BC5A2-- --===============3578633504792560463== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19f X19fX19fX19fX19fX19fX19fX19fX19fX18KSWYgeW91ciBxdWVzdGlvbiBpcyBvZiBpbnRlcmVz dCB0byBvdGhlcnMgYXMgd2VsbCwgcGxlYXNlIGFkZCBhbiBlbnRyeSB0byB0aGUgV2lraSEKCm1h aWxsaXN0IDogbnRnLWNvbnRleHRAbnRnLm5sIC8gaHR0cDovL3d3dy5udGcubmwvbWFpbG1hbi9s aXN0aW5mby9udGctY29udGV4dAp3ZWJwYWdlICA6IGh0dHA6Ly93d3cucHJhZ21hLWFkZS5ubCAv IGh0dHA6Ly9jb250ZXh0LmFhbmhldC5uZXQKYXJjaGl2ZSAgOiBodHRwczovL2JpdGJ1Y2tldC5v cmcvcGhnL2NvbnRleHQtbWlycm9yL2NvbW1pdHMvCndpa2kgICAgIDogaHR0cDovL2NvbnRleHRn YXJkZW4ubmV0Cl9fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19f X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fCg== --===============3578633504792560463==--