Author Topic: Opacity  (Read 595 times)

March 13, 2019, 12:59:41 AM
Read 595 times

Krzysztof

  • Jr. Member

  • Offline
  • ***

  • 40
Hello, i would like to know if current opacity settings in Inkscape are proper according to SVG standard.
Each object created in Inkscape has 3 attributes what describe transparency - Opacity, Fill-Opacity and Stroke-Opacity. Adobe Illustrator CS6 doesn't create Fill-Opacity and Stroke-Opacity, interprets transparency (from inkscape) like it should (at least) but shows that object has no transparency at attributes level.
And I have third competitor, the most important one, which is totally confused when all 3 attributes are on object - it just ignores transparency completely.
How should viewer interpret all these attributes? Sum it up?
Can I somehow disable fill-opacity and stroke-opacity creation in Inkscape?
  • 0.92.3
  • Win7x64

March 13, 2019, 06:22:13 AM
Reply #1

Moini

  • IC Mentor

  • Offline
  • ******

  • 1,568
    • VektorRascheln
Set the Alpha of the fill and stroke color to 0. Does that solve the problem?

And yes, Inkscape handles that correctly. Usually, browsers are the best applications to compare with, e.g. Firefox or Chrome/Chromium.

March 13, 2019, 08:48:57 AM
Reply #2

Krzysztof

  • Jr. Member

  • Offline
  • ***

  • 40
Yes, the third competitor (TGML) sees transparency correctly when alpha for both fill and stroke are set and global transparency set to defualt 100%. But Adobe doesn't use alpha transparency and manage only opacity attribute and TGML accept this.
I solve this by removing all fill-opacity and stroke-opacity from notepad on svg file. Inkscape doesn't recreate these attributes if I don't touch alpha color. Setting alpha to 0 make object vanish completely so this is not good solution.
  • 0.92.3
  • Win7x64

March 13, 2019, 09:45:23 AM
Reply #3

Moini

  • IC Mentor

  • Offline
  • ******

  • 1,568
    • VektorRascheln
Oops, sorry. I meant 1 instead of 0... too quick... :-(

March 13, 2019, 03:13:20 PM
Reply #4

Krzysztof

  • Jr. Member

  • Offline
  • ***

  • 40
Oops, sorry. I meant 1 instead of 0... too quick... :-(

It doesn't matter. If i touch alpha color Inkscape recreates fill-opacity and stroke-opacity. If there are not such attributes in object definition Inkscape doesn't recreate them and interprets like both are set to 1.
This is why I asked if I can disable something in Inkscape to not create fill/stroke opacity attributes at all. Think it is not possible.
  • 0.92.3
  • Win7x64

March 13, 2019, 03:23:30 PM
Reply #5

Lazur

  • IC Mentor

  • Offline
  • ******
  • Inkscape Filters Wizard

  • 1,154
  • Gender
    Male

    Male
You can set both fill and stroke style to be unset -next to the fill rule icon in the fill and stroke tab.
Inkscape renders those as plain black fill with no stroke.

March 13, 2019, 04:18:15 PM
Reply #6

brynn

  • Administrator

  • Offline
  • ******

  • 3,941
  • Gender
    Female

    Female
    • Inkscape Community
Fyi, it's the question mark icon, for Unset fill and/or stroke.  :)
  • Inkscape version 0.92.3
  • Windows 7 Pro, 64-bit
Inkscape Tutorials (and manuals)                      Inkscape Community Gallery                        Inkscape for Cutting Design                     



"Be ashamed to die until you have won some victory for humanity" - Horace Mann                       

March 14, 2019, 01:15:54 AM
Reply #7

Krzysztof

  • Jr. Member

  • Offline
  • ***

  • 40
You can set both fill and stroke style to be unset -next to the fill rule icon in the fill and stroke tab.
Inkscape renders those as plain black fill with no stroke.

I don't want to remove stroke/fill style but "fill-opacity" and "stroke-opacity" attributes. So again, which icon does this? For sure not a question mark.
I think i need to find it somewhere in the code of inkscape and replace for example fill-opacity to fill-upacity for inkscape never again mess with this attributes. No browser will interpret fill-upacity or stroke-upacity correctly, just ignore it.
  • 0.92.3
  • Win7x64

March 14, 2019, 03:20:11 AM
Reply #8

brynn

  • Administrator

  • Offline
  • ******

  • 3,941
  • Gender
    Female

    Female
    • Inkscape Community
No, the question mark icon is the button for Unset fill.  But your're right, it looks like Unset doesn't remove the fill-opacity and stroke-opacity, from the style attribute.

I don't think there's any way to avoid those attribute values.  Maybe you can find a different program which can handle them properly?
  • Inkscape version 0.92.3
  • Windows 7 Pro, 64-bit
Inkscape Tutorials (and manuals)                      Inkscape Community Gallery                        Inkscape for Cutting Design                     



"Be ashamed to die until you have won some victory for humanity" - Horace Mann                       

March 14, 2019, 11:53:33 AM
Reply #9

Moini

  • IC Mentor

  • Offline
  • ******

  • 1,568
    • VektorRascheln
Another idea: Does it help if you save as 'Optimized SVG' and check the first two options in the first tab of the save dialog (shorten... / convert ...)?