Bug 59317 - [appkit/uikit] Simplify NSAttributedString (currently split in 3 frameworks)
Summary: [appkit/uikit] Simplify NSAttributedString (currently split in 3 frameworks)
Status: CONFIRMED
Alias: None
Product: iOS
Classification: Xamarin
Component: Xamarin.iOS.dll (show other bugs)
Version: XI 10.99 (xcode9)
Hardware: PC Mac OS
: Normal enhancement
Target Milestone: Future Cycle (TBD)
Assignee: Bugzilla
URL:
Depends on:
Blocks:
 
Reported: 2017-09-08 04:04 UTC by Vincent Dondain [MSFT]
Modified: 2017-09-21 15:00 UTC (History)
2 users (show)

See Also:
Tags:
Is this bug a regression?: ---
Last known good build:


Attachments

Description Vincent Dondain [MSFT] 2017-09-08 04:04:40 UTC
NSAttributedString constants are defined in multiple places:

[iOS/Mac] Foundation’s NSAttributedString (x3 cause there are 3 declarations) + DictionaryContainer in NSAttributedString.mac.cs (missing iOS strong dictionary)
[iOS] UIKit’s UIStringAttributeKey + DictionaryContainer in NSAttributedString.iOS.cs
[Mac] AppKit’s NSStringAttributeKey + DictionaryContainer in NSStringAttributes.cs && NSAttributedString.mac.cs (edited)

Some stuff in UIKit, some in appkit, some in foundation (but duplicated Fields cause they are also in AppKit), actually in all 3 frameworks.

We have `NSStringAttributes.cs` and `NSAttributedString.mac.cs` (there seems to be some duplication).

In PR 2599 I added the new field to https://github.com/VincentDondain/xamarin-macios/blob/0c4bf1a9c5f80e9cca56a07de9e9480ce1287802/src/foundation.cs#L13185-L13255 but I’m not sure this should actually live in `foundation.cs` maybe the separation between AppKit and UIKit is the way to go.

This feels like it's just adding to the mess so we may want to simplify things (:

Note You need to log in before you can comment on or make changes to this bug.