ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: Peter Rolf <indiego@gmx.net>
To: mailing list for ConTeXt users <ntg-context@ntg.nl>
Subject: Re: MKIV strange results in Adobe Reader
Date: Thu, 08 Sep 2011 12:29:52 +0200	[thread overview]
Message-ID: <4E689920.5010801@gmx.net> (raw)
In-Reply-To: <4E688B8E.6010606@wxs.nl>

Am 08.09.2011 11:31, schrieb Hans Hagen:
> On 8-9-2011 11:19, Otso Helenius wrote:
>> Hello,
>>
>> I recently made a SimpleSlides presentation with MKIV (2011.08.27
>> 13:24). It looks ok on numerous PDF readers including Okular, Google
>> Docs, Sumatra PDF. Whenever I open it on Adobe Reader, the results are
>> rather puzzling:
>>
>> 1) The fifth page background is not black but grey, also some later
>> pages have grey background
>> 2) The RGB and CMYK swatch colours are all messed up
>>
>> The picture on page four has been intentionally corrupted with a hex
>> editor and then opened and saved again in Gimp to remove the errors in
>> the file.
>>
>> You can view the source here: https://pi-xi.net/share/colorlecture.tex
>> and the finished PDF here: https://pi-xi.net/share/colorlecture.pdf
>>
>> The only modifications I've made to the simpleslides-s-BottomSquares.tex
>> is replacing the background color, contrast color and variant color with
>> different values ([s=.0], [r=.8,g=.2,b=.2], [s=.15]).
>>
>> I would appreciate if someone could explain if there are bugs in my tex
>> sources, in MKIV or in the Adobe Reader – and in any case how can I fix
>> the erroneous output on Adobe Reader to match it on Sumatra, Google
>> Docs, etc.
> 
> Do you use transparencies? On pages where they are used, a different
> color rendered seems to kick in (in acrobat).
>
You can try to add

\startluacode
function backends.codeinjections.rgbtransparencygroup()
    local d = lpdf.dictionary {
        S  = lpdf.constant("Transparency"),
        CS = lpdf.constant("DeviceRGB"),
        I  = true }
    lpdf.registerpagefinalizer(function()
lpdf.addtopageattributes("Group",d) end)
end
\stopluacode
\def\pngTransparencyHack{\ctxlua{backends.codeinjections.rgbtransparencygroup()}}

\pngTranparencyHack


This is what I use here for my RGB based graphics. Anyhow, as the name
of the macro says: it's not more than a (RGB only) hack.


Regards, Peter
___________________________________________________________________________________
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
___________________________________________________________________________________

  reply	other threads:[~2011-09-08 10:29 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-09-08  9:19 Otso Helenius
2011-09-08  9:31 ` Hans Hagen
2011-09-08 10:29   ` Peter Rolf [this message]
2011-09-11 14:48   ` Otso Helenius

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4E689920.5010801@gmx.net \
    --to=indiego@gmx.net \
    --cc=ntg-context@ntg.nl \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).