This Way. ConTEXt magazine #6 MkIV June A Few Dangerous Features Hans Hagen PRAGMA ADE

Similar documents
This is the drill hole location:

COMMUNITY CHURCH. Branding Guidelines

Identity Standards. Canada and Bermuda Territory SalvationArmy.ca

September 8 BRAND IDENTITY GUIDE. This document has been approved for public release.

Chi Alpha Campus Ministries, U.S.A. Style guide

Style Guide. Visual and editorial guidelines for Church at Charlotte communications

1 Thessalonians. 1Greetings from Paul, Silas, and Timothy.

Lesson 7: Pain. In today's chapters Jonas receives painful memories from The Giver. How do you think he will respond to these memories?

WEEK 1 Activity: God Loves Everyone

Bible Memory Verse. John 16:33

Graphics Design Standard Effective January 2014

Skrocketing YOUR Vibration

The liturg Package. Donald P. Goodman III. June 27, 2008

LEADER S GUIDE BIG MESSAGE LIVE DN 1.3 DOCUMENT PURPOSE USER AGREEMENT BIG PICTURE: POSITION

VISUAL IDENTITY GUIDELINES

CHIOS. Energy Healing. Study Workbook. Healing Level III. with Review Questions and Exercises on Techniques Version 1.5

2 Peter. 1Greetings from Simon Peter, a servant and

World Life Expectancy

Intel x86 Jump Instructions. Part 5. JMP address. Operations: Program Flow Control. Operations: Program Flow Control.

Nyhedsbrev 8 / Right Now / October 2017 / Efva Lilja. A conversation

Imagine That... Temple Beth Sholom BRAND STANDARDS GUIDE. Revised as of 8/8/16

Lesson 3 What a Savior

Bible Memory Verse. Zephaniah 3:17

We Believe in God. Study Guide WHAT WE KNOW ABOUT GOD LESSON ONE. We Believe in God by Third Millennium Ministries

The Glory of Living under the Cross. Wayne D. Mueller. Leader s Guide SAMPLE

GRAPHIC STANDARDS SPRING 2018

Technique. Work. Sale

PDF / FIRST RECONCILIATION FOR CHILDREN REPAIR MANUAL

Camp. the. of the Spirit. Littles & Me. a hands on study of Galatians 5:22-23 helping families connect, play, learn & grow in God s Word together

BRAND STYLE GUIDE

POCKETBOOK OF CHANGE

Church of God Branding Guidelines

The Harmonic Shield. Holographic Shield Technology. Developed by Mashhur Anam.

Bible Memory Verse. Acts 18:26

UPANISHADS THE HOLY SPIRIT OF VEDAS BY F. MAX MULLER ADI SHANKARACHARYA

