From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/95050 Path: news.gmane.org!not-for-mail From: Wolfgang Schuster Newsgroups: gmane.comp.tex.context Subject: Re: Set default background color or pattern for tables Date: Mon, 30 May 2016 18:45:37 +0200 Message-ID: <574C6E31.1040408@gmail.com> References: Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============2154628365395840789==" X-Trace: ger.gmane.org 1464626770 12228 80.91.229.3 (30 May 2016 16:46:10 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 30 May 2016 16:46:10 +0000 (UTC) To: mailing list for ConTeXt users Original-X-From: ntg-context-bounces@ntg.nl Mon May 30 18:45:58 2016 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 plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1b7QKD-0007gU-OZ for gctc-ntg-context-518@m.gmane.org; Mon, 30 May 2016 18:45:57 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by zapf.ntg.nl (Postfix) with ESMTP id 83681DF36; Mon, 30 May 2016 18:45:48 +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 r6QQI-lIj7d7; Mon, 30 May 2016 18:45:47 +0200 (CEST) Original-Received: from zapf.ntg.nl (localhost [IPv6:::1]) by zapf.ntg.nl (Postfix) with ESMTP id CDC10DFDD; Mon, 30 May 2016 18:45:47 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by zapf.ntg.nl (Postfix) with ESMTP id 0492CDEFD for ; Mon, 30 May 2016 18:45:46 +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 SrmRHGkxyhEX for ; Mon, 30 May 2016 18:45:45 +0200 (CEST) Original-Received: from mail-wm0-f48.google.com (mail-wm0-f48.google.com [74.125.82.48]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by zapf.ntg.nl (Postfix) with ESMTPS id 85146DEDB for ; Mon, 30 May 2016 18:45:35 +0200 (CEST) Original-Received: by mail-wm0-f48.google.com with SMTP id n129so94488754wmn.1 for ; Mon, 30 May 2016 09:45:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:subject:references :in-reply-to; bh=OxL3EPh7Skt7uqaSFB4gbp06hW2FJYooXqyiHsxoqIk=; b=HOjCOHUJi6drwnEj67EP/WB63AUw3WGkWCYp64aQLQlEu4zl67MEPtZeIsPkQ5tkSD rs+LmqQdOzysyeqafAkXZhv1nu1X8iHgUCc4QcvrMgDYH0vSvTNJ5RLbhFK7dXsS1di8 IkbCaiEcqcn04NRAn3BAJ8SDmVRmsRMzq1jc9l5jBXYNqbeQFVTPSp+AWLZpqOuL/1+2 /L3q2PUqTUO0oQnwU2cuUmbrUP278B63J+M4R7kShHud/GlYNOdkwnl4qrB+BDeBNQtK g4zuqIqhtF2QJlJkj8jsOkbwZnckmGFJxnfjmdd23T+6WOof3vR667OEyg3bYMGgaSy3 Xphg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:message-id:date:from:user-agent:mime-version:to :subject:references:in-reply-to; bh=OxL3EPh7Skt7uqaSFB4gbp06hW2FJYooXqyiHsxoqIk=; b=FDa7maAUsCurjn62NVyBALLHg9pR2R8HBjslgNCo1TkRpcWXMC6Purk4hxDU9h1iT+ XJzNfai668Fi4Dgig7k9+yoKdrD/Gyn5O1TT5NwYcKXbz5wG+FITpDnrp4MJa3Jkkajk g4hGKva+o5n8mkGdBSXw78TcrCaZX4a2crfEPLN8s2H2osNQlqso0b4i3wx9W6GKkKDe OLmBtziVFqDlmNmhXeZFrY0YcKx1GJ4FSANtxdB6PYL5iIqk9qL4keRSESnkrzLxnmoq xD3eF+6GPvikxXigJergdEZiumjSaSmp8qDDVZzIwF22HG5tnVr+98MlJfjkmz55HqJd 5gCQ== X-Gm-Message-State: ALyK8tKiQ7O9s8x2Iz6UyPtrkKZlQqo7LScgxiU11O7rd2aar7ie10kSbuQHLA/pKdJx5g== X-Received: by 10.194.58.8 with SMTP id m8mr28823374wjq.98.1464626735183; Mon, 30 May 2016 09:45:35 -0700 (PDT) Original-Received: from keima.localdomain (x2f2fb8d.dyn.telefonica.de. [2.242.251.141]) by smtp.gmail.com with ESMTPSA id 75sm12638644wml.15.2016.05.30.09.45.34 for (version=TLSv1/SSLv3 cipher=OTHER); Mon, 30 May 2016 09:45:34 -0700 (PDT) User-Agent: Postbox 4.0.8 (Macintosh/20151105) In-Reply-To: X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.16 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:95050 Archived-At: This is a multi-part message in MIME format. --===============2154628365395840789== Content-Type: multipart/alternative; boundary="------------030805060308000802030100" This is a multi-part message in MIME format. --------------030805060308000802030100 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit > Nicola > 30. Mai 2016 um 17:45 > I'd like to set a default background color for all the tables in my > document. > This is what I have tried (using the latest beta): > > \setuptables[background=color,backgroundcolor=red] > \starttext > \starttable[|cm|] > \HL > \NC \bf R \NC \AR > \NC A \NC \AR > \HL > \NC \bot \NC \AR > \NC 1 \NC \AR > \stoptable > \stoptext > > No red background, though. What am I missing? > > The next step would be how to use a hatched pattern, but for now I'd > be happy with a flat color. The table environment does not support backgrounds but you can use the tabulate environment. \starttext \defineframedcontent[nicola][frame=off,background=color,backgroundcolor=yellow] \setuptabulate[frame=nicola] \starttabulate[|k{0.25}cm|] \HL \NC \bf R \NC\NR \NC A \NC\NR \HL \NC \bot \NC\NR \NC 1 \NC\NR \stoptabulate \stoptext Wolfgang --------------030805060308000802030100 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
30= .=20 Mai 2016 um 17:45
I'd like to set a default=20 background color for all the tables in my document.
This is what I have tried (using the latest beta):

