bugGNUstep - Bugs: bug #13140, possible dataWithEPSInsideRect: bug

 
 

You are not allowed to post comments on this tracker with your current authentication level.

bug #13140: possible dataWithEPSInsideRect: bug

Submitted by:  None
Submitted on:  Fri 20 May 2005 08:57:00 PM UTC  
 
Category: Gui/AppKitSeverity: 3 - Normal
Item Group: BugStatus: Ready For Test
Privacy: PublicAssigned to: Fred Kiefer <FredKiefer>
Open/Closed: Closed

(Jump to the original submission Jump to the original submission)

Mon 27 Mar 2006 10:19:01 AM UTC, comment #6:

Oops, I forgot to change the actual status :-)

Fred Kiefer <FredKiefer>
Project MemberIn charge of this item.
Mon 27 Mar 2006 10:18:23 AM UTC, comment #5:

Closed after one year of testing

Fred Kiefer <FredKiefer>
Project MemberIn charge of this item.
Sun 22 May 2005 09:44:32 PM UTC, comment #4:

I just changed some in CVS to allow the printing of cells that haven't been put into a window. This should resolve most of your problems.
What will remain are problems with drawing in the window background colour (no window, no background colour) and I see also some Rectfill calls with empty rectangles. I still don't fully understand where this come from, but at least for the example you gave the result looks ok.

Thank you very much for this bug report. It helped to highlight a problem with the GNUstep code that went unnoticed for quite some time. I expect that there is still more to do, for example every call to lockfocus should be send only after checking canDraw first.

Fred Kiefer <FredKiefer>
Project MemberIn charge of this item.
Sun 22 May 2005 02:45:41 PM UTC, comment #3:

Ok, I did not see that you did reply yet...
I moved the box printing method to the close method, and it does not reproduce the BLACK window anymore and the eps is just fine...
About my second problem that consists in the printing with [self contentView] dataWithEPSInsideRect ... method, the printout is white. Maybe this is because the contentView has NO background and the GRAY background is the window's background that is NO visible for contentView?
Thanks for your reflexion.

Anonymous
Sun 22 May 2005 02:37:47 PM UTC, comment #2:

other remark:
if I replace the dataWithEPSInsideRect: thing in MainWindow.m
by
[self dataWithEPSInsideRect: [[self contentView] bounds]];
the resulting eps file will be fully identical to that I can see on screen in the original version, BUT after this replacement,
the MainWindow is totally BLACK. I don't understand.
in case of
[[self contentView] dataWithEPSInsideRect: [[self contentView] bounds]];
the eps won't be correct, but the MainWindow on screen.
It seems that there is several mismatches between the different views.

Anonymous
Sat 21 May 2005 04:56:06 PM UTC, comment #1:

The probelm here is not with the NSBox, but with the way you try to create the EPS file. You do so in the initWithFrame: method of the box and at this time it is still not connected to a window. Most of the drawing code has a check to see if a view has a window assigned and will do nothing with out that.
You may test this, by just moving the box printing to some place later in the code.

Up to now I thoght this is the correct behaviour, but now I am not totally sure any more. The canDraw method in NSView also checks for the printing view, so perhaps this is also a valid scenario. If we decide so, we will need to replace all the window != nil tests with canDraw.

Yes, I think we should do so.

Fred Kiefer <FredKiefer>
Project MemberIn charge of this item.
Fri 20 May 2005 08:57:00 PM UTC, original submission:

I created an NSWindow with an NSView inside. In
that, I created an NSBox with an NSView inside
containing an image and a text.

When I use the dataWithEPSInsideRect method with
NSWindow's contentView and write it to a file, I
can see the box with its contents. If I do the
same with NSBox's contentView, I can see no text
neither image in the resulted eps file. Is there a
difference in Views when constructing eps inside
box and inside window?
BTW, the box background is gray and the window's
background is white. Why are they different?

Anonymous

 

Attached Files
file #2998:  bugs.tar.gz added by None (5KiB - application/gzip - launch the Tesz.app, click new and then quit. examine the resulting files: file.eps and file1.eps)

 

Depends on the following items: None found

Items that depend on this one: None found

 

CC list is empty

 

Do you think this task is very important?
If so, you can click here to add your encouragement to it.
This task has 0 encouragements so far.

Only logged-in users can vote.

 

Please enter the title of George Orwell's famous dystopian book (it's a date):

 

 

Follow 6 latest changes.

Date Changed By Updated Field Previous Value => Replaced By
Mon 27 Mar 2006 10:19:01 AM UTCFredKieferOpen/ClosedIn Test=>Closed
Sun 22 May 2005 09:44:32 PM UTCFredKieferStatusIn Progress=>Ready For Test
  Open/ClosedOpen=>In Test
Sat 21 May 2005 04:56:06 PM UTCFredKieferStatusNone=>In Progress
  Assigned toNone=>FredKiefer
Fri 20 May 2005 08:57:00 PM UTCNoneAttached File-=>Added bugs.tar.gz, #2523

Back to the top


Powered by Savane 3.1-cleanup1