GNOME Bugzilla – Bug 402113
Allow invisible objects through a 'transparent' color
Last modified: 2011-04-03 17:00:50 UTC
I'd like to be able to select a "colour" that is actually transparent, with the result that it is possible to create objects that are invicible in practice. Today the workaround to create an "invisible" object is to set its colour to that of the background. Perhaps it'd be enough if the color selection dialog allows you to select a transparent color. Otherwise the property dialog needs to get checkboxes for toggling the transparency. Possibly a continous transparency setting is desirable.
Having an invisible object sound like being a wor-around for something else (maybe some misculation of diagram boundaries for printing). If there is a real use-case beside a work-around please elaborate. Otherwise you should probably close this bug and write one for the issue you want to work around ;)
*sigh* This is why I prefer discussion bugs etc before actually filing them. Now the discussion will happen here instead of in the list and I'm too lazy to move it there. It is true I thought of it as a workaround, but although I don't remeber the use cases right now, it has been useful in other drawing softwares (eg TGif) to be able to select an "invisible" color. Anyway, here is the situation: I was working with an object (a rectangle) that I needed to give some extra connection points. AFAIK, the recommended way is to attach a line between two of the corners, and give that line more connection points. Just before that, I'd used a line that I made "invisible" and added connection points to it, and then attached text objects to the line. Currently the drawback with this approach is that you always have to make sure the line´s color is that of whatever is in the background. So in this particular case it might actually just be about making *lines* transparent. When it comes to most objects, they have a setting for drawing/not drawing the background. I guess that could be considered an existing option that lets you have an invisible/transparent background. It's sort of related, but I'd like a better way of controlling the connection points on a line. I'll bring up that issue on the mailing list before I file it in bugzilla.
A transparent color or transparency setting is not the correct solution to your problem. However, it is a very useful thing in and of itself, for instance for doing Venn diagrams or shading areas. A number of the exporters would not be able to support it, and adding support to those that can would be the major part of the code required to implement this.
And? (I'm not sure what, if any, further input you'd like from me)
Nothing, really, unless it's a patch that adds transparency:)
Hi, I'd love to have the "transparent colour" feature, too. This could be used not only to do fancy things like those previously mentioned in comment #3 but also to e.g. set the background colour as transparent and so export PNG with a transparent background (instead of a solid colour). Currently I have to export my DIA diagrams as PNG with white background, then load them with GIMP and manually add the alfa channel... it's really uncomfortable! Please add this feature!
(In reply to comment #6) > export PNG with a transparent background (instead of a solid colour). this already is possible with Dia 0.96.x, please try to export as "Cairo PNG (with alpha)"
(In reply to comment #7) > (In reply to comment #6) > > export PNG with a transparent background (instead of a solid colour). > this already is possible with Dia 0.96.x, please try to export as "Cairo PNG > (with alpha)" Using the stock Dia 0.96.1 coming with Ubuntu 8.04 I don't see that save option; wrt to PNG I have two only options: "Portable Network Graphics (*.png)" and "Pixbuf[png] (*.png)". None of them exports the background as transparent. Btw if I go under Diagram->Properties and then click on the tab "Colours" I see the background colour is set to white, so I think it's right that saving to PNG generates images with white background. If I could select "transparent" as background colour, I think that it would be logical to create transparent PNG when exporting...
Created attachment 141350 [details] Partial transparent background color effect Playing with the patch from bug #591525 I got the attached effect. To me this makes the idea of controlling the background transparency for export via the diagrams background color transparency not that appealing. With the current drawing model the background color must be opaque, because it is used to clear the background to a defined state.
With the alpha branch merged to master this feature is available (see bug #591525 for detaily), of course with above mentioned limitation. Not all renderers are supporting transparency so making objects completely transparent doe not always make them invisble ;)