wordpress-mobile / wordpress-mobile/AztecEditor-iOS

`UITextWritingDirection` deprecation warning

Open
#1,371 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

[Type] Enhancement
Dominant language
Swift
Stars
669
Forks
153
Avg merge
11h 27m
Merged PRs (30d)
4

Description

Since iOS13.0 the usage of the UITextWritingDirection typealias is deprecated in favour of the existing underlying NSWritingDirection data type: https://developer.apple.com/documentation/uikit/uitextwritingdirection

Since we use these as the return type when defining methods like baseWritingDirectionForPosition in the header file, it causes warnings in the editor where this dependency is used. For example in WCiOS:

Screenshot 2023-08-11 at 08 14 12
'UITextWritingDirection' is deprecated: first deprecated in iOS 13.0

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Search the header declarations for methods such as baseWritingDirectionForPosition that use UITextWritingDirection, then inspect the surrounding API definitions. Update the deprecated type usage to the underlying type described in the issue and verify that the dependency no longer produces the iOS 13 deprecation warning.

Written by the indexing model from the issue text.

Assessment

Tech stack
swift
Domain
mobile-dev
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.