\setuptables[background=3Dcolor,backgroundcolor=3Dred]
\starttext
\starttable[|cm|]
=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 \HL
=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 \NC \bf = R \NC \AR
=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 \NC A=C2= =A0=C2=A0=C2=A0=C2=A0 \NC \AR
=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 \HL
=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 \NC \bot= =C2=A0 \NC \AR
=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 \NC 1=C2= =A0=C2=A0=C2=A0=C2=A0 \NC \AR
=C2=A0\stoptable
\stoptext

No red background, though. What am I missing?

The next step would be how to use a hatched pattern, but for now I'd
be happy with a flat color.
The table environment does not support backgrounds but you can use the=20 tabulate environment.

\starttext

\defineframedcontent[nicola][frame=3Doff,background=3Dcolor,backgroundcol= or=3Dyellow]

\setuptabulate[frame=3Dnicola]

\starttabulate[|k{0.25}cm|]
\HL
\NC \bf R \NC\NR
\NC A=C2=A0=C2=A0=C2=A0=C2=A0 \NC\NR
\HL
\NC \bot=C2=A0 \NC\NR
\NC 1=C2=A0=C2=A0=C2=A0=C2=A0 \NC\NR
\stoptabulate

\stoptext

Wolfgang
--------------030805060308000802030100-- --===============2154628365395840789== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19f X19fX19fX19fX19fX19fX19fX19fX19fX18KSWYgeW91ciBxdWVzdGlvbiBpcyBvZiBpbnRlcmVz dCB0byBvdGhlcnMgYXMgd2VsbCwgcGxlYXNlIGFkZCBhbiBlbnRyeSB0byB0aGUgV2lraSEKCm1h aWxsaXN0IDogbnRnLWNvbnRleHRAbnRnLm5sIC8gaHR0cDovL3d3dy5udGcubmwvbWFpbG1hbi9s aXN0aW5mby9udGctY29udGV4dAp3ZWJwYWdlICA6IGh0dHA6Ly93d3cucHJhZ21hLWFkZS5ubCAv IGh0dHA6Ly90ZXguYWFuaGV0Lm5ldAphcmNoaXZlICA6IGh0dHA6Ly9mb3VuZHJ5LnN1cGVsZWMu ZnIvcHJvamVjdHMvY29udGV4dHJldi8Kd2lraSAgICAgOiBodHRwOi8vY29udGV4dGdhcmRlbi5u ZXQKX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19f X19fX19fX19fX19fX19fX19fX19fX19fX19fX18= --===============2154628365395840789==--