Minor issue with PDF-Export ?

Knowledge exchange related to the VPE Report Engine and PDF Library

Moderator: IDEAL Software Support

Minor issue with PDF-Export ?

Postby DDTech » Wed Oct 28, 2009 12:18 am

Sorry another question.

I print out timebars with different colors and just fell over this in the PDF-Export. Maybe I can do something from my side to avoid it.

The light green and the red bar have pure white text on them (rgb(255,255,255)). Normally no problem.

However on holidays a hatch is being printed in the background and in this case the white text also gets hatched.

See the bars in the second row:

Image

(this is a screenshot from the PDF-file, viewed with Acrobat 9)

A zoomed view shows it better:

Image

It's still the correct text. I can select, copy and paste it.

This only happens in the PDF-output. Preview, VPE-Files or PDF created with FreePDFXP or Adobe Distiller look fine.

As soon as I change the forecolor of the red bar just by 1 (ie. rgb(254,255,255) everything's fine:

Image

Note that even the green one draws correct although only the red one has the non-pure-white forecolor.

Must be some kind of masking-issue or the like.

Any hint?


Kind regards


Frank Dietrich
DDTech
 
Posts: 37
Joined: Mon Oct 26, 2009 11:45 am

Postby IDEAL Software Support » Wed Oct 28, 2009 1:15 pm

This seems to be a problem of VPE, we are going to examine it. To make sure we understand the details: the background box is hatched and the red or green boxes have solid colors, right? Is the background box transparent or does it have a solid white color?
IDEAL Software Support
 
Posts: 1622
Joined: Thu Nov 18, 2004 4:03 pm

Postby DDTech » Wed Oct 28, 2009 1:49 pm

IDEAL Software Support wrote:This seems to be a problem of VPE, we are going to examine it. To make sure we understand the details: the background box is hatched and the red or green boxes have solid colors, right? Is the background box transparent or does it have a solid white color?


Thanks a lot.

I just send You sample-reports for other purposes in VPE-Format. Accidentally one of them is the same these shots where taken from.

What's going on is quite complicated to reproduce as it's spread over several classes, but I looked it up.

First the background is drawn. This is either a solid color or hatched. In both cases .TransparentMode is .F.

This is drawn as a .box()

On top of it the TimeLines are drawn

then .textColor and .hatchStyle are being reset

Later the bars are drawn either with TransparentMode=.F. or .BKGMode=VBKG_GRD_LINE and .writeBox(..)

- snip -

I just tried to change the white of the hatch instead of the bar's forecolor. and also tried with other colors - same effects.

it seems that behavior appears as soon as the hatch-backcolor and the WriteBox()'s Forecolor match.


HTH

Frank
DDTech
 
Posts: 37
Joined: Mon Oct 26, 2009 11:45 am

Postby IDEAL Software Support » Wed Oct 28, 2009 1:57 pm

We are not able to reproduce the problem.

Here is our code (in C++):
Code: Select all
   VpeSetBkgMode(hDoc, VBKG_SOLID);
   VpeSetBkgColor(hDoc, COLOR_WHITE);
   VpeSetHatchStyle(hDoc, HS_BDIAGONAL);
   VpeBox(hDoc, 1, 1, -5, -3);

   VpeSetHatchStyle(hDoc, HS_NONE);
   VpeSetBkgColor(hDoc, COLOR_LTRED);
   VpeBox(hDoc, 1.5, 1.5, -4, -2);

   VpeSetTextColor(hDoc, COLOR_WHITE);
   VpePrint(hDoc, 2, 2, "hello");


Can you verify on your side that this code produces the problem? If it does also work on your side, is it possible for you to modify the code so that it does produce the problem? If so, please send the modified code by e-mail to our support e-mail address.
IDEAL Software Support
 
Posts: 1622
Joined: Thu Nov 18, 2004 4:03 pm

Postby DDTech » Wed Oct 28, 2009 2:50 pm

IDEAL Software Support wrote:We are not able to reproduce the problem. ....
Code: Select all
   ...
   VpeBox(hDoc, 1.5, 1.5, -4, -2);

   VpeSetTextColor(hDoc, COLOR_WHITE);
   VpePrint(hDoc, 2, 2, "hello");



I have not tried yet, but my code uses WriteBox() not Box() + Print()
DDTech
 
Posts: 37
Joined: Mon Oct 26, 2009 11:45 am

Postby IDEAL Software Support » Thu Oct 29, 2009 9:48 am

Changing the code to WriteBox() still does not show the problem.
IDEAL Software Support
 
Posts: 1622
Joined: Thu Nov 18, 2004 4:03 pm

Postby DDTech » Thu Oct 29, 2009 10:51 am

IDEAL Software Support wrote:Changing the code to WriteBox() still does not show the problem.


Here too. Both ways work.

However when I change to BkgMode VBKG_GRD_LINE, I can reproduce the behavior.
Code: Select all
.BkgMode = VBKG_GRD_LINE
.BkgGradientStartColor = COLOR_LTRED
.BkgGradientEndColor = COLOR_LTRED
.TextColor = COLOR_WHITE

.WriteBox(1.5, 1.5, -4, -2, "Hello-2")


Shows the behavior either with .Box() + .Print() or .WriteBox()


Regards

Frank Dietrich


*-- correction: EndColor should be COLOR_DKRED but it even works with LTRed to LTRed :-)
DDTech
 
Posts: 37
Joined: Mon Oct 26, 2009 11:45 am

Postby IDEAL Software Support » Thu Oct 29, 2009 2:24 pm

Ok, thanks for pointing us in the right direction. We will examine this problem and post new information when available. This will take a few days.
IDEAL Software Support
 
Posts: 1622
Joined: Thu Nov 18, 2004 4:03 pm

Postby DDTech » Thu Oct 29, 2009 2:29 pm

IDEAL Software Support wrote:Ok, thanks for pointing us in the right direction. We will examine this problem and post new information when available. This will take a few days.


Thanks a lot. No problem. In the most unlikely event that one of my customers falls over this, I can ask him/her to change either background or Textcolor by one or two tics.
This does not have a visible effect at all and would solve the problem.

Regards

Frank
DDTech
 
Posts: 37
Joined: Mon Oct 26, 2009 11:45 am

Postby IDEAL Software Support » Mon Nov 02, 2009 2:47 pm

Update: The problem has been fixed. The fix will be released with VPE v6.0 in about 2 months. Customers with a valid subscription will receive VPE v6.0 free of charge.
IDEAL Software Support
 
Posts: 1622
Joined: Thu Nov 18, 2004 4:03 pm

Postby DDTech » Mon Nov 02, 2009 2:57 pm

IDEAL Software Support wrote:Update: The problem has been fixed. The fix will be released with VPE v6.0 in about 2 months. Customers with a valid subscription will receive VPE v6.0 free of charge.


Lovely. Great News on Monday and the beginning of the month .... November may come :D
DDTech
 
Posts: 37
Joined: Mon Oct 26, 2009 11:45 am


Return to VPE Open Forum

Who is online

Users browsing this forum: Bing [Bot] and 57 guests