Scripting Bridge, ability to get ranges from an SBElementArray
| Originator: | amorya | ||
| Number: | rdar://19353255 | Date Originated: | 28-Dec-2014 06:41 PM |
| Status: | Open | Resolved: | |
| Product: | OS X | Product Version: | Mac OS X 10.10.1 (14B25) |
| Classification: | Other Bug | Reproducible: | Not Applicable |
I’m trying to work with rich text through the Scripting Bridge. The idiom I’m trying to use is “apply this font name to characters 5-9”, for example. In Applescript I could just do “characters 5 thru 9”, but in Scripting Bridge I can’t find an equivalent. I’d like an API like this: - (SBElementArray*)[SBElementArray objectWithRange:(NSString*)rangeString] This would return another SBElementArray, which would be able to correctly proxy commands to the subset using only one AppleEvent. Current workaround: iterate, and send one Apple Event per character. Very inefficient and slow.
Comments
Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!