File tree Expand file tree Collapse file tree 2 files changed +15
-0
lines changed
Sources/SwiftRichString/Style Expand file tree Collapse file tree 2 files changed +15
-0
lines changed Original file line number Diff line number Diff line change @@ -487,6 +487,7 @@ The following properties are available:
487487| font | `FontConvertible` | font used in text |
488488| color | `ColorConvertible` | foreground color of the text |
489489| backColor | `ColorConvertible` | background color of the text |
490+ | shadow | `NSShadow` | shadow effect of the text |
490491| underline | `(NSUnderlineStyle? ,ColorConvertible? )` | underline style and color (if color is nil foreground is used) |
491492| strikethrough | `(NSUnderlineStyle? ,ColorConvertible? )` | strikethrough style and color (if color is nil foreground is used) |
492493| baselineOffset | `Float ` | character’s offset from the baseline, in point |
Original file line number Diff line number Diff line change @@ -325,6 +325,20 @@ public class Style: StyleProtocol {
325325 }
326326 }
327327
328+ #if os(iOS) || os(tvOS) || os(macOS)
329+
330+ /// The value of this attribute is an `NSShadow` object. The default value of this property is nil.
331+ public var shadow : NSShadow ? {
332+ set {
333+ self . set ( attribute: shadow, forKey: . shadow)
334+ }
335+ get {
336+ return self . get ( attributeForKey: . shadow)
337+ }
338+ }
339+
340+ #endif
341+
328342 #if os(iOS) || os(tvOS) || os(watchOS)
329343
330344 /// Enable spoken of all punctuation in the text.
You can’t perform that action at this time.
0 commit comments