?he Bre*n Through. SeSf*[,tee*[ng Sterr.Bs $n. #*t$nd Feupeg^ A Praetieol 6uide to Qucntum Psyehology. Niculino Gheorghild

Bible Memory Verse. Acts 18:26

APPLICATION for TEACHING POSITION

>> THE_PARABLES_PROJECT >> TEACHERS NOTES

Digital Logic Lecture 5 Boolean Algebra and Logic Gates Part I

1 Timothy. 15What I say is true, and you should fully

INSIDE THE NOW: MEDITATIONS ON TIME BY THICH NHAT HANH ( ) BY THICH NHAT HANH;

Tau Alpha Delta Branding Guidelines. The Face We Present

Laboratory Exercise Saratoga Springs Temple Site Locator

HANDBOOK OF PRAYERS BY JAMES SOCIAS DOWNLOAD EBOOK : HANDBOOK OF PRAYERS BY JAMES SOCIAS PDF

VISUAL STANDARDS GUIDE

Jacek Wiślicki, Introduction to CS. MS word 2010-basic formatting. Laurent Babout,

Peter Tan The Spiritual World

Sociology of Religion (Soci 452), Fall 2015

Chapter 1: Introduction to Communication Studies from A Primer on Communication Studies was adapted by The Saylor Foundation under a Creative Commons

AGENDA. (1) The Goal and Purpose of SafeR Church

Jesus Is Alive. Teacher Enrichment. We Can Tell Others That Jesus Is Alive! Lesson 9. Bible Point. Bible Verse. Growing Closer to Jesus

A Diamond Numerology Chart Analysis. for. John Hancock. Hans Decoz. A Diamond Report for age 26 for John Peter Hancock

What do we believe? What does it mean to be a Christian in the United Church? How do we talk about our faith to other Christians and people of other

Social Studies 10-1: The Position Paper

A NEW WAY OF LIVING: ONE SIMPLE STEP TO A LIFE WITHOUT FEAR BY SANTOSH NAMBIAR

Camp. the. of the Spirit. Littles & Me. a hands on study of Galatians 5:22-23 helping families connect, play, learn & grow in God s Word together

5D Astrology Report: April 2017

Visual Identity Standards Manual

A Sweet Opportunity. Seeing the GOSPEL in HALLOWEEN. Path Through the Narrow Gate

Building an Effective Class Prayer Ministry

The Gospel Primer By Caesar Kalinowski

At the sacred center of each one of us spin

2 Timothy. Jesus. I am an apostle because God wanted me to be. God sent me to tell people about the promise of life that is in Christ Jesus.

SIMEON S PROCLAMATION

The Good, the Bad, and the Ugly

1. Introduction Formal deductive logic Overview

SAMPLER Explore a sample from LIVE s new message series

Purpose. To strengthen your desire to tell the truth, even when it is not easy.

Jesus is alive. Teacher Enrichment. We Can Tell Others That Jesus Is Alive! Lesson 6. Bible Point. Bible Verse. Growing Closer to Jesus

Camp. the. of the Spirit. Littles & Me. a hands on study of Galatians 5:22-23 helping families connect, play, learn & grow in God s Word together

PW Historian Workshop

BY: IGNISSERPENTUS. DATE OF RELEASE: August 2013 STORE ON DAZ DAMAGE INC WEBSITE

STRANGE THINGS ARE HAPPENING SATANISM WITCHCRAFT AND GOD

Your school is wondering if they should use School Uniforms next year. Should your school have Uniforms?

Copyright 2013 Answers in Genesis. Limited license to copy.

LAKE VALLEY FIRE PROTECTION DISTRICT

Alignment with our real nature continued: Getting control of our vibrational dial

Hope you enjoyed this article and any ideas or thoughts are very much encouraged, me at

Summary. Background. Individual Contribution For consideration by the UTC. Date:

13 Things That Don't Make Sense: The Most Intriguing Scientific Mysteries By Audible Studios, Michael Brooks

Alpha Brand Guidelines. Version 2.0 October 2014

FAITH- FILLED LEADERSHIP AUTHORITY, ENGAGEMENT AND ACCOUNTABILITY Christine Anderson FCJ

Art Of Jewish Cooking By Jennie Grossinger

Intel x86 Jump Instructions. Part 6. JMP address. Operations: Program Flow Control. Operations: Program Flow Control.

Make sure to include some transitional sentences between the hook and the thesis statement.

Force of Life Attunement Guide

Angelic Consciousness for Inspired Action and Accelerated Manifestation Part II

FAQs of The One Command

BIOGEOMETRY ADVANCED TRAINING. Six-day training of theory and practical comprising Levels 4,5, September Athens (Vougliameni) Greece

UNSHAKABLE PURSUIT DESIGN GUIDE

GOODWILL MEDITATION GROUP

We exist to lead common people into uncommon life in Jesus.

As Our Own Savior! How Can We Be Saved? It Is God s Free Gift... When We Trust in

Changing Views of Drugs and Consciousness. By Jennifer Mitradarmbidhaks American University Washington, DC May 11, 2005

We Believe in God. Lesson Guide WHAT WE KNOW ABOUT GOD LESSON ONE. We Believe in God by Third Millennium Ministries

PREVIEW COPY. Mass in Honor of Saint Cecilia. David Hurd. Kyrie Gloria Gospel Acclamation Credo Sanctus Mysterium Fidei Amen Agnus Dei

Purchase Your Streaming License Today At TheFaithPlaybook.com

Resources General Conference Women s Ministries.

FATHERS DAY KIDS BIBLE LESSONS DOWNLOAD

Transcription:

This Way ConTEXt magazine #6 MkIV June 2004 A Few Dangerous Features Hans Hagen PRAGMA ADE

A Few Dangerous Features Remark 1 The features discussed here have a so called global character, i.e. all settings are global by nature. Future releases may introduce (and by default change to) local behaviour. So, don t make your documents depending on local/global behaviour. In most cases you will probably not notice the difference. Being negative The ConTEXt page imposition machinery provides negation because sometimes raster image processors need that feature. In that case negation is applied to the whole page. Within the document stream inverted colors are normally (and best) realized with defining an appropriate color. For special purposes we also provide negation \startcolor[red]\ignorespaces \startnegative\ignorespaces \startpositive\ignorespaces \removeunwantedspaces\stoppositive \removeunwantedspaces\stopnegative \removeunwantedspaces\stopcolor The Earth, as a habitat for animal life, is in old age and has a fatal illness. Several, in fact. It would be happening whether humans had ever evolved or not. But our presence is like the effect of an old-age patient who smokes many packs of cigarettes per day and we humans are the cigarettes. The Earth, as a habitat for animal life, is in old age and has a fatal illness. Several, in fact. It would be happening whether humans had ever evolved or not. But our presence is like the effect of an old-age patient who smokes many packs of cigarettes per day and we humans are the cigarettes. The Earth, as a habitat for animal life, is in old age and has a fatal illness. Several, in fact. It would be happening whether humans had ever evolved or not. But our presence is like the effect of an old-age patient who smokes many packs of cigarettes per day and we humans are the cigarettes.the Earth, as a habitat for animal life, is in old age and has a fatal illness. Several, in fact. It would be happening whether humans had ever evolved or not. But our presence is like the effect of an old-age patient who smokes many packs of cigarettes per day and we humans are the cigarettes.the Earth, as a habitat for animal life, is in old age and has a fatal illness. Several, in fact. It would be happening whether humans had ever evolved or not. But our presence is like the effect of an old-age patient who smokes many packs of cigarettes per day and we humans are the cigarettes. #6 MkIV September 12, 2016 This Way 1

2 We can also apply negation to graphic, but the result may not be what we expect. While writing this document figure 1 negates well when view in Ghostscript but Acrobat 6 shows a strange vertical line pattern. \startcombination {\startpositive \externalfigure[hacker.jpg][width=4cm]% \stoppositive} {normal} {\startnegative \externalfigure[hacker.jpg][width=4cm]% \stopnegative} {negative} \stopcombination A Few Dangerous Features normal Figure 1 negative Negation of graphics. Font effects Another bag of tricks concerns font effects. As with negation and the to be discussed overprint these are implemented using the ConTEXt (still experimental) feature handler, but this time we don t provide direct commands. Instead we use arguments to control the effects. In this paragraph we have \starteffect[hidden]hidden a piece of text\stopeffect. How useful this feature is depends on the kind of documents you make. An alternative is to put the text in a viewer layer (\starteffect[hidden]as provided by \PDF\stopeffect) that is hidden, but since that feature is not widely available the effects approach is safer. In this paragraph we have hidden a piece of text. How useful this feature is depends on the kind of documents you make. An alternative is to put the text in a viewer layer (as provided by pdf) that is hidden, but since that feature is not widely available the effects approach is safer. More interesting is changing the way a font is rendered. An outline version is rendered with the outer effect. \bf \starteffect[outer] \stopeffect \par 2 This Way September 12, 2016 #6 MkIV

A Few Dangerous Features 3 The Earth, as a habitat for animal life, is in old age and has a fatal illness. Several, in fact. It would be happening whether humans had ever evolved or not. But our presence is like the effect of an old-age patient who smokes many packs of cigarettes per day and we humans are the cigarettes. The inner effect is the normal one so there is no reason to show it here. The both option combines the two resulting in an extra bold version. \bf \starteffect[both] \stopeffect \par The Earth, as a habitat for animal life, is in old age and has a fatal illness. Several, in fact. It would be happening whether humans had ever evolved or not. But our presence is like the effect of an old-age patient who smokes many packs of cigarettes per day and we humans are the cigarettes. You can influence the linewidth as is demonstrated in the following example: \setupeffect[outer][rulethickness=.8pt] \bfd \starteffect[outer]bigger is Beautiful\stopeffect Bigger is Beautiful Speaking of 2004, in ConTEXt (read: TEX) intercharacter spacing can only be achieved by macro processing. The next method works well, but you need to manipulate the \hsize yourself, since the typesetting engine is unaware of this backend manipulation. \setupeffect[both][stretch=2] \setupalign[right] \dontleavehmode \hsize=.6\hsize \bf \starteffect[both] \stopeffect \par The Earth, as a habitat for animal life, is in old age and has a fatal illness. Several, in fact. It would be happening whether humans had ever evolved or not. But our presence is like the effect of an old-age patient who smokes many packs of cigarettes per day and we humans are the cigarettes. The normal (or inner) alternative looks as follows: \setupeffect[normal][stretch=2] \setupalign[right] \dontleavehmode \hsize=.6\hsize \bf \starteffect[normal] \stopeffect \par The Earth, as a habitat for animal life, is in old age and has a fatal illness. Several, in fact. It #6 MkIV September 12, 2016 This Way 3

would be happening whether humans had ever evolved or not. But our presence is like the effect of an old-age patient who smokes many packs of cigarettes per day and we humans are the cigarettes. Overprint and 4 Another feature that should be used with care is overprint. Normally a raster image processor will knock out colored areas under colored text or areas on top. This works well when the printing engine (or press) is able to precisely align the color plates. If not, you will get artifacts that show up as follows (often such effects occur in newspapers and cheap magazines): A Few Dangerous Features cheap On the one hand we get white spots and depending on how well the ink covers, we can get darker spots as well. In such cases it s best to overprint the background, which of course only works as expected when the top color is a well covering black. Otherwise we probably may have to compensate the color, which in turn depends on the kind of paper used. At the document level, you can set the overprint with: \setupcolors[overprint=yes] We show a few examples of local usage: a simple application first (figure 2): [background=color,backgroundcolor=ocyan, frame=off,offset=.25cm,strut=no] {\bfb\setstrut \startoverprint {overprint\\\start \stop}% \stopoverprint 4 This Way September 12, 2016 #6 MkIV

A Few Dangerous Features {\\\startoverprint overprint\stopoverprint}}% We can nest overprint and turn it off as well (figure 2): \startoverprint [background=color,backgroundcolor=ocyan, frame=off,offset=.25cm,strut=no] {\bfb\setstrut {overprint\\\start \stop}% \start {\\\startoverprint overprint\stopoverprint}% \stop}% \stopoverprint 5 Sometimes the overprint preview in Acrobat works better when we apply a gray background (figure 2). We use rather ugly pure cmyk colors, otherwise the effect is not visible in overprint preview mode. [background=color,backgroundcolor=ogray,backgroundoffset=.25em, frame=off,offset=overlay] {\getbuffer[a]} and (figure 2): [background=color,backgroundcolor=ogray,backgroundoffset=.25em, frame=off,offset=overlay] {\getbuffer[b]} If we look at examples b and d of figure 2) in Acrobat overprint preview mode, we will see that the effect depends on where we apply the overprint settings. As said, these are tricky features and should be used with care and understanding. #6 MkIV September 12, 2016 This Way 5

overprint overprint a b overprint overprint Figure 2 6 overprint overprint Preview overprint and. c d overprint overprint A Few Dangerous Features 6 This Way September 12, 2016 #6 MkIV

A Few Dangerous Features % language=uk source code of this document % author : Hans Hagen % copyright : PRAGMA ADE & ConTeXt Development Team % license : Creative Commons Attribution ShareAlike 4.0 International % reference : pragma-ade.nl contextgarden.net texlive (related) distributions % origin : the ConTeXt distribution % % comment : Because this manual is distributed with TeX distributions it comes with a rather % liberal license. We try to adapt these documents to upgrades in the (sub)systems % that they describe. Using parts of the content otherwise can therefore conflict % with existing functionality and we cannot be held responsible for that. Many of % the manuals contain characteristic graphics and personal notes or examples that % make no sense when used out-of-context. \usemodule[mag-01,abr-02] \setupcolors[rgb=no,cmyk=yes] \definecolor[red] \definecolor[green] \definecolor[blue] [c=.25,m=.75,y=.75,k=.25] [c=.75,m=.25,y=.75,k=.25] [c=.75,m=.75,y=.25,k=.25] \definecolor[tred] \definecolor[tgreen] \definecolor[tblue] \definecolor[tblack] [c=.25,m=.75,y=.75,k=.25,t=.5,a=1] [c=.75,m=.25,y=.75,k=.25,t=.5,a=1] [c=.75,m=.75,y=.25,k=.25,t=.5,a=1] [s=0,t=.75,a=1] \definecolor[ocyan] [c=.75] \definecolor[omagenta] [m=.75] \definecolor[oyellow] [y=.75] \definecolor[ogray] [s=.5] [abstract] Occasionally we experiment a bit with (\PDF) features that are useful but at the same time dangerous when applied uncontrolled. In the process of cleaning up some files in my source tree and triggered by a discussion about overprint I decided to move some of that code into the kernel. You are warned! \startdocument [title={a Few Dangerous Features}, author=hans Hagen, affiliation=pragma ADE, date=june 2004, number=6 \MKIV] \subject{remark} The features discussed here have a so called global character, i.e. all settings are global by nature. Future releases may introduce (and by default change to) local behaviour. So, don't make your documents depending on local/global behaviour. In most cases you will probably not notice the difference. \subject{being negative} The \CONTEXT\ page imposition machinery provides negation because sometimes raster image processors need that feature. In that case negation is applied to the whole page. Within the document stream inverted colors are normally (and best) realized with defining an appropriate color. For special purposes we also provide negation #6 MkIV September 12, 2016 This Way 7

\startcolor[red]\ignorespaces \startnegative\ignorespaces \startpositive\ignorespaces \removeunwantedspaces\stoppositive \removeunwantedspaces\stopnegative \removeunwantedspaces\stopcolor \typebuffer \getbuffer source code of this document We can also apply negation to graphic, but the result may not be what we expect. While writing this document \in {figure} [fig:negated] negates well when view in \GHOSTSCRIPT\ but \ACROBAT~6 shows a strange vertical line pattern. A Few Dangerous Features \startcombination {\startpositive \externalfigure[hacker.jpg][width=4cm]% \stoppositive} {normal} {\startnegative \externalfigure[hacker.jpg][width=4cm]% \stopnegative} {negative} \stopcombination \typebuffer \placefigure [here] [fig:negated] {Negation of graphics.} {\getbuffer} \subject{font effects} Another bag of tricks concerns font effects. As with negation and the to be discussed overprint these are implemented using the \CONTEXT\ (still experimental) feature handler, but this time we don't provide direct commands. Instead we use arguments to control the effects. In this paragraph we have \starteffect[hidden]hidden a piece of text\stopeffect. How useful this feature is depends on the kind of documents you make. An alternative is to put the text in a viewer layer (\starteffect[hidden]as provided by \PDF\stopeffect) that is hidden, but since that feature is not widely available the effects approach is safer. \typebuffer \getbuffer More interesting is changing the way a font is rendered. An outline version is rendered with the \type {outer} effect. 8 This Way September 12, 2016 #6 MkIV

A Few Dangerous Features source code of this document \bf \starteffect[outer] \stopeffect \par \typebuffer \start \getbuffer \stop The \type {inner} effect is the normal one so there is no reason to show it here. The \type {both} option combines the two resulting in an extra bold version. \bf \starteffect[both] \stopeffect \par \typebuffer \start \getbuffer \stop You can influence the linewidth as is demonstrated in the following example: \setupeffect[outer][rulethickness=.8pt] \bfd \starteffect[outer]bigger is Beautiful\stopeffect \typebuffer \start \getbuffer \stop Speaking of 2004, in \CONTEXT\ (read: \TEX) intercharacter spacing can only be achieved by macro processing. The next method works well, but you need to manipulate the \type {\hsize} yourself, since the typesetting engine is unaware of this backend manipulation. \setupeffect[both][stretch=2] \setupalign[right] \dontleavehmode \hsize=.6\hsize \bf \starteffect[both] \stopeffect \par \typebuffer \start \getbuffer \stop The \type {normal} (or \type {inner}) alternative looks as follows: \setupeffect[normal][stretch=2] \setupalign[right] \dontleavehmode \hsize=.6\hsize \bf \starteffect[normal] \stopeffect \par \typebuffer \start \getbuffer \stop \subject{overprint and } Another feature that should be used with care is overprint. Normally a raster image processor will knock out colored areas under colored text or areas on top. This works well when the printing engine (or press) is able to precisely align the color plates. If not, you will get artifacts that show up as follows (often such effects occur in newspapers and cheap magazines): \definelayer[fake][width=6cm,height=4cm] \setlayerframed [fake] [preset=lefttop] #6 MkIV September 12, 2016 This Way 9

source code of this document [frame=off,width=8cm,height=4cm, background=color,backgroundcolor=blue,foregroundcolor=white] {\definedfont[serifbold at 6\bodyfontsize]cheap} \setlayerframed [fake] [preset=lefttop,offset=1pt] [frame=off,width=8cm,height=4cm, foregroundcolor=tblack] {\definedfont[serifbold at 6\bodyfontsize]cheap} \startbaselinecorrection \tightlayer[fake] \stopbaselinecorrection On the one hand we get white spots and depending on how well the ink covers, we can get darker spots as well. In such cases it's best to overprint the background, which of course only works as expected when the top color is a well covering black. Otherwise we probably may have to compensate the color, which in turn depends on the kind of paper used. A Few Dangerous Features At the document level, you can set the overprint with: \starttyping \setupcolors[overprint=yes] \stoptyping We show a few examples of local usage: a simple application first (\in {figure} {a} [fig:overprint]): [a] [background=color,backgroundcolor=ocyan, frame=off,offset=.25cm,strut=no] {\bfb\setstrut \startoverprint {overprint\\\start \stop}% \stopoverprint {\\\startoverprint overprint\stopoverprint}}% \typebuffer[a] We can nest overprint and turn it off as well (\in {figure} {b} [fig:overprint]): [b] \startoverprint [background=color,backgroundcolor=ocyan, frame=off,offset=.25cm,strut=no] {\bfb\setstrut 10 This Way September 12, 2016 #6 MkIV

A Few Dangerous Features source code of this document {overprint\\\start \stop}% \start {\\\startoverprint overprint\stopoverprint}% \stop}% \stopoverprint \typebuffer[b] Sometimes the overprint preview in \ACROBAT\ works better when we apply a gray background (\in {figure} {c} [fig:overprint]). We use rather ugly pure \CMYK\ colors, otherwise the effect is not visible in overprint preview mode. [c] [background=color,backgroundcolor=ogray,backgroundoffset=.25em, frame=off,offset=overlay] {\getbuffer[a]} \typebuffer[c] and (\in {figure} {d} [fig:overprint]): [d] [background=color,backgroundcolor=ogray,backgroundoffset=.25em, frame=off,offset=overlay] {\getbuffer[b]} \typebuffer[d] \startcombination[2*2] {\getbuffer[a]} {a} {\getbuffer[c]} {c} {\getbuffer[b]} {b} {\getbuffer[d]} {d} \stopcombination \placefigure [here] [fig:overprint] {Preview overprint and.} {\getbuffer} If we look at examples~b and~d of \in {figure} [fig:overprint]) in \ACROBAT\ overprint preview mode, we will see that the effect depends on where we apply the overprint settings. As said, these are tricky features and should be used with care and understanding. \stopdocument #6 MkIV September 12, 2016 This Way 11

source code of this document A Few Dangerous Features 12 This Way September 12, 2016 #6 MkIV