diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2021-01-19 09:58:01 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2021-01-19 14:33:10 +0100 |
commit | 064ce013a161e1aa02241a3a65191ae96136ec1b (patch) | |
tree | 2ce98cc9d717c8a3d4a8ea3052282a918f6ec136 /vcl/osx | |
parent | f32280f64ef10669b987ad61b0b5fe449d3f4285 (diff) |
loplugin:colorcheck (macOS)
as suggested by noelgrandin on IRC, "just add ColorTransparency as the first
param, since that will maintain whatever the code is doing currently (whether it
is actually correct is a different story)"
Change-Id: I3fd7f10ffadc343f3f9a532120e2a7bbb33244d7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109616
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Tested-by: Jenkins
Diffstat (limited to 'vcl/osx')
-rw-r--r-- | vcl/osx/a11ytextattributeswrapper.mm | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/vcl/osx/a11ytextattributeswrapper.mm b/vcl/osx/a11ytextattributeswrapper.mm index ac4cb7d2444d..a1a6d0350e4b 100644 --- a/vcl/osx/a11ytextattributeswrapper.mm +++ b/vcl/osx/a11ytextattributeswrapper.mm @@ -232,9 +232,9 @@ using namespace ::com::sun::star::uno; } else if ( property.Name == "CharUnderlineHasColor" ) { underlineHasColor = [ AquaA11yTextAttributesWrapper convertBoolean: property ]; } else if ( property.Name == "CharColor" ) { - [ AquaA11yTextAttributesWrapper addColor: property.Value.get<sal_Int32>() forAttribute: NSAccessibilityForegroundColorTextAttribute andRange: range toString: string ]; + [ AquaA11yTextAttributesWrapper addColor: Color(ColorTransparency, property.Value.get<sal_Int32>()) forAttribute: NSAccessibilityForegroundColorTextAttribute andRange: range toString: string ]; } else if ( property.Name == "CharBackColor" ) { - [ AquaA11yTextAttributesWrapper addColor: property.Value.get<sal_Int32>() forAttribute: NSAccessibilityBackgroundColorTextAttribute andRange: range toString: string ]; + [ AquaA11yTextAttributesWrapper addColor: Color(ColorTransparency, property.Value.get<sal_Int32>()) forAttribute: NSAccessibilityBackgroundColorTextAttribute andRange: range toString: string ]; } else if ( property.Name == "CharEscapement" ) { // values < zero mean subscript // values > zero mean superscript @@ -267,7 +267,7 @@ SAL_WNODEPRECATED_DECLARATIONS_POP } // add underline information if ( underlineHasColor ) { - [ AquaA11yTextAttributesWrapper addColor: underlineColor forAttribute: NSAccessibilityUnderlineColorTextAttribute andRange: range toString: string ]; + [ AquaA11yTextAttributesWrapper addColor: Color(ColorTransparency, underlineColor) forAttribute: NSAccessibilityUnderlineColorTextAttribute andRange: range toString: string ]; } // add font information NSFont * font = [fontDescriptor font]; |