Author Topic: Export of transparent PNG  (Read 6661 times)

shngrdnr

  • Newbie
  • *
  • Posts: 3
  • Karma: 0
Export of transparent PNG
« on: June 09, 2011, 12:04:44 pm »
I want to export an image from Scribus as a png file with transparency - all exports so far have given the image a white background.  I notice on bug.scribus.net (https://bugs.scribus.net/view.php?id=9687) that the issue has already been addressed by user ale:

Quote
indeed i could get a PNG with a transparent background by outcommenting the line

painter->clear(Doc->papColor);

in QImage ScribusView::PageToPixmap().

it may be necessary to do the same for ScribusView::MPageToPixmap() ...

now, i just have to find out, how to pass the value from a new checkbox in the export to PNG dialog...

However, ale hasn't mentioned which file to edit, or where to find it on a PC (operating Win XP SP3).  Feels like a stupid question but there it is.  Anyone help please?

Nermander

  • Hero Member
  • *****
  • Posts: 1093
  • Karma: 15
Re: Export of transparent PNG
« Reply #1 on: June 09, 2011, 03:15:11 pm »
He is talking about the Scribus source code, so it is nothing you can edit in your installed Scribus.

shngrdnr

  • Newbie
  • *
  • Posts: 3
  • Karma: 0
Re: Export of transparent PNG
« Reply #2 on: June 09, 2011, 04:02:38 pm »
Fair enough Nermander - so there's absolutely no way around it?  Well, fair enough - I guess from what ale says it'll be available in a future version, I'll just export as normal and edit in PS till then...

a.l.e

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1074
  • Country: 00
  • Karma: 17
    • the graphics lab
Re: Export of transparent PNG
« Reply #3 on: June 09, 2011, 10:03:02 pm »
may i ask you why do you want to export to png?

basically, exporting to png is not really a key feature for scribus.... so there are not that many chances that the devs will focus on it soon :-)

... and myself i wonder a bit why i should spend more time on it...

any good reason?

shngrdnr

  • Newbie
  • *
  • Posts: 3
  • Karma: 0
Re: Export of transparent PNG
« Reply #4 on: June 10, 2011, 10:48:32 am »
Quote
may i ask you why do you want to export to png?

basically, exporting to png is not really a key feature for scribus.... so there are not that many chances that the devs will focus on it soon :-)

... and myself i wonder a bit why i should spend more time on it...

any good reason?

Hey a.l.e

That's a fair question.  To me, my reason is good, but I doubt many others would have exactly similar needs.

I'm currently writing a webcomic, which is located here - it's part-animated in a Flash program, Swishmax.  As I go along I'm also preparing a print version, which I compile in Scribus (I intend to crowdfund in a few months, and I want to offer the print version as a reward, and to sell at conventions and so on).  Typically, I prepare the print version first, and then move on to the Flash version after I'm happy with the layout there.

When I compile the comic, I use a series of pre-prepared images as backgrounds for the text - these are scans of thick inked lines - which I arrange in Scribus until I'm happy.   When I'm happy with the text, I export the inklines as a single PNG for import into Swishmax, where I rewrite the text over the lines, to ensure consistency (I used to export the text as a vector and then reimport into Swish, but this was really inefficient).  Because Scribus exports non-transparent PNGs, I have to make use of Photoshop in an intermediary stage, removing all the white areas that the program has exported. 

So that's the reason.  As I say, it's a fairly uncommon scenario, I'm sure - but I'm fairly confident that other scenarios exist that would mean that a similar transparent PNG export would be useful.  As it says in the bugs.Scribus posting, several users have already asked for it.  That said, I understand if you don't want to implement this - it is your time after all.

Nermander

  • Hero Member
  • *****
  • Posts: 1093
  • Karma: 15
Re: Export of transparent PNG
« Reply #5 on: June 10, 2011, 01:19:47 pm »
Have you looked at exporting to PDF and use for example ImageMagick to convert the PDF to PNG?

 

palmate