You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Aug 25, 2020. It is now read-only.
labelLeft.icon = UIImage(named: "Bell") // Set icon image
labelLeft.iconPadding = 5 // Set padding between icon and label
labelLeft.numberOfLines = 1 // Required
labelLeft.iconPosition =( .Right, .Center ) // Icon position
In this case text is not shown properly. Fixed it by updating SMIconLabel as
if iconPosition.horizontal == .Right {
if textAlignment == .Right {
iconView.frame = CGRectOffset(iconView.frame, frame.width - iconView.frame.width, iconYPosition)
// newRect = CGRectMake(frame.width - size.width - iconView.frame.width - iconPadding, 0, size.width, height)
newRect = CGRectMake(0, 0, frame.width - (iconView.frame.width + iconPadding), height)
}
The text was updated successfully, but these errors were encountered:
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
labelLeft.icon = UIImage(named: "Bell") // Set icon image
labelLeft.iconPadding = 5 // Set padding between icon and label
labelLeft.numberOfLines = 1 // Required
labelLeft.iconPosition =( .Right, .Center ) // Icon position
In this case text is not shown properly. Fixed it by updating SMIconLabel as
if iconPosition.horizontal == .Right {
if textAlignment == .Right {
iconView.frame = CGRectOffset(iconView.frame, frame.width - iconView.frame.width, iconYPosition)
// newRect = CGRectMake(frame.width - size.width - iconView.frame.width - iconPadding, 0, size.width, height)
newRect = CGRectMake(0, 0, frame.width - (iconView.frame.width + iconPadding), height)
}
The text was updated successfully, but these errors were encountered: