আমি কীভাবে কোনও এনএসএট্রিবিউটেড স্ট্রিংয়ে পাঠ্য প্রান্তিককরণের বৈশিষ্ট্যটি পাঠাতে পারি?
সম্পাদনা: আমি কি কিছু ভুল করছি? এটি প্রান্তিককরণ পরিবর্তন বলে মনে হচ্ছে না।
CTParagraphStyleSetting setting;
setting.spec = kCTParagraphStyleSpecifierAlignment;
setting.valueSize = kCTCenterTextAlignment;
CTParagraphStyleSetting settings[1] = {
{kCTParagraphStyleSpecifierAlignment, sizeof(CGFloat), &setting},
};
CTParagraphStyleRef paragraph = CTParagraphStyleCreate(settings, sizeof(setting));
NSMutableAttributedString *mutableAttributed = [[NSMutableAttributedString alloc] initWithAttributedString:self.attributedString];
[mutableAttributed addAttributes:[NSDictionary dictionaryWithObjectsAndKeys:(NSObject*)paragraph ,(NSString*) kCTParagraphStyleAttributeName, nil] range:_selectedRange];