Skip to content

Conversation

@Claes34
Copy link

@Claes34 Claes34 commented Aug 31, 2022

This PR adds a new ignoreDynamicFontSize property that is necessary if you want to set sizes for other styles then italic or bold without setting the fontName (you cannot get SFUI font via name).

Inspired by an old but still opened PR.

@Narayane
Copy link

@SimonFairbairn possible to include this PR in next release please?

Copy link

@leolobato leolobato left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Requesting changes only for the indentation.

font = UIFont.preferredFont(forTextStyle: textStyle)
}

if ignoreDynamicFontSize, let fontSize = fontSize {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe it would be a good idea to fix indentation before merging?

public var underlineLinks : Bool = false

/// **iOS only** : Setting this boolean to true will force using the exact size set for each style if available.
public var ignoreDynamicFontSize : Bool = false

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This works and covers an genuine use case, but a better solution might be to use scaledFont(for:, maximumPointSize:) from UIFontMetrics on SwiftyMarkdown+iOS.swift instead?

@Narayane Narayane force-pushed the feature/ignore-dynamic-font-size branch from 40c26cd to f5a9f49 Compare November 16, 2022 18:14
@Narayane
Copy link

Hi @leolobato,
I have done your requested changes.
Thanks.

@Claes34
Copy link
Author

Claes34 commented Nov 18, 2022

Hi @leolobato,

I have done your requested changes.

Thanks.

Thanks Seb

@Narayane
Copy link

@leolobato possible to merge it plz?

@leolobato
Copy link

@Narayane I don't have write permission to this repository. Only @SimonFairbairn should be able to merge and by the number of open, unmerged PRs, I suspect he doesn't have time to maintain this library anymore.

I suggest you use your own fork with the fix on your project.